ApplicationInsights-JS/AISKULight/dist-history/aisdklite.0.0.3.min.js

2 строки
80 KiB
JavaScript

!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var n=t();for(var i in n)("object"==typeof exports?exports:e)[i]=n[i]}}(window,function(){return function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=16)}([function(e,t,n){var i,r;i=[n,t,n(1),n(3),n(12),n(2)],void 0===(r=function(e,t,n,i,r,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=function(){function e(){}return e.disableStorage=function(){e._canUseLocalStorage=!1,e._canUseSessionStorage=!1},e._getLocalStorageObject=function(){return e.canUseLocalStorage()?e._getVerifiedStorageObject(n.StorageType.LocalStorage):null},e._getVerifiedStorageObject=function(e){var t,i,r=null;try{i=new Date,(r=e===n.StorageType.LocalStorage?window.localStorage:window.sessionStorage).setItem(i,i),t=r.getItem(i)!=i,r.removeItem(i),t&&(r=null)}catch(e){r=null}return r},e.isInternalApplicationInsightsEndpoint=function(t){return-1!==e._internalEndpoints.indexOf(t.toLowerCase())},e.canUseLocalStorage=function(){return void 0===e._canUseLocalStorage&&(e._canUseLocalStorage=!!e._getVerifiedStorageObject(n.StorageType.LocalStorage)),e._canUseLocalStorage},e.getStorage=function(t,n){var r=e._getLocalStorageObject();if(null!==r)try{return r.getItem(n)}catch(n){e._canUseLocalStorage=!1,t.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.BrowserCannotReadLocalStorage,"Browser failed read of local storage. "+e.getExceptionName(n),{exception:e.dump(n)})}return null},e.setStorage=function(t,n,r){var o=e._getLocalStorageObject();if(null!==o)try{return o.setItem(n,r),!0}catch(n){e._canUseLocalStorage=!1,t.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.BrowserCannotWriteLocalStorage,"Browser failed write to local storage. "+e.getExceptionName(n),{exception:e.dump(n)})}return!1},e.removeStorage=function(t,n){var r=e._getLocalStorageObject();if(null!==r)try{return r.removeItem(n),!0}catch(n){e._canUseLocalStorage=!1,t.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.BrowserFailedRemovalFromLocalStorage,"Browser failed removal of local storage item. "+e.getExceptionName(n),{exception:e.dump(n)})}return!1},e._getSessionStorageObject=function(){return e.canUseSessionStorage()?e._getVerifiedStorageObject(n.StorageType.SessionStorage):null},e.canUseSessionStorage=function(){return void 0===e._canUseSessionStorage&&(e._canUseSessionStorage=!!e._getVerifiedStorageObject(n.StorageType.SessionStorage)),e._canUseSessionStorage},e.getSessionStorageKeys=function(){var t=[];if(e.canUseSessionStorage())for(var n in window.sessionStorage)t.push(n);return t},e.getSessionStorage=function(t,n){var r=e._getSessionStorageObject();if(null!==r)try{return r.getItem(n)}catch(n){e._canUseSessionStorage=!1,t.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.BrowserCannotReadSessionStorage,"Browser failed read of session storage. "+e.getExceptionName(n),{exception:e.dump(n)})}return null},e.setSessionStorage=function(t,n,r){var o=e._getSessionStorageObject();if(null!==o)try{return o.setItem(n,r),!0}catch(n){e._canUseSessionStorage=!1,t.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.BrowserCannotWriteSessionStorage,"Browser failed write to session storage. "+e.getExceptionName(n),{exception:e.dump(n)})}return!1},e.removeSessionStorage=function(t,n){var r=e._getSessionStorageObject();if(null!==r)try{return r.removeItem(n),!0}catch(n){e._canUseSessionStorage=!1,t.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.BrowserFailedRemovalFromSessionStorage,"Browser failed removal of session storage item. "+e.getExceptionName(n),{exception:e.dump(n)})}return!1},e.disableCookies=function(){e._canUseCookies=!1},e.canUseCookies=function(t){if(void 0===e._canUseCookies){e._canUseCookies=!1;try{e._canUseCookies=void 0!==e.document.cookie}catch(n){t.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.CannotAccessCookie,"Cannot access document.cookie - "+e.getExceptionName(n),{exception:e.dump(n)})}}return e._canUseCookies},e.setCookie=function(t,n,i,r){var o="",a="";r&&(o=";domain="+r),e.document.location&&"https:"===e.document.location.protocol&&(a=";secure"),e.canUseCookies(t)&&(e.document.cookie=n+"="+i+o+";path=/"+a)},e.stringToBoolOrDefault=function(e,t){return void 0===t&&(t=!1),null==e?t:"true"===e.toString().toLowerCase()},e.getCookie=function(t,n){if(e.canUseCookies(t)){var i="";if(n&&n.length)for(var r=n+"=",o=e.document.cookie.split(";"),a=0;a<o.length;a++){var s=o[a];if((s=e.trim(s))&&0===s.indexOf(r)){i=s.substring(r.length,o[a].length);break}}return i}},e.deleteCookie=function(t,n){e.canUseCookies(t)&&(e.document.cookie=n+"=;path=/;expires=Thu, 01 Jan 1970 00:00:01 GMT;")},e.trim=function(e){return"string"!=typeof e?e:e.replace(/^\s+|\s+$/g,"")},e.newId=function(){for(var e="",t=1073741824*Math.random();t>0;){e+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(t%64),t=Math.floor(t/64)}return e},e.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)},e.isError=function(e){return"[object Error]"===Object.prototype.toString.call(e)},e.isDate=function(e){return"[object Date]"===Object.prototype.toString.call(e)},e.toISOStringForIE8=function(t){if(e.isDate(t)){if(Date.prototype.toISOString)return t.toISOString();var n=function(e){var t=String(e);return 1===t.length&&(t="0"+t),t};return t.getUTCFullYear()+"-"+n(t.getUTCMonth()+1)+"-"+n(t.getUTCDate())+"T"+n(t.getUTCHours())+":"+n(t.getUTCMinutes())+":"+n(t.getUTCSeconds())+"."+String((t.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}},e.getIEVersion=function(e){void 0===e&&(e=null);var t=e?e.toLowerCase():navigator.userAgent.toLowerCase();return-1!=t.indexOf("msie")?parseInt(t.split("msie")[1]):null},e.msToTimeSpan=function(e){(isNaN(e)||e<0)&&(e=0);var t=""+(e=Math.round(e))%1e3,n=""+Math.floor(e/1e3)%60,i=""+Math.floor(e/6e4)%60,r=""+Math.floor(e/36e5)%24,o=Math.floor(e/864e5);return t=1===t.length?"00"+t:2===t.length?"0"+t:t,n=n.length<2?"0"+n:n,i=i.length<2?"0"+i:i,(o>0?o+".":"")+(r=r.length<2?"0"+r:r)+":"+i+":"+n+"."+t},e.isCrossOriginError=function(e,t,n,i,r){return("Script error."===e||"Script error"===e)&&!r},e.dump=function(e){var t=Object.prototype.toString.call(e),n=JSON.stringify(e);return"[object Error]"===t&&(n="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e.name+"'"),t+n},e.getExceptionName=function(e){return"[object Error]"===Object.prototype.toString.call(e)?e.name:""},e.addEventHandler=function(e,t){if(!window||"string"!=typeof e||"function"!=typeof t)return!1;var n="on"+e;if(window.addEventListener)window.addEventListener(e,t,!1);else{if(!window.attachEvent)return!1;window.attachEvent(n,t)}return!0},e.IsBeaconApiSupported=function(){return"sendBeacon"in navigator&&navigator.sendBeacon},e.document="undefined"!=typeof document?document:{},e._canUseCookies=void 0,e._canUseLocalStorage=void 0,e._canUseSessionStorage=void 0,e._internalEndpoints=["https://dc.services.visualstudio.com/v2/track","https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"],e.NotSpecified="not_specified",e}();t.Util=a;var s=function(){function e(){}return e.parseUrl=function(t){return e.htmlAnchorElement||(e.htmlAnchorElement=e.document.createElement?e.document.createElement("a"):{}),e.htmlAnchorElement.href=t,e.htmlAnchorElement},e.getAbsoluteUrl=function(t){var n,i=e.parseUrl(t);return i&&(n=i.href),n},e.getPathName=function(t){var n,i=e.parseUrl(t);return i&&(n=i.pathname),n},e.getCompleteUrl=function(e,t){return e?e.toUpperCase()+" "+t:t},e.document="undefined"!=typeof document?document:{},e}();t.UrlHelper=s;var l=function(){function e(){}return e.canIncludeCorrelationHeader=function(e,t,n){if(e&&e.disableCorrelationHeaders)return!1;if(!t)return!1;var i=s.parseUrl(t).host.toLowerCase();if(!(e&&e.enableCorsCorrelation||i===n))return!1;var r=e&&e.correlationHeaderExcludedDomains;if(!r||0==r.length)return!0;for(var o=0;o<r.length;o++){if(new RegExp(r[o].toLowerCase().replace(/\./g,".").replace(/\*/g,".*")).test(i))return!1}return!0},e.getCorrelationContext=function(t){if(t){var n=e.getCorrelationContextValue(t,r.RequestHeaders.requestContextTargetKey);if(n&&n!==e.correlationIdPrefix)return n}},e.getCorrelationContextValue=function(e,t){if(e)for(var n=e.split(","),i=0;i<n.length;++i){var r=n[i].split("=");if(2==r.length&&r[0]==t)return r[1]}},e.correlationIdPrefix="cid-v1:",e}();t.CorrelationIdHelper=l;var u=function(){function e(){}return e.ParseDependencyPath=function(e,t,n,i){var r,a;if(t&&t.length>0){var l=s.parseUrl(t);if(r=l.host,null!=l.pathname)"/"!==(i=0===l.pathname.length?"/":l.pathname).charAt(0)&&(i="/"+i),a=o.DataSanitizer.sanitizeString(e,n?n+" "+i:i);else a=o.DataSanitizer.sanitizeString(e,t)}else r=i,a=i;return{target:r,name:a}},e}();t.AjaxHelper=u;var c=function(){function e(){}return e.Now=window.performance&&window.performance.now&&window.performance.timing?function(){return window.performance.now()+window.performance.timing.navigationStart}:function(){return(new Date).getTime()},e.GetDuration=function(e,t){var n=null;return 0===e||0===t||i.CoreUtils.isNullOrUndefined(e)||i.CoreUtils.isNullOrUndefined(t)||(n=t-e),n},e}();t.DateTimeUtils=c}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.LocalStorage=0]="LocalStorage",e[e.SessionStorage=1]="SessionStorage"}(t.StorageType||(t.StorageType={})),function(e){e[e.Default=0]="Default",e[e.Required=1]="Required",e[e.Array=2]="Array",e[e.Hidden=4]="Hidden"}(t.FieldType||(t.FieldType={}))}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r;i=[n,t,n(3),n(0)],void 0===(r=function(e,t,n,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(){}return e.sanitizeKeyAndAddUniqueness=function(t,n,i){var r=n.length,o=e.sanitizeKey(t,n);if(o.length!==r){for(var a=0,s=o;void 0!==i[s];)a++,s=o.substring(0,e.MAX_NAME_LENGTH-3)+e.padNumber(a);o=s}return o},e.sanitizeKey=function(t,r){return r&&(r=i.Util.trim(r.toString())).length>e.MAX_NAME_LENGTH&&(r=r.substring(0,e.MAX_NAME_LENGTH),t.throwInternal(n.LoggingSeverity.WARNING,n._InternalMessageId.NameTooLong,"name is too long. It has been truncated to "+e.MAX_NAME_LENGTH+" characters.",{name:r},!0)),r},e.sanitizeString=function(t,r,o){return void 0===o&&(o=e.MAX_STRING_LENGTH),r&&(o=o||e.MAX_STRING_LENGTH,(r=i.Util.trim(r)).toString().length>o&&(r=r.toString().substring(0,o),t.throwInternal(n.LoggingSeverity.WARNING,n._InternalMessageId.StringValueTooLong,"string value is too long. It has been truncated to "+o+" characters.",{value:r},!0))),r},e.sanitizeUrl=function(t,i){return e.sanitizeInput(t,i,e.MAX_URL_LENGTH,n._InternalMessageId.UrlTooLong)},e.sanitizeMessage=function(t,i){return i&&i.length>e.MAX_MESSAGE_LENGTH&&(i=i.substring(0,e.MAX_MESSAGE_LENGTH),t.throwInternal(n.LoggingSeverity.WARNING,n._InternalMessageId.MessageTruncated,"message is too long, it has been truncated to "+e.MAX_MESSAGE_LENGTH+" characters.",{message:i},!0)),i},e.sanitizeException=function(t,i){return i&&i.length>e.MAX_EXCEPTION_LENGTH&&(i=i.substring(0,e.MAX_EXCEPTION_LENGTH),t.throwInternal(n.LoggingSeverity.WARNING,n._InternalMessageId.ExceptionTruncated,"exception is too long, it has been truncated to "+e.MAX_EXCEPTION_LENGTH+" characters.",{exception:i},!0)),i},e.sanitizeProperties=function(t,n){if(n){var i={};for(var r in n){var o=e.sanitizeString(t,n[r],e.MAX_PROPERTY_LENGTH);i[r=e.sanitizeKeyAndAddUniqueness(t,r,i)]=o}n=i}return n},e.sanitizeMeasurements=function(t,n){if(n){var i={};for(var r in n){var o=n[r];i[r=e.sanitizeKeyAndAddUniqueness(t,r,i)]=o}n=i}return n},e.sanitizeId=function(t,i){return i?e.sanitizeInput(t,i,e.MAX_ID_LENGTH,n._InternalMessageId.IdTooLong).toString():i},e.sanitizeInput=function(e,t,r,o){return t&&(t=i.Util.trim(t)).length>r&&(t=t.substring(0,r),e.throwInternal(n.LoggingSeverity.WARNING,o,"input is too long, it has been truncated to "+r+" characters.",{data:t},!0)),t},e.padNumber=function(e){var t="00"+e;return t.substr(t.length-3)},e.MAX_NAME_LENGTH=150,e.MAX_ID_LENGTH=128,e.MAX_PROPERTY_LENGTH=8192,e.MAX_STRING_LENGTH=1024,e.MAX_URL_LENGTH=2048,e.MAX_MESSAGE_LENGTH=32768,e.MAX_EXCEPTION_LENGTH=32768,e}();t.DataSanitizer=r}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r;i=[n,t,n(19),n(8),n(20),n(6),n(9),n(10),n(11)],void 0===(r=function(e,t,n,i,r,o,a,s,l){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MinChannelPriorty=n.MinChannelPriorty,t.EventsDiscardedReason=i.EventsDiscardedReason,t.AppInsightsCore=r.AppInsightsCore,t.CoreUtils=o.CoreUtils,t.NotificationManager=a.NotificationManager,t.DiagnosticLogger=s.DiagnosticLogger,t._InternalLogMessage=s._InternalLogMessage,t._InternalMessageId=l._InternalMessageId,t.LoggingSeverity=l.LoggingSeverity}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){return function(){}}();t.Domain=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r;i=[n,t,n(0),n(1),n(12),n(30),n(13),n(14),n(31),n(33),n(34),n(25),n(38),n(7),n(39),n(41),n(43),n(45),n(46),n(47),n(2),n(48)],void 0===(r=function(e,t,n,i,r,o,a,s,l,u,c,p,f,d,g,h,v,y,_,m,I,S){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Util=n.Util,t.CorrelationIdHelper=n.CorrelationIdHelper,t.UrlHelper=n.UrlHelper,t.DateTimeUtils=n.DateTimeUtils,t.FieldType=i.FieldType,t.RequestHeaders=r.RequestHeaders,t.DisabledPropertyName=o.DisabledPropertyName,t.AIData=a.Data,t.AIBase=s.Base,t.Envelope=l.Envelope,t.Event=u.Event,t.Exception=c.Exception,t.Metric=p.Metric,t.PageView=f.PageView,t.PageViewData=d.PageViewData,t.RemoteDependencyData=g.RemoteDependencyData,t.Trace=h.Trace,t.PageViewPerformance=v.PageViewPerformance,t.Data=y.Data,t.SeverityLevel=_.SeverityLevel,t.ContextTagKeys=m.ContextTagKeys,t.DataSanitizer=I.DataSanitizer,t.TelemetryItemCreator=S.TelemetryItemCreator}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){}return e.isNullOrUndefined=function(e){return null==e},e.newGuid=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(i,function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)})},e}();t.CoreUtils=n;var i=/[xy]/g}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(15)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.properties={},t.measurements={},t}return o(t,e),t}(n.EventData);t.PageViewData=i}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EventsDiscardedReason={Unknown:0,NonRetryableStatus:1,InvalidEvent:2,SizeLimitExceeded:3,KillSwitch:4,QueueFull:5}}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){this.listeners=[]}return e.prototype.addNotificationListener=function(e){this.listeners.push(e)},e.prototype.removeNotificationListener=function(e){for(var t=this.listeners.indexOf(e);t>-1;)this.listeners.splice(t,1),t=this.listeners.indexOf(e)},e.prototype.eventsSent=function(e){for(var t=this,n=function(n){i.listeners[n].eventsSent&&setTimeout(function(){return t.listeners[n].eventsSent(e)},0)},i=this,r=0;r<this.listeners.length;++r)n(r)},e.prototype.eventsDiscarded=function(e,t){for(var n=this,i=function(i){r.listeners[i].eventsDiscarded&&setTimeout(function(){return n.listeners[i].eventsDiscarded(e,t)},0)},r=this,o=0;o<this.listeners.length;++o)i(o)},e}();t.NotificationManager=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r;i=[n,t,n(11),n(6)],void 0===(r=function(e,t,n,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(t,n,i,r){void 0===i&&(i=!1),this.messageId=t,this.message=(i?e.AiUserActionablePrefix:e.AiNonUserActionablePrefix)+t;var o=(n?" message:"+e.sanitizeDiagnosticText(n):"")+(r?" props:"+e.sanitizeDiagnosticText(JSON.stringify(r)):"");this.message+=o}return e.sanitizeDiagnosticText=function(e){return'"'+e.replace(/\"/g,"")+'"'},e.dataType="MessageData",e.AiNonUserActionablePrefix="AI (Internal): ",e.AiUserActionablePrefix="AI: ",e}();t._InternalLogMessage=r;var o=function(){function e(e){this.AIInternalMessagePrefix="AITR_",this.enableDebugExceptions=function(){return!1},this.consoleLoggingLevel=function(){return 1},this.telemetryLoggingLevel=function(){return 0},this.maxInternalMessageLimit=function(){return 25},this.queue=[],this._messageCount=0,this._messageLogged={},i.CoreUtils.isNullOrUndefined(e)||(i.CoreUtils.isNullOrUndefined(e.loggingLevelConsole)||(this.consoleLoggingLevel=function(){return e.loggingLevelConsole}),i.CoreUtils.isNullOrUndefined(e.loggingLevelTelemetry)||(this.telemetryLoggingLevel=function(){return e.loggingLevelTelemetry}),i.CoreUtils.isNullOrUndefined(e.maxMessageLimit)||(this.maxInternalMessageLimit=function(){return e.maxMessageLimit}),i.CoreUtils.isNullOrUndefined(e.enableDebugExceptions)||(this.enableDebugExceptions=function(){return e.enableDebugExceptions}))}return e.prototype.throwInternal=function(e,t,i,o,a){void 0===a&&(a=!1);var s=new r(t,i,a,o);if(this.enableDebugExceptions())throw s;if(void 0!==s&&s&&void 0!==s.message){if(a){var l=+s.messageId;(!this._messageLogged[l]||this.consoleLoggingLevel()>=n.LoggingSeverity.WARNING)&&(this.warnToConsole(s.message),this._messageLogged[l]=!0)}else this.consoleLoggingLevel()>=n.LoggingSeverity.WARNING&&this.warnToConsole(s.message);this.logInternalMessage(e,s)}},e.prototype.warnToConsole=function(e){"undefined"!=typeof console&&console&&("function"==typeof console.warn?console.warn(e):"function"==typeof console.log&&console.log(e))},e.prototype.resetInternalMessageCount=function(){this._messageCount=0,this._messageLogged={}},e.prototype.logInternalMessage=function(e,t){if(!this._areInternalMessagesThrottled()){var i=!0,o=this.AIInternalMessagePrefix+t.messageId;if(this._messageLogged[o]?i=!1:this._messageLogged[o]=!0,i&&(e<=this.telemetryLoggingLevel()&&(this.queue.push(t),this._messageCount++),this._messageCount==this.maxInternalMessageLimit())){var a="Internal events throttle limit per PageView reached for this app.",s=new r(n._InternalMessageId.MessageLimitPerPVExceeded,a,!1);this.queue.push(s),this.warnToConsole(a)}}},e.prototype._areInternalMessagesThrottled=function(){return this._messageCount>=this.maxInternalMessageLimit()},e}();t.DiagnosticLogger=o}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.CRITICAL=1]="CRITICAL",e[e.WARNING=2]="WARNING"}(t.LoggingSeverity||(t.LoggingSeverity={})),t._InternalMessageId={BrowserDoesNotSupportLocalStorage:0,BrowserCannotReadLocalStorage:1,BrowserCannotReadSessionStorage:2,BrowserCannotWriteLocalStorage:3,BrowserCannotWriteSessionStorage:4,BrowserFailedRemovalFromLocalStorage:5,BrowserFailedRemovalFromSessionStorage:6,CannotSendEmptyTelemetry:7,ClientPerformanceMathError:8,ErrorParsingAISessionCookie:9,ErrorPVCalc:10,ExceptionWhileLoggingError:11,FailedAddingTelemetryToBuffer:12,FailedMonitorAjaxAbort:13,FailedMonitorAjaxDur:14,FailedMonitorAjaxOpen:15,FailedMonitorAjaxRSC:16,FailedMonitorAjaxSend:17,FailedMonitorAjaxGetCorrelationHeader:18,FailedToAddHandlerForOnBeforeUnload:19,FailedToSendQueuedTelemetry:20,FailedToReportDataLoss:21,FlushFailed:22,MessageLimitPerPVExceeded:23,MissingRequiredFieldSpecification:24,NavigationTimingNotSupported:25,OnError:26,SessionRenewalDateIsZero:27,SenderNotInitialized:28,StartTrackEventFailed:29,StopTrackEventFailed:30,StartTrackFailed:31,StopTrackFailed:32,TelemetrySampledAndNotSent:33,TrackEventFailed:34,TrackExceptionFailed:35,TrackMetricFailed:36,TrackPVFailed:37,TrackPVFailedCalc:38,TrackTraceFailed:39,TransmissionFailed:40,FailedToSetStorageBuffer:41,FailedToRestoreStorageBuffer:42,InvalidBackendResponse:43,FailedToFixDepricatedValues:44,InvalidDurationValue:45,TelemetryEnvelopeInvalid:46,CreateEnvelopeError:47,CannotSerializeObject:48,CannotSerializeObjectNonSerializable:49,CircularReferenceDetected:50,ClearAuthContextFailed:51,ExceptionTruncated:52,IllegalCharsInName:53,ItemNotInArray:54,MaxAjaxPerPVExceeded:55,MessageTruncated:56,NameTooLong:57,SampleRateOutOfRange:58,SetAuthContextFailed:59,SetAuthContextFailedAccountName:60,StringValueTooLong:61,StartCalledMoreThanOnce:62,StopCalledWithoutStart:63,TelemetryInitializerFailed:64,TrackArgumentsNotSpecified:65,UrlTooLong:66,SessionStorageBufferFull:67,CannotAccessCookie:68,IdTooLong:69}}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){}return e.requestContextHeader="Request-Context",e.requestContextTargetKey="appId",e.requestContextAppIdFormat="appId=cid-v1:",e.requestIdHeader="Request-Id",e.sdkContextHeader="Sdk-Context",e.sdkContextHeaderAppIdRequest="appId",e.requestContextHeaderLowerCase="request-context",e}();t.RequestHeaders=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(14)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(){return e.call(this)||this}return o(t,e),t}(n.Base);t.Data=i}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){return function(){}}();t.Base=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(4)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.properties={},t.measurements={},t}return o(t,e),t}(n.Domain);t.EventData=i}.apply(t,i))||(e.exports=r)},function(e,t,n){e.exports=n(17)},function(e,t,n){var i,r,o;!function(a){if("object"==typeof e&&"object"==typeof e.exports){var s=a(n(18),t);void 0!==s&&(e.exports=s)}else r=[n,t,n(3),n(21)],void 0===(o="function"==typeof(i=a)?i.apply(t,r):i)||(e.exports=o)}(function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=e("applicationinsights-core-js"),i=e("applicationinsights-channel-js"),r=function(){function e(e){if(n.CoreUtils.isNullOrUndefined(e)||n.CoreUtils.isNullOrUndefined(e.instrumentationKey))throw new Error("Invalid input configuration");this.initialize()}return e.prototype.initialize=function(){this.core=new n.AppInsightsCore;var e=[],t=new i.Sender;e.push(t),this.core.initialize(this.config,e),t.initialize(this.config,this.core,e)},e.prototype.track=function(e){this.core.track(e)},e}();t.ApplicationInsights=r})},function(e,t){function n(e){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}n.keys=function(){return[]},n.resolve=n,e.exports=n,n.id=18},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MinChannelPriorty=100}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r;i=[n,t,n(8),n(6),n(9),n(10)],void 0===(r=function(e,t,n,i,r,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=function(){function e(){this._isInitialized=!1,this._extensions=new Array,this._channelController=new s}return e.prototype.initialize=function(e,t){var n=this;if(this._isInitialized)throw Error("Core should not be initialized more than once");if(!e||i.CoreUtils.isNullOrUndefined(e.instrumentationKey))throw Error("Please provide instrumentation key");if(this.config=e,this._notificationManager=new r.NotificationManager,this.config.extensions=i.CoreUtils.isNullOrUndefined(this.config.extensions)?[]:this.config.extensions,this.config.extensionConfig=i.CoreUtils.isNullOrUndefined(this.config.extensionConfig)?{}:this.config.extensionConfig,this.config.extensionConfig.NotificationManager=this._notificationManager,this.logger=new o.DiagnosticLogger(e),t.forEach(function(e){if(i.CoreUtils.isNullOrUndefined(e.initialize))throw Error(l)}),this.config.extensions.length>0){var a=!0;if(this.config.extensions.forEach(function(e){i.CoreUtils.isNullOrUndefined(e)&&(a=!1)}),!a)throw Error(l)}(c=this._extensions).push.apply(c,[this._channelController].concat(t,this.config.extensions)),this._extensions=this._extensions.sort(function(e,t){var n=e,i=t,r=typeof n.processTelemetry,o=typeof i.processTelemetry;return"function"===r&&"function"===o?n.priority-i.priority:"function"===r&&"function"!==o?1:"function"!==r&&"function"===o?-1:void 0});var s={};this._extensions.forEach(function(e){var t=e;t&&t.priority&&(i.CoreUtils.isNullOrUndefined(s[t.priority])?s[t.priority]=t.identifier:n.logger.warnToConsole("Two extensions have same priority"+s[t.priority]+", "+t.identifier))});for(var c,p=-1,f=0;f<this._extensions.length-1;f++){var d=this._extensions[f];if(!d||"function"==typeof d.processTelemetry){if(d.priority===u){p=f+1;break}this._extensions[f].setNextPlugin(this._extensions[f+1])}}if(this._channelController.initialize(this.config,this,this._extensions),this._extensions.forEach(function(e){e&&e.priority<u&&e.initialize(n.config,n,n._extensions)}),p<this._extensions.length&&this._extensions.splice(p),0===this.getTransmissionControls().length)throw new Error("No channels available");this._isInitialized=!0},e.prototype.getTransmissionControls=function(){return this._channelController.ChannelControls},e.prototype.track=function(e){if(null===e)throw this._notifiyInvalidEvent(e),Error("Invalid telemetry item");if(e.baseData&&!e.baseType)throw this._notifiyInvalidEvent(e),Error("Provide data.baseType for data.baseData");e.baseType||(e.baseType="EventData"),e.instrumentationKey||(e.instrumentationKey=this.config.instrumentationKey),e.timestamp||(e.timestamp=new Date),this._validateTelmetryItem(e);for(var t=0;t<this._extensions.length;){if(this._extensions[t].processTelemetry){this._extensions[t].processTelemetry(e);break}t++}},e.prototype.addNotificationListener=function(e){this._notificationManager.addNotificationListener(e)},e.prototype.removeNotificationListener=function(e){this._notificationManager.removeNotificationListener(e)},e.prototype.pollInternalLogs=function(){var e=this;if(!(this.config.diagnosticLoggingInterval>0))throw Error("config.diagnosticLoggingInterval must be a positive integer");return setInterval(function(){var t=e.logger.queue;t.forEach(function(t){var n={name:"InternalMessageId: "+t.messageId,instrumentationKey:e.config.instrumentationKey,timestamp:new Date,baseType:o._InternalLogMessage.dataType,baseData:{message:t.message}};e.track(n)}),t.length=0},this.config.diagnosticLoggingInterval)},e.prototype._validateTelmetryItem=function(e){if(i.CoreUtils.isNullOrUndefined(e.name))throw this._notifiyInvalidEvent(e),Error("telemetry name required");if(i.CoreUtils.isNullOrUndefined(e.timestamp))throw this._notifiyInvalidEvent(e),Error("telemetry timestamp required");if(i.CoreUtils.isNullOrUndefined(e.instrumentationKey))throw this._notifiyInvalidEvent(e),Error("telemetry instrumentationKey required")},e.prototype._notifiyInvalidEvent=function(e){this._notificationManager.eventsDiscarded([e],n.EventsDiscardedReason.InvalidEvent)},e}();t.AppInsightsCore=a;var s=function(){function e(){this.identifier="ChannelControllerPlugin",this.priority=u}return e.prototype.processTelemetry=function(e){this.channelQueue.forEach(function(t){t.length>0&&t[0].processTelemetry(e)})},Object.defineProperty(e.prototype,"ChannelControls",{get:function(){return this.channelQueue},enumerable:!0,configurable:!0}),e.prototype.initialize=function(e,t,n){var i=this;if(this.channelQueue=new Array,e.channels)e.channels.forEach(function(r){if(r&&r.length>0){(r=r.sort(function(e,t){return e.priority-t.priority})).forEach(function(i){return i.initialize(e,t,n)});for(var o=1;o<r.length;o++)r[o-1].setNextPlugin(r[o]);i.channelQueue.push(r)}});else{for(var r=new Array,o=0;o<n.length;o++){var a=n[o];a.priority>u&&r.push(a)}if(r.length>0){(r=r.sort(function(e,t){return e.priority-t.priority})).forEach(function(i){return i.initialize(e,t,n)});for(o=1;o<r.length;o++)r[o-1].setNextPlugin(r[o]);this.channelQueue.push(r)}}},e}(),l="Extensions must provide callback to initialize",u=200}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r;i=[n,t,n(22)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Sender=n.Sender}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r;i=[n,t,n(24),n(49),n(50),n(51),n(52),n(53),n(23),n(54),n(55),n(56),n(5),n(3),n(3),n(57)],void 0===(r=function(e,t,n,i,r,o,a,s,l,u,c,p,f,d,g,h){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var v=function(){function e(){this.priority=201,this._XMLHttpRequestSupported=!1}return e.prototype.pause=function(){throw new Error("Method not implemented.")},e.prototype.resume=function(){throw new Error("Method not implemented.")},e.prototype.flush=function(){try{this.triggerSend()}catch(e){this._logger.throwInternal(d.LoggingSeverity.CRITICAL,d._InternalMessageId.FlushFailed,"flush failed, telemetry will not be collected: "+f.Util.getExceptionName(e),{exception:f.Util.dump(e)})}},e.prototype.teardown=function(){throw new Error("Method not implemented.")},e.prototype.initialize=function(t,i,r){(this.identifier="AppInsightsChannelPlugin",this._logger=i.logger,this._serializer=new p.Serializer(i.logger),this._consecutiveErrors=0,this._retryAt=null,this._lastSend=0,this._config=e._getDefaultAppInsightsChannelConfig(t,this.identifier),this._sender=null,this._buffer=f.Util.canUseSessionStorage()&&this._config.enableSessionStorageBuffer?new n.SessionStorageSendBuffer(this._logger,this._config):new n.ArraySendBuffer(this._config),!this._config.isBeaconApiDisabled()&&f.Util.IsBeaconApiSupported())?this._sender=this._beaconSender:"undefined"!=typeof XMLHttpRequest&&("withCredentials"in new XMLHttpRequest?(this._sender=this._xhrSender,this._XMLHttpRequestSupported=!0):"undefined"!=typeof XDomainRequest&&(this._sender=this._xdrSender))},e.prototype.processTelemetry=function(t){try{if(this._config.disableTelemetry())return;if(!t)return void this._logger.throwInternal(d.LoggingSeverity.CRITICAL,d._InternalMessageId.CannotSendEmptyTelemetry,"Cannot send empty telemetry");if(!this._sender)return void this._logger.throwInternal(d.LoggingSeverity.CRITICAL,d._InternalMessageId.SenderNotInitialized,"Sender was not initialized");if(!e._validate(t))return void this._logger.throwInternal(d.LoggingSeverity.CRITICAL,d._InternalMessageId.TelemetryEnvelopeInvalid,"Invalid telemetry envelope");var n=this._constructEnvelope(t);if(!n)return void this._logger.throwInternal(d.LoggingSeverity.CRITICAL,d._InternalMessageId.CreateEnvelopeError,"Unable to create an AppInsights envelope");var i=this._serializer.serialize(n),r=this._buffer.getItems(),o=this._buffer.batchPayloads(r);o&&o.length+i.length>this._config.maxBatchSizeInBytes()&&this.triggerSend(),this._buffer.enqueue(i),this._setupTimer()}catch(e){this._logger.throwInternal(d.LoggingSeverity.WARNING,d._InternalMessageId.FailedAddingTelemetryToBuffer,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+f.Util.getExceptionName(e),{exception:f.Util.dump(e)})}g.CoreUtils.isNullOrUndefined(this._nextPlugin)||this._nextPlugin.processTelemetry(t)},e.prototype.setNextPlugin=function(e){this._nextPlugin=e},e.prototype._xhrReadyStateChange=function(e,t,n){if(4===e.readyState){var i=null;if(this._appId||(i=this._parseResponse(e.responseText||e.response))&&i.appId&&(this._appId=i.appId),(e.status<200||e.status>=300)&&0!==e.status)!this._config.isRetryDisabled()&&this._isRetriable(e.status)?(this._resendPayload(t),this._logger.throwInternal(d.LoggingSeverity.WARNING,d._InternalMessageId.TransmissionFailed,". Response code "+e.status+". Will retry to send "+t.length+" items.")):this._onError(t,this._formatErrorMessageXhr(e));else if(0===e.status||h.Offline.isOffline()){if(!this._config.isRetryDisabled()){this._resendPayload(t,10),this._logger.throwInternal(d.LoggingSeverity.WARNING,d._InternalMessageId.TransmissionFailed,". Offline - Response Code: "+e.status+". Offline status: "+h.Offline.isOffline()+". Will retry to send "+t.length+" items.")}}else 206===e.status?(i||(i=this._parseResponse(e.responseText||e.response)),i&&!this._config.isRetryDisabled()?this._onPartialSuccess(t,i):this._onError(t,this._formatErrorMessageXhr(e))):(this._consecutiveErrors=0,this._onSuccess(t,n))}},e.prototype.triggerSend=function(e){void 0===e&&(e=!0);try{if(this._config.disableTelemetry())this._buffer.clear();else{if(this._buffer.count()>0){var t=this._buffer.getItems();this._sender(t,e)}this._lastSend=+new Date}clearTimeout(this._timeoutHandle),this._timeoutHandle=null,this._retryAt=null}catch(e){(!f.Util.getIEVersion()||f.Util.getIEVersion()>9)&&this._logger.throwInternal(d.LoggingSeverity.CRITICAL,d._InternalMessageId.TransmissionFailed,"Telemetry transmission failed, some telemetry will be lost: "+f.Util.getExceptionName(e),{exception:f.Util.dump(e)})}},e.prototype._onError=function(e,t,n){this._logger.throwInternal(d.LoggingSeverity.WARNING,d._InternalMessageId.OnError,"Failed to send telemetry.",{message:t}),this._buffer.clearSent(e)},e.prototype._onPartialSuccess=function(e,t){for(var n=[],i=[],r=0,o=t.errors.reverse();r<o.length;r++){var a=o[r],s=e.splice(a.index,1)[0];this._isRetriable(a.statusCode)?i.push(s):n.push(s)}e.length>0&&this._onSuccess(e,t.itemsAccepted),n.length>0&&this._onError(n,this._formatErrorMessageXhr(null,["partial success",t.itemsAccepted,"of",t.itemsReceived].join(" "))),i.length>0&&(this._resendPayload(i),this._logger.throwInternal(d.LoggingSeverity.WARNING,d._InternalMessageId.TransmissionFailed,"Partial success. Delivered: "+e.length+", Failed: "+n.length+". Will retry to send "+i.length+" our of "+t.itemsReceived+" items"))},e.prototype._onSuccess=function(e,t){this._buffer.clearSent(e)},e.prototype._xdrOnLoad=function(e,t){if(!e||e.responseText+""!="200"&&""!==e.responseText){var n=this._parseResponse(e.responseText);n&&n.itemsReceived&&n.itemsReceived>n.itemsAccepted&&!this._config.isRetryDisabled()?this._onPartialSuccess(t,n):this._onError(t,this._formatErrorMessageXdr(e))}else this._consecutiveErrors=0,this._onSuccess(t,0)},e.prototype._constructEnvelope=function(e){switch(e.baseType){case f.Event.dataType:return i.EventEnvelopeCreator.EventEnvelopeCreator.Create(this._logger,e);case f.Trace.dataType:return i.TraceEnvelopeCreator.TraceEnvelopeCreator.Create(this._logger,e);case f.PageView.dataType:return i.PageViewEnvelopeCreator.PageViewEnvelopeCreator.Create(this._logger,e);case f.PageViewPerformance.dataType:return i.PageViewPerformanceEnvelopeCreator.PageViewPerformanceEnvelopeCreator.Create(this._logger,e);case f.Exception.dataType:return i.ExceptionEnvelopeCreator.ExceptionEnvelopeCreator.Create(this._logger,e);case f.Metric.dataType:return i.MetricEnvelopeCreator.MetricEnvelopeCreator.Create(this._logger,e);case f.RemoteDependencyData.dataType:return i.DependencyEnvelopeCreator.DependencyEnvelopeCreator.Create(this._logger,e);default:return i.EventEnvelopeCreator.EventEnvelopeCreator.Create(this._logger,e)}},e._getDefaultAppInsightsChannelConfig=function(e,t){var n={},i=e.extensionConfig&&e.extensionConfig[t]?e.extensionConfig[t]:{};return n.endpointUrl=function(){return e.endpointUrl||"https://dc.services.visualstudio.com/v2/track"},n.emitLineDelimitedJson=function(){return f.Util.stringToBoolOrDefault(i.emitLineDelimitedJson)},n.maxBatchInterval=function(){return isNaN(i.maxBatchInterval)?15e3:i.maxBatchInterval},n.maxBatchSizeInBytes=function(){return i.maxBatchSizeInBytes>0?i.maxBatchSizeInBytes:102400},n.disableTelemetry=function(){return f.Util.stringToBoolOrDefault(i.disableTelemetry)},n.enableSessionStorageBuffer=function(){return f.Util.stringToBoolOrDefault(i.enableSessionStorageBuffer,!0)},n.isRetryDisabled=function(){return f.Util.stringToBoolOrDefault(i.isRetryDisabled)},n.isBeaconApiDisabled=function(){return f.Util.stringToBoolOrDefault(i.isBeaconApiDisabled,!0)},n},e._validate=function(e){switch(e.baseType){case f.Event.dataType:return r.EventValidator.EventValidator.Validate(e);case f.Trace.dataType:return o.TraceValidator.TraceValidator.Validate(e);case f.Exception.dataType:return a.ExceptionValidator.ExceptionValidator.Validate(e);case f.Metric.dataType:return s.MetricValidator.MetricValidator.Validate(e);case f.PageView.dataType:return u.PageViewValidator.PageViewValidator.Validate(e);case f.PageViewPerformance.dataType:return l.PageViewPerformanceValidator.PageViewPerformanceValidator.Validate(e);case f.RemoteDependencyData.dataType:return c.RemoteDepdencyValidator.RemoteDepdencyValidator.Validate(e);default:return r.EventValidator.EventValidator.Validate(e)}},e.prototype._beaconSender=function(e,t){var n=this._config.endpointUrl(),i=this._buffer.batchPayloads(e),r=new Blob([i],{type:"text/plain;charset=UTF-8"});navigator.sendBeacon(n,r)?this._buffer.markAsSent(e):this._logger.throwInternal(d.LoggingSeverity.CRITICAL,d._InternalMessageId.TransmissionFailed,". Failed to send telemetry with Beacon API.")},e.prototype._xhrSender=function(e,t){var n=this,i=new XMLHttpRequest;i[f.DisabledPropertyName]=!0,i.open("POST",this._config.endpointUrl(),t),i.setRequestHeader("Content-type","application/json"),f.Util.isInternalApplicationInsightsEndpoint(this._config.endpointUrl())&&i.setRequestHeader(f.RequestHeaders.sdkContextHeader,f.RequestHeaders.sdkContextHeaderAppIdRequest),i.onreadystatechange=function(){return n._xhrReadyStateChange(i,e,e.length)},i.onerror=function(t){return n._onError(e,n._formatErrorMessageXhr(i),t)};var r=this._buffer.batchPayloads(e);i.send(r),this._buffer.markAsSent(e)},e.prototype._parseResponse=function(e){try{if(e&&""!==e){var t=JSON.parse(e);if(t&&t.itemsReceived&&t.itemsReceived>=t.itemsAccepted&&t.itemsReceived-t.itemsAccepted==t.errors.length)return t}}catch(t){this._logger.throwInternal(d.LoggingSeverity.CRITICAL,d._InternalMessageId.InvalidBackendResponse,"Cannot parse the response. "+f.Util.getExceptionName(t),{response:e})}return null},e.prototype._resendPayload=function(e,t){if(void 0===t&&(t=1),e&&0!==e.length){this._buffer.clearSent(e),this._consecutiveErrors++;for(var n=0,i=e;n<i.length;n++){var r=i[n];this._buffer.enqueue(r)}this._setRetryTime(t),this._setupTimer()}},e.prototype._setRetryTime=function(e){var t;if(this._consecutiveErrors<=1)t=10;else{var n=(Math.pow(2,this._consecutiveErrors)-1)/2,i=Math.floor(Math.random()*n*10)+1;i*=e,t=Math.max(Math.min(i,3600),10)}var r=Date.now()+1e3*t;this._retryAt=r},e.prototype._setupTimer=function(){var e=this;if(!this._timeoutHandle){var t=this._retryAt?Math.max(0,this._retryAt-Date.now()):0,n=Math.max(this._config.maxBatchInterval(),t);this._timeoutHandle=setTimeout(function(){e.triggerSend()},n)}},e.prototype._isRetriable=function(e){return 408==e||429==e||500==e||503==e},e.prototype._formatErrorMessageXhr=function(e,t){return e?"XMLHttpRequest,Status:"+e.status+",Response:"+e.responseText||e.response||"":t},e.prototype._xdrSender=function(e,t){var n=this,i=new XDomainRequest;i.onload=function(){return n._xdrOnLoad(i,e)},i.onerror=function(t){return n._onError(e,n._formatErrorMessageXdr(i),t)};var r=window.location.protocol;if(0!==this._config.endpointUrl().lastIndexOf(r,0))return this._logger.throwInternal(d.LoggingSeverity.WARNING,d._InternalMessageId.TransmissionFailed,". Cannot send XDomain request. The endpoint URL protocol doesn't match the hosting page protocol."),void this._buffer.clear();var o=this._config.endpointUrl().replace(/^(https?:)/,"");i.open("POST",o);var a=this._buffer.batchPayloads(e);i.send(a),this._buffer.markAsSent(e)},e.prototype._formatErrorMessageXdr=function(e,t){return e?"XDomainRequest,Response:"+e.responseText||"":t},e}();t.Sender=v}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){}return e.prototype.Validate=function(e){return!0},e.PageViewPerformanceValidator=new e,e}();t.PageViewPerformanceValidator=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r;i=[n,t,n(5),n(3)],void 0===(r=function(e,t,n,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e){this._config=e,this._buffer=[]}return e.prototype.enqueue=function(e){this._buffer.push(e)},e.prototype.count=function(){return this._buffer.length},e.prototype.clear=function(){this._buffer.length=0},e.prototype.getItems=function(){return this._buffer.slice(0)},e.prototype.batchPayloads=function(e){return e&&e.length>0?this._config.emitLineDelimitedJson()?e.join("\n"):"["+e.join(",")+"]":null},e.prototype.markAsSent=function(e){this.clear()},e.prototype.clearSent=function(e){},e}();t.ArraySendBuffer=r;var o=function(){function e(t,n){this._bufferFullMessageSent=!1,this._logger=t,this._config=n;var i=this.getBuffer(e.BUFFER_KEY),r=this.getBuffer(e.SENT_BUFFER_KEY);this._buffer=i.concat(r),this._buffer.length>e.MAX_BUFFER_SIZE&&(this._buffer.length=e.MAX_BUFFER_SIZE),this.setBuffer(e.SENT_BUFFER_KEY,[]),this.setBuffer(e.BUFFER_KEY,this._buffer)}return e.prototype.enqueue=function(t){this._buffer.length>=e.MAX_BUFFER_SIZE?this._bufferFullMessageSent||(this._logger.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.SessionStorageBufferFull,"Maximum buffer size reached: "+this._buffer.length,!0),this._bufferFullMessageSent=!0):(this._buffer.push(t),this.setBuffer(e.BUFFER_KEY,this._buffer))},e.prototype.count=function(){return this._buffer.length},e.prototype.clear=function(){this._buffer.length=0,this.setBuffer(e.BUFFER_KEY,[]),this.setBuffer(e.SENT_BUFFER_KEY,[]),this._bufferFullMessageSent=!1},e.prototype.getItems=function(){return this._buffer.slice(0)},e.prototype.batchPayloads=function(e){return e&&e.length>0?this._config.emitLineDelimitedJson()?e.join("\n"):"["+e.join(",")+"]":null},e.prototype.markAsSent=function(t){this._buffer=this.removePayloadsFromBuffer(t,this._buffer),this.setBuffer(e.BUFFER_KEY,this._buffer);var n=this.getBuffer(e.SENT_BUFFER_KEY);n instanceof Array&&t instanceof Array&&((n=n.concat(t)).length>e.MAX_BUFFER_SIZE&&(this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.SessionStorageBufferFull,"Sent buffer reached its maximum size: "+n.length,!0),n.length=e.MAX_BUFFER_SIZE),this.setBuffer(e.SENT_BUFFER_KEY,n))},e.prototype.clearSent=function(t){var n=this.getBuffer(e.SENT_BUFFER_KEY);n=this.removePayloadsFromBuffer(t,n),this.setBuffer(e.SENT_BUFFER_KEY,n)},e.prototype.removePayloadsFromBuffer=function(e,t){var n=[];for(var i in t){var r=!1;for(var o in e)if(e[o]===t[i]){r=!0;break}r||n.push(t[i])}return n},e.prototype.getBuffer=function(e){try{var t=n.Util.getSessionStorage(this._logger,e);if(t){var r=JSON.parse(t);if(r)return r}}catch(t){this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.FailedToRestoreStorageBuffer," storage key: "+e+", "+n.Util.getExceptionName(t),{exception:n.Util.dump(t)})}return[]},e.prototype.setBuffer=function(e,t){try{var r=JSON.stringify(t);n.Util.setSessionStorage(this._logger,e,r)}catch(t){n.Util.setSessionStorage(this._logger,e,JSON.stringify([])),this._logger.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.FailedToSetStorageBuffer," storage key: "+e+", "+n.Util.getExceptionName(t)+". Buffer cleared",{exception:n.Util.dump(t)})}},e.BUFFER_KEY="AI_buffer",e.SENT_BUFFER_KEY="AI_sentBuffer",e.MAX_BUFFER_SIZE=2e3,e}();t.SessionStorageSendBuffer=o}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(26),n(2),n(1),n(27),n(0)],void 0===(r=function(e,t,n,i,r,a,s){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var l=function(e){function t(t,n,o,l,u,c,p){var f=e.call(this)||this;f.aiDataContract={ver:r.FieldType.Required,metrics:r.FieldType.Required,properties:r.FieldType.Default};var d=new a.DataPoint;return d.count=l>0?l:void 0,d.max=isNaN(c)||null===c?void 0:c,d.min=isNaN(u)||null===u?void 0:u,d.name=i.DataSanitizer.sanitizeString(t,n)||s.Util.NotSpecified,d.value=o,f.metrics=[d],f.properties=i.DataSanitizer.sanitizeProperties(t,p),f}return o(t,e),t.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",t.dataType="MetricData",t}(n.MetricData);t.Metric=l}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(4)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.metrics=[],t.properties={},t}return o(t,e),t}(n.Domain);t.MetricData=i}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(28),n(1)],void 0===(r=function(e,t,n,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.aiDataContract={name:i.FieldType.Required,kind:i.FieldType.Default,value:i.FieldType.Required,count:i.FieldType.Default,min:i.FieldType.Default,max:i.FieldType.Default,stdDev:i.FieldType.Default},t}return o(t,e),t}(n.DataPoint);t.DataPoint=r}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r;i=[n,t,n(29)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(){return function(){this.kind=n.DataPointType.Measurement}}();t.DataPoint=i}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.Measurement=0]="Measurement",e[e.Aggregation=1]="Aggregation"}(t.DataPointType||(t.DataPointType={}))}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DisabledPropertyName="Microsoft_ApplicationInsights_BypassAjaxInstrumentation"}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(32),n(2),n(1),n(0)],void 0===(r=function(e,t,n,i,r,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var s=function(e){function t(t,n,o){var s=e.call(this)||this;return s.name=i.DataSanitizer.sanitizeString(t,o)||a.Util.NotSpecified,s.data=n,s.time=a.Util.toISOStringForIE8(new Date),s.aiDataContract={time:r.FieldType.Required,iKey:r.FieldType.Required,name:r.FieldType.Required,sampleRate:function(){return 100==s.sampleRate?r.FieldType.Hidden:r.FieldType.Required},tags:r.FieldType.Required,data:r.FieldType.Required},s}return o(t,e),t}(n.Envelope);t.Envelope=s}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){return function(){this.ver=1,this.sampleRate=100,this.tags={}}}();t.Envelope=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(15),n(2),n(1),n(0)],void 0===(r=function(e,t,n,i,r,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var s=function(e){function t(t,n,o,s){var l=e.call(this)||this;return l.aiDataContract={ver:r.FieldType.Required,name:r.FieldType.Required,properties:r.FieldType.Default,measurements:r.FieldType.Default},l.name=i.DataSanitizer.sanitizeString(t,n)||a.Util.NotSpecified,l.properties=i.DataSanitizer.sanitizeProperties(t,o),l.measurements=i.DataSanitizer.sanitizeMeasurements(t,s),l}return o(t,e),t.envelopeType="Microsoft.ApplicationInsights.{0}.Event",t.dataType="EventData",t}(n.EventData);t.Event=s}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(35),n(36),n(37),n(2),n(1),n(0)],void 0===(r=function(e,t,n,i,r,a,s,l){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=function(e){function t(t,n,i,r,o){var l=e.call(this)||this;return l.aiDataContract={ver:s.FieldType.Required,exceptions:s.FieldType.Required,severityLevel:s.FieldType.Default,properties:s.FieldType.Default,measurements:s.FieldType.Default},l.properties=a.DataSanitizer.sanitizeProperties(t,i),l.measurements=a.DataSanitizer.sanitizeMeasurements(t,r),l.exceptions=[new c(t,n)],o&&(l.severityLevel=o),l}return o(t,e),t.CreateSimpleException=function(e,t,n,i,r,o){return{exceptions:[{hasFullStack:!0,message:e,stack:r,typeName:t}]}},t.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",t.dataType="ExceptionData",t}(i.ExceptionData);t.Exception=u;var c=function(e){function t(t,n){var i=e.call(this)||this;i.aiDataContract={id:s.FieldType.Default,outerId:s.FieldType.Default,typeName:s.FieldType.Required,message:s.FieldType.Required,hasFullStack:s.FieldType.Default,stack:s.FieldType.Default,parsedStack:s.FieldType.Array},i.typeName=a.DataSanitizer.sanitizeString(t,n.name)||l.Util.NotSpecified,i.message=a.DataSanitizer.sanitizeMessage(t,n.message)||l.Util.NotSpecified;var r=n.stack;return i.parsedStack=i.parseStack(r),i.stack=a.DataSanitizer.sanitizeException(t,r),i.hasFullStack=l.Util.isArray(i.parsedStack)&&i.parsedStack.length>0,i}return o(t,e),t.prototype.parseStack=function(e){var t=void 0;if("string"==typeof e){var n=e.split("\n");t=[];for(var i=0,r=0,o=0;o<=n.length;o++){var a=n[o];if(p.regex.test(a)){var s=new p(n[o],i++);r+=s.sizeInBytes,t.push(s)}}if(r>32768)for(var l=0,u=t.length-1,c=0,f=l,d=u;l<u;){if((c+=t[l].sizeInBytes+t[u].sizeInBytes)>32768){var g=d-f+1;t.splice(f,g);break}f=l,d=u,l++,u--}}return t},t}(r.ExceptionDetails),p=function(e){function t(n,i){var r=e.call(this)||this;r.sizeInBytes=0,r.aiDataContract={level:s.FieldType.Required,method:s.FieldType.Required,assembly:s.FieldType.Default,fileName:s.FieldType.Default,line:s.FieldType.Default},r.level=i,r.method="<no_method>",r.assembly=l.Util.trim(n);var o=n.match(t.regex);return o&&o.length>=5&&(r.method=l.Util.trim(o[2])||r.method,r.fileName=l.Util.trim(o[4]),r.line=parseInt(o[5])||0),r.sizeInBytes+=r.method.length,r.sizeInBytes+=r.fileName.length,r.sizeInBytes+=r.assembly.length,r.sizeInBytes+=t.baseSize,r.sizeInBytes+=r.level.toString().length,r.sizeInBytes+=r.line.toString().length,r}return o(t,e),t.regex=/^([\s]+at)?(.*?)(\@|\s\(|\s)([^\(\@\n]+):([0-9]+):([0-9]+)(\)?)$/,t.baseSize=58,t}(n.StackFrame);t._StackFrame=p}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){return function(){}}();t.StackFrame=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(4)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.exceptions=[],t.properties={},t.measurements={},t}return o(t,e),t}(n.Domain);t.ExceptionData=i}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){return function(){this.hasFullStack=!0,this.parsedStack=[]}}();t.ExceptionDetails=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(7),n(2),n(1),n(0)],void 0===(r=function(e,t,n,i,r,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var s=function(e){function t(t,n,o,s,l,u,c){var p=e.call(this)||this;return p.aiDataContract={ver:r.FieldType.Required,name:r.FieldType.Default,url:r.FieldType.Default,duration:r.FieldType.Default,properties:r.FieldType.Default,measurements:r.FieldType.Default,id:r.FieldType.Default},p.id=i.DataSanitizer.sanitizeId(t,c),p.url=i.DataSanitizer.sanitizeUrl(t,o),p.name=i.DataSanitizer.sanitizeString(t,n)||a.Util.NotSpecified,isNaN(s)||(p.duration=a.Util.msToTimeSpan(s)),p.properties=i.DataSanitizer.sanitizeProperties(t,l),p.measurements=i.DataSanitizer.sanitizeMeasurements(t,u),p}return o(t,e),t.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",t.dataType="PageviewData",t}(n.PageViewData);t.PageView=s}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(2),n(1),n(0),n(0),n(40)],void 0===(r=function(e,t,n,i,r,a,s){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var l=function(e){function t(t,o,s,l,u,c,p,f,d,g){var h=e.call(this)||this;h.aiDataContract={id:i.FieldType.Required,ver:i.FieldType.Required,name:i.FieldType.Default,resultCode:i.FieldType.Default,duration:i.FieldType.Default,success:i.FieldType.Default,data:i.FieldType.Default,target:i.FieldType.Default,type:i.FieldType.Default,properties:i.FieldType.Default,measurements:i.FieldType.Default,kind:i.FieldType.Default,value:i.FieldType.Default,count:i.FieldType.Default,min:i.FieldType.Default,max:i.FieldType.Default,stdDev:i.FieldType.Default,dependencyKind:i.FieldType.Default,dependencySource:i.FieldType.Default,commandName:i.FieldType.Default,dependencyTypeName:i.FieldType.Default},h.id=o,h.duration=r.Util.msToTimeSpan(u),h.success=c,h.resultCode=p+"",h.type="Ajax",h.data=n.DataSanitizer.sanitizeUrl(t,l);var v=a.AjaxHelper.ParseDependencyPath(t,s,f,l);return h.target=v.target,h.name=v.name,h.properties=n.DataSanitizer.sanitizeProperties(t,d),h.measurements=n.DataSanitizer.sanitizeMeasurements(t,g),h}return o(t,e),t.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",t.dataType="RemoteDependencyData",t}(s.RemoteDependencyData);t.RemoteDependencyData=l}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(4)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.success=!0,t.properties={},t.measurements={},t}return o(t,e),t}(n.Domain);t.RemoteDependencyData=i}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(42),n(2),n(1),n(0)],void 0===(r=function(e,t,n,i,r,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var s=function(e){function t(t,n,o,s){var l=e.call(this)||this;return l.aiDataContract={ver:r.FieldType.Required,message:r.FieldType.Required,severityLevel:r.FieldType.Default,properties:r.FieldType.Default},n=n||a.Util.NotSpecified,l.message=i.DataSanitizer.sanitizeMessage(t,n),l.properties=i.DataSanitizer.sanitizeProperties(t,o),s&&(l.severityLevel=s),l}return o(t,e),t.envelopeType="Microsoft.ApplicationInsights.{0}.Message",t.dataType="MessageData",t}(n.MessageData);t.Trace=s}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(4)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.properties={},t}return o(t,e),t}(n.Domain);t.MessageData=i}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(44),n(1),n(2),n(0),n(3)],void 0===(r=function(e,t,n,i,r,a,s){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var l=function(e){function t(n,o,l,u,c,p){var f=e.call(this)||this;f.aiDataContract={ver:i.FieldType.Required,name:i.FieldType.Default,url:i.FieldType.Default,duration:i.FieldType.Default,perfTotal:i.FieldType.Default,networkConnect:i.FieldType.Default,sentRequest:i.FieldType.Default,receivedResponse:i.FieldType.Default,domProcessing:i.FieldType.Default,properties:i.FieldType.Default,measurements:i.FieldType.Default},f.isValid=!1;var d=t.getPerformanceTiming();if(d){var g=t.getDuration(d.navigationStart,d.loadEventEnd),h=t.getDuration(d.navigationStart,d.connectEnd),v=t.getDuration(d.requestStart,d.responseStart),y=t.getDuration(d.responseStart,d.responseEnd),_=t.getDuration(d.responseEnd,d.loadEventEnd);0==g?n.throwInternal(s.LoggingSeverity.WARNING,s._InternalMessageId.ErrorPVCalc,"error calculating page view performance.",{total:g,network:h,request:v,response:y,dom:_}):t.shouldCollectDuration(g,h,v,y,_)?g<Math.floor(h)+Math.floor(v)+Math.floor(y)+Math.floor(_)?n.throwInternal(s.LoggingSeverity.WARNING,s._InternalMessageId.ClientPerformanceMathError,"client performance math error.",{total:g,network:h,request:v,response:y,dom:_}):(f.durationMs=g,f.perfTotal=f.duration=a.Util.msToTimeSpan(g),f.networkConnect=a.Util.msToTimeSpan(h),f.sentRequest=a.Util.msToTimeSpan(v),f.receivedResponse=a.Util.msToTimeSpan(y),f.domProcessing=a.Util.msToTimeSpan(_),f.isValid=!0):n.throwInternal(s.LoggingSeverity.WARNING,s._InternalMessageId.InvalidDurationValue,"Invalid page load duration value. Browser perf data won't be sent.",{total:g,network:h,request:v,response:y,dom:_})}return f.url=r.DataSanitizer.sanitizeUrl(n,l),f.name=r.DataSanitizer.sanitizeString(n,o)||a.Util.NotSpecified,f.properties=r.DataSanitizer.sanitizeProperties(n,c),f.measurements=r.DataSanitizer.sanitizeMeasurements(n,p),f}return o(t,e),t.prototype.getIsValid=function(){return this.isValid},t.prototype.getDurationMs=function(){return this.durationMs},t.getPerformanceTiming=function(){return t.isPerformanceTimingSupported()?window.performance.timing:null},t.isPerformanceTimingSupported=function(){return"undefined"!=typeof window&&window.performance&&window.performance.timing},t.isPerformanceTimingDataReady=function(){var e=window.performance.timing;return e.domainLookupStart>0&&e.navigationStart>0&&e.responseStart>0&&e.requestStart>0&&e.loadEventEnd>0&&e.responseEnd>0&&e.connectEnd>0&&e.domLoading>0},t.getDuration=function(e,t){var n=void 0;return isNaN(e)||isNaN(t)||(n=Math.max(t-e,0)),n},t.shouldCollectDuration=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var i=["googlebot","adsbot-google","apis-google","mediapartners-google"],r=navigator.userAgent,o=!1;if(r)for(var a=0;a<i.length;a++)o=o||-1!==r.toLowerCase().indexOf(i[a]);if(o)return!1;for(var s=0;s<e.length;s++)if(e[s]>=t.MAX_DURATION_ALLOWED)return!1;return!0},t.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",t.dataType="PageviewPerformanceData",t.MAX_DURATION_ALLOWED=36e5,t}(n.PageViewPerfData);t.PageViewPerformance=l}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(7)],void 0===(r=function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.properties={},t.measurements={},t}return o(t,e),t}(n.PageViewData);t.PageViewPerfData=i}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(13),n(1)],void 0===(r=function(e,t,n,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(e){function t(t,n){var r=e.call(this)||this;return r.aiDataContract={baseType:i.FieldType.Required,baseData:i.FieldType.Required},r.baseType=t,r.baseData=n,r}return o(t,e),t}(n.Data);t.Data=r}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.Verbose=0]="Verbose",e[e.Information=1]="Information",e[e.Warning=2]="Warning",e[e.Error=3]="Error",e[e.Critical=4]="Critical"}(t.SeverityLevel||(t.SeverityLevel={}))}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){return function(){this.applicationVersion="ai.application.ver",this.applicationBuild="ai.application.build",this.applicationTypeId="ai.application.typeId",this.applicationId="ai.application.applicationId",this.applicationLayer="ai.application.layer",this.deviceId="ai.device.id",this.deviceIp="ai.device.ip",this.deviceLanguage="ai.device.language",this.deviceLocale="ai.device.locale",this.deviceModel="ai.device.model",this.deviceFriendlyName="ai.device.friendlyName",this.deviceNetwork="ai.device.network",this.deviceNetworkName="ai.device.networkName",this.deviceOEMName="ai.device.oemName",this.deviceOS="ai.device.os",this.deviceOSVersion="ai.device.osVersion",this.deviceRoleInstance="ai.device.roleInstance",this.deviceRoleName="ai.device.roleName",this.deviceScreenResolution="ai.device.screenResolution",this.deviceType="ai.device.type",this.deviceMachineName="ai.device.machineName",this.deviceVMName="ai.device.vmName",this.deviceBrowser="ai.device.browser",this.deviceBrowserVersion="ai.device.browserVersion",this.locationIp="ai.location.ip",this.locationCountry="ai.location.country",this.locationProvince="ai.location.province",this.locationCity="ai.location.city",this.operationId="ai.operation.id",this.operationName="ai.operation.name",this.operationParentId="ai.operation.parentId",this.operationRootId="ai.operation.rootId",this.operationSyntheticSource="ai.operation.syntheticSource",this.operationCorrelationVector="ai.operation.correlationVector",this.sessionId="ai.session.id",this.sessionIsFirst="ai.session.isFirst",this.sessionIsNew="ai.session.isNew",this.userAccountAcquisitionDate="ai.user.accountAcquisitionDate",this.userAccountId="ai.user.accountId",this.userAgent="ai.user.userAgent",this.userId="ai.user.id",this.userStoreRegion="ai.user.storeRegion",this.userAuthUserId="ai.user.authUserId",this.userAnonymousUserAcquisitionDate="ai.user.anonUserAcquisitionDate",this.userAuthenticatedUserAcquisitionDate="ai.user.authUserAcquisitionDate",this.cloudName="ai.cloud.name",this.cloudRole="ai.cloud.role",this.cloudRoleVer="ai.cloud.roleVer",this.cloudRoleInstance="ai.cloud.roleInstance",this.cloudEnvironment="ai.cloud.environment",this.cloudLocation="ai.cloud.location",this.cloudDeploymentUnit="ai.cloud.deploymentUnit",this.internalSdkVersion="ai.internal.sdkVersion",this.internalAgentVersion="ai.internal.agentVersion",this.internalNodeName="ai.internal.nodeName"}}();t.ContextTagKeys=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r;i=[n,t,n(0),n(2),n(3)],void 0===(r=function(e,t,n,i,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=function(){function e(){}return e.create=function(e,t,o,a,s,l){if(o=i.DataSanitizer.sanitizeString(a,o)||n.Util.NotSpecified,r.CoreUtils.isNullOrUndefined(e)||r.CoreUtils.isNullOrUndefined(t)||r.CoreUtils.isNullOrUndefined(o))throw Error("Input doesn't contain all required fields");var u={name:o,timestamp:new Date,instrumentationKey:"",ctx:l||{},tags:[],data:{},baseType:t,baseData:e};if(!r.CoreUtils.isNullOrUndefined(s))for(var c in s)s.hasOwnProperty(c)&&(u.data[c]=s[c]);return u},e}();t.TelemetryItemCreator=o}.apply(t,i))||(e.exports=r)},function(e,t,n){var i,r,o=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}();i=[n,t,n(5),n(3)],void 0===(r=function(e,t,n,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ContextTagKeys=["ai.application.ver","ai.application.build","ai.application.typeId","ai.application.applicationId","ai.application.layer","ai.device.id","ai.device.ip","ai.device.language","ai.device.locale","ai.device.model","ai.device.friendlyName","ai.device.network","ai.device.networkName","ai.device.oemName","ai.device.os","ai.device.osVersion","ai.device.roleInstance","ai.device.roleName","ai.device.screenResolution","ai.device.type","ai.device.machineName","ai.device.vmName","ai.device.browser","ai.device.browserVersion","ai.location.ip","ai.location.country","ai.location.province","ai.location.city","ai.operation.id","ai.operation.name","ai.operation.parentId","ai.operation.rootId","ai.operation.syntheticSource","ai.operation.correlationVector","ai.session.id","ai.session.isFirst","ai.session.isNew","ai.user.accountAcquisitionDate","ai.user.accountId","ai.user.userAgent","ai.user.id","ai.user.storeRegion","ai.user.authUserId","ai.user.anonUserAcquisitionDate","ai.user.authUserAcquisitionDate","ai.cloud.name","ai.cloud.role","ai.cloud.roleVer","ai.cloud.roleInstance","ai.cloud.environment","ai.cloud.location","ai.cloud.deploymentUnit","ai.internal.sdkVersion","ai.internal.agentVersion","ai.internal.nodeName"];var r=function(){function e(){}return e.extractProperties=function(e){var t=null;for(var n in e)if(e.hasOwnProperty(n)){var i=e[n];"number"!=typeof i&&(t||(t={}),t[n]=i)}return t},e.extractPropsAndMeasurements=function(e,t,n){if(!i.CoreUtils.isNullOrUndefined(e))for(var r in e)if(e.hasOwnProperty(r)){var o=e[r];"number"==typeof o?n[r]=o:t[r]=o}},e.createEnvelope=function(e,i,r,o){var a=new n.Envelope(e,o,i);a.iKey=r.instrumentationKey;var s=r.instrumentationKey.replace(/-/g,"");for(var l in a.name=a.name.replace("{0}",s),r.ctx)r.ctx.hasOwnProperty(l)&&t.ContextTagKeys.indexOf(l)>=0&&(a.tags[l]=r.ctx[l]);return r.tags.forEach(function(e){for(var n in e)e.hasOwnProperty(n)&&t.ContextTagKeys.indexOf(n)>=0&&(a.tags[n]=e[n])}),a},e}();t.EnvelopeCreator=r;var a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.Create=function(e,t){this._logger=e,i.CoreUtils.isNullOrUndefined(t.baseData)&&this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.");var o={},a={};r.extractPropsAndMeasurements(t.data,a,o);var s=t.baseData;if(i.CoreUtils.isNullOrUndefined(s))return e.warnToConsole("Invalid input for dependency data"),null;var l=s.id,u=s.absoluteUrl,c=s.commandName,p=s.duration,f=s.success,d=s.resultCode,g=s.method,h=new n.RemoteDependencyData(e,l,u,c,p,f,d,g,a,o),v=new n.Data(n.RemoteDependencyData.dataType,h);return r.createEnvelope(e,n.RemoteDependencyData.envelopeType,t,v)},t.DependencyEnvelopeCreator=new t,t}(r);t.DependencyEnvelopeCreator=a;var s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.Create=function(e,t){this._logger=e,i.CoreUtils.isNullOrUndefined(t.baseData)&&this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.");var o={},a={};t.baseType!==n.Event.dataType&&r.extractPropsAndMeasurements(t.baseData,o,a),r.extractPropsAndMeasurements(t.data,o,a);var s=t.baseData.name,l=new n.Event(e,s,o,a),u=new n.Data(n.Event.dataType,l);return r.createEnvelope(e,n.Event.envelopeType,t,u)},t.EventEnvelopeCreator=new t,t}(r);t.EventEnvelopeCreator=s;var l=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.Create=function(e,t){this._logger=e,i.CoreUtils.isNullOrUndefined(t.baseData)&&this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.");var o={},a={};r.extractPropsAndMeasurements(t.data,o,a);var s=t.baseData.error,l=t.baseData.severityLevel,u=new n.Exception(e,s,o,a,l),c=new n.Data(n.Exception.dataType,u);return r.createEnvelope(e,n.Exception.envelopeType,t,c)},t.ExceptionEnvelopeCreator=new t,t}(r);t.ExceptionEnvelopeCreator=l;var u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.Create=function(e,t){this._logger=e,i.CoreUtils.isNullOrUndefined(t.baseData)&&this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.");var o=r.extractProperties(t.data),a=t.baseData.name,s=t.baseData.average,l=t.baseData.sampleCount,u=t.baseData.min,c=t.baseData.max,p=new n.Metric(e,a,s,l,u,c,o),f=new n.Data(n.Metric.dataType,p);return r.createEnvelope(e,n.Metric.envelopeType,t,f)},t.MetricEnvelopeCreator=new t,t}(r);t.MetricEnvelopeCreator=u;var c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.Create=function(e,t){this._logger=e,i.CoreUtils.isNullOrUndefined(t.baseData)&&this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.");var o=void 0;i.CoreUtils.isNullOrUndefined(t.data)||i.CoreUtils.isNullOrUndefined(t.data.duration)||(o=t.data.duration,delete t.data.duration);var a={},s={};r.extractPropsAndMeasurements(t.data,a,s);var l=t.baseData.name,u=t.baseData.uri;if(i.CoreUtils.isNullOrUndefined(t.baseData.refUri)||(a.refUri=t.baseData.refUri),i.CoreUtils.isNullOrUndefined(t.baseData.pageType)||(a.pageType=t.baseData.pageType),i.CoreUtils.isNullOrUndefined(t.baseData.isLoggedIn)||(a.isLoggedIn=t.baseData.isLoggedIn),!i.CoreUtils.isNullOrUndefined(t.baseData.pageTags)){var c=t.baseData.pageTags;for(var p in c)c.hasOwnProperty(p)&&(a[p]=c[p])}var f=new n.PageView(e,l,u,o,a,s),d=new n.Data(n.PageView.dataType,f);return r.createEnvelope(e,n.PageView.envelopeType,t,d)},t.PageViewEnvelopeCreator=new t,t}(r);t.PageViewEnvelopeCreator=c;var p=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.Create=function(e,t){this._logger=e,i.CoreUtils.isNullOrUndefined(t.baseData)&&this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.");var o={},a={};r.extractPropsAndMeasurements(t.data,o,a);var s=t.baseData.name,l=t.baseData.uri,u=t.baseData.duration,c=new n.PageViewPerformance(e,s,l,u,o,a),p=new n.Data(n.PageViewPerformance.dataType,c);return r.createEnvelope(e,n.PageViewPerformance.envelopeType,t,p)},t.PageViewPerformanceEnvelopeCreator=new t,t}(r);t.PageViewPerformanceEnvelopeCreator=p;var f=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.Create=function(e,t){this._logger=e,i.CoreUtils.isNullOrUndefined(t.baseData)&&this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.");var o=t.baseData.message,a=t.baseData.severityLevel,s=r.extractProperties(t.data),l=new n.Trace(e,o,s,a),u=new n.Data(n.Trace.dataType,l);return r.createEnvelope(e,n.Trace.envelopeType,t,u)},t.TraceEnvelopeCreator=new t,t}(r);t.TraceEnvelopeCreator=f}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){}return e.prototype.Validate=function(e){return!0},e.EventValidator=new e,e}();t.EventValidator=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){}return e.prototype.Validate=function(e){return!0},e.TraceValidator=new e,e}();t.TraceValidator=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){}return e.prototype.Validate=function(e){return!0},e._validateExceptions=function(e){return!0},e.ExceptionValidator=new e,e}();t.ExceptionValidator=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){}return e.prototype.Validate=function(e){return!0},e.MetricValidator=new e,e}();t.MetricValidator=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){}return e.prototype.Validate=function(e){return!0},e.PageViewValidator=new e,e}();t.PageViewValidator=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){}return e.prototype.Validate=function(e){return!0},e.RemoteDepdencyValidator=new e,e}();t.RemoteDepdencyValidator=n}.apply(t,[n,t]))||(e.exports=i)},function(e,t,n){var i,r;i=[n,t,n(5),n(3)],void 0===(r=function(e,t,n,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e){this._logger=e}return e.prototype.serialize=function(e){var t=this._serializeObject(e,"root");return JSON.stringify(t)},e.prototype._serializeObject=function(e,t){var r={};if(!e)return this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.CannotSerializeObject,"cannot serialize object because it is null or undefined",{name:t},!0),r;if(e.__aiCircularRefCheck)return this._logger.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.CircularReferenceDetected,"Circular reference detected while serializing object",{name:t},!0),r;if(!e.aiDataContract){if("measurements"===t)r=this._serializeStringMap(e,"number",t);else if("properties"===t)r=this._serializeStringMap(e,"string",t);else if("tags"===t)r=this._serializeStringMap(e,"string",t);else if(n.Util.isArray(e))r=this._serializeArray(e,t);else{this._logger.throwInternal(i.LoggingSeverity.WARNING,i._InternalMessageId.CannotSerializeObjectNonSerializable,"Attempting to serialize an object which does not implement ISerializable",{name:t},!0);try{JSON.stringify(e),r=e}catch(e){this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.CannotSerializeObject,e&&"function"==typeof e.toString?e.toString():"Error serializing object",null,!0)}}return r}for(var o in e.__aiCircularRefCheck=!0,e.aiDataContract){var a,s=e.aiDataContract[o],l="function"==typeof s?s()&n.FieldType.Required:s&n.FieldType.Required,u="function"==typeof s?s()&n.FieldType.Hidden:s&n.FieldType.Hidden,c=s&n.FieldType.Array,p=void 0!==e[o],f="object"==typeof e[o]&&null!==e[o];if(!l||p||c){if(!u)void 0!==(a=f?c?this._serializeArray(e[o],o):this._serializeObject(e[o],o):e[o])&&(r[o]=a)}else this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.MissingRequiredFieldSpecification,"Missing required field specification. The field is required but not present on source",{field:o,name:t})}return delete e.__aiCircularRefCheck,r},e.prototype._serializeArray=function(e,t){var r=void 0;if(e)if(n.Util.isArray(e)){r=[];for(var o=0;o<e.length;o++){var a=e[o],s=this._serializeObject(a,t+"["+o+"]");r.push(s)}}else this._logger.throwInternal(i.LoggingSeverity.CRITICAL,i._InternalMessageId.ItemNotInArray,"This field was specified as an array in the contract but the item is not an array.\r\n",{name:t},!0);return r},e.prototype._serializeStringMap=function(e,t,n){var r=void 0;if(e)for(var o in r={},e){var a=e[o];if("string"===t)void 0===a?r[o]="undefined":null===a?r[o]="null":a.toString?r[o]=a.toString():r[o]="invalid field: toString() is not defined.";else if("number"===t)if(void 0===a)r[o]="undefined";else if(null===a)r[o]="null";else{var s=parseFloat(a);isNaN(s)?r[o]="NaN":r[o]=s}else r[o]="invalid field: "+n+" is of unknown type.",this._logger.throwInternal(i.LoggingSeverity.CRITICAL,r[o],null,!0)}return r},e}();t.Serializer=r}.apply(t,i))||(e.exports=r)},function(e,t,n){var i;void 0===(i=function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){this._onlineStatus=!0,window&&window.addEventListener?(window.addEventListener("online",this._setOnline.bind(this),!1),window.addEventListener("offline",this._setOffline.bind(this),!1),this.isListening=!0):document&&document.body?(document.body.ononline=this._setOnline.bind(this),document.body.onoffline=this._setOffline.bind(this),this.isListening=!0):document?(document.ononline=this._setOnline.bind(this),document.onoffline=this._setOffline.bind(this),this.isListening=!0):this.isListening=!1}return e.prototype._setOnline=function(){this._onlineStatus=!0},e.prototype._setOffline=function(){this._onlineStatus=!1},e.prototype.isOnline=function(){return this.isListening?this._onlineStatus:!navigator||navigator.onLine},e.prototype.isOffline=function(){return!this.isOnline()},e.Offline=new e,e}();t.OfflineListener=n,t.Offline=n.Offline}.apply(t,[n,t]))||(e.exports=i)}])});
//# sourceMappingURL=aisdklite.0.0.3.min.js.map