easyproctor 0.0.83 → 0.0.85

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,7 @@
1
- "use strict";(()=>{var NC=Object.create;var Tp=Object.defineProperty;var PC=Object.getOwnPropertyDescriptor;var CC=Object.getOwnPropertyNames;var RC=Object.getPrototypeOf,EC=Object.prototype.hasOwnProperty;var as=(r,e)=>()=>(e||r((e={exports:{}}).exports,e),e.exports),TC=(r,e)=>{for(var t in e)Tp(r,t,{get:e[t],enumerable:!0})},wC=(r,e,t,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of CC(e))!EC.call(r,n)&&n!==t&&Tp(r,n,{get:()=>e[n],enumerable:!(a=PC(e,n))||a.enumerable});return r};var ns=(r,e,t)=>(t=r!=null?NC(RC(r)):{},wC(e||!r||!r.__esModule?Tp(t,"default",{value:r,enumerable:!0}):t,r));var Bg=as((Ip,Mp)=>{"use strict";(function(r,e){typeof Ip=="object"&&typeof Mp<"u"?Mp.exports=e():typeof define=="function"&&define.amd?define(e):r.MicRecorder=e()})(Ip,function(){function r(z){return new Int8Array(z)}function e(z){return new Int16Array(z)}function t(z){return new Int32Array(z)}function a(z){return new Float32Array(z)}function n(z){return new Float64Array(z)}function i(z){if(z.length==1)return a(z[0]);var te=z[0];z=z.slice(1);for(var ce=[],re=0;re<te;re++)ce.push(i(z));return ce}function s(z){if(z.length==1)return t(z[0]);var te=z[0];z=z.slice(1);for(var ce=[],re=0;re<te;re++)ce.push(s(z));return ce}function o(z){if(z.length==1)return e(z[0]);var te=z[0];z=z.slice(1);for(var ce=[],re=0;re<te;re++)ce.push(o(z));return ce}function l(z){if(z.length==1)return new Array(z[0]);var te=z[0];z=z.slice(1);for(var ce=[],re=0;re<te;re++)ce.push(l(z));return ce}var c={};c.fill=function(z,te,ce,re){if(arguments.length==2)for(var Ee=0;Ee<z.length;Ee++)z[Ee]=arguments[1];else for(var Ee=te;Ee<ce;Ee++)z[Ee]=re};var p={};p.arraycopy=function(z,te,ce,re,Ee){for(var ie=te+Ee;te<ie;)ce[re++]=z[te++]};var M={};M.SQRT2=1.4142135623730951,M.FAST_LOG10=function(z){return Math.log10(z)},M.FAST_LOG10_X=function(z,te){return Math.log10(z)*te};function S(z){this.ordinal=z}S.short_block_allowed=new S(0),S.short_block_coupled=new S(1),S.short_block_dispensed=new S(2),S.short_block_forced=new S(3);var O={};O.MAX_VALUE=34028235e31;function E(z){this.ordinal=z}E.vbr_off=new E(0),E.vbr_mt=new E(1),E.vbr_rh=new E(2),E.vbr_abr=new E(3),E.vbr_mtrh=new E(4),E.vbr_default=E.vbr_mtrh;var q=function(z){},C={System:p,VbrMode:E,Float:O,ShortBlock:S,Util:M,Arrays:c,new_array_n:l,new_byte:r,new_double:n,new_float:a,new_float_n:i,new_int:t,new_int_n:s,new_short:e,new_short_n:o,assert:q},W=C.System,ae=C.Util,Ce=C.Arrays,et=C.new_float;function gt(){var z=[-.1482523854003001,32.308141959636465,296.40344946382766,883.1344870032432,11113.947376231741,1057.2713659324597,305.7402417275812,30.825928907280012,3.8533188138216365,59.42900443849514,709.5899960123345,5281.91112291017,-5829.66483675846,-817.6293103748613,-76.91656988279972,-4.594269939176596,.9063471690191471,.1960342806591213,-.15466694054279598,34.324387823855965,301.8067566458425,817.599602898885,11573.795901679885,1181.2520595540152,321.59731579894424,31.232021761053772,3.7107095756221318,53.650946155329365,684.167428119626,5224.56624370173,-6366.391851890084,-908.9766368219582,-89.83068876699639,-5.411397422890401,.8206787908286602,.3901806440322567,-.16070888947830023,36.147034243915876,304.11815768187864,732.7429163887613,11989.60988270091,1300.012278487897,335.28490093152146,31.48816102859945,3.373875931311736,47.232241542899175,652.7371796173471,5132.414255594984,-6909.087078780055,-1001.9990371107289,-103.62185754286375,-6.104916304710272,.7416505462720353,.5805693545089249,-.16636367662261495,37.751650073343995,303.01103387567713,627.9747488785183,12358.763425278165,1412.2779918482834,346.7496836825721,31.598286663170416,3.1598635433980946,40.57878626349686,616.1671130880391,5007.833007176154,-7454.040671756168,-1095.7960341867115,-118.24411666465777,-6.818469345853504,.6681786379192989,.7653668647301797,-.1716176790982088,39.11551877123304,298.3413246578966,503.5259106886539,12679.589408408976,1516.5821921214542,355.9850766329023,31.395241710249053,2.9164211881972335,33.79716964664243,574.8943997801362,4853.234992253242,-7997.57021486075,-1189.7624067269965,-133.6444792601766,-7.7202770609839915,.5993769336819237,.9427934736519954,-.17645823955292173,40.21879108166477,289.9982036694474,359.3226160751053,12950.259102786438,1612.1013903507662,362.85067106591504,31.045922092242872,2.822222032597987,26.988862316190684,529.8996541764288,4671.371946949588,-8535.899136645805,-1282.5898586244496,-149.58553632943463,-8.643494270763135,.5345111359507916,1.111140466039205,-.36174739330527045,41.04429910497807,277.5463268268618,195.6386023135583,13169.43812144731,1697.6433561479398,367.40983966190305,30.557037410382826,2.531473372857427,20.070154905927314,481.50208566532336,4464.970341588308,-9065.36882077239,-1373.62841526722,-166.1660487028118,-9.58289321133207,.4729647758913199,1.268786568327291,-.36970682634889585,41.393213350082036,261.2935935556502,12.935476055240873,13336.131683328815,1772.508612059496,369.76534388639965,29.751323653701338,2.4023193045459172,13.304795348228817,430.5615775526625,4237.0568611071185,-9581.931701634761,-1461.6913552409758,-183.12733958476446,-10.718010163869403,.41421356237309503,1.414213562373095,-.37677560326535325,41.619486213528496,241.05423794991074,-187.94665032361226,13450.063605744153,1836.153896465782,369.4908799925761,29.001847876923147,2.0714759319987186,6.779591200894186,377.7767837205709,3990.386575512536,-10081.709459700915,-1545.947424837898,-200.3762958015653,-11.864482073055006,.3578057213145241,1.546020906725474,-.3829366947518991,41.1516456456653,216.47684307105183,-406.1569483347166,13511.136535077321,1887.8076599260432,367.3025214564151,28.136213436723654,1.913880671464418,.3829366947518991,323.85365704338597,3728.1472257487526,-10561.233882199509,-1625.2025997821418,-217.62525175416,-13.015432208941645,.3033466836073424,1.66293922460509,-.5822628872992417,40.35639251440489,188.20071124269245,-640.2706748618148,13519.21490106562,1927.6022433578062,362.8197642637487,26.968821921868447,1.7463817695935329,-5.62650678237171,269.3016715297017,3453.386536448852,-11016.145278780888,-1698.6569643425091,-234.7658734267683,-14.16351421663124,.2504869601913055,1.76384252869671,-.5887180101749253,39.23429103868072,155.76096234403798,-889.2492977967378,13475.470561874661,1955.0535223723712,356.4450994756727,25.894952980042156,1.5695032905781554,-11.181939564328772,214.80884394039484,3169.1640829158237,-11443.321309975563,-1765.1588461316153,-251.68908574481912,-15.49755935939164,.198912367379658,1.847759065022573,-.7912582233652842,37.39369355329111,119.699486012458,-1151.0956593239027,13380.446257078214,1970.3952110853447,348.01959814116185,24.731487364283044,1.3850130831637748,-16.421408865300393,161.05030052864092,2878.3322807850063,-11838.991423510031,-1823.985884688674,-268.2854986386903,-16.81724543849939,.1483359875383474,1.913880671464418,-.7960642926861912,35.2322109610459,80.01928065061526,-1424.0212633405113,13235.794061869668,1973.804052543835,337.9908651258184,23.289159354463873,1.3934255946442087,-21.099669467133474,108.48348407242611,2583.700758091299,-12199.726194855148,-1874.2780658979746,-284.2467154529415,-18.11369784385905,.09849140335716425,1.961570560806461,-.998795456205172,32.56307803611191,36.958364584370486,-1706.075448829146,13043.287458812016,1965.3831106103316,326.43182772364605,22.175018750622293,1.198638339011324,-25.371248002043963,57.53505923036915,2288.41886619975,-12522.674544337233,-1914.8400385312243,-299.26241273417224,-19.37805630698734,.04912684976946725,1.990369453344394,.035780907*ae.SQRT2*.5/2384e-9,.017876148*ae.SQRT2*.5/2384e-9,.003134727*ae.SQRT2*.5/2384e-9,.002457142*ae.SQRT2*.5/2384e-9,971317e-9*ae.SQRT2*.5/2384e-9,218868e-9*ae.SQRT2*.5/2384e-9,101566e-9*ae.SQRT2*.5/2384e-9,13828e-9*ae.SQRT2*.5/2384e-9,12804.797818791945,1945.5515939597317,313.4244966442953,20.801593959731544,1995.1556208053692,9.000838926174497,-29.20218120805369],te=12,ce=36,re=[[2382191739347913e-28,6423305872147834e-28,9400849094049688e-28,1122435026096556e-27,1183840321267481e-27,1122435026096556e-27,940084909404969e-27,6423305872147839e-28,2382191739347918e-28,5456116108943412e-27,4878985199565852e-27,4240448995017367e-27,3559909094758252e-27,2858043359288075e-27,2156177623817898e-27,1475637723558783e-27,8371015190102974e-28,2599706096327376e-28,-5456116108943412e-27,-4878985199565852e-27,-4240448995017367e-27,-3559909094758252e-27,-2858043359288076e-27,-2156177623817898e-27,-1475637723558783e-27,-8371015190102975e-28,-2599706096327376e-28,-2382191739347923e-28,-6423305872147843e-28,-9400849094049696e-28,-1122435026096556e-27,-1183840321267481e-27,-1122435026096556e-27,-9400849094049694e-28,-642330587214784e-27,-2382191739347918e-28],[2382191739347913e-28,6423305872147834e-28,9400849094049688e-28,1122435026096556e-27,1183840321267481e-27,1122435026096556e-27,9400849094049688e-28,6423305872147841e-28,2382191739347918e-28,5456116108943413e-27,4878985199565852e-27,4240448995017367e-27,3559909094758253e-27,2858043359288075e-27,2156177623817898e-27,1475637723558782e-27,8371015190102975e-28,2599706096327376e-28,-5461314069809755e-27,-4921085770524055e-27,-4343405037091838e-27,-3732668368707687e-27,-3093523840190885e-27,-2430835727329465e-27,-1734679010007751e-27,-974825365660928e-27,-2797435120168326e-28,0,0,0,0,0,0,-2283748241799531e-28,-4037858874020686e-28,-2146547464825323e-28],[.1316524975873958,.414213562373095,.7673269879789602,1.091308501069271,1.303225372841206,1.56968557711749,1.920982126971166,2.414213562373094,3.171594802363212,4.510708503662055,7.595754112725146,22.90376554843115,.984807753012208,.6427876096865394,.3420201433256688,.9396926207859084,-.1736481776669303,-.7660444431189779,.8660254037844387,.5,-.5144957554275265,-.4717319685649723,-.3133774542039019,-.1819131996109812,-.09457419252642064,-.04096558288530405,-.01419856857247115,-.003699974673760037,.8574929257125442,.8817419973177052,.9496286491027329,.9833145924917901,.9955178160675857,.9991605581781475,.999899195244447,.9999931550702802],[0,0,0,0,0,0,2283748241799531e-28,4037858874020686e-28,2146547464825323e-28,5461314069809755e-27,4921085770524055e-27,4343405037091838e-27,3732668368707687e-27,3093523840190885e-27,2430835727329466e-27,1734679010007751e-27,974825365660928e-27,2797435120168326e-28,-5456116108943413e-27,-4878985199565852e-27,-4240448995017367e-27,-3559909094758253e-27,-2858043359288075e-27,-2156177623817898e-27,-1475637723558782e-27,-8371015190102975e-28,-2599706096327376e-28,-2382191739347913e-28,-6423305872147834e-28,-9400849094049688e-28,-1122435026096556e-27,-1183840321267481e-27,-1122435026096556e-27,-9400849094049688e-28,-6423305872147841e-28,-2382191739347918e-28]],Ee=re[P.SHORT_TYPE],ie=re[P.SHORT_TYPE],ye=re[P.SHORT_TYPE],ze=re[P.SHORT_TYPE],He=[0,1,16,17,8,9,24,25,4,5,20,21,12,13,28,29,2,3,18,19,10,11,26,27,6,7,22,23,14,15,30,31];function $(L,Q,m){for(var B=10,V=Q+238-14-286,k=-15;k<0;k++){var _,g,D;_=z[B+-10],g=L[V+-224]*_,D=L[Q+224]*_,_=z[B+-9],g+=L[V+-160]*_,D+=L[Q+160]*_,_=z[B+-8],g+=L[V+-96]*_,D+=L[Q+96]*_,_=z[B+-7],g+=L[V+-32]*_,D+=L[Q+32]*_,_=z[B+-6],g+=L[V+32]*_,D+=L[Q+-32]*_,_=z[B+-5],g+=L[V+96]*_,D+=L[Q+-96]*_,_=z[B+-4],g+=L[V+160]*_,D+=L[Q+-160]*_,_=z[B+-3],g+=L[V+224]*_,D+=L[Q+-224]*_,_=z[B+-2],g+=L[Q+-256]*_,D-=L[V+256]*_,_=z[B+-1],g+=L[Q+-192]*_,D-=L[V+192]*_,_=z[B+0],g+=L[Q+-128]*_,D-=L[V+128]*_,_=z[B+1],g+=L[Q+-64]*_,D-=L[V+64]*_,_=z[B+2],g+=L[Q+0]*_,D-=L[V+0]*_,_=z[B+3],g+=L[Q+64]*_,D-=L[V+-64]*_,_=z[B+4],g+=L[Q+128]*_,D-=L[V+-128]*_,_=z[B+5],g+=L[Q+192]*_,D-=L[V+-192]*_,g*=z[B+6],_=D-g,m[30+k*2]=D+g,m[31+k*2]=z[B+7]*_,B+=18,Q--,V++}{var g,D,K,w;D=L[Q+-16]*z[B+-10],g=L[Q+-32]*z[B+-2],D+=(L[Q+-48]-L[Q+16])*z[B+-9],g+=L[Q+-96]*z[B+-1],D+=(L[Q+-80]+L[Q+48])*z[B+-8],g+=L[Q+-160]*z[B+0],D+=(L[Q+-112]-L[Q+80])*z[B+-7],g+=L[Q+-224]*z[B+1],D+=(L[Q+-144]+L[Q+112])*z[B+-6],g-=L[Q+32]*z[B+2],D+=(L[Q+-176]-L[Q+144])*z[B+-5],g-=L[Q+96]*z[B+3],D+=(L[Q+-208]+L[Q+176])*z[B+-4],g-=L[Q+160]*z[B+4],D+=(L[Q+-240]-L[Q+208])*z[B+-3],g-=L[Q+224],K=g-D,w=g+D,D=m[14],g=m[15]-D,m[31]=w+D,m[30]=K+g,m[15]=K-g,m[14]=w-D}{var u;u=m[28]-m[0],m[0]+=m[28],m[28]=u*z[B+-2*18+7],u=m[29]-m[1],m[1]+=m[29],m[29]=u*z[B+-2*18+7],u=m[26]-m[2],m[2]+=m[26],m[26]=u*z[B+-4*18+7],u=m[27]-m[3],m[3]+=m[27],m[27]=u*z[B+-4*18+7],u=m[24]-m[4],m[4]+=m[24],m[24]=u*z[B+-6*18+7],u=m[25]-m[5],m[5]+=m[25],m[25]=u*z[B+-6*18+7],u=m[22]-m[6],m[6]+=m[22],m[22]=u*ae.SQRT2,u=m[23]-m[7],m[7]+=m[23],m[23]=u*ae.SQRT2-m[7],m[7]-=m[6],m[22]-=m[7],m[23]-=m[22],u=m[6],m[6]=m[31]-u,m[31]=m[31]+u,u=m[7],m[7]=m[30]-u,m[30]=m[30]+u,u=m[22],m[22]=m[15]-u,m[15]=m[15]+u,u=m[23],m[23]=m[14]-u,m[14]=m[14]+u,u=m[20]-m[8],m[8]+=m[20],m[20]=u*z[B+-10*18+7],u=m[21]-m[9],m[9]+=m[21],m[21]=u*z[B+-10*18+7],u=m[18]-m[10],m[10]+=m[18],m[18]=u*z[B+-12*18+7],u=m[19]-m[11],m[11]+=m[19],m[19]=u*z[B+-12*18+7],u=m[16]-m[12],m[12]+=m[16],m[16]=u*z[B+-14*18+7],u=m[17]-m[13],m[13]+=m[17],m[17]=u*z[B+-14*18+7],u=-m[20]+m[24],m[20]+=m[24],m[24]=u*z[B+-12*18+7],u=-m[21]+m[25],m[21]+=m[25],m[25]=u*z[B+-12*18+7],u=m[4]-m[8],m[4]+=m[8],m[8]=u*z[B+-12*18+7],u=m[5]-m[9],m[5]+=m[9],m[9]=u*z[B+-12*18+7],u=m[0]-m[12],m[0]+=m[12],m[12]=u*z[B+-4*18+7],u=m[1]-m[13],m[1]+=m[13],m[13]=u*z[B+-4*18+7],u=m[16]-m[28],m[16]+=m[28],m[28]=u*z[B+-4*18+7],u=-m[17]+m[29],m[17]+=m[29],m[29]=u*z[B+-4*18+7],u=ae.SQRT2*(m[2]-m[10]),m[2]+=m[10],m[10]=u,u=ae.SQRT2*(m[3]-m[11]),m[3]+=m[11],m[11]=u,u=ae.SQRT2*(-m[18]+m[26]),m[18]+=m[26],m[26]=u-m[18],u=ae.SQRT2*(-m[19]+m[27]),m[19]+=m[27],m[27]=u-m[19],u=m[2],m[19]-=m[3],m[3]-=u,m[2]=m[31]-u,m[31]+=u,u=m[3],m[11]-=m[19],m[18]-=u,m[3]=m[30]-u,m[30]+=u,u=m[18],m[27]-=m[11],m[19]-=u,m[18]=m[15]-u,m[15]+=u,u=m[19],m[10]-=u,m[19]=m[14]-u,m[14]+=u,u=m[10],m[11]-=u,m[10]=m[23]-u,m[23]+=u,u=m[11],m[26]-=u,m[11]=m[22]-u,m[22]+=u,u=m[26],m[27]-=u,m[26]=m[7]-u,m[7]+=u,u=m[27],m[27]=m[6]-u,m[6]+=u,u=ae.SQRT2*(m[0]-m[4]),m[0]+=m[4],m[4]=u,u=ae.SQRT2*(m[1]-m[5]),m[1]+=m[5],m[5]=u,u=ae.SQRT2*(m[16]-m[20]),m[16]+=m[20],m[20]=u,u=ae.SQRT2*(m[17]-m[21]),m[17]+=m[21],m[21]=u,u=-ae.SQRT2*(m[8]-m[12]),m[8]+=m[12],m[12]=u-m[8],u=-ae.SQRT2*(m[9]-m[13]),m[9]+=m[13],m[13]=u-m[9],u=-ae.SQRT2*(m[25]-m[29]),m[25]+=m[29],m[29]=u-m[25],u=-ae.SQRT2*(m[24]+m[28]),m[24]-=m[28],m[28]=u-m[24],u=m[24]-m[16],m[24]=u,u=m[20]-u,m[20]=u,u=m[28]-u,m[28]=u,u=m[25]-m[17],m[25]=u,u=m[21]-u,m[21]=u,u=m[29]-u,m[29]=u,u=m[17]-m[1],m[17]=u,u=m[9]-u,m[9]=u,u=m[25]-u,m[25]=u,u=m[5]-u,m[5]=u,u=m[21]-u,m[21]=u,u=m[13]-u,m[13]=u,u=m[29]-u,m[29]=u,u=m[1]-m[0],m[1]=u,u=m[16]-u,m[16]=u,u=m[17]-u,m[17]=u,u=m[8]-u,m[8]=u,u=m[9]-u,m[9]=u,u=m[24]-u,m[24]=u,u=m[25]-u,m[25]=u,u=m[4]-u,m[4]=u,u=m[5]-u,m[5]=u,u=m[20]-u,m[20]=u,u=m[21]-u,m[21]=u,u=m[12]-u,m[12]=u,u=m[13]-u,m[13]=u,u=m[28]-u,m[28]=u,u=m[29]-u,m[29]=u,u=m[0],m[0]+=m[31],m[31]-=u,u=m[1],m[1]+=m[30],m[30]-=u,u=m[16],m[16]+=m[15],m[15]-=u,u=m[17],m[17]+=m[14],m[14]-=u,u=m[8],m[8]+=m[23],m[23]-=u,u=m[9],m[9]+=m[22],m[22]-=u,u=m[24],m[24]+=m[7],m[7]-=u,u=m[25],m[25]+=m[6],m[6]-=u,u=m[4],m[4]+=m[27],m[27]-=u,u=m[5],m[5]+=m[26],m[26]-=u,u=m[20],m[20]+=m[11],m[11]-=u,u=m[21],m[21]+=m[10],m[10]-=u,u=m[12],m[12]+=m[19],m[19]-=u,u=m[13],m[13]+=m[18],m[18]-=u,u=m[28],m[28]+=m[3],m[3]-=u,u=m[29],m[29]+=m[2],m[2]-=u}}function fe(L,Q){for(var m=0;m<3;m++){var B,V,k,_,g,D;_=L[Q+2*3]*re[P.SHORT_TYPE][0]-L[Q+5*3],B=L[Q+0*3]*re[P.SHORT_TYPE][2]-L[Q+3*3],V=_+B,k=_-B,_=L[Q+5*3]*re[P.SHORT_TYPE][0]+L[Q+2*3],B=L[Q+3*3]*re[P.SHORT_TYPE][2]+L[Q+0*3],g=_+B,D=-_+B,B=(L[Q+1*3]*re[P.SHORT_TYPE][1]-L[Q+4*3])*2069978111953089e-26,_=(L[Q+4*3]*re[P.SHORT_TYPE][1]+L[Q+1*3])*2069978111953089e-26,L[Q+3*0]=V*190752519173728e-25+B,L[Q+3*5]=-g*190752519173728e-25+_,k=k*.8660254037844387*1907525191737281e-26,g=g*.5*1907525191737281e-26+_,L[Q+3*1]=k-g,L[Q+3*2]=k+g,V=V*.5*1907525191737281e-26-B,D=D*.8660254037844387*1907525191737281e-26,L[Q+3*3]=V+D,L[Q+3*4]=V-D,Q++}}function ge(L,Q,m){var B,V;{var k,_,g,D,K,w,u,F;k=m[17]-m[9],g=m[15]-m[11],D=m[14]-m[12],K=m[0]+m[8],w=m[1]+m[7],u=m[2]+m[6],F=m[3]+m[5],L[Q+17]=K+u-F-(w-m[4]),V=(K+u-F)*ie[12+7]+(w-m[4]),B=(k-g-D)*ie[12+6],L[Q+5]=B+V,L[Q+6]=B-V,_=(m[16]-m[10])*ie[12+6],w=w*ie[12+7]+m[4],B=k*ie[12+0]+_+g*ie[12+1]+D*ie[12+2],V=-K*ie[12+4]+w-u*ie[12+5]+F*ie[12+3],L[Q+1]=B+V,L[Q+2]=B-V,B=k*ie[12+1]-_-g*ie[12+2]+D*ie[12+0],V=-K*ie[12+5]+w-u*ie[12+3]+F*ie[12+4],L[Q+9]=B+V,L[Q+10]=B-V,B=k*ie[12+2]-_+g*ie[12+0]-D*ie[12+1],V=K*ie[12+3]-w+u*ie[12+4]-F*ie[12+5],L[Q+13]=B+V,L[Q+14]=B-V}{var R,f,y,b,d,x,N,T;R=m[8]-m[0],y=m[6]-m[2],b=m[5]-m[3],d=m[17]+m[9],x=m[16]+m[10],N=m[15]+m[11],T=m[14]+m[12],L[Q+0]=d+N+T+(x+m[13]),B=(d+N+T)*ie[12+7]-(x+m[13]),V=(R-y+b)*ie[12+6],L[Q+11]=B+V,L[Q+12]=B-V,f=(m[7]-m[1])*ie[12+6],x=m[13]-x*ie[12+7],B=d*ie[12+3]-x+N*ie[12+4]+T*ie[12+5],V=R*ie[12+2]+f+y*ie[12+0]+b*ie[12+1],L[Q+3]=B+V,L[Q+4]=B-V,B=-d*ie[12+5]+x-N*ie[12+3]-T*ie[12+4],V=R*ie[12+1]+f-y*ie[12+2]-b*ie[12+0],L[Q+7]=B+V,L[Q+8]=B-V,B=-d*ie[12+4]+x-N*ie[12+5]-T*ie[12+3],V=R*ie[12+0]-f+y*ie[12+1]-b*ie[12+2],L[Q+15]=B+V,L[Q+16]=B-V}}this.mdct_sub48=function(L,Q,m){for(var B=Q,V=286,k=0;k<L.channels_out;k++){for(var _=0;_<L.mode_gr;_++){for(var g,D=L.l3_side.tt[_][k],K=D.xr,w=0,u=L.sb_sample[k][1-_],F=0,R=0;R<18/2;R++)for($(B,V,u[F]),$(B,V+32,u[F+1]),F+=2,V+=64,g=1;g<32;g+=2)u[F-1][g]*=-1;for(g=0;g<32;g++,w+=18){var f=D.block_type,y=L.sb_sample[k][_],b=L.sb_sample[k][1-_];if(D.mixed_block_flag!=0&&g<2&&(f=0),L.amp_filter[g]<1e-12)Ce.fill(K,w+0,w+18,0);else{if(L.amp_filter[g]<1)for(var R=0;R<18;R++)b[R][He[g]]*=L.amp_filter[g];if(f==P.SHORT_TYPE){for(var R=-te/4;R<0;R++){var d=re[P.SHORT_TYPE][R+3];K[w+R*3+9]=y[9+R][He[g]]*d-y[8-R][He[g]],K[w+R*3+18]=y[14-R][He[g]]*d+y[15+R][He[g]],K[w+R*3+10]=y[15+R][He[g]]*d-y[14-R][He[g]],K[w+R*3+19]=b[2-R][He[g]]*d+b[3+R][He[g]],K[w+R*3+11]=b[3+R][He[g]]*d-b[2-R][He[g]],K[w+R*3+20]=b[8-R][He[g]]*d+b[9+R][He[g]]}fe(K,w)}else{for(var x=et(18),R=-ce/4;R<0;R++){var N,T;N=re[f][R+27]*b[R+9][He[g]]+re[f][R+36]*b[8-R][He[g]],T=re[f][R+9]*y[R+9][He[g]]-re[f][R+18]*y[8-R][He[g]],x[R+9]=N-T*Ee[3+R+9],x[R+18]=N*Ee[3+R+9]+T}ge(K,w,x)}}if(f!=P.SHORT_TYPE&&g!=0)for(var R=7;R>=0;--R){var Y,j;Y=K[w+R]*ye[20+R]+K[w+-1-R]*ze[28+R],j=K[w+R]*ze[28+R]-K[w+-1-R]*ye[20+R],K[w+-1-R]=Y,K[w+R]=j}}}if(B=m,V=286,L.mode_gr==1)for(var X=0;X<18;X++)W.arraycopy(L.sb_sample[k][1][X],0,L.sb_sample[k][0][X],0,32)}}}var _t=gt,dt=C.System,Tt=C.new_float,pr=C.new_float_n;function yr(){this.l=Tt(P.SBMAX_l),this.s=pr([P.SBMAX_s,3]);var z=this;this.assign=function(te){dt.arraycopy(te.l,0,z.l,0,P.SBMAX_l);for(var ce=0;ce<P.SBMAX_s;ce++)for(var re=0;re<3;re++)z.s[ce][re]=te.s[ce][re]}}var Cr=yr;function Ia(){this.thm=new Cr,this.en=new Cr}var oa=Ia,Lr=C.System,Vr=C.VbrMode,Sr=C.new_array_n,At=C.new_float,tr=C.new_float_n,Qt=C.new_int,$t=C.assert;ot.ENCDELAY=576,ot.POSTDELAY=1152,ot.MDCTDELAY=48,ot.FFTOFFSET=224+ot.MDCTDELAY,ot.DECDELAY=528,ot.SBLIMIT=32,ot.CBANDS=64,ot.SBPSY_l=21,ot.SBPSY_s=12,ot.SBMAX_l=22,ot.SBMAX_s=13,ot.PSFB21=6,ot.PSFB12=6,ot.BLKSIZE=1024,ot.HBLKSIZE=ot.BLKSIZE/2+1,ot.BLKSIZE_s=256,ot.HBLKSIZE_s=ot.BLKSIZE_s/2+1,ot.NORM_TYPE=0,ot.START_TYPE=1,ot.SHORT_TYPE=2,ot.STOP_TYPE=3,ot.MPG_MD_LR_LR=0,ot.MPG_MD_LR_I=1,ot.MPG_MD_MS_LR=2,ot.MPG_MD_MS_I=3,ot.fircoef=[-.0207887*5,-.0378413*5,-.0432472*5,-.031183*5,779609e-23*5,.0467745*5,.10091*5,.151365*5,.187098*5];function ot(){var z=_t,te=oa,ce=ot.FFTOFFSET,re=ot.MPG_MD_MS_LR,Ee=null;this.psy=null;var ie=null,ye=null,ze=null;this.setModules=function(L,Q,m,B){Ee=L,this.psy=Q,ie=Q,ye=B,ze=m};var He=new z;function $(L){var Q,m;if(L.ATH.useAdjust==0){L.ATH.adjust=1;return}if(m=L.loudness_sq[0][0],Q=L.loudness_sq[1][0],L.channels_out==2?(m+=L.loudness_sq[0][1],Q+=L.loudness_sq[1][1]):(m+=m,Q+=Q),L.mode_gr==2&&(m=Math.max(m,Q)),m*=.5,m*=L.ATH.aaSensitivityP,m>.03125)L.ATH.adjust>=1?L.ATH.adjust=1:L.ATH.adjust<L.ATH.adjustLimit&&(L.ATH.adjust=L.ATH.adjustLimit),L.ATH.adjustLimit=1;else{var B=31.98*m+625e-6;L.ATH.adjust>=B?(L.ATH.adjust*=B*.075+.925,L.ATH.adjust<B&&(L.ATH.adjust=B)):L.ATH.adjustLimit>=B?L.ATH.adjust=B:L.ATH.adjust<L.ATH.adjustLimit&&(L.ATH.adjust=L.ATH.adjustLimit),L.ATH.adjustLimit=B}}function fe(L){var Q,m;for($t(0<=L.bitrate_index&&L.bitrate_index<16),$t(0<=L.mode_ext&&L.mode_ext<4),L.bitrate_stereoMode_Hist[L.bitrate_index][4]++,L.bitrate_stereoMode_Hist[15][4]++,L.channels_out==2&&(L.bitrate_stereoMode_Hist[L.bitrate_index][L.mode_ext]++,L.bitrate_stereoMode_Hist[15][L.mode_ext]++),Q=0;Q<L.mode_gr;++Q)for(m=0;m<L.channels_out;++m){var B=L.l3_side.tt[Q][m].block_type|0;L.l3_side.tt[Q][m].mixed_block_flag!=0&&(B=4),L.bitrate_blockType_Hist[L.bitrate_index][B]++,L.bitrate_blockType_Hist[L.bitrate_index][5]++,L.bitrate_blockType_Hist[15][B]++,L.bitrate_blockType_Hist[15][5]++}}function ge(L,Q){var m=L.internal_flags,B,V;if(m.lame_encode_frame_init==0){var k,_,g=At(2014),D=At(286+1152+576);for(m.lame_encode_frame_init=1,k=0,_=0;k<286+576*(1+m.mode_gr);++k)k<576*m.mode_gr?(g[k]=0,m.channels_out==2&&(D[k]=0)):(g[k]=Q[0][_],m.channels_out==2&&(D[k]=Q[1][_]),++_);for(V=0;V<m.mode_gr;V++)for(B=0;B<m.channels_out;B++)m.l3_side.tt[V][B].block_type=ot.SHORT_TYPE;He.mdct_sub48(m,g,D),$t(576>=ot.FFTOFFSET),$t(m.mf_size>=ot.BLKSIZE+L.framesize-ot.FFTOFFSET),$t(m.mf_size>=512+L.framesize-32)}}this.lame_encode_mp3_frame=function(L,Q,m,B,V,k){var _,g=Sr([2,2]);g[0][0]=new te,g[0][1]=new te,g[1][0]=new te,g[1][1]=new te;var D=Sr([2,2]);D[0][0]=new te,D[0][1]=new te,D[1][0]=new te,D[1][1]=new te;var K,w=[null,null],u=L.internal_flags,F=tr([2,4]),R=[.5,.5],f=[[0,0],[0,0]],y=[[0,0],[0,0]],b,d,x;if(w[0]=Q,w[1]=m,u.lame_encode_frame_init==0&&ge(L,w),u.padding=0,(u.slot_lag-=u.frac_SpF)<0&&(u.slot_lag+=L.out_samplerate,u.padding=1),u.psymodel!=0){var N,T=[null,null],Y=0,j=Qt(2);for(x=0;x<u.mode_gr;x++){for(d=0;d<u.channels_out;d++)T[d]=w[d],Y=576+x*576-ot.FFTOFFSET;if(L.VBR==Vr.vbr_mtrh||L.VBR==Vr.vbr_mt?N=ie.L3psycho_anal_vbr(L,T,Y,x,g,D,f[x],y[x],F[x],j):N=ie.L3psycho_anal_ns(L,T,Y,x,g,D,f[x],y[x],F[x],j),N!=0)return-4;for(L.mode==Dr.JOINT_STEREO&&(R[x]=F[x][2]+F[x][3],R[x]>0&&(R[x]=F[x][3]/R[x])),d=0;d<u.channels_out;d++){var X=u.l3_side.tt[x][d];X.block_type=j[d],X.mixed_block_flag=0}}}else for(x=0;x<u.mode_gr;x++)for(d=0;d<u.channels_out;d++)u.l3_side.tt[x][d].block_type=ot.NORM_TYPE,u.l3_side.tt[x][d].mixed_block_flag=0,y[x][d]=f[x][d]=700;if($(u),He.mdct_sub48(u,w[0],w[1]),u.mode_ext=ot.MPG_MD_LR_LR,L.force_ms)u.mode_ext=ot.MPG_MD_MS_LR;else if(L.mode==Dr.JOINT_STEREO){var _e=0,h=0;for(x=0;x<u.mode_gr;x++)for(d=0;d<u.channels_out;d++)_e+=y[x][d],h+=f[x][d];if(_e<=1*h){var v=u.l3_side.tt[0],de=u.l3_side.tt[u.mode_gr-1];v[0].block_type==v[1].block_type&&de[0].block_type==de[1].block_type&&(u.mode_ext=ot.MPG_MD_MS_LR)}}if(u.mode_ext==re?(K=D,b=y):(K=g,b=f),L.analysis&&u.pinfo!=null)for(x=0;x<u.mode_gr;x++)for(d=0;d<u.channels_out;d++)u.pinfo.ms_ratio[x]=u.ms_ratio[x],u.pinfo.ms_ener_ratio[x]=R[x],u.pinfo.blocktype[x][d]=u.l3_side.tt[x][d].block_type,u.pinfo.pe[x][d]=b[x][d],Lr.arraycopy(u.l3_side.tt[x][d].xr,0,u.pinfo.xr[x][d],0,576),u.mode_ext==re&&(u.pinfo.ers[x][d]=u.pinfo.ers[x][d+2],Lr.arraycopy(u.pinfo.energy[x][d+2],0,u.pinfo.energy[x][d],0,u.pinfo.energy[x][d].length));if(L.VBR==Vr.vbr_off||L.VBR==Vr.vbr_abr){var ve,De;for(ve=0;ve<18;ve++)u.nsPsy.pefirbuf[ve]=u.nsPsy.pefirbuf[ve+1];for(De=0,x=0;x<u.mode_gr;x++)for(d=0;d<u.channels_out;d++)De+=b[x][d];for(u.nsPsy.pefirbuf[18]=De,De=u.nsPsy.pefirbuf[9],ve=0;ve<9;ve++)De+=(u.nsPsy.pefirbuf[ve]+u.nsPsy.pefirbuf[18-ve])*ot.fircoef[ve];for(De=670*5*u.mode_gr*u.channels_out/De,x=0;x<u.mode_gr;x++)for(d=0;d<u.channels_out;d++)b[x][d]*=De}if(u.iteration_loop.iteration_loop(L,b,R,K),Ee.format_bitstream(L),_=Ee.copy_buffer(u,B,V,k,1),L.bWriteVbrTag&&ye.addVbrFrame(L),L.analysis&&u.pinfo!=null){for(d=0;d<u.channels_out;d++){var Ue;for(Ue=0;Ue<ce;Ue++)u.pinfo.pcmdata[d][Ue]=u.pinfo.pcmdata[d][Ue+L.framesize];for(Ue=ce;Ue<1600;Ue++)u.pinfo.pcmdata[d][Ue]=w[d][Ue-ce]}ze.set_frame_pinfo(L,K)}return fe(u),_}}var P=ot,Z=C.Util,Re=C.new_float;function ke(){var z=Re(P.BLKSIZE),te=Re(P.BLKSIZE_s/2),ce=[.9238795325112867,.3826834323650898,.9951847266721969,.0980171403295606,.9996988186962042,.02454122852291229,.9999811752826011,.006135884649154475];function re(ie,ye,ze){var He=0,$,fe,ge;ze<<=1;var L=ye+ze;$=4;do{var Q,m,B,V,k,_,g;g=$>>1,V=$,k=$<<1,_=k+V,$=k<<1,fe=ye,ge=fe+g;do{var D,K,w,u;K=ie[fe+0]-ie[fe+V],D=ie[fe+0]+ie[fe+V],u=ie[fe+k]-ie[fe+_],w=ie[fe+k]+ie[fe+_],ie[fe+k]=D-w,ie[fe+0]=D+w,ie[fe+_]=K-u,ie[fe+V]=K+u,K=ie[ge+0]-ie[ge+V],D=ie[ge+0]+ie[ge+V],u=Z.SQRT2*ie[ge+_],w=Z.SQRT2*ie[ge+k],ie[ge+k]=D-w,ie[ge+0]=D+w,ie[ge+_]=K-u,ie[ge+V]=K+u,ge+=$,fe+=$}while(fe<L);for(m=ce[He+0],Q=ce[He+1],B=1;B<g;B++){var F,R;F=1-2*Q*Q,R=2*Q*m,fe=ye+B,ge=ye+V-B;do{var f,y,b,D,K,d,w,x,u,N;y=R*ie[fe+V]-F*ie[ge+V],f=F*ie[fe+V]+R*ie[ge+V],K=ie[fe+0]-f,D=ie[fe+0]+f,d=ie[ge+0]-y,b=ie[ge+0]+y,y=R*ie[fe+_]-F*ie[ge+_],f=F*ie[fe+_]+R*ie[ge+_],u=ie[fe+k]-f,w=ie[fe+k]+f,N=ie[ge+k]-y,x=ie[ge+k]+y,y=Q*w-m*N,f=m*w+Q*N,ie[fe+k]=D-f,ie[fe+0]=D+f,ie[ge+_]=d-y,ie[ge+V]=d+y,y=m*x-Q*u,f=Q*x+m*u,ie[ge+k]=b-f,ie[ge+0]=b+f,ie[fe+_]=K-y,ie[fe+V]=K+y,ge+=$,fe+=$}while(fe<L);F=m,m=F*ce[He+0]-Q*ce[He+1],Q=F*ce[He+1]+Q*ce[He+0]}He+=2}while($<ze)}var Ee=[0,128,64,192,32,160,96,224,16,144,80,208,48,176,112,240,8,136,72,200,40,168,104,232,24,152,88,216,56,184,120,248,4,132,68,196,36,164,100,228,20,148,84,212,52,180,116,244,12,140,76,204,44,172,108,236,28,156,92,220,60,188,124,252,2,130,66,194,34,162,98,226,18,146,82,210,50,178,114,242,10,138,74,202,42,170,106,234,26,154,90,218,58,186,122,250,6,134,70,198,38,166,102,230,22,150,86,214,54,182,118,246,14,142,78,206,46,174,110,238,30,158,94,222,62,190,126,254];this.fft_short=function(ie,ye,ze,He,$){for(var fe=0;fe<3;fe++){var ge=P.BLKSIZE_s/2,L=65535&576/3*(fe+1),Q=P.BLKSIZE_s/8-1;do{var m,B,V,k,_,g=Ee[Q<<2]&255;m=te[g]*He[ze][$+g+L],_=te[127-g]*He[ze][$+g+L+128],B=m-_,m=m+_,V=te[g+64]*He[ze][$+g+L+64],_=te[63-g]*He[ze][$+g+L+192],k=V-_,V=V+_,ge-=4,ye[fe][ge+0]=m+V,ye[fe][ge+2]=m-V,ye[fe][ge+1]=B+k,ye[fe][ge+3]=B-k,m=te[g+1]*He[ze][$+g+L+1],_=te[126-g]*He[ze][$+g+L+129],B=m-_,m=m+_,V=te[g+65]*He[ze][$+g+L+65],_=te[62-g]*He[ze][$+g+L+193],k=V-_,V=V+_,ye[fe][ge+P.BLKSIZE_s/2+0]=m+V,ye[fe][ge+P.BLKSIZE_s/2+2]=m-V,ye[fe][ge+P.BLKSIZE_s/2+1]=B+k,ye[fe][ge+P.BLKSIZE_s/2+3]=B-k}while(--Q>=0);re(ye[fe],ge,P.BLKSIZE_s/2)}},this.fft_long=function(ie,ye,ze,He,$){var fe=P.BLKSIZE/8-1,ge=P.BLKSIZE/2;do{var L,Q,m,B,V,k=Ee[fe]&255;L=z[k]*He[ze][$+k],V=z[k+512]*He[ze][$+k+512],Q=L-V,L=L+V,m=z[k+256]*He[ze][$+k+256],V=z[k+768]*He[ze][$+k+768],B=m-V,m=m+V,ge-=4,ye[ge+0]=L+m,ye[ge+2]=L-m,ye[ge+1]=Q+B,ye[ge+3]=Q-B,L=z[k+1]*He[ze][$+k+1],V=z[k+513]*He[ze][$+k+513],Q=L-V,L=L+V,m=z[k+257]*He[ze][$+k+257],V=z[k+769]*He[ze][$+k+769],B=m-V,m=m+V,ye[ge+P.BLKSIZE/2+0]=L+m,ye[ge+P.BLKSIZE/2+2]=L-m,ye[ge+P.BLKSIZE/2+1]=Q+B,ye[ge+P.BLKSIZE/2+3]=Q-B}while(--fe>=0);re(ye,ge,P.BLKSIZE/2)},this.init_fft=function(ie){for(var ye=0;ye<P.BLKSIZE;ye++)z[ye]=.42-.5*Math.cos(2*Math.PI*(ye+.5)/P.BLKSIZE)+.08*Math.cos(4*Math.PI*(ye+.5)/P.BLKSIZE);for(var ye=0;ye<P.BLKSIZE_s/2;ye++)te[ye]=.5*(1-Math.cos(2*Math.PI*(ye+.5)/P.BLKSIZE_s))}}var ne=ke,ue=C.VbrMode,Ne=C.Float,Se=C.ShortBlock,Pe=C.Util,Fe=C.Arrays,Te=C.new_float,it=C.new_float_n,lt=C.new_int,pe=C.assert;function qr(){var z=new ne,te=2.302585092994046,ce=2,re=16,Ee=2,ie=16,ye=.34,ze=1/(14752*14752)/(P.BLKSIZE/2),He=.01,$=.8,fe=.6,ge=.3,L=3.5,Q=4.4,m=25,B=21,V=.2302585093;function k(I){return I}function _(I,A){for(var U=0,G=0;G<P.BLKSIZE/2;++G)U+=I[G]*A.ATH.eql_w[G];return U*=ze,U}function g(I,A,U,G,se,H,ee,oe,J,he,le){var xe=I.internal_flags;if(J<2)z.fft_long(xe,G[se],J,he,le),z.fft_short(xe,H[ee],J,he,le);else if(J==2){for(var je=P.BLKSIZE-1;je>=0;--je){var ht=G[se+0][je],Ie=G[se+1][je];G[se+0][je]=(ht+Ie)*Pe.SQRT2*.5,G[se+1][je]=(ht-Ie)*Pe.SQRT2*.5}for(var ct=2;ct>=0;--ct)for(var je=P.BLKSIZE_s-1;je>=0;--je){var ht=H[ee+0][ct][je],Ie=H[ee+1][ct][je];H[ee+0][ct][je]=(ht+Ie)*Pe.SQRT2*.5,H[ee+1][ct][je]=(ht-Ie)*Pe.SQRT2*.5}}A[0]=G[se+0][0],A[0]*=A[0];for(var je=P.BLKSIZE/2-1;je>=0;--je){var me=G[se+0][P.BLKSIZE/2-je],We=G[se+0][P.BLKSIZE/2+je];A[P.BLKSIZE/2-je]=(me*me+We*We)*.5}for(var ct=2;ct>=0;--ct){U[ct][0]=H[ee+0][ct][0],U[ct][0]*=U[ct][0];for(var je=P.BLKSIZE_s/2-1;je>=0;--je){var me=H[ee+0][ct][P.BLKSIZE_s/2-je],We=H[ee+0][ct][P.BLKSIZE_s/2+je];U[ct][P.BLKSIZE_s/2-je]=(me*me+We*We)*.5}}{for(var Ct=0,je=11;je<P.HBLKSIZE;je++)Ct+=A[je];xe.tot_ener[J]=Ct}if(I.analysis){for(var je=0;je<P.HBLKSIZE;je++)xe.pinfo.energy[oe][J][je]=xe.pinfo.energy_save[J][je],xe.pinfo.energy_save[J][je]=A[je];xe.pinfo.pe[oe][J]=xe.pe[J]}I.athaa_loudapprox==2&&J<2&&(xe.loudness_sq[oe][J]=xe.loudness_sq_save[J],xe.loudness_sq_save[J]=_(A,xe))}var D=8,K=23,w=15,u,F,R,f=[1,.79433,.63096,.63096,.63096,.63096,.63096,.25119,.11749];function y(){u=Math.pow(10,(D+1)/16),F=Math.pow(10,(K+1)/16),R=Math.pow(10,w/10)}var b=[3.3246*3.3246,3.23837*3.23837,3.15437*3.15437,3.00412*3.00412,2.86103*2.86103,2.65407*2.65407,2.46209*2.46209,2.284*2.284,2.11879*2.11879,1.96552*1.96552,1.82335*1.82335,1.69146*1.69146,1.56911*1.56911,1.46658*1.46658,1.37074*1.37074,1.31036*1.31036,1.25264*1.25264,1.20648*1.20648,1.16203*1.16203,1.12765*1.12765,1.09428*1.09428,1.0659*1.0659,1.03826*1.03826,1.01895*1.01895,1],d=[1.33352*1.33352,1.35879*1.35879,1.38454*1.38454,1.39497*1.39497,1.40548*1.40548,1.3537*1.3537,1.30382*1.30382,1.22321*1.22321,1.14758*1.14758,1],x=[2.35364*2.35364,2.29259*2.29259,2.23313*2.23313,2.12675*2.12675,2.02545*2.02545,1.87894*1.87894,1.74303*1.74303,1.61695*1.61695,1.49999*1.49999,1.39148*1.39148,1.29083*1.29083,1.19746*1.19746,1.11084*1.11084,1.03826*1.03826];function N(I,A,U,G,se,H){var ee;if(A>I)if(A<I*F)ee=A/I;else return I+A;else{if(I>=A*F)return I+A;ee=I/A}if(pe(I>=0),pe(A>=0),I+=A,G+3<=3+3){if(ee>=u)return I;var oe=0|Pe.FAST_LOG10_X(ee,16);return I*d[oe]}var oe=0|Pe.FAST_LOG10_X(ee,16);if(H!=0?A=se.ATH.cb_s[U]*se.ATH.adjust:A=se.ATH.cb_l[U]*se.ATH.adjust,pe(A>=0),I<R*A){if(I>A){var J,he;return J=1,oe<=13&&(J=x[oe]),he=Pe.FAST_LOG10_X(I/A,10/15),I*((b[oe]-J)*he+J)}return oe>13?I:I*x[oe]}return I*b[oe]}var T=[1.33352*1.33352,1.35879*1.35879,1.38454*1.38454,1.39497*1.39497,1.40548*1.40548,1.3537*1.3537,1.30382*1.30382,1.22321*1.22321,1.14758*1.14758,1];function Y(I,A,U){var G;if(I<0&&(I=0),A<0&&(A=0),I<=0)return A;if(A<=0)return I;if(A>I?G=A/I:G=I/A,-2<=U&&U<=2){if(G>=u)return I+A;var se=0|Pe.FAST_LOG10_X(G,16);return(I+A)*T[se]}return G<F?I+A:(I<A&&(I=A),I)}function j(I,A){var U=I.internal_flags;if(U.channels_out>1){for(var G=0;G<P.SBMAX_l;G++){var se=U.thm[0].l[G],H=U.thm[1].l[G];U.thm[0].l[G]+=H*A,U.thm[1].l[G]+=se*A}for(var G=0;G<P.SBMAX_s;G++)for(var ee=0;ee<3;ee++){var se=U.thm[0].s[G][ee],H=U.thm[1].s[G][ee];U.thm[0].s[G][ee]+=H*A,U.thm[1].s[G][ee]+=se*A}}}function X(I){for(var A=0;A<P.SBMAX_l;A++)if(!(I.thm[0].l[A]>1.58*I.thm[1].l[A]||I.thm[1].l[A]>1.58*I.thm[0].l[A])){var U=I.mld_l[A]*I.en[3].l[A],G=Math.max(I.thm[2].l[A],Math.min(I.thm[3].l[A],U));U=I.mld_l[A]*I.en[2].l[A];var se=Math.max(I.thm[3].l[A],Math.min(I.thm[2].l[A],U));I.thm[2].l[A]=G,I.thm[3].l[A]=se}for(var A=0;A<P.SBMAX_s;A++)for(var H=0;H<3;H++)if(!(I.thm[0].s[A][H]>1.58*I.thm[1].s[A][H]||I.thm[1].s[A][H]>1.58*I.thm[0].s[A][H])){var U=I.mld_s[A]*I.en[3].s[A][H],G=Math.max(I.thm[2].s[A][H],Math.min(I.thm[3].s[A][H],U));U=I.mld_s[A]*I.en[2].s[A][H];var se=Math.max(I.thm[3].s[A][H],Math.min(I.thm[2].s[A][H],U));I.thm[2].s[A][H]=G,I.thm[3].s[A][H]=se}}function _e(I,A,U){var G=A,se=Math.pow(10,U);A*=2,G*=2;for(var H=0;H<P.SBMAX_l;H++){var ee,oe,J,he;if(he=I.ATH.cb_l[I.bm_l[H]]*se,ee=Math.min(Math.max(I.thm[0].l[H],he),Math.max(I.thm[1].l[H],he)),oe=Math.max(I.thm[2].l[H],he),J=Math.max(I.thm[3].l[H],he),ee*A<oe+J){var le=ee*G/(oe+J);oe*=le,J*=le,pe(oe+J>0)}I.thm[2].l[H]=Math.min(oe,I.thm[2].l[H]),I.thm[3].l[H]=Math.min(J,I.thm[3].l[H])}se*=P.BLKSIZE_s/P.BLKSIZE;for(var H=0;H<P.SBMAX_s;H++)for(var xe=0;xe<3;xe++){var ee,oe,J,he;if(he=I.ATH.cb_s[I.bm_s[H]]*se,ee=Math.min(Math.max(I.thm[0].s[H][xe],he),Math.max(I.thm[1].s[H][xe],he)),oe=Math.max(I.thm[2].s[H][xe],he),J=Math.max(I.thm[3].s[H][xe],he),ee*A<oe+J){var le=ee*A/(oe+J);oe*=le,J*=le,pe(oe+J>0)}I.thm[2].s[H][xe]=Math.min(I.thm[2].s[H][xe],oe),I.thm[3].s[H][xe]=Math.min(I.thm[3].s[H][xe],J)}}function h(I,A,U,G,se){var H,ee,oe=0,J=0;for(H=ee=0;H<P.SBMAX_s;++ee,++H){for(var he=I.bo_s[H],le=I.npart_s,xe=he<le?he:le;ee<xe;)pe(A[ee]>=0),pe(U[ee]>=0),oe+=A[ee],J+=U[ee],ee++;if(I.en[G].s[H][se]=oe,I.thm[G].s[H][se]=J,ee>=le){++H;break}pe(A[ee]>=0),pe(U[ee]>=0);{var je=I.PSY.bo_s_weight[H],ht=1-je;oe=je*A[ee],J=je*U[ee],I.en[G].s[H][se]+=oe,I.thm[G].s[H][se]+=J,oe=ht*A[ee],J=ht*U[ee]}}for(;H<P.SBMAX_s;++H)I.en[G].s[H][se]=0,I.thm[G].s[H][se]=0}function v(I,A,U,G){var se,H,ee=0,oe=0;for(se=H=0;se<P.SBMAX_l;++H,++se){for(var J=I.bo_l[se],he=I.npart_l,le=J<he?J:he;H<le;)pe(A[H]>=0),pe(U[H]>=0),ee+=A[H],oe+=U[H],H++;if(I.en[G].l[se]=ee,I.thm[G].l[se]=oe,H>=he){++se;break}pe(A[H]>=0),pe(U[H]>=0);{var xe=I.PSY.bo_l_weight[se],je=1-xe;ee=xe*A[H],oe=xe*U[H],I.en[G].l[se]+=ee,I.thm[G].l[se]+=oe,ee=je*A[H],oe=je*U[H]}}for(;se<P.SBMAX_l;++se)I.en[G].l[se]=0,I.thm[G].l[se]=0}function de(I,A,U,G,se,H){var ee=I.internal_flags,oe,J;for(J=oe=0;J<ee.npart_s;++J){for(var he=0,le=0,xe=ee.numlines_s[J],je=0;je<xe;++je,++oe){var ht=A[H][oe];he+=ht,le<ht&&(le=ht)}U[J]=he}for(pe(J==ee.npart_s),pe(oe==129),oe=J=0;J<ee.npart_s;J++){var Ie=ee.s3ind_s[J][0],ct=ee.s3_ss[oe++]*U[Ie];for(++Ie;Ie<=ee.s3ind_s[J][1];)ct+=ee.s3_ss[oe]*U[Ie],++oe,++Ie;{var me=Ee*ee.nb_s1[se][J];G[J]=Math.min(ct,me)}if(ee.blocktype_old[se&1]==P.SHORT_TYPE){var me=ie*ee.nb_s2[se][J],We=G[J];G[J]=Math.min(me,We)}ee.nb_s2[se][J]=ee.nb_s1[se][J],ee.nb_s1[se][J]=ct,pe(G[J]>=0)}for(;J<=P.CBANDS;++J)U[J]=0,G[J]=0}function ve(I,A,U,G){var se=I.internal_flags;I.short_blocks==Se.short_block_coupled&&!(A[0]!=0&&A[1]!=0)&&(A[0]=A[1]=0);for(var H=0;H<se.channels_out;H++)G[H]=P.NORM_TYPE,I.short_blocks==Se.short_block_dispensed&&(A[H]=1),I.short_blocks==Se.short_block_forced&&(A[H]=0),A[H]!=0?(pe(se.blocktype_old[H]!=P.START_TYPE),se.blocktype_old[H]==P.SHORT_TYPE&&(G[H]=P.STOP_TYPE)):(G[H]=P.SHORT_TYPE,se.blocktype_old[H]==P.NORM_TYPE&&(se.blocktype_old[H]=P.START_TYPE),se.blocktype_old[H]==P.STOP_TYPE&&(se.blocktype_old[H]=P.SHORT_TYPE)),U[H]=se.blocktype_old[H],se.blocktype_old[H]=G[H]}function De(I,A,U){return U>=1?I:U<=0?A:A>0?Math.pow(I/A,U)*A:0}var Ue=[11.8,13.6,17.2,32,46.5,51.3,57.5,67.1,71.5,84.6,97.6,130];function $e(I,A){for(var U=309.07,G=0;G<P.SBMAX_s-1;G++)for(var se=0;se<3;se++){var H=I.thm.s[G][se];if(pe(G<Ue.length),H>0){var ee=H*A,oe=I.en.s[G][se];oe>ee&&(oe>ee*1e10?U+=Ue[G]*(10*te):(pe(ee>0),U+=Ue[G]*Pe.FAST_LOG10(oe/ee)))}}return U}var Xe=[6.8,5.8,5.8,6.4,6.5,9.9,12.1,14.4,15,18.9,21.6,26.9,34.2,40.2,46.8,56.5,60.7,73.9,85.7,93.4,126.1];function yt(I,A){for(var U=281.0575,G=0;G<P.SBMAX_l-1;G++){var se=I.thm.l[G];if(pe(G<Xe.length),se>0){var H=se*A,ee=I.en.l[G];ee>H&&(ee>H*1e10?U+=Xe[G]*(10*te):(pe(H>0),U+=Xe[G]*Pe.FAST_LOG10(ee/H)))}}return U}function tt(I,A,U,G,se){var H,ee;for(H=ee=0;H<I.npart_l;++H){var oe=0,J=0,he;for(he=0;he<I.numlines_l[H];++he,++ee){var le=A[ee];pe(le>=0),oe+=le,J<le&&(J=le)}U[H]=oe,G[H]=J,se[H]=oe*I.rnumlines_l[H],pe(I.rnumlines_l[H]>=0),pe(oe>=0),pe(U[H]>=0),pe(G[H]>=0),pe(se[H]>=0)}}function Ve(I,A,U,G){var se=f.length-1,H=0,ee=U[H]+U[H+1];if(pe(ee>=0),ee>0){var oe=A[H];oe<A[H+1]&&(oe=A[H+1]),pe(I.numlines_l[H]+I.numlines_l[H+1]-1>0),ee=20*(oe*2-ee)/(ee*(I.numlines_l[H]+I.numlines_l[H+1]-1));var J=0|ee;J>se&&(J=se),G[H]=J}else G[H]=0;for(H=1;H<I.npart_l-1;H++)if(ee=U[H-1]+U[H]+U[H+1],pe(ee>=0),ee>0){var oe=A[H-1];oe<A[H]&&(oe=A[H]),oe<A[H+1]&&(oe=A[H+1]),pe(I.numlines_l[H-1]+I.numlines_l[H]+I.numlines_l[H+1]-1>0),ee=20*(oe*3-ee)/(ee*(I.numlines_l[H-1]+I.numlines_l[H]+I.numlines_l[H+1]-1));var J=0|ee;J>se&&(J=se),G[H]=J}else G[H]=0;if(pe(H>0),pe(H==I.npart_l-1),ee=U[H-1]+U[H],pe(ee>=0),ee>0){var oe=A[H-1];oe<A[H]&&(oe=A[H]),pe(I.numlines_l[H-1]+I.numlines_l[H]-1>0),ee=20*(oe*2-ee)/(ee*(I.numlines_l[H-1]+I.numlines_l[H]-1));var J=0|ee;J>se&&(J=se),G[H]=J}else G[H]=0;pe(H==I.npart_l-1)}var kt=[-865163e-23*2,-.00851586*2,-674764e-23*2,.0209036*2,-336639e-22*2,-.0438162*2,-154175e-22*2,.0931738*2,-552212e-22*2,-.313819*2];this.L3psycho_anal_ns=function(I,A,U,G,se,H,ee,oe,J,he){var le=I.internal_flags,xe=it([2,P.BLKSIZE]),je=it([2,3,P.BLKSIZE_s]),ht=Te(P.CBANDS+1),Ie=Te(P.CBANDS+1),ct=Te(P.CBANDS+2),me=lt(2),We=lt(2),Ct,Ae,rt,Me,ut,mr,Ke,bt,wt=it([2,576]),xr,ja=lt(P.CBANDS+2),Mr=lt(P.CBANDS+2);for(Fe.fill(Mr,0),Ct=le.channels_out,I.mode==Dr.JOINT_STEREO&&(Ct=4),I.VBR==ue.vbr_off?xr=le.ResvMax==0?0:le.ResvSize/le.ResvMax*.5:I.VBR==ue.vbr_rh||I.VBR==ue.vbr_mtrh||I.VBR==ue.vbr_mt?xr=.6:xr=1,Ae=0;Ae<le.channels_out;Ae++){var hr=A[Ae],Oa=U+576-350-B+192;for(pe(kt.length==(B-1)/2),Me=0;Me<576;Me++){var Va,Ga;for(Va=hr[Oa+Me+10],Ga=0,ut=0;ut<(B-1)/2-1;ut+=2)Va+=kt[ut]*(hr[Oa+Me+ut]+hr[Oa+Me+B-ut]),Ga+=kt[ut+1]*(hr[Oa+Me+ut+1]+hr[Oa+Me+B-ut-1]);wt[Ae][Me]=Va+Ga}se[G][Ae].en.assign(le.en[Ae]),se[G][Ae].thm.assign(le.thm[Ae]),Ct>2&&(H[G][Ae].en.assign(le.en[Ae+2]),H[G][Ae].thm.assign(le.thm[Ae+2]))}for(Ae=0;Ae<Ct;Ae++){var wn,In,ha=Te(12),ai=[0,0,0,0],Mo=Te(12),_p=1,Eg,Tg=Te(P.CBANDS),wg=Te(P.CBANDS),gr=[0,0,0,0],Ig=Te(P.HBLKSIZE),Mg=it([3,P.HBLKSIZE_s]);for(pe(le.npart_s<=P.CBANDS),pe(le.npart_l<=P.CBANDS),Me=0;Me<3;Me++)ha[Me]=le.nsPsy.last_en_subshort[Ae][Me+6],pe(le.nsPsy.last_en_subshort[Ae][Me+4]>0),Mo[Me]=ha[Me]/le.nsPsy.last_en_subshort[Ae][Me+4],ai[0]+=ha[Me];if(Ae==2)for(Me=0;Me<576;Me++){var bp,Sp;bp=wt[0][Me],Sp=wt[1][Me],wt[0][Me]=bp+Sp,wt[1][Me]=bp-Sp}{var Ag=wt[Ae&1],Wl=0;for(Me=0;Me<9;Me++){for(var SC=Wl+64,Gr=1;Wl<SC;Wl++)Gr<Math.abs(Ag[Wl])&&(Gr=Math.abs(Ag[Wl]));le.nsPsy.last_en_subshort[Ae][Me]=ha[Me+3]=Gr,ai[1+Me/3]+=Gr,Gr>ha[Me+3-2]?(pe(ha[Me+3-2]>0),Gr=Gr/ha[Me+3-2]):ha[Me+3-2]>Gr*10?(pe(Gr>0),Gr=ha[Me+3-2]/(Gr*10)):Gr=0,Mo[Me+3]=Gr}}if(I.analysis){var Np=Mo[0];for(Me=1;Me<12;Me++)Np<Mo[Me]&&(Np=Mo[Me]);le.pinfo.ers[G][Ae]=le.pinfo.ers_save[Ae],le.pinfo.ers_save[Ae]=Np}for(Eg=Ae==3?le.nsPsy.attackthre_s:le.nsPsy.attackthre,Me=0;Me<12;Me++)gr[Me/3]==0&&Mo[Me]>Eg&&(gr[Me/3]=Me%3+1);for(Me=1;Me<4;Me++){var Pp;ai[Me-1]>ai[Me]?(pe(ai[Me]>0),Pp=ai[Me-1]/ai[Me]):(pe(ai[Me-1]>0),Pp=ai[Me]/ai[Me-1]),Pp<1.7&&(gr[Me]=0,Me==1&&(gr[0]=0))}for(gr[0]!=0&&le.nsPsy.lastAttacks[Ae]!=0&&(gr[0]=0),(le.nsPsy.lastAttacks[Ae]==3||gr[0]+gr[1]+gr[2]+gr[3]!=0)&&(_p=0,gr[1]!=0&&gr[0]!=0&&(gr[1]=0),gr[2]!=0&&gr[1]!=0&&(gr[2]=0),gr[3]!=0&&gr[2]!=0&&(gr[3]=0)),Ae<2?We[Ae]=_p:_p==0&&(We[0]=We[1]=0),J[Ae]=le.tot_ener[Ae],In=je,wn=xe,g(I,Ig,Mg,wn,Ae&1,In,Ae&1,G,Ae,A,U),tt(le,Ig,ht,Tg,wg),Ve(le,Tg,wg,ja),bt=0;bt<3;bt++){var Cp,za;for(de(I,Mg,Ie,ct,Ae,bt),h(le,Ie,ct,Ae,bt),Ke=0;Ke<P.SBMAX_s;Ke++){if(za=le.thm[Ae].s[Ke][bt],za*=$,gr[bt]>=2||gr[bt+1]==1){var Yl=bt!=0?bt-1:2,Gr=De(le.thm[Ae].s[Ke][Yl],za,fe*xr);za=Math.min(za,Gr)}if(gr[bt]==1){var Yl=bt!=0?bt-1:2,Gr=De(le.thm[Ae].s[Ke][Yl],za,ge*xr);za=Math.min(za,Gr)}else if(bt!=0&&gr[bt-1]==3||bt==0&&le.nsPsy.lastAttacks[Ae]==3){var Yl=bt!=2?bt+1:0,Gr=De(le.thm[Ae].s[Ke][Yl],za,ge*xr);za=Math.min(za,Gr)}Cp=ha[bt*3+3]+ha[bt*3+4]+ha[bt*3+5],ha[bt*3+5]*6<Cp&&(za*=.5,ha[bt*3+4]*6<Cp&&(za*=.5)),le.thm[Ae].s[Ke][bt]=za}}for(le.nsPsy.lastAttacks[Ae]=gr[2],mr=0,rt=0;rt<le.npart_l;rt++){for(var Fs=le.s3ind[rt][0],Rp=ht[Fs]*f[ja[Fs]],Us=le.s3_ll[mr++]*Rp;++Fs<=le.s3ind[rt][1];)Rp=ht[Fs]*f[ja[Fs]],Us=N(Us,le.s3_ll[mr++]*Rp,Fs,Fs-rt,le,0);Us*=.158489319246111,le.blocktype_old[Ae&1]==P.SHORT_TYPE?ct[rt]=Us:ct[rt]=De(Math.min(Us,Math.min(ce*le.nb_1[Ae][rt],re*le.nb_2[Ae][rt])),Us,xr),le.nb_2[Ae][rt]=le.nb_1[Ae][rt],le.nb_1[Ae][rt]=Us}for(;rt<=P.CBANDS;++rt)ht[rt]=0,ct[rt]=0;v(le,ht,ct,Ae)}if((I.mode==Dr.STEREO||I.mode==Dr.JOINT_STEREO)&&I.interChRatio>0&&j(I,I.interChRatio),I.mode==Dr.JOINT_STEREO){var Ep;X(le),Ep=I.msfix,Math.abs(Ep)>0&&_e(le,Ep,I.ATHlower*le.ATH.adjust)}for(ve(I,We,he,me),Ae=0;Ae<Ct;Ae++){var Ql,Zl=0,Nm,Pm;Ae>1?(Ql=oe,Zl=-2,Nm=P.NORM_TYPE,(he[0]==P.SHORT_TYPE||he[1]==P.SHORT_TYPE)&&(Nm=P.SHORT_TYPE),Pm=H[G][Ae-2]):(Ql=ee,Zl=0,Nm=he[Ae],Pm=se[G][Ae]),Nm==P.SHORT_TYPE?Ql[Zl+Ae]=$e(Pm,le.masking_lower):Ql[Zl+Ae]=yt(Pm,le.masking_lower),I.analysis&&(le.pinfo.pe[G][Ae]=Ql[Zl+Ae])}return 0};function lr(I,A,U,G,se,H,ee,oe){var J=I.internal_flags;if(G<2)z.fft_long(J,ee[oe],G,A,U);else if(G==2)for(var he=P.BLKSIZE-1;he>=0;--he){var le=ee[oe+0][he],xe=ee[oe+1][he];ee[oe+0][he]=(le+xe)*Pe.SQRT2*.5,ee[oe+1][he]=(le-xe)*Pe.SQRT2*.5}H[0]=ee[oe+0][0],H[0]*=H[0];for(var he=P.BLKSIZE/2-1;he>=0;--he){var je=ee[oe+0][P.BLKSIZE/2-he],ht=ee[oe+0][P.BLKSIZE/2+he];H[P.BLKSIZE/2-he]=(je*je+ht*ht)*.5}{for(var Ie=0,he=11;he<P.HBLKSIZE;he++)Ie+=H[he];J.tot_ener[G]=Ie}if(I.analysis){for(var he=0;he<P.HBLKSIZE;he++)J.pinfo.energy[se][G][he]=J.pinfo.energy_save[G][he],J.pinfo.energy_save[G][he]=H[he];J.pinfo.pe[se][G]=J.pe[G]}}function Kt(I,A,U,G,se,H,ee,oe){var J=I.internal_flags;if(se==0&&G<2&&z.fft_short(J,ee[oe],G,A,U),G==2)for(var he=P.BLKSIZE_s-1;he>=0;--he){var le=ee[oe+0][se][he],xe=ee[oe+1][se][he];ee[oe+0][se][he]=(le+xe)*Pe.SQRT2*.5,ee[oe+1][se][he]=(le-xe)*Pe.SQRT2*.5}H[se][0]=ee[oe+0][se][0],H[se][0]*=H[se][0];for(var he=P.BLKSIZE_s/2-1;he>=0;--he){var je=ee[oe+0][se][P.BLKSIZE_s/2-he],ht=ee[oe+0][se][P.BLKSIZE_s/2+he];H[se][P.BLKSIZE_s/2-he]=(je*je+ht*ht)*.5}}function cr(I,A,U,G){var se=I.internal_flags;I.athaa_loudapprox==2&&U<2&&(se.loudness_sq[A][U]=se.loudness_sq_save[U],se.loudness_sq_save[U]=_(G,se))}var Nr=[-865163e-23*2,-.00851586*2,-674764e-23*2,.0209036*2,-336639e-22*2,-.0438162*2,-154175e-22*2,.0931738*2,-552212e-22*2,-.313819*2];function Rr(I,A,U,G,se,H,ee,oe,J,he){for(var le=it([2,576]),xe=I.internal_flags,je=xe.channels_out,ht=I.mode==Dr.JOINT_STEREO?4:je,Ie=0;Ie<je;Ie++){firbuf=A[Ie];var ct=U+576-350-B+192;pe(Nr.length==(B-1)/2);for(var me=0;me<576;me++){var We,Ct;We=firbuf[ct+me+10],Ct=0;for(var Ae=0;Ae<(B-1)/2-1;Ae+=2)We+=Nr[Ae]*(firbuf[ct+me+Ae]+firbuf[ct+me+B-Ae]),Ct+=Nr[Ae+1]*(firbuf[ct+me+Ae+1]+firbuf[ct+me+B-Ae-1]);le[Ie][me]=We+Ct}se[G][Ie].en.assign(xe.en[Ie]),se[G][Ie].thm.assign(xe.thm[Ie]),ht>2&&(H[G][Ie].en.assign(xe.en[Ie+2]),H[G][Ie].thm.assign(xe.thm[Ie+2]))}for(var Ie=0;Ie<ht;Ie++){var rt=Te(12),Me=Te(12),ut=[0,0,0,0],mr=le[Ie&1],Ke=0,bt=Ie==3?xe.nsPsy.attackthre_s:xe.nsPsy.attackthre,wt=1;if(Ie==2)for(var me=0,Ae=576;Ae>0;++me,--Ae){var xr=le[0][me],ja=le[1][me];le[0][me]=xr+ja,le[1][me]=xr-ja}for(var me=0;me<3;me++)Me[me]=xe.nsPsy.last_en_subshort[Ie][me+6],pe(xe.nsPsy.last_en_subshort[Ie][me+4]>0),rt[me]=Me[me]/xe.nsPsy.last_en_subshort[Ie][me+4],ut[0]+=Me[me];for(var me=0;me<9;me++){for(var Mr=Ke+64,hr=1;Ke<Mr;Ke++)hr<Math.abs(mr[Ke])&&(hr=Math.abs(mr[Ke]));xe.nsPsy.last_en_subshort[Ie][me]=Me[me+3]=hr,ut[1+me/3]+=hr,hr>Me[me+3-2]?(pe(Me[me+3-2]>0),hr=hr/Me[me+3-2]):Me[me+3-2]>hr*10?(pe(hr>0),hr=Me[me+3-2]/(hr*10)):hr=0,rt[me+3]=hr}for(var me=0;me<3;++me){var Oa=Me[me*3+3]+Me[me*3+4]+Me[me*3+5],Va=1;Me[me*3+5]*6<Oa&&(Va*=.5,Me[me*3+4]*6<Oa&&(Va*=.5)),oe[Ie][me]=Va}if(I.analysis){for(var Ga=rt[0],me=1;me<12;me++)Ga<rt[me]&&(Ga=rt[me]);xe.pinfo.ers[G][Ie]=xe.pinfo.ers_save[Ie],xe.pinfo.ers_save[Ie]=Ga}for(var me=0;me<12;me++)J[Ie][me/3]==0&&rt[me]>bt&&(J[Ie][me/3]=me%3+1);for(var me=1;me<4;me++){var wn=ut[me-1],In=ut[me],ha=Math.max(wn,In);ha<4e4&&wn<1.7*In&&In<1.7*wn&&(me==1&&J[Ie][0]<=J[Ie][me]&&(J[Ie][0]=0),J[Ie][me]=0)}J[Ie][0]<=xe.nsPsy.lastAttacks[Ie]&&(J[Ie][0]=0),(xe.nsPsy.lastAttacks[Ie]==3||J[Ie][0]+J[Ie][1]+J[Ie][2]+J[Ie][3]!=0)&&(wt=0,J[Ie][1]!=0&&J[Ie][0]!=0&&(J[Ie][1]=0),J[Ie][2]!=0&&J[Ie][1]!=0&&(J[Ie][2]=0),J[Ie][3]!=0&&J[Ie][2]!=0&&(J[Ie][3]=0)),Ie<2?he[Ie]=wt:wt==0&&(he[0]=he[1]=0),ee[Ie]=xe.tot_ener[Ie]}}function na(I,A,U){if(U==0)for(var G=0;G<I.npart_s;G++)I.nb_s2[A][G]=I.nb_s1[A][G],I.nb_s1[A][G]=0}function ri(I,A){for(var U=0;U<I.npart_l;U++)I.nb_2[A][U]=I.nb_1[A][U],I.nb_1[A][U]=0}function Aa(I,A,U,G){var se=f.length-1,H=0,ee=U[H]+U[H+1];if(pe(ee>=0),ee>0){var oe=A[H];oe<A[H+1]&&(oe=A[H+1]),pe(I.numlines_s[H]+I.numlines_s[H+1]-1>0),ee=20*(oe*2-ee)/(ee*(I.numlines_s[H]+I.numlines_s[H+1]-1));var J=0|ee;J>se&&(J=se),G[H]=J}else G[H]=0;for(H=1;H<I.npart_s-1;H++)if(ee=U[H-1]+U[H]+U[H+1],pe(H+1<I.npart_s),pe(ee>=0),ee>0){var oe=A[H-1];oe<A[H]&&(oe=A[H]),oe<A[H+1]&&(oe=A[H+1]),pe(I.numlines_s[H-1]+I.numlines_s[H]+I.numlines_s[H+1]-1>0),ee=20*(oe*3-ee)/(ee*(I.numlines_s[H-1]+I.numlines_s[H]+I.numlines_s[H+1]-1));var J=0|ee;J>se&&(J=se),G[H]=J}else G[H]=0;if(pe(H>0),pe(H==I.npart_s-1),ee=U[H-1]+U[H],pe(ee>=0),ee>0){var oe=A[H-1];oe<A[H]&&(oe=A[H]),pe(I.numlines_s[H-1]+I.numlines_s[H]-1>0),ee=20*(oe*2-ee)/(ee*(I.numlines_s[H-1]+I.numlines_s[H]-1));var J=0|ee;J>se&&(J=se),G[H]=J}else G[H]=0;pe(H==I.npart_s-1)}function Ba(I,A,U,G,se,H){var ee=I.internal_flags,oe=new float[P.CBANDS],J=Te(P.CBANDS),he,le,xe,je=new int[P.CBANDS];for(xe=le=0;xe<ee.npart_s;++xe){var ht=0,Ie=0,ct=ee.numlines_s[xe];for(he=0;he<ct;++he,++le){var me=A[H][le];ht+=me,Ie<me&&(Ie=me)}U[xe]=ht,pe(ht>=0),oe[xe]=Ie,pe(ct>0),J[xe]=ht/ct,pe(J[xe]>=0)}for(pe(xe==ee.npart_s),pe(le==129);xe<P.CBANDS;++xe)oe[xe]=0,J[xe]=0;for(Aa(ee,oe,J,je),le=xe=0;xe<ee.npart_s;xe++){var We=ee.s3ind_s[xe][0],Ct=ee.s3ind_s[xe][1],Ae,rt,Me,ut,mr;for(Ae=je[We],rt=1,ut=ee.s3_ss[le]*U[We]*f[je[We]],++le,++We;We<=Ct;)Ae+=je[We],rt+=1,Me=ee.s3_ss[le]*U[We]*f[je[We]],ut=Y(ut,Me,We-xe),++le,++We;Ae=(1+2*Ae)/(2*rt),mr=f[Ae]*.5,ut*=mr,G[xe]=ut,ee.nb_s2[se][xe]=ee.nb_s1[se][xe],ee.nb_s1[se][xe]=ut,Me=oe[xe],Me*=ee.minval_s[xe],Me*=mr,G[xe]>Me&&(G[xe]=Me),ee.masking_lower>1&&(G[xe]*=ee.masking_lower),G[xe]>U[xe]&&(G[xe]=U[xe]),ee.masking_lower<1&&(G[xe]*=ee.masking_lower),pe(G[xe]>=0)}for(;xe<P.CBANDS;++xe)U[xe]=0,G[xe]=0}function En(I,A,U,G,se){var H=Te(P.CBANDS),ee=Te(P.CBANDS),oe=lt(P.CBANDS+2),J;tt(I,A,U,H,ee),Ve(I,H,ee,oe);var he=0;for(J=0;J<I.npart_l;J++){var le,xe,je,ht,Ie=I.s3ind[J][0],ct=I.s3ind[J][1],me=0,We=0;for(me=oe[Ie],We+=1,xe=I.s3_ll[he]*U[Ie]*f[oe[Ie]],++he,++Ie;Ie<=ct;)me+=oe[Ie],We+=1,le=I.s3_ll[he]*U[Ie]*f[oe[Ie]],ht=Y(xe,le,Ie-J),xe=ht,++he,++Ie;if(me=(1+2*me)/(2*We),je=f[me]*.5,xe*=je,I.blocktype_old[se&1]==P.SHORT_TYPE){var Ct=ce*I.nb_1[se][J];Ct>0?G[J]=Math.min(xe,Ct):G[J]=Math.min(xe,U[J]*ge)}else{var Ae=re*I.nb_2[se][J],rt=ce*I.nb_1[se][J],Ct;Ae<=0&&(Ae=xe),rt<=0&&(rt=xe),I.blocktype_old[se&1]==P.NORM_TYPE?Ct=Math.min(rt,Ae):Ct=rt,G[J]=Math.min(xe,Ct)}I.nb_2[se][J]=I.nb_1[se][J],I.nb_1[se][J]=xe,le=H[J],le*=I.minval_l[J],le*=je,G[J]>le&&(G[J]=le),I.masking_lower>1&&(G[J]*=I.masking_lower),G[J]>U[J]&&(G[J]=U[J]),I.masking_lower<1&&(G[J]*=I.masking_lower),pe(G[J]>=0)}for(;J<P.CBANDS;++J)U[J]=0,G[J]=0}function Ds(I,A){var U=I.internal_flags;I.short_blocks==Se.short_block_coupled&&!(A[0]!=0&&A[1]!=0)&&(A[0]=A[1]=0);for(var G=0;G<U.channels_out;G++)I.short_blocks==Se.short_block_dispensed&&(A[G]=1),I.short_blocks==Se.short_block_forced&&(A[G]=0)}function ks(I,A,U){for(var G=I.internal_flags,se=0;se<G.channels_out;se++){var H=P.NORM_TYPE;A[se]!=0?(pe(G.blocktype_old[se]!=P.START_TYPE),G.blocktype_old[se]==P.SHORT_TYPE&&(H=P.STOP_TYPE)):(H=P.SHORT_TYPE,G.blocktype_old[se]==P.NORM_TYPE&&(G.blocktype_old[se]=P.START_TYPE),G.blocktype_old[se]==P.STOP_TYPE&&(G.blocktype_old[se]=P.SHORT_TYPE)),U[se]=G.blocktype_old[se],G.blocktype_old[se]=H}}function Tn(I,A,U,G,se,H,ee){for(var oe=H*2,J=H>0?Math.pow(10,se):1,he,le,xe=0;xe<ee;++xe){var je=I[2][xe],ht=I[3][xe],Ie=A[0][xe],ct=A[1][xe],me=A[2][xe],We=A[3][xe];if(Ie<=1.58*ct&&ct<=1.58*Ie){var Ct=U[xe]*ht,Ae=U[xe]*je;le=Math.max(me,Math.min(We,Ct)),he=Math.max(We,Math.min(me,Ae))}else le=me,he=We;if(H>0){var rt,Me,ut=G[xe]*J;if(rt=Math.min(Math.max(Ie,ut),Math.max(ct,ut)),me=Math.max(le,ut),We=Math.max(he,ut),Me=me+We,Me>0&&rt*oe<Me){var mr=rt*oe/Me;me*=mr,We*=mr,pe(Me>0)}le=Math.min(me,le),he=Math.min(We,he)}le>je&&(le=je),he>ht&&(he=ht),A[2][xe]=le,A[3][xe]=he}}this.L3psycho_anal_vbr=function(I,A,U,G,se,H,ee,oe,J,he){var le=I.internal_flags,xe,je,ht=Te(P.HBLKSIZE),Ie=it([3,P.HBLKSIZE_s]),ct=it([2,P.BLKSIZE]),me=it([2,3,P.BLKSIZE_s]),We=it([4,P.CBANDS]),Ct=it([4,P.CBANDS]),Ae=it([4,3]),rt=.6,Me=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],ut=lt(2),mr=I.mode==Dr.JOINT_STEREO?4:le.channels_out;Rr(I,A,U,G,se,H,J,Ae,Me,ut),Ds(I,ut);{for(var Ke=0;Ke<mr;Ke++){var bt=Ke&1;xe=ct,lr(I,A,U,Ke,G,ht,xe,bt),cr(I,G,Ke,ht),ut[bt]!=0?En(le,ht,We[Ke],Ct[Ke],Ke):ri(le,Ke)}ut[0]+ut[1]==2&&I.mode==Dr.JOINT_STEREO&&Tn(We,Ct,le.mld_cb_l,le.ATH.cb_l,I.ATHlower*le.ATH.adjust,I.msfix,le.npart_l);for(var Ke=0;Ke<mr;Ke++){var bt=Ke&1;ut[bt]!=0&&v(le,We[Ke],Ct[Ke],Ke)}}{for(var wt=0;wt<3;wt++){for(var Ke=0;Ke<mr;++Ke){var bt=Ke&1;ut[bt]!=0?na(le,Ke,wt):(je=me,Kt(I,A,U,Ke,wt,Ie,je,bt),Ba(I,Ie,We[Ke],Ct[Ke],Ke,wt))}ut[0]+ut[1]==0&&I.mode==Dr.JOINT_STEREO&&Tn(We,Ct,le.mld_cb_s,le.ATH.cb_s,I.ATHlower*le.ATH.adjust,I.msfix,le.npart_s);for(var Ke=0;Ke<mr;++Ke){var bt=Ke&1;ut[bt]==0&&h(le,We[Ke],Ct[Ke],Ke,wt)}}for(var Ke=0;Ke<mr;Ke++){var bt=Ke&1;if(ut[bt]==0)for(var xr=0;xr<P.SBMAX_s;xr++){for(var ja=Te(3),wt=0;wt<3;wt++){var Mr=le.thm[Ke].s[xr][wt];if(Mr*=$,Me[Ke][wt]>=2||Me[Ke][wt+1]==1){var hr=wt!=0?wt-1:2,Oa=De(le.thm[Ke].s[xr][hr],Mr,fe*rt);Mr=Math.min(Mr,Oa)}else if(Me[Ke][wt]==1){var hr=wt!=0?wt-1:2,Oa=De(le.thm[Ke].s[xr][hr],Mr,ge*rt);Mr=Math.min(Mr,Oa)}else if(wt!=0&&Me[Ke][wt-1]==3||wt==0&&le.nsPsy.lastAttacks[Ke]==3){var hr=wt!=2?wt+1:0,Oa=De(le.thm[Ke].s[xr][hr],Mr,ge*rt);Mr=Math.min(Mr,Oa)}Mr*=Ae[Ke][wt],ja[wt]=Mr}for(var wt=0;wt<3;wt++)le.thm[Ke].s[xr][wt]=ja[wt]}}}for(var Ke=0;Ke<mr;Ke++)le.nsPsy.lastAttacks[Ke]=Me[Ke][2];ks(I,ut,he);for(var Ke=0;Ke<mr;Ke++){var Va,Ga,wn,In;Ke>1?(Va=oe,Ga=-2,wn=P.NORM_TYPE,(he[0]==P.SHORT_TYPE||he[1]==P.SHORT_TYPE)&&(wn=P.SHORT_TYPE),In=H[G][Ke-2]):(Va=ee,Ga=0,wn=he[Ke],In=se[G][Ke]),wn==P.SHORT_TYPE?Va[Ga+Ke]=$e(In,le.masking_lower):Va[Ga+Ke]=yt(In,le.masking_lower),I.analysis&&(le.pinfo.pe[G][Ke]=Va[Ga+Ke])}return 0};function ba(I,A){var U=I,G;return U>=0?G=-U*27:G=U*A,G<=-72?0:Math.exp(G*V)}function ts(I){var A=0,U=0;{var G=0,se,H;for(G=0;ba(G,I)>1e-20;G-=1);for(se=G,H=0;Math.abs(H-se)>1e-12;)G=(H+se)/2,ba(G,I)>0?H=G:se=G;A=se}{var G=0,se,H;for(G=0;ba(G,I)>1e-20;G+=1);for(se=0,H=G;Math.abs(H-se)>1e-12;)G=(H+se)/2,ba(G,I)>0?se=G:H=G;U=H}{var ee=0,oe=1e3,J;for(J=0;J<=oe;++J){var G=A+J*(U-A)/oe,he=ba(G,I);ee+=he}{var le=(oe+1)/(ee*(U-A));return le}}}function $l(I){var A,U,G,se;return A=I,A>=0?A*=3:A*=1.5,A>=.5&&A<=2.5?(se=A-.5,U=8*(se*se-2*se)):U=0,A+=.474,G=15.811389+7.5*A-17.5*Math.sqrt(1+A*A),G<=-60?0:(A=Math.exp((U+G)*V),A/=.6609193,A)}function rs(I){return I<0&&(I=0),I=I*.001,13*Math.atan(.76*I)+3.5*Math.atan(I*I/(7.5*7.5))}function Pg(I,A,U,G,se,H,ee,oe,J,he,le,xe){var je=Te(P.CBANDS+1),ht=oe/(xe>15?2*576:2*192),Ie=lt(P.HBLKSIZE),ct;oe/=J;var me=0,We=0;for(ct=0;ct<P.CBANDS;ct++){var Ct,Ae;for(Ct=rs(oe*me),je[ct]=oe*me,Ae=me;rs(oe*Ae)-Ct<ye&&Ae<=J/2;Ae++);for(I[ct]=Ae-me,We=ct+1;me<Ae;)pe(me<P.HBLKSIZE),Ie[me++]=ct;if(me>J/2){me=J/2,++ct;break}}pe(ct<P.CBANDS),je[ct]=oe*me;for(var rt=0;rt<xe;rt++){var Me,ut,mr,Ke,bt;mr=he[rt],Ke=he[rt+1],Me=0|Math.floor(.5+le*(mr-.5)),Me<0&&(Me=0),ut=0|Math.floor(.5+le*(Ke-.5)),ut>J/2&&(ut=J/2),U[rt]=(Ie[Me]+Ie[ut])/2,A[rt]=Ie[ut];var wt=ht*Ke;ee[rt]=(wt-je[A[rt]])/(je[A[rt]+1]-je[A[rt]]),ee[rt]<0?ee[rt]=0:ee[rt]>1&&(ee[rt]=1),bt=rs(oe*he[rt]*le),bt=Math.min(bt,15.5)/15.5,H[rt]=Math.pow(10,1.25*(1-Math.cos(Math.PI*bt))-2.5)}me=0;for(var xr=0;xr<We;xr++){var ja=I[xr],Ct,Mr;Ct=rs(oe*me),Mr=rs(oe*(me+ja-1)),G[xr]=.5*(Ct+Mr),Ct=rs(oe*(me-.5)),Mr=rs(oe*(me+ja-.5)),se[xr]=Mr-Ct,me+=ja}return We}function Cg(I,A,U,G,se,H){var ee=it([P.CBANDS,P.CBANDS]),oe,J=0;if(H)for(var he=0;he<A;he++)for(oe=0;oe<A;oe++){var le=$l(U[he]-U[oe])*G[oe];ee[he][oe]=le*se[he]}else for(oe=0;oe<A;oe++)for(var xe=15+Math.min(21/U[oe],12),je=ts(xe),he=0;he<A;he++){var le=je*ba(U[he]-U[oe],xe)*G[oe];ee[he][oe]=le*se[he]}for(var he=0;he<A;he++){for(oe=0;oe<A&&!(ee[he][oe]>0);oe++);for(I[he][0]=oe,oe=A-1;oe>0&&!(ee[he][oe]>0);oe--);I[he][1]=oe,J+=I[he][1]-I[he][0]+1}for(var ht=Te(J),Ie=0,he=0;he<A;he++)for(oe=I[he][0];oe<=I[he][1];oe++)ht[Ie++]=ee[he][oe];return ht}function Rg(I){var A=rs(I);return A=Math.min(A,15.5)/15.5,Math.pow(10,1.25*(1-Math.cos(Math.PI*A))-2.5)}this.psymodel_init=function(I){var A=I.internal_flags,U,G=!0,se=13,H=24,ee=0,oe=0,J=-8.25,he=-4.5,le=Te(P.CBANDS),xe=Te(P.CBANDS),je=Te(P.CBANDS),ht=I.out_samplerate;switch(I.experimentalZ){default:case 0:G=!0;break;case 1:G=!(I.VBR==ue.vbr_mtrh||I.VBR==ue.vbr_mt);break;case 2:G=!1;break;case 3:se=8,ee=-1.75,oe=-.0125,J=-8.25,he=-2.25;break}for(A.ms_ener_ratio_old=.25,A.blocktype_old[0]=A.blocktype_old[1]=P.NORM_TYPE,U=0;U<4;++U){for(var me=0;me<P.CBANDS;++me)A.nb_1[U][me]=1e20,A.nb_2[U][me]=1e20,A.nb_s1[U][me]=A.nb_s2[U][me]=1;for(var Ie=0;Ie<P.SBMAX_l;Ie++)A.en[U].l[Ie]=1e20,A.thm[U].l[Ie]=1e20;for(var me=0;me<3;++me){for(var Ie=0;Ie<P.SBMAX_s;Ie++)A.en[U].s[Ie][me]=1e20,A.thm[U].s[Ie][me]=1e20;A.nsPsy.lastAttacks[U]=0}for(var me=0;me<9;me++)A.nsPsy.last_en_subshort[U][me]=10}for(A.loudness_sq_save[0]=A.loudness_sq_save[1]=0,A.npart_l=Pg(A.numlines_l,A.bo_l,A.bm_l,le,xe,A.mld_l,A.PSY.bo_l_weight,ht,P.BLKSIZE,A.scalefac_band.l,P.BLKSIZE/(2*576),P.SBMAX_l),pe(A.npart_l<P.CBANDS),U=0;U<A.npart_l;U++){var ct=ee;le[U]>=se&&(ct=oe*(le[U]-se)/(H-se)+ee*(H-le[U])/(H-se)),je[U]=Math.pow(10,ct/10),A.numlines_l[U]>0?A.rnumlines_l[U]=1/A.numlines_l[U]:A.rnumlines_l[U]=0}A.s3_ll=Cg(A.s3ind,A.npart_l,le,xe,je,G);var me=0;for(U=0;U<A.npart_l;U++){var We;We=Ne.MAX_VALUE;for(var Ct=0;Ct<A.numlines_l[U];Ct++,me++){var Ae=ht*me/(1e3*P.BLKSIZE),rt;rt=this.ATHformula(Ae*1e3,I)-20,rt=Math.pow(10,.1*rt),rt*=A.numlines_l[U],We>rt&&(We=rt)}A.ATH.cb_l[U]=We,We=-20+le[U]*20/10,We>6&&(We=100),We<-15&&(We=-15),We-=8,A.minval_l[U]=Math.pow(10,We/10)*A.numlines_l[U]}for(A.npart_s=Pg(A.numlines_s,A.bo_s,A.bm_s,le,xe,A.mld_s,A.PSY.bo_s_weight,ht,P.BLKSIZE_s,A.scalefac_band.s,P.BLKSIZE_s/(2*192),P.SBMAX_s),pe(A.npart_s<P.CBANDS),me=0,U=0;U<A.npart_s;U++){var We,ct=J;le[U]>=se&&(ct=he*(le[U]-se)/(H-se)+J*(H-le[U])/(H-se)),je[U]=Math.pow(10,ct/10),We=Ne.MAX_VALUE;for(var Ct=0;Ct<A.numlines_s[U];Ct++,me++){var Ae=ht*me/(1e3*P.BLKSIZE_s),rt;rt=this.ATHformula(Ae*1e3,I)-20,rt=Math.pow(10,.1*rt),rt*=A.numlines_s[U],We>rt&&(We=rt)}A.ATH.cb_s[U]=We,We=-7+le[U]*7/12,le[U]>12&&(We*=1+Math.log(1+We)*3.1),le[U]<12&&(We*=1+Math.log(1-We)*2.3),We<-15&&(We=-15),We-=8,A.minval_s[U]=Math.pow(10,We/10)*A.numlines_s[U]}A.s3_ss=Cg(A.s3ind_s,A.npart_s,le,xe,je,G),y(),z.init_fft(A),A.decay=Math.exp(-1*te/(He*ht/192));{var Me;Me=L,(I.exp_nspsytune&2)!=0&&(Me=1),Math.abs(I.msfix)>0&&(Me=I.msfix),I.msfix=Me;for(var ut=0;ut<A.npart_l;ut++)A.s3ind[ut][1]>A.npart_l-1&&(A.s3ind[ut][1]=A.npart_l-1)}var mr=576*A.mode_gr/ht;if(A.ATH.decay=Math.pow(10,-12/10*mr),A.ATH.adjust=.01,A.ATH.adjustLimit=1,pe(A.bo_l[P.SBMAX_l-1]<=A.npart_l),pe(A.bo_s[P.SBMAX_s-1]<=A.npart_s),I.ATHtype!=-1){var Ae,Ke=I.out_samplerate/P.BLKSIZE,bt=0;for(Ae=0,U=0;U<P.BLKSIZE/2;++U)Ae+=Ke,A.ATH.eql_w[U]=1/Math.pow(10,this.ATHformula(Ae,I)/10),bt+=A.ATH.eql_w[U];for(bt=1/bt,U=P.BLKSIZE/2;--U>=0;)A.ATH.eql_w[U]*=bt}{for(var ut=me=0;ut<A.npart_s;++ut)for(U=0;U<A.numlines_s[ut];++U)++me;pe(me==129);for(var ut=me=0;ut<A.npart_l;++ut)for(U=0;U<A.numlines_l[ut];++U)++me;pe(me==513)}for(me=0,U=0;U<A.npart_l;U++){var Ae=ht*(me+A.numlines_l[U]/2)/(1*P.BLKSIZE);A.mld_cb_l[U]=Rg(Ae),me+=A.numlines_l[U]}for(;U<P.CBANDS;++U)A.mld_cb_l[U]=1;for(me=0,U=0;U<A.npart_s;U++){var Ae=ht*(me+A.numlines_s[U]/2)/(1*P.BLKSIZE_s);A.mld_cb_s[U]=Rg(Ae),me+=A.numlines_s[U]}for(;U<P.CBANDS;++U)A.mld_cb_s[U]=1;return 0};function Io(I,A){I<-.3&&(I=3410),I/=1e3,I=Math.max(.1,I);var U=3.64*Math.pow(I,-.8)-6.8*Math.exp(-.6*Math.pow(I-3.4,2))+6*Math.exp(-.15*Math.pow(I-8.7,2))+(.6+.04*A)*.001*Math.pow(I,4);return U}this.ATHformula=function(I,A){var U;switch(A.ATHtype){case 0:U=Io(I,9);break;case 1:U=Io(I,-1);break;case 2:U=Io(I,0);break;case 3:U=Io(I,1)+6;break;case 4:U=Io(I,A.ATHcurve);break;default:U=Io(I,0);break}return U}}var ra=qr;function aa(z){var te=z;this.ordinal=function(){return te}}aa.STEREO=new aa(0),aa.JOINT_STEREO=new aa(1),aa.DUAL_CHANNEL=new aa(2),aa.MONO=new aa(3),aa.NOT_SET=new aa(4);var fa=aa;function Dt(){this.class_id=0,this.num_samples=0,this.num_channels=0,this.in_samplerate=0,this.out_samplerate=0,this.scale=0,this.scale_left=0,this.scale_right=0,this.analysis=!1,this.bWriteVbrTag=!1,this.decode_only=!1,this.quality=0,this.mode=fa.STEREO,this.force_ms=!1,this.free_format=!1,this.findReplayGain=!1,this.decode_on_the_fly=!1,this.write_id3tag_automatic=!1,this.brate=0,this.compression_ratio=0,this.copyright=0,this.original=0,this.extension=0,this.emphasis=0,this.error_protection=0,this.strict_ISO=!1,this.disable_reservoir=!1,this.quant_comp=0,this.quant_comp_short=0,this.experimentalY=!1,this.experimentalZ=0,this.exp_nspsytune=0,this.preset=0,this.VBR=null,this.VBR_q_frac=0,this.VBR_q=0,this.VBR_mean_bitrate_kbps=0,this.VBR_min_bitrate_kbps=0,this.VBR_max_bitrate_kbps=0,this.VBR_hard_min=0,this.lowpassfreq=0,this.highpassfreq=0,this.lowpasswidth=0,this.highpasswidth=0,this.maskingadjust=0,this.maskingadjust_short=0,this.ATHonly=!1,this.ATHshort=!1,this.noATH=!1,this.ATHtype=0,this.ATHcurve=0,this.ATHlower=0,this.athaa_type=0,this.athaa_loudapprox=0,this.athaa_sensitivity=0,this.short_blocks=null,this.useTemporal=!1,this.interChRatio=0,this.msfix=0,this.tune=!1,this.tune_value_a=0,this.version=0,this.encoder_delay=0,this.encoder_padding=0,this.framesize=0,this.frameNum=0,this.lame_allocated_gfp=0,this.internal_flags=null}var Bs=Dt,pm={};pm.SFBMAX=P.SBMAX_s*3;var Ei=pm,jl=C.new_float,Ti=C.new_int;function dp(){this.xr=jl(576),this.l3_enc=Ti(576),this.scalefac=Ti(Ei.SFBMAX),this.xrpow_max=0,this.part2_3_length=0,this.big_values=0,this.count1=0,this.global_gain=0,this.scalefac_compress=0,this.block_type=0,this.mixed_block_flag=0,this.table_select=Ti(3),this.subblock_gain=Ti(3+1),this.region0_count=0,this.region1_count=0,this.preflag=0,this.scalefac_scale=0,this.count1table_select=0,this.part2_length=0,this.sfb_lmax=0,this.sfb_smin=0,this.psy_lmax=0,this.sfbmax=0,this.psymax=0,this.sfbdivide=0,this.width=Ti(Ei.SFBMAX),this.window=Ti(Ei.SFBMAX),this.count1bits=0,this.sfb_partition_table=null,this.slen=Ti(4),this.max_nonzero_coeff=0;var z=this;function te(re){return new Int32Array(re)}function ce(re){return new Float32Array(re)}this.assign=function(re){z.xr=ce(re.xr),z.l3_enc=te(re.l3_enc),z.scalefac=te(re.scalefac),z.xrpow_max=re.xrpow_max,z.part2_3_length=re.part2_3_length,z.big_values=re.big_values,z.count1=re.count1,z.global_gain=re.global_gain,z.scalefac_compress=re.scalefac_compress,z.block_type=re.block_type,z.mixed_block_flag=re.mixed_block_flag,z.table_select=te(re.table_select),z.subblock_gain=te(re.subblock_gain),z.region0_count=re.region0_count,z.region1_count=re.region1_count,z.preflag=re.preflag,z.scalefac_scale=re.scalefac_scale,z.count1table_select=re.count1table_select,z.part2_length=re.part2_length,z.sfb_lmax=re.sfb_lmax,z.sfb_smin=re.sfb_smin,z.psy_lmax=re.psy_lmax,z.sfbmax=re.sfbmax,z.psymax=re.psymax,z.sfbdivide=re.sfbdivide,z.width=te(re.width),z.window=te(re.window),z.count1bits=re.count1bits,z.sfb_partition_table=re.sfb_partition_table.slice(0),z.slen=te(re.slen),z.max_nonzero_coeff=re.max_nonzero_coeff}}var fm=dp,mg=C.new_int;function y3(){this.tt=[[null,null],[null,null]],this.main_data_begin=0,this.private_bits=0,this.resvDrain_pre=0,this.resvDrain_post=0,this.scfsi=[mg(4),mg(4)];for(var z=0;z<2;z++)for(var te=0;te<2;te++)this.tt[z][te]=new fm}var x3=y3,hm=C.System,ym=C.new_int;function g3(z,te,ce,re){this.l=ym(1+P.SBMAX_l),this.s=ym(1+P.SBMAX_s),this.psfb21=ym(1+P.PSFB21),this.psfb12=ym(1+P.PSFB12);var Ee=this.l,ie=this.s;arguments.length==4&&(this.arrL=arguments[0],this.arrS=arguments[1],this.arr21=arguments[2],this.arr12=arguments[3],hm.arraycopy(this.arrL,0,Ee,0,Math.min(this.arrL.length,this.l.length)),hm.arraycopy(this.arrS,0,ie,0,Math.min(this.arrS.length,this.s.length)),hm.arraycopy(this.arr21,0,this.psfb21,0,Math.min(this.arr21.length,this.psfb21.length)),hm.arraycopy(this.arr12,0,this.psfb12,0,Math.min(this.arr12.length,this.psfb12.length)))}var Zn=g3,up=C.new_float,v3=C.new_float_n,_3=C.new_int;function b3(){this.last_en_subshort=v3([4,9]),this.lastAttacks=_3(4),this.pefirbuf=up(19),this.longfact=up(P.SBMAX_l),this.shortfact=up(P.SBMAX_s),this.attackthre=0,this.attackthre_s=0}var S3=b3;function N3(){this.sum=0,this.seen=0,this.want=0,this.pos=0,this.size=0,this.bag=null,this.nVbrNumFrames=0,this.nBytesWritten=0,this.TotalFrameSize=0}var P3=N3,C3=C.new_byte,R3=C.new_double,cn=C.new_float,Os=C.new_float_n,Rn=C.new_int,xm=C.new_int_n;wi.MFSIZE=3*1152+P.ENCDELAY-P.MDCTDELAY,wi.MAX_HEADER_BUF=256,wi.MAX_BITS_PER_CHANNEL=4095,wi.MAX_BITS_PER_GRANULE=7680,wi.BPC=320;function wi(){var z=40;this.Class_ID=0,this.lame_encode_frame_init=0,this.iteration_init_init=0,this.fill_buffer_resample_init=0,this.mfbuf=Os([2,wi.MFSIZE]),this.mode_gr=0,this.channels_in=0,this.channels_out=0,this.resample_ratio=0,this.mf_samples_to_encode=0,this.mf_size=0,this.VBR_min_bitrate=0,this.VBR_max_bitrate=0,this.bitrate_index=0,this.samplerate_index=0,this.mode_ext=0,this.lowpass1=0,this.lowpass2=0,this.highpass1=0,this.highpass2=0,this.noise_shaping=0,this.noise_shaping_amp=0,this.substep_shaping=0,this.psymodel=0,this.noise_shaping_stop=0,this.subblock_gain=0,this.use_best_huffman=0,this.full_outer_loop=0,this.l3_side=new x3,this.ms_ratio=cn(2),this.padding=0,this.frac_SpF=0,this.slot_lag=0,this.tag_spec=null,this.nMusicCRC=0,this.OldValue=Rn(2),this.CurrentStep=Rn(2),this.masking_lower=0,this.bv_scf=Rn(576),this.pseudohalf=Rn(Ei.SFBMAX),this.sfb21_extra=!1,this.inbuf_old=new Array(2),this.blackfilt=new Array(2*wi.BPC+1),this.itime=R3(2),this.sideinfo_len=0,this.sb_sample=Os([2,2,18,P.SBLIMIT]),this.amp_filter=cn(32);function te(){this.write_timing=0,this.ptr=0,this.buf=C3(z)}this.header=new Array(wi.MAX_HEADER_BUF),this.h_ptr=0,this.w_ptr=0,this.ancillary_flag=0,this.ResvSize=0,this.ResvMax=0,this.scalefac_band=new Zn,this.minval_l=cn(P.CBANDS),this.minval_s=cn(P.CBANDS),this.nb_1=Os([4,P.CBANDS]),this.nb_2=Os([4,P.CBANDS]),this.nb_s1=Os([4,P.CBANDS]),this.nb_s2=Os([4,P.CBANDS]),this.s3_ss=null,this.s3_ll=null,this.decay=0,this.thm=new Array(4),this.en=new Array(4),this.tot_ener=cn(4),this.loudness_sq=Os([2,2]),this.loudness_sq_save=cn(2),this.mld_l=cn(P.SBMAX_l),this.mld_s=cn(P.SBMAX_s),this.bm_l=Rn(P.SBMAX_l),this.bo_l=Rn(P.SBMAX_l),this.bm_s=Rn(P.SBMAX_s),this.bo_s=Rn(P.SBMAX_s),this.npart_l=0,this.npart_s=0,this.s3ind=xm([P.CBANDS,2]),this.s3ind_s=xm([P.CBANDS,2]),this.numlines_s=Rn(P.CBANDS),this.numlines_l=Rn(P.CBANDS),this.rnumlines_l=cn(P.CBANDS),this.mld_cb_l=cn(P.CBANDS),this.mld_cb_s=cn(P.CBANDS),this.numlines_s_num1=0,this.numlines_l_num1=0,this.pe=cn(4),this.ms_ratio_s_old=0,this.ms_ratio_l_old=0,this.ms_ener_ratio_old=0,this.blocktype_old=Rn(2),this.nsPsy=new S3,this.VBR_seek_table=new P3,this.ATH=null,this.PSY=null,this.nogap_total=0,this.nogap_current=0,this.decode_on_the_fly=!0,this.findReplayGain=!0,this.findPeakSample=!0,this.PeakSample=0,this.RadioGain=0,this.AudiophileGain=0,this.rgdata=null,this.noclipGainChange=0,this.noclipScale=0,this.bitrate_stereoMode_Hist=xm([16,4+1]),this.bitrate_blockType_Hist=xm([16,4+1+1]),this.pinfo=null,this.hip=null,this.in_buffer_nsamples=0,this.in_buffer_0=null,this.in_buffer_1=null,this.iteration_loop=null;for(var ce=0;ce<this.en.length;ce++)this.en[ce]=new Cr;for(var ce=0;ce<this.thm.length;ce++)this.thm[ce]=new Cr;for(var ce=0;ce<this.header.length;ce++)this.header[ce]=new te}var rr=wi,zs=C.new_float;function E3(){this.useAdjust=0,this.aaSensitivityP=0,this.adjust=0,this.adjustLimit=0,this.decay=0,this.floor=0,this.l=zs(P.SBMAX_l),this.s=zs(P.SBMAX_s),this.psfb21=zs(P.PSFB21),this.psfb12=zs(P.PSFB12),this.cb_l=zs(P.CBANDS),this.cb_s=zs(P.CBANDS),this.eql_w=zs(P.BLKSIZE/2)}var T3=E3,Ma=C.System,dg=C.Arrays;fr.STEPS_per_dB=100,fr.MAX_dB=120,fr.GAIN_NOT_ENOUGH_SAMPLES=-24601,fr.GAIN_ANALYSIS_ERROR=0,fr.GAIN_ANALYSIS_OK=1,fr.INIT_GAIN_ANALYSIS_ERROR=0,fr.INIT_GAIN_ANALYSIS_OK=1,fr.YULE_ORDER=10,fr.MAX_ORDER=fr.YULE_ORDER,fr.MAX_SAMP_FREQ=48e3,fr.RMS_WINDOW_TIME_NUMERATOR=1,fr.RMS_WINDOW_TIME_DENOMINATOR=20,fr.MAX_SAMPLES_PER_WINDOW=fr.MAX_SAMP_FREQ*fr.RMS_WINDOW_TIME_NUMERATOR/fr.RMS_WINDOW_TIME_DENOMINATOR+1;function fr(){var z=64.82,te=fr.YULE_ORDER,ce=.95,re=fr.MAX_SAMP_FREQ,Ee=fr.RMS_WINDOW_TIME_NUMERATOR,ie=fr.RMS_WINDOW_TIME_DENOMINATOR,ye=fr.MAX_SAMPLES_PER_WINDOW,ze=[[.038575994352,-3.84664617118067,-.02160367184185,7.81501653005538,-.00123395316851,-11.34170355132042,-9291677959e-14,13.05504219327545,-.01655260341619,-12.28759895145294,.02161526843274,9.4829380631979,-.02074045215285,-5.87257861775999,.00594298065125,2.75465861874613,.00306428023191,-.86984376593551,.00012025322027,.13919314567432,.00288463683916],[.0541865640643,-3.47845948550071,-.02911007808948,6.36317777566148,-.00848709379851,-8.54751527471874,-.00851165645469,9.4769360780128,-.00834990904936,-8.81498681370155,.02245293253339,6.85401540936998,-.02596338512915,-4.39470996079559,.01624864962975,2.19611684890774,-.00240879051584,-.75104302451432,.00674613682247,.13149317958808,-.00187763777362],[.15457299681924,-2.37898834973084,-.09331049056315,2.84868151156327,-.06247880153653,-2.64577170229825,.02163541888798,2.23697657451713,-.05588393329856,-1.67148153367602,.04781476674921,1.00595954808547,.00222312597743,-.45953458054983,.03174092540049,.16378164858596,-.01390589421898,-.05032077717131,.00651420667831,.0234789740702,-.00881362733839],[.30296907319327,-1.61273165137247,-.22613988682123,1.0797749225997,-.08587323730772,-.2565625775407,.03282930172664,-.1627671912044,-.00915702933434,-.22638893773906,-.02364141202522,.39120800788284,-.00584456039913,-.22138138954925,.06276101321749,.04500235387352,-828086748e-14,.02005851806501,.00205861885564,.00302439095741,-.02950134983287],[.33642304856132,-1.49858979367799,-.2557224142557,.87350271418188,-.11828570177555,.12205022308084,.11921148675203,-.80774944671438,-.07834489609479,.47854794562326,-.0046997791438,-.12453458140019,-.0058950022444,-.04067510197014,.05724228140351,.08333755284107,.00832043980773,-.04237348025746,-.0163538138454,.02977207319925,-.0176017656815],[.4491525660845,-.62820619233671,-.14351757464547,.29661783706366,-.22784394429749,-.372563729424,-.01419140100551,.00213767857124,.04078262797139,-.42029820170918,-.12398163381748,.22199650564824,.04097565135648,.00613424350682,.10478503600251,.06747620744683,-.01863887810927,.05784820375801,-.03193428438915,.03222754072173,.00541907748707],[.56619470757641,-1.04800335126349,-.75464456939302,.29156311971249,.1624213774223,-.26806001042947,.16744243493672,.00819999645858,-.18901604199609,.45054734505008,.3093178284183,-.33032403314006,-.27562961986224,.0673936833311,.00647310677246,-.04784254229033,.08647503780351,.01639907836189,-.0378898455484,.01807364323573,-.00588215443421],[.58100494960553,-.51035327095184,-.53174909058578,-.31863563325245,-.14289799034253,-.20256413484477,.17520704835522,.1472815413433,.02377945217615,.38952639978999,.15558449135573,-.23313271880868,-.25344790059353,-.05246019024463,.01628462406333,-.02505961724053,.06920467763959,.02442357316099,-.03721611395801,.01818801111503,-.00749618797172],[.53648789255105,-.2504987195602,-.42163034350696,-.43193942311114,-.00275953611929,-.03424681017675,.04267842219415,-.04678328784242,-.10214864179676,.26408300200955,.14590772289388,.15113130533216,-.02459864859345,-.17556493366449,-.11202315195388,-.18823009262115,-.04060034127,.05477720428674,.0478866554818,.0470440968812,-.02217936801134]],He=[[.98621192462708,-1.97223372919527,-1.97242384925416,.97261396931306,.98621192462708],[.98500175787242,-1.96977855582618,-1.97000351574484,.9702284756635,.98500175787242],[.97938932735214,-1.95835380975398,-1.95877865470428,.95920349965459,.97938932735214],[.97531843204928,-1.95002759149878,-1.95063686409857,.95124613669835,.97531843204928],[.97316523498161,-1.94561023566527,-1.94633046996323,.94705070426118,.97316523498161],[.96454515552826,-1.92783286977036,-1.92909031105652,.93034775234268,.96454515552826],[.96009142950541,-1.91858953033784,-1.92018285901082,.92177618768381,.96009142950541],[.95856916599601,-1.9154210807478,-1.91713833199203,.91885558323625,.95856916599601],[.94597685600279,-1.88903307939452,-1.89195371200558,.89487434461664,.94597685600279]];function $(m,B,V,k,_,g){for(;_--!=0;)V[k]=1e-10+m[B+0]*g[0]-V[k-1]*g[1]+m[B-1]*g[2]-V[k-2]*g[3]+m[B-2]*g[4]-V[k-3]*g[5]+m[B-3]*g[6]-V[k-4]*g[7]+m[B-4]*g[8]-V[k-5]*g[9]+m[B-5]*g[10]-V[k-6]*g[11]+m[B-6]*g[12]-V[k-7]*g[13]+m[B-7]*g[14]-V[k-8]*g[15]+m[B-8]*g[16]-V[k-9]*g[17]+m[B-9]*g[18]-V[k-10]*g[19]+m[B-10]*g[20],++k,++B}function fe(m,B,V,k,_,g){for(;_--!=0;)V[k]=m[B+0]*g[0]-V[k-1]*g[1]+m[B-1]*g[2]-V[k-2]*g[3]+m[B-2]*g[4],++k,++B}function ge(m,B){for(var V=0;V<MAX_ORDER;V++)m.linprebuf[V]=m.lstepbuf[V]=m.loutbuf[V]=m.rinprebuf[V]=m.rstepbuf[V]=m.routbuf[V]=0;switch(0|B){case 48e3:m.reqindex=0;break;case 44100:m.reqindex=1;break;case 32e3:m.reqindex=2;break;case 24e3:m.reqindex=3;break;case 22050:m.reqindex=4;break;case 16e3:m.reqindex=5;break;case 12e3:m.reqindex=6;break;case 11025:m.reqindex=7;break;case 8e3:m.reqindex=8;break;default:return INIT_GAIN_ANALYSIS_ERROR}return m.sampleWindow=0|(B*Ee+ie-1)/ie,m.lsum=0,m.rsum=0,m.totsamp=0,dg.ill(m.A,0),INIT_GAIN_ANALYSIS_OK}this.InitGainAnalysis=function(m,B){return ge(m,B)!=INIT_GAIN_ANALYSIS_OK?INIT_GAIN_ANALYSIS_ERROR:(m.linpre=MAX_ORDER,m.rinpre=MAX_ORDER,m.lstep=MAX_ORDER,m.rstep=MAX_ORDER,m.lout=MAX_ORDER,m.rout=MAX_ORDER,dg.fill(m.B,0),INIT_GAIN_ANALYSIS_OK)};function L(m){return m*m}this.AnalyzeSamples=function(m,B,V,k,_,g,D){var K,w,u,F,R,f,y;if(g==0)return GAIN_ANALYSIS_OK;switch(y=0,R=g,D){case 1:k=B,_=V;break;case 2:break;default:return GAIN_ANALYSIS_ERROR}for(g<MAX_ORDER?(Ma.arraycopy(B,V,m.linprebuf,MAX_ORDER,g),Ma.arraycopy(k,_,m.rinprebuf,MAX_ORDER,g)):(Ma.arraycopy(B,V,m.linprebuf,MAX_ORDER,MAX_ORDER),Ma.arraycopy(k,_,m.rinprebuf,MAX_ORDER,MAX_ORDER));R>0;){f=R>m.sampleWindow-m.totsamp?m.sampleWindow-m.totsamp:R,y<MAX_ORDER?(K=m.linpre+y,w=m.linprebuf,u=m.rinpre+y,F=m.rinprebuf,f>MAX_ORDER-y&&(f=MAX_ORDER-y)):(K=V+y,w=B,u=_+y,F=k),$(w,K,m.lstepbuf,m.lstep+m.totsamp,f,ze[m.reqindex]),$(F,u,m.rstepbuf,m.rstep+m.totsamp,f,ze[m.reqindex]),fe(m.lstepbuf,m.lstep+m.totsamp,m.loutbuf,m.lout+m.totsamp,f,He[m.reqindex]),fe(m.rstepbuf,m.rstep+m.totsamp,m.routbuf,m.rout+m.totsamp,f,He[m.reqindex]),K=m.lout+m.totsamp,w=m.loutbuf,u=m.rout+m.totsamp,F=m.routbuf;for(var b=f%8;b--!=0;)m.lsum+=L(w[K++]),m.rsum+=L(F[u++]);for(b=f/8;b--!=0;)m.lsum+=L(w[K+0])+L(w[K+1])+L(w[K+2])+L(w[K+3])+L(w[K+4])+L(w[K+5])+L(w[K+6])+L(w[K+7]),K+=8,m.rsum+=L(F[u+0])+L(F[u+1])+L(F[u+2])+L(F[u+3])+L(F[u+4])+L(F[u+5])+L(F[u+6])+L(F[u+7]),u+=8;if(R-=f,y+=f,m.totsamp+=f,m.totsamp==m.sampleWindow){var d=fr.STEPS_per_dB*10*Math.log10((m.lsum+m.rsum)/m.totsamp*.5+1e-37),x=d<=0?0:0|d;x>=m.A.length&&(x=m.A.length-1),m.A[x]++,m.lsum=m.rsum=0,Ma.arraycopy(m.loutbuf,m.totsamp,m.loutbuf,0,MAX_ORDER),Ma.arraycopy(m.routbuf,m.totsamp,m.routbuf,0,MAX_ORDER),Ma.arraycopy(m.lstepbuf,m.totsamp,m.lstepbuf,0,MAX_ORDER),Ma.arraycopy(m.rstepbuf,m.totsamp,m.rstepbuf,0,MAX_ORDER),m.totsamp=0}if(m.totsamp>m.sampleWindow)return GAIN_ANALYSIS_ERROR}return g<MAX_ORDER?(Ma.arraycopy(m.linprebuf,g,m.linprebuf,0,MAX_ORDER-g),Ma.arraycopy(m.rinprebuf,g,m.rinprebuf,0,MAX_ORDER-g),Ma.arraycopy(B,V,m.linprebuf,MAX_ORDER-g,g),Ma.arraycopy(k,_,m.rinprebuf,MAX_ORDER-g,g)):(Ma.arraycopy(B,V+g-MAX_ORDER,m.linprebuf,0,MAX_ORDER),Ma.arraycopy(k,_+g-MAX_ORDER,m.rinprebuf,0,MAX_ORDER)),GAIN_ANALYSIS_OK};function Q(m,B){var V,k=0;for(V=0;V<B;V++)k+=m[V];if(k==0)return GAIN_NOT_ENOUGH_SAMPLES;var _=0|Math.ceil(k*(1-ce));for(V=B;V-- >0&&!((_-=m[V])<=0););return z-V/fr.STEPS_per_dB}this.GetTitleGain=function(m){for(var B=Q(m.A,m.A.length),V=0;V<m.A.length;V++)m.B[V]+=m.A[V],m.A[V]=0;for(var V=0;V<MAX_ORDER;V++)m.linprebuf[V]=m.lstepbuf[V]=m.loutbuf[V]=m.rinprebuf[V]=m.rstepbuf[V]=m.routbuf[V]=0;return m.totsamp=0,m.lsum=m.rsum=0,B}}var _a=fr,To=C.new_float,ug=C.new_int;function w3(){this.linprebuf=To(_a.MAX_ORDER*2),this.linpre=0,this.lstepbuf=To(_a.MAX_SAMPLES_PER_WINDOW+_a.MAX_ORDER),this.lstep=0,this.loutbuf=To(_a.MAX_SAMPLES_PER_WINDOW+_a.MAX_ORDER),this.lout=0,this.rinprebuf=To(_a.MAX_ORDER*2),this.rinpre=0,this.rstepbuf=To(_a.MAX_SAMPLES_PER_WINDOW+_a.MAX_ORDER),this.rstep=0,this.routbuf=To(_a.MAX_SAMPLES_PER_WINDOW+_a.MAX_ORDER),this.rout=0,this.sampleWindow=0,this.totsamp=0,this.lsum=0,this.rsum=0,this.freqindex=0,this.first=0,this.A=ug(0|_a.STEPS_per_dB*_a.MAX_dB),this.B=ug(0|_a.STEPS_per_dB*_a.MAX_dB)}var I3=w3;function M3(z){this.bits=z}var pg=M3,fg=C.new_float,A3=C.new_int,hg=C.assert;function B3(z){var te=z;this.quantize=te,this.iteration_loop=function(ce,re,Ee,ie){var ye=ce.internal_flags,ze=fg(Ei.SFBMAX),He=fg(576),$=A3(2),fe=0,ge,L=ye.l3_side,Q=new pg(fe);this.quantize.rv.ResvFrameBegin(ce,Q),fe=Q.bits;for(var m=0;m<ye.mode_gr;m++){ge=this.quantize.qupvt.on_pe(ce,re,$,fe,m,m),ye.mode_ext==P.MPG_MD_MS_LR&&(this.quantize.ms_convert(ye.l3_side,m),this.quantize.qupvt.reduce_side($,Ee[m],fe,ge));for(var B=0;B<ye.channels_out;B++){var V,k,_=L.tt[m][B];_.block_type!=P.SHORT_TYPE?(V=0,k=ye.PSY.mask_adjust-V):(V=0,k=ye.PSY.mask_adjust_short-V),ye.masking_lower=Math.pow(10,k*.1),this.quantize.init_outer_loop(ye,_),this.quantize.init_xrpow(ye,_,He)&&(this.quantize.qupvt.calc_xmin(ce,ie[m][B],_,ze),this.quantize.outer_loop(ce,_,ze,He,B,$[B])),this.quantize.iteration_finish_one(ye,m,B),hg(_.part2_3_length<=rr.MAX_BITS_PER_CHANNEL),hg(_.part2_3_length<=$[B])}}this.quantize.rv.ResvFrameEnd(ye,fe)}}var O3=B3;function Ft(z,te,ce,re){this.xlen=z,this.linmax=te,this.table=ce,this.hlen=re}var Be={};Be.t1HB=[1,1,1,0],Be.t2HB=[1,2,1,3,1,1,3,2,0],Be.t3HB=[3,2,1,1,1,1,3,2,0],Be.t5HB=[1,2,6,5,3,1,4,4,7,5,7,1,6,1,1,0],Be.t6HB=[7,3,5,1,6,2,3,2,5,4,4,1,3,3,2,0],Be.t7HB=[1,2,10,19,16,10,3,3,7,10,5,3,11,4,13,17,8,4,12,11,18,15,11,2,7,6,9,14,3,1,6,4,5,3,2,0],Be.t8HB=[3,4,6,18,12,5,5,1,2,16,9,3,7,3,5,14,7,3,19,17,15,13,10,4,13,5,8,11,5,1,12,4,4,1,1,0],Be.t9HB=[7,5,9,14,15,7,6,4,5,5,6,7,7,6,8,8,8,5,15,6,9,10,5,1,11,7,9,6,4,1,14,4,6,2,6,0],Be.t10HB=[1,2,10,23,35,30,12,17,3,3,8,12,18,21,12,7,11,9,15,21,32,40,19,6,14,13,22,34,46,23,18,7,20,19,33,47,27,22,9,3,31,22,41,26,21,20,5,3,14,13,10,11,16,6,5,1,9,8,7,8,4,4,2,0],Be.t11HB=[3,4,10,24,34,33,21,15,5,3,4,10,32,17,11,10,11,7,13,18,30,31,20,5,25,11,19,59,27,18,12,5,35,33,31,58,30,16,7,5,28,26,32,19,17,15,8,14,14,12,9,13,14,9,4,1,11,4,6,6,6,3,2,0],Be.t12HB=[9,6,16,33,41,39,38,26,7,5,6,9,23,16,26,11,17,7,11,14,21,30,10,7,17,10,15,12,18,28,14,5,32,13,22,19,18,16,9,5,40,17,31,29,17,13,4,2,27,12,11,15,10,7,4,1,27,12,8,12,6,3,1,0],Be.t13HB=[1,5,14,21,34,51,46,71,42,52,68,52,67,44,43,19,3,4,12,19,31,26,44,33,31,24,32,24,31,35,22,14,15,13,23,36,59,49,77,65,29,40,30,40,27,33,42,16,22,20,37,61,56,79,73,64,43,76,56,37,26,31,25,14,35,16,60,57,97,75,114,91,54,73,55,41,48,53,23,24,58,27,50,96,76,70,93,84,77,58,79,29,74,49,41,17,47,45,78,74,115,94,90,79,69,83,71,50,59,38,36,15,72,34,56,95,92,85,91,90,86,73,77,65,51,44,43,42,43,20,30,44,55,78,72,87,78,61,46,54,37,30,20,16,53,25,41,37,44,59,54,81,66,76,57,54,37,18,39,11,35,33,31,57,42,82,72,80,47,58,55,21,22,26,38,22,53,25,23,38,70,60,51,36,55,26,34,23,27,14,9,7,34,32,28,39,49,75,30,52,48,40,52,28,18,17,9,5,45,21,34,64,56,50,49,45,31,19,12,15,10,7,6,3,48,23,20,39,36,35,53,21,16,23,13,10,6,1,4,2,16,15,17,27,25,20,29,11,17,12,16,8,1,1,0,1],Be.t15HB=[7,12,18,53,47,76,124,108,89,123,108,119,107,81,122,63,13,5,16,27,46,36,61,51,42,70,52,83,65,41,59,36,19,17,15,24,41,34,59,48,40,64,50,78,62,80,56,33,29,28,25,43,39,63,55,93,76,59,93,72,54,75,50,29,52,22,42,40,67,57,95,79,72,57,89,69,49,66,46,27,77,37,35,66,58,52,91,74,62,48,79,63,90,62,40,38,125,32,60,56,50,92,78,65,55,87,71,51,73,51,70,30,109,53,49,94,88,75,66,122,91,73,56,42,64,44,21,25,90,43,41,77,73,63,56,92,77,66,47,67,48,53,36,20,71,34,67,60,58,49,88,76,67,106,71,54,38,39,23,15,109,53,51,47,90,82,58,57,48,72,57,41,23,27,62,9,86,42,40,37,70,64,52,43,70,55,42,25,29,18,11,11,118,68,30,55,50,46,74,65,49,39,24,16,22,13,14,7,91,44,39,38,34,63,52,45,31,52,28,19,14,8,9,3,123,60,58,53,47,43,32,22,37,24,17,12,15,10,2,1,71,37,34,30,28,20,17,26,21,16,10,6,8,6,2,0],Be.t16HB=[1,5,14,44,74,63,110,93,172,149,138,242,225,195,376,17,3,4,12,20,35,62,53,47,83,75,68,119,201,107,207,9,15,13,23,38,67,58,103,90,161,72,127,117,110,209,206,16,45,21,39,69,64,114,99,87,158,140,252,212,199,387,365,26,75,36,68,65,115,101,179,164,155,264,246,226,395,382,362,9,66,30,59,56,102,185,173,265,142,253,232,400,388,378,445,16,111,54,52,100,184,178,160,133,257,244,228,217,385,366,715,10,98,48,91,88,165,157,148,261,248,407,397,372,380,889,884,8,85,84,81,159,156,143,260,249,427,401,392,383,727,713,708,7,154,76,73,141,131,256,245,426,406,394,384,735,359,710,352,11,139,129,67,125,247,233,229,219,393,743,737,720,885,882,439,4,243,120,118,115,227,223,396,746,742,736,721,712,706,223,436,6,202,224,222,218,216,389,386,381,364,888,443,707,440,437,1728,4,747,211,210,208,370,379,734,723,714,1735,883,877,876,3459,865,2,377,369,102,187,726,722,358,711,709,866,1734,871,3458,870,434,0,12,10,7,11,10,17,11,9,13,12,10,7,5,3,1,3],Be.t24HB=[15,13,46,80,146,262,248,434,426,669,653,649,621,517,1032,88,14,12,21,38,71,130,122,216,209,198,327,345,319,297,279,42,47,22,41,74,68,128,120,221,207,194,182,340,315,295,541,18,81,39,75,70,134,125,116,220,204,190,178,325,311,293,271,16,147,72,69,135,127,118,112,210,200,188,352,323,306,285,540,14,263,66,129,126,119,114,214,202,192,180,341,317,301,281,262,12,249,123,121,117,113,215,206,195,185,347,330,308,291,272,520,10,435,115,111,109,211,203,196,187,353,332,313,298,283,531,381,17,427,212,208,205,201,193,186,177,169,320,303,286,268,514,377,16,335,199,197,191,189,181,174,333,321,305,289,275,521,379,371,11,668,184,183,179,175,344,331,314,304,290,277,530,383,373,366,10,652,346,171,168,164,318,309,299,287,276,263,513,375,368,362,6,648,322,316,312,307,302,292,284,269,261,512,376,370,364,359,4,620,300,296,294,288,282,273,266,515,380,374,369,365,361,357,2,1033,280,278,274,267,264,259,382,378,372,367,363,360,358,356,0,43,20,19,17,15,13,11,9,7,6,4,7,5,3,1,3],Be.t32HB=[1<<0,5<<1,4<<1,5<<2,6<<1,5<<2,4<<2,4<<3,7<<1,3<<2,6<<2,0<<3,7<<2,2<<3,3<<3,1<<4],Be.t33HB=[15<<0,14<<1,13<<1,12<<2,11<<1,10<<2,9<<2,8<<3,7<<1,6<<2,5<<2,4<<3,3<<2,2<<3,1<<3,0<<4],Be.t1l=[1,4,3,5],Be.t2l=[1,4,7,4,5,7,6,7,8],Be.t3l=[2,3,7,4,4,7,6,7,8],Be.t5l=[1,4,7,8,4,5,8,9,7,8,9,10,8,8,9,10],Be.t6l=[3,4,6,8,4,4,6,7,5,6,7,8,7,7,8,9],Be.t7l=[1,4,7,9,9,10,4,6,8,9,9,10,7,7,9,10,10,11,8,9,10,11,11,11,8,9,10,11,11,12,9,10,11,12,12,12],Be.t8l=[2,4,7,9,9,10,4,4,6,10,10,10,7,6,8,10,10,11,9,10,10,11,11,12,9,9,10,11,12,12,10,10,11,11,13,13],Be.t9l=[3,4,6,7,9,10,4,5,6,7,8,10,5,6,7,8,9,10,7,7,8,9,9,10,8,8,9,9,10,11,9,9,10,10,11,11],Be.t10l=[1,4,7,9,10,10,10,11,4,6,8,9,10,11,10,10,7,8,9,10,11,12,11,11,8,9,10,11,12,12,11,12,9,10,11,12,12,12,12,12,10,11,12,12,13,13,12,13,9,10,11,12,12,12,13,13,10,10,11,12,12,13,13,13],Be.t11l=[2,4,6,8,9,10,9,10,4,5,6,8,10,10,9,10,6,7,8,9,10,11,10,10,8,8,9,11,10,12,10,11,9,10,10,11,11,12,11,12,9,10,11,12,12,13,12,13,9,9,9,10,11,12,12,12,9,9,10,11,12,12,12,12],Be.t12l=[4,4,6,8,9,10,10,10,4,5,6,7,9,9,10,10,6,6,7,8,9,10,9,10,7,7,8,8,9,10,10,10,8,8,9,9,10,10,10,11,9,9,10,10,10,11,10,11,9,9,9,10,10,11,11,12,10,10,10,11,11,11,11,12],Be.t13l=[1,5,7,8,9,10,10,11,10,11,12,12,13,13,14,14,4,6,8,9,10,10,11,11,11,11,12,12,13,14,14,14,7,8,9,10,11,11,12,12,11,12,12,13,13,14,15,15,8,9,10,11,11,12,12,12,12,13,13,13,13,14,15,15,9,9,11,11,12,12,13,13,12,13,13,14,14,15,15,16,10,10,11,12,12,12,13,13,13,13,14,13,15,15,16,16,10,11,12,12,13,13,13,13,13,14,14,14,15,15,16,16,11,11,12,13,13,13,14,14,14,14,15,15,15,16,18,18,10,10,11,12,12,13,13,14,14,14,14,15,15,16,17,17,11,11,12,12,13,13,13,15,14,15,15,16,16,16,18,17,11,12,12,13,13,14,14,15,14,15,16,15,16,17,18,19,12,12,12,13,14,14,14,14,15,15,15,16,17,17,17,18,12,13,13,14,14,15,14,15,16,16,17,17,17,18,18,18,13,13,14,15,15,15,16,16,16,16,16,17,18,17,18,18,14,14,14,15,15,15,17,16,16,19,17,17,17,19,18,18,13,14,15,16,16,16,17,16,17,17,18,18,21,20,21,18],Be.t15l=[3,5,6,8,8,9,10,10,10,11,11,12,12,12,13,14,5,5,7,8,9,9,10,10,10,11,11,12,12,12,13,13,6,7,7,8,9,9,10,10,10,11,11,12,12,13,13,13,7,8,8,9,9,10,10,11,11,11,12,12,12,13,13,13,8,8,9,9,10,10,11,11,11,11,12,12,12,13,13,13,9,9,9,10,10,10,11,11,11,11,12,12,13,13,13,14,10,9,10,10,10,11,11,11,11,12,12,12,13,13,14,14,10,10,10,11,11,11,11,12,12,12,12,12,13,13,13,14,10,10,10,11,11,11,11,12,12,12,12,13,13,14,14,14,10,10,11,11,11,11,12,12,12,13,13,13,13,14,14,14,11,11,11,11,12,12,12,12,12,13,13,13,13,14,15,14,11,11,11,11,12,12,12,12,13,13,13,13,14,14,14,15,12,12,11,12,12,12,13,13,13,13,13,13,14,14,15,15,12,12,12,12,12,13,13,13,13,14,14,14,14,14,15,15,13,13,13,13,13,13,13,13,14,14,14,14,15,15,14,15,13,13,13,13,13,13,13,14,14,14,14,14,15,15,15,15],Be.t16_5l=[1,5,7,9,10,10,11,11,12,12,12,13,13,13,14,11,4,6,8,9,10,11,11,11,12,12,12,13,14,13,14,11,7,8,9,10,11,11,12,12,13,12,13,13,13,14,14,12,9,9,10,11,11,12,12,12,13,13,14,14,14,15,15,13,10,10,11,11,12,12,13,13,13,14,14,14,15,15,15,12,10,10,11,11,12,13,13,14,13,14,14,15,15,15,16,13,11,11,11,12,13,13,13,13,14,14,14,14,15,15,16,13,11,11,12,12,13,13,13,14,14,15,15,15,15,17,17,13,11,12,12,13,13,13,14,14,15,15,15,15,16,16,16,13,12,12,12,13,13,14,14,15,15,15,15,16,15,16,15,14,12,13,12,13,14,14,14,14,15,16,16,16,17,17,16,13,13,13,13,13,14,14,15,16,16,16,16,16,16,15,16,14,13,14,14,14,14,15,15,15,15,17,16,16,16,16,18,14,15,14,14,14,15,15,16,16,16,18,17,17,17,19,17,14,14,15,13,14,16,16,15,16,16,17,18,17,19,17,16,14,11,11,11,12,12,13,13,13,14,14,14,14,14,14,14,12],Be.t16l=[1,5,7,9,10,10,11,11,12,12,12,13,13,13,14,10,4,6,8,9,10,11,11,11,12,12,12,13,14,13,14,10,7,8,9,10,11,11,12,12,13,12,13,13,13,14,14,11,9,9,10,11,11,12,12,12,13,13,14,14,14,15,15,12,10,10,11,11,12,12,13,13,13,14,14,14,15,15,15,11,10,10,11,11,12,13,13,14,13,14,14,15,15,15,16,12,11,11,11,12,13,13,13,13,14,14,14,14,15,15,16,12,11,11,12,12,13,13,13,14,14,15,15,15,15,17,17,12,11,12,12,13,13,13,14,14,15,15,15,15,16,16,16,12,12,12,12,13,13,14,14,15,15,15,15,16,15,16,15,13,12,13,12,13,14,14,14,14,15,16,16,16,17,17,16,12,13,13,13,13,14,14,15,16,16,16,16,16,16,15,16,13,13,14,14,14,14,15,15,15,15,17,16,16,16,16,18,13,15,14,14,14,15,15,16,16,16,18,17,17,17,19,17,13,14,15,13,14,16,16,15,16,16,17,18,17,19,17,16,13,10,10,10,11,11,12,12,12,13,13,13,13,13,13,13,10],Be.t24l=[4,5,7,8,9,10,10,11,11,12,12,12,12,12,13,10,5,6,7,8,9,10,10,11,11,11,12,12,12,12,12,10,7,7,8,9,9,10,10,11,11,11,11,12,12,12,13,9,8,8,9,9,10,10,10,11,11,11,11,12,12,12,12,9,9,9,9,10,10,10,10,11,11,11,12,12,12,12,13,9,10,9,10,10,10,10,11,11,11,11,12,12,12,12,12,9,10,10,10,10,10,11,11,11,11,12,12,12,12,12,13,9,11,10,10,10,11,11,11,11,12,12,12,12,12,13,13,10,11,11,11,11,11,11,11,11,11,12,12,12,12,13,13,10,11,11,11,11,11,11,11,12,12,12,12,12,13,13,13,10,12,11,11,11,11,12,12,12,12,12,12,13,13,13,13,10,12,12,11,11,11,12,12,12,12,12,12,13,13,13,13,10,12,12,12,12,12,12,12,12,12,12,13,13,13,13,13,10,12,12,12,12,12,12,12,12,13,13,13,13,13,13,13,10,13,12,12,12,12,12,12,13,13,13,13,13,13,13,13,10,9,9,9,9,9,9,9,9,9,9,9,10,10,10,10,6],Be.t32l=[1+0,4+1,4+1,5+2,4+1,6+2,5+2,6+3,4+1,5+2,5+2,6+3,5+2,6+3,6+3,6+4],Be.t33l=[4+0,4+1,4+1,4+2,4+1,4+2,4+2,4+3,4+1,4+2,4+2,4+3,4+2,4+3,4+3,4+4],Be.ht=[new Ft(0,0,null,null),new Ft(2,0,Be.t1HB,Be.t1l),new Ft(3,0,Be.t2HB,Be.t2l),new Ft(3,0,Be.t3HB,Be.t3l),new Ft(0,0,null,null),new Ft(4,0,Be.t5HB,Be.t5l),new Ft(4,0,Be.t6HB,Be.t6l),new Ft(6,0,Be.t7HB,Be.t7l),new Ft(6,0,Be.t8HB,Be.t8l),new Ft(6,0,Be.t9HB,Be.t9l),new Ft(8,0,Be.t10HB,Be.t10l),new Ft(8,0,Be.t11HB,Be.t11l),new Ft(8,0,Be.t12HB,Be.t12l),new Ft(16,0,Be.t13HB,Be.t13l),new Ft(0,0,null,Be.t16_5l),new Ft(16,0,Be.t15HB,Be.t15l),new Ft(1,1,Be.t16HB,Be.t16l),new Ft(2,3,Be.t16HB,Be.t16l),new Ft(3,7,Be.t16HB,Be.t16l),new Ft(4,15,Be.t16HB,Be.t16l),new Ft(6,63,Be.t16HB,Be.t16l),new Ft(8,255,Be.t16HB,Be.t16l),new Ft(10,1023,Be.t16HB,Be.t16l),new Ft(13,8191,Be.t16HB,Be.t16l),new Ft(4,15,Be.t24HB,Be.t24l),new Ft(5,31,Be.t24HB,Be.t24l),new Ft(6,63,Be.t24HB,Be.t24l),new Ft(7,127,Be.t24HB,Be.t24l),new Ft(8,255,Be.t24HB,Be.t24l),new Ft(9,511,Be.t24HB,Be.t24l),new Ft(11,2047,Be.t24HB,Be.t24l),new Ft(13,8191,Be.t24HB,Be.t24l),new Ft(0,0,Be.t32HB,Be.t32l),new Ft(0,0,Be.t33HB,Be.t33l)],Be.largetbl=[65540,327685,458759,589832,655369,655370,720906,720907,786443,786444,786444,851980,851980,851980,917517,655370,262149,393222,524295,589832,655369,720906,720906,720907,786443,786443,786444,851980,917516,851980,917516,655370,458759,524295,589832,655369,720905,720906,786442,786443,851979,786443,851979,851980,851980,917516,917517,720905,589832,589832,655369,720905,720906,786442,786442,786443,851979,851979,917515,917516,917516,983052,983052,786441,655369,655369,720905,720906,786442,786442,851978,851979,851979,917515,917516,917516,983052,983052,983053,720905,655370,655369,720906,720906,786442,851978,851979,917515,851979,917515,917516,983052,983052,983052,1048588,786441,720906,720906,720906,786442,851978,851979,851979,851979,917515,917516,917516,917516,983052,983052,1048589,786441,720907,720906,786442,786442,851979,851979,851979,917515,917516,983052,983052,983052,983052,1114125,1114125,786442,720907,786443,786443,851979,851979,851979,917515,917515,983051,983052,983052,983052,1048588,1048589,1048589,786442,786443,786443,786443,851979,851979,917515,917515,983052,983052,983052,983052,1048588,983053,1048589,983053,851978,786444,851979,786443,851979,917515,917516,917516,917516,983052,1048588,1048588,1048589,1114125,1114125,1048589,786442,851980,851980,851979,851979,917515,917516,983052,1048588,1048588,1048588,1048588,1048589,1048589,983053,1048589,851978,851980,917516,917516,917516,917516,983052,983052,983052,983052,1114124,1048589,1048589,1048589,1048589,1179661,851978,983052,917516,917516,917516,983052,983052,1048588,1048588,1048589,1179661,1114125,1114125,1114125,1245197,1114125,851978,917517,983052,851980,917516,1048588,1048588,983052,1048589,1048589,1114125,1179661,1114125,1245197,1114125,1048589,851978,655369,655369,655369,720905,720905,786441,786441,786441,851977,851977,851977,851978,851978,851978,851978,655366],Be.table23=[65538,262147,458759,262148,327684,458759,393222,458759,524296],Be.table56=[65539,262148,458758,524296,262148,327684,524294,589831,458757,524294,589831,655368,524295,524295,589832,655369],Be.bitrate_table=[[0,8,16,24,32,40,48,56,64,80,96,112,128,144,160,-1],[0,32,40,48,56,64,80,96,112,128,160,192,224,256,320,-1],[0,8,16,24,32,40,48,56,64,-1,-1,-1,-1,-1,-1,-1]],Be.samplerate_table=[[22050,24e3,16e3,-1],[44100,48e3,32e3,-1],[11025,12e3,8e3,-1]],Be.scfsi_band=[0,6,11,16,21];var Ht=Be,Ls=C.VbrMode,gm=C.Float,pp=C.Util,qs=C.new_float,z3=C.new_int,Ii=C.assert;Fa.Q_MAX=256+1,Fa.Q_MAX2=116,Fa.LARGE_BITS=1e5,Fa.IXMAX_VAL=8206;function Fa(){var z=null,te=null,ce=null;this.setModules=function(g,D,K){z=g,te=D,ce=K};function re(g){return Ii(0<=g+Fa.Q_MAX2&&g<Fa.Q_MAX),L[g+Fa.Q_MAX2]}this.IPOW20=function(g){return Ii(0<=g&&g<Fa.Q_MAX),Q[g]};var Ee=2220446049250313e-31,ie=Fa.IXMAX_VAL,ye=ie+2,ze=Fa.Q_MAX,He=Fa.Q_MAX2,$=Fa.LARGE_BITS,fe=100;this.nr_of_sfb_block=[[[6,5,5,5],[9,9,9,9],[6,9,9,9]],[[6,5,7,3],[9,9,12,6],[6,9,12,6]],[[11,10,0,0],[18,18,0,0],[15,18,0,0]],[[7,7,7,0],[12,12,12,0],[6,15,12,0]],[[6,6,6,3],[12,9,9,6],[6,12,9,6]],[[8,8,5,0],[15,12,9,0],[6,18,9,0]]];var ge=[0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,2,2,3,3,3,2,0];this.pretab=ge,this.sfBandIndex=[new Zn([0,6,12,18,24,30,36,44,54,66,80,96,116,140,168,200,238,284,336,396,464,522,576],[0,4,8,12,18,24,32,42,56,74,100,132,174,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Zn([0,6,12,18,24,30,36,44,54,66,80,96,114,136,162,194,232,278,332,394,464,540,576],[0,4,8,12,18,26,36,48,62,80,104,136,180,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Zn([0,6,12,18,24,30,36,44,54,66,80,96,116,140,168,200,238,284,336,396,464,522,576],[0,4,8,12,18,26,36,48,62,80,104,134,174,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Zn([0,4,8,12,16,20,24,30,36,44,52,62,74,90,110,134,162,196,238,288,342,418,576],[0,4,8,12,16,22,30,40,52,66,84,106,136,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Zn([0,4,8,12,16,20,24,30,36,42,50,60,72,88,106,128,156,190,230,276,330,384,576],[0,4,8,12,16,22,28,38,50,64,80,100,126,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Zn([0,4,8,12,16,20,24,30,36,44,54,66,82,102,126,156,194,240,296,364,448,550,576],[0,4,8,12,16,22,30,42,58,78,104,138,180,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Zn([0,6,12,18,24,30,36,44,54,66,80,96,116,140,168,200,238,284,336,396,464,522,576],[0/3,12/3,24/3,36/3,54/3,78/3,108/3,144/3,186/3,240/3,312/3,402/3,522/3,576/3],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Zn([0,6,12,18,24,30,36,44,54,66,80,96,116,140,168,200,238,284,336,396,464,522,576],[0/3,12/3,24/3,36/3,54/3,78/3,108/3,144/3,186/3,240/3,312/3,402/3,522/3,576/3],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Zn([0,12,24,36,48,60,72,88,108,132,160,192,232,280,336,400,476,566,568,570,572,574,576],[0/3,24/3,48/3,72/3,108/3,156/3,216/3,288/3,372/3,480/3,486/3,492/3,498/3,576/3],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0])];var L=qs(ze+He+1),Q=qs(ze),m=qs(ye),B=qs(ye);this.adj43=B;function V(g,D){var K=ce.ATHformula(D,g);return K-=fe,K=Math.pow(10,K/10+g.ATHlower),K}function k(g){for(var D=g.internal_flags.ATH.l,K=g.internal_flags.ATH.psfb21,w=g.internal_flags.ATH.s,u=g.internal_flags.ATH.psfb12,F=g.internal_flags,R=g.out_samplerate,f=0;f<P.SBMAX_l;f++){var y=F.scalefac_band.l[f],b=F.scalefac_band.l[f+1];D[f]=gm.MAX_VALUE;for(var d=y;d<b;d++){var x=d*R/1152,N=V(g,x);D[f]=Math.min(D[f],N)}}for(var f=0;f<P.PSFB21;f++){var y=F.scalefac_band.psfb21[f],b=F.scalefac_band.psfb21[f+1];K[f]=gm.MAX_VALUE;for(var d=y;d<b;d++){var x=d*R/1152,N=V(g,x);K[f]=Math.min(K[f],N)}}for(var f=0;f<P.SBMAX_s;f++){var y=F.scalefac_band.s[f],b=F.scalefac_band.s[f+1];w[f]=gm.MAX_VALUE;for(var d=y;d<b;d++){var x=d*R/384,N=V(g,x);w[f]=Math.min(w[f],N)}w[f]*=F.scalefac_band.s[f+1]-F.scalefac_band.s[f]}for(var f=0;f<P.PSFB12;f++){var y=F.scalefac_band.psfb12[f],b=F.scalefac_band.psfb12[f+1];u[f]=gm.MAX_VALUE;for(var d=y;d<b;d++){var x=d*R/384,N=V(g,x);u[f]=Math.min(u[f],N)}u[f]*=F.scalefac_band.s[13]-F.scalefac_band.s[12]}if(g.noATH){for(var f=0;f<P.SBMAX_l;f++)D[f]=1e-20;for(var f=0;f<P.PSFB21;f++)K[f]=1e-20;for(var f=0;f<P.SBMAX_s;f++)w[f]=1e-20;for(var f=0;f<P.PSFB12;f++)u[f]=1e-20}F.ATH.floor=10*Math.log10(V(g,-1))}this.iteration_init=function(g){var D=g.internal_flags,K=D.l3_side,w;if(D.iteration_init_init==0){for(D.iteration_init_init=1,K.main_data_begin=0,k(g),m[0]=0,w=1;w<ye;w++)m[w]=Math.pow(w,4/3);for(w=0;w<ye-1;w++)B[w]=w+1-Math.pow(.5*(m[w]+m[w+1]),.75);for(B[w]=.5,w=0;w<ze;w++)Q[w]=Math.pow(2,(w-210)*-.1875);for(w=0;w<=ze+He;w++)L[w]=Math.pow(2,(w-210-He)*.25);z.huffman_init(D);{var u,F,R,f;for(w=g.exp_nspsytune>>2&63,w>=32&&(w-=64),u=Math.pow(10,w/4/10),w=g.exp_nspsytune>>8&63,w>=32&&(w-=64),F=Math.pow(10,w/4/10),w=g.exp_nspsytune>>14&63,w>=32&&(w-=64),R=Math.pow(10,w/4/10),w=g.exp_nspsytune>>20&63,w>=32&&(w-=64),f=R*Math.pow(10,w/4/10),w=0;w<P.SBMAX_l;w++){var y;w<=6?y=u:w<=13?y=F:w<=20?y=R:y=f,D.nsPsy.longfact[w]=y}for(w=0;w<P.SBMAX_s;w++){var y;w<=5?y=u:w<=10?y=F:w<=11?y=R:y=f,D.nsPsy.shortfact[w]=y}}}},this.on_pe=function(g,D,K,w,u,F){var R=g.internal_flags,f=0,y,b=z3(2),d,x=new pg(f),N=te.ResvMaxBits(g,w,x,F);f=x.bits;var T=f+N;for(T>rr.MAX_BITS_PER_GRANULE&&(T=rr.MAX_BITS_PER_GRANULE),y=0,d=0;d<R.channels_out;++d)K[d]=Math.min(rr.MAX_BITS_PER_CHANNEL,f/R.channels_out),b[d]=0|K[d]*D[u][d]/700-K[d],b[d]>w*3/4&&(b[d]=w*3/4),b[d]<0&&(b[d]=0),b[d]+K[d]>rr.MAX_BITS_PER_CHANNEL&&(b[d]=Math.max(0,rr.MAX_BITS_PER_CHANNEL-K[d])),y+=b[d];if(y>N)for(d=0;d<R.channels_out;++d)b[d]=N*b[d]/y;for(d=0;d<R.channels_out;++d)K[d]+=b[d],N-=b[d];for(y=0,d=0;d<R.channels_out;++d)y+=K[d];if(y>rr.MAX_BITS_PER_GRANULE){var Y=0;for(d=0;d<R.channels_out;++d)K[d]*=rr.MAX_BITS_PER_GRANULE,K[d]/=y,Y+=K[d];Ii(Y<=rr.MAX_BITS_PER_GRANULE)}return T},this.reduce_side=function(g,D,K,w){Ii(w<=rr.MAX_BITS_PER_GRANULE),Ii(g[0]+g[1]<=rr.MAX_BITS_PER_GRANULE);var u=.33*(.5-D)/.5;u<0&&(u=0),u>.5&&(u=.5);var F=0|u*.5*(g[0]+g[1]);F>rr.MAX_BITS_PER_CHANNEL-g[0]&&(F=rr.MAX_BITS_PER_CHANNEL-g[0]),F<0&&(F=0),g[1]>=125&&(g[1]-F>125?(g[0]<K&&(g[0]+=F),g[1]-=F):(g[0]+=g[1]-125,g[1]=125)),F=g[0]+g[1],F>w&&(g[0]=w*g[0]/F,g[1]=w*g[1]/F),Ii(g[0]<=rr.MAX_BITS_PER_CHANNEL),Ii(g[1]<=rr.MAX_BITS_PER_CHANNEL),Ii(g[0]+g[1]<=rr.MAX_BITS_PER_GRANULE)},this.athAdjust=function(g,D,K){var w=90.30873362,u=94.82444863,F=pp.FAST_LOG10_X(D,10),R=g*g,f=0;return F-=K,R>1e-20&&(f=1+pp.FAST_LOG10_X(R,10/w)),f<0&&(f=0),F*=f,F+=K+w-u,Math.pow(10,.1*F)},this.calc_xmin=function(g,D,K,w){var u=0,F=g.internal_flags,R,f=0,y=0,b=F.ATH,d=K.xr,x=g.VBR==Ls.vbr_mtrh?1:0,N=F.masking_lower;for((g.VBR==Ls.vbr_mtrh||g.VBR==Ls.vbr_mt)&&(N=1),R=0;R<K.psy_lmax;R++){var T,Y,j,X,_e,h;g.VBR==Ls.vbr_rh||g.VBR==Ls.vbr_mtrh?Y=athAdjust(b.adjust,b.l[R],b.floor):Y=b.adjust*b.l[R],_e=K.width[R],j=Y/_e,X=Ee,h=_e>>1,T=0;do{var v,de;v=d[f]*d[f],T+=v,X+=v<j?v:j,f++,de=d[f]*d[f],T+=de,X+=de<j?de:j,f++}while(--h>0);if(T>Y&&y++,R==P.SBPSY_l){var ve=Y*F.nsPsy.longfact[R];X<ve&&(X=ve)}if(x!=0&&(Y=X),!g.ATHonly){var De=D.en.l[R];if(De>0){var ve;ve=T*D.thm.l[R]*N/De,x!=0&&(ve*=F.nsPsy.longfact[R]),Y<ve&&(Y=ve)}}x!=0?w[u++]=Y:w[u++]=Y*F.nsPsy.longfact[R]}var Ue=575;if(K.block_type!=P.SHORT_TYPE)for(var $e=576;$e--!=0&&Mi.EQ(d[$e],0);)Ue=$e;K.max_nonzero_coeff=Ue;for(var Xe=K.sfb_smin;R<K.psymax;Xe++,R+=3){var _e,yt,tt;for(g.VBR==Ls.vbr_rh||g.VBR==Ls.vbr_mtrh?tt=athAdjust(b.adjust,b.s[Xe],b.floor):tt=b.adjust*b.s[Xe],_e=K.width[R],yt=0;yt<3;yt++){var T=0,Y,j,X,h=_e>>1;j=tt/_e,X=Ee;do{var v,de;v=d[f]*d[f],T+=v,X+=v<j?v:j,f++,de=d[f]*d[f],T+=de,X+=de<j?de:j,f++}while(--h>0);if(T>tt&&y++,Xe==P.SBPSY_s){var ve=tt*F.nsPsy.shortfact[Xe];X<ve&&(X=ve)}if(x!=0?Y=X:Y=tt,!g.ATHonly&&!g.ATHshort){var De=D.en.s[Xe][yt];if(De>0){var ve;ve=T*D.thm.s[Xe][yt]*N/De,x!=0&&(ve*=F.nsPsy.shortfact[Xe]),Y<ve&&(Y=ve)}}x!=0?w[u++]=Y:w[u++]=Y*F.nsPsy.shortfact[Xe]}g.useTemporal&&(w[u-3]>w[u-3+1]&&(w[u-3+1]+=(w[u-3]-w[u-3+1])*F.decay),w[u-3+1]>w[u-3+2]&&(w[u-3+2]+=(w[u-3+1]-w[u-3+2])*F.decay))}return y};function _(g){this.s=g}this.calc_noise_core=function(g,D,K,w){var u=0,F=D.s,R=g.l3_enc;if(F>g.count1)for(;K--!=0;){var f;f=g.xr[F],F++,u+=f*f,f=g.xr[F],F++,u+=f*f}else if(F>g.big_values){var y=qs(2);for(y[0]=0,y[1]=w;K--!=0;){var f;f=Math.abs(g.xr[F])-y[R[F]],F++,u+=f*f,f=Math.abs(g.xr[F])-y[R[F]],F++,u+=f*f}}else for(;K--!=0;){var f;f=Math.abs(g.xr[F])-m[R[F]]*w,F++,u+=f*f,f=Math.abs(g.xr[F])-m[R[F]]*w,F++,u+=f*f}return D.s=F,u},this.calc_noise=function(g,D,K,w,u){var F=0,R=0,f,y,b=0,d=0,x=0,N=-20,T=0,Y=g.scalefac,j=0;for(w.over_SSD=0,f=0;f<g.psymax;f++){var X=g.global_gain-(Y[j++]+(g.preflag!=0?ge[f]:0)<<g.scalefac_scale+1)-g.subblock_gain[g.window[f]]*8,_e=0;if(u!=null&&u.step[f]==X)_e=u.noise[f],T+=g.width[f],K[F++]=_e/D[R++],_e=u.noise_log[f];else{var h=re(X);if(y=g.width[f]>>1,T+g.width[f]>g.max_nonzero_coeff){var v;v=g.max_nonzero_coeff-T+1,v>0?y=v>>1:y=0}var de=new _(T);_e=this.calc_noise_core(g,de,y,h),T=de.s,u!=null&&(u.step[f]=X,u.noise[f]=_e),_e=K[F++]=_e/D[R++],_e=pp.FAST_LOG10(Math.max(_e,1e-20)),u!=null&&(u.noise_log[f]=_e)}if(u!=null&&(u.global_gain=g.global_gain),x+=_e,_e>0){var ve;ve=Math.max(0|_e*10+.5,1),w.over_SSD+=ve*ve,b++,d+=_e}N=Math.max(N,_e)}return w.over_count=b,w.tot_noise=x,w.over_noise=d,w.max_noise=N,b},this.set_pinfo=function(g,D,K,w,u){var F=g.internal_flags,R,f,y,b,d,x=D.scalefac_scale==0?.5:1,N=D.scalefac,T=qs(L3Side.SFBMAX),Y=qs(L3Side.SFBMAX),j=new CalcNoiseResult;calc_xmin(g,K,D,T),calc_noise(D,T,Y,j,null);var X=0;for(f=D.sfb_lmax,D.block_type!=P.SHORT_TYPE&&D.mixed_block_flag==0&&(f=22),R=0;R<f;R++){var _e=F.scalefac_band.l[R],h=F.scalefac_band.l[R+1],v=h-_e;for(b=0;X<h;X++)b+=D.xr[X]*D.xr[X];b/=v,d=1e15,F.pinfo.en[w][u][R]=d*b,F.pinfo.xfsf[w][u][R]=d*T[R]*Y[R]/v,K.en.l[R]>0&&!g.ATHonly?b=b/K.en.l[R]:b=0,F.pinfo.thr[w][u][R]=d*Math.max(b*K.thm.l[R],F.ATH.l[R]),F.pinfo.LAMEsfb[w][u][R]=0,D.preflag!=0&&R>=11&&(F.pinfo.LAMEsfb[w][u][R]=-x*ge[R]),R<P.SBPSY_l&&(Ii(N[R]>=0),F.pinfo.LAMEsfb[w][u][R]-=x*N[R])}if(D.block_type==P.SHORT_TYPE)for(f=R,R=D.sfb_smin;R<P.SBMAX_s;R++)for(var _e=F.scalefac_band.s[R],h=F.scalefac_band.s[R+1],v=h-_e,de=0;de<3;de++){for(b=0,y=_e;y<h;y++)b+=D.xr[X]*D.xr[X],X++;b=Math.max(b/v,1e-20),d=1e15,F.pinfo.en_s[w][u][3*R+de]=d*b,F.pinfo.xfsf_s[w][u][3*R+de]=d*T[f]*Y[f]/v,K.en.s[R][de]>0?b=b/K.en.s[R][de]:b=0,(g.ATHonly||g.ATHshort)&&(b=0),F.pinfo.thr_s[w][u][3*R+de]=d*Math.max(b*K.thm.s[R][de],F.ATH.s[R]),F.pinfo.LAMEsfb_s[w][u][3*R+de]=-2*D.subblock_gain[de],R<P.SBPSY_s&&(F.pinfo.LAMEsfb_s[w][u][3*R+de]-=x*N[f]),f++}F.pinfo.LAMEqss[w][u]=D.global_gain,F.pinfo.LAMEmainbits[w][u]=D.part2_3_length+D.part2_length,F.pinfo.LAMEsfbits[w][u]=D.part2_length,F.pinfo.over[w][u]=j.over_count,F.pinfo.max_noise[w][u]=j.max_noise*10,F.pinfo.over_noise[w][u]=j.over_noise*10,F.pinfo.tot_noise[w][u]=j.tot_noise*10,F.pinfo.over_SSD[w][u]=j.over_SSD}}var Zi=Fa,L3=C.System,q3=C.Arrays,Vl=C.new_int,mn=C.assert;function fp(){var z=null;this.qupvt=null,this.setModules=function(f){this.qupvt=f,z=f};function te(f){this.bits=0|f}var ce=[[0,0],[0,0],[0,0],[0,0],[0,0],[0,1],[1,1],[1,1],[1,2],[2,2],[2,3],[2,3],[3,4],[3,4],[3,4],[4,5],[4,5],[4,6],[5,6],[5,6],[5,7],[6,7],[6,7]];function re(f,y,b,d,x,N){var T=.5946/y;for(mn(f>0),f=f>>1;f--!=0;)x[N++]=T>b[d++]?0:1,x[N++]=T>b[d++]?0:1}function Ee(f,y,b,d,x,N){mn(f>0),f=f>>1;var T=f%2;for(f=f>>1;f--!=0;){var Y,j,X,_e,h,v,de,ve;Y=b[d++]*y,j=b[d++]*y,h=0|Y,X=b[d++]*y,v=0|j,_e=b[d++]*y,de=0|X,Y+=z.adj43[h],ve=0|_e,j+=z.adj43[v],x[N++]=0|Y,X+=z.adj43[de],x[N++]=0|j,_e+=z.adj43[ve],x[N++]=0|X,x[N++]=0|_e}if(T!=0){var Y,j,h,v;Y=b[d++]*y,j=b[d++]*y,h=0|Y,v=0|j,Y+=z.adj43[h],j+=z.adj43[v],x[N++]=0|Y,x[N++]=0|j}}function ie(f,y,b,d,x){var N,T,Y=0,j,X=0,_e=0,h=0,v=y,de=0,ve=v,De=0,Ue=f,$e=0;for(j=x!=null&&d.global_gain==x.global_gain,d.block_type==P.SHORT_TYPE?T=38:T=21,N=0;N<=T;N++){var Xe=-1;if((j||d.block_type==P.NORM_TYPE)&&(Xe=d.global_gain-(d.scalefac[N]+(d.preflag!=0?z.pretab[N]:0)<<d.scalefac_scale+1)-d.subblock_gain[d.window[N]]*8),mn(d.width[N]>=0),j&&x.step[N]==Xe)X!=0&&(Ee(X,b,Ue,$e,ve,De),X=0),_e!=0&&(re(_e,b,Ue,$e,ve,De),_e=0);else{var yt=d.width[N];if(Y+d.width[N]>d.max_nonzero_coeff){var tt;tt=d.max_nonzero_coeff-Y+1,q3.fill(y,d.max_nonzero_coeff,576,0),yt=tt,yt<0&&(yt=0),N=T+1}if(X==0&&_e==0&&(ve=v,De=de,Ue=f,$e=h),x!=null&&x.sfb_count1>0&&N>=x.sfb_count1&&x.step[N]>0&&Xe>=x.step[N]?(X!=0&&(Ee(X,b,Ue,$e,ve,De),X=0,ve=v,De=de,Ue=f,$e=h),_e+=yt):(_e!=0&&(re(_e,b,Ue,$e,ve,De),_e=0,ve=v,De=de,Ue=f,$e=h),X+=yt),yt<=0){_e!=0&&(re(_e,b,Ue,$e,ve,De),_e=0),X!=0&&(Ee(X,b,Ue,$e,ve,De),X=0);break}}N<=T&&(de+=d.width[N],h+=d.width[N],Y+=d.width[N])}X!=0&&(Ee(X,b,Ue,$e,ve,De),X=0),_e!=0&&(re(_e,b,Ue,$e,ve,De),_e=0)}function ye(f,y,b){var d=0,x=0;do{var N=f[y++],T=f[y++];d<N&&(d=N),x<T&&(x=T)}while(y<b);return d<x&&(d=x),d}function ze(f,y,b,d,x,N){var T=Ht.ht[d].xlen*65536+Ht.ht[x].xlen,Y=0,j;do{var X=f[y++],_e=f[y++];X!=0&&(X>14&&(X=15,Y+=T),X*=16),_e!=0&&(_e>14&&(_e=15,Y+=T),X+=_e),Y+=Ht.largetbl[X]}while(y<b);return j=Y&65535,Y>>=16,Y>j&&(Y=j,d=x),N.bits+=Y,d}function He(f,y,b,d){var x=0,N=Ht.ht[1].hlen;do{var T=f[y+0]*2+f[y+1];y+=2,x+=N[T]}while(y<b);return d.bits+=x,1}function $(f,y,b,d,x){var N=0,T,Y=Ht.ht[d].xlen,j;d==2?j=Ht.table23:j=Ht.table56;do{var X=f[y+0]*Y+f[y+1];y+=2,N+=j[X]}while(y<b);return T=N&65535,N>>=16,N>T&&(N=T,d++),x.bits+=N,d}function fe(f,y,b,d,x){var N=0,T=0,Y=0,j=Ht.ht[d].xlen,X=Ht.ht[d].hlen,_e=Ht.ht[d+1].hlen,h=Ht.ht[d+2].hlen;do{var v=f[y+0]*j+f[y+1];y+=2,N+=X[v],T+=_e[v],Y+=h[v]}while(y<b);var de=d;return N>T&&(N=T,de++),N>Y&&(N=Y,de=d+2),x.bits+=N,de}var ge=[1,2,5,7,7,10,10,13,13,13,13,13,13,13,13];function L(f,y,b,d){var x=ye(f,y,b);switch(x){case 0:return x;case 1:return He(f,y,b,d);case 2:case 3:return $(f,y,b,ge[x-1],d);case 4:case 5:case 6:case 7:case 8:case 9:case 10:case 11:case 12:case 13:case 14:case 15:return fe(f,y,b,ge[x-1],d);default:if(x>Zi.IXMAX_VAL)return d.bits=Zi.LARGE_BITS,-1;x-=15;var N;for(N=24;N<32&&!(Ht.ht[N].linmax>=x);N++);var T;for(T=N-8;T<24&&!(Ht.ht[T].linmax>=x);T++);return ze(f,y,b,T,N,d)}}this.noquant_count_bits=function(f,y,b){var d=y.l3_enc,x=Math.min(576,y.max_nonzero_coeff+2>>1<<1);for(b!=null&&(b.sfb_count1=0);x>1&&(d[x-1]|d[x-2])==0;x-=2);y.count1=x;for(var N=0,T=0;x>3;x-=4){var Y;if(((d[x-1]|d[x-2]|d[x-3]|d[x-4])&2147483647)>1)break;Y=((d[x-4]*2+d[x-3])*2+d[x-2])*2+d[x-1],N+=Ht.t32l[Y],T+=Ht.t33l[Y]}var j=N;if(y.count1table_select=0,N>T&&(j=T,y.count1table_select=1),y.count1bits=j,y.big_values=x,x==0)return j;if(y.block_type==P.SHORT_TYPE)N=3*f.scalefac_band.s[3],N>y.big_values&&(N=y.big_values),T=y.big_values;else if(y.block_type==P.NORM_TYPE){if(mn(x<=576),N=y.region0_count=f.bv_scf[x-2],T=y.region1_count=f.bv_scf[x-1],mn(N+T+2<P.SBPSY_l),T=f.scalefac_band.l[N+T+2],N=f.scalefac_band.l[N+1],T<x){var X=new te(j);y.table_select[2]=L(d,T,x,X),j=X.bits}}else y.region0_count=7,y.region1_count=P.SBMAX_l-1-7-1,N=f.scalefac_band.l[7+1],T=x,N>T&&(N=T);if(N=Math.min(N,x),T=Math.min(T,x),mn(N>=0),mn(T>=0),0<N){var X=new te(j);y.table_select[0]=L(d,0,N,X),j=X.bits}if(N<T){var X=new te(j);y.table_select[1]=L(d,N,T,X),j=X.bits}if(f.use_best_huffman==2&&(y.part2_3_length=j,best_huffman_divide(f,y),j=y.part2_3_length),b!=null&&y.block_type==P.NORM_TYPE){for(var _e=0;f.scalefac_band.l[_e]<y.big_values;)_e++;b.sfb_count1=_e}return j},this.count_bits=function(f,y,b,d){var x=b.l3_enc,N=Zi.IXMAX_VAL/z.IPOW20(b.global_gain);if(b.xrpow_max>N)return Zi.LARGE_BITS;if(ie(y,x,z.IPOW20(b.global_gain),b,d),(f.substep_shaping&2)!=0)for(var T=0,Y=b.global_gain+b.scalefac_scale,j=.634521682242439/z.IPOW20(Y),X=0;X<b.sfbmax;X++){var _e=b.width[X];if(mn(_e>=0),f.pseudohalf[X]==0)T+=_e;else{var h;for(h=T,T+=_e;h<T;++h)x[h]=y[h]>=j?x[h]:0}}return this.noquant_count_bits(f,b,d)};function Q(f,y,b,d,x,N,T){for(var Y=y.big_values,j=0;j<=7+15;j++)d[j]=Zi.LARGE_BITS;for(var j=0;j<16;j++){var X=f.scalefac_band.l[j+1];if(X>=Y)break;var _e=0,h=new te(_e),v=L(b,0,X,h);_e=h.bits;for(var de=0;de<8;de++){var ve=f.scalefac_band.l[j+de+2];if(ve>=Y)break;var De=_e;h=new te(De);var Ue=L(b,X,ve,h);De=h.bits,d[j+de]>De&&(d[j+de]=De,x[j+de]=j,N[j+de]=v,T[j+de]=Ue)}}}function m(f,y,b,d,x,N,T,Y){for(var j=y.big_values,X=2;X<P.SBMAX_l+1;X++){var _e=f.scalefac_band.l[X];if(_e>=j)break;var h=x[X-2]+y.count1bits;if(b.part2_3_length<=h)break;var v=new te(h),de=L(d,_e,j,v);h=v.bits,!(b.part2_3_length<=h)&&(b.assign(y),b.part2_3_length=h,b.region0_count=N[X-2],b.region1_count=X-2-N[X-2],b.table_select[0]=T[X-2],b.table_select[1]=Y[X-2],b.table_select[2]=de)}}this.best_huffman_divide=function(f,y){var b=new fm,d=y.l3_enc,x=Vl(7+15+1),N=Vl(7+15+1),T=Vl(7+15+1),Y=Vl(7+15+1);if(!(y.block_type==P.SHORT_TYPE&&f.mode_gr==1)){b.assign(y),y.block_type==P.NORM_TYPE&&(Q(f,y,d,x,N,T,Y),m(f,b,y,d,x,N,T,Y));var j=b.big_values;if(!(j==0||(d[j-2]|d[j-1])>1)&&(j=y.count1+2,!(j>576))){b.assign(y),b.count1=j;var X=0,_e=0;for(mn(j<=576);j>b.big_values;j-=4){var h=((d[j-4]*2+d[j-3])*2+d[j-2])*2+d[j-1];X+=Ht.t32l[h],_e+=Ht.t33l[h]}if(b.big_values=j,b.count1table_select=0,X>_e&&(X=_e,b.count1table_select=1),b.count1bits=X,b.block_type==P.NORM_TYPE)m(f,b,y,d,x,N,T,Y);else{if(b.part2_3_length=X,X=f.scalefac_band.l[7+1],X>j&&(X=j),X>0){var v=new te(b.part2_3_length);b.table_select[0]=L(d,0,X,v),b.part2_3_length=v.bits}if(j>X){var v=new te(b.part2_3_length);b.table_select[1]=L(d,X,j,v),b.part2_3_length=v.bits}y.part2_3_length>b.part2_3_length&&y.assign(b)}}}};var B=[1,1,1,1,8,2,2,2,4,4,4,8,8,8,16,16],V=[1,2,4,8,1,2,4,8,2,4,8,2,4,8,4,8],k=[0,0,0,0,3,1,1,1,2,2,2,3,3,3,4,4],_=[0,1,2,3,0,1,2,3,1,2,3,1,2,3,2,3];fp.slen1_tab=k,fp.slen2_tab=_;function g(f,y){for(var b,d=y.tt[1][f],x=y.tt[0][f],N=0;N<Ht.scfsi_band.length-1;N++){for(b=Ht.scfsi_band[N];b<Ht.scfsi_band[N+1]&&!(x.scalefac[b]!=d.scalefac[b]&&d.scalefac[b]>=0);b++);if(b==Ht.scfsi_band[N+1]){for(b=Ht.scfsi_band[N];b<Ht.scfsi_band[N+1];b++)d.scalefac[b]=-1;y.scfsi[f][N]=1}}var T=0,Y=0;for(b=0;b<11;b++)d.scalefac[b]!=-1&&(Y++,T<d.scalefac[b]&&(T=d.scalefac[b]));for(var j=0,X=0;b<P.SBPSY_l;b++)d.scalefac[b]!=-1&&(X++,j<d.scalefac[b]&&(j=d.scalefac[b]));for(var N=0;N<16;N++)if(T<B[N]&&j<V[N]){var _e=k[N]*Y+_[N]*X;d.part2_length>_e&&(d.part2_length=_e,d.scalefac_compress=N)}}this.best_scalefac_store=function(f,y,b,d){var x=d.tt[y][b],N,T,Y,j,X=0;for(Y=0,N=0;N<x.sfbmax;N++){var _e=x.width[N];for(mn(_e>=0),Y+=_e,j=-_e;j<0&&x.l3_enc[j+Y]==0;j++);j==0&&(x.scalefac[N]=X=-2)}if(x.scalefac_scale==0&&x.preflag==0){var h=0;for(N=0;N<x.sfbmax;N++)x.scalefac[N]>0&&(h|=x.scalefac[N]);if((h&1)==0&&h!=0){for(N=0;N<x.sfbmax;N++)x.scalefac[N]>0&&(x.scalefac[N]>>=1);x.scalefac_scale=X=1}}if(x.preflag==0&&x.block_type!=P.SHORT_TYPE&&f.mode_gr==2){for(N=11;N<P.SBPSY_l&&!(x.scalefac[N]<z.pretab[N]&&x.scalefac[N]!=-2);N++);if(N==P.SBPSY_l){for(N=11;N<P.SBPSY_l;N++)x.scalefac[N]>0&&(x.scalefac[N]-=z.pretab[N]);x.preflag=X=1}}for(T=0;T<4;T++)d.scfsi[b][T]=0;for(f.mode_gr==2&&y==1&&d.tt[0][b].block_type!=P.SHORT_TYPE&&d.tt[1][b].block_type!=P.SHORT_TYPE&&(g(b,d),X=0),N=0;N<x.sfbmax;N++)x.scalefac[N]==-2&&(x.scalefac[N]=0);X!=0&&(f.mode_gr==2?this.scale_bitcount(x):this.scale_bitcount_lsf(f,x))};function D(f,y){for(var b=0;b<y;++b)if(f[b]<0)return!1;return!0}var K=[0,18,36,54,54,36,54,72,54,72,90,72,90,108,108,126],w=[0,18,36,54,51,35,53,71,52,70,88,69,87,105,104,122],u=[0,10,20,30,33,21,31,41,32,42,52,43,53,63,64,74];this.scale_bitcount=function(f){var y,b,d=0,x=0,N,T=f.scalefac;if(mn(D(T,f.sfbmax)),f.block_type==P.SHORT_TYPE)N=K,f.mixed_block_flag!=0&&(N=w);else if(N=u,f.preflag==0){for(b=11;b<P.SBPSY_l&&!(T[b]<z.pretab[b]);b++);if(b==P.SBPSY_l)for(f.preflag=1,b=11;b<P.SBPSY_l;b++)T[b]-=z.pretab[b]}for(b=0;b<f.sfbdivide;b++)d<T[b]&&(d=T[b]);for(;b<f.sfbmax;b++)x<T[b]&&(x=T[b]);for(f.part2_length=Zi.LARGE_BITS,y=0;y<16;y++)d<B[y]&&x<V[y]&&f.part2_length>N[y]&&(f.part2_length=N[y],f.scalefac_compress=y);return f.part2_length==Zi.LARGE_BITS};var F=[[15,15,7,7],[15,15,7,0],[7,3,0,0],[15,31,31,0],[7,7,7,0],[3,3,0,0]];this.scale_bitcount_lsf=function(f,y){var b,d,x,N,T,Y,j,X,_e=Vl(4),h=y.scalefac;for(y.preflag!=0?b=2:b=0,j=0;j<4;j++)_e[j]=0;if(y.block_type==P.SHORT_TYPE){d=1;var v=z.nr_of_sfb_block[b][d];for(X=0,x=0;x<4;x++)for(N=v[x]/3,j=0;j<N;j++,X++)for(T=0;T<3;T++)h[X*3+T]>_e[x]&&(_e[x]=h[X*3+T])}else{d=0;var v=z.nr_of_sfb_block[b][d];for(X=0,x=0;x<4;x++)for(N=v[x],j=0;j<N;j++,X++)h[X]>_e[x]&&(_e[x]=h[X])}for(Y=!1,x=0;x<4;x++)_e[x]>F[b][x]&&(Y=!0);if(!Y){var de,ve,De,Ue;for(y.sfb_partition_table=z.nr_of_sfb_block[b][d],x=0;x<4;x++)y.slen[x]=R[_e[x]];switch(de=y.slen[0],ve=y.slen[1],De=y.slen[2],Ue=y.slen[3],b){case 0:y.scalefac_compress=(de*5+ve<<4)+(De<<2)+Ue;break;case 1:y.scalefac_compress=400+(de*5+ve<<2)+De;break;case 2:y.scalefac_compress=500+de*3+ve;break;default:L3.err.printf(`intensity stereo not implemented yet
2
- `);break}}if(!Y)for(mn(y.sfb_partition_table!=null),y.part2_length=0,x=0;x<4;x++)y.part2_length+=y.slen[x]*y.sfb_partition_table[x];return Y};var R=[0,1,2,2,3,3,3,3,4,4,4,4,4,4,4,4];this.huffman_init=function(f){for(var y=2;y<=576;y+=2){for(var b=0,d;f.scalefac_band.l[++b]<y;);for(d=ce[b][0];f.scalefac_band.l[d+1]>y;)d--;for(d<0&&(d=ce[b][0]),f.bv_scf[y-2]=d,d=ce[b][1];f.scalefac_band.l[d+f.bv_scf[y-2]+2]>y;)d--;d<0&&(d=ce[b][1]),f.bv_scf[y-1]=d}}}var hp=fp,Jn=C.System,H3=C.Arrays,D3=C.new_byte,k3=C.new_float_n,F3=C.new_int,Pt=C.assert;vm.EQ=function(z,te){return Math.abs(z)>Math.abs(te)?Math.abs(z-te)<=Math.abs(z)*1e-6:Math.abs(z-te)<=Math.abs(te)*1e-6},vm.NEQ=function(z,te){return!vm.EQ(z,te)};function vm(){var z=this,te=32773,ce=32,re=null,Ee=null,ie=null,ye=null;this.setModules=function(R,f,y,b){re=R,Ee=f,ie=y,ye=b};var ze=null,He=0,$=0,fe=0;this.getframebits=function(R){var f=R.internal_flags,y;f.bitrate_index!=0?y=Ht.bitrate_table[R.version][f.bitrate_index]:y=R.brate,Pt(8<=y&&y<=640);var b=0|(R.version+1)*72e3*y/R.out_samplerate+f.padding;return 8*b};function ge(R){Jn.arraycopy(R.header[R.w_ptr].buf,0,ze,$,R.sideinfo_len),$+=R.sideinfo_len,He+=R.sideinfo_len*8,R.w_ptr=R.w_ptr+1&rr.MAX_HEADER_BUF-1}function L(R,f,y){for(Pt(y<ce-2);y>0;){var b;fe==0&&(fe=8,$++,Pt($<Wt.LAME_MAXMP3BUFFER),Pt(R.header[R.w_ptr].write_timing>=He),R.header[R.w_ptr].write_timing==He&&ge(R),ze[$]=0),b=Math.min(y,fe),y-=b,fe-=b,Pt(y<ce),Pt(fe<ce),ze[$]|=f>>y<<fe,He+=b}}function Q(R,f,y){for(Pt(y<ce-2);y>0;){var b;fe==0&&(fe=8,$++,Pt($<Wt.LAME_MAXMP3BUFFER),ze[$]=0),b=Math.min(y,fe),y-=b,fe-=b,Pt(y<ce),Pt(fe<ce),ze[$]|=f>>y<<fe,He+=b}}function m(R,f){var y=R.internal_flags,b;if(Pt(f>=0),f>=8&&(L(y,76,8),f-=8),f>=8&&(L(y,65,8),f-=8),f>=8&&(L(y,77,8),f-=8),f>=8&&(L(y,69,8),f-=8),f>=32){var d=ie.getLameShortVersion();if(f>=32)for(b=0;b<d.length&&f>=8;++b)f-=8,L(y,d.charAt(b),8)}for(;f>=1;f-=1)L(y,y.ancillary_flag,1),y.ancillary_flag^=R.disable_reservoir?0:1;Pt(f==0)}function B(R,f,y){for(var b=R.header[R.h_ptr].ptr;y>0;){var d=Math.min(y,8-(b&7));y-=d,Pt(y<ce),R.header[R.h_ptr].buf[b>>3]|=f>>y<<8-(b&7)-d,b+=d}R.header[R.h_ptr].ptr=b}function V(R,f){R<<=8;for(var y=0;y<8;y++)R<<=1,f<<=1,((f^R)&65536)!=0&&(f^=te);return f}this.CRC_writeheader=function(R,f){var y=65535;y=V(f[2]&255,y),y=V(f[3]&255,y);for(var b=6;b<R.sideinfo_len;b++)y=V(f[b]&255,y);f[4]=byte(y>>8),f[5]=byte(y&255)};function k(R,f){var y=R.internal_flags,b,d,x;if(b=y.l3_side,y.header[y.h_ptr].ptr=0,H3.fill(y.header[y.h_ptr].buf,0,y.sideinfo_len,0),R.out_samplerate<16e3?B(y,4094,12):B(y,4095,12),B(y,R.version,1),B(y,4-3,2),B(y,R.error_protection?0:1,1),B(y,y.bitrate_index,4),B(y,y.samplerate_index,2),B(y,y.padding,1),B(y,R.extension,1),B(y,R.mode.ordinal(),2),B(y,y.mode_ext,2),B(y,R.copyright,1),B(y,R.original,1),B(y,R.emphasis,2),R.error_protection&&B(y,0,16),R.version==1){for(Pt(b.main_data_begin>=0),B(y,b.main_data_begin,9),y.channels_out==2?B(y,b.private_bits,3):B(y,b.private_bits,5),x=0;x<y.channels_out;x++){var N;for(N=0;N<4;N++)B(y,b.scfsi[x][N],1)}for(d=0;d<2;d++)for(x=0;x<y.channels_out;x++){var T=b.tt[d][x];B(y,T.part2_3_length+T.part2_length,12),B(y,T.big_values/2,9),B(y,T.global_gain,8),B(y,T.scalefac_compress,4),T.block_type!=P.NORM_TYPE?(B(y,1,1),B(y,T.block_type,2),B(y,T.mixed_block_flag,1),T.table_select[0]==14&&(T.table_select[0]=16),B(y,T.table_select[0],5),T.table_select[1]==14&&(T.table_select[1]=16),B(y,T.table_select[1],5),B(y,T.subblock_gain[0],3),B(y,T.subblock_gain[1],3),B(y,T.subblock_gain[2],3)):(B(y,0,1),T.table_select[0]==14&&(T.table_select[0]=16),B(y,T.table_select[0],5),T.table_select[1]==14&&(T.table_select[1]=16),B(y,T.table_select[1],5),T.table_select[2]==14&&(T.table_select[2]=16),B(y,T.table_select[2],5),Pt(0<=T.region0_count&&T.region0_count<16),Pt(0<=T.region1_count&&T.region1_count<8),B(y,T.region0_count,4),B(y,T.region1_count,3)),B(y,T.preflag,1),B(y,T.scalefac_scale,1),B(y,T.count1table_select,1)}}else for(Pt(b.main_data_begin>=0),B(y,b.main_data_begin,8),B(y,b.private_bits,y.channels_out),d=0,x=0;x<y.channels_out;x++){var T=b.tt[d][x];B(y,T.part2_3_length+T.part2_length,12),B(y,T.big_values/2,9),B(y,T.global_gain,8),B(y,T.scalefac_compress,9),T.block_type!=P.NORM_TYPE?(B(y,1,1),B(y,T.block_type,2),B(y,T.mixed_block_flag,1),T.table_select[0]==14&&(T.table_select[0]=16),B(y,T.table_select[0],5),T.table_select[1]==14&&(T.table_select[1]=16),B(y,T.table_select[1],5),B(y,T.subblock_gain[0],3),B(y,T.subblock_gain[1],3),B(y,T.subblock_gain[2],3)):(B(y,0,1),T.table_select[0]==14&&(T.table_select[0]=16),B(y,T.table_select[0],5),T.table_select[1]==14&&(T.table_select[1]=16),B(y,T.table_select[1],5),T.table_select[2]==14&&(T.table_select[2]=16),B(y,T.table_select[2],5),Pt(0<=T.region0_count&&T.region0_count<16),Pt(0<=T.region1_count&&T.region1_count<8),B(y,T.region0_count,4),B(y,T.region1_count,3)),B(y,T.scalefac_scale,1),B(y,T.count1table_select,1)}R.error_protection&&CRC_writeheader(y,y.header[y.h_ptr].buf);{var Y=y.h_ptr;Pt(y.header[Y].ptr==y.sideinfo_len*8),y.h_ptr=Y+1&rr.MAX_HEADER_BUF-1,y.header[y.h_ptr].write_timing=y.header[Y].write_timing+f,y.h_ptr==y.w_ptr&&Jn.err.println(`Error: MAX_HEADER_BUF too small in bitstream.c
3
- `)}}function _(R,f){var y=Ht.ht[f.count1table_select+32],b,d=0,x=f.big_values,N=f.big_values;for(Pt(f.count1table_select<2),b=(f.count1-f.big_values)/4;b>0;--b){var T=0,Y=0,j;j=f.l3_enc[x+0],j!=0&&(Y+=8,f.xr[N+0]<0&&T++,Pt(j<=1)),j=f.l3_enc[x+1],j!=0&&(Y+=4,T*=2,f.xr[N+1]<0&&T++,Pt(j<=1)),j=f.l3_enc[x+2],j!=0&&(Y+=2,T*=2,f.xr[N+2]<0&&T++,Pt(j<=1)),j=f.l3_enc[x+3],j!=0&&(Y++,T*=2,f.xr[N+3]<0&&T++,Pt(j<=1)),x+=4,N+=4,L(R,T+y.table[Y],y.hlen[Y]),d+=y.hlen[Y]}return d}function g(R,f,y,b,d){var x=Ht.ht[f],N=0;if(Pt(f<32),f==0)return N;for(var T=y;T<b;T+=2){var Y=0,j=0,X=x.xlen,_e=x.xlen,h=0,v=d.l3_enc[T],de=d.l3_enc[T+1];if(v!=0&&(d.xr[T]<0&&h++,Y--),f>15){if(v>14){var ve=v-15;Pt(ve<=x.linmax),h|=ve<<1,j=X,v=15}if(de>14){var De=de-15;Pt(De<=x.linmax),h<<=X,h|=De,j+=X,de=15}_e=16}de!=0&&(h<<=1,d.xr[T+1]<0&&h++,Y--),Pt((v|de)<16),v=v*_e+de,j-=Y,Y+=x.hlen[v],Pt(Y<=ce),Pt(j<=ce),L(R,x.table[v],Y),L(R,h,j),N+=Y+j}return N}function D(R,f){var y=3*R.scalefac_band.s[3];y>f.big_values&&(y=f.big_values);var b=g(R,f.table_select[0],0,y,f);return b+=g(R,f.table_select[1],y,f.big_values,f),b}function K(R,f){var y,b,d,x;y=f.big_values,Pt(0<=y&&y<=576);var N=f.region0_count+1;return Pt(0<=N),Pt(N<R.scalefac_band.l.length),d=R.scalefac_band.l[N],N+=f.region1_count+1,Pt(0<=N),Pt(N<R.scalefac_band.l.length),x=R.scalefac_band.l[N],d>y&&(d=y),x>y&&(x=y),b=g(R,f.table_select[0],0,d,f),b+=g(R,f.table_select[1],d,x,f),b+=g(R,f.table_select[2],x,y,f),b}function w(R){var f,y,b,d,x=0,N=R.internal_flags,T=N.l3_side;if(R.version==1)for(f=0;f<2;f++)for(y=0;y<N.channels_out;y++){var Y=T.tt[f][y],j=hp.slen1_tab[Y.scalefac_compress],X=hp.slen2_tab[Y.scalefac_compress];for(d=0,b=0;b<Y.sfbdivide;b++)Y.scalefac[b]!=-1&&(L(N,Y.scalefac[b],j),d+=j);for(;b<Y.sfbmax;b++)Y.scalefac[b]!=-1&&(L(N,Y.scalefac[b],X),d+=X);Pt(d==Y.part2_length),Y.block_type==P.SHORT_TYPE?d+=D(N,Y):d+=K(N,Y),d+=_(N,Y),Pt(d==Y.part2_3_length+Y.part2_length),x+=d}else for(f=0,y=0;y<N.channels_out;y++){var Y=T.tt[f][y],_e,h,v=0;if(Pt(Y.sfb_partition_table!=null),d=0,b=0,h=0,Y.block_type==P.SHORT_TYPE){for(;h<4;h++){var de=Y.sfb_partition_table[h]/3,ve=Y.slen[h];for(_e=0;_e<de;_e++,b++)L(N,Math.max(Y.scalefac[b*3+0],0),ve),L(N,Math.max(Y.scalefac[b*3+1],0),ve),L(N,Math.max(Y.scalefac[b*3+2],0),ve),v+=3*ve}d+=D(N,Y)}else{for(;h<4;h++){var de=Y.sfb_partition_table[h],ve=Y.slen[h];for(_e=0;_e<de;_e++,b++)L(N,Math.max(Y.scalefac[b],0),ve),v+=ve}d+=K(N,Y)}d+=_(N,Y),Pt(d==Y.part2_3_length),Pt(v==Y.part2_length),x+=v+d}return x}function u(){this.total=0}function F(R,f){var y=R.internal_flags,b,d,x,N,T;return T=y.w_ptr,N=y.h_ptr-1,N==-1&&(N=rr.MAX_HEADER_BUF-1),b=y.header[N].write_timing-He,f.total=b,b>=0&&(d=1+N-T,N<T&&(d=1+N-T+rr.MAX_HEADER_BUF),b-=d*8*y.sideinfo_len),x=z.getframebits(R),b+=x,f.total+=x,f.total%8!=0?f.total=1+f.total/8:f.total=f.total/8,f.total+=$+1,b<0&&Jn.err.println(`strange error flushing buffer ...
4
- `),b}this.flush_bitstream=function(R){var f=R.internal_flags,y,b,d=f.h_ptr-1;if(d==-1&&(d=rr.MAX_HEADER_BUF-1),y=f.l3_side,!((b=F(R,new u))<0)){if(m(R,b),Pt(f.header[d].write_timing+this.getframebits(R)==He),f.ResvSize=0,y.main_data_begin=0,f.findReplayGain){var x=re.GetTitleGain(f.rgdata);Pt(NEQ(x,Xl.GAIN_NOT_ENOUGH_SAMPLES)),f.RadioGain=Math.floor(x*10+.5)|0}f.findPeakSample&&(f.noclipGainChange=Math.ceil(Math.log10(f.PeakSample/32767)*20*10)|0,f.noclipGainChange>0&&(EQ(R.scale,1)||EQ(R.scale,0))?f.noclipScale=Math.floor(32767/f.PeakSample*100)/100:f.noclipScale=-1)}},this.add_dummy_byte=function(R,f,y){for(var b=R.internal_flags,d;y-- >0;)for(Q(b,f,8),d=0;d<rr.MAX_HEADER_BUF;++d)b.header[d].write_timing+=8},this.format_bitstream=function(R){var f=R.internal_flags,y;y=f.l3_side;var b=this.getframebits(R);m(R,y.resvDrain_pre),k(R,b);var d=8*f.sideinfo_len;if(d+=w(R),m(R,y.resvDrain_post),d+=y.resvDrain_post,y.main_data_begin+=(b-d)/8,F(R,new u)!=f.ResvSize&&Jn.err.println("Internal buffer inconsistency. flushbits <> ResvSize"),y.main_data_begin*8!=f.ResvSize&&(Jn.err.printf(`bit reservoir error:
1
+ "use strict";(()=>{var G2=Object.create;var j1=Object.defineProperty;var X2=Object.getOwnPropertyDescriptor;var K2=Object.getOwnPropertyNames;var W2=Object.getPrototypeOf,Y2=Object.prototype.hasOwnProperty;var z1=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var $2=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of K2(t))!Y2.call(e,a)&&a!==r&&j1(e,a,{get:()=>t[a],enumerable:!(n=X2(t,a))||n.enumerable});return e};var G1=(e,t,r)=>(r=e!=null?G2(W2(e)):{},$2(t||!e||!e.__esModule?j1(r,"default",{value:e,enumerable:!0}):r,e));var X1=z1((cs,fs)=>{"use strict";(function(e,t){typeof cs=="object"&&typeof fs<"u"?fs.exports=t():typeof define=="function"&&define.amd?define(t):e.MicRecorder=t()})(cs,function(){function e(C){return new Int8Array(C)}function t(C){return new Int16Array(C)}function r(C){return new Int32Array(C)}function n(C){return new Float32Array(C)}function a(C){return new Float64Array(C)}function i(C){if(C.length==1)return n(C[0]);var $=C[0];C=C.slice(1);for(var ie=[],Z=0;Z<$;Z++)ie.push(i(C));return ie}function s(C){if(C.length==1)return r(C[0]);var $=C[0];C=C.slice(1);for(var ie=[],Z=0;Z<$;Z++)ie.push(s(C));return ie}function m(C){if(C.length==1)return t(C[0]);var $=C[0];C=C.slice(1);for(var ie=[],Z=0;Z<$;Z++)ie.push(m(C));return ie}function _(C){if(C.length==1)return new Array(C[0]);var $=C[0];C=C.slice(1);for(var ie=[],Z=0;Z<$;Z++)ie.push(_(C));return ie}var h={};h.fill=function(C,$,ie,Z){if(arguments.length==2)for(var Re=0;Re<C.length;Re++)C[Re]=arguments[1];else for(var Re=$;Re<ie;Re++)C[Re]=Z};var k={};k.arraycopy=function(C,$,ie,Z,Re){for(var J=$+Re;$<J;)ie[Z++]=C[$++]};var re={};re.SQRT2=1.4142135623730951,re.FAST_LOG10=function(C){return Math.log10(C)},re.FAST_LOG10_X=function(C,$){return Math.log10(C)*$};function oe(C){this.ordinal=C}oe.short_block_allowed=new oe(0),oe.short_block_coupled=new oe(1),oe.short_block_dispensed=new oe(2),oe.short_block_forced=new oe(3);var te={};te.MAX_VALUE=34028235e31;function D(C){this.ordinal=C}D.vbr_off=new D(0),D.vbr_mt=new D(1),D.vbr_rh=new D(2),D.vbr_abr=new D(3),D.vbr_mtrh=new D(4),D.vbr_default=D.vbr_mtrh;var Se=function(C){},P={System:k,VbrMode:D,Float:te,ShortBlock:oe,Util:re,Arrays:h,new_array_n:_,new_byte:e,new_double:a,new_float:n,new_float_n:i,new_int:r,new_int_n:s,new_short:t,new_short_n:m,assert:Se},se=P.System,ue=P.Util,De=P.Arrays,et=P.new_float;function ut(){var C=[-.1482523854003001,32.308141959636465,296.40344946382766,883.1344870032432,11113.947376231741,1057.2713659324597,305.7402417275812,30.825928907280012,3.8533188138216365,59.42900443849514,709.5899960123345,5281.91112291017,-5829.66483675846,-817.6293103748613,-76.91656988279972,-4.594269939176596,.9063471690191471,.1960342806591213,-.15466694054279598,34.324387823855965,301.8067566458425,817.599602898885,11573.795901679885,1181.2520595540152,321.59731579894424,31.232021761053772,3.7107095756221318,53.650946155329365,684.167428119626,5224.56624370173,-6366.391851890084,-908.9766368219582,-89.83068876699639,-5.411397422890401,.8206787908286602,.3901806440322567,-.16070888947830023,36.147034243915876,304.11815768187864,732.7429163887613,11989.60988270091,1300.012278487897,335.28490093152146,31.48816102859945,3.373875931311736,47.232241542899175,652.7371796173471,5132.414255594984,-6909.087078780055,-1001.9990371107289,-103.62185754286375,-6.104916304710272,.7416505462720353,.5805693545089249,-.16636367662261495,37.751650073343995,303.01103387567713,627.9747488785183,12358.763425278165,1412.2779918482834,346.7496836825721,31.598286663170416,3.1598635433980946,40.57878626349686,616.1671130880391,5007.833007176154,-7454.040671756168,-1095.7960341867115,-118.24411666465777,-6.818469345853504,.6681786379192989,.7653668647301797,-.1716176790982088,39.11551877123304,298.3413246578966,503.5259106886539,12679.589408408976,1516.5821921214542,355.9850766329023,31.395241710249053,2.9164211881972335,33.79716964664243,574.8943997801362,4853.234992253242,-7997.57021486075,-1189.7624067269965,-133.6444792601766,-7.7202770609839915,.5993769336819237,.9427934736519954,-.17645823955292173,40.21879108166477,289.9982036694474,359.3226160751053,12950.259102786438,1612.1013903507662,362.85067106591504,31.045922092242872,2.822222032597987,26.988862316190684,529.8996541764288,4671.371946949588,-8535.899136645805,-1282.5898586244496,-149.58553632943463,-8.643494270763135,.5345111359507916,1.111140466039205,-.36174739330527045,41.04429910497807,277.5463268268618,195.6386023135583,13169.43812144731,1697.6433561479398,367.40983966190305,30.557037410382826,2.531473372857427,20.070154905927314,481.50208566532336,4464.970341588308,-9065.36882077239,-1373.62841526722,-166.1660487028118,-9.58289321133207,.4729647758913199,1.268786568327291,-.36970682634889585,41.393213350082036,261.2935935556502,12.935476055240873,13336.131683328815,1772.508612059496,369.76534388639965,29.751323653701338,2.4023193045459172,13.304795348228817,430.5615775526625,4237.0568611071185,-9581.931701634761,-1461.6913552409758,-183.12733958476446,-10.718010163869403,.41421356237309503,1.414213562373095,-.37677560326535325,41.619486213528496,241.05423794991074,-187.94665032361226,13450.063605744153,1836.153896465782,369.4908799925761,29.001847876923147,2.0714759319987186,6.779591200894186,377.7767837205709,3990.386575512536,-10081.709459700915,-1545.947424837898,-200.3762958015653,-11.864482073055006,.3578057213145241,1.546020906725474,-.3829366947518991,41.1516456456653,216.47684307105183,-406.1569483347166,13511.136535077321,1887.8076599260432,367.3025214564151,28.136213436723654,1.913880671464418,.3829366947518991,323.85365704338597,3728.1472257487526,-10561.233882199509,-1625.2025997821418,-217.62525175416,-13.015432208941645,.3033466836073424,1.66293922460509,-.5822628872992417,40.35639251440489,188.20071124269245,-640.2706748618148,13519.21490106562,1927.6022433578062,362.8197642637487,26.968821921868447,1.7463817695935329,-5.62650678237171,269.3016715297017,3453.386536448852,-11016.145278780888,-1698.6569643425091,-234.7658734267683,-14.16351421663124,.2504869601913055,1.76384252869671,-.5887180101749253,39.23429103868072,155.76096234403798,-889.2492977967378,13475.470561874661,1955.0535223723712,356.4450994756727,25.894952980042156,1.5695032905781554,-11.181939564328772,214.80884394039484,3169.1640829158237,-11443.321309975563,-1765.1588461316153,-251.68908574481912,-15.49755935939164,.198912367379658,1.847759065022573,-.7912582233652842,37.39369355329111,119.699486012458,-1151.0956593239027,13380.446257078214,1970.3952110853447,348.01959814116185,24.731487364283044,1.3850130831637748,-16.421408865300393,161.05030052864092,2878.3322807850063,-11838.991423510031,-1823.985884688674,-268.2854986386903,-16.81724543849939,.1483359875383474,1.913880671464418,-.7960642926861912,35.2322109610459,80.01928065061526,-1424.0212633405113,13235.794061869668,1973.804052543835,337.9908651258184,23.289159354463873,1.3934255946442087,-21.099669467133474,108.48348407242611,2583.700758091299,-12199.726194855148,-1874.2780658979746,-284.2467154529415,-18.11369784385905,.09849140335716425,1.961570560806461,-.998795456205172,32.56307803611191,36.958364584370486,-1706.075448829146,13043.287458812016,1965.3831106103316,326.43182772364605,22.175018750622293,1.198638339011324,-25.371248002043963,57.53505923036915,2288.41886619975,-12522.674544337233,-1914.8400385312243,-299.26241273417224,-19.37805630698734,.04912684976946725,1.990369453344394,.035780907*ue.SQRT2*.5/2384e-9,.017876148*ue.SQRT2*.5/2384e-9,.003134727*ue.SQRT2*.5/2384e-9,.002457142*ue.SQRT2*.5/2384e-9,971317e-9*ue.SQRT2*.5/2384e-9,218868e-9*ue.SQRT2*.5/2384e-9,101566e-9*ue.SQRT2*.5/2384e-9,13828e-9*ue.SQRT2*.5/2384e-9,12804.797818791945,1945.5515939597317,313.4244966442953,20.801593959731544,1995.1556208053692,9.000838926174497,-29.20218120805369],$=12,ie=36,Z=[[2382191739347913e-28,6423305872147834e-28,9400849094049688e-28,1122435026096556e-27,1183840321267481e-27,1122435026096556e-27,940084909404969e-27,6423305872147839e-28,2382191739347918e-28,5456116108943412e-27,4878985199565852e-27,4240448995017367e-27,3559909094758252e-27,2858043359288075e-27,2156177623817898e-27,1475637723558783e-27,8371015190102974e-28,2599706096327376e-28,-5456116108943412e-27,-4878985199565852e-27,-4240448995017367e-27,-3559909094758252e-27,-2858043359288076e-27,-2156177623817898e-27,-1475637723558783e-27,-8371015190102975e-28,-2599706096327376e-28,-2382191739347923e-28,-6423305872147843e-28,-9400849094049696e-28,-1122435026096556e-27,-1183840321267481e-27,-1122435026096556e-27,-9400849094049694e-28,-642330587214784e-27,-2382191739347918e-28],[2382191739347913e-28,6423305872147834e-28,9400849094049688e-28,1122435026096556e-27,1183840321267481e-27,1122435026096556e-27,9400849094049688e-28,6423305872147841e-28,2382191739347918e-28,5456116108943413e-27,4878985199565852e-27,4240448995017367e-27,3559909094758253e-27,2858043359288075e-27,2156177623817898e-27,1475637723558782e-27,8371015190102975e-28,2599706096327376e-28,-5461314069809755e-27,-4921085770524055e-27,-4343405037091838e-27,-3732668368707687e-27,-3093523840190885e-27,-2430835727329465e-27,-1734679010007751e-27,-974825365660928e-27,-2797435120168326e-28,0,0,0,0,0,0,-2283748241799531e-28,-4037858874020686e-28,-2146547464825323e-28],[.1316524975873958,.414213562373095,.7673269879789602,1.091308501069271,1.303225372841206,1.56968557711749,1.920982126971166,2.414213562373094,3.171594802363212,4.510708503662055,7.595754112725146,22.90376554843115,.984807753012208,.6427876096865394,.3420201433256688,.9396926207859084,-.1736481776669303,-.7660444431189779,.8660254037844387,.5,-.5144957554275265,-.4717319685649723,-.3133774542039019,-.1819131996109812,-.09457419252642064,-.04096558288530405,-.01419856857247115,-.003699974673760037,.8574929257125442,.8817419973177052,.9496286491027329,.9833145924917901,.9955178160675857,.9991605581781475,.999899195244447,.9999931550702802],[0,0,0,0,0,0,2283748241799531e-28,4037858874020686e-28,2146547464825323e-28,5461314069809755e-27,4921085770524055e-27,4343405037091838e-27,3732668368707687e-27,3093523840190885e-27,2430835727329466e-27,1734679010007751e-27,974825365660928e-27,2797435120168326e-28,-5456116108943413e-27,-4878985199565852e-27,-4240448995017367e-27,-3559909094758253e-27,-2858043359288075e-27,-2156177623817898e-27,-1475637723558782e-27,-8371015190102975e-28,-2599706096327376e-28,-2382191739347913e-28,-6423305872147834e-28,-9400849094049688e-28,-1122435026096556e-27,-1183840321267481e-27,-1122435026096556e-27,-9400849094049688e-28,-6423305872147841e-28,-2382191739347918e-28]],Re=Z[g.SHORT_TYPE],J=Z[g.SHORT_TYPE],me=Z[g.SHORT_TYPE],Fe=Z[g.SHORT_TYPE],Oe=[0,1,16,17,8,9,24,25,4,5,20,21,12,13,28,29,2,3,18,19,10,11,26,27,6,7,22,23,14,15,30,31];function z(M,X,o){for(var I=10,U=X+238-14-286,F=-15;F<0;F++){var x,p,N;x=C[I+-10],p=M[U+-224]*x,N=M[X+224]*x,x=C[I+-9],p+=M[U+-160]*x,N+=M[X+160]*x,x=C[I+-8],p+=M[U+-96]*x,N+=M[X+96]*x,x=C[I+-7],p+=M[U+-32]*x,N+=M[X+32]*x,x=C[I+-6],p+=M[U+32]*x,N+=M[X+-32]*x,x=C[I+-5],p+=M[U+96]*x,N+=M[X+-96]*x,x=C[I+-4],p+=M[U+160]*x,N+=M[X+-160]*x,x=C[I+-3],p+=M[U+224]*x,N+=M[X+-224]*x,x=C[I+-2],p+=M[X+-256]*x,N-=M[U+256]*x,x=C[I+-1],p+=M[X+-192]*x,N-=M[U+192]*x,x=C[I+0],p+=M[X+-128]*x,N-=M[U+128]*x,x=C[I+1],p+=M[X+-64]*x,N-=M[U+64]*x,x=C[I+2],p+=M[X+0]*x,N-=M[U+0]*x,x=C[I+3],p+=M[X+64]*x,N-=M[U+-64]*x,x=C[I+4],p+=M[X+128]*x,N-=M[U+-128]*x,x=C[I+5],p+=M[X+192]*x,N-=M[U+-192]*x,p*=C[I+6],x=N-p,o[30+F*2]=N+p,o[31+F*2]=C[I+7]*x,I+=18,X--,U++}{var p,N,q,w;N=M[X+-16]*C[I+-10],p=M[X+-32]*C[I+-2],N+=(M[X+-48]-M[X+16])*C[I+-9],p+=M[X+-96]*C[I+-1],N+=(M[X+-80]+M[X+48])*C[I+-8],p+=M[X+-160]*C[I+0],N+=(M[X+-112]-M[X+80])*C[I+-7],p+=M[X+-224]*C[I+1],N+=(M[X+-144]+M[X+112])*C[I+-6],p-=M[X+32]*C[I+2],N+=(M[X+-176]-M[X+144])*C[I+-5],p-=M[X+96]*C[I+3],N+=(M[X+-208]+M[X+176])*C[I+-4],p-=M[X+160]*C[I+4],N+=(M[X+-240]-M[X+208])*C[I+-3],p-=M[X+224],q=p-N,w=p+N,N=o[14],p=o[15]-N,o[31]=w+N,o[30]=q+p,o[15]=q-p,o[14]=w-N}{var u;u=o[28]-o[0],o[0]+=o[28],o[28]=u*C[I+-2*18+7],u=o[29]-o[1],o[1]+=o[29],o[29]=u*C[I+-2*18+7],u=o[26]-o[2],o[2]+=o[26],o[26]=u*C[I+-4*18+7],u=o[27]-o[3],o[3]+=o[27],o[27]=u*C[I+-4*18+7],u=o[24]-o[4],o[4]+=o[24],o[24]=u*C[I+-6*18+7],u=o[25]-o[5],o[5]+=o[25],o[25]=u*C[I+-6*18+7],u=o[22]-o[6],o[6]+=o[22],o[22]=u*ue.SQRT2,u=o[23]-o[7],o[7]+=o[23],o[23]=u*ue.SQRT2-o[7],o[7]-=o[6],o[22]-=o[7],o[23]-=o[22],u=o[6],o[6]=o[31]-u,o[31]=o[31]+u,u=o[7],o[7]=o[30]-u,o[30]=o[30]+u,u=o[22],o[22]=o[15]-u,o[15]=o[15]+u,u=o[23],o[23]=o[14]-u,o[14]=o[14]+u,u=o[20]-o[8],o[8]+=o[20],o[20]=u*C[I+-10*18+7],u=o[21]-o[9],o[9]+=o[21],o[21]=u*C[I+-10*18+7],u=o[18]-o[10],o[10]+=o[18],o[18]=u*C[I+-12*18+7],u=o[19]-o[11],o[11]+=o[19],o[19]=u*C[I+-12*18+7],u=o[16]-o[12],o[12]+=o[16],o[16]=u*C[I+-14*18+7],u=o[17]-o[13],o[13]+=o[17],o[17]=u*C[I+-14*18+7],u=-o[20]+o[24],o[20]+=o[24],o[24]=u*C[I+-12*18+7],u=-o[21]+o[25],o[21]+=o[25],o[25]=u*C[I+-12*18+7],u=o[4]-o[8],o[4]+=o[8],o[8]=u*C[I+-12*18+7],u=o[5]-o[9],o[5]+=o[9],o[9]=u*C[I+-12*18+7],u=o[0]-o[12],o[0]+=o[12],o[12]=u*C[I+-4*18+7],u=o[1]-o[13],o[1]+=o[13],o[13]=u*C[I+-4*18+7],u=o[16]-o[28],o[16]+=o[28],o[28]=u*C[I+-4*18+7],u=-o[17]+o[29],o[17]+=o[29],o[29]=u*C[I+-4*18+7],u=ue.SQRT2*(o[2]-o[10]),o[2]+=o[10],o[10]=u,u=ue.SQRT2*(o[3]-o[11]),o[3]+=o[11],o[11]=u,u=ue.SQRT2*(-o[18]+o[26]),o[18]+=o[26],o[26]=u-o[18],u=ue.SQRT2*(-o[19]+o[27]),o[19]+=o[27],o[27]=u-o[19],u=o[2],o[19]-=o[3],o[3]-=u,o[2]=o[31]-u,o[31]+=u,u=o[3],o[11]-=o[19],o[18]-=u,o[3]=o[30]-u,o[30]+=u,u=o[18],o[27]-=o[11],o[19]-=u,o[18]=o[15]-u,o[15]+=u,u=o[19],o[10]-=u,o[19]=o[14]-u,o[14]+=u,u=o[10],o[11]-=u,o[10]=o[23]-u,o[23]+=u,u=o[11],o[26]-=u,o[11]=o[22]-u,o[22]+=u,u=o[26],o[27]-=u,o[26]=o[7]-u,o[7]+=u,u=o[27],o[27]=o[6]-u,o[6]+=u,u=ue.SQRT2*(o[0]-o[4]),o[0]+=o[4],o[4]=u,u=ue.SQRT2*(o[1]-o[5]),o[1]+=o[5],o[5]=u,u=ue.SQRT2*(o[16]-o[20]),o[16]+=o[20],o[20]=u,u=ue.SQRT2*(o[17]-o[21]),o[17]+=o[21],o[21]=u,u=-ue.SQRT2*(o[8]-o[12]),o[8]+=o[12],o[12]=u-o[8],u=-ue.SQRT2*(o[9]-o[13]),o[9]+=o[13],o[13]=u-o[9],u=-ue.SQRT2*(o[25]-o[29]),o[25]+=o[29],o[29]=u-o[25],u=-ue.SQRT2*(o[24]+o[28]),o[24]-=o[28],o[28]=u-o[24],u=o[24]-o[16],o[24]=u,u=o[20]-u,o[20]=u,u=o[28]-u,o[28]=u,u=o[25]-o[17],o[25]=u,u=o[21]-u,o[21]=u,u=o[29]-u,o[29]=u,u=o[17]-o[1],o[17]=u,u=o[9]-u,o[9]=u,u=o[25]-u,o[25]=u,u=o[5]-u,o[5]=u,u=o[21]-u,o[21]=u,u=o[13]-u,o[13]=u,u=o[29]-u,o[29]=u,u=o[1]-o[0],o[1]=u,u=o[16]-u,o[16]=u,u=o[17]-u,o[17]=u,u=o[8]-u,o[8]=u,u=o[9]-u,o[9]=u,u=o[24]-u,o[24]=u,u=o[25]-u,o[25]=u,u=o[4]-u,o[4]=u,u=o[5]-u,o[5]=u,u=o[20]-u,o[20]=u,u=o[21]-u,o[21]=u,u=o[12]-u,o[12]=u,u=o[13]-u,o[13]=u,u=o[28]-u,o[28]=u,u=o[29]-u,o[29]=u,u=o[0],o[0]+=o[31],o[31]-=u,u=o[1],o[1]+=o[30],o[30]-=u,u=o[16],o[16]+=o[15],o[15]-=u,u=o[17],o[17]+=o[14],o[14]-=u,u=o[8],o[8]+=o[23],o[23]-=u,u=o[9],o[9]+=o[22],o[22]-=u,u=o[24],o[24]+=o[7],o[7]-=u,u=o[25],o[25]+=o[6],o[6]-=u,u=o[4],o[4]+=o[27],o[27]-=u,u=o[5],o[5]+=o[26],o[26]-=u,u=o[20],o[20]+=o[11],o[11]-=u,u=o[21],o[21]+=o[10],o[10]-=u,u=o[12],o[12]+=o[19],o[19]-=u,u=o[13],o[13]+=o[18],o[18]-=u,u=o[28],o[28]+=o[3],o[3]-=u,u=o[29],o[29]+=o[2],o[2]-=u}}function ve(M,X){for(var o=0;o<3;o++){var I,U,F,x,p,N;x=M[X+2*3]*Z[g.SHORT_TYPE][0]-M[X+5*3],I=M[X+0*3]*Z[g.SHORT_TYPE][2]-M[X+3*3],U=x+I,F=x-I,x=M[X+5*3]*Z[g.SHORT_TYPE][0]+M[X+2*3],I=M[X+3*3]*Z[g.SHORT_TYPE][2]+M[X+0*3],p=x+I,N=-x+I,I=(M[X+1*3]*Z[g.SHORT_TYPE][1]-M[X+4*3])*2069978111953089e-26,x=(M[X+4*3]*Z[g.SHORT_TYPE][1]+M[X+1*3])*2069978111953089e-26,M[X+3*0]=U*190752519173728e-25+I,M[X+3*5]=-p*190752519173728e-25+x,F=F*.8660254037844387*1907525191737281e-26,p=p*.5*1907525191737281e-26+x,M[X+3*1]=F-p,M[X+3*2]=F+p,U=U*.5*1907525191737281e-26-I,N=N*.8660254037844387*1907525191737281e-26,M[X+3*3]=U+N,M[X+3*4]=U-N,X++}}function pe(M,X,o){var I,U;{var F,x,p,N,q,w,u,L;F=o[17]-o[9],p=o[15]-o[11],N=o[14]-o[12],q=o[0]+o[8],w=o[1]+o[7],u=o[2]+o[6],L=o[3]+o[5],M[X+17]=q+u-L-(w-o[4]),U=(q+u-L)*J[12+7]+(w-o[4]),I=(F-p-N)*J[12+6],M[X+5]=I+U,M[X+6]=I-U,x=(o[16]-o[10])*J[12+6],w=w*J[12+7]+o[4],I=F*J[12+0]+x+p*J[12+1]+N*J[12+2],U=-q*J[12+4]+w-u*J[12+5]+L*J[12+3],M[X+1]=I+U,M[X+2]=I-U,I=F*J[12+1]-x-p*J[12+2]+N*J[12+0],U=-q*J[12+5]+w-u*J[12+3]+L*J[12+4],M[X+9]=I+U,M[X+10]=I-U,I=F*J[12+2]-x+p*J[12+0]-N*J[12+1],U=q*J[12+3]-w+u*J[12+4]-L*J[12+5],M[X+13]=I+U,M[X+14]=I-U}{var E,c,d,b,l,v,y,T;E=o[8]-o[0],d=o[6]-o[2],b=o[5]-o[3],l=o[17]+o[9],v=o[16]+o[10],y=o[15]+o[11],T=o[14]+o[12],M[X+0]=l+y+T+(v+o[13]),I=(l+y+T)*J[12+7]-(v+o[13]),U=(E-d+b)*J[12+6],M[X+11]=I+U,M[X+12]=I-U,c=(o[7]-o[1])*J[12+6],v=o[13]-v*J[12+7],I=l*J[12+3]-v+y*J[12+4]+T*J[12+5],U=E*J[12+2]+c+d*J[12+0]+b*J[12+1],M[X+3]=I+U,M[X+4]=I-U,I=-l*J[12+5]+v-y*J[12+3]-T*J[12+4],U=E*J[12+1]+c-d*J[12+2]-b*J[12+0],M[X+7]=I+U,M[X+8]=I-U,I=-l*J[12+4]+v-y*J[12+5]-T*J[12+3],U=E*J[12+0]-c+d*J[12+1]-b*J[12+2],M[X+15]=I+U,M[X+16]=I-U}}this.mdct_sub48=function(M,X,o){for(var I=X,U=286,F=0;F<M.channels_out;F++){for(var x=0;x<M.mode_gr;x++){for(var p,N=M.l3_side.tt[x][F],q=N.xr,w=0,u=M.sb_sample[F][1-x],L=0,E=0;E<18/2;E++)for(z(I,U,u[L]),z(I,U+32,u[L+1]),L+=2,U+=64,p=1;p<32;p+=2)u[L-1][p]*=-1;for(p=0;p<32;p++,w+=18){var c=N.block_type,d=M.sb_sample[F][x],b=M.sb_sample[F][1-x];if(N.mixed_block_flag!=0&&p<2&&(c=0),M.amp_filter[p]<1e-12)De.fill(q,w+0,w+18,0);else{if(M.amp_filter[p]<1)for(var E=0;E<18;E++)b[E][Oe[p]]*=M.amp_filter[p];if(c==g.SHORT_TYPE){for(var E=-$/4;E<0;E++){var l=Z[g.SHORT_TYPE][E+3];q[w+E*3+9]=d[9+E][Oe[p]]*l-d[8-E][Oe[p]],q[w+E*3+18]=d[14-E][Oe[p]]*l+d[15+E][Oe[p]],q[w+E*3+10]=d[15+E][Oe[p]]*l-d[14-E][Oe[p]],q[w+E*3+19]=b[2-E][Oe[p]]*l+b[3+E][Oe[p]],q[w+E*3+11]=b[3+E][Oe[p]]*l-b[2-E][Oe[p]],q[w+E*3+20]=b[8-E][Oe[p]]*l+b[9+E][Oe[p]]}ve(q,w)}else{for(var v=et(18),E=-ie/4;E<0;E++){var y,T;y=Z[c][E+27]*b[E+9][Oe[p]]+Z[c][E+36]*b[8-E][Oe[p]],T=Z[c][E+9]*d[E+9][Oe[p]]-Z[c][E+18]*d[8-E][Oe[p]],v[E+9]=y-T*Re[3+E+9],v[E+18]=y*Re[3+E+9]+T}pe(q,w,v)}}if(c!=g.SHORT_TYPE&&p!=0)for(var E=7;E>=0;--E){var G,H;G=q[w+E]*me[20+E]+q[w+-1-E]*Fe[28+E],H=q[w+E]*Fe[28+E]-q[w+-1-E]*me[20+E],q[w+-1-E]=G,q[w+E]=H}}}if(I=o,U=286,M.mode_gr==1)for(var j=0;j<18;j++)se.arraycopy(M.sb_sample[F][1][j],0,M.sb_sample[F][0][j],0,32)}}}var ht=ut,st=P.System,yt=P.new_float,Vt=P.new_float_n;function zt(){this.l=yt(g.SBMAX_l),this.s=Vt([g.SBMAX_s,3]);var C=this;this.assign=function($){st.arraycopy($.l,0,C.l,0,g.SBMAX_l);for(var ie=0;ie<g.SBMAX_s;ie++)for(var Z=0;Z<3;Z++)C.s[ie][Z]=$.s[ie][Z]}}var Zt=zt;function kr(){this.thm=new Zt,this.en=new Zt}var Tr=kr,ar=P.System,fr=P.VbrMode,Wt=P.new_array_n,pt=P.new_float,Lt=P.new_float_n,Bt=P.new_int,Ct=P.assert;Ze.ENCDELAY=576,Ze.POSTDELAY=1152,Ze.MDCTDELAY=48,Ze.FFTOFFSET=224+Ze.MDCTDELAY,Ze.DECDELAY=528,Ze.SBLIMIT=32,Ze.CBANDS=64,Ze.SBPSY_l=21,Ze.SBPSY_s=12,Ze.SBMAX_l=22,Ze.SBMAX_s=13,Ze.PSFB21=6,Ze.PSFB12=6,Ze.BLKSIZE=1024,Ze.HBLKSIZE=Ze.BLKSIZE/2+1,Ze.BLKSIZE_s=256,Ze.HBLKSIZE_s=Ze.BLKSIZE_s/2+1,Ze.NORM_TYPE=0,Ze.START_TYPE=1,Ze.SHORT_TYPE=2,Ze.STOP_TYPE=3,Ze.MPG_MD_LR_LR=0,Ze.MPG_MD_LR_I=1,Ze.MPG_MD_MS_LR=2,Ze.MPG_MD_MS_I=3,Ze.fircoef=[-.0207887*5,-.0378413*5,-.0432472*5,-.031183*5,779609e-23*5,.0467745*5,.10091*5,.151365*5,.187098*5];function Ze(){var C=ht,$=Tr,ie=Ze.FFTOFFSET,Z=Ze.MPG_MD_MS_LR,Re=null;this.psy=null;var J=null,me=null,Fe=null;this.setModules=function(M,X,o,I){Re=M,this.psy=X,J=X,me=I,Fe=o};var Oe=new C;function z(M){var X,o;if(M.ATH.useAdjust==0){M.ATH.adjust=1;return}if(o=M.loudness_sq[0][0],X=M.loudness_sq[1][0],M.channels_out==2?(o+=M.loudness_sq[0][1],X+=M.loudness_sq[1][1]):(o+=o,X+=X),M.mode_gr==2&&(o=Math.max(o,X)),o*=.5,o*=M.ATH.aaSensitivityP,o>.03125)M.ATH.adjust>=1?M.ATH.adjust=1:M.ATH.adjust<M.ATH.adjustLimit&&(M.ATH.adjust=M.ATH.adjustLimit),M.ATH.adjustLimit=1;else{var I=31.98*o+625e-6;M.ATH.adjust>=I?(M.ATH.adjust*=I*.075+.925,M.ATH.adjust<I&&(M.ATH.adjust=I)):M.ATH.adjustLimit>=I?M.ATH.adjust=I:M.ATH.adjust<M.ATH.adjustLimit&&(M.ATH.adjust=M.ATH.adjustLimit),M.ATH.adjustLimit=I}}function ve(M){var X,o;for(Ct(0<=M.bitrate_index&&M.bitrate_index<16),Ct(0<=M.mode_ext&&M.mode_ext<4),M.bitrate_stereoMode_Hist[M.bitrate_index][4]++,M.bitrate_stereoMode_Hist[15][4]++,M.channels_out==2&&(M.bitrate_stereoMode_Hist[M.bitrate_index][M.mode_ext]++,M.bitrate_stereoMode_Hist[15][M.mode_ext]++),X=0;X<M.mode_gr;++X)for(o=0;o<M.channels_out;++o){var I=M.l3_side.tt[X][o].block_type|0;M.l3_side.tt[X][o].mixed_block_flag!=0&&(I=4),M.bitrate_blockType_Hist[M.bitrate_index][I]++,M.bitrate_blockType_Hist[M.bitrate_index][5]++,M.bitrate_blockType_Hist[15][I]++,M.bitrate_blockType_Hist[15][5]++}}function pe(M,X){var o=M.internal_flags,I,U;if(o.lame_encode_frame_init==0){var F,x,p=pt(2014),N=pt(286+1152+576);for(o.lame_encode_frame_init=1,F=0,x=0;F<286+576*(1+o.mode_gr);++F)F<576*o.mode_gr?(p[F]=0,o.channels_out==2&&(N[F]=0)):(p[F]=X[0][x],o.channels_out==2&&(N[F]=X[1][x]),++x);for(U=0;U<o.mode_gr;U++)for(I=0;I<o.channels_out;I++)o.l3_side.tt[U][I].block_type=Ze.SHORT_TYPE;Oe.mdct_sub48(o,p,N),Ct(576>=Ze.FFTOFFSET),Ct(o.mf_size>=Ze.BLKSIZE+M.framesize-Ze.FFTOFFSET),Ct(o.mf_size>=512+M.framesize-32)}}this.lame_encode_mp3_frame=function(M,X,o,I,U,F){var x,p=Wt([2,2]);p[0][0]=new $,p[0][1]=new $,p[1][0]=new $,p[1][1]=new $;var N=Wt([2,2]);N[0][0]=new $,N[0][1]=new $,N[1][0]=new $,N[1][1]=new $;var q,w=[null,null],u=M.internal_flags,L=Lt([2,4]),E=[.5,.5],c=[[0,0],[0,0]],d=[[0,0],[0,0]],b,l,v;if(w[0]=X,w[1]=o,u.lame_encode_frame_init==0&&pe(M,w),u.padding=0,(u.slot_lag-=u.frac_SpF)<0&&(u.slot_lag+=M.out_samplerate,u.padding=1),u.psymodel!=0){var y,T=[null,null],G=0,H=Bt(2);for(v=0;v<u.mode_gr;v++){for(l=0;l<u.channels_out;l++)T[l]=w[l],G=576+v*576-Ze.FFTOFFSET;if(M.VBR==fr.vbr_mtrh||M.VBR==fr.vbr_mt?y=J.L3psycho_anal_vbr(M,T,G,v,p,N,c[v],d[v],L[v],H):y=J.L3psycho_anal_ns(M,T,G,v,p,N,c[v],d[v],L[v],H),y!=0)return-4;for(M.mode==sr.JOINT_STEREO&&(E[v]=L[v][2]+L[v][3],E[v]>0&&(E[v]=L[v][3]/E[v])),l=0;l<u.channels_out;l++){var j=u.l3_side.tt[v][l];j.block_type=H[l],j.mixed_block_flag=0}}}else for(v=0;v<u.mode_gr;v++)for(l=0;l<u.channels_out;l++)u.l3_side.tt[v][l].block_type=Ze.NORM_TYPE,u.l3_side.tt[v][l].mixed_block_flag=0,d[v][l]=c[v][l]=700;if(z(u),Oe.mdct_sub48(u,w[0],w[1]),u.mode_ext=Ze.MPG_MD_LR_LR,M.force_ms)u.mode_ext=Ze.MPG_MD_MS_LR;else if(M.mode==sr.JOINT_STEREO){var be=0,f=0;for(v=0;v<u.mode_gr;v++)for(l=0;l<u.channels_out;l++)be+=d[v][l],f+=c[v][l];if(be<=1*f){var S=u.l3_side.tt[0],ce=u.l3_side.tt[u.mode_gr-1];S[0].block_type==S[1].block_type&&ce[0].block_type==ce[1].block_type&&(u.mode_ext=Ze.MPG_MD_MS_LR)}}if(u.mode_ext==Z?(q=N,b=d):(q=p,b=c),M.analysis&&u.pinfo!=null)for(v=0;v<u.mode_gr;v++)for(l=0;l<u.channels_out;l++)u.pinfo.ms_ratio[v]=u.ms_ratio[v],u.pinfo.ms_ener_ratio[v]=E[v],u.pinfo.blocktype[v][l]=u.l3_side.tt[v][l].block_type,u.pinfo.pe[v][l]=b[v][l],ar.arraycopy(u.l3_side.tt[v][l].xr,0,u.pinfo.xr[v][l],0,576),u.mode_ext==Z&&(u.pinfo.ers[v][l]=u.pinfo.ers[v][l+2],ar.arraycopy(u.pinfo.energy[v][l+2],0,u.pinfo.energy[v][l],0,u.pinfo.energy[v][l].length));if(M.VBR==fr.vbr_off||M.VBR==fr.vbr_abr){var xe,ke;for(xe=0;xe<18;xe++)u.nsPsy.pefirbuf[xe]=u.nsPsy.pefirbuf[xe+1];for(ke=0,v=0;v<u.mode_gr;v++)for(l=0;l<u.channels_out;l++)ke+=b[v][l];for(u.nsPsy.pefirbuf[18]=ke,ke=u.nsPsy.pefirbuf[9],xe=0;xe<9;xe++)ke+=(u.nsPsy.pefirbuf[xe]+u.nsPsy.pefirbuf[18-xe])*Ze.fircoef[xe];for(ke=670*5*u.mode_gr*u.channels_out/ke,v=0;v<u.mode_gr;v++)for(l=0;l<u.channels_out;l++)b[v][l]*=ke}if(u.iteration_loop.iteration_loop(M,b,E,q),Re.format_bitstream(M),x=Re.copy_buffer(u,I,U,F,1),M.bWriteVbrTag&&me.addVbrFrame(M),M.analysis&&u.pinfo!=null){for(l=0;l<u.channels_out;l++){var Ve;for(Ve=0;Ve<ie;Ve++)u.pinfo.pcmdata[l][Ve]=u.pinfo.pcmdata[l][Ve+M.framesize];for(Ve=ie;Ve<1600;Ve++)u.pinfo.pcmdata[l][Ve]=w[l][Ve-ie]}Fe.set_frame_pinfo(M,q)}return ve(u),x}}var g=Ze,K=P.Util,we=P.new_float;function He(){var C=we(g.BLKSIZE),$=we(g.BLKSIZE_s/2),ie=[.9238795325112867,.3826834323650898,.9951847266721969,.0980171403295606,.9996988186962042,.02454122852291229,.9999811752826011,.006135884649154475];function Z(J,me,Fe){var Oe=0,z,ve,pe;Fe<<=1;var M=me+Fe;z=4;do{var X,o,I,U,F,x,p;p=z>>1,U=z,F=z<<1,x=F+U,z=F<<1,ve=me,pe=ve+p;do{var N,q,w,u;q=J[ve+0]-J[ve+U],N=J[ve+0]+J[ve+U],u=J[ve+F]-J[ve+x],w=J[ve+F]+J[ve+x],J[ve+F]=N-w,J[ve+0]=N+w,J[ve+x]=q-u,J[ve+U]=q+u,q=J[pe+0]-J[pe+U],N=J[pe+0]+J[pe+U],u=K.SQRT2*J[pe+x],w=K.SQRT2*J[pe+F],J[pe+F]=N-w,J[pe+0]=N+w,J[pe+x]=q-u,J[pe+U]=q+u,pe+=z,ve+=z}while(ve<M);for(o=ie[Oe+0],X=ie[Oe+1],I=1;I<p;I++){var L,E;L=1-2*X*X,E=2*X*o,ve=me+I,pe=me+U-I;do{var c,d,b,N,q,l,w,v,u,y;d=E*J[ve+U]-L*J[pe+U],c=L*J[ve+U]+E*J[pe+U],q=J[ve+0]-c,N=J[ve+0]+c,l=J[pe+0]-d,b=J[pe+0]+d,d=E*J[ve+x]-L*J[pe+x],c=L*J[ve+x]+E*J[pe+x],u=J[ve+F]-c,w=J[ve+F]+c,y=J[pe+F]-d,v=J[pe+F]+d,d=X*w-o*y,c=o*w+X*y,J[ve+F]=N-c,J[ve+0]=N+c,J[pe+x]=l-d,J[pe+U]=l+d,d=o*v-X*u,c=X*v+o*u,J[pe+F]=b-c,J[pe+0]=b+c,J[ve+x]=q-d,J[ve+U]=q+d,pe+=z,ve+=z}while(ve<M);L=o,o=L*ie[Oe+0]-X*ie[Oe+1],X=L*ie[Oe+1]+X*ie[Oe+0]}Oe+=2}while(z<Fe)}var Re=[0,128,64,192,32,160,96,224,16,144,80,208,48,176,112,240,8,136,72,200,40,168,104,232,24,152,88,216,56,184,120,248,4,132,68,196,36,164,100,228,20,148,84,212,52,180,116,244,12,140,76,204,44,172,108,236,28,156,92,220,60,188,124,252,2,130,66,194,34,162,98,226,18,146,82,210,50,178,114,242,10,138,74,202,42,170,106,234,26,154,90,218,58,186,122,250,6,134,70,198,38,166,102,230,22,150,86,214,54,182,118,246,14,142,78,206,46,174,110,238,30,158,94,222,62,190,126,254];this.fft_short=function(J,me,Fe,Oe,z){for(var ve=0;ve<3;ve++){var pe=g.BLKSIZE_s/2,M=65535&576/3*(ve+1),X=g.BLKSIZE_s/8-1;do{var o,I,U,F,x,p=Re[X<<2]&255;o=$[p]*Oe[Fe][z+p+M],x=$[127-p]*Oe[Fe][z+p+M+128],I=o-x,o=o+x,U=$[p+64]*Oe[Fe][z+p+M+64],x=$[63-p]*Oe[Fe][z+p+M+192],F=U-x,U=U+x,pe-=4,me[ve][pe+0]=o+U,me[ve][pe+2]=o-U,me[ve][pe+1]=I+F,me[ve][pe+3]=I-F,o=$[p+1]*Oe[Fe][z+p+M+1],x=$[126-p]*Oe[Fe][z+p+M+129],I=o-x,o=o+x,U=$[p+65]*Oe[Fe][z+p+M+65],x=$[62-p]*Oe[Fe][z+p+M+193],F=U-x,U=U+x,me[ve][pe+g.BLKSIZE_s/2+0]=o+U,me[ve][pe+g.BLKSIZE_s/2+2]=o-U,me[ve][pe+g.BLKSIZE_s/2+1]=I+F,me[ve][pe+g.BLKSIZE_s/2+3]=I-F}while(--X>=0);Z(me[ve],pe,g.BLKSIZE_s/2)}},this.fft_long=function(J,me,Fe,Oe,z){var ve=g.BLKSIZE/8-1,pe=g.BLKSIZE/2;do{var M,X,o,I,U,F=Re[ve]&255;M=C[F]*Oe[Fe][z+F],U=C[F+512]*Oe[Fe][z+F+512],X=M-U,M=M+U,o=C[F+256]*Oe[Fe][z+F+256],U=C[F+768]*Oe[Fe][z+F+768],I=o-U,o=o+U,pe-=4,me[pe+0]=M+o,me[pe+2]=M-o,me[pe+1]=X+I,me[pe+3]=X-I,M=C[F+1]*Oe[Fe][z+F+1],U=C[F+513]*Oe[Fe][z+F+513],X=M-U,M=M+U,o=C[F+257]*Oe[Fe][z+F+257],U=C[F+769]*Oe[Fe][z+F+769],I=o-U,o=o+U,me[pe+g.BLKSIZE/2+0]=M+o,me[pe+g.BLKSIZE/2+2]=M-o,me[pe+g.BLKSIZE/2+1]=X+I,me[pe+g.BLKSIZE/2+3]=X-I}while(--ve>=0);Z(me,pe,g.BLKSIZE/2)},this.init_fft=function(J){for(var me=0;me<g.BLKSIZE;me++)C[me]=.42-.5*Math.cos(2*Math.PI*(me+.5)/g.BLKSIZE)+.08*Math.cos(4*Math.PI*(me+.5)/g.BLKSIZE);for(var me=0;me<g.BLKSIZE_s/2;me++)$[me]=.5*(1-Math.cos(2*Math.PI*(me+.5)/g.BLKSIZE_s))}}var Q=He,fe=P.VbrMode,Ee=P.Float,ge=P.ShortBlock,Te=P.Util,Ue=P.Arrays,Ae=P.new_float,$e=P.new_float_n,Qe=P.new_int,de=P.assert;function ir(){var C=new Q,$=2.302585092994046,ie=2,Z=16,Re=2,J=16,me=.34,Fe=1/(14752*14752)/(g.BLKSIZE/2),Oe=.01,z=.8,ve=.6,pe=.3,M=3.5,X=4.4,o=25,I=21,U=.2302585093;function F(R){return R}function x(R,A){for(var O=0,V=0;V<g.BLKSIZE/2;++V)O+=R[V]*A.ATH.eql_w[V];return O*=Fe,O}function p(R,A,O,V,ee,B,Y,ne,W,_e,ae){var he=R.internal_flags;if(W<2)C.fft_long(he,V[ee],W,_e,ae),C.fft_short(he,B[Y],W,_e,ae);else if(W==2){for(var qe=g.BLKSIZE-1;qe>=0;--qe){var at=V[ee+0][qe],Ce=V[ee+1][qe];V[ee+0][qe]=(at+Ce)*Te.SQRT2*.5,V[ee+1][qe]=(at-Ce)*Te.SQRT2*.5}for(var Je=2;Je>=0;--Je)for(var qe=g.BLKSIZE_s-1;qe>=0;--qe){var at=B[Y+0][Je][qe],Ce=B[Y+1][Je][qe];B[Y+0][Je][qe]=(at+Ce)*Te.SQRT2*.5,B[Y+1][Je][qe]=(at-Ce)*Te.SQRT2*.5}}A[0]=V[ee+0][0],A[0]*=A[0];for(var qe=g.BLKSIZE/2-1;qe>=0;--qe){var le=V[ee+0][g.BLKSIZE/2-qe],Ke=V[ee+0][g.BLKSIZE/2+qe];A[g.BLKSIZE/2-qe]=(le*le+Ke*Ke)*.5}for(var Je=2;Je>=0;--Je){O[Je][0]=B[Y+0][Je][0],O[Je][0]*=O[Je][0];for(var qe=g.BLKSIZE_s/2-1;qe>=0;--qe){var le=B[Y+0][Je][g.BLKSIZE_s/2-qe],Ke=B[Y+0][Je][g.BLKSIZE_s/2+qe];O[Je][g.BLKSIZE_s/2-qe]=(le*le+Ke*Ke)*.5}}{for(var _t=0,qe=11;qe<g.HBLKSIZE;qe++)_t+=A[qe];he.tot_ener[W]=_t}if(R.analysis){for(var qe=0;qe<g.HBLKSIZE;qe++)he.pinfo.energy[ne][W][qe]=he.pinfo.energy_save[W][qe],he.pinfo.energy_save[W][qe]=A[qe];he.pinfo.pe[ne][W]=he.pe[W]}R.athaa_loudapprox==2&&W<2&&(he.loudness_sq[ne][W]=he.loudness_sq_save[W],he.loudness_sq_save[W]=x(A,he))}var N=8,q=23,w=15,u,L,E,c=[1,.79433,.63096,.63096,.63096,.63096,.63096,.25119,.11749];function d(){u=Math.pow(10,(N+1)/16),L=Math.pow(10,(q+1)/16),E=Math.pow(10,w/10)}var b=[3.3246*3.3246,3.23837*3.23837,3.15437*3.15437,3.00412*3.00412,2.86103*2.86103,2.65407*2.65407,2.46209*2.46209,2.284*2.284,2.11879*2.11879,1.96552*1.96552,1.82335*1.82335,1.69146*1.69146,1.56911*1.56911,1.46658*1.46658,1.37074*1.37074,1.31036*1.31036,1.25264*1.25264,1.20648*1.20648,1.16203*1.16203,1.12765*1.12765,1.09428*1.09428,1.0659*1.0659,1.03826*1.03826,1.01895*1.01895,1],l=[1.33352*1.33352,1.35879*1.35879,1.38454*1.38454,1.39497*1.39497,1.40548*1.40548,1.3537*1.3537,1.30382*1.30382,1.22321*1.22321,1.14758*1.14758,1],v=[2.35364*2.35364,2.29259*2.29259,2.23313*2.23313,2.12675*2.12675,2.02545*2.02545,1.87894*1.87894,1.74303*1.74303,1.61695*1.61695,1.49999*1.49999,1.39148*1.39148,1.29083*1.29083,1.19746*1.19746,1.11084*1.11084,1.03826*1.03826];function y(R,A,O,V,ee,B){var Y;if(A>R)if(A<R*L)Y=A/R;else return R+A;else{if(R>=A*L)return R+A;Y=R/A}if(de(R>=0),de(A>=0),R+=A,V+3<=3+3){if(Y>=u)return R;var ne=0|Te.FAST_LOG10_X(Y,16);return R*l[ne]}var ne=0|Te.FAST_LOG10_X(Y,16);if(B!=0?A=ee.ATH.cb_s[O]*ee.ATH.adjust:A=ee.ATH.cb_l[O]*ee.ATH.adjust,de(A>=0),R<E*A){if(R>A){var W,_e;return W=1,ne<=13&&(W=v[ne]),_e=Te.FAST_LOG10_X(R/A,10/15),R*((b[ne]-W)*_e+W)}return ne>13?R:R*v[ne]}return R*b[ne]}var T=[1.33352*1.33352,1.35879*1.35879,1.38454*1.38454,1.39497*1.39497,1.40548*1.40548,1.3537*1.3537,1.30382*1.30382,1.22321*1.22321,1.14758*1.14758,1];function G(R,A,O){var V;if(R<0&&(R=0),A<0&&(A=0),R<=0)return A;if(A<=0)return R;if(A>R?V=A/R:V=R/A,-2<=O&&O<=2){if(V>=u)return R+A;var ee=0|Te.FAST_LOG10_X(V,16);return(R+A)*T[ee]}return V<L?R+A:(R<A&&(R=A),R)}function H(R,A){var O=R.internal_flags;if(O.channels_out>1){for(var V=0;V<g.SBMAX_l;V++){var ee=O.thm[0].l[V],B=O.thm[1].l[V];O.thm[0].l[V]+=B*A,O.thm[1].l[V]+=ee*A}for(var V=0;V<g.SBMAX_s;V++)for(var Y=0;Y<3;Y++){var ee=O.thm[0].s[V][Y],B=O.thm[1].s[V][Y];O.thm[0].s[V][Y]+=B*A,O.thm[1].s[V][Y]+=ee*A}}}function j(R){for(var A=0;A<g.SBMAX_l;A++)if(!(R.thm[0].l[A]>1.58*R.thm[1].l[A]||R.thm[1].l[A]>1.58*R.thm[0].l[A])){var O=R.mld_l[A]*R.en[3].l[A],V=Math.max(R.thm[2].l[A],Math.min(R.thm[3].l[A],O));O=R.mld_l[A]*R.en[2].l[A];var ee=Math.max(R.thm[3].l[A],Math.min(R.thm[2].l[A],O));R.thm[2].l[A]=V,R.thm[3].l[A]=ee}for(var A=0;A<g.SBMAX_s;A++)for(var B=0;B<3;B++)if(!(R.thm[0].s[A][B]>1.58*R.thm[1].s[A][B]||R.thm[1].s[A][B]>1.58*R.thm[0].s[A][B])){var O=R.mld_s[A]*R.en[3].s[A][B],V=Math.max(R.thm[2].s[A][B],Math.min(R.thm[3].s[A][B],O));O=R.mld_s[A]*R.en[2].s[A][B];var ee=Math.max(R.thm[3].s[A][B],Math.min(R.thm[2].s[A][B],O));R.thm[2].s[A][B]=V,R.thm[3].s[A][B]=ee}}function be(R,A,O){var V=A,ee=Math.pow(10,O);A*=2,V*=2;for(var B=0;B<g.SBMAX_l;B++){var Y,ne,W,_e;if(_e=R.ATH.cb_l[R.bm_l[B]]*ee,Y=Math.min(Math.max(R.thm[0].l[B],_e),Math.max(R.thm[1].l[B],_e)),ne=Math.max(R.thm[2].l[B],_e),W=Math.max(R.thm[3].l[B],_e),Y*A<ne+W){var ae=Y*V/(ne+W);ne*=ae,W*=ae,de(ne+W>0)}R.thm[2].l[B]=Math.min(ne,R.thm[2].l[B]),R.thm[3].l[B]=Math.min(W,R.thm[3].l[B])}ee*=g.BLKSIZE_s/g.BLKSIZE;for(var B=0;B<g.SBMAX_s;B++)for(var he=0;he<3;he++){var Y,ne,W,_e;if(_e=R.ATH.cb_s[R.bm_s[B]]*ee,Y=Math.min(Math.max(R.thm[0].s[B][he],_e),Math.max(R.thm[1].s[B][he],_e)),ne=Math.max(R.thm[2].s[B][he],_e),W=Math.max(R.thm[3].s[B][he],_e),Y*A<ne+W){var ae=Y*A/(ne+W);ne*=ae,W*=ae,de(ne+W>0)}R.thm[2].s[B][he]=Math.min(R.thm[2].s[B][he],ne),R.thm[3].s[B][he]=Math.min(R.thm[3].s[B][he],W)}}function f(R,A,O,V,ee){var B,Y,ne=0,W=0;for(B=Y=0;B<g.SBMAX_s;++Y,++B){for(var _e=R.bo_s[B],ae=R.npart_s,he=_e<ae?_e:ae;Y<he;)de(A[Y]>=0),de(O[Y]>=0),ne+=A[Y],W+=O[Y],Y++;if(R.en[V].s[B][ee]=ne,R.thm[V].s[B][ee]=W,Y>=ae){++B;break}de(A[Y]>=0),de(O[Y]>=0);{var qe=R.PSY.bo_s_weight[B],at=1-qe;ne=qe*A[Y],W=qe*O[Y],R.en[V].s[B][ee]+=ne,R.thm[V].s[B][ee]+=W,ne=at*A[Y],W=at*O[Y]}}for(;B<g.SBMAX_s;++B)R.en[V].s[B][ee]=0,R.thm[V].s[B][ee]=0}function S(R,A,O,V){var ee,B,Y=0,ne=0;for(ee=B=0;ee<g.SBMAX_l;++B,++ee){for(var W=R.bo_l[ee],_e=R.npart_l,ae=W<_e?W:_e;B<ae;)de(A[B]>=0),de(O[B]>=0),Y+=A[B],ne+=O[B],B++;if(R.en[V].l[ee]=Y,R.thm[V].l[ee]=ne,B>=_e){++ee;break}de(A[B]>=0),de(O[B]>=0);{var he=R.PSY.bo_l_weight[ee],qe=1-he;Y=he*A[B],ne=he*O[B],R.en[V].l[ee]+=Y,R.thm[V].l[ee]+=ne,Y=qe*A[B],ne=qe*O[B]}}for(;ee<g.SBMAX_l;++ee)R.en[V].l[ee]=0,R.thm[V].l[ee]=0}function ce(R,A,O,V,ee,B){var Y=R.internal_flags,ne,W;for(W=ne=0;W<Y.npart_s;++W){for(var _e=0,ae=0,he=Y.numlines_s[W],qe=0;qe<he;++qe,++ne){var at=A[B][ne];_e+=at,ae<at&&(ae=at)}O[W]=_e}for(de(W==Y.npart_s),de(ne==129),ne=W=0;W<Y.npart_s;W++){var Ce=Y.s3ind_s[W][0],Je=Y.s3_ss[ne++]*O[Ce];for(++Ce;Ce<=Y.s3ind_s[W][1];)Je+=Y.s3_ss[ne]*O[Ce],++ne,++Ce;{var le=Re*Y.nb_s1[ee][W];V[W]=Math.min(Je,le)}if(Y.blocktype_old[ee&1]==g.SHORT_TYPE){var le=J*Y.nb_s2[ee][W],Ke=V[W];V[W]=Math.min(le,Ke)}Y.nb_s2[ee][W]=Y.nb_s1[ee][W],Y.nb_s1[ee][W]=Je,de(V[W]>=0)}for(;W<=g.CBANDS;++W)O[W]=0,V[W]=0}function xe(R,A,O,V){var ee=R.internal_flags;R.short_blocks==ge.short_block_coupled&&!(A[0]!=0&&A[1]!=0)&&(A[0]=A[1]=0);for(var B=0;B<ee.channels_out;B++)V[B]=g.NORM_TYPE,R.short_blocks==ge.short_block_dispensed&&(A[B]=1),R.short_blocks==ge.short_block_forced&&(A[B]=0),A[B]!=0?(de(ee.blocktype_old[B]!=g.START_TYPE),ee.blocktype_old[B]==g.SHORT_TYPE&&(V[B]=g.STOP_TYPE)):(V[B]=g.SHORT_TYPE,ee.blocktype_old[B]==g.NORM_TYPE&&(ee.blocktype_old[B]=g.START_TYPE),ee.blocktype_old[B]==g.STOP_TYPE&&(ee.blocktype_old[B]=g.SHORT_TYPE)),O[B]=ee.blocktype_old[B],ee.blocktype_old[B]=V[B]}function ke(R,A,O){return O>=1?R:O<=0?A:A>0?Math.pow(R/A,O)*A:0}var Ve=[11.8,13.6,17.2,32,46.5,51.3,57.5,67.1,71.5,84.6,97.6,130];function Xe(R,A){for(var O=309.07,V=0;V<g.SBMAX_s-1;V++)for(var ee=0;ee<3;ee++){var B=R.thm.s[V][ee];if(de(V<Ve.length),B>0){var Y=B*A,ne=R.en.s[V][ee];ne>Y&&(ne>Y*1e10?O+=Ve[V]*(10*$):(de(Y>0),O+=Ve[V]*Te.FAST_LOG10(ne/Y)))}}return O}var Ge=[6.8,5.8,5.8,6.4,6.5,9.9,12.1,14.4,15,18.9,21.6,26.9,34.2,40.2,46.8,56.5,60.7,73.9,85.7,93.4,126.1];function it(R,A){for(var O=281.0575,V=0;V<g.SBMAX_l-1;V++){var ee=R.thm.l[V];if(de(V<Ge.length),ee>0){var B=ee*A,Y=R.en.l[V];Y>B&&(Y>B*1e10?O+=Ge[V]*(10*$):(de(B>0),O+=Ge[V]*Te.FAST_LOG10(Y/B)))}}return O}function We(R,A,O,V,ee){var B,Y;for(B=Y=0;B<R.npart_l;++B){var ne=0,W=0,_e;for(_e=0;_e<R.numlines_l[B];++_e,++Y){var ae=A[Y];de(ae>=0),ne+=ae,W<ae&&(W=ae)}O[B]=ne,V[B]=W,ee[B]=ne*R.rnumlines_l[B],de(R.rnumlines_l[B]>=0),de(ne>=0),de(O[B]>=0),de(V[B]>=0),de(ee[B]>=0)}}function je(R,A,O,V){var ee=c.length-1,B=0,Y=O[B]+O[B+1];if(de(Y>=0),Y>0){var ne=A[B];ne<A[B+1]&&(ne=A[B+1]),de(R.numlines_l[B]+R.numlines_l[B+1]-1>0),Y=20*(ne*2-Y)/(Y*(R.numlines_l[B]+R.numlines_l[B+1]-1));var W=0|Y;W>ee&&(W=ee),V[B]=W}else V[B]=0;for(B=1;B<R.npart_l-1;B++)if(Y=O[B-1]+O[B]+O[B+1],de(Y>=0),Y>0){var ne=A[B-1];ne<A[B]&&(ne=A[B]),ne<A[B+1]&&(ne=A[B+1]),de(R.numlines_l[B-1]+R.numlines_l[B]+R.numlines_l[B+1]-1>0),Y=20*(ne*3-Y)/(Y*(R.numlines_l[B-1]+R.numlines_l[B]+R.numlines_l[B+1]-1));var W=0|Y;W>ee&&(W=ee),V[B]=W}else V[B]=0;if(de(B>0),de(B==R.npart_l-1),Y=O[B-1]+O[B],de(Y>=0),Y>0){var ne=A[B-1];ne<A[B]&&(ne=A[B]),de(R.numlines_l[B-1]+R.numlines_l[B]-1>0),Y=20*(ne*2-Y)/(Y*(R.numlines_l[B-1]+R.numlines_l[B]-1));var W=0|Y;W>ee&&(W=ee),V[B]=W}else V[B]=0;de(B==R.npart_l-1)}var Tt=[-865163e-23*2,-.00851586*2,-674764e-23*2,.0209036*2,-336639e-22*2,-.0438162*2,-154175e-22*2,.0931738*2,-552212e-22*2,-.313819*2];this.L3psycho_anal_ns=function(R,A,O,V,ee,B,Y,ne,W,_e){var ae=R.internal_flags,he=$e([2,g.BLKSIZE]),qe=$e([2,3,g.BLKSIZE_s]),at=Ae(g.CBANDS+1),Ce=Ae(g.CBANDS+1),Je=Ae(g.CBANDS+2),le=Qe(2),Ke=Qe(2),_t,Be,Ye,Me,tt,Ut,ze,ct,mt=$e([2,576]),Gt,Yr=Qe(g.CBANDS+2),er=Qe(g.CBANDS+2);for(Ue.fill(er,0),_t=ae.channels_out,R.mode==sr.JOINT_STEREO&&(_t=4),R.VBR==fe.vbr_off?Gt=ae.ResvMax==0?0:ae.ResvSize/ae.ResvMax*.5:R.VBR==fe.vbr_rh||R.VBR==fe.vbr_mtrh||R.VBR==fe.vbr_mt?Gt=.6:Gt=1,Be=0;Be<ae.channels_out;Be++){var jt=A[Be],qr=O+576-350-I+192;for(de(Tt.length==(I-1)/2),Me=0;Me<576;Me++){var $r,Zr;for($r=jt[qr+Me+10],Zr=0,tt=0;tt<(I-1)/2-1;tt+=2)$r+=Tt[tt]*(jt[qr+Me+tt]+jt[qr+Me+I-tt]),Zr+=Tt[tt+1]*(jt[qr+Me+tt+1]+jt[qr+Me+I-tt-1]);mt[Be][Me]=$r+Zr}ee[V][Be].en.assign(ae.en[Be]),ee[V][Be].thm.assign(ae.thm[Be]),_t>2&&(B[V][Be].en.assign(ae.en[Be+2]),B[V][Be].thm.assign(ae.thm[Be+2]))}for(Be=0;Be<_t;Be++){var yn,gn,Ar=Ae(12),Hn=[0,0,0,0],ti=Ae(12),ts=1,O1,k1=Ae(g.CBANDS),H1=Ae(g.CBANDS),Xt=[0,0,0,0],U1=Ae(g.HBLKSIZE),V1=$e([3,g.HBLKSIZE_s]);for(de(ae.npart_s<=g.CBANDS),de(ae.npart_l<=g.CBANDS),Me=0;Me<3;Me++)Ar[Me]=ae.nsPsy.last_en_subshort[Be][Me+6],de(ae.nsPsy.last_en_subshort[Be][Me+4]>0),ti[Me]=Ar[Me]/ae.nsPsy.last_en_subshort[Be][Me+4],Hn[0]+=Ar[Me];if(Be==2)for(Me=0;Me<576;Me++){var rs,ns;rs=mt[0][Me],ns=mt[1][Me],mt[0][Me]=rs+ns,mt[1][Me]=rs-ns}{var q1=mt[Be&1],zi=0;for(Me=0;Me<9;Me++){for(var z2=zi+64,dr=1;zi<z2;zi++)dr<Math.abs(q1[zi])&&(dr=Math.abs(q1[zi]));ae.nsPsy.last_en_subshort[Be][Me]=Ar[Me+3]=dr,Hn[1+Me/3]+=dr,dr>Ar[Me+3-2]?(de(Ar[Me+3-2]>0),dr=dr/Ar[Me+3-2]):Ar[Me+3-2]>dr*10?(de(dr>0),dr=Ar[Me+3-2]/(dr*10)):dr=0,ti[Me+3]=dr}}if(R.analysis){var as=ti[0];for(Me=1;Me<12;Me++)as<ti[Me]&&(as=ti[Me]);ae.pinfo.ers[V][Be]=ae.pinfo.ers_save[Be],ae.pinfo.ers_save[Be]=as}for(O1=Be==3?ae.nsPsy.attackthre_s:ae.nsPsy.attackthre,Me=0;Me<12;Me++)Xt[Me/3]==0&&ti[Me]>O1&&(Xt[Me/3]=Me%3+1);for(Me=1;Me<4;Me++){var is;Hn[Me-1]>Hn[Me]?(de(Hn[Me]>0),is=Hn[Me-1]/Hn[Me]):(de(Hn[Me-1]>0),is=Hn[Me]/Hn[Me-1]),is<1.7&&(Xt[Me]=0,Me==1&&(Xt[0]=0))}for(Xt[0]!=0&&ae.nsPsy.lastAttacks[Be]!=0&&(Xt[0]=0),(ae.nsPsy.lastAttacks[Be]==3||Xt[0]+Xt[1]+Xt[2]+Xt[3]!=0)&&(ts=0,Xt[1]!=0&&Xt[0]!=0&&(Xt[1]=0),Xt[2]!=0&&Xt[1]!=0&&(Xt[2]=0),Xt[3]!=0&&Xt[2]!=0&&(Xt[3]=0)),Be<2?Ke[Be]=ts:ts==0&&(Ke[0]=Ke[1]=0),W[Be]=ae.tot_ener[Be],gn=qe,yn=he,p(R,U1,V1,yn,Be&1,gn,Be&1,V,Be,A,O),We(ae,U1,at,k1,H1),je(ae,k1,H1,Yr),ct=0;ct<3;ct++){var os,jr;for(ce(R,V1,Ce,Je,Be,ct),f(ae,Ce,Je,Be,ct),ze=0;ze<g.SBMAX_s;ze++){if(jr=ae.thm[Be].s[ze][ct],jr*=z,Xt[ct]>=2||Xt[ct+1]==1){var Gi=ct!=0?ct-1:2,dr=ke(ae.thm[Be].s[ze][Gi],jr,ve*Gt);jr=Math.min(jr,dr)}if(Xt[ct]==1){var Gi=ct!=0?ct-1:2,dr=ke(ae.thm[Be].s[ze][Gi],jr,pe*Gt);jr=Math.min(jr,dr)}else if(ct!=0&&Xt[ct-1]==3||ct==0&&ae.nsPsy.lastAttacks[Be]==3){var Gi=ct!=2?ct+1:0,dr=ke(ae.thm[Be].s[ze][Gi],jr,pe*Gt);jr=Math.min(jr,dr)}os=Ar[ct*3+3]+Ar[ct*3+4]+Ar[ct*3+5],Ar[ct*3+5]*6<os&&(jr*=.5,Ar[ct*3+4]*6<os&&(jr*=.5)),ae.thm[Be].s[ze][ct]=jr}}for(ae.nsPsy.lastAttacks[Be]=Xt[2],Ut=0,Ye=0;Ye<ae.npart_l;Ye++){for(var Ma=ae.s3ind[Ye][0],ss=at[Ma]*c[Yr[Ma]],Ba=ae.s3_ll[Ut++]*ss;++Ma<=ae.s3ind[Ye][1];)ss=at[Ma]*c[Yr[Ma]],Ba=y(Ba,ae.s3_ll[Ut++]*ss,Ma,Ma-Ye,ae,0);Ba*=.158489319246111,ae.blocktype_old[Be&1]==g.SHORT_TYPE?Je[Ye]=Ba:Je[Ye]=ke(Math.min(Ba,Math.min(ie*ae.nb_1[Be][Ye],Z*ae.nb_2[Be][Ye])),Ba,Gt),ae.nb_2[Be][Ye]=ae.nb_1[Be][Ye],ae.nb_1[Be][Ye]=Ba}for(;Ye<=g.CBANDS;++Ye)at[Ye]=0,Je[Ye]=0;S(ae,at,Je,Be)}if((R.mode==sr.STEREO||R.mode==sr.JOINT_STEREO)&&R.interChRatio>0&&H(R,R.interChRatio),R.mode==sr.JOINT_STEREO){var ls;j(ae),ls=R.msfix,Math.abs(ls)>0&&be(ae,ls,R.ATHlower*ae.ATH.adjust)}for(xe(R,Ke,_e,le),Be=0;Be<_t;Be++){var Xi,Ki=0,Xo,Ko;Be>1?(Xi=ne,Ki=-2,Xo=g.NORM_TYPE,(_e[0]==g.SHORT_TYPE||_e[1]==g.SHORT_TYPE)&&(Xo=g.SHORT_TYPE),Ko=B[V][Be-2]):(Xi=Y,Ki=0,Xo=_e[Be],Ko=ee[V][Be]),Xo==g.SHORT_TYPE?Xi[Ki+Be]=Xe(Ko,ae.masking_lower):Xi[Ki+Be]=it(Ko,ae.masking_lower),R.analysis&&(ae.pinfo.pe[V][Be]=Xi[Ki+Be])}return 0};function kt(R,A,O,V,ee,B,Y,ne){var W=R.internal_flags;if(V<2)C.fft_long(W,Y[ne],V,A,O);else if(V==2)for(var _e=g.BLKSIZE-1;_e>=0;--_e){var ae=Y[ne+0][_e],he=Y[ne+1][_e];Y[ne+0][_e]=(ae+he)*Te.SQRT2*.5,Y[ne+1][_e]=(ae-he)*Te.SQRT2*.5}B[0]=Y[ne+0][0],B[0]*=B[0];for(var _e=g.BLKSIZE/2-1;_e>=0;--_e){var qe=Y[ne+0][g.BLKSIZE/2-_e],at=Y[ne+0][g.BLKSIZE/2+_e];B[g.BLKSIZE/2-_e]=(qe*qe+at*at)*.5}{for(var Ce=0,_e=11;_e<g.HBLKSIZE;_e++)Ce+=B[_e];W.tot_ener[V]=Ce}if(R.analysis){for(var _e=0;_e<g.HBLKSIZE;_e++)W.pinfo.energy[ee][V][_e]=W.pinfo.energy_save[V][_e],W.pinfo.energy_save[V][_e]=B[_e];W.pinfo.pe[ee][V]=W.pe[V]}}function At(R,A,O,V,ee,B,Y,ne){var W=R.internal_flags;if(ee==0&&V<2&&C.fft_short(W,Y[ne],V,A,O),V==2)for(var _e=g.BLKSIZE_s-1;_e>=0;--_e){var ae=Y[ne+0][ee][_e],he=Y[ne+1][ee][_e];Y[ne+0][ee][_e]=(ae+he)*Te.SQRT2*.5,Y[ne+1][ee][_e]=(ae-he)*Te.SQRT2*.5}B[ee][0]=Y[ne+0][ee][0],B[ee][0]*=B[ee][0];for(var _e=g.BLKSIZE_s/2-1;_e>=0;--_e){var qe=Y[ne+0][ee][g.BLKSIZE_s/2-_e],at=Y[ne+0][ee][g.BLKSIZE_s/2+_e];B[ee][g.BLKSIZE_s/2-_e]=(qe*qe+at*at)*.5}}function Ht(R,A,O,V){var ee=R.internal_flags;R.athaa_loudapprox==2&&O<2&&(ee.loudness_sq[A][O]=ee.loudness_sq_save[O],ee.loudness_sq_save[O]=x(V,ee))}var Yt=[-865163e-23*2,-.00851586*2,-674764e-23*2,.0209036*2,-336639e-22*2,-.0438162*2,-154175e-22*2,.0931738*2,-552212e-22*2,-.313819*2];function Qt(R,A,O,V,ee,B,Y,ne,W,_e){for(var ae=$e([2,576]),he=R.internal_flags,qe=he.channels_out,at=R.mode==sr.JOINT_STEREO?4:qe,Ce=0;Ce<qe;Ce++){firbuf=A[Ce];var Je=O+576-350-I+192;de(Yt.length==(I-1)/2);for(var le=0;le<576;le++){var Ke,_t;Ke=firbuf[Je+le+10],_t=0;for(var Be=0;Be<(I-1)/2-1;Be+=2)Ke+=Yt[Be]*(firbuf[Je+le+Be]+firbuf[Je+le+I-Be]),_t+=Yt[Be+1]*(firbuf[Je+le+Be+1]+firbuf[Je+le+I-Be-1]);ae[Ce][le]=Ke+_t}ee[V][Ce].en.assign(he.en[Ce]),ee[V][Ce].thm.assign(he.thm[Ce]),at>2&&(B[V][Ce].en.assign(he.en[Ce+2]),B[V][Ce].thm.assign(he.thm[Ce+2]))}for(var Ce=0;Ce<at;Ce++){var Ye=Ae(12),Me=Ae(12),tt=[0,0,0,0],Ut=ae[Ce&1],ze=0,ct=Ce==3?he.nsPsy.attackthre_s:he.nsPsy.attackthre,mt=1;if(Ce==2)for(var le=0,Be=576;Be>0;++le,--Be){var Gt=ae[0][le],Yr=ae[1][le];ae[0][le]=Gt+Yr,ae[1][le]=Gt-Yr}for(var le=0;le<3;le++)Me[le]=he.nsPsy.last_en_subshort[Ce][le+6],de(he.nsPsy.last_en_subshort[Ce][le+4]>0),Ye[le]=Me[le]/he.nsPsy.last_en_subshort[Ce][le+4],tt[0]+=Me[le];for(var le=0;le<9;le++){for(var er=ze+64,jt=1;ze<er;ze++)jt<Math.abs(Ut[ze])&&(jt=Math.abs(Ut[ze]));he.nsPsy.last_en_subshort[Ce][le]=Me[le+3]=jt,tt[1+le/3]+=jt,jt>Me[le+3-2]?(de(Me[le+3-2]>0),jt=jt/Me[le+3-2]):Me[le+3-2]>jt*10?(de(jt>0),jt=Me[le+3-2]/(jt*10)):jt=0,Ye[le+3]=jt}for(var le=0;le<3;++le){var qr=Me[le*3+3]+Me[le*3+4]+Me[le*3+5],$r=1;Me[le*3+5]*6<qr&&($r*=.5,Me[le*3+4]*6<qr&&($r*=.5)),ne[Ce][le]=$r}if(R.analysis){for(var Zr=Ye[0],le=1;le<12;le++)Zr<Ye[le]&&(Zr=Ye[le]);he.pinfo.ers[V][Ce]=he.pinfo.ers_save[Ce],he.pinfo.ers_save[Ce]=Zr}for(var le=0;le<12;le++)W[Ce][le/3]==0&&Ye[le]>ct&&(W[Ce][le/3]=le%3+1);for(var le=1;le<4;le++){var yn=tt[le-1],gn=tt[le],Ar=Math.max(yn,gn);Ar<4e4&&yn<1.7*gn&&gn<1.7*yn&&(le==1&&W[Ce][0]<=W[Ce][le]&&(W[Ce][0]=0),W[Ce][le]=0)}W[Ce][0]<=he.nsPsy.lastAttacks[Ce]&&(W[Ce][0]=0),(he.nsPsy.lastAttacks[Ce]==3||W[Ce][0]+W[Ce][1]+W[Ce][2]+W[Ce][3]!=0)&&(mt=0,W[Ce][1]!=0&&W[Ce][0]!=0&&(W[Ce][1]=0),W[Ce][2]!=0&&W[Ce][1]!=0&&(W[Ce][2]=0),W[Ce][3]!=0&&W[Ce][2]!=0&&(W[Ce][3]=0)),Ce<2?_e[Ce]=mt:mt==0&&(_e[0]=_e[1]=0),Y[Ce]=he.tot_ener[Ce]}}function gr(R,A,O){if(O==0)for(var V=0;V<R.npart_s;V++)R.nb_s2[A][V]=R.nb_s1[A][V],R.nb_s1[A][V]=0}function kn(R,A){for(var O=0;O<R.npart_l;O++)R.nb_2[A][O]=R.nb_1[A][O],R.nb_1[A][O]=0}function Ur(R,A,O,V){var ee=c.length-1,B=0,Y=O[B]+O[B+1];if(de(Y>=0),Y>0){var ne=A[B];ne<A[B+1]&&(ne=A[B+1]),de(R.numlines_s[B]+R.numlines_s[B+1]-1>0),Y=20*(ne*2-Y)/(Y*(R.numlines_s[B]+R.numlines_s[B+1]-1));var W=0|Y;W>ee&&(W=ee),V[B]=W}else V[B]=0;for(B=1;B<R.npart_s-1;B++)if(Y=O[B-1]+O[B]+O[B+1],de(B+1<R.npart_s),de(Y>=0),Y>0){var ne=A[B-1];ne<A[B]&&(ne=A[B]),ne<A[B+1]&&(ne=A[B+1]),de(R.numlines_s[B-1]+R.numlines_s[B]+R.numlines_s[B+1]-1>0),Y=20*(ne*3-Y)/(Y*(R.numlines_s[B-1]+R.numlines_s[B]+R.numlines_s[B+1]-1));var W=0|Y;W>ee&&(W=ee),V[B]=W}else V[B]=0;if(de(B>0),de(B==R.npart_s-1),Y=O[B-1]+O[B],de(Y>=0),Y>0){var ne=A[B-1];ne<A[B]&&(ne=A[B]),de(R.numlines_s[B-1]+R.numlines_s[B]-1>0),Y=20*(ne*2-Y)/(Y*(R.numlines_s[B-1]+R.numlines_s[B]-1));var W=0|Y;W>ee&&(W=ee),V[B]=W}else V[B]=0;de(B==R.npart_s-1)}function Vr(R,A,O,V,ee,B){var Y=R.internal_flags,ne=new float[g.CBANDS],W=Ae(g.CBANDS),_e,ae,he,qe=new int[g.CBANDS];for(he=ae=0;he<Y.npart_s;++he){var at=0,Ce=0,Je=Y.numlines_s[he];for(_e=0;_e<Je;++_e,++ae){var le=A[B][ae];at+=le,Ce<le&&(Ce=le)}O[he]=at,de(at>=0),ne[he]=Ce,de(Je>0),W[he]=at/Je,de(W[he]>=0)}for(de(he==Y.npart_s),de(ae==129);he<g.CBANDS;++he)ne[he]=0,W[he]=0;for(Ur(Y,ne,W,qe),ae=he=0;he<Y.npart_s;he++){var Ke=Y.s3ind_s[he][0],_t=Y.s3ind_s[he][1],Be,Ye,Me,tt,Ut;for(Be=qe[Ke],Ye=1,tt=Y.s3_ss[ae]*O[Ke]*c[qe[Ke]],++ae,++Ke;Ke<=_t;)Be+=qe[Ke],Ye+=1,Me=Y.s3_ss[ae]*O[Ke]*c[qe[Ke]],tt=G(tt,Me,Ke-he),++ae,++Ke;Be=(1+2*Be)/(2*Ye),Ut=c[Be]*.5,tt*=Ut,V[he]=tt,Y.nb_s2[ee][he]=Y.nb_s1[ee][he],Y.nb_s1[ee][he]=tt,Me=ne[he],Me*=Y.minval_s[he],Me*=Ut,V[he]>Me&&(V[he]=Me),Y.masking_lower>1&&(V[he]*=Y.masking_lower),V[he]>O[he]&&(V[he]=O[he]),Y.masking_lower<1&&(V[he]*=Y.masking_lower),de(V[he]>=0)}for(;he<g.CBANDS;++he)O[he]=0,V[he]=0}function xn(R,A,O,V,ee){var B=Ae(g.CBANDS),Y=Ae(g.CBANDS),ne=Qe(g.CBANDS+2),W;We(R,A,O,B,Y),je(R,B,Y,ne);var _e=0;for(W=0;W<R.npart_l;W++){var ae,he,qe,at,Ce=R.s3ind[W][0],Je=R.s3ind[W][1],le=0,Ke=0;for(le=ne[Ce],Ke+=1,he=R.s3_ll[_e]*O[Ce]*c[ne[Ce]],++_e,++Ce;Ce<=Je;)le+=ne[Ce],Ke+=1,ae=R.s3_ll[_e]*O[Ce]*c[ne[Ce]],at=G(he,ae,Ce-W),he=at,++_e,++Ce;if(le=(1+2*le)/(2*Ke),qe=c[le]*.5,he*=qe,R.blocktype_old[ee&1]==g.SHORT_TYPE){var _t=ie*R.nb_1[ee][W];_t>0?V[W]=Math.min(he,_t):V[W]=Math.min(he,O[W]*pe)}else{var Be=Z*R.nb_2[ee][W],Ye=ie*R.nb_1[ee][W],_t;Be<=0&&(Be=he),Ye<=0&&(Ye=he),R.blocktype_old[ee&1]==g.NORM_TYPE?_t=Math.min(Ye,Be):_t=Ye,V[W]=Math.min(he,_t)}R.nb_2[ee][W]=R.nb_1[ee][W],R.nb_1[ee][W]=he,ae=B[W],ae*=R.minval_l[W],ae*=qe,V[W]>ae&&(V[W]=ae),R.masking_lower>1&&(V[W]*=R.masking_lower),V[W]>O[W]&&(V[W]=O[W]),R.masking_lower<1&&(V[W]*=R.masking_lower),de(V[W]>=0)}for(;W<g.CBANDS;++W)O[W]=0,V[W]=0}function Ia(R,A){var O=R.internal_flags;R.short_blocks==ge.short_block_coupled&&!(A[0]!=0&&A[1]!=0)&&(A[0]=A[1]=0);for(var V=0;V<O.channels_out;V++)R.short_blocks==ge.short_block_dispensed&&(A[V]=1),R.short_blocks==ge.short_block_forced&&(A[V]=0)}function Ca(R,A,O){for(var V=R.internal_flags,ee=0;ee<V.channels_out;ee++){var B=g.NORM_TYPE;A[ee]!=0?(de(V.blocktype_old[ee]!=g.START_TYPE),V.blocktype_old[ee]==g.SHORT_TYPE&&(B=g.STOP_TYPE)):(B=g.SHORT_TYPE,V.blocktype_old[ee]==g.NORM_TYPE&&(V.blocktype_old[ee]=g.START_TYPE),V.blocktype_old[ee]==g.STOP_TYPE&&(V.blocktype_old[ee]=g.SHORT_TYPE)),O[ee]=V.blocktype_old[ee],V.blocktype_old[ee]=B}}function bn(R,A,O,V,ee,B,Y){for(var ne=B*2,W=B>0?Math.pow(10,ee):1,_e,ae,he=0;he<Y;++he){var qe=R[2][he],at=R[3][he],Ce=A[0][he],Je=A[1][he],le=A[2][he],Ke=A[3][he];if(Ce<=1.58*Je&&Je<=1.58*Ce){var _t=O[he]*at,Be=O[he]*qe;ae=Math.max(le,Math.min(Ke,_t)),_e=Math.max(Ke,Math.min(le,Be))}else ae=le,_e=Ke;if(B>0){var Ye,Me,tt=V[he]*W;if(Ye=Math.min(Math.max(Ce,tt),Math.max(Je,tt)),le=Math.max(ae,tt),Ke=Math.max(_e,tt),Me=le+Ke,Me>0&&Ye*ne<Me){var Ut=Ye*ne/Me;le*=Ut,Ke*=Ut,de(Me>0)}ae=Math.min(le,ae),_e=Math.min(Ke,_e)}ae>qe&&(ae=qe),_e>at&&(_e=at),A[2][he]=ae,A[3][he]=_e}}this.L3psycho_anal_vbr=function(R,A,O,V,ee,B,Y,ne,W,_e){var ae=R.internal_flags,he,qe,at=Ae(g.HBLKSIZE),Ce=$e([3,g.HBLKSIZE_s]),Je=$e([2,g.BLKSIZE]),le=$e([2,3,g.BLKSIZE_s]),Ke=$e([4,g.CBANDS]),_t=$e([4,g.CBANDS]),Be=$e([4,3]),Ye=.6,Me=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],tt=Qe(2),Ut=R.mode==sr.JOINT_STEREO?4:ae.channels_out;Qt(R,A,O,V,ee,B,W,Be,Me,tt),Ia(R,tt);{for(var ze=0;ze<Ut;ze++){var ct=ze&1;he=Je,kt(R,A,O,ze,V,at,he,ct),Ht(R,V,ze,at),tt[ct]!=0?xn(ae,at,Ke[ze],_t[ze],ze):kn(ae,ze)}tt[0]+tt[1]==2&&R.mode==sr.JOINT_STEREO&&bn(Ke,_t,ae.mld_cb_l,ae.ATH.cb_l,R.ATHlower*ae.ATH.adjust,R.msfix,ae.npart_l);for(var ze=0;ze<Ut;ze++){var ct=ze&1;tt[ct]!=0&&S(ae,Ke[ze],_t[ze],ze)}}{for(var mt=0;mt<3;mt++){for(var ze=0;ze<Ut;++ze){var ct=ze&1;tt[ct]!=0?gr(ae,ze,mt):(qe=le,At(R,A,O,ze,mt,Ce,qe,ct),Vr(R,Ce,Ke[ze],_t[ze],ze,mt))}tt[0]+tt[1]==0&&R.mode==sr.JOINT_STEREO&&bn(Ke,_t,ae.mld_cb_s,ae.ATH.cb_s,R.ATHlower*ae.ATH.adjust,R.msfix,ae.npart_s);for(var ze=0;ze<Ut;++ze){var ct=ze&1;tt[ct]==0&&f(ae,Ke[ze],_t[ze],ze,mt)}}for(var ze=0;ze<Ut;ze++){var ct=ze&1;if(tt[ct]==0)for(var Gt=0;Gt<g.SBMAX_s;Gt++){for(var Yr=Ae(3),mt=0;mt<3;mt++){var er=ae.thm[ze].s[Gt][mt];if(er*=z,Me[ze][mt]>=2||Me[ze][mt+1]==1){var jt=mt!=0?mt-1:2,qr=ke(ae.thm[ze].s[Gt][jt],er,ve*Ye);er=Math.min(er,qr)}else if(Me[ze][mt]==1){var jt=mt!=0?mt-1:2,qr=ke(ae.thm[ze].s[Gt][jt],er,pe*Ye);er=Math.min(er,qr)}else if(mt!=0&&Me[ze][mt-1]==3||mt==0&&ae.nsPsy.lastAttacks[ze]==3){var jt=mt!=2?mt+1:0,qr=ke(ae.thm[ze].s[Gt][jt],er,pe*Ye);er=Math.min(er,qr)}er*=Be[ze][mt],Yr[mt]=er}for(var mt=0;mt<3;mt++)ae.thm[ze].s[Gt][mt]=Yr[mt]}}}for(var ze=0;ze<Ut;ze++)ae.nsPsy.lastAttacks[ze]=Me[ze][2];Ca(R,tt,_e);for(var ze=0;ze<Ut;ze++){var $r,Zr,yn,gn;ze>1?($r=ne,Zr=-2,yn=g.NORM_TYPE,(_e[0]==g.SHORT_TYPE||_e[1]==g.SHORT_TYPE)&&(yn=g.SHORT_TYPE),gn=B[V][ze-2]):($r=Y,Zr=0,yn=_e[ze],gn=ee[V][ze]),yn==g.SHORT_TYPE?$r[Zr+ze]=Xe(gn,ae.masking_lower):$r[Zr+ze]=it(gn,ae.masking_lower),R.analysis&&(ae.pinfo.pe[V][ze]=$r[Zr+ze])}return 0};function Br(R,A){var O=R,V;return O>=0?V=-O*27:V=O*A,V<=-72?0:Math.exp(V*U)}function oa(R){var A=0,O=0;{var V=0,ee,B;for(V=0;Br(V,R)>1e-20;V-=1);for(ee=V,B=0;Math.abs(B-ee)>1e-12;)V=(B+ee)/2,Br(V,R)>0?B=V:ee=V;A=ee}{var V=0,ee,B;for(V=0;Br(V,R)>1e-20;V+=1);for(ee=0,B=V;Math.abs(B-ee)>1e-12;)V=(B+ee)/2,Br(V,R)>0?ee=V:B=V;O=B}{var Y=0,ne=1e3,W;for(W=0;W<=ne;++W){var V=A+W*(O-A)/ne,_e=Br(V,R);Y+=_e}{var ae=(ne+1)/(Y*(O-A));return ae}}}function ji(R){var A,O,V,ee;return A=R,A>=0?A*=3:A*=1.5,A>=.5&&A<=2.5?(ee=A-.5,O=8*(ee*ee-2*ee)):O=0,A+=.474,V=15.811389+7.5*A-17.5*Math.sqrt(1+A*A),V<=-60?0:(A=Math.exp((O+V)*U),A/=.6609193,A)}function sa(R){return R<0&&(R=0),R=R*.001,13*Math.atan(.76*R)+3.5*Math.atan(R*R/(7.5*7.5))}function F1(R,A,O,V,ee,B,Y,ne,W,_e,ae,he){var qe=Ae(g.CBANDS+1),at=ne/(he>15?2*576:2*192),Ce=Qe(g.HBLKSIZE),Je;ne/=W;var le=0,Ke=0;for(Je=0;Je<g.CBANDS;Je++){var _t,Be;for(_t=sa(ne*le),qe[Je]=ne*le,Be=le;sa(ne*Be)-_t<me&&Be<=W/2;Be++);for(R[Je]=Be-le,Ke=Je+1;le<Be;)de(le<g.HBLKSIZE),Ce[le++]=Je;if(le>W/2){le=W/2,++Je;break}}de(Je<g.CBANDS),qe[Je]=ne*le;for(var Ye=0;Ye<he;Ye++){var Me,tt,Ut,ze,ct;Ut=_e[Ye],ze=_e[Ye+1],Me=0|Math.floor(.5+ae*(Ut-.5)),Me<0&&(Me=0),tt=0|Math.floor(.5+ae*(ze-.5)),tt>W/2&&(tt=W/2),O[Ye]=(Ce[Me]+Ce[tt])/2,A[Ye]=Ce[tt];var mt=at*ze;Y[Ye]=(mt-qe[A[Ye]])/(qe[A[Ye]+1]-qe[A[Ye]]),Y[Ye]<0?Y[Ye]=0:Y[Ye]>1&&(Y[Ye]=1),ct=sa(ne*_e[Ye]*ae),ct=Math.min(ct,15.5)/15.5,B[Ye]=Math.pow(10,1.25*(1-Math.cos(Math.PI*ct))-2.5)}le=0;for(var Gt=0;Gt<Ke;Gt++){var Yr=R[Gt],_t,er;_t=sa(ne*le),er=sa(ne*(le+Yr-1)),V[Gt]=.5*(_t+er),_t=sa(ne*(le-.5)),er=sa(ne*(le+Yr-.5)),ee[Gt]=er-_t,le+=Yr}return Ke}function L1(R,A,O,V,ee,B){var Y=$e([g.CBANDS,g.CBANDS]),ne,W=0;if(B)for(var _e=0;_e<A;_e++)for(ne=0;ne<A;ne++){var ae=ji(O[_e]-O[ne])*V[ne];Y[_e][ne]=ae*ee[_e]}else for(ne=0;ne<A;ne++)for(var he=15+Math.min(21/O[ne],12),qe=oa(he),_e=0;_e<A;_e++){var ae=qe*Br(O[_e]-O[ne],he)*V[ne];Y[_e][ne]=ae*ee[_e]}for(var _e=0;_e<A;_e++){for(ne=0;ne<A&&!(Y[_e][ne]>0);ne++);for(R[_e][0]=ne,ne=A-1;ne>0&&!(Y[_e][ne]>0);ne--);R[_e][1]=ne,W+=R[_e][1]-R[_e][0]+1}for(var at=Ae(W),Ce=0,_e=0;_e<A;_e++)for(ne=R[_e][0];ne<=R[_e][1];ne++)at[Ce++]=Y[_e][ne];return at}function D1(R){var A=sa(R);return A=Math.min(A,15.5)/15.5,Math.pow(10,1.25*(1-Math.cos(Math.PI*A))-2.5)}this.psymodel_init=function(R){var A=R.internal_flags,O,V=!0,ee=13,B=24,Y=0,ne=0,W=-8.25,_e=-4.5,ae=Ae(g.CBANDS),he=Ae(g.CBANDS),qe=Ae(g.CBANDS),at=R.out_samplerate;switch(R.experimentalZ){default:case 0:V=!0;break;case 1:V=!(R.VBR==fe.vbr_mtrh||R.VBR==fe.vbr_mt);break;case 2:V=!1;break;case 3:ee=8,Y=-1.75,ne=-.0125,W=-8.25,_e=-2.25;break}for(A.ms_ener_ratio_old=.25,A.blocktype_old[0]=A.blocktype_old[1]=g.NORM_TYPE,O=0;O<4;++O){for(var le=0;le<g.CBANDS;++le)A.nb_1[O][le]=1e20,A.nb_2[O][le]=1e20,A.nb_s1[O][le]=A.nb_s2[O][le]=1;for(var Ce=0;Ce<g.SBMAX_l;Ce++)A.en[O].l[Ce]=1e20,A.thm[O].l[Ce]=1e20;for(var le=0;le<3;++le){for(var Ce=0;Ce<g.SBMAX_s;Ce++)A.en[O].s[Ce][le]=1e20,A.thm[O].s[Ce][le]=1e20;A.nsPsy.lastAttacks[O]=0}for(var le=0;le<9;le++)A.nsPsy.last_en_subshort[O][le]=10}for(A.loudness_sq_save[0]=A.loudness_sq_save[1]=0,A.npart_l=F1(A.numlines_l,A.bo_l,A.bm_l,ae,he,A.mld_l,A.PSY.bo_l_weight,at,g.BLKSIZE,A.scalefac_band.l,g.BLKSIZE/(2*576),g.SBMAX_l),de(A.npart_l<g.CBANDS),O=0;O<A.npart_l;O++){var Je=Y;ae[O]>=ee&&(Je=ne*(ae[O]-ee)/(B-ee)+Y*(B-ae[O])/(B-ee)),qe[O]=Math.pow(10,Je/10),A.numlines_l[O]>0?A.rnumlines_l[O]=1/A.numlines_l[O]:A.rnumlines_l[O]=0}A.s3_ll=L1(A.s3ind,A.npart_l,ae,he,qe,V);var le=0;for(O=0;O<A.npart_l;O++){var Ke;Ke=Ee.MAX_VALUE;for(var _t=0;_t<A.numlines_l[O];_t++,le++){var Be=at*le/(1e3*g.BLKSIZE),Ye;Ye=this.ATHformula(Be*1e3,R)-20,Ye=Math.pow(10,.1*Ye),Ye*=A.numlines_l[O],Ke>Ye&&(Ke=Ye)}A.ATH.cb_l[O]=Ke,Ke=-20+ae[O]*20/10,Ke>6&&(Ke=100),Ke<-15&&(Ke=-15),Ke-=8,A.minval_l[O]=Math.pow(10,Ke/10)*A.numlines_l[O]}for(A.npart_s=F1(A.numlines_s,A.bo_s,A.bm_s,ae,he,A.mld_s,A.PSY.bo_s_weight,at,g.BLKSIZE_s,A.scalefac_band.s,g.BLKSIZE_s/(2*192),g.SBMAX_s),de(A.npart_s<g.CBANDS),le=0,O=0;O<A.npart_s;O++){var Ke,Je=W;ae[O]>=ee&&(Je=_e*(ae[O]-ee)/(B-ee)+W*(B-ae[O])/(B-ee)),qe[O]=Math.pow(10,Je/10),Ke=Ee.MAX_VALUE;for(var _t=0;_t<A.numlines_s[O];_t++,le++){var Be=at*le/(1e3*g.BLKSIZE_s),Ye;Ye=this.ATHformula(Be*1e3,R)-20,Ye=Math.pow(10,.1*Ye),Ye*=A.numlines_s[O],Ke>Ye&&(Ke=Ye)}A.ATH.cb_s[O]=Ke,Ke=-7+ae[O]*7/12,ae[O]>12&&(Ke*=1+Math.log(1+Ke)*3.1),ae[O]<12&&(Ke*=1+Math.log(1-Ke)*2.3),Ke<-15&&(Ke=-15),Ke-=8,A.minval_s[O]=Math.pow(10,Ke/10)*A.numlines_s[O]}A.s3_ss=L1(A.s3ind_s,A.npart_s,ae,he,qe,V),d(),C.init_fft(A),A.decay=Math.exp(-1*$/(Oe*at/192));{var Me;Me=M,(R.exp_nspsytune&2)!=0&&(Me=1),Math.abs(R.msfix)>0&&(Me=R.msfix),R.msfix=Me;for(var tt=0;tt<A.npart_l;tt++)A.s3ind[tt][1]>A.npart_l-1&&(A.s3ind[tt][1]=A.npart_l-1)}var Ut=576*A.mode_gr/at;if(A.ATH.decay=Math.pow(10,-12/10*Ut),A.ATH.adjust=.01,A.ATH.adjustLimit=1,de(A.bo_l[g.SBMAX_l-1]<=A.npart_l),de(A.bo_s[g.SBMAX_s-1]<=A.npart_s),R.ATHtype!=-1){var Be,ze=R.out_samplerate/g.BLKSIZE,ct=0;for(Be=0,O=0;O<g.BLKSIZE/2;++O)Be+=ze,A.ATH.eql_w[O]=1/Math.pow(10,this.ATHformula(Be,R)/10),ct+=A.ATH.eql_w[O];for(ct=1/ct,O=g.BLKSIZE/2;--O>=0;)A.ATH.eql_w[O]*=ct}{for(var tt=le=0;tt<A.npart_s;++tt)for(O=0;O<A.numlines_s[tt];++O)++le;de(le==129);for(var tt=le=0;tt<A.npart_l;++tt)for(O=0;O<A.numlines_l[tt];++O)++le;de(le==513)}for(le=0,O=0;O<A.npart_l;O++){var Be=at*(le+A.numlines_l[O]/2)/(1*g.BLKSIZE);A.mld_cb_l[O]=D1(Be),le+=A.numlines_l[O]}for(;O<g.CBANDS;++O)A.mld_cb_l[O]=1;for(le=0,O=0;O<A.npart_s;O++){var Be=at*(le+A.numlines_s[O]/2)/(1*g.BLKSIZE_s);A.mld_cb_s[O]=D1(Be),le+=A.numlines_s[O]}for(;O<g.CBANDS;++O)A.mld_cb_s[O]=1;return 0};function ei(R,A){R<-.3&&(R=3410),R/=1e3,R=Math.max(.1,R);var O=3.64*Math.pow(R,-.8)-6.8*Math.exp(-.6*Math.pow(R-3.4,2))+6*Math.exp(-.15*Math.pow(R-8.7,2))+(.6+.04*A)*.001*Math.pow(R,4);return O}this.ATHformula=function(R,A){var O;switch(A.ATHtype){case 0:O=ei(R,9);break;case 1:O=ei(R,-1);break;case 2:O=ei(R,0);break;case 3:O=ei(R,1)+6;break;case 4:O=ei(R,A.ATHcurve);break;default:O=ei(R,0);break}return O}}var br=ir;function yr(C){var $=C;this.ordinal=function(){return $}}yr.STEREO=new yr(0),yr.JOINT_STEREO=new yr(1),yr.DUAL_CHANNEL=new yr(2),yr.MONO=new yr(3),yr.NOT_SET=new yr(4);var Rr=yr;function Et(){this.class_id=0,this.num_samples=0,this.num_channels=0,this.in_samplerate=0,this.out_samplerate=0,this.scale=0,this.scale_left=0,this.scale_right=0,this.analysis=!1,this.bWriteVbrTag=!1,this.decode_only=!1,this.quality=0,this.mode=Rr.STEREO,this.force_ms=!1,this.free_format=!1,this.findReplayGain=!1,this.decode_on_the_fly=!1,this.write_id3tag_automatic=!1,this.brate=0,this.compression_ratio=0,this.copyright=0,this.original=0,this.extension=0,this.emphasis=0,this.error_protection=0,this.strict_ISO=!1,this.disable_reservoir=!1,this.quant_comp=0,this.quant_comp_short=0,this.experimentalY=!1,this.experimentalZ=0,this.exp_nspsytune=0,this.preset=0,this.VBR=null,this.VBR_q_frac=0,this.VBR_q=0,this.VBR_mean_bitrate_kbps=0,this.VBR_min_bitrate_kbps=0,this.VBR_max_bitrate_kbps=0,this.VBR_hard_min=0,this.lowpassfreq=0,this.highpassfreq=0,this.lowpasswidth=0,this.highpasswidth=0,this.maskingadjust=0,this.maskingadjust_short=0,this.ATHonly=!1,this.ATHshort=!1,this.noATH=!1,this.ATHtype=0,this.ATHcurve=0,this.ATHlower=0,this.athaa_type=0,this.athaa_loudapprox=0,this.athaa_sensitivity=0,this.short_blocks=null,this.useTemporal=!1,this.interChRatio=0,this.msfix=0,this.tune=!1,this.tune_value_a=0,this.version=0,this.encoder_delay=0,this.encoder_padding=0,this.framesize=0,this.frameNum=0,this.lame_allocated_gfp=0,this.internal_flags=null}var ga=Et,Do={};Do.SFBMAX=g.SBMAX_s*3;var zn=Do,ki=P.new_float,Gn=P.new_int;function X0(){this.xr=ki(576),this.l3_enc=Gn(576),this.scalefac=Gn(zn.SFBMAX),this.xrpow_max=0,this.part2_3_length=0,this.big_values=0,this.count1=0,this.global_gain=0,this.scalefac_compress=0,this.block_type=0,this.mixed_block_flag=0,this.table_select=Gn(3),this.subblock_gain=Gn(3+1),this.region0_count=0,this.region1_count=0,this.preflag=0,this.scalefac_scale=0,this.count1table_select=0,this.part2_length=0,this.sfb_lmax=0,this.sfb_smin=0,this.psy_lmax=0,this.sfbmax=0,this.psymax=0,this.sfbdivide=0,this.width=Gn(zn.SFBMAX),this.window=Gn(zn.SFBMAX),this.count1bits=0,this.sfb_partition_table=null,this.slen=Gn(4),this.max_nonzero_coeff=0;var C=this;function $(Z){return new Int32Array(Z)}function ie(Z){return new Float32Array(Z)}this.assign=function(Z){C.xr=ie(Z.xr),C.l3_enc=$(Z.l3_enc),C.scalefac=$(Z.scalefac),C.xrpow_max=Z.xrpow_max,C.part2_3_length=Z.part2_3_length,C.big_values=Z.big_values,C.count1=Z.count1,C.global_gain=Z.global_gain,C.scalefac_compress=Z.scalefac_compress,C.block_type=Z.block_type,C.mixed_block_flag=Z.mixed_block_flag,C.table_select=$(Z.table_select),C.subblock_gain=$(Z.subblock_gain),C.region0_count=Z.region0_count,C.region1_count=Z.region1_count,C.preflag=Z.preflag,C.scalefac_scale=Z.scalefac_scale,C.count1table_select=Z.count1table_select,C.part2_length=Z.part2_length,C.sfb_lmax=Z.sfb_lmax,C.sfb_smin=Z.sfb_smin,C.psy_lmax=Z.psy_lmax,C.sfbmax=Z.sfbmax,C.psymax=Z.psymax,C.sfbdivide=Z.sfbdivide,C.width=$(Z.width),C.window=$(Z.window),C.count1bits=Z.count1bits,C.sfb_partition_table=Z.sfb_partition_table.slice(0),C.slen=$(Z.slen),C.max_nonzero_coeff=Z.max_nonzero_coeff}}var Oo=X0,b1=P.new_int;function kf(){this.tt=[[null,null],[null,null]],this.main_data_begin=0,this.private_bits=0,this.resvDrain_pre=0,this.resvDrain_post=0,this.scfsi=[b1(4),b1(4)];for(var C=0;C<2;C++)for(var $=0;$<2;$++)this.tt[C][$]=new Oo}var Hf=kf,ko=P.System,Ho=P.new_int;function Uf(C,$,ie,Z){this.l=Ho(1+g.SBMAX_l),this.s=Ho(1+g.SBMAX_s),this.psfb21=Ho(1+g.PSFB21),this.psfb12=Ho(1+g.PSFB12);var Re=this.l,J=this.s;arguments.length==4&&(this.arrL=arguments[0],this.arrS=arguments[1],this.arr21=arguments[2],this.arr12=arguments[3],ko.arraycopy(this.arrL,0,Re,0,Math.min(this.arrL.length,this.l.length)),ko.arraycopy(this.arrS,0,J,0,Math.min(this.arrS.length,this.s.length)),ko.arraycopy(this.arr21,0,this.psfb21,0,Math.min(this.arr21.length,this.psfb21.length)),ko.arraycopy(this.arr12,0,this.psfb12,0,Math.min(this.arr12.length,this.psfb12.length)))}var Fn=Uf,K0=P.new_float,Vf=P.new_float_n,qf=P.new_int;function jf(){this.last_en_subshort=Vf([4,9]),this.lastAttacks=qf(4),this.pefirbuf=K0(19),this.longfact=K0(g.SBMAX_l),this.shortfact=K0(g.SBMAX_s),this.attackthre=0,this.attackthre_s=0}var zf=jf;function Gf(){this.sum=0,this.seen=0,this.want=0,this.pos=0,this.size=0,this.bag=null,this.nVbrNumFrames=0,this.nBytesWritten=0,this.TotalFrameSize=0}var Xf=Gf,Kf=P.new_byte,Wf=P.new_double,un=P.new_float,Ea=P.new_float_n,Sn=P.new_int,Uo=P.new_int_n;Xn.MFSIZE=3*1152+g.ENCDELAY-g.MDCTDELAY,Xn.MAX_HEADER_BUF=256,Xn.MAX_BITS_PER_CHANNEL=4095,Xn.MAX_BITS_PER_GRANULE=7680,Xn.BPC=320;function Xn(){var C=40;this.Class_ID=0,this.lame_encode_frame_init=0,this.iteration_init_init=0,this.fill_buffer_resample_init=0,this.mfbuf=Ea([2,Xn.MFSIZE]),this.mode_gr=0,this.channels_in=0,this.channels_out=0,this.resample_ratio=0,this.mf_samples_to_encode=0,this.mf_size=0,this.VBR_min_bitrate=0,this.VBR_max_bitrate=0,this.bitrate_index=0,this.samplerate_index=0,this.mode_ext=0,this.lowpass1=0,this.lowpass2=0,this.highpass1=0,this.highpass2=0,this.noise_shaping=0,this.noise_shaping_amp=0,this.substep_shaping=0,this.psymodel=0,this.noise_shaping_stop=0,this.subblock_gain=0,this.use_best_huffman=0,this.full_outer_loop=0,this.l3_side=new Hf,this.ms_ratio=un(2),this.padding=0,this.frac_SpF=0,this.slot_lag=0,this.tag_spec=null,this.nMusicCRC=0,this.OldValue=Sn(2),this.CurrentStep=Sn(2),this.masking_lower=0,this.bv_scf=Sn(576),this.pseudohalf=Sn(zn.SFBMAX),this.sfb21_extra=!1,this.inbuf_old=new Array(2),this.blackfilt=new Array(2*Xn.BPC+1),this.itime=Wf(2),this.sideinfo_len=0,this.sb_sample=Ea([2,2,18,g.SBLIMIT]),this.amp_filter=un(32);function $(){this.write_timing=0,this.ptr=0,this.buf=Kf(C)}this.header=new Array(Xn.MAX_HEADER_BUF),this.h_ptr=0,this.w_ptr=0,this.ancillary_flag=0,this.ResvSize=0,this.ResvMax=0,this.scalefac_band=new Fn,this.minval_l=un(g.CBANDS),this.minval_s=un(g.CBANDS),this.nb_1=Ea([4,g.CBANDS]),this.nb_2=Ea([4,g.CBANDS]),this.nb_s1=Ea([4,g.CBANDS]),this.nb_s2=Ea([4,g.CBANDS]),this.s3_ss=null,this.s3_ll=null,this.decay=0,this.thm=new Array(4),this.en=new Array(4),this.tot_ener=un(4),this.loudness_sq=Ea([2,2]),this.loudness_sq_save=un(2),this.mld_l=un(g.SBMAX_l),this.mld_s=un(g.SBMAX_s),this.bm_l=Sn(g.SBMAX_l),this.bo_l=Sn(g.SBMAX_l),this.bm_s=Sn(g.SBMAX_s),this.bo_s=Sn(g.SBMAX_s),this.npart_l=0,this.npart_s=0,this.s3ind=Uo([g.CBANDS,2]),this.s3ind_s=Uo([g.CBANDS,2]),this.numlines_s=Sn(g.CBANDS),this.numlines_l=Sn(g.CBANDS),this.rnumlines_l=un(g.CBANDS),this.mld_cb_l=un(g.CBANDS),this.mld_cb_s=un(g.CBANDS),this.numlines_s_num1=0,this.numlines_l_num1=0,this.pe=un(4),this.ms_ratio_s_old=0,this.ms_ratio_l_old=0,this.ms_ener_ratio_old=0,this.blocktype_old=Sn(2),this.nsPsy=new zf,this.VBR_seek_table=new Xf,this.ATH=null,this.PSY=null,this.nogap_total=0,this.nogap_current=0,this.decode_on_the_fly=!0,this.findReplayGain=!0,this.findPeakSample=!0,this.PeakSample=0,this.RadioGain=0,this.AudiophileGain=0,this.rgdata=null,this.noclipGainChange=0,this.noclipScale=0,this.bitrate_stereoMode_Hist=Uo([16,4+1]),this.bitrate_blockType_Hist=Uo([16,4+1+1]),this.pinfo=null,this.hip=null,this.in_buffer_nsamples=0,this.in_buffer_0=null,this.in_buffer_1=null,this.iteration_loop=null;for(var ie=0;ie<this.en.length;ie++)this.en[ie]=new Zt;for(var ie=0;ie<this.thm.length;ie++)this.thm[ie]=new Zt;for(var ie=0;ie<this.header.length;ie++)this.header[ie]=new $}var Dt=Xn,Ta=P.new_float;function Yf(){this.useAdjust=0,this.aaSensitivityP=0,this.adjust=0,this.adjustLimit=0,this.decay=0,this.floor=0,this.l=Ta(g.SBMAX_l),this.s=Ta(g.SBMAX_s),this.psfb21=Ta(g.PSFB21),this.psfb12=Ta(g.PSFB12),this.cb_l=Ta(g.CBANDS),this.cb_s=Ta(g.CBANDS),this.eql_w=Ta(g.BLKSIZE/2)}var $f=Yf,Hr=P.System,y1=P.Arrays;qt.STEPS_per_dB=100,qt.MAX_dB=120,qt.GAIN_NOT_ENOUGH_SAMPLES=-24601,qt.GAIN_ANALYSIS_ERROR=0,qt.GAIN_ANALYSIS_OK=1,qt.INIT_GAIN_ANALYSIS_ERROR=0,qt.INIT_GAIN_ANALYSIS_OK=1,qt.YULE_ORDER=10,qt.MAX_ORDER=qt.YULE_ORDER,qt.MAX_SAMP_FREQ=48e3,qt.RMS_WINDOW_TIME_NUMERATOR=1,qt.RMS_WINDOW_TIME_DENOMINATOR=20,qt.MAX_SAMPLES_PER_WINDOW=qt.MAX_SAMP_FREQ*qt.RMS_WINDOW_TIME_NUMERATOR/qt.RMS_WINDOW_TIME_DENOMINATOR+1;function qt(){var C=64.82,$=qt.YULE_ORDER,ie=.95,Z=qt.MAX_SAMP_FREQ,Re=qt.RMS_WINDOW_TIME_NUMERATOR,J=qt.RMS_WINDOW_TIME_DENOMINATOR,me=qt.MAX_SAMPLES_PER_WINDOW,Fe=[[.038575994352,-3.84664617118067,-.02160367184185,7.81501653005538,-.00123395316851,-11.34170355132042,-9291677959e-14,13.05504219327545,-.01655260341619,-12.28759895145294,.02161526843274,9.4829380631979,-.02074045215285,-5.87257861775999,.00594298065125,2.75465861874613,.00306428023191,-.86984376593551,.00012025322027,.13919314567432,.00288463683916],[.0541865640643,-3.47845948550071,-.02911007808948,6.36317777566148,-.00848709379851,-8.54751527471874,-.00851165645469,9.4769360780128,-.00834990904936,-8.81498681370155,.02245293253339,6.85401540936998,-.02596338512915,-4.39470996079559,.01624864962975,2.19611684890774,-.00240879051584,-.75104302451432,.00674613682247,.13149317958808,-.00187763777362],[.15457299681924,-2.37898834973084,-.09331049056315,2.84868151156327,-.06247880153653,-2.64577170229825,.02163541888798,2.23697657451713,-.05588393329856,-1.67148153367602,.04781476674921,1.00595954808547,.00222312597743,-.45953458054983,.03174092540049,.16378164858596,-.01390589421898,-.05032077717131,.00651420667831,.0234789740702,-.00881362733839],[.30296907319327,-1.61273165137247,-.22613988682123,1.0797749225997,-.08587323730772,-.2565625775407,.03282930172664,-.1627671912044,-.00915702933434,-.22638893773906,-.02364141202522,.39120800788284,-.00584456039913,-.22138138954925,.06276101321749,.04500235387352,-828086748e-14,.02005851806501,.00205861885564,.00302439095741,-.02950134983287],[.33642304856132,-1.49858979367799,-.2557224142557,.87350271418188,-.11828570177555,.12205022308084,.11921148675203,-.80774944671438,-.07834489609479,.47854794562326,-.0046997791438,-.12453458140019,-.0058950022444,-.04067510197014,.05724228140351,.08333755284107,.00832043980773,-.04237348025746,-.0163538138454,.02977207319925,-.0176017656815],[.4491525660845,-.62820619233671,-.14351757464547,.29661783706366,-.22784394429749,-.372563729424,-.01419140100551,.00213767857124,.04078262797139,-.42029820170918,-.12398163381748,.22199650564824,.04097565135648,.00613424350682,.10478503600251,.06747620744683,-.01863887810927,.05784820375801,-.03193428438915,.03222754072173,.00541907748707],[.56619470757641,-1.04800335126349,-.75464456939302,.29156311971249,.1624213774223,-.26806001042947,.16744243493672,.00819999645858,-.18901604199609,.45054734505008,.3093178284183,-.33032403314006,-.27562961986224,.0673936833311,.00647310677246,-.04784254229033,.08647503780351,.01639907836189,-.0378898455484,.01807364323573,-.00588215443421],[.58100494960553,-.51035327095184,-.53174909058578,-.31863563325245,-.14289799034253,-.20256413484477,.17520704835522,.1472815413433,.02377945217615,.38952639978999,.15558449135573,-.23313271880868,-.25344790059353,-.05246019024463,.01628462406333,-.02505961724053,.06920467763959,.02442357316099,-.03721611395801,.01818801111503,-.00749618797172],[.53648789255105,-.2504987195602,-.42163034350696,-.43193942311114,-.00275953611929,-.03424681017675,.04267842219415,-.04678328784242,-.10214864179676,.26408300200955,.14590772289388,.15113130533216,-.02459864859345,-.17556493366449,-.11202315195388,-.18823009262115,-.04060034127,.05477720428674,.0478866554818,.0470440968812,-.02217936801134]],Oe=[[.98621192462708,-1.97223372919527,-1.97242384925416,.97261396931306,.98621192462708],[.98500175787242,-1.96977855582618,-1.97000351574484,.9702284756635,.98500175787242],[.97938932735214,-1.95835380975398,-1.95877865470428,.95920349965459,.97938932735214],[.97531843204928,-1.95002759149878,-1.95063686409857,.95124613669835,.97531843204928],[.97316523498161,-1.94561023566527,-1.94633046996323,.94705070426118,.97316523498161],[.96454515552826,-1.92783286977036,-1.92909031105652,.93034775234268,.96454515552826],[.96009142950541,-1.91858953033784,-1.92018285901082,.92177618768381,.96009142950541],[.95856916599601,-1.9154210807478,-1.91713833199203,.91885558323625,.95856916599601],[.94597685600279,-1.88903307939452,-1.89195371200558,.89487434461664,.94597685600279]];function z(o,I,U,F,x,p){for(;x--!=0;)U[F]=1e-10+o[I+0]*p[0]-U[F-1]*p[1]+o[I-1]*p[2]-U[F-2]*p[3]+o[I-2]*p[4]-U[F-3]*p[5]+o[I-3]*p[6]-U[F-4]*p[7]+o[I-4]*p[8]-U[F-5]*p[9]+o[I-5]*p[10]-U[F-6]*p[11]+o[I-6]*p[12]-U[F-7]*p[13]+o[I-7]*p[14]-U[F-8]*p[15]+o[I-8]*p[16]-U[F-9]*p[17]+o[I-9]*p[18]-U[F-10]*p[19]+o[I-10]*p[20],++F,++I}function ve(o,I,U,F,x,p){for(;x--!=0;)U[F]=o[I+0]*p[0]-U[F-1]*p[1]+o[I-1]*p[2]-U[F-2]*p[3]+o[I-2]*p[4],++F,++I}function pe(o,I){for(var U=0;U<MAX_ORDER;U++)o.linprebuf[U]=o.lstepbuf[U]=o.loutbuf[U]=o.rinprebuf[U]=o.rstepbuf[U]=o.routbuf[U]=0;switch(0|I){case 48e3:o.reqindex=0;break;case 44100:o.reqindex=1;break;case 32e3:o.reqindex=2;break;case 24e3:o.reqindex=3;break;case 22050:o.reqindex=4;break;case 16e3:o.reqindex=5;break;case 12e3:o.reqindex=6;break;case 11025:o.reqindex=7;break;case 8e3:o.reqindex=8;break;default:return INIT_GAIN_ANALYSIS_ERROR}return o.sampleWindow=0|(I*Re+J-1)/J,o.lsum=0,o.rsum=0,o.totsamp=0,y1.ill(o.A,0),INIT_GAIN_ANALYSIS_OK}this.InitGainAnalysis=function(o,I){return pe(o,I)!=INIT_GAIN_ANALYSIS_OK?INIT_GAIN_ANALYSIS_ERROR:(o.linpre=MAX_ORDER,o.rinpre=MAX_ORDER,o.lstep=MAX_ORDER,o.rstep=MAX_ORDER,o.lout=MAX_ORDER,o.rout=MAX_ORDER,y1.fill(o.B,0),INIT_GAIN_ANALYSIS_OK)};function M(o){return o*o}this.AnalyzeSamples=function(o,I,U,F,x,p,N){var q,w,u,L,E,c,d;if(p==0)return GAIN_ANALYSIS_OK;switch(d=0,E=p,N){case 1:F=I,x=U;break;case 2:break;default:return GAIN_ANALYSIS_ERROR}for(p<MAX_ORDER?(Hr.arraycopy(I,U,o.linprebuf,MAX_ORDER,p),Hr.arraycopy(F,x,o.rinprebuf,MAX_ORDER,p)):(Hr.arraycopy(I,U,o.linprebuf,MAX_ORDER,MAX_ORDER),Hr.arraycopy(F,x,o.rinprebuf,MAX_ORDER,MAX_ORDER));E>0;){c=E>o.sampleWindow-o.totsamp?o.sampleWindow-o.totsamp:E,d<MAX_ORDER?(q=o.linpre+d,w=o.linprebuf,u=o.rinpre+d,L=o.rinprebuf,c>MAX_ORDER-d&&(c=MAX_ORDER-d)):(q=U+d,w=I,u=x+d,L=F),z(w,q,o.lstepbuf,o.lstep+o.totsamp,c,Fe[o.reqindex]),z(L,u,o.rstepbuf,o.rstep+o.totsamp,c,Fe[o.reqindex]),ve(o.lstepbuf,o.lstep+o.totsamp,o.loutbuf,o.lout+o.totsamp,c,Oe[o.reqindex]),ve(o.rstepbuf,o.rstep+o.totsamp,o.routbuf,o.rout+o.totsamp,c,Oe[o.reqindex]),q=o.lout+o.totsamp,w=o.loutbuf,u=o.rout+o.totsamp,L=o.routbuf;for(var b=c%8;b--!=0;)o.lsum+=M(w[q++]),o.rsum+=M(L[u++]);for(b=c/8;b--!=0;)o.lsum+=M(w[q+0])+M(w[q+1])+M(w[q+2])+M(w[q+3])+M(w[q+4])+M(w[q+5])+M(w[q+6])+M(w[q+7]),q+=8,o.rsum+=M(L[u+0])+M(L[u+1])+M(L[u+2])+M(L[u+3])+M(L[u+4])+M(L[u+5])+M(L[u+6])+M(L[u+7]),u+=8;if(E-=c,d+=c,o.totsamp+=c,o.totsamp==o.sampleWindow){var l=qt.STEPS_per_dB*10*Math.log10((o.lsum+o.rsum)/o.totsamp*.5+1e-37),v=l<=0?0:0|l;v>=o.A.length&&(v=o.A.length-1),o.A[v]++,o.lsum=o.rsum=0,Hr.arraycopy(o.loutbuf,o.totsamp,o.loutbuf,0,MAX_ORDER),Hr.arraycopy(o.routbuf,o.totsamp,o.routbuf,0,MAX_ORDER),Hr.arraycopy(o.lstepbuf,o.totsamp,o.lstepbuf,0,MAX_ORDER),Hr.arraycopy(o.rstepbuf,o.totsamp,o.rstepbuf,0,MAX_ORDER),o.totsamp=0}if(o.totsamp>o.sampleWindow)return GAIN_ANALYSIS_ERROR}return p<MAX_ORDER?(Hr.arraycopy(o.linprebuf,p,o.linprebuf,0,MAX_ORDER-p),Hr.arraycopy(o.rinprebuf,p,o.rinprebuf,0,MAX_ORDER-p),Hr.arraycopy(I,U,o.linprebuf,MAX_ORDER-p,p),Hr.arraycopy(F,x,o.rinprebuf,MAX_ORDER-p,p)):(Hr.arraycopy(I,U+p-MAX_ORDER,o.linprebuf,0,MAX_ORDER),Hr.arraycopy(F,x+p-MAX_ORDER,o.rinprebuf,0,MAX_ORDER)),GAIN_ANALYSIS_OK};function X(o,I){var U,F=0;for(U=0;U<I;U++)F+=o[U];if(F==0)return GAIN_NOT_ENOUGH_SAMPLES;var x=0|Math.ceil(F*(1-ie));for(U=I;U-- >0&&!((x-=o[U])<=0););return C-U/qt.STEPS_per_dB}this.GetTitleGain=function(o){for(var I=X(o.A,o.A.length),U=0;U<o.A.length;U++)o.B[U]+=o.A[U],o.A[U]=0;for(var U=0;U<MAX_ORDER;U++)o.linprebuf[U]=o.lstepbuf[U]=o.loutbuf[U]=o.rinprebuf[U]=o.rstepbuf[U]=o.routbuf[U]=0;return o.totsamp=0,o.lsum=o.rsum=0,I}}var Mr=qt,Qa=P.new_float,g1=P.new_int;function Zf(){this.linprebuf=Qa(Mr.MAX_ORDER*2),this.linpre=0,this.lstepbuf=Qa(Mr.MAX_SAMPLES_PER_WINDOW+Mr.MAX_ORDER),this.lstep=0,this.loutbuf=Qa(Mr.MAX_SAMPLES_PER_WINDOW+Mr.MAX_ORDER),this.lout=0,this.rinprebuf=Qa(Mr.MAX_ORDER*2),this.rinpre=0,this.rstepbuf=Qa(Mr.MAX_SAMPLES_PER_WINDOW+Mr.MAX_ORDER),this.rstep=0,this.routbuf=Qa(Mr.MAX_SAMPLES_PER_WINDOW+Mr.MAX_ORDER),this.rout=0,this.sampleWindow=0,this.totsamp=0,this.lsum=0,this.rsum=0,this.freqindex=0,this.first=0,this.A=g1(0|Mr.STEPS_per_dB*Mr.MAX_dB),this.B=g1(0|Mr.STEPS_per_dB*Mr.MAX_dB)}var Qf=Zf;function Jf(C){this.bits=C}var E1=Jf,T1=P.new_float,e2=P.new_int,w1=P.assert;function t2(C){var $=C;this.quantize=$,this.iteration_loop=function(ie,Z,Re,J){var me=ie.internal_flags,Fe=T1(zn.SFBMAX),Oe=T1(576),z=e2(2),ve=0,pe,M=me.l3_side,X=new E1(ve);this.quantize.rv.ResvFrameBegin(ie,X),ve=X.bits;for(var o=0;o<me.mode_gr;o++){pe=this.quantize.qupvt.on_pe(ie,Z,z,ve,o,o),me.mode_ext==g.MPG_MD_MS_LR&&(this.quantize.ms_convert(me.l3_side,o),this.quantize.qupvt.reduce_side(z,Re[o],ve,pe));for(var I=0;I<me.channels_out;I++){var U,F,x=M.tt[o][I];x.block_type!=g.SHORT_TYPE?(U=0,F=me.PSY.mask_adjust-U):(U=0,F=me.PSY.mask_adjust_short-U),me.masking_lower=Math.pow(10,F*.1),this.quantize.init_outer_loop(me,x),this.quantize.init_xrpow(me,x,Oe)&&(this.quantize.qupvt.calc_xmin(ie,J[o][I],x,Fe),this.quantize.outer_loop(ie,x,Fe,Oe,I,z[I])),this.quantize.iteration_finish_one(me,o,I),w1(x.part2_3_length<=Dt.MAX_BITS_PER_CHANNEL),w1(x.part2_3_length<=z[I])}}this.quantize.rv.ResvFrameEnd(me,ve)}}var r2=t2;function wt(C,$,ie,Z){this.xlen=C,this.linmax=$,this.table=ie,this.hlen=Z}var Ne={};Ne.t1HB=[1,1,1,0],Ne.t2HB=[1,2,1,3,1,1,3,2,0],Ne.t3HB=[3,2,1,1,1,1,3,2,0],Ne.t5HB=[1,2,6,5,3,1,4,4,7,5,7,1,6,1,1,0],Ne.t6HB=[7,3,5,1,6,2,3,2,5,4,4,1,3,3,2,0],Ne.t7HB=[1,2,10,19,16,10,3,3,7,10,5,3,11,4,13,17,8,4,12,11,18,15,11,2,7,6,9,14,3,1,6,4,5,3,2,0],Ne.t8HB=[3,4,6,18,12,5,5,1,2,16,9,3,7,3,5,14,7,3,19,17,15,13,10,4,13,5,8,11,5,1,12,4,4,1,1,0],Ne.t9HB=[7,5,9,14,15,7,6,4,5,5,6,7,7,6,8,8,8,5,15,6,9,10,5,1,11,7,9,6,4,1,14,4,6,2,6,0],Ne.t10HB=[1,2,10,23,35,30,12,17,3,3,8,12,18,21,12,7,11,9,15,21,32,40,19,6,14,13,22,34,46,23,18,7,20,19,33,47,27,22,9,3,31,22,41,26,21,20,5,3,14,13,10,11,16,6,5,1,9,8,7,8,4,4,2,0],Ne.t11HB=[3,4,10,24,34,33,21,15,5,3,4,10,32,17,11,10,11,7,13,18,30,31,20,5,25,11,19,59,27,18,12,5,35,33,31,58,30,16,7,5,28,26,32,19,17,15,8,14,14,12,9,13,14,9,4,1,11,4,6,6,6,3,2,0],Ne.t12HB=[9,6,16,33,41,39,38,26,7,5,6,9,23,16,26,11,17,7,11,14,21,30,10,7,17,10,15,12,18,28,14,5,32,13,22,19,18,16,9,5,40,17,31,29,17,13,4,2,27,12,11,15,10,7,4,1,27,12,8,12,6,3,1,0],Ne.t13HB=[1,5,14,21,34,51,46,71,42,52,68,52,67,44,43,19,3,4,12,19,31,26,44,33,31,24,32,24,31,35,22,14,15,13,23,36,59,49,77,65,29,40,30,40,27,33,42,16,22,20,37,61,56,79,73,64,43,76,56,37,26,31,25,14,35,16,60,57,97,75,114,91,54,73,55,41,48,53,23,24,58,27,50,96,76,70,93,84,77,58,79,29,74,49,41,17,47,45,78,74,115,94,90,79,69,83,71,50,59,38,36,15,72,34,56,95,92,85,91,90,86,73,77,65,51,44,43,42,43,20,30,44,55,78,72,87,78,61,46,54,37,30,20,16,53,25,41,37,44,59,54,81,66,76,57,54,37,18,39,11,35,33,31,57,42,82,72,80,47,58,55,21,22,26,38,22,53,25,23,38,70,60,51,36,55,26,34,23,27,14,9,7,34,32,28,39,49,75,30,52,48,40,52,28,18,17,9,5,45,21,34,64,56,50,49,45,31,19,12,15,10,7,6,3,48,23,20,39,36,35,53,21,16,23,13,10,6,1,4,2,16,15,17,27,25,20,29,11,17,12,16,8,1,1,0,1],Ne.t15HB=[7,12,18,53,47,76,124,108,89,123,108,119,107,81,122,63,13,5,16,27,46,36,61,51,42,70,52,83,65,41,59,36,19,17,15,24,41,34,59,48,40,64,50,78,62,80,56,33,29,28,25,43,39,63,55,93,76,59,93,72,54,75,50,29,52,22,42,40,67,57,95,79,72,57,89,69,49,66,46,27,77,37,35,66,58,52,91,74,62,48,79,63,90,62,40,38,125,32,60,56,50,92,78,65,55,87,71,51,73,51,70,30,109,53,49,94,88,75,66,122,91,73,56,42,64,44,21,25,90,43,41,77,73,63,56,92,77,66,47,67,48,53,36,20,71,34,67,60,58,49,88,76,67,106,71,54,38,39,23,15,109,53,51,47,90,82,58,57,48,72,57,41,23,27,62,9,86,42,40,37,70,64,52,43,70,55,42,25,29,18,11,11,118,68,30,55,50,46,74,65,49,39,24,16,22,13,14,7,91,44,39,38,34,63,52,45,31,52,28,19,14,8,9,3,123,60,58,53,47,43,32,22,37,24,17,12,15,10,2,1,71,37,34,30,28,20,17,26,21,16,10,6,8,6,2,0],Ne.t16HB=[1,5,14,44,74,63,110,93,172,149,138,242,225,195,376,17,3,4,12,20,35,62,53,47,83,75,68,119,201,107,207,9,15,13,23,38,67,58,103,90,161,72,127,117,110,209,206,16,45,21,39,69,64,114,99,87,158,140,252,212,199,387,365,26,75,36,68,65,115,101,179,164,155,264,246,226,395,382,362,9,66,30,59,56,102,185,173,265,142,253,232,400,388,378,445,16,111,54,52,100,184,178,160,133,257,244,228,217,385,366,715,10,98,48,91,88,165,157,148,261,248,407,397,372,380,889,884,8,85,84,81,159,156,143,260,249,427,401,392,383,727,713,708,7,154,76,73,141,131,256,245,426,406,394,384,735,359,710,352,11,139,129,67,125,247,233,229,219,393,743,737,720,885,882,439,4,243,120,118,115,227,223,396,746,742,736,721,712,706,223,436,6,202,224,222,218,216,389,386,381,364,888,443,707,440,437,1728,4,747,211,210,208,370,379,734,723,714,1735,883,877,876,3459,865,2,377,369,102,187,726,722,358,711,709,866,1734,871,3458,870,434,0,12,10,7,11,10,17,11,9,13,12,10,7,5,3,1,3],Ne.t24HB=[15,13,46,80,146,262,248,434,426,669,653,649,621,517,1032,88,14,12,21,38,71,130,122,216,209,198,327,345,319,297,279,42,47,22,41,74,68,128,120,221,207,194,182,340,315,295,541,18,81,39,75,70,134,125,116,220,204,190,178,325,311,293,271,16,147,72,69,135,127,118,112,210,200,188,352,323,306,285,540,14,263,66,129,126,119,114,214,202,192,180,341,317,301,281,262,12,249,123,121,117,113,215,206,195,185,347,330,308,291,272,520,10,435,115,111,109,211,203,196,187,353,332,313,298,283,531,381,17,427,212,208,205,201,193,186,177,169,320,303,286,268,514,377,16,335,199,197,191,189,181,174,333,321,305,289,275,521,379,371,11,668,184,183,179,175,344,331,314,304,290,277,530,383,373,366,10,652,346,171,168,164,318,309,299,287,276,263,513,375,368,362,6,648,322,316,312,307,302,292,284,269,261,512,376,370,364,359,4,620,300,296,294,288,282,273,266,515,380,374,369,365,361,357,2,1033,280,278,274,267,264,259,382,378,372,367,363,360,358,356,0,43,20,19,17,15,13,11,9,7,6,4,7,5,3,1,3],Ne.t32HB=[1<<0,5<<1,4<<1,5<<2,6<<1,5<<2,4<<2,4<<3,7<<1,3<<2,6<<2,0<<3,7<<2,2<<3,3<<3,1<<4],Ne.t33HB=[15<<0,14<<1,13<<1,12<<2,11<<1,10<<2,9<<2,8<<3,7<<1,6<<2,5<<2,4<<3,3<<2,2<<3,1<<3,0<<4],Ne.t1l=[1,4,3,5],Ne.t2l=[1,4,7,4,5,7,6,7,8],Ne.t3l=[2,3,7,4,4,7,6,7,8],Ne.t5l=[1,4,7,8,4,5,8,9,7,8,9,10,8,8,9,10],Ne.t6l=[3,4,6,8,4,4,6,7,5,6,7,8,7,7,8,9],Ne.t7l=[1,4,7,9,9,10,4,6,8,9,9,10,7,7,9,10,10,11,8,9,10,11,11,11,8,9,10,11,11,12,9,10,11,12,12,12],Ne.t8l=[2,4,7,9,9,10,4,4,6,10,10,10,7,6,8,10,10,11,9,10,10,11,11,12,9,9,10,11,12,12,10,10,11,11,13,13],Ne.t9l=[3,4,6,7,9,10,4,5,6,7,8,10,5,6,7,8,9,10,7,7,8,9,9,10,8,8,9,9,10,11,9,9,10,10,11,11],Ne.t10l=[1,4,7,9,10,10,10,11,4,6,8,9,10,11,10,10,7,8,9,10,11,12,11,11,8,9,10,11,12,12,11,12,9,10,11,12,12,12,12,12,10,11,12,12,13,13,12,13,9,10,11,12,12,12,13,13,10,10,11,12,12,13,13,13],Ne.t11l=[2,4,6,8,9,10,9,10,4,5,6,8,10,10,9,10,6,7,8,9,10,11,10,10,8,8,9,11,10,12,10,11,9,10,10,11,11,12,11,12,9,10,11,12,12,13,12,13,9,9,9,10,11,12,12,12,9,9,10,11,12,12,12,12],Ne.t12l=[4,4,6,8,9,10,10,10,4,5,6,7,9,9,10,10,6,6,7,8,9,10,9,10,7,7,8,8,9,10,10,10,8,8,9,9,10,10,10,11,9,9,10,10,10,11,10,11,9,9,9,10,10,11,11,12,10,10,10,11,11,11,11,12],Ne.t13l=[1,5,7,8,9,10,10,11,10,11,12,12,13,13,14,14,4,6,8,9,10,10,11,11,11,11,12,12,13,14,14,14,7,8,9,10,11,11,12,12,11,12,12,13,13,14,15,15,8,9,10,11,11,12,12,12,12,13,13,13,13,14,15,15,9,9,11,11,12,12,13,13,12,13,13,14,14,15,15,16,10,10,11,12,12,12,13,13,13,13,14,13,15,15,16,16,10,11,12,12,13,13,13,13,13,14,14,14,15,15,16,16,11,11,12,13,13,13,14,14,14,14,15,15,15,16,18,18,10,10,11,12,12,13,13,14,14,14,14,15,15,16,17,17,11,11,12,12,13,13,13,15,14,15,15,16,16,16,18,17,11,12,12,13,13,14,14,15,14,15,16,15,16,17,18,19,12,12,12,13,14,14,14,14,15,15,15,16,17,17,17,18,12,13,13,14,14,15,14,15,16,16,17,17,17,18,18,18,13,13,14,15,15,15,16,16,16,16,16,17,18,17,18,18,14,14,14,15,15,15,17,16,16,19,17,17,17,19,18,18,13,14,15,16,16,16,17,16,17,17,18,18,21,20,21,18],Ne.t15l=[3,5,6,8,8,9,10,10,10,11,11,12,12,12,13,14,5,5,7,8,9,9,10,10,10,11,11,12,12,12,13,13,6,7,7,8,9,9,10,10,10,11,11,12,12,13,13,13,7,8,8,9,9,10,10,11,11,11,12,12,12,13,13,13,8,8,9,9,10,10,11,11,11,11,12,12,12,13,13,13,9,9,9,10,10,10,11,11,11,11,12,12,13,13,13,14,10,9,10,10,10,11,11,11,11,12,12,12,13,13,14,14,10,10,10,11,11,11,11,12,12,12,12,12,13,13,13,14,10,10,10,11,11,11,11,12,12,12,12,13,13,14,14,14,10,10,11,11,11,11,12,12,12,13,13,13,13,14,14,14,11,11,11,11,12,12,12,12,12,13,13,13,13,14,15,14,11,11,11,11,12,12,12,12,13,13,13,13,14,14,14,15,12,12,11,12,12,12,13,13,13,13,13,13,14,14,15,15,12,12,12,12,12,13,13,13,13,14,14,14,14,14,15,15,13,13,13,13,13,13,13,13,14,14,14,14,15,15,14,15,13,13,13,13,13,13,13,14,14,14,14,14,15,15,15,15],Ne.t16_5l=[1,5,7,9,10,10,11,11,12,12,12,13,13,13,14,11,4,6,8,9,10,11,11,11,12,12,12,13,14,13,14,11,7,8,9,10,11,11,12,12,13,12,13,13,13,14,14,12,9,9,10,11,11,12,12,12,13,13,14,14,14,15,15,13,10,10,11,11,12,12,13,13,13,14,14,14,15,15,15,12,10,10,11,11,12,13,13,14,13,14,14,15,15,15,16,13,11,11,11,12,13,13,13,13,14,14,14,14,15,15,16,13,11,11,12,12,13,13,13,14,14,15,15,15,15,17,17,13,11,12,12,13,13,13,14,14,15,15,15,15,16,16,16,13,12,12,12,13,13,14,14,15,15,15,15,16,15,16,15,14,12,13,12,13,14,14,14,14,15,16,16,16,17,17,16,13,13,13,13,13,14,14,15,16,16,16,16,16,16,15,16,14,13,14,14,14,14,15,15,15,15,17,16,16,16,16,18,14,15,14,14,14,15,15,16,16,16,18,17,17,17,19,17,14,14,15,13,14,16,16,15,16,16,17,18,17,19,17,16,14,11,11,11,12,12,13,13,13,14,14,14,14,14,14,14,12],Ne.t16l=[1,5,7,9,10,10,11,11,12,12,12,13,13,13,14,10,4,6,8,9,10,11,11,11,12,12,12,13,14,13,14,10,7,8,9,10,11,11,12,12,13,12,13,13,13,14,14,11,9,9,10,11,11,12,12,12,13,13,14,14,14,15,15,12,10,10,11,11,12,12,13,13,13,14,14,14,15,15,15,11,10,10,11,11,12,13,13,14,13,14,14,15,15,15,16,12,11,11,11,12,13,13,13,13,14,14,14,14,15,15,16,12,11,11,12,12,13,13,13,14,14,15,15,15,15,17,17,12,11,12,12,13,13,13,14,14,15,15,15,15,16,16,16,12,12,12,12,13,13,14,14,15,15,15,15,16,15,16,15,13,12,13,12,13,14,14,14,14,15,16,16,16,17,17,16,12,13,13,13,13,14,14,15,16,16,16,16,16,16,15,16,13,13,14,14,14,14,15,15,15,15,17,16,16,16,16,18,13,15,14,14,14,15,15,16,16,16,18,17,17,17,19,17,13,14,15,13,14,16,16,15,16,16,17,18,17,19,17,16,13,10,10,10,11,11,12,12,12,13,13,13,13,13,13,13,10],Ne.t24l=[4,5,7,8,9,10,10,11,11,12,12,12,12,12,13,10,5,6,7,8,9,10,10,11,11,11,12,12,12,12,12,10,7,7,8,9,9,10,10,11,11,11,11,12,12,12,13,9,8,8,9,9,10,10,10,11,11,11,11,12,12,12,12,9,9,9,9,10,10,10,10,11,11,11,12,12,12,12,13,9,10,9,10,10,10,10,11,11,11,11,12,12,12,12,12,9,10,10,10,10,10,11,11,11,11,12,12,12,12,12,13,9,11,10,10,10,11,11,11,11,12,12,12,12,12,13,13,10,11,11,11,11,11,11,11,11,11,12,12,12,12,13,13,10,11,11,11,11,11,11,11,12,12,12,12,12,13,13,13,10,12,11,11,11,11,12,12,12,12,12,12,13,13,13,13,10,12,12,11,11,11,12,12,12,12,12,12,13,13,13,13,10,12,12,12,12,12,12,12,12,12,12,13,13,13,13,13,10,12,12,12,12,12,12,12,12,13,13,13,13,13,13,13,10,13,12,12,12,12,12,12,13,13,13,13,13,13,13,13,10,9,9,9,9,9,9,9,9,9,9,9,10,10,10,10,6],Ne.t32l=[1+0,4+1,4+1,5+2,4+1,6+2,5+2,6+3,4+1,5+2,5+2,6+3,5+2,6+3,6+3,6+4],Ne.t33l=[4+0,4+1,4+1,4+2,4+1,4+2,4+2,4+3,4+1,4+2,4+2,4+3,4+2,4+3,4+3,4+4],Ne.ht=[new wt(0,0,null,null),new wt(2,0,Ne.t1HB,Ne.t1l),new wt(3,0,Ne.t2HB,Ne.t2l),new wt(3,0,Ne.t3HB,Ne.t3l),new wt(0,0,null,null),new wt(4,0,Ne.t5HB,Ne.t5l),new wt(4,0,Ne.t6HB,Ne.t6l),new wt(6,0,Ne.t7HB,Ne.t7l),new wt(6,0,Ne.t8HB,Ne.t8l),new wt(6,0,Ne.t9HB,Ne.t9l),new wt(8,0,Ne.t10HB,Ne.t10l),new wt(8,0,Ne.t11HB,Ne.t11l),new wt(8,0,Ne.t12HB,Ne.t12l),new wt(16,0,Ne.t13HB,Ne.t13l),new wt(0,0,null,Ne.t16_5l),new wt(16,0,Ne.t15HB,Ne.t15l),new wt(1,1,Ne.t16HB,Ne.t16l),new wt(2,3,Ne.t16HB,Ne.t16l),new wt(3,7,Ne.t16HB,Ne.t16l),new wt(4,15,Ne.t16HB,Ne.t16l),new wt(6,63,Ne.t16HB,Ne.t16l),new wt(8,255,Ne.t16HB,Ne.t16l),new wt(10,1023,Ne.t16HB,Ne.t16l),new wt(13,8191,Ne.t16HB,Ne.t16l),new wt(4,15,Ne.t24HB,Ne.t24l),new wt(5,31,Ne.t24HB,Ne.t24l),new wt(6,63,Ne.t24HB,Ne.t24l),new wt(7,127,Ne.t24HB,Ne.t24l),new wt(8,255,Ne.t24HB,Ne.t24l),new wt(9,511,Ne.t24HB,Ne.t24l),new wt(11,2047,Ne.t24HB,Ne.t24l),new wt(13,8191,Ne.t24HB,Ne.t24l),new wt(0,0,Ne.t32HB,Ne.t32l),new wt(0,0,Ne.t33HB,Ne.t33l)],Ne.largetbl=[65540,327685,458759,589832,655369,655370,720906,720907,786443,786444,786444,851980,851980,851980,917517,655370,262149,393222,524295,589832,655369,720906,720906,720907,786443,786443,786444,851980,917516,851980,917516,655370,458759,524295,589832,655369,720905,720906,786442,786443,851979,786443,851979,851980,851980,917516,917517,720905,589832,589832,655369,720905,720906,786442,786442,786443,851979,851979,917515,917516,917516,983052,983052,786441,655369,655369,720905,720906,786442,786442,851978,851979,851979,917515,917516,917516,983052,983052,983053,720905,655370,655369,720906,720906,786442,851978,851979,917515,851979,917515,917516,983052,983052,983052,1048588,786441,720906,720906,720906,786442,851978,851979,851979,851979,917515,917516,917516,917516,983052,983052,1048589,786441,720907,720906,786442,786442,851979,851979,851979,917515,917516,983052,983052,983052,983052,1114125,1114125,786442,720907,786443,786443,851979,851979,851979,917515,917515,983051,983052,983052,983052,1048588,1048589,1048589,786442,786443,786443,786443,851979,851979,917515,917515,983052,983052,983052,983052,1048588,983053,1048589,983053,851978,786444,851979,786443,851979,917515,917516,917516,917516,983052,1048588,1048588,1048589,1114125,1114125,1048589,786442,851980,851980,851979,851979,917515,917516,983052,1048588,1048588,1048588,1048588,1048589,1048589,983053,1048589,851978,851980,917516,917516,917516,917516,983052,983052,983052,983052,1114124,1048589,1048589,1048589,1048589,1179661,851978,983052,917516,917516,917516,983052,983052,1048588,1048588,1048589,1179661,1114125,1114125,1114125,1245197,1114125,851978,917517,983052,851980,917516,1048588,1048588,983052,1048589,1048589,1114125,1179661,1114125,1245197,1114125,1048589,851978,655369,655369,655369,720905,720905,786441,786441,786441,851977,851977,851977,851978,851978,851978,851978,655366],Ne.table23=[65538,262147,458759,262148,327684,458759,393222,458759,524296],Ne.table56=[65539,262148,458758,524296,262148,327684,524294,589831,458757,524294,589831,655368,524295,524295,589832,655369],Ne.bitrate_table=[[0,8,16,24,32,40,48,56,64,80,96,112,128,144,160,-1],[0,32,40,48,56,64,80,96,112,128,160,192,224,256,320,-1],[0,8,16,24,32,40,48,56,64,-1,-1,-1,-1,-1,-1,-1]],Ne.samplerate_table=[[22050,24e3,16e3,-1],[44100,48e3,32e3,-1],[11025,12e3,8e3,-1]],Ne.scfsi_band=[0,6,11,16,21];var gt=Ne,wa=P.VbrMode,Vo=P.Float,W0=P.Util,Ra=P.new_float,n2=P.new_int,Kn=P.assert;Kr.Q_MAX=256+1,Kr.Q_MAX2=116,Kr.LARGE_BITS=1e5,Kr.IXMAX_VAL=8206;function Kr(){var C=null,$=null,ie=null;this.setModules=function(p,N,q){C=p,$=N,ie=q};function Z(p){return Kn(0<=p+Kr.Q_MAX2&&p<Kr.Q_MAX),M[p+Kr.Q_MAX2]}this.IPOW20=function(p){return Kn(0<=p&&p<Kr.Q_MAX),X[p]};var Re=2220446049250313e-31,J=Kr.IXMAX_VAL,me=J+2,Fe=Kr.Q_MAX,Oe=Kr.Q_MAX2,z=Kr.LARGE_BITS,ve=100;this.nr_of_sfb_block=[[[6,5,5,5],[9,9,9,9],[6,9,9,9]],[[6,5,7,3],[9,9,12,6],[6,9,12,6]],[[11,10,0,0],[18,18,0,0],[15,18,0,0]],[[7,7,7,0],[12,12,12,0],[6,15,12,0]],[[6,6,6,3],[12,9,9,6],[6,12,9,6]],[[8,8,5,0],[15,12,9,0],[6,18,9,0]]];var pe=[0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,2,2,3,3,3,2,0];this.pretab=pe,this.sfBandIndex=[new Fn([0,6,12,18,24,30,36,44,54,66,80,96,116,140,168,200,238,284,336,396,464,522,576],[0,4,8,12,18,24,32,42,56,74,100,132,174,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Fn([0,6,12,18,24,30,36,44,54,66,80,96,114,136,162,194,232,278,332,394,464,540,576],[0,4,8,12,18,26,36,48,62,80,104,136,180,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Fn([0,6,12,18,24,30,36,44,54,66,80,96,116,140,168,200,238,284,336,396,464,522,576],[0,4,8,12,18,26,36,48,62,80,104,134,174,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Fn([0,4,8,12,16,20,24,30,36,44,52,62,74,90,110,134,162,196,238,288,342,418,576],[0,4,8,12,16,22,30,40,52,66,84,106,136,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Fn([0,4,8,12,16,20,24,30,36,42,50,60,72,88,106,128,156,190,230,276,330,384,576],[0,4,8,12,16,22,28,38,50,64,80,100,126,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Fn([0,4,8,12,16,20,24,30,36,44,54,66,82,102,126,156,194,240,296,364,448,550,576],[0,4,8,12,16,22,30,42,58,78,104,138,180,192],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Fn([0,6,12,18,24,30,36,44,54,66,80,96,116,140,168,200,238,284,336,396,464,522,576],[0/3,12/3,24/3,36/3,54/3,78/3,108/3,144/3,186/3,240/3,312/3,402/3,522/3,576/3],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Fn([0,6,12,18,24,30,36,44,54,66,80,96,116,140,168,200,238,284,336,396,464,522,576],[0/3,12/3,24/3,36/3,54/3,78/3,108/3,144/3,186/3,240/3,312/3,402/3,522/3,576/3],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]),new Fn([0,12,24,36,48,60,72,88,108,132,160,192,232,280,336,400,476,566,568,570,572,574,576],[0/3,24/3,48/3,72/3,108/3,156/3,216/3,288/3,372/3,480/3,486/3,492/3,498/3,576/3],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0])];var M=Ra(Fe+Oe+1),X=Ra(Fe),o=Ra(me),I=Ra(me);this.adj43=I;function U(p,N){var q=ie.ATHformula(N,p);return q-=ve,q=Math.pow(10,q/10+p.ATHlower),q}function F(p){for(var N=p.internal_flags.ATH.l,q=p.internal_flags.ATH.psfb21,w=p.internal_flags.ATH.s,u=p.internal_flags.ATH.psfb12,L=p.internal_flags,E=p.out_samplerate,c=0;c<g.SBMAX_l;c++){var d=L.scalefac_band.l[c],b=L.scalefac_band.l[c+1];N[c]=Vo.MAX_VALUE;for(var l=d;l<b;l++){var v=l*E/1152,y=U(p,v);N[c]=Math.min(N[c],y)}}for(var c=0;c<g.PSFB21;c++){var d=L.scalefac_band.psfb21[c],b=L.scalefac_band.psfb21[c+1];q[c]=Vo.MAX_VALUE;for(var l=d;l<b;l++){var v=l*E/1152,y=U(p,v);q[c]=Math.min(q[c],y)}}for(var c=0;c<g.SBMAX_s;c++){var d=L.scalefac_band.s[c],b=L.scalefac_band.s[c+1];w[c]=Vo.MAX_VALUE;for(var l=d;l<b;l++){var v=l*E/384,y=U(p,v);w[c]=Math.min(w[c],y)}w[c]*=L.scalefac_band.s[c+1]-L.scalefac_band.s[c]}for(var c=0;c<g.PSFB12;c++){var d=L.scalefac_band.psfb12[c],b=L.scalefac_band.psfb12[c+1];u[c]=Vo.MAX_VALUE;for(var l=d;l<b;l++){var v=l*E/384,y=U(p,v);u[c]=Math.min(u[c],y)}u[c]*=L.scalefac_band.s[13]-L.scalefac_band.s[12]}if(p.noATH){for(var c=0;c<g.SBMAX_l;c++)N[c]=1e-20;for(var c=0;c<g.PSFB21;c++)q[c]=1e-20;for(var c=0;c<g.SBMAX_s;c++)w[c]=1e-20;for(var c=0;c<g.PSFB12;c++)u[c]=1e-20}L.ATH.floor=10*Math.log10(U(p,-1))}this.iteration_init=function(p){var N=p.internal_flags,q=N.l3_side,w;if(N.iteration_init_init==0){for(N.iteration_init_init=1,q.main_data_begin=0,F(p),o[0]=0,w=1;w<me;w++)o[w]=Math.pow(w,4/3);for(w=0;w<me-1;w++)I[w]=w+1-Math.pow(.5*(o[w]+o[w+1]),.75);for(I[w]=.5,w=0;w<Fe;w++)X[w]=Math.pow(2,(w-210)*-.1875);for(w=0;w<=Fe+Oe;w++)M[w]=Math.pow(2,(w-210-Oe)*.25);C.huffman_init(N);{var u,L,E,c;for(w=p.exp_nspsytune>>2&63,w>=32&&(w-=64),u=Math.pow(10,w/4/10),w=p.exp_nspsytune>>8&63,w>=32&&(w-=64),L=Math.pow(10,w/4/10),w=p.exp_nspsytune>>14&63,w>=32&&(w-=64),E=Math.pow(10,w/4/10),w=p.exp_nspsytune>>20&63,w>=32&&(w-=64),c=E*Math.pow(10,w/4/10),w=0;w<g.SBMAX_l;w++){var d;w<=6?d=u:w<=13?d=L:w<=20?d=E:d=c,N.nsPsy.longfact[w]=d}for(w=0;w<g.SBMAX_s;w++){var d;w<=5?d=u:w<=10?d=L:w<=11?d=E:d=c,N.nsPsy.shortfact[w]=d}}}},this.on_pe=function(p,N,q,w,u,L){var E=p.internal_flags,c=0,d,b=n2(2),l,v=new E1(c),y=$.ResvMaxBits(p,w,v,L);c=v.bits;var T=c+y;for(T>Dt.MAX_BITS_PER_GRANULE&&(T=Dt.MAX_BITS_PER_GRANULE),d=0,l=0;l<E.channels_out;++l)q[l]=Math.min(Dt.MAX_BITS_PER_CHANNEL,c/E.channels_out),b[l]=0|q[l]*N[u][l]/700-q[l],b[l]>w*3/4&&(b[l]=w*3/4),b[l]<0&&(b[l]=0),b[l]+q[l]>Dt.MAX_BITS_PER_CHANNEL&&(b[l]=Math.max(0,Dt.MAX_BITS_PER_CHANNEL-q[l])),d+=b[l];if(d>y)for(l=0;l<E.channels_out;++l)b[l]=y*b[l]/d;for(l=0;l<E.channels_out;++l)q[l]+=b[l],y-=b[l];for(d=0,l=0;l<E.channels_out;++l)d+=q[l];if(d>Dt.MAX_BITS_PER_GRANULE){var G=0;for(l=0;l<E.channels_out;++l)q[l]*=Dt.MAX_BITS_PER_GRANULE,q[l]/=d,G+=q[l];Kn(G<=Dt.MAX_BITS_PER_GRANULE)}return T},this.reduce_side=function(p,N,q,w){Kn(w<=Dt.MAX_BITS_PER_GRANULE),Kn(p[0]+p[1]<=Dt.MAX_BITS_PER_GRANULE);var u=.33*(.5-N)/.5;u<0&&(u=0),u>.5&&(u=.5);var L=0|u*.5*(p[0]+p[1]);L>Dt.MAX_BITS_PER_CHANNEL-p[0]&&(L=Dt.MAX_BITS_PER_CHANNEL-p[0]),L<0&&(L=0),p[1]>=125&&(p[1]-L>125?(p[0]<q&&(p[0]+=L),p[1]-=L):(p[0]+=p[1]-125,p[1]=125)),L=p[0]+p[1],L>w&&(p[0]=w*p[0]/L,p[1]=w*p[1]/L),Kn(p[0]<=Dt.MAX_BITS_PER_CHANNEL),Kn(p[1]<=Dt.MAX_BITS_PER_CHANNEL),Kn(p[0]+p[1]<=Dt.MAX_BITS_PER_GRANULE)},this.athAdjust=function(p,N,q){var w=90.30873362,u=94.82444863,L=W0.FAST_LOG10_X(N,10),E=p*p,c=0;return L-=q,E>1e-20&&(c=1+W0.FAST_LOG10_X(E,10/w)),c<0&&(c=0),L*=c,L+=q+w-u,Math.pow(10,.1*L)},this.calc_xmin=function(p,N,q,w){var u=0,L=p.internal_flags,E,c=0,d=0,b=L.ATH,l=q.xr,v=p.VBR==wa.vbr_mtrh?1:0,y=L.masking_lower;for((p.VBR==wa.vbr_mtrh||p.VBR==wa.vbr_mt)&&(y=1),E=0;E<q.psy_lmax;E++){var T,G,H,j,be,f;p.VBR==wa.vbr_rh||p.VBR==wa.vbr_mtrh?G=athAdjust(b.adjust,b.l[E],b.floor):G=b.adjust*b.l[E],be=q.width[E],H=G/be,j=Re,f=be>>1,T=0;do{var S,ce;S=l[c]*l[c],T+=S,j+=S<H?S:H,c++,ce=l[c]*l[c],T+=ce,j+=ce<H?ce:H,c++}while(--f>0);if(T>G&&d++,E==g.SBPSY_l){var xe=G*L.nsPsy.longfact[E];j<xe&&(j=xe)}if(v!=0&&(G=j),!p.ATHonly){var ke=N.en.l[E];if(ke>0){var xe;xe=T*N.thm.l[E]*y/ke,v!=0&&(xe*=L.nsPsy.longfact[E]),G<xe&&(G=xe)}}v!=0?w[u++]=G:w[u++]=G*L.nsPsy.longfact[E]}var Ve=575;if(q.block_type!=g.SHORT_TYPE)for(var Xe=576;Xe--!=0&&Wn.EQ(l[Xe],0);)Ve=Xe;q.max_nonzero_coeff=Ve;for(var Ge=q.sfb_smin;E<q.psymax;Ge++,E+=3){var be,it,We;for(p.VBR==wa.vbr_rh||p.VBR==wa.vbr_mtrh?We=athAdjust(b.adjust,b.s[Ge],b.floor):We=b.adjust*b.s[Ge],be=q.width[E],it=0;it<3;it++){var T=0,G,H,j,f=be>>1;H=We/be,j=Re;do{var S,ce;S=l[c]*l[c],T+=S,j+=S<H?S:H,c++,ce=l[c]*l[c],T+=ce,j+=ce<H?ce:H,c++}while(--f>0);if(T>We&&d++,Ge==g.SBPSY_s){var xe=We*L.nsPsy.shortfact[Ge];j<xe&&(j=xe)}if(v!=0?G=j:G=We,!p.ATHonly&&!p.ATHshort){var ke=N.en.s[Ge][it];if(ke>0){var xe;xe=T*N.thm.s[Ge][it]*y/ke,v!=0&&(xe*=L.nsPsy.shortfact[Ge]),G<xe&&(G=xe)}}v!=0?w[u++]=G:w[u++]=G*L.nsPsy.shortfact[Ge]}p.useTemporal&&(w[u-3]>w[u-3+1]&&(w[u-3+1]+=(w[u-3]-w[u-3+1])*L.decay),w[u-3+1]>w[u-3+2]&&(w[u-3+2]+=(w[u-3+1]-w[u-3+2])*L.decay))}return d};function x(p){this.s=p}this.calc_noise_core=function(p,N,q,w){var u=0,L=N.s,E=p.l3_enc;if(L>p.count1)for(;q--!=0;){var c;c=p.xr[L],L++,u+=c*c,c=p.xr[L],L++,u+=c*c}else if(L>p.big_values){var d=Ra(2);for(d[0]=0,d[1]=w;q--!=0;){var c;c=Math.abs(p.xr[L])-d[E[L]],L++,u+=c*c,c=Math.abs(p.xr[L])-d[E[L]],L++,u+=c*c}}else for(;q--!=0;){var c;c=Math.abs(p.xr[L])-o[E[L]]*w,L++,u+=c*c,c=Math.abs(p.xr[L])-o[E[L]]*w,L++,u+=c*c}return N.s=L,u},this.calc_noise=function(p,N,q,w,u){var L=0,E=0,c,d,b=0,l=0,v=0,y=-20,T=0,G=p.scalefac,H=0;for(w.over_SSD=0,c=0;c<p.psymax;c++){var j=p.global_gain-(G[H++]+(p.preflag!=0?pe[c]:0)<<p.scalefac_scale+1)-p.subblock_gain[p.window[c]]*8,be=0;if(u!=null&&u.step[c]==j)be=u.noise[c],T+=p.width[c],q[L++]=be/N[E++],be=u.noise_log[c];else{var f=Z(j);if(d=p.width[c]>>1,T+p.width[c]>p.max_nonzero_coeff){var S;S=p.max_nonzero_coeff-T+1,S>0?d=S>>1:d=0}var ce=new x(T);be=this.calc_noise_core(p,ce,d,f),T=ce.s,u!=null&&(u.step[c]=j,u.noise[c]=be),be=q[L++]=be/N[E++],be=W0.FAST_LOG10(Math.max(be,1e-20)),u!=null&&(u.noise_log[c]=be)}if(u!=null&&(u.global_gain=p.global_gain),v+=be,be>0){var xe;xe=Math.max(0|be*10+.5,1),w.over_SSD+=xe*xe,b++,l+=be}y=Math.max(y,be)}return w.over_count=b,w.tot_noise=v,w.over_noise=l,w.max_noise=y,b},this.set_pinfo=function(p,N,q,w,u){var L=p.internal_flags,E,c,d,b,l,v=N.scalefac_scale==0?.5:1,y=N.scalefac,T=Ra(L3Side.SFBMAX),G=Ra(L3Side.SFBMAX),H=new CalcNoiseResult;calc_xmin(p,q,N,T),calc_noise(N,T,G,H,null);var j=0;for(c=N.sfb_lmax,N.block_type!=g.SHORT_TYPE&&N.mixed_block_flag==0&&(c=22),E=0;E<c;E++){var be=L.scalefac_band.l[E],f=L.scalefac_band.l[E+1],S=f-be;for(b=0;j<f;j++)b+=N.xr[j]*N.xr[j];b/=S,l=1e15,L.pinfo.en[w][u][E]=l*b,L.pinfo.xfsf[w][u][E]=l*T[E]*G[E]/S,q.en.l[E]>0&&!p.ATHonly?b=b/q.en.l[E]:b=0,L.pinfo.thr[w][u][E]=l*Math.max(b*q.thm.l[E],L.ATH.l[E]),L.pinfo.LAMEsfb[w][u][E]=0,N.preflag!=0&&E>=11&&(L.pinfo.LAMEsfb[w][u][E]=-v*pe[E]),E<g.SBPSY_l&&(Kn(y[E]>=0),L.pinfo.LAMEsfb[w][u][E]-=v*y[E])}if(N.block_type==g.SHORT_TYPE)for(c=E,E=N.sfb_smin;E<g.SBMAX_s;E++)for(var be=L.scalefac_band.s[E],f=L.scalefac_band.s[E+1],S=f-be,ce=0;ce<3;ce++){for(b=0,d=be;d<f;d++)b+=N.xr[j]*N.xr[j],j++;b=Math.max(b/S,1e-20),l=1e15,L.pinfo.en_s[w][u][3*E+ce]=l*b,L.pinfo.xfsf_s[w][u][3*E+ce]=l*T[c]*G[c]/S,q.en.s[E][ce]>0?b=b/q.en.s[E][ce]:b=0,(p.ATHonly||p.ATHshort)&&(b=0),L.pinfo.thr_s[w][u][3*E+ce]=l*Math.max(b*q.thm.s[E][ce],L.ATH.s[E]),L.pinfo.LAMEsfb_s[w][u][3*E+ce]=-2*N.subblock_gain[ce],E<g.SBPSY_s&&(L.pinfo.LAMEsfb_s[w][u][3*E+ce]-=v*y[c]),c++}L.pinfo.LAMEqss[w][u]=N.global_gain,L.pinfo.LAMEmainbits[w][u]=N.part2_3_length+N.part2_length,L.pinfo.LAMEsfbits[w][u]=N.part2_length,L.pinfo.over[w][u]=H.over_count,L.pinfo.max_noise[w][u]=H.max_noise*10,L.pinfo.over_noise[w][u]=H.over_noise*10,L.pinfo.tot_noise[w][u]=H.tot_noise*10,L.pinfo.over_SSD[w][u]=H.over_SSD}}var na=Kr,a2=P.System,i2=P.Arrays,Hi=P.new_int,cn=P.assert;function Y0(){var C=null;this.qupvt=null,this.setModules=function(c){this.qupvt=c,C=c};function $(c){this.bits=0|c}var ie=[[0,0],[0,0],[0,0],[0,0],[0,0],[0,1],[1,1],[1,1],[1,2],[2,2],[2,3],[2,3],[3,4],[3,4],[3,4],[4,5],[4,5],[4,6],[5,6],[5,6],[5,7],[6,7],[6,7]];function Z(c,d,b,l,v,y){var T=.5946/d;for(cn(c>0),c=c>>1;c--!=0;)v[y++]=T>b[l++]?0:1,v[y++]=T>b[l++]?0:1}function Re(c,d,b,l,v,y){cn(c>0),c=c>>1;var T=c%2;for(c=c>>1;c--!=0;){var G,H,j,be,f,S,ce,xe;G=b[l++]*d,H=b[l++]*d,f=0|G,j=b[l++]*d,S=0|H,be=b[l++]*d,ce=0|j,G+=C.adj43[f],xe=0|be,H+=C.adj43[S],v[y++]=0|G,j+=C.adj43[ce],v[y++]=0|H,be+=C.adj43[xe],v[y++]=0|j,v[y++]=0|be}if(T!=0){var G,H,f,S;G=b[l++]*d,H=b[l++]*d,f=0|G,S=0|H,G+=C.adj43[f],H+=C.adj43[S],v[y++]=0|G,v[y++]=0|H}}function J(c,d,b,l,v){var y,T,G=0,H,j=0,be=0,f=0,S=d,ce=0,xe=S,ke=0,Ve=c,Xe=0;for(H=v!=null&&l.global_gain==v.global_gain,l.block_type==g.SHORT_TYPE?T=38:T=21,y=0;y<=T;y++){var Ge=-1;if((H||l.block_type==g.NORM_TYPE)&&(Ge=l.global_gain-(l.scalefac[y]+(l.preflag!=0?C.pretab[y]:0)<<l.scalefac_scale+1)-l.subblock_gain[l.window[y]]*8),cn(l.width[y]>=0),H&&v.step[y]==Ge)j!=0&&(Re(j,b,Ve,Xe,xe,ke),j=0),be!=0&&(Z(be,b,Ve,Xe,xe,ke),be=0);else{var it=l.width[y];if(G+l.width[y]>l.max_nonzero_coeff){var We;We=l.max_nonzero_coeff-G+1,i2.fill(d,l.max_nonzero_coeff,576,0),it=We,it<0&&(it=0),y=T+1}if(j==0&&be==0&&(xe=S,ke=ce,Ve=c,Xe=f),v!=null&&v.sfb_count1>0&&y>=v.sfb_count1&&v.step[y]>0&&Ge>=v.step[y]?(j!=0&&(Re(j,b,Ve,Xe,xe,ke),j=0,xe=S,ke=ce,Ve=c,Xe=f),be+=it):(be!=0&&(Z(be,b,Ve,Xe,xe,ke),be=0,xe=S,ke=ce,Ve=c,Xe=f),j+=it),it<=0){be!=0&&(Z(be,b,Ve,Xe,xe,ke),be=0),j!=0&&(Re(j,b,Ve,Xe,xe,ke),j=0);break}}y<=T&&(ce+=l.width[y],f+=l.width[y],G+=l.width[y])}j!=0&&(Re(j,b,Ve,Xe,xe,ke),j=0),be!=0&&(Z(be,b,Ve,Xe,xe,ke),be=0)}function me(c,d,b){var l=0,v=0;do{var y=c[d++],T=c[d++];l<y&&(l=y),v<T&&(v=T)}while(d<b);return l<v&&(l=v),l}function Fe(c,d,b,l,v,y){var T=gt.ht[l].xlen*65536+gt.ht[v].xlen,G=0,H;do{var j=c[d++],be=c[d++];j!=0&&(j>14&&(j=15,G+=T),j*=16),be!=0&&(be>14&&(be=15,G+=T),j+=be),G+=gt.largetbl[j]}while(d<b);return H=G&65535,G>>=16,G>H&&(G=H,l=v),y.bits+=G,l}function Oe(c,d,b,l){var v=0,y=gt.ht[1].hlen;do{var T=c[d+0]*2+c[d+1];d+=2,v+=y[T]}while(d<b);return l.bits+=v,1}function z(c,d,b,l,v){var y=0,T,G=gt.ht[l].xlen,H;l==2?H=gt.table23:H=gt.table56;do{var j=c[d+0]*G+c[d+1];d+=2,y+=H[j]}while(d<b);return T=y&65535,y>>=16,y>T&&(y=T,l++),v.bits+=y,l}function ve(c,d,b,l,v){var y=0,T=0,G=0,H=gt.ht[l].xlen,j=gt.ht[l].hlen,be=gt.ht[l+1].hlen,f=gt.ht[l+2].hlen;do{var S=c[d+0]*H+c[d+1];d+=2,y+=j[S],T+=be[S],G+=f[S]}while(d<b);var ce=l;return y>T&&(y=T,ce++),y>G&&(y=G,ce=l+2),v.bits+=y,ce}var pe=[1,2,5,7,7,10,10,13,13,13,13,13,13,13,13];function M(c,d,b,l){var v=me(c,d,b);switch(v){case 0:return v;case 1:return Oe(c,d,b,l);case 2:case 3:return z(c,d,b,pe[v-1],l);case 4:case 5:case 6:case 7:case 8:case 9:case 10:case 11:case 12:case 13:case 14:case 15:return ve(c,d,b,pe[v-1],l);default:if(v>na.IXMAX_VAL)return l.bits=na.LARGE_BITS,-1;v-=15;var y;for(y=24;y<32&&!(gt.ht[y].linmax>=v);y++);var T;for(T=y-8;T<24&&!(gt.ht[T].linmax>=v);T++);return Fe(c,d,b,T,y,l)}}this.noquant_count_bits=function(c,d,b){var l=d.l3_enc,v=Math.min(576,d.max_nonzero_coeff+2>>1<<1);for(b!=null&&(b.sfb_count1=0);v>1&&(l[v-1]|l[v-2])==0;v-=2);d.count1=v;for(var y=0,T=0;v>3;v-=4){var G;if(((l[v-1]|l[v-2]|l[v-3]|l[v-4])&2147483647)>1)break;G=((l[v-4]*2+l[v-3])*2+l[v-2])*2+l[v-1],y+=gt.t32l[G],T+=gt.t33l[G]}var H=y;if(d.count1table_select=0,y>T&&(H=T,d.count1table_select=1),d.count1bits=H,d.big_values=v,v==0)return H;if(d.block_type==g.SHORT_TYPE)y=3*c.scalefac_band.s[3],y>d.big_values&&(y=d.big_values),T=d.big_values;else if(d.block_type==g.NORM_TYPE){if(cn(v<=576),y=d.region0_count=c.bv_scf[v-2],T=d.region1_count=c.bv_scf[v-1],cn(y+T+2<g.SBPSY_l),T=c.scalefac_band.l[y+T+2],y=c.scalefac_band.l[y+1],T<v){var j=new $(H);d.table_select[2]=M(l,T,v,j),H=j.bits}}else d.region0_count=7,d.region1_count=g.SBMAX_l-1-7-1,y=c.scalefac_band.l[7+1],T=v,y>T&&(y=T);if(y=Math.min(y,v),T=Math.min(T,v),cn(y>=0),cn(T>=0),0<y){var j=new $(H);d.table_select[0]=M(l,0,y,j),H=j.bits}if(y<T){var j=new $(H);d.table_select[1]=M(l,y,T,j),H=j.bits}if(c.use_best_huffman==2&&(d.part2_3_length=H,best_huffman_divide(c,d),H=d.part2_3_length),b!=null&&d.block_type==g.NORM_TYPE){for(var be=0;c.scalefac_band.l[be]<d.big_values;)be++;b.sfb_count1=be}return H},this.count_bits=function(c,d,b,l){var v=b.l3_enc,y=na.IXMAX_VAL/C.IPOW20(b.global_gain);if(b.xrpow_max>y)return na.LARGE_BITS;if(J(d,v,C.IPOW20(b.global_gain),b,l),(c.substep_shaping&2)!=0)for(var T=0,G=b.global_gain+b.scalefac_scale,H=.634521682242439/C.IPOW20(G),j=0;j<b.sfbmax;j++){var be=b.width[j];if(cn(be>=0),c.pseudohalf[j]==0)T+=be;else{var f;for(f=T,T+=be;f<T;++f)v[f]=d[f]>=H?v[f]:0}}return this.noquant_count_bits(c,b,l)};function X(c,d,b,l,v,y,T){for(var G=d.big_values,H=0;H<=7+15;H++)l[H]=na.LARGE_BITS;for(var H=0;H<16;H++){var j=c.scalefac_band.l[H+1];if(j>=G)break;var be=0,f=new $(be),S=M(b,0,j,f);be=f.bits;for(var ce=0;ce<8;ce++){var xe=c.scalefac_band.l[H+ce+2];if(xe>=G)break;var ke=be;f=new $(ke);var Ve=M(b,j,xe,f);ke=f.bits,l[H+ce]>ke&&(l[H+ce]=ke,v[H+ce]=H,y[H+ce]=S,T[H+ce]=Ve)}}}function o(c,d,b,l,v,y,T,G){for(var H=d.big_values,j=2;j<g.SBMAX_l+1;j++){var be=c.scalefac_band.l[j];if(be>=H)break;var f=v[j-2]+d.count1bits;if(b.part2_3_length<=f)break;var S=new $(f),ce=M(l,be,H,S);f=S.bits,!(b.part2_3_length<=f)&&(b.assign(d),b.part2_3_length=f,b.region0_count=y[j-2],b.region1_count=j-2-y[j-2],b.table_select[0]=T[j-2],b.table_select[1]=G[j-2],b.table_select[2]=ce)}}this.best_huffman_divide=function(c,d){var b=new Oo,l=d.l3_enc,v=Hi(7+15+1),y=Hi(7+15+1),T=Hi(7+15+1),G=Hi(7+15+1);if(!(d.block_type==g.SHORT_TYPE&&c.mode_gr==1)){b.assign(d),d.block_type==g.NORM_TYPE&&(X(c,d,l,v,y,T,G),o(c,b,d,l,v,y,T,G));var H=b.big_values;if(!(H==0||(l[H-2]|l[H-1])>1)&&(H=d.count1+2,!(H>576))){b.assign(d),b.count1=H;var j=0,be=0;for(cn(H<=576);H>b.big_values;H-=4){var f=((l[H-4]*2+l[H-3])*2+l[H-2])*2+l[H-1];j+=gt.t32l[f],be+=gt.t33l[f]}if(b.big_values=H,b.count1table_select=0,j>be&&(j=be,b.count1table_select=1),b.count1bits=j,b.block_type==g.NORM_TYPE)o(c,b,d,l,v,y,T,G);else{if(b.part2_3_length=j,j=c.scalefac_band.l[7+1],j>H&&(j=H),j>0){var S=new $(b.part2_3_length);b.table_select[0]=M(l,0,j,S),b.part2_3_length=S.bits}if(H>j){var S=new $(b.part2_3_length);b.table_select[1]=M(l,j,H,S),b.part2_3_length=S.bits}d.part2_3_length>b.part2_3_length&&d.assign(b)}}}};var I=[1,1,1,1,8,2,2,2,4,4,4,8,8,8,16,16],U=[1,2,4,8,1,2,4,8,2,4,8,2,4,8,4,8],F=[0,0,0,0,3,1,1,1,2,2,2,3,3,3,4,4],x=[0,1,2,3,0,1,2,3,1,2,3,1,2,3,2,3];Y0.slen1_tab=F,Y0.slen2_tab=x;function p(c,d){for(var b,l=d.tt[1][c],v=d.tt[0][c],y=0;y<gt.scfsi_band.length-1;y++){for(b=gt.scfsi_band[y];b<gt.scfsi_band[y+1]&&!(v.scalefac[b]!=l.scalefac[b]&&l.scalefac[b]>=0);b++);if(b==gt.scfsi_band[y+1]){for(b=gt.scfsi_band[y];b<gt.scfsi_band[y+1];b++)l.scalefac[b]=-1;d.scfsi[c][y]=1}}var T=0,G=0;for(b=0;b<11;b++)l.scalefac[b]!=-1&&(G++,T<l.scalefac[b]&&(T=l.scalefac[b]));for(var H=0,j=0;b<g.SBPSY_l;b++)l.scalefac[b]!=-1&&(j++,H<l.scalefac[b]&&(H=l.scalefac[b]));for(var y=0;y<16;y++)if(T<I[y]&&H<U[y]){var be=F[y]*G+x[y]*j;l.part2_length>be&&(l.part2_length=be,l.scalefac_compress=y)}}this.best_scalefac_store=function(c,d,b,l){var v=l.tt[d][b],y,T,G,H,j=0;for(G=0,y=0;y<v.sfbmax;y++){var be=v.width[y];for(cn(be>=0),G+=be,H=-be;H<0&&v.l3_enc[H+G]==0;H++);H==0&&(v.scalefac[y]=j=-2)}if(v.scalefac_scale==0&&v.preflag==0){var f=0;for(y=0;y<v.sfbmax;y++)v.scalefac[y]>0&&(f|=v.scalefac[y]);if((f&1)==0&&f!=0){for(y=0;y<v.sfbmax;y++)v.scalefac[y]>0&&(v.scalefac[y]>>=1);v.scalefac_scale=j=1}}if(v.preflag==0&&v.block_type!=g.SHORT_TYPE&&c.mode_gr==2){for(y=11;y<g.SBPSY_l&&!(v.scalefac[y]<C.pretab[y]&&v.scalefac[y]!=-2);y++);if(y==g.SBPSY_l){for(y=11;y<g.SBPSY_l;y++)v.scalefac[y]>0&&(v.scalefac[y]-=C.pretab[y]);v.preflag=j=1}}for(T=0;T<4;T++)l.scfsi[b][T]=0;for(c.mode_gr==2&&d==1&&l.tt[0][b].block_type!=g.SHORT_TYPE&&l.tt[1][b].block_type!=g.SHORT_TYPE&&(p(b,l),j=0),y=0;y<v.sfbmax;y++)v.scalefac[y]==-2&&(v.scalefac[y]=0);j!=0&&(c.mode_gr==2?this.scale_bitcount(v):this.scale_bitcount_lsf(c,v))};function N(c,d){for(var b=0;b<d;++b)if(c[b]<0)return!1;return!0}var q=[0,18,36,54,54,36,54,72,54,72,90,72,90,108,108,126],w=[0,18,36,54,51,35,53,71,52,70,88,69,87,105,104,122],u=[0,10,20,30,33,21,31,41,32,42,52,43,53,63,64,74];this.scale_bitcount=function(c){var d,b,l=0,v=0,y,T=c.scalefac;if(cn(N(T,c.sfbmax)),c.block_type==g.SHORT_TYPE)y=q,c.mixed_block_flag!=0&&(y=w);else if(y=u,c.preflag==0){for(b=11;b<g.SBPSY_l&&!(T[b]<C.pretab[b]);b++);if(b==g.SBPSY_l)for(c.preflag=1,b=11;b<g.SBPSY_l;b++)T[b]-=C.pretab[b]}for(b=0;b<c.sfbdivide;b++)l<T[b]&&(l=T[b]);for(;b<c.sfbmax;b++)v<T[b]&&(v=T[b]);for(c.part2_length=na.LARGE_BITS,d=0;d<16;d++)l<I[d]&&v<U[d]&&c.part2_length>y[d]&&(c.part2_length=y[d],c.scalefac_compress=d);return c.part2_length==na.LARGE_BITS};var L=[[15,15,7,7],[15,15,7,0],[7,3,0,0],[15,31,31,0],[7,7,7,0],[3,3,0,0]];this.scale_bitcount_lsf=function(c,d){var b,l,v,y,T,G,H,j,be=Hi(4),f=d.scalefac;for(d.preflag!=0?b=2:b=0,H=0;H<4;H++)be[H]=0;if(d.block_type==g.SHORT_TYPE){l=1;var S=C.nr_of_sfb_block[b][l];for(j=0,v=0;v<4;v++)for(y=S[v]/3,H=0;H<y;H++,j++)for(T=0;T<3;T++)f[j*3+T]>be[v]&&(be[v]=f[j*3+T])}else{l=0;var S=C.nr_of_sfb_block[b][l];for(j=0,v=0;v<4;v++)for(y=S[v],H=0;H<y;H++,j++)f[j]>be[v]&&(be[v]=f[j])}for(G=!1,v=0;v<4;v++)be[v]>L[b][v]&&(G=!0);if(!G){var ce,xe,ke,Ve;for(d.sfb_partition_table=C.nr_of_sfb_block[b][l],v=0;v<4;v++)d.slen[v]=E[be[v]];switch(ce=d.slen[0],xe=d.slen[1],ke=d.slen[2],Ve=d.slen[3],b){case 0:d.scalefac_compress=(ce*5+xe<<4)+(ke<<2)+Ve;break;case 1:d.scalefac_compress=400+(ce*5+xe<<2)+ke;break;case 2:d.scalefac_compress=500+ce*3+xe;break;default:a2.err.printf(`intensity stereo not implemented yet
2
+ `);break}}if(!G)for(cn(d.sfb_partition_table!=null),d.part2_length=0,v=0;v<4;v++)d.part2_length+=d.slen[v]*d.sfb_partition_table[v];return G};var E=[0,1,2,2,3,3,3,3,4,4,4,4,4,4,4,4];this.huffman_init=function(c){for(var d=2;d<=576;d+=2){for(var b=0,l;c.scalefac_band.l[++b]<d;);for(l=ie[b][0];c.scalefac_band.l[l+1]>d;)l--;for(l<0&&(l=ie[b][0]),c.bv_scf[d-2]=l,l=ie[b][1];c.scalefac_band.l[l+c.bv_scf[d-2]+2]>d;)l--;l<0&&(l=ie[b][1]),c.bv_scf[d-1]=l}}}var $0=Y0,Ln=P.System,o2=P.Arrays,s2=P.new_byte,l2=P.new_float_n,u2=P.new_int,vt=P.assert;qo.EQ=function(C,$){return Math.abs(C)>Math.abs($)?Math.abs(C-$)<=Math.abs(C)*1e-6:Math.abs(C-$)<=Math.abs($)*1e-6},qo.NEQ=function(C,$){return!qo.EQ(C,$)};function qo(){var C=this,$=32773,ie=32,Z=null,Re=null,J=null,me=null;this.setModules=function(E,c,d,b){Z=E,Re=c,J=d,me=b};var Fe=null,Oe=0,z=0,ve=0;this.getframebits=function(E){var c=E.internal_flags,d;c.bitrate_index!=0?d=gt.bitrate_table[E.version][c.bitrate_index]:d=E.brate,vt(8<=d&&d<=640);var b=0|(E.version+1)*72e3*d/E.out_samplerate+c.padding;return 8*b};function pe(E){Ln.arraycopy(E.header[E.w_ptr].buf,0,Fe,z,E.sideinfo_len),z+=E.sideinfo_len,Oe+=E.sideinfo_len*8,E.w_ptr=E.w_ptr+1&Dt.MAX_HEADER_BUF-1}function M(E,c,d){for(vt(d<ie-2);d>0;){var b;ve==0&&(ve=8,z++,vt(z<Mt.LAME_MAXMP3BUFFER),vt(E.header[E.w_ptr].write_timing>=Oe),E.header[E.w_ptr].write_timing==Oe&&pe(E),Fe[z]=0),b=Math.min(d,ve),d-=b,ve-=b,vt(d<ie),vt(ve<ie),Fe[z]|=c>>d<<ve,Oe+=b}}function X(E,c,d){for(vt(d<ie-2);d>0;){var b;ve==0&&(ve=8,z++,vt(z<Mt.LAME_MAXMP3BUFFER),Fe[z]=0),b=Math.min(d,ve),d-=b,ve-=b,vt(d<ie),vt(ve<ie),Fe[z]|=c>>d<<ve,Oe+=b}}function o(E,c){var d=E.internal_flags,b;if(vt(c>=0),c>=8&&(M(d,76,8),c-=8),c>=8&&(M(d,65,8),c-=8),c>=8&&(M(d,77,8),c-=8),c>=8&&(M(d,69,8),c-=8),c>=32){var l=J.getLameShortVersion();if(c>=32)for(b=0;b<l.length&&c>=8;++b)c-=8,M(d,l.charAt(b),8)}for(;c>=1;c-=1)M(d,d.ancillary_flag,1),d.ancillary_flag^=E.disable_reservoir?0:1;vt(c==0)}function I(E,c,d){for(var b=E.header[E.h_ptr].ptr;d>0;){var l=Math.min(d,8-(b&7));d-=l,vt(d<ie),E.header[E.h_ptr].buf[b>>3]|=c>>d<<8-(b&7)-l,b+=l}E.header[E.h_ptr].ptr=b}function U(E,c){E<<=8;for(var d=0;d<8;d++)E<<=1,c<<=1,((c^E)&65536)!=0&&(c^=$);return c}this.CRC_writeheader=function(E,c){var d=65535;d=U(c[2]&255,d),d=U(c[3]&255,d);for(var b=6;b<E.sideinfo_len;b++)d=U(c[b]&255,d);c[4]=byte(d>>8),c[5]=byte(d&255)};function F(E,c){var d=E.internal_flags,b,l,v;if(b=d.l3_side,d.header[d.h_ptr].ptr=0,o2.fill(d.header[d.h_ptr].buf,0,d.sideinfo_len,0),E.out_samplerate<16e3?I(d,4094,12):I(d,4095,12),I(d,E.version,1),I(d,4-3,2),I(d,E.error_protection?0:1,1),I(d,d.bitrate_index,4),I(d,d.samplerate_index,2),I(d,d.padding,1),I(d,E.extension,1),I(d,E.mode.ordinal(),2),I(d,d.mode_ext,2),I(d,E.copyright,1),I(d,E.original,1),I(d,E.emphasis,2),E.error_protection&&I(d,0,16),E.version==1){for(vt(b.main_data_begin>=0),I(d,b.main_data_begin,9),d.channels_out==2?I(d,b.private_bits,3):I(d,b.private_bits,5),v=0;v<d.channels_out;v++){var y;for(y=0;y<4;y++)I(d,b.scfsi[v][y],1)}for(l=0;l<2;l++)for(v=0;v<d.channels_out;v++){var T=b.tt[l][v];I(d,T.part2_3_length+T.part2_length,12),I(d,T.big_values/2,9),I(d,T.global_gain,8),I(d,T.scalefac_compress,4),T.block_type!=g.NORM_TYPE?(I(d,1,1),I(d,T.block_type,2),I(d,T.mixed_block_flag,1),T.table_select[0]==14&&(T.table_select[0]=16),I(d,T.table_select[0],5),T.table_select[1]==14&&(T.table_select[1]=16),I(d,T.table_select[1],5),I(d,T.subblock_gain[0],3),I(d,T.subblock_gain[1],3),I(d,T.subblock_gain[2],3)):(I(d,0,1),T.table_select[0]==14&&(T.table_select[0]=16),I(d,T.table_select[0],5),T.table_select[1]==14&&(T.table_select[1]=16),I(d,T.table_select[1],5),T.table_select[2]==14&&(T.table_select[2]=16),I(d,T.table_select[2],5),vt(0<=T.region0_count&&T.region0_count<16),vt(0<=T.region1_count&&T.region1_count<8),I(d,T.region0_count,4),I(d,T.region1_count,3)),I(d,T.preflag,1),I(d,T.scalefac_scale,1),I(d,T.count1table_select,1)}}else for(vt(b.main_data_begin>=0),I(d,b.main_data_begin,8),I(d,b.private_bits,d.channels_out),l=0,v=0;v<d.channels_out;v++){var T=b.tt[l][v];I(d,T.part2_3_length+T.part2_length,12),I(d,T.big_values/2,9),I(d,T.global_gain,8),I(d,T.scalefac_compress,9),T.block_type!=g.NORM_TYPE?(I(d,1,1),I(d,T.block_type,2),I(d,T.mixed_block_flag,1),T.table_select[0]==14&&(T.table_select[0]=16),I(d,T.table_select[0],5),T.table_select[1]==14&&(T.table_select[1]=16),I(d,T.table_select[1],5),I(d,T.subblock_gain[0],3),I(d,T.subblock_gain[1],3),I(d,T.subblock_gain[2],3)):(I(d,0,1),T.table_select[0]==14&&(T.table_select[0]=16),I(d,T.table_select[0],5),T.table_select[1]==14&&(T.table_select[1]=16),I(d,T.table_select[1],5),T.table_select[2]==14&&(T.table_select[2]=16),I(d,T.table_select[2],5),vt(0<=T.region0_count&&T.region0_count<16),vt(0<=T.region1_count&&T.region1_count<8),I(d,T.region0_count,4),I(d,T.region1_count,3)),I(d,T.scalefac_scale,1),I(d,T.count1table_select,1)}E.error_protection&&CRC_writeheader(d,d.header[d.h_ptr].buf);{var G=d.h_ptr;vt(d.header[G].ptr==d.sideinfo_len*8),d.h_ptr=G+1&Dt.MAX_HEADER_BUF-1,d.header[d.h_ptr].write_timing=d.header[G].write_timing+c,d.h_ptr==d.w_ptr&&Ln.err.println(`Error: MAX_HEADER_BUF too small in bitstream.c
3
+ `)}}function x(E,c){var d=gt.ht[c.count1table_select+32],b,l=0,v=c.big_values,y=c.big_values;for(vt(c.count1table_select<2),b=(c.count1-c.big_values)/4;b>0;--b){var T=0,G=0,H;H=c.l3_enc[v+0],H!=0&&(G+=8,c.xr[y+0]<0&&T++,vt(H<=1)),H=c.l3_enc[v+1],H!=0&&(G+=4,T*=2,c.xr[y+1]<0&&T++,vt(H<=1)),H=c.l3_enc[v+2],H!=0&&(G+=2,T*=2,c.xr[y+2]<0&&T++,vt(H<=1)),H=c.l3_enc[v+3],H!=0&&(G++,T*=2,c.xr[y+3]<0&&T++,vt(H<=1)),v+=4,y+=4,M(E,T+d.table[G],d.hlen[G]),l+=d.hlen[G]}return l}function p(E,c,d,b,l){var v=gt.ht[c],y=0;if(vt(c<32),c==0)return y;for(var T=d;T<b;T+=2){var G=0,H=0,j=v.xlen,be=v.xlen,f=0,S=l.l3_enc[T],ce=l.l3_enc[T+1];if(S!=0&&(l.xr[T]<0&&f++,G--),c>15){if(S>14){var xe=S-15;vt(xe<=v.linmax),f|=xe<<1,H=j,S=15}if(ce>14){var ke=ce-15;vt(ke<=v.linmax),f<<=j,f|=ke,H+=j,ce=15}be=16}ce!=0&&(f<<=1,l.xr[T+1]<0&&f++,G--),vt((S|ce)<16),S=S*be+ce,H-=G,G+=v.hlen[S],vt(G<=ie),vt(H<=ie),M(E,v.table[S],G),M(E,f,H),y+=G+H}return y}function N(E,c){var d=3*E.scalefac_band.s[3];d>c.big_values&&(d=c.big_values);var b=p(E,c.table_select[0],0,d,c);return b+=p(E,c.table_select[1],d,c.big_values,c),b}function q(E,c){var d,b,l,v;d=c.big_values,vt(0<=d&&d<=576);var y=c.region0_count+1;return vt(0<=y),vt(y<E.scalefac_band.l.length),l=E.scalefac_band.l[y],y+=c.region1_count+1,vt(0<=y),vt(y<E.scalefac_band.l.length),v=E.scalefac_band.l[y],l>d&&(l=d),v>d&&(v=d),b=p(E,c.table_select[0],0,l,c),b+=p(E,c.table_select[1],l,v,c),b+=p(E,c.table_select[2],v,d,c),b}function w(E){var c,d,b,l,v=0,y=E.internal_flags,T=y.l3_side;if(E.version==1)for(c=0;c<2;c++)for(d=0;d<y.channels_out;d++){var G=T.tt[c][d],H=$0.slen1_tab[G.scalefac_compress],j=$0.slen2_tab[G.scalefac_compress];for(l=0,b=0;b<G.sfbdivide;b++)G.scalefac[b]!=-1&&(M(y,G.scalefac[b],H),l+=H);for(;b<G.sfbmax;b++)G.scalefac[b]!=-1&&(M(y,G.scalefac[b],j),l+=j);vt(l==G.part2_length),G.block_type==g.SHORT_TYPE?l+=N(y,G):l+=q(y,G),l+=x(y,G),vt(l==G.part2_3_length+G.part2_length),v+=l}else for(c=0,d=0;d<y.channels_out;d++){var G=T.tt[c][d],be,f,S=0;if(vt(G.sfb_partition_table!=null),l=0,b=0,f=0,G.block_type==g.SHORT_TYPE){for(;f<4;f++){var ce=G.sfb_partition_table[f]/3,xe=G.slen[f];for(be=0;be<ce;be++,b++)M(y,Math.max(G.scalefac[b*3+0],0),xe),M(y,Math.max(G.scalefac[b*3+1],0),xe),M(y,Math.max(G.scalefac[b*3+2],0),xe),S+=3*xe}l+=N(y,G)}else{for(;f<4;f++){var ce=G.sfb_partition_table[f],xe=G.slen[f];for(be=0;be<ce;be++,b++)M(y,Math.max(G.scalefac[b],0),xe),S+=xe}l+=q(y,G)}l+=x(y,G),vt(l==G.part2_3_length),vt(S==G.part2_length),v+=S+l}return v}function u(){this.total=0}function L(E,c){var d=E.internal_flags,b,l,v,y,T;return T=d.w_ptr,y=d.h_ptr-1,y==-1&&(y=Dt.MAX_HEADER_BUF-1),b=d.header[y].write_timing-Oe,c.total=b,b>=0&&(l=1+y-T,y<T&&(l=1+y-T+Dt.MAX_HEADER_BUF),b-=l*8*d.sideinfo_len),v=C.getframebits(E),b+=v,c.total+=v,c.total%8!=0?c.total=1+c.total/8:c.total=c.total/8,c.total+=z+1,b<0&&Ln.err.println(`strange error flushing buffer ...
4
+ `),b}this.flush_bitstream=function(E){var c=E.internal_flags,d,b,l=c.h_ptr-1;if(l==-1&&(l=Dt.MAX_HEADER_BUF-1),d=c.l3_side,!((b=L(E,new u))<0)){if(o(E,b),vt(c.header[l].write_timing+this.getframebits(E)==Oe),c.ResvSize=0,d.main_data_begin=0,c.findReplayGain){var v=Z.GetTitleGain(c.rgdata);vt(NEQ(v,qi.GAIN_NOT_ENOUGH_SAMPLES)),c.RadioGain=Math.floor(v*10+.5)|0}c.findPeakSample&&(c.noclipGainChange=Math.ceil(Math.log10(c.PeakSample/32767)*20*10)|0,c.noclipGainChange>0&&(EQ(E.scale,1)||EQ(E.scale,0))?c.noclipScale=Math.floor(32767/c.PeakSample*100)/100:c.noclipScale=-1)}},this.add_dummy_byte=function(E,c,d){for(var b=E.internal_flags,l;d-- >0;)for(X(b,c,8),l=0;l<Dt.MAX_HEADER_BUF;++l)b.header[l].write_timing+=8},this.format_bitstream=function(E){var c=E.internal_flags,d;d=c.l3_side;var b=this.getframebits(E);o(E,d.resvDrain_pre),F(E,b);var l=8*c.sideinfo_len;if(l+=w(E),o(E,d.resvDrain_post),l+=d.resvDrain_post,d.main_data_begin+=(b-l)/8,L(E,new u)!=c.ResvSize&&Ln.err.println("Internal buffer inconsistency. flushbits <> ResvSize"),d.main_data_begin*8!=c.ResvSize&&(Ln.err.printf(`bit reservoir error:
5
5
  l3_side.main_data_begin: %d
6
6
  Resvoir size: %d
7
7
  resv drain (post) %d
@@ -10,50 +10,29 @@ header and sideinfo: %d
10
10
  data bits: %d
11
11
  total bits: %d (remainder: %d)
12
12
  bitsperframe: %d
13
- `,8*y.main_data_begin,f.ResvSize,y.resvDrain_post,y.resvDrain_pre,8*f.sideinfo_len,d-y.resvDrain_post-8*f.sideinfo_len,d,d%8,b),Jn.err.println("This is a fatal error. It has several possible causes:"),Jn.err.println("90%% LAME compiled with buggy version of gcc using advanced optimizations"),Jn.err.println(" 9%% Your system is overclocked"),Jn.err.println(" 1%% bug in LAME encoding library"),f.ResvSize=y.main_data_begin*8),Pt(He%8==0),He>1e9){var x;for(x=0;x<rr.MAX_HEADER_BUF;++x)f.header[x].write_timing-=He;He=0}return 0},this.copy_buffer=function(R,f,y,b,d){var x=$+1;if(x<=0)return 0;if(b!=0&&x>b)return-1;if(Jn.arraycopy(ze,0,f,y,x),$=-1,fe=0,d!=0){var N=F3(1);if(N[0]=R.nMusicCRC,ye.updateMusicCRC(N,f,y,x),R.nMusicCRC=N[0],x>0&&(R.VBR_seek_table.nBytesWritten+=x),R.decode_on_the_fly){for(var T=k3([2,1152]),Y=x,j=-1,X;j!=0;)if(j=Ee.hip_decode1_unclipped(R.hip,f,y,Y,T[0],T[1]),Y=0,j==-1&&(j=0),j>0){if(Pt(j<=1152),R.findPeakSample){for(X=0;X<j;X++)T[0][X]>R.PeakSample?R.PeakSample=T[0][X]:-T[0][X]>R.PeakSample&&(R.PeakSample=-T[0][X]);if(R.channels_out>1)for(X=0;X<j;X++)T[1][X]>R.PeakSample?R.PeakSample=T[1][X]:-T[1][X]>R.PeakSample&&(R.PeakSample=-T[1][X])}if(R.findReplayGain&&re.AnalyzeSamples(R.rgdata,T[0],0,T[1],0,j,R.channels_out)==Xl.GAIN_ANALYSIS_ERROR)return-6}}}return x},this.init_bit_stream_w=function(R){ze=D3(Wt.LAME_MAXMP3BUFFER),R.h_ptr=R.w_ptr=0,R.header[R.h_ptr].write_timing=0,$=-1,fe=0,He=0}}var Ji=vm,U3=C.System,ir=C.VbrMode,yp=C.ShortBlock,Hs=C.new_float,yg=C.new_int_n,j3=C.new_short_n,Ua=C.assert;function Hr(){var z=this,te=128*1024;Hr.V9=410,Hr.V8=420,Hr.V7=430,Hr.V6=440,Hr.V5=450,Hr.V4=460,Hr.V3=470,Hr.V2=480,Hr.V1=490,Hr.V0=500,Hr.R3MIX=1e3,Hr.STANDARD=1001,Hr.EXTREME=1002,Hr.INSANE=1003,Hr.STANDARD_FAST=1004,Hr.EXTREME_FAST=1005,Hr.MEDIUM=1006,Hr.MEDIUM_FAST=1007;var ce=16384+te;Hr.LAME_MAXMP3BUFFER=ce;var re,Ee,ie,ye,ze,He=new ra,$,fe,ge,L;this.enc=new P,this.setModules=function(h,v,de,ve,De,Ue,$e,Xe,yt){re=h,Ee=v,ie=de,ye=ve,ze=De,$=Ue,fe=$e,ge=Xe,L=yt,this.enc.setModules(Ee,He,ye,$)};function Q(){this.mask_adjust=0,this.mask_adjust_short=0,this.bo_l_weight=Hs(P.SBMAX_l),this.bo_s_weight=Hs(P.SBMAX_s)}function m(){this.lowerlimit=0}function B(h,v){this.lowpass=v}var V=4294479419;function k(h){var v;return h.class_id=V,v=h.internal_flags=new rr,h.mode=Dr.NOT_SET,h.original=1,h.in_samplerate=44100,h.num_channels=2,h.num_samples=-1,h.bWriteVbrTag=!0,h.quality=-1,h.short_blocks=null,v.subblock_gain=-1,h.lowpassfreq=0,h.highpassfreq=0,h.lowpasswidth=-1,h.highpasswidth=-1,h.VBR=ir.vbr_off,h.VBR_q=4,h.ATHcurve=-1,h.VBR_mean_bitrate_kbps=128,h.VBR_min_bitrate_kbps=0,h.VBR_max_bitrate_kbps=0,h.VBR_hard_min=0,v.VBR_min_bitrate=1,v.VBR_max_bitrate=13,h.quant_comp=-1,h.quant_comp_short=-1,h.msfix=-1,v.resample_ratio=1,v.OldValue[0]=180,v.OldValue[1]=180,v.CurrentStep[0]=4,v.CurrentStep[1]=4,v.masking_lower=1,v.nsPsy.attackthre=-1,v.nsPsy.attackthre_s=-1,h.scale=-1,h.athaa_type=-1,h.ATHtype=-1,h.athaa_loudapprox=-1,h.athaa_sensitivity=0,h.useTemporal=null,h.interChRatio=-1,v.mf_samples_to_encode=P.ENCDELAY+P.POSTDELAY,h.encoder_padding=0,v.mf_size=P.ENCDELAY-P.MDCTDELAY,h.findReplayGain=!1,h.decode_on_the_fly=!1,v.decode_on_the_fly=!1,v.findReplayGain=!1,v.findPeakSample=!1,v.RadioGain=0,v.AudiophileGain=0,v.noclipGainChange=0,v.noclipScale=-1,h.preset=0,h.write_id3tag_automatic=!0,0}this.lame_init=function(){var h=new Bs,v=k(h);return v!=0?null:(h.lame_allocated_gfp=1,h)};function _(h){return h>1?0:h<=0?1:Math.cos(Math.PI/2*h)}this.nearestBitrateFullIndex=function(h){var v=[8,16,24,32,40,48,56,64,80,96,112,128,160,192,224,256,320],de=0,ve=0,De=0,Ue=0;Ue=v[16],De=16,ve=v[16],de=16;for(var $e=0;$e<16;$e++)if(Math.max(h,v[$e+1])!=h){Ue=v[$e+1],De=$e+1,ve=v[$e],de=$e;break}return Ue-h>h-ve?de:De};function g(h,v){var de=44100;return v>=48e3?de=48e3:v>=44100?de=44100:v>=32e3?de=32e3:v>=24e3?de=24e3:v>=22050?de=22050:v>=16e3?de=16e3:v>=12e3?de=12e3:v>=11025?de=11025:v>=8e3&&(de=8e3),h==-1?de:(h<=15960&&(de=44100),h<=15250&&(de=32e3),h<=11220&&(de=24e3),h<=9970&&(de=22050),h<=7230&&(de=16e3),h<=5420&&(de=12e3),h<=4510&&(de=11025),h<=3970&&(de=8e3),v<de?v>44100?48e3:v>32e3?44100:v>24e3?32e3:v>22050?24e3:v>16e3?22050:v>12e3?16e3:v>11025?12e3:v>8e3?11025:8e3:de)}function D(h,v){switch(h){case 44100:return v.version=1,0;case 48e3:return v.version=1,1;case 32e3:return v.version=1,2;case 22050:return v.version=0,0;case 24e3:return v.version=0,1;case 16e3:return v.version=0,2;case 11025:return v.version=0,0;case 12e3:return v.version=0,1;case 8e3:return v.version=0,2;default:return v.version=0,-1}}function K(h,v,de){de<16e3&&(v=2);for(var ve=Ht.bitrate_table[v][1],De=2;De<=14;De++)Ht.bitrate_table[v][De]>0&&Math.abs(Ht.bitrate_table[v][De]-h)<Math.abs(ve-h)&&(ve=Ht.bitrate_table[v][De]);return ve}function w(h,v,de){de<16e3&&(v=2);for(var ve=0;ve<=14;ve++)if(Ht.bitrate_table[v][ve]>0&&Ht.bitrate_table[v][ve]==h)return ve;return-1}function u(h,v){var de=[new B(8,2e3),new B(16,3700),new B(24,3900),new B(32,5500),new B(40,7e3),new B(48,7500),new B(56,1e4),new B(64,11e3),new B(80,13500),new B(96,15100),new B(112,15600),new B(128,17e3),new B(160,17500),new B(192,18600),new B(224,19400),new B(256,19700),new B(320,20500)],ve=z.nearestBitrateFullIndex(v);h.lowerlimit=de[ve].lowpass}function F(h){var v=h.internal_flags,de=32,ve=-1;if(v.lowpass1>0){for(var De=999,Ue=0;Ue<=31;Ue++){var $e=Ue/31;$e>=v.lowpass2&&(de=Math.min(de,Ue)),v.lowpass1<$e&&$e<v.lowpass2&&(De=Math.min(De,Ue))}De==999?v.lowpass1=(de-.75)/31:v.lowpass1=(De-.75)/31,v.lowpass2=de/31}if(v.highpass2>0&&v.highpass2<.9*(.75/31)&&(v.highpass1=0,v.highpass2=0,U3.err.println(`Warning: highpass filter disabled. highpass frequency too small
14
- `)),v.highpass2>0){for(var Xe=-1,Ue=0;Ue<=31;Ue++){var $e=Ue/31;$e<=v.highpass1&&(ve=Math.max(ve,Ue)),v.highpass1<$e&&$e<v.highpass2&&(Xe=Math.max(Xe,Ue))}v.highpass1=ve/31,Xe==-1?v.highpass2=(ve+.75)/31:v.highpass2=(Xe+.75)/31}for(var Ue=0;Ue<32;Ue++){var yt,tt,$e=Ue/31;v.highpass2>v.highpass1?yt=_((v.highpass2-$e)/(v.highpass2-v.highpass1+1e-20)):yt=1,v.lowpass2>v.lowpass1?tt=_(($e-v.lowpass1)/(v.lowpass2-v.lowpass1+1e-20)):tt=1,v.amp_filter[Ue]=yt*tt}}function R(h){var v=h.internal_flags;switch(h.quality){default:case 9:v.psymodel=0,v.noise_shaping=0,v.noise_shaping_amp=0,v.noise_shaping_stop=0,v.use_best_huffman=0,v.full_outer_loop=0;break;case 8:h.quality=7;case 7:v.psymodel=1,v.noise_shaping=0,v.noise_shaping_amp=0,v.noise_shaping_stop=0,v.use_best_huffman=0,v.full_outer_loop=0;break;case 6:v.psymodel=1,v.noise_shaping==0&&(v.noise_shaping=1),v.noise_shaping_amp=0,v.noise_shaping_stop=0,v.subblock_gain==-1&&(v.subblock_gain=1),v.use_best_huffman=0,v.full_outer_loop=0;break;case 5:v.psymodel=1,v.noise_shaping==0&&(v.noise_shaping=1),v.noise_shaping_amp=0,v.noise_shaping_stop=0,v.subblock_gain==-1&&(v.subblock_gain=1),v.use_best_huffman=0,v.full_outer_loop=0;break;case 4:v.psymodel=1,v.noise_shaping==0&&(v.noise_shaping=1),v.noise_shaping_amp=0,v.noise_shaping_stop=0,v.subblock_gain==-1&&(v.subblock_gain=1),v.use_best_huffman=1,v.full_outer_loop=0;break;case 3:v.psymodel=1,v.noise_shaping==0&&(v.noise_shaping=1),v.noise_shaping_amp=1,v.noise_shaping_stop=1,v.subblock_gain==-1&&(v.subblock_gain=1),v.use_best_huffman=1,v.full_outer_loop=0;break;case 2:v.psymodel=1,v.noise_shaping==0&&(v.noise_shaping=1),v.substep_shaping==0&&(v.substep_shaping=2),v.noise_shaping_amp=1,v.noise_shaping_stop=1,v.subblock_gain==-1&&(v.subblock_gain=1),v.use_best_huffman=1,v.full_outer_loop=0;break;case 1:v.psymodel=1,v.noise_shaping==0&&(v.noise_shaping=1),v.substep_shaping==0&&(v.substep_shaping=2),v.noise_shaping_amp=2,v.noise_shaping_stop=1,v.subblock_gain==-1&&(v.subblock_gain=1),v.use_best_huffman=1,v.full_outer_loop=0;break;case 0:v.psymodel=1,v.noise_shaping==0&&(v.noise_shaping=1),v.substep_shaping==0&&(v.substep_shaping=2),v.noise_shaping_amp=2,v.noise_shaping_stop=1,v.subblock_gain==-1&&(v.subblock_gain=1),v.use_best_huffman=1,v.full_outer_loop=0;break}}function f(h){var v=h.internal_flags;h.frameNum=0,h.write_id3tag_automatic&&ge.id3tag_write_v2(h),v.bitrate_stereoMode_Hist=yg([16,4+1]),v.bitrate_blockType_Hist=yg([16,4+1+1]),v.PeakSample=0,h.bWriteVbrTag&&$.InitVbrTag(h)}this.lame_init_params=function(h){var v=h.internal_flags;if(v.Class_ID=0,v.ATH==null&&(v.ATH=new T3),v.PSY==null&&(v.PSY=new Q),v.rgdata==null&&(v.rgdata=new I3),v.channels_in=h.num_channels,v.channels_in==1&&(h.mode=Dr.MONO),v.channels_out=h.mode==Dr.MONO?1:2,v.mode_ext=P.MPG_MD_MS_LR,h.mode==Dr.MONO&&(h.force_ms=!1),h.VBR==ir.vbr_off&&h.VBR_mean_bitrate_kbps!=128&&h.brate==0&&(h.brate=h.VBR_mean_bitrate_kbps),h.VBR==ir.vbr_off||h.VBR==ir.vbr_mtrh||h.VBR==ir.vbr_mt||(h.free_format=!1),h.VBR==ir.vbr_off&&h.brate==0&&Ji.EQ(h.compression_ratio,0)&&(h.compression_ratio=11.025),h.VBR==ir.vbr_off&&h.compression_ratio>0&&(h.out_samplerate==0&&(h.out_samplerate=map2MP3Frequency(int(.97*h.in_samplerate))),h.brate=0|h.out_samplerate*16*v.channels_out/(1e3*h.compression_ratio),v.samplerate_index=D(h.out_samplerate,h),h.free_format||(h.brate=K(h.brate,h.version,h.out_samplerate))),h.out_samplerate!=0&&(h.out_samplerate<16e3?(h.VBR_mean_bitrate_kbps=Math.max(h.VBR_mean_bitrate_kbps,8),h.VBR_mean_bitrate_kbps=Math.min(h.VBR_mean_bitrate_kbps,64)):h.out_samplerate<32e3?(h.VBR_mean_bitrate_kbps=Math.max(h.VBR_mean_bitrate_kbps,8),h.VBR_mean_bitrate_kbps=Math.min(h.VBR_mean_bitrate_kbps,160)):(h.VBR_mean_bitrate_kbps=Math.max(h.VBR_mean_bitrate_kbps,32),h.VBR_mean_bitrate_kbps=Math.min(h.VBR_mean_bitrate_kbps,320))),h.lowpassfreq==0){var de=16e3;switch(h.VBR){case ir.vbr_off:{var ve=new m;u(ve,h.brate),de=ve.lowerlimit;break}case ir.vbr_abr:{var ve=new m;u(ve,h.VBR_mean_bitrate_kbps),de=ve.lowerlimit;break}case ir.vbr_rh:{var De=[19500,19e3,18600,18e3,17500,16e3,15600,14900,12500,1e4,3950];if(0<=h.VBR_q&&h.VBR_q<=9){var Ue=De[h.VBR_q],$e=De[h.VBR_q+1],Xe=h.VBR_q_frac;de=linear_int(Ue,$e,Xe)}else de=19500;break}default:{var De=[19500,19e3,18500,18e3,17500,16500,15500,14500,12500,9500,3950];if(0<=h.VBR_q&&h.VBR_q<=9){var Ue=De[h.VBR_q],$e=De[h.VBR_q+1],Xe=h.VBR_q_frac;de=linear_int(Ue,$e,Xe)}else de=19500}}h.mode==Dr.MONO&&(h.VBR==ir.vbr_off||h.VBR==ir.vbr_abr)&&(de*=1.5),h.lowpassfreq=de|0}if(h.out_samplerate==0&&(2*h.lowpassfreq>h.in_samplerate&&(h.lowpassfreq=h.in_samplerate/2),h.out_samplerate=g(h.lowpassfreq|0,h.in_samplerate)),h.lowpassfreq=Math.min(20500,h.lowpassfreq),h.lowpassfreq=Math.min(h.out_samplerate/2,h.lowpassfreq),h.VBR==ir.vbr_off&&(h.compression_ratio=h.out_samplerate*16*v.channels_out/(1e3*h.brate)),h.VBR==ir.vbr_abr&&(h.compression_ratio=h.out_samplerate*16*v.channels_out/(1e3*h.VBR_mean_bitrate_kbps)),h.bWriteVbrTag||(h.findReplayGain=!1,h.decode_on_the_fly=!1,v.findPeakSample=!1),v.findReplayGain=h.findReplayGain,v.decode_on_the_fly=h.decode_on_the_fly,v.decode_on_the_fly&&(v.findPeakSample=!0),v.findReplayGain&&re.InitGainAnalysis(v.rgdata,h.out_samplerate)==Xl.INIT_GAIN_ANALYSIS_ERROR)return h.internal_flags=null,-6;switch(v.decode_on_the_fly&&!h.decode_only&&(v.hip!=null&&L.hip_decode_exit(v.hip),v.hip=L.hip_decode_init()),v.mode_gr=h.out_samplerate<=24e3?1:2,h.framesize=576*v.mode_gr,h.encoder_delay=P.ENCDELAY,v.resample_ratio=h.in_samplerate/h.out_samplerate,h.VBR){case ir.vbr_mt:case ir.vbr_rh:case ir.vbr_mtrh:{var yt=[5.7,6.5,7.3,8.2,10,11.9,13,14,15,16.5];h.compression_ratio=yt[h.VBR_q]}break;case ir.vbr_abr:h.compression_ratio=h.out_samplerate*16*v.channels_out/(1e3*h.VBR_mean_bitrate_kbps);break;default:h.compression_ratio=h.out_samplerate*16*v.channels_out/(1e3*h.brate);break}if(h.mode==Dr.NOT_SET&&(h.mode=Dr.JOINT_STEREO),h.highpassfreq>0?(v.highpass1=2*h.highpassfreq,h.highpasswidth>=0?v.highpass2=2*(h.highpassfreq+h.highpasswidth):v.highpass2=(1+0)*2*h.highpassfreq,v.highpass1/=h.out_samplerate,v.highpass2/=h.out_samplerate):(v.highpass1=0,v.highpass2=0),h.lowpassfreq>0?(v.lowpass2=2*h.lowpassfreq,h.lowpasswidth>=0?(v.lowpass1=2*(h.lowpassfreq-h.lowpasswidth),v.lowpass1<0&&(v.lowpass1=0)):v.lowpass1=(1-0)*2*h.lowpassfreq,v.lowpass1/=h.out_samplerate,v.lowpass2/=h.out_samplerate):(v.lowpass1=0,v.lowpass2=0),F(h),v.samplerate_index=D(h.out_samplerate,h),v.samplerate_index<0)return h.internal_flags=null,-1;if(h.VBR==ir.vbr_off){if(h.free_format)v.bitrate_index=0;else if(h.brate=K(h.brate,h.version,h.out_samplerate),v.bitrate_index=w(h.brate,h.version,h.out_samplerate),v.bitrate_index<=0)return h.internal_flags=null,-1}else v.bitrate_index=1;h.analysis&&(h.bWriteVbrTag=!1),v.pinfo!=null&&(h.bWriteVbrTag=!1),Ee.init_bit_stream_w(v);for(var tt=v.samplerate_index+3*h.version+6*(h.out_samplerate<16e3?1:0),Ve=0;Ve<P.SBMAX_l+1;Ve++)v.scalefac_band.l[Ve]=ye.sfBandIndex[tt].l[Ve];for(var Ve=0;Ve<P.PSFB21+1;Ve++){var kt=(v.scalefac_band.l[22]-v.scalefac_band.l[21])/P.PSFB21,lr=v.scalefac_band.l[21]+Ve*kt;v.scalefac_band.psfb21[Ve]=lr}v.scalefac_band.psfb21[P.PSFB21]=576;for(var Ve=0;Ve<P.SBMAX_s+1;Ve++)v.scalefac_band.s[Ve]=ye.sfBandIndex[tt].s[Ve];for(var Ve=0;Ve<P.PSFB12+1;Ve++){var kt=(v.scalefac_band.s[13]-v.scalefac_band.s[12])/P.PSFB12,lr=v.scalefac_band.s[12]+Ve*kt;v.scalefac_band.psfb12[Ve]=lr}v.scalefac_band.psfb12[P.PSFB12]=192,h.version==1?v.sideinfo_len=v.channels_out==1?4+17:4+32:v.sideinfo_len=v.channels_out==1?4+9:4+17,h.error_protection&&(v.sideinfo_len+=2),f(h),v.Class_ID=V;{var Kt;for(Kt=0;Kt<19;Kt++)v.nsPsy.pefirbuf[Kt]=700*v.mode_gr*v.channels_out;h.ATHtype==-1&&(h.ATHtype=4)}switch(Ua(h.VBR_q<=9),Ua(h.VBR_q>=0),h.VBR){case ir.vbr_mt:h.VBR=ir.vbr_mtrh;case ir.vbr_mtrh:{h.useTemporal==null&&(h.useTemporal=!1),ie.apply_preset(h,500-h.VBR_q*10,0),h.quality<0&&(h.quality=LAME_DEFAULT_QUALITY),h.quality<5&&(h.quality=0),h.quality>5&&(h.quality=5),v.PSY.mask_adjust=h.maskingadjust,v.PSY.mask_adjust_short=h.maskingadjust_short,h.experimentalY?v.sfb21_extra=!1:v.sfb21_extra=h.out_samplerate>44e3,v.iteration_loop=new VBRNewIterationLoop(ze);break}case ir.vbr_rh:{ie.apply_preset(h,500-h.VBR_q*10,0),v.PSY.mask_adjust=h.maskingadjust,v.PSY.mask_adjust_short=h.maskingadjust_short,h.experimentalY?v.sfb21_extra=!1:v.sfb21_extra=h.out_samplerate>44e3,h.quality>6&&(h.quality=6),h.quality<0&&(h.quality=LAME_DEFAULT_QUALITY),v.iteration_loop=new VBROldIterationLoop(ze);break}default:{var cr;v.sfb21_extra=!1,h.quality<0&&(h.quality=LAME_DEFAULT_QUALITY),cr=h.VBR,cr==ir.vbr_off&&(h.VBR_mean_bitrate_kbps=h.brate),ie.apply_preset(h,h.VBR_mean_bitrate_kbps,0),h.VBR=cr,v.PSY.mask_adjust=h.maskingadjust,v.PSY.mask_adjust_short=h.maskingadjust_short,cr==ir.vbr_off?v.iteration_loop=new O3(ze):v.iteration_loop=new ABRIterationLoop(ze);break}}if(Ua(h.scale>=0),h.VBR!=ir.vbr_off){if(v.VBR_min_bitrate=1,v.VBR_max_bitrate=14,h.out_samplerate<16e3&&(v.VBR_max_bitrate=8),h.VBR_min_bitrate_kbps!=0&&(h.VBR_min_bitrate_kbps=K(h.VBR_min_bitrate_kbps,h.version,h.out_samplerate),v.VBR_min_bitrate=w(h.VBR_min_bitrate_kbps,h.version,h.out_samplerate),v.VBR_min_bitrate<0)||h.VBR_max_bitrate_kbps!=0&&(h.VBR_max_bitrate_kbps=K(h.VBR_max_bitrate_kbps,h.version,h.out_samplerate),v.VBR_max_bitrate=w(h.VBR_max_bitrate_kbps,h.version,h.out_samplerate),v.VBR_max_bitrate<0))return-1;h.VBR_min_bitrate_kbps=Ht.bitrate_table[h.version][v.VBR_min_bitrate],h.VBR_max_bitrate_kbps=Ht.bitrate_table[h.version][v.VBR_max_bitrate],h.VBR_mean_bitrate_kbps=Math.min(Ht.bitrate_table[h.version][v.VBR_max_bitrate],h.VBR_mean_bitrate_kbps),h.VBR_mean_bitrate_kbps=Math.max(Ht.bitrate_table[h.version][v.VBR_min_bitrate],h.VBR_mean_bitrate_kbps)}return h.tune&&(v.PSY.mask_adjust+=h.tune_value_a,v.PSY.mask_adjust_short+=h.tune_value_a),R(h),Ua(h.scale>=0),h.athaa_type<0?v.ATH.useAdjust=3:v.ATH.useAdjust=h.athaa_type,v.ATH.aaSensitivityP=Math.pow(10,h.athaa_sensitivity/-10),h.short_blocks==null&&(h.short_blocks=yp.short_block_allowed),h.short_blocks==yp.short_block_allowed&&(h.mode==Dr.JOINT_STEREO||h.mode==Dr.STEREO)&&(h.short_blocks=yp.short_block_coupled),h.quant_comp<0&&(h.quant_comp=1),h.quant_comp_short<0&&(h.quant_comp_short=0),h.msfix<0&&(h.msfix=0),h.exp_nspsytune=h.exp_nspsytune|1,h.internal_flags.nsPsy.attackthre<0&&(h.internal_flags.nsPsy.attackthre=ra.NSATTACKTHRE),h.internal_flags.nsPsy.attackthre_s<0&&(h.internal_flags.nsPsy.attackthre_s=ra.NSATTACKTHRE_S),Ua(h.scale>=0),h.scale<0&&(h.scale=1),h.ATHtype<0&&(h.ATHtype=4),h.ATHcurve<0&&(h.ATHcurve=4),h.athaa_loudapprox<0&&(h.athaa_loudapprox=2),h.interChRatio<0&&(h.interChRatio=0),h.useTemporal==null&&(h.useTemporal=!0),v.slot_lag=v.frac_SpF=0,h.VBR==ir.vbr_off&&(v.slot_lag=v.frac_SpF=(h.version+1)*72e3*h.brate%h.out_samplerate|0),ye.iteration_init(h),He.psymodel_init(h),Ua(h.scale>=0),0};function y(h,v){(h.in_buffer_0==null||h.in_buffer_nsamples<v)&&(h.in_buffer_0=Hs(v),h.in_buffer_1=Hs(v),h.in_buffer_nsamples=v)}this.lame_encode_flush=function(h,v,de,ve){var De=h.internal_flags,Ue=j3([2,1152]),$e=0,Xe,yt,tt,Ve,kt=De.mf_samples_to_encode-P.POSTDELAY,lr=b(h);if(De.mf_samples_to_encode<1)return 0;for(Xe=0,h.in_samplerate!=h.out_samplerate&&(kt+=16*h.out_samplerate/h.in_samplerate),tt=h.framesize-kt%h.framesize,tt<576&&(tt+=h.framesize),h.encoder_padding=tt,Ve=(kt+tt)/h.framesize;Ve>0&&$e>=0;){var Kt=lr-De.mf_size,cr=h.frameNum;Kt*=h.in_samplerate,Kt/=h.out_samplerate,Kt>1152&&(Kt=1152),Kt<1&&(Kt=1),yt=ve-Xe,ve==0&&(yt=0),$e=this.lame_encode_buffer(h,Ue[0],Ue[1],Kt,v,de,yt),de+=$e,Xe+=$e,Ve-=cr!=h.frameNum?1:0}if(De.mf_samples_to_encode=0,$e<0||(yt=ve-Xe,ve==0&&(yt=0),Ee.flush_bitstream(h),$e=Ee.copy_buffer(De,v,de,yt,1),$e<0))return $e;if(de+=$e,Xe+=$e,yt=ve-Xe,ve==0&&(yt=0),h.write_id3tag_automatic){if(ge.id3tag_write_v1(h),$e=Ee.copy_buffer(De,v,de,yt,0),$e<0)return $e;Xe+=$e}return Xe},this.lame_encode_buffer=function(h,v,de,ve,De,Ue,$e){var Xe=h.internal_flags,yt=[null,null];if(Xe.Class_ID!=V)return-3;if(ve==0)return 0;y(Xe,ve),yt[0]=Xe.in_buffer_0,yt[1]=Xe.in_buffer_1;for(var tt=0;tt<ve;tt++)yt[0][tt]=v[tt],Xe.channels_in>1&&(yt[1][tt]=de[tt]);return d(h,yt[0],yt[1],ve,De,Ue,$e)};function b(h){var v=P.BLKSIZE+h.framesize-P.FFTOFFSET;return v=Math.max(v,512+h.framesize-32),Ua(rr.MFSIZE>=v),v}function d(h,v,de,ve,De,Ue,$e){var Xe=h.internal_flags,yt=0,tt,Ve,kt,lr,Kt,cr=[null,null],Nr=[null,null];if(Xe.Class_ID!=V)return-3;if(ve==0)return 0;if(Kt=Ee.copy_buffer(Xe,De,Ue,$e,0),Kt<0)return Kt;if(Ue+=Kt,yt+=Kt,Nr[0]=v,Nr[1]=de,Ji.NEQ(h.scale,0)&&Ji.NEQ(h.scale,1))for(Ve=0;Ve<ve;++Ve)Nr[0][Ve]*=h.scale,Xe.channels_out==2&&(Nr[1][Ve]*=h.scale);if(Ji.NEQ(h.scale_left,0)&&Ji.NEQ(h.scale_left,1))for(Ve=0;Ve<ve;++Ve)Nr[0][Ve]*=h.scale_left;if(Ji.NEQ(h.scale_right,0)&&Ji.NEQ(h.scale_right,1))for(Ve=0;Ve<ve;++Ve)Nr[1][Ve]*=h.scale_right;if(h.num_channels==2&&Xe.channels_out==1)for(Ve=0;Ve<ve;++Ve)Nr[0][Ve]=.5*(Nr[0][Ve]+Nr[1][Ve]),Nr[1][Ve]=0;lr=b(h),cr[0]=Xe.mfbuf[0],cr[1]=Xe.mfbuf[1];for(var Rr=0;ve>0;){var na=[null,null],ri=0,Aa=0;na[0]=Nr[0],na[1]=Nr[1];var Ba=new N;if(_e(h,cr,na,Rr,ve,Ba),ri=Ba.n_in,Aa=Ba.n_out,Xe.findReplayGain&&!Xe.decode_on_the_fly&&re.AnalyzeSamples(Xe.rgdata,cr[0],Xe.mf_size,cr[1],Xe.mf_size,Aa,Xe.channels_out)==Xl.GAIN_ANALYSIS_ERROR)return-6;if(ve-=ri,Rr+=ri,Xe.channels_out==2,Xe.mf_size+=Aa,Ua(Xe.mf_size<=rr.MFSIZE),Xe.mf_samples_to_encode<1&&(Xe.mf_samples_to_encode=P.ENCDELAY+P.POSTDELAY),Xe.mf_samples_to_encode+=Aa,Xe.mf_size>=lr){var En=$e-yt;if($e==0&&(En=0),tt=x(h,cr[0],cr[1],De,Ue,En),tt<0)return tt;for(Ue+=tt,yt+=tt,Xe.mf_size-=h.framesize,Xe.mf_samples_to_encode-=h.framesize,kt=0;kt<Xe.channels_out;kt++)for(Ve=0;Ve<Xe.mf_size;Ve++)cr[kt][Ve]=cr[kt][Ve+h.framesize]}}return Ua(ve==0),yt}function x(h,v,de,ve,De,Ue){var $e=z.enc.lame_encode_mp3_frame(h,v,de,ve,De,Ue);return h.frameNum++,$e}function N(){this.n_in=0,this.n_out=0}function T(){this.num_used=0}function Y(h,v){return v!=0?Y(v,h%v):h}function j(h,v,de){var ve=Math.PI*v;h/=de,h<0&&(h=0),h>1&&(h=1);var De=h-.5,Ue=.42-.5*Math.cos(2*h*Math.PI)+.08*Math.cos(4*h*Math.PI);return Math.abs(De)<1e-9?ve/Math.PI:Ue*Math.sin(de*ve*De)/(Math.PI*de*De)}function X(h,v,de,ve,De,Ue,$e,Xe,yt){var tt=h.internal_flags,Ve,kt=0,lr,Kt=h.out_samplerate/Y(h.out_samplerate,h.in_samplerate);Kt>rr.BPC&&(Kt=rr.BPC);var cr=Math.abs(tt.resample_ratio-Math.floor(.5+tt.resample_ratio))<1e-4?1:0,Nr=1/tt.resample_ratio;Nr>1&&(Nr=1);var Rr=31;Rr%2==0&&--Rr,Rr+=cr;var na=Rr+1;if(tt.fill_buffer_resample_init==0){for(tt.inbuf_old[0]=Hs(na),tt.inbuf_old[1]=Hs(na),Ve=0;Ve<=2*Kt;++Ve)tt.blackfilt[Ve]=Hs(na);for(tt.itime[0]=0,tt.itime[1]=0,kt=0;kt<=2*Kt;kt++){var ri=0,Aa=(kt-Kt)/(2*Kt);for(Ve=0;Ve<=Rr;Ve++)ri+=tt.blackfilt[kt][Ve]=j(Ve-Aa,Nr,Rr);for(Ve=0;Ve<=Rr;Ve++)tt.blackfilt[kt][Ve]/=ri}tt.fill_buffer_resample_init=1}var Ba=tt.inbuf_old[yt];for(lr=0;lr<ve;lr++){var En,Ds;if(En=lr*tt.resample_ratio,kt=0|Math.floor(En-tt.itime[yt]),Rr+kt-Rr/2>=$e)break;var Aa=En-tt.itime[yt]-(kt+.5*(Rr%2));Ua(Math.abs(Aa)<=.501),Ds=0|Math.floor(Aa*2*Kt+Kt+.5);var ks=0;for(Ve=0;Ve<=Rr;++Ve){var Tn=Ve+kt-Rr/2,ba;Ua(Tn<$e),Ua(Tn+na>=0),ba=Tn<0?Ba[na+Tn]:De[Ue+Tn],ks+=ba*tt.blackfilt[Ds][Ve]}v[de+lr]=ks}if(Xe.num_used=Math.min($e,Rr+kt-Rr/2),tt.itime[yt]+=Xe.num_used-lr*tt.resample_ratio,Xe.num_used>=na)for(Ve=0;Ve<na;Ve++)Ba[Ve]=De[Ue+Xe.num_used+Ve-na];else{var ts=na-Xe.num_used;for(Ve=0;Ve<ts;++Ve)Ba[Ve]=Ba[Ve+Xe.num_used];for(kt=0;Ve<na;++Ve,++kt)Ba[Ve]=De[Ue+kt];Ua(kt==Xe.num_used)}return lr}function _e(h,v,de,ve,De,Ue){var $e=h.internal_flags;if($e.resample_ratio<.9999||$e.resample_ratio>1.0001)for(var Xe=0;Xe<$e.channels_out;Xe++){var yt=new T;Ue.n_out=X(h,v[Xe],$e.mf_size,h.framesize,de[Xe],ve,De,yt,Xe),Ue.n_in=yt.num_used}else{Ue.n_out=Math.min(h.framesize,De),Ue.n_in=Ue.n_out;for(var tt=0;tt<Ue.n_out;++tt)v[0][$e.mf_size+tt]=de[0][ve+tt],$e.channels_out==2&&(v[1][$e.mf_size+tt]=de[1][ve+tt])}}}var V3=Hr,ei=C.VbrMode;function G3(){function z($,fe,ge,L,Q,m,B,V,k,_,g,D,K,w,u){this.vbr_q=$,this.quant_comp=fe,this.quant_comp_s=ge,this.expY=L,this.st_lrm=Q,this.st_s=m,this.masking_adj=B,this.masking_adj_short=V,this.ath_lower=k,this.ath_curve=_,this.ath_sensitivity=g,this.interch=D,this.safejoint=K,this.sfb21mod=w,this.msfix=u}function te($,fe,ge,L,Q,m,B,V,k,_,g,D,K,w){this.quant_comp=fe,this.quant_comp_s=ge,this.safejoint=L,this.nsmsfix=Q,this.st_lrm=m,this.st_s=B,this.nsbass=V,this.scale=k,this.masking_adj=_,this.ath_lower=g,this.ath_curve=D,this.interch=K,this.sfscale=w}var ce;this.setModules=function($){ce=$};var re=[new z(0,9,9,0,5.2,125,-4.2,-6.3,4.8,1,0,0,2,21,.97),new z(1,9,9,0,5.3,125,-3.6,-5.6,4.5,1.5,0,0,2,21,1.35),new z(2,9,9,0,5.6,125,-2.2,-3.5,2.8,2,0,0,2,21,1.49),new z(3,9,9,1,5.8,130,-1.8,-2.8,2.6,3,-4,0,2,20,1.64),new z(4,9,9,1,6,135,-.7,-1.1,1.1,3.5,-8,0,2,0,1.79),new z(5,9,9,1,6.4,140,.5,.4,-7.5,4,-12,2e-4,0,0,1.95),new z(6,9,9,1,6.6,145,.67,.65,-14.7,6.5,-19,4e-4,0,0,2.3),new z(7,9,9,1,6.6,145,.8,.75,-19.7,8,-22,6e-4,0,0,2.7),new z(8,9,9,1,6.6,145,1.2,1.15,-27.5,10,-23,7e-4,0,0,0),new z(9,9,9,1,6.6,145,1.6,1.6,-36,11,-25,8e-4,0,0,0),new z(10,9,9,1,6.6,145,2,2,-36,12,-25,8e-4,0,0,0)],Ee=[new z(0,9,9,0,4.2,25,-7,-4,7.5,1,0,0,2,26,.97),new z(1,9,9,0,4.2,25,-5.6,-3.6,4.5,1.5,0,0,2,21,1.35),new z(2,9,9,0,4.2,25,-4.4,-1.8,2,2,0,0,2,18,1.49),new z(3,9,9,1,4.2,25,-3.4,-1.25,1.1,3,-4,0,2,15,1.64),new z(4,9,9,1,4.2,25,-2.2,.1,0,3.5,-8,0,2,0,1.79),new z(5,9,9,1,4.2,25,-1,1.65,-7.7,4,-12,2e-4,0,0,1.95),new z(6,9,9,1,4.2,25,-0,2.47,-7.7,6.5,-19,4e-4,0,0,2),new z(7,9,9,1,4.2,25,.5,2,-14.5,8,-22,6e-4,0,0,2),new z(8,9,9,1,4.2,25,1,2.4,-22,10,-23,7e-4,0,0,2),new z(9,9,9,1,4.2,25,1.5,2.95,-30,11,-25,8e-4,0,0,2),new z(10,9,9,1,4.2,25,2,2.95,-36,12,-30,8e-4,0,0,2)];function ie($,fe,ge){var L=$.VBR==ei.vbr_rh?re:Ee,Q=$.VBR_q_frac,m=L[fe],B=L[fe+1],V=m;m.st_lrm=m.st_lrm+Q*(B.st_lrm-m.st_lrm),m.st_s=m.st_s+Q*(B.st_s-m.st_s),m.masking_adj=m.masking_adj+Q*(B.masking_adj-m.masking_adj),m.masking_adj_short=m.masking_adj_short+Q*(B.masking_adj_short-m.masking_adj_short),m.ath_lower=m.ath_lower+Q*(B.ath_lower-m.ath_lower),m.ath_curve=m.ath_curve+Q*(B.ath_curve-m.ath_curve),m.ath_sensitivity=m.ath_sensitivity+Q*(B.ath_sensitivity-m.ath_sensitivity),m.interch=m.interch+Q*(B.interch-m.interch),m.msfix=m.msfix+Q*(B.msfix-m.msfix),He($,V.vbr_q),ge!=0?$.quant_comp=V.quant_comp:Math.abs($.quant_comp- -1)>0||($.quant_comp=V.quant_comp),ge!=0?$.quant_comp_short=V.quant_comp_s:Math.abs($.quant_comp_short- -1)>0||($.quant_comp_short=V.quant_comp_s),V.expY!=0&&($.experimentalY=V.expY!=0),ge!=0?$.internal_flags.nsPsy.attackthre=V.st_lrm:Math.abs($.internal_flags.nsPsy.attackthre- -1)>0||($.internal_flags.nsPsy.attackthre=V.st_lrm),ge!=0?$.internal_flags.nsPsy.attackthre_s=V.st_s:Math.abs($.internal_flags.nsPsy.attackthre_s- -1)>0||($.internal_flags.nsPsy.attackthre_s=V.st_s),ge!=0?$.maskingadjust=V.masking_adj:Math.abs($.maskingadjust-0)>0||($.maskingadjust=V.masking_adj),ge!=0?$.maskingadjust_short=V.masking_adj_short:Math.abs($.maskingadjust_short-0)>0||($.maskingadjust_short=V.masking_adj_short),ge!=0?$.ATHlower=-V.ath_lower/10:Math.abs(-$.ATHlower*10-0)>0||($.ATHlower=-V.ath_lower/10),ge!=0?$.ATHcurve=V.ath_curve:Math.abs($.ATHcurve- -1)>0||($.ATHcurve=V.ath_curve),ge!=0?$.athaa_sensitivity=V.ath_sensitivity:Math.abs($.athaa_sensitivity- -1)>0||($.athaa_sensitivity=V.ath_sensitivity),V.interch>0&&(ge!=0?$.interChRatio=V.interch:Math.abs($.interChRatio- -1)>0||($.interChRatio=V.interch)),V.safejoint>0&&($.exp_nspsytune=$.exp_nspsytune|V.safejoint),V.sfb21mod>0&&($.exp_nspsytune=$.exp_nspsytune|V.sfb21mod<<20),ge!=0?$.msfix=V.msfix:Math.abs($.msfix- -1)>0||($.msfix=V.msfix),ge==0&&($.VBR_q=fe,$.VBR_q_frac=Q)}var ye=[new te(8,9,9,0,0,6.6,145,0,.95,0,-30,11,.0012,1),new te(16,9,9,0,0,6.6,145,0,.95,0,-25,11,.001,1),new te(24,9,9,0,0,6.6,145,0,.95,0,-20,11,.001,1),new te(32,9,9,0,0,6.6,145,0,.95,0,-15,11,.001,1),new te(40,9,9,0,0,6.6,145,0,.95,0,-10,11,9e-4,1),new te(48,9,9,0,0,6.6,145,0,.95,0,-10,11,9e-4,1),new te(56,9,9,0,0,6.6,145,0,.95,0,-6,11,8e-4,1),new te(64,9,9,0,0,6.6,145,0,.95,0,-2,11,8e-4,1),new te(80,9,9,0,0,6.6,145,0,.95,0,0,8,7e-4,1),new te(96,9,9,0,2.5,6.6,145,0,.95,0,1,5.5,6e-4,1),new te(112,9,9,0,2.25,6.6,145,0,.95,0,2,4.5,5e-4,1),new te(128,9,9,0,1.95,6.4,140,0,.95,0,3,4,2e-4,1),new te(160,9,9,1,1.79,6,135,0,.95,-2,5,3.5,0,1),new te(192,9,9,1,1.49,5.6,125,0,.97,-4,7,3,0,0),new te(224,9,9,1,1.25,5.2,125,0,.98,-6,9,2,0,0),new te(256,9,9,1,.97,5.2,125,0,1,-8,10,1,0,0),new te(320,9,9,1,.9,5.2,125,0,1,-10,12,0,0,0)];function ze($,fe,ge){var L=fe,Q=ce.nearestBitrateFullIndex(fe);if($.VBR=ei.vbr_abr,$.VBR_mean_bitrate_kbps=L,$.VBR_mean_bitrate_kbps=Math.min($.VBR_mean_bitrate_kbps,320),$.VBR_mean_bitrate_kbps=Math.max($.VBR_mean_bitrate_kbps,8),$.brate=$.VBR_mean_bitrate_kbps,$.VBR_mean_bitrate_kbps>320&&($.disable_reservoir=!0),ye[Q].safejoint>0&&($.exp_nspsytune=$.exp_nspsytune|2),ye[Q].sfscale>0&&($.internal_flags.noise_shaping=2),Math.abs(ye[Q].nsbass)>0){var m=int(ye[Q].nsbass*4);m<0&&(m+=64),$.exp_nspsytune=$.exp_nspsytune|m<<2}return ge!=0?$.quant_comp=ye[Q].quant_comp:Math.abs($.quant_comp- -1)>0||($.quant_comp=ye[Q].quant_comp),ge!=0?$.quant_comp_short=ye[Q].quant_comp_s:Math.abs($.quant_comp_short- -1)>0||($.quant_comp_short=ye[Q].quant_comp_s),ge!=0?$.msfix=ye[Q].nsmsfix:Math.abs($.msfix- -1)>0||($.msfix=ye[Q].nsmsfix),ge!=0?$.internal_flags.nsPsy.attackthre=ye[Q].st_lrm:Math.abs($.internal_flags.nsPsy.attackthre- -1)>0||($.internal_flags.nsPsy.attackthre=ye[Q].st_lrm),ge!=0?$.internal_flags.nsPsy.attackthre_s=ye[Q].st_s:Math.abs($.internal_flags.nsPsy.attackthre_s- -1)>0||($.internal_flags.nsPsy.attackthre_s=ye[Q].st_s),ge!=0?$.scale=ye[Q].scale:Math.abs($.scale- -1)>0||($.scale=ye[Q].scale),ge!=0?$.maskingadjust=ye[Q].masking_adj:Math.abs($.maskingadjust-0)>0||($.maskingadjust=ye[Q].masking_adj),ye[Q].masking_adj>0?ge!=0?$.maskingadjust_short=ye[Q].masking_adj*.9:Math.abs($.maskingadjust_short-0)>0||($.maskingadjust_short=ye[Q].masking_adj*.9):ge!=0?$.maskingadjust_short=ye[Q].masking_adj*1.1:Math.abs($.maskingadjust_short-0)>0||($.maskingadjust_short=ye[Q].masking_adj*1.1),ge!=0?$.ATHlower=-ye[Q].ath_lower/10:Math.abs(-$.ATHlower*10-0)>0||($.ATHlower=-ye[Q].ath_lower/10),ge!=0?$.ATHcurve=ye[Q].ath_curve:Math.abs($.ATHcurve- -1)>0||($.ATHcurve=ye[Q].ath_curve),ge!=0?$.interChRatio=ye[Q].interch:Math.abs($.interChRatio- -1)>0||($.interChRatio=ye[Q].interch),fe}this.apply_preset=function($,fe,ge){switch(fe){case Wt.R3MIX:{fe=Wt.V3,$.VBR=ei.vbr_mtrh;break}case Wt.MEDIUM:{fe=Wt.V4,$.VBR=ei.vbr_rh;break}case Wt.MEDIUM_FAST:{fe=Wt.V4,$.VBR=ei.vbr_mtrh;break}case Wt.STANDARD:{fe=Wt.V2,$.VBR=ei.vbr_rh;break}case Wt.STANDARD_FAST:{fe=Wt.V2,$.VBR=ei.vbr_mtrh;break}case Wt.EXTREME:{fe=Wt.V0,$.VBR=ei.vbr_rh;break}case Wt.EXTREME_FAST:{fe=Wt.V0,$.VBR=ei.vbr_mtrh;break}case Wt.INSANE:return fe=320,$.preset=fe,ze($,fe,ge),$.VBR=ei.vbr_off,fe}switch($.preset=fe,fe){case Wt.V9:return ie($,9,ge),fe;case Wt.V8:return ie($,8,ge),fe;case Wt.V7:return ie($,7,ge),fe;case Wt.V6:return ie($,6,ge),fe;case Wt.V5:return ie($,5,ge),fe;case Wt.V4:return ie($,4,ge),fe;case Wt.V3:return ie($,3,ge),fe;case Wt.V2:return ie($,2,ge),fe;case Wt.V1:return ie($,1,ge),fe;case Wt.V0:return ie($,0,ge),fe;default:break}return 8<=fe&&fe<=320?ze($,fe,ge):($.preset=0,fe)};function He($,fe){var ge=0;return 0>fe&&(ge=-1,fe=0),9<fe&&(ge=-1,fe=9),$.VBR_q=fe,$.VBR_q_frac=0,ge}}var K3=G3;function X3(){var z,te;this.setModules=function(ce,re){z=ce,te=re}}var $3=X3;function W3(){this.over_noise=0,this.tot_noise=0,this.max_noise=0,this.over_count=0,this.over_SSD=0,this.bits=0}var xp=W3,xg=C.new_float,Y3=C.new_int;function Q3(){this.global_gain=0,this.sfb_count1=0,this.step=Y3(39),this.noise=xg(39),this.noise_log=xg(39)}var Z3=Q3,es=C.System,gg=C.VbrMode,gp=C.Util,wo=C.Arrays,Gl=C.new_float,dn=C.assert;function J3(){var z;this.rv=null;var te;this.qupvt=null;var ce,re=new $3,Ee;this.setModules=function(k,_,g,D){z=k,te=_,this.rv=_,ce=g,this.qupvt=g,Ee=D,re.setModules(ce,Ee)},this.ms_convert=function(k,_){for(var g=0;g<576;++g){var D=k.tt[_][0].xr[g],K=k.tt[_][1].xr[g];k.tt[_][0].xr[g]=(D+K)*(gp.SQRT2*.5),k.tt[_][1].xr[g]=(D-K)*(gp.SQRT2*.5)}};function ie(k,_,g,D){D=0;for(var K=0;K<=g;++K){var w=Math.abs(k.xr[K]);D+=w,_[K]=Math.sqrt(w*Math.sqrt(w)),_[K]>k.xrpow_max&&(k.xrpow_max=_[K])}return D}this.init_xrpow=function(k,_,g){var D=0,K=0|_.max_nonzero_coeff;if(dn(g!=null),_.xrpow_max=0,dn(0<=K&&K<=575),wo.fill(g,K,576,0),D=ie(_,g,K,D),D>1e-20){var w=0;(k.substep_shaping&2)!=0&&(w=1);for(var u=0;u<_.psymax;u++)k.pseudohalf[u]=w;return!0}return wo.fill(_.l3_enc,0,576,0),!1};function ye(k,_){var g=k.ATH,D=_.xr;if(_.block_type!=P.SHORT_TYPE)for(var K=!1,w=P.PSFB21-1;w>=0&&!K;w--){var u=k.scalefac_band.psfb21[w],F=k.scalefac_band.psfb21[w+1],R=ce.athAdjust(g.adjust,g.psfb21[w],g.floor);k.nsPsy.longfact[21]>1e-12&&(R*=k.nsPsy.longfact[21]);for(var f=F-1;f>=u;f--)if(Math.abs(D[f])<R)D[f]=0;else{K=!0;break}}else for(var y=0;y<3;y++)for(var K=!1,w=P.PSFB12-1;w>=0&&!K;w--){var u=k.scalefac_band.s[12]*3+(k.scalefac_band.s[13]-k.scalefac_band.s[12])*y+(k.scalefac_band.psfb12[w]-k.scalefac_band.psfb12[0]),F=u+(k.scalefac_band.psfb12[w+1]-k.scalefac_band.psfb12[w]),b=ce.athAdjust(g.adjust,g.psfb12[w],g.floor);k.nsPsy.shortfact[12]>1e-12&&(b*=k.nsPsy.shortfact[12]);for(var f=F-1;f>=u;f--)if(Math.abs(D[f])<b)D[f]=0;else{K=!0;break}}}this.init_outer_loop=function(k,_){_.part2_3_length=0,_.big_values=0,_.count1=0,_.global_gain=210,_.scalefac_compress=0,_.table_select[0]=0,_.table_select[1]=0,_.table_select[2]=0,_.subblock_gain[0]=0,_.subblock_gain[1]=0,_.subblock_gain[2]=0,_.subblock_gain[3]=0,_.region0_count=0,_.region1_count=0,_.preflag=0,_.scalefac_scale=0,_.count1table_select=0,_.part2_length=0,_.sfb_lmax=P.SBPSY_l,_.sfb_smin=P.SBPSY_s,_.psy_lmax=k.sfb21_extra?P.SBMAX_l:P.SBPSY_l,_.psymax=_.psy_lmax,_.sfbmax=_.sfb_lmax,_.sfbdivide=11;for(var g=0;g<P.SBMAX_l;g++)_.width[g]=k.scalefac_band.l[g+1]-k.scalefac_band.l[g],_.window[g]=3;if(_.block_type==P.SHORT_TYPE){var D=Gl(576);_.sfb_smin=0,_.sfb_lmax=0,_.mixed_block_flag!=0&&(_.sfb_smin=3,_.sfb_lmax=k.mode_gr*2+4),_.psymax=_.sfb_lmax+3*((k.sfb21_extra?P.SBMAX_s:P.SBPSY_s)-_.sfb_smin),_.sfbmax=_.sfb_lmax+3*(P.SBPSY_s-_.sfb_smin),_.sfbdivide=_.sfbmax-18,_.psy_lmax=_.sfb_lmax;var K=k.scalefac_band.l[_.sfb_lmax];es.arraycopy(_.xr,0,D,0,576);for(var g=_.sfb_smin;g<P.SBMAX_s;g++)for(var w=k.scalefac_band.s[g],u=k.scalefac_band.s[g+1],F=0;F<3;F++)for(var R=w;R<u;R++)_.xr[K++]=D[3*R+F];for(var f=_.sfb_lmax,g=_.sfb_smin;g<P.SBMAX_s;g++)_.width[f]=_.width[f+1]=_.width[f+2]=k.scalefac_band.s[g+1]-k.scalefac_band.s[g],_.window[f]=0,_.window[f+1]=1,_.window[f+2]=2,f+=3}_.count1bits=0,_.sfb_partition_table=ce.nr_of_sfb_block[0][0],_.slen[0]=0,_.slen[1]=0,_.slen[2]=0,_.slen[3]=0,_.max_nonzero_coeff=575,wo.fill(_.scalefac,0),ye(k,_)};function ze(k){this.ordinal=k}ze.BINSEARCH_NONE=new ze(0),ze.BINSEARCH_UP=new ze(1),ze.BINSEARCH_DOWN=new ze(2);function He(k,_,g,D,K){var w,u=k.CurrentStep[D],F=!1,R=k.OldValue[D],f=ze.BINSEARCH_NONE;for(_.global_gain=R,g-=_.part2_length,dn(u!=0);;){var y;if(w=Ee.count_bits(k,K,_,null),u==1||w==g)break;w>g?(f==ze.BINSEARCH_DOWN&&(F=!0),F&&(u/=2),f=ze.BINSEARCH_UP,y=u):(f==ze.BINSEARCH_UP&&(F=!0),F&&(u/=2),f=ze.BINSEARCH_DOWN,y=-u),_.global_gain+=y,_.global_gain<0&&(_.global_gain=0,F=!0),_.global_gain>255&&(_.global_gain=255,F=!0)}for(dn(_.global_gain>=0),dn(_.global_gain<256);w>g&&_.global_gain<255;)_.global_gain++,w=Ee.count_bits(k,K,_,null);return k.CurrentStep[D]=R-_.global_gain>=4?4:2,k.OldValue[D]=_.global_gain,_.part2_3_length=w,w}this.trancate_smallspectrums=function(k,_,g,D){var K=Gl(Ei.SFBMAX);if(!((k.substep_shaping&4)==0&&_.block_type==P.SHORT_TYPE||(k.substep_shaping&128)!=0)){ce.calc_noise(_,g,K,new xp,null);for(var u=0;u<576;u++){var w=0;_.l3_enc[u]!=0&&(w=Math.abs(_.xr[u])),D[u]=w}var u=0,F=8;_.block_type==P.SHORT_TYPE&&(F=6);do{var R,f,y,b,d=_.width[F];if(u+=d,!(K[F]>=1)&&(wo.sort(D,u-d,d),!Mi.EQ(D[u-1],0))){R=(1-K[F])*g[F],f=0,b=0;do{var x;for(y=1;b+y<d&&!Mi.NEQ(D[b+u-d],D[b+u+y-d]);y++);if(x=D[b+u-d]*D[b+u-d]*y,R<x){b!=0&&(f=D[b+u-d-1]);break}R-=x,b+=y}while(b<d);if(!Mi.EQ(f,0))do Math.abs(_.xr[u-d])<=f&&(_.l3_enc[u-d]=0);while(--d>0)}}while(++F<_.psymax);_.part2_3_length=Ee.noquant_count_bits(k,_,null)}};function $(k){for(var _=0;_<k.sfbmax;_++)if(k.scalefac[_]+k.subblock_gain[k.window[_]]==0)return!1;return!0}function fe(k){return gp.FAST_LOG10(.368+.632*k*k*k)}function ge(k,_){for(var g=1e-37,D=0;D<_.psymax;D++)g+=fe(k[D]);return Math.max(1e-20,g)}function L(k,_,g,D,K){var w;switch(k){default:case 9:{_.over_count>0?(w=g.over_SSD<=_.over_SSD,g.over_SSD==_.over_SSD&&(w=g.bits<_.bits)):w=g.max_noise<0&&g.max_noise*10+g.bits<=_.max_noise*10+_.bits;break}case 0:w=g.over_count<_.over_count||g.over_count==_.over_count&&g.over_noise<_.over_noise||g.over_count==_.over_count&&Mi.EQ(g.over_noise,_.over_noise)&&g.tot_noise<_.tot_noise;break;case 8:g.max_noise=ge(K,D);case 1:w=g.max_noise<_.max_noise;break;case 2:w=g.tot_noise<_.tot_noise;break;case 3:w=g.tot_noise<_.tot_noise&&g.max_noise<_.max_noise;break;case 4:w=g.max_noise<=0&&_.max_noise>.2||g.max_noise<=0&&_.max_noise<0&&_.max_noise>g.max_noise-.2&&g.tot_noise<_.tot_noise||g.max_noise<=0&&_.max_noise>0&&_.max_noise>g.max_noise-.2&&g.tot_noise<_.tot_noise+_.over_noise||g.max_noise>0&&_.max_noise>-.05&&_.max_noise>g.max_noise-.1&&g.tot_noise+g.over_noise<_.tot_noise+_.over_noise||g.max_noise>0&&_.max_noise>-.1&&_.max_noise>g.max_noise-.15&&g.tot_noise+g.over_noise+g.over_noise<_.tot_noise+_.over_noise+_.over_noise;break;case 5:w=g.over_noise<_.over_noise||Mi.EQ(g.over_noise,_.over_noise)&&g.tot_noise<_.tot_noise;break;case 6:w=g.over_noise<_.over_noise||Mi.EQ(g.over_noise,_.over_noise)&&(g.max_noise<_.max_noise||Mi.EQ(g.max_noise,_.max_noise)&&g.tot_noise<=_.tot_noise);break;case 7:w=g.over_count<_.over_count||g.over_noise<_.over_noise;break}return _.over_count==0&&(w=w&&g.bits<_.bits),w}function Q(k,_,g,D,K){var w=k.internal_flags,u;_.scalefac_scale==0?u=1.2968395546510096:u=1.6817928305074292;for(var F=0,R=0;R<_.sfbmax;R++)F<g[R]&&(F=g[R]);var f=w.noise_shaping_amp;switch(f==3&&(K?f=2:f=1),f){case 2:break;case 1:F>1?F=Math.pow(F,.5):F*=.95;break;case 0:default:F>1?F=1:F*=.95;break}for(var y=0,R=0;R<_.sfbmax;R++){var b=_.width[R],d;if(y+=b,!(g[R]<F)){if((w.substep_shaping&2)!=0&&(w.pseudohalf[R]=w.pseudohalf[R]==0?1:0,w.pseudohalf[R]==0&&w.noise_shaping_amp==2))return;for(_.scalefac[R]++,d=-b;d<0;d++)D[y+d]*=u,D[y+d]>_.xrpow_max&&(_.xrpow_max=D[y+d]);if(w.noise_shaping_amp==2)return}}}function m(k,_){for(var g=1.2968395546510096,D=0,K=0;K<k.sfbmax;K++){var w=k.width[K],u=k.scalefac[K];if(k.preflag!=0&&(u+=ce.pretab[K]),D+=w,(u&1)!=0){u++;for(var F=-w;F<0;F++)_[D+F]*=g,_[D+F]>k.xrpow_max&&(k.xrpow_max=_[D+F])}k.scalefac[K]=u>>1}k.preflag=0,k.scalefac_scale=1}function B(k,_,g){var D,K=_.scalefac;for(D=0;D<_.sfb_lmax;D++)if(K[D]>=16)return!0;for(var w=0;w<3;w++){var u=0,F=0;for(D=_.sfb_lmax+w;D<_.sfbdivide;D+=3)u<K[D]&&(u=K[D]);for(;D<_.sfbmax;D+=3)F<K[D]&&(F=K[D]);if(!(u<16&&F<8)){if(_.subblock_gain[w]>=7)return!0;_.subblock_gain[w]++;var R=k.scalefac_band.l[_.sfb_lmax];for(D=_.sfb_lmax+w;D<_.sfbmax;D+=3){var f,y=_.width[D],b=K[D];if(dn(b>=0),b=b-(4>>_.scalefac_scale),b>=0){K[D]=b,R+=y*3;continue}K[D]=0;{var d=210+(b<<_.scalefac_scale+1);f=ce.IPOW20(d)}R+=y*(w+1);for(var x=-y;x<0;x++)g[R+x]*=f,g[R+x]>_.xrpow_max&&(_.xrpow_max=g[R+x]);R+=y*(3-w-1)}{var f=ce.IPOW20(202);R+=_.width[D]*(w+1);for(var x=-_.width[D];x<0;x++)g[R+x]*=f,g[R+x]>_.xrpow_max&&(_.xrpow_max=g[R+x])}}}return!1}function V(k,_,g,D,K){var w=k.internal_flags;Q(k,_,g,D,K);var u=$(_);return u?!1:(w.mode_gr==2?u=Ee.scale_bitcount(_):u=Ee.scale_bitcount_lsf(w,_),u?(w.noise_shaping>1&&(wo.fill(w.pseudohalf,0),_.scalefac_scale==0?(m(_,D),u=!1):_.block_type==P.SHORT_TYPE&&w.subblock_gain>0&&(u=B(w,_,D)||$(_))),u||(w.mode_gr==2?u=Ee.scale_bitcount(_):u=Ee.scale_bitcount_lsf(w,_)),!u):!0)}this.outer_loop=function(k,_,g,D,K,w){var u=k.internal_flags,F=new fm,R=Gl(576),f=Gl(Ei.SFBMAX),y=new xp,b,d=new Z3,x=9999999,N=!1,T=!1,Y=0;if(He(u,_,w,K,D),u.noise_shaping==0)return 100;ce.calc_noise(_,g,f,y,d),y.bits=_.part2_3_length,F.assign(_);var j=0;for(es.arraycopy(D,0,R,0,576);!N;){do{var X=new xp,_e,h=255;if((u.substep_shaping&2)!=0?_e=20:_e=3,u.sfb21_extra&&(f[F.sfbmax]>1||F.block_type==P.SHORT_TYPE&&(f[F.sfbmax+1]>1||f[F.sfbmax+2]>1))||!V(k,F,f,D,T))break;F.scalefac_scale!=0&&(h=254);var v=w-F.part2_length;if(v<=0)break;for(;(F.part2_3_length=Ee.count_bits(u,D,F,d))>v&&F.global_gain<=h;)F.global_gain++;if(F.global_gain>h)break;if(y.over_count==0){for(;(F.part2_3_length=Ee.count_bits(u,D,F,d))>x&&F.global_gain<=h;)F.global_gain++;if(F.global_gain>h)break}if(ce.calc_noise(F,g,f,X,d),X.bits=F.part2_3_length,_.block_type!=P.SHORT_TYPE?b=k.quant_comp:b=k.quant_comp_short,b=L(b,y,X,F,f)?1:0,b!=0)x=_.part2_3_length,y=X,_.assign(F),j=0,es.arraycopy(D,0,R,0,576);else if(u.full_outer_loop==0&&(++j>_e&&y.over_count==0||u.noise_shaping_amp==3&&T&&j>30||u.noise_shaping_amp==3&&T&&F.global_gain-Y>15))break}while(F.global_gain+F.scalefac_scale<255);u.noise_shaping_amp==3?T?N=!0:(F.assign(_),es.arraycopy(R,0,D,0,576),j=0,Y=F.global_gain,T=!0):N=!0}return dn(_.global_gain+_.scalefac_scale<=255),k.VBR==gg.vbr_rh||k.VBR==gg.vbr_mtrh?es.arraycopy(R,0,D,0,576):(u.substep_shaping&1)!=0&&trancate_smallspectrums(u,_,g,D),y.over_count},this.iteration_finish_one=function(k,_,g){var D=k.l3_side,K=D.tt[_][g];Ee.best_scalefac_store(k,_,g,D),k.use_best_huffman==1&&Ee.best_huffman_divide(k,K),te.ResvAdjust(k,K)},this.VBR_encode_granule=function(k,_,g,D,K,w,u){var F=k.internal_flags,R=new fm,f=Gl(576),y=u,b=u+1,d=(u+w)/2,x,N,T=0,Y=F.sfb21_extra;dn(y<=LameInternalFlags.MAX_BITS_PER_CHANNEL),wo.fill(R.l3_enc,0);do dn(d>=w),dn(d<=u),dn(w<=u),d>y-42?F.sfb21_extra=!1:F.sfb21_extra=Y,N=outer_loop(k,_,g,D,K,d),N<=0?(T=1,b=_.part2_3_length,R.assign(_),es.arraycopy(D,0,f,0,576),u=b-32,x=u-w,d=(u+w)/2):(w=d+32,x=u-w,d=(u+w)/2,T!=0&&(T=2,_.assign(R),es.arraycopy(f,0,D,0,576)));while(x>12);F.sfb21_extra=Y,T==2&&es.arraycopy(R.l3_enc,0,_.l3_enc,0,576),dn(_.part2_3_length<=y)},this.get_framebits=function(k,_){var g=k.internal_flags;g.bitrate_index=g.VBR_min_bitrate;var D=z.getframebits(k);g.bitrate_index=1,D=z.getframebits(k);for(var K=1;K<=g.VBR_max_bitrate;K++){g.bitrate_index=K;var w=new MeanBits(D);_[K]=te.ResvFrameBegin(k,w),D=w.bits}},this.VBR_old_prepare=function(k,_,g,D,K,w,u,F,R){var f=k.internal_flags,y,b=0,d=1,x=0;f.bitrate_index=f.VBR_max_bitrate;var N=te.ResvFrameBegin(k,new MeanBits(0))/f.mode_gr;get_framebits(k,w);for(var T=0;T<f.mode_gr;T++){var Y=ce.on_pe(k,_,F[T],N,T,0);f.mode_ext==P.MPG_MD_MS_LR&&(ms_convert(f.l3_side,T),ce.reduce_side(F[T],g[T],N,Y));for(var j=0;j<f.channels_out;++j){var X=f.l3_side.tt[T][j];X.block_type!=P.SHORT_TYPE?(b=1.28/(1+Math.exp(3.5-_[T][j]/300))-.05,y=f.PSY.mask_adjust-b):(b=2.56/(1+Math.exp(3.5-_[T][j]/300))-.14,y=f.PSY.mask_adjust_short-b),f.masking_lower=Math.pow(10,y*.1),init_outer_loop(f,X),R[T][j]=ce.calc_xmin(k,D[T][j],X,K[T][j]),R[T][j]!=0&&(d=0),u[T][j]=126,x+=F[T][j]}}for(var T=0;T<f.mode_gr;T++)for(var j=0;j<f.channels_out;j++)x>w[f.VBR_max_bitrate]&&(F[T][j]*=w[f.VBR_max_bitrate],F[T][j]/=x),u[T][j]>F[T][j]&&(u[T][j]=F[T][j]);return d},this.bitpressure_strategy=function(k,_,g,D){for(var K=0;K<k.mode_gr;K++)for(var w=0;w<k.channels_out;w++){for(var u=k.l3_side.tt[K][w],F=_[K][w],R=0,f=0;f<u.psy_lmax;f++)F[R++]*=1+.029*f*f/P.SBMAX_l/P.SBMAX_l;if(u.block_type==P.SHORT_TYPE)for(var f=u.sfb_smin;f<P.SBMAX_s;f++)F[R++]*=1+.029*f*f/P.SBMAX_s/P.SBMAX_s,F[R++]*=1+.029*f*f/P.SBMAX_s/P.SBMAX_s,F[R++]*=1+.029*f*f/P.SBMAX_s/P.SBMAX_s;D[K][w]=0|Math.max(g[K][w],.9*D[K][w])}},this.VBR_new_prepare=function(k,_,g,D,K,w){var u=k.internal_flags,F=1,R=0,f=0,y;if(k.free_format){u.bitrate_index=0;var b=new MeanBits(R);y=te.ResvFrameBegin(k,b),R=b.bits,K[0]=y}else{u.bitrate_index=u.VBR_max_bitrate;var b=new MeanBits(R);te.ResvFrameBegin(k,b),R=b.bits,get_framebits(k,K),y=K[u.VBR_max_bitrate]}for(var d=0;d<u.mode_gr;d++){ce.on_pe(k,_,w[d],R,d,0),u.mode_ext==P.MPG_MD_MS_LR&&ms_convert(u.l3_side,d);for(var x=0;x<u.channels_out;++x){var N=u.l3_side.tt[d][x];u.masking_lower=Math.pow(10,u.PSY.mask_adjust*.1),init_outer_loop(u,N),ce.calc_xmin(k,g[d][x],N,D[d][x])!=0&&(F=0),f+=w[d][x]}}for(var d=0;d<u.mode_gr;d++)for(var x=0;x<u.channels_out;x++)f>y&&(w[d][x]*=y,w[d][x]/=f);return F},this.calc_target_bits=function(k,_,g,D,K,w){var u=k.internal_flags,F=u.l3_side,R,f,y,b,d=0;u.bitrate_index=u.VBR_max_bitrate;var x=new MeanBits(d);for(w[0]=te.ResvFrameBegin(k,x),d=x.bits,u.bitrate_index=1,d=z.getframebits(k)-u.sideinfo_len*8,K[0]=d/(u.mode_gr*u.channels_out),d=k.VBR_mean_bitrate_kbps*k.framesize*1e3,(u.substep_shaping&1)!=0&&(d*=1.09),d/=k.out_samplerate,d-=u.sideinfo_len*8,d/=u.mode_gr*u.channels_out,R=.93+.07*(11-k.compression_ratio)/(11-5.5),R<.9&&(R=.9),R>1&&(R=1),f=0;f<u.mode_gr;f++){var N=0;for(y=0;y<u.channels_out;y++){if(D[f][y]=int(R*d),_[f][y]>700){var T=int((_[f][y]-700)/1.4),Y=F.tt[f][y];D[f][y]=int(R*d),Y.block_type==P.SHORT_TYPE&&T<d/2&&(T=d/2),T>d*3/2?T=d*3/2:T<0&&(T=0),D[f][y]+=T}D[f][y]>LameInternalFlags.MAX_BITS_PER_CHANNEL&&(D[f][y]=LameInternalFlags.MAX_BITS_PER_CHANNEL),N+=D[f][y]}if(N>LameInternalFlags.MAX_BITS_PER_GRANULE)for(y=0;y<u.channels_out;++y)D[f][y]*=LameInternalFlags.MAX_BITS_PER_GRANULE,D[f][y]/=N}if(u.mode_ext==P.MPG_MD_MS_LR)for(f=0;f<u.mode_gr;f++)ce.reduce_side(D[f],g[f],d*u.channels_out,LameInternalFlags.MAX_BITS_PER_GRANULE);for(b=0,f=0;f<u.mode_gr;f++)for(y=0;y<u.channels_out;y++)D[f][y]>LameInternalFlags.MAX_BITS_PER_CHANNEL&&(D[f][y]=LameInternalFlags.MAX_BITS_PER_CHANNEL),b+=D[f][y];if(b>w[0])for(f=0;f<u.mode_gr;f++)for(y=0;y<u.channels_out;y++)D[f][y]*=w[0],D[f][y]/=b}}var eC=J3,_m=C.assert;function tC(){var z;this.setModules=function(te){z=te},this.ResvFrameBegin=function(te,ce){var re=te.internal_flags,Ee,ie=re.l3_side,ye=z.getframebits(te);ce.bits=(ye-re.sideinfo_len*8)/re.mode_gr;var ze=8*256*re.mode_gr-8;te.brate>320?Ee=8*int(te.brate*1e3/(te.out_samplerate/1152)/8+.5):(Ee=8*1440,te.strict_ISO&&(Ee=8*int(32e4/(te.out_samplerate/1152)/8+.5))),re.ResvMax=Ee-ye,re.ResvMax>ze&&(re.ResvMax=ze),(re.ResvMax<0||te.disable_reservoir)&&(re.ResvMax=0);var He=ce.bits*re.mode_gr+Math.min(re.ResvSize,re.ResvMax);return He>Ee&&(He=Ee),_m(re.ResvMax%8==0),_m(re.ResvMax>=0),ie.resvDrain_pre=0,re.pinfo!=null&&(re.pinfo.mean_bits=ce.bits/2,re.pinfo.resvsize=re.ResvSize),He},this.ResvMaxBits=function(te,ce,re,Ee){var ie=te.internal_flags,ye,ze=ie.ResvSize,He=ie.ResvMax;Ee!=0&&(ze+=ce),(ie.substep_shaping&1)!=0&&(He*=.9),re.bits=ce,ze*10>He*9?(ye=ze-He*9/10,re.bits+=ye,ie.substep_shaping|=128):(ye=0,ie.substep_shaping&=127,!te.disable_reservoir&&(ie.substep_shaping&1)==0&&(re.bits-=.1*ce));var $=ze<ie.ResvMax*6/10?ze:ie.ResvMax*6/10;return $-=ye,$<0&&($=0),$},this.ResvAdjust=function(te,ce){te.ResvSize-=ce.part2_3_length+ce.part2_length},this.ResvFrameEnd=function(te,ce){var re,Ee=te.l3_side;te.ResvSize+=ce*te.mode_gr;var ie=0;Ee.resvDrain_post=0,Ee.resvDrain_pre=0,(re=te.ResvSize%8)!=0&&(ie+=re),re=te.ResvSize-ie-te.ResvMax,re>0&&(_m(re%8==0),_m(re>=0),ie+=re);{var ye=Math.min(Ee.main_data_begin*8,ie)/8;Ee.resvDrain_pre+=8*ye,ie-=8*ye,te.ResvSize-=8*ye,Ee.main_data_begin-=ye}Ee.resvDrain_post+=ie,te.ResvSize-=ie}}var rC=tC;function aC(){var z="http://www.mp3dev.org/",te=3,ce=98,re=4,Ee=0,ie=93;this.getLameVersion=function(){return te+"."+ce+"."+re},this.getLameShortVersion=function(){return te+"."+ce+"."+re},this.getLameVeryShortVersion=function(){return"LAME"+te+"."+ce+"r"},this.getPsyVersion=function(){return Ee+"."+ie},this.getLameUrl=function(){return z},this.getLameOsBitness=function(){return"32bits"}}var nC=aC,iC=C.System,vp=C.VbrMode,vg=C.ShortBlock,sC=C.Arrays,bm=C.new_byte,oC=C.assert;Kl.NUMTOCENTRIES=100,Kl.MAXFRAMESIZE=2880;function Kl(){var z,te,ce;this.setModules=function(d,x,N){z=d,te=x,ce=N};var re=1,Ee=2,ie=4,ye=8,ze=Kl.NUMTOCENTRIES,He=Kl.MAXFRAMESIZE,$=ze+4+4+4+4+4,fe=$+9+1+1+8+1+1+3+1+1+2+4+2+2,ge=128,L=64,Q=32,m=null,B="Xing",V="Info",k=[0,49345,49537,320,49921,960,640,49729,50689,1728,1920,51009,1280,50625,50305,1088,52225,3264,3456,52545,3840,53185,52865,3648,2560,51905,52097,2880,51457,2496,2176,51265,55297,6336,6528,55617,6912,56257,55937,6720,7680,57025,57217,8e3,56577,7616,7296,56385,5120,54465,54657,5440,55041,6080,5760,54849,53761,4800,4992,54081,4352,53697,53377,4160,61441,12480,12672,61761,13056,62401,62081,12864,13824,63169,63361,14144,62721,13760,13440,62529,15360,64705,64897,15680,65281,16320,16e3,65089,64001,15040,15232,64321,14592,63937,63617,14400,10240,59585,59777,10560,60161,11200,10880,59969,60929,11968,12160,61249,11520,60865,60545,11328,58369,9408,9600,58689,9984,59329,59009,9792,8704,58049,58241,9024,57601,8640,8320,57409,40961,24768,24960,41281,25344,41921,41601,25152,26112,42689,42881,26432,42241,26048,25728,42049,27648,44225,44417,27968,44801,28608,28288,44609,43521,27328,27520,43841,26880,43457,43137,26688,30720,47297,47489,31040,47873,31680,31360,47681,48641,32448,32640,48961,32e3,48577,48257,31808,46081,29888,30080,46401,30464,47041,46721,30272,29184,45761,45953,29504,45313,29120,28800,45121,20480,37057,37249,20800,37633,21440,21120,37441,38401,22208,22400,38721,21760,38337,38017,21568,39937,23744,23936,40257,24320,40897,40577,24128,23040,39617,39809,23360,39169,22976,22656,38977,34817,18624,18816,35137,19200,35777,35457,19008,19968,36545,36737,20288,36097,19904,19584,35905,17408,33985,34177,17728,34561,18368,18048,34369,33281,17088,17280,33601,16640,33217,32897,16448];function _(d,x){if(d.nVbrNumFrames++,d.sum+=x,d.seen++,!(d.seen<d.want)&&(d.pos<d.size&&(d.bag[d.pos]=d.sum,d.pos++,d.seen=0),d.pos==d.size)){for(var N=1;N<d.size;N+=2)d.bag[N/2]=d.bag[N];d.want*=2,d.pos/=2}}function g(d,x){if(!(d.pos<=0))for(var N=1;N<ze;++N){var T=N/ze,Y,j,X=0|Math.floor(T*d.pos);X>d.pos-1&&(X=d.pos-1),Y=d.bag[X],j=d.sum;var _e=0|256*Y/j;_e>255&&(_e=255),x[N]=255&_e}}this.addVbrFrame=function(d){var x=d.internal_flags,N=Tables.bitrate_table[d.version][x.bitrate_index];oC(x.VBR_seek_table.bag!=null),_(x.VBR_seek_table,N)};function D(d,x){var N=d[x+0]&255;return N<<=8,N|=d[x+1]&255,N<<=8,N|=d[x+2]&255,N<<=8,N|=d[x+3]&255,N}function K(d,x,N){d[x+0]=255&(N>>24&255),d[x+1]=255&(N>>16&255),d[x+2]=255&(N>>8&255),d[x+3]=255&(N&255)}function w(d,x,N){d[x+0]=255&(N>>8&255),d[x+1]=255&(N&255)}function u(d,x){return new String(d,x,B.length(),m).equals(B)||new String(d,x,V.length(),m).equals(V)}function F(d,x,N){return 255&(d<<x|N&~(-1<<x))}function R(d,x){var N=d.internal_flags;x[0]=F(x[0],8,255),x[1]=F(x[1],3,7),x[1]=F(x[1],1,d.out_samplerate<16e3?0:1),x[1]=F(x[1],1,d.version),x[1]=F(x[1],2,4-3),x[1]=F(x[1],1,d.error_protection?0:1),x[2]=F(x[2],4,N.bitrate_index),x[2]=F(x[2],2,N.samplerate_index),x[2]=F(x[2],1,0),x[2]=F(x[2],1,d.extension),x[3]=F(x[3],2,d.mode.ordinal()),x[3]=F(x[3],2,N.mode_ext),x[3]=F(x[3],1,d.copyright),x[3]=F(x[3],1,d.original),x[3]=F(x[3],2,d.emphasis),x[0]=255;var T=255&(x[1]&241),Y;d.version==1?Y=ge:d.out_samplerate<16e3?Y=Q:Y=L,d.VBR==vp.vbr_off&&(Y=d.brate);var j;d.free_format?j=0:j=255&16*z.BitrateIndex(Y,d.version,d.out_samplerate),d.version==1?(x[1]=255&(T|10),T=255&(x[2]&13),x[2]=255&(j|T)):(x[1]=255&(T|2),T=255&(x[2]&13),x[2]=255&(j|T))}this.getVbrTag=function(d){var x=new VBRTagData,N=0;x.flags=0;var T=d[N+1]>>3&1,Y=d[N+2]>>2&3,j=d[N+3]>>6&3,X=d[N+2]>>4&15;if(X=Tables.bitrate_table[T][X],d[N+1]>>4==14?x.samprate=Tables.samplerate_table[2][Y]:x.samprate=Tables.samplerate_table[T][Y],T!=0?j!=3?N+=32+4:N+=17+4:j!=3?N+=17+4:N+=9+4,!u(d,N))return null;N+=4,x.hId=T;var _e=x.flags=D(d,N);if(N+=4,(_e&re)!=0&&(x.frames=D(d,N),N+=4),(_e&Ee)!=0&&(x.bytes=D(d,N),N+=4),(_e&ie)!=0){if(x.toc!=null)for(var h=0;h<ze;h++)x.toc[h]=d[N+h];N+=ze}x.vbrScale=-1,(_e&ye)!=0&&(x.vbrScale=D(d,N),N+=4),x.headersize=(T+1)*72e3*X/x.samprate,N+=21;var v=d[N+0]<<4;v+=d[N+1]>>4;var de=(d[N+1]&15)<<8;return de+=d[N+2]&255,(v<0||v>3e3)&&(v=-1),(de<0||de>3e3)&&(de=-1),x.encDelay=v,x.encPadding=de,x},this.InitVbrTag=function(d){var x=d.internal_flags,N;d.version==1?N=ge:d.out_samplerate<16e3?N=Q:N=L,d.VBR==vp.vbr_off&&(N=d.brate);var T=(d.version+1)*72e3*N/d.out_samplerate,Y=x.sideinfo_len+fe;if(x.VBR_seek_table.TotalFrameSize=T,T<Y||T>He){d.bWriteVbrTag=!1;return}x.VBR_seek_table.nVbrNumFrames=0,x.VBR_seek_table.nBytesWritten=0,x.VBR_seek_table.sum=0,x.VBR_seek_table.seen=0,x.VBR_seek_table.want=1,x.VBR_seek_table.pos=0,x.VBR_seek_table.bag==null&&(x.VBR_seek_table.bag=new int[400],x.VBR_seek_table.size=400);var j=bm(He);R(d,j);for(var X=x.VBR_seek_table.TotalFrameSize,_e=0;_e<X;++_e)te.add_dummy_byte(d,j[_e]&255,1)};function f(d,x){var N=x^d;return x=x>>8^k[N&255],x}this.updateMusicCRC=function(d,x,N,T){for(var Y=0;Y<T;++Y)d[0]=f(x[N+Y],d[0])};function y(d,x,N,T,Y){var j=d.internal_flags,X=0,_e=d.encoder_delay,h=d.encoder_padding,v=100-10*d.VBR_q-d.quality,de=ce.getLameVeryShortVersion(),ve,De=0,Ue,$e=[1,5,3,2,4,0,3],Xe=0|(d.lowpassfreq/100+.5>255?255:d.lowpassfreq/100+.5),yt=0,tt=0,Ve=0,kt=d.internal_flags.noise_shaping,lr=0,Kt=0,cr=0,Nr=0,Rr=0,na=(d.exp_nspsytune&1)!=0,ri=(d.exp_nspsytune&2)!=0,Aa=!1,Ba=!1,En=d.internal_flags.nogap_total,Ds=d.internal_flags.nogap_current,ks=d.ATHtype,Tn=0,ba;switch(d.VBR){case vbr_abr:ba=d.VBR_mean_bitrate_kbps;break;case vbr_off:ba=d.brate;break;default:ba=d.VBR_min_bitrate_kbps}switch(d.VBR.ordinal()<$e.length?ve=$e[d.VBR.ordinal()]:ve=0,Ue=16*De+ve,j.findReplayGain&&(j.RadioGain>510&&(j.RadioGain=510),j.RadioGain<-510&&(j.RadioGain=-510),tt=8192,tt|=3072,j.RadioGain>=0?tt|=j.RadioGain:(tt|=512,tt|=-j.RadioGain)),j.findPeakSample&&(yt=Math.abs(0|j.PeakSample/32767*Math.pow(2,23)+.5)),En!=-1&&(Ds>0&&(Ba=!0),Ds<En-1&&(Aa=!0)),Tn=ks+((na?1:0)<<4)+((ri?1:0)<<5)+((Aa?1:0)<<6)+((Ba?1:0)<<7),v<0&&(v=0),d.mode){case MONO:lr=0;break;case STEREO:lr=1;break;case DUAL_CHANNEL:lr=2;break;case JOINT_STEREO:d.force_ms?lr=4:lr=3;break;case NOT_SET:default:lr=7;break}d.in_samplerate<=32e3?cr=0:d.in_samplerate==48e3?cr=2:d.in_samplerate>48e3?cr=3:cr=1,(d.short_blocks==vg.short_block_forced||d.short_blocks==vg.short_block_dispensed||d.lowpassfreq==-1&&d.highpassfreq==-1||d.scale_left<d.scale_right||d.scale_left>d.scale_right||d.disable_reservoir&&d.brate<320||d.noATH||d.ATHonly||ks==0||d.in_samplerate<=32e3)&&(Kt=1),Nr=kt+(lr<<2)+(Kt<<5)+(cr<<6),Rr=j.nMusicCRC,K(N,T+X,v),X+=4;for(var ts=0;ts<9;ts++)N[T+X+ts]=255&de.charAt(ts);X+=9,N[T+X]=255&Ue,X++,N[T+X]=255&Xe,X++,K(N,T+X,yt),X+=4,w(N,T+X,tt),X+=2,w(N,T+X,Ve),X+=2,N[T+X]=255&Tn,X++,ba>=255?N[T+X]=255:N[T+X]=255&ba,X++,N[T+X]=255&_e>>4,N[T+X+1]=255&(_e<<4)+(h>>8),N[T+X+2]=255&h,X+=3,N[T+X]=255&Nr,X++,N[T+X++]=0,w(N,T+X,d.preset),X+=2,K(N,T+X,x),X+=4,w(N,T+X,Rr),X+=2;for(var $l=0;$l<X;$l++)Y=f(N[T+$l],Y);return w(N,T+X,Y),X+=2,X}function b(d){d.seek(0);var x=bm(10);d.readFully(x);var N;return new String(x,"ISO-8859-1").startsWith("ID3")?N=0:N=((x[6]&127)<<21|(x[7]&127)<<14|(x[8]&127)<<7|x[9]&127)+x.length,N}this.getLameTagFrame=function(d,x){var N=d.internal_flags;if(!d.bWriteVbrTag||N.Class_ID!=Wt.LAME_ID||N.VBR_seek_table.pos<=0)return 0;if(x.length<N.VBR_seek_table.TotalFrameSize)return N.VBR_seek_table.TotalFrameSize;sC.fill(x,0,N.VBR_seek_table.TotalFrameSize,0),R(d,x);var T=bm(ze);if(d.free_format)for(var Y=1;Y<ze;++Y)T[Y]=255&255*Y/100;else g(N.VBR_seek_table,T);var j=N.sideinfo_len;d.error_protection&&(j-=2),d.VBR==vp.vbr_off?(x[j++]=255&V.charAt(0),x[j++]=255&V.charAt(1),x[j++]=255&V.charAt(2),x[j++]=255&V.charAt(3)):(x[j++]=255&B.charAt(0),x[j++]=255&B.charAt(1),x[j++]=255&B.charAt(2),x[j++]=255&B.charAt(3)),K(x,j,re+Ee+ie+ye),j+=4,K(x,j,N.VBR_seek_table.nVbrNumFrames),j+=4;var X=N.VBR_seek_table.nBytesWritten+N.VBR_seek_table.TotalFrameSize;K(x,j,0|X),j+=4,iC.arraycopy(T,0,x,j,T.length),j+=T.length,d.error_protection&&te.CRC_writeheader(N,x);for(var _e=0,Y=0;Y<j;Y++)_e=f(x[Y],_e);return j+=y(d,X,x,j,_e),N.VBR_seek_table.TotalFrameSize},this.putVbrTag=function(d,x){var N=d.internal_flags;if(N.VBR_seek_table.pos<=0||(x.seek(x.length()),x.length()==0))return-1;var T=b(x);x.seek(T);var Y=bm(He),j=getLameTagFrame(d,Y);return j>Y.length?-1:(j<1||x.write(Y,0,j),0)}}var lC=Kl,_g=C.new_byte,bg=C.assert,Wt=V3,cC=K3,Xl=_a,mC=Zi,dC=eC,uC=hp,pC=rC,Dr=fa,Mi=Ji;function fC(){var z,te;this.setModules=function(ce,re){z=ce,te=re}}function hC(){var z,te,ce;this.setModules=function(re,Ee,ie){z=re,te=Ee,ce=ie}}function yC(){}function xC(){var z,te;this.setModules=function(ce,re){z=ce,te=re}}function gC(z,te,ce){arguments.length!=3&&(console.error("WARN: Mp3Encoder(channels, samplerate, kbps) not specified"),z=1,te=44100,ce=128);var re=new Wt,Ee=new fC,ie=new Xl,ye=new Mi,ze=new cC,He=new mC,$=new dC,fe=new lC,ge=new nC,L=new xC,Q=new pC,m=new uC,B=new hC,V=new yC;re.setModules(ie,ye,ze,He,$,fe,ge,L,V),ye.setModules(ie,V,ge,fe),L.setModules(ye,ge),ze.setModules(re),$.setModules(ye,Q,He,m),He.setModules(m,Q,re.enc.psy),Q.setModules(ye),m.setModules(He),fe.setModules(re,ye,ge),Ee.setModules(B,V),B.setModules(ge,L,ze);var k=re.lame_init();k.num_channels=z,k.in_samplerate=te,k.brate=ce,k.mode=Dr.STEREO,k.quality=3,k.bWriteVbrTag=!1,k.disable_reservoir=!0,k.write_id3tag_automatic=!1;var _=re.lame_init_params(k);bg(_==0);var g=1152,D=0|1.25*g+7200,K=_g(D);this.encodeBuffer=function(w,u){z==1&&(u=w),bg(w.length==u.length),w.length>g&&(g=w.length,D=0|1.25*g+7200,K=_g(D));var F=re.lame_encode_buffer(k,w,u,w.length,K,0,D);return new Int8Array(K.subarray(0,F))},this.flush=function(){var w=re.lame_encode_flush(k,K,0,D);return new Int8Array(K.subarray(0,w))}}function ti(){this.dataOffset=0,this.dataLen=0,this.channels=0,this.sampleRate=0}function Sm(z){return z.charCodeAt(0)<<24|z.charCodeAt(1)<<16|z.charCodeAt(2)<<8|z.charCodeAt(3)}ti.RIFF=Sm("RIFF"),ti.WAVE=Sm("WAVE"),ti.fmt_=Sm("fmt "),ti.data=Sm("data"),ti.readHeader=function(z){var te=new ti,ce=z.getUint32(0,!1);if(ti.RIFF==ce){var re=z.getUint32(4,!0);if(ti.WAVE==z.getUint32(8,!1)&&ti.fmt_==z.getUint32(12,!1)){var Ee=z.getUint32(16,!0),ie=16+4;switch(Ee){case 16:case 18:te.channels=z.getUint16(ie+2,!0),te.sampleRate=z.getUint32(ie+4,!0);break;default:throw"extended fmt chunk not implemented"}ie+=Ee;for(var ye=ti.data,ze=0;ye!=ce&&(ce=z.getUint32(ie,!1),ze=z.getUint32(ie+4,!0),ye!=ce);)ie+=ze+8;return te.dataLen=ze,te.dataOffset=ie+8,te}}};var vC=gC,Sg=function(z,te){if(!(z instanceof te))throw new TypeError("Cannot call a class as a function")},Ng=function(){function z(te,ce){for(var re=0;re<ce.length;re++){var Ee=ce[re];Ee.enumerable=Ee.enumerable||!1,Ee.configurable=!0,"value"in Ee&&(Ee.writable=!0),Object.defineProperty(te,Ee.key,Ee)}}return function(te,ce,re){return ce&&z(te.prototype,ce),re&&z(te,re),te}}(),_C=function(){function z(te){Sg(this,z),this.config={sampleRate:44100,bitRate:128},Object.assign(this.config,te),this.mp3Encoder=new vC(1,this.config.sampleRate,this.config.bitRate),this.maxSamples=1152,this.samplesMono=null,this.clearBuffer()}return Ng(z,[{key:"clearBuffer",value:function(){this.dataBuffer=[]}},{key:"appendToBuffer",value:function(ce){this.dataBuffer.push(new Int8Array(ce))}},{key:"floatTo16BitPCM",value:function(ce,re){for(var Ee=0;Ee<ce.length;Ee++){var ie=Math.max(-1,Math.min(1,ce[Ee]));re[Ee]=ie<0?ie*32768:ie*32767}}},{key:"convertBuffer",value:function(ce){var re=new Float32Array(ce),Ee=new Int16Array(ce.length);return this.floatTo16BitPCM(re,Ee),Ee}},{key:"encode",value:function(ce){this.samplesMono=this.convertBuffer(ce);for(var re=this.samplesMono.length,Ee=0;re>=0;Ee+=this.maxSamples){var ie=this.samplesMono.subarray(Ee,Ee+this.maxSamples),ye=this.mp3Encoder.encodeBuffer(ie);this.appendToBuffer(ye),re-=this.maxSamples}}},{key:"finish",value:function(){return this.appendToBuffer(this.mp3Encoder.flush()),this.dataBuffer}}]),z}(),bC=function(){function z(te){Sg(this,z),this.config={bitRate:128,startRecordingAt:300,deviceId:null},this.activeStream=null,this.context=null,this.microphone=null,this.processor=null,this.startTime=0,Object.assign(this.config,te)}return Ng(z,[{key:"addMicrophoneListener",value:function(ce){var re=this;this.activeStream=ce,this.timerToStart=setTimeout(function(){delete re.timerToStart},this.config.startRecordingAt),this.microphone=this.context.createMediaStreamSource(ce),this.processor=this.context.createScriptProcessor(0,1,1),this.processor.onaudioprocess=function(Ee){re.timerToStart||re.lameEncoder.encode(Ee.inputBuffer.getChannelData(0))},this.microphone.connect(this.processor),this.processor.connect(this.context.destination)}},{key:"stop",value:function(){return this.processor&&this.microphone&&(this.microphone.disconnect(),this.processor.disconnect(),this.context&&this.context.state!=="closed"&&this.context.close(),this.processor.onaudioprocess=null,this.activeStream.getAudioTracks().forEach(function(ce){return ce.stop()})),this}},{key:"start",value:function(){var ce=this,re=window.AudioContext||window.webkitAudioContext;this.context=new re,this.config.sampleRate=this.context.sampleRate,this.lameEncoder=new _C(this.config);var Ee=this.config.deviceId?{deviceId:{exact:this.config.deviceId}}:!0;return new Promise(function(ie,ye){navigator.mediaDevices.getUserMedia({audio:Ee}).then(function(ze){ce.addMicrophoneListener(ze),ie(ze)}).catch(function(ze){ye(ze)})})}},{key:"getMp3",value:function(){var ce=this,re=this.lameEncoder.finish();return new Promise(function(Ee,ie){re.length===0?ie(new Error("No buffer to send")):(Ee([re,new Blob(re,{type:"audio/mp3"})]),ce.lameEncoder.clearBuffer())})}}]),z}();return bC})});var _v=as((QI,Am)=>{var ev,tv,rv,av,nv,iv,sv,ov,lv,Im,jp,cv,mv,dv,Bo,uv,pv,fv,hv,yv,xv,gv,vv,Mm;(function(r){var e=typeof global=="object"?global:typeof self=="object"?self:typeof this=="object"?this:{};typeof define=="function"&&define.amd?define("tslib",["exports"],function(a){r(t(e,t(a)))}):typeof Am=="object"&&typeof Am.exports=="object"?r(t(e,t(Am.exports))):r(t(e));function t(a,n){return a!==e&&(typeof Object.create=="function"?Object.defineProperty(a,"__esModule",{value:!0}):a.__esModule=!0),function(i,s){return a[i]=n?n(i,s):s}}})(function(r){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,n){a.__proto__=n}||function(a,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(a[i]=n[i])};ev=function(a,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(a,n);function i(){this.constructor=a}a.prototype=n===null?Object.create(n):(i.prototype=n.prototype,new i)},tv=Object.assign||function(a){for(var n,i=1,s=arguments.length;i<s;i++){n=arguments[i];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(a[o]=n[o])}return a},rv=function(a,n){var i={};for(var s in a)Object.prototype.hasOwnProperty.call(a,s)&&n.indexOf(s)<0&&(i[s]=a[s]);if(a!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,s=Object.getOwnPropertySymbols(a);o<s.length;o++)n.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(a,s[o])&&(i[s[o]]=a[s[o]]);return i},av=function(a,n,i,s){var o=arguments.length,l=o<3?n:s===null?s=Object.getOwnPropertyDescriptor(n,i):s,c;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")l=Reflect.decorate(a,n,i,s);else for(var p=a.length-1;p>=0;p--)(c=a[p])&&(l=(o<3?c(l):o>3?c(n,i,l):c(n,i))||l);return o>3&&l&&Object.defineProperty(n,i,l),l},nv=function(a,n){return function(i,s){n(i,s,a)}},iv=function(a,n){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(a,n)},sv=function(a,n,i,s){function o(l){return l instanceof i?l:new i(function(c){c(l)})}return new(i||(i=Promise))(function(l,c){function p(O){try{S(s.next(O))}catch(E){c(E)}}function M(O){try{S(s.throw(O))}catch(E){c(E)}}function S(O){O.done?l(O.value):o(O.value).then(p,M)}S((s=s.apply(a,n||[])).next())})},ov=function(a,n){var i={label:0,sent:function(){if(l[0]&1)throw l[1];return l[1]},trys:[],ops:[]},s,o,l,c;return c={next:p(0),throw:p(1),return:p(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function p(S){return function(O){return M([S,O])}}function M(S){if(s)throw new TypeError("Generator is already executing.");for(;i;)try{if(s=1,o&&(l=S[0]&2?o.return:S[0]?o.throw||((l=o.return)&&l.call(o),0):o.next)&&!(l=l.call(o,S[1])).done)return l;switch(o=0,l&&(S=[S[0]&2,l.value]),S[0]){case 0:case 1:l=S;break;case 4:return i.label++,{value:S[1],done:!1};case 5:i.label++,o=S[1],S=[0];continue;case 7:S=i.ops.pop(),i.trys.pop();continue;default:if(l=i.trys,!(l=l.length>0&&l[l.length-1])&&(S[0]===6||S[0]===2)){i=0;continue}if(S[0]===3&&(!l||S[1]>l[0]&&S[1]<l[3])){i.label=S[1];break}if(S[0]===6&&i.label<l[1]){i.label=l[1],l=S;break}if(l&&i.label<l[2]){i.label=l[2],i.ops.push(S);break}l[2]&&i.ops.pop(),i.trys.pop();continue}S=n.call(a,i)}catch(O){S=[6,O],o=0}finally{s=l=0}if(S[0]&5)throw S[1];return{value:S[0]?S[1]:void 0,done:!0}}},lv=function(a,n){for(var i in a)i!=="default"&&!Object.prototype.hasOwnProperty.call(n,i)&&Mm(n,a,i)},Mm=Object.create?function(a,n,i,s){s===void 0&&(s=i),Object.defineProperty(a,s,{enumerable:!0,get:function(){return n[i]}})}:function(a,n,i,s){s===void 0&&(s=i),a[s]=n[i]},Im=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,i=n&&a[n],s=0;if(i)return i.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&s>=a.length&&(a=void 0),{value:a&&a[s++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},jp=function(a,n){var i=typeof Symbol=="function"&&a[Symbol.iterator];if(!i)return a;var s=i.call(a),o,l=[],c;try{for(;(n===void 0||n-- >0)&&!(o=s.next()).done;)l.push(o.value)}catch(p){c={error:p}}finally{try{o&&!o.done&&(i=s.return)&&i.call(s)}finally{if(c)throw c.error}}return l},cv=function(){for(var a=[],n=0;n<arguments.length;n++)a=a.concat(jp(arguments[n]));return a},mv=function(){for(var a=0,n=0,i=arguments.length;n<i;n++)a+=arguments[n].length;for(var s=Array(a),o=0,n=0;n<i;n++)for(var l=arguments[n],c=0,p=l.length;c<p;c++,o++)s[o]=l[c];return s},dv=function(a,n,i){if(i||arguments.length===2)for(var s=0,o=n.length,l;s<o;s++)(l||!(s in n))&&(l||(l=Array.prototype.slice.call(n,0,s)),l[s]=n[s]);return a.concat(l||Array.prototype.slice.call(n))},Bo=function(a){return this instanceof Bo?(this.v=a,this):new Bo(a)},uv=function(a,n,i){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var s=i.apply(a,n||[]),o,l=[];return o={},c("next"),c("throw"),c("return"),o[Symbol.asyncIterator]=function(){return this},o;function c(q){s[q]&&(o[q]=function(C){return new Promise(function(W,ae){l.push([q,C,W,ae])>1||p(q,C)})})}function p(q,C){try{M(s[q](C))}catch(W){E(l[0][3],W)}}function M(q){q.value instanceof Bo?Promise.resolve(q.value.v).then(S,O):E(l[0][2],q)}function S(q){p("next",q)}function O(q){p("throw",q)}function E(q,C){q(C),l.shift(),l.length&&p(l[0][0],l[0][1])}},pv=function(a){var n,i;return n={},s("next"),s("throw",function(o){throw o}),s("return"),n[Symbol.iterator]=function(){return this},n;function s(o,l){n[o]=a[o]?function(c){return(i=!i)?{value:Bo(a[o](c)),done:o==="return"}:l?l(c):c}:l}},fv=function(a){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=a[Symbol.asyncIterator],i;return n?n.call(a):(a=typeof Im=="function"?Im(a):a[Symbol.iterator](),i={},s("next"),s("throw"),s("return"),i[Symbol.asyncIterator]=function(){return this},i);function s(l){i[l]=a[l]&&function(c){return new Promise(function(p,M){c=a[l](c),o(p,M,c.done,c.value)})}}function o(l,c,p,M){Promise.resolve(M).then(function(S){l({value:S,done:p})},c)}},hv=function(a,n){return Object.defineProperty?Object.defineProperty(a,"raw",{value:n}):a.raw=n,a};var t=Object.create?function(a,n){Object.defineProperty(a,"default",{enumerable:!0,value:n})}:function(a,n){a.default=n};yv=function(a){if(a&&a.__esModule)return a;var n={};if(a!=null)for(var i in a)i!=="default"&&Object.prototype.hasOwnProperty.call(a,i)&&Mm(n,a,i);return t(n,a),n},xv=function(a){return a&&a.__esModule?a:{default:a}},gv=function(a,n,i,s){if(i==="a"&&!s)throw new TypeError("Private accessor was defined without a getter");if(typeof n=="function"?a!==n||!s:!n.has(a))throw new TypeError("Cannot read private member from an object whose class did not declare it");return i==="m"?s:i==="a"?s.call(a):s?s.value:n.get(a)},vv=function(a,n,i,s,o){if(s==="m")throw new TypeError("Private method is not writable");if(s==="a"&&!o)throw new TypeError("Private accessor was defined without a setter");if(typeof n=="function"?a!==n||!o:!n.has(a))throw new TypeError("Cannot write private member to an object whose class did not declare it");return s==="a"?o.call(a,i):o?o.value=i:n.set(a,i),i},r("__extends",ev),r("__assign",tv),r("__rest",rv),r("__decorate",av),r("__param",nv),r("__metadata",iv),r("__awaiter",sv),r("__generator",ov),r("__exportStar",lv),r("__createBinding",Mm),r("__values",Im),r("__read",jp),r("__spread",cv),r("__spreadArrays",mv),r("__spreadArray",dv),r("__await",Bo),r("__asyncGenerator",uv),r("__asyncDelegator",pv),r("__asyncValues",fv),r("__makeTemplateObject",hv),r("__importStar",yv),r("__importDefault",xv),r("__classPrivateFieldGet",gv),r("__classPrivateFieldSet",vv)})});var Yv=as((KM,Fm)=>{var Iv,Mv,Av,Bv,Ov,zv,Lv,qv,Hv,Dm,$p,Dv,kv,Fv,Lo,Uv,jv,Vv,Gv,Kv,Xv,$v,Wv,km;(function(r){var e=typeof global=="object"?global:typeof self=="object"?self:typeof this=="object"?this:{};typeof define=="function"&&define.amd?define("tslib",["exports"],function(a){r(t(e,t(a)))}):typeof Fm=="object"&&typeof Fm.exports=="object"?r(t(e,t(Fm.exports))):r(t(e));function t(a,n){return a!==e&&(typeof Object.create=="function"?Object.defineProperty(a,"__esModule",{value:!0}):a.__esModule=!0),function(i,s){return a[i]=n?n(i,s):s}}})(function(r){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,n){a.__proto__=n}||function(a,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(a[i]=n[i])};Iv=function(a,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(a,n);function i(){this.constructor=a}a.prototype=n===null?Object.create(n):(i.prototype=n.prototype,new i)},Mv=Object.assign||function(a){for(var n,i=1,s=arguments.length;i<s;i++){n=arguments[i];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(a[o]=n[o])}return a},Av=function(a,n){var i={};for(var s in a)Object.prototype.hasOwnProperty.call(a,s)&&n.indexOf(s)<0&&(i[s]=a[s]);if(a!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,s=Object.getOwnPropertySymbols(a);o<s.length;o++)n.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(a,s[o])&&(i[s[o]]=a[s[o]]);return i},Bv=function(a,n,i,s){var o=arguments.length,l=o<3?n:s===null?s=Object.getOwnPropertyDescriptor(n,i):s,c;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")l=Reflect.decorate(a,n,i,s);else for(var p=a.length-1;p>=0;p--)(c=a[p])&&(l=(o<3?c(l):o>3?c(n,i,l):c(n,i))||l);return o>3&&l&&Object.defineProperty(n,i,l),l},Ov=function(a,n){return function(i,s){n(i,s,a)}},zv=function(a,n){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(a,n)},Lv=function(a,n,i,s){function o(l){return l instanceof i?l:new i(function(c){c(l)})}return new(i||(i=Promise))(function(l,c){function p(O){try{S(s.next(O))}catch(E){c(E)}}function M(O){try{S(s.throw(O))}catch(E){c(E)}}function S(O){O.done?l(O.value):o(O.value).then(p,M)}S((s=s.apply(a,n||[])).next())})},qv=function(a,n){var i={label:0,sent:function(){if(l[0]&1)throw l[1];return l[1]},trys:[],ops:[]},s,o,l,c;return c={next:p(0),throw:p(1),return:p(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function p(S){return function(O){return M([S,O])}}function M(S){if(s)throw new TypeError("Generator is already executing.");for(;i;)try{if(s=1,o&&(l=S[0]&2?o.return:S[0]?o.throw||((l=o.return)&&l.call(o),0):o.next)&&!(l=l.call(o,S[1])).done)return l;switch(o=0,l&&(S=[S[0]&2,l.value]),S[0]){case 0:case 1:l=S;break;case 4:return i.label++,{value:S[1],done:!1};case 5:i.label++,o=S[1],S=[0];continue;case 7:S=i.ops.pop(),i.trys.pop();continue;default:if(l=i.trys,!(l=l.length>0&&l[l.length-1])&&(S[0]===6||S[0]===2)){i=0;continue}if(S[0]===3&&(!l||S[1]>l[0]&&S[1]<l[3])){i.label=S[1];break}if(S[0]===6&&i.label<l[1]){i.label=l[1],l=S;break}if(l&&i.label<l[2]){i.label=l[2],i.ops.push(S);break}l[2]&&i.ops.pop(),i.trys.pop();continue}S=n.call(a,i)}catch(O){S=[6,O],o=0}finally{s=l=0}if(S[0]&5)throw S[1];return{value:S[0]?S[1]:void 0,done:!0}}},Hv=function(a,n){for(var i in a)i!=="default"&&!Object.prototype.hasOwnProperty.call(n,i)&&km(n,a,i)},km=Object.create?function(a,n,i,s){s===void 0&&(s=i),Object.defineProperty(a,s,{enumerable:!0,get:function(){return n[i]}})}:function(a,n,i,s){s===void 0&&(s=i),a[s]=n[i]},Dm=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,i=n&&a[n],s=0;if(i)return i.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&s>=a.length&&(a=void 0),{value:a&&a[s++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},$p=function(a,n){var i=typeof Symbol=="function"&&a[Symbol.iterator];if(!i)return a;var s=i.call(a),o,l=[],c;try{for(;(n===void 0||n-- >0)&&!(o=s.next()).done;)l.push(o.value)}catch(p){c={error:p}}finally{try{o&&!o.done&&(i=s.return)&&i.call(s)}finally{if(c)throw c.error}}return l},Dv=function(){for(var a=[],n=0;n<arguments.length;n++)a=a.concat($p(arguments[n]));return a},kv=function(){for(var a=0,n=0,i=arguments.length;n<i;n++)a+=arguments[n].length;for(var s=Array(a),o=0,n=0;n<i;n++)for(var l=arguments[n],c=0,p=l.length;c<p;c++,o++)s[o]=l[c];return s},Fv=function(a,n,i){if(i||arguments.length===2)for(var s=0,o=n.length,l;s<o;s++)(l||!(s in n))&&(l||(l=Array.prototype.slice.call(n,0,s)),l[s]=n[s]);return a.concat(l||Array.prototype.slice.call(n))},Lo=function(a){return this instanceof Lo?(this.v=a,this):new Lo(a)},Uv=function(a,n,i){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var s=i.apply(a,n||[]),o,l=[];return o={},c("next"),c("throw"),c("return"),o[Symbol.asyncIterator]=function(){return this},o;function c(q){s[q]&&(o[q]=function(C){return new Promise(function(W,ae){l.push([q,C,W,ae])>1||p(q,C)})})}function p(q,C){try{M(s[q](C))}catch(W){E(l[0][3],W)}}function M(q){q.value instanceof Lo?Promise.resolve(q.value.v).then(S,O):E(l[0][2],q)}function S(q){p("next",q)}function O(q){p("throw",q)}function E(q,C){q(C),l.shift(),l.length&&p(l[0][0],l[0][1])}},jv=function(a){var n,i;return n={},s("next"),s("throw",function(o){throw o}),s("return"),n[Symbol.iterator]=function(){return this},n;function s(o,l){n[o]=a[o]?function(c){return(i=!i)?{value:Lo(a[o](c)),done:o==="return"}:l?l(c):c}:l}},Vv=function(a){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=a[Symbol.asyncIterator],i;return n?n.call(a):(a=typeof Dm=="function"?Dm(a):a[Symbol.iterator](),i={},s("next"),s("throw"),s("return"),i[Symbol.asyncIterator]=function(){return this},i);function s(l){i[l]=a[l]&&function(c){return new Promise(function(p,M){c=a[l](c),o(p,M,c.done,c.value)})}}function o(l,c,p,M){Promise.resolve(M).then(function(S){l({value:S,done:p})},c)}},Gv=function(a,n){return Object.defineProperty?Object.defineProperty(a,"raw",{value:n}):a.raw=n,a};var t=Object.create?function(a,n){Object.defineProperty(a,"default",{enumerable:!0,value:n})}:function(a,n){a.default=n};Kv=function(a){if(a&&a.__esModule)return a;var n={};if(a!=null)for(var i in a)i!=="default"&&Object.prototype.hasOwnProperty.call(a,i)&&km(n,a,i);return t(n,a),n},Xv=function(a){return a&&a.__esModule?a:{default:a}},$v=function(a,n,i,s){if(i==="a"&&!s)throw new TypeError("Private accessor was defined without a getter");if(typeof n=="function"?a!==n||!s:!n.has(a))throw new TypeError("Cannot read private member from an object whose class did not declare it");return i==="m"?s:i==="a"?s.call(a):s?s.value:n.get(a)},Wv=function(a,n,i,s,o){if(s==="m")throw new TypeError("Private method is not writable");if(s==="a"&&!o)throw new TypeError("Private accessor was defined without a setter");if(typeof n=="function"?a!==n||!o:!n.has(a))throw new TypeError("Cannot write private member to an object whose class did not declare it");return s==="a"?o.call(a,i):o?o.value=i:n.set(a,i),i},r("__extends",Iv),r("__assign",Mv),r("__rest",Av),r("__decorate",Bv),r("__param",Ov),r("__metadata",zv),r("__awaiter",Lv),r("__generator",qv),r("__exportStar",Hv),r("__createBinding",km),r("__values",Dm),r("__read",$p),r("__spread",Dv),r("__spreadArrays",kv),r("__spreadArray",Fv),r("__await",Lo),r("__asyncGenerator",Uv),r("__asyncDelegator",jv),r("__asyncValues",Vv),r("__makeTemplateObject",Gv),r("__importStar",Kv),r("__importDefault",Xv),r("__classPrivateFieldGet",$v),r("__classPrivateFieldSet",Wv)})});var wb=as((_9,id)=>{var cb,mb,db,ub,pb,fb,hb,yb,xb,ad,F0,gb,vb,_b,Uo,bb,Sb,Nb,Pb,Cb,Rb,Eb,Tb,nd;(function(r){var e=typeof global=="object"?global:typeof self=="object"?self:typeof this=="object"?this:{};typeof define=="function"&&define.amd?define("tslib",["exports"],function(a){r(t(e,t(a)))}):typeof id=="object"&&typeof id.exports=="object"?r(t(e,t(id.exports))):r(t(e));function t(a,n){return a!==e&&(typeof Object.create=="function"?Object.defineProperty(a,"__esModule",{value:!0}):a.__esModule=!0),function(i,s){return a[i]=n?n(i,s):s}}})(function(r){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,n){a.__proto__=n}||function(a,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(a[i]=n[i])};cb=function(a,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(a,n);function i(){this.constructor=a}a.prototype=n===null?Object.create(n):(i.prototype=n.prototype,new i)},mb=Object.assign||function(a){for(var n,i=1,s=arguments.length;i<s;i++){n=arguments[i];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(a[o]=n[o])}return a},db=function(a,n){var i={};for(var s in a)Object.prototype.hasOwnProperty.call(a,s)&&n.indexOf(s)<0&&(i[s]=a[s]);if(a!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,s=Object.getOwnPropertySymbols(a);o<s.length;o++)n.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(a,s[o])&&(i[s[o]]=a[s[o]]);return i},ub=function(a,n,i,s){var o=arguments.length,l=o<3?n:s===null?s=Object.getOwnPropertyDescriptor(n,i):s,c;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")l=Reflect.decorate(a,n,i,s);else for(var p=a.length-1;p>=0;p--)(c=a[p])&&(l=(o<3?c(l):o>3?c(n,i,l):c(n,i))||l);return o>3&&l&&Object.defineProperty(n,i,l),l},pb=function(a,n){return function(i,s){n(i,s,a)}},fb=function(a,n){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(a,n)},hb=function(a,n,i,s){function o(l){return l instanceof i?l:new i(function(c){c(l)})}return new(i||(i=Promise))(function(l,c){function p(O){try{S(s.next(O))}catch(E){c(E)}}function M(O){try{S(s.throw(O))}catch(E){c(E)}}function S(O){O.done?l(O.value):o(O.value).then(p,M)}S((s=s.apply(a,n||[])).next())})},yb=function(a,n){var i={label:0,sent:function(){if(l[0]&1)throw l[1];return l[1]},trys:[],ops:[]},s,o,l,c;return c={next:p(0),throw:p(1),return:p(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function p(S){return function(O){return M([S,O])}}function M(S){if(s)throw new TypeError("Generator is already executing.");for(;i;)try{if(s=1,o&&(l=S[0]&2?o.return:S[0]?o.throw||((l=o.return)&&l.call(o),0):o.next)&&!(l=l.call(o,S[1])).done)return l;switch(o=0,l&&(S=[S[0]&2,l.value]),S[0]){case 0:case 1:l=S;break;case 4:return i.label++,{value:S[1],done:!1};case 5:i.label++,o=S[1],S=[0];continue;case 7:S=i.ops.pop(),i.trys.pop();continue;default:if(l=i.trys,!(l=l.length>0&&l[l.length-1])&&(S[0]===6||S[0]===2)){i=0;continue}if(S[0]===3&&(!l||S[1]>l[0]&&S[1]<l[3])){i.label=S[1];break}if(S[0]===6&&i.label<l[1]){i.label=l[1],l=S;break}if(l&&i.label<l[2]){i.label=l[2],i.ops.push(S);break}l[2]&&i.ops.pop(),i.trys.pop();continue}S=n.call(a,i)}catch(O){S=[6,O],o=0}finally{s=l=0}if(S[0]&5)throw S[1];return{value:S[0]?S[1]:void 0,done:!0}}},xb=function(a,n){for(var i in a)i!=="default"&&!Object.prototype.hasOwnProperty.call(n,i)&&nd(n,a,i)},nd=Object.create?function(a,n,i,s){s===void 0&&(s=i),Object.defineProperty(a,s,{enumerable:!0,get:function(){return n[i]}})}:function(a,n,i,s){s===void 0&&(s=i),a[s]=n[i]},ad=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,i=n&&a[n],s=0;if(i)return i.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&s>=a.length&&(a=void 0),{value:a&&a[s++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},F0=function(a,n){var i=typeof Symbol=="function"&&a[Symbol.iterator];if(!i)return a;var s=i.call(a),o,l=[],c;try{for(;(n===void 0||n-- >0)&&!(o=s.next()).done;)l.push(o.value)}catch(p){c={error:p}}finally{try{o&&!o.done&&(i=s.return)&&i.call(s)}finally{if(c)throw c.error}}return l},gb=function(){for(var a=[],n=0;n<arguments.length;n++)a=a.concat(F0(arguments[n]));return a},vb=function(){for(var a=0,n=0,i=arguments.length;n<i;n++)a+=arguments[n].length;for(var s=Array(a),o=0,n=0;n<i;n++)for(var l=arguments[n],c=0,p=l.length;c<p;c++,o++)s[o]=l[c];return s},_b=function(a,n,i){if(i||arguments.length===2)for(var s=0,o=n.length,l;s<o;s++)(l||!(s in n))&&(l||(l=Array.prototype.slice.call(n,0,s)),l[s]=n[s]);return a.concat(l||Array.prototype.slice.call(n))},Uo=function(a){return this instanceof Uo?(this.v=a,this):new Uo(a)},bb=function(a,n,i){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var s=i.apply(a,n||[]),o,l=[];return o={},c("next"),c("throw"),c("return"),o[Symbol.asyncIterator]=function(){return this},o;function c(q){s[q]&&(o[q]=function(C){return new Promise(function(W,ae){l.push([q,C,W,ae])>1||p(q,C)})})}function p(q,C){try{M(s[q](C))}catch(W){E(l[0][3],W)}}function M(q){q.value instanceof Uo?Promise.resolve(q.value.v).then(S,O):E(l[0][2],q)}function S(q){p("next",q)}function O(q){p("throw",q)}function E(q,C){q(C),l.shift(),l.length&&p(l[0][0],l[0][1])}},Sb=function(a){var n,i;return n={},s("next"),s("throw",function(o){throw o}),s("return"),n[Symbol.iterator]=function(){return this},n;function s(o,l){n[o]=a[o]?function(c){return(i=!i)?{value:Uo(a[o](c)),done:o==="return"}:l?l(c):c}:l}},Nb=function(a){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=a[Symbol.asyncIterator],i;return n?n.call(a):(a=typeof ad=="function"?ad(a):a[Symbol.iterator](),i={},s("next"),s("throw"),s("return"),i[Symbol.asyncIterator]=function(){return this},i);function s(l){i[l]=a[l]&&function(c){return new Promise(function(p,M){c=a[l](c),o(p,M,c.done,c.value)})}}function o(l,c,p,M){Promise.resolve(M).then(function(S){l({value:S,done:p})},c)}},Pb=function(a,n){return Object.defineProperty?Object.defineProperty(a,"raw",{value:n}):a.raw=n,a};var t=Object.create?function(a,n){Object.defineProperty(a,"default",{enumerable:!0,value:n})}:function(a,n){a.default=n};Cb=function(a){if(a&&a.__esModule)return a;var n={};if(a!=null)for(var i in a)i!=="default"&&Object.prototype.hasOwnProperty.call(a,i)&&nd(n,a,i);return t(n,a),n},Rb=function(a){return a&&a.__esModule?a:{default:a}},Eb=function(a,n,i,s){if(i==="a"&&!s)throw new TypeError("Private accessor was defined without a getter");if(typeof n=="function"?a!==n||!s:!n.has(a))throw new TypeError("Cannot read private member from an object whose class did not declare it");return i==="m"?s:i==="a"?s.call(a):s?s.value:n.get(a)},Tb=function(a,n,i,s,o){if(s==="m")throw new TypeError("Private method is not writable");if(s==="a"&&!o)throw new TypeError("Private accessor was defined without a setter");if(typeof n=="function"?a!==n||!o:!n.has(a))throw new TypeError("Cannot write private member to an object whose class did not declare it");return s==="a"?o.call(a,i):o?o.value=i:n.set(a,i),i},r("__extends",cb),r("__assign",mb),r("__rest",db),r("__decorate",ub),r("__param",pb),r("__metadata",fb),r("__awaiter",hb),r("__generator",yb),r("__exportStar",xb),r("__createBinding",nd),r("__values",ad),r("__read",F0),r("__spread",gb),r("__spreadArrays",vb),r("__spreadArray",_b),r("__await",Uo),r("__asyncGenerator",bb),r("__asyncDelegator",Sb),r("__asyncValues",Nb),r("__makeTemplateObject",Pb),r("__importStar",Cb),r("__importDefault",Rb),r("__classPrivateFieldGet",Eb),r("__classPrivateFieldSet",Tb)})});var D2=as(()=>{});var eS=as((qz,X1)=>{"use strict";var rl=typeof Reflect=="object"?Reflect:null,V2=rl&&typeof rl.apply=="function"?rl.apply:function(e,t,a){return Function.prototype.apply.call(e,t,a)},nu;rl&&typeof rl.ownKeys=="function"?nu=rl.ownKeys:Object.getOwnPropertySymbols?nu=function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:nu=function(e){return Object.getOwnPropertyNames(e)};function yT(r){console&&console.warn&&console.warn(r)}var K2=Number.isNaN||function(e){return e!==e};function nr(){nr.init.call(this)}X1.exports=nr;X1.exports.once=_T;nr.EventEmitter=nr;nr.prototype._events=void 0;nr.prototype._eventsCount=0;nr.prototype._maxListeners=void 0;var G2=10;function iu(r){if(typeof r!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof r)}Object.defineProperty(nr,"defaultMaxListeners",{enumerable:!0,get:function(){return G2},set:function(r){if(typeof r!="number"||r<0||K2(r))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+r+".");G2=r}});nr.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0};nr.prototype.setMaxListeners=function(e){if(typeof e!="number"||e<0||K2(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this};function X2(r){return r._maxListeners===void 0?nr.defaultMaxListeners:r._maxListeners}nr.prototype.getMaxListeners=function(){return X2(this)};nr.prototype.emit=function(e){for(var t=[],a=1;a<arguments.length;a++)t.push(arguments[a]);var n=e==="error",i=this._events;if(i!==void 0)n=n&&i.error===void 0;else if(!n)return!1;if(n){var s;if(t.length>0&&(s=t[0]),s instanceof Error)throw s;var o=new Error("Unhandled error."+(s?" ("+s.message+")":""));throw o.context=s,o}var l=i[e];if(l===void 0)return!1;if(typeof l=="function")V2(l,this,t);else for(var c=l.length,p=Z2(l,c),a=0;a<c;++a)V2(p[a],this,t);return!0};function $2(r,e,t,a){var n,i,s;if(iu(t),i=r._events,i===void 0?(i=r._events=Object.create(null),r._eventsCount=0):(i.newListener!==void 0&&(r.emit("newListener",e,t.listener?t.listener:t),i=r._events),s=i[e]),s===void 0)s=i[e]=t,++r._eventsCount;else if(typeof s=="function"?s=i[e]=a?[t,s]:[s,t]:a?s.unshift(t):s.push(t),n=X2(r),n>0&&s.length>n&&!s.warned){s.warned=!0;var o=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");o.name="MaxListenersExceededWarning",o.emitter=r,o.type=e,o.count=s.length,yT(o)}return r}nr.prototype.addListener=function(e,t){return $2(this,e,t,!1)};nr.prototype.on=nr.prototype.addListener;nr.prototype.prependListener=function(e,t){return $2(this,e,t,!0)};function xT(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function W2(r,e,t){var a={fired:!1,wrapFn:void 0,target:r,type:e,listener:t},n=xT.bind(a);return n.listener=t,a.wrapFn=n,n}nr.prototype.once=function(e,t){return iu(t),this.on(e,W2(this,e,t)),this};nr.prototype.prependOnceListener=function(e,t){return iu(t),this.prependListener(e,W2(this,e,t)),this};nr.prototype.removeListener=function(e,t){var a,n,i,s,o;if(iu(t),n=this._events,n===void 0)return this;if(a=n[e],a===void 0)return this;if(a===t||a.listener===t)--this._eventsCount===0?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit("removeListener",e,a.listener||t));else if(typeof a!="function"){for(i=-1,s=a.length-1;s>=0;s--)if(a[s]===t||a[s].listener===t){o=a[s].listener,i=s;break}if(i<0)return this;i===0?a.shift():gT(a,i),a.length===1&&(n[e]=a[0]),n.removeListener!==void 0&&this.emit("removeListener",e,o||t)}return this};nr.prototype.off=nr.prototype.removeListener;nr.prototype.removeAllListeners=function(e){var t,a,n;if(a=this._events,a===void 0)return this;if(a.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):a[e]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete a[e]),this;if(arguments.length===0){var i=Object.keys(a),s;for(n=0;n<i.length;++n)s=i[n],s!=="removeListener"&&this.removeAllListeners(s);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(t=a[e],typeof t=="function")this.removeListener(e,t);else if(t!==void 0)for(n=t.length-1;n>=0;n--)this.removeListener(e,t[n]);return this};function Y2(r,e,t){var a=r._events;if(a===void 0)return[];var n=a[e];return n===void 0?[]:typeof n=="function"?t?[n.listener||n]:[n]:t?vT(n):Z2(n,n.length)}nr.prototype.listeners=function(e){return Y2(this,e,!0)};nr.prototype.rawListeners=function(e){return Y2(this,e,!1)};nr.listenerCount=function(r,e){return typeof r.listenerCount=="function"?r.listenerCount(e):Q2.call(r,e)};nr.prototype.listenerCount=Q2;function Q2(r){var e=this._events;if(e!==void 0){var t=e[r];if(typeof t=="function")return 1;if(t!==void 0)return t.length}return 0}nr.prototype.eventNames=function(){return this._eventsCount>0?nu(this._events):[]};function Z2(r,e){for(var t=new Array(e),a=0;a<e;++a)t[a]=r[a];return t}function gT(r,e){for(;e+1<r.length;e++)r[e]=r[e+1];r.pop()}function vT(r){for(var e=new Array(r.length),t=0;t<e.length;++t)e[t]=r[t].listener||r[t];return e}function _T(r,e){return new Promise(function(t,a){function n(s){r.removeListener(e,i),a(s)}function i(){typeof r.removeListener=="function"&&r.removeListener("error",n),t([].slice.call(arguments))}J2(r,e,i,{once:!0}),e!=="error"&&bT(r,n,{once:!0})})}function bT(r,e,t){typeof r.on=="function"&&J2(r,"error",e,t)}function J2(r,e,t,a){if(typeof r.on=="function")a.once?r.once(e,t):r.on(e,t);else if(typeof r.addEventListener=="function")r.addEventListener(e,function n(i){a.once&&r.removeEventListener(e,n),t(i)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof r)}});var wS=as((rq,pu)=>{var cS,mS,dS,uS,pS,fS,hS,yS,xS,du,ry,gS,vS,_S,sl,bS,SS,NS,PS,CS,RS,ES,TS,uu;(function(r){var e=typeof global=="object"?global:typeof self=="object"?self:typeof this=="object"?this:{};typeof define=="function"&&define.amd?define("tslib",["exports"],function(a){r(t(e,t(a)))}):typeof pu=="object"&&typeof pu.exports=="object"?r(t(e,t(pu.exports))):r(t(e));function t(a,n){return a!==e&&(typeof Object.create=="function"?Object.defineProperty(a,"__esModule",{value:!0}):a.__esModule=!0),function(i,s){return a[i]=n?n(i,s):s}}})(function(r){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,n){a.__proto__=n}||function(a,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(a[i]=n[i])};cS=function(a,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(a,n);function i(){this.constructor=a}a.prototype=n===null?Object.create(n):(i.prototype=n.prototype,new i)},mS=Object.assign||function(a){for(var n,i=1,s=arguments.length;i<s;i++){n=arguments[i];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(a[o]=n[o])}return a},dS=function(a,n){var i={};for(var s in a)Object.prototype.hasOwnProperty.call(a,s)&&n.indexOf(s)<0&&(i[s]=a[s]);if(a!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,s=Object.getOwnPropertySymbols(a);o<s.length;o++)n.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(a,s[o])&&(i[s[o]]=a[s[o]]);return i},uS=function(a,n,i,s){var o=arguments.length,l=o<3?n:s===null?s=Object.getOwnPropertyDescriptor(n,i):s,c;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")l=Reflect.decorate(a,n,i,s);else for(var p=a.length-1;p>=0;p--)(c=a[p])&&(l=(o<3?c(l):o>3?c(n,i,l):c(n,i))||l);return o>3&&l&&Object.defineProperty(n,i,l),l},pS=function(a,n){return function(i,s){n(i,s,a)}},fS=function(a,n){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(a,n)},hS=function(a,n,i,s){function o(l){return l instanceof i?l:new i(function(c){c(l)})}return new(i||(i=Promise))(function(l,c){function p(O){try{S(s.next(O))}catch(E){c(E)}}function M(O){try{S(s.throw(O))}catch(E){c(E)}}function S(O){O.done?l(O.value):o(O.value).then(p,M)}S((s=s.apply(a,n||[])).next())})},yS=function(a,n){var i={label:0,sent:function(){if(l[0]&1)throw l[1];return l[1]},trys:[],ops:[]},s,o,l,c;return c={next:p(0),throw:p(1),return:p(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function p(S){return function(O){return M([S,O])}}function M(S){if(s)throw new TypeError("Generator is already executing.");for(;i;)try{if(s=1,o&&(l=S[0]&2?o.return:S[0]?o.throw||((l=o.return)&&l.call(o),0):o.next)&&!(l=l.call(o,S[1])).done)return l;switch(o=0,l&&(S=[S[0]&2,l.value]),S[0]){case 0:case 1:l=S;break;case 4:return i.label++,{value:S[1],done:!1};case 5:i.label++,o=S[1],S=[0];continue;case 7:S=i.ops.pop(),i.trys.pop();continue;default:if(l=i.trys,!(l=l.length>0&&l[l.length-1])&&(S[0]===6||S[0]===2)){i=0;continue}if(S[0]===3&&(!l||S[1]>l[0]&&S[1]<l[3])){i.label=S[1];break}if(S[0]===6&&i.label<l[1]){i.label=l[1],l=S;break}if(l&&i.label<l[2]){i.label=l[2],i.ops.push(S);break}l[2]&&i.ops.pop(),i.trys.pop();continue}S=n.call(a,i)}catch(O){S=[6,O],o=0}finally{s=l=0}if(S[0]&5)throw S[1];return{value:S[0]?S[1]:void 0,done:!0}}},xS=function(a,n){for(var i in a)i!=="default"&&!Object.prototype.hasOwnProperty.call(n,i)&&uu(n,a,i)},uu=Object.create?function(a,n,i,s){s===void 0&&(s=i),Object.defineProperty(a,s,{enumerable:!0,get:function(){return n[i]}})}:function(a,n,i,s){s===void 0&&(s=i),a[s]=n[i]},du=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,i=n&&a[n],s=0;if(i)return i.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&s>=a.length&&(a=void 0),{value:a&&a[s++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},ry=function(a,n){var i=typeof Symbol=="function"&&a[Symbol.iterator];if(!i)return a;var s=i.call(a),o,l=[],c;try{for(;(n===void 0||n-- >0)&&!(o=s.next()).done;)l.push(o.value)}catch(p){c={error:p}}finally{try{o&&!o.done&&(i=s.return)&&i.call(s)}finally{if(c)throw c.error}}return l},gS=function(){for(var a=[],n=0;n<arguments.length;n++)a=a.concat(ry(arguments[n]));return a},vS=function(){for(var a=0,n=0,i=arguments.length;n<i;n++)a+=arguments[n].length;for(var s=Array(a),o=0,n=0;n<i;n++)for(var l=arguments[n],c=0,p=l.length;c<p;c++,o++)s[o]=l[c];return s},_S=function(a,n,i){if(i||arguments.length===2)for(var s=0,o=n.length,l;s<o;s++)(l||!(s in n))&&(l||(l=Array.prototype.slice.call(n,0,s)),l[s]=n[s]);return a.concat(l||Array.prototype.slice.call(n))},sl=function(a){return this instanceof sl?(this.v=a,this):new sl(a)},bS=function(a,n,i){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var s=i.apply(a,n||[]),o,l=[];return o={},c("next"),c("throw"),c("return"),o[Symbol.asyncIterator]=function(){return this},o;function c(q){s[q]&&(o[q]=function(C){return new Promise(function(W,ae){l.push([q,C,W,ae])>1||p(q,C)})})}function p(q,C){try{M(s[q](C))}catch(W){E(l[0][3],W)}}function M(q){q.value instanceof sl?Promise.resolve(q.value.v).then(S,O):E(l[0][2],q)}function S(q){p("next",q)}function O(q){p("throw",q)}function E(q,C){q(C),l.shift(),l.length&&p(l[0][0],l[0][1])}},SS=function(a){var n,i;return n={},s("next"),s("throw",function(o){throw o}),s("return"),n[Symbol.iterator]=function(){return this},n;function s(o,l){n[o]=a[o]?function(c){return(i=!i)?{value:sl(a[o](c)),done:o==="return"}:l?l(c):c}:l}},NS=function(a){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=a[Symbol.asyncIterator],i;return n?n.call(a):(a=typeof du=="function"?du(a):a[Symbol.iterator](),i={},s("next"),s("throw"),s("return"),i[Symbol.asyncIterator]=function(){return this},i);function s(l){i[l]=a[l]&&function(c){return new Promise(function(p,M){c=a[l](c),o(p,M,c.done,c.value)})}}function o(l,c,p,M){Promise.resolve(M).then(function(S){l({value:S,done:p})},c)}},PS=function(a,n){return Object.defineProperty?Object.defineProperty(a,"raw",{value:n}):a.raw=n,a};var t=Object.create?function(a,n){Object.defineProperty(a,"default",{enumerable:!0,value:n})}:function(a,n){a.default=n};CS=function(a){if(a&&a.__esModule)return a;var n={};if(a!=null)for(var i in a)i!=="default"&&Object.prototype.hasOwnProperty.call(a,i)&&uu(n,a,i);return t(n,a),n},RS=function(a){return a&&a.__esModule?a:{default:a}},ES=function(a,n,i,s){if(i==="a"&&!s)throw new TypeError("Private accessor was defined without a getter");if(typeof n=="function"?a!==n||!s:!n.has(a))throw new TypeError("Cannot read private member from an object whose class did not declare it");return i==="m"?s:i==="a"?s.call(a):s?s.value:n.get(a)},TS=function(a,n,i,s,o){if(s==="m")throw new TypeError("Private method is not writable");if(s==="a"&&!o)throw new TypeError("Private accessor was defined without a setter");if(typeof n=="function"?a!==n||!o:!n.has(a))throw new TypeError("Cannot write private member to an object whose class did not declare it");return s==="a"?o.call(a,i):o?o.value=i:n.set(a,i),i},r("__extends",cS),r("__assign",mS),r("__rest",dS),r("__decorate",uS),r("__param",pS),r("__metadata",fS),r("__awaiter",hS),r("__generator",yS),r("__exportStar",xS),r("__createBinding",uu),r("__values",du),r("__read",ry),r("__spread",gS),r("__spreadArrays",vS),r("__spreadArray",_S),r("__await",sl),r("__asyncGenerator",bS),r("__asyncDelegator",SS),r("__asyncValues",NS),r("__makeTemplateObject",PS),r("__importStar",CS),r("__importDefault",RS),r("__classPrivateFieldGet",ES),r("__classPrivateFieldSet",TS)})});var VP=as((PG,jP)=>{jP.exports=typeof self=="object"?self.FormData:window.FormData});function Jl(r,e){let t,a={mimeType:"video/webm;codecs=vp9",videoBitsPerSecond:128e3,audioBitsPerSecond:64e3},n=new MediaRecorder(r,a);n.ondataavailable=s=>{s.data.size>0&&e.push(s.data),t&&t()},n.start();function i(){return new Promise(s=>{n.state=="recording"?(t=s,n.stop(),r.getTracks().forEach(o=>{o.stop()})):s()})}return i}async function wp(r,e={cameraId:void 0,microphoneId:void 0},t={width:640,height:480}){let{cameraId:a,microphoneId:n}=e,i={audio:{deviceId:n},video:{deviceId:a,width:t.width,height:t.height,frameRate:15}},s=await navigator.mediaDevices.getUserMedia(i),o=Jl(s,r);return{cameraStream:s,stopCameraRecording:o}}var Og=ns(Bg()),Ap;function zg(){let r=new Og.default({bitRate:128});function e(){r.start().then(()=>{}).catch(a=>{console.error(a)})}async function t(){return await r.stop().getMp3().then(async([n,i])=>({buffer:n,blob:i})).catch(n=>{alert("We could not retrieve your message"),console.log(n)})}return Ap=t,{start:e,stop:t}}var Lg="script_not_called_inside_body",qg="incompatible_navigator",Hg="required_field_not_provided",Dg="not_shared_first_screen",ec="multiple_monitors_detected",Cm="proctoring_already_started",js="proctoring_not_started",kg="proctoring_running",Fg="no_videos_recorded";async function Bp(r,e){let{allowOnlyFirstMonitor:t,onStopSharingScreenCallback:a}=e,n={video:{cursor:"always"},audio:!1},i=await navigator.mediaDevices.getDisplayMedia(n),s=i.getVideoTracks();if(s[0].onended=a,navigator.userAgent.indexOf("Firefox")>-1&&!s.find(M=>M.label=="Primary Monitor")&&t)throw ec;if(!(s.find(p=>["screen:0:0","Primary Monitor"].includes(p.label))!=null)&&t)throw s.forEach(p=>{p.stop()}),Dg;let c=Jl(i,r);return{screenStream:i,stopScreenRecorder:c}}function Rm(r){return r.toLowerCase()}function Op(r){if(r&&typeof r=="object"){let e=r;if(typeof e.rawHeaders=="function"&&typeof e.clone=="function"&&typeof e.get=="function"&&typeof e.set=="function"&&typeof e.contains=="function"&&typeof e.remove=="function"&&typeof e.headersArray=="function"&&typeof e.headerValues=="function"&&typeof e.headerNames=="function"&&typeof e.toJson=="function")return!0}return!1}var Kr=class{constructor(e){if(this._headersMap={},e)for(let t in e)this.set(t,e[t])}set(e,t){this._headersMap[Rm(e)]={name:e,value:t.toString()}}get(e){let t=this._headersMap[Rm(e)];return t?t.value:void 0}contains(e){return!!this._headersMap[Rm(e)]}remove(e){let t=this.contains(e);return delete this._headersMap[Rm(e)],t}rawHeaders(){let e={};for(let t in this._headersMap){let a=this._headersMap[t];e[a.name.toLowerCase()]=a.value}return e}headersArray(){let e=[];for(let t in this._headersMap)e.push(this._headersMap[t]);return e}headerNames(){let e=[],t=this.headersArray();for(let a=0;a<t.length;++a)e.push(t[a].name);return e}headerValues(){let e=[],t=this.headersArray();for(let a=0;a<t.length;++a)e.push(t[a].value);return e}toJson(){return this.rawHeaders()}toString(){return JSON.stringify(this.toJson())}clone(){let e={};for(let t in this._headersMap){let a=this._headersMap[t];e[a.name]=a.value}return new Kr(e)}};function zp(r){let e="";for(let t=0;t<r.length;t++)e+=String.fromCharCode(r[t]);return btoa(e)}function Lp(r){let e=atob(r),t=new Uint8Array(e.length);for(let a=0;a<e.length;a++)t[a]=e.charCodeAt(a);return t}var Em,MC=new Uint8Array(16);function qp(){if(!Em&&(Em=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto),!Em))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Em(MC)}var Ug=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function AC(r){return typeof r=="string"&&Ug.test(r)}var jg=AC;var la=[];for(Tm=0;Tm<256;++Tm)la.push((Tm+256).toString(16).substr(1));var Tm;function BC(r){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,t=(la[r[e+0]]+la[r[e+1]]+la[r[e+2]]+la[r[e+3]]+"-"+la[r[e+4]]+la[r[e+5]]+"-"+la[r[e+6]]+la[r[e+7]]+"-"+la[r[e+8]]+la[r[e+9]]+"-"+la[r[e+10]]+la[r[e+11]]+la[r[e+12]]+la[r[e+13]]+la[r[e+14]]+la[r[e+15]]).toLowerCase();if(!jg(t))throw TypeError("Stringified UUID is invalid");return t}var Vg=BC;function OC(r,e,t){r=r||{};var a=r.random||(r.rng||qp)();if(a[6]=a[6]&15|64,a[8]=a[8]&63|128,e){t=t||0;for(var n=0;n<16;++n)e[t+n]=a[n];return e}return Vg(a)}var Hp=OC;var Ai={coreHttpVersion:"2.2.2",HTTP:"http:",HTTPS:"https:",HTTP_PROXY:"HTTP_PROXY",HTTPS_PROXY:"HTTPS_PROXY",NO_PROXY:"NO_PROXY",ALL_PROXY:"ALL_PROXY",HttpConstants:{HttpVerbs:{PUT:"PUT",GET:"GET",DELETE:"DELETE",POST:"POST",MERGE:"MERGE",HEAD:"HEAD",PATCH:"PATCH"},StatusCodes:{TooManyRequests:429,ServiceUnavailable:503}},HeaderConstants:{AUTHORIZATION:"authorization",AUTHORIZATION_SCHEME:"Bearer",RETRY_AFTER:"Retry-After",USER_AGENT:"User-Agent"}};var vr="$",Mn="_";var zC=/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/i,Lt=typeof process<"u"&&!!process.version&&!!process.versions&&!!process.versions.node;function Dp(r){return zC.test(r)}function Ka(){return Hp()}function Gg(r,e,t,a){if(Array.isArray(r)||(r=[r]),!t||!a)return{[e]:r};let n={[e]:r};return n[vr]={[t]:a},n}var LC=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function kp(r){return LC.test(r)}function Ao(r,e,t){return!r||!e?r:r.split(e).join(t||"")}function Kg(r){return typeof r!="object"&&typeof r!="function"||r===null}function Xg(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)&&!(r instanceof RegExp)&&!(r instanceof Date)}var kr=class{constructor(e={},t){this.modelMappers=e,this.isXML=t}validateConstraints(e,t,a){let n=(i,s)=>{throw new Error(`"${a}" with value "${t}" should satisfy the constraint "${i}": ${s}.`)};if(e.constraints&&t!=null){let i=t,{ExclusiveMaximum:s,ExclusiveMinimum:o,InclusiveMaximum:l,InclusiveMinimum:c,MaxItems:p,MaxLength:M,MinItems:S,MinLength:O,MultipleOf:E,Pattern:q,UniqueItems:C}=e.constraints;s!=null&&i>=s&&n("ExclusiveMaximum",s),o!=null&&i<=o&&n("ExclusiveMinimum",o),l!=null&&i>l&&n("InclusiveMaximum",l),c!=null&&i<c&&n("InclusiveMinimum",c);let W=t;if(p!=null&&W.length>p&&n("MaxItems",p),M!=null&&W.length>M&&n("MaxLength",M),S!=null&&W.length<S&&n("MinItems",S),O!=null&&W.length<O&&n("MinLength",O),E!=null&&i%E!==0&&n("MultipleOf",E),q){let ae=typeof q=="string"?new RegExp(q):q;(typeof t!="string"||t.match(ae)===null)&&n("Pattern",q)}C&&W.some((ae,Ce,et)=>et.indexOf(ae)!==Ce)&&n("UniqueItems",C)}}serialize(e,t,a,n={}){var i,s,o;let l={rootName:(i=n.rootName)!==null&&i!==void 0?i:"",includeRoot:(s=n.includeRoot)!==null&&s!==void 0?s:!1,xmlCharKey:(o=n.xmlCharKey)!==null&&o!==void 0?o:Mn},c={},p=e.type.name;a||(a=e.serializedName),p.match(/^Sequence$/i)!==null&&(c=[]),e.isConstant&&(t=e.defaultValue);let{required:M,nullable:S}=e;if(M&&S&&t===void 0)throw new Error(`${a} cannot be undefined.`);if(M&&!S&&t==null)throw new Error(`${a} cannot be null or undefined.`);if(!M&&S===!1&&t===null)throw new Error(`${a} cannot be null.`);return t==null?c=t:(this.validateConstraints(e,t,a),p.match(/^any$/i)!==null?c=t:p.match(/^(Number|String|Boolean|Object|Stream|Uuid)$/i)!==null?c=UC(p,a,t):p.match(/^Enum$/i)!==null?c=jC(a,e.type.allowedValues,t):p.match(/^(Date|DateTime|TimeSpan|DateTimeRfc1123|UnixTime)$/i)!==null?c=KC(p,t,a):p.match(/^ByteArray$/i)!==null?c=VC(a,t):p.match(/^Base64Url$/i)!==null?c=GC(a,t):p.match(/^Sequence$/i)!==null?c=XC(this,e,t,a,Boolean(this.isXML),l):p.match(/^Dictionary$/i)!==null?c=$C(this,e,t,a,Boolean(this.isXML),l):p.match(/^Composite$/i)!==null&&(c=YC(this,e,t,a,Boolean(this.isXML),l))),c}deserialize(e,t,a,n={}){var i,s,o;let l={rootName:(i=n.rootName)!==null&&i!==void 0?i:"",includeRoot:(s=n.includeRoot)!==null&&s!==void 0?s:!1,xmlCharKey:(o=n.xmlCharKey)!==null&&o!==void 0?o:Mn};if(t==null)return this.isXML&&e.type.name==="Sequence"&&!e.xmlIsWrapped&&(t=[]),e.defaultValue!==void 0&&(t=e.defaultValue),t;let c,p=e.type.name;if(a||(a=e.serializedName),p.match(/^Composite$/i)!==null)c=ZC(this,e,t,a,l);else{if(this.isXML){let M=l.xmlCharKey,S=t;S[vr]!=null&&S[M]!=null&&(t=S[M])}p.match(/^Number$/i)!==null?(c=parseFloat(t),isNaN(c)&&(c=t)):p.match(/^Boolean$/i)!==null?t==="true"?c=!0:t==="false"?c=!1:c=t:p.match(/^(String|Enum|Object|Stream|Uuid|TimeSpan|any)$/i)!==null?c=t:p.match(/^(Date|DateTime|DateTimeRfc1123)$/i)!==null?c=new Date(t):p.match(/^UnixTime$/i)!==null?c=FC(t):p.match(/^ByteArray$/i)!==null?c=Lp(t):p.match(/^Base64Url$/i)!==null?c=DC(t):p.match(/^Sequence$/i)!==null?c=eR(this,e,t,a,l):p.match(/^Dictionary$/i)!==null&&(c=JC(this,e,t,a,l))}return e.isConstant&&(c=e.defaultValue),c}};function qC(r,e){let t=r.length;for(;t-1>=0&&r[t-1]===e;)--t;return r.substr(0,t)}function HC(r){if(!r)return;if(!(r instanceof Uint8Array))throw new Error("Please provide an input of type Uint8Array for converting to Base64Url.");let e=zp(r);return qC(e,"=").replace(/\+/g,"-").replace(/\//g,"_")}function DC(r){if(!!r){if(r&&typeof r.valueOf()!="string")throw new Error("Please provide an input of type string for converting to Uint8Array");return r=r.replace(/-/g,"+").replace(/_/g,"/"),Lp(r)}}function Up(r){let e=[],t="";if(r){let a=r.split(".");for(let n of a)n.charAt(n.length-1)==="\\"?t+=n.substr(0,n.length-1)+".":(t+=n,e.push(t),t="")}return e}function kC(r){if(!!r)return typeof r.valueOf()=="string"&&(r=new Date(r)),Math.floor(r.getTime()/1e3)}function FC(r){if(!!r)return new Date(r*1e3)}function UC(r,e,t){if(t!=null){if(r.match(/^Number$/i)!==null){if(typeof t!="number")throw new Error(`${e} with value ${t} must be of type number.`)}else if(r.match(/^String$/i)!==null){if(typeof t.valueOf()!="string")throw new Error(`${e} with value "${t}" must be of type string.`)}else if(r.match(/^Uuid$/i)!==null){if(!(typeof t.valueOf()=="string"&&Dp(t)))throw new Error(`${e} with value "${t}" must be of type string and a valid uuid.`)}else if(r.match(/^Boolean$/i)!==null){if(typeof t!="boolean")throw new Error(`${e} with value ${t} must be of type boolean.`)}else if(r.match(/^Stream$/i)!==null){let a=typeof t;if(a!=="string"&&a!=="function"&&!(t instanceof ArrayBuffer)&&!ArrayBuffer.isView(t)&&!((typeof Blob=="function"||typeof Blob=="object")&&t instanceof Blob))throw new Error(`${e} must be a string, Blob, ArrayBuffer, ArrayBufferView, or a function returning NodeJS.ReadableStream.`)}}return t}function jC(r,e,t){if(!e)throw new Error(`Please provide a set of allowedValues to validate ${r} as an Enum Type.`);if(!e.some(n=>typeof n.valueOf()=="string"?n.toLowerCase()===t.toLowerCase():n===t))throw new Error(`${t} is not a valid value for ${r}. The valid values are: ${JSON.stringify(e)}.`);return t}function VC(r,e){let t="";if(e!=null){if(!(e instanceof Uint8Array))throw new Error(`${r} must be of type Uint8Array.`);t=zp(e)}return t}function GC(r,e){let t="";if(e!=null){if(!(e instanceof Uint8Array))throw new Error(`${r} must be of type Uint8Array.`);t=HC(e)||""}return t}function KC(r,e,t){if(e!=null){if(r.match(/^Date$/i)!==null){if(!(e instanceof Date||typeof e.valueOf()=="string"&&!isNaN(Date.parse(e))))throw new Error(`${t} must be an instanceof Date or a string in ISO8601 format.`);e=e instanceof Date?e.toISOString().substring(0,10):new Date(e).toISOString().substring(0,10)}else if(r.match(/^DateTime$/i)!==null){if(!(e instanceof Date||typeof e.valueOf()=="string"&&!isNaN(Date.parse(e))))throw new Error(`${t} must be an instanceof Date or a string in ISO8601 format.`);e=e instanceof Date?e.toISOString():new Date(e).toISOString()}else if(r.match(/^DateTimeRfc1123$/i)!==null){if(!(e instanceof Date||typeof e.valueOf()=="string"&&!isNaN(Date.parse(e))))throw new Error(`${t} must be an instanceof Date or a string in RFC-1123 format.`);e=e instanceof Date?e.toUTCString():new Date(e).toUTCString()}else if(r.match(/^UnixTime$/i)!==null){if(!(e instanceof Date||typeof e.valueOf()=="string"&&!isNaN(Date.parse(e))))throw new Error(`${t} must be an instanceof Date or a string in RFC-1123/ISO8601 format for it to be serialized in UnixTime/Epoch format.`);e=kC(e)}else if(r.match(/^TimeSpan$/i)!==null&&!kp(e))throw new Error(`${t} must be a string in ISO 8601 format. Instead was "${e}".`)}return e}function XC(r,e,t,a,n,i){if(!Array.isArray(t))throw new Error(`${a} must be of type Array.`);let s=e.type.element;if(!s||typeof s!="object")throw new Error(`element" metadata for an Array must be defined in the mapper and it must of type "object" in ${a}.`);let o=[];for(let l=0;l<t.length;l++){let c=r.serialize(s,t[l],a,i);if(n&&s.xmlNamespace){let p=s.xmlNamespacePrefix?`xmlns:${s.xmlNamespacePrefix}`:"xmlns";s.type.name==="Composite"?(o[l]=Object.assign({},c),o[l][vr]={[p]:s.xmlNamespace}):(o[l]={},o[l][i.xmlCharKey]=c,o[l][vr]={[p]:s.xmlNamespace})}else o[l]=c}return o}function $C(r,e,t,a,n,i){if(typeof t!="object")throw new Error(`${a} must be of type object.`);let s=e.type.value;if(!s||typeof s!="object")throw new Error(`"value" metadata for a Dictionary must be defined in the mapper and it must of type "object" in ${a}.`);let o={};for(let l of Object.keys(t)){let c=r.serialize(s,t[l],a,i);o[l]=Qg(s,c,n,i)}if(n&&e.xmlNamespace){let l=e.xmlNamespacePrefix?`xmlns:${e.xmlNamespacePrefix}`:"xmlns",c=o;return c[vr]={[l]:e.xmlNamespace},c}return o}function WC(r,e,t){let a=e.type.additionalProperties;if(!a&&e.type.className){let n=Wg(r,e,t);return n?.type.additionalProperties}return a}function Wg(r,e,t){let a=e.type.className;if(!a)throw new Error(`Class name for model "${t}" is not provided in the mapper "${JSON.stringify(e,void 0,2)}".`);return r.modelMappers[a]}function Yg(r,e,t){let a=e.type.modelProperties;if(!a){let n=Wg(r,e,t);if(!n)throw new Error(`mapper() cannot be null or undefined for model "${e.type.className}".`);if(a=n?.type.modelProperties,!a)throw new Error(`modelProperties cannot be null or undefined in the mapper "${JSON.stringify(n)}" of type "${e.type.className}" for object "${t}".`)}return a}function YC(r,e,t,a,n,i){if(wm(r,e)&&(e=Zg(r,e,t,"clientName")),t!=null){let s={},o=Yg(r,e,a);for(let c of Object.keys(o)){let p=o[c];if(p.readOnly)continue;let M,S=s;if(r.isXML)p.xmlIsWrapped?M=p.xmlName:M=p.xmlElementName||p.xmlName;else{let O=Up(p.serializedName);M=O.pop();for(let E of O)S[E]==null&&(t[c]!=null||p.defaultValue!==void 0)&&(S[E]={}),S=S[E]}if(S!=null){if(n&&e.xmlNamespace){let W=e.xmlNamespacePrefix?`xmlns:${e.xmlNamespacePrefix}`:"xmlns";S[vr]=Object.assign(Object.assign({},S[vr]),{[W]:e.xmlNamespace})}let O=p.serializedName!==""?a+"."+p.serializedName:a,E=t[c],q=wm(r,e);q&&q.clientName===c&&E==null&&(E=e.serializedName);let C=r.serialize(p,E,O,i);if(C!==void 0&&M!=null){let W=Qg(p,C,n,i);n&&p.xmlIsAttribute?(S[vr]=S[vr]||{},S[vr][M]=C):n&&p.xmlIsWrapped?S[M]={[p.xmlElementName]:W}:S[M]=W}}}let l=WC(r,e,a);if(l){let c=Object.keys(o);for(let p in t)c.every(S=>S!==p)&&(s[p]=r.serialize(l,t[p],a+'["'+p+'"]',i))}return s}return t}function Qg(r,e,t,a){if(!t||!r.xmlNamespace)return e;let i={[r.xmlNamespacePrefix?`xmlns:${r.xmlNamespacePrefix}`:"xmlns"]:r.xmlNamespace};if(["Composite"].includes(r.type.name)){if(e[vr])return e;{let o=Object.assign({},e);return o[vr]=i,o}}let s={};return s[a.xmlCharKey]=e,s[vr]=i,s}function QC(r,e){return[vr,e.xmlCharKey].includes(r)}function ZC(r,e,t,a,n){var i;wm(r,e)&&(e=Zg(r,e,t,"serializedName"));let s=Yg(r,e,a),o={},l=[];for(let p of Object.keys(s)){let M=s[p],S=Up(s[p].serializedName);l.push(S[0]);let{serializedName:O,xmlName:E,xmlElementName:q}=M,C=a;O!==""&&O!==void 0&&(C=a+"."+O);let W=M.headerCollectionPrefix;if(W){let ae={};for(let Ce of Object.keys(t))Ce.startsWith(W)&&(ae[Ce.substring(W.length)]=r.deserialize(M.type.value,t[Ce],C,n)),l.push(Ce);o[p]=ae}else if(r.isXML)if(M.xmlIsAttribute&&t[vr])o[p]=r.deserialize(M,t[vr][E],C,n);else{let ae=q||E||O;if(M.xmlIsWrapped){let Ce=t[E],et=(i=Ce?.[q])!==null&&i!==void 0?i:[];o[p]=r.deserialize(M,et,C,n)}else{let Ce=t[ae];o[p]=r.deserialize(M,Ce,C,n)}}else{let ae,Ce=t;for(let _t of S){if(!Ce)break;Ce=Ce[_t]}ae=Ce;let et=e.type.polymorphicDiscriminator;et&&p===et.clientName&&ae==null&&(ae=e.serializedName);let gt;if(Array.isArray(t[p])&&s[p].serializedName===""){ae=t[p];let _t=r.deserialize(M,ae,C,n);for(let[dt,Tt]of Object.entries(o))Object.prototype.hasOwnProperty.call(_t,dt)||(_t[dt]=Tt);o=_t}else(ae!==void 0||M.defaultValue!==void 0)&&(gt=r.deserialize(M,ae,C,n),o[p]=gt)}}let c=e.type.additionalProperties;if(c){let p=M=>{for(let S in s)if(Up(s[S].serializedName)[0]===M)return!1;return!0};for(let M in t)p(M)&&(o[M]=r.deserialize(c,t[M],a+'["'+M+'"]',n))}else if(t)for(let p of Object.keys(t))o[p]===void 0&&!l.includes(p)&&!QC(p,n)&&(o[p]=t[p]);return o}function JC(r,e,t,a,n){let i=e.type.value;if(!i||typeof i!="object")throw new Error(`"value" metadata for a Dictionary must be defined in the mapper and it must of type "object" in ${a}`);if(t){let s={};for(let o of Object.keys(t))s[o]=r.deserialize(i,t[o],a,n);return s}return t}function eR(r,e,t,a,n){let i=e.type.element;if(!i||typeof i!="object")throw new Error(`element" metadata for an Array must be defined in the mapper and it must of type "object" in ${a}`);if(t){Array.isArray(t)||(t=[t]);let s=[];for(let o=0;o<t.length;o++)s[o]=r.deserialize(i,t[o],`${a}[${o}]`,n);return s}return t}function Zg(r,e,t,a){let n=wm(r,e);if(n){let i=n[a];if(i!=null){let s=t[i];if(s!=null){let o=e.type.uberParent||e.type.className,l=s===o?s:o+"."+s,c=r.modelMappers.discriminators[l];c&&(e=c)}}}return e}function wm(r,e){return e.type.polymorphicDiscriminator||$g(r,e.type.uberParent)||$g(r,e.type.className)}function $g(r,e){return e&&r.modelMappers[e]&&r.modelMappers[e].type.polymorphicDiscriminator}function tR(r){let e={};for(let t of r)e[t]=t;return e}var ni=tR(["Base64Url","Boolean","ByteArray","Composite","Date","DateTime","DateTimeRfc1123","Dictionary","Enum","Number","Object","Sequence","String","Stream","TimeSpan","UnixTime"]);function Jg(r){if(r&&typeof r=="object"){let e=r;if(typeof e.url=="string"&&typeof e.method=="string"&&typeof e.headers=="object"&&Op(e.headers)&&typeof e.validateRequestProperties=="function"&&typeof e.prepare=="function"&&typeof e.clone=="function")return!0}return!1}var An=class{constructor(e,t,a,n,i,s,o,l,c,p,M,S,O,E,q){this.streamResponseBody=s,this.streamResponseStatusCodes=q,this.url=e||"",this.method=t||"GET",this.headers=Op(i)?i:new Kr(i),this.body=a,this.query=n,this.formData=void 0,this.withCredentials=o||!1,this.abortSignal=l,this.timeout=c||0,this.onUploadProgress=p,this.onDownloadProgress=M,this.proxySettings=S,this.keepAlive=O,this.decompressResponse=E,this.requestId=this.headers.get("x-ms-client-request-id")||Ka()}validateRequestProperties(){if(!this.method)throw new Error("WebResource.method is required.");if(!this.url)throw new Error("WebResource.url is required.")}prepare(e){if(!e)throw new Error("options object is required");if(e.method===void 0||e.method===null||typeof e.method.valueOf()!="string")throw new Error("options.method must be a string.");if(e.url&&e.pathTemplate)throw new Error("options.url and options.pathTemplate are mutually exclusive. Please provide exactly one of them.");if((e.pathTemplate===void 0||e.pathTemplate===null||typeof e.pathTemplate.valueOf()!="string")&&(e.url===void 0||e.url===null||typeof e.url.valueOf()!="string"))throw new Error("Please provide exactly one of options.pathTemplate or options.url.");if(e.url){if(typeof e.url!="string")throw new Error('options.url must be of type "string".');this.url=e.url}if(e.method){let t=["GET","PUT","HEAD","DELETE","OPTIONS","POST","PATCH","TRACE"];if(t.indexOf(e.method.toUpperCase())===-1)throw new Error('The provided method "'+e.method+'" is invalid. Supported HTTP methods are: '+JSON.stringify(t))}if(this.method=e.method.toUpperCase(),e.pathTemplate){let{pathTemplate:t,pathParameters:a}=e;if(typeof t!="string")throw new Error('options.pathTemplate must be of type "string".');e.baseUrl||(e.baseUrl="https://management.azure.com");let n=e.baseUrl,i=n+(n.endsWith("/")?"":"/")+(t.startsWith("/")?t.slice(1):t),s=i.match(/({[\w-]*\s*[\w-]*})/gi);if(s&&s.length){if(!a)throw new Error(`pathTemplate: ${t} has been provided. Hence, options.pathParameters must also be provided.`);s.forEach(function(o){let l=o.slice(1,-1),c=a[l];if(c==null||!(typeof c=="string"||typeof c=="object")){let p=JSON.stringify(a,void 0,2);throw new Error(`pathTemplate: ${t} contains the path parameter ${l} however, it is not present in parameters: ${p}.The value of the path parameter can either be a "string" of the form { ${l}: "some sample value" } or it can be an "object" of the form { "${l}": { value: "some sample value", skipUrlEncoding: true } }.`)}if(typeof c.valueOf()=="string"&&(i=i.replace(o,encodeURIComponent(c))),typeof c.valueOf()=="object"){if(!c.value)throw new Error(`options.pathParameters[${l}] is of type "object" but it does not contain a "value" property.`);c.skipUrlEncoding?i=i.replace(o,c.value):i=i.replace(o,encodeURIComponent(c.value))}})}this.url=i}if(e.queryParameters){let t=e.queryParameters;if(typeof t!="object")throw new Error('options.queryParameters must be of type object. It should be a JSON object of "query-parameter-name" as the key and the "query-parameter-value" as the value. The "query-parameter-value" may be fo type "string" or an "object" of the form { value: "query-parameter-value", skipUrlEncoding: true }.');this.url&&this.url.indexOf("?")===-1&&(this.url+="?");let a=[];this.query={};for(let n in t){let i=t[n];if(i){if(typeof i=="string")a.push(n+"="+encodeURIComponent(i)),this.query[n]=encodeURIComponent(i);else if(typeof i=="object"){if(!i.value)throw new Error(`options.queryParameters[${n}] is of type "object" but it does not contain a "value" property.`);i.skipUrlEncoding?(a.push(n+"="+i.value),this.query[n]=i.value):(a.push(n+"="+encodeURIComponent(i.value)),this.query[n]=encodeURIComponent(i.value))}}}this.url+=a.join("&")}if(e.headers){let t=e.headers;for(let a of Object.keys(e.headers))this.headers.set(a,t[a])}return this.headers.get("accept-language")||this.headers.set("accept-language","en-US"),!this.headers.get("x-ms-client-request-id")&&!e.disableClientRequestId&&this.headers.set("x-ms-client-request-id",this.requestId),this.headers.get("Content-Type")||this.headers.set("Content-Type","application/json; charset=utf-8"),this.body=e.body,e.body!==void 0&&e.body!==null&&(e.bodyIsStream?(this.headers.get("Transfer-Encoding")||this.headers.set("Transfer-Encoding","chunked"),this.headers.get("Content-Type")!=="application/octet-stream"&&this.headers.set("Content-Type","application/octet-stream")):(e.serializationMapper&&(this.body=new kr(e.mappers).serialize(e.serializationMapper,e.body,"requestBody")),e.disableJsonStringifyOnBody||(this.body=JSON.stringify(e.body)))),e.spanOptions&&(this.spanOptions=e.spanOptions),e.tracingContext&&(this.tracingContext=e.tracingContext),this.abortSignal=e.abortSignal,this.onDownloadProgress=e.onDownloadProgress,this.onUploadProgress=e.onUploadProgress,this}clone(){let e=new An(this.url,this.method,this.body,this.query,this.headers&&this.headers.clone(),this.streamResponseBody,this.withCredentials,this.abortSignal,this.timeout,this.onUploadProgress,this.onDownloadProgress,this.proxySettings,this.keepAlive,this.decompressResponse,this.streamResponseStatusCodes);return this.formData&&(e.formData=this.formData),this.operationSpec&&(e.operationSpec=this.operationSpec),this.shouldDeserialize&&(e.shouldDeserialize=this.shouldDeserialize),this.operationResponseGetter&&(e.operationResponseGetter=this.operationResponseGetter),e}};var bv=ns(_v(),1),{__extends:Sv,__assign:ZI,__rest:JI,__decorate:eM,__param:tM,__metadata:rM,__awaiter:aM,__generator:nM,__exportStar:iM,__createBinding:sM,__values:oM,__read:lM,__spread:cM,__spreadArrays:mM,__spreadArray:dM,__await:uM,__asyncGenerator:pM,__asyncDelegator:fM,__asyncValues:hM,__makeTemplateObject:yM,__importStar:xM,__importDefault:gM,__classPrivateFieldGet:vM,__classPrivateFieldSet:_M}=bv.default;var Oo=new WeakMap,Bm=new WeakMap,Vp=function(){function r(){this.onabort=null,Oo.set(this,[]),Bm.set(this,!1)}return Object.defineProperty(r.prototype,"aborted",{get:function(){if(!Bm.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");return Bm.get(this)},enumerable:!1,configurable:!0}),Object.defineProperty(r,"none",{get:function(){return new r},enumerable:!1,configurable:!0}),r.prototype.addEventListener=function(e,t){if(!Oo.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");var a=Oo.get(this);a.push(t)},r.prototype.removeEventListener=function(e,t){if(!Oo.has(this))throw new TypeError("Expected `this` to be an instance of AbortSignal.");var a=Oo.get(this),n=a.indexOf(t);n>-1&&a.splice(n,1)},r.prototype.dispatchEvent=function(e){throw new Error("This is a stub dispatchEvent implementation that should not be used. It only exists for type-checking purposes.")},r}();function Gp(r){if(!r.aborted){r.onabort&&r.onabort.call(r);var e=Oo.get(r);e&&e.slice().forEach(function(t){t.call(r,{type:"abort"})}),Bm.set(r,!0)}}var ii=function(r){Sv(e,r);function e(t){var a=r.call(this,t)||this;return a.name="AbortError",a}return e}(Error);var rR=function(){function r(e){var t=this;if(this._signal=new Vp,!!e){Array.isArray(e)||(e=arguments);for(var a=0,n=e;a<n.length;a++){var i=n[a];i.aborted?this.abort():i.addEventListener("abort",function(){t.abort()})}}}return Object.defineProperty(r.prototype,"signal",{get:function(){return this._signal},enumerable:!1,configurable:!0}),r.prototype.abort=function(){Gp(this._signal)},r.timeout=function(e){var t=new Vp,a=setTimeout(Gp,e,t);return typeof a.unref=="function"&&a.unref(),t},r}();var Nv={};var Om=URL;var si=class{constructor(){this._rawQuery={}}any(){return Object.keys(this._rawQuery).length>0}keys(){return Object.keys(this._rawQuery)}set(e,t){let a=t;if(e)if(a!=null){let n=Array.isArray(a)?a:a.toString();this._rawQuery[e]=n}else delete this._rawQuery[e]}get(e){return e?this._rawQuery[e]:void 0}toString(){let e="";for(let t in this._rawQuery){e&&(e+="&");let a=this._rawQuery[t];if(Array.isArray(a)){let n=[];for(let i of a)n.push(`${t}=${i}`);e+=n.join("&")}else e+=`${t}=${a}`}return e}static parse(e){let t=new si;if(e){e.startsWith("?")&&(e=e.substring(1));let a="ParameterName",n="",i="";for(let s=0;s<e.length;++s){let o=e[s];switch(a){case"ParameterName":switch(o){case"=":a="ParameterValue";break;case"&":n="",i="";break;default:n+=o;break}break;case"ParameterValue":switch(o){case"&":t.set(n,i),n="",i="",a="ParameterName";break;default:i+=o;break}break;default:throw new Error("Unrecognized URLQuery parse state: "+a)}}a==="ParameterValue"&&t.set(n,i)}return t}},ar=class{setScheme(e){e?this.set(e,"SCHEME"):this._scheme=void 0}getScheme(){return this._scheme}setHost(e){e?this.set(e,"SCHEME_OR_HOST"):this._host=void 0}getHost(){return this._host}setPort(e){e==null||e===""?this._port=void 0:this.set(e.toString(),"PORT")}getPort(){return this._port}setPath(e){if(!e)this._path=void 0;else{let t=e.indexOf("://");if(t!==-1){let a=e.lastIndexOf("/",t);this.set(a===-1?e:e.substr(a+1),"SCHEME")}else this.set(e,"PATH")}}appendPath(e){if(e){let t=this.getPath();t&&(t.endsWith("/")||(t+="/"),e.startsWith("/")&&(e=e.substring(1)),e=t+e),this.set(e,"PATH")}}getPath(){return this._path}setQuery(e){e?this._query=si.parse(e):this._query=void 0}setQueryParameter(e,t){e&&(this._query||(this._query=new si),this._query.set(e,t))}getQueryParameterValue(e){return this._query?this._query.get(e):void 0}getQuery(){return this._query?this._query.toString():void 0}set(e,t){let a=new Kp(e,t);for(;a.next();){let n=a.current(),i;if(n)switch(n.type){case"SCHEME":this._scheme=n.text||void 0;break;case"HOST":this._host=n.text||void 0;break;case"PORT":this._port=n.text||void 0;break;case"PATH":i=n.text||void 0,(!this._path||this._path==="/"||i!=="/")&&(this._path=i);break;case"QUERY":this._query=si.parse(n.text);break;default:throw new Error(`Unrecognized URLTokenType: ${n.type}`)}}}toString(){let e="";return this._scheme&&(e+=`${this._scheme}://`),this._host&&(e+=this._host),this._port&&(e+=`:${this._port}`),this._path&&(this._path.startsWith("/")||(e+="/"),e+=this._path),this._query&&this._query.any()&&(e+=`?${this._query.toString()}`),e}replaceAll(e,t){e&&(this.setScheme(Ao(this.getScheme(),e,t)),this.setHost(Ao(this.getHost(),e,t)),this.setPort(Ao(this.getPort(),e,t)),this.setPath(Ao(this.getPath(),e,t)),this.setQuery(Ao(this.getQuery(),e,t)))}static parse(e){let t=new ar;return t.set(e,"SCHEME_OR_HOST"),t}},ca=class{constructor(e,t){this.text=e,this.type=t}static scheme(e){return new ca(e,"SCHEME")}static host(e){return new ca(e,"HOST")}static port(e){return new ca(e,"PORT")}static path(e){return new ca(e,"PATH")}static query(e){return new ca(e,"QUERY")}};function aR(r){let e=r.charCodeAt(0);return 48<=e&&e<=57||65<=e&&e<=90||97<=e&&e<=122}var Kp=class{constructor(e,t){this._text=e,this._textLength=e?e.length:0,this._currentState=t??"SCHEME_OR_HOST",this._currentIndex=0}current(){return this._currentToken}next(){if(!ss(this))this._currentToken=void 0;else switch(this._currentState){case"SCHEME":sR(this);break;case"SCHEME_OR_HOST":oR(this);break;case"HOST":lR(this);break;case"PORT":cR(this);break;case"PATH":mR(this);break;case"QUERY":dR(this);break;default:throw new Error(`Unrecognized URLTokenizerState: ${this._currentState}`)}return!!this._currentToken}};function nR(r){let e="";return r._currentIndex<r._textLength&&(e=r._text.substring(r._currentIndex),r._currentIndex=r._textLength),e}function ss(r){return r._currentIndex<r._textLength}function is(r){return r._text[r._currentIndex]}function zm(r,e){ss(r)&&(e||(e=1),r._currentIndex+=e)}function Pv(r,e){let t=r._currentIndex+e;return r._textLength<t&&(t=r._textLength),r._text.substring(r._currentIndex,t)}function Cv(r,e){let t="";for(;ss(r);){let a=is(r);if(e(a))t+=a,zm(r);else break}return t}function iR(r){return Cv(r,e=>aR(e))}function Lm(r,...e){return Cv(r,t=>e.indexOf(t)===-1)}function sR(r){let e=iR(r);r._currentToken=ca.scheme(e),ss(r)?r._currentState="HOST":r._currentState="DONE"}function oR(r){let e=Lm(r,":","/","?");ss(r)?is(r)===":"?Pv(r,3)==="://"?(r._currentToken=ca.scheme(e),r._currentState="HOST"):(r._currentToken=ca.host(e),r._currentState="PORT"):(r._currentToken=ca.host(e),is(r)==="/"?r._currentState="PATH":r._currentState="QUERY"):(r._currentToken=ca.host(e),r._currentState="DONE")}function lR(r){Pv(r,3)==="://"&&zm(r,3);let e=Lm(r,":","/","?");r._currentToken=ca.host(e),ss(r)?is(r)===":"?r._currentState="PORT":is(r)==="/"?r._currentState="PATH":r._currentState="QUERY":r._currentState="DONE"}function cR(r){is(r)===":"&&zm(r);let e=Lm(r,"/","?");r._currentToken=ca.port(e),ss(r)?is(r)==="/"?r._currentState="PATH":r._currentState="QUERY":r._currentState="DONE"}function mR(r){let e=Lm(r,"?");r._currentToken=ca.path(e),ss(r)?r._currentState="QUERY":r._currentState="DONE"}function dR(r){is(r)==="?"&&zm(r);let e=nR(r);r._currentToken=ca.query(e),r._currentState="DONE"}var Rv="REDACTED",Ev=["x-ms-client-request-id","x-ms-return-client-request-id","x-ms-useragent","x-ms-correlation-request-id","x-ms-request-id","client-request-id","ms-cv","return-client-request-id","traceparent","Access-Control-Allow-Credentials","Access-Control-Allow-Headers","Access-Control-Allow-Methods","Access-Control-Allow-Origin","Access-Control-Expose-Headers","Access-Control-Max-Age","Access-Control-Request-Headers","Access-Control-Request-Method","Origin","Accept","Accept-Encoding","Cache-Control","Connection","Content-Length","Content-Type","Date","ETag","Expires","If-Match","If-Modified-Since","If-None-Match","If-Unmodified-Since","Last-Modified","Pragma","Request-Id","Retry-After","Server","Transfer-Encoding","User-Agent"],Tv=["api-version"],zo=class{constructor({allowedHeaderNames:e=[],allowedQueryParameters:t=[]}={}){e=Array.isArray(e)?Ev.concat(e):Ev,t=Array.isArray(t)?Tv.concat(t):Tv,this.allowedHeaderNames=new Set(e.map(a=>a.toLowerCase())),this.allowedQueryParameters=new Set(t.map(a=>a.toLowerCase()))}sanitize(e){let t=new Set;return JSON.stringify(e,(a,n)=>{if(n instanceof Error)return Object.assign(Object.assign({},n),{name:n.name,message:n.message});if(a==="_headersMap")return this.sanitizeHeaders(n);if(a==="url")return this.sanitizeUrl(n);if(a==="query")return this.sanitizeQuery(n);if(a==="body")return;if(a==="response")return;if(a==="operationSpec")return;if(Array.isArray(n)||Xg(n)){if(t.has(n))return"[Circular]";t.add(n)}return n},2)}sanitizeHeaders(e){return this.sanitizeObject(e,this.allowedHeaderNames,(t,a)=>t[a].value)}sanitizeQuery(e){return this.sanitizeObject(e,this.allowedQueryParameters,(t,a)=>t[a])}sanitizeObject(e,t,a){if(typeof e!="object"||e===null)return e;let n={};for(let i of Object.keys(e))t.has(i.toLowerCase())?n[i]=a(e,i):n[i]=Rv;return n}sanitizeUrl(e){if(typeof e!="string"||e===null)return e;let t=ar.parse(e),a=t.getQuery();if(!a)return e;let n=si.parse(a);for(let i of n.keys())this.allowedQueryParameters.has(i.toLowerCase())||n.set(i,Rv);return t.setQuery(n.toString()),t.toString()}};var uR=new zo,ma=class extends Error{constructor(e,t,a,n,i){super(e),this.name="RestError",this.code=t,this.statusCode=a,this.request=n,this.response=i,Object.setPrototypeOf(this,ma.prototype)}[Nv](){return`RestError: ${this.message}
15
- ${uR.sanitize(this)}`}};ma.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR";ma.PARSE_ERROR="PARSE_ERROR";var os=class{sendRequest(e){var t;let a=new XMLHttpRequest;if(e.proxySettings)throw new Error("HTTP proxy is not supported in browser environment");let n=e.abortSignal;if(n){if(n.aborted)return Promise.reject(new ii("The operation was aborted."));let i=()=>{a.abort()};n.addEventListener("abort",i),a.addEventListener("readystatechange",()=>{a.readyState===XMLHttpRequest.DONE&&n.removeEventListener("abort",i)})}if(wv(a.upload,e.onUploadProgress),wv(a,e.onDownloadProgress),e.formData){let i=e.formData,s=new FormData,o=(c,p)=>{p&&Object.prototype.hasOwnProperty.call(p,"value")&&Object.prototype.hasOwnProperty.call(p,"options")?s.append(c,p.value,p.options):s.append(c,p)};for(let c of Object.keys(i)){let p=i[c];if(Array.isArray(p))for(let M=0;M<p.length;M++)o(c,p[M]);else o(c,p)}e.body=s,e.formData=void 0;let l=e.headers.get("Content-Type");l&&l.indexOf("multipart/form-data")!==-1&&e.headers.remove("Content-Type")}a.open(e.method,e.url),a.timeout=e.timeout,a.withCredentials=e.withCredentials;for(let i of e.headers.headersArray())a.setRequestHeader(i.name,i.value);return a.responseType=((t=e.streamResponseStatusCodes)===null||t===void 0?void 0:t.size)||e.streamResponseBody?"blob":"text",a.send(e.body===void 0?null:e.body),a.responseType==="blob"?new Promise((i,s)=>{pR(a,e,i,s),Xp(e,a,s)}):new Promise(function(i,s){a.addEventListener("load",()=>i({request:e,status:a.status,headers:qm(a),bodyAsText:a.responseText})),Xp(e,a,s)})}};function pR(r,e,t,a){r.addEventListener("readystatechange",()=>{var n;if(r.readyState===XMLHttpRequest.HEADERS_RECEIVED)if(e.streamResponseBody||((n=e.streamResponseStatusCodes)===null||n===void 0?void 0:n.has(r.status))){let i=new Promise((s,o)=>{r.addEventListener("load",()=>{s(r.response)}),Xp(e,r,o)});t({request:e,status:r.status,headers:qm(r),blobBody:i})}else r.addEventListener("load",()=>{if(r.response){let i=new FileReader;i.onload=function(s){var o;let l=(o=s.target)===null||o===void 0?void 0:o.result;t({request:e,status:r.status,headers:qm(r),bodyAsText:l})},i.onerror=function(s){a(i.error)},i.readAsText(r.response,"UTF-8")}else t({request:e,status:r.status,headers:qm(r)})})})}function wv(r,e){e&&r.addEventListener("progress",t=>e({loadedBytes:t.loaded}))}function qm(r){let e=new Kr,t=r.getAllResponseHeaders().trim().split(/[\r\n]+/);for(let a of t){let n=a.indexOf(":"),i=a.slice(0,n),s=a.slice(n+2);e.set(i,s)}return e}function Xp(r,e,t){e.addEventListener("error",()=>t(new ma(`Failed to send request to ${r.url}`,ma.REQUEST_SEND_ERROR,void 0,r)));let a=new ii("The operation was aborted.");e.addEventListener("abort",()=>t(a)),e.addEventListener("timeout",()=>t(a))}var Hm;(function(r){r[r.OFF=0]="OFF",r[r.ERROR=1]="ERROR",r[r.WARNING=2]="WARNING",r[r.INFO=3]="INFO"})(Hm||(Hm={}));var Qv=ns(Yv(),1),{__extends:XM,__assign:$M,__rest:Zv,__decorate:WM,__param:YM,__metadata:QM,__awaiter:ZM,__generator:JM,__exportStar:e6,__createBinding:t6,__values:r6,__read:a6,__spread:n6,__spreadArrays:i6,__spreadArray:s6,__await:o6,__asyncGenerator:l6,__asyncDelegator:c6,__asyncValues:m6,__makeTemplateObject:d6,__importStar:u6,__importDefault:p6,__classPrivateFieldGet:f6,__classPrivateFieldSet:h6}=Qv.default;function Ye(r){var e;let{requestOptions:t,tracingOptions:a}=r,i=Zv(r,["requestOptions","tracingOptions"]);return t&&(i=Object.assign(Object.assign({},i),t)),a&&(i.tracingContext=a.tracingContext,i.spanOptions=(e=a)===null||e===void 0?void 0:e.spanOptions),i}function Ar(r){let e=r;return e&&typeof e.getToken=="function"&&(e.signRequest===void 0||e.getToken.length>0)}var It=class{constructor(e,t){this._nextPolicy=e,this._options=t}shouldLog(e){return this._options.shouldLog(e)}log(e,t){this._options.log(e,t)}},qo=class{constructor(e){this._logger=e}shouldLog(e){return!!this._logger&&e!==Hm.OFF&&e<=this._logger.minimumLogLevel}log(e,t){this._logger&&this.shouldLog(e)&&this._logger.log(e,t)}};function Jv(...r){if(r.length>0){let e=String(r[0]);e.includes(":error")?console.error(...r):e.includes(":warning")?console.warn(...r):e.includes(":info")?console.info(...r):e.includes(":verbose")?console.debug(...r):console.debug(...r)}}var e_=typeof process<"u"&&process.env&&process.env.DEBUG||void 0,t_,Wp=[],Yp=[],Um=[];e_&&Qp(e_);var r_=Object.assign(r=>a_(r),{enable:Qp,enabled:Zp,disable:fR,log:Jv});function Qp(r){t_=r,Wp=[],Yp=[];let e=/\*/g,t=r.split(",").map(a=>a.trim().replace(e,".*?"));for(let a of t)a.startsWith("-")?Yp.push(new RegExp(`^${a.substr(1)}$`)):Wp.push(new RegExp(`^${a}$`));for(let a of Um)a.enabled=Zp(a.namespace)}function Zp(r){if(r.endsWith("*"))return!0;for(let e of Yp)if(e.test(r))return!1;for(let e of Wp)if(e.test(r))return!0;return!1}function fR(){let r=t_||"";return Qp(""),r}function a_(r){let e=Object.assign(t,{enabled:Zp(r),destroy:hR,log:r_.log,namespace:r,extend:yR});function t(...a){!e.enabled||(a.length>0&&(a[0]=`${r} ${a[0]}`),e.log(...a))}return Um.push(e),e}function hR(){let r=Um.indexOf(this);return r>=0?(Um.splice(r,1),!0):!1}function yR(r){let e=a_(`${this.namespace}:${r}`);return e.log=this.log,e}var Ho=r_;var i_=new Set,jm=typeof process<"u"&&process.env&&process.env.AZURE_LOG_LEVEL||void 0,Jp,e0=Ho("azure");e0.log=(...r)=>{Ho.log(...r)};var t0=["verbose","info","warning","error"];jm&&(l_(jm)?xR(jm):console.error(`AZURE_LOG_LEVEL set to unknown log level '${jm}'; logging is not enabled. Acceptable values: ${t0.join(", ")}.`));function xR(r){if(r&&!l_(r))throw new Error(`Unknown log level '${r}'. Acceptable values: ${t0.join(",")}`);Jp=r;let e=[];for(let t of i_)o_(t)&&e.push(t.namespace);Ho.enable(e.join(","))}var n_={verbose:400,info:300,warning:200,error:100};function Gm(r){let e=e0.extend(r);return s_(e0,e),{error:Vm(e,"error"),warning:Vm(e,"warning"),info:Vm(e,"info"),verbose:Vm(e,"verbose")}}function s_(r,e){e.log=(...t)=>{r.log(...t)}}function Vm(r,e){let t=Object.assign(r.extend(e),{level:e});if(s_(r,t),o_(t)){let a=Ho.disable();Ho.enable(a+","+t.namespace)}return i_.add(t),t}function o_(r){return!!(Jp&&n_[r.level]<=n_[Jp])}function l_(r){return t0.includes(r)}var La=Gm("core-http");function tc(r={}){return{create:(e,t)=>new r0(e,t,r)}}var r0=class extends It{constructor(e,t,{logger:a=La.info,allowedHeaderNames:n=[],allowedQueryParameters:i=[]}={}){super(e,t),this.logger=a,this.sanitizer=new zo({allowedHeaderNames:n,allowedQueryParameters:i})}get allowedHeaderNames(){return this.sanitizer.allowedHeaderNames}set allowedHeaderNames(e){this.sanitizer.allowedHeaderNames=e}get allowedQueryParameters(){return this.sanitizer.allowedQueryParameters}set allowedQueryParameters(e){this.sanitizer.allowedQueryParameters=e}sendRequest(e){return this.logger.enabled?(this.logRequest(e),this._nextPolicy.sendRequest(e).then(t=>this.logResponse(t))):this._nextPolicy.sendRequest(e)}logRequest(e){this.logger(`Request: ${this.sanitizer.sanitize(e)}`)}logResponse(e){return this.logger(`Response status code: ${e.status}`),this.logger(`Headers: ${this.sanitizer.sanitize(e.headers)}`),e}};function oi(r){return Km(r.parameterPath,r.mapper)}function Km(r,e){let t;return typeof r=="string"?t=r:Array.isArray(r)?t=r.join("."):t=e.serializedName,t}function c_(r){let e=new Set;for(let t in r.responses){let a=r.responses[t];a.bodyMapper&&a.bodyMapper.type.name===ni.Stream&&e.add(Number(t))}return e}if(!self.document||!self.DOMParser||!self.Node||!self.XMLSerializer)throw new Error('This library depends on the following DOM objects: ["document", "DOMParser", "Node", "XMLSerializer"] to parse XML, but some of these are undefined. You may provide a polyfill to make these globally available in order to support your environment. For more information, please refer to https://aka.ms/azsdk/js/web-workers. ');var a0=document.implementation.createDocument(null,null,null),m_=new DOMParser;function d_(r,e={}){var t,a,n;try{let i={rootName:(t=e.rootName)!==null&&t!==void 0?t:"",includeRoot:(a=e.includeRoot)!==null&&a!==void 0?a:!1,xmlCharKey:(n=e.xmlCharKey)!==null&&n!==void 0?n:Mn},s=m_.parseFromString(r,"application/xml");vR(s);let o;return i.includeRoot?o=n0(s,i):o=n0(s.childNodes[0],i),Promise.resolve(o)}catch(i){return Promise.reject(i)}}var rc;function gR(){var r;if(rc===void 0)try{rc=(r=m_.parseFromString("INVALID","text/xml").getElementsByTagName("parsererror")[0].namespaceURI)!==null&&r!==void 0?r:""}catch{rc=""}return rc}function vR(r){let e=r.getElementsByTagName("parsererror");if(e.length>0&&gR()){for(let t=0;t<e.length;t++)if(e[t].namespaceURI===rc)throw new Error(e[t].innerHTML)}}function _R(r){return!!r.attributes}function bR(r){return _R(r)&&r.hasAttributes()?r:void 0}function n0(r,e){let t={},a=r.childNodes.length,n=r.childNodes[0],i=n&&a===1&&n.nodeType===Node.TEXT_NODE&&n.nodeValue||void 0,s=bR(r);if(s){t[vr]={};for(let o=0;o<s.attributes.length;o++){let l=s.attributes[o];t[vr][l.nodeName]=l.nodeValue}i&&(t[e.xmlCharKey]=i)}else a===0?t="":i&&(t=i);if(!i)for(let o=0;o<a;o++){let l=r.childNodes[o];if(l.nodeType!==Node.TEXT_NODE){let c=n0(l,e);t[l.nodeName]?Array.isArray(t[l.nodeName])?t[l.nodeName].push(c):t[l.nodeName]=[t[l.nodeName],c]:t[l.nodeName]=c}}return t}var SR=new XMLSerializer;function s0(r,e={}){var t,a,n;let i={rootName:(t=e.rootName)!==null&&t!==void 0?t:"root",includeRoot:(a=e.includeRoot)!==null&&a!==void 0?a:!1,xmlCharKey:(n=e.xmlCharKey)!==null&&n!==void 0?n:Mn},s=i0(r,i.rootName,i)[0];return'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>'+SR.serializeToString(s)}function NR(r){let e=[];for(let t of Object.keys(r)){let a=a0.createAttribute(t);a.value=r[t].toString(),e.push(a)}return e}function i0(r,e,t){if(r==null||typeof r=="string"||typeof r=="number"||typeof r=="boolean"){let a=a0.createElement(e);return a.textContent=r==null?"":r.toString(),[a]}else if(Array.isArray(r)){let a=[];for(let n of r)for(let i of i0(n,e,t))a.push(i);return a}else if(typeof r=="object"){let a=a0.createElement(e);for(let n of Object.keys(r))if(n===vr)for(let i of NR(r[n]))a.attributes.setNamedItem(i);else if(n===t.xmlCharKey)a.textContent=r[n].toString();else for(let i of i0(r[n],n,t))a.appendChild(i);return[a]}else throw new Error(`Illegal value passed to buildObject: ${r}`)}function Vs(r,e){return{create:(t,a)=>new o0(t,a,r,e)}}var PR=["application/json","text/json"],CR=["application/xml","application/atom+xml"];var o0=class extends It{constructor(e,t,a,n={}){var i;super(e,t),this.jsonContentTypes=a&&a.json||PR,this.xmlContentTypes=a&&a.xml||CR,this.xmlCharKey=(i=n.xmlCharKey)!==null&&i!==void 0?i:Mn}async sendRequest(e){return this._nextPolicy.sendRequest(e).then(t=>u_(this.jsonContentTypes,this.xmlContentTypes,t,{xmlCharKey:this.xmlCharKey}))}};function RR(r){let e,t=r.request,a=t.operationSpec;if(a){let n=t.operationResponseGetter;n?e=n(a,r):e=a.responses[r.status]}return e}function ER(r){let e=r.request.shouldDeserialize,t;return e===void 0?t=!0:typeof e=="boolean"?t=e:t=e(r),t}function u_(r,e,t,a={}){var n,i,s;let o={rootName:(n=a.rootName)!==null&&n!==void 0?n:"",includeRoot:(i=a.includeRoot)!==null&&i!==void 0?i:!1,xmlCharKey:(s=a.xmlCharKey)!==null&&s!==void 0?s:Mn};return IR(r,e,t,o).then(l=>{if(!ER(l))return l;let c=l.request.operationSpec;if(!c||!c.responses)return l;let p=RR(l),{error:M,shouldReturnResponse:S}=wR(l,c,p);if(M)throw M;if(S)return l;if(p){if(p.bodyMapper){let O=l.parsedBody;c.isXML&&p.bodyMapper.type.name===ni.Sequence&&(O=typeof O=="object"?O[p.bodyMapper.xmlElementName]:[]);try{l.parsedBody=c.serializer.deserialize(p.bodyMapper,O,"operationRes.parsedBody",a)}catch(E){throw new ma(`Error ${E} occurred in deserializing the responseBody - ${l.bodyAsText}`,void 0,l.status,l.request,l)}}else c.httpMethod==="HEAD"&&(l.parsedBody=t.status>=200&&t.status<300);p.headersMapper&&(l.parsedHeaders=c.serializer.deserialize(p.headersMapper,l.headers.rawHeaders(),"operationRes.parsedHeaders",a))}return l})}function TR(r){let e=Object.keys(r.responses);return e.length===0||e.length===1&&e[0]==="default"}function wR(r,e,t){var a;let n=200<=r.status&&r.status<300;if(TR(e)?n:!!t)if(t){if(!t.isError)return{error:null,shouldReturnResponse:!1}}else return{error:null,shouldReturnResponse:!1};let s=t??e.responses.default,l=((a=r.request.streamResponseStatusCodes)===null||a===void 0?void 0:a.has(r.status))||r.request.streamResponseBody?`Unexpected status code: ${r.status}`:r.bodyAsText,c=new ma(l,void 0,r.status,r.request,r);if(!s)throw c;let p=s.bodyMapper,M=s.headersMapper;try{if(r.parsedBody){let S=r.parsedBody,O;if(p){let q=S;e.isXML&&p.type.name===ni.Sequence&&(q=typeof S=="object"?S[p.xmlElementName]:[]),O=e.serializer.deserialize(p,q,"error.response.parsedBody")}let E=S.error||O||S;c.code=E.code,E.message&&(c.message=E.message),p&&(c.response.parsedBody=O)}r.headers&&M&&(c.response.parsedHeaders=e.serializer.deserialize(M,r.headers.rawHeaders(),"operationRes.parsedHeaders"))}catch(S){c.message=`Error "${S.message}" occurred in deserializing the responseBody - "${r.bodyAsText}" for the default response.`}return{error:c,shouldReturnResponse:!1}}function IR(r,e,t,a){var n;let i=o=>{let l=`Error "${o}" occurred while parsing the response body - ${t.bodyAsText}.`,c=o.code||ma.PARSE_ERROR,p=new ma(l,c,t.status,t.request,t);return Promise.reject(p)};if(!(((n=t.request.streamResponseStatusCodes)===null||n===void 0?void 0:n.has(t.status))||t.request.streamResponseBody)&&t.bodyAsText){let o=t.bodyAsText,l=t.headers.get("Content-Type")||"",c=l?l.split(";").map(p=>p.toLowerCase()):[];if(c.length===0||c.some(p=>r.indexOf(p)!==-1))return new Promise(p=>{t.parsedBody=JSON.parse(o),p(t)}).catch(i);if(c.some(p=>e.indexOf(p)!==-1))return d_(o,a).then(p=>(t.parsedBody=p,t)).catch(i)}return Promise.resolve(t)}function Bi(r){return typeof r=="number"}function Xm(r,e,t,a,n){return e(a,n)?t.retryCount<r:!1}function $m(r,e={retryCount:0,retryInterval:0},t){t&&(e.error&&(t.innerError=e.error),e.error=t),e.retryCount++;let a=Math.pow(2,e.retryCount-1)-1;return a*=r.retryInterval*.8+Math.floor(Math.random()*(r.retryInterval*.4)),e.retryInterval=Math.min(r.minRetryInterval+a,r.maxRetryInterval),e}function p_(r){return typeof r<"u"&&r!==null}var MR="The operation was aborted.";function Xa(r,e,t){return new Promise((a,n)=>{let i,s,o=()=>n(new ii(t?.abortErrorMsg?t?.abortErrorMsg:MR)),l=()=>{t?.abortSignal&&s&&t.abortSignal.removeEventListener("abort",s)};if(s=()=>(p_(i)&&clearTimeout(i),l(),o()),t?.abortSignal&&t.abortSignal.aborted)return o();i=setTimeout(()=>{l(),a(e)},r),t?.abortSignal&&t.abortSignal.addEventListener("abort",s)})}function h_(r,e,t){return{create:(a,n)=>new l0(a,n,r,e,t)}}var f_;(function(r){r[r.Exponential=0]="Exponential"})(f_||(f_={}));var l0=class extends It{constructor(e,t,a,n,i){super(e,t),this.retryCount=Bi(a)?a:3,this.retryInterval=Bi(n)?n:3e4,this.maxRetryInterval=Bi(i)?i:9e4}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then(t=>Wm(this,e,t)).catch(t=>Wm(this,e,t.response,void 0,t))}};async function Wm(r,e,t,a,n){function i(o){let l=o?.status;return!(l===503&&t?.headers.get(Ai.HeaderConstants.RETRY_AFTER)||l===void 0||l<500&&l!==408||l===501||l===505)}a=$m({retryInterval:r.retryInterval,minRetryInterval:0,maxRetryInterval:r.maxRetryInterval},a,n);let s=e.abortSignal&&e.abortSignal.aborted;if(!s&&Xm(r.retryCount,i,a,t)){La.info(`Retrying request in ${a.retryInterval}`);try{await Xa(a.retryInterval);let o=await r._nextPolicy.sendRequest(e.clone());return Wm(r,e,o,a)}catch(o){return Wm(r,e,t,a,o)}}else{if(s||n||!t)throw a.error||new ma("Failed to send the request.",ma.REQUEST_SEND_ERROR,t&&t.status,t&&t.request,t);return t}}function ac(r="x-ms-client-request-id"){return{create:(e,t)=>new u0(e,t,r)}}var u0=class extends It{constructor(e,t,a){super(e,t),this._requestIdHeaderName=a}sendRequest(e){return e.headers.contains(this._requestIdHeaderName)||e.headers.set(this._requestIdHeaderName,e.requestId),this._nextPolicy.sendRequest(e)}};function p0(){return"x-ms-useragent"}function y_(){let r=self.navigator;return[{key:"OS",value:(r.oscpu||r.platform).replace(" ","")}]}function AR(){return[{key:"core-http",value:Ai.coreHttpVersion}]}function BR(r,e=" ",t="/"){return r.map(a=>{let n=a.value?`${t}${a.value}`:"";return`${a.key}${n}`}).join(e)}var x_=p0;function Do(){let r=AR(),e=y_();return BR(r.concat(e))}function h0(r){let e=!r||r.key===void 0||r.key===null?p0():r.key,t=!r||r.value===void 0||r.value===null?Do():r.value;return{create:(a,n)=>new f0(a,n,e,t)}}var f0=class extends It{constructor(e,t,a,n){super(e,t),this._nextPolicy=e,this._options=t,this.headerKey=a,this.headerValue=n}sendRequest(e){return this.addUserAgentHeader(e),this._nextPolicy.sendRequest(e)}addUserAgentHeader(e){e.headers||(e.headers=new Kr),!e.headers.get(this.headerKey)&&this.headerValue&&e.headers.set(this.headerKey,this.headerValue)}};var g_=["GET","HEAD"];function v_(r=20){return{create:(e,t)=>new y0(e,t,r)}}var y0=class extends It{constructor(e,t,a=20){super(e,t),this.maxRetries=a}sendRequest(e){return this._nextPolicy.sendRequest(e).then(t=>__(this,t,0))}};function __(r,e,t){let{request:a,status:n}=e,i=e.headers.get("location");if(i&&(n===300||n===301&&g_.includes(a.method)||n===302&&g_.includes(a.method)||n===303&&a.method==="POST"||n===307)&&(!r.maxRetries||t<r.maxRetries)){let s=ar.parse(a.url);return s.setPath(i),a.url=s.toString(),n===303&&(a.method="GET",delete a.body),r._nextPolicy.sendRequest(a).then(o=>__(r,o,t+1))}return Promise.resolve(e)}function b_(r=30){return{create:(e,t)=>new x0(e,t,r)}}var x0=class extends It{constructor(e,t,a=30){super(e,t),this._retryTimeout=a}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then(t=>OR(this,e,t))}};function OR(r,e,t){if(t.status===409){let a=zR(t.bodyAsText);if(a){let n=LR(e.url);return qR(r,n,a,e).catch(()=>!1).then(i=>i?(e.headers.set("x-ms-client-request-id",Ka()),r._nextPolicy.sendRequest(e.clone())):t)}}return Promise.resolve(t)}function S_(r,e=!1){let t=r.clone();return e&&(t.url=r.url),t.headers.set("x-ms-client-request-id",Ka()),t.headers.set("Content-Type","application/json; charset=utf-8"),t}function zR(r){let e,t;if(r){try{t=JSON.parse(r)}catch{}if(t&&t.error&&t.error.message&&t.error.code&&t.error.code==="MissingSubscriptionRegistration"){let a=t.error.message.match(/.*'(.*)'/i);a&&(e=a.pop())}}return e}function LR(r){let e,t=r.match(/.*\/subscriptions\/[a-f0-9-]+\//gi);if(t&&t[0])e=t[0];else throw new Error(`Unable to extract subscriptionId from the given url - ${r}.`);return e}async function qR(r,e,t,a){let n=`${e}providers/${t}/register?api-version=2016-02-01`,i=`${e}providers/${t}?api-version=2016-02-01`,s=S_(a);if(s.method="POST",s.url=n,(await r._nextPolicy.sendRequest(s)).status!==200)throw new Error(`Autoregistration of ${t} failed. Please try registering manually.`);return N_(r,i,a)}async function N_(r,e,t){let a=S_(t);a.url=e,a.method="GET";let n=await r._nextPolicy.sendRequest(a),i=n.parsedBody;return n.parsedBody&&i.registrationState&&i.registrationState==="Registered"?!0:(await Xa(r._retryTimeout*1e3),N_(r,e,t))}var HR={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function DR(r,e,t){async function a(){if(Date.now()<t)try{return await r()}catch{return null}else{let i=await r();if(i===null)throw new Error("Failed to refresh access token.");return i}}let n=await a();for(;n===null;)await Xa(e),n=await a();return n}function kR(r,e,t){let a=null,n=null,i=Object.assign(Object.assign({},HR),t),s={get isRefreshing(){return a!==null},get shouldRefresh(){var l;return!s.isRefreshing&&((l=n?.expiresOnTimestamp)!==null&&l!==void 0?l:0)-i.refreshWindowInMs<Date.now()},get mustRefresh(){return n===null||n.expiresOnTimestamp-i.forcedRefreshWindowInMs<Date.now()}};function o(l){var c;return s.isRefreshing||(a=DR(()=>r.getToken(e,l),i.retryIntervalInMs,(c=n?.expiresOnTimestamp)!==null&&c!==void 0?c:Date.now()).then(M=>(a=null,n=M,n)).catch(M=>{throw a=null,n=null,M})),a}return async l=>s.mustRefresh?o(l):(s.shouldRefresh&&o(l),n)}function Gs(r,e){let t=kR(r,e);class a extends It{constructor(i,s){super(i,s)}async sendRequest(i){if(!i.url.toLowerCase().startsWith("https://"))throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.");let{token:s}=await t({abortSignal:i.abortSignal,tracingOptions:{tracingContext:i.tracingContext}});return i.headers.set(Ai.HeaderConstants.AUTHORIZATION,`Bearer ${s}`),this._nextPolicy.sendRequest(i)}}return{create:(n,i)=>new a(n,i)}}function P_(r,e,t,a){return{create:(n,i)=>new g0(n,i,r,e,t,a)}}var g0=class extends It{constructor(e,t,a,n,i,s){super(e,t),this.retryCount=Bi(a)?a:3,this.retryInterval=Bi(n)?n:3e4,this.minRetryInterval=Bi(i)?i:3e3,this.maxRetryInterval=Bi(s)?s:9e4}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).catch(t=>C_(this,e,t.response,t))}};async function C_(r,e,t,a,n){n=$m(r,n,a);function i(s,o){return!!(o&&o.code&&(o.code==="ETIMEDOUT"||o.code==="ESOCKETTIMEDOUT"||o.code==="ECONNREFUSED"||o.code==="ECONNRESET"||o.code==="ENOENT"))}if(Xm(r.retryCount,i,n,t,a))try{return await Xa(n.retryInterval),r._nextPolicy.sendRequest(e.clone())}catch(s){return C_(r,e,t,s,n)}else return a?Promise.reject(n.error):t}var $a;(function(r){r.Csv=",",r.Ssv=" ",r.Tsv=" ",r.Pipes="|",r.Multi="Multi"})($a||($a={}));var UR=new Error("ProxyPolicy is not supported in browser environment");function nc(r){return{create:(e,t)=>{throw UR}}}var R_=Ai.HttpConstants.StatusCodes;function T_(){return{create:(r,e)=>new ko(r,e)}}var E_="The operation was aborted.",ko=class extends It{constructor(e,t,a){super(e,t),this.numberOfRetries=0,this._handleResponse=a||this._defaultResponseHandler}async sendRequest(e){let t=await this._nextPolicy.sendRequest(e.clone());return t.status!==R_.TooManyRequests&&t.status!==R_.ServiceUnavailable?t:this._handleResponse(e,t)}async _defaultResponseHandler(e,t){var a;let n=t.headers.get(Ai.HeaderConstants.RETRY_AFTER);if(n){let i=ko.parseRetryAfterHeader(n);if(i){if(this.numberOfRetries+=1,await Xa(i,void 0,{abortSignal:e.abortSignal,abortErrorMsg:E_}),!((a=e.abortSignal)===null||a===void 0)&&a.aborted)throw new ii(E_);return this.numberOfRetries<3?this.sendRequest(e):this._nextPolicy.sendRequest(e)}}return t}static parseRetryAfterHeader(e){let t=Number(e);return Number.isNaN(t)?ko.parseDateRetryAfterHeader(e):t*1e3}static parseDateRetryAfterHeader(e){try{let t=Date.now(),n=Date.parse(e)-t;return Number.isNaN(n)?void 0:n}catch{return}}};function w_(r){return{create:(e,t)=>new v0(e,t,r)}}var v0=class extends It{constructor(e,t,a){super(e,t),this.authenticationProvider=a}signRequest(e){return this.authenticationProvider.signRequest(e)}sendRequest(e){return this.signRequest(e).then(t=>this._nextPolicy.sendRequest(t))}};var jR={enable:!0};function b0(r){return{create:(e,t)=>new _0(e,t,r||jR)}}var _0=class extends It{constructor(e,t,a){super(e,t),this.keepAliveOptions=a}async sendRequest(e){return e.keepAlive=this.keepAliveOptions.enable,this._nextPolicy.sendRequest(e)}};var I_=typeof globalThis=="object"?globalThis:typeof self=="object"?self:typeof window=="object"?window:typeof global=="object"?global:{};var ls="1.0.4";var M_=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;function VR(r){var e=new Set([r]),t=new Set,a=r.match(M_);if(!a)return function(){return!1};var n={major:+a[1],minor:+a[2],patch:+a[3],prerelease:a[4]};if(n.prerelease!=null)return function(l){return l===r};function i(o){return t.add(o),!1}function s(o){return e.add(o),!0}return function(l){if(e.has(l))return!0;if(t.has(l))return!1;var c=l.match(M_);if(!c)return i(l);var p={major:+c[1],minor:+c[2],patch:+c[3],prerelease:c[4]};return p.prerelease!=null||n.major!==p.major?i(l):n.major===0?n.minor===p.minor&&n.patch<=p.patch?s(l):i(l):n.minor<=p.minor?s(l):i(l)}}var A_=VR(ls);var GR=ls.split(".")[0],ic=Symbol.for("opentelemetry.js.api."+GR),sc=I_;function cs(r,e,t,a){var n;a===void 0&&(a=!1);var i=sc[ic]=(n=sc[ic])!==null&&n!==void 0?n:{version:ls};if(!a&&i[r]){var s=new Error("@opentelemetry/api: Attempted duplicate registration of API: "+r);return t.error(s.stack||s.message),!1}if(i.version!==ls){var s=new Error("@opentelemetry/api: All API registration versions must match");return t.error(s.stack||s.message),!1}return i[r]=e,t.debug("@opentelemetry/api: Registered a global for "+r+" v"+ls+"."),!0}function Bn(r){var e,t,a=(e=sc[ic])===null||e===void 0?void 0:e.version;if(!(!a||!A_(a)))return(t=sc[ic])===null||t===void 0?void 0:t[r]}function ms(r,e){e.debug("@opentelemetry/api: Unregistering a global for "+r+" v"+ls+".");var t=sc[ic];t&&delete t[r]}var B_=function(){function r(e){this._namespace=e.namespace||"DiagComponentLogger"}return r.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return oc("debug",this._namespace,e)},r.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return oc("error",this._namespace,e)},r.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return oc("info",this._namespace,e)},r.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return oc("warn",this._namespace,e)},r.prototype.verbose=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return oc("verbose",this._namespace,e)},r}();function oc(r,e,t){var a=Bn("diag");if(!!a)return t.unshift(e),a[r].apply(a,t)}var qa;(function(r){r[r.NONE=0]="NONE",r[r.ERROR=30]="ERROR",r[r.WARN=50]="WARN",r[r.INFO=60]="INFO",r[r.DEBUG=70]="DEBUG",r[r.VERBOSE=80]="VERBOSE",r[r.ALL=9999]="ALL"})(qa||(qa={}));function O_(r,e){r<qa.NONE?r=qa.NONE:r>qa.ALL&&(r=qa.ALL),e=e||{};function t(a,n){var i=e[a];return typeof i=="function"&&r>=n?i.bind(e):function(){}}return{error:t("error",qa.ERROR),warn:t("warn",qa.WARN),info:t("info",qa.INFO),debug:t("debug",qa.DEBUG),verbose:t("verbose",qa.VERBOSE)}}var KR="diag",Wa=function(){function r(){function e(a){return function(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];var s=Bn("diag");if(!!s)return s[a].apply(s,n)}}var t=this;t.setLogger=function(a,n){var i,s;if(n===void 0&&(n=qa.INFO),a===t){var o=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");return t.error((i=o.stack)!==null&&i!==void 0?i:o.message),!1}var l=Bn("diag"),c=O_(n,a);if(l){var p=(s=new Error().stack)!==null&&s!==void 0?s:"<failed to generate stacktrace>";l.warn("Current logger will be overwritten from "+p),c.warn("Current logger will overwrite one already registered from "+p)}return cs("diag",c,t,!0)},t.disable=function(){ms(KR,t)},t.createComponentLogger=function(a){return new B_(a)},t.verbose=e("verbose"),t.debug=e("debug"),t.info=e("info"),t.warn=e("warn"),t.error=e("error")}return r.instance=function(){return this._instance||(this._instance=new r),this._instance},r}();var z_=function(){function r(e){this._entries=e?new Map(e):new Map}return r.prototype.getEntry=function(e){var t=this._entries.get(e);if(!!t)return Object.assign({},t)},r.prototype.getAllEntries=function(){return Array.from(this._entries.entries()).map(function(e){var t=e[0],a=e[1];return[t,a]})},r.prototype.setEntry=function(e,t){var a=new r(this._entries);return a._entries.set(e,t),a},r.prototype.removeEntry=function(e){var t=new r(this._entries);return t._entries.delete(e),t},r.prototype.removeEntries=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var a=new r(this._entries),n=0,i=e;n<i.length;n++){var s=i[n];a._entries.delete(s)}return a},r.prototype.clear=function(){return new r},r}();var XR=Symbol("BaggageEntryMetadata");var cA=Wa.instance();function L_(r){return r===void 0&&(r={}),new z_(new Map(Object.entries(r)))}var S0=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}],dA=function(){function r(){function e(a){return function(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];if(console){var s=console[a];if(typeof s!="function"&&(s=console.log),typeof s=="function")return s.apply(console,n)}}}for(var t=0;t<S0.length;t++)this[S0[t].n]=e(S0[t].c)}return r}();var q_={get:function(r,e){if(r!=null)return r[e]},keys:function(r){return r==null?[]:Object.keys(r)}},H_={set:function(r,e,t){r!=null&&(r[e]=t)}};function Ym(r){return Symbol.for(r)}var $R=function(){function r(e){var t=this;t._currentContext=e?new Map(e):new Map,t.getValue=function(a){return t._currentContext.get(a)},t.setValue=function(a,n){var i=new r(t._currentContext);return i._currentContext.set(a,n),i},t.deleteValue=function(a){var n=new r(t._currentContext);return n._currentContext.delete(a),n}}return r}(),D_=new $R;var WR=function(r,e){for(var t=0,a=e.length,n=r.length;t<a;t++,n++)r[n]=e[t];return r},k_=function(){function r(){}return r.prototype.active=function(){return D_},r.prototype.with=function(e,t,a){for(var n=[],i=3;i<arguments.length;i++)n[i-3]=arguments[i];return t.call.apply(t,WR([a],n))},r.prototype.bind=function(e,t){return t},r.prototype.enable=function(){return this},r.prototype.disable=function(){return this},r}();var YR=function(r,e){for(var t=0,a=e.length,n=r.length;t<a;t++,n++)r[n]=e[t];return r},N0="context",QR=new k_,Qm=function(){function r(){}return r.getInstance=function(){return this._instance||(this._instance=new r),this._instance},r.prototype.setGlobalContextManager=function(e){return cs(N0,e,Wa.instance())},r.prototype.active=function(){return this._getContextManager().active()},r.prototype.with=function(e,t,a){for(var n,i=[],s=3;s<arguments.length;s++)i[s-3]=arguments[s];return(n=this._getContextManager()).with.apply(n,YR([e,t,a],i))},r.prototype.bind=function(e,t){return this._getContextManager().bind(e,t)},r.prototype._getContextManager=function(){return Bn(N0)||QR},r.prototype.disable=function(){this._getContextManager().disable(),ms(N0,Wa.instance())},r}();var Zm;(function(r){r[r.NONE=0]="NONE",r[r.SAMPLED=1]="SAMPLED"})(Zm||(Zm={}));var Jm="0000000000000000",ed="00000000000000000000000000000000",lc={traceId:ed,spanId:Jm,traceFlags:Zm.NONE};var ds=function(){function r(e){e===void 0&&(e=lc),this._spanContext=e}return r.prototype.spanContext=function(){return this._spanContext},r.prototype.setAttribute=function(e,t){return this},r.prototype.setAttributes=function(e){return this},r.prototype.addEvent=function(e,t){return this},r.prototype.setStatus=function(e){return this},r.prototype.updateName=function(e){return this},r.prototype.end=function(e){},r.prototype.isRecording=function(){return!1},r.prototype.recordException=function(e,t){},r}();var P0=Ym("OpenTelemetry Context Key SPAN");function C0(r){return r.getValue(P0)||void 0}function cc(r,e){return r.setValue(P0,e)}function F_(r){return r.deleteValue(P0)}function U_(r,e){return cc(r,new ds(e))}function td(r){var e;return(e=C0(r))===null||e===void 0?void 0:e.spanContext()}var ZR=/^([0-9a-f]{32})$/i,JR=/^[0-9a-f]{16}$/i;function j_(r){return ZR.test(r)&&r!==ed}function V_(r){return JR.test(r)&&r!==Jm}function mc(r){return j_(r.traceId)&&V_(r.spanId)}function G_(r){return new ds(r)}var K_=Qm.getInstance(),rd=function(){function r(){}return r.prototype.startSpan=function(e,t,a){var n=Boolean(t?.root);if(n)return new ds;var i=a&&td(a);return eE(i)&&mc(i)?new ds(i):new ds},r.prototype.startActiveSpan=function(e,t,a,n){var i,s,o;if(!(arguments.length<2)){arguments.length===2?o=t:arguments.length===3?(i=t,o=a):(i=t,s=a,o=n);var l=s??K_.active(),c=this.startSpan(e,i,l),p=cc(l,c);return K_.with(p,o,void 0,c)}},r}();function eE(r){return typeof r=="object"&&typeof r.spanId=="string"&&typeof r.traceId=="string"&&typeof r.traceFlags=="number"}var tE=new rd,X_=function(){function r(e,t,a){this._provider=e,this.name=t,this.version=a}return r.prototype.startSpan=function(e,t,a){return this._getTracer().startSpan(e,t,a)},r.prototype.startActiveSpan=function(e,t,a,n){var i=this._getTracer();return Reflect.apply(i.startActiveSpan,i,arguments)},r.prototype._getTracer=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateTracer(this.name,this.version);return e?(this._delegate=e,this._delegate):tE},r}();var $_=function(){function r(){}return r.prototype.getTracer=function(e,t){return new rd},r}();var rE=new $_,R0=function(){function r(){}return r.prototype.getTracer=function(e,t){var a;return(a=this.getDelegateTracer(e,t))!==null&&a!==void 0?a:new X_(this,e,t)},r.prototype.getDelegate=function(){var e;return(e=this._delegate)!==null&&e!==void 0?e:rE},r.prototype.setDelegate=function(e){this._delegate=e},r.prototype.getDelegateTracer=function(e,t){var a;return(a=this._delegate)===null||a===void 0?void 0:a.getTracer(e,t)},r}();var W_;(function(r){r[r.NOT_RECORD=0]="NOT_RECORD",r[r.RECORD=1]="RECORD",r[r.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"})(W_||(W_={}));var Y_;(function(r){r[r.INTERNAL=0]="INTERNAL",r[r.SERVER=1]="SERVER",r[r.CLIENT=2]="CLIENT",r[r.PRODUCER=3]="PRODUCER",r[r.CONSUMER=4]="CONSUMER"})(Y_||(Y_={}));var Q_;(function(r){r[r.UNSET=0]="UNSET",r[r.OK=1]="OK",r[r.ERROR=2]="ERROR"})(Q_||(Q_={}));var E0="trace",Z_=function(){function r(){this._proxyTracerProvider=new R0,this.wrapSpanContext=G_,this.isSpanContextValid=mc,this.deleteSpan=F_,this.getSpan=C0,this.getSpanContext=td,this.setSpan=cc,this.setSpanContext=U_}return r.getInstance=function(){return this._instance||(this._instance=new r),this._instance},r.prototype.setGlobalTracerProvider=function(e){var t=cs(E0,this._proxyTracerProvider,Wa.instance());return t&&this._proxyTracerProvider.setDelegate(e),t},r.prototype.getTracerProvider=function(){return Bn(E0)||this._proxyTracerProvider},r.prototype.getTracer=function(e,t){return this.getTracerProvider().getTracer(e,t)},r.prototype.disable=function(){ms(E0,Wa.instance()),this._proxyTracerProvider=new R0},r}();var J_=function(){function r(){}return r.prototype.inject=function(e,t){},r.prototype.extract=function(e,t){return e},r.prototype.fields=function(){return[]},r}();var T0=Ym("OpenTelemetry Baggage Key");function eb(r){return r.getValue(T0)||void 0}function tb(r,e){return r.setValue(T0,e)}function rb(r){return r.deleteValue(T0)}var w0="propagation",aE=new J_,ab=function(){function r(){this.createBaggage=L_,this.getBaggage=eb,this.setBaggage=tb,this.deleteBaggage=rb}return r.getInstance=function(){return this._instance||(this._instance=new r),this._instance},r.prototype.setGlobalPropagator=function(e){return cs(w0,e,Wa.instance())},r.prototype.inject=function(e,t,a){return a===void 0&&(a=H_),this._getGlobalPropagator().inject(e,t,a)},r.prototype.extract=function(e,t,a){return a===void 0&&(a=q_),this._getGlobalPropagator().extract(e,t,a)},r.prototype.fields=function(){return this._getGlobalPropagator().fields()},r.prototype.disable=function(){ms(w0,Wa.instance())},r.prototype._getGlobalPropagator=function(){return Bn(w0)||aE},r}();var nb=Qm.getInstance(),Fo=Z_.getInstance(),yB=ab.getInstance(),gB=Wa.instance();var Ks;(function(r){r[r.INTERNAL=0]="INTERNAL",r[r.SERVER=1]="SERVER",r[r.CLIENT=2]="CLIENT",r[r.PRODUCER=3]="PRODUCER",r[r.CONSUMER=4]="CONSUMER"})(Ks||(Ks={}));function I0(r,e){return Fo.setSpan(r,e)}function M0(r){return Fo.isSpanContextValid(r)}function A0(r,e){return Fo.getTracer(r||"azure/core-tracing",e)}var B0=nb,qe;(function(r){r[r.UNSET=0]="UNSET",r[r.OK=1]="OK",r[r.ERROR=2]="ERROR"})(qe||(qe={}));function nE(){var r;if(typeof process>"u")return!1;let e=(r=process.env.AZURE_TRACING_DISABLED)===null||r===void 0?void 0:r.toLowerCase();return e==="false"||e==="0"?!1:Boolean(e)}function dc(r){return function(e,t){let a=A0(),n=t?.tracingOptions||{},i=Object.assign({kind:Ks.INTERNAL},n.spanOptions),s=r.packagePrefix?`${r.packagePrefix}.${e}`:e,o;nE()?o=Fo.wrapSpanContext(lc):o=a.startSpan(s,i,n.tracingContext),r.namespace&&o.setAttribute("az.namespace",r.namespace);let l=n.spanOptions||{};o.isRecording()&&r.namespace&&(l=Object.assign(Object.assign({},n.spanOptions),{attributes:Object.assign(Object.assign({},i.attributes),{"az.namespace":r.namespace})}));let c=Object.assign(Object.assign({},n),{spanOptions:l,tracingContext:I0(n.tracingContext||B0.active(),o)}),p=Object.assign(Object.assign({},t),{tracingOptions:c});return{span:o,updatedOptions:p}}}var iE="00";function O0(r){let e=[];if(r.traceId||e.push("traceId"),r.spanId||e.push("spanId"),e.length)return;let a=(r.traceFlags||0).toString(16),n=a.length===1?`0${a}`:a;return`${iE}-${r.traceId}-${r.spanId}-${n}`}var sE=dc({packagePrefix:"",namespace:""});function L0(r={}){return{create(e,t){return new z0(e,t,r)}}}var z0=class extends It{constructor(e,t,a){super(e,t),this.userAgent=a.userAgent}async sendRequest(e){if(!e.tracingContext)return this._nextPolicy.sendRequest(e);let t=this.tryCreateSpan(e);if(!t)return this._nextPolicy.sendRequest(e);try{let a=await this._nextPolicy.sendRequest(e);return this.tryProcessResponse(t,a),a}catch(a){throw this.tryProcessError(t,a),a}}tryCreateSpan(e){var t;try{let a=ar.parse(e.url).getPath()||"/",{span:n}=sE(a,{tracingOptions:{spanOptions:Object.assign(Object.assign({},e.spanOptions),{kind:Ks.CLIENT}),tracingContext:e.tracingContext}});if(!n.isRecording()){n.end();return}let i=(t=e.tracingContext)===null||t===void 0?void 0:t.getValue(Symbol.for("az.namespace"));typeof i=="string"&&n.setAttribute("az.namespace",i),n.setAttributes({"http.method":e.method,"http.url":e.url,requestId:e.requestId}),this.userAgent&&n.setAttribute("http.user_agent",this.userAgent);let s=n.spanContext(),o=O0(s);if(o&&M0(s)){e.headers.set("traceparent",o);let l=s.traceState&&s.traceState.serialize();l&&e.headers.set("tracestate",l)}return n}catch(a){La.warning(`Skipping creating a tracing span due to an error: ${a.message}`);return}}tryProcessError(e,t){try{e.setStatus({code:qe.ERROR,message:t.message}),t.statusCode&&e.setAttribute("http.status_code",t.statusCode),e.end()}catch(a){La.warning(`Skipping tracing span processing due to an error: ${a.message}`)}}tryProcessResponse(e,t){try{e.setAttribute("http.status_code",t.status);let a=t.headers.get("x-ms-request-id");a&&e.setAttribute("serviceRequestId",a),e.setStatus({code:qe.OK}),e.end()}catch(a){La.warning(`Skipping tracing span processing due to an error: ${a.message}`)}}};var oE=new Error("DisableResponseDecompressionPolicy is not supported in browser environment");function q0(){return{create:(r,e)=>{throw oE}}}var H0;function ib(){return H0||(H0=new os),H0}var pc=class{constructor(e,t){t||(t={}),this._withCredentials=t.withCredentials||!1,this._httpClient=t.httpClient||ib(),this._requestPolicyOptions=new qo(t.httpPipelineLogger);let a;if(Array.isArray(t.requestPolicyFactories))La.info("ServiceClient: using custom request policies"),a=t.requestPolicyFactories;else{let n;if(Ar(e))La.info("ServiceClient: creating bearer token authentication policy from provided credentials"),n=(()=>{let s,o=this,l=t;return{create(c,p){let M=dE(l,o.baseUri);if(!M)throw new Error("When using credential, the ServiceClient must contain a baseUri or a credentialScopes in ServiceClientOptions. Unable to create a bearerTokenAuthenticationPolicy");return s==null&&(s=Gs(e,M)),s.create(c,p)}}})();else if(e&&typeof e.signRequest=="function")La.info("ServiceClient: creating signing policy from provided credentials"),n=w_(e);else if(e!=null)throw new Error("The credentials argument must implement the TokenCredential interface");if(La.info("ServiceClient: using default request policies"),a=mE(n,t),t.requestPolicyFactories){let i=t.requestPolicyFactories(a);i&&(a=i)}}this._requestPolicyFactories=a}sendRequest(e){if(e==null||typeof e!="object")throw new Error("options cannot be null or undefined and it must be of type object.");let t;try{Jg(e)?(e.validateRequestProperties(),t=e):(t=new An,t=t.prepare(e))}catch(n){return Promise.reject(n)}let a=this._httpClient;if(this._requestPolicyFactories&&this._requestPolicyFactories.length>0)for(let n=this._requestPolicyFactories.length-1;n>=0;--n)a=this._requestPolicyFactories[n].create(a,this._requestPolicyOptions);return a.sendRequest(t)}async sendOperationRequest(e,t,a){var n;typeof e.options=="function"&&(a=e.options,e.options=void 0);let i=(n=e.options)===null||n===void 0?void 0:n.serializerOptions,s=new An,o;try{let c=t.baseUrl||this.baseUri;if(!c)throw new Error("If operationSpec.baseUrl is not specified, then the ServiceClient must have a baseUri string property that contains the base URL to use.");s.method=t.httpMethod,s.operationSpec=t;let p=ar.parse(c);if(t.path&&p.appendPath(t.path),t.urlParameters&&t.urlParameters.length>0)for(let q of t.urlParameters){let C=uc(this,e,q,t.serializer);C=t.serializer.serialize(q.mapper,C,oi(q),i),q.skipEncoding||(C=encodeURIComponent(C)),p.replaceAll(`{${q.mapper.serializedName||oi(q)}}`,C)}if(t.queryParameters&&t.queryParameters.length>0)for(let q of t.queryParameters){let C=uc(this,e,q,t.serializer);if(C!=null){if(C=t.serializer.serialize(q.mapper,C,oi(q),i),q.collectionFormat!==void 0&&q.collectionFormat!==null)if(q.collectionFormat===$a.Multi){if(C.length===0)continue;for(let W in C){let ae=C[W];C[W]=ae==null?"":ae.toString()}}else(q.collectionFormat===$a.Ssv||q.collectionFormat===$a.Tsv)&&(C=C.join(q.collectionFormat));if(!q.skipEncoding)if(Array.isArray(C))for(let W in C)C[W]!==void 0&&C[W]!==null&&(C[W]=encodeURIComponent(C[W]));else C=encodeURIComponent(C);q.collectionFormat!==void 0&&q.collectionFormat!==null&&q.collectionFormat!==$a.Multi&&q.collectionFormat!==$a.Ssv&&q.collectionFormat!==$a.Tsv&&(C=C.join(q.collectionFormat)),p.setQueryParameter(q.mapper.serializedName||oi(q),C)}}s.url=p.toString();let M=t.contentType||this.requestContentType;if(M&&t.requestBody&&s.headers.set("Content-Type",M),t.headerParameters)for(let q of t.headerParameters){let C=uc(this,e,q,t.serializer);if(C!=null){C=t.serializer.serialize(q.mapper,C,oi(q),i);let W=q.mapper.headerCollectionPrefix;if(W)for(let ae of Object.keys(C))s.headers.set(W+ae,C[ae]);else s.headers.set(q.mapper.serializedName||oi(q),C)}}let S=e.options;if(S){if(S.customHeaders)for(let q in S.customHeaders)s.headers.set(q,S.customHeaders[q]);S.abortSignal&&(s.abortSignal=S.abortSignal),S.timeout&&(s.timeout=S.timeout),S.onUploadProgress&&(s.onUploadProgress=S.onUploadProgress),S.onDownloadProgress&&(s.onDownloadProgress=S.onDownloadProgress),S.spanOptions&&(s.spanOptions=S.spanOptions),S.tracingContext&&(s.tracingContext=S.tracingContext),S.shouldDeserialize!==void 0&&S.shouldDeserialize!==null&&(s.shouldDeserialize=S.shouldDeserialize)}s.withCredentials=this._withCredentials,lE(this,s,e,t),s.streamResponseStatusCodes===void 0&&(s.streamResponseStatusCodes=c_(t));let O,E;try{O=await this.sendRequest(s)}catch(q){E=q}E?(E.response&&(E.details=D0(E.response,t.responses[E.statusCode]||t.responses.default)),o=Promise.reject(E)):o=Promise.resolve(D0(O,t.responses[O.status]))}catch(c){o=Promise.reject(c)}let l=a;return l&&o.then(c=>l(null,c._response.parsedBody,c._response.request,c._response)).catch(c=>l(c)),o}};function lE(r,e,t,a){var n,i,s,o,l,c;let p=(i=(n=t.options)===null||n===void 0?void 0:n.serializerOptions)!==null&&i!==void 0?i:{},M={rootName:(s=p.rootName)!==null&&s!==void 0?s:"",includeRoot:(o=p.includeRoot)!==null&&o!==void 0?o:!1,xmlCharKey:(l=p.xmlCharKey)!==null&&l!==void 0?l:Mn},S=p.xmlCharKey;if(a.requestBody&&a.requestBody.mapper){e.body=uc(r,t,a.requestBody,a.serializer);let O=a.requestBody.mapper,{required:E,xmlName:q,xmlElementName:C,serializedName:W,xmlNamespace:ae,xmlNamespacePrefix:Ce}=O,et=O.type.name;try{if(e.body!==void 0&&e.body!==null||E){let gt=oi(a.requestBody);e.body=a.serializer.serialize(O,e.body,gt,M);let _t=et===ni.Stream;if(a.isXML){let dt=Ce?`xmlns:${Ce}`:"xmlns",Tt=cE(ae,dt,et,e.body,M);et===ni.Sequence?e.body=s0(Gg(Tt,C||q||W,dt,ae),{rootName:q||W,xmlCharKey:S}):_t||(e.body=s0(Tt,{rootName:q||W,xmlCharKey:S}))}else{if(et===ni.String&&(((c=a.contentType)===null||c===void 0?void 0:c.match("text/plain"))||a.mediaType==="text"))return;_t||(e.body=JSON.stringify(e.body))}}}catch(gt){throw new Error(`Error "${gt.message}" occurred in serializing the payload - ${JSON.stringify(W,void 0," ")}.`)}}else if(a.formDataParameters&&a.formDataParameters.length>0){e.formData={};for(let O of a.formDataParameters){let E=uc(r,t,O,a.serializer);if(E!=null){let q=O.mapper.serializedName||oi(O);e.formData[q]=a.serializer.serialize(O.mapper,E,oi(O),M)}}}}function cE(r,e,t,a,n){if(r&&!["Composite","Sequence","Dictionary"].includes(t)){let i={};return i[n.xmlCharKey]=a,i[vr]={[e]:r},i}return a}function sb(r,e){let t;return typeof r=="string"?t=r:(t=e(),typeof r=="function"&&(t=r(t))),t}function mE(r,e){let t=[];e.generateClientRequestIdHeader&&t.push(ac(e.clientRequestIdHeaderName)),r&&t.push(r);let a=sb(e.userAgentHeaderName,x_),n=sb(e.userAgent,Do);return a&&n&&t.push(h0({key:a,value:n})),t.push(v_()),t.push(b_(e.rpRegistrationRetryTimeout)),e.noRetryPolicy||(t.push(h_()),t.push(P_()),t.push(T_())),t.push(Vs(e.deserializationContentTypes)),Lt&&t.push(nc(e.proxySettings)),t.push(tc({logger:La.info})),t}function uc(r,e,t,a){return lb(r,e,t.parameterPath,t.mapper,a)}function lb(r,e,t,a,n){var i;let s;typeof t=="string"&&(t=[t]);let o=(i=e.options)===null||i===void 0?void 0:i.serializerOptions;if(Array.isArray(t)){if(t.length>0){if(a.isConstant)s=a.defaultValue;else{let c=ob(e,t);c.propertyFound||(c=ob(r,t));let p=!1;c.propertyFound||(p=a.required||t[0]==="options"&&t.length===2),s=p?a.defaultValue:c.propertyValue}let l=Km(t,a);n.serialize(a,s,l,o)}}else{a.required&&(s={});for(let l in t){let c=a.type.modelProperties[l],p=t[l],M=lb(r,e,p,c,n),S=Km(p,c);n.serialize(c,M,S,o),M!=null&&(s||(s={}),s[l]=M)}}return s}function ob(r,e){let t={propertyFound:!1},a=0;for(;a<e.length;++a){let n=e[a];if(r!=null&&n in r)r=r[n];else break}return a===e.length&&(t.propertyValue=r,t.propertyFound=!0),t}function D0(r,e){let t=r.parsedHeaders,a=e&&e.bodyMapper,n=i=>Object.defineProperty(i,"_response",{value:r});if(a){let i=a.type.name;if(i==="Stream")return n(Object.assign(Object.assign({},t),{blobBody:r.blobBody,readableStreamBody:r.readableStreamBody}));let s=i==="Composite"&&a.type.modelProperties||{},o=Object.keys(s).some(l=>s[l].serializedName==="");if(i==="Sequence"||o){let l=[...r.parsedBody||[]];for(let c of Object.keys(s))s[c].serializedName&&(l[c]=r.parsedBody[c]);if(t)for(let c of Object.keys(t))l[c]=t[c];return n(l),l}if(i==="Composite"||i==="Dictionary")return n(Object.assign(Object.assign({},t),r.parsedBody))}return a||r.request.method==="HEAD"||Kg(r.parsedBody)?n(Object.assign(Object.assign({},t),{body:r.parsedBody})):n(Object.assign(Object.assign({},t),r.parsedBody))}function dE(r,e){if(r?.credentialScopes){let t=r.credentialScopes;return Array.isArray(t)?t.map(a=>new Om(a).toString()):new Om(t).toString()}if(e)return`${e}/.default`}(typeof Symbol===void 0||!Symbol.asyncIterator)&&(Symbol.asyncIterator=Symbol.for("Symbol.asyncIterator"));var Ib=ns(wb(),1),{__extends:b9,__assign:S9,__rest:N9,__decorate:P9,__param:C9,__metadata:R9,__awaiter:E9,__generator:T9,__exportStar:w9,__createBinding:I9,__values:M9,__read:A9,__spread:B9,__spreadArrays:O9,__spreadArray:z9,__await:dr,__asyncGenerator:li,__asyncDelegator:fc,__asyncValues:Oi,__makeTemplateObject:L9,__importStar:q9,__importDefault:H9,__classPrivateFieldGet:D9,__classPrivateFieldSet:k9}=Ib.default;var ya={};TC(ya,{AccessPolicy:()=>NE,AppendBlobAppendBlockExceptionHeaders:()=>o1,AppendBlobAppendBlockFromUrlExceptionHeaders:()=>c1,AppendBlobAppendBlockFromUrlHeaders:()=>l1,AppendBlobAppendBlockHeaders:()=>s1,AppendBlobCreateExceptionHeaders:()=>i1,AppendBlobCreateHeaders:()=>n1,AppendBlobSealExceptionHeaders:()=>d1,AppendBlobSealHeaders:()=>m1,ArrowConfiguration:()=>LE,ArrowField:()=>qE,BlobAbortCopyFromURLExceptionHeaders:()=>Mh,BlobAbortCopyFromURLHeaders:()=>Ih,BlobAcquireLeaseExceptionHeaders:()=>hh,BlobAcquireLeaseHeaders:()=>fh,BlobBreakLeaseExceptionHeaders:()=>Nh,BlobBreakLeaseHeaders:()=>Sh,BlobChangeLeaseExceptionHeaders:()=>bh,BlobChangeLeaseHeaders:()=>_h,BlobCopyFromURLExceptionHeaders:()=>wh,BlobCopyFromURLHeaders:()=>Th,BlobCreateSnapshotExceptionHeaders:()=>Ch,BlobCreateSnapshotHeaders:()=>Ph,BlobDeleteExceptionHeaders:()=>Jf,BlobDeleteHeaders:()=>Zf,BlobDeleteImmutabilityPolicyExceptionHeaders:()=>ch,BlobDeleteImmutabilityPolicyHeaders:()=>lh,BlobDownloadExceptionHeaders:()=>Wf,BlobDownloadHeaders:()=>od,BlobFlatListSegment:()=>PE,BlobGetAccountInfoExceptionHeaders:()=>Oh,BlobGetAccountInfoHeaders:()=>Bh,BlobGetPropertiesExceptionHeaders:()=>Qf,BlobGetPropertiesHeaders:()=>Yf,BlobGetTagsExceptionHeaders:()=>qh,BlobGetTagsHeaders:()=>Lh,BlobHierarchyListSegment:()=>EE,BlobItemInternal:()=>CE,BlobPrefix:()=>TE,BlobPropertiesInternal:()=>RE,BlobQueryExceptionHeaders:()=>zh,BlobQueryHeaders:()=>cd,BlobReleaseLeaseExceptionHeaders:()=>xh,BlobReleaseLeaseHeaders:()=>yh,BlobRenewLeaseExceptionHeaders:()=>vh,BlobRenewLeaseHeaders:()=>gh,BlobServiceProperties:()=>hc,BlobServiceStatistics:()=>U0,BlobSetExpiryExceptionHeaders:()=>ah,BlobSetExpiryHeaders:()=>rh,BlobSetHttpHeadersExceptionHeaders:()=>ih,BlobSetHttpHeadersHeaders:()=>nh,BlobSetImmutabilityPolicyExceptionHeaders:()=>oh,BlobSetImmutabilityPolicyHeaders:()=>sh,BlobSetLegalHoldExceptionHeaders:()=>dh,BlobSetLegalHoldHeaders:()=>mh,BlobSetMetadataExceptionHeaders:()=>ph,BlobSetMetadataHeaders:()=>uh,BlobSetTagsExceptionHeaders:()=>Dh,BlobSetTagsHeaders:()=>Hh,BlobSetTierExceptionHeaders:()=>Ah,BlobSetTierHeaders:()=>ld,BlobStartCopyFromURLExceptionHeaders:()=>Eh,BlobStartCopyFromURLHeaders:()=>Rh,BlobTag:()=>bE,BlobTags:()=>yc,BlobUndeleteExceptionHeaders:()=>th,BlobUndeleteHeaders:()=>eh,Block:()=>wE,BlockBlobCommitBlockListExceptionHeaders:()=>b1,BlockBlobCommitBlockListHeaders:()=>_1,BlockBlobGetBlockListExceptionHeaders:()=>N1,BlockBlobGetBlockListHeaders:()=>S1,BlockBlobPutBlobFromUrlExceptionHeaders:()=>h1,BlockBlobPutBlobFromUrlHeaders:()=>f1,BlockBlobStageBlockExceptionHeaders:()=>x1,BlockBlobStageBlockFromURLExceptionHeaders:()=>v1,BlockBlobStageBlockFromURLHeaders:()=>g1,BlockBlobStageBlockHeaders:()=>y1,BlockBlobUploadExceptionHeaders:()=>p1,BlockBlobUploadHeaders:()=>u1,BlockList:()=>Y0,BlockLookupList:()=>W0,ClearRange:()=>ME,ContainerAcquireLeaseExceptionHeaders:()=>Of,ContainerAcquireLeaseHeaders:()=>Bf,ContainerBreakLeaseExceptionHeaders:()=>kf,ContainerBreakLeaseHeaders:()=>Df,ContainerChangeLeaseExceptionHeaders:()=>Uf,ContainerChangeLeaseHeaders:()=>Ff,ContainerCreateExceptionHeaders:()=>yf,ContainerCreateHeaders:()=>hf,ContainerDeleteExceptionHeaders:()=>_f,ContainerDeleteHeaders:()=>vf,ContainerGetAccessPolicyExceptionHeaders:()=>Pf,ContainerGetAccessPolicyHeaders:()=>Nf,ContainerGetAccountInfoExceptionHeaders:()=>$f,ContainerGetAccountInfoHeaders:()=>Xf,ContainerGetPropertiesExceptionHeaders:()=>gf,ContainerGetPropertiesHeaders:()=>xf,ContainerItem:()=>gE,ContainerListBlobFlatSegmentExceptionHeaders:()=>Vf,ContainerListBlobFlatSegmentHeaders:()=>jf,ContainerListBlobHierarchySegmentExceptionHeaders:()=>Kf,ContainerListBlobHierarchySegmentHeaders:()=>Gf,ContainerProperties:()=>vE,ContainerReleaseLeaseExceptionHeaders:()=>Lf,ContainerReleaseLeaseHeaders:()=>zf,ContainerRenameExceptionHeaders:()=>If,ContainerRenameHeaders:()=>wf,ContainerRenewLeaseExceptionHeaders:()=>Hf,ContainerRenewLeaseHeaders:()=>qf,ContainerRestoreExceptionHeaders:()=>Tf,ContainerRestoreHeaders:()=>Ef,ContainerSetAccessPolicyExceptionHeaders:()=>Rf,ContainerSetAccessPolicyHeaders:()=>Cf,ContainerSetMetadataExceptionHeaders:()=>Sf,ContainerSetMetadataHeaders:()=>bf,ContainerSubmitBatchExceptionHeaders:()=>Af,ContainerSubmitBatchHeaders:()=>Mf,CorsRule:()=>hE,DelimitedTextConfiguration:()=>OE,FilterBlobItem:()=>_E,FilterBlobSegment:()=>K0,GeoReplication:()=>xE,JsonTextConfiguration:()=>zE,KeyInfo:()=>V0,ListBlobsFlatSegmentResponse:()=>X0,ListBlobsHierarchySegmentResponse:()=>$0,ListContainersSegmentResponse:()=>j0,Logging:()=>uE,Metrics:()=>fE,PageBlobClearPagesExceptionHeaders:()=>Gh,PageBlobClearPagesHeaders:()=>Vh,PageBlobCopyIncrementalExceptionHeaders:()=>a1,PageBlobCopyIncrementalHeaders:()=>r1,PageBlobCreateExceptionHeaders:()=>Fh,PageBlobCreateHeaders:()=>kh,PageBlobGetPageRangesDiffExceptionHeaders:()=>Qh,PageBlobGetPageRangesDiffHeaders:()=>Yh,PageBlobGetPageRangesExceptionHeaders:()=>Wh,PageBlobGetPageRangesHeaders:()=>$h,PageBlobResizeExceptionHeaders:()=>Jh,PageBlobResizeHeaders:()=>Zh,PageBlobUpdateSequenceNumberExceptionHeaders:()=>t1,PageBlobUpdateSequenceNumberHeaders:()=>e1,PageBlobUploadPagesExceptionHeaders:()=>jh,PageBlobUploadPagesFromURLExceptionHeaders:()=>Xh,PageBlobUploadPagesFromURLHeaders:()=>Kh,PageBlobUploadPagesHeaders:()=>Uh,PageList:()=>sd,PageRange:()=>IE,QueryFormat:()=>BE,QueryRequest:()=>Q0,QuerySerialization:()=>AE,RetentionPolicy:()=>pE,ServiceFilterBlobsExceptionHeaders:()=>ff,ServiceFilterBlobsHeaders:()=>pf,ServiceGetAccountInfoExceptionHeaders:()=>mf,ServiceGetAccountInfoHeaders:()=>cf,ServiceGetPropertiesExceptionHeaders:()=>tf,ServiceGetPropertiesHeaders:()=>ef,ServiceGetStatisticsExceptionHeaders:()=>af,ServiceGetStatisticsHeaders:()=>rf,ServiceGetUserDelegationKeyExceptionHeaders:()=>lf,ServiceGetUserDelegationKeyHeaders:()=>of,ServiceListContainersSegmentExceptionHeaders:()=>sf,ServiceListContainersSegmentHeaders:()=>nf,ServiceSetPropertiesExceptionHeaders:()=>J0,ServiceSetPropertiesHeaders:()=>Z0,ServiceSubmitBatchExceptionHeaders:()=>uf,ServiceSubmitBatchHeaders:()=>df,SignedIdentifier:()=>SE,StaticWebsite:()=>yE,StorageError:()=>Qe,UserDelegationKey:()=>G0});var hc={serializedName:"BlobServiceProperties",xmlName:"StorageServiceProperties",type:{name:"Composite",className:"BlobServiceProperties",modelProperties:{blobAnalyticsLogging:{serializedName:"Logging",xmlName:"Logging",type:{name:"Composite",className:"Logging"}},hourMetrics:{serializedName:"HourMetrics",xmlName:"HourMetrics",type:{name:"Composite",className:"Metrics"}},minuteMetrics:{serializedName:"MinuteMetrics",xmlName:"MinuteMetrics",type:{name:"Composite",className:"Metrics"}},cors:{serializedName:"Cors",xmlName:"Cors",xmlIsWrapped:!0,xmlElementName:"CorsRule",type:{name:"Sequence",element:{type:{name:"Composite",className:"CorsRule"}}}},defaultServiceVersion:{serializedName:"DefaultServiceVersion",xmlName:"DefaultServiceVersion",type:{name:"String"}},deleteRetentionPolicy:{serializedName:"DeleteRetentionPolicy",xmlName:"DeleteRetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}},staticWebsite:{serializedName:"StaticWebsite",xmlName:"StaticWebsite",type:{name:"Composite",className:"StaticWebsite"}}}}},uE={serializedName:"Logging",type:{name:"Composite",className:"Logging",modelProperties:{version:{serializedName:"Version",required:!0,xmlName:"Version",type:{name:"String"}},deleteProperty:{serializedName:"Delete",required:!0,xmlName:"Delete",type:{name:"Boolean"}},read:{serializedName:"Read",required:!0,xmlName:"Read",type:{name:"Boolean"}},write:{serializedName:"Write",required:!0,xmlName:"Write",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}},pE={serializedName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy",modelProperties:{enabled:{serializedName:"Enabled",required:!0,xmlName:"Enabled",type:{name:"Boolean"}},days:{constraints:{InclusiveMinimum:1},serializedName:"Days",xmlName:"Days",type:{name:"Number"}}}}},fE={serializedName:"Metrics",type:{name:"Composite",className:"Metrics",modelProperties:{version:{serializedName:"Version",xmlName:"Version",type:{name:"String"}},enabled:{serializedName:"Enabled",required:!0,xmlName:"Enabled",type:{name:"Boolean"}},includeAPIs:{serializedName:"IncludeAPIs",xmlName:"IncludeAPIs",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}},hE={serializedName:"CorsRule",type:{name:"Composite",className:"CorsRule",modelProperties:{allowedOrigins:{serializedName:"AllowedOrigins",required:!0,xmlName:"AllowedOrigins",type:{name:"String"}},allowedMethods:{serializedName:"AllowedMethods",required:!0,xmlName:"AllowedMethods",type:{name:"String"}},allowedHeaders:{serializedName:"AllowedHeaders",required:!0,xmlName:"AllowedHeaders",type:{name:"String"}},exposedHeaders:{serializedName:"ExposedHeaders",required:!0,xmlName:"ExposedHeaders",type:{name:"String"}},maxAgeInSeconds:{constraints:{InclusiveMinimum:0},serializedName:"MaxAgeInSeconds",required:!0,xmlName:"MaxAgeInSeconds",type:{name:"Number"}}}}},yE={serializedName:"StaticWebsite",type:{name:"Composite",className:"StaticWebsite",modelProperties:{enabled:{serializedName:"Enabled",required:!0,xmlName:"Enabled",type:{name:"Boolean"}},indexDocument:{serializedName:"IndexDocument",xmlName:"IndexDocument",type:{name:"String"}},errorDocument404Path:{serializedName:"ErrorDocument404Path",xmlName:"ErrorDocument404Path",type:{name:"String"}},defaultIndexDocumentPath:{serializedName:"DefaultIndexDocumentPath",xmlName:"DefaultIndexDocumentPath",type:{name:"String"}}}}},Qe={serializedName:"StorageError",type:{name:"Composite",className:"StorageError",modelProperties:{message:{serializedName:"Message",xmlName:"Message",type:{name:"String"}},code:{serializedName:"Code",xmlName:"Code",type:{name:"String"}}}}},U0={serializedName:"BlobServiceStatistics",xmlName:"StorageServiceStats",type:{name:"Composite",className:"BlobServiceStatistics",modelProperties:{geoReplication:{serializedName:"GeoReplication",xmlName:"GeoReplication",type:{name:"Composite",className:"GeoReplication"}}}}},xE={serializedName:"GeoReplication",type:{name:"Composite",className:"GeoReplication",modelProperties:{status:{serializedName:"Status",required:!0,xmlName:"Status",type:{name:"Enum",allowedValues:["live","bootstrap","unavailable"]}},lastSyncOn:{serializedName:"LastSyncTime",required:!0,xmlName:"LastSyncTime",type:{name:"DateTimeRfc1123"}}}}},j0={serializedName:"ListContainersSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListContainersSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:!0,xmlName:"ServiceEndpoint",xmlIsAttribute:!0,type:{name:"String"}},prefix:{serializedName:"Prefix",xmlName:"Prefix",type:{name:"String"}},marker:{serializedName:"Marker",xmlName:"Marker",type:{name:"String"}},maxPageSize:{serializedName:"MaxResults",xmlName:"MaxResults",type:{name:"Number"}},containerItems:{serializedName:"ContainerItems",required:!0,xmlName:"Containers",xmlIsWrapped:!0,xmlElementName:"Container",type:{name:"Sequence",element:{type:{name:"Composite",className:"ContainerItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}},gE={serializedName:"ContainerItem",xmlName:"Container",type:{name:"Composite",className:"ContainerItem",modelProperties:{name:{serializedName:"Name",required:!0,xmlName:"Name",type:{name:"String"}},deleted:{serializedName:"Deleted",xmlName:"Deleted",type:{name:"Boolean"}},version:{serializedName:"Version",xmlName:"Version",type:{name:"String"}},properties:{serializedName:"Properties",xmlName:"Properties",type:{name:"Composite",className:"ContainerProperties"}},metadata:{serializedName:"Metadata",xmlName:"Metadata",type:{name:"Dictionary",value:{type:{name:"String"}}}}}}},vE={serializedName:"ContainerProperties",type:{name:"Composite",className:"ContainerProperties",modelProperties:{lastModified:{serializedName:"Last-Modified",required:!0,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:!0,xmlName:"Etag",type:{name:"String"}},leaseStatus:{serializedName:"LeaseStatus",xmlName:"LeaseStatus",type:{name:"Enum",allowedValues:["locked","unlocked"]}},leaseState:{serializedName:"LeaseState",xmlName:"LeaseState",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseDuration:{serializedName:"LeaseDuration",xmlName:"LeaseDuration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},publicAccess:{serializedName:"PublicAccess",xmlName:"PublicAccess",type:{name:"Enum",allowedValues:["container","blob"]}},hasImmutabilityPolicy:{serializedName:"HasImmutabilityPolicy",xmlName:"HasImmutabilityPolicy",type:{name:"Boolean"}},hasLegalHold:{serializedName:"HasLegalHold",xmlName:"HasLegalHold",type:{name:"Boolean"}},defaultEncryptionScope:{serializedName:"DefaultEncryptionScope",xmlName:"DefaultEncryptionScope",type:{name:"String"}},preventEncryptionScopeOverride:{serializedName:"DenyEncryptionScopeOverride",xmlName:"DenyEncryptionScopeOverride",type:{name:"Boolean"}},deletedOn:{serializedName:"DeletedTime",xmlName:"DeletedTime",type:{name:"DateTimeRfc1123"}},remainingRetentionDays:{serializedName:"RemainingRetentionDays",xmlName:"RemainingRetentionDays",type:{name:"Number"}},isImmutableStorageWithVersioningEnabled:{serializedName:"ImmutableStorageWithVersioningEnabled",xmlName:"ImmutableStorageWithVersioningEnabled",type:{name:"Boolean"}}}}},V0={serializedName:"KeyInfo",type:{name:"Composite",className:"KeyInfo",modelProperties:{startsOn:{serializedName:"Start",required:!0,xmlName:"Start",type:{name:"String"}},expiresOn:{serializedName:"Expiry",required:!0,xmlName:"Expiry",type:{name:"String"}}}}},G0={serializedName:"UserDelegationKey",type:{name:"Composite",className:"UserDelegationKey",modelProperties:{signedObjectId:{serializedName:"SignedOid",required:!0,xmlName:"SignedOid",type:{name:"String"}},signedTenantId:{serializedName:"SignedTid",required:!0,xmlName:"SignedTid",type:{name:"String"}},signedStartsOn:{serializedName:"SignedStart",required:!0,xmlName:"SignedStart",type:{name:"String"}},signedExpiresOn:{serializedName:"SignedExpiry",required:!0,xmlName:"SignedExpiry",type:{name:"String"}},signedService:{serializedName:"SignedService",required:!0,xmlName:"SignedService",type:{name:"String"}},signedVersion:{serializedName:"SignedVersion",required:!0,xmlName:"SignedVersion",type:{name:"String"}},value:{serializedName:"Value",required:!0,xmlName:"Value",type:{name:"String"}}}}},K0={serializedName:"FilterBlobSegment",xmlName:"EnumerationResults",type:{name:"Composite",className:"FilterBlobSegment",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:!0,xmlName:"ServiceEndpoint",xmlIsAttribute:!0,type:{name:"String"}},where:{serializedName:"Where",required:!0,xmlName:"Where",type:{name:"String"}},blobs:{serializedName:"Blobs",required:!0,xmlName:"Blobs",xmlIsWrapped:!0,xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"FilterBlobItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}},_E={serializedName:"FilterBlobItem",xmlName:"Blob",type:{name:"Composite",className:"FilterBlobItem",modelProperties:{name:{serializedName:"Name",required:!0,xmlName:"Name",type:{name:"String"}},containerName:{serializedName:"ContainerName",required:!0,xmlName:"ContainerName",type:{name:"String"}},tags:{serializedName:"Tags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags"}}}}},yc={serializedName:"BlobTags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags",modelProperties:{blobTagSet:{serializedName:"BlobTagSet",required:!0,xmlName:"TagSet",xmlIsWrapped:!0,xmlElementName:"Tag",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobTag"}}}}}}},bE={serializedName:"BlobTag",xmlName:"Tag",type:{name:"Composite",className:"BlobTag",modelProperties:{key:{serializedName:"Key",required:!0,xmlName:"Key",type:{name:"String"}},value:{serializedName:"Value",required:!0,xmlName:"Value",type:{name:"String"}}}}},SE={serializedName:"SignedIdentifier",xmlName:"SignedIdentifier",type:{name:"Composite",className:"SignedIdentifier",modelProperties:{id:{serializedName:"Id",required:!0,xmlName:"Id",type:{name:"String"}},accessPolicy:{serializedName:"AccessPolicy",xmlName:"AccessPolicy",type:{name:"Composite",className:"AccessPolicy"}}}}},NE={serializedName:"AccessPolicy",type:{name:"Composite",className:"AccessPolicy",modelProperties:{startsOn:{serializedName:"Start",xmlName:"Start",type:{name:"String"}},expiresOn:{serializedName:"Expiry",xmlName:"Expiry",type:{name:"String"}},permissions:{serializedName:"Permission",xmlName:"Permission",type:{name:"String"}}}}},X0={serializedName:"ListBlobsFlatSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsFlatSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:!0,xmlName:"ServiceEndpoint",xmlIsAttribute:!0,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:!0,xmlName:"ContainerName",xmlIsAttribute:!0,type:{name:"String"}},prefix:{serializedName:"Prefix",xmlName:"Prefix",type:{name:"String"}},marker:{serializedName:"Marker",xmlName:"Marker",type:{name:"String"}},maxPageSize:{serializedName:"MaxResults",xmlName:"MaxResults",type:{name:"Number"}},segment:{serializedName:"Segment",xmlName:"Blobs",type:{name:"Composite",className:"BlobFlatListSegment"}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}},PE={serializedName:"BlobFlatListSegment",xmlName:"Blobs",type:{name:"Composite",className:"BlobFlatListSegment",modelProperties:{blobItems:{serializedName:"BlobItems",required:!0,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}},CE={serializedName:"BlobItemInternal",xmlName:"Blob",type:{name:"Composite",className:"BlobItemInternal",modelProperties:{name:{serializedName:"Name",required:!0,xmlName:"Name",type:{name:"String"}},deleted:{serializedName:"Deleted",required:!0,xmlName:"Deleted",type:{name:"Boolean"}},snapshot:{serializedName:"Snapshot",required:!0,xmlName:"Snapshot",type:{name:"String"}},versionId:{serializedName:"VersionId",xmlName:"VersionId",type:{name:"String"}},isCurrentVersion:{serializedName:"IsCurrentVersion",xmlName:"IsCurrentVersion",type:{name:"Boolean"}},properties:{serializedName:"Properties",xmlName:"Properties",type:{name:"Composite",className:"BlobPropertiesInternal"}},metadata:{serializedName:"Metadata",xmlName:"Metadata",type:{name:"Dictionary",value:{type:{name:"String"}}}},blobTags:{serializedName:"BlobTags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags"}},objectReplicationMetadata:{serializedName:"ObjectReplicationMetadata",xmlName:"OrMetadata",type:{name:"Dictionary",value:{type:{name:"String"}}}},hasVersionsOnly:{serializedName:"HasVersionsOnly",xmlName:"HasVersionsOnly",type:{name:"Boolean"}}}}},RE={serializedName:"BlobPropertiesInternal",xmlName:"Properties",type:{name:"Composite",className:"BlobPropertiesInternal",modelProperties:{createdOn:{serializedName:"Creation-Time",xmlName:"Creation-Time",type:{name:"DateTimeRfc1123"}},lastModified:{serializedName:"Last-Modified",required:!0,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:!0,xmlName:"Etag",type:{name:"String"}},contentLength:{serializedName:"Content-Length",xmlName:"Content-Length",type:{name:"Number"}},contentType:{serializedName:"Content-Type",xmlName:"Content-Type",type:{name:"String"}},contentEncoding:{serializedName:"Content-Encoding",xmlName:"Content-Encoding",type:{name:"String"}},contentLanguage:{serializedName:"Content-Language",xmlName:"Content-Language",type:{name:"String"}},contentMD5:{serializedName:"Content-MD5",xmlName:"Content-MD5",type:{name:"ByteArray"}},contentDisposition:{serializedName:"Content-Disposition",xmlName:"Content-Disposition",type:{name:"String"}},cacheControl:{serializedName:"Cache-Control",xmlName:"Cache-Control",type:{name:"String"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},blobType:{serializedName:"BlobType",xmlName:"BlobType",type:{name:"Enum",allowedValues:["BlockBlob","PageBlob","AppendBlob"]}},leaseStatus:{serializedName:"LeaseStatus",xmlName:"LeaseStatus",type:{name:"Enum",allowedValues:["locked","unlocked"]}},leaseState:{serializedName:"LeaseState",xmlName:"LeaseState",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseDuration:{serializedName:"LeaseDuration",xmlName:"LeaseDuration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},copyId:{serializedName:"CopyId",xmlName:"CopyId",type:{name:"String"}},copyStatus:{serializedName:"CopyStatus",xmlName:"CopyStatus",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},copySource:{serializedName:"CopySource",xmlName:"CopySource",type:{name:"String"}},copyProgress:{serializedName:"CopyProgress",xmlName:"CopyProgress",type:{name:"String"}},copyCompletedOn:{serializedName:"CopyCompletionTime",xmlName:"CopyCompletionTime",type:{name:"DateTimeRfc1123"}},copyStatusDescription:{serializedName:"CopyStatusDescription",xmlName:"CopyStatusDescription",type:{name:"String"}},serverEncrypted:{serializedName:"ServerEncrypted",xmlName:"ServerEncrypted",type:{name:"Boolean"}},incrementalCopy:{serializedName:"IncrementalCopy",xmlName:"IncrementalCopy",type:{name:"Boolean"}},destinationSnapshot:{serializedName:"DestinationSnapshot",xmlName:"DestinationSnapshot",type:{name:"String"}},deletedOn:{serializedName:"DeletedTime",xmlName:"DeletedTime",type:{name:"DateTimeRfc1123"}},remainingRetentionDays:{serializedName:"RemainingRetentionDays",xmlName:"RemainingRetentionDays",type:{name:"Number"}},accessTier:{serializedName:"AccessTier",xmlName:"AccessTier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive"]}},accessTierInferred:{serializedName:"AccessTierInferred",xmlName:"AccessTierInferred",type:{name:"Boolean"}},archiveStatus:{serializedName:"ArchiveStatus",xmlName:"ArchiveStatus",type:{name:"Enum",allowedValues:["rehydrate-pending-to-hot","rehydrate-pending-to-cool"]}},customerProvidedKeySha256:{serializedName:"CustomerProvidedKeySha256",xmlName:"CustomerProvidedKeySha256",type:{name:"String"}},encryptionScope:{serializedName:"EncryptionScope",xmlName:"EncryptionScope",type:{name:"String"}},accessTierChangedOn:{serializedName:"AccessTierChangeTime",xmlName:"AccessTierChangeTime",type:{name:"DateTimeRfc1123"}},tagCount:{serializedName:"TagCount",xmlName:"TagCount",type:{name:"Number"}},expiresOn:{serializedName:"Expiry-Time",xmlName:"Expiry-Time",type:{name:"DateTimeRfc1123"}},isSealed:{serializedName:"Sealed",xmlName:"Sealed",type:{name:"Boolean"}},rehydratePriority:{serializedName:"RehydratePriority",xmlName:"RehydratePriority",type:{name:"Enum",allowedValues:["High","Standard"]}},lastAccessedOn:{serializedName:"LastAccessTime",xmlName:"LastAccessTime",type:{name:"DateTimeRfc1123"}},immutabilityPolicyExpiresOn:{serializedName:"ImmutabilityPolicyUntilDate",xmlName:"ImmutabilityPolicyUntilDate",type:{name:"DateTimeRfc1123"}},immutabilityPolicyMode:{serializedName:"ImmutabilityPolicyMode",xmlName:"ImmutabilityPolicyMode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}},legalHold:{serializedName:"LegalHold",xmlName:"LegalHold",type:{name:"Boolean"}}}}},$0={serializedName:"ListBlobsHierarchySegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsHierarchySegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:!0,xmlName:"ServiceEndpoint",xmlIsAttribute:!0,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:!0,xmlName:"ContainerName",xmlIsAttribute:!0,type:{name:"String"}},prefix:{serializedName:"Prefix",xmlName:"Prefix",type:{name:"String"}},marker:{serializedName:"Marker",xmlName:"Marker",type:{name:"String"}},maxPageSize:{serializedName:"MaxResults",xmlName:"MaxResults",type:{name:"Number"}},delimiter:{serializedName:"Delimiter",xmlName:"Delimiter",type:{name:"String"}},segment:{serializedName:"Segment",xmlName:"Blobs",type:{name:"Composite",className:"BlobHierarchyListSegment"}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}},EE={serializedName:"BlobHierarchyListSegment",xmlName:"Blobs",type:{name:"Composite",className:"BlobHierarchyListSegment",modelProperties:{blobPrefixes:{serializedName:"BlobPrefixes",xmlName:"BlobPrefixes",xmlElementName:"BlobPrefix",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobPrefix"}}}},blobItems:{serializedName:"BlobItems",required:!0,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}},TE={serializedName:"BlobPrefix",type:{name:"Composite",className:"BlobPrefix",modelProperties:{name:{serializedName:"Name",required:!0,xmlName:"Name",type:{name:"String"}}}}},W0={serializedName:"BlockLookupList",xmlName:"BlockList",type:{name:"Composite",className:"BlockLookupList",modelProperties:{committed:{serializedName:"Committed",xmlName:"Committed",xmlElementName:"Committed",type:{name:"Sequence",element:{type:{name:"String"}}}},uncommitted:{serializedName:"Uncommitted",xmlName:"Uncommitted",xmlElementName:"Uncommitted",type:{name:"Sequence",element:{type:{name:"String"}}}},latest:{serializedName:"Latest",xmlName:"Latest",xmlElementName:"Latest",type:{name:"Sequence",element:{type:{name:"String"}}}}}}},Y0={serializedName:"BlockList",type:{name:"Composite",className:"BlockList",modelProperties:{committedBlocks:{serializedName:"CommittedBlocks",xmlName:"CommittedBlocks",xmlIsWrapped:!0,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}},uncommittedBlocks:{serializedName:"UncommittedBlocks",xmlName:"UncommittedBlocks",xmlIsWrapped:!0,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}}}}},wE={serializedName:"Block",type:{name:"Composite",className:"Block",modelProperties:{name:{serializedName:"Name",required:!0,xmlName:"Name",type:{name:"String"}},size:{serializedName:"Size",required:!0,xmlName:"Size",type:{name:"Number"}}}}},sd={serializedName:"PageList",type:{name:"Composite",className:"PageList",modelProperties:{pageRange:{serializedName:"PageRange",xmlName:"PageRange",xmlElementName:"PageRange",type:{name:"Sequence",element:{type:{name:"Composite",className:"PageRange"}}}},clearRange:{serializedName:"ClearRange",xmlName:"ClearRange",xmlElementName:"ClearRange",type:{name:"Sequence",element:{type:{name:"Composite",className:"ClearRange"}}}}}}},IE={serializedName:"PageRange",xmlName:"PageRange",type:{name:"Composite",className:"PageRange",modelProperties:{start:{serializedName:"Start",required:!0,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:!0,xmlName:"End",type:{name:"Number"}}}}},ME={serializedName:"ClearRange",xmlName:"ClearRange",type:{name:"Composite",className:"ClearRange",modelProperties:{start:{serializedName:"Start",required:!0,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:!0,xmlName:"End",type:{name:"Number"}}}}},Q0={serializedName:"QueryRequest",xmlName:"QueryRequest",type:{name:"Composite",className:"QueryRequest",modelProperties:{queryType:{serializedName:"QueryType",required:!0,xmlName:"QueryType",type:{name:"String"}},expression:{serializedName:"Expression",required:!0,xmlName:"Expression",type:{name:"String"}},inputSerialization:{serializedName:"InputSerialization",xmlName:"InputSerialization",type:{name:"Composite",className:"QuerySerialization"}},outputSerialization:{serializedName:"OutputSerialization",xmlName:"OutputSerialization",type:{name:"Composite",className:"QuerySerialization"}}}}},AE={serializedName:"QuerySerialization",type:{name:"Composite",className:"QuerySerialization",modelProperties:{format:{serializedName:"Format",xmlName:"Format",type:{name:"Composite",className:"QueryFormat"}}}}},BE={serializedName:"QueryFormat",type:{name:"Composite",className:"QueryFormat",modelProperties:{type:{serializedName:"Type",required:!0,xmlName:"Type",type:{name:"Enum",allowedValues:["delimited","json","arrow","parquet"]}},delimitedTextConfiguration:{serializedName:"DelimitedTextConfiguration",xmlName:"DelimitedTextConfiguration",type:{name:"Composite",className:"DelimitedTextConfiguration"}},jsonTextConfiguration:{serializedName:"JsonTextConfiguration",xmlName:"JsonTextConfiguration",type:{name:"Composite",className:"JsonTextConfiguration"}},arrowConfiguration:{serializedName:"ArrowConfiguration",xmlName:"ArrowConfiguration",type:{name:"Composite",className:"ArrowConfiguration"}},parquetTextConfiguration:{serializedName:"ParquetTextConfiguration",xmlName:"ParquetTextConfiguration",type:{name:"any"}}}}},OE={serializedName:"DelimitedTextConfiguration",xmlName:"DelimitedTextConfiguration",type:{name:"Composite",className:"DelimitedTextConfiguration",modelProperties:{columnSeparator:{serializedName:"ColumnSeparator",xmlName:"ColumnSeparator",type:{name:"String"}},fieldQuote:{serializedName:"FieldQuote",xmlName:"FieldQuote",type:{name:"String"}},recordSeparator:{serializedName:"RecordSeparator",xmlName:"RecordSeparator",type:{name:"String"}},escapeChar:{serializedName:"EscapeChar",xmlName:"EscapeChar",type:{name:"String"}},headersPresent:{serializedName:"HeadersPresent",xmlName:"HasHeaders",type:{name:"Boolean"}}}}},zE={serializedName:"JsonTextConfiguration",xmlName:"JsonTextConfiguration",type:{name:"Composite",className:"JsonTextConfiguration",modelProperties:{recordSeparator:{serializedName:"RecordSeparator",xmlName:"RecordSeparator",type:{name:"String"}}}}},LE={serializedName:"ArrowConfiguration",xmlName:"ArrowConfiguration",type:{name:"Composite",className:"ArrowConfiguration",modelProperties:{schema:{serializedName:"Schema",required:!0,xmlName:"Schema",xmlIsWrapped:!0,xmlElementName:"Field",type:{name:"Sequence",element:{type:{name:"Composite",className:"ArrowField"}}}}}}},qE={serializedName:"ArrowField",xmlName:"Field",type:{name:"Composite",className:"ArrowField",modelProperties:{type:{serializedName:"Type",required:!0,xmlName:"Type",type:{name:"String"}},name:{serializedName:"Name",xmlName:"Name",type:{name:"String"}},precision:{serializedName:"Precision",xmlName:"Precision",type:{name:"Number"}},scale:{serializedName:"Scale",xmlName:"Scale",type:{name:"Number"}}}}},Z0={serializedName:"Service_setPropertiesHeaders",type:{name:"Composite",className:"ServiceSetPropertiesHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},J0={serializedName:"Service_setPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceSetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ef={serializedName:"Service_getPropertiesHeaders",type:{name:"Composite",className:"ServiceGetPropertiesHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},tf={serializedName:"Service_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},rf={serializedName:"Service_getStatisticsHeaders",type:{name:"Composite",className:"ServiceGetStatisticsHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},af={serializedName:"Service_getStatisticsExceptionHeaders",type:{name:"Composite",className:"ServiceGetStatisticsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},nf={serializedName:"Service_listContainersSegmentHeaders",type:{name:"Composite",className:"ServiceListContainersSegmentHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},sf={serializedName:"Service_listContainersSegmentExceptionHeaders",type:{name:"Composite",className:"ServiceListContainersSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},of={serializedName:"Service_getUserDelegationKeyHeaders",type:{name:"Composite",className:"ServiceGetUserDelegationKeyHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},lf={serializedName:"Service_getUserDelegationKeyExceptionHeaders",type:{name:"Composite",className:"ServiceGetUserDelegationKeyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},cf={serializedName:"Service_getAccountInfoHeaders",type:{name:"Composite",className:"ServiceGetAccountInfoHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},skuName:{serializedName:"x-ms-sku-name",xmlName:"x-ms-sku-name",type:{name:"Enum",allowedValues:["Standard_LRS","Standard_GRS","Standard_RAGRS","Standard_ZRS","Premium_LRS"]}},accountKind:{serializedName:"x-ms-account-kind",xmlName:"x-ms-account-kind",type:{name:"Enum",allowedValues:["Storage","BlobStorage","StorageV2","FileStorage","BlockBlobStorage"]}},isHierarchicalNamespaceEnabled:{serializedName:"x-ms-is-hns-enabled",xmlName:"x-ms-is-hns-enabled",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},mf={serializedName:"Service_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ServiceGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},df={serializedName:"Service_submitBatchHeaders",type:{name:"Composite",className:"ServiceSubmitBatchHeaders",modelProperties:{contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},uf={serializedName:"Service_submitBatchExceptionHeaders",type:{name:"Composite",className:"ServiceSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},pf={serializedName:"Service_filterBlobsHeaders",type:{name:"Composite",className:"ServiceFilterBlobsHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ff={serializedName:"Service_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ServiceFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},hf={serializedName:"Container_createHeaders",type:{name:"Composite",className:"ContainerCreateHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},yf={serializedName:"Container_createExceptionHeaders",type:{name:"Composite",className:"ContainerCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},xf={serializedName:"Container_getPropertiesHeaders",type:{name:"Composite",className:"ContainerGetPropertiesHeaders",modelProperties:{metadata:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-meta-"},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseDuration:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},leaseState:{serializedName:"x-ms-lease-state",xmlName:"x-ms-lease-state",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseStatus:{serializedName:"x-ms-lease-status",xmlName:"x-ms-lease-status",type:{name:"Enum",allowedValues:["locked","unlocked"]}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobPublicAccess:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}},hasImmutabilityPolicy:{serializedName:"x-ms-has-immutability-policy",xmlName:"x-ms-has-immutability-policy",type:{name:"Boolean"}},hasLegalHold:{serializedName:"x-ms-has-legal-hold",xmlName:"x-ms-has-legal-hold",type:{name:"Boolean"}},defaultEncryptionScope:{serializedName:"x-ms-default-encryption-scope",xmlName:"x-ms-default-encryption-scope",type:{name:"String"}},denyEncryptionScopeOverride:{serializedName:"x-ms-deny-encryption-scope-override",xmlName:"x-ms-deny-encryption-scope-override",type:{name:"Boolean"}},isImmutableStorageWithVersioningEnabled:{serializedName:"x-ms-immutable-storage-with-versioning-enabled",xmlName:"x-ms-immutable-storage-with-versioning-enabled",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},gf={serializedName:"Container_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ContainerGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},vf={serializedName:"Container_deleteHeaders",type:{name:"Composite",className:"ContainerDeleteHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},_f={serializedName:"Container_deleteExceptionHeaders",type:{name:"Composite",className:"ContainerDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},bf={serializedName:"Container_setMetadataHeaders",type:{name:"Composite",className:"ContainerSetMetadataHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Sf={serializedName:"Container_setMetadataExceptionHeaders",type:{name:"Composite",className:"ContainerSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Nf={serializedName:"Container_getAccessPolicyHeaders",type:{name:"Composite",className:"ContainerGetAccessPolicyHeaders",modelProperties:{blobPublicAccess:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Pf={serializedName:"Container_getAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Cf={serializedName:"Container_setAccessPolicyHeaders",type:{name:"Composite",className:"ContainerSetAccessPolicyHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Rf={serializedName:"Container_setAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerSetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ef={serializedName:"Container_restoreHeaders",type:{name:"Composite",className:"ContainerRestoreHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Tf={serializedName:"Container_restoreExceptionHeaders",type:{name:"Composite",className:"ContainerRestoreExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},wf={serializedName:"Container_renameHeaders",type:{name:"Composite",className:"ContainerRenameHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},If={serializedName:"Container_renameExceptionHeaders",type:{name:"Composite",className:"ContainerRenameExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Mf={serializedName:"Container_submitBatchHeaders",type:{name:"Composite",className:"ContainerSubmitBatchHeaders",modelProperties:{contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}}}}},Af={serializedName:"Container_submitBatchExceptionHeaders",type:{name:"Composite",className:"ContainerSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Bf={serializedName:"Container_acquireLeaseHeaders",type:{name:"Composite",className:"ContainerAcquireLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Of={serializedName:"Container_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},zf={serializedName:"Container_releaseLeaseHeaders",type:{name:"Composite",className:"ContainerReleaseLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Lf={serializedName:"Container_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},qf={serializedName:"Container_renewLeaseHeaders",type:{name:"Composite",className:"ContainerRenewLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Hf={serializedName:"Container_renewLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Df={serializedName:"Container_breakLeaseHeaders",type:{name:"Composite",className:"ContainerBreakLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseTime:{serializedName:"x-ms-lease-time",xmlName:"x-ms-lease-time",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},kf={serializedName:"Container_breakLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ff={serializedName:"Container_changeLeaseHeaders",type:{name:"Composite",className:"ContainerChangeLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Uf={serializedName:"Container_changeLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},jf={serializedName:"Container_listBlobFlatSegmentHeaders",type:{name:"Composite",className:"ContainerListBlobFlatSegmentHeaders",modelProperties:{contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Vf={serializedName:"Container_listBlobFlatSegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobFlatSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Gf={serializedName:"Container_listBlobHierarchySegmentHeaders",type:{name:"Composite",className:"ContainerListBlobHierarchySegmentHeaders",modelProperties:{contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Kf={serializedName:"Container_listBlobHierarchySegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobHierarchySegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Xf={serializedName:"Container_getAccountInfoHeaders",type:{name:"Composite",className:"ContainerGetAccountInfoHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},skuName:{serializedName:"x-ms-sku-name",xmlName:"x-ms-sku-name",type:{name:"Enum",allowedValues:["Standard_LRS","Standard_GRS","Standard_RAGRS","Standard_ZRS","Premium_LRS"]}},accountKind:{serializedName:"x-ms-account-kind",xmlName:"x-ms-account-kind",type:{name:"Enum",allowedValues:["Storage","BlobStorage","StorageV2","FileStorage","BlockBlobStorage"]}}}}},$f={serializedName:"Container_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},od={serializedName:"Blob_downloadHeaders",type:{name:"Composite",className:"BlobDownloadHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},metadata:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-meta-"},objectReplicationPolicyId:{serializedName:"x-ms-or-policy-id",xmlName:"x-ms-or-policy-id",type:{name:"String"}},objectReplicationRules:{serializedName:"x-ms-or",xmlName:"x-ms-or",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-or-"},contentLength:{serializedName:"content-length",xmlName:"content-length",type:{name:"Number"}},contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},contentRange:{serializedName:"content-range",xmlName:"content-range",type:{name:"String"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},contentEncoding:{serializedName:"content-encoding",xmlName:"content-encoding",type:{name:"String"}},cacheControl:{serializedName:"cache-control",xmlName:"cache-control",type:{name:"String"}},contentDisposition:{serializedName:"content-disposition",xmlName:"content-disposition",type:{name:"String"}},contentLanguage:{serializedName:"content-language",xmlName:"content-language",type:{name:"String"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},blobType:{serializedName:"x-ms-blob-type",xmlName:"x-ms-blob-type",type:{name:"Enum",allowedValues:["BlockBlob","PageBlob","AppendBlob"]}},copyCompletedOn:{serializedName:"x-ms-copy-completion-time",xmlName:"x-ms-copy-completion-time",type:{name:"DateTimeRfc1123"}},copyStatusDescription:{serializedName:"x-ms-copy-status-description",xmlName:"x-ms-copy-status-description",type:{name:"String"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyProgress:{serializedName:"x-ms-copy-progress",xmlName:"x-ms-copy-progress",type:{name:"String"}},copySource:{serializedName:"x-ms-copy-source",xmlName:"x-ms-copy-source",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},leaseDuration:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},leaseState:{serializedName:"x-ms-lease-state",xmlName:"x-ms-lease-state",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseStatus:{serializedName:"x-ms-lease-status",xmlName:"x-ms-lease-status",type:{name:"Enum",allowedValues:["locked","unlocked"]}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},isCurrentVersion:{serializedName:"x-ms-is-current-version",xmlName:"x-ms-is-current-version",type:{name:"Boolean"}},acceptRanges:{serializedName:"accept-ranges",xmlName:"accept-ranges",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},isServerEncrypted:{serializedName:"x-ms-server-encrypted",xmlName:"x-ms-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},blobContentMD5:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}},tagCount:{serializedName:"x-ms-tag-count",xmlName:"x-ms-tag-count",type:{name:"Number"}},isSealed:{serializedName:"x-ms-blob-sealed",xmlName:"x-ms-blob-sealed",type:{name:"Boolean"}},lastAccessed:{serializedName:"x-ms-last-access-time",xmlName:"x-ms-last-access-time",type:{name:"DateTimeRfc1123"}},immutabilityPolicyExpiresOn:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}},immutabilityPolicyMode:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}},legalHold:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}},contentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}}}},Wf={serializedName:"Blob_downloadExceptionHeaders",type:{name:"Composite",className:"BlobDownloadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Yf={serializedName:"Blob_getPropertiesHeaders",type:{name:"Composite",className:"BlobGetPropertiesHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},createdOn:{serializedName:"x-ms-creation-time",xmlName:"x-ms-creation-time",type:{name:"DateTimeRfc1123"}},metadata:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-meta-"},objectReplicationPolicyId:{serializedName:"x-ms-or-policy-id",xmlName:"x-ms-or-policy-id",type:{name:"String"}},objectReplicationRules:{serializedName:"x-ms-or",xmlName:"x-ms-or",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-or-"},blobType:{serializedName:"x-ms-blob-type",xmlName:"x-ms-blob-type",type:{name:"Enum",allowedValues:["BlockBlob","PageBlob","AppendBlob"]}},copyCompletedOn:{serializedName:"x-ms-copy-completion-time",xmlName:"x-ms-copy-completion-time",type:{name:"DateTimeRfc1123"}},copyStatusDescription:{serializedName:"x-ms-copy-status-description",xmlName:"x-ms-copy-status-description",type:{name:"String"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyProgress:{serializedName:"x-ms-copy-progress",xmlName:"x-ms-copy-progress",type:{name:"String"}},copySource:{serializedName:"x-ms-copy-source",xmlName:"x-ms-copy-source",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},isIncrementalCopy:{serializedName:"x-ms-incremental-copy",xmlName:"x-ms-incremental-copy",type:{name:"Boolean"}},destinationSnapshot:{serializedName:"x-ms-copy-destination-snapshot",xmlName:"x-ms-copy-destination-snapshot",type:{name:"String"}},leaseDuration:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},leaseState:{serializedName:"x-ms-lease-state",xmlName:"x-ms-lease-state",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseStatus:{serializedName:"x-ms-lease-status",xmlName:"x-ms-lease-status",type:{name:"Enum",allowedValues:["locked","unlocked"]}},contentLength:{serializedName:"content-length",xmlName:"content-length",type:{name:"Number"}},contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},contentEncoding:{serializedName:"content-encoding",xmlName:"content-encoding",type:{name:"String"}},contentDisposition:{serializedName:"content-disposition",xmlName:"content-disposition",type:{name:"String"}},contentLanguage:{serializedName:"content-language",xmlName:"content-language",type:{name:"String"}},cacheControl:{serializedName:"cache-control",xmlName:"cache-control",type:{name:"String"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},acceptRanges:{serializedName:"accept-ranges",xmlName:"accept-ranges",type:{name:"String"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},isServerEncrypted:{serializedName:"x-ms-server-encrypted",xmlName:"x-ms-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},accessTier:{serializedName:"x-ms-access-tier",xmlName:"x-ms-access-tier",type:{name:"String"}},accessTierInferred:{serializedName:"x-ms-access-tier-inferred",xmlName:"x-ms-access-tier-inferred",type:{name:"Boolean"}},archiveStatus:{serializedName:"x-ms-archive-status",xmlName:"x-ms-archive-status",type:{name:"String"}},accessTierChangedOn:{serializedName:"x-ms-access-tier-change-time",xmlName:"x-ms-access-tier-change-time",type:{name:"DateTimeRfc1123"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},isCurrentVersion:{serializedName:"x-ms-is-current-version",xmlName:"x-ms-is-current-version",type:{name:"Boolean"}},tagCount:{serializedName:"x-ms-tag-count",xmlName:"x-ms-tag-count",type:{name:"Number"}},expiresOn:{serializedName:"x-ms-expiry-time",xmlName:"x-ms-expiry-time",type:{name:"DateTimeRfc1123"}},isSealed:{serializedName:"x-ms-blob-sealed",xmlName:"x-ms-blob-sealed",type:{name:"Boolean"}},rehydratePriority:{serializedName:"x-ms-rehydrate-priority",xmlName:"x-ms-rehydrate-priority",type:{name:"Enum",allowedValues:["High","Standard"]}},lastAccessed:{serializedName:"x-ms-last-access-time",xmlName:"x-ms-last-access-time",type:{name:"DateTimeRfc1123"}},immutabilityPolicyExpiresOn:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}},immutabilityPolicyMode:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}},legalHold:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Qf={serializedName:"Blob_getPropertiesExceptionHeaders",type:{name:"Composite",className:"BlobGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Zf={serializedName:"Blob_deleteHeaders",type:{name:"Composite",className:"BlobDeleteHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Jf={serializedName:"Blob_deleteExceptionHeaders",type:{name:"Composite",className:"BlobDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},eh={serializedName:"Blob_undeleteHeaders",type:{name:"Composite",className:"BlobUndeleteHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},th={serializedName:"Blob_undeleteExceptionHeaders",type:{name:"Composite",className:"BlobUndeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},rh={serializedName:"Blob_setExpiryHeaders",type:{name:"Composite",className:"BlobSetExpiryHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},ah={serializedName:"Blob_setExpiryExceptionHeaders",type:{name:"Composite",className:"BlobSetExpiryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},nh={serializedName:"Blob_setHttpHeadersHeaders",type:{name:"Composite",className:"BlobSetHttpHeadersHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ih={serializedName:"Blob_setHttpHeadersExceptionHeaders",type:{name:"Composite",className:"BlobSetHttpHeadersExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},sh={serializedName:"Blob_setImmutabilityPolicyHeaders",type:{name:"Composite",className:"BlobSetImmutabilityPolicyHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},immutabilityPolicyExpiry:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}},immutabilityPolicyMode:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}}}}},oh={serializedName:"Blob_setImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobSetImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},lh={serializedName:"Blob_deleteImmutabilityPolicyHeaders",type:{name:"Composite",className:"BlobDeleteImmutabilityPolicyHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},ch={serializedName:"Blob_deleteImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobDeleteImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},mh={serializedName:"Blob_setLegalHoldHeaders",type:{name:"Composite",className:"BlobSetLegalHoldHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},legalHold:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}}}},dh={serializedName:"Blob_setLegalHoldExceptionHeaders",type:{name:"Composite",className:"BlobSetLegalHoldExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},uh={serializedName:"Blob_setMetadataHeaders",type:{name:"Composite",className:"BlobSetMetadataHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ph={serializedName:"Blob_setMetadataExceptionHeaders",type:{name:"Composite",className:"BlobSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},fh={serializedName:"Blob_acquireLeaseHeaders",type:{name:"Composite",className:"BlobAcquireLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},hh={serializedName:"Blob_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"BlobAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},yh={serializedName:"Blob_releaseLeaseHeaders",type:{name:"Composite",className:"BlobReleaseLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},xh={serializedName:"Blob_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"BlobReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},gh={serializedName:"Blob_renewLeaseHeaders",type:{name:"Composite",className:"BlobRenewLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},vh={serializedName:"Blob_renewLeaseExceptionHeaders",type:{name:"Composite",className:"BlobRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},_h={serializedName:"Blob_changeLeaseHeaders",type:{name:"Composite",className:"BlobChangeLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},bh={serializedName:"Blob_changeLeaseExceptionHeaders",type:{name:"Composite",className:"BlobChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Sh={serializedName:"Blob_breakLeaseHeaders",type:{name:"Composite",className:"BlobBreakLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseTime:{serializedName:"x-ms-lease-time",xmlName:"x-ms-lease-time",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Nh={serializedName:"Blob_breakLeaseExceptionHeaders",type:{name:"Composite",className:"BlobBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ph={serializedName:"Blob_createSnapshotHeaders",type:{name:"Composite",className:"BlobCreateSnapshotHeaders",modelProperties:{snapshot:{serializedName:"x-ms-snapshot",xmlName:"x-ms-snapshot",type:{name:"String"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ch={serializedName:"Blob_createSnapshotExceptionHeaders",type:{name:"Composite",className:"BlobCreateSnapshotExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Rh={serializedName:"Blob_startCopyFromURLHeaders",type:{name:"Composite",className:"BlobStartCopyFromURLHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Eh={serializedName:"Blob_startCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobStartCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Th={serializedName:"Blob_copyFromURLHeaders",type:{name:"Composite",className:"BlobCopyFromURLHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyStatus:{defaultValue:"success",isConstant:!0,serializedName:"x-ms-copy-status",type:{name:"String"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},wh={serializedName:"Blob_copyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ih={serializedName:"Blob_abortCopyFromURLHeaders",type:{name:"Composite",className:"BlobAbortCopyFromURLHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Mh={serializedName:"Blob_abortCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobAbortCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ld={serializedName:"Blob_setTierHeaders",type:{name:"Composite",className:"BlobSetTierHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ah={serializedName:"Blob_setTierExceptionHeaders",type:{name:"Composite",className:"BlobSetTierExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Bh={serializedName:"Blob_getAccountInfoHeaders",type:{name:"Composite",className:"BlobGetAccountInfoHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},skuName:{serializedName:"x-ms-sku-name",xmlName:"x-ms-sku-name",type:{name:"Enum",allowedValues:["Standard_LRS","Standard_GRS","Standard_RAGRS","Standard_ZRS","Premium_LRS"]}},accountKind:{serializedName:"x-ms-account-kind",xmlName:"x-ms-account-kind",type:{name:"Enum",allowedValues:["Storage","BlobStorage","StorageV2","FileStorage","BlockBlobStorage"]}}}}},Oh={serializedName:"Blob_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"BlobGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},cd={serializedName:"Blob_queryHeaders",type:{name:"Composite",className:"BlobQueryHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},metadata:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}}},contentLength:{serializedName:"content-length",xmlName:"content-length",type:{name:"Number"}},contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},contentRange:{serializedName:"content-range",xmlName:"content-range",type:{name:"String"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},contentEncoding:{serializedName:"content-encoding",xmlName:"content-encoding",type:{name:"String"}},cacheControl:{serializedName:"cache-control",xmlName:"cache-control",type:{name:"String"}},contentDisposition:{serializedName:"content-disposition",xmlName:"content-disposition",type:{name:"String"}},contentLanguage:{serializedName:"content-language",xmlName:"content-language",type:{name:"String"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},blobType:{serializedName:"x-ms-blob-type",xmlName:"x-ms-blob-type",type:{name:"Enum",allowedValues:["BlockBlob","PageBlob","AppendBlob"]}},copyCompletionTime:{serializedName:"x-ms-copy-completion-time",xmlName:"x-ms-copy-completion-time",type:{name:"DateTimeRfc1123"}},copyStatusDescription:{serializedName:"x-ms-copy-status-description",xmlName:"x-ms-copy-status-description",type:{name:"String"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyProgress:{serializedName:"x-ms-copy-progress",xmlName:"x-ms-copy-progress",type:{name:"String"}},copySource:{serializedName:"x-ms-copy-source",xmlName:"x-ms-copy-source",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},leaseDuration:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},leaseState:{serializedName:"x-ms-lease-state",xmlName:"x-ms-lease-state",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseStatus:{serializedName:"x-ms-lease-status",xmlName:"x-ms-lease-status",type:{name:"Enum",allowedValues:["locked","unlocked"]}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},acceptRanges:{serializedName:"accept-ranges",xmlName:"accept-ranges",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},isServerEncrypted:{serializedName:"x-ms-server-encrypted",xmlName:"x-ms-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},blobContentMD5:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}},contentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}}}},zh={serializedName:"Blob_queryExceptionHeaders",type:{name:"Composite",className:"BlobQueryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Lh={serializedName:"Blob_getTagsHeaders",type:{name:"Composite",className:"BlobGetTagsHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},qh={serializedName:"Blob_getTagsExceptionHeaders",type:{name:"Composite",className:"BlobGetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Hh={serializedName:"Blob_setTagsHeaders",type:{name:"Composite",className:"BlobSetTagsHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Dh={serializedName:"Blob_setTagsExceptionHeaders",type:{name:"Composite",className:"BlobSetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},kh={serializedName:"PageBlob_createHeaders",type:{name:"Composite",className:"PageBlobCreateHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Fh={serializedName:"PageBlob_createExceptionHeaders",type:{name:"Composite",className:"PageBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Uh={serializedName:"PageBlob_uploadPagesHeaders",type:{name:"Composite",className:"PageBlobUploadPagesHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},jh={serializedName:"PageBlob_uploadPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Vh={serializedName:"PageBlob_clearPagesHeaders",type:{name:"Composite",className:"PageBlobClearPagesHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Gh={serializedName:"PageBlob_clearPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobClearPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Kh={serializedName:"PageBlob_uploadPagesFromURLHeaders",type:{name:"Composite",className:"PageBlobUploadPagesFromURLHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Xh={serializedName:"PageBlob_uploadPagesFromURLExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},$h={serializedName:"PageBlob_getPageRangesHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},blobContentLength:{serializedName:"x-ms-blob-content-length",xmlName:"x-ms-blob-content-length",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Wh={serializedName:"PageBlob_getPageRangesExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Yh={serializedName:"PageBlob_getPageRangesDiffHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesDiffHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},blobContentLength:{serializedName:"x-ms-blob-content-length",xmlName:"x-ms-blob-content-length",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Qh={serializedName:"PageBlob_getPageRangesDiffExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesDiffExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Zh={serializedName:"PageBlob_resizeHeaders",type:{name:"Composite",className:"PageBlobResizeHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Jh={serializedName:"PageBlob_resizeExceptionHeaders",type:{name:"Composite",className:"PageBlobResizeExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},e1={serializedName:"PageBlob_updateSequenceNumberHeaders",type:{name:"Composite",className:"PageBlobUpdateSequenceNumberHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},t1={serializedName:"PageBlob_updateSequenceNumberExceptionHeaders",type:{name:"Composite",className:"PageBlobUpdateSequenceNumberExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},r1={serializedName:"PageBlob_copyIncrementalHeaders",type:{name:"Composite",className:"PageBlobCopyIncrementalHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},a1={serializedName:"PageBlob_copyIncrementalExceptionHeaders",type:{name:"Composite",className:"PageBlobCopyIncrementalExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},n1={serializedName:"AppendBlob_createHeaders",type:{name:"Composite",className:"AppendBlobCreateHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},i1={serializedName:"AppendBlob_createExceptionHeaders",type:{name:"Composite",className:"AppendBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},s1={serializedName:"AppendBlob_appendBlockHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobAppendOffset:{serializedName:"x-ms-blob-append-offset",xmlName:"x-ms-blob-append-offset",type:{name:"String"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},o1={serializedName:"AppendBlob_appendBlockExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},l1={serializedName:"AppendBlob_appendBlockFromUrlHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockFromUrlHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobAppendOffset:{serializedName:"x-ms-blob-append-offset",xmlName:"x-ms-blob-append-offset",type:{name:"String"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},c1={serializedName:"AppendBlob_appendBlockFromUrlExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},m1={serializedName:"AppendBlob_sealHeaders",type:{name:"Composite",className:"AppendBlobSealHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isSealed:{serializedName:"x-ms-blob-sealed",xmlName:"x-ms-blob-sealed",type:{name:"Boolean"}}}}},d1={serializedName:"AppendBlob_sealExceptionHeaders",type:{name:"Composite",className:"AppendBlobSealExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},u1={serializedName:"BlockBlob_uploadHeaders",type:{name:"Composite",className:"BlockBlobUploadHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},p1={serializedName:"BlockBlob_uploadExceptionHeaders",type:{name:"Composite",className:"BlockBlobUploadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},f1={serializedName:"BlockBlob_putBlobFromUrlHeaders",type:{name:"Composite",className:"BlockBlobPutBlobFromUrlHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},h1={serializedName:"BlockBlob_putBlobFromUrlExceptionHeaders",type:{name:"Composite",className:"BlockBlobPutBlobFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},y1={serializedName:"BlockBlob_stageBlockHeaders",type:{name:"Composite",className:"BlockBlobStageBlockHeaders",modelProperties:{contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},x1={serializedName:"BlockBlob_stageBlockExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},g1={serializedName:"BlockBlob_stageBlockFromURLHeaders",type:{name:"Composite",className:"BlockBlobStageBlockFromURLHeaders",modelProperties:{contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},v1={serializedName:"BlockBlob_stageBlockFromURLExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},_1={serializedName:"BlockBlob_commitBlockListHeaders",type:{name:"Composite",className:"BlockBlobCommitBlockListHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},b1={serializedName:"BlockBlob_commitBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobCommitBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},S1={serializedName:"BlockBlob_getBlockListHeaders",type:{name:"Composite",className:"BlockBlobGetBlockListHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},blobContentLength:{serializedName:"x-ms-blob-content-length",xmlName:"x-ms-blob-content-length",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},N1={serializedName:"BlockBlob_getBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobGetBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};var un={parameterPath:["options","contentType"],mapper:{defaultValue:"application/xml",isConstant:!0,serializedName:"Content-Type",type:{name:"String"}}},Mb={parameterPath:"blobServiceProperties",mapper:hc},pn={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:!0,serializedName:"Accept",type:{name:"String"}}},Ze={parameterPath:"url",mapper:{serializedName:"url",required:!0,xmlName:"url",type:{name:"String"}},skipEncoding:!0},xc={parameterPath:"restype",mapper:{defaultValue:"service",isConstant:!0,serializedName:"restype",type:{name:"String"}}},fn={parameterPath:"comp",mapper:{defaultValue:"properties",isConstant:!0,serializedName:"comp",type:{name:"String"}}},at={parameterPath:["options","timeoutInSeconds"],mapper:{constraints:{InclusiveMinimum:0},serializedName:"timeout",xmlName:"timeout",type:{name:"Number"}}},Je={parameterPath:"version",mapper:{defaultValue:"2020-10-02",isConstant:!0,serializedName:"x-ms-version",type:{name:"String"}}},nt={parameterPath:["options","requestId"],mapper:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}}},mt={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:!0,serializedName:"Accept",type:{name:"String"}}},Ab={parameterPath:"comp",mapper:{defaultValue:"stats",isConstant:!0,serializedName:"comp",type:{name:"String"}}},gc={parameterPath:"comp",mapper:{defaultValue:"list",isConstant:!0,serializedName:"comp",type:{name:"String"}}},vc={parameterPath:["options","prefix"],mapper:{serializedName:"prefix",xmlName:"prefix",type:{name:"String"}}},jo={parameterPath:["options","marker"],mapper:{serializedName:"marker",xmlName:"marker",type:{name:"String"}}},Vo={parameterPath:["options","maxPageSize"],mapper:{constraints:{InclusiveMinimum:1},serializedName:"maxresults",xmlName:"maxresults",type:{name:"Number"}}},Bb={parameterPath:["options","include"],mapper:{serializedName:"include",xmlName:"include",xmlElementName:"ListContainersIncludeType",type:{name:"Sequence",element:{type:{name:"Enum",allowedValues:["metadata","deleted"]}}}},collectionFormat:$a.Csv},Ob={parameterPath:"keyInfo",mapper:V0},zb={parameterPath:"comp",mapper:{defaultValue:"userdelegationkey",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Go={parameterPath:"restype",mapper:{defaultValue:"account",isConstant:!0,serializedName:"restype",type:{name:"String"}}},md={parameterPath:"body",mapper:{serializedName:"body",required:!0,xmlName:"body",type:{name:"Stream"}}},dd={parameterPath:"comp",mapper:{defaultValue:"batch",isConstant:!0,serializedName:"comp",type:{name:"String"}}},ia={parameterPath:"contentLength",mapper:{serializedName:"Content-Length",required:!0,xmlName:"Content-Length",type:{name:"Number"}}},ud={parameterPath:"multipartContentType",mapper:{serializedName:"Content-Type",required:!0,xmlName:"Content-Type",type:{name:"String"}}},Lb={parameterPath:"comp",mapper:{defaultValue:"blobs",isConstant:!0,serializedName:"comp",type:{name:"String"}}},qb={parameterPath:["options","where"],mapper:{serializedName:"where",xmlName:"where",type:{name:"String"}}},da={parameterPath:"restype",mapper:{defaultValue:"container",isConstant:!0,serializedName:"restype",type:{name:"String"}}},xa={parameterPath:["options","metadata"],mapper:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-meta-"}},P1={parameterPath:["options","access"],mapper:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}}},Hb={parameterPath:["options","containerEncryptionScope","defaultEncryptionScope"],mapper:{serializedName:"x-ms-default-encryption-scope",xmlName:"x-ms-default-encryption-scope",type:{name:"String"}}},Db={parameterPath:["options","containerEncryptionScope","preventEncryptionScopeOverride"],mapper:{serializedName:"x-ms-deny-encryption-scope-override",xmlName:"x-ms-deny-encryption-scope-override",type:{name:"Boolean"}}},Mt={parameterPath:["options","leaseAccessConditions","leaseId"],mapper:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}}},Rt={parameterPath:["options","modifiedAccessConditions","ifModifiedSince"],mapper:{serializedName:"If-Modified-Since",xmlName:"If-Modified-Since",type:{name:"DateTimeRfc1123"}}},Et={parameterPath:["options","modifiedAccessConditions","ifUnmodifiedSince"],mapper:{serializedName:"If-Unmodified-Since",xmlName:"If-Unmodified-Since",type:{name:"DateTimeRfc1123"}}},pd={parameterPath:"comp",mapper:{defaultValue:"metadata",isConstant:!0,serializedName:"comp",type:{name:"String"}}},C1={parameterPath:"comp",mapper:{defaultValue:"acl",isConstant:!0,serializedName:"comp",type:{name:"String"}}},kb={parameterPath:["options","containerAcl"],mapper:{serializedName:"containerAcl",xmlName:"SignedIdentifiers",xmlIsWrapped:!0,xmlElementName:"SignedIdentifier",type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}}}},fd={parameterPath:"comp",mapper:{defaultValue:"undelete",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Fb={parameterPath:["options","deletedContainerName"],mapper:{serializedName:"x-ms-deleted-container-name",xmlName:"x-ms-deleted-container-name",type:{name:"String"}}},Ub={parameterPath:["options","deletedContainerVersion"],mapper:{serializedName:"x-ms-deleted-container-version",xmlName:"x-ms-deleted-container-version",type:{name:"String"}}},jb={parameterPath:"comp",mapper:{defaultValue:"rename",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Vb={parameterPath:"sourceContainerName",mapper:{serializedName:"x-ms-source-container-name",required:!0,xmlName:"x-ms-source-container-name",type:{name:"String"}}},Gb={parameterPath:["options","sourceLeaseId"],mapper:{serializedName:"x-ms-source-lease-id",xmlName:"x-ms-source-lease-id",type:{name:"String"}}},hn={parameterPath:"comp",mapper:{defaultValue:"lease",isConstant:!0,serializedName:"comp",type:{name:"String"}}},hd={parameterPath:"action",mapper:{defaultValue:"acquire",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},yd={parameterPath:["options","duration"],mapper:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Number"}}},xd={parameterPath:["options","proposedLeaseId"],mapper:{serializedName:"x-ms-proposed-lease-id",xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}},gd={parameterPath:"action",mapper:{defaultValue:"release",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},us={parameterPath:"leaseId",mapper:{serializedName:"x-ms-lease-id",required:!0,xmlName:"x-ms-lease-id",type:{name:"String"}}},vd={parameterPath:"action",mapper:{defaultValue:"renew",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},_d={parameterPath:"action",mapper:{defaultValue:"break",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},bd={parameterPath:["options","breakPeriod"],mapper:{serializedName:"x-ms-lease-break-period",xmlName:"x-ms-lease-break-period",type:{name:"Number"}}},Sd={parameterPath:"action",mapper:{defaultValue:"change",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},Nd={parameterPath:"proposedLeaseId",mapper:{serializedName:"x-ms-proposed-lease-id",required:!0,xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}},R1={parameterPath:["options","include"],mapper:{serializedName:"include",xmlName:"include",xmlElementName:"ListBlobsIncludeItem",type:{name:"Sequence",element:{type:{name:"Enum",allowedValues:["copy","deleted","metadata","snapshots","uncommittedblobs","versions","tags","immutabilitypolicy","legalhold","deletedwithversions"]}}}},collectionFormat:$a.Csv},Kb={parameterPath:"delimiter",mapper:{serializedName:"delimiter",required:!0,xmlName:"delimiter",type:{name:"String"}}},yn={parameterPath:["options","snapshot"],mapper:{serializedName:"snapshot",xmlName:"snapshot",type:{name:"String"}}},$s={parameterPath:["options","versionId"],mapper:{serializedName:"versionid",xmlName:"versionid",type:{name:"String"}}},Ws={parameterPath:["options","range"],mapper:{serializedName:"x-ms-range",xmlName:"x-ms-range",type:{name:"String"}}},Xb={parameterPath:["options","rangeGetContentMD5"],mapper:{serializedName:"x-ms-range-get-content-md5",xmlName:"x-ms-range-get-content-md5",type:{name:"Boolean"}}},$b={parameterPath:["options","rangeGetContentCRC64"],mapper:{serializedName:"x-ms-range-get-content-crc64",xmlName:"x-ms-range-get-content-crc64",type:{name:"Boolean"}}},Er={parameterPath:["options","cpkInfo","encryptionKey"],mapper:{serializedName:"x-ms-encryption-key",xmlName:"x-ms-encryption-key",type:{name:"String"}}},Tr={parameterPath:["options","cpkInfo","encryptionKeySha256"],mapper:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}}},wr={parameterPath:["options","encryptionAlgorithm"],mapper:{defaultValue:"AES256",isConstant:!0,serializedName:"x-ms-encryption-algorithm",type:{name:"String"}}},Ut={parameterPath:["options","modifiedAccessConditions","ifMatch"],mapper:{serializedName:"If-Match",xmlName:"If-Match",type:{name:"String"}}},jt={parameterPath:["options","modifiedAccessConditions","ifNoneMatch"],mapper:{serializedName:"If-None-Match",xmlName:"If-None-Match",type:{name:"String"}}},qt={parameterPath:["options","modifiedAccessConditions","ifTags"],mapper:{serializedName:"x-ms-if-tags",xmlName:"x-ms-if-tags",type:{name:"String"}}},Wb={parameterPath:["options","deleteSnapshots"],mapper:{serializedName:"x-ms-delete-snapshots",xmlName:"x-ms-delete-snapshots",type:{name:"Enum",allowedValues:["include","only"]}}},Yb={parameterPath:["options","blobDeleteType"],mapper:{serializedName:"deletetype",xmlName:"deletetype",type:{name:"String"}}},Qb={parameterPath:"comp",mapper:{defaultValue:"expiry",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Zb={parameterPath:"expiryOptions",mapper:{serializedName:"x-ms-expiry-option",required:!0,xmlName:"x-ms-expiry-option",type:{name:"String"}}},Jb={parameterPath:["options","expiresOn"],mapper:{serializedName:"x-ms-expiry-time",xmlName:"x-ms-expiry-time",type:{name:"String"}}},ci={parameterPath:["options","blobHttpHeaders","blobCacheControl"],mapper:{serializedName:"x-ms-blob-cache-control",xmlName:"x-ms-blob-cache-control",type:{name:"String"}}},mi={parameterPath:["options","blobHttpHeaders","blobContentType"],mapper:{serializedName:"x-ms-blob-content-type",xmlName:"x-ms-blob-content-type",type:{name:"String"}}},di={parameterPath:["options","blobHttpHeaders","blobContentMD5"],mapper:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}}},ui={parameterPath:["options","blobHttpHeaders","blobContentEncoding"],mapper:{serializedName:"x-ms-blob-content-encoding",xmlName:"x-ms-blob-content-encoding",type:{name:"String"}}},pi={parameterPath:["options","blobHttpHeaders","blobContentLanguage"],mapper:{serializedName:"x-ms-blob-content-language",xmlName:"x-ms-blob-content-language",type:{name:"String"}}},fi={parameterPath:["options","blobHttpHeaders","blobContentDisposition"],mapper:{serializedName:"x-ms-blob-content-disposition",xmlName:"x-ms-blob-content-disposition",type:{name:"String"}}},E1={parameterPath:"comp",mapper:{defaultValue:"immutabilityPolicies",isConstant:!0,serializedName:"comp",type:{name:"String"}}},On={parameterPath:["options","immutabilityPolicyExpiry"],mapper:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}}},zn={parameterPath:["options","immutabilityPolicyMode"],mapper:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}}},e2={parameterPath:"comp",mapper:{defaultValue:"legalhold",isConstant:!0,serializedName:"comp",type:{name:"String"}}},t2={parameterPath:"legalHold",mapper:{serializedName:"x-ms-legal-hold",required:!0,xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}},Xr={parameterPath:["options","encryptionScope"],mapper:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}}},r2={parameterPath:"comp",mapper:{defaultValue:"snapshot",isConstant:!0,serializedName:"comp",type:{name:"String"}}},zi={parameterPath:["options","tier"],mapper:{serializedName:"x-ms-access-tier",xmlName:"x-ms-access-tier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive"]}}},T1={parameterPath:["options","rehydratePriority"],mapper:{serializedName:"x-ms-rehydrate-priority",xmlName:"x-ms-rehydrate-priority",type:{name:"Enum",allowedValues:["High","Standard"]}}},hi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfModifiedSince"],mapper:{serializedName:"x-ms-source-if-modified-since",xmlName:"x-ms-source-if-modified-since",type:{name:"DateTimeRfc1123"}}},yi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfUnmodifiedSince"],mapper:{serializedName:"x-ms-source-if-unmodified-since",xmlName:"x-ms-source-if-unmodified-since",type:{name:"DateTimeRfc1123"}}},xi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfMatch"],mapper:{serializedName:"x-ms-source-if-match",xmlName:"x-ms-source-if-match",type:{name:"String"}}},gi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfNoneMatch"],mapper:{serializedName:"x-ms-source-if-none-match",xmlName:"x-ms-source-if-none-match",type:{name:"String"}}},Pd={parameterPath:["options","sourceModifiedAccessConditions","sourceIfTags"],mapper:{serializedName:"x-ms-source-if-tags",xmlName:"x-ms-source-if-tags",type:{name:"String"}}},Ys={parameterPath:"copySource",mapper:{serializedName:"x-ms-copy-source",required:!0,xmlName:"x-ms-copy-source",type:{name:"String"}}},Ln={parameterPath:["options","blobTagsString"],mapper:{serializedName:"x-ms-tags",xmlName:"x-ms-tags",type:{name:"String"}}},a2={parameterPath:["options","sealBlob"],mapper:{serializedName:"x-ms-seal-blob",xmlName:"x-ms-seal-blob",type:{name:"Boolean"}}},vi={parameterPath:["options","legalHold"],mapper:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}},n2={parameterPath:"xMsRequiresSync",mapper:{defaultValue:"true",isConstant:!0,serializedName:"x-ms-requires-sync",type:{name:"String"}}},Li={parameterPath:["options","sourceContentMD5"],mapper:{serializedName:"x-ms-source-content-md5",xmlName:"x-ms-source-content-md5",type:{name:"ByteArray"}}},qi={parameterPath:["options","copySourceAuthorization"],mapper:{serializedName:"x-ms-copy-source-authorization",xmlName:"x-ms-copy-source-authorization",type:{name:"String"}}},i2={parameterPath:"comp",mapper:{defaultValue:"copy",isConstant:!0,serializedName:"comp",type:{name:"String"}}},s2={parameterPath:"copyActionAbortConstant",mapper:{defaultValue:"abort",isConstant:!0,serializedName:"x-ms-copy-action",type:{name:"String"}}},o2={parameterPath:"copyId",mapper:{serializedName:"copyid",required:!0,xmlName:"copyid",type:{name:"String"}}},l2={parameterPath:"comp",mapper:{defaultValue:"tier",isConstant:!0,serializedName:"comp",type:{name:"String"}}},c2={parameterPath:"tier",mapper:{serializedName:"x-ms-access-tier",required:!0,xmlName:"x-ms-access-tier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive"]}}},m2={parameterPath:["options","queryRequest"],mapper:Q0},d2={parameterPath:"comp",mapper:{defaultValue:"query",isConstant:!0,serializedName:"comp",type:{name:"String"}}},w1={parameterPath:"comp",mapper:{defaultValue:"tags",isConstant:!0,serializedName:"comp",type:{name:"String"}}},u2={parameterPath:["options","tags"],mapper:yc},xn={parameterPath:["options","transactionalContentMD5"],mapper:{serializedName:"Content-MD5",xmlName:"Content-MD5",type:{name:"ByteArray"}}},Hi={parameterPath:["options","transactionalContentCrc64"],mapper:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}},p2={parameterPath:"blobType",mapper:{defaultValue:"PageBlob",isConstant:!0,serializedName:"x-ms-blob-type",type:{name:"String"}}},I1={parameterPath:"blobContentLength",mapper:{serializedName:"x-ms-blob-content-length",required:!0,xmlName:"x-ms-blob-content-length",type:{name:"Number"}}},M1={parameterPath:["options","blobSequenceNumber"],mapper:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}}},Qs={parameterPath:["options","contentType"],mapper:{defaultValue:"application/octet-stream",isConstant:!0,serializedName:"Content-Type",type:{name:"String"}}},Zs={parameterPath:"body",mapper:{serializedName:"body",required:!0,xmlName:"body",type:{name:"Stream"}}},Js={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:!0,serializedName:"Accept",type:{name:"String"}}},Cd={parameterPath:"comp",mapper:{defaultValue:"page",isConstant:!0,serializedName:"comp",type:{name:"String"}}},A1={parameterPath:"pageWrite",mapper:{defaultValue:"update",isConstant:!0,serializedName:"x-ms-page-write",type:{name:"String"}}},Rd={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThanOrEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-le",xmlName:"x-ms-if-sequence-number-le",type:{name:"Number"}}},Ed={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThan"],mapper:{serializedName:"x-ms-if-sequence-number-lt",xmlName:"x-ms-if-sequence-number-lt",type:{name:"Number"}}},Td={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-eq",xmlName:"x-ms-if-sequence-number-eq",type:{name:"Number"}}},f2={parameterPath:"pageWrite",mapper:{defaultValue:"clear",isConstant:!0,serializedName:"x-ms-page-write",type:{name:"String"}}},Ko={parameterPath:"sourceUrl",mapper:{serializedName:"x-ms-copy-source",required:!0,xmlName:"x-ms-copy-source",type:{name:"String"}}},h2={parameterPath:"sourceRange",mapper:{serializedName:"x-ms-source-range",required:!0,xmlName:"x-ms-source-range",type:{name:"String"}}},Xo={parameterPath:["options","sourceContentCrc64"],mapper:{serializedName:"x-ms-source-content-crc64",xmlName:"x-ms-source-content-crc64",type:{name:"ByteArray"}}},y2={parameterPath:"range",mapper:{serializedName:"x-ms-range",required:!0,xmlName:"x-ms-range",type:{name:"String"}}},B1={parameterPath:"comp",mapper:{defaultValue:"pagelist",isConstant:!0,serializedName:"comp",type:{name:"String"}}},x2={parameterPath:["options","prevsnapshot"],mapper:{serializedName:"prevsnapshot",xmlName:"prevsnapshot",type:{name:"String"}}},g2={parameterPath:["options","prevSnapshotUrl"],mapper:{serializedName:"x-ms-previous-snapshot-url",xmlName:"x-ms-previous-snapshot-url",type:{name:"String"}}},v2={parameterPath:"sequenceNumberAction",mapper:{serializedName:"x-ms-sequence-number-action",required:!0,xmlName:"x-ms-sequence-number-action",type:{name:"Enum",allowedValues:["max","update","increment"]}}},_2={parameterPath:"comp",mapper:{defaultValue:"incrementalcopy",isConstant:!0,serializedName:"comp",type:{name:"String"}}},b2={parameterPath:"blobType",mapper:{defaultValue:"AppendBlob",isConstant:!0,serializedName:"x-ms-blob-type",type:{name:"String"}}},O1={parameterPath:"comp",mapper:{defaultValue:"appendblock",isConstant:!0,serializedName:"comp",type:{name:"String"}}},z1={parameterPath:["options","appendPositionAccessConditions","maxSize"],mapper:{serializedName:"x-ms-blob-condition-maxsize",xmlName:"x-ms-blob-condition-maxsize",type:{name:"Number"}}},wd={parameterPath:["options","appendPositionAccessConditions","appendPosition"],mapper:{serializedName:"x-ms-blob-condition-appendpos",xmlName:"x-ms-blob-condition-appendpos",type:{name:"Number"}}},Id={parameterPath:["options","sourceRange"],mapper:{serializedName:"x-ms-source-range",xmlName:"x-ms-source-range",type:{name:"String"}}},S2={parameterPath:"comp",mapper:{defaultValue:"seal",isConstant:!0,serializedName:"comp",type:{name:"String"}}},L1={parameterPath:"blobType",mapper:{defaultValue:"BlockBlob",isConstant:!0,serializedName:"x-ms-blob-type",type:{name:"String"}}},N2={parameterPath:["options","copySourceBlobProperties"],mapper:{serializedName:"x-ms-copy-source-blob-properties",xmlName:"x-ms-copy-source-blob-properties",type:{name:"Boolean"}}},q1={parameterPath:"comp",mapper:{defaultValue:"block",isConstant:!0,serializedName:"comp",type:{name:"String"}}},H1={parameterPath:"blockId",mapper:{serializedName:"blockid",required:!0,xmlName:"blockid",type:{name:"String"}}},P2={parameterPath:"blocks",mapper:W0},D1={parameterPath:"comp",mapper:{defaultValue:"blocklist",isConstant:!0,serializedName:"comp",type:{name:"String"}}},C2={parameterPath:"listType",mapper:{defaultValue:"committed",serializedName:"blocklisttype",required:!0,xmlName:"blocklisttype",type:{name:"Enum",allowedValues:["committed","uncommitted","all"]}}};var Wo=class{constructor(e){this.client=e}setProperties(e,t){let a={blobServiceProperties:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,HE)}getProperties(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,DE)}getStatistics(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,kE)}listContainersSegment(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,FE)}getUserDelegationKey(e,t){let a={keyInfo:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,UE)}getAccountInfo(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,jE)}submitBatch(e,t,a,n){let i={contentLength:e,multipartContentType:t,body:a,options:Ye(n||{})};return this.client.sendOperationRequest(i,VE)}filterBlobs(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,GE)}},ps=new kr(ya,!0),HE={path:"/",httpMethod:"PUT",responses:{202:{headersMapper:Z0},default:{bodyMapper:Qe,headersMapper:J0}},requestBody:Mb,queryParameters:[xc,fn,at],urlParameters:[Ze],headerParameters:[un,pn,Je,nt],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:ps},DE={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:hc,headersMapper:ef},default:{bodyMapper:Qe,headersMapper:tf}},queryParameters:[xc,fn,at],urlParameters:[Ze],headerParameters:[Je,nt,mt],isXML:!0,serializer:ps},kE={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:U0,headersMapper:rf},default:{bodyMapper:Qe,headersMapper:af}},queryParameters:[xc,at,Ab],urlParameters:[Ze],headerParameters:[Je,nt,mt],isXML:!0,serializer:ps},FE={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:j0,headersMapper:nf},default:{bodyMapper:Qe,headersMapper:sf}},queryParameters:[at,gc,vc,jo,Vo,Bb],urlParameters:[Ze],headerParameters:[Je,nt,mt],isXML:!0,serializer:ps},UE={path:"/",httpMethod:"POST",responses:{200:{bodyMapper:G0,headersMapper:of},default:{bodyMapper:Qe,headersMapper:lf}},requestBody:Ob,queryParameters:[xc,at,zb],urlParameters:[Ze],headerParameters:[un,pn,Je,nt],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:ps},jE={path:"/",httpMethod:"GET",responses:{200:{headersMapper:cf},default:{bodyMapper:Qe,headersMapper:mf}},queryParameters:[fn,Go],urlParameters:[Ze],headerParameters:[Je,mt],isXML:!0,serializer:ps},VE={path:"/",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:df},default:{bodyMapper:Qe,headersMapper:uf}},requestBody:md,queryParameters:[at,dd],urlParameters:[Ze],headerParameters:[un,pn,Je,nt,ia,ud],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:ps},GE={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:K0,headersMapper:pf},default:{bodyMapper:Qe,headersMapper:ff}},queryParameters:[at,jo,Vo,Lb,qb],urlParameters:[Ze],headerParameters:[Je,nt,mt],isXML:!0,serializer:ps};var qn=class{constructor(e){this.client=e}create(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,KE)}getProperties(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,XE)}delete(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,$E)}setMetadata(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,WE)}getAccessPolicy(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,YE)}setAccessPolicy(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,QE)}restore(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,ZE)}rename(e,t){let a={sourceContainerName:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,JE)}submitBatch(e,t,a,n){let i={contentLength:e,multipartContentType:t,body:a,options:Ye(n||{})};return this.client.sendOperationRequest(i,e4)}acquireLease(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,t4)}releaseLease(e,t){let a={leaseId:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,r4)}renewLease(e,t){let a={leaseId:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,a4)}breakLease(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,n4)}changeLease(e,t,a){let n={leaseId:e,proposedLeaseId:t,options:Ye(a||{})};return this.client.sendOperationRequest(n,i4)}listBlobFlatSegment(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,s4)}listBlobHierarchySegment(e,t){let a={delimiter:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,o4)}getAccountInfo(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,l4)}},ua=new kr(ya,!0),KE={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:hf},default:{bodyMapper:Qe,headersMapper:yf}},queryParameters:[at,da],urlParameters:[Ze],headerParameters:[Je,nt,mt,xa,P1,Hb,Db],isXML:!0,serializer:ua},XE={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:xf},default:{bodyMapper:Qe,headersMapper:gf}},queryParameters:[at,da],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt],isXML:!0,serializer:ua},$E={path:"/{containerName}",httpMethod:"DELETE",responses:{202:{headersMapper:vf},default:{bodyMapper:Qe,headersMapper:_f}},queryParameters:[at,da],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et],isXML:!0,serializer:ua},WE={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:bf},default:{bodyMapper:Qe,headersMapper:Sf}},queryParameters:[at,da,pd],urlParameters:[Ze],headerParameters:[Je,nt,mt,xa,Mt,Rt],isXML:!0,serializer:ua},YE={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}},serializedName:"SignedIdentifiers",xmlName:"SignedIdentifiers",xmlIsWrapped:!0,xmlElementName:"SignedIdentifier"},headersMapper:Nf},default:{bodyMapper:Qe,headersMapper:Pf}},queryParameters:[at,da,C1],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt],isXML:!0,serializer:ua},QE={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Cf},default:{bodyMapper:Qe,headersMapper:Rf}},requestBody:kb,queryParameters:[at,da,C1],urlParameters:[Ze],headerParameters:[un,pn,Je,nt,P1,Mt,Rt,Et],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:ua},ZE={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Ef},default:{bodyMapper:Qe,headersMapper:Tf}},queryParameters:[at,da,fd],urlParameters:[Ze],headerParameters:[Je,nt,mt,Fb,Ub],isXML:!0,serializer:ua},JE={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:wf},default:{bodyMapper:Qe,headersMapper:If}},queryParameters:[at,da,jb],urlParameters:[Ze],headerParameters:[Je,nt,mt,Vb,Gb],isXML:!0,serializer:ua},e4={path:"/{containerName}",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Mf},default:{bodyMapper:Qe,headersMapper:Af}},requestBody:md,queryParameters:[at,dd,da],urlParameters:[Ze],headerParameters:[un,pn,Je,nt,ia,ud],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:ua},t4={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Bf},default:{bodyMapper:Qe,headersMapper:Of}},queryParameters:[at,da,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,hd,yd,xd],isXML:!0,serializer:ua},r4={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:zf},default:{bodyMapper:Qe,headersMapper:Lf}},queryParameters:[at,da,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,gd,us],isXML:!0,serializer:ua},a4={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:qf},default:{bodyMapper:Qe,headersMapper:Hf}},queryParameters:[at,da,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,us,vd],isXML:!0,serializer:ua},n4={path:"/{containerName}",httpMethod:"PUT",responses:{202:{headersMapper:Df},default:{bodyMapper:Qe,headersMapper:kf}},queryParameters:[at,da,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,_d,bd],isXML:!0,serializer:ua},i4={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Ff},default:{bodyMapper:Qe,headersMapper:Uf}},queryParameters:[at,da,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,us,Sd,Nd],isXML:!0,serializer:ua},s4={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:X0,headersMapper:jf},default:{bodyMapper:Qe,headersMapper:Vf}},queryParameters:[at,gc,vc,jo,Vo,da,R1],urlParameters:[Ze],headerParameters:[Je,nt,mt],isXML:!0,serializer:ua},o4={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:$0,headersMapper:Gf},default:{bodyMapper:Qe,headersMapper:Kf}},queryParameters:[at,gc,vc,jo,Vo,da,R1,Kb],urlParameters:[Ze],headerParameters:[Je,nt,mt],isXML:!0,serializer:ua},l4={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:Xf},default:{bodyMapper:Qe,headersMapper:$f}},queryParameters:[fn,Go],urlParameters:[Ze],headerParameters:[Je,mt],isXML:!0,serializer:ua};var eo=class{constructor(e){this.client=e}download(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,c4)}getProperties(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,m4)}delete(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,d4)}undelete(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,u4)}setExpiry(e,t){let a={expiryOptions:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,p4)}setHttpHeaders(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,f4)}setImmutabilityPolicy(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,h4)}deleteImmutabilityPolicy(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,y4)}setLegalHold(e,t){let a={legalHold:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,x4)}setMetadata(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,g4)}acquireLease(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,v4)}releaseLease(e,t){let a={leaseId:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,_4)}renewLease(e,t){let a={leaseId:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,b4)}changeLease(e,t,a){let n={leaseId:e,proposedLeaseId:t,options:Ye(a||{})};return this.client.sendOperationRequest(n,S4)}breakLease(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,N4)}createSnapshot(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,P4)}startCopyFromURL(e,t){let a={copySource:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,C4)}copyFromURL(e,t){let a={copySource:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,R4)}abortCopyFromURL(e,t){let a={copyId:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,E4)}setTier(e,t){let a={tier:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,T4)}getAccountInfo(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,w4)}query(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,I4)}getTags(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,M4)}setTags(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,A4)}},_r=new kr(ya,!0),c4={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:od},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:od},default:{bodyMapper:Qe,headersMapper:Wf}},queryParameters:[at,yn,$s],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et,Ws,Xb,$b,Er,Tr,wr,Ut,jt,qt],isXML:!0,serializer:_r},m4={path:"/{containerName}/{blob}",httpMethod:"HEAD",responses:{200:{headersMapper:Yf},default:{bodyMapper:Qe,headersMapper:Qf}},queryParameters:[at,yn,$s],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt],isXML:!0,serializer:_r},d4={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{202:{headersMapper:Zf},default:{bodyMapper:Qe,headersMapper:Jf}},queryParameters:[at,yn,$s,Yb],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et,Ut,jt,qt,Wb],isXML:!0,serializer:_r},u4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:eh},default:{bodyMapper:Qe,headersMapper:th}},queryParameters:[at,fd],urlParameters:[Ze],headerParameters:[Je,nt,mt],isXML:!0,serializer:_r},p4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:rh},default:{bodyMapper:Qe,headersMapper:ah}},queryParameters:[at,Qb],urlParameters:[Ze],headerParameters:[Je,nt,mt,Zb,Jb],isXML:!0,serializer:_r},f4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:nh},default:{bodyMapper:Qe,headersMapper:ih}},queryParameters:[fn,at],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et,Ut,jt,qt,ci,mi,di,ui,pi,fi],isXML:!0,serializer:_r},h4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:sh},default:{bodyMapper:Qe,headersMapper:oh}},queryParameters:[at,E1],urlParameters:[Ze],headerParameters:[Je,nt,mt,Et,On,zn],isXML:!0,serializer:_r},y4={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{200:{headersMapper:lh},default:{bodyMapper:Qe,headersMapper:ch}},queryParameters:[at,E1],urlParameters:[Ze],headerParameters:[Je,nt,mt],isXML:!0,serializer:_r},x4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:mh},default:{bodyMapper:Qe,headersMapper:dh}},queryParameters:[at,e2],urlParameters:[Ze],headerParameters:[Je,nt,mt,t2],isXML:!0,serializer:_r},g4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:uh},default:{bodyMapper:Qe,headersMapper:ph}},queryParameters:[at,pd],urlParameters:[Ze],headerParameters:[Je,nt,mt,xa,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,Xr],isXML:!0,serializer:_r},v4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:fh},default:{bodyMapper:Qe,headersMapper:hh}},queryParameters:[at,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,hd,yd,xd,Ut,jt,qt],isXML:!0,serializer:_r},_4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:yh},default:{bodyMapper:Qe,headersMapper:xh}},queryParameters:[at,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,gd,us,Ut,jt,qt],isXML:!0,serializer:_r},b4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:gh},default:{bodyMapper:Qe,headersMapper:vh}},queryParameters:[at,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,us,vd,Ut,jt,qt],isXML:!0,serializer:_r},S4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:_h},default:{bodyMapper:Qe,headersMapper:bh}},queryParameters:[at,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,us,Sd,Nd,Ut,jt,qt],isXML:!0,serializer:_r},N4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Sh},default:{bodyMapper:Qe,headersMapper:Nh}},queryParameters:[at,hn],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,_d,bd,Ut,jt,qt],isXML:!0,serializer:_r},P4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ph},default:{bodyMapper:Qe,headersMapper:Ch}},queryParameters:[at,r2],urlParameters:[Ze],headerParameters:[Je,nt,mt,xa,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,Xr],isXML:!0,serializer:_r},C4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Rh},default:{bodyMapper:Qe,headersMapper:Eh}},queryParameters:[at],urlParameters:[Ze],headerParameters:[Je,nt,mt,xa,Mt,Rt,Et,Ut,jt,qt,On,zn,zi,T1,hi,yi,xi,gi,Pd,Ys,Ln,a2,vi],isXML:!0,serializer:_r},R4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Th},default:{bodyMapper:Qe,headersMapper:wh}},queryParameters:[at],urlParameters:[Ze],headerParameters:[Je,nt,mt,xa,Mt,Rt,Et,Ut,jt,qt,On,zn,zi,hi,yi,xi,gi,Ys,Ln,vi,n2,Li,qi],isXML:!0,serializer:_r},E4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:Ih},default:{bodyMapper:Qe,headersMapper:Mh}},queryParameters:[at,i2,o2],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,s2],isXML:!0,serializer:_r},T4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ld},202:{headersMapper:ld},default:{bodyMapper:Qe,headersMapper:Ah}},queryParameters:[at,yn,$s,l2],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,qt,T1,c2],isXML:!0,serializer:_r},w4={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{headersMapper:Bh},default:{bodyMapper:Qe,headersMapper:Oh}},queryParameters:[fn,Go],urlParameters:[Ze],headerParameters:[Je,mt],isXML:!0,serializer:_r},I4={path:"/{containerName}/{blob}",httpMethod:"POST",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:cd},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:cd},default:{bodyMapper:Qe,headersMapper:zh}},requestBody:m2,queryParameters:[at,yn,d2],urlParameters:[Ze],headerParameters:[un,pn,Je,nt,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:_r},M4={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:yc,headersMapper:Lh},default:{bodyMapper:Qe,headersMapper:qh}},queryParameters:[at,yn,$s,w1],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,qt],isXML:!0,serializer:_r},A4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:Hh},default:{bodyMapper:Qe,headersMapper:Dh}},requestBody:u2,queryParameters:[at,$s,w1],urlParameters:[Ze],headerParameters:[un,pn,Je,nt,Mt,qt,xn,Hi],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:_r};var Md=class{constructor(e){this.client=e}create(e,t,a){let n={contentLength:e,blobContentLength:t,options:Ye(a||{})};return this.client.sendOperationRequest(n,O4)}uploadPages(e,t,a){let n={contentLength:e,body:t,options:Ye(a||{})};return this.client.sendOperationRequest(n,z4)}clearPages(e,t){let a={contentLength:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,L4)}uploadPagesFromURL(e,t,a,n,i){let s={sourceUrl:e,sourceRange:t,contentLength:a,range:n,options:Ye(i||{})};return this.client.sendOperationRequest(s,q4)}getPageRanges(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,H4)}getPageRangesDiff(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,D4)}resize(e,t){let a={blobContentLength:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,k4)}updateSequenceNumber(e,t){let a={sequenceNumberAction:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,F4)}copyIncremental(e,t){let a={copySource:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,U4)}},fs=new kr(ya,!0),B4=new kr(ya,!1),O4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:kh},default:{bodyMapper:Qe,headersMapper:Fh}},queryParameters:[at],urlParameters:[Ze],headerParameters:[Je,nt,mt,ia,xa,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,ci,mi,di,ui,pi,fi,On,zn,Xr,zi,Ln,vi,p2,I1,M1],isXML:!0,serializer:fs},z4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Uh},default:{bodyMapper:Qe,headersMapper:jh}},requestBody:Zs,queryParameters:[at,Cd],urlParameters:[Ze],headerParameters:[Je,nt,ia,Mt,Rt,Et,Ws,Er,Tr,wr,Ut,jt,qt,Xr,xn,Hi,Qs,Js,A1,Rd,Ed,Td],mediaType:"binary",serializer:B4},L4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Vh},default:{bodyMapper:Qe,headersMapper:Gh}},queryParameters:[at,Cd],urlParameters:[Ze],headerParameters:[Je,nt,mt,ia,Mt,Rt,Et,Ws,Er,Tr,wr,Ut,jt,qt,Xr,Rd,Ed,Td,f2],isXML:!0,serializer:fs},q4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Kh},default:{bodyMapper:Qe,headersMapper:Xh}},queryParameters:[at,Cd],urlParameters:[Ze],headerParameters:[Je,nt,mt,ia,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,Xr,hi,yi,xi,gi,Li,qi,A1,Rd,Ed,Td,Ko,h2,Xo,y2],isXML:!0,serializer:fs},H4={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:sd,headersMapper:$h},default:{bodyMapper:Qe,headersMapper:Wh}},queryParameters:[at,yn,B1],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et,Ws,Ut,jt,qt],isXML:!0,serializer:fs},D4={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:sd,headersMapper:Yh},default:{bodyMapper:Qe,headersMapper:Qh}},queryParameters:[at,yn,B1,x2],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et,Ws,Ut,jt,qt,g2],isXML:!0,serializer:fs},k4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Zh},default:{bodyMapper:Qe,headersMapper:Jh}},queryParameters:[fn,at],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,Xr,I1],isXML:!0,serializer:fs},F4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:e1},default:{bodyMapper:Qe,headersMapper:t1}},queryParameters:[fn,at],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et,Ut,jt,qt,M1,v2],isXML:!0,serializer:fs},U4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:r1},default:{bodyMapper:Qe,headersMapper:a1}},queryParameters:[at,_2],urlParameters:[Ze],headerParameters:[Je,nt,mt,Rt,Et,Ut,jt,qt,Ys],isXML:!0,serializer:fs};var Ad=class{constructor(e){this.client=e}create(e,t){let a={contentLength:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,V4)}appendBlock(e,t,a){let n={contentLength:e,body:t,options:Ye(a||{})};return this.client.sendOperationRequest(n,G4)}appendBlockFromUrl(e,t,a){let n={sourceUrl:e,contentLength:t,options:Ye(a||{})};return this.client.sendOperationRequest(n,K4)}seal(e){let t={options:Ye(e||{})};return this.client.sendOperationRequest(t,X4)}},k1=new kr(ya,!0),j4=new kr(ya,!1),V4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:n1},default:{bodyMapper:Qe,headersMapper:i1}},queryParameters:[at],urlParameters:[Ze],headerParameters:[Je,nt,mt,ia,xa,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,ci,mi,di,ui,pi,fi,On,zn,Xr,Ln,vi,b2],isXML:!0,serializer:k1},G4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:s1},default:{bodyMapper:Qe,headersMapper:o1}},requestBody:Zs,queryParameters:[at,O1],urlParameters:[Ze],headerParameters:[Je,nt,ia,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,Xr,xn,Hi,Qs,Js,z1,wd],mediaType:"binary",serializer:j4},K4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:l1},default:{bodyMapper:Qe,headersMapper:c1}},queryParameters:[at,O1],urlParameters:[Ze],headerParameters:[Je,nt,mt,ia,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,Xr,hi,yi,xi,gi,Li,qi,xn,Ko,Xo,z1,wd,Id],isXML:!0,serializer:k1},X4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:m1},default:{bodyMapper:Qe,headersMapper:d1}},queryParameters:[at,S2],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,Rt,Et,Ut,jt,wd],isXML:!0,serializer:k1};var Bd=class{constructor(e){this.client=e}upload(e,t,a){let n={contentLength:e,body:t,options:Ye(a||{})};return this.client.sendOperationRequest(n,$4)}putBlobFromUrl(e,t,a){let n={contentLength:e,copySource:t,options:Ye(a||{})};return this.client.sendOperationRequest(n,W4)}stageBlock(e,t,a,n){let i={blockId:e,contentLength:t,body:a,options:Ye(n||{})};return this.client.sendOperationRequest(i,Y4)}stageBlockFromURL(e,t,a,n){let i={blockId:e,contentLength:t,sourceUrl:a,options:Ye(n||{})};return this.client.sendOperationRequest(i,Q4)}commitBlockList(e,t){let a={blocks:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,Z4)}getBlockList(e,t){let a={listType:e,options:Ye(t||{})};return this.client.sendOperationRequest(a,J4)}},Od=new kr(ya,!0),R2=new kr(ya,!1),$4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:u1},default:{bodyMapper:Qe,headersMapper:p1}},requestBody:Zs,queryParameters:[at],urlParameters:[Ze],headerParameters:[Je,nt,ia,xa,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,ci,mi,di,ui,pi,fi,On,zn,Xr,zi,Ln,vi,xn,Qs,Js,L1],mediaType:"binary",serializer:R2},W4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:f1},default:{bodyMapper:Qe,headersMapper:h1}},queryParameters:[at],urlParameters:[Ze],headerParameters:[Je,nt,mt,ia,xa,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,ci,mi,di,ui,pi,fi,Xr,zi,hi,yi,xi,gi,Pd,Ys,Ln,Li,qi,xn,L1,N2],isXML:!0,serializer:Od},Y4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:y1},default:{bodyMapper:Qe,headersMapper:x1}},requestBody:Zs,queryParameters:[at,q1,H1],urlParameters:[Ze],headerParameters:[Je,nt,ia,Mt,Er,Tr,wr,Xr,xn,Hi,Qs,Js],mediaType:"binary",serializer:R2},Q4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:g1},default:{bodyMapper:Qe,headersMapper:v1}},queryParameters:[at,q1,H1],urlParameters:[Ze],headerParameters:[Je,nt,mt,ia,Mt,Er,Tr,wr,Xr,hi,yi,xi,gi,Li,qi,Ko,Xo,Id],isXML:!0,serializer:Od},Z4={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:_1},default:{bodyMapper:Qe,headersMapper:b1}},requestBody:P2,queryParameters:[at,D1],urlParameters:[Ze],headerParameters:[un,pn,Je,nt,xa,Mt,Rt,Et,Er,Tr,wr,Ut,jt,qt,ci,mi,di,ui,pi,fi,On,zn,Xr,zi,Ln,vi,xn,Hi],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Od},J4={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:Y0,headersMapper:S1},default:{bodyMapper:Qe,headersMapper:N1}},queryParameters:[at,yn,D1,C2],urlParameters:[Ze],headerParameters:[Je,nt,mt,Mt,qt],isXML:!0,serializer:Od};var Ya=Gm("storage-blob");var E2="12.8.0",_c="2020-10-02";var zd="https://storage.azure.com/.default",Qa={Parameters:{FORCE_BROWSER_NO_CACHE:"_",SIGNATURE:"sig",SNAPSHOT:"snapshot",VERSIONID:"versionid",TIMEOUT:"timeout"}},T2={HTTP_ACCEPTED:202,HTTP_CONFLICT:409,HTTP_NOT_FOUND:404,HTTP_PRECON_FAILED:412,HTTP_RANGE_NOT_SATISFIABLE:416},Sa={AUTHORIZATION:"Authorization",AUTHORIZATION_SCHEME:"Bearer",CONTENT_ENCODING:"Content-Encoding",CONTENT_ID:"Content-ID",CONTENT_LANGUAGE:"Content-Language",CONTENT_LENGTH:"Content-Length",CONTENT_MD5:"Content-Md5",CONTENT_TRANSFER_ENCODING:"Content-Transfer-Encoding",CONTENT_TYPE:"Content-Type",COOKIE:"Cookie",DATE:"date",IF_MATCH:"if-match",IF_MODIFIED_SINCE:"if-modified-since",IF_NONE_MATCH:"if-none-match",IF_UNMODIFIED_SINCE:"if-unmodified-since",PREFIX_FOR_STORAGE:"x-ms-",RANGE:"Range",USER_AGENT:"User-Agent",X_MS_CLIENT_REQUEST_ID:"x-ms-client-request-id",X_MS_COPY_SOURCE:"x-ms-copy-source",X_MS_DATE:"x-ms-date",X_MS_ERROR_CODE:"x-ms-error-code",X_MS_VERSION:"x-ms-version"},Hn="",F1="*",eT=1*1024*1024,U1=256,Z9=4*eT,Dn=`\r
16
- `,Ld="HTTP/1.1",w2="AES256",I2="DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;",M2=["Access-Control-Allow-Origin","Cache-Control","Content-Length","Content-Type","Date","Request-Id","traceparent","Transfer-Encoding","User-Agent","x-ms-client-request-id","x-ms-date","x-ms-error-code","x-ms-request-id","x-ms-return-client-request-id","x-ms-version","Accept-Ranges","Content-Disposition","Content-Encoding","Content-Language","Content-MD5","Content-Range","ETag","Last-Modified","Server","Vary","x-ms-content-crc64","x-ms-copy-action","x-ms-copy-completion-time","x-ms-copy-id","x-ms-copy-progress","x-ms-copy-status","x-ms-has-immutability-policy","x-ms-has-legal-hold","x-ms-lease-state","x-ms-lease-status","x-ms-range","x-ms-request-server-encrypted","x-ms-server-encrypted","x-ms-snapshot","x-ms-source-range","If-Match","If-Modified-Since","If-None-Match","If-Unmodified-Since","x-ms-access-tier","x-ms-access-tier-change-time","x-ms-access-tier-inferred","x-ms-account-kind","x-ms-archive-status","x-ms-blob-append-offset","x-ms-blob-cache-control","x-ms-blob-committed-block-count","x-ms-blob-condition-appendpos","x-ms-blob-condition-maxsize","x-ms-blob-content-disposition","x-ms-blob-content-encoding","x-ms-blob-content-language","x-ms-blob-content-length","x-ms-blob-content-md5","x-ms-blob-content-type","x-ms-blob-public-access","x-ms-blob-sequence-number","x-ms-blob-type","x-ms-copy-destination-snapshot","x-ms-creation-time","x-ms-default-encryption-scope","x-ms-delete-snapshots","x-ms-delete-type-permanent","x-ms-deny-encryption-scope-override","x-ms-encryption-algorithm","x-ms-if-sequence-number-eq","x-ms-if-sequence-number-le","x-ms-if-sequence-number-lt","x-ms-incremental-copy","x-ms-lease-action","x-ms-lease-break-period","x-ms-lease-duration","x-ms-lease-id","x-ms-lease-time","x-ms-page-write","x-ms-proposed-lease-id","x-ms-range-get-content-md5","x-ms-rehydrate-priority","x-ms-sequence-number-action","x-ms-sku-name","x-ms-source-content-md5","x-ms-source-if-match","x-ms-source-if-modified-since","x-ms-source-if-none-match","x-ms-source-if-unmodified-since","x-ms-tag-count","x-ms-encryption-key-sha256","x-ms-if-tags","x-ms-source-if-tags"],A2=["comp","maxresults","rscc","rscd","rsce","rscl","rsct","se","si","sip","sp","spr","sr","srt","ss","st","sv","include","marker","prefix","copyid","restype","blockid","blocklisttype","delimiter","prevsnapshot","ske","skoid","sks","skt","sktid","skv","snapshot"];function B2(r){let e=ar.parse(r),t=e.getPath();return t=t||"/",t=rT(t),e.setPath(t),e.toString()}function tT(r){let e="";if(r.search("DevelopmentStorageProxyUri=")!==-1){let t=r.split(";");for(let a of t)a.trim().startsWith("DevelopmentStorageProxyUri=")&&(e=a.trim().match("DevelopmentStorageProxyUri=(.*)")[1])}return e}function Yo(r,e){let t=r.split(";");for(let a of t)if(a.trim().startsWith(e))return a.trim().match(e+"=(.*)")[1];return""}function Di(r){let e="";r.startsWith("UseDevelopmentStorage=true")&&(e=tT(r),r=I2);let t=Yo(r,"BlobEndpoint");if(t=t.endsWith("/")?t.slice(0,-1):t,r.search("DefaultEndpointsProtocol=")!==-1&&r.search("AccountKey=")!==-1){let a="",n="",i=Buffer.from("accountKey","base64"),s="";if(n=Yo(r,"AccountName"),i=Buffer.from(Yo(r,"AccountKey"),"base64"),!t){a=Yo(r,"DefaultEndpointsProtocol");let o=a.toLowerCase();if(o!=="https"&&o!=="http")throw new Error("Invalid DefaultEndpointsProtocol in the provided Connection String. Expecting 'https' or 'http'");if(s=Yo(r,"EndpointSuffix"),!s)throw new Error("Invalid EndpointSuffix in the provided Connection String");t=`${a}://${n}.blob.${s}`}if(n){if(i.length===0)throw new Error("Invalid AccountKey in the provided Connection String")}else throw new Error("Invalid AccountName in the provided Connection String");return{kind:"AccountConnString",url:t,accountName:n,accountKey:i,proxyUri:e}}else{let a=Yo(r,"SharedAccessSignature"),n=G1(t);if(t){if(!a)throw new Error("Invalid SharedAccessSignature in the provided SAS Connection String")}else throw new Error("Invalid BlobEndpoint in the provided SAS Connection String");return{kind:"SASConnString",url:t,accountName:n,accountSas:a}}}function rT(r){return encodeURIComponent(r).replace(/%2F/g,"/").replace(/'/g,"%27").replace(/\+/g,"%20").replace(/%25/g,"%")}function ur(r,e){let t=ar.parse(r),a=t.getPath();return a=a?a.endsWith("/")?`${a}${e}`:`${a}/${e}`:e,t.setPath(a),t.toString()}function _i(r,e,t){let a=ar.parse(r);return a.setQueryParameter(e,t),a.toString()}function j1(r,e){return ar.parse(r).getQueryParameterValue(e)}function O2(r,e){let t=ar.parse(r);return t.setHost(e),t.toString()}function qd(r){return ar.parse(r).getPath()}function z2(r){return ar.parse(r).getScheme()}function L2(r){let e=ar.parse(r),t=e.getPath();if(!t)throw new RangeError("Invalid url without valid path.");let a=e.getQuery()||"";return a=a.trim(),a!==""&&(a=a.startsWith("?")?a:`?${a}`),`${t}${a}`}function Qo(r,e){let t=ar.parse(r),a=t.getQuery();return a?a+="&"+e:a=e,t.setQuery(a),t.toString()}function sr(r,e=!0){let t=r.toISOString();return e?t.substring(0,t.length-1)+"0000Z":t.substring(0,t.length-5)+"Z"}function aT(r){return Lt?Buffer.from(r).toString("base64"):btoa(r)}function V1(r,e){r.length>42&&(r=r.slice(0,42));let i=r+nT(e.toString(),48-r.length,"0");return aT(i)}async function q2(r,e,t){return new Promise((a,n)=>{let i,s=()=>{i!==void 0&&clearTimeout(i),n(t)};i=setTimeout(()=>{e!==void 0&&e.removeEventListener("abort",s),a()},r),e!==void 0&&e.addEventListener("abort",s)})}function nT(r,e,t=" "){return String.prototype.padStart?r.padStart(e,t):(t=t||" ",r.length>e?r:(e=e-r.length,e>t.length&&(t+=t.repeat(e/t.length)),t.slice(0,e)+r))}function Hd(r,e){return r.toLocaleLowerCase()===e.toLocaleLowerCase()}function G1(r){let e=ar.parse(r),t;try{return e.getHost().split(".")[1]==="blob"?t=e.getHost().split(".")[0]:bc(e)?t=e.getPath().split("/")[1]:t="",t}catch{throw new Error("Unable to extract accountName with provided information.")}}function bc(r){if(r.getHost()===void 0)return!1;let e=r.getHost()+(r.getPort()===void 0?"":":"+r.getPort());return/^.*:.*:.*$|^localhost(:[0-9]+)?$|^(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])){3}(:[0-9]+)?$/.test(e)}function hs(r){if(r===void 0)return;let e=[];for(let t in r)if(Object.prototype.hasOwnProperty.call(r,t)){let a=r[t];e.push(`${encodeURIComponent(t)}=${encodeURIComponent(a)}`)}return e.join("&")}function H2(r){if(r===void 0)return;let e={blobTagSet:[]};for(let t in r)if(Object.prototype.hasOwnProperty.call(r,t)){let a=r[t];e.blobTagSet.push({key:t,value:a})}return e}function to(r){if(r===void 0)return;let e={};for(let t of r.blobTagSet)e[t.key]=t.value;return e}function K1(r){if(r!==void 0)switch(r.kind){case"csv":return{format:{type:"delimited",delimitedTextConfiguration:{columnSeparator:r.columnSeparator||",",fieldQuote:r.fieldQuote||"",recordSeparator:r.recordSeparator,escapeChar:r.escapeCharacter||"",headersPresent:r.hasHeaders||!1}}};case"json":return{format:{type:"json",jsonTextConfiguration:{recordSeparator:r.recordSeparator}}};case"arrow":return{format:{type:"arrow",arrowConfiguration:{schema:r.schema}}};case"parquet":return{format:{type:"parquet"}};default:throw Error("Invalid BlobQueryTextConfiguration.")}}function Zo(r){if(!r||"policy-id"in r)return;let e=[];for(let t in r){let a=t.split("_"),n="or-";a[0].startsWith(n)&&(a[0]=a[0].substring(n.length));let i={ruleId:a[1],replicationStatus:r[t]},s=e.findIndex(o=>o.policyId===a[0]);s>-1?e[s].rules.push(i):e.push({policyId:a[0],rules:[i]})}return e}function Dd(r,e){return r.credential=e,r}function Jo(r){return r?r.scheme+" "+r.value:void 0}var kd=class extends It{constructor(e,t){super(e,t)}async sendRequest(e){return Lt?this._nextPolicy.sendRequest(e):((e.method.toUpperCase()==="GET"||e.method.toUpperCase()==="HEAD")&&(e.url=_i(e.url,Qa.Parameters.FORCE_BROWSER_NO_CACHE,new Date().getTime().toString())),e.headers.remove(Sa.COOKIE),e.headers.remove(Sa.CONTENT_LENGTH),this._nextPolicy.sendRequest(e))}};var Fd=class{create(e,t){return new kd(e,t)}};var el;(function(r){r[r.EXPONENTIAL=0]="EXPONENTIAL",r[r.FIXED=1]="FIXED"})(el||(el={}));var ys={maxRetryDelayInMs:120*1e3,maxTries:4,retryDelayInMs:4*1e3,retryPolicyType:el.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void 0},iT=new ii("The operation was aborted."),Ud=class extends It{constructor(e,t,a=ys){super(e,t),this.retryOptions={retryPolicyType:a.retryPolicyType?a.retryPolicyType:ys.retryPolicyType,maxTries:a.maxTries&&a.maxTries>=1?Math.floor(a.maxTries):ys.maxTries,tryTimeoutInMs:a.tryTimeoutInMs&&a.tryTimeoutInMs>=0?a.tryTimeoutInMs:ys.tryTimeoutInMs,retryDelayInMs:a.retryDelayInMs&&a.retryDelayInMs>=0?Math.min(a.retryDelayInMs,a.maxRetryDelayInMs?a.maxRetryDelayInMs:ys.maxRetryDelayInMs):ys.retryDelayInMs,maxRetryDelayInMs:a.maxRetryDelayInMs&&a.maxRetryDelayInMs>=0?a.maxRetryDelayInMs:ys.maxRetryDelayInMs,secondaryHost:a.secondaryHost?a.secondaryHost:ys.secondaryHost}}async sendRequest(e){return this.attemptSendRequest(e,!1,1)}async attemptSendRequest(e,t,a){let n=e.clone(),i=t||!this.retryOptions.secondaryHost||!(e.method==="GET"||e.method==="HEAD"||e.method==="OPTIONS")||a%2===1;i||(n.url=O2(n.url,this.retryOptions.secondaryHost)),this.retryOptions.tryTimeoutInMs&&(n.url=_i(n.url,Qa.Parameters.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString()));let s;try{if(Ya.info(`RetryPolicy: =====> Try=${a} ${i?"Primary":"Secondary"}`),s=await this._nextPolicy.sendRequest(n),!this.shouldRetry(i,a,s))return s;t=t||!i&&s.status===404}catch(o){if(Ya.error(`RetryPolicy: Caught error, message: ${o.message}, code: ${o.code}`),!this.shouldRetry(i,a,s,o))throw o}return await this.delay(i,a,e.abortSignal),this.attemptSendRequest(e,t,++a)}shouldRetry(e,t,a,n){if(t>=this.retryOptions.maxTries)return Ya.info(`RetryPolicy: Attempt(s) ${t} >= maxTries ${this.retryOptions.maxTries}, no further try.`),!1;let i=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(n){for(let s of i)if(n.name.toUpperCase().includes(s)||n.message.toUpperCase().includes(s)||n.code&&n.code.toString().toUpperCase()===s)return Ya.info(`RetryPolicy: Network error ${s} found, will retry.`),!0}if(a||n){let s=a?a.status:n?n.statusCode:0;if(!e&&s===404)return Ya.info("RetryPolicy: Secondary access with 404, will retry."),!0;if(s===503||s===500)return Ya.info(`RetryPolicy: Will retry for status code ${s}.`),!0}return n?.code==="PARSE_ERROR"&&n?.message.startsWith('Error "Error: Unclosed root tag')?(Ya.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry."),!0):!1}async delay(e,t,a){let n=0;if(e)switch(this.retryOptions.retryPolicyType){case el.EXPONENTIAL:n=Math.min((Math.pow(2,t-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;case el.FIXED:n=this.retryOptions.retryDelayInMs;break}else n=Math.random()*1e3;return Ya.info(`RetryPolicy: Delay for ${n}ms`),q2(n,a,iT)}};var jd=class{constructor(e){this.retryOptions=e}create(e,t){return new Ud(e,t,this.retryOptions)}};var Vd=class extends It{sendRequest(e){return this._nextPolicy.sendRequest(this.signRequest(e))}signRequest(e){return e}};var Gd=class extends Vd{constructor(e,t){super(e,t)}};var Kd=class{create(e,t){throw new Error("Method should be implemented in children classes.")}};var Vt=class extends Kd{create(e,t){return new Gd(e,t)}};var Wd=ns(D2());var Xd=class extends It{constructor(e,t,a){super(e,t),this.telemetry=a}async sendRequest(e){return Lt&&(e.headers||(e.headers=new Kr),e.headers.get(Sa.USER_AGENT)||e.headers.set(Sa.USER_AGENT,this.telemetry)),this._nextPolicy.sendRequest(e)}};var $d=class{constructor(e){let t=[];if(Lt){if(e){let i=e.userAgentPrefix||"";i.length>0&&t.indexOf(i)===-1&&t.push(i)}let a=`azsdk-js-storageblob/${E2}`;t.indexOf(a)===-1&&t.push(a);let n=`(NODE-VERSION ${process.version}; ${Wd.type()} ${Wd.release()})`;t.indexOf(n)===-1&&t.push(n)}this.telemetryString=t.join(" ")}create(e,t){return new Xd(e,t,this.telemetryString)}};var sT=new os;function k2(){return sT}function kn(r){if(!r||typeof r!="object")return!1;let e=r;return Array.isArray(e.factories)&&typeof e.options=="object"&&typeof e.toServiceClientOptions=="function"}var Sc=class{constructor(e,t={}){this.factories=e,this.options=Object.assign(Object.assign({},t),{httpClient:t.httpClient||k2()})}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}};function Yt(r,e={}){r===void 0&&(r=new Vt);let t=new $d(e.userAgentOptions),a=[L0({userAgent:t.telemetryString}),b0(e.keepAliveOptions),t,ac(),new Fd,new jd(e.retryOptions),Vs(void 0,{xmlCharKey:"#"}),tc({logger:Ya.info,allowedHeaderNames:M2,allowedQueryParameters:A2})];return Lt&&(a.push(nc(e.proxyOptions)),a.push(q0())),a.push(Ar(r)?Dd(Gs(r,zd),r):r),new Sc(a,e)}var or=class{};var oT="azure-storage-blob",lT="12.8.0",ki=class extends pc{constructor(e,t){if(e===void 0)throw new Error("'url' cannot be null");if(t||(t={}),!t.userAgent){let a=Do();t.userAgent=`${oT}/${lT} ${a}`}super(void 0,t),this.requestContentType="application/json; charset=utf-8",this.baseUri=t.endpoint||"{url}",this.url=e,this.version=t.version||"2020-10-02"}};var xs=class{constructor(e,t){this.url=B2(e),this.accountName=G1(e),this.pipeline=t,this.storageClientContext=new ki(this.url,t.toServiceClientOptions()),this.isHttps=Hd(z2(this.url)||"","https"),this.credential=new Vt;for(let n of this.pipeline.factories)Lt&&n instanceof or||n instanceof Vt?this.credential=n:Ar(n.credential)&&(this.credential=n.credential);let a=this.storageClientContext;a.requestContentType=void 0}};var Ge=dc({packagePrefix:"Azure.Storage.Blob",namespace:"Microsoft.Storage"});function st(r){var e,t;return{spanOptions:(e=r?.tracingOptions)===null||e===void 0?void 0:e.spanOptions,tracingContext:(t=r?.tracingOptions)===null||t===void 0?void 0:t.tracingContext}}var bi=class{constructor(){this.read=!1,this.add=!1,this.create=!1,this.write=!1,this.delete=!1,this.deleteVersion=!1,this.tag=!1,this.move=!1,this.execute=!1,this.setImmutabilityPolicy=!1}static parse(e){let t=new bi;for(let a of e)switch(a){case"r":t.read=!0;break;case"a":t.add=!0;break;case"c":t.create=!0;break;case"w":t.write=!0;break;case"d":t.delete=!0;break;case"x":t.deleteVersion=!0;break;case"t":t.tag=!0;break;case"m":t.move=!0;break;case"e":t.execute=!0;break;case"i":t.setImmutabilityPolicy=!0;break;default:throw new RangeError(`Invalid permission: ${a}`)}return t}static from(e){let t=new bi;return e.read&&(t.read=!0),e.add&&(t.add=!0),e.create&&(t.create=!0),e.write&&(t.write=!0),e.delete&&(t.delete=!0),e.deleteVersion&&(t.deleteVersion=!0),e.tag&&(t.tag=!0),e.move&&(t.move=!0),e.execute&&(t.execute=!0),e.setImmutabilityPolicy&&(t.setImmutabilityPolicy=!0),t}toString(){let e=[];return this.read&&e.push("r"),this.add&&e.push("a"),this.create&&e.push("c"),this.write&&e.push("w"),this.delete&&e.push("d"),this.deleteVersion&&e.push("x"),this.tag&&e.push("t"),this.move&&e.push("m"),this.execute&&e.push("e"),this.setImmutabilityPolicy&&e.push("i"),e.join("")}};var Si=class{constructor(){this.read=!1,this.add=!1,this.create=!1,this.write=!1,this.delete=!1,this.deleteVersion=!1,this.list=!1,this.tag=!1,this.move=!1,this.execute=!1,this.setImmutabilityPolicy=!1}static parse(e){let t=new Si;for(let a of e)switch(a){case"r":t.read=!0;break;case"a":t.add=!0;break;case"c":t.create=!0;break;case"w":t.write=!0;break;case"d":t.delete=!0;break;case"l":t.list=!0;break;case"t":t.tag=!0;break;case"x":t.deleteVersion=!0;break;case"m":t.move=!0;break;case"e":t.execute=!0;break;case"i":t.setImmutabilityPolicy=!0;break;default:throw new RangeError(`Invalid permission ${a}`)}return t}static from(e){let t=new Si;return e.read&&(t.read=!0),e.add&&(t.add=!0),e.create&&(t.create=!0),e.write&&(t.write=!0),e.delete&&(t.delete=!0),e.list&&(t.list=!0),e.deleteVersion&&(t.deleteVersion=!0),e.tag&&(t.tag=!0),e.move&&(t.move=!0),e.execute&&(t.execute=!0),e.setImmutabilityPolicy&&(t.setImmutabilityPolicy=!0),t}toString(){let e=[];return this.read&&e.push("r"),this.add&&e.push("a"),this.create&&e.push("c"),this.write&&e.push("w"),this.delete&&e.push("d"),this.deleteVersion&&e.push("x"),this.list&&e.push("l"),this.tag&&e.push("t"),this.move&&e.push("m"),this.execute&&e.push("e"),this.setImmutabilityPolicy&&e.push("i"),e.join("")}};var Yd=class{};function Fi(r){return r.end?`${r.start}-${r.end}`:r.start}var F2;(function(r){r.Https="https",r.HttpsAndHttp="https,http"})(F2||(F2={}));var Ui=class{constructor(e,t,a,n,i,s,o,l,c,p,M,S,O,E,q,C,W,ae,Ce){this.version=e,this.signature=t,a!==void 0&&typeof a!="string"?(this.permissions=a.permissions,this.services=a.services,this.resourceTypes=a.resourceTypes,this.protocol=a.protocol,this.startsOn=a.startsOn,this.expiresOn=a.expiresOn,this.ipRangeInner=a.ipRange,this.identifier=a.identifier,this.resource=a.resource,this.cacheControl=a.cacheControl,this.contentDisposition=a.contentDisposition,this.contentEncoding=a.contentEncoding,this.contentLanguage=a.contentLanguage,this.contentType=a.contentType,a.userDelegationKey&&(this.signedOid=a.userDelegationKey.signedObjectId,this.signedTenantId=a.userDelegationKey.signedTenantId,this.signedStartsOn=a.userDelegationKey.signedStartsOn,this.signedExpiresOn=a.userDelegationKey.signedExpiresOn,this.signedService=a.userDelegationKey.signedService,this.signedVersion=a.userDelegationKey.signedVersion,this.preauthorizedAgentObjectId=a.preauthorizedAgentObjectId,this.correlationId=a.correlationId)):(this.services=n,this.resourceTypes=i,this.expiresOn=l,this.permissions=a,this.protocol=s,this.startsOn=o,this.ipRangeInner=c,this.identifier=p,this.resource=M,this.cacheControl=S,this.contentDisposition=O,this.contentEncoding=E,this.contentLanguage=q,this.contentType=C,W&&(this.signedOid=W.signedObjectId,this.signedTenantId=W.signedTenantId,this.signedStartsOn=W.signedStartsOn,this.signedExpiresOn=W.signedExpiresOn,this.signedService=W.signedService,this.signedVersion=W.signedVersion,this.preauthorizedAgentObjectId=ae,this.correlationId=Ce))}get ipRange(){if(this.ipRangeInner)return{end:this.ipRangeInner.end,start:this.ipRangeInner.start}}toString(){let e=["sv","ss","srt","spr","st","se","sip","si","skoid","sktid","skt","ske","sks","skv","sr","sp","sig","rscc","rscd","rsce","rscl","rsct","saoid","scid"],t=[];for(let a of e)switch(a){case"sv":this.tryAppendQueryParameter(t,a,this.version);break;case"ss":this.tryAppendQueryParameter(t,a,this.services);break;case"srt":this.tryAppendQueryParameter(t,a,this.resourceTypes);break;case"spr":this.tryAppendQueryParameter(t,a,this.protocol);break;case"st":this.tryAppendQueryParameter(t,a,this.startsOn?sr(this.startsOn,!1):void 0);break;case"se":this.tryAppendQueryParameter(t,a,this.expiresOn?sr(this.expiresOn,!1):void 0);break;case"sip":this.tryAppendQueryParameter(t,a,this.ipRange?Fi(this.ipRange):void 0);break;case"si":this.tryAppendQueryParameter(t,a,this.identifier);break;case"skoid":this.tryAppendQueryParameter(t,a,this.signedOid);break;case"sktid":this.tryAppendQueryParameter(t,a,this.signedTenantId);break;case"skt":this.tryAppendQueryParameter(t,a,this.signedStartsOn?sr(this.signedStartsOn,!1):void 0);break;case"ske":this.tryAppendQueryParameter(t,a,this.signedExpiresOn?sr(this.signedExpiresOn,!1):void 0);break;case"sks":this.tryAppendQueryParameter(t,a,this.signedService);break;case"skv":this.tryAppendQueryParameter(t,a,this.signedVersion);break;case"sr":this.tryAppendQueryParameter(t,a,this.resource);break;case"sp":this.tryAppendQueryParameter(t,a,this.permissions);break;case"sig":this.tryAppendQueryParameter(t,a,this.signature);break;case"rscc":this.tryAppendQueryParameter(t,a,this.cacheControl);break;case"rscd":this.tryAppendQueryParameter(t,a,this.contentDisposition);break;case"rsce":this.tryAppendQueryParameter(t,a,this.contentEncoding);break;case"rscl":this.tryAppendQueryParameter(t,a,this.contentLanguage);break;case"rsct":this.tryAppendQueryParameter(t,a,this.contentType);break;case"saoid":this.tryAppendQueryParameter(t,a,this.preauthorizedAgentObjectId);break;case"scid":this.tryAppendQueryParameter(t,a,this.correlationId);break}return t.join("&")}tryAppendQueryParameter(e,t,a){!a||(t=encodeURIComponent(t),a=encodeURIComponent(a),t.length>0&&a.length>0&&e.push(`${t}=${a}`))}};function Qd(r,e,t){let a=r.version?r.version:_c,n=e instanceof or?e:void 0,i;if(n===void 0&&t!==void 0&&(i=new Yd(t,e)),n===void 0&&i===void 0)throw TypeError("Invalid sharedKeyCredential, userDelegationKey or accountName.");if(a>="2018-11-09")return n!==void 0?mT(r,n):a>="2020-02-10"?uT(r,i):dT(r,i);if(a>="2015-04-05"){if(n!==void 0)return cT(r,n);throw new RangeError("'version' must be >= '2018-11-09' when generating user delegation SAS using user delegation key.")}throw new RangeError("'version' must be >= '2015-04-05'.")}function cT(r,e){if(r=Jd(r),!r.identifier&&!(r.permissions&&r.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let t="c";r.blobName&&(t="b");let a;r.permissions&&(r.blobName?a=bi.parse(r.permissions.toString()).toString():a=Si.parse(r.permissions.toString()).toString());let n=[a||"",r.startsOn?sr(r.startsOn,!1):"",r.expiresOn?sr(r.expiresOn,!1):"",Zd(e.accountName,r.containerName,r.blobName),r.identifier,r.ipRange?Fi(r.ipRange):"",r.protocol?r.protocol:"",r.version,r.cacheControl?r.cacheControl:"",r.contentDisposition?r.contentDisposition:"",r.contentEncoding?r.contentEncoding:"",r.contentLanguage?r.contentLanguage:"",r.contentType?r.contentType:""].join(`
17
- `),i=e.computeHMACSHA256(n);return new Ui(r.version,i,a,void 0,void 0,r.protocol,r.startsOn,r.expiresOn,r.ipRange,r.identifier,t,r.cacheControl,r.contentDisposition,r.contentEncoding,r.contentLanguage,r.contentType)}function mT(r,e){if(r=Jd(r),!r.identifier&&!(r.permissions&&r.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let t="c",a=r.snapshotTime;r.blobName&&(t="b",r.snapshotTime?t="bs":r.versionId&&(t="bv",a=r.versionId));let n;r.permissions&&(r.blobName?n=bi.parse(r.permissions.toString()).toString():n=Si.parse(r.permissions.toString()).toString());let i=[n||"",r.startsOn?sr(r.startsOn,!1):"",r.expiresOn?sr(r.expiresOn,!1):"",Zd(e.accountName,r.containerName,r.blobName),r.identifier,r.ipRange?Fi(r.ipRange):"",r.protocol?r.protocol:"",r.version,t,a,r.cacheControl?r.cacheControl:"",r.contentDisposition?r.contentDisposition:"",r.contentEncoding?r.contentEncoding:"",r.contentLanguage?r.contentLanguage:"",r.contentType?r.contentType:""].join(`
18
- `),s=e.computeHMACSHA256(i);return new Ui(r.version,s,n,void 0,void 0,r.protocol,r.startsOn,r.expiresOn,r.ipRange,r.identifier,t,r.cacheControl,r.contentDisposition,r.contentEncoding,r.contentLanguage,r.contentType)}function dT(r,e){if(r=Jd(r),!r.permissions||!r.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let t="c",a=r.snapshotTime;r.blobName&&(t="b",r.snapshotTime?t="bs":r.versionId&&(t="bv",a=r.versionId));let n;r.permissions&&(r.blobName?n=bi.parse(r.permissions.toString()).toString():n=Si.parse(r.permissions.toString()).toString());let i=[n||"",r.startsOn?sr(r.startsOn,!1):"",r.expiresOn?sr(r.expiresOn,!1):"",Zd(e.accountName,r.containerName,r.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?sr(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?sr(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,r.ipRange?Fi(r.ipRange):"",r.protocol?r.protocol:"",r.version,t,a,r.cacheControl,r.contentDisposition,r.contentEncoding,r.contentLanguage,r.contentType].join(`
19
- `),s=e.computeHMACSHA256(i);return new Ui(r.version,s,n,void 0,void 0,r.protocol,r.startsOn,r.expiresOn,r.ipRange,r.identifier,t,r.cacheControl,r.contentDisposition,r.contentEncoding,r.contentLanguage,r.contentType,e.userDelegationKey)}function uT(r,e){if(r=Jd(r),!r.permissions||!r.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let t="c",a=r.snapshotTime;r.blobName&&(t="b",r.snapshotTime?t="bs":r.versionId&&(t="bv",a=r.versionId));let n;r.permissions&&(r.blobName?n=bi.parse(r.permissions.toString()).toString():n=Si.parse(r.permissions.toString()).toString());let i=[n||"",r.startsOn?sr(r.startsOn,!1):"",r.expiresOn?sr(r.expiresOn,!1):"",Zd(e.accountName,r.containerName,r.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?sr(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?sr(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,r.preauthorizedAgentObjectId,void 0,r.correlationId,r.ipRange?Fi(r.ipRange):"",r.protocol?r.protocol:"",r.version,t,a,r.cacheControl,r.contentDisposition,r.contentEncoding,r.contentLanguage,r.contentType].join(`
20
- `),s=e.computeHMACSHA256(i);return new Ui(r.version,s,n,void 0,void 0,r.protocol,r.startsOn,r.expiresOn,r.ipRange,r.identifier,t,r.cacheControl,r.contentDisposition,r.contentEncoding,r.contentLanguage,r.contentType,e.userDelegationKey,r.preauthorizedAgentObjectId,r.correlationId)}function Zd(r,e,t){let a=[`/blob/${r}/${e}`];return t&&a.push(`/${t}`),a.join("")}function Jd(r){let e=r.version?r.version:_c;if(r.snapshotTime&&e<"2018-11-09")throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.");if(r.blobName===void 0&&r.snapshotTime)throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.");if(r.versionId&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.");if(r.blobName===void 0&&r.versionId)throw RangeError("Must provide 'blobName' when providing 'versionId'.");if(r.permissions&&r.permissions.setImmutabilityPolicy&&e<"2020-08-04")throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.");if(r.permissions&&r.permissions.deleteVersion&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.");if(r.permissions&&r.permissions.tag&&e<"2019-12-12")throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.");if(e<"2020-02-10"&&r.permissions&&(r.permissions.move||r.permissions.execute))throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.");if(e<"2020-02-10"&&(r.preauthorizedAgentObjectId||r.correlationId))throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.");return r.version=e,r}var tl=class{constructor(e,t){let a=new ki(e.url,e.pipeline.toServiceClientOptions());this._url=e.url,e.name===void 0?(this._isContainer=!0,this._containerOrBlobOperation=new qn(a)):(this._isContainer=!1,this._containerOrBlobOperation=new eo(a)),t||(t=Ka()),this._leaseId=t}get leaseId(){return this._leaseId}get url(){return this._url}async acquireLease(e,t={}){var a,n,i,s,o,l;let{span:c,updatedOptions:p}=Ge("BlobLeaseClient-acquireLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((n=t.conditions)===null||n===void 0?void 0:n.ifMatch)!==Hn||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==Hn||((o=t.conditions)===null||o===void 0?void 0:o.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");try{return await this._containerOrBlobOperation.acquireLease(Object.assign({abortSignal:t.abortSignal,duration:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(l=t.conditions)===null||l===void 0?void 0:l.tagConditions}),proposedLeaseId:this._leaseId},st(p)))}catch(M){throw c.setStatus({code:qe.ERROR,message:M.message}),M}finally{c.end()}}async changeLease(e,t={}){var a,n,i,s,o,l;let{span:c,updatedOptions:p}=Ge("BlobLeaseClient-changeLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((n=t.conditions)===null||n===void 0?void 0:n.ifMatch)!==Hn||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==Hn||((o=t.conditions)===null||o===void 0?void 0:o.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");try{let M=await this._containerOrBlobOperation.changeLease(this._leaseId,e,Object.assign({abortSignal:t.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(l=t.conditions)===null||l===void 0?void 0:l.tagConditions})},st(p)));return this._leaseId=e,M}catch(M){throw c.setStatus({code:qe.ERROR,message:M.message}),M}finally{c.end()}}async releaseLease(e={}){var t,a,n,i,s,o;let{span:l,updatedOptions:c}=Ge("BlobLeaseClient-releaseLease",e);if(this._isContainer&&(((t=e.conditions)===null||t===void 0?void 0:t.ifMatch)&&((a=e.conditions)===null||a===void 0?void 0:a.ifMatch)!==Hn||((n=e.conditions)===null||n===void 0?void 0:n.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==Hn||((s=e.conditions)===null||s===void 0?void 0:s.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");try{return await this._containerOrBlobOperation.releaseLease(this._leaseId,Object.assign({abortSignal:e.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:(o=e.conditions)===null||o===void 0?void 0:o.tagConditions})},st(c)))}catch(p){throw l.setStatus({code:qe.ERROR,message:p.message}),p}finally{l.end()}}async renewLease(e={}){var t,a,n,i,s,o;let{span:l,updatedOptions:c}=Ge("BlobLeaseClient-renewLease",e);if(this._isContainer&&(((t=e.conditions)===null||t===void 0?void 0:t.ifMatch)&&((a=e.conditions)===null||a===void 0?void 0:a.ifMatch)!==Hn||((n=e.conditions)===null||n===void 0?void 0:n.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==Hn||((s=e.conditions)===null||s===void 0?void 0:s.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");try{return await this._containerOrBlobOperation.renewLease(this._leaseId,Object.assign({abortSignal:e.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:(o=e.conditions)===null||o===void 0?void 0:o.tagConditions})},st(c)))}catch(p){throw l.setStatus({code:qe.ERROR,message:p.message}),p}finally{l.end()}}async breakLease(e,t={}){var a,n,i,s,o,l;let{span:c,updatedOptions:p}=Ge("BlobLeaseClient-breakLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((n=t.conditions)===null||n===void 0?void 0:n.ifMatch)!==Hn||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==Hn||((o=t.conditions)===null||o===void 0?void 0:o.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");try{let M=Object.assign({abortSignal:t.abortSignal,breakPeriod:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(l=t.conditions)===null||l===void 0?void 0:l.tagConditions})},st(p));return await this._containerOrBlobOperation.breakLease(M)}catch(M){throw c.setStatus({code:qe.ERROR,message:M.message}),M}finally{c.end()}}};var eu=class{constructor(e,t={}){this.originalResponse=e}get acceptRanges(){return this.originalResponse.acceptRanges}get cacheControl(){return this.originalResponse.cacheControl}get contentDisposition(){return this.originalResponse.contentDisposition}get contentEncoding(){return this.originalResponse.contentEncoding}get contentLanguage(){return this.originalResponse.contentLanguage}get blobSequenceNumber(){return this.originalResponse.blobSequenceNumber}get blobType(){return this.originalResponse.blobType}get contentLength(){return this.originalResponse.contentLength}get contentMD5(){return this.originalResponse.contentMD5}get contentRange(){return this.originalResponse.contentRange}get contentType(){return this.originalResponse.contentType}get copyCompletedOn(){}get copyId(){return this.originalResponse.copyId}get copyProgress(){return this.originalResponse.copyProgress}get copySource(){return this.originalResponse.copySource}get copyStatus(){return this.originalResponse.copyStatus}get copyStatusDescription(){return this.originalResponse.copyStatusDescription}get leaseDuration(){return this.originalResponse.leaseDuration}get leaseState(){return this.originalResponse.leaseState}get leaseStatus(){return this.originalResponse.leaseStatus}get date(){return this.originalResponse.date}get blobCommittedBlockCount(){return this.originalResponse.blobCommittedBlockCount}get etag(){return this.originalResponse.etag}get errorCode(){return this.originalResponse.errorCode}get isServerEncrypted(){return this.originalResponse.isServerEncrypted}get blobContentMD5(){return this.originalResponse.blobContentMD5}get lastModified(){return this.originalResponse.lastModified}get metadata(){return this.originalResponse.metadata}get requestId(){return this.originalResponse.requestId}get clientRequestId(){return this.originalResponse.clientRequestId}get version(){return this.originalResponse.version}get encryptionKeySha256(){return this.originalResponse.encryptionKeySha256}get contentCrc64(){return this.originalResponse.contentCrc64}get blobBody(){throw Error("Quick query in browser is not supported yet.")}get readableStreamBody(){}get _response(){return this.originalResponse._response}};var U2;(function(r){r.Hot="Hot",r.Cool="Cool",r.Archive="Archive"})(U2||(U2={}));var j2;(function(r){r.P4="P4",r.P6="P6",r.P10="P10",r.P15="P15",r.P20="P20",r.P30="P30",r.P40="P40",r.P50="P50",r.P60="P60",r.P70="P70",r.P80="P80"})(j2||(j2={}));function ro(r){if(r!==void 0)return r}function $r(r,e){if(r&&!e)throw new RangeError("Customer-provided encryption key must be used over HTTPS.");r&&!r.encryptionAlgorithm&&(r.encryptionAlgorithm=w2)}function tu(r){let e=(r._response.parsedBody.pageRange||[]).map(a=>({offset:a.start,count:a.end-a.start})),t=(r._response.parsedBody.clearRange||[]).map(a=>({offset:a.start,count:a.end-a.start}));return Object.assign(Object.assign({},r),{pageRange:e,clearRange:t,_response:Object.assign(Object.assign({},r._response),{parsedBody:{pageRange:e,clearRange:t}})})}var Nc=class extends Error{constructor(e){super(e),this.name="PollerStoppedError",Object.setPrototypeOf(this,Nc.prototype)}},Pc=class extends Error{constructor(e){super(e),this.name="PollerCancelledError",Object.setPrototypeOf(this,Pc.prototype)}},ru=class{constructor(e){this.stopped=!0,this.pollProgressCallbacks=[],this.operation=e,this.promise=new Promise((t,a)=>{this.resolve=t,this.reject=a}),this.promise.catch(()=>{})}async startPolling(){for(this.stopped&&(this.stopped=!1);!this.isStopped()&&!this.isDone();)await this.poll(),await this.delay()}async pollOnce(e={}){try{this.isDone()||(this.operation=await this.operation.update({abortSignal:e.abortSignal,fireProgress:this.fireProgress.bind(this)}),this.isDone()&&this.resolve&&this.resolve(this.operation.state.result))}catch(t){throw this.operation.state.error=t,this.reject&&this.reject(t),t}}fireProgress(e){for(let t of this.pollProgressCallbacks)t(e)}async cancelOnce(e={}){this.operation=await this.operation.cancel(e),this.reject&&this.reject(new Pc("Poller cancelled"))}poll(e={}){if(!this.pollOncePromise){this.pollOncePromise=this.pollOnce(e);let t=()=>{this.pollOncePromise=void 0};this.pollOncePromise.then(t,t).catch(this.reject)}return this.pollOncePromise}async pollUntilDone(){return this.stopped&&this.startPolling().catch(this.reject),this.promise}onProgress(e){return this.pollProgressCallbacks.push(e),()=>{this.pollProgressCallbacks=this.pollProgressCallbacks.filter(t=>t!==e)}}isDone(){let e=this.operation.state;return Boolean(e.isCompleted||e.isCancelled||e.error)}stopPolling(){this.stopped||(this.stopped=!0,this.reject&&this.reject(new Nc("This poller is already stopped")))}isStopped(){return this.stopped}cancelOperation(e={}){if(this.stopped||(this.stopped=!0),!this.cancelPromise)this.cancelPromise=this.cancelOnce(e);else if(e.abortSignal)throw new Error("A cancel request is currently pending");return this.cancelPromise}getOperationState(){return this.operation.state}getResult(){return this.operation.state.result}toString(){return this.operation.toString()}};var au=class extends ru{constructor(e){let{blobClient:t,copySource:a,intervalInMs:n=15e3,onProgress:i,resumeFrom:s,startCopyFromURLOptions:o}=e,l;s&&(l=JSON.parse(s).state);let c=Cc(Object.assign(Object.assign({},l),{blobClient:t,copySource:a,startCopyFromURLOptions:o}));super(c),typeof i=="function"&&this.onProgress(i),this.intervalInMs=n}delay(){return Xa(this.intervalInMs)}},pT=async function(e={}){let t=this.state,{copyId:a}=t;return t.isCompleted?Cc(t):a?(await t.blobClient.abortCopyFromURL(a,{abortSignal:e.abortSignal}),t.isCancelled=!0,Cc(t)):(t.isCancelled=!0,Cc(t))},fT=async function(e={}){let t=this.state,{blobClient:a,copySource:n,startCopyFromURLOptions:i}=t;if(t.isStarted){if(!t.isCompleted)try{let s=await t.blobClient.getProperties({abortSignal:e.abortSignal}),{copyStatus:o,copyProgress:l}=s,c=t.copyProgress;l&&(t.copyProgress=l),o==="pending"&&l!==c&&typeof e.fireProgress=="function"?e.fireProgress(t):o==="success"?(t.result=s,t.isCompleted=!0):o==="failed"&&(t.error=new Error(`Blob copy failed with reason: "${s.copyStatusDescription||"unknown"}"`),t.isCompleted=!0)}catch(s){t.error=s,t.isCompleted=!0}}else{t.isStarted=!0;let s=await a.startCopyFromURL(n,i);t.copyId=s.copyId,s.copyStatus==="success"&&(t.result=s,t.isCompleted=!0)}return Cc(t)},hT=function(){return JSON.stringify({state:this.state},(e,t)=>{if(e!=="blobClient")return t})};function Cc(r){return{state:Object.assign({},r),cancel:pT,toString:hT,update:fT}}function gn(r){if(r.offset<0)throw new RangeError("Range.offset cannot be smaller than 0.");if(r.count&&r.count<=0)throw new RangeError("Range.count must be larger than 0. Leave it undefined if you want a range from offset to the end.");return r.count?`bytes=${r.offset}-${r.offset+r.count-1}`:`bytes=${r.offset}-`}var tS=ns(eS()),Rc;(function(r){r[r.Good=0]="Good",r[r.Error=1]="Error"})(Rc||(Rc={}));var Ec=class{constructor(e=5){if(this.actives=0,this.completed=0,this.offset=0,this.operations=[],this.state=Rc.Good,e<1)throw new RangeError("concurrency must be larger than 0");this.concurrency=e,this.emitter=new tS.EventEmitter}addOperation(e){this.operations.push(async()=>{try{this.actives++,await e(),this.actives--,this.completed++,this.parallelExecute()}catch(t){this.emitter.emit("error",t)}})}async do(){return this.operations.length===0?Promise.resolve():(this.parallelExecute(),new Promise((e,t)=>{this.emitter.on("finish",e),this.emitter.on("error",a=>{this.state=Rc.Error,t(a)})}))}nextOperation(){return this.offset<this.operations.length?this.operations[this.offset++]:null}parallelExecute(){if(this.state!==Rc.Error){if(this.completed>=this.operations.length){this.emitter.emit("finish");return}for(;this.actives<this.concurrency;){let e=this.nextOperation();if(e)e();else return}}}};var su=class{};async function rS(r){let e=new FileReader;return new Promise((t,a)=>{e.onloadend=n=>{t(n.target.result)},e.onerror=a,e.readAsText(r)})}var aS=function(){},nS=function(){};var Na=class extends xs{constructor(e,t,a,n){n=n||{};let i,s;if(kn(t))s=e,i=t;else if(Lt&&t instanceof or||t instanceof Vt||Ar(t))s=e,n=a,i=Yt(t,n);else if(!t&&typeof t!="string")s=e,i=Yt(new Vt,n);else if(t&&typeof t=="string"&&a&&typeof a=="string"){let o=t,l=a,c=Di(e);if(c.kind==="AccountConnString")if(Lt){let p=new or(c.accountName,c.accountKey);s=ur(ur(c.url,encodeURIComponent(o)),encodeURIComponent(l)),n.proxyOptions=(c.proxyUri,void 0),i=Yt(p,n)}else throw new Error("Account connection string is only supported in Node.js environment");else if(c.kind==="SASConnString")s=ur(ur(c.url,encodeURIComponent(o)),encodeURIComponent(l))+"?"+c.accountSas,i=Yt(new Vt,n);else throw new Error("Connection string must be either an Account connection string or a SAS connection string")}else throw new Error("Expecting non-empty strings for containerName and blobName parameters");super(s,i),{blobName:this._name,containerName:this._containerName}=this.getBlobAndContainerNamesFromUrl(),this.blobContext=new eo(this.storageClientContext),this._snapshot=j1(this.url,Qa.Parameters.SNAPSHOT),this._versionId=j1(this.url,Qa.Parameters.VERSIONID)}get name(){return this._name}get containerName(){return this._containerName}withSnapshot(e){return new Na(_i(this.url,Qa.Parameters.SNAPSHOT,e.length===0?void 0:e),this.pipeline)}withVersion(e){return new Na(_i(this.url,Qa.Parameters.VERSIONID,e.length===0?void 0:e),this.pipeline)}getAppendBlobClient(){return new ao(this.url,this.pipeline)}getBlockBlobClient(){return new no(this.url,this.pipeline)}getPageBlobClient(){return new io(this.url,this.pipeline)}async download(e=0,t,a={}){var n;a.conditions=a.conditions||{},a.conditions=a.conditions||{},$r(a.customerProvidedKey,this.isHttps);let{span:i,updatedOptions:s}=Ge("BlobClient-download",a);try{let o=await this.blobContext.download(Object.assign({abortSignal:a.abortSignal,leaseAccessConditions:a.conditions,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(n=a.conditions)===null||n===void 0?void 0:n.tagConditions}),requestOptions:{onDownloadProgress:Lt?void 0:a.onProgress},range:e===0&&!t?void 0:gn({offset:e,count:t}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey},st(s))),l=Object.assign(Object.assign({},o),{_response:o._response,objectReplicationDestinationPolicyId:o.objectReplicationPolicyId,objectReplicationSourceProperties:Zo(o.objectReplicationRules)});if(!Lt)return l;if((a.maxRetryRequests===void 0||a.maxRetryRequests<0)&&(a.maxRetryRequests=5),o.contentLength===void 0)throw new RangeError("File download response doesn't contain valid content length header");if(!o.etag)throw new RangeError("File download response doesn't contain valid etag header");return new 1(l,async c=>{var p;let M={leaseAccessConditions:a.conditions,modifiedAccessConditions:{ifMatch:a.conditions.ifMatch||o.etag,ifModifiedSince:a.conditions.ifModifiedSince,ifNoneMatch:a.conditions.ifNoneMatch,ifUnmodifiedSince:a.conditions.ifUnmodifiedSince,ifTags:(p=a.conditions)===null||p===void 0?void 0:p.tagConditions},range:gn({count:e+o.contentLength-c,offset:c}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey};return(await this.blobContext.download(Object.assign({abortSignal:a.abortSignal},M))).readableStreamBody},e,o.contentLength,{maxRetryRequests:a.maxRetryRequests,onProgress:a.onProgress})}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async exists(e={}){let{span:t,updatedOptions:a}=Ge("BlobClient-exists",e);try{return $r(e.customerProvidedKey,this.isHttps),await this.getProperties({abortSignal:e.abortSignal,customerProvidedKey:e.customerProvidedKey,conditions:e.conditions,tracingOptions:a.tracingOptions}),!0}catch(n){if(n.statusCode===404)return t.setStatus({code:qe.ERROR,message:"Expected exception when checking blob existence"}),!1;throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async getProperties(e={}){var t;let{span:a,updatedOptions:n}=Ge("BlobClient-getProperties",e);try{e.conditions=e.conditions||{},$r(e.customerProvidedKey,this.isHttps);let i=await this.blobContext.getProperties(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:(t=e.conditions)===null||t===void 0?void 0:t.tagConditions}),cpkInfo:e.customerProvidedKey},st(n)));return Object.assign(Object.assign({},i),{_response:i._response,objectReplicationDestinationPolicyId:i.objectReplicationPolicyId,objectReplicationSourceProperties:Zo(i.objectReplicationRules)})}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async delete(e={}){var t;let{span:a,updatedOptions:n}=Ge("BlobClient-delete",e);e.conditions=e.conditions||{};try{return await this.blobContext.delete(Object.assign({abortSignal:e.abortSignal,deleteSnapshots:e.deleteSnapshots,leaseAccessConditions:e.conditions,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:(t=e.conditions)===null||t===void 0?void 0:t.tagConditions})},st(n)))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async deleteIfExists(e={}){var t,a;let{span:n,updatedOptions:i}=Ge("BlobClient-deleteIfExists",e);try{let s=await this.delete(i);return Object.assign(Object.assign({succeeded:!0},s),{_response:s._response})}catch(s){if(((t=s.details)===null||t===void 0?void 0:t.errorCode)==="BlobNotFound")return n.setStatus({code:qe.ERROR,message:"Expected exception when deleting a blob or snapshot only if it exists."}),Object.assign(Object.assign({succeeded:!1},(a=s.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:s.response});throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async undelete(e={}){let{span:t,updatedOptions:a}=Ge("BlobClient-undelete",e);try{return await this.blobContext.undelete(Object.assign({abortSignal:e.abortSignal},st(a)))}catch(n){throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async setHTTPHeaders(e,t={}){var a;let{span:n,updatedOptions:i}=Ge("BlobClient-setHTTPHeaders",t);t.conditions=t.conditions||{};try{return $r(t.customerProvidedKey,this.isHttps),await this.blobContext.setHttpHeaders(Object.assign({abortSignal:t.abortSignal,blobHttpHeaders:e,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions})},st(i)))}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async setMetadata(e,t={}){var a;let{span:n,updatedOptions:i}=Ge("BlobClient-setMetadata",t);t.conditions=t.conditions||{};try{return $r(t.customerProvidedKey,this.isHttps),await this.blobContext.setMetadata(Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),cpkInfo:t.customerProvidedKey,encryptionScope:t.encryptionScope},st(i)))}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async setTags(e,t={}){var a;let{span:n,updatedOptions:i}=Ge("BlobClient-setTags",t);try{return await this.blobContext.setTags(Object.assign(Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions})},st(i)),{tags:H2(e)}))}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async getTags(e={}){var t;let{span:a,updatedOptions:n}=Ge("BlobClient-getTags",e);try{let i=await this.blobContext.getTags(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:(t=e.conditions)===null||t===void 0?void 0:t.tagConditions})},st(n)));return Object.assign(Object.assign({},i),{_response:i._response,tags:to({blobTagSet:i.blobTagSet})||{}})}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}getBlobLeaseClient(e){return new tl(this,e)}async createSnapshot(e={}){var t;let{span:a,updatedOptions:n}=Ge("BlobClient-createSnapshot",e);e.conditions=e.conditions||{};try{return $r(e.customerProvidedKey,this.isHttps),await this.blobContext.createSnapshot(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,metadata:e.metadata,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:(t=e.conditions)===null||t===void 0?void 0:t.tagConditions}),cpkInfo:e.customerProvidedKey,encryptionScope:e.encryptionScope},st(n)))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async beginCopyFromURL(e,t={}){let a={abortCopyFromURL:(...i)=>this.abortCopyFromURL(...i),getProperties:(...i)=>this.getProperties(...i),startCopyFromURL:(...i)=>this.startCopyFromURL(...i)},n=new au({blobClient:a,copySource:e,intervalInMs:t.intervalInMs,onProgress:t.onProgress,resumeFrom:t.resumeFrom,startCopyFromURLOptions:t});return await n.poll(),n}async abortCopyFromURL(e,t={}){let{span:a,updatedOptions:n}=Ge("BlobClient-abortCopyFromURL",t);try{return await this.blobContext.abortCopyFromURL(e,Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions},st(n)))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async syncCopyFromURL(e,t={}){var a,n,i;let{span:s,updatedOptions:o}=Ge("BlobClient-syncCopyFromURL",t);t.conditions=t.conditions||{},t.sourceConditions=t.sourceConditions||{};try{return await this.blobContext.copyFromURL(e,Object.assign({abortSignal:t.abortSignal,metadata:t.metadata,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:t.sourceConditions.ifMatch,sourceIfModifiedSince:t.sourceConditions.ifModifiedSince,sourceIfNoneMatch:t.sourceConditions.ifNoneMatch,sourceIfUnmodifiedSince:t.sourceConditions.ifUnmodifiedSince},sourceContentMD5:t.sourceContentMD5,copySourceAuthorization:Jo(t.sourceAuthorization),blobTagsString:hs(t.tags),immutabilityPolicyExpiry:(n=t.immutabilityPolicy)===null||n===void 0?void 0:n.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold},st(o)))}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}async setAccessTier(e,t={}){var a;let{span:n,updatedOptions:i}=Ge("BlobClient-setAccessTier",t);try{return await this.blobContext.setTier(ro(e),Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),rehydratePriority:t.rehydratePriority},st(i)))}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async downloadToBuffer(e,t,a,n={}){let i,s=0,o=0,l=n;e instanceof Buffer?(i=e,s=t||0,o=typeof a=="number"?a:0):(s=typeof e=="number"?e:0,o=typeof t=="number"?t:0,l=a||{});let{span:c,updatedOptions:p}=Ge("BlobClient-downloadToBuffer",l);try{if(l.blockSize||(l.blockSize=0),l.blockSize<0)throw new RangeError("blockSize option must be >= 0");if(l.blockSize===0&&(l.blockSize=4194304),s<0)throw new RangeError("offset option must be >= 0");if(o&&o<=0)throw new RangeError("count option must be greater than 0");if(l.conditions||(l.conditions={}),!o){let O=await this.getProperties(Object.assign(Object.assign({},l),{tracingOptions:Object.assign(Object.assign({},l.tracingOptions),st(p))}));if(o=O.contentLength-s,o<0)throw new RangeError(`offset ${s} shouldn't be larger than blob size ${O.contentLength}`)}if(!i)try{i=Buffer.alloc(o)}catch(O){throw new Error(`Unable to allocate the buffer of size: ${o}(in bytes). Please try passing your own buffer to the "downloadToBuffer" method or try using other methods like "download" or "downloadToFile". ${O.message}`)}if(i.length<o)throw new RangeError(`The buffer's size should be equal to or larger than the request count of bytes: ${o}`);let M=0,S=new Ec(l.concurrency);for(let O=s;O<s+o;O=O+l.blockSize)S.addOperation(async()=>{let E=s+o;O+l.blockSize<E&&(E=O+l.blockSize);let C=(await this.download(O,E-O,{abortSignal:l.abortSignal,conditions:l.conditions,maxRetryRequests:l.maxRetryRequestsPerBlock,customerProvidedKey:l.customerProvidedKey,tracingOptions:Object.assign(Object.assign({},l.tracingOptions),st(p))})).readableStreamBody;await(O-s,E-s,void 0),M+=E-O,l.onProgress&&l.onProgress({loadedBytes:M})});return await S.do(),i}catch(M){throw c.setStatus({code:qe.ERROR,message:M.message}),M}finally{c.end()}}async downloadToFile(e,t=0,a,n={}){let{span:i,updatedOptions:s}=Ge("BlobClient-downloadToFile",n);try{let o=await this.download(t,a,Object.assign(Object.assign({},n),{tracingOptions:Object.assign(Object.assign({},n.tracingOptions),st(s))}));return o.readableStreamBody&&await(o.readableStreamBody,void 0),o.blobDownloadStream=void 0,o}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}getBlobAndContainerNamesFromUrl(){let e,t;try{let a=ar.parse(this.url);if(a.getHost().split(".")[1]==="blob"){let n=a.getPath().match("/([^/]*)(/(.*))?");e=n[1],t=n[3]}else if(bc(a)){let n=a.getPath().match("/([^/]*)/([^/]*)(/(.*))?");e=n[2],t=n[4]}else{let n=a.getPath().match("/([^/]*)(/(.*))?");e=n[1],t=n[3]}if(e=decodeURIComponent(e),t=decodeURIComponent(t),t=t.replace(/\\/g,"/"),!e)throw new Error("Provided containerName is invalid.");return{blobName:t,containerName:e}}catch{throw new Error("Unable to extract blobName and containerName with provided information.")}}async startCopyFromURL(e,t={}){var a,n,i;let{span:s,updatedOptions:o}=Ge("BlobClient-startCopyFromURL",t);t.conditions=t.conditions||{},t.sourceConditions=t.sourceConditions||{};try{return await this.blobContext.startCopyFromURL(e,Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:t.metadata,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:t.sourceConditions.ifMatch,sourceIfModifiedSince:t.sourceConditions.ifModifiedSince,sourceIfNoneMatch:t.sourceConditions.ifNoneMatch,sourceIfUnmodifiedSince:t.sourceConditions.ifUnmodifiedSince,sourceIfTags:t.sourceConditions.tagConditions},immutabilityPolicyExpiry:(n=t.immutabilityPolicy)===null||n===void 0?void 0:n.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,rehydratePriority:t.rehydratePriority,tier:ro(t.tier),blobTagsString:hs(t.tags),sealBlob:t.sealBlob},st(o)))}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}generateSasUrl(e){return new Promise(t=>{if(!(this.credential instanceof or))throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");let a=Qd(Object.assign({containerName:this._containerName,blobName:this._name,snapshotTime:this._snapshot,versionId:this._versionId},e),this.credential).toString();t(Qo(this.url,a))})}async deleteImmutabilityPolicy(e){let{span:t,updatedOptions:a}=Ge("BlobClient-deleteImmutabilityPolicy",e);try{return await this.blobContext.deleteImmutabilityPolicy(Object.assign({abortSignal:e?.abortSignal},st(a)))}catch(n){throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async setImmutabilityPolicy(e,t){let{span:a,updatedOptions:n}=Ge("BlobClient-setImmutabilityPolicy",t);try{return await this.blobContext.setImmutabilityPolicy(Object.assign({abortSignal:t?.abortSignal,immutabilityPolicyExpiry:e.expiriesOn,immutabilityPolicyMode:e.policyMode,modifiedAccessConditions:t?.modifiedAccessCondition},st(n)))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async setLegalHold(e,t){let{span:a,updatedOptions:n}=Ge("BlobClient-setLegalHold",t);try{return await this.blobContext.setLegalHold(e,Object.assign({abortSignal:t?.abortSignal},st(n)))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}},ao=class extends Na{constructor(e,t,a,n){let i,s;if(n=n||{},kn(t))s=e,i=t;else if(Lt&&t instanceof or||t instanceof Vt||Ar(t))s=e,n=a,i=Yt(t,n);else if(!t&&typeof t!="string")s=e,i=Yt(new Vt,n);else if(t&&typeof t=="string"&&a&&typeof a=="string"){let o=t,l=a,c=Di(e);if(c.kind==="AccountConnString")if(Lt){let p=new or(c.accountName,c.accountKey);s=ur(ur(c.url,encodeURIComponent(o)),encodeURIComponent(l)),n.proxyOptions=(c.proxyUri,void 0),i=Yt(p,n)}else throw new Error("Account connection string is only supported in Node.js environment");else if(c.kind==="SASConnString")s=ur(ur(c.url,encodeURIComponent(o)),encodeURIComponent(l))+"?"+c.accountSas,i=Yt(new Vt,n);else throw new Error("Connection string must be either an Account connection string or a SAS connection string")}else throw new Error("Expecting non-empty strings for containerName and blobName parameters");super(s,i),this.appendBlobContext=new Ad(this.storageClientContext)}withSnapshot(e){return new ao(_i(this.url,Qa.Parameters.SNAPSHOT,e.length===0?void 0:e),this.pipeline)}async create(e={}){var t,a,n;let{span:i,updatedOptions:s}=Ge("AppendBlobClient-create",e);e.conditions=e.conditions||{};try{return $r(e.customerProvidedKey,this.isHttps),await this.appendBlobContext.create(0,Object.assign({abortSignal:e.abortSignal,blobHttpHeaders:e.blobHTTPHeaders,leaseAccessConditions:e.conditions,metadata:e.metadata,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:(t=e.conditions)===null||t===void 0?void 0:t.tagConditions}),cpkInfo:e.customerProvidedKey,encryptionScope:e.encryptionScope,immutabilityPolicyExpiry:(a=e.immutabilityPolicy)===null||a===void 0?void 0:a.expiriesOn,immutabilityPolicyMode:(n=e.immutabilityPolicy)===null||n===void 0?void 0:n.policyMode,legalHold:e.legalHold,blobTagsString:hs(e.tags)},st(s)))}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async createIfNotExists(e={}){var t,a;let{span:n,updatedOptions:i}=Ge("AppendBlobClient-createIfNotExists",e),s={ifNoneMatch:F1};try{let o=await this.create(Object.assign(Object.assign({},i),{conditions:s}));return Object.assign(Object.assign({succeeded:!0},o),{_response:o._response})}catch(o){if(((t=o.details)===null||t===void 0?void 0:t.errorCode)==="BlobAlreadyExists")return n.setStatus({code:qe.ERROR,message:"Expected exception when creating a blob only if it does not already exist."}),Object.assign(Object.assign({succeeded:!1},(a=o.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:o.response});throw n.setStatus({code:qe.ERROR,message:o.message}),o}finally{n.end()}}async seal(e={}){var t;let{span:a,updatedOptions:n}=Ge("AppendBlobClient-seal",e);e.conditions=e.conditions||{};try{return await this.appendBlobContext.seal(Object.assign({abortSignal:e.abortSignal,appendPositionAccessConditions:e.conditions,leaseAccessConditions:e.conditions,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:(t=e.conditions)===null||t===void 0?void 0:t.tagConditions})},st(n)))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async appendBlock(e,t,a={}){var n;let{span:i,updatedOptions:s}=Ge("AppendBlobClient-appendBlock",a);a.conditions=a.conditions||{};try{return $r(a.customerProvidedKey,this.isHttps),await this.appendBlobContext.appendBlock(t,e,Object.assign({abortSignal:a.abortSignal,appendPositionAccessConditions:a.conditions,leaseAccessConditions:a.conditions,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(n=a.conditions)===null||n===void 0?void 0:n.tagConditions}),requestOptions:{onUploadProgress:a.onProgress},transactionalContentMD5:a.transactionalContentMD5,transactionalContentCrc64:a.transactionalContentCrc64,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},st(s)))}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async appendBlockFromURL(e,t,a,n={}){var i;let{span:s,updatedOptions:o}=Ge("AppendBlobClient-appendBlockFromURL",n);n.conditions=n.conditions||{},n.sourceConditions=n.sourceConditions||{};try{return $r(n.customerProvidedKey,this.isHttps),await this.appendBlobContext.appendBlockFromUrl(e,0,Object.assign({abortSignal:n.abortSignal,sourceRange:gn({offset:t,count:a}),sourceContentMD5:n.sourceContentMD5,sourceContentCrc64:n.sourceContentCrc64,leaseAccessConditions:n.conditions,appendPositionAccessConditions:n.conditions,modifiedAccessConditions:Object.assign(Object.assign({},n.conditions),{ifTags:(i=n.conditions)===null||i===void 0?void 0:i.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:n.sourceConditions.ifMatch,sourceIfModifiedSince:n.sourceConditions.ifModifiedSince,sourceIfNoneMatch:n.sourceConditions.ifNoneMatch,sourceIfUnmodifiedSince:n.sourceConditions.ifUnmodifiedSince},copySourceAuthorization:Jo(n.sourceAuthorization),cpkInfo:n.customerProvidedKey,encryptionScope:n.encryptionScope},st(o)))}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}},no=class extends Na{constructor(e,t,a,n){let i,s;if(n=n||{},kn(t))s=e,i=t;else if(Lt&&t instanceof or||t instanceof Vt||Ar(t))s=e,n=a,i=Yt(t,n);else if(!t&&typeof t!="string")s=e,i=Yt(new Vt,n);else if(t&&typeof t=="string"&&a&&typeof a=="string"){let o=t,l=a,c=Di(e);if(c.kind==="AccountConnString")if(Lt){let p=new or(c.accountName,c.accountKey);s=ur(ur(c.url,encodeURIComponent(o)),encodeURIComponent(l)),n.proxyOptions=(c.proxyUri,void 0),i=Yt(p,n)}else throw new Error("Account connection string is only supported in Node.js environment");else if(c.kind==="SASConnString")s=ur(ur(c.url,encodeURIComponent(o)),encodeURIComponent(l))+"?"+c.accountSas,i=Yt(new Vt,n);else throw new Error("Connection string must be either an Account connection string or a SAS connection string")}else throw new Error("Expecting non-empty strings for containerName and blobName parameters");super(s,i),this.blockBlobContext=new Bd(this.storageClientContext),this._blobContext=new eo(this.storageClientContext)}withSnapshot(e){return new no(_i(this.url,Qa.Parameters.SNAPSHOT,e.length===0?void 0:e),this.pipeline)}async query(e,t={}){var a;$r(t.customerProvidedKey,this.isHttps);let{span:n,updatedOptions:i}=Ge("BlockBlobClient-query",t);try{if(!Lt)throw new Error("This operation currently is only supported in Node.js.");let s=await this._blobContext.query(Object.assign({abortSignal:t.abortSignal,queryRequest:{queryType:"SQL",expression:e,inputSerialization:K1(t.inputTextConfiguration),outputSerialization:K1(t.outputTextConfiguration)},leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions})},st(i)));return new eu(s,{abortSignal:t.abortSignal,onProgress:t.onProgress,onError:t.onError})}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async upload(e,t,a={}){var n,i,s;a.conditions=a.conditions||{};let{span:o,updatedOptions:l}=Ge("BlockBlobClient-upload",a);try{return $r(a.customerProvidedKey,this.isHttps),await this.blockBlobContext.upload(t,e,Object.assign({abortSignal:a.abortSignal,blobHttpHeaders:a.blobHTTPHeaders,leaseAccessConditions:a.conditions,metadata:a.metadata,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(n=a.conditions)===null||n===void 0?void 0:n.tagConditions}),requestOptions:{onUploadProgress:a.onProgress},cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope,immutabilityPolicyExpiry:(i=a.immutabilityPolicy)===null||i===void 0?void 0:i.expiriesOn,immutabilityPolicyMode:(s=a.immutabilityPolicy)===null||s===void 0?void 0:s.policyMode,legalHold:a.legalHold,tier:ro(a.tier),blobTagsString:hs(a.tags)},st(l)))}catch(c){throw o.setStatus({code:qe.ERROR,message:c.message}),c}finally{o.end()}}async syncUploadFromURL(e,t={}){var a,n,i,s,o;t.conditions=t.conditions||{};let{span:l,updatedOptions:c}=Ge("BlockBlobClient-syncUploadFromURL",t);try{return $r(t.customerProvidedKey,this.isHttps),await this.blockBlobContext.putBlobFromUrl(0,e,Object.assign(Object.assign(Object.assign({},t),{blobHttpHeaders:t.blobHTTPHeaders,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:t.conditions.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:(a=t.sourceConditions)===null||a===void 0?void 0:a.ifMatch,sourceIfModifiedSince:(n=t.sourceConditions)===null||n===void 0?void 0:n.ifModifiedSince,sourceIfNoneMatch:(i=t.sourceConditions)===null||i===void 0?void 0:i.ifNoneMatch,sourceIfUnmodifiedSince:(s=t.sourceConditions)===null||s===void 0?void 0:s.ifUnmodifiedSince,sourceIfTags:(o=t.sourceConditions)===null||o===void 0?void 0:o.tagConditions},cpkInfo:t.customerProvidedKey,copySourceAuthorization:Jo(t.sourceAuthorization),tier:ro(t.tier),blobTagsString:hs(t.tags)}),st(c)))}catch(p){throw l.setStatus({code:qe.ERROR,message:p.message}),p}finally{l.end()}}async stageBlock(e,t,a,n={}){let{span:i,updatedOptions:s}=Ge("BlockBlobClient-stageBlock",n);try{return $r(n.customerProvidedKey,this.isHttps),await this.blockBlobContext.stageBlock(e,a,t,Object.assign({abortSignal:n.abortSignal,leaseAccessConditions:n.conditions,requestOptions:{onUploadProgress:n.onProgress},transactionalContentMD5:n.transactionalContentMD5,transactionalContentCrc64:n.transactionalContentCrc64,cpkInfo:n.customerProvidedKey,encryptionScope:n.encryptionScope},st(s)))}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async stageBlockFromURL(e,t,a=0,n,i={}){let{span:s,updatedOptions:o}=Ge("BlockBlobClient-stageBlockFromURL",i);try{return $r(i.customerProvidedKey,this.isHttps),await this.blockBlobContext.stageBlockFromURL(e,0,t,Object.assign({abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,sourceContentMD5:i.sourceContentMD5,sourceContentCrc64:i.sourceContentCrc64,sourceRange:a===0&&!n?void 0:gn({offset:a,count:n}),cpkInfo:i.customerProvidedKey,encryptionScope:i.encryptionScope,copySourceAuthorization:Jo(i.sourceAuthorization)},st(o)))}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}async commitBlockList(e,t={}){var a,n,i;t.conditions=t.conditions||{};let{span:s,updatedOptions:o}=Ge("BlockBlobClient-commitBlockList",t);try{return $r(t.customerProvidedKey,this.isHttps),await this.blockBlobContext.commitBlockList({latest:e},Object.assign({abortSignal:t.abortSignal,blobHttpHeaders:t.blobHTTPHeaders,leaseAccessConditions:t.conditions,metadata:t.metadata,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),cpkInfo:t.customerProvidedKey,encryptionScope:t.encryptionScope,immutabilityPolicyExpiry:(n=t.immutabilityPolicy)===null||n===void 0?void 0:n.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:ro(t.tier),blobTagsString:hs(t.tags)},st(o)))}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}async getBlockList(e,t={}){var a;let{span:n,updatedOptions:i}=Ge("BlockBlobClient-getBlockList",t);try{let s=await this.blockBlobContext.getBlockList(e,Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions})},st(i)));return s.committedBlocks||(s.committedBlocks=[]),s.uncommittedBlocks||(s.uncommittedBlocks=[]),s}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async uploadData(e,t={}){let{span:a,updatedOptions:n}=Ge("BlockBlobClient-uploadData",t);try{if(Lt){let i;return e instanceof Buffer?i=e:e instanceof ArrayBuffer?i=Buffer.from(e):(e=e,i=Buffer.from(e.buffer,e.byteOffset,e.byteLength)),this.uploadSeekableInternal((s,o)=>i.slice(s,s+o),i.byteLength,n)}else{let i=new Blob([e]);return this.uploadSeekableInternal((s,o)=>i.slice(s,s+o),i.size,n)}}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async uploadBrowserData(e,t={}){let{span:a,updatedOptions:n}=Ge("BlockBlobClient-uploadBrowserData",t);try{let i=new Blob([e]);return await this.uploadSeekableInternal((s,o)=>i.slice(s,s+o),i.size,n)}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async uploadSeekableInternal(e,t,a={}){if(a.blockSize||(a.blockSize=0),a.blockSize<0||a.blockSize>4194304e3)throw new RangeError(`blockSize option must be >= 0 and <= ${4194304e3}`);if(a.maxSingleShotSize!==0&&!a.maxSingleShotSize&&(a.maxSingleShotSize=268435456),a.maxSingleShotSize<0||a.maxSingleShotSize>268435456)throw new RangeError(`maxSingleShotSize option must be >= 0 and <= ${268435456}`);if(a.blockSize===0){if(t>4194304e3*5e4)throw new RangeError(`${t} is too larger to upload to a block blob.`);t>a.maxSingleShotSize&&(a.blockSize=Math.ceil(t/5e4),a.blockSize<4194304&&(a.blockSize=4194304))}a.blobHTTPHeaders||(a.blobHTTPHeaders={}),a.conditions||(a.conditions={});let{span:n,updatedOptions:i}=Ge("BlockBlobClient-uploadSeekableInternal",a);try{if(t<=a.maxSingleShotSize)return await this.upload(e(0,t),t,i);let s=Math.floor((t-1)/a.blockSize)+1;if(s>5e4)throw new RangeError(`The buffer's size is too big or the BlockSize is too small;the number of blocks must be <= ${5e4}`);let o=[],l=Ka(),c=0,p=new Ec(a.concurrency);for(let M=0;M<s;M++)p.addOperation(async()=>{let S=V1(l,M),O=a.blockSize*M,q=(M===s-1?t:O+a.blockSize)-O;o.push(S),await this.stageBlock(S,e(O,q),q,{abortSignal:a.abortSignal,conditions:a.conditions,encryptionScope:a.encryptionScope,tracingOptions:i.tracingOptions}),c+=q,a.onProgress&&a.onProgress({loadedBytes:c})});return await p.do(),this.commitBlockList(o,i)}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async uploadFile(e,t={}){let{span:a,updatedOptions:n}=Ge("BlockBlobClient-uploadFile",t);try{let i=(await aS(e)).size;return await this.uploadSeekableInternal((s,o)=>()=>nS(e,{autoClose:!0,end:o?s+o-1:1/0,start:s}),i,Object.assign(Object.assign({},t),{tracingOptions:Object.assign(Object.assign({},t.tracingOptions),st(n))}))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async uploadStream(e,t=8388608,a=5,n={}){n.blobHTTPHeaders||(n.blobHTTPHeaders={}),n.conditions||(n.conditions={});let{span:i,updatedOptions:s}=Ge("BlockBlobClient-uploadStream",n);try{let o=0,l=Ka(),c=0,p=[];return await new su(e,t,a,async(S,O)=>{let E=V1(l,o);p.push(E),o++,await this.stageBlock(E,S,O,{conditions:n.conditions,encryptionScope:n.encryptionScope,tracingOptions:s.tracingOptions}),c+=O,n.onProgress&&n.onProgress({loadedBytes:c})},Math.ceil(a/4*3)).do(),await this.commitBlockList(p,Object.assign(Object.assign({},n),{tracingOptions:Object.assign(Object.assign({},n.tracingOptions),st(s))}))}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}},io=class extends Na{constructor(e,t,a,n){let i,s;if(n=n||{},kn(t))s=e,i=t;else if(Lt&&t instanceof or||t instanceof Vt||Ar(t))s=e,n=a,i=Yt(t,n);else if(!t&&typeof t!="string")s=e,i=Yt(new Vt,n);else if(t&&typeof t=="string"&&a&&typeof a=="string"){let o=t,l=a,c=Di(e);if(c.kind==="AccountConnString")if(Lt){let p=new or(c.accountName,c.accountKey);s=ur(ur(c.url,encodeURIComponent(o)),encodeURIComponent(l)),n.proxyOptions=(c.proxyUri,void 0),i=Yt(p,n)}else throw new Error("Account connection string is only supported in Node.js environment");else if(c.kind==="SASConnString")s=ur(ur(c.url,encodeURIComponent(o)),encodeURIComponent(l))+"?"+c.accountSas,i=Yt(new Vt,n);else throw new Error("Connection string must be either an Account connection string or a SAS connection string")}else throw new Error("Expecting non-empty strings for containerName and blobName parameters");super(s,i),this.pageBlobContext=new Md(this.storageClientContext)}withSnapshot(e){return new io(_i(this.url,Qa.Parameters.SNAPSHOT,e.length===0?void 0:e),this.pipeline)}async create(e,t={}){var a,n,i;t.conditions=t.conditions||{};let{span:s,updatedOptions:o}=Ge("PageBlobClient-create",t);try{return $r(t.customerProvidedKey,this.isHttps),await this.pageBlobContext.create(0,e,Object.assign({abortSignal:t.abortSignal,blobHttpHeaders:t.blobHTTPHeaders,blobSequenceNumber:t.blobSequenceNumber,leaseAccessConditions:t.conditions,metadata:t.metadata,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),cpkInfo:t.customerProvidedKey,encryptionScope:t.encryptionScope,immutabilityPolicyExpiry:(n=t.immutabilityPolicy)===null||n===void 0?void 0:n.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:ro(t.tier),blobTagsString:hs(t.tags)},st(o)))}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}async createIfNotExists(e,t={}){var a,n;let{span:i,updatedOptions:s}=Ge("PageBlobClient-createIfNotExists",t);try{let o={ifNoneMatch:F1},l=await this.create(e,Object.assign(Object.assign({},t),{conditions:o,tracingOptions:s.tracingOptions}));return Object.assign(Object.assign({succeeded:!0},l),{_response:l._response})}catch(o){if(((a=o.details)===null||a===void 0?void 0:a.errorCode)==="BlobAlreadyExists")return i.setStatus({code:qe.ERROR,message:"Expected exception when creating a blob only if it does not already exist."}),Object.assign(Object.assign({succeeded:!1},(n=o.response)===null||n===void 0?void 0:n.parsedHeaders),{_response:o.response});throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async uploadPages(e,t,a,n={}){var i;n.conditions=n.conditions||{};let{span:s,updatedOptions:o}=Ge("PageBlobClient-uploadPages",n);try{return $r(n.customerProvidedKey,this.isHttps),await this.pageBlobContext.uploadPages(a,e,Object.assign({abortSignal:n.abortSignal,leaseAccessConditions:n.conditions,modifiedAccessConditions:Object.assign(Object.assign({},n.conditions),{ifTags:(i=n.conditions)===null||i===void 0?void 0:i.tagConditions}),requestOptions:{onUploadProgress:n.onProgress},range:gn({offset:t,count:a}),sequenceNumberAccessConditions:n.conditions,transactionalContentMD5:n.transactionalContentMD5,transactionalContentCrc64:n.transactionalContentCrc64,cpkInfo:n.customerProvidedKey,encryptionScope:n.encryptionScope},st(o)))}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}async uploadPagesFromURL(e,t,a,n,i={}){var s;i.conditions=i.conditions||{},i.sourceConditions=i.sourceConditions||{};let{span:o,updatedOptions:l}=Ge("PageBlobClient-uploadPagesFromURL",i);try{return $r(i.customerProvidedKey,this.isHttps),await this.pageBlobContext.uploadPagesFromURL(e,gn({offset:t,count:n}),0,gn({offset:a,count:n}),Object.assign({abortSignal:i.abortSignal,sourceContentMD5:i.sourceContentMD5,sourceContentCrc64:i.sourceContentCrc64,leaseAccessConditions:i.conditions,sequenceNumberAccessConditions:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i.conditions),{ifTags:(s=i.conditions)===null||s===void 0?void 0:s.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:i.sourceConditions.ifMatch,sourceIfModifiedSince:i.sourceConditions.ifModifiedSince,sourceIfNoneMatch:i.sourceConditions.ifNoneMatch,sourceIfUnmodifiedSince:i.sourceConditions.ifUnmodifiedSince},cpkInfo:i.customerProvidedKey,encryptionScope:i.encryptionScope,copySourceAuthorization:Jo(i.sourceAuthorization)},st(l)))}catch(c){throw o.setStatus({code:qe.ERROR,message:c.message}),c}finally{o.end()}}async clearPages(e=0,t,a={}){var n;a.conditions=a.conditions||{};let{span:i,updatedOptions:s}=Ge("PageBlobClient-clearPages",a);try{return await this.pageBlobContext.clearPages(0,Object.assign({abortSignal:a.abortSignal,leaseAccessConditions:a.conditions,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(n=a.conditions)===null||n===void 0?void 0:n.tagConditions}),range:gn({offset:e,count:t}),sequenceNumberAccessConditions:a.conditions,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},st(s)))}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async getPageRanges(e=0,t,a={}){var n;a.conditions=a.conditions||{};let{span:i,updatedOptions:s}=Ge("PageBlobClient-getPageRanges",a);try{return await this.pageBlobContext.getPageRanges(Object.assign({abortSignal:a.abortSignal,leaseAccessConditions:a.conditions,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(n=a.conditions)===null||n===void 0?void 0:n.tagConditions}),range:gn({offset:e,count:t})},st(s))).then(tu)}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async getPageRangesDiff(e,t,a,n={}){var i;n.conditions=n.conditions||{};let{span:s,updatedOptions:o}=Ge("PageBlobClient-getPageRangesDiff",n);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:n.abortSignal,leaseAccessConditions:n.conditions,modifiedAccessConditions:Object.assign(Object.assign({},n.conditions),{ifTags:(i=n.conditions)===null||i===void 0?void 0:i.tagConditions}),prevsnapshot:a,range:gn({offset:e,count:t})},st(o))).then(tu)}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}async getPageRangesDiffForManagedDisks(e,t,a,n={}){var i;n.conditions=n.conditions||{};let{span:s,updatedOptions:o}=Ge("PageBlobClient-GetPageRangesDiffForManagedDisks",n);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:n.abortSignal,leaseAccessConditions:n.conditions,modifiedAccessConditions:Object.assign(Object.assign({},n.conditions),{ifTags:(i=n.conditions)===null||i===void 0?void 0:i.tagConditions}),prevSnapshotUrl:a,range:gn({offset:e,count:t})},st(o))).then(tu)}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}async resize(e,t={}){var a;t.conditions=t.conditions||{};let{span:n,updatedOptions:i}=Ge("PageBlobClient-resize",t);try{return await this.pageBlobContext.resize(e,Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),encryptionScope:t.encryptionScope},st(i)))}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async updateSequenceNumber(e,t,a={}){var n;a.conditions=a.conditions||{};let{span:i,updatedOptions:s}=Ge("PageBlobClient-updateSequenceNumber",a);try{return await this.pageBlobContext.updateSequenceNumber(e,Object.assign({abortSignal:a.abortSignal,blobSequenceNumber:t,leaseAccessConditions:a.conditions,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(n=a.conditions)===null||n===void 0?void 0:n.tagConditions})},st(s)))}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async startCopyIncremental(e,t={}){var a;let{span:n,updatedOptions:i}=Ge("PageBlobClient-startCopyIncremental",t);try{return await this.pageBlobContext.copyIncremental(e,Object.assign({abortSignal:t.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions})},st(i)))}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}};async function iS(r){let e=await r.blobBody;return rS(e)}function sS(r){return new Blob([r]).size}var lu=": ",oS=" ",lS=-1,cu=class{constructor(e,t){if(!e||!e.contentType)throw new RangeError("batchResponse is malformed or doesn't contain valid content-type.");if(!t||t.size===0)throw new RangeError("Invalid state: subRequests is not provided or size is 0.");this.batchResponse=e,this.subRequests=t,this.responseBatchBoundary=this.batchResponse.contentType.split("=")[1],this.perResponsePrefix=`--${this.responseBatchBoundary}${Dn}`,this.batchResponseEnding=`--${this.responseBatchBoundary}--`}async parseBatchResponse(){if(this.batchResponse._response.status!==T2.HTTP_ACCEPTED)throw new Error(`Invalid state: batch request failed with status: '${this.batchResponse._response.status}'.`);let t=(await iS(this.batchResponse)).split(this.batchResponseEnding)[0].split(this.perResponsePrefix).slice(1),a=t.length;if(a!==this.subRequests.size&&a!==1)throw new Error("Invalid state: sub responses' count is not equal to sub requests' count.");let n=new Array(a),i=0,s=0;for(let o=0;o<a;o++){let l=t[o],c={};c.headers=new Kr;let p=l.split(`${Dn}`),M=!1,S=!1,O=!1,E=lS;for(let q of p){if(!M){if(q.startsWith(Sa.CONTENT_ID)&&(E=parseInt(q.split(lu)[1])),q.startsWith(Ld)){M=!0;let C=q.split(oS);c.status=parseInt(C[1]),c.statusMessage=C.slice(2).join(oS)}continue}if(q.trim()===""){S||(S=!0);continue}if(S)c.bodyAsText||(c.bodyAsText=""),c.bodyAsText+=q;else{if(q.indexOf(lu)===-1)throw new Error(`Invalid state: find non-empty line '${q}' without HTTP header delimiter '${lu}'.`);let C=q.split(lu);c.headers.set(C[0],C[1]),C[0]===Sa.X_MS_ERROR_CODE&&(c.errorCode=C[1],O=!0)}}E!==lS&&Number.isInteger(E)&&E>=0&&E<this.subRequests.size&&n[E]===void 0?(c._request=this.subRequests.get(E),n[E]=c):Ya.error(`subResponses[${o}] is dropped as the Content-ID is not found or invalid, Content-ID: ${E}`),O?s++:i++}return{subResponses:n,subResponsesSucceededCount:i,subResponsesFailedCount:s}}};var al;(function(r){r[r.LOCKED=0]="LOCKED",r[r.UNLOCKED=1]="UNLOCKED"})(al||(al={}));var so=class{static async lock(e){return new Promise(t=>{this.keys[e]===void 0||this.keys[e]===al.UNLOCKED?(this.keys[e]=al.LOCKED,t()):this.onUnlockEvent(e,()=>{this.keys[e]=al.LOCKED,t()})})}static async unlock(e){return new Promise(t=>{this.keys[e]===al.LOCKED&&this.emitUnlockEvent(e),delete this.keys[e],t()})}static onUnlockEvent(e,t){this.listeners[e]===void 0?this.listeners[e]=[t]:this.listeners[e].push(t)}static emitUnlockEvent(e){if(this.listeners[e]!==void 0&&this.listeners[e].length>0){let t=this.listeners[e].shift();setImmediate(()=>{t.call(this)})}}};so.keys={};so.listeners={};var nl=class{constructor(){this.batch="batch",this.batchRequest=new Q1}getMultiPartContentType(){return this.batchRequest.getMultipartContentType()}getHttpRequestBody(){return this.batchRequest.getHttpRequestBody()}getSubRequests(){return this.batchRequest.getSubRequests()}async addSubRequestInternal(e,t){await so.lock(this.batch);try{this.batchRequest.preAddSubRequest(e),await t(),this.batchRequest.postAddSubRequest(e)}finally{await so.unlock(this.batch)}}setBatchType(e){if(this.batchType||(this.batchType=e),this.batchType!==e)throw new RangeError(`BlobBatch only supports one operation type per batch and it already is being used for ${this.batchType} operations.`)}async deleteBlob(e,t,a){let n,i;if(typeof e=="string"&&(Lt&&t instanceof or||t instanceof Vt||Ar(t)))n=e,i=t;else if(e instanceof Na)n=e.url,i=e.credential,a=t;else throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.");a||(a={});let{span:s,updatedOptions:o}=Ge("BatchDeleteRequest-addSubRequest",a);try{this.setBatchType("delete"),await this.addSubRequestInternal({url:n,credential:i},async()=>{await new Na(n,this.batchRequest.createPipeline(i)).delete(o)})}catch(l){throw s.setStatus({code:qe.ERROR,message:l.message}),l}finally{s.end()}}async setBlobAccessTier(e,t,a,n){let i,s,o;if(typeof e=="string"&&(Lt&&t instanceof or||t instanceof Vt||Ar(t)))i=e,s=t,o=a;else if(e instanceof Na)i=e.url,s=e.credential,o=t,n=a;else throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.");n||(n={});let{span:l,updatedOptions:c}=Ge("BatchSetTierRequest-addSubRequest",n);try{this.setBatchType("setAccessTier"),await this.addSubRequestInternal({url:i,credential:s},async()=>{await new Na(i,this.batchRequest.createPipeline(s)).setAccessTier(o,c)})}catch(p){throw l.setStatus({code:qe.ERROR,message:p.message}),p}finally{l.end()}}},Q1=class{constructor(){this.operationCount=0,this.body="";let e=Ka();this.boundary=`batch_${e}`,this.subRequestPrefix=`--${this.boundary}${Dn}${Sa.CONTENT_TYPE}: application/http${Dn}${Sa.CONTENT_TRANSFER_ENCODING}: binary`,this.multipartContentType=`multipart/mixed; boundary=${this.boundary}`,this.batchRequestEnding=`--${this.boundary}--`,this.subRequests=new Map}createPipeline(e){let t=e instanceof Vt,a=3+(t?0:1),n=new Array(a);return n[0]=Vs(),n[1]=new ty,t||(n[2]=Ar(e)?Dd(Gs(e,zd),e):e),n[a-1]=new J1(this),new Sc(n,{})}appendSubRequestToBody(e){this.body+=[this.subRequestPrefix,`${Sa.CONTENT_ID}: ${this.operationCount}`,"",`${e.method.toString()} ${L2(e.url)} ${Ld}${Dn}`].join(Dn);for(let t of e.headers.headersArray())this.body+=`${t.name}: ${t.value}${Dn}`;this.body+=Dn}preAddSubRequest(e){if(this.operationCount>=U1)throw new RangeError(`Cannot exceed ${U1} sub requests in a single batch`);let t=qd(e.url);if(!t||t==="")throw new RangeError(`Invalid url for sub request: '${e.url}'`)}postAddSubRequest(e){this.subRequests.set(this.operationCount,e),this.operationCount++}getHttpRequestBody(){return`${this.body}${this.batchRequestEnding}${Dn}`}getMultipartContentType(){return this.multipartContentType}getSubRequests(){return this.subRequests}},Z1=class extends It{constructor(e,t,a){super(t,a),this.dummyResponse={request:new An,status:200,headers:new Kr},this.batchRequest=e}async sendRequest(e){return await this.batchRequest.appendSubRequestToBody(e),this.dummyResponse}},J1=class{constructor(e){this.batchRequest=e}create(e,t){return new Z1(this.batchRequest,e,t)}},ey=class extends It{constructor(e,t){super(e,t)}async sendRequest(e){let t="";for(let a of e.headers.headersArray())Hd(a.name,Sa.X_MS_VERSION)&&(t=a.name);return t!==""&&e.headers.remove(t),this._nextPolicy.sendRequest(e)}},ty=class{create(e,t){return new ey(e,t)}};var il=class{constructor(e,t,a){let n;kn(t)?n=t:t?n=Yt(t,a):n=Yt(new Vt,a);let i=new ki(e,n.toServiceClientOptions()),s=qd(e);s&&s!=="/"?this.serviceOrContainerContext=new qn(i):this.serviceOrContainerContext=new Wo(i)}createBatch(){return new nl}async deleteBlobs(e,t,a){let n=new nl;for(let i of e)typeof i=="string"?await n.deleteBlob(i,t,a):await n.deleteBlob(i,t);return this.submitBatch(n)}async setBlobsAccessTier(e,t,a,n){let i=new nl;for(let s of e)typeof s=="string"?await i.setBlobAccessTier(s,t,a,n):await i.setBlobAccessTier(s,t,a);return this.submitBatch(i)}async submitBatch(e,t={}){if(!e||e.getSubRequests().size===0)throw new RangeError("Batch request should contain one or more sub requests.");let{span:a,updatedOptions:n}=Ge("BlobBatchClient-submitBatch",t);try{let i=e.getHttpRequestBody(),s=await this.serviceOrContainerContext.submitBatch(sS(i),e.getMultiPartContentType(),i,Object.assign(Object.assign({},t),st(n))),l=await new cu(s,e.getSubRequests()).parseBatchResponse();return{_response:s._response,contentType:s.contentType,errorCode:s.errorCode,requestId:s.requestId,clientRequestId:s.clientRequestId,version:s.version,subResponses:l.subResponses,subResponsesSucceededCount:l.subResponsesSucceededCount,subResponsesFailedCount:l.subResponsesFailedCount}}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}};var mu=class extends xs{constructor(e,t,a){let n,i;if(a=a||{},kn(t))i=e,n=t;else if(Lt&&t instanceof or||t instanceof Vt||Ar(t))i=e,n=Yt(t,a);else if(!t&&typeof t!="string")i=e,n=Yt(new Vt,a);else if(t&&typeof t=="string"){let s=t,o=Di(e);if(o.kind==="AccountConnString")if(Lt){let l=new or(o.accountName,o.accountKey);i=ur(o.url,encodeURIComponent(s)),a.proxyOptions=(o.proxyUri,void 0),n=Yt(l,a)}else throw new Error("Account connection string is only supported in Node.js environment");else if(o.kind==="SASConnString")i=ur(o.url,encodeURIComponent(s))+"?"+o.accountSas,n=Yt(new Vt,a);else throw new Error("Connection string must be either an Account connection string or a SAS connection string")}else throw new Error("Expecting non-empty strings for containerName parameter");super(i,n),this._containerName=this.getContainerNameFromUrl(),this.containerContext=new qn(this.storageClientContext)}get containerName(){return this._containerName}async create(e={}){let{span:t,updatedOptions:a}=Ge("ContainerClient-create",e);try{return await this.containerContext.create(Object.assign(Object.assign({},e),st(a)))}catch(n){throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async createIfNotExists(e={}){var t,a;let{span:n,updatedOptions:i}=Ge("ContainerClient-createIfNotExists",e);try{let s=await this.create(i);return Object.assign(Object.assign({succeeded:!0},s),{_response:s._response})}catch(s){if(((t=s.details)===null||t===void 0?void 0:t.errorCode)==="ContainerAlreadyExists")return n.setStatus({code:qe.ERROR,message:"Expected exception when creating a container only if it does not already exist."}),Object.assign(Object.assign({succeeded:!1},(a=s.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:s.response});throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async exists(e={}){let{span:t,updatedOptions:a}=Ge("ContainerClient-exists",e);try{return await this.getProperties({abortSignal:e.abortSignal,tracingOptions:a.tracingOptions}),!0}catch(n){if(n.statusCode===404)return t.setStatus({code:qe.ERROR,message:"Expected exception when checking container existence"}),!1;throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}getBlobClient(e){return new Na(ur(this.url,encodeURIComponent(e)),this.pipeline)}getAppendBlobClient(e){return new ao(ur(this.url,encodeURIComponent(e)),this.pipeline)}getBlockBlobClient(e){return new no(ur(this.url,encodeURIComponent(e)),this.pipeline)}getPageBlobClient(e){return new io(ur(this.url,encodeURIComponent(e)),this.pipeline)}async getProperties(e={}){e.conditions||(e.conditions={});let{span:t,updatedOptions:a}=Ge("ContainerClient-getProperties",e);try{return await this.containerContext.getProperties(Object.assign(Object.assign({abortSignal:e.abortSignal},e.conditions),st(a)))}catch(n){throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async delete(e={}){e.conditions||(e.conditions={});let{span:t,updatedOptions:a}=Ge("ContainerClient-delete",e);try{return await this.containerContext.delete(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:e.conditions},st(a)))}catch(n){throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async deleteIfExists(e={}){var t,a;let{span:n,updatedOptions:i}=Ge("ContainerClient-deleteIfExists",e);try{let s=await this.delete(i);return Object.assign(Object.assign({succeeded:!0},s),{_response:s._response})}catch(s){if(((t=s.details)===null||t===void 0?void 0:t.errorCode)==="ContainerNotFound")return n.setStatus({code:qe.ERROR,message:"Expected exception when deleting a container only if it exists."}),Object.assign(Object.assign({succeeded:!1},(a=s.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:s.response});throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async setMetadata(e,t={}){if(t.conditions||(t.conditions={}),t.conditions.ifUnmodifiedSince)throw new RangeError("the IfUnmodifiedSince must have their default values because they are ignored by the blob service");let{span:a,updatedOptions:n}=Ge("ContainerClient-setMetadata",t);try{return await this.containerContext.setMetadata(Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:e,modifiedAccessConditions:t.conditions},st(n)))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async getAccessPolicy(e={}){e.conditions||(e.conditions={});let{span:t,updatedOptions:a}=Ge("ContainerClient-getAccessPolicy",e);try{let n=await this.containerContext.getAccessPolicy(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions},st(a))),i={_response:n._response,blobPublicAccess:n.blobPublicAccess,date:n.date,etag:n.etag,errorCode:n.errorCode,lastModified:n.lastModified,requestId:n.requestId,clientRequestId:n.clientRequestId,signedIdentifiers:[],version:n.version};for(let s of n){let o;s.accessPolicy&&(o={permissions:s.accessPolicy.permissions},s.accessPolicy.expiresOn&&(o.expiresOn=new Date(s.accessPolicy.expiresOn)),s.accessPolicy.startsOn&&(o.startsOn=new Date(s.accessPolicy.startsOn))),i.signedIdentifiers.push({accessPolicy:o,id:s.id})}return i}catch(n){throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async setAccessPolicy(e,t,a={}){a.conditions=a.conditions||{};let{span:n,updatedOptions:i}=Ge("ContainerClient-setAccessPolicy",a);try{let s=[];for(let o of t||[])s.push({accessPolicy:{expiresOn:o.accessPolicy.expiresOn?sr(o.accessPolicy.expiresOn):"",permissions:o.accessPolicy.permissions,startsOn:o.accessPolicy.startsOn?sr(o.accessPolicy.startsOn):""},id:o.id});return await this.containerContext.setAccessPolicy(Object.assign({abortSignal:a.abortSignal,access:e,containerAcl:s,leaseAccessConditions:a.conditions,modifiedAccessConditions:a.conditions},st(i)))}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}getBlobLeaseClient(e){return new tl(this,e)}async uploadBlockBlob(e,t,a,n={}){let{span:i,updatedOptions:s}=Ge("ContainerClient-uploadBlockBlob",n);try{let o=this.getBlockBlobClient(e),l=await o.upload(t,a,s);return{blockBlobClient:o,response:l}}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async deleteBlob(e,t={}){let{span:a,updatedOptions:n}=Ge("ContainerClient-deleteBlob",t);try{let i=this.getBlobClient(e);return t.versionId&&(i=i.withVersion(t.versionId)),await i.delete(n)}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async listBlobFlatSegment(e,t={}){let{span:a,updatedOptions:n}=Ge("ContainerClient-listBlobFlatSegment",t);try{let i=await this.containerContext.listBlobFlatSegment(Object.assign(Object.assign({marker:e},t),st(n)));return Object.assign(Object.assign({},i),{_response:i._response,segment:Object.assign(Object.assign({},i.segment),{blobItems:i.segment.blobItems.map(o=>Object.assign(Object.assign({},o),{tags:to(o.blobTags),objectReplicationSourceProperties:Zo(o.objectReplicationMetadata)}))})})}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async listBlobHierarchySegment(e,t,a={}){let{span:n,updatedOptions:i}=Ge("ContainerClient-listBlobHierarchySegment",a);try{let s=await this.containerContext.listBlobHierarchySegment(e,Object.assign(Object.assign({marker:t},a),st(i)));return Object.assign(Object.assign({},s),{_response:s._response,segment:Object.assign(Object.assign({},s.segment),{blobItems:s.segment.blobItems.map(l=>Object.assign(Object.assign({},l),{tags:to(l.blobTags),objectReplicationSourceProperties:Zo(l.objectReplicationMetadata)}))})})}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}listSegments(e,t={}){return li(this,arguments,function*(){let n;if(!!e||e===void 0)do n=yield dr(this.listBlobFlatSegment(e,t)),e=n.continuationToken,yield yield dr(yield dr(n));while(e)})}listItems(e={}){return li(this,arguments,function*(){var a,n;let i;try{for(var s=Oi(this.listSegments(i,e)),o;o=yield dr(s.next()),!o.done;){let l=o.value;yield dr(yield*fc(Oi(l.segment.blobItems)))}}catch(l){a={error:l}}finally{try{o&&!o.done&&(n=s.return)&&(yield dr(n.call(s)))}finally{if(a)throw a.error}}})}listBlobsFlat(e={}){let t=[];e.includeCopy&&t.push("copy"),e.includeDeleted&&t.push("deleted"),e.includeMetadata&&t.push("metadata"),e.includeSnapshots&&t.push("snapshots"),e.includeVersions&&t.push("versions"),e.includeUncommitedBlobs&&t.push("uncommittedblobs"),e.includeTags&&t.push("tags"),e.includeDeletedWithVersions&&t.push("deletedwithversions"),e.includeImmutabilityPolicy&&t.push("immutabilitypolicy"),e.includeLegalHold&&t.push("legalhold"),e.prefix===""&&(e.prefix=void 0);let a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{}),n=this.listItems(a);return{next(){return n.next()},[Symbol.asyncIterator](){return this},byPage:(i={})=>this.listSegments(i.continuationToken,Object.assign({maxPageSize:i.maxPageSize},a))}}listHierarchySegments(e,t,a={}){return li(this,arguments,function*(){let i;if(!!t||t===void 0)do i=yield dr(this.listBlobHierarchySegment(e,t,a)),t=i.continuationToken,yield yield dr(yield dr(i));while(t)})}listItemsByHierarchy(e,t={}){return li(this,arguments,function*(){var n,i;let s;try{for(var o=Oi(this.listHierarchySegments(e,s,t)),l;l=yield dr(o.next()),!l.done;){let p=l.value.segment;if(p.blobPrefixes)for(let M of p.blobPrefixes)yield yield dr(Object.assign({kind:"prefix"},M));for(let M of p.blobItems)yield yield dr(Object.assign({kind:"blob"},M))}}catch(c){n={error:c}}finally{try{l&&!l.done&&(i=o.return)&&(yield dr(i.call(o)))}finally{if(n)throw n.error}}})}listBlobsByHierarchy(e,t={}){if(e==="")throw new RangeError("delimiter should contain one or more characters");let a=[];t.includeCopy&&a.push("copy"),t.includeDeleted&&a.push("deleted"),t.includeMetadata&&a.push("metadata"),t.includeSnapshots&&a.push("snapshots"),t.includeVersions&&a.push("versions"),t.includeUncommitedBlobs&&a.push("uncommittedblobs"),t.includeTags&&a.push("tags"),t.includeDeletedWithVersions&&a.push("deletedwithversions"),t.includeImmutabilityPolicy&&a.push("immutabilitypolicy"),t.includeLegalHold&&a.push("legalhold"),t.prefix===""&&(t.prefix=void 0);let n=Object.assign(Object.assign({},t),a.length>0?{include:a}:{}),i=this.listItemsByHierarchy(e,n);return{async next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(s={})=>this.listHierarchySegments(e,s.continuationToken,Object.assign({maxPageSize:s.maxPageSize},n))}}getContainerNameFromUrl(){let e;try{let t=ar.parse(this.url);if(t.getHost().split(".")[1]==="blob"?e=t.getPath().split("/")[1]:bc(t)?e=t.getPath().split("/")[2]:e=t.getPath().split("/")[1],e=decodeURIComponent(e),!e)throw new Error("Provided containerName is invalid.");return e}catch{throw new Error("Unable to extract containerName with provided information.")}}generateSasUrl(e){return new Promise(t=>{if(!(this.credential instanceof or))throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");let a=Qd(Object.assign({containerName:this._containerName},e),this.credential).toString();t(Qo(this.url,a))})}getBlobBatchClient(){return new il(this.url,this.pipeline)}};var IS=ns(wS(),1),{__extends:aq,__assign:nq,__rest:iq,__decorate:sq,__param:oq,__metadata:lq,__awaiter:cq,__generator:mq,__exportStar:dq,__createBinding:uq,__values:pq,__read:fq,__spread:hq,__spreadArrays:yq,__spreadArray:xq,__await:PT,__asyncGenerator:CT,__asyncDelegator:RT,__asyncValues:ET,__makeTemplateObject:gq,__importStar:vq,__importDefault:_q,__classPrivateFieldGet:bq,__classPrivateFieldSet:Sq}=IS.default;var ji=class{constructor(){this.read=!1,this.write=!1,this.delete=!1,this.deleteVersion=!1,this.list=!1,this.add=!1,this.create=!1,this.update=!1,this.process=!1,this.tag=!1,this.filter=!1,this.setImmutabilityPolicy=!1}static parse(e){let t=new ji;for(let a of e)switch(a){case"r":t.read=!0;break;case"w":t.write=!0;break;case"d":t.delete=!0;break;case"x":t.deleteVersion=!0;break;case"l":t.list=!0;break;case"a":t.add=!0;break;case"c":t.create=!0;break;case"u":t.update=!0;break;case"p":t.process=!0;break;case"t":t.tag=!0;break;case"f":t.filter=!0;break;case"i":t.setImmutabilityPolicy=!0;break;default:throw new RangeError(`Invalid permission character: ${a}`)}return t}static from(e){let t=new ji;return e.read&&(t.read=!0),e.write&&(t.write=!0),e.delete&&(t.delete=!0),e.deleteVersion&&(t.deleteVersion=!0),e.filter&&(t.filter=!0),e.tag&&(t.tag=!0),e.list&&(t.list=!0),e.add&&(t.add=!0),e.create&&(t.create=!0),e.update&&(t.update=!0),e.process&&(t.process=!0),e.setImmutabilityPolicy&&(t.setImmutabilityPolicy=!0),t}toString(){let e=[];return this.read&&e.push("r"),this.write&&e.push("w"),this.delete&&e.push("d"),this.deleteVersion&&e.push("x"),this.filter&&e.push("f"),this.tag&&e.push("t"),this.list&&e.push("l"),this.add&&e.push("a"),this.create&&e.push("c"),this.update&&e.push("u"),this.process&&e.push("p"),this.setImmutabilityPolicy&&e.push("i"),e.join("")}};var ol=class{constructor(){this.service=!1,this.container=!1,this.object=!1}static parse(e){let t=new ol;for(let a of e)switch(a){case"s":t.service=!0;break;case"c":t.container=!0;break;case"o":t.object=!0;break;default:throw new RangeError(`Invalid resource type: ${a}`)}return t}toString(){let e=[];return this.service&&e.push("s"),this.container&&e.push("c"),this.object&&e.push("o"),e.join("")}};var gs=class{constructor(){this.blob=!1,this.file=!1,this.queue=!1,this.table=!1}static parse(e){let t=new gs;for(let a of e)switch(a){case"b":t.blob=!0;break;case"f":t.file=!0;break;case"q":t.queue=!0;break;case"t":t.table=!0;break;default:throw new RangeError(`Invalid service character: ${a}`)}return t}toString(){let e=[];return this.blob&&e.push("b"),this.table&&e.push("t"),this.queue&&e.push("q"),this.file&&e.push("f"),e.join("")}};function MS(r,e){let t=r.version?r.version:_c;if(r.permissions&&r.permissions.setImmutabilityPolicy&&t<"2020-08-04")throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.");if(r.permissions&&r.permissions.deleteVersion&&t<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when provided 'x' permission.");if(r.permissions&&r.permissions.tag&&t<"2019-12-12")throw RangeError("'version' must be >= '2019-12-12' when provided 't' permission.");if(r.permissions&&r.permissions.filter&&t<"2019-12-12")throw RangeError("'version' must be >= '2019-12-12' when provided 'f' permission.");let a=ji.parse(r.permissions.toString()),n=gs.parse(r.services).toString(),i=ol.parse(r.resourceTypes).toString(),s=[e.accountName,a,n,i,r.startsOn?sr(r.startsOn,!1):"",sr(r.expiresOn,!1),r.ipRange?Fi(r.ipRange):"",r.protocol?r.protocol:"",t,""].join(`
21
- `),o=e.computeHMACSHA256(s);return new Ui(t,o,a.toString(),n,i,r.protocol,r.startsOn,r.expiresOn,r.ipRange)}var oo=class extends xs{constructor(e,t,a){let n;kn(t)?n=t:Lt&&t instanceof or||t instanceof Vt||Ar(t)?n=Yt(t,a):n=Yt(new Vt,a),super(e,n),this.serviceContext=new Wo(this.storageClientContext)}static fromConnectionString(e,t){t=t||{};let a=Di(e);if(a.kind==="AccountConnString")if(Lt){let n=new or(a.accountName,a.accountKey);t.proxyOptions=(a.proxyUri,void 0);let i=Yt(n,t);return new oo(a.url,i)}else throw new Error("Account connection string is only supported in Node.js environment");else if(a.kind==="SASConnString"){let n=Yt(new Vt,t);return new oo(a.url+"?"+a.accountSas,n)}else throw new Error("Connection string must be either an Account connection string or a SAS connection string")}getContainerClient(e){return new mu(ur(this.url,encodeURIComponent(e)),this.pipeline)}async createContainer(e,t={}){let{span:a,updatedOptions:n}=Ge("BlobServiceClient-createContainer",t);try{let i=this.getContainerClient(e),s=await i.create(n);return{containerClient:i,containerCreateResponse:s}}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async deleteContainer(e,t={}){let{span:a,updatedOptions:n}=Ge("BlobServiceClient-deleteContainer",t);try{return await this.getContainerClient(e).delete(n)}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async undeleteContainer(e,t,a={}){let{span:n,updatedOptions:i}=Ge("BlobServiceClient-undeleteContainer",a);try{let s=this.getContainerClient(a.destinationContainerName||e),l=await new qn(s.storageClientContext).restore(Object.assign({deletedContainerName:e,deletedContainerVersion:t},i));return{containerClient:s,containerUndeleteResponse:l}}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}async renameContainer(e,t,a={}){var n;let{span:i,updatedOptions:s}=Ge("BlobServiceClient-renameContainer",a);try{let o=this.getContainerClient(t),c=await new qn(o.storageClientContext).rename(e,Object.assign(Object.assign({},s),{sourceLeaseId:(n=a.sourceCondition)===null||n===void 0?void 0:n.leaseId}));return{containerClient:o,containerRenameResponse:c}}catch(o){throw i.setStatus({code:qe.ERROR,message:o.message}),o}finally{i.end()}}async getProperties(e={}){let{span:t,updatedOptions:a}=Ge("BlobServiceClient-getProperties",e);try{return await this.serviceContext.getProperties(Object.assign({abortSignal:e.abortSignal},st(a)))}catch(n){throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async setProperties(e,t={}){let{span:a,updatedOptions:n}=Ge("BlobServiceClient-setProperties",t);try{return await this.serviceContext.setProperties(e,Object.assign({abortSignal:t.abortSignal},st(n)))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async getStatistics(e={}){let{span:t,updatedOptions:a}=Ge("BlobServiceClient-getStatistics",e);try{return await this.serviceContext.getStatistics(Object.assign({abortSignal:e.abortSignal},st(a)))}catch(n){throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async getAccountInfo(e={}){let{span:t,updatedOptions:a}=Ge("BlobServiceClient-getAccountInfo",e);try{return await this.serviceContext.getAccountInfo(Object.assign({abortSignal:e.abortSignal},st(a)))}catch(n){throw t.setStatus({code:qe.ERROR,message:n.message}),n}finally{t.end()}}async listContainersSegment(e,t={}){let{span:a,updatedOptions:n}=Ge("BlobServiceClient-listContainersSegment",t);try{return await this.serviceContext.listContainersSegment(Object.assign(Object.assign(Object.assign({abortSignal:t.abortSignal,marker:e},t),{include:typeof t.include=="string"?[t.include]:t.include}),st(n)))}catch(i){throw a.setStatus({code:qe.ERROR,message:i.message}),i}finally{a.end()}}async findBlobsByTagsSegment(e,t,a={}){let{span:n,updatedOptions:i}=Ge("BlobServiceClient-findBlobsByTagsSegment",a);try{let s=await this.serviceContext.filterBlobs(Object.assign({abortSignal:a.abortSignal,where:e,marker:t,maxPageSize:a.maxPageSize},st(i)));return Object.assign(Object.assign({},s),{_response:s._response,blobs:s.blobs.map(l=>{var c;let p="";return((c=l.tags)===null||c===void 0?void 0:c.blobTagSet.length)===1&&(p=l.tags.blobTagSet[0].value),Object.assign(Object.assign({},l),{tags:to(l.tags),tagValue:p})})})}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}findBlobsByTagsSegments(e,t,a={}){return li(this,arguments,function*(){let i;if(!!t||t===void 0)do i=yield dr(this.findBlobsByTagsSegment(e,t,a)),i.blobs=i.blobs||[],t=i.continuationToken,yield yield dr(i);while(t)})}findBlobsByTagsItems(e,t={}){return li(this,arguments,function*(){var n,i;let s;try{for(var o=Oi(this.findBlobsByTagsSegments(e,s,t)),l;l=yield dr(o.next()),!l.done;){let c=l.value;yield dr(yield*fc(Oi(c.blobs)))}}catch(c){n={error:c}}finally{try{l&&!l.done&&(i=o.return)&&(yield dr(i.call(o)))}finally{if(n)throw n.error}}})}findBlobsByTags(e,t={}){let a=Object.assign({},t),n=this.findBlobsByTagsItems(e,a);return{next(){return n.next()},[Symbol.asyncIterator](){return this},byPage:(i={})=>this.findBlobsByTagsSegments(e,i.continuationToken,Object.assign({maxPageSize:i.maxPageSize},a))}}listSegments(e,t={}){return li(this,arguments,function*(){let n;if(!!e||e===void 0)do n=yield dr(this.listContainersSegment(e,t)),n.containerItems=n.containerItems||[],e=n.continuationToken,yield yield dr(yield dr(n));while(e)})}listItems(e={}){return li(this,arguments,function*(){var a,n;let i;try{for(var s=Oi(this.listSegments(i,e)),o;o=yield dr(s.next()),!o.done;){let l=o.value;yield dr(yield*fc(Oi(l.containerItems)))}}catch(l){a={error:l}}finally{try{o&&!o.done&&(n=s.return)&&(yield dr(n.call(s)))}finally{if(a)throw a.error}}})}listContainers(e={}){e.prefix===""&&(e.prefix=void 0);let t=[];e.includeDeleted&&t.push("deleted"),e.includeMetadata&&t.push("metadata");let a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{}),n=this.listItems(a);return{next(){return n.next()},[Symbol.asyncIterator](){return this},byPage:(i={})=>this.listSegments(i.continuationToken,Object.assign({maxPageSize:i.maxPageSize},a))}}async getUserDelegationKey(e,t,a={}){let{span:n,updatedOptions:i}=Ge("BlobServiceClient-getUserDelegationKey",a);try{let s=await this.serviceContext.getUserDelegationKey({startsOn:sr(e,!1),expiresOn:sr(t,!1)},Object.assign({abortSignal:a.abortSignal},st(i))),o={signedObjectId:s.signedObjectId,signedTenantId:s.signedTenantId,signedStartsOn:new Date(s.signedStartsOn),signedExpiresOn:new Date(s.signedExpiresOn),signedService:s.signedService,signedVersion:s.signedVersion,value:s.value};return Object.assign({_response:s._response,requestId:s.requestId,clientRequestId:s.clientRequestId,version:s.version,date:s.date,errorCode:s.errorCode},o)}catch(s){throw n.setStatus({code:qe.ERROR,message:s.message}),s}finally{n.end()}}getBlobBatchClient(){return new il(this.url,this.pipeline)}generateAccountSasUrl(e,t=ji.parse("r"),a="sco",n={}){if(!(this.credential instanceof or))throw RangeError("Can only generate the account SAS when the client is initialized with a shared key credential");if(e===void 0){let s=new Date;e=new Date(s.getTime()+3600*1e3)}let i=MS(Object.assign({permissions:t,expiresOn:e,resourceTypes:a,services:gs.parse("b").toString()},n),this.credential).toString();return Qo(this.url,i)}};var AS={Unknown:0,NonRetryableStatus:1,InvalidEvent:2,SizeLimitExceeded:3,KillSwitch:4,QueueFull:5};var Fn="function",Ha="object",Un="undefined",Pr="prototype",Tc="hasOwnProperty";var Za=Object,ll=Za[Pr],cl=Za.assign,fu=Za.create,hu=Za.defineProperty,vs=ll[Tc];var ml=null;function vn(r){return r===void 0&&(r=!0),(!ml||!r)&&(typeof globalThis!==Un&&globalThis&&(ml=globalThis),typeof self!==Un&&self&&(ml=self),typeof window!==Un&&window&&(ml=window),typeof global!==Un&&global&&(ml=global)),ml}function dl(r){throw new TypeError(r)}function ul(r){var e=fu;if(e)return e(r);if(r==null)return{};var t=typeof r;t!==Ha&&t!==Fn&&dl("Object prototype may only be an Object:"+r);function a(){}return a[Pr]=r,new a}var dH=(vn()||{}).Symbol,uH=(vn()||{}).Reflect;var wT=function(r){for(var e,t=1,a=arguments.length;t<a;t++){e=arguments[t];for(var n in e)ll[Tc].call(e,n)&&(r[n]=e[n])}return r},Br=cl||wT,ay=function(r,e){return ay=Za.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,a){t.__proto__=a}||function(t,a){for(var n in a)a[Tc](n)&&(t[n]=a[n])},ay(r,e)};function Nt(r,e){typeof e!==Fn&&e!==null&&dl("Class extends value "+String(e)+" is not a constructor or null"),ay(r,e);function t(){this.constructor=r}r[Pr]=e===null?ul(e):(t[Pr]=e[Pr],new t)}function yu(r,e){for(var t=0,a=e.length,n=r.length;t<a;t++,n++)r[n]=e[t];return r}var xu="constructor",Vi="prototype",gu="function",vu="_dynInstFuncs",sy="_isDynProxy",pl="_dynClass",IT="_dynCls$",oy="_dynInstChk",wc=oy,LS="_dfOpts",BS="_unknown_",MT="__proto__",ny="useBaseInst",OS="setInstFuncs",Su=Object,Ic=Su.getPrototypeOf,zS=0;function _s(r,e){return r&&Su[Vi].hasOwnProperty.call(r,e)}function qS(r){return r&&(r===Su[Vi]||r===Array[Vi])}function ly(r){return qS(r)||r===Function[Vi]}function lo(r){if(r){if(Ic)return Ic(r);var e=r[MT]||r[Vi]||(r[xu]?r[xu][Vi]:null);if(e)return e}return null}function _u(r,e){var t=[],a=Su.getOwnPropertyNames;if(a)t=a(r);else for(var n in r)typeof n=="string"&&_s(r,n)&&t.push(n);if(t&&t.length>0)for(var i=0;i<t.length;i++)e(t[i])}function cy(r,e,t){return e!==xu&&typeof r[e]===gu&&(t||_s(r,e))}function bu(r){throw new TypeError("DynamicProto: "+r)}function AT(r){var e={};return _u(r,function(t){!e[t]&&cy(r,t,!1)&&(e[t]=r[t])}),e}function my(r,e){for(var t=r.length-1;t>=0;t--)if(r[t]===e)return!0;return!1}function BT(r,e,t,a){function n(l,c,p){var M=c[p];if(M[sy]&&a){var S=l[vu]||{};S[wc]!==!1&&(M=(S[c[pl]]||{})[p]||M)}return function(){return M.apply(l,arguments)}}var i={};_u(t,function(l){i[l]=n(e,t,l)});for(var s=lo(r),o=[];s&&!ly(s)&&!my(o,s);)_u(s,function(l){!i[l]&&cy(s,l,!Ic)&&(i[l]=n(e,s,l))}),o.push(s),s=lo(s);return i}function OT(r,e,t,a){var n=null;if(r&&_s(t,pl)){var i=r[vu]||{};if(n=(i[t[pl]]||{})[e],n||bu("Missing ["+e+"] "+gu),!n[oy]&&i[wc]!==!1){for(var s=!_s(r,e),o=lo(r),l=[];s&&o&&!ly(o)&&!my(l,o);){var c=o[e];if(c){s=c===a;break}l.push(o),o=lo(o)}try{s&&(r[e]=n),n[oy]=1}catch{i[wc]=!1}}}return n}function zT(r,e,t){var a=e[r];return a===t&&(a=lo(e)[r]),typeof a!==gu&&bu("["+r+"] is not a "+gu),a}function LT(r,e,t,a,n){function i(l,c){var p=function(){var M=OT(this,c,l,p)||zT(c,l,p);return M.apply(this,arguments)};return p[sy]=1,p}if(!qS(r)){var s=t[vu]=t[vu]||{},o=s[e]=s[e]||{};s[wc]!==!1&&(s[wc]=!!n),_u(t,function(l){cy(t,l,!1)&&t[l]!==a[l]&&(o[l]=t[l],delete t[l],(!_s(r,l)||r[l]&&!r[l][sy])&&(r[l]=i(r,l)))})}}function qT(r,e){if(Ic)for(var t=[],a=lo(e);a&&!ly(a)&&!my(t,a);){if(a===r)return!0;t.push(a),a=lo(a)}return!1}function iy(r,e){return _s(r,Vi)?r.name||e||BS:((r||{})[xu]||{}).name||e||BS}function dy(r,e,t,a){_s(r,Vi)||bu("theClass is an invalid class definition.");var n=r[Vi];qT(n,e)||bu("["+iy(r)+"] is not in class hierarchy of ["+iy(e)+"]");var i=null;_s(n,pl)?i=n[pl]:(i=IT+iy(r,"_")+"$"+zS,zS++,n[pl]=i);var s=dy[LS],o=!!s[ny];o&&a&&a[ny]!==void 0&&(o=!!a[ny]);var l=AT(e),c=BT(n,e,l,o);t(e,c);var p=!!Ic&&!!s[OS];p&&a&&(p=!!a[OS]),LT(n,i,e,l,p!==!1)}var HT={setInstFuncs:!0,useBaseInst:!0};dy[LS]=HT;var zt=dy;var Oe;(function(r){r[r.CRITICAL=1]="CRITICAL",r[r.WARNING=2]="WARNING"})(Oe||(Oe={}));var we={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,InvalidEvent:70,FailedMonitorAjaxSetRequestHeader:71,SendBrowserInfoOnUserInit:72,PluginException:73,NotificationException:74,SnippetScriptLoadFailure:99,InvalidInstrumentationKey:100,CannotParseAiBlobValue:101,InvalidContentBlob:102,TrackPageActionEventFailed:103,FailedAddingCustomDefinedRequestContext:104,InMemoryStorageBufferFull:105};var DT="on",HS="attachEvent",DS="addEventListener";var XS="toISOString",$S="endsWith",kT="startsWith",kS="indexOf",FS="map",US="reduce",py="trim",WS="toString",FT="__proto__",UT="constructor",jS=hu,LH=Za.freeze,qH=Za.seal,VS=Za.keys,fy=String[Pr],jT=fy[py],VT=fy[$S],HH=fy[kT],GT=Date[Pr],KT=GT[XS],XT=Array.isArray,YS=ll[WS],$T=vs[WS],DH=$T.call(Za),WT=/-([a-z])/g,YT=/([^\w\d_$])/g,QT=/^(\d+[\w\d_$])/,GS=Object.getPrototypeOf;function QS(r){if(r){if(GS)return GS(r);var e=r[FT]||r[Pr]||r[UT];if(e)return e}return null}function Ir(r){return r===void 0||typeof r===Un}function Le(r){return r===null||Ir(r)}function hy(r){return!Le(r)}function Mc(r,e){return!!(r&&vs.call(r,e))}function jn(r){return!!(r&&typeof r===Ha)}function vt(r){return!!(r&&typeof r===Fn)}function Vn(r,e,t,a){a===void 0&&(a=!1);var n=!1;if(!Le(r))try{Le(r[DS])?Le(r[HS])||(r[HS](DT+e,t),n=!0):(r[DS](e,t,a),n=!0)}catch{}return n}function yy(r){var e=r;return e&&pt(e)&&(e=e.replace(WT,function(t,a){return a.toUpperCase()}),e=e.replace(YT,"_"),e=e.replace(QT,function(t,a){return"_"+a})),e}function Xt(r,e){if(r)for(var t in r)vs.call(r,t)&&e.call(r,t,r[t])}function xy(r,e){var t=!1;return r&&e&&!(t=r===e)&&(t=VT?r[$S](e):ZT(r,e)),t}function ZT(r,e){var t=!1,a=e?e.length:0,n=r?r.length:0;if(a&&n&&n>=a&&!(t=r===e)){for(var i=n-1,s=a-1;s>=0;s--){if(r[i]!=e[s])return!1;i--}t=!0}return t}function Wr(r,e){return r&&e?r.indexOf(e)!==-1:!1}var Yr=XT||JT;function JT(r){return!!(r&&YS.call(r)==="[object Array]")}function fl(r){return!!(r&&YS.call(r)==="[object Error]")}function pt(r){return typeof r=="string"}function hl(r){return typeof r=="number"}function Pa(r){if(r)return KT?r[XS]():ew(r)}function ew(r){if(r&&r.getUTCFullYear){var e=function(t){var a=String(t);return a.length===1&&(a="0"+a),a};return r.getUTCFullYear()+"-"+e(r.getUTCMonth()+1)+"-"+e(r.getUTCDate())+"T"+e(r.getUTCHours())+":"+e(r.getUTCMinutes())+":"+e(r.getUTCSeconds())+"."+String((r.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}}function ft(r,e,t){var a=r.length;try{for(var n=0;n<a&&!(n in r&&e.call(t||r,r[n],n,r)===-1);n++);}catch{}}function Ni(r,e,t){if(r){if(r[kS])return r[kS](e,t);var a=r.length,n=t||0;try{for(var i=Math.max(n>=0?n:a-Math.abs(n),0);i<a;i++)if(i in r&&r[i]===e)return i}catch{}}return-1}function co(r,e,t){var a;if(r){if(r[FS])return r[FS](e,t);var n=r.length,i=t||r;a=new Array(n);try{for(var s=0;s<n;s++)s in r&&(a[s]=e.call(i,r[s],r))}catch{}}return a}function Nu(r,e,t){var a;if(r){if(r[US])return r[US](e,t);var n=r.length,i=0;if(arguments.length>=3)a=arguments[2];else{for(;i<n&&!(i in r);)i++;a=r[i++]}for(;i<n;)i in r&&(a=e(a,r[i],i,r)),i++}return a}function Or(r){return r&&(r=jT&&r[py]?r[py]():r.replace?r.replace(/^\s+|\s+$/g,""):r),r}var KS=!{toString:null}.propertyIsEnumerable("toString"),uy=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];function _n(r){var e=typeof r;if(e!==Fn&&(e!==Ha||r===null)&&dl("objKeys called on non-object"),!KS&&VS)return VS(r);var t=[];for(var a in r)r&&vs.call(r,a)&&t.push(a);if(KS)for(var n=uy.length,i=0;i<n;i++)r&&vs.call(r,uy[i])&&t.push(uy[i]);return t}function bs(r,e,t,a){if(jS)try{var n={enumerable:!0,configurable:!0};return t&&(n.get=t),a&&(n.set=a),jS(r,e,n),!0}catch{}return!1}function Qr(){var r=Date;return r.now?r.now():new r().getTime()}function Ot(r){return fl(r)?r.name:""}function Bt(r,e,t,a,n){var i=t;return r&&(i=r[e],i!==t&&(!n||n(i))&&(!a||a(t))&&(i=t,r[e]=i)),i}function Zr(r,e,t){var a;return r?(a=r[e],!a&&Le(a)&&(a=Ir(t)?{}:t,r[e]=a)):a=Ir(t)?{}:t,a}function Pu(r){return!r}function yl(r){return!!r}function ga(r){throw new Error(r)}function gy(r,e,t){if(r&&e&&r!==e&&jn(r)&&jn(e)){var a=function(i){if(pt(i)){var s=e[i];vt(s)?(!t||t(i,!0,e,r))&&(r[i]=function(o){return function(){var l=arguments;return e[o].apply(e,l)}}(i)):(!t||t(i,!1,e,r))&&(Mc(r,i)&&delete r[i],bs(r,i,function(){return e[i]},function(o){e[i]=o})||(r[i]=s))}};for(var n in e)a(n)}return r}function vy(r){return function(){function e(){var t=this;r&&Xt(r,function(a,n){t[a]=n})}return e}()}function Cu(r){return r&&cl&&(r=Za(cl({},r))),r}var ZS="window",tw="document",rw="documentMode",aw="navigator",nw="history",iw="location",sw="console",ow="performance",JS="JSON",lw="crypto",cw="msCrypto",mw="ReactNative",Ny="msie",Py="trident/",_y=null,by=null,dw=!1,xl=null,Sy=null;function eN(r,e){var t=!1;if(r){try{if(t=e in r,!t){var a=r[Pr];a&&(t=e in a)}}catch{}if(!t)try{var n=new r;t=!Ir(n[e])}catch{}}return t}function zr(r){var e=vn();return e&&e[r]?e[r]:r===ZS&&mo()?window:null}function mo(){return Boolean(typeof window===Ha&&window)}function Pi(){return mo()?window:zr(ZS)}function Ru(){return Boolean(typeof document===Ha&&document)}function Fr(){return Ru()?document:zr(tw)}function Cy(){return Boolean(typeof navigator===Ha&&navigator)}function va(){return Cy()?navigator:zr(aw)}function tN(){return Boolean(typeof history===Ha&&history)}function Ry(){return tN()?history:zr(nw)}function Ja(r){if(r&&dw){var e=zr("__mockLocation");if(e)return e}return typeof location===Ha&&location?location:zr(iw)}function Ey(){return typeof console!==Un?console:zr(sw)}function en(){return zr(ow)}function Gn(){return Boolean(typeof JSON===Ha&&JSON||zr(JS)!==null)}function Jr(){return Gn()?JSON||zr(JS):null}function Ty(){return zr(lw)}function wy(){return zr(cw)}function Iy(){var r=va();return r&&r.product?r.product===mw:!1}function uo(){var r=va();if(r&&(r.userAgent!==by||_y===null)){by=r.userAgent;var e=(by||"").toLowerCase();_y=Wr(e,Ny)||Wr(e,Py)}return _y}function gl(r){if(r===void 0&&(r=null),!r){var e=va()||{};r=e?(e.userAgent||"").toLowerCase():""}var t=(r||"").toLowerCase();if(Wr(t,Ny)){var a=Fr()||{};return Math.max(parseInt(t.split(Ny)[1]),a[rw]||0)}else if(Wr(t,Py)){var n=parseInt(t.split(Py)[1]);if(n)return n+4}return null}function xt(r){var e=Object[Pr].toString.call(r),t="";return e==="[object Error]"?t="{ stack: '"+r.stack+"', message: '"+r.message+"', name: '"+r.name+"'":Gn()&&(t=Jr().stringify(r)),e+t}function po(){return Sy===null&&(Sy=Cy()&&Boolean(va().sendBeacon)),Sy}function Eu(r){var e=!1;try{var t=zr("fetch");e=!!t;var a=zr("Request");e&&r&&a&&(e=eN(a,"keepalive"))}catch{}return e}function Tu(){return xl===null&&(xl=typeof XDomainRequest<"u",xl&&fo()&&(xl=xl&&!eN(zr("XMLHttpRequest"),"withCredentials"))),xl}function fo(){var r=!1;try{var e=zr("XMLHttpRequest");r=!!e}catch{}return r}var My=["eventsSent","eventsDiscarded","eventsSendRequest","perfEvent"],Iu=null,wu;function uw(r,e){return function(){var t=arguments,a=Ay(e);if(a){var n=a.listener;n&&n[r]&&n[r].apply(n,t)}}}function pw(){var r=zr("Microsoft");return r&&(Iu=r.ApplicationInsights),Iu}function Ay(r){var e=Iu;return!e&&r.disableDbgExt!==!0&&(e=Iu||pw()),e?e.ChromeDbgExt:null}function rN(r){if(!wu){wu={};for(var e=0;e<My.length;e++)wu[My[e]]=uw(My[e],r)}return wu}var fw="AI (Internal): ",hw="AI: ",yw="AITR_",xw="errorToConsole",gw="warnToConsole";function aN(r){return r?'"'+r.replace(/\"/g,"")+'"':""}function nN(r,e){var t=Ey();if(t){var a="log";t[r]&&(a=r),vt(t[a])&&t[a](e)}}var Gi=function(){function r(e,t,a,n){a===void 0&&(a=!1);var i=this;i.messageId=e,i.message=(a?hw:fw)+e;var s="";Gn()&&(s=Jr().stringify(n));var o=(t?" message:"+aN(t):"")+(n?" props:"+aN(s):"");i.message+=o}return r.dataType="MessageData",r}();function Ki(r,e){return(r||{}).logger||new vl(e)}var vl=function(){function r(e){this.identifier="DiagnosticLogger",this.queue=[];var t=0,a={};zt(r,this,function(n){Le(e)&&(e={}),n.consoleLoggingLevel=function(){return i("loggingLevelConsole",0)},n.telemetryLoggingLevel=function(){return i("loggingLevelTelemetry",1)},n.maxInternalMessageLimit=function(){return i("maxMessageLimit",25)},n.enableDebugExceptions=function(){return i("enableDebugExceptions",!1)},n.throwInternal=function(l,c,p,M,S){S===void 0&&(S=!1);var O=new Gi(c,p,S,M);if(n.enableDebugExceptions())throw O;var E=l===Oe.CRITICAL?xw:gw;if(Ir(O.message))o("throw"+(l===Oe.CRITICAL?"Critical":"Warning"),O);else{var q=n.consoleLoggingLevel();if(S){var C=+O.messageId;!a[C]&&q>=l&&(n[E](O.message),a[C]=!0)}else q>=l&&n[E](O.message);n.logInternalMessage(l,O)}},n.warnToConsole=function(l){nN("warn",l),o("warning",l)},n.errorToConsole=function(l){nN("error",l),o("error",l)},n.resetInternalMessageCount=function(){t=0,a={}},n.logInternalMessage=function(l,c){if(!s()){var p=!0,M=yw+c.messageId;if(a[M]?p=!1:a[M]=!0,p&&(l<=n.telemetryLoggingLevel()&&(n.queue.push(c),t++,o(l===Oe.CRITICAL?"error":"warn",c)),t===n.maxInternalMessageLimit())){var S="Internal events throttle limit per PageView reached for this app.",O=new Gi(we.MessageLimitPerPVExceeded,S,!1);n.queue.push(O),l===Oe.CRITICAL?n.errorToConsole(S):n.warnToConsole(S)}}};function i(l,c){var p=e[l];return Le(p)?c:p}function s(){return t>=n.maxInternalMessageLimit()}function o(l,c){var p=Ay(e);p&&p.diagLog&&p.diagLog(l,c)}})}return r}();var _l="ctx",vw=null,Ac=function(){function r(e,t,a){var n=this,i=!1;if(n.start=Qr(),n.name=e,n.isAsync=a,n.isChildEvt=function(){return!1},vt(t)){var s;i=bs(n,"payload",function(){return!s&&vt(t)&&(s=t(),t=null),s})}n.getCtx=function(o){return o?o===r.ParentContextKey||o===r.ChildrenContextKey?n[o]:(n[_l]||{})[o]:null},n.setCtx=function(o,l){if(o)if(o===r.ParentContextKey)n[o]||(n.isChildEvt=function(){return!0}),n[o]=l;else if(o===r.ChildrenContextKey)n[o]=l;else{var c=n[_l]=n[_l]||{};c[o]=l}},n.complete=function(){var o=0,l=n.getCtx(r.ChildrenContextKey);if(Yr(l))for(var c=0;c<l.length;c++){var p=l[c];p&&(o+=p.time)}n.time=Qr()-n.start,n.exTime=n.time-o,n.complete=function(){},!i&&vt(t)&&(n.payload=t())}}return r.ParentContextKey="parent",r.ChildrenContextKey="childEvts",r}();var Oy=function(){function r(e){this.ctx={},zt(r,this,function(t){t.create=function(a,n,i){return new Ac(a,n,i)},t.fire=function(a){a&&(a.complete(),e&&vt(e.perfEvent)&&e.perfEvent(a))},t.setCtx=function(a,n){if(a){var i=t[_l]=t[_l]||{};i[a]=n}},t.getCtx=function(a){return(t[_l]||{})[a]}})}return r}();var By="CoreUtils.doPerf";function Ci(r,e,t,a,n){if(r){var i=r;if(vt(i.getPerfMgr)&&(i=i.getPerfMgr()),i){var s=void 0,o=i.getCtx(By);try{if(s=i.create(e(),a,n),s){if(o&&s.setCtx&&(s.setCtx(Ac.ParentContextKey,o),o.getCtx&&o.setCtx)){var l=o.getCtx(Ac.ChildrenContextKey);l||(l=[],o.setCtx(Ac.ChildrenContextKey,l)),l.push(s)}return i.setCtx(By,s),t(s)}}catch(c){s&&s.setCtx&&s.setCtx("exception",c)}finally{s&&i.fire(s),i.setCtx(By,o)}}}return t()}function zy(){return vw}var iN=function(){function r(e,t){var a=this,n=null,i=vt(e.processTelemetry),s=vt(e.setNextPlugin);a._hasRun=!1,a.getPlugin=function(){return e},a.getNext=function(){return n},a.setNext=function(o){n=o},a.processTelemetry=function(o,l){l||(l=t);var c=e?e.identifier:"TelemetryPluginChain";Ci(l?l.core():null,function(){return c+":processTelemetry"},function(){if(e&&i){a._hasRun=!0;try{l.setNext(n),s&&e.setNextPlugin(n),n&&(n._hasRun=!1),e.processTelemetry(o,l)}catch(M){var p=n&&n._hasRun;(!n||!p)&&l.diagLog().throwInternal(Oe.CRITICAL,we.PluginException,"Plugin ["+e.identifier+"] failed during processTelemetry - "+xt(M)),n&&!p&&n.processTelemetry(o,l)}}else n&&(a._hasRun=!0,n.processTelemetry(o,l))},function(){return{item:o}},!o.sync)}}return r}();function Ly(r,e){var t=[];if(r&&r.length>0)for(var a=null,n=0;n<r.length;n++){var i=r[n];if(i&&vt(i.processTelemetry)){var s=new iN(i,e);t.push(s),a&&a.setNext(s),a=s}}return t.length>0?t[0]:null}function _w(r,e,t){var a=[],n=!t;if(r)for(;r;){var i=r.getPlugin();(n||i===t)&&(n=!0,a.push(i)),r=r.getNext()}return n||a.push(t),Ly(a,e)}function bw(r,e,t){var a=r,n=!1;return t&&r&&(a=[],ft(r,function(i){(n||i===t)&&(n=!0,a.push(i))})),t&&!n&&(a||(a=[]),a.push(t)),Ly(a,e)}var Xi=function(){function r(e,t,a,n){var i=this,s=null;n!==null&&(e&&vt(e.getPlugin)?s=_w(e,i,n||e.getPlugin()):n?s=bw(e,i,n):Ir(n)&&(s=Ly(e,i))),i.core=function(){return a},i.diagLog=function(){return Ki(a,t)},i.getCfg=function(){return t},i.getExtCfg=function(o,l){l===void 0&&(l={});var c;if(t){var p=t.extensionConfig;p&&o&&(c=p[o])}return c||l},i.getConfig=function(o,l,c){c===void 0&&(c=!1);var p,M=i.getExtCfg(o,null);return M&&!Le(M[l])?p=M[l]:t&&!Le(t[l])&&(p=t[l]),Le(p)?c:p},i.hasNext=function(){return s!=null},i.getNext=function(){return s},i.setNext=function(o){s=o},i.processNext=function(o){var l=s;l&&(s=l.getNext(),l.processTelemetry(o,i))},i.createNew=function(o,l){return o===void 0&&(o=null),new r(o||s,t,a,l)}}return r}();var sN="iKey",Mu="extensionConfig";var Au="getPlugin",Kn=function(){function r(){var e=this,t=!1,a=null,n=null;e.core=null,e.diagLog=function(i){return e._getTelCtx(i).diagLog()},e.isInitialized=function(){return t},e.setInitialized=function(i){t=i},e.setNextPlugin=function(i){n=i},e.processNext=function(i,s){s?s.processNext(i):n&&vt(n.processTelemetry)&&n.processTelemetry(i,null)},e._getTelCtx=function(i){i===void 0&&(i=null);var s=i;if(!s){var o=a||new Xi(null,{},e.core);n&&n[Au]?s=o.createNew(null,n[Au]):s=o.createNew(null,n)}return s},e._baseTelInit=function(i,s,o,l){i&&Bt(i,Mu,[],null,Le),!l&&s&&(l=s.getProcessTelContext().getNext());var c=n;n&&n[Au]&&(c=n[Au]()),e.core=s,a=new Xi(l,i,s,c),t=!0}}return r.prototype.initialize=function(e,t,a,n){this._baseTelInit(e,t,a,n)},r}();var qy="processTelemetry",oN="priority",lN="setNextPlugin",cN="isInitialized";function Bc(r,e){for(var t=[],a=null,n=r.getNext();n;){var i=n.getPlugin();i&&(a&&vt(a[lN])&&vt(i[qy])&&a[lN](i),(!vt(i[cN])||!i[cN]())&&t.push(i),a=i,n=n.getNext())}ft(t,function(s){s.initialize(r.getCfg(),r.core(),e,r.getNext())})}function Hy(r){return r.sort(function(e,t){var a=0,n=vt(t[qy]);return vt(e[qy])?a=n?e[oN]-t[oN]:1:n&&(a=-1),a})}var Dy=500,Sw="Channel has invalid priority",mN=function(r){Nt(e,r);function e(){var t=r.call(this)||this;t.identifier="ChannelControllerPlugin",t.priority=Dy;var a;zt(e,t,function(o,l){o.setNextPlugin=function(c){},o.processTelemetry=function(c,p){a&&ft(a,function(M){if(M.length>0){var S=t._getTelCtx(p).createNew(M);S.processNext(c)}})},o.getChannelControls=function(){return a},o.initialize=function(c,p,M){o.isInitialized()||(l.initialize(c,p,M),s((c||{}).channels,M),ft(a,function(S){return Bc(new Xi(S,c,p),M)}))}});function n(o){ft(o,function(l){l.priority<Dy&&ga(Sw+l.identifier)})}function i(o){o&&o.length>0&&(o=o.sort(function(l,c){return l.priority-c.priority}),n(o),a.push(o))}function s(o,l){if(a=[],o&&ft(o,function(p){return i(p)}),l){var c=[];ft(l,function(p){p.priority>Dy&&c.push(p)}),i(c)}}return t}return e._staticInit=function(){var t=e.prototype;bs(t,"ChannelControls",t.getChannelControls),bs(t,"channelQueue",t.getChannelControls)}(),e}(Kn);var dN="toGMTString",uN="toUTCString",Vy="cookie",ky="expires",Uy="enabled",pN="isCookieUseDisabled",fN="disableCookiesUsage",Ss="_ckMgr",Xn="",Bu=null,Fy=null,hN=null,Oc=Fr(),yN={},zu={};function Nw(r,e){var t=ho[Ss]||zu[Ss];return t||(t=ho[Ss]=ho(r,e),zu[Ss]=t),t}function Ou(r){return r?r.isEnabled():!0}function Pw(r){var e=r.cookieCfg=r.cookieCfg||{};if(Bt(e,"domain",r.cookieDomain,hy,Le),Bt(e,"path",r.cookiePath||"/",null,Le),Le(e[Uy])){var t=void 0;Ir(r[pN])||(t=!r[pN]),Ir(r[fN])||(t=!r[fN]),e[Uy]=t}return e}function yo(r,e){var t;if(r)t=r.getCookieMgr();else if(e){var a=e.cookieCfg;a[Ss]?t=a[Ss]:t=ho(e)}return t||(t=Nw(e,(r||{}).logger)),t}function ho(r,e){var t=Pw(r||zu),a=t.path||"/",n=t.domain,i=t[Uy]!==!1,s={isEnabled:function(){var o=i&&jy(e),l=zu[Ss];return o&&l&&s!==l&&(o=Ou(l)),o},setEnabled:function(o){i=o!==!1},set:function(o,l,c,p,M){var S=!1;if(Ou(s)){var O={},E=Or(l||Xn),q=E.indexOf(";");if(q!==-1&&(E=Or(l.substring(0,q)),O=_N(l.substring(q+1))),Bt(O,"domain",p||n,yl,Ir),!Le(c)){var C=uo();if(Ir(O[ky])){var W=Qr(),ae=W+c*1e3;if(ae>0){var Ce=new Date;Ce.setTime(ae),Bt(O,ky,xN(Ce,C?dN:uN)||xN(Ce,C?dN:uN)||Xn,yl)}}C||Bt(O,"max-age",Xn+c,null,Ir)}var et=Ja();et&&et.protocol==="https:"&&(Bt(O,"secure",null,null,Ir),Fy===null&&(Fy=!Gy((va()||{}).userAgent)),Fy&&Bt(O,"SameSite","None",null,Ir)),Bt(O,"path",M||a,null,Ir);var gt=t.setCookie||vN;gt(o,gN(E,O)),S=!0}return S},get:function(o){var l=Xn;return Ou(s)&&(l=(t.getCookie||Cw)(o)),l},del:function(o,l){var c=!1;return Ou(s)&&(c=s.purge(o,l)),c},purge:function(o,l){var c,p=!1;if(jy(e)){var M=(c={},c.path=l||"/",c[ky]="Thu, 01 Jan 1970 00:00:01 GMT",c);uo()||(M["max-age"]="0");var S=t.delCookie||vN;S(o,gN(Xn,M)),p=!0}return p}};return s[Ss]=s,s}function jy(r){if(Bu===null){Bu=!1;try{var e=Oc||{};Bu=e[Vy]!==void 0}catch(t){r&&r.throwInternal(Oe.WARNING,we.CannotAccessCookie,"Cannot access document.cookie - "+Ot(t),{exception:xt(t)})}}return Bu}function _N(r){var e={};if(r&&r.length){var t=Or(r).split(";");ft(t,function(a){if(a=Or(a||Xn),a){var n=a.indexOf("=");n===-1?e[a]=null:e[Or(a.substring(0,n))]=Or(a.substring(n+1))}})}return e}function xN(r,e){return vt(r[e])?r[e]():null}function gN(r,e){var t=r||Xn;return Xt(e,function(a,n){t+="; "+a+(Le(n)?Xn:"="+n)}),t}function Cw(r){var e=Xn;if(Oc){var t=Oc[Vy]||Xn;hN!==t&&(yN=_N(t),hN=t),e=Or(yN[r]||Xn)}return e}function vN(r,e){Oc&&(Oc[Vy]=r+"="+e)}function Gy(r){return pt(r)?!!(Wr(r,"CPU iPhone OS 12")||Wr(r,"iPad; CPU OS 12")||Wr(r,"Macintosh; Intel Mac OS X 10_14")&&Wr(r,"Version/")&&Wr(r,"Safari")||Wr(r,"Macintosh; Intel Mac OS X 10_14")&&xy(r,"AppleWebKit/605.1.15 (KHTML, like Gecko)")||Wr(r,"Chrome/5")||Wr(r,"Chrome/6")||Wr(r,"UnrealEngine")&&!Wr(r,"Chrome")||Wr(r,"UCBrowser/12")||Wr(r,"UCBrowser/11")):!1}var Rw="Extensions must provide callback to initialize",bN="_notificationManager";function Ew(r,e){return new Oy(e)}var SN=function(){function r(){var e=!1,t,a,n,i,s;zt(r,this,function(o){o._extensions=new Array,a=new mN,o.logger=new vl({loggingLevelConsole:Oe.CRITICAL}),t=[],o.isInitialized=function(){return e},o.initialize=function(l,c,p,M){o.isInitialized()&&ga("Core should not be initialized more than once"),(!l||Le(l.instrumentationKey))&&ga("Please provide instrumentation key"),n=M,o[bN]=M,o.config=l||{},M&&o.config.disableDbgExt!==!0&&M.addNotificationListener(rN(l)),o.config.enablePerfMgr&&Bt(o.config,"createPerfMgr",Ew),l.extensions=Le(l.extensions)?[]:l.extensions;var S=Zr(l,Mu);S.NotificationManager=M,p&&(o.logger=p);var O=[];O.push.apply(O,yu(yu([],c,!1),l.extensions,!1)),O=Hy(O);var E=[],q=[],C={};ft(O,function(W){(Le(W)||Le(W.initialize))&&ga(Rw);var ae=W.priority,Ce=W.identifier;W&&ae&&(Le(C[ae])?C[ae]=Ce:p.warnToConsole("Two extensions have same priority #"+ae+" - "+C[ae]+", "+Ce)),!ae||ae<a.priority?E.push(W):q.push(W)}),O.push(a),E.push(a),O=Hy(O),o._extensions=O,Bc(new Xi([a],l,o),O),Bc(new Xi(E,l,o),O),o._extensions=E,o.getTransmissionControls().length===0&&ga("No channels available"),e=!0,o.releaseQueue()},o.getTransmissionControls=function(){return a.getChannelControls()},o.track=function(l){Bt(l,sN,o.config.instrumentationKey,null,Pu),Bt(l,"time",Pa(new Date),null,Pu),Bt(l,"ver","4.0",null,Le),o.isInitialized()?o.getProcessTelContext().processNext(l):t.push(l)},o.getProcessTelContext=function(){var l=o._extensions,c=l;return(!l||l.length===0)&&(c=[a]),new Xi(c,o.config,o)},o.getNotifyMgr=function(){return n||(n=ul({addNotificationListener:function(l){},removeNotificationListener:function(l){},eventsSent:function(l){},eventsDiscarded:function(l,c){},eventsSendRequest:function(l,c){}}),o[bN]=n),n},o.getCookieMgr=function(){return s||(s=ho(o.config,o.logger)),s},o.setCookieMgr=function(l){s=l},o.getPerfMgr=function(){return i||o.config&&o.config.enablePerfMgr&&vt(o.config.createPerfMgr)&&(i=o.config.createPerfMgr(o,o.getNotifyMgr())),i||zy()},o.setPerfMgr=function(l){i=l},o.eventCnt=function(){return t.length},o.releaseQueue=function(){t.length>0&&(ft(t,function(l){o.getProcessTelContext().processNext(l)}),t=[])}})}return r}();var NN=function(){function r(e){this.listeners=[];var t=!!(e||{}).perfEvtsSendAll;zt(r,this,function(a){a.addNotificationListener=function(n){a.listeners.push(n)},a.removeNotificationListener=function(n){for(var i=Ni(a.listeners,n);i>-1;)a.listeners.splice(i,1),i=Ni(a.listeners,n)},a.eventsSent=function(n){ft(a.listeners,function(i){i&&i.eventsSent&&setTimeout(function(){return i.eventsSent(n)},0)})},a.eventsDiscarded=function(n,i){ft(a.listeners,function(s){s&&s.eventsDiscarded&&setTimeout(function(){return s.eventsDiscarded(n,i)},0)})},a.eventsSendRequest=function(n,i){ft(a.listeners,function(s){if(s&&s.eventsSendRequest)if(i)setTimeout(function(){return s.eventsSendRequest(n,i)},0);else try{s.eventsSendRequest(n,i)}catch{}})},a.perfEvent=function(n){n&&(t||!n.isChildEvt())&&ft(a.listeners,function(i){if(i&&i.perfEvent)if(n.isAsync)setTimeout(function(){return i.perfEvent(n)},0);else try{i.perfEvent(n)}catch{}})}})}return r}();var Ky=function(r){Nt(e,r);function e(){var t=r.call(this)||this,a=0;return zt(e,t,function(n,i){n.initialize=function(l,c,p,M){i.initialize(l,c,p||new vl(l),M||new NN(l))},n.track=function(l){Ci(n.getPerfMgr(),function(){return"AppInsightsCore:track"},function(){l===null&&(o(l),ga("Invalid telemetry item")),s(l),i.track(l)},function(){return{item:l}},!l.sync)},n.addNotificationListener=function(l){var c=n.getNotifyMgr();c&&c.addNotificationListener(l)},n.removeNotificationListener=function(l){var c=n.getNotifyMgr();c&&c.removeNotificationListener(l)},n.pollInternalLogs=function(l){var c=n.config.diagnosticLogInterval;return(!c||!(c>0))&&(c=1e4),a&&n.stopPollingInternalLogs(),a=setInterval(function(){var p=n.logger?n.logger.queue:[];ft(p,function(M){var S={name:l||"InternalMessageId: "+M.messageId,iKey:n.config.instrumentationKey,time:Pa(new Date),baseType:Gi.dataType,baseData:{message:M.message}};n.track(S)}),p.length=0},c),a},n.stopPollingInternalLogs=function(){!a||(clearInterval(a),a=0)};function s(l){if(Le(l.name))throw o(l),Error("telemetry name required")}function o(l){var c=n.getNotifyMgr();c&&c.eventsDiscarded([l],AS.InvalidEvent)}}),t}return e}(SN);var PN=4294967296,xo=4294967295,CN=!1,zc=123456789,Lc=987654321;function Tw(r){r<0&&(r>>>=0),zc=123456789+r&xo,Lc=987654321-r&xo,CN=!0}function ww(){try{var r=Qr()&2147483647;Tw((Math.random()*PN^r)+r)}catch{}}function bl(r){var e,t=Ty()||wy();return t&&t.getRandomValues?e=t.getRandomValues(new Uint32Array(1))[0]&xo:uo()?(CN||ww(),e=RN()&xo):e=Math.floor(PN*Math.random()|0),r||(e>>>=0),e}function RN(r){Lc=36969*(Lc&65535)+(Lc>>16)&xo,zc=18e3*(zc&65535)+(zc>>16)&xo;var e=(Lc<<16)+(zc&65535)>>>0&xo|0;return r||(e>>>=0),e}var EN="visibilitychange",TN="pagehide";function Lu(r,e){var t=!1,a=Pi();a&&(t=Vn(a,r,e),t=Vn(a.body,r,e)||t);var n=Fr();return n&&(t=Vn(n,r,e)||t),t}function Xy(r,e,t){var a=!1;if(e&&r&&Yr(r)){var n=[];ft(r,function(i){pt(i)&&(!t||Ni(t,i)===-1?a=Lu(i,e)||a:n.push(i))}),!a&&n.length>0&&(a=Xy(n,e))}return a}function $y(r,e){return Xy(["beforeunload","unload","pagehide"],r,e)}function qc(r,e){function t(n){var i=Fr();r&&i&&i.visibilityState==="hidden"&&r(n)}var a=!1;return(!e||Ni(e,TN)===-1)&&(a=Lu(TN,r)),(!e||Ni(e,EN)===-1)&&(a=Lu(EN,t)||a),!a&&e&&(a=qc(r)),a}function Sl(r){r===void 0&&(r=22);for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t=bl()>>>0,a=0,n="";n.length<r;)a++,n+=e.charAt(t&63),t>>>=6,a===5&&(t=(bl()<<2&4294967295|t&3)>>>0,a=0);return n}function Da(){for(var r=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],e="",t,a=0;a<4;a++)t=bl(),e+=r[t&15]+r[t>>4&15]+r[t>>8&15]+r[t>>12&15]+r[t>>16&15]+r[t>>20&15]+r[t>>24&15]+r[t>>28&15];var n=r[8+(bl()&3)|0];return e.substr(0,8)+e.substr(9,4)+"4"+e.substr(13,3)+n+e.substr(16,3)+e.substr(19,12)}var IN="_aiHooks",MN=["req","rsp","hkErr","fnErr"];function Yy(r,e){if(r)for(var t=0;t<r.length&&!e(r[t],t);t++);}function Wy(r,e,t,a,n){n>=0&&n<=2&&Yy(r,function(i,s){var o=i.cbks,l=o[MN[n]];if(l){e.ctx=function(){var M=a[s]=a[s]||{};return M};try{l.apply(e.inst,t)}catch(M){var c=e.err;try{var p=o[MN[2]];p&&(e.err=M,p.apply(e.inst,t))}catch{}finally{e.err=c}}}})}function Bw(r){return function(){var e=this,t=arguments,a=r.h,n={name:r.n,inst:e,ctx:null,set:l},i=[],s=o([n],t);function o(p,M){return Yy(M,function(S){p.push(S)}),p}function l(p,M){t=o([],t),t[p]=M,s=o([n],t)}Wy(a,n,s,i,0);var c=r.f;try{n.rslt=c.apply(e,t)}catch(p){throw n.err=p,Wy(a,n,s,i,3),p}return Wy(a,n,s,i,1),n.rslt}}function AN(r,e,t){var a=null;return r&&(Mc(r,e)?a=r:t&&(a=AN(QS(r),e,!1))),a}function Qy(r,e,t){return r?Hc(r[Pr],e,t,!1):null}function Hc(r,e,t,a){if(a===void 0&&(a=!0),r&&e&&t){var n=AN(r,e,a);if(n){var i=n[e];if(typeof i===Fn){var s=i[IN];if(!s){s={i:0,n:e,f:i,h:[]};var o=Bw(s);o[IN]=s,n[e]=o}var l={id:s.i,cbks:t,rm:function(){var c=this.id;Yy(s.h,function(p,M){if(p.id===c)return s.h.splice(M,1),1})}};return s.i++,s.h.push(l),l}}}return null}var Zt={requestContextHeader:"Request-Context",requestContextTargetKey:"appId",requestContextAppIdFormat:"appId=cid-v1:",requestIdHeader:"Request-Id",traceParentHeader:"traceparent",traceStateHeader:"tracestate",sdkContextHeader:"Sdk-Context",sdkContextHeaderAppIdRequest:"appId",requestContextHeaderLowerCase:"request-context"};function Zy(r,e,t){var a=e.length,n=BN(r,e);if(n.length!==a){for(var i=0,s=n;t[s]!==void 0;)i++,s=n.substring(0,150-3)+ON(i);n=s}return n}function BN(r,e){var t;return e&&(e=Or(e.toString()),e.length>150&&(t=e.substring(0,150),r&&r.throwInternal(Oe.WARNING,we.NameTooLong,"name is too long. It has been truncated to "+150+" characters.",{name:e},!0))),t||e}function Jt(r,e,t){t===void 0&&(t=1024);var a;return e&&(t=t||1024,e=Or(e),e.toString().length>t&&(a=e.toString().substring(0,t),r&&r.throwInternal(Oe.WARNING,we.StringValueTooLong,"string value is too long. It has been truncated to "+t+" characters.",{value:e},!0))),a||e}function $i(r,e){return tx(r,e,2048,we.UrlTooLong)}function Dc(r,e){var t;return e&&e.length>32768&&(t=e.substring(0,32768),r&&r.throwInternal(Oe.WARNING,we.MessageTruncated,"message is too long, it has been truncated to "+32768+" characters.",{message:e},!0)),t||e}function Jy(r,e){var t;if(e){var a=""+e;a.length>32768&&(t=a.substring(0,32768),r&&r.throwInternal(Oe.WARNING,we.ExceptionTruncated,"exception is too long, it has been truncated to "+32768+" characters.",{exception:e},!0))}return t||e}function Ca(r,e){if(e){var t={};Xt(e,function(a,n){if(jn(n)&&Gn())try{n=Jr().stringify(n)}catch(i){r&&r.throwInternal(Oe.WARNING,we.CannotSerializeObjectNonSerializable,"custom property is not valid",{exception:i},!0)}n=Jt(r,n,8192),a=Zy(r,a,t),t[a]=n}),e=t}return e}function Ra(r,e){if(e){var t={};Xt(e,function(a,n){a=Zy(r,a,t),t[a]=n}),e=t}return e}function ex(r,e){return e&&tx(r,e,128,we.IdTooLong).toString()}function tx(r,e,t,a){var n;return e&&(e=Or(e),e.length>t&&(n=e.substring(0,t),r&&r.throwInternal(Oe.WARNING,a,"input is too long, it has been truncated to "+t+" characters.",{data:e},!0))),n||e}function ON(r){var e="00"+r;return e.substr(e.length-3)}function go(r){var e=null;if(vt(Event))e=new Event(r);else{var t=Fr();t&&t.createEvent&&(e=t.createEvent("Event"),e.initEvent(r,!0,!0))}return e}function bn(r,e){return e===void 0&&(e=!1),r==null?e:r.toString().toLowerCase()==="true"}function tn(r){(isNaN(r)||r<0)&&(r=0),r=Math.round(r);var e=""+r%1e3,t=""+Math.floor(r/1e3)%60,a=""+Math.floor(r/(1e3*60))%60,n=""+Math.floor(r/(1e3*60*60))%24,i=Math.floor(r/(1e3*60*60*24));return e=e.length===1?"00"+e:e.length===2?"0"+e:e,t=t.length<2?"0"+t:t,a=a.length<2?"0"+a:a,n=n.length<2?"0"+n:n,(i>0?i+".":"")+n+":"+a+":"+t+"."+e}function rx(r,e){var t=null;return ft(r,function(a){if(a.identifier===e)return t=a,-1}),t}function ax(r,e,t,a,n){return!n&&pt(r)&&(r==="Script error."||r==="Script error")}var $n="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",Nl="sampleRate",Pl="ProcessLegacy",kc="http.method",qu="https://dc.services.visualstudio.com",Ur="not_specified",Hu="iKey";var Ns;(function(r){r[r.LocalStorage=0]="LocalStorage",r[r.SessionStorage=1]="SessionStorage"})(Ns||(Ns={}));var Sn;(function(r){r[r.AI=0]="AI",r[r.AI_AND_W3C=1]="AI_AND_W3C",r[r.W3C=2]="W3C"})(Sn||(Sn={}));var vo=void 0,_o=void 0;function nx(){return ku()?Du(Ns.LocalStorage):null}function Du(r){try{if(Le(vn()))return null;var e=new Date,t=zr(r===Ns.LocalStorage?"localStorage":"sessionStorage");t.setItem(e.toString(),e.toString());var a=t.getItem(e.toString())!==e.toString();if(t.removeItem(e.toString()),!a)return t}catch{}return null}function ix(){return bo()?Du(Ns.SessionStorage):null}function sx(){vo=!1,_o=!1}function ku(){return vo===void 0&&(vo=!!Du(Ns.LocalStorage)),vo}function ox(r,e){var t=nx();if(t!==null)try{return t.getItem(e)}catch(a){vo=!1,r.throwInternal(Oe.WARNING,we.BrowserCannotReadLocalStorage,"Browser failed read of local storage. "+Ot(a),{exception:xt(a)})}return null}function lx(r,e,t){var a=nx();if(a!==null)try{return a.setItem(e,t),!0}catch(n){vo=!1,r.throwInternal(Oe.WARNING,we.BrowserCannotWriteLocalStorage,"Browser failed write to local storage. "+Ot(n),{exception:xt(n)})}return!1}function cx(r,e){var t=nx();if(t!==null)try{return t.removeItem(e),!0}catch(a){vo=!1,r.throwInternal(Oe.WARNING,we.BrowserFailedRemovalFromLocalStorage,"Browser failed removal of local storage item. "+Ot(a),{exception:xt(a)})}return!1}function bo(){return _o===void 0&&(_o=!!Du(Ns.SessionStorage)),_o}function Cl(r,e){var t=ix();if(t!==null)try{return t.getItem(e)}catch(a){_o=!1,r.throwInternal(Oe.WARNING,we.BrowserCannotReadSessionStorage,"Browser failed read of session storage. "+Ot(a),{exception:xt(a)})}return null}function Rl(r,e,t){var a=ix();if(a!==null)try{return a.setItem(e,t),!0}catch(n){_o=!1,r.throwInternal(Oe.WARNING,we.BrowserCannotWriteSessionStorage,"Browser failed write to session storage. "+Ot(n),{exception:xt(n)})}return!1}function mx(r,e){var t=ix();if(t!==null)try{return t.removeItem(e),!0}catch(a){_o=!1,r.throwInternal(Oe.WARNING,we.BrowserFailedRemovalFromSessionStorage,"Browser failed removal of session storage item. "+Ot(a),{exception:xt(a)})}return!1}var zN=Fr()||{},LN=0,Dw=[null,null,null,null,null];function Fc(r){var e=LN,t=Dw,a=t[e];return zN.createElement?t[e]||(a=t[e]=zN.createElement("a")):a={host:dx(r,!0)},a.href=r,e++,e>=t.length&&(e=0),LN=e,a}function Fu(r){var e,t=Fc(r);return t&&(e=t.href),e}function Uu(r,e){return r?r.toUpperCase()+" "+e:e}function dx(r,e){var t=ju(r,e)||"";if(t){var a=t.match(/(www[0-9]?\.)?(.[^/:]+)(\:[\d]+)?/i);if(a!=null&&a.length>3&&pt(a[2])&&a[2].length>0)return a[2]+(a[3]||"")}return t}function ju(r,e){var t=null;if(r){var a=r.match(/(\w*):\/\/(.[^/:]+)(\:[\d]+)?/i);if(a!=null&&a.length>2&&pt(a[2])&&a[2].length>0&&(t=a[2]||"",e&&a.length>2)){var n=(a[1]||"").toLowerCase(),i=a[3]||"";(n==="http"&&i===":80"||n==="https"&&i===":443")&&(i=""),t+=i}}return t}var Fw=["https://dc.services.visualstudio.com/v2/track","https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"];function So(r){return Fw.indexOf(r.toLowerCase())!==-1}var Wi={correlationIdPrefix:"cid-v1:",canIncludeCorrelationHeader:function(r,e,t){if(!e||r&&r.disableCorrelationHeaders)return!1;if(r&&r.correlationHeaderExcludePatterns){for(var a=0;a<r.correlationHeaderExcludePatterns.length;a++)if(r.correlationHeaderExcludePatterns[a].test(e))return!1}var n=Fc(e).host.toLowerCase();if(n&&(n.indexOf(":443")!==-1||n.indexOf(":80")!==-1)&&(n=(ju(e,!0)||"").toLowerCase()),(!r||!r.enableCorsCorrelation)&&n&&n!==t)return!1;var i=r&&r.correlationHeaderDomains;if(i){var s;if(ft(i,function(c){var p=new RegExp(c.toLowerCase().replace(/\\/g,"\\\\").replace(/\./g,"\\.").replace(/\*/g,".*"));s=s||p.test(n)}),!s)return!1}var o=r&&r.correlationHeaderExcludedDomains;if(!o||o.length===0)return!0;for(var a=0;a<o.length;a++){var l=new RegExp(o[a].toLowerCase().replace(/\\/g,"\\\\").replace(/\./g,"\\.").replace(/\*/g,".*"));if(l.test(n))return!1}return n&&n.length>0},getCorrelationContext:function(r){if(r){var e=Wi.getCorrelationContextValue(r,Zt.requestContextTargetKey);if(e&&e!==Wi.correlationIdPrefix)return e}},getCorrelationContextValue:function(r,e){if(r)for(var t=r.split(","),a=0;a<t.length;++a){var n=t[a].split("=");if(n.length===2&&n[0]===e)return n[1]}}};function qN(r,e,t,a){var n,i=a,s=a;if(e&&e.length>0){var o=Fc(e);if(n=o.host,!i)if(o.pathname!=null){var l=o.pathname.length===0?"/":o.pathname;l.charAt(0)!=="/"&&(l="/"+l),s=o.pathname,i=Jt(r,t?t+" "+l:l)}else i=Jt(r,e)}else n=a,i=a;return{target:n,name:i,data:s}}function El(){var r=en();if(r&&r.now&&r.timing){var e=r.now()+r.timing.navigationStart;if(e>0)return e}return Qr()}function ea(r,e){var t=null;return r!==0&&e!==0&&!Le(r)&&!Le(e)&&(t=e-r),t}var Uw=";",jw="=";function ux(r){if(!r)return{};var e=r.split(Uw),t=Nu(e,function(n,i){var s=i.split(jw);if(s.length===2){var o=s[0].toLowerCase(),l=s[1];n[o]=l}return n},{});if(_n(t).length>0){if(t.endpointsuffix){var a=t.location?t.location+".":"";t.ingestionendpoint=t.ingestionendpoint||"https://"+a+"dc."+t.endpointsuffix}t.ingestionendpoint=t.ingestionendpoint||qu}return t}var px=function(){function r(){}return r}();var fx=function(r){Nt(e,r);function e(){return r.call(this)||this}return e}(px);var HN=function(){function r(){this.ver=1,this.sampleRate=100,this.tags={}}return r}();var Vu=function(r){Nt(e,r);function e(t,a,n){var i=r.call(this)||this;return i.name=Jt(t,n)||Ur,i.data=a,i.time=Pa(new Date),i.aiDataContract={time:1,iKey:1,name:1,sampleRate:function(){return i.sampleRate===100?4:1},tags:1,data:1},i}return e}(HN);var Gu=function(){function r(){this.ver=2,this.properties={},this.measurements={}}return r}();var rn=function(r){Nt(e,r);function e(t,a,n,i){var s=r.call(this)||this;return s.aiDataContract={ver:1,name:1,properties:0,measurements:0},s.name=Jt(t,a)||Ur,s.properties=Ca(t,n),s.measurements=Ra(t,i),s}return e.envelopeType="Microsoft.ApplicationInsights.{0}.Event",e.dataType="EventData",e}(Gu);var DN=function(){function r(){}return r}();var kN=function(){function r(){this.ver=2,this.exceptions=[],this.properties={},this.measurements={}}return r}();var FN=function(){function r(){this.hasFullStack=!0,this.parsedStack=[]}return r}();var Vw="<no_method>",wl="error",Nn="stack",yx="stackDetails",UN="errorSrc",xx="message",GN="description";function gx(r,e){var t=r;return t&&!pt(t)&&(JSON&&JSON.stringify?(t=JSON.stringify(r),e&&(!t||t==="{}")&&(vt(r.toString)?t=r.toString():t=""+r)):t=""+r+" - (Missing JSON.stringify)"),t||""}function KN(r,e){var t=r;return r&&(t&&!pt(t)&&(t=r[xx]||r[GN]||t),t&&!pt(t)&&(t=gx(t,!0)),r.filename&&(t=t+" @"+(r.filename||"")+":"+(r.lineno||"?")+":"+(r.colno||"?"))),e&&e!=="String"&&e!=="Object"&&e!=="Error"&&(t||"").indexOf(e)===-1&&(t=e+": "+t),t||""}function Gw(r){try{if(jn(r))return"hasFullStack"in r&&"typeName"in r}catch{}return!1}function Kw(r){try{if(jn(r))return"ver"in r&&"exceptions"in r&&"properties"in r}catch{}return!1}function jN(r){return r&&r.src&&pt(r.src)&&r.obj&&Yr(r.obj)}function Tl(r){var e=r||"";pt(e)||(pt(e[Nn])?e=e[Nn]:e=""+e);var t=e.split(`
22
- `);return{src:e,obj:t}}function Xw(r){for(var e=[],t=r.split(`
23
- `),a=0;a<t.length;a++){var n=t[a];t[a+1]&&(n+="@"+t[a+1],a++),e.push(n)}return{src:r,obj:e}}function XN(r){var e=null;if(r)try{if(r[Nn])e=Tl(r[Nn]);else if(r[wl]&&r[wl][Nn])e=Tl(r[wl][Nn]);else if(r.exception&&r.exception[Nn])e=Tl(r.exception[Nn]);else if(jN(r))e=r;else if(jN(r[yx]))e=r[yx];else if(window&&window.opera&&r[xx])e=Xw(r.message);else if(pt(r))e=Tl(r);else{var t=r[xx]||r[GN]||"";pt(r[UN])&&(t&&(t+=`
24
- `),t+=" from "+r[UN]),t&&(e=Tl(t))}}catch(a){e=Tl(a)}return e||{src:"",obj:null}}function $w(r){var e="";return r&&(r.obj?ft(r.obj,function(t){e+=t+`
25
- `}):e=r.src||""),e}function Ww(r){var e,t=r.obj;if(t&&t.length>0){e=[];var a=0,n=0;ft(t,function(E){var q=E.toString();if(vx.regex.test(q)){var C=new vx(q,a++);n+=C.sizeInBytes,e.push(C)}});var i=32*1024;if(n>i)for(var s=0,o=e.length-1,l=0,c=s,p=o;s<o;){var M=e[s].sizeInBytes,S=e[o].sizeInBytes;if(l+=M+S,l>i){var O=p-c+1;e.splice(c,O);break}c=s,p=o,s++,o--}}return e}function Ku(r){var e="";if(r&&(e=r.typeName||r.name||"",!e))try{var t=/function (.{1,200})\(/,a=t.exec(r.constructor.toString());e=a&&a.length>1?a[1]:""}catch{}return e}function hx(r){if(r)try{if(!pt(r)){var e=Ku(r),t=gx(r,!1);return(!t||t==="{}")&&(r[wl]&&(r=r[wl],e=Ku(r)),t=gx(r,!0)),t.indexOf(e)!==0&&e!=="String"?e+":"+t:t}}catch{}return""+(r||"")}var pa=function(r){Nt(e,r);function e(t,a,n,i,s,o){var l=r.call(this)||this;return l.aiDataContract={ver:1,exceptions:1,severityLevel:0,properties:0,measurements:0},Kw(a)?(l.exceptions=a.exceptions,l.properties=a.properties,l.measurements=a.measurements,a.severityLevel&&(l.severityLevel=a.severityLevel),a.id&&(l.id=a.id),a.problemGroup&&(l.problemGroup=a.problemGroup),l.ver=2,Le(a.isManual)||(l.isManual=a.isManual)):(n||(n={}),l.exceptions=[new VN(t,a,n)],l.properties=Ca(t,n),l.measurements=Ra(t,i),s&&(l.severityLevel=s),o&&(l.id=o)),l}return e.CreateAutoException=function(t,a,n,i,s,o,l,c){var p=Ku(s||o||t);return{message:KN(t,p),url:a,lineNumber:n,columnNumber:i,error:hx(s||o||t),evt:hx(o||t),typeName:p,stackDetails:XN(l||s||o),errorSrc:c}},e.CreateFromInterface=function(t,a,n,i){var s=a.exceptions&&co(a.exceptions,function(l){return VN.CreateFromInterface(t,l)}),o=new e(t,Br(Br({},a),{exceptions:s}),n,i);return o},e.prototype.toInterface=function(){var t=this,a=t.exceptions,n=t.properties,i=t.measurements,s=t.severityLevel,o=t.problemGroup,l=t.id,c=t.isManual,p=a instanceof Array&&co(a,function(M){return M.toInterface()})||void 0;return{ver:"4.0",exceptions:p,severityLevel:s,properties:n,measurements:i,problemGroup:o,id:l,isManual:c}},e.CreateSimpleException=function(t,a,n,i,s,o){return{exceptions:[{hasFullStack:!0,message:t,stack:s,typeName:a}]}},e.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",e.dataType="ExceptionData",e.formatError=hx,e}(kN);var VN=function(r){Nt(e,r);function e(t,a,n){var i=r.call(this)||this;if(i.aiDataContract={id:0,outerId:0,typeName:1,message:1,hasFullStack:0,stack:0,parsedStack:2},Gw(a))i.typeName=a.typeName,i.message=a.message,i[Nn]=a[Nn],i.parsedStack=a.parsedStack,i.hasFullStack=a.hasFullStack;else{var s=a,o=s&&s.evt;fl(s)||(s=s[wl]||o||s),i.typeName=Jt(t,Ku(s))||Ur,i.message=Dc(t,KN(a||s,i.typeName))||Ur;var l=a[yx]||XN(a);i.parsedStack=Ww(l),i[Nn]=Jy(t,$w(l)),i.hasFullStack=Yr(i.parsedStack)&&i.parsedStack.length>0,n&&(n.typeName=n.typeName||i.typeName)}return i}return e.prototype.toInterface=function(){var t=this.parsedStack instanceof Array&&co(this.parsedStack,function(n){return n.toInterface()}),a={id:this.id,outerId:this.outerId,typeName:this.typeName,message:this.message,hasFullStack:this.hasFullStack,stack:this[Nn],parsedStack:t||void 0};return a},e.CreateFromInterface=function(t,a){var n=a.parsedStack instanceof Array&&co(a.parsedStack,function(s){return vx.CreateFromInterface(s)})||a.parsedStack,i=new e(t,Br(Br({},a),{parsedStack:n}));return i},e}(FN);var vx=function(r){Nt(e,r);function e(t,a){var n=r.call(this)||this;if(n.sizeInBytes=0,n.aiDataContract={level:1,method:1,assembly:0,fileName:0,line:0},typeof t=="string"){var i=t;n.level=a,n.method=Vw,n.assembly=Or(i),n.fileName="",n.line=0;var s=i.match(e.regex);s&&s.length>=5&&(n.method=Or(s[2])||n.method,n.fileName=Or(s[4]),n.line=parseInt(s[5])||0)}else n.level=t.level,n.method=t.method,n.assembly=t.assembly,n.fileName=t.fileName,n.line=t.line,n.sizeInBytes=0;return n.sizeInBytes+=n.method.length,n.sizeInBytes+=n.fileName.length,n.sizeInBytes+=n.assembly.length,n.sizeInBytes+=e.baseSize,n.sizeInBytes+=n.level.toString().length,n.sizeInBytes+=n.line.toString().length,n}return e.CreateFromInterface=function(t){return new e(t,null)},e.prototype.toInterface=function(){return{level:this.level,method:this.method,assembly:this.assembly,fileName:this.fileName,line:this.line}},e.regex=/^([\s]+at)?[\s]{0,50}([^\@\()]+?)[\s]{0,50}(\@|\()([^\(\n]+):([0-9]+):([0-9]+)(\)?)$/,e.baseSize=58,e}(DN);var $N=function(){function r(){this.ver=2,this.metrics=[],this.properties={},this.measurements={}}return r}();var Xu;(function(r){r[r.Measurement=0]="Measurement",r[r.Aggregation=1]="Aggregation"})(Xu||(Xu={}));var WN=function(){function r(){this.kind=Xu.Measurement}return r}();var YN=function(r){Nt(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.aiDataContract={name:1,kind:0,value:1,count:0,min:0,max:0,stdDev:0},t}return e}(WN);var an=function(r){Nt(e,r);function e(t,a,n,i,s,o,l,c,p){var M=r.call(this)||this;M.aiDataContract={ver:1,metrics:1,properties:0};var S=new YN;return S.count=i>0?i:void 0,S.max=isNaN(o)||o===null?void 0:o,S.min=isNaN(s)||s===null?void 0:s,S.name=Jt(t,a)||Ur,S.value=n,S.stdDev=isNaN(l)||l===null?void 0:l,M.metrics=[S],M.properties=Ca(t,c),M.measurements=Ra(t,p),M}return e.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",e.dataType="MetricData",e}($N);var Uc=function(r){Nt(e,r);function e(){var t=r.call(this)||this;return t.ver=2,t.properties={},t.measurements={},t}return e}(Gu);var Ea=function(r){Nt(e,r);function e(t,a,n,i,s,o,l){var c=r.call(this)||this;return c.aiDataContract={ver:1,name:0,url:0,duration:0,properties:0,measurements:0,id:0},c.id=ex(t,l),c.url=$i(t,n),c.name=Jt(t,a)||Ur,isNaN(i)||(c.duration=tn(i)),c.properties=Ca(t,s),c.measurements=Ra(t,o),c}return e.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",e.dataType="PageviewData",e}(Uc);var QN=function(){function r(){this.ver=2,this.success=!0,this.properties={},this.measurements={}}return r}();var nn=function(r){Nt(e,r);function e(t,a,n,i,s,o,l,c,p,M,S,O){p===void 0&&(p="Ajax");var E=r.call(this)||this;E.aiDataContract={id:1,ver:1,name:0,resultCode:0,duration:0,success:0,data:0,target:0,type:0,properties:0,measurements:0,kind:0,value:0,count:0,min:0,max:0,stdDev:0,dependencyKind:0,dependencySource:0,commandName:0,dependencyTypeName:0},E.id=a,E.duration=tn(s),E.success=o,E.resultCode=l+"",E.type=Jt(t,p);var q=qN(t,n,c,i);return E.data=$i(t,i)||q.data,E.target=Jt(t,q.target),M&&(E.target="".concat(E.target," | ").concat(M)),E.name=Jt(t,q.name),E.properties=Ca(t,S),E.measurements=Ra(t,O),E}return e.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",e.dataType="RemoteDependencyData",e}(QN);var ZN=function(){function r(){this.ver=2,this.properties={},this.measurements={}}return r}();var Wn=function(r){Nt(e,r);function e(t,a,n,i,s){var o=r.call(this)||this;return o.aiDataContract={ver:1,message:1,severityLevel:0,properties:0},a=a||Ur,o.message=Dc(t,a),o.properties=Ca(t,i),o.measurements=Ra(t,s),n&&(o.severityLevel=n),o}return e.envelopeType="Microsoft.ApplicationInsights.{0}.Message",e.dataType="MessageData",e}(ZN);var JN=function(r){Nt(e,r);function e(){var t=r.call(this)||this;return t.ver=2,t.properties={},t.measurements={},t}return e}(Uc);var Yn=function(r){Nt(e,r);function e(t,a,n,i,s,o,l){var c=r.call(this)||this;return c.aiDataContract={ver:1,name:0,url:0,duration:0,perfTotal:0,networkConnect:0,sentRequest:0,receivedResponse:0,domProcessing:0,properties:0,measurements:0},c.url=$i(t,n),c.name=Jt(t,a)||Ur,c.properties=Ca(t,s),c.measurements=Ra(t,o),l&&(c.domProcessing=l.domProcessing,c.duration=l.duration,c.networkConnect=l.networkConnect,c.perfTotal=l.perfTotal,c.receivedResponse=l.receivedResponse,c.sentRequest=l.sentRequest),c}return e.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",e.dataType="PageviewPerformanceData",e}(JN);var Ri=function(r){Nt(e,r);function e(t,a){var n=r.call(this)||this;return n.aiDataContract={baseType:1,baseData:1},n.baseType=t,n.baseData=a,n}return e}(fx);var Il;(function(r){r[r.Verbose=0]="Verbose",r[r.Information=1]="Information",r[r.Warning=2]="Warning",r[r.Error=3]="Error",r[r.Critical=4]="Critical"})(Il||(Il={}));function Cs(r){var e="ai."+r+".";return function(t){return e+t}}var jc=Cs("application"),ta=Cs("device"),$u=Cs("location"),Ml=Cs("operation"),_x=Cs("session"),Ps=Cs("user"),No=Cs("cloud"),Vc=Cs("internal"),Al=function(r){Nt(e,r);function e(){return r.call(this)||this}return e}(vy({applicationVersion:jc("ver"),applicationBuild:jc("build"),applicationTypeId:jc("typeId"),applicationId:jc("applicationId"),applicationLayer:jc("layer"),deviceId:ta("id"),deviceIp:ta("ip"),deviceLanguage:ta("language"),deviceLocale:ta("locale"),deviceModel:ta("model"),deviceFriendlyName:ta("friendlyName"),deviceNetwork:ta("network"),deviceNetworkName:ta("networkName"),deviceOEMName:ta("oemName"),deviceOS:ta("os"),deviceOSVersion:ta("osVersion"),deviceRoleInstance:ta("roleInstance"),deviceRoleName:ta("roleName"),deviceScreenResolution:ta("screenResolution"),deviceType:ta("type"),deviceMachineName:ta("machineName"),deviceVMName:ta("vmName"),deviceBrowser:ta("browser"),deviceBrowserVersion:ta("browserVersion"),locationIp:$u("ip"),locationCountry:$u("country"),locationProvince:$u("province"),locationCity:$u("city"),operationId:Ml("id"),operationName:Ml("name"),operationParentId:Ml("parentId"),operationRootId:Ml("rootId"),operationSyntheticSource:Ml("syntheticSource"),operationCorrelationVector:Ml("correlationVector"),sessionId:_x("id"),sessionIsFirst:_x("isFirst"),sessionIsNew:_x("isNew"),userAccountAcquisitionDate:Ps("accountAcquisitionDate"),userAccountId:Ps("accountId"),userAgent:Ps("userAgent"),userId:Ps("id"),userStoreRegion:Ps("storeRegion"),userAuthUserId:Ps("authUserId"),userAnonymousUserAcquisitionDate:Ps("anonUserAcquisitionDate"),userAuthenticatedUserAcquisitionDate:Ps("authUserAcquisitionDate"),cloudName:No("name"),cloudRole:No("role"),cloudRoleVer:No("roleVer"),cloudRoleInstance:No("roleInstance"),cloudEnvironment:No("environment"),cloudLocation:No("location"),cloudDeploymentUnit:No("deploymentUnit"),internalNodeName:Vc("nodeName"),internalSdkVersion:Vc("sdkVersion"),internalAgentVersion:Vc("agentVersion"),internalSnippet:Vc("snippet"),internalSdkSrc:Vc("sdkSrc")}));var Pn=function(){function r(){}return r.create=function(e,t,a,n,i,s){if(a=Jt(n,a)||Ur,Le(e)||Le(t)||Le(a))throw Error("Input doesn't contain all required fields");var o="";e[Hu]&&(o=e[Hu],delete e[Hu]);var l={name:a,time:Pa(new Date),iKey:o,ext:s||{},tags:[],data:{},baseType:t,baseData:e};return Le(i)||Xt(i,function(c,p){l.data[c]=p}),l},r}();var Ta={UserExt:"user",DeviceExt:"device",TraceExt:"trace",WebExt:"web",AppExt:"app",OSExt:"os",SessionExt:"ses",SDKExt:"sdk"},er=new Al;var Rs="AppInsightsPropertiesPlugin",Gc="AppInsightsChannelPlugin",bx="ApplicationInsightsAnalytics";var eP=function(){function r(e,t,a,n){zt(r,this,function(i){var s=null,o=[],l=!1,c;a&&(c=a.logger);function p(){a&&ft(a.getTransmissionControls(),function(S){ft(S,function(O){return O.flush(!0)})})}function M(S){o.push(S),s||(s=setInterval(function(){var O=o.slice(0),E=!1;o=[],ft(O,function(q){q()?E=!0:o.push(q)}),o.length===0&&(clearInterval(s),s=null),E&&p()},100))}i.trackPageView=function(S,O){var E=S.name;if(Le(E)||typeof E!="string"){var q=Fr();E=S.name=q&&q.title||""}var C=S.uri;if(Le(C)||typeof C!="string"){var W=Ja();C=S.uri=W&&W.href||""}if(!n.isPerformanceTimingSupported()){e.sendPageViewInternal(S,O),p(),c.throwInternal(Oe.WARNING,we.NavigationTimingNotSupported,"trackPageView: navigation timing API used for calculation of page duration is not supported in this browser. This page view will be collected without duration and timing info.");return}var ae=!1,Ce,et=n.getPerformanceTiming().navigationStart;et>0&&(Ce=ea(et,+new Date),n.shouldCollectDuration(Ce)||(Ce=void 0));var gt;!Le(O)&&!Le(O.duration)&&(gt=O.duration),(t||!isNaN(gt))&&(isNaN(gt)&&(O||(O={}),O.duration=Ce),e.sendPageViewInternal(S,O),p(),ae=!0);var _t=6e4;O||(O={}),M(function(){var dt=!1;try{if(n.isPerformanceTimingDataReady()){dt=!0;var Tt={name:E,uri:C};n.populatePageViewPerformanceEvent(Tt),!Tt.isValid&&!ae?(O.duration=Ce,e.sendPageViewInternal(S,O)):(ae||(O.duration=Tt.durationMs,e.sendPageViewInternal(S,O)),l||(e.sendPageViewPerformanceInternal(Tt,O),l=!0))}else et>0&&ea(et,+new Date)>_t&&(dt=!0,ae||(O.duration=_t,e.sendPageViewInternal(S,O)))}catch(pr){c.throwInternal(Oe.CRITICAL,we.TrackPVFailedCalc,"trackPageView failed on page load calculation: "+Ot(pr),{exception:xt(pr)})}return dt})}})}return r}();var tP=function(){function r(e,t){this.prevPageVisitDataKeyName="prevPageVisitData",this.pageVisitTimeTrackingHandler=t,this._logger=e}return r.prototype.trackPreviousPageVisit=function(e,t){try{var a=this.restartPageVisitTimer(e,t);a&&this.pageVisitTimeTrackingHandler(a.pageName,a.pageUrl,a.pageVisitTime)}catch(n){this._logger.warnToConsole("Auto track page visit time failed, metric will not be collected: "+xt(n))}},r.prototype.restartPageVisitTimer=function(e,t){try{var a=this.stopPageVisitTimer();return this.startPageVisitTimer(e,t),a}catch(n){return this._logger.warnToConsole("Call to restart failed: "+xt(n)),null}},r.prototype.startPageVisitTimer=function(e,t){try{if(bo()){Cl(this._logger,this.prevPageVisitDataKeyName)!=null&&ga("Cannot call startPageVisit consecutively without first calling stopPageVisit");var a=new t5(e,t),n=Jr().stringify(a);Rl(this._logger,this.prevPageVisitDataKeyName,n)}}catch(i){this._logger.warnToConsole("Call to start failed: "+xt(i))}},r.prototype.stopPageVisitTimer=function(){try{if(bo()){var e=Qr(),t=Cl(this._logger,this.prevPageVisitDataKeyName);if(t&&Gn()){var a=Jr().parse(t);return a.pageVisitTime=e-a.pageVisitStartTime,mx(this._logger,this.prevPageVisitDataKeyName),a}else return null}return null}catch(n){return this._logger.warnToConsole("Stop page visit timer failed: "+xt(n)),null}},r}();var t5=function(){function r(e,t){this.pageVisitStartTime=Qr(),this.pageName=e,this.pageUrl=t}return r}();var rP=function(){function r(e){this.MAX_DURATION_ALLOWED=36e5,e&&(this._logger=e.logger)}return r.prototype.populatePageViewPerformanceEvent=function(e){e.isValid=!1;var t=this.getPerformanceNavigationTiming(),a=this.getPerformanceTiming(),n=0,i=0,s=0,o=0,l=0;(t||a)&&(t?(n=t.duration,i=t.startTime===0?t.connectEnd:ea(t.startTime,t.connectEnd),s=ea(t.requestStart,t.responseStart),o=ea(t.responseStart,t.responseEnd),l=ea(t.responseEnd,t.loadEventEnd)):(n=ea(a.navigationStart,a.loadEventEnd),i=ea(a.navigationStart,a.connectEnd),s=ea(a.requestStart,a.responseStart),o=ea(a.responseStart,a.responseEnd),l=ea(a.responseEnd,a.loadEventEnd)),n===0?this._logger.throwInternal(Oe.WARNING,we.ErrorPVCalc,"error calculating page view performance.",{total:n,network:i,request:s,response:o,dom:l}):this.shouldCollectDuration(n,i,s,o,l)?n<Math.floor(i)+Math.floor(s)+Math.floor(o)+Math.floor(l)?this._logger.throwInternal(Oe.WARNING,we.ClientPerformanceMathError,"client performance math error.",{total:n,network:i,request:s,response:o,dom:l}):(e.durationMs=n,e.perfTotal=e.duration=tn(n),e.networkConnect=tn(i),e.sentRequest=tn(s),e.receivedResponse=tn(o),e.domProcessing=tn(l),e.isValid=!0):this._logger.throwInternal(Oe.WARNING,we.InvalidDurationValue,"Invalid page load duration value. Browser perf data won't be sent.",{total:n,network:i,request:s,response:o,dom:l}))},r.prototype.getPerformanceTiming=function(){return this.isPerformanceTimingSupported()?en().timing:null},r.prototype.getPerformanceNavigationTiming=function(){return this.isPerformanceNavigationTimingSupported()?en().getEntriesByType("navigation")[0]:null},r.prototype.isPerformanceNavigationTimingSupported=function(){var e=en();return e&&e.getEntriesByType&&e.getEntriesByType("navigation").length>0},r.prototype.isPerformanceTimingSupported=function(){var e=en();return e&&e.timing},r.prototype.isPerformanceTimingDataReady=function(){var e=en(),t=e?e.timing:0;return t&&t.domainLookupStart>0&&t.navigationStart>0&&t.responseStart>0&&t.requestStart>0&&t.loadEventEnd>0&&t.responseEnd>0&&t.connectEnd>0&&t.domLoading>0},r.prototype.shouldCollectDuration=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var a=va()||{},n=["googlebot","adsbot-google","apis-google","mediapartners-google"],i=a.userAgent,s=!1;if(i)for(var o=0;o<n.length;o++)s=s||i.toLowerCase().indexOf(n[o])!==-1;if(s)return!1;for(var o=0;o<e.length;o++)if(e[o]<0||e[o]>=this.MAX_DURATION_ALLOWED)return!1;return!0},r}();var aP="duration",Sx="event";function Kc(r,e){r&&r.dispatchEvent&&e&&r.dispatchEvent(e)}function r5(r){if(r&&r.reason){var e=r.reason;return!pt(e)&&vt(e.toString)?e.toString():xt(e)}return r||""}var Nx=function(r){Nt(e,r);function e(){var t=r.call(this)||this;t.identifier=bx,t.priority=180,t.autoRoutePVDelay=500;var a,n,i,s=0,o,l;return zt(e,t,function(c,p){var M=Ja(!0);o=M&&M.href||"",c.getCookieMgr=function(){return yo(c.core)},c.processTelemetry=function(C,W){Ci(c.core,function(){return c.identifier+":processTelemetry"},function(){var ae=!1,Ce=c._telemetryInitializers.length;W=c._getTelCtx(W);for(var et=0;et<Ce;++et){var gt=c._telemetryInitializers[et];if(gt)try{if(gt.apply(null,[C])===!1){ae=!0;break}}catch(_t){W.diagLog().throwInternal(Oe.CRITICAL,we.TelemetryInitializerFailed,"One of telemetry initializers failed, telemetry item will not be sent: "+Ot(_t),{exception:xt(_t)},!0)}}ae||c.processNext(C,W)},function(){return{item:C}},!C.sync)},c.trackEvent=function(C,W){try{var ae=Pn.create(C,rn.dataType,rn.envelopeType,c.diagLog(),W);c.core.track(ae)}catch(Ce){c.diagLog().throwInternal(Oe.WARNING,we.TrackTraceFailed,"trackTrace failed, trace will not be collected: "+Ot(Ce),{exception:xt(Ce)})}},c.startTrackEvent=function(C){try{a.start(C)}catch(W){c.diagLog().throwInternal(Oe.CRITICAL,we.StartTrackEventFailed,"startTrackEvent failed, event will not be collected: "+Ot(W),{exception:xt(W)})}},c.stopTrackEvent=function(C,W,ae){try{a.stop(C,void 0,W)}catch(Ce){c.diagLog().throwInternal(Oe.CRITICAL,we.StopTrackEventFailed,"stopTrackEvent failed, event will not be collected: "+Ot(Ce),{exception:xt(Ce)})}},c.trackTrace=function(C,W){try{var ae=Pn.create(C,Wn.dataType,Wn.envelopeType,c.diagLog(),W);c.core.track(ae)}catch(Ce){c.diagLog().throwInternal(Oe.WARNING,we.TrackTraceFailed,"trackTrace failed, trace will not be collected: "+Ot(Ce),{exception:xt(Ce)})}},c.trackMetric=function(C,W){try{var ae=Pn.create(C,an.dataType,an.envelopeType,c.diagLog(),W);c.core.track(ae)}catch(Ce){c.diagLog().throwInternal(Oe.CRITICAL,we.TrackMetricFailed,"trackMetric failed, metric will not be collected: "+Ot(Ce),{exception:xt(Ce)})}},c.trackPageView=function(C,W){try{var ae=C||{};c._pageViewManager.trackPageView(ae,Br(Br(Br({},ae.properties),ae.measurements),W)),c.config.autoTrackPageVisitTime&&c._pageVisitTimeManager.trackPreviousPageVisit(ae.name,ae.uri)}catch(Ce){c.diagLog().throwInternal(Oe.CRITICAL,we.TrackPVFailed,"trackPageView failed, page view will not be collected: "+Ot(Ce),{exception:xt(Ce)})}},c.sendPageViewInternal=function(C,W,ae){var Ce=Fr();Ce&&(C.refUri=C.refUri===void 0?Ce.referrer:C.refUri);var et=Pn.create(C,Ea.dataType,Ea.envelopeType,c.diagLog(),W,ae);c.core.track(et),s=0},c.sendPageViewPerformanceInternal=function(C,W,ae){var Ce=Pn.create(C,Yn.dataType,Yn.envelopeType,c.diagLog(),W,ae);c.core.track(Ce)},c.trackPageViewPerformance=function(C,W){try{c._pageViewPerformanceManager.populatePageViewPerformanceEvent(C),c.sendPageViewPerformanceInternal(C,W)}catch(ae){c.diagLog().throwInternal(Oe.CRITICAL,we.TrackPVFailed,"trackPageViewPerformance failed, page view will not be collected: "+Ot(ae),{exception:xt(ae)})}},c.startTrackPage=function(C){try{if(typeof C!="string"){var W=Fr();C=W&&W.title||""}n.start(C)}catch(ae){c.diagLog().throwInternal(Oe.CRITICAL,we.StartTrackFailed,"startTrackPage failed, page view may not be collected: "+Ot(ae),{exception:xt(ae)})}},c.stopTrackPage=function(C,W,ae,Ce){try{if(typeof C!="string"){var et=Fr();C=et&&et.title||""}if(typeof W!="string"){var gt=Ja();W=gt&&gt.href||""}n.stop(C,W,ae,Ce),c.config.autoTrackPageVisitTime&&c._pageVisitTimeManager.trackPreviousPageVisit(C,W)}catch(_t){c.diagLog().throwInternal(Oe.CRITICAL,we.StopTrackFailed,"stopTrackPage failed, page view will not be collected: "+Ot(_t),{exception:xt(_t)})}},c.sendExceptionInternal=function(C,W,ae){var Ce=C.exception||C.error||new Error(Ur),et=new pa(c.diagLog(),Ce,C.properties||W,C.measurements,C.severityLevel,C.id).toInterface(),gt=Pn.create(et,pa.dataType,pa.envelopeType,c.diagLog(),W,ae);c.core.track(gt)},c.trackException=function(C,W){try{c.sendExceptionInternal(C,W)}catch(ae){c.diagLog().throwInternal(Oe.CRITICAL,we.TrackExceptionFailed,"trackException failed, exception will not be collected: "+Ot(ae),{exception:xt(ae)})}},c._onerror=function(C){var W=C&&C.error,ae=C&&C.evt;try{if(!ae){var Ce=Pi();Ce&&(ae=Ce[Sx])}var et=C&&C.url||(Fr()||{}).URL,gt=C.errorSrc||"window.onerror@"+et+":"+(C.lineNumber||0)+":"+(C.columnNumber||0),_t={errorSrc:gt,url:et,lineNumber:C.lineNumber||0,columnNumber:C.columnNumber||0,message:C.message};ax(C.message,C.url,C.lineNumber,C.columnNumber,C.error)?q(pa.CreateAutoException("Script error: The browser's same-origin policy prevents us from getting the details of this exception. Consider using the 'crossorigin' attribute.",et,C.lineNumber||0,C.columnNumber||0,W,ae,null,gt),_t):(C.errorSrc||(C.errorSrc=gt),c.trackException({exception:C,severityLevel:Il.Error},_t))}catch(Tt){var dt=W?W.name+", "+W.message:"null";c.diagLog().throwInternal(Oe.CRITICAL,we.ExceptionWhileLoggingError,"_onError threw exception while logging error, error will not be collected: "+Ot(Tt),{exception:xt(Tt),errorString:dt})}},c.addTelemetryInitializer=function(C){c._telemetryInitializers.push(C)},c.initialize=function(C,W,ae,Ce){if(!c.isInitialized()){if(Le(W))throw Error("Error initializing");p.initialize(C,W,ae,Ce),c.setInitialized(!1);var et=c._getTelCtx(),gt=c.identifier;c.config=et.getExtCfg(gt);var _t=e.getDefaultConfig(C);_t!==void 0&&Xt(_t,function(At,tr){c.config[At]=et.getConfig(gt,At,tr),c.config[At]===void 0&&(c.config[At]=tr)}),c.config.isStorageUseDisabled&&sx();var dt={instrumentationKey:function(){return C.instrumentationKey},accountId:function(){return c.config.accountId||C.accountId},sessionRenewalMs:function(){return c.config.sessionRenewalMs||C.sessionRenewalMs},sessionExpirationMs:function(){return c.config.sessionExpirationMs||C.sessionExpirationMs},sampleRate:function(){return c.config.samplingPercentage||C.samplingPercentage},sdkExtension:function(){return c.config.sdkExtension||C.sdkExtension},isBrowserLinkTrackingEnabled:function(){return c.config.isBrowserLinkTrackingEnabled||C.isBrowserLinkTrackingEnabled},appId:function(){return c.config.appId||C.appId}};c._pageViewPerformanceManager=new rP(c.core),c._pageViewManager=new eP(t,c.config.overridePageViewDuration,c.core,c._pageViewPerformanceManager),c._pageVisitTimeManager=new tP(c.diagLog(),function(At,tr,Qt){return S(At,tr,Qt)}),c._telemetryInitializers=c._telemetryInitializers||[],O(dt),a=new nP(c.diagLog(),"trackEvent"),a.action=function(At,tr,Qt,$t){$t||($t={}),$t[aP]=Qt.toString(),c.trackEvent({name:At,properties:$t})},n=new nP(c.diagLog(),"trackPageView"),n.action=function(At,tr,Qt,$t,ot){Le($t)&&($t={}),$t[aP]=Qt.toString();var P={name:At,uri:tr,properties:$t,measurements:ot};c.sendPageViewInternal(P,$t)};var Tt=Pi(),pr=Ry(),yr=Ja(!0),Cr=t;if(c.config.disableExceptionTracking===!1&&!c.config.autoExceptionInstrumented&&Tt){var Ia="onerror",oa=Tt[Ia];Tt.onerror=function(At,tr,Qt,$t,ot){var P=Tt[Sx],Z=oa&&oa(At,tr,Qt,$t,ot);return Z!==!0&&Cr._onerror(pa.CreateAutoException(At,tr,Qt,$t,ot,P)),Z},c.config.autoExceptionInstrumented=!0}if(c.config.disableExceptionTracking===!1&&c.config.enableUnhandledPromiseRejectionTracking===!0&&!c.config.autoUnhandledPromiseInstrumented&&Tt){var Lr="onunhandledrejection",Vr=Tt[Lr];Tt[Lr]=function(At){var tr=Tt[Sx],Qt=Vr&&Vr.call(Tt,At);return Qt!==!0&&Cr._onerror(pa.CreateAutoException(r5(At),yr?yr.href:"",0,0,At,tr)),Qt},c.config.autoUnhandledPromiseInstrumented=!0}if(c.config.enableAutoRouteTracking===!0&&pr&&vt(pr.pushState)&&vt(pr.replaceState)&&Tt&&typeof Event<"u"){var Sr=t;ft(ae,function(At){At.identifier===Rs&&(i=At)}),pr.pushState=function(At){return function(){var Qt=At.apply(this,arguments);return Kc(Tt,go(Sr.config.namePrefix+"pushState")),Kc(Tt,go(Sr.config.namePrefix+"locationchange")),Qt}}(pr.pushState),pr.replaceState=function(At){return function(){var Qt=At.apply(this,arguments);return Kc(Tt,go(Sr.config.namePrefix+"replaceState")),Kc(Tt,go(Sr.config.namePrefix+"locationchange")),Qt}}(pr.replaceState),Tt.addEventListener&&(Tt.addEventListener(Sr.config.namePrefix+"popstate",function(){Kc(Tt,go(Sr.config.namePrefix+"locationchange"))}),Tt.addEventListener(Sr.config.namePrefix+"locationchange",function(){if(i&&i.context&&i.context.telemetryTrace){i.context.telemetryTrace.traceID=Da();var At="_unknown_";yr&&yr.pathname&&(At=yr.pathname+(yr.hash||"")),i.context.telemetryTrace.name=Jt(Sr.diagLog(),At)}l&&(o=l),l=yr&&yr.href||"",setTimeout(function(tr){Sr.trackPageView({refUri:tr,properties:{duration:0}})}.bind(t,o),Sr.autoRoutePVDelay)}))}c.setInitialized(!0)}};function S(C,W,ae){var Ce={PageName:C,PageUrl:W};c.trackMetric({name:"PageVisitTime",average:ae,max:ae,min:ae,sampleCount:1},Ce)}function O(C){if(!C.isBrowserLinkTrackingEnabled()){var W=["/browserLinkSignalR/","/__browserLink/"],ae=function(Ce){if(Ce.baseType===nn.dataType){var et=Ce.baseData;if(et){for(var gt=0;gt<W.length;gt++)if(et.target&&et.target.indexOf(W[gt])>=0)return!1}}return!0};E(ae)}}function E(C){c._telemetryInitializers.push(C)}function q(C,W){var ae=Pn.create(C,pa.dataType,pa.envelopeType,c.diagLog(),W);c.core.track(ae)}}),t}return e.getDefaultConfig=function(t){return t||(t={}),t.sessionRenewalMs=30*60*1e3,t.sessionExpirationMs=24*60*60*1e3,t.disableExceptionTracking=bn(t.disableExceptionTracking),t.autoTrackPageVisitTime=bn(t.autoTrackPageVisitTime),t.overridePageViewDuration=bn(t.overridePageViewDuration),t.enableUnhandledPromiseRejectionTracking=bn(t.enableUnhandledPromiseRejectionTracking),(isNaN(t.samplingPercentage)||t.samplingPercentage<=0||t.samplingPercentage>=100)&&(t.samplingPercentage=100),t.isStorageUseDisabled=bn(t.isStorageUseDisabled),t.isBrowserLinkTrackingEnabled=bn(t.isBrowserLinkTrackingEnabled),t.enableAutoRouteTracking=bn(t.enableAutoRouteTracking),t.namePrefix=t.namePrefix||"",t.enableDebug=bn(t.enableDebug),t.disableFlushOnBeforeUnload=bn(t.disableFlushOnBeforeUnload),t.disableFlushOnUnload=bn(t.disableFlushOnUnload,t.disableFlushOnBeforeUnload),t},e.Version="2.7.4",e}(Kn);var nP=function(){function r(e,t){var a=this,n={};a.start=function(i){typeof n[i]<"u"&&e.throwInternal(Oe.WARNING,we.StartCalledMoreThanOnce,"start was called more than once for this event without calling stop.",{name:i,key:i},!0),n[i]=+new Date},a.stop=function(i,s,o,l){var c=n[i];if(isNaN(c))e.throwInternal(Oe.WARNING,we.StopCalledWithoutStart,"stop was called without a corresponding start.",{name:i,key:i},!0);else{var p=+new Date,M=ea(c,p);a.action(i,s,M,o,l)}delete n[i],n[i]=void 0}}return r}();var iP=function(){function r(e,t){var a=[],n=!1;this._get=function(){return a},this._set=function(i){return a=i,a},zt(r,this,function(i){i.enqueue=function(s){if(i.count()>=t.eventsLimitInMem()){n||(e.throwInternal(Oe.WARNING,we.InMemoryStorageBufferFull,"Maximum in-memory buffer size reached: "+i.count(),!0),n=!0);return}a.push(s)},i.count=function(){return a.length},i.size=function(){for(var s=a.length,o=0;o<a.length;o++)s+=a[o].length;return t.emitLineDelimitedJson()||(s+=2),s},i.clear=function(){a=[],n=!1},i.getItems=function(){return a.slice(0)},i.batchPayloads=function(s){if(s&&s.length>0){var o=t.emitLineDelimitedJson()?s.join(`
26
- `):"["+s.join(",")+"]";return o}return null}})}return r}(),sP=function(r){Nt(e,r);function e(t,a){var n=r.call(this,t,a)||this;return zt(e,n,function(i,s){i.markAsSent=function(o){s.clear()},i.clearSent=function(o){}}),n}return e}(iP);var oP=function(r){Nt(e,r);function e(t,a){var n=r.call(this,t,a)||this,i=!1;return zt(e,n,function(s,o){var l=S(e.BUFFER_KEY),c=S(e.SENT_BUFFER_KEY),p=s._set(l.concat(c));p.length>e.MAX_BUFFER_SIZE&&(p.length=e.MAX_BUFFER_SIZE),O(e.SENT_BUFFER_KEY,[]),O(e.BUFFER_KEY,p),s.enqueue=function(E){if(s.count()>=e.MAX_BUFFER_SIZE){i||(t.throwInternal(Oe.WARNING,we.SessionStorageBufferFull,"Maximum buffer size reached: "+s.count(),!0),i=!0);return}o.enqueue(E),O(e.BUFFER_KEY,s._get())},s.clear=function(){o.clear(),O(e.BUFFER_KEY,s._get()),O(e.SENT_BUFFER_KEY,[]),i=!1},s.markAsSent=function(E){O(e.BUFFER_KEY,s._set(M(E,s._get())));var q=S(e.SENT_BUFFER_KEY);q instanceof Array&&E instanceof Array&&(q=q.concat(E),q.length>e.MAX_BUFFER_SIZE&&(t.throwInternal(Oe.CRITICAL,we.SessionStorageBufferFull,"Sent buffer reached its maximum size: "+q.length,!0),q.length=e.MAX_BUFFER_SIZE),O(e.SENT_BUFFER_KEY,q))},s.clearSent=function(E){var q=S(e.SENT_BUFFER_KEY);q=M(E,q),O(e.SENT_BUFFER_KEY,q)};function M(E,q){var C=[];return ft(q,function(W){!vt(W)&&Ni(E,W)===-1&&C.push(W)}),C}function S(E){var q=E;try{q=a.namePrefix&&a.namePrefix()?a.namePrefix()+"_"+q:q;var C=Cl(t,q);if(C){var W=Jr().parse(C);if(pt(W)&&(W=Jr().parse(W)),W&&Yr(W))return W}}catch(ae){t.throwInternal(Oe.CRITICAL,we.FailedToRestoreStorageBuffer," storage key: "+q+", "+Ot(ae),{exception:xt(ae)})}return[]}function O(E,q){var C=E;try{C=a.namePrefix&&a.namePrefix()?a.namePrefix()+"_"+C:C;var W=JSON.stringify(q);Rl(t,C,W)}catch(ae){Rl(t,C,JSON.stringify([])),t.throwInternal(Oe.WARNING,we.FailedToSetStorageBuffer," storage key: "+C+", "+Ot(ae)+". Buffer cleared",{exception:xt(ae)})}}}),n}return e.BUFFER_KEY="AI_buffer",e.SENT_BUFFER_KEY="AI_sentBuffer",e.MAX_BUFFER_SIZE=2e3,e}(iP);var Px="baseType",br="baseData",sa="properties",lP="true";function jr(r,e,t){return Bt(r,e,t,yl)}function a5(r,e,t){var a=t.tags=t.tags||{},n=e.ext=e.ext||{},i=e.tags=e.tags||[],s=n.user;s&&(jr(a,er.userAuthUserId,s.authId),jr(a,er.userId,s.id||s.localId));var o=n.app;o&&jr(a,er.sessionId,o.sesId);var l=n.device;l&&(jr(a,er.deviceId,l.id||l.localId),jr(a,er.deviceType,l.deviceClass),jr(a,er.deviceIp,l.ip),jr(a,er.deviceModel,l.model),jr(a,er.deviceType,l.deviceType));var c=e.ext.web;if(c){jr(a,er.deviceLanguage,c.browserLang),jr(a,er.deviceBrowserVersion,c.browserVer),jr(a,er.deviceBrowser,c.browser);var p=t.data=t.data||{},M=p[br]=p[br]||{},S=M[sa]=M[sa]||{};jr(S,"domain",c.domain),jr(S,"isManual",c.isManual?lP:null),jr(S,"screenRes",c.screenRes),jr(S,"userConsent",c.userConsent?lP:null)}var O=n.os;O&&jr(a,er.deviceOS,O.name);var E=n.trace;E&&(jr(a,er.operationParentId,E.parentID),jr(a,er.operationName,Jt(r,E.name)),jr(a,er.operationId,E.traceID));for(var q={},C=i.length-1;C>=0;C--){var W=i[C];Xt(W,function(Ce,et){q[Ce]=et}),i.splice(C,1)}Xt(i,function(Ce,et){q[Ce]=et});var ae=Br(Br({},a),q);ae[er.internalSdkVersion]||(ae[er.internalSdkVersion]="javascript:".concat(n5.Version)),t.tags=Cu(ae)}function Es(r,e,t){Le(r)||Xt(r,function(a,n){hl(n)?t[a]=n:pt(n)?e[a]=n:Gn()&&(e[a]=Jr().stringify(n))})}function Po(r,e){Le(r)||Xt(r,function(t,a){r[t]=a||e})}function Co(r,e,t,a){var n=new Vu(r,a,e);jr(n,"sampleRate",t[Nl]),(t[br]||{}).startTime&&(n.time=Pa(t[br].startTime)),n.iKey=t.iKey;var i=t.iKey.replace(/-/g,"");return n.name=n.name.replace("{0}",i),a5(r,t,n),t.tags=t.tags||[],Cu(n)}function Ro(r,e){Le(e[br])&&r.throwInternal(Oe.CRITICAL,we.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.")}var n5={Version:"2.7.4"};function cP(r,e,t){Ro(r,e);var a=e[br].measurements||{},n=e[br][sa]||{};Es(e.data,n,a),Le(t)||Po(n,t);var i=e[br];if(Le(i))return r.warnToConsole("Invalid input for dependency data"),null;var s=i[sa]&&i[sa][kc]?i[sa][kc]:"GET",o=new nn(r,i.id,i.target,i.name,i.duration,i.success,i.responseCode,s,i.type,i.correlationContext,n,a),l=new Ri(nn.dataType,o);return Co(r,nn.envelopeType,e,l)}function Cx(r,e,t){Ro(r,e);var a={},n={};e[Px]!==rn.dataType&&(a.baseTypeSource=e[Px]),e[Px]===rn.dataType?(a=e[br][sa]||{},n=e[br].measurements||{}):e[br]&&Es(e[br],a,n),Es(e.data,a,n),Le(t)||Po(a,t);var i=e[br].name,s=new rn(r,i,a,n),o=new Ri(rn.dataType,s);return Co(r,rn.envelopeType,e,o)}function mP(r,e,t){Ro(r,e);var a=e[br].measurements||{},n=e[br][sa]||{};Es(e.data,n,a),Le(t)||Po(n,t);var i=e[br],s=pa.CreateFromInterface(r,i,n,a),o=new Ri(pa.dataType,s);return Co(r,pa.envelopeType,e,o)}function dP(r,e,t){Ro(r,e);var a=e[br],n=a[sa]||{},i=a.measurements||{};Es(e.data,n,i),Le(t)||Po(n,t);var s=new an(r,a.name,a.average,a.sampleCount,a.min,a.max,a.stdDev,n,i),o=new Ri(an.dataType,s);return Co(r,an.envelopeType,e,o)}function uP(r,e,t){Ro(r,e);var a="duration",n,i=e[br];!Le(i)&&!Le(i[sa])&&!Le(i[sa][a])?(n=i[sa][a],delete i[sa][a]):!Le(e.data)&&!Le(e.data[a])&&(n=e.data[a],delete e.data[a]);var s=e[br],o;((e.ext||{}).trace||{}).traceID&&(o=e.ext.trace.traceID);var l=s.id||o,c=s.name,p=s.uri,M=s[sa]||{},S=s.measurements||{};if(Le(s.refUri)||(M.refUri=s.refUri),Le(s.pageType)||(M.pageType=s.pageType),Le(s.isLoggedIn)||(M.isLoggedIn=s.isLoggedIn.toString()),!Le(s[sa])){var O=s[sa];Xt(O,function(C,W){M[C]=W})}Es(e.data,M,S),Le(t)||Po(M,t);var E=new Ea(r,c,p,n,M,S,l),q=new Ri(Ea.dataType,E);return Co(r,Ea.envelopeType,e,q)}function pP(r,e,t){Ro(r,e);var a=e[br],n=a.name,i=a.uri||a.url,s=a[sa]||{},o=a.measurements||{};Es(e.data,s,o),Le(t)||Po(s,t);var l=new Yn(r,n,i,void 0,s,o,a),c=new Ri(Yn.dataType,l);return Co(r,Yn.envelopeType,e,c)}function fP(r,e,t){Ro(r,e);var a=e[br].message,n=e[br].severityLevel,i=e[br][sa]||{},s=e[br].measurements||{};Es(e.data,i,s),Le(t)||Po(i,t);var o=new Wn(r,a,n,i,s),l=new Ri(Wn.dataType,o);return Co(r,Wn.envelopeType,e,l)}var hP=function(){function r(e){zt(r,this,function(t){t.serialize=function(s){var o=a(s,"root");try{return Jr().stringify(o)}catch(l){e.throwInternal(Oe.CRITICAL,we.CannotSerializeObject,l&&vt(l.toString)?l.toString():"Error serializing object",null,!0)}};function a(s,o){var l="__aiCircularRefCheck",c={};if(!s)return e.throwInternal(Oe.CRITICAL,we.CannotSerializeObject,"cannot serialize object because it is null or undefined",{name:o},!0),c;if(s[l])return e.throwInternal(Oe.WARNING,we.CircularReferenceDetected,"Circular reference detected while serializing object",{name:o},!0),c;if(!s.aiDataContract){if(o==="measurements")c=i(s,"number",o);else if(o==="properties")c=i(s,"string",o);else if(o==="tags")c=i(s,"string",o);else if(Yr(s))c=n(s,o);else{e.throwInternal(Oe.WARNING,we.CannotSerializeObjectNonSerializable,"Attempting to serialize an object which does not implement ISerializable",{name:o},!0);try{Jr().stringify(s),c=s}catch(p){e.throwInternal(Oe.CRITICAL,we.CannotSerializeObject,p&&vt(p.toString)?p.toString():"Error serializing object",null,!0)}}return c}return s[l]=!0,Xt(s.aiDataContract,function(p,M){var S=vt(M)?M()&1:M&1,O=vt(M)?M()&4:M&4,E=M&2,q=s[p]!==void 0,C=jn(s[p])&&s[p]!==null;if(S&&!q&&!E)e.throwInternal(Oe.CRITICAL,we.MissingRequiredFieldSpecification,"Missing required field specification. The field is required but not present on source",{field:p,name:o});else if(!O){var W=void 0;C?E?W=n(s[p],p):W=a(s[p],p):W=s[p],W!==void 0&&(c[p]=W)}}),delete s[l],c}function n(s,o){var l;if(s)if(!Yr(s))e.throwInternal(Oe.CRITICAL,we.ItemNotInArray,`This field was specified as an array in the contract but the item is not an array.\r
27
- `,{name:o},!0);else{l=[];for(var c=0;c<s.length;c++){var p=s[c],M=a(p,o+"["+c+"]");l.push(M)}}return l}function i(s,o,l){var c;return s&&(c={},Xt(s,function(p,M){if(o==="string")M===void 0?c[p]="undefined":M===null?c[p]="null":M.toString?c[p]=M.toString():c[p]="invalid field: toString() is not defined.";else if(o==="number")if(M===void 0)c[p]="undefined";else if(M===null)c[p]="null";else{var S=parseFloat(M);isNaN(S)?c[p]="NaN":c[p]=S}else c[p]="invalid field: "+l+" is of unknown type.",e.throwInternal(Oe.CRITICAL,c[p],null,!0)})),c}})}return r}();var i5=function(){function r(){var e=Pi(),t=Fr(),a=!1,n=!0;zt(r,this,function(i){try{if(e&&Vn(e,"online",l)&&(Vn(e,"offline",c),a=!0),t){var s=t.body||t;Ir(s.ononline)||(s.ononline=l,s.onoffline=c,a=!0)}if(a){var o=va();o&&!Le(o.onLine)&&(n=o.onLine)}}catch{a=!1}i.isListening=a,i.isOnline=function(){var p=!0,M=va();return a?p=n:M&&!Le(M.onLine)&&(p=M.onLine),p},i.isOffline=function(){return!i.isOnline()};function l(){n=!0}function c(){n=!1}})}return r.Offline=new r,r}();var Rx=i5.Offline;var s5=8,yP=function(){function r(){}return r.prototype.getHashCodeScore=function(e){var t=this.getHashCode(e)/r.INT_MAX_VALUE;return t*100},r.prototype.getHashCode=function(e){if(e==="")return 0;for(;e.length<s5;)e=e.concat(e);for(var t=5381,a=0;a<e.length;++a)t=(t<<5)+t+e.charCodeAt(a),t=t&t;return Math.abs(t)},r.INT_MAX_VALUE=2147483647,r}();var xP=function(){function r(){var e=this,t=new yP,a=new Al;e.getSamplingScore=function(n){var i=0;return n.tags&&n.tags[a.userId]?i=t.getHashCodeScore(n.tags[a.userId]):n.ext&&n.ext.user&&n.ext.user.id?i=t.getHashCodeScore(n.ext.user.id):n.tags&&n.tags[a.operationId]?i=t.getHashCodeScore(n.tags[a.operationId]):n.ext&&n.ext.telemetryTrace&&n.ext.telemetryTrace.traceID?i=t.getHashCodeScore(n.ext.telemetryTrace.traceID):i=Math.random()*100,i}}return r}();var gP=function(){function r(e,t){this.INT_MAX_VALUE=2147483647;var a=t||Ki(null);(e>100||e<0)&&(a.throwInternal(Oe.WARNING,we.SampleRateOutOfRange,"Sampling rate is out of range (0..100). Sampling will be disabled, you may be sending too much data which may affect your AI service level.",{samplingRate:e},!0),e=100),this.sampleRate=e,this.samplingScoreGenerator=new xP}return r.prototype.isSampledIn=function(e){var t=this.sampleRate,a=!1;return t==null||t>=100||e.baseType===an.dataType?!0:(a=this.samplingScoreGenerator.getSamplingScore(e)<t,a)},r}();var Yi,o5=65e3;function Wu(r){try{return r.responseText}catch{}return null}function vP(){return{endpointUrl:function(){return"https://dc.services.visualstudio.com/v2/track"},emitLineDelimitedJson:function(){return!1},maxBatchInterval:function(){return 15e3},maxBatchSizeInBytes:function(){return 102400},disableTelemetry:function(){return!1},enableSessionStorageBuffer:function(){return!0},isRetryDisabled:function(){return!1},isBeaconApiDisabled:function(){return!0},disableXhr:function(){return!1},onunloadDisableFetch:function(){return!1},onunloadDisableBeacon:function(){return!1},instrumentationKey:function(){},namePrefix:function(){},samplingPercentage:function(){return 100},customHeaders:function(){},convertUndefined:function(){},eventsLimitInMem:function(){return 1e4}}}var l5=(Yi={},Yi[rn.dataType]=Cx,Yi[Wn.dataType]=fP,Yi[Ea.dataType]=uP,Yi[Yn.dataType]=pP,Yi[pa.dataType]=mP,Yi[an.dataType]=dP,Yi[nn.dataType]=cP,Yi),Ex=function(r){Nt(e,r);function e(){var t=r.call(this)||this;t.priority=1001,t.identifier=Gc;var a,n,i,s=!1,o,l,c,p={},M=0,S,O;return t._senderConfig=vP(),zt(e,t,function(E,q){function C(){ga("Method not implemented.")}E.pause=function(){Vr(),s=!0},E.resume=function(){s&&(s=!1,n=null,E._buffer.size()>E._senderConfig.maxBatchSizeInBytes()&&E.triggerSend(!0,null,10),Lr())},E.flush=function(){if(!s){Vr();try{E.triggerSend(!0,null,1)}catch(Z){E.diagLog().throwInternal(Oe.CRITICAL,we.FlushFailed,"flush failed, telemetry will not be collected: "+Ot(Z),{exception:xt(Z)})}}},E.onunloadFlush=function(){if(!s)if((E._senderConfig.onunloadDisableBeacon()===!1||E._senderConfig.isBeaconApiDisabled()===!1)&&po())try{E.triggerSend(!0,et,2)}catch(Z){E.diagLog().throwInternal(Oe.CRITICAL,we.FailedToSendQueuedTelemetry,"failed to flush with beacon sender on page unload, telemetry will not be collected: "+Ot(Z),{exception:xt(Z)})}else E.flush()},E.teardown=C,E.addHeader=function(Z,Re){p[Z]=Re},E.initialize=function(Z,Re,ke,ne){q.initialize(Z,Re,ke,ne);var ue=E._getTelCtx(),Ne=E.identifier;l=new hP(Re.logger),a=0,n=null,i=0,E._sender=null,c=0;var Se=E.diagLog(),Pe=vP();Xt(Pe,function(it,lt){E._senderConfig[it]=function(){return ue.getConfig(Ne,it,lt())}}),E._buffer=E._senderConfig.enableSessionStorageBuffer()&&bo()?new oP(Se,E._senderConfig):new sP(Se,E._senderConfig),E._sample=new gP(E._senderConfig.samplingPercentage(),Se),P(Z)||Se.throwInternal(Oe.CRITICAL,we.InvalidInstrumentationKey,"Invalid Instrumentation key "+Z.instrumentationKey),!So(E._senderConfig.endpointUrl())&&E._senderConfig.customHeaders()&&E._senderConfig.customHeaders().length>0&&ft(E._senderConfig.customHeaders(),function(it){t.addHeader(it.header,it.value)});var Fe=E._senderConfig,Te=null;!Fe.disableXhr()&&Tu()?Te=tr:!Fe.disableXhr()&&fo()&&(Te=dt),!Te&&Eu()&&(Te=pr),S=Te||dt,!Fe.isBeaconApiDisabled()&&po()&&(Te=_t),E._sender=Te||dt,!Fe.onunloadDisableFetch()&&Eu(!0)?O=Tt:po()?O=_t:!Fe.disableXhr()&&Tu()?O=tr:!Fe.disableXhr()&&fo()?O=dt:O=S},E.processTelemetry=function(Z,Re){Re=E._getTelCtx(Re);try{if(E._senderConfig.disableTelemetry())return;if(!Z){Re.diagLog().throwInternal(Oe.CRITICAL,we.CannotSendEmptyTelemetry,"Cannot send empty telemetry");return}if(Z.baseData&&!Z.baseType){Re.diagLog().throwInternal(Oe.CRITICAL,we.InvalidEvent,"Cannot send telemetry without baseData and baseType");return}if(Z.baseType||(Z.baseType="EventData"),!E._sender){Re.diagLog().throwInternal(Oe.CRITICAL,we.SenderNotInitialized,"Sender was not initialized");return}if(W(Z))Z[Nl]=E._sample.sampleRate;else{Re.diagLog().throwInternal(Oe.WARNING,we.TelemetrySampledAndNotSent,"Telemetry item was sampled out and not sent",{SampleRate:E._sample.sampleRate});return}var ke=E._senderConfig.convertUndefined()||void 0,ne=Z.iKey||E._senderConfig.instrumentationKey(),ue=e.constructEnvelope(Z,ne,Re.diagLog(),ke);if(!ue){Re.diagLog().throwInternal(Oe.CRITICAL,we.CreateEnvelopeError,"Unable to create an AppInsights envelope");return}var Ne=!1;if(Z.tags&&Z.tags[Pl]&&(ft(Z.tags[Pl],function(Te){try{Te&&Te(ue)===!1&&(Ne=!0,Re.diagLog().warnToConsole("Telemetry processor check returns false"))}catch(it){Re.diagLog().throwInternal(Oe.CRITICAL,we.TelemetryInitializerFailed,"One of telemetry initializers failed, telemetry item will not be sent: "+Ot(it),{exception:xt(it)},!0)}}),delete Z.tags[Pl]),Ne)return;var Se=l.serialize(ue),Pe=E._buffer,Fe=Pe.size();Fe+Se.length>E._senderConfig.maxBatchSizeInBytes()&&E.triggerSend(!0,null,10),Pe.enqueue(Se),Lr()}catch(Te){Re.diagLog().throwInternal(Oe.WARNING,we.FailedAddingTelemetryToBuffer,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+Ot(Te),{exception:xt(Te)})}E.processNext(Z,Re)},E._xhrReadyStateChange=function(Z,Re,ke){Z.readyState===4&&ae(Z.status,Re,Z.responseURL,ke,At(Z),Wu(Z)||Z.response)},E.triggerSend=function(Z,Re,ke){if(Z===void 0&&(Z=!0),!s)try{var ne=E._buffer;if(E._senderConfig.disableTelemetry())ne.clear();else{if(ne.count()>0){var ue=ne.getItems();ot(ke||0,Z),Re?Re.call(t,ue,Z):E._sender(ue,Z)}i=+new Date}Vr()}catch(Se){var Ne=gl();(!Ne||Ne>9)&&E.diagLog().throwInternal(Oe.CRITICAL,we.TransmissionFailed,"Telemetry transmission failed, some telemetry will be lost: "+Ot(Se),{exception:xt(Se)})}},E._onError=function(Z,Re,ke){E.diagLog().throwInternal(Oe.WARNING,we.OnError,"Failed to send telemetry.",{message:Re}),E._buffer.clearSent(Z)},E._onPartialSuccess=function(Z,Re){for(var ke=[],ne=[],ue=Re.errors.reverse(),Ne=0,Se=ue;Ne<Se.length;Ne++){var Pe=Se[Ne],Fe=Z.splice(Pe.index,1)[0];Sr(Pe.statusCode)?ne.push(Fe):ke.push(Fe)}Z.length>0&&E._onSuccess(Z,Re.itemsAccepted),ke.length>0&&E._onError(ke,At(null,["partial success",Re.itemsAccepted,"of",Re.itemsReceived].join(" "))),ne.length>0&&(Ia(ne),E.diagLog().throwInternal(Oe.WARNING,we.TransmissionFailed,"Partial success. Delivered: "+Z.length+", Failed: "+ke.length+". Will retry to send "+ne.length+" our of "+Re.itemsReceived+" items"))},E._onSuccess=function(Z,Re){E._buffer.clearSent(Z)},E._xdrOnLoad=function(Z,Re){var ke=Wu(Z);if(Z&&(ke+""=="200"||ke===""))a=0,E._onSuccess(Re,0);else{var ne=Cr(ke);ne&&ne.itemsReceived&&ne.itemsReceived>ne.itemsAccepted&&!E._senderConfig.isRetryDisabled()?E._onPartialSuccess(Re,ne):E._onError(Re,Qt(Z))}};function W(Z){return E._sample.isSampledIn(Z)}function ae(Z,Re,ke,ne,ue,Ne){var Se=null;if(E._appId||(Se=Cr(Ne),Se&&Se.appId&&(E._appId=Se.appId)),(Z<200||Z>=300)&&Z!==0){if((Z===301||Z===307||Z===308)&&!Ce(ke)){E._onError(Re,ue);return}!E._senderConfig.isRetryDisabled()&&Sr(Z)?(Ia(Re),E.diagLog().throwInternal(Oe.WARNING,we.TransmissionFailed,". Response code "+Z+". Will retry to send "+Re.length+" items.")):E._onError(Re,ue)}else if(Rx.isOffline()){if(!E._senderConfig.isRetryDisabled()){var Pe=10;Ia(Re,Pe),E.diagLog().throwInternal(Oe.WARNING,we.TransmissionFailed,". Offline - Response Code: ".concat(Z,". Offline status: ").concat(Rx.isOffline(),". Will retry to send ").concat(Re.length," items."))}}else Ce(ke),Z===206?(Se||(Se=Cr(Ne)),Se&&!E._senderConfig.isRetryDisabled()?E._onPartialSuccess(Re,Se):E._onError(Re,ue)):(a=0,E._onSuccess(Re,ne))}function Ce(Z){return c>=10?!1:!Le(Z)&&Z!==""&&Z!==E._senderConfig.endpointUrl()?(E._senderConfig.endpointUrl=function(){return Z},++c,!0):!1}function et(Z,Re){O?O(Z,!1):_t(Z,Re)}function gt(Z){var Re=va(),ke=E._buffer,ne=E._senderConfig.endpointUrl(),ue=E._buffer.batchPayloads(Z),Ne=new Blob([ue],{type:"text/plain;charset=UTF-8"}),Se=Re.sendBeacon(ne,Ne);return Se&&(ke.markAsSent(Z),E._onSuccess(Z,Z.length)),Se}function _t(Z,Re){if(Yr(Z)&&Z.length>0&&!gt(Z)){for(var ke=[],ne=0;ne<Z.length;ne++){var ue=Z[ne];gt([ue])||ke.push(ue)}ke.length>0&&(S(ke,!0),E.diagLog().throwInternal(Oe.WARNING,we.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with normal sender."))}}function dt(Z,Re){var ke=new XMLHttpRequest,ne=E._senderConfig.endpointUrl();try{ke[$n]=!0}catch{}ke.open("POST",ne,Re),ke.setRequestHeader("Content-type","application/json"),So(ne)&&ke.setRequestHeader(Zt.sdkContextHeader,Zt.sdkContextHeaderAppIdRequest),ft(_n(p),function(Ne){ke.setRequestHeader(Ne,p[Ne])}),ke.onreadystatechange=function(){return E._xhrReadyStateChange(ke,Z,Z.length)},ke.onerror=function(Ne){return E._onError(Z,At(ke),Ne)};var ue=E._buffer.batchPayloads(Z);ke.send(ue),E._buffer.markAsSent(Z)}function Tt(Z,Re){if(Yr(Z)){for(var ke=Z.length,ne=0;ne<Z.length;ne++)ke+=Z[ne].length;M+ke<=o5?yr(Z,!1):po()?_t(Z,Re):(S&&S(Z,!0),E.diagLog().throwInternal(Oe.WARNING,we.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with xhrSender."))}}function pr(Z,Re){yr(Z,!0)}function yr(Z,Re){var ke,ne=E._senderConfig.endpointUrl(),ue=E._buffer.batchPayloads(Z),Ne=new Blob([ue],{type:"application/json"}),Se=new Headers,Pe=ue.length,Fe=!1,Te=!1;So(ne)&&Se.append(Zt.sdkContextHeader,Zt.sdkContextHeaderAppIdRequest),ft(_n(p),function(pe){Se.append(pe,p[pe])});var it=(ke={method:"POST",headers:Se,body:Ne},ke[$n]=!0,ke);Re||(it.keepalive=!0,Fe=!0,M+=Pe);var lt=new Request(ne,it);try{lt[$n]=!0}catch{}E._buffer.markAsSent(Z);try{fetch(lt).then(function(pe){Re||(M-=Pe,Pe=0),Te||(Te=!0,pe.ok?pe.text().then(function(qr){ae(pe.status,Z,pe.url,Z.length,pe.statusText,qr)}):E._onError(Z,pe.statusText))}).catch(function(pe){Re||(M-=Pe,Pe=0),Te||(Te=!0,E._onError(Z,pe.message))})}catch(pe){Te||E._onError(Z,xt(pe))}Fe&&!Te&&(Te=!0,E._onSuccess(Z,Z.length))}function Cr(Z){try{if(Z&&Z!==""){var Re=Jr().parse(Z);if(Re&&Re.itemsReceived&&Re.itemsReceived>=Re.itemsAccepted&&Re.itemsReceived-Re.itemsAccepted===Re.errors.length)return Re}}catch(ke){E.diagLog().throwInternal(Oe.CRITICAL,we.InvalidBackendResponse,"Cannot parse the response. "+Ot(ke),{response:Z})}return null}function Ia(Z,Re){if(Re===void 0&&(Re=1),!(!Z||Z.length===0)){var ke=E._buffer;ke.clearSent(Z),a++;for(var ne=0,ue=Z;ne<ue.length;ne++){var Ne=ue[ne];ke.enqueue(Ne)}oa(Re),Lr()}}function oa(Z){var Re=10,ke;if(a<=1)ke=Re;else{var ne=(Math.pow(2,a)-1)/2,ue=Math.floor(Math.random()*ne*Re)+1;ue=Z*ue,ke=Math.max(Math.min(ue,3600),Re)}var Ne=Qr()+ke*1e3;n=Ne}function Lr(){if(!o&&!s){var Z=n?Math.max(0,n-Qr()):0,Re=Math.max(E._senderConfig.maxBatchInterval(),Z);o=setTimeout(function(){o=null,E.triggerSend(!0,null,1)},Re)}}function Vr(){clearTimeout(o),o=null,n=null}function Sr(Z){return Z===408||Z===429||Z===500||Z===503}function At(Z,Re){return Z?"XMLHttpRequest,Status:"+Z.status+",Response:"+Wu(Z)||Z.response||"":Re}function tr(Z,Re){var ke=E._buffer,ne=Pi(),ue=new XDomainRequest;ue.onload=function(){return E._xdrOnLoad(ue,Z)},ue.onerror=function(Fe){return E._onError(Z,Qt(ue),Fe)};var Ne=ne&&ne.location&&ne.location.protocol||"";if(E._senderConfig.endpointUrl().lastIndexOf(Ne,0)!==0){E.diagLog().throwInternal(Oe.WARNING,we.TransmissionFailed,". Cannot send XDomain request. The endpoint URL protocol doesn't match the hosting page protocol."),ke.clear();return}var Se=E._senderConfig.endpointUrl().replace(/^(https?:)/,"");ue.open("POST",Se);var Pe=ke.batchPayloads(Z);ue.send(Pe),ke.markAsSent(Z)}function Qt(Z,Re){return Z?"XDomainRequest,Response:"+Wu(Z)||"":Re}function $t(){var Z="getNotifyMgr";return E.core[Z]?E.core[Z]():E.core._notificationManager}function ot(Z,Re){var ke=$t();if(ke&&ke.eventsSendRequest)try{ke.eventsSendRequest(Z,Re)}catch(ne){E.diagLog().throwInternal(Oe.CRITICAL,we.NotificationException,"send request notification failed: "+Ot(ne),{exception:xt(ne)})}}function P(Z){var Re=Le(Z.disableInstrumentationKeyValidation)?!1:Z.disableInstrumentationKeyValidation;if(Re)return!0;var ke="^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$",ne=new RegExp(ke);return ne.test(Z.instrumentationKey)}}),t}return e.constructEnvelope=function(t,a,n,i){var s;a!==t.iKey&&!Le(a)?s=Br(Br({},t),{iKey:a}):s=t;var o=l5[s.baseType]||Cx;return o(n,s,i)},e}(Kn);var c5="ai_session",Tx=function(){function r(){}return r}();var _P=function(){function r(e,t){var a=this,n,i,s=Ki(t),o=yo(t);zt(r,a,function(l){e||(e={}),vt(e.sessionExpirationMs)||(e.sessionExpirationMs=function(){return r.acquisitionSpan}),vt(e.sessionRenewalMs)||(e.sessionRenewalMs=function(){return r.renewalSpan}),l.config=e;var c=l.config.sessionCookiePostfix&&l.config.sessionCookiePostfix()?l.config.sessionCookiePostfix():l.config.namePrefix&&l.config.namePrefix()?l.config.namePrefix():"";n=function(){return c5+c},l.automaticSession=new Tx,l.update=function(){var q=Qr(),C=!1,W=l.automaticSession;W.id||(C=!p(W,q));var ae=l.config.sessionExpirationMs();if(!C&&ae>0){var Ce=l.config.sessionRenewalMs(),et=q-W.acquisitionDate,gt=q-W.renewalDate;C=et<0||gt<0,C=C||et>ae,C=C||gt>Ce}C?S(q):(!i||q-i>r.cookieUpdateInterval)&&O(W,q)},l.backup=function(){var q=l.automaticSession;E(q.id,q.acquisitionDate,q.renewalDate)};function p(q,C){var W=!1,ae=o.get(n());if(ae&&vt(ae.split))W=M(q,ae);else{var Ce=ox(s,n());Ce&&(W=M(q,Ce))}return W||!!q.id}function M(q,C){var W=!1,ae=", session will be reset",Ce=C.split("|");if(Ce.length>=2)try{var et=+Ce[1]||0,gt=+Ce[2]||0;isNaN(et)||et<=0?s.throwInternal(Oe.WARNING,we.SessionRenewalDateIsZero,"AI session acquisition date is 0"+ae):isNaN(gt)||gt<=0?s.throwInternal(Oe.WARNING,we.SessionRenewalDateIsZero,"AI session renewal date is 0"+ae):Ce[0]&&(q.id=Ce[0],q.acquisitionDate=et,q.renewalDate=gt,W=!0)}catch(_t){s.throwInternal(Oe.CRITICAL,we.ErrorParsingAISessionCookie,"Error parsing ai_session value ["+(C||"")+"]"+ae+" - "+Ot(_t),{exception:xt(_t)})}return W}function S(q){var C=l.config||{},W=(C.getNewId?C.getNewId():null)||Sl;l.automaticSession.id=W(C.idLength?C.idLength():22),l.automaticSession.acquisitionDate=q,O(l.automaticSession,q),ku()||s.throwInternal(Oe.WARNING,we.BrowserDoesNotSupportLocalStorage,"Browser does not support local storage. Session durations will be inaccurate.")}function O(q,C){var W=q.acquisitionDate;q.renewalDate=C;var ae=l.config,Ce=ae.sessionRenewalMs(),et=W+ae.sessionExpirationMs()-C,gt=[q.id,W,C],_t=0;et<Ce?_t=et/1e3:_t=Ce/1e3;var dt=ae.cookieDomain?ae.cookieDomain():null;o.set(n(),gt.join("|"),ae.sessionExpirationMs()>0?_t:null,dt),i=C}function E(q,C,W){lx(s,n(),[q,C,W].join("|"))}})}return r.acquisitionSpan=864e5,r.renewalSpan=18e5,r.cookieUpdateInterval=6e4,r}();var bP=function(){function r(){}return r}();var SP=function(){function r(){this.id="browser",this.deviceClass="Browser"}return r}();var m5="2.7.4",NP=function(){function r(e){this.sdkVersion=(e.sdkExtension&&e.sdkExtension()?e.sdkExtension()+"_":"")+"javascript:"+m5}return r}();function PP(r){return!(typeof r!="string"||!r||r.match(/,|;|=| |\|/))}var CP=function(){function r(e,t){this.isNewUser=!1,this.isUserCookieSet=!1;var a=Ki(t),n=yo(t),i;zt(r,this,function(s){s.config=e;var o=s.config.userCookiePostfix&&s.config.userCookiePostfix()?s.config.userCookiePostfix():"";i=function(){return r.userCookieName+o};var l=n.get(i());if(l){s.isNewUser=!1;var c=l.split(r.cookieSeparator);c.length>0&&(s.id=c[0],s.isUserCookieSet=!!s.id)}function p(){var W=e||{},ae=(W.getNewId?W.getNewId():null)||Sl,Ce=ae(W.idLength?e.idLength():22);return Ce}function M(W){var ae=Pa(new Date);s.accountAcquisitionDate=ae,s.isNewUser=!0;var Ce=[W,ae];return Ce}function S(W){var ae=31536e3;s.isUserCookieSet=n.set(i(),W,ae)}if(!s.id){s.id=p();var O=M(s.id);S(O.join(r.cookieSeparator));var E=e.namePrefix&&e.namePrefix()?e.namePrefix()+"ai_session":"ai_session";cx(a,E)}s.accountId=e.accountId?e.accountId():void 0;var q=n.get(r.authUserCookieName);if(q){q=decodeURI(q);var C=q.split(r.cookieSeparator);C[0]&&(s.authenticatedId=C[0]),C.length>1&&C[1]&&(s.accountId=C[1])}s.setAuthenticatedUserContext=function(W,ae,Ce){Ce===void 0&&(Ce=!1);var et=!PP(W)||ae&&!PP(ae);if(et){a.throwInternal(Oe.WARNING,we.SetAuthContextFailedAccountName,"Setting auth user context failed. User auth/account id should be of type string, and not contain commas, semi-colons, equal signs, spaces, or vertical-bars.",!0);return}s.authenticatedId=W;var gt=s.authenticatedId;ae&&(s.accountId=ae,gt=[s.authenticatedId,s.accountId].join(r.cookieSeparator)),Ce&&n.set(r.authUserCookieName,encodeURI(gt))},s.clearAuthenticatedUserContext=function(){s.authenticatedId=null,s.accountId=null,n.del(r.authUserCookieName)},s.update=function(W){if(s.id!==W||!s.isUserCookieSet){var ae=W||p(),Ce=M(ae);S(Ce.join(r.cookieSeparator))}}})}return r.cookieSeparator="|",r.userCookieName="ai_user",r.authUserCookieName="ai_authUser",r}();var RP=function(){function r(){}return r}();var EP=function(){function r(e,t,a,n){var i=this;i.traceID=e||Da(),i.parentID=t,i.name=a;var s=Ja();!a&&s&&s.pathname&&(i.name=s.pathname),i.name=Jt(n,i.name)}return r}();var Yu="ext",Qu="tags";function Bl(r,e){r&&r[e]&&_n(r[e]).length===0&&delete r[e]}var TP=function(){function r(e,t){var a=this,n=e.logger;this.appId=function(){return null},this.getSessionId=function(){return null},zt(r,this,function(i){i.application=new bP,i.internal=new NP(t),mo()&&(i.sessionManager=new _P(t,e),i.device=new SP,i.location=new RP,i.user=new CP(t,e),i.telemetryTrace=new EP(void 0,void 0,void 0,n),i.session=new Tx),i.getSessionId=function(){var s=i.session,o=null;if(s&&pt(s.id))o=s.id;else{var l=(i.sessionManager||{}).automaticSession;o=l&&pt(l.id)?l.id:null}return o},i.applySessionContext=function(s,o){Bt(Zr(s.ext,Ta.AppExt),"sesId",i.getSessionId(),pt)},i.applyOperatingSystemContxt=function(s,o){Bt(s.ext,Ta.OSExt,i.os)},i.applyApplicationContext=function(s,o){var l=i.application;if(l){var c=Zr(s,Qu);Bt(c,er.applicationVersion,l.ver,pt),Bt(c,er.applicationBuild,l.build,pt)}},i.applyDeviceContext=function(s,o){var l=i.device;if(l){var c=Zr(Zr(s,Yu),Ta.DeviceExt);Bt(c,"localId",l.id,pt),Bt(c,"ip",l.ip,pt),Bt(c,"model",l.model,pt),Bt(c,"deviceClass",l.deviceClass,pt)}},i.applyInternalContext=function(s,o){var l=i.internal;if(l){var c=Zr(s,Qu);Bt(c,er.internalAgentVersion,l.agentVersion,pt),Bt(c,er.internalSdkVersion,l.sdkVersion,pt),(s.baseType===Gi.dataType||s.baseType===Ea.dataType)&&(Bt(c,er.internalSnippet,l.snippetVer,pt),Bt(c,er.internalSdkSrc,l.sdkSrc,pt))}},i.applyLocationContext=function(s,o){var l=a.location;l&&Bt(Zr(s,Qu,[]),er.locationIp,l.ip,pt)},i.applyOperationContext=function(s,o){var l=i.telemetryTrace;if(l){var c=Zr(Zr(s,Yu),Ta.TraceExt,{traceID:void 0,parentID:void 0});Bt(c,"traceID",l.traceID,pt),Bt(c,"name",l.name,pt),Bt(c,"parentID",l.parentID,pt)}},i.applyWebContext=function(s,o){var l=a.web;l&&Bt(Zr(s,Yu),Ta.WebExt,l)},i.applyUserContext=function(s,o){var l=i.user;if(l){var c=Zr(s,Qu,[]);Bt(c,er.userAccountId,l.accountId,pt);var p=Zr(Zr(s,Yu),Ta.UserExt);Bt(p,"id",l.id,pt),Bt(p,"authId",l.authenticatedId,pt)}},i.cleanUp=function(s,o){var l=s.ext;l&&(Bl(l,Ta.DeviceExt),Bl(l,Ta.UserExt),Bl(l,Ta.WebExt),Bl(l,Ta.OSExt),Bl(l,Ta.AppExt),Bl(l,Ta.TraceExt))}})}return r}();var d5=function(r){Nt(e,r);function e(){var t=r.call(this)||this;t.priority=110,t.identifier=Rs;var a,n;return zt(e,t,function(i,s){i.initialize=function(l,c,p,M){s.initialize(l,c,p,M);var S=i._getTelCtx(),O=i.identifier,E=e.getDefaultConfig();n=n||{},Xt(E,function(q,C){n[q]=function(){return S.getConfig(O,q,C())}}),i.context=new TP(c,n),a=rx(p,Gc),i.context.appId=function(){return a?a._appId:null},i._extConfig=n},i.processTelemetry=function(l,c){if(!Le(l)){c=i._getTelCtx(c),l.name===Ea.envelopeType&&c.diagLog().resetInternalMessageCount();var p=i.context||{};p.session&&typeof i.context.session.id!="string"&&p.sessionManager&&p.sessionManager.update();var M=p.user;if(M&&!M.isUserCookieSet&&M.update(p.user.id),o(l,c),M&&M.isNewUser){M.isNewUser=!1;var S=new Gi(we.SendBrowserInfoOnUserInit,(va()||{}).userAgent||"");c.diagLog().logInternalMessage(Oe.CRITICAL,S)}i.processNext(l,c)}};function o(l,c){Zr(l,"tags",[]),Zr(l,"ext",{});var p=i.context;p.applySessionContext(l,c),p.applyApplicationContext(l,c),p.applyDeviceContext(l,c),p.applyOperationContext(l,c),p.applyUserContext(l,c),p.applyOperatingSystemContxt(l,c),p.applyWebContext(l,c),p.applyLocationContext(l,c),p.applyInternalContext(l,c),p.cleanUp(l,c)}}),t}return e.getDefaultConfig=function(){var t={instrumentationKey:function(){},accountId:function(){return null},sessionRenewalMs:function(){return 18e5},samplingPercentage:function(){return 100},sessionExpirationMs:function(){return 864e5},cookieDomain:function(){return null},sdkExtension:function(){return null},isBrowserLinkTrackingEnabled:function(){return!1},appId:function(){return null},getSessionId:function(){return null},namePrefix:function(){},sessionCookiePostfix:function(){},userCookiePostfix:function(){},idLength:function(){return 22},getNewId:function(){return null}};return t},e}(Kn),wx=d5;var sn="properties";function wP(r,e,t){var a=0,n=r[e],i=r[t];return n&&i&&(a=ea(n,i)),a}function Eo(r,e,t,a,n){var i=0,s=wP(t,a,n);return s&&(i=Ts(r,e,tn(s))),i}function Ts(r,e,t){var a="ajaxPerf",n=0;if(r&&e&&t){var i=r[a]=r[a]||{};i[e]=t,n=1}return n}function u5(r,e){var t=r.perfTiming,a=e[sn]||{},n=0,i="name",s="Start",o="End",l="domainLookup",c="connect",p="redirect",M="request",S="response",O="duration",E="startTime",q=l+s,C=l+o,W=c+s,ae=c+o,Ce=M+s,et=M+o,gt=S+s,_t=S+o,dt=p+s,Tt=p=o,pr="transferSize",yr="encodedBodySize",Cr="decodedBodySize",Ia="serverTiming";if(t){n|=Eo(a,p,t,dt,Tt),n|=Eo(a,l,t,q,C),n|=Eo(a,c,t,W,ae),n|=Eo(a,M,t,Ce,et),n|=Eo(a,S,t,gt,_t),n|=Eo(a,"networkConnect",t,E,ae),n|=Eo(a,"sentRequest",t,Ce,_t);var oa=t[O];oa||(oa=wP(t,E,_t)||0),n|=Ts(a,O,oa),n|=Ts(a,"perfTotal",oa);var Lr=t[Ia];if(Lr){var Vr={};ft(Lr,function(Sr,At){var tr=yy(Sr[i]||""+At),Qt=Vr[tr]||{};Xt(Sr,function($t,ot){($t!==i&&pt(ot)||hl(ot))&&(Qt[$t]&&(ot=Qt[$t]+";"+ot),(ot||!pt(ot))&&(Qt[$t]=ot))}),Vr[tr]=Qt}),n|=Ts(a,Ia,Vr)}n|=Ts(a,pr,t[pr]),n|=Ts(a,yr,t[yr]),n|=Ts(a,Cr,t[Cr])}else r.perfMark&&(n|=Ts(a,"missing",r.perfAttempts));n&&(e[sn]=a)}var p5=function(){function r(){var e=this;e.openDone=!1,e.setRequestHeaderDone=!1,e.sendDone=!1,e.abortDone=!1,e.stateChangeAttached=!1}return r}();var Ix=function(){function r(e,t,a){var n=this,i=a,s="responseText";n.perfMark=null,n.completed=!1,n.requestHeadersSize=null,n.requestHeaders=null,n.responseReceivingDuration=null,n.callbackDuration=null,n.ajaxTotalDuration=null,n.aborted=0,n.pageUrl=null,n.requestUrl=null,n.requestSize=0,n.method=null,n.status=null,n.requestSentTime=null,n.responseStartedTime=null,n.responseFinishedTime=null,n.callbackFinishedTime=null,n.endTime=null,n.xhrMonitoringState=new p5,n.clientFailure=0,n.traceID=e,n.spanID=t,zt(r,n,function(o){o.getAbsoluteUrl=function(){return o.requestUrl?Fu(o.requestUrl):null},o.getPathName=function(){return o.requestUrl?$i(i,Uu(o.method,o.requestUrl)):null},o.CreateTrackItem=function(l,c,p){var M;if(o.ajaxTotalDuration=Math.round(ea(o.requestSentTime,o.responseFinishedTime)*1e3)/1e3,o.ajaxTotalDuration<0)return null;var S=(M={id:"|"+o.traceID+"."+o.spanID,target:o.getAbsoluteUrl(),name:o.getPathName(),type:l,startTime:null,duration:o.ajaxTotalDuration,success:+o.status>=200&&+o.status<400,responseCode:+o.status,method:o.method},M[sn]={HttpMethod:o.method},M);if(o.requestSentTime&&(S.startTime=new Date,S.startTime.setTime(o.requestSentTime)),u5(o,S),c&&_n(o.requestHeaders).length>0&&(S[sn]=S[sn]||{},S[sn].requestHeaders=o.requestHeaders),p){var O=p();if(O){var E=O.correlationContext;if(E&&(S.correlationContext=E),O.headerMap&&_n(O.headerMap).length>0&&(S[sn]=S[sn]||{},S[sn].responseHeaders=O.headerMap),o.errorStatusText&&o.status>=400){var q=O.type;S[sn]=S[sn]||{},(q===""||q==="text")&&(S[sn][s]=O[s]?O.statusText+" - "+O[s]:O.statusText),q==="json"&&(S[sn][s]=O.response?O.statusText+" - "+JSON.stringify(O.response):O.statusText)}}}return S}})}return r}();var Mx=function(){function r(e,t){var a=this;a.traceFlag=r.DEFAULT_TRACE_FLAG,a.version=r.DEFAULT_VERSION,e&&r.isValidTraceId(e)?a.traceId=e:a.traceId=Da(),t&&r.isValidSpanId(t)?a.spanId=t:a.spanId=Da().substr(0,16)}return r.isValidTraceId=function(e){return e.match(/^[0-9a-f]{32}$/)&&e!=="00000000000000000000000000000000"},r.isValidSpanId=function(e){return e.match(/^[0-9a-f]{16}$/)&&e!=="0000000000000000"},r.prototype.toString=function(){var e=this;return"".concat(e.version,"-").concat(e.traceId,"-").concat(e.spanId,"-").concat(e.traceFlag)},r.DEFAULT_TRACE_FLAG="01",r.DEFAULT_VERSION="00",r}();var IP="ai.ajxmn.",$c="diagLog",on="ajaxData",AP="throwInternal",Wc="fetch",MP=0;function f5(){var r=vn();return!r||Le(r.Request)||Le(r.Request[Pr])||Le(r[Wc])?null:r[Wc]}function h5(r){var e=!1;if(fo()){var t=XMLHttpRequest[Pr];e=!Le(t)&&!Le(t.open)&&!Le(t.send)&&!Le(t.abort)}var a=gl();if(a&&a<9&&(e=!1),e)try{var n=new XMLHttpRequest;n[on]={};var i=XMLHttpRequest[Pr].open;XMLHttpRequest[Pr].open=i}catch(s){e=!1,Yc(r,we.FailedMonitorAjaxOpen,"Failed to enable XMLHttpRequest monitoring, extension is not supported",{exception:xt(s)})}return e}function Zu(r){var e="";try{!Le(r)&&!Le(r[on])&&!Le(r[on].requestUrl)&&(e+="(url: '"+r[on].requestUrl+"')")}catch{}return e}function Yc(r,e,t,a,n){r[$c]()[AP](Oe.CRITICAL,e,t,a,n)}function Ol(r,e,t,a,n){r[$c]()[AP](Oe.WARNING,e,t,a,n)}function Xc(r,e,t){return function(a){Yc(r,e,t,{ajaxDiagnosticsMessage:Zu(a.inst),exception:xt(a.err)})}}function zl(r,e){return r&&e?r.indexOf(e):-1}var Ax=function(r){Nt(e,r);function e(){var t=r.call(this)||this;t.identifier=e.identifier,t.priority=120;var a="trackDependencyDataInternal",n=Ja(),i=!1,s=!1,o=n&&n.host&&n.host.toLowerCase(),l=e.getEmptyConfig(),c=!1,p=!1,M=0,S,O,E,q,C=!1,W=0,ae=!1,Ce=[],et={},gt,_t;return zt(e,t,function(dt,Tt){dt.initialize=function(ne,ue,Ne,Se){if(!dt.isInitialized()){Tt.initialize(ne,ue,Ne,Se);var Pe=dt._getTelCtx(),Fe=e.getDefaultConfig();Xt(Fe,function(qr,ra){l[qr]=Pe.getConfig(e.identifier,qr,ra)});var Te=l.distributedTracingMode;if(c=l.enableRequestHeaderTracking,p=l.enableAjaxErrorStatusText,C=l.enableAjaxPerfTracking,W=l.maxAjaxCallsPerView,ae=l.enableResponseHeaderTracking,gt=l.excludeRequestFromAutoTrackingPatterns,_t=l.addRequestContext,E=Te===Sn.AI||Te===Sn.AI_AND_W3C,O=Te===Sn.AI_AND_W3C||Te===Sn.W3C,C){var it=ne.instrumentationKey||"unkwn";it.length>5?q=IP+it.substring(it.length-5)+".":q=IP+it+"."}if(l.disableAjaxTracking===!1&&Ia(),yr(),Ne.length>0&&Ne){for(var lt=void 0,pe=0;!lt&&pe<Ne.length;)Ne[pe]&&Ne[pe].identifier===Rs&&(lt=Ne[pe]),pe++;lt&&(S=lt.context)}}},dt.teardown=function(){ft(Ce,function(ne){ne.rm()}),Ce=[],i=!1,s=!1,dt.setInitialized(!1)},dt.trackDependencyData=function(ne,ue){dt[a](ne,ue)},dt.includeCorrelationHeaders=function(ne,ue,Ne,Se){var Pe=dt._currentWindowHost||o;if(ue){if(Wi.canIncludeCorrelationHeader(l,ne.getAbsoluteUrl(),Pe)){if(Ne||(Ne={}),Ne.headers=new Headers(Ne.headers||(ue instanceof Request?ue.headers||{}:{})),E){var Fe="|"+ne.traceID+"."+ne.spanID;Ne.headers.set(Zt.requestIdHeader,Fe),c&&(ne.requestHeaders[Zt.requestIdHeader]=Fe)}var Te=l.appId||S&&S.appId();if(Te&&(Ne.headers.set(Zt.requestContextHeader,Zt.requestContextAppIdFormat+Te),c&&(ne.requestHeaders[Zt.requestContextHeader]=Zt.requestContextAppIdFormat+Te)),O){var it=new Mx(ne.traceID,ne.spanID);Ne.headers.set(Zt.traceParentHeader,it.toString()),c&&(ne.requestHeaders[Zt.traceParentHeader]=it.toString())}}return Ne}else if(Se){if(Wi.canIncludeCorrelationHeader(l,ne.getAbsoluteUrl(),Pe)){if(E){var Fe="|"+ne.traceID+"."+ne.spanID;Se.setRequestHeader(Zt.requestIdHeader,Fe),c&&(ne.requestHeaders[Zt.requestIdHeader]=Fe)}var Te=l.appId||S&&S.appId();if(Te&&(Se.setRequestHeader(Zt.requestContextHeader,Zt.requestContextAppIdFormat+Te),c&&(ne.requestHeaders[Zt.requestContextHeader]=Zt.requestContextAppIdFormat+Te)),O){var it=new Mx(ne.traceID,ne.spanID);Se.setRequestHeader(Zt.traceParentHeader,it.toString()),c&&(ne.requestHeaders[Zt.traceParentHeader]=it.toString())}}return Se}},dt[a]=function(ne,ue,Ne){if(W===-1||M<W){(l.distributedTracingMode===Sn.W3C||l.distributedTracingMode===Sn.AI_AND_W3C)&&typeof ne.id=="string"&&ne.id[ne.id.length-1]!=="."&&(ne.id+="."),Le(ne.startTime)&&(ne.startTime=new Date);var Se=Pn.create(ne,nn.dataType,nn.envelopeType,dt[$c](),ue,Ne);dt.core.track(Se)}else M===W&&Yc(dt,we.MaxAjaxPerPVExceeded,"Maximum ajax per page view limit reached, ajax monitoring is paused until the next trackPageView(). In order to increase the limit set the maxAjaxCallsPerView configuration parameter.",!0);++M};function pr(ne){var ue=!0;return(ne||l.ignoreHeaders)&&ft(l.ignoreHeaders,function(Ne){if(Ne.toLowerCase()===ne.toLowerCase())return ue=!1,-1}),ue}function yr(){var ne=f5();if(!!ne){var ue=vn(),Ne=ne.polyfill;l.disableFetchTracking===!1?(Ce.push(Hc(ue,Wc,{req:function(Se,Pe,Fe){var Te;if(i&&!oa(null,Pe,Fe)&&!(Ne&&s)){var it=Se.ctx();Te=P(Pe,Fe);var lt=dt.includeCorrelationHeaders(Te,Pe,Fe);lt!==Fe&&Se.set(1,lt),it.data=Te}},rsp:function(Se,Pe){var Fe=Se.ctx().data;Fe&&(Se.rslt=Se.rslt.then(function(Te){return Re(Se,(Te||{}).status,Pe,Te,Fe,function(){var it={statusText:Te.statusText,headerMap:null,correlationContext:ke(Te)};if(ae){var lt={};Te.headers.forEach(function(pe,qr){pr(qr)&&(lt[qr]=pe)}),it.headerMap=lt}return it}),Te}).catch(function(Te){throw Re(Se,0,Pe,null,Fe,null,{error:Te.message}),Te}))},hkErr:Xc(dt,we.FailedMonitorAjaxOpen,"Failed to monitor Window.fetch, monitoring data for this fetch call may be incorrect.")})),i=!0):Ne&&Ce.push(Hc(ue,Wc,{req:function(Se,Pe,Fe){oa(null,Pe,Fe)}})),Ne&&(ue[Wc].polyfill=Ne)}}function Cr(ne,ue,Ne){Ce.push(Qy(ne,ue,Ne))}function Ia(){h5(dt)&&!s&&(Cr(XMLHttpRequest,"open",{req:function(ne,ue,Ne,Se){var Pe=ne.inst,Fe=Pe[on];!oa(Pe,Ne)&&Lr(Pe,!0)&&((!Fe||!Fe.xhrMonitoringState.openDone)&&Vr(Pe,ue,Ne,Se),Sr(Pe))},hkErr:Xc(dt,we.FailedMonitorAjaxOpen,"Failed to monitor XMLHttpRequest.open, monitoring data for this ajax call may be incorrect.")}),Cr(XMLHttpRequest,"send",{req:function(ne,ue){var Ne=ne.inst,Se=Ne[on];Lr(Ne)&&!Se.xhrMonitoringState.sendDone&&($t("xhr",Se),Se.requestSentTime=El(),dt.includeCorrelationHeaders(Se,void 0,void 0,Ne),Se.xhrMonitoringState.sendDone=!0)},hkErr:Xc(dt,we.FailedMonitorAjaxSend,"Failed to monitor XMLHttpRequest, monitoring data for this ajax call may be incorrect.")}),Cr(XMLHttpRequest,"abort",{req:function(ne){var ue=ne.inst,Ne=ue[on];Lr(ue)&&!Ne.xhrMonitoringState.abortDone&&(Ne.aborted=1,Ne.xhrMonitoringState.abortDone=!0)},hkErr:Xc(dt,we.FailedMonitorAjaxAbort,"Failed to monitor XMLHttpRequest.abort, monitoring data for this ajax call may be incorrect.")}),c&&Cr(XMLHttpRequest,"setRequestHeader",{req:function(ne,ue,Ne){var Se=ne.inst;Lr(Se)&&pr(ue)&&(Se[on].requestHeaders[ue]=Ne)},hkErr:Xc(dt,we.FailedMonitorAjaxSetRequestHeader,"Failed to monitor XMLHttpRequest.setRequestHeader, monitoring data for this ajax call may be incorrect.")}),s=!0)}function oa(ne,ue,Ne){var Se=!1,Pe=((pt(ue)?ue:(ue||{}).url||"")||"").toLowerCase();if(ft(gt,function(it){var lt=it;pt(it)&&(lt=new RegExp(it)),Se||(Se=lt.test(Pe))}),Se)return Se;var Fe=zl(Pe,"?"),Te=zl(Pe,"#");return(Fe===-1||Te!==-1&&Te<Fe)&&(Fe=Te),Fe!==-1&&(Pe=Pe.substring(0,Fe)),Le(ne)?Le(ue)||(Se=(typeof ue=="object"?ue[$n]===!0:!1)||(Ne?Ne[$n]===!0:!1)):Se=ne[$n]===!0||Pe[$n]===!0,!Se&&Pe&&So(Pe)&&(Se=!0),Se?et[Pe]||(et[Pe]=1):et[Pe]&&(Se=!0),Se}function Lr(ne,ue){var Ne=!0,Se=s;return Le(ne)||(Ne=ue===!0||!Le(ne[on])),Se&&Ne}function Vr(ne,ue,Ne,Se){var Pe=S&&S.telemetryTrace&&S.telemetryTrace.traceID||Da(),Fe=Da().substr(0,16),Te=new Ix(Pe,Fe,dt[$c]());Te.method=ue,Te.requestUrl=Ne,Te.xhrMonitoringState.openDone=!0,Te.requestHeaders={},Te.async=Se,Te.errorStatusText=p,ne[on]=Te}function Sr(ne){ne[on].xhrMonitoringState.stateChangeAttached=Vn(ne,"readystatechange",function(){try{ne&&ne.readyState===4&&Lr(ne)&&tr(ne)}catch(Ne){var ue=xt(Ne);(!ue||zl(ue.toLowerCase(),"c00c023f")===-1)&&Yc(dt,we.FailedMonitorAjaxRSC,"Failed to monitor XMLHttpRequest 'readystatechange' event handler, monitoring data for this ajax call may be incorrect.",{ajaxDiagnosticsMessage:Zu(ne),exception:ue})}})}function At(ne){try{var ue=ne.responseType;if(ue===""||ue==="text")return ne.responseText}catch{}return null}function tr(ne){var ue=ne[on];ue.responseFinishedTime=El(),ue.status=ne.status;function Ne(Se,Pe){var Fe=Pe||{};Fe.ajaxDiagnosticsMessage=Zu(ne),Se&&(Fe.exception=xt(Se)),Ol(dt,we.FailedMonitorAjaxDur,"Failed to calculate the duration of the ajax call, monitoring data for this ajax call won't be sent.",Fe)}ot("xmlhttprequest",ue,function(){try{var Se=ue.CreateTrackItem("Ajax",c,function(){var Fe={statusText:ne.statusText,headerMap:null,correlationContext:Qt(ne),type:ne.responseType,responseText:At(ne),response:ne.response};if(ae){var Te=ne.getAllResponseHeaders();if(Te){var it=Or(Te).split(/[\r\n]+/),lt={};ft(it,function(pe){var qr=pe.split(": "),ra=qr.shift(),aa=qr.join(": ");pr(ra)&&(lt[ra]=aa)}),Fe.headerMap=lt}}return Fe}),Pe=void 0;try{_t&&(Pe=_t({status:ne.status,xhr:ne}))}catch{Ol(dt,we.FailedAddingCustomDefinedRequestContext,"Failed to add custom defined request context as configured call back may missing a null check.")}Se?(Pe!==void 0&&(Se.properties=Br(Br({},Se.properties),Pe)),dt[a](Se)):Ne(null,{requestSentTime:ue.requestSentTime,responseFinishedTime:ue.responseFinishedTime})}finally{try{ne[on]=null}catch{}}},function(Se){Ne(Se,null)})}function Qt(ne){try{var ue=ne.getAllResponseHeaders();if(ue!==null){var Ne=zl(ue.toLowerCase(),Zt.requestContextHeaderLowerCase);if(Ne!==-1){var Se=ne.getResponseHeader(Zt.requestContextHeader);return Wi.getCorrelationContext(Se)}}}catch(Pe){Ol(dt,we.FailedMonitorAjaxGetCorrelationHeader,"Failed to get Request-Context correlation header as it may be not included in the response or not accessible.",{ajaxDiagnosticsMessage:Zu(ne),exception:xt(Pe)})}}function $t(ne,ue){if(ue.requestUrl&&q&&C){var Ne=en();if(Ne&&vt(Ne.mark)){MP++;var Se=q+ne+"#"+MP;Ne.mark(Se);var Pe=Ne.getEntriesByName(Se);Pe&&Pe.length===1&&(ue.perfMark=Pe[0])}}}function ot(ne,ue,Ne,Se){var Pe=ue.perfMark,Fe=en(),Te=l.maxAjaxPerfLookupAttempts,it=l.ajaxPerfLookupDelay,lt=ue.requestUrl,pe=0;(function qr(){try{if(Fe&&Pe){pe++;for(var ra=null,aa=Fe.getEntries(),fa=aa.length-1;fa>=0;fa--){var Dt=aa[fa];if(Dt){if(Dt.entryType==="resource")Dt.initiatorType===ne&&(zl(Dt.name,lt)!==-1||zl(lt,Dt.name)!==-1)&&(ra=Dt);else if(Dt.entryType==="mark"&&Dt.name===Pe.name){ue.perfTiming=ra;break}if(Dt.startTime<Pe.startTime-1e3)break}}}!Pe||ue.perfTiming||pe>=Te||ue.async===!1?(Pe&&vt(Fe.clearMarks)&&Fe.clearMarks(Pe.name),ue.perfAttempts=pe,Ne()):setTimeout(qr,it)}catch(Bs){Se(Bs)}})()}function P(ne,ue){var Ne=S&&S.telemetryTrace&&S.telemetryTrace.traceID||Da(),Se=Da().substr(0,16),Pe=new Ix(Ne,Se,dt[$c]());Pe.requestSentTime=El(),Pe.errorStatusText=p,ne instanceof Request?Pe.requestUrl=ne?ne.url:"":Pe.requestUrl=ne;var Fe="GET";ue&&ue.method?Fe=ue.method:ne&&ne instanceof Request&&(Fe=ne.method),Pe.method=Fe;var Te={};if(c){var it=new Headers((ue?ue.headers:0)||(ne instanceof Request?ne.headers||{}:{}));it.forEach(function(lt,pe){pr(pe)&&(Te[pe]=lt)})}return Pe.requestHeaders=Te,$t("fetch",Pe),Pe}function Z(ne){var ue="";try{Le(ne)||(typeof ne=="string"?ue+="(url: '".concat(ne,"')"):ue+="(url: '".concat(ne.url,"')"))}catch(Ne){Yc(dt,we.FailedMonitorAjaxOpen,"Failed to grab failed fetch diagnostics message",{exception:xt(Ne)})}return ue}function Re(ne,ue,Ne,Se,Pe,Fe,Te){if(!Pe)return;function it(lt,pe,qr){var ra=qr||{};ra.fetchDiagnosticsMessage=Z(Ne),pe&&(ra.exception=xt(pe)),Ol(dt,lt,"Failed to calculate the duration of the fetch call, monitoring data for this fetch call won't be sent.",ra)}Pe.responseFinishedTime=El(),Pe.status=ue,ot("fetch",Pe,function(){var lt=Pe.CreateTrackItem("Fetch",c,Fe),pe;try{_t&&(pe=_t({status:ue,request:Ne,response:Se}))}catch{Ol(dt,we.FailedAddingCustomDefinedRequestContext,"Failed to add custom defined request context as configured call back may missing a null check.")}lt?(pe!==void 0&&(lt.properties=Br(Br({},lt.properties),pe)),dt[a](lt)):it(we.FailedMonitorAjaxDur,null,{requestSentTime:Pe.requestSentTime,responseFinishedTime:Pe.responseFinishedTime})},function(lt){it(we.FailedMonitorAjaxGetCorrelationHeader,lt,null)})}function ke(ne){if(ne&&ne.headers)try{var ue=ne.headers.get(Zt.requestContextHeader);return Wi.getCorrelationContext(ue)}catch(Ne){Ol(dt,we.FailedMonitorAjaxGetCorrelationHeader,"Failed to get Request-Context correlation header as it may be not included in the response or not accessible.",{fetchDiagnosticsMessage:Z(ne),exception:xt(Ne)})}}}),t}return e.getDefaultConfig=function(){var t={maxAjaxCallsPerView:500,disableAjaxTracking:!1,disableFetchTracking:!0,excludeRequestFromAutoTrackingPatterns:void 0,disableCorrelationHeaders:!1,distributedTracingMode:Sn.AI_AND_W3C,correlationHeaderExcludedDomains:["*.blob.core.windows.net","*.blob.core.chinacloudapi.cn","*.blob.core.cloudapi.de","*.blob.core.usgovcloudapi.net"],correlationHeaderDomains:void 0,correlationHeaderExcludePatterns:void 0,appId:void 0,enableCorsCorrelation:!1,enableRequestHeaderTracking:!1,enableResponseHeaderTracking:!1,enableAjaxErrorStatusText:!1,enableAjaxPerfTracking:!1,maxAjaxPerfLookupAttempts:3,ajaxPerfLookupDelay:25,ignoreHeaders:["Authorization","X-API-Key","WWW-Authenticate"],addRequestContext:void 0};return t},e.getEmptyConfig=function(){var t=this.getDefaultConfig();return Xt(t,function(a){t[a]=void 0}),t},e.prototype.processTelemetry=function(t,a){this.processNext(t,a)},e.identifier="AjaxDependencyPlugin",e}(Kn);var Bx,BP=["snippet","dependencies","properties","_snippetVersion","appInsightsNew","getSKUDefaults"];var Ox=function(){function r(e){var t=this;t._snippetVersion=""+(e.sv||e.version||""),e.queue=e.queue||[],e.version=e.version||2;var a=e.config||{};if(a.connectionString){var n=ux(a.connectionString),i=n.ingestionendpoint;a.endpointUrl=i?"".concat(i,"/v2/track"):a.endpointUrl,a.instrumentationKey=n.instrumentationkey||a.instrumentationKey}t.appInsights=new Nx,t.properties=new wx,t.dependencies=new Ax,t.core=new Ky,t._sender=new Ex,t.snippet=e,t.config=a,t.getSKUDefaults()}return r.prototype.getCookieMgr=function(){return this.appInsights.getCookieMgr()},r.prototype.trackEvent=function(e,t){this.appInsights.trackEvent(e,t)},r.prototype.trackPageView=function(e){var t=e||{};this.appInsights.trackPageView(t)},r.prototype.trackPageViewPerformance=function(e){var t=e||{};this.appInsights.trackPageViewPerformance(t)},r.prototype.trackException=function(e,t){e&&!e.exception&&e.error&&(e.exception=e.error),this.appInsights.trackException(e,t)},r.prototype._onerror=function(e){this.appInsights._onerror(e)},r.prototype.trackTrace=function(e,t){this.appInsights.trackTrace(e,t)},r.prototype.trackMetric=function(e,t){this.appInsights.trackMetric(e,t)},r.prototype.startTrackPage=function(e){this.appInsights.startTrackPage(e)},r.prototype.stopTrackPage=function(e,t,a,n){this.appInsights.stopTrackPage(e,t,a,n)},r.prototype.startTrackEvent=function(e){this.appInsights.startTrackEvent(e)},r.prototype.stopTrackEvent=function(e,t,a){this.appInsights.stopTrackEvent(e,t,a)},r.prototype.addTelemetryInitializer=function(e){return this.appInsights.addTelemetryInitializer(e)},r.prototype.setAuthenticatedUserContext=function(e,t,a){a===void 0&&(a=!1),this.properties.context.user.setAuthenticatedUserContext(e,t,a)},r.prototype.clearAuthenticatedUserContext=function(){this.properties.context.user.clearAuthenticatedUserContext()},r.prototype.trackDependencyData=function(e){this.dependencies.trackDependencyData(e)},r.prototype.flush=function(e){var t=this;e===void 0&&(e=!0),Ci(this.core,function(){return"AISKU.flush"},function(){ft(t.core.getTransmissionControls(),function(a){ft(a,function(n){n.flush(e)})})},null,e)},r.prototype.onunloadFlush=function(e){e===void 0&&(e=!0),ft(this.core.getTransmissionControls(),function(t){ft(t,function(a){a.onunloadFlush?a.onunloadFlush():a.flush(e)})})},r.prototype.loadAppInsights=function(e,t,a){var n=this;e===void 0&&(e=!1);var i=this;function s(o){if(o){var l="";Le(i._snippetVersion)||(l+=i._snippetVersion),e&&(l+=".lg"),i.context&&i.context.internal&&(i.context.internal.snippetVer=l||"-"),Xt(i,function(c,p){pt(c)&&!vt(p)&&c&&c[0]!=="_"&&BP.indexOf(c)===-1&&(o[c]=p)})}}return e&&i.config.extensions&&i.config.extensions.length>0&&ga("Extensions not allowed in legacy mode"),Ci(i.core,function(){return"AISKU.loadAppInsights"},function(){var o=[];o.push(i._sender),o.push(i.properties),o.push(i.dependencies),o.push(i.appInsights),i.core.initialize(i.config,o,t,a),i.context=i.properties.context,Bx&&i.context&&(i.context.internal.sdkSrc=Bx),s(i.snippet),i.emptyQueue(),i.pollInternalLogs(),i.addHousekeepingBeforeUnload(n)}),i},r.prototype.updateSnippetDefinitions=function(e){gy(e,this,function(t){return t&&BP.indexOf(t)===-1})},r.prototype.emptyQueue=function(){var e=this;try{if(Yr(e.snippet.queue)){for(var t=e.snippet.queue.length,a=0;a<t;a++){var n=e.snippet.queue[a];n()}e.snippet.queue=void 0,delete e.snippet.queue}}catch(s){var i={};s&&vt(s.toString)&&(i.exception=s.toString())}},r.prototype.pollInternalLogs=function(){this.core.pollInternalLogs()},r.prototype.stopPollingInternalLogs=function(){this.core.stopPollingInternalLogs()},r.prototype.addHousekeepingBeforeUnload=function(e){if(mo()||Ru()){var t=function(){e.onunloadFlush(!1),ft(e.appInsights.core._extensions,function(i){if(i.identifier===Rs)return i&&i.context&&i.context._sessionManager&&i.context._sessionManager.backup(),-1})},a=!1,n=e.appInsights.config.disablePageUnloadEvents;e.appInsights.config.disableFlushOnBeforeUnload||(a=$y(t,n),a=qc(t,n)||a,!a&&!Iy()&&e.appInsights.core.logger.throwInternal(Oe.CRITICAL,we.FailedToAddHandlerForOnBeforeUnload,"Could not add handler for beforeunload and pagehide")),!a&&!e.appInsights.config.disableFlushOnUnload&&qc(t,n)}},r.prototype.getSender=function(){return this._sender},r.prototype.getSKUDefaults=function(){var e=this;e.config.diagnosticLogInterval=e.config.diagnosticLogInterval&&e.config.diagnosticLogInterval>0?e.config.diagnosticLogInterval:1e4},r}();(function(){var r=null,e=!1,t=["://js.monitor.azure.com/","://az416426.vo.msecnd.net/"];try{var a=(document||{}).currentScript;a&&(r=a.src)}catch{}if(r)try{var n=r.toLowerCase();if(n){for(var i="",s=0;s<t.length;s++)if(n.indexOf(t[s])!==-1){i="cdn"+(s+1),n.indexOf("/scripts/")===-1&&(n.indexOf("/next/")!==-1?i+="-next":n.indexOf("/beta/")!==-1&&(i+="-beta")),Bx=i+(e?".mod":"");break}}}catch{}})();var Ll,OP=r=>(Ll=new Ox({config:{instrumentationKey:r}}),Ll.loadAppInsights(),Ll),Qc={START:"start",FINISH:"finish",ERROR:"error",UPLOAD_VIDEO:"upload_video",START_RECORD:"start_record",FILE:"file"},y5=r=>Ll.trackException({exception:r}),Zc=(r,e)=>Ll.trackEvent({name:r,properties:e}),x5=(r,e,t)=>Ll.trackPageView({name:r,uri:e,properties:t}),St={trackPage:x5,trackError:y5,registerStart:(r,e,t)=>Zc(Qc.START,{proctoringId:r,success:e,description:t}),registerFinish:(r,e,t)=>Zc(Qc.FINISH,{proctoringId:r,success:e,description:t}),registerError:(r,e)=>Zc(Qc.ERROR,{proctoringId:r,description:e}),registerUploadVideo:(r,e,t,a)=>Zc(Qc.UPLOAD_VIDEO,{proctoringId:r,success:e,description:t,uploadTime:a}),registerRecord:(r,e,t)=>Zc(Qc.START_RECORD,{proctoringId:r,success:e,description:t})};function Jc(r,e){return function(){return r.apply(e,arguments)}}var{toString:LP}=Object.prototype,{getPrototypeOf:qx}=Object,Hx=(r=>e=>{let t=LP.call(e);return r[t]||(r[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),Qi=r=>(r=r.toLowerCase(),e=>Hx(e)===r),ep=r=>e=>typeof e===r,{isArray:em}=Array,zx=ep("undefined");function g5(r){return r!==null&&!zx(r)&&r.constructor!==null&&!zx(r.constructor)&&ql(r.constructor.isBuffer)&&r.constructor.isBuffer(r)}var qP=Qi("ArrayBuffer");function v5(r){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(r):e=r&&r.buffer&&qP(r.buffer),e}var _5=ep("string"),ql=ep("function"),HP=ep("number"),DP=r=>r!==null&&typeof r=="object",b5=r=>r===!0||r===!1,Ju=r=>{if(Hx(r)!=="object")return!1;let e=qx(r);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in r)&&!(Symbol.iterator in r)},S5=Qi("Date"),N5=Qi("File"),P5=Qi("Blob"),C5=Qi("FileList"),R5=r=>DP(r)&&ql(r.pipe),E5=r=>{let e="[object FormData]";return r&&(typeof FormData=="function"&&r instanceof FormData||LP.call(r)===e||ql(r.toString)&&r.toString()===e)},T5=Qi("URLSearchParams"),w5=r=>r.trim?r.trim():r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function tp(r,e,{allOwnKeys:t=!1}={}){if(r===null||typeof r>"u")return;let a,n;if(typeof r!="object"&&(r=[r]),em(r))for(a=0,n=r.length;a<n;a++)e.call(null,r[a],a,r);else{let i=t?Object.getOwnPropertyNames(r):Object.keys(r),s=i.length,o;for(a=0;a<s;a++)o=i[a],e.call(null,r[o],o,r)}}function Lx(){let r={},e=(t,a)=>{Ju(r[a])&&Ju(t)?r[a]=Lx(r[a],t):Ju(t)?r[a]=Lx({},t):em(t)?r[a]=t.slice():r[a]=t};for(let t=0,a=arguments.length;t<a;t++)arguments[t]&&tp(arguments[t],e);return r}var I5=(r,e,t,{allOwnKeys:a}={})=>(tp(e,(n,i)=>{t&&ql(n)?r[i]=Jc(n,t):r[i]=n},{allOwnKeys:a}),r),M5=r=>(r.charCodeAt(0)===65279&&(r=r.slice(1)),r),A5=(r,e,t,a)=>{r.prototype=Object.create(e.prototype,a),r.prototype.constructor=r,Object.defineProperty(r,"super",{value:e.prototype}),t&&Object.assign(r.prototype,t)},B5=(r,e,t,a)=>{let n,i,s,o={};if(e=e||{},r==null)return e;do{for(n=Object.getOwnPropertyNames(r),i=n.length;i-- >0;)s=n[i],(!a||a(s,r,e))&&!o[s]&&(e[s]=r[s],o[s]=!0);r=t!==!1&&qx(r)}while(r&&(!t||t(r,e))&&r!==Object.prototype);return e},O5=(r,e,t)=>{r=String(r),(t===void 0||t>r.length)&&(t=r.length),t-=e.length;let a=r.indexOf(e,t);return a!==-1&&a===t},z5=r=>{if(!r)return null;if(em(r))return r;let e=r.length;if(!HP(e))return null;let t=new Array(e);for(;e-- >0;)t[e]=r[e];return t},L5=(r=>e=>r&&e instanceof r)(typeof Uint8Array<"u"&&qx(Uint8Array)),q5=(r,e)=>{let a=(r&&r[Symbol.iterator]).call(r),n;for(;(n=a.next())&&!n.done;){let i=n.value;e.call(r,i[0],i[1])}},H5=(r,e)=>{let t,a=[];for(;(t=r.exec(e))!==null;)a.push(t);return a},D5=Qi("HTMLFormElement"),k5=r=>r.toLowerCase().replace(/[_-\s]([a-z\d])(\w*)/g,function(t,a,n){return a.toUpperCase()+n}),zP=(({hasOwnProperty:r})=>(e,t)=>r.call(e,t))(Object.prototype),F5=Qi("RegExp"),kP=(r,e)=>{let t=Object.getOwnPropertyDescriptors(r),a={};tp(t,(n,i)=>{e(n,i,r)!==!1&&(a[i]=n)}),Object.defineProperties(r,a)},U5=r=>{kP(r,(e,t)=>{let a=r[t];if(!!ql(a)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not read-only method '"+t+"'")})}})},j5=(r,e)=>{let t={},a=n=>{n.forEach(i=>{t[i]=!0})};return em(r)?a(r):a(String(r).split(e)),t},V5=()=>{},G5=(r,e)=>(r=+r,Number.isFinite(r)?r:e),be={isArray:em,isArrayBuffer:qP,isBuffer:g5,isFormData:E5,isArrayBufferView:v5,isString:_5,isNumber:HP,isBoolean:b5,isObject:DP,isPlainObject:Ju,isUndefined:zx,isDate:S5,isFile:N5,isBlob:P5,isRegExp:F5,isFunction:ql,isStream:R5,isURLSearchParams:T5,isTypedArray:L5,isFileList:C5,forEach:tp,merge:Lx,extend:I5,trim:w5,stripBOM:M5,inherits:A5,toFlatObject:B5,kindOf:Hx,kindOfTest:Qi,endsWith:O5,toArray:z5,forEachEntry:q5,matchAll:H5,isHTMLForm:D5,hasOwnProperty:zP,hasOwnProp:zP,reduceDescriptors:kP,freezeMethods:U5,toObjectSet:j5,toCamelCase:k5,noop:V5,toFiniteNumber:G5};function Hl(r,e,t,a,n){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=r,this.name="AxiosError",e&&(this.code=e),t&&(this.config=t),a&&(this.request=a),n&&(this.response=n)}be.inherits(Hl,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var FP=Hl.prototype,UP={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(r=>{UP[r]={value:r}});Object.defineProperties(Hl,UP);Object.defineProperty(FP,"isAxiosError",{value:!0});Hl.from=(r,e,t,a,n,i)=>{let s=Object.create(FP);return be.toFlatObject(r,s,function(l){return l!==Error.prototype},o=>o!=="isAxiosError"),Hl.call(s,r.message,e,t,a,n),s.cause=r,s.name=r.name,i&&Object.assign(s,i),s};var Gt=Hl;var GP=ns(VP(),1),KP=GP.default;function Dx(r){return be.isPlainObject(r)||be.isArray(r)}function $P(r){return be.endsWith(r,"[]")?r.slice(0,-2):r}function XP(r,e,t){return r?r.concat(e).map(function(n,i){return n=$P(n),!t&&i?"["+n+"]":n}).join(t?".":""):e}function K5(r){return be.isArray(r)&&!r.some(Dx)}var X5=be.toFlatObject(be,{},null,function(e){return/^is[A-Z]/.test(e)});function $5(r){return r&&be.isFunction(r.append)&&r[Symbol.toStringTag]==="FormData"&&r[Symbol.iterator]}function W5(r,e,t){if(!be.isObject(r))throw new TypeError("target must be an object");e=e||new(KP||FormData),t=be.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(q,C){return!be.isUndefined(C[q])});let a=t.metaTokens,n=t.visitor||p,i=t.dots,s=t.indexes,l=(t.Blob||typeof Blob<"u"&&Blob)&&$5(e);if(!be.isFunction(n))throw new TypeError("visitor must be a function");function c(E){if(E===null)return"";if(be.isDate(E))return E.toISOString();if(!l&&be.isBlob(E))throw new Gt("Blob is not supported. Use a Buffer instead.");return be.isArrayBuffer(E)||be.isTypedArray(E)?l&&typeof Blob=="function"?new Blob([E]):Buffer.from(E):E}function p(E,q,C){let W=E;if(E&&!C&&typeof E=="object"){if(be.endsWith(q,"{}"))q=a?q:q.slice(0,-2),E=JSON.stringify(E);else if(be.isArray(E)&&K5(E)||be.isFileList(E)||be.endsWith(q,"[]")&&(W=be.toArray(E)))return q=$P(q),W.forEach(function(Ce,et){!(be.isUndefined(Ce)||Ce===null)&&e.append(s===!0?XP([q],et,i):s===null?q:q+"[]",c(Ce))}),!1}return Dx(E)?!0:(e.append(XP(C,q,i),c(E)),!1)}let M=[],S=Object.assign(X5,{defaultVisitor:p,convertValue:c,isVisitable:Dx});function O(E,q){if(!be.isUndefined(E)){if(M.indexOf(E)!==-1)throw Error("Circular reference detected in "+q.join("."));M.push(E),be.forEach(E,function(W,ae){(!(be.isUndefined(W)||W===null)&&n.call(e,W,be.isString(ae)?ae.trim():ae,q,S))===!0&&O(W,q?q.concat(ae):[ae])}),M.pop()}}if(!be.isObject(r))throw new TypeError("data must be an object");return O(r),e}var ws=W5;function WP(r){let e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(r).replace(/[!'()~]|%20|%00/g,function(a){return e[a]})}function YP(r,e){this._pairs=[],r&&ws(r,this,e)}var QP=YP.prototype;QP.append=function(e,t){this._pairs.push([e,t])};QP.toString=function(e){let t=e?function(a){return e.call(this,a,WP)}:WP;return this._pairs.map(function(n){return t(n[0])+"="+t(n[1])},"").join("&")};var rp=YP;function Y5(r){return encodeURIComponent(r).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function tm(r,e,t){if(!e)return r;let a=t&&t.encode||Y5,n=t&&t.serialize,i;if(n?i=n(e,t):i=be.isURLSearchParams(e)?e.toString():new rp(e,t).toString(a),i){let s=r.indexOf("#");s!==-1&&(r=r.slice(0,s)),r+=(r.indexOf("?")===-1?"?":"&")+i}return r}var kx=class{constructor(){this.handlers=[]}use(e,t,a){return this.handlers.push({fulfilled:e,rejected:t,synchronous:a?a.synchronous:!1,runWhen:a?a.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){be.forEach(this.handlers,function(a){a!==null&&e(a)})}},Fx=kx;var ap={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1};var ZP=typeof URLSearchParams<"u"?URLSearchParams:rp;var JP=FormData;var Q5=(()=>{let r;return typeof navigator<"u"&&((r=navigator.product)==="ReactNative"||r==="NativeScript"||r==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),wa={isBrowser:!0,classes:{URLSearchParams:ZP,FormData:JP,Blob},isStandardBrowserEnv:Q5,protocols:["http","https","file","blob","url","data"]};function Ux(r,e){return ws(r,new wa.classes.URLSearchParams,Object.assign({visitor:function(t,a,n,i){return wa.isNode&&be.isBuffer(t)?(this.append(a,t.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},e))}function Z5(r){return be.matchAll(/\w+|\[(\w*)]/g,r).map(e=>e[0]==="[]"?"":e[1]||e[0])}function J5(r){let e={},t=Object.keys(r),a,n=t.length,i;for(a=0;a<n;a++)i=t[a],e[i]=r[i];return e}function eI(r){function e(t,a,n,i){let s=t[i++],o=Number.isFinite(+s),l=i>=t.length;return s=!s&&be.isArray(n)?n.length:s,l?(be.hasOwnProp(n,s)?n[s]=[n[s],a]:n[s]=a,!o):((!n[s]||!be.isObject(n[s]))&&(n[s]=[]),e(t,a,n[s],i)&&be.isArray(n[s])&&(n[s]=J5(n[s])),!o)}if(be.isFormData(r)&&be.isFunction(r.entries)){let t={};return be.forEachEntry(r,(a,n)=>{e(Z5(a),n,t,0)}),t}return null}var np=eI;function jx(r,e,t){let a=t.config.validateStatus;!t.status||!a||a(t.status)?r(t):e(new Gt("Request failed with status code "+t.status,[Gt.ERR_BAD_REQUEST,Gt.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}var e3=wa.isStandardBrowserEnv?function(){return{write:function(t,a,n,i,s,o){let l=[];l.push(t+"="+encodeURIComponent(a)),be.isNumber(n)&&l.push("expires="+new Date(n).toGMTString()),be.isString(i)&&l.push("path="+i),be.isString(s)&&l.push("domain="+s),o===!0&&l.push("secure"),document.cookie=l.join("; ")},read:function(t){let a=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return a?decodeURIComponent(a[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function Vx(r){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(r)}function Gx(r,e){return e?r.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):r}function rm(r,e){return r&&!Vx(e)?Gx(r,e):e}var t3=wa.isStandardBrowserEnv?function(){let e=/(msie|trident)/i.test(navigator.userAgent),t=document.createElement("a"),a;function n(i){let s=i;return e&&(t.setAttribute("href",s),s=t.href),t.setAttribute("href",s),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:t.pathname.charAt(0)==="/"?t.pathname:"/"+t.pathname}}return a=n(window.location.href),function(s){let o=be.isString(s)?n(s):s;return o.protocol===a.protocol&&o.host===a.host}}():function(){return function(){return!0}}();function r3(r,e,t){Gt.call(this,r??"canceled",Gt.ERR_CANCELED,e,t),this.name="CanceledError"}be.inherits(r3,Gt,{__CANCEL__:!0});var Is=r3;function Kx(r){let e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(r);return e&&e[1]||""}var tI=be.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),a3=r=>{let e={},t,a,n;return r&&r.split(`
28
- `).forEach(function(s){n=s.indexOf(":"),t=s.substring(0,n).trim().toLowerCase(),a=s.substring(n+1).trim(),!(!t||e[t]&&tI[t])&&(t==="set-cookie"?e[t]?e[t].push(a):e[t]=[a]:e[t]=e[t]?e[t]+", "+a:a)}),e};var n3=Symbol("internals"),s3=Symbol("defaults");function nm(r){return r&&String(r).trim().toLowerCase()}function ip(r){return r===!1||r==null?r:be.isArray(r)?r.map(ip):String(r)}function rI(r){let e=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g,a;for(;a=t.exec(r);)e[a[1]]=a[2];return e}function i3(r,e,t,a){if(be.isFunction(a))return a.call(this,e,t);if(!!be.isString(e)){if(be.isString(a))return e.indexOf(a)!==-1;if(be.isRegExp(a))return a.test(e)}}function aI(r){return r.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,a)=>t.toUpperCase()+a)}function nI(r,e){let t=be.toCamelCase(" "+e);["get","set","has"].forEach(a=>{Object.defineProperty(r,a+t,{value:function(n,i,s){return this[a].call(this,e,n,i,s)},configurable:!0})})}function am(r,e){e=e.toLowerCase();let t=Object.keys(r),a=t.length,n;for(;a-- >0;)if(n=t[a],e===n.toLowerCase())return n;return null}function Dl(r,e){r&&this.set(r),this[s3]=e||null}Object.assign(Dl.prototype,{set:function(r,e,t){let a=this;function n(i,s,o){let l=nm(s);if(!l)throw new Error("header name must be a non-empty string");let c=am(a,l);c&&o!==!0&&(a[c]===!1||o===!1)||(a[c||s]=ip(i))}return be.isPlainObject(r)?be.forEach(r,(i,s)=>{n(i,s,e)}):n(e,r,t),this},get:function(r,e){if(r=nm(r),!r)return;let t=am(this,r);if(t){let a=this[t];if(!e)return a;if(e===!0)return rI(a);if(be.isFunction(e))return e.call(this,a,t);if(be.isRegExp(e))return e.exec(a);throw new TypeError("parser must be boolean|regexp|function")}},has:function(r,e){if(r=nm(r),r){let t=am(this,r);return!!(t&&(!e||i3(this,this[t],t,e)))}return!1},delete:function(r,e){let t=this,a=!1;function n(i){if(i=nm(i),i){let s=am(t,i);s&&(!e||i3(t,t[s],s,e))&&(delete t[s],a=!0)}}return be.isArray(r)?r.forEach(n):n(r),a},clear:function(){return Object.keys(this).forEach(this.delete.bind(this))},normalize:function(r){let e=this,t={};return be.forEach(this,(a,n)=>{let i=am(t,n);if(i){e[i]=ip(a),delete e[n];return}let s=r?aI(n):String(n).trim();s!==n&&delete e[n],e[s]=ip(a),t[s]=!0}),this},toJSON:function(r){let e=Object.create(null);return be.forEach(Object.assign({},this[s3]||null,this),(t,a)=>{t==null||t===!1||(e[a]=r&&be.isArray(t)?t.join(", "):t)}),e}});Object.assign(Dl,{from:function(r){return be.isString(r)?new this(a3(r)):r instanceof this?r:new this(r)},accessor:function(r){let t=(this[n3]=this[n3]={accessors:{}}).accessors,a=this.prototype;function n(i){let s=nm(i);t[s]||(nI(a,i),t[s]=!0)}return be.isArray(r)?r.forEach(n):n(r),this}});Dl.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent"]);be.freezeMethods(Dl.prototype);be.freezeMethods(Dl);var Qn=Dl;function iI(r,e){r=r||10;let t=new Array(r),a=new Array(r),n=0,i=0,s;return e=e!==void 0?e:1e3,function(l){let c=Date.now(),p=a[i];s||(s=c),t[n]=l,a[n]=c;let M=i,S=0;for(;M!==n;)S+=t[M++],M=M%r;if(n=(n+1)%r,n===i&&(i=(i+1)%r),c-s<e)return;let O=p&&c-p;return O?Math.round(S*1e3/O):void 0}}var o3=iI;function l3(r,e){let t=0,a=o3(50,250);return n=>{let i=n.loaded,s=n.lengthComputable?n.total:void 0,o=i-t,l=a(o),c=i<=s;t=i;let p={loaded:i,total:s,progress:s?i/s:void 0,bytes:o,rate:l||void 0,estimated:l&&s&&c?(s-i)/l:void 0};p[e?"download":"upload"]=!0,r(p)}}function im(r){return new Promise(function(t,a){let n=r.data,i=Qn.from(r.headers).normalize(),s=r.responseType,o;function l(){r.cancelToken&&r.cancelToken.unsubscribe(o),r.signal&&r.signal.removeEventListener("abort",o)}be.isFormData(n)&&wa.isStandardBrowserEnv&&i.setContentType(!1);let c=new XMLHttpRequest;if(r.auth){let O=r.auth.username||"",E=r.auth.password?unescape(encodeURIComponent(r.auth.password)):"";i.set("Authorization","Basic "+btoa(O+":"+E))}let p=rm(r.baseURL,r.url);c.open(r.method.toUpperCase(),tm(p,r.params,r.paramsSerializer),!0),c.timeout=r.timeout;function M(){if(!c)return;let O=Qn.from("getAllResponseHeaders"in c&&c.getAllResponseHeaders()),q={data:!s||s==="text"||s==="json"?c.responseText:c.response,status:c.status,statusText:c.statusText,headers:O,config:r,request:c};jx(function(W){t(W),l()},function(W){a(W),l()},q),c=null}if("onloadend"in c?c.onloadend=M:c.onreadystatechange=function(){!c||c.readyState!==4||c.status===0&&!(c.responseURL&&c.responseURL.indexOf("file:")===0)||setTimeout(M)},c.onabort=function(){!c||(a(new Gt("Request aborted",Gt.ECONNABORTED,r,c)),c=null)},c.onerror=function(){a(new Gt("Network Error",Gt.ERR_NETWORK,r,c)),c=null},c.ontimeout=function(){let E=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded",q=r.transitional||ap;r.timeoutErrorMessage&&(E=r.timeoutErrorMessage),a(new Gt(E,q.clarifyTimeoutError?Gt.ETIMEDOUT:Gt.ECONNABORTED,r,c)),c=null},wa.isStandardBrowserEnv){let O=(r.withCredentials||t3(p))&&r.xsrfCookieName&&e3.read(r.xsrfCookieName);O&&i.set(r.xsrfHeaderName,O)}n===void 0&&i.setContentType(null),"setRequestHeader"in c&&be.forEach(i.toJSON(),function(E,q){c.setRequestHeader(q,E)}),be.isUndefined(r.withCredentials)||(c.withCredentials=!!r.withCredentials),s&&s!=="json"&&(c.responseType=r.responseType),typeof r.onDownloadProgress=="function"&&c.addEventListener("progress",l3(r.onDownloadProgress,!0)),typeof r.onUploadProgress=="function"&&c.upload&&c.upload.addEventListener("progress",l3(r.onUploadProgress)),(r.cancelToken||r.signal)&&(o=O=>{!c||(a(!O||O.type?new Is(null,r,c):O),c.abort(),c=null)},r.cancelToken&&r.cancelToken.subscribe(o),r.signal&&(r.signal.aborted?o():r.signal.addEventListener("abort",o)));let S=Kx(p);if(S&&wa.protocols.indexOf(S)===-1){a(new Gt("Unsupported protocol "+S+":",Gt.ERR_BAD_REQUEST,r));return}c.send(n||null)})}var c3={http:im,xhr:im},Xx={getAdapter:r=>{if(be.isString(r)){let e=c3[r];if(!r)throw Error(be.hasOwnProp(r)?`Adapter '${r}' is not available in the build`:`Can not resolve adapter '${r}'`);return e}if(!be.isFunction(r))throw new TypeError("adapter is not a function");return r},adapters:c3};var sI={"Content-Type":"application/x-www-form-urlencoded"};function oI(){let r;return typeof XMLHttpRequest<"u"?r=Xx.getAdapter("xhr"):typeof process<"u"&&be.kindOf(process)==="process"&&(r=Xx.getAdapter("http")),r}function lI(r,e,t){if(be.isString(r))try{return(e||JSON.parse)(r),be.trim(r)}catch(a){if(a.name!=="SyntaxError")throw a}return(t||JSON.stringify)(r)}var sp={transitional:ap,adapter:oI(),transformRequest:[function(e,t){let a=t.getContentType()||"",n=a.indexOf("application/json")>-1,i=be.isObject(e);if(i&&be.isHTMLForm(e)&&(e=new FormData(e)),be.isFormData(e))return n&&n?JSON.stringify(np(e)):e;if(be.isArrayBuffer(e)||be.isBuffer(e)||be.isStream(e)||be.isFile(e)||be.isBlob(e))return e;if(be.isArrayBufferView(e))return e.buffer;if(be.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let o;if(i){if(a.indexOf("application/x-www-form-urlencoded")>-1)return Ux(e,this.formSerializer).toString();if((o=be.isFileList(e))||a.indexOf("multipart/form-data")>-1){let l=this.env&&this.env.FormData;return ws(o?{"files[]":e}:e,l&&new l,this.formSerializer)}}return i||n?(t.setContentType("application/json",!1),lI(e)):e}],transformResponse:[function(e){let t=this.transitional||sp.transitional,a=t&&t.forcedJSONParsing,n=this.responseType==="json";if(e&&be.isString(e)&&(a&&!this.responseType||n)){let s=!(t&&t.silentJSONParsing)&&n;try{return JSON.parse(e)}catch(o){if(s)throw o.name==="SyntaxError"?Gt.from(o,Gt.ERR_BAD_RESPONSE,this,null,this.response):o}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:wa.classes.FormData,Blob:wa.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};be.forEach(["delete","get","head"],function(e){sp.headers[e]={}});be.forEach(["post","put","patch"],function(e){sp.headers[e]=be.merge(sI)});var kl=sp;function sm(r,e){let t=this||kl,a=e||t,n=Qn.from(a.headers),i=a.data;return be.forEach(r,function(o){i=o.call(t,i,n.normalize(),e?e.status:void 0)}),n.normalize(),i}function om(r){return!!(r&&r.__CANCEL__)}function $x(r){if(r.cancelToken&&r.cancelToken.throwIfRequested(),r.signal&&r.signal.aborted)throw new Is}function op(r){return $x(r),r.headers=Qn.from(r.headers),r.data=sm.call(r,r.transformRequest),(r.adapter||kl.adapter)(r).then(function(a){return $x(r),a.data=sm.call(r,r.transformResponse,a),a.headers=Qn.from(a.headers),a},function(a){return om(a)||($x(r),a&&a.response&&(a.response.data=sm.call(r,r.transformResponse,a.response),a.response.headers=Qn.from(a.response.headers))),Promise.reject(a)})}function Ms(r,e){e=e||{};let t={};function a(c,p){return be.isPlainObject(c)&&be.isPlainObject(p)?be.merge(c,p):be.isPlainObject(p)?be.merge({},p):be.isArray(p)?p.slice():p}function n(c){if(be.isUndefined(e[c])){if(!be.isUndefined(r[c]))return a(void 0,r[c])}else return a(r[c],e[c])}function i(c){if(!be.isUndefined(e[c]))return a(void 0,e[c])}function s(c){if(be.isUndefined(e[c])){if(!be.isUndefined(r[c]))return a(void 0,r[c])}else return a(void 0,e[c])}function o(c){if(c in e)return a(r[c],e[c]);if(c in r)return a(void 0,r[c])}let l={url:i,method:i,data:i,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:o};return be.forEach(Object.keys(r).concat(Object.keys(e)),function(p){let M=l[p]||n,S=M(p);be.isUndefined(S)&&M!==o||(t[p]=S)}),t}var lp="1.1.3";var Wx={};["object","boolean","number","function","string","symbol"].forEach((r,e)=>{Wx[r]=function(a){return typeof a===r||"a"+(e<1?"n ":" ")+r}});var m3={};Wx.transitional=function(e,t,a){function n(i,s){return"[Axios v"+lp+"] Transitional option '"+i+"'"+s+(a?". "+a:"")}return(i,s,o)=>{if(e===!1)throw new Gt(n(s," has been removed"+(t?" in "+t:"")),Gt.ERR_DEPRECATED);return t&&!m3[s]&&(m3[s]=!0,console.warn(n(s," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(i,s,o):!0}};function cI(r,e,t){if(typeof r!="object")throw new Gt("options must be an object",Gt.ERR_BAD_OPTION_VALUE);let a=Object.keys(r),n=a.length;for(;n-- >0;){let i=a[n],s=e[i];if(s){let o=r[i],l=o===void 0||s(o,i,r);if(l!==!0)throw new Gt("option "+i+" must be "+l,Gt.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new Gt("Unknown option "+i,Gt.ERR_BAD_OPTION)}}var cp={assertOptions:cI,validators:Wx};var As=cp.validators,Fl=class{constructor(e){this.defaults=e,this.interceptors={request:new Fx,response:new Fx}}request(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=Ms(this.defaults,t);let{transitional:a,paramsSerializer:n}=t;a!==void 0&&cp.assertOptions(a,{silentJSONParsing:As.transitional(As.boolean),forcedJSONParsing:As.transitional(As.boolean),clarifyTimeoutError:As.transitional(As.boolean)},!1),n!==void 0&&cp.assertOptions(n,{encode:As.function,serialize:As.function},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let i=t.headers&&be.merge(t.headers.common,t.headers[t.method]);i&&be.forEach(["delete","get","head","post","put","patch","common"],function(E){delete t.headers[E]}),t.headers=new Qn(t.headers,i);let s=[],o=!0;this.interceptors.request.forEach(function(E){typeof E.runWhen=="function"&&E.runWhen(t)===!1||(o=o&&E.synchronous,s.unshift(E.fulfilled,E.rejected))});let l=[];this.interceptors.response.forEach(function(E){l.push(E.fulfilled,E.rejected)});let c,p=0,M;if(!o){let O=[op.bind(this),void 0];for(O.unshift.apply(O,s),O.push.apply(O,l),M=O.length,c=Promise.resolve(t);p<M;)c=c.then(O[p++],O[p++]);return c}M=s.length;let S=t;for(p=0;p<M;){let O=s[p++],E=s[p++];try{S=O(S)}catch(q){E.call(this,q);break}}try{c=op.call(this,S)}catch(O){return Promise.reject(O)}for(p=0,M=l.length;p<M;)c=c.then(l[p++],l[p++]);return c}getUri(e){e=Ms(this.defaults,e);let t=rm(e.baseURL,e.url);return tm(t,e.params,e.paramsSerializer)}};be.forEach(["delete","get","head","options"],function(e){Fl.prototype[e]=function(t,a){return this.request(Ms(a||{},{method:e,url:t,data:(a||{}).data}))}});be.forEach(["post","put","patch"],function(e){function t(a){return function(i,s,o){return this.request(Ms(o||{},{method:e,headers:a?{"Content-Type":"multipart/form-data"}:{},url:i,data:s}))}}Fl.prototype[e]=t(),Fl.prototype[e+"Form"]=t(!0)});var lm=Fl;var cm=class{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(i){t=i});let a=this;this.promise.then(n=>{if(!a._listeners)return;let i=a._listeners.length;for(;i-- >0;)a._listeners[i](n);a._listeners=null}),this.promise.then=n=>{let i,s=new Promise(o=>{a.subscribe(o),i=o}).then(n);return s.cancel=function(){a.unsubscribe(i)},s},e(function(i,s,o){a.reason||(a.reason=new Is(i,s,o),t(a.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;let t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}static source(){let e;return{token:new cm(function(n){e=n}),cancel:e}}},d3=cm;function Yx(r){return function(t){return r.apply(null,t)}}function Qx(r){return be.isObject(r)&&r.isAxiosError===!0}function u3(r){let e=new lm(r),t=Jc(lm.prototype.request,e);return be.extend(t,lm.prototype,e,{allOwnKeys:!0}),be.extend(t,e,null,{allOwnKeys:!0}),t.create=function(n){return u3(Ms(r,n))},t}var ka=u3(kl);ka.Axios=lm;ka.CanceledError=Is;ka.CancelToken=d3;ka.isCancel=om;ka.VERSION=lp;ka.toFormData=ws;ka.AxiosError=Gt;ka.Cancel=ka.CanceledError;ka.all=function(e){return Promise.all(e)};ka.spread=Yx;ka.isAxiosError=Qx;ka.formToJSON=r=>np(be.isHTMLForm(r)?new FormData(r):r);var Zx=ka;var{Axios:FX,AxiosError:UX,CanceledError:jX,isCancel:VX,CancelToken:GX,VERSION:KX,all:XX,Cancel:$X,isAxiosError:WX,spread:YX,toFormData:QX}=Zx,mm=Zx;var Jx="https://proctoring-api.easyproctor.tech/api";async function eg(r){r&&(Jx="https://proctoring-api-hml.easyproctor.tech/api")}async function ln(r){let{url:e,method:t,body:a,jwt:n}=r,i=await fetch(Jx+e,{method:t,body:a!=null?JSON.stringify(a):void 0,headers:{Authorization:`Bearer ${n}`,"Content-Type":"application/json","Access-Control-Allow-Origin":"*"}});if(i.status>=400)throw"N\xE3o foi poss\xEDvel realizar a requisi\xE7\xE3o, tente novamente mais tarde";let s=i.headers.get("content-type");return(s?s.includes("application/json"):!1)?await i.json():null}async function tg(r){let{url:e,method:t,body:a,jwt:n}=r,i=await mm.request({url:Jx+e,method:t,headers:{Authorization:`Bearer ${n}`,"Access-Control-Allow-Origin":"*"},data:a});if(i.status>=400)throw"N\xE3o foi poss\xEDvel realizar a requisi\xE7\xE3o, tente novamente mais tarde";return i}var p3="",mI="",f3="",dI,dm="",uI,pI=!0;async function rg(r,e,t){p3=r,mI=e,f3=t,dI=new oo(`https://${p3}.blob.core.windows.net${f3}`)}function fI(r){St.registerError(r,dm)}async function ag(r,e,t,a){try{let{file:n,onProgress:i}=r;dm+=`Upload: ${n.type}
29
- `;let s=l=>{let c=l.loadedBytes/n.size*100;i&&i(Math.round(c))},o=await tg({url:"/AzureKey/signed-url",method:"POST",jwt:a,body:{objectName:n.name,contentType:n.type}});await mm.request({url:o.data,method:"PUT",headers:{"x-ms-blob-type":"BlockBlob"},data:n,onUploadProgress:l=>{s({loadedBytes:l.loaded})}})}catch(n){await hI(r,t,a).catch(async()=>{throw fI(e),n})}}async function hI(r,e,t){try{let{file:a,onProgress:n}=r,i=o=>{let l=o.loadedBytes/a.size*100;n&&n(Math.round(l))},s=await tg({url:"/AwsKey/signed-url",method:"POST",jwt:t,body:{objectName:a.name,contentType:a.type}});await mm.request({url:s.data,method:"PUT",headers:{"Content-Type":a.type},data:a,onUploadProgress:o=>{i({loadedBytes:o.loaded})}}).then(()=>{ln({url:"/Proctoring/aws-to-azure",method:"POST",jwt:t,body:{objectName:`${a.name}`}})})}catch(a){dm+=`
13
+ `,8*d.main_data_begin,c.ResvSize,d.resvDrain_post,d.resvDrain_pre,8*c.sideinfo_len,l-d.resvDrain_post-8*c.sideinfo_len,l,l%8,b),Ln.err.println("This is a fatal error. It has several possible causes:"),Ln.err.println("90%% LAME compiled with buggy version of gcc using advanced optimizations"),Ln.err.println(" 9%% Your system is overclocked"),Ln.err.println(" 1%% bug in LAME encoding library"),c.ResvSize=d.main_data_begin*8),vt(Oe%8==0),Oe>1e9){var v;for(v=0;v<Dt.MAX_HEADER_BUF;++v)c.header[v].write_timing-=Oe;Oe=0}return 0},this.copy_buffer=function(E,c,d,b,l){var v=z+1;if(v<=0)return 0;if(b!=0&&v>b)return-1;if(Ln.arraycopy(Fe,0,c,d,v),z=-1,ve=0,l!=0){var y=u2(1);if(y[0]=E.nMusicCRC,me.updateMusicCRC(y,c,d,v),E.nMusicCRC=y[0],v>0&&(E.VBR_seek_table.nBytesWritten+=v),E.decode_on_the_fly){for(var T=l2([2,1152]),G=v,H=-1,j;H!=0;)if(H=Re.hip_decode1_unclipped(E.hip,c,d,G,T[0],T[1]),G=0,H==-1&&(H=0),H>0){if(vt(H<=1152),E.findPeakSample){for(j=0;j<H;j++)T[0][j]>E.PeakSample?E.PeakSample=T[0][j]:-T[0][j]>E.PeakSample&&(E.PeakSample=-T[0][j]);if(E.channels_out>1)for(j=0;j<H;j++)T[1][j]>E.PeakSample?E.PeakSample=T[1][j]:-T[1][j]>E.PeakSample&&(E.PeakSample=-T[1][j])}if(E.findReplayGain&&Z.AnalyzeSamples(E.rgdata,T[0],0,T[1],0,H,E.channels_out)==qi.GAIN_ANALYSIS_ERROR)return-6}}}return v},this.init_bit_stream_w=function(E){Fe=s2(Mt.LAME_MAXMP3BUFFER),E.h_ptr=E.w_ptr=0,E.header[E.h_ptr].write_timing=0,z=-1,ve=0,Oe=0}}var aa=qo,c2=P.System,Ot=P.VbrMode,Z0=P.ShortBlock,Aa=P.new_float,R1=P.new_int_n,f2=P.new_short_n,Wr=P.assert;function or(){var C=this,$=128*1024;or.V9=410,or.V8=420,or.V7=430,or.V6=440,or.V5=450,or.V4=460,or.V3=470,or.V2=480,or.V1=490,or.V0=500,or.R3MIX=1e3,or.STANDARD=1001,or.EXTREME=1002,or.INSANE=1003,or.STANDARD_FAST=1004,or.EXTREME_FAST=1005,or.MEDIUM=1006,or.MEDIUM_FAST=1007;var ie=16384+$;or.LAME_MAXMP3BUFFER=ie;var Z,Re,J,me,Fe,Oe=new br,z,ve,pe,M;this.enc=new g,this.setModules=function(f,S,ce,xe,ke,Ve,Xe,Ge,it){Z=f,Re=S,J=ce,me=xe,Fe=ke,z=Ve,ve=Xe,pe=Ge,M=it,this.enc.setModules(Re,Oe,me,z)};function X(){this.mask_adjust=0,this.mask_adjust_short=0,this.bo_l_weight=Aa(g.SBMAX_l),this.bo_s_weight=Aa(g.SBMAX_s)}function o(){this.lowerlimit=0}function I(f,S){this.lowpass=S}var U=4294479419;function F(f){var S;return f.class_id=U,S=f.internal_flags=new Dt,f.mode=sr.NOT_SET,f.original=1,f.in_samplerate=44100,f.num_channels=2,f.num_samples=-1,f.bWriteVbrTag=!0,f.quality=-1,f.short_blocks=null,S.subblock_gain=-1,f.lowpassfreq=0,f.highpassfreq=0,f.lowpasswidth=-1,f.highpasswidth=-1,f.VBR=Ot.vbr_off,f.VBR_q=4,f.ATHcurve=-1,f.VBR_mean_bitrate_kbps=128,f.VBR_min_bitrate_kbps=0,f.VBR_max_bitrate_kbps=0,f.VBR_hard_min=0,S.VBR_min_bitrate=1,S.VBR_max_bitrate=13,f.quant_comp=-1,f.quant_comp_short=-1,f.msfix=-1,S.resample_ratio=1,S.OldValue[0]=180,S.OldValue[1]=180,S.CurrentStep[0]=4,S.CurrentStep[1]=4,S.masking_lower=1,S.nsPsy.attackthre=-1,S.nsPsy.attackthre_s=-1,f.scale=-1,f.athaa_type=-1,f.ATHtype=-1,f.athaa_loudapprox=-1,f.athaa_sensitivity=0,f.useTemporal=null,f.interChRatio=-1,S.mf_samples_to_encode=g.ENCDELAY+g.POSTDELAY,f.encoder_padding=0,S.mf_size=g.ENCDELAY-g.MDCTDELAY,f.findReplayGain=!1,f.decode_on_the_fly=!1,S.decode_on_the_fly=!1,S.findReplayGain=!1,S.findPeakSample=!1,S.RadioGain=0,S.AudiophileGain=0,S.noclipGainChange=0,S.noclipScale=-1,f.preset=0,f.write_id3tag_automatic=!0,0}this.lame_init=function(){var f=new ga,S=F(f);return S!=0?null:(f.lame_allocated_gfp=1,f)};function x(f){return f>1?0:f<=0?1:Math.cos(Math.PI/2*f)}this.nearestBitrateFullIndex=function(f){var S=[8,16,24,32,40,48,56,64,80,96,112,128,160,192,224,256,320],ce=0,xe=0,ke=0,Ve=0;Ve=S[16],ke=16,xe=S[16],ce=16;for(var Xe=0;Xe<16;Xe++)if(Math.max(f,S[Xe+1])!=f){Ve=S[Xe+1],ke=Xe+1,xe=S[Xe],ce=Xe;break}return Ve-f>f-xe?ce:ke};function p(f,S){var ce=44100;return S>=48e3?ce=48e3:S>=44100?ce=44100:S>=32e3?ce=32e3:S>=24e3?ce=24e3:S>=22050?ce=22050:S>=16e3?ce=16e3:S>=12e3?ce=12e3:S>=11025?ce=11025:S>=8e3&&(ce=8e3),f==-1?ce:(f<=15960&&(ce=44100),f<=15250&&(ce=32e3),f<=11220&&(ce=24e3),f<=9970&&(ce=22050),f<=7230&&(ce=16e3),f<=5420&&(ce=12e3),f<=4510&&(ce=11025),f<=3970&&(ce=8e3),S<ce?S>44100?48e3:S>32e3?44100:S>24e3?32e3:S>22050?24e3:S>16e3?22050:S>12e3?16e3:S>11025?12e3:S>8e3?11025:8e3:ce)}function N(f,S){switch(f){case 44100:return S.version=1,0;case 48e3:return S.version=1,1;case 32e3:return S.version=1,2;case 22050:return S.version=0,0;case 24e3:return S.version=0,1;case 16e3:return S.version=0,2;case 11025:return S.version=0,0;case 12e3:return S.version=0,1;case 8e3:return S.version=0,2;default:return S.version=0,-1}}function q(f,S,ce){ce<16e3&&(S=2);for(var xe=gt.bitrate_table[S][1],ke=2;ke<=14;ke++)gt.bitrate_table[S][ke]>0&&Math.abs(gt.bitrate_table[S][ke]-f)<Math.abs(xe-f)&&(xe=gt.bitrate_table[S][ke]);return xe}function w(f,S,ce){ce<16e3&&(S=2);for(var xe=0;xe<=14;xe++)if(gt.bitrate_table[S][xe]>0&&gt.bitrate_table[S][xe]==f)return xe;return-1}function u(f,S){var ce=[new I(8,2e3),new I(16,3700),new I(24,3900),new I(32,5500),new I(40,7e3),new I(48,7500),new I(56,1e4),new I(64,11e3),new I(80,13500),new I(96,15100),new I(112,15600),new I(128,17e3),new I(160,17500),new I(192,18600),new I(224,19400),new I(256,19700),new I(320,20500)],xe=C.nearestBitrateFullIndex(S);f.lowerlimit=ce[xe].lowpass}function L(f){var S=f.internal_flags,ce=32,xe=-1;if(S.lowpass1>0){for(var ke=999,Ve=0;Ve<=31;Ve++){var Xe=Ve/31;Xe>=S.lowpass2&&(ce=Math.min(ce,Ve)),S.lowpass1<Xe&&Xe<S.lowpass2&&(ke=Math.min(ke,Ve))}ke==999?S.lowpass1=(ce-.75)/31:S.lowpass1=(ke-.75)/31,S.lowpass2=ce/31}if(S.highpass2>0&&S.highpass2<.9*(.75/31)&&(S.highpass1=0,S.highpass2=0,c2.err.println(`Warning: highpass filter disabled. highpass frequency too small
14
+ `)),S.highpass2>0){for(var Ge=-1,Ve=0;Ve<=31;Ve++){var Xe=Ve/31;Xe<=S.highpass1&&(xe=Math.max(xe,Ve)),S.highpass1<Xe&&Xe<S.highpass2&&(Ge=Math.max(Ge,Ve))}S.highpass1=xe/31,Ge==-1?S.highpass2=(xe+.75)/31:S.highpass2=(Ge+.75)/31}for(var Ve=0;Ve<32;Ve++){var it,We,Xe=Ve/31;S.highpass2>S.highpass1?it=x((S.highpass2-Xe)/(S.highpass2-S.highpass1+1e-20)):it=1,S.lowpass2>S.lowpass1?We=x((Xe-S.lowpass1)/(S.lowpass2-S.lowpass1+1e-20)):We=1,S.amp_filter[Ve]=it*We}}function E(f){var S=f.internal_flags;switch(f.quality){default:case 9:S.psymodel=0,S.noise_shaping=0,S.noise_shaping_amp=0,S.noise_shaping_stop=0,S.use_best_huffman=0,S.full_outer_loop=0;break;case 8:f.quality=7;case 7:S.psymodel=1,S.noise_shaping=0,S.noise_shaping_amp=0,S.noise_shaping_stop=0,S.use_best_huffman=0,S.full_outer_loop=0;break;case 6:S.psymodel=1,S.noise_shaping==0&&(S.noise_shaping=1),S.noise_shaping_amp=0,S.noise_shaping_stop=0,S.subblock_gain==-1&&(S.subblock_gain=1),S.use_best_huffman=0,S.full_outer_loop=0;break;case 5:S.psymodel=1,S.noise_shaping==0&&(S.noise_shaping=1),S.noise_shaping_amp=0,S.noise_shaping_stop=0,S.subblock_gain==-1&&(S.subblock_gain=1),S.use_best_huffman=0,S.full_outer_loop=0;break;case 4:S.psymodel=1,S.noise_shaping==0&&(S.noise_shaping=1),S.noise_shaping_amp=0,S.noise_shaping_stop=0,S.subblock_gain==-1&&(S.subblock_gain=1),S.use_best_huffman=1,S.full_outer_loop=0;break;case 3:S.psymodel=1,S.noise_shaping==0&&(S.noise_shaping=1),S.noise_shaping_amp=1,S.noise_shaping_stop=1,S.subblock_gain==-1&&(S.subblock_gain=1),S.use_best_huffman=1,S.full_outer_loop=0;break;case 2:S.psymodel=1,S.noise_shaping==0&&(S.noise_shaping=1),S.substep_shaping==0&&(S.substep_shaping=2),S.noise_shaping_amp=1,S.noise_shaping_stop=1,S.subblock_gain==-1&&(S.subblock_gain=1),S.use_best_huffman=1,S.full_outer_loop=0;break;case 1:S.psymodel=1,S.noise_shaping==0&&(S.noise_shaping=1),S.substep_shaping==0&&(S.substep_shaping=2),S.noise_shaping_amp=2,S.noise_shaping_stop=1,S.subblock_gain==-1&&(S.subblock_gain=1),S.use_best_huffman=1,S.full_outer_loop=0;break;case 0:S.psymodel=1,S.noise_shaping==0&&(S.noise_shaping=1),S.substep_shaping==0&&(S.substep_shaping=2),S.noise_shaping_amp=2,S.noise_shaping_stop=1,S.subblock_gain==-1&&(S.subblock_gain=1),S.use_best_huffman=1,S.full_outer_loop=0;break}}function c(f){var S=f.internal_flags;f.frameNum=0,f.write_id3tag_automatic&&pe.id3tag_write_v2(f),S.bitrate_stereoMode_Hist=R1([16,4+1]),S.bitrate_blockType_Hist=R1([16,4+1+1]),S.PeakSample=0,f.bWriteVbrTag&&z.InitVbrTag(f)}this.lame_init_params=function(f){var S=f.internal_flags;if(S.Class_ID=0,S.ATH==null&&(S.ATH=new $f),S.PSY==null&&(S.PSY=new X),S.rgdata==null&&(S.rgdata=new Qf),S.channels_in=f.num_channels,S.channels_in==1&&(f.mode=sr.MONO),S.channels_out=f.mode==sr.MONO?1:2,S.mode_ext=g.MPG_MD_MS_LR,f.mode==sr.MONO&&(f.force_ms=!1),f.VBR==Ot.vbr_off&&f.VBR_mean_bitrate_kbps!=128&&f.brate==0&&(f.brate=f.VBR_mean_bitrate_kbps),f.VBR==Ot.vbr_off||f.VBR==Ot.vbr_mtrh||f.VBR==Ot.vbr_mt||(f.free_format=!1),f.VBR==Ot.vbr_off&&f.brate==0&&aa.EQ(f.compression_ratio,0)&&(f.compression_ratio=11.025),f.VBR==Ot.vbr_off&&f.compression_ratio>0&&(f.out_samplerate==0&&(f.out_samplerate=map2MP3Frequency(int(.97*f.in_samplerate))),f.brate=0|f.out_samplerate*16*S.channels_out/(1e3*f.compression_ratio),S.samplerate_index=N(f.out_samplerate,f),f.free_format||(f.brate=q(f.brate,f.version,f.out_samplerate))),f.out_samplerate!=0&&(f.out_samplerate<16e3?(f.VBR_mean_bitrate_kbps=Math.max(f.VBR_mean_bitrate_kbps,8),f.VBR_mean_bitrate_kbps=Math.min(f.VBR_mean_bitrate_kbps,64)):f.out_samplerate<32e3?(f.VBR_mean_bitrate_kbps=Math.max(f.VBR_mean_bitrate_kbps,8),f.VBR_mean_bitrate_kbps=Math.min(f.VBR_mean_bitrate_kbps,160)):(f.VBR_mean_bitrate_kbps=Math.max(f.VBR_mean_bitrate_kbps,32),f.VBR_mean_bitrate_kbps=Math.min(f.VBR_mean_bitrate_kbps,320))),f.lowpassfreq==0){var ce=16e3;switch(f.VBR){case Ot.vbr_off:{var xe=new o;u(xe,f.brate),ce=xe.lowerlimit;break}case Ot.vbr_abr:{var xe=new o;u(xe,f.VBR_mean_bitrate_kbps),ce=xe.lowerlimit;break}case Ot.vbr_rh:{var ke=[19500,19e3,18600,18e3,17500,16e3,15600,14900,12500,1e4,3950];if(0<=f.VBR_q&&f.VBR_q<=9){var Ve=ke[f.VBR_q],Xe=ke[f.VBR_q+1],Ge=f.VBR_q_frac;ce=linear_int(Ve,Xe,Ge)}else ce=19500;break}default:{var ke=[19500,19e3,18500,18e3,17500,16500,15500,14500,12500,9500,3950];if(0<=f.VBR_q&&f.VBR_q<=9){var Ve=ke[f.VBR_q],Xe=ke[f.VBR_q+1],Ge=f.VBR_q_frac;ce=linear_int(Ve,Xe,Ge)}else ce=19500}}f.mode==sr.MONO&&(f.VBR==Ot.vbr_off||f.VBR==Ot.vbr_abr)&&(ce*=1.5),f.lowpassfreq=ce|0}if(f.out_samplerate==0&&(2*f.lowpassfreq>f.in_samplerate&&(f.lowpassfreq=f.in_samplerate/2),f.out_samplerate=p(f.lowpassfreq|0,f.in_samplerate)),f.lowpassfreq=Math.min(20500,f.lowpassfreq),f.lowpassfreq=Math.min(f.out_samplerate/2,f.lowpassfreq),f.VBR==Ot.vbr_off&&(f.compression_ratio=f.out_samplerate*16*S.channels_out/(1e3*f.brate)),f.VBR==Ot.vbr_abr&&(f.compression_ratio=f.out_samplerate*16*S.channels_out/(1e3*f.VBR_mean_bitrate_kbps)),f.bWriteVbrTag||(f.findReplayGain=!1,f.decode_on_the_fly=!1,S.findPeakSample=!1),S.findReplayGain=f.findReplayGain,S.decode_on_the_fly=f.decode_on_the_fly,S.decode_on_the_fly&&(S.findPeakSample=!0),S.findReplayGain&&Z.InitGainAnalysis(S.rgdata,f.out_samplerate)==qi.INIT_GAIN_ANALYSIS_ERROR)return f.internal_flags=null,-6;switch(S.decode_on_the_fly&&!f.decode_only&&(S.hip!=null&&M.hip_decode_exit(S.hip),S.hip=M.hip_decode_init()),S.mode_gr=f.out_samplerate<=24e3?1:2,f.framesize=576*S.mode_gr,f.encoder_delay=g.ENCDELAY,S.resample_ratio=f.in_samplerate/f.out_samplerate,f.VBR){case Ot.vbr_mt:case Ot.vbr_rh:case Ot.vbr_mtrh:{var it=[5.7,6.5,7.3,8.2,10,11.9,13,14,15,16.5];f.compression_ratio=it[f.VBR_q]}break;case Ot.vbr_abr:f.compression_ratio=f.out_samplerate*16*S.channels_out/(1e3*f.VBR_mean_bitrate_kbps);break;default:f.compression_ratio=f.out_samplerate*16*S.channels_out/(1e3*f.brate);break}if(f.mode==sr.NOT_SET&&(f.mode=sr.JOINT_STEREO),f.highpassfreq>0?(S.highpass1=2*f.highpassfreq,f.highpasswidth>=0?S.highpass2=2*(f.highpassfreq+f.highpasswidth):S.highpass2=(1+0)*2*f.highpassfreq,S.highpass1/=f.out_samplerate,S.highpass2/=f.out_samplerate):(S.highpass1=0,S.highpass2=0),f.lowpassfreq>0?(S.lowpass2=2*f.lowpassfreq,f.lowpasswidth>=0?(S.lowpass1=2*(f.lowpassfreq-f.lowpasswidth),S.lowpass1<0&&(S.lowpass1=0)):S.lowpass1=(1-0)*2*f.lowpassfreq,S.lowpass1/=f.out_samplerate,S.lowpass2/=f.out_samplerate):(S.lowpass1=0,S.lowpass2=0),L(f),S.samplerate_index=N(f.out_samplerate,f),S.samplerate_index<0)return f.internal_flags=null,-1;if(f.VBR==Ot.vbr_off){if(f.free_format)S.bitrate_index=0;else if(f.brate=q(f.brate,f.version,f.out_samplerate),S.bitrate_index=w(f.brate,f.version,f.out_samplerate),S.bitrate_index<=0)return f.internal_flags=null,-1}else S.bitrate_index=1;f.analysis&&(f.bWriteVbrTag=!1),S.pinfo!=null&&(f.bWriteVbrTag=!1),Re.init_bit_stream_w(S);for(var We=S.samplerate_index+3*f.version+6*(f.out_samplerate<16e3?1:0),je=0;je<g.SBMAX_l+1;je++)S.scalefac_band.l[je]=me.sfBandIndex[We].l[je];for(var je=0;je<g.PSFB21+1;je++){var Tt=(S.scalefac_band.l[22]-S.scalefac_band.l[21])/g.PSFB21,kt=S.scalefac_band.l[21]+je*Tt;S.scalefac_band.psfb21[je]=kt}S.scalefac_band.psfb21[g.PSFB21]=576;for(var je=0;je<g.SBMAX_s+1;je++)S.scalefac_band.s[je]=me.sfBandIndex[We].s[je];for(var je=0;je<g.PSFB12+1;je++){var Tt=(S.scalefac_band.s[13]-S.scalefac_band.s[12])/g.PSFB12,kt=S.scalefac_band.s[12]+je*Tt;S.scalefac_band.psfb12[je]=kt}S.scalefac_band.psfb12[g.PSFB12]=192,f.version==1?S.sideinfo_len=S.channels_out==1?4+17:4+32:S.sideinfo_len=S.channels_out==1?4+9:4+17,f.error_protection&&(S.sideinfo_len+=2),c(f),S.Class_ID=U;{var At;for(At=0;At<19;At++)S.nsPsy.pefirbuf[At]=700*S.mode_gr*S.channels_out;f.ATHtype==-1&&(f.ATHtype=4)}switch(Wr(f.VBR_q<=9),Wr(f.VBR_q>=0),f.VBR){case Ot.vbr_mt:f.VBR=Ot.vbr_mtrh;case Ot.vbr_mtrh:{f.useTemporal==null&&(f.useTemporal=!1),J.apply_preset(f,500-f.VBR_q*10,0),f.quality<0&&(f.quality=LAME_DEFAULT_QUALITY),f.quality<5&&(f.quality=0),f.quality>5&&(f.quality=5),S.PSY.mask_adjust=f.maskingadjust,S.PSY.mask_adjust_short=f.maskingadjust_short,f.experimentalY?S.sfb21_extra=!1:S.sfb21_extra=f.out_samplerate>44e3,S.iteration_loop=new VBRNewIterationLoop(Fe);break}case Ot.vbr_rh:{J.apply_preset(f,500-f.VBR_q*10,0),S.PSY.mask_adjust=f.maskingadjust,S.PSY.mask_adjust_short=f.maskingadjust_short,f.experimentalY?S.sfb21_extra=!1:S.sfb21_extra=f.out_samplerate>44e3,f.quality>6&&(f.quality=6),f.quality<0&&(f.quality=LAME_DEFAULT_QUALITY),S.iteration_loop=new VBROldIterationLoop(Fe);break}default:{var Ht;S.sfb21_extra=!1,f.quality<0&&(f.quality=LAME_DEFAULT_QUALITY),Ht=f.VBR,Ht==Ot.vbr_off&&(f.VBR_mean_bitrate_kbps=f.brate),J.apply_preset(f,f.VBR_mean_bitrate_kbps,0),f.VBR=Ht,S.PSY.mask_adjust=f.maskingadjust,S.PSY.mask_adjust_short=f.maskingadjust_short,Ht==Ot.vbr_off?S.iteration_loop=new r2(Fe):S.iteration_loop=new ABRIterationLoop(Fe);break}}if(Wr(f.scale>=0),f.VBR!=Ot.vbr_off){if(S.VBR_min_bitrate=1,S.VBR_max_bitrate=14,f.out_samplerate<16e3&&(S.VBR_max_bitrate=8),f.VBR_min_bitrate_kbps!=0&&(f.VBR_min_bitrate_kbps=q(f.VBR_min_bitrate_kbps,f.version,f.out_samplerate),S.VBR_min_bitrate=w(f.VBR_min_bitrate_kbps,f.version,f.out_samplerate),S.VBR_min_bitrate<0)||f.VBR_max_bitrate_kbps!=0&&(f.VBR_max_bitrate_kbps=q(f.VBR_max_bitrate_kbps,f.version,f.out_samplerate),S.VBR_max_bitrate=w(f.VBR_max_bitrate_kbps,f.version,f.out_samplerate),S.VBR_max_bitrate<0))return-1;f.VBR_min_bitrate_kbps=gt.bitrate_table[f.version][S.VBR_min_bitrate],f.VBR_max_bitrate_kbps=gt.bitrate_table[f.version][S.VBR_max_bitrate],f.VBR_mean_bitrate_kbps=Math.min(gt.bitrate_table[f.version][S.VBR_max_bitrate],f.VBR_mean_bitrate_kbps),f.VBR_mean_bitrate_kbps=Math.max(gt.bitrate_table[f.version][S.VBR_min_bitrate],f.VBR_mean_bitrate_kbps)}return f.tune&&(S.PSY.mask_adjust+=f.tune_value_a,S.PSY.mask_adjust_short+=f.tune_value_a),E(f),Wr(f.scale>=0),f.athaa_type<0?S.ATH.useAdjust=3:S.ATH.useAdjust=f.athaa_type,S.ATH.aaSensitivityP=Math.pow(10,f.athaa_sensitivity/-10),f.short_blocks==null&&(f.short_blocks=Z0.short_block_allowed),f.short_blocks==Z0.short_block_allowed&&(f.mode==sr.JOINT_STEREO||f.mode==sr.STEREO)&&(f.short_blocks=Z0.short_block_coupled),f.quant_comp<0&&(f.quant_comp=1),f.quant_comp_short<0&&(f.quant_comp_short=0),f.msfix<0&&(f.msfix=0),f.exp_nspsytune=f.exp_nspsytune|1,f.internal_flags.nsPsy.attackthre<0&&(f.internal_flags.nsPsy.attackthre=br.NSATTACKTHRE),f.internal_flags.nsPsy.attackthre_s<0&&(f.internal_flags.nsPsy.attackthre_s=br.NSATTACKTHRE_S),Wr(f.scale>=0),f.scale<0&&(f.scale=1),f.ATHtype<0&&(f.ATHtype=4),f.ATHcurve<0&&(f.ATHcurve=4),f.athaa_loudapprox<0&&(f.athaa_loudapprox=2),f.interChRatio<0&&(f.interChRatio=0),f.useTemporal==null&&(f.useTemporal=!0),S.slot_lag=S.frac_SpF=0,f.VBR==Ot.vbr_off&&(S.slot_lag=S.frac_SpF=(f.version+1)*72e3*f.brate%f.out_samplerate|0),me.iteration_init(f),Oe.psymodel_init(f),Wr(f.scale>=0),0};function d(f,S){(f.in_buffer_0==null||f.in_buffer_nsamples<S)&&(f.in_buffer_0=Aa(S),f.in_buffer_1=Aa(S),f.in_buffer_nsamples=S)}this.lame_encode_flush=function(f,S,ce,xe){var ke=f.internal_flags,Ve=f2([2,1152]),Xe=0,Ge,it,We,je,Tt=ke.mf_samples_to_encode-g.POSTDELAY,kt=b(f);if(ke.mf_samples_to_encode<1)return 0;for(Ge=0,f.in_samplerate!=f.out_samplerate&&(Tt+=16*f.out_samplerate/f.in_samplerate),We=f.framesize-Tt%f.framesize,We<576&&(We+=f.framesize),f.encoder_padding=We,je=(Tt+We)/f.framesize;je>0&&Xe>=0;){var At=kt-ke.mf_size,Ht=f.frameNum;At*=f.in_samplerate,At/=f.out_samplerate,At>1152&&(At=1152),At<1&&(At=1),it=xe-Ge,xe==0&&(it=0),Xe=this.lame_encode_buffer(f,Ve[0],Ve[1],At,S,ce,it),ce+=Xe,Ge+=Xe,je-=Ht!=f.frameNum?1:0}if(ke.mf_samples_to_encode=0,Xe<0||(it=xe-Ge,xe==0&&(it=0),Re.flush_bitstream(f),Xe=Re.copy_buffer(ke,S,ce,it,1),Xe<0))return Xe;if(ce+=Xe,Ge+=Xe,it=xe-Ge,xe==0&&(it=0),f.write_id3tag_automatic){if(pe.id3tag_write_v1(f),Xe=Re.copy_buffer(ke,S,ce,it,0),Xe<0)return Xe;Ge+=Xe}return Ge},this.lame_encode_buffer=function(f,S,ce,xe,ke,Ve,Xe){var Ge=f.internal_flags,it=[null,null];if(Ge.Class_ID!=U)return-3;if(xe==0)return 0;d(Ge,xe),it[0]=Ge.in_buffer_0,it[1]=Ge.in_buffer_1;for(var We=0;We<xe;We++)it[0][We]=S[We],Ge.channels_in>1&&(it[1][We]=ce[We]);return l(f,it[0],it[1],xe,ke,Ve,Xe)};function b(f){var S=g.BLKSIZE+f.framesize-g.FFTOFFSET;return S=Math.max(S,512+f.framesize-32),Wr(Dt.MFSIZE>=S),S}function l(f,S,ce,xe,ke,Ve,Xe){var Ge=f.internal_flags,it=0,We,je,Tt,kt,At,Ht=[null,null],Yt=[null,null];if(Ge.Class_ID!=U)return-3;if(xe==0)return 0;if(At=Re.copy_buffer(Ge,ke,Ve,Xe,0),At<0)return At;if(Ve+=At,it+=At,Yt[0]=S,Yt[1]=ce,aa.NEQ(f.scale,0)&&aa.NEQ(f.scale,1))for(je=0;je<xe;++je)Yt[0][je]*=f.scale,Ge.channels_out==2&&(Yt[1][je]*=f.scale);if(aa.NEQ(f.scale_left,0)&&aa.NEQ(f.scale_left,1))for(je=0;je<xe;++je)Yt[0][je]*=f.scale_left;if(aa.NEQ(f.scale_right,0)&&aa.NEQ(f.scale_right,1))for(je=0;je<xe;++je)Yt[1][je]*=f.scale_right;if(f.num_channels==2&&Ge.channels_out==1)for(je=0;je<xe;++je)Yt[0][je]=.5*(Yt[0][je]+Yt[1][je]),Yt[1][je]=0;kt=b(f),Ht[0]=Ge.mfbuf[0],Ht[1]=Ge.mfbuf[1];for(var Qt=0;xe>0;){var gr=[null,null],kn=0,Ur=0;gr[0]=Yt[0],gr[1]=Yt[1];var Vr=new y;if(be(f,Ht,gr,Qt,xe,Vr),kn=Vr.n_in,Ur=Vr.n_out,Ge.findReplayGain&&!Ge.decode_on_the_fly&&Z.AnalyzeSamples(Ge.rgdata,Ht[0],Ge.mf_size,Ht[1],Ge.mf_size,Ur,Ge.channels_out)==qi.GAIN_ANALYSIS_ERROR)return-6;if(xe-=kn,Qt+=kn,Ge.channels_out==2,Ge.mf_size+=Ur,Wr(Ge.mf_size<=Dt.MFSIZE),Ge.mf_samples_to_encode<1&&(Ge.mf_samples_to_encode=g.ENCDELAY+g.POSTDELAY),Ge.mf_samples_to_encode+=Ur,Ge.mf_size>=kt){var xn=Xe-it;if(Xe==0&&(xn=0),We=v(f,Ht[0],Ht[1],ke,Ve,xn),We<0)return We;for(Ve+=We,it+=We,Ge.mf_size-=f.framesize,Ge.mf_samples_to_encode-=f.framesize,Tt=0;Tt<Ge.channels_out;Tt++)for(je=0;je<Ge.mf_size;je++)Ht[Tt][je]=Ht[Tt][je+f.framesize]}}return Wr(xe==0),it}function v(f,S,ce,xe,ke,Ve){var Xe=C.enc.lame_encode_mp3_frame(f,S,ce,xe,ke,Ve);return f.frameNum++,Xe}function y(){this.n_in=0,this.n_out=0}function T(){this.num_used=0}function G(f,S){return S!=0?G(S,f%S):f}function H(f,S,ce){var xe=Math.PI*S;f/=ce,f<0&&(f=0),f>1&&(f=1);var ke=f-.5,Ve=.42-.5*Math.cos(2*f*Math.PI)+.08*Math.cos(4*f*Math.PI);return Math.abs(ke)<1e-9?xe/Math.PI:Ve*Math.sin(ce*xe*ke)/(Math.PI*ce*ke)}function j(f,S,ce,xe,ke,Ve,Xe,Ge,it){var We=f.internal_flags,je,Tt=0,kt,At=f.out_samplerate/G(f.out_samplerate,f.in_samplerate);At>Dt.BPC&&(At=Dt.BPC);var Ht=Math.abs(We.resample_ratio-Math.floor(.5+We.resample_ratio))<1e-4?1:0,Yt=1/We.resample_ratio;Yt>1&&(Yt=1);var Qt=31;Qt%2==0&&--Qt,Qt+=Ht;var gr=Qt+1;if(We.fill_buffer_resample_init==0){for(We.inbuf_old[0]=Aa(gr),We.inbuf_old[1]=Aa(gr),je=0;je<=2*At;++je)We.blackfilt[je]=Aa(gr);for(We.itime[0]=0,We.itime[1]=0,Tt=0;Tt<=2*At;Tt++){var kn=0,Ur=(Tt-At)/(2*At);for(je=0;je<=Qt;je++)kn+=We.blackfilt[Tt][je]=H(je-Ur,Yt,Qt);for(je=0;je<=Qt;je++)We.blackfilt[Tt][je]/=kn}We.fill_buffer_resample_init=1}var Vr=We.inbuf_old[it];for(kt=0;kt<xe;kt++){var xn,Ia;if(xn=kt*We.resample_ratio,Tt=0|Math.floor(xn-We.itime[it]),Qt+Tt-Qt/2>=Xe)break;var Ur=xn-We.itime[it]-(Tt+.5*(Qt%2));Wr(Math.abs(Ur)<=.501),Ia=0|Math.floor(Ur*2*At+At+.5);var Ca=0;for(je=0;je<=Qt;++je){var bn=je+Tt-Qt/2,Br;Wr(bn<Xe),Wr(bn+gr>=0),Br=bn<0?Vr[gr+bn]:ke[Ve+bn],Ca+=Br*We.blackfilt[Ia][je]}S[ce+kt]=Ca}if(Ge.num_used=Math.min(Xe,Qt+Tt-Qt/2),We.itime[it]+=Ge.num_used-kt*We.resample_ratio,Ge.num_used>=gr)for(je=0;je<gr;je++)Vr[je]=ke[Ve+Ge.num_used+je-gr];else{var oa=gr-Ge.num_used;for(je=0;je<oa;++je)Vr[je]=Vr[je+Ge.num_used];for(Tt=0;je<gr;++je,++Tt)Vr[je]=ke[Ve+Tt];Wr(Tt==Ge.num_used)}return kt}function be(f,S,ce,xe,ke,Ve){var Xe=f.internal_flags;if(Xe.resample_ratio<.9999||Xe.resample_ratio>1.0001)for(var Ge=0;Ge<Xe.channels_out;Ge++){var it=new T;Ve.n_out=j(f,S[Ge],Xe.mf_size,f.framesize,ce[Ge],xe,ke,it,Ge),Ve.n_in=it.num_used}else{Ve.n_out=Math.min(f.framesize,ke),Ve.n_in=Ve.n_out;for(var We=0;We<Ve.n_out;++We)S[0][Xe.mf_size+We]=ce[0][xe+We],Xe.channels_out==2&&(S[1][Xe.mf_size+We]=ce[1][xe+We])}}}var d2=or,Dn=P.VbrMode;function v2(){function C(z,ve,pe,M,X,o,I,U,F,x,p,N,q,w,u){this.vbr_q=z,this.quant_comp=ve,this.quant_comp_s=pe,this.expY=M,this.st_lrm=X,this.st_s=o,this.masking_adj=I,this.masking_adj_short=U,this.ath_lower=F,this.ath_curve=x,this.ath_sensitivity=p,this.interch=N,this.safejoint=q,this.sfb21mod=w,this.msfix=u}function $(z,ve,pe,M,X,o,I,U,F,x,p,N,q,w){this.quant_comp=ve,this.quant_comp_s=pe,this.safejoint=M,this.nsmsfix=X,this.st_lrm=o,this.st_s=I,this.nsbass=U,this.scale=F,this.masking_adj=x,this.ath_lower=p,this.ath_curve=N,this.interch=q,this.sfscale=w}var ie;this.setModules=function(z){ie=z};var Z=[new C(0,9,9,0,5.2,125,-4.2,-6.3,4.8,1,0,0,2,21,.97),new C(1,9,9,0,5.3,125,-3.6,-5.6,4.5,1.5,0,0,2,21,1.35),new C(2,9,9,0,5.6,125,-2.2,-3.5,2.8,2,0,0,2,21,1.49),new C(3,9,9,1,5.8,130,-1.8,-2.8,2.6,3,-4,0,2,20,1.64),new C(4,9,9,1,6,135,-.7,-1.1,1.1,3.5,-8,0,2,0,1.79),new C(5,9,9,1,6.4,140,.5,.4,-7.5,4,-12,2e-4,0,0,1.95),new C(6,9,9,1,6.6,145,.67,.65,-14.7,6.5,-19,4e-4,0,0,2.3),new C(7,9,9,1,6.6,145,.8,.75,-19.7,8,-22,6e-4,0,0,2.7),new C(8,9,9,1,6.6,145,1.2,1.15,-27.5,10,-23,7e-4,0,0,0),new C(9,9,9,1,6.6,145,1.6,1.6,-36,11,-25,8e-4,0,0,0),new C(10,9,9,1,6.6,145,2,2,-36,12,-25,8e-4,0,0,0)],Re=[new C(0,9,9,0,4.2,25,-7,-4,7.5,1,0,0,2,26,.97),new C(1,9,9,0,4.2,25,-5.6,-3.6,4.5,1.5,0,0,2,21,1.35),new C(2,9,9,0,4.2,25,-4.4,-1.8,2,2,0,0,2,18,1.49),new C(3,9,9,1,4.2,25,-3.4,-1.25,1.1,3,-4,0,2,15,1.64),new C(4,9,9,1,4.2,25,-2.2,.1,0,3.5,-8,0,2,0,1.79),new C(5,9,9,1,4.2,25,-1,1.65,-7.7,4,-12,2e-4,0,0,1.95),new C(6,9,9,1,4.2,25,-0,2.47,-7.7,6.5,-19,4e-4,0,0,2),new C(7,9,9,1,4.2,25,.5,2,-14.5,8,-22,6e-4,0,0,2),new C(8,9,9,1,4.2,25,1,2.4,-22,10,-23,7e-4,0,0,2),new C(9,9,9,1,4.2,25,1.5,2.95,-30,11,-25,8e-4,0,0,2),new C(10,9,9,1,4.2,25,2,2.95,-36,12,-30,8e-4,0,0,2)];function J(z,ve,pe){var M=z.VBR==Dn.vbr_rh?Z:Re,X=z.VBR_q_frac,o=M[ve],I=M[ve+1],U=o;o.st_lrm=o.st_lrm+X*(I.st_lrm-o.st_lrm),o.st_s=o.st_s+X*(I.st_s-o.st_s),o.masking_adj=o.masking_adj+X*(I.masking_adj-o.masking_adj),o.masking_adj_short=o.masking_adj_short+X*(I.masking_adj_short-o.masking_adj_short),o.ath_lower=o.ath_lower+X*(I.ath_lower-o.ath_lower),o.ath_curve=o.ath_curve+X*(I.ath_curve-o.ath_curve),o.ath_sensitivity=o.ath_sensitivity+X*(I.ath_sensitivity-o.ath_sensitivity),o.interch=o.interch+X*(I.interch-o.interch),o.msfix=o.msfix+X*(I.msfix-o.msfix),Oe(z,U.vbr_q),pe!=0?z.quant_comp=U.quant_comp:Math.abs(z.quant_comp- -1)>0||(z.quant_comp=U.quant_comp),pe!=0?z.quant_comp_short=U.quant_comp_s:Math.abs(z.quant_comp_short- -1)>0||(z.quant_comp_short=U.quant_comp_s),U.expY!=0&&(z.experimentalY=U.expY!=0),pe!=0?z.internal_flags.nsPsy.attackthre=U.st_lrm:Math.abs(z.internal_flags.nsPsy.attackthre- -1)>0||(z.internal_flags.nsPsy.attackthre=U.st_lrm),pe!=0?z.internal_flags.nsPsy.attackthre_s=U.st_s:Math.abs(z.internal_flags.nsPsy.attackthre_s- -1)>0||(z.internal_flags.nsPsy.attackthre_s=U.st_s),pe!=0?z.maskingadjust=U.masking_adj:Math.abs(z.maskingadjust-0)>0||(z.maskingadjust=U.masking_adj),pe!=0?z.maskingadjust_short=U.masking_adj_short:Math.abs(z.maskingadjust_short-0)>0||(z.maskingadjust_short=U.masking_adj_short),pe!=0?z.ATHlower=-U.ath_lower/10:Math.abs(-z.ATHlower*10-0)>0||(z.ATHlower=-U.ath_lower/10),pe!=0?z.ATHcurve=U.ath_curve:Math.abs(z.ATHcurve- -1)>0||(z.ATHcurve=U.ath_curve),pe!=0?z.athaa_sensitivity=U.ath_sensitivity:Math.abs(z.athaa_sensitivity- -1)>0||(z.athaa_sensitivity=U.ath_sensitivity),U.interch>0&&(pe!=0?z.interChRatio=U.interch:Math.abs(z.interChRatio- -1)>0||(z.interChRatio=U.interch)),U.safejoint>0&&(z.exp_nspsytune=z.exp_nspsytune|U.safejoint),U.sfb21mod>0&&(z.exp_nspsytune=z.exp_nspsytune|U.sfb21mod<<20),pe!=0?z.msfix=U.msfix:Math.abs(z.msfix- -1)>0||(z.msfix=U.msfix),pe==0&&(z.VBR_q=ve,z.VBR_q_frac=X)}var me=[new $(8,9,9,0,0,6.6,145,0,.95,0,-30,11,.0012,1),new $(16,9,9,0,0,6.6,145,0,.95,0,-25,11,.001,1),new $(24,9,9,0,0,6.6,145,0,.95,0,-20,11,.001,1),new $(32,9,9,0,0,6.6,145,0,.95,0,-15,11,.001,1),new $(40,9,9,0,0,6.6,145,0,.95,0,-10,11,9e-4,1),new $(48,9,9,0,0,6.6,145,0,.95,0,-10,11,9e-4,1),new $(56,9,9,0,0,6.6,145,0,.95,0,-6,11,8e-4,1),new $(64,9,9,0,0,6.6,145,0,.95,0,-2,11,8e-4,1),new $(80,9,9,0,0,6.6,145,0,.95,0,0,8,7e-4,1),new $(96,9,9,0,2.5,6.6,145,0,.95,0,1,5.5,6e-4,1),new $(112,9,9,0,2.25,6.6,145,0,.95,0,2,4.5,5e-4,1),new $(128,9,9,0,1.95,6.4,140,0,.95,0,3,4,2e-4,1),new $(160,9,9,1,1.79,6,135,0,.95,-2,5,3.5,0,1),new $(192,9,9,1,1.49,5.6,125,0,.97,-4,7,3,0,0),new $(224,9,9,1,1.25,5.2,125,0,.98,-6,9,2,0,0),new $(256,9,9,1,.97,5.2,125,0,1,-8,10,1,0,0),new $(320,9,9,1,.9,5.2,125,0,1,-10,12,0,0,0)];function Fe(z,ve,pe){var M=ve,X=ie.nearestBitrateFullIndex(ve);if(z.VBR=Dn.vbr_abr,z.VBR_mean_bitrate_kbps=M,z.VBR_mean_bitrate_kbps=Math.min(z.VBR_mean_bitrate_kbps,320),z.VBR_mean_bitrate_kbps=Math.max(z.VBR_mean_bitrate_kbps,8),z.brate=z.VBR_mean_bitrate_kbps,z.VBR_mean_bitrate_kbps>320&&(z.disable_reservoir=!0),me[X].safejoint>0&&(z.exp_nspsytune=z.exp_nspsytune|2),me[X].sfscale>0&&(z.internal_flags.noise_shaping=2),Math.abs(me[X].nsbass)>0){var o=int(me[X].nsbass*4);o<0&&(o+=64),z.exp_nspsytune=z.exp_nspsytune|o<<2}return pe!=0?z.quant_comp=me[X].quant_comp:Math.abs(z.quant_comp- -1)>0||(z.quant_comp=me[X].quant_comp),pe!=0?z.quant_comp_short=me[X].quant_comp_s:Math.abs(z.quant_comp_short- -1)>0||(z.quant_comp_short=me[X].quant_comp_s),pe!=0?z.msfix=me[X].nsmsfix:Math.abs(z.msfix- -1)>0||(z.msfix=me[X].nsmsfix),pe!=0?z.internal_flags.nsPsy.attackthre=me[X].st_lrm:Math.abs(z.internal_flags.nsPsy.attackthre- -1)>0||(z.internal_flags.nsPsy.attackthre=me[X].st_lrm),pe!=0?z.internal_flags.nsPsy.attackthre_s=me[X].st_s:Math.abs(z.internal_flags.nsPsy.attackthre_s- -1)>0||(z.internal_flags.nsPsy.attackthre_s=me[X].st_s),pe!=0?z.scale=me[X].scale:Math.abs(z.scale- -1)>0||(z.scale=me[X].scale),pe!=0?z.maskingadjust=me[X].masking_adj:Math.abs(z.maskingadjust-0)>0||(z.maskingadjust=me[X].masking_adj),me[X].masking_adj>0?pe!=0?z.maskingadjust_short=me[X].masking_adj*.9:Math.abs(z.maskingadjust_short-0)>0||(z.maskingadjust_short=me[X].masking_adj*.9):pe!=0?z.maskingadjust_short=me[X].masking_adj*1.1:Math.abs(z.maskingadjust_short-0)>0||(z.maskingadjust_short=me[X].masking_adj*1.1),pe!=0?z.ATHlower=-me[X].ath_lower/10:Math.abs(-z.ATHlower*10-0)>0||(z.ATHlower=-me[X].ath_lower/10),pe!=0?z.ATHcurve=me[X].ath_curve:Math.abs(z.ATHcurve- -1)>0||(z.ATHcurve=me[X].ath_curve),pe!=0?z.interChRatio=me[X].interch:Math.abs(z.interChRatio- -1)>0||(z.interChRatio=me[X].interch),ve}this.apply_preset=function(z,ve,pe){switch(ve){case Mt.R3MIX:{ve=Mt.V3,z.VBR=Dn.vbr_mtrh;break}case Mt.MEDIUM:{ve=Mt.V4,z.VBR=Dn.vbr_rh;break}case Mt.MEDIUM_FAST:{ve=Mt.V4,z.VBR=Dn.vbr_mtrh;break}case Mt.STANDARD:{ve=Mt.V2,z.VBR=Dn.vbr_rh;break}case Mt.STANDARD_FAST:{ve=Mt.V2,z.VBR=Dn.vbr_mtrh;break}case Mt.EXTREME:{ve=Mt.V0,z.VBR=Dn.vbr_rh;break}case Mt.EXTREME_FAST:{ve=Mt.V0,z.VBR=Dn.vbr_mtrh;break}case Mt.INSANE:return ve=320,z.preset=ve,Fe(z,ve,pe),z.VBR=Dn.vbr_off,ve}switch(z.preset=ve,ve){case Mt.V9:return J(z,9,pe),ve;case Mt.V8:return J(z,8,pe),ve;case Mt.V7:return J(z,7,pe),ve;case Mt.V6:return J(z,6,pe),ve;case Mt.V5:return J(z,5,pe),ve;case Mt.V4:return J(z,4,pe),ve;case Mt.V3:return J(z,3,pe),ve;case Mt.V2:return J(z,2,pe),ve;case Mt.V1:return J(z,1,pe),ve;case Mt.V0:return J(z,0,pe),ve;default:break}return 8<=ve&&ve<=320?Fe(z,ve,pe):(z.preset=0,ve)};function Oe(z,ve){var pe=0;return 0>ve&&(pe=-1,ve=0),9<ve&&(pe=-1,ve=9),z.VBR_q=ve,z.VBR_q_frac=0,pe}}var _2=v2;function m2(){var C,$;this.setModules=function(ie,Z){C=ie,$=Z}}var h2=m2;function p2(){this.over_noise=0,this.tot_noise=0,this.max_noise=0,this.over_count=0,this.over_SSD=0,this.bits=0}var Q0=p2,A1=P.new_float,S2=P.new_int;function x2(){this.global_gain=0,this.sfb_count1=0,this.step=S2(39),this.noise=A1(39),this.noise_log=A1(39)}var b2=x2,ia=P.System,I1=P.VbrMode,J0=P.Util,Ja=P.Arrays,Ui=P.new_float,fn=P.assert;function y2(){var C;this.rv=null;var $;this.qupvt=null;var ie,Z=new h2,Re;this.setModules=function(F,x,p,N){C=F,$=x,this.rv=x,ie=p,this.qupvt=p,Re=N,Z.setModules(ie,Re)},this.ms_convert=function(F,x){for(var p=0;p<576;++p){var N=F.tt[x][0].xr[p],q=F.tt[x][1].xr[p];F.tt[x][0].xr[p]=(N+q)*(J0.SQRT2*.5),F.tt[x][1].xr[p]=(N-q)*(J0.SQRT2*.5)}};function J(F,x,p,N){N=0;for(var q=0;q<=p;++q){var w=Math.abs(F.xr[q]);N+=w,x[q]=Math.sqrt(w*Math.sqrt(w)),x[q]>F.xrpow_max&&(F.xrpow_max=x[q])}return N}this.init_xrpow=function(F,x,p){var N=0,q=0|x.max_nonzero_coeff;if(fn(p!=null),x.xrpow_max=0,fn(0<=q&&q<=575),Ja.fill(p,q,576,0),N=J(x,p,q,N),N>1e-20){var w=0;(F.substep_shaping&2)!=0&&(w=1);for(var u=0;u<x.psymax;u++)F.pseudohalf[u]=w;return!0}return Ja.fill(x.l3_enc,0,576,0),!1};function me(F,x){var p=F.ATH,N=x.xr;if(x.block_type!=g.SHORT_TYPE)for(var q=!1,w=g.PSFB21-1;w>=0&&!q;w--){var u=F.scalefac_band.psfb21[w],L=F.scalefac_band.psfb21[w+1],E=ie.athAdjust(p.adjust,p.psfb21[w],p.floor);F.nsPsy.longfact[21]>1e-12&&(E*=F.nsPsy.longfact[21]);for(var c=L-1;c>=u;c--)if(Math.abs(N[c])<E)N[c]=0;else{q=!0;break}}else for(var d=0;d<3;d++)for(var q=!1,w=g.PSFB12-1;w>=0&&!q;w--){var u=F.scalefac_band.s[12]*3+(F.scalefac_band.s[13]-F.scalefac_band.s[12])*d+(F.scalefac_band.psfb12[w]-F.scalefac_band.psfb12[0]),L=u+(F.scalefac_band.psfb12[w+1]-F.scalefac_band.psfb12[w]),b=ie.athAdjust(p.adjust,p.psfb12[w],p.floor);F.nsPsy.shortfact[12]>1e-12&&(b*=F.nsPsy.shortfact[12]);for(var c=L-1;c>=u;c--)if(Math.abs(N[c])<b)N[c]=0;else{q=!0;break}}}this.init_outer_loop=function(F,x){x.part2_3_length=0,x.big_values=0,x.count1=0,x.global_gain=210,x.scalefac_compress=0,x.table_select[0]=0,x.table_select[1]=0,x.table_select[2]=0,x.subblock_gain[0]=0,x.subblock_gain[1]=0,x.subblock_gain[2]=0,x.subblock_gain[3]=0,x.region0_count=0,x.region1_count=0,x.preflag=0,x.scalefac_scale=0,x.count1table_select=0,x.part2_length=0,x.sfb_lmax=g.SBPSY_l,x.sfb_smin=g.SBPSY_s,x.psy_lmax=F.sfb21_extra?g.SBMAX_l:g.SBPSY_l,x.psymax=x.psy_lmax,x.sfbmax=x.sfb_lmax,x.sfbdivide=11;for(var p=0;p<g.SBMAX_l;p++)x.width[p]=F.scalefac_band.l[p+1]-F.scalefac_band.l[p],x.window[p]=3;if(x.block_type==g.SHORT_TYPE){var N=Ui(576);x.sfb_smin=0,x.sfb_lmax=0,x.mixed_block_flag!=0&&(x.sfb_smin=3,x.sfb_lmax=F.mode_gr*2+4),x.psymax=x.sfb_lmax+3*((F.sfb21_extra?g.SBMAX_s:g.SBPSY_s)-x.sfb_smin),x.sfbmax=x.sfb_lmax+3*(g.SBPSY_s-x.sfb_smin),x.sfbdivide=x.sfbmax-18,x.psy_lmax=x.sfb_lmax;var q=F.scalefac_band.l[x.sfb_lmax];ia.arraycopy(x.xr,0,N,0,576);for(var p=x.sfb_smin;p<g.SBMAX_s;p++)for(var w=F.scalefac_band.s[p],u=F.scalefac_band.s[p+1],L=0;L<3;L++)for(var E=w;E<u;E++)x.xr[q++]=N[3*E+L];for(var c=x.sfb_lmax,p=x.sfb_smin;p<g.SBMAX_s;p++)x.width[c]=x.width[c+1]=x.width[c+2]=F.scalefac_band.s[p+1]-F.scalefac_band.s[p],x.window[c]=0,x.window[c+1]=1,x.window[c+2]=2,c+=3}x.count1bits=0,x.sfb_partition_table=ie.nr_of_sfb_block[0][0],x.slen[0]=0,x.slen[1]=0,x.slen[2]=0,x.slen[3]=0,x.max_nonzero_coeff=575,Ja.fill(x.scalefac,0),me(F,x)};function Fe(F){this.ordinal=F}Fe.BINSEARCH_NONE=new Fe(0),Fe.BINSEARCH_UP=new Fe(1),Fe.BINSEARCH_DOWN=new Fe(2);function Oe(F,x,p,N,q){var w,u=F.CurrentStep[N],L=!1,E=F.OldValue[N],c=Fe.BINSEARCH_NONE;for(x.global_gain=E,p-=x.part2_length,fn(u!=0);;){var d;if(w=Re.count_bits(F,q,x,null),u==1||w==p)break;w>p?(c==Fe.BINSEARCH_DOWN&&(L=!0),L&&(u/=2),c=Fe.BINSEARCH_UP,d=u):(c==Fe.BINSEARCH_UP&&(L=!0),L&&(u/=2),c=Fe.BINSEARCH_DOWN,d=-u),x.global_gain+=d,x.global_gain<0&&(x.global_gain=0,L=!0),x.global_gain>255&&(x.global_gain=255,L=!0)}for(fn(x.global_gain>=0),fn(x.global_gain<256);w>p&&x.global_gain<255;)x.global_gain++,w=Re.count_bits(F,q,x,null);return F.CurrentStep[N]=E-x.global_gain>=4?4:2,F.OldValue[N]=x.global_gain,x.part2_3_length=w,w}this.trancate_smallspectrums=function(F,x,p,N){var q=Ui(zn.SFBMAX);if(!((F.substep_shaping&4)==0&&x.block_type==g.SHORT_TYPE||(F.substep_shaping&128)!=0)){ie.calc_noise(x,p,q,new Q0,null);for(var u=0;u<576;u++){var w=0;x.l3_enc[u]!=0&&(w=Math.abs(x.xr[u])),N[u]=w}var u=0,L=8;x.block_type==g.SHORT_TYPE&&(L=6);do{var E,c,d,b,l=x.width[L];if(u+=l,!(q[L]>=1)&&(Ja.sort(N,u-l,l),!Wn.EQ(N[u-1],0))){E=(1-q[L])*p[L],c=0,b=0;do{var v;for(d=1;b+d<l&&!Wn.NEQ(N[b+u-l],N[b+u+d-l]);d++);if(v=N[b+u-l]*N[b+u-l]*d,E<v){b!=0&&(c=N[b+u-l-1]);break}E-=v,b+=d}while(b<l);if(!Wn.EQ(c,0))do Math.abs(x.xr[u-l])<=c&&(x.l3_enc[u-l]=0);while(--l>0)}}while(++L<x.psymax);x.part2_3_length=Re.noquant_count_bits(F,x,null)}};function z(F){for(var x=0;x<F.sfbmax;x++)if(F.scalefac[x]+F.subblock_gain[F.window[x]]==0)return!1;return!0}function ve(F){return J0.FAST_LOG10(.368+.632*F*F*F)}function pe(F,x){for(var p=1e-37,N=0;N<x.psymax;N++)p+=ve(F[N]);return Math.max(1e-20,p)}function M(F,x,p,N,q){var w;switch(F){default:case 9:{x.over_count>0?(w=p.over_SSD<=x.over_SSD,p.over_SSD==x.over_SSD&&(w=p.bits<x.bits)):w=p.max_noise<0&&p.max_noise*10+p.bits<=x.max_noise*10+x.bits;break}case 0:w=p.over_count<x.over_count||p.over_count==x.over_count&&p.over_noise<x.over_noise||p.over_count==x.over_count&&Wn.EQ(p.over_noise,x.over_noise)&&p.tot_noise<x.tot_noise;break;case 8:p.max_noise=pe(q,N);case 1:w=p.max_noise<x.max_noise;break;case 2:w=p.tot_noise<x.tot_noise;break;case 3:w=p.tot_noise<x.tot_noise&&p.max_noise<x.max_noise;break;case 4:w=p.max_noise<=0&&x.max_noise>.2||p.max_noise<=0&&x.max_noise<0&&x.max_noise>p.max_noise-.2&&p.tot_noise<x.tot_noise||p.max_noise<=0&&x.max_noise>0&&x.max_noise>p.max_noise-.2&&p.tot_noise<x.tot_noise+x.over_noise||p.max_noise>0&&x.max_noise>-.05&&x.max_noise>p.max_noise-.1&&p.tot_noise+p.over_noise<x.tot_noise+x.over_noise||p.max_noise>0&&x.max_noise>-.1&&x.max_noise>p.max_noise-.15&&p.tot_noise+p.over_noise+p.over_noise<x.tot_noise+x.over_noise+x.over_noise;break;case 5:w=p.over_noise<x.over_noise||Wn.EQ(p.over_noise,x.over_noise)&&p.tot_noise<x.tot_noise;break;case 6:w=p.over_noise<x.over_noise||Wn.EQ(p.over_noise,x.over_noise)&&(p.max_noise<x.max_noise||Wn.EQ(p.max_noise,x.max_noise)&&p.tot_noise<=x.tot_noise);break;case 7:w=p.over_count<x.over_count||p.over_noise<x.over_noise;break}return x.over_count==0&&(w=w&&p.bits<x.bits),w}function X(F,x,p,N,q){var w=F.internal_flags,u;x.scalefac_scale==0?u=1.2968395546510096:u=1.6817928305074292;for(var L=0,E=0;E<x.sfbmax;E++)L<p[E]&&(L=p[E]);var c=w.noise_shaping_amp;switch(c==3&&(q?c=2:c=1),c){case 2:break;case 1:L>1?L=Math.pow(L,.5):L*=.95;break;case 0:default:L>1?L=1:L*=.95;break}for(var d=0,E=0;E<x.sfbmax;E++){var b=x.width[E],l;if(d+=b,!(p[E]<L)){if((w.substep_shaping&2)!=0&&(w.pseudohalf[E]=w.pseudohalf[E]==0?1:0,w.pseudohalf[E]==0&&w.noise_shaping_amp==2))return;for(x.scalefac[E]++,l=-b;l<0;l++)N[d+l]*=u,N[d+l]>x.xrpow_max&&(x.xrpow_max=N[d+l]);if(w.noise_shaping_amp==2)return}}}function o(F,x){for(var p=1.2968395546510096,N=0,q=0;q<F.sfbmax;q++){var w=F.width[q],u=F.scalefac[q];if(F.preflag!=0&&(u+=ie.pretab[q]),N+=w,(u&1)!=0){u++;for(var L=-w;L<0;L++)x[N+L]*=p,x[N+L]>F.xrpow_max&&(F.xrpow_max=x[N+L])}F.scalefac[q]=u>>1}F.preflag=0,F.scalefac_scale=1}function I(F,x,p){var N,q=x.scalefac;for(N=0;N<x.sfb_lmax;N++)if(q[N]>=16)return!0;for(var w=0;w<3;w++){var u=0,L=0;for(N=x.sfb_lmax+w;N<x.sfbdivide;N+=3)u<q[N]&&(u=q[N]);for(;N<x.sfbmax;N+=3)L<q[N]&&(L=q[N]);if(!(u<16&&L<8)){if(x.subblock_gain[w]>=7)return!0;x.subblock_gain[w]++;var E=F.scalefac_band.l[x.sfb_lmax];for(N=x.sfb_lmax+w;N<x.sfbmax;N+=3){var c,d=x.width[N],b=q[N];if(fn(b>=0),b=b-(4>>x.scalefac_scale),b>=0){q[N]=b,E+=d*3;continue}q[N]=0;{var l=210+(b<<x.scalefac_scale+1);c=ie.IPOW20(l)}E+=d*(w+1);for(var v=-d;v<0;v++)p[E+v]*=c,p[E+v]>x.xrpow_max&&(x.xrpow_max=p[E+v]);E+=d*(3-w-1)}{var c=ie.IPOW20(202);E+=x.width[N]*(w+1);for(var v=-x.width[N];v<0;v++)p[E+v]*=c,p[E+v]>x.xrpow_max&&(x.xrpow_max=p[E+v])}}}return!1}function U(F,x,p,N,q){var w=F.internal_flags;X(F,x,p,N,q);var u=z(x);return u?!1:(w.mode_gr==2?u=Re.scale_bitcount(x):u=Re.scale_bitcount_lsf(w,x),u?(w.noise_shaping>1&&(Ja.fill(w.pseudohalf,0),x.scalefac_scale==0?(o(x,N),u=!1):x.block_type==g.SHORT_TYPE&&w.subblock_gain>0&&(u=I(w,x,N)||z(x))),u||(w.mode_gr==2?u=Re.scale_bitcount(x):u=Re.scale_bitcount_lsf(w,x)),!u):!0)}this.outer_loop=function(F,x,p,N,q,w){var u=F.internal_flags,L=new Oo,E=Ui(576),c=Ui(zn.SFBMAX),d=new Q0,b,l=new b2,v=9999999,y=!1,T=!1,G=0;if(Oe(u,x,w,q,N),u.noise_shaping==0)return 100;ie.calc_noise(x,p,c,d,l),d.bits=x.part2_3_length,L.assign(x);var H=0;for(ia.arraycopy(N,0,E,0,576);!y;){do{var j=new Q0,be,f=255;if((u.substep_shaping&2)!=0?be=20:be=3,u.sfb21_extra&&(c[L.sfbmax]>1||L.block_type==g.SHORT_TYPE&&(c[L.sfbmax+1]>1||c[L.sfbmax+2]>1))||!U(F,L,c,N,T))break;L.scalefac_scale!=0&&(f=254);var S=w-L.part2_length;if(S<=0)break;for(;(L.part2_3_length=Re.count_bits(u,N,L,l))>S&&L.global_gain<=f;)L.global_gain++;if(L.global_gain>f)break;if(d.over_count==0){for(;(L.part2_3_length=Re.count_bits(u,N,L,l))>v&&L.global_gain<=f;)L.global_gain++;if(L.global_gain>f)break}if(ie.calc_noise(L,p,c,j,l),j.bits=L.part2_3_length,x.block_type!=g.SHORT_TYPE?b=F.quant_comp:b=F.quant_comp_short,b=M(b,d,j,L,c)?1:0,b!=0)v=x.part2_3_length,d=j,x.assign(L),H=0,ia.arraycopy(N,0,E,0,576);else if(u.full_outer_loop==0&&(++H>be&&d.over_count==0||u.noise_shaping_amp==3&&T&&H>30||u.noise_shaping_amp==3&&T&&L.global_gain-G>15))break}while(L.global_gain+L.scalefac_scale<255);u.noise_shaping_amp==3?T?y=!0:(L.assign(x),ia.arraycopy(E,0,N,0,576),H=0,G=L.global_gain,T=!0):y=!0}return fn(x.global_gain+x.scalefac_scale<=255),F.VBR==I1.vbr_rh||F.VBR==I1.vbr_mtrh?ia.arraycopy(E,0,N,0,576):(u.substep_shaping&1)!=0&&trancate_smallspectrums(u,x,p,N),d.over_count},this.iteration_finish_one=function(F,x,p){var N=F.l3_side,q=N.tt[x][p];Re.best_scalefac_store(F,x,p,N),F.use_best_huffman==1&&Re.best_huffman_divide(F,q),$.ResvAdjust(F,q)},this.VBR_encode_granule=function(F,x,p,N,q,w,u){var L=F.internal_flags,E=new Oo,c=Ui(576),d=u,b=u+1,l=(u+w)/2,v,y,T=0,G=L.sfb21_extra;fn(d<=LameInternalFlags.MAX_BITS_PER_CHANNEL),Ja.fill(E.l3_enc,0);do fn(l>=w),fn(l<=u),fn(w<=u),l>d-42?L.sfb21_extra=!1:L.sfb21_extra=G,y=outer_loop(F,x,p,N,q,l),y<=0?(T=1,b=x.part2_3_length,E.assign(x),ia.arraycopy(N,0,c,0,576),u=b-32,v=u-w,l=(u+w)/2):(w=l+32,v=u-w,l=(u+w)/2,T!=0&&(T=2,x.assign(E),ia.arraycopy(c,0,N,0,576)));while(v>12);L.sfb21_extra=G,T==2&&ia.arraycopy(E.l3_enc,0,x.l3_enc,0,576),fn(x.part2_3_length<=d)},this.get_framebits=function(F,x){var p=F.internal_flags;p.bitrate_index=p.VBR_min_bitrate;var N=C.getframebits(F);p.bitrate_index=1,N=C.getframebits(F);for(var q=1;q<=p.VBR_max_bitrate;q++){p.bitrate_index=q;var w=new MeanBits(N);x[q]=$.ResvFrameBegin(F,w),N=w.bits}},this.VBR_old_prepare=function(F,x,p,N,q,w,u,L,E){var c=F.internal_flags,d,b=0,l=1,v=0;c.bitrate_index=c.VBR_max_bitrate;var y=$.ResvFrameBegin(F,new MeanBits(0))/c.mode_gr;get_framebits(F,w);for(var T=0;T<c.mode_gr;T++){var G=ie.on_pe(F,x,L[T],y,T,0);c.mode_ext==g.MPG_MD_MS_LR&&(ms_convert(c.l3_side,T),ie.reduce_side(L[T],p[T],y,G));for(var H=0;H<c.channels_out;++H){var j=c.l3_side.tt[T][H];j.block_type!=g.SHORT_TYPE?(b=1.28/(1+Math.exp(3.5-x[T][H]/300))-.05,d=c.PSY.mask_adjust-b):(b=2.56/(1+Math.exp(3.5-x[T][H]/300))-.14,d=c.PSY.mask_adjust_short-b),c.masking_lower=Math.pow(10,d*.1),init_outer_loop(c,j),E[T][H]=ie.calc_xmin(F,N[T][H],j,q[T][H]),E[T][H]!=0&&(l=0),u[T][H]=126,v+=L[T][H]}}for(var T=0;T<c.mode_gr;T++)for(var H=0;H<c.channels_out;H++)v>w[c.VBR_max_bitrate]&&(L[T][H]*=w[c.VBR_max_bitrate],L[T][H]/=v),u[T][H]>L[T][H]&&(u[T][H]=L[T][H]);return l},this.bitpressure_strategy=function(F,x,p,N){for(var q=0;q<F.mode_gr;q++)for(var w=0;w<F.channels_out;w++){for(var u=F.l3_side.tt[q][w],L=x[q][w],E=0,c=0;c<u.psy_lmax;c++)L[E++]*=1+.029*c*c/g.SBMAX_l/g.SBMAX_l;if(u.block_type==g.SHORT_TYPE)for(var c=u.sfb_smin;c<g.SBMAX_s;c++)L[E++]*=1+.029*c*c/g.SBMAX_s/g.SBMAX_s,L[E++]*=1+.029*c*c/g.SBMAX_s/g.SBMAX_s,L[E++]*=1+.029*c*c/g.SBMAX_s/g.SBMAX_s;N[q][w]=0|Math.max(p[q][w],.9*N[q][w])}},this.VBR_new_prepare=function(F,x,p,N,q,w){var u=F.internal_flags,L=1,E=0,c=0,d;if(F.free_format){u.bitrate_index=0;var b=new MeanBits(E);d=$.ResvFrameBegin(F,b),E=b.bits,q[0]=d}else{u.bitrate_index=u.VBR_max_bitrate;var b=new MeanBits(E);$.ResvFrameBegin(F,b),E=b.bits,get_framebits(F,q),d=q[u.VBR_max_bitrate]}for(var l=0;l<u.mode_gr;l++){ie.on_pe(F,x,w[l],E,l,0),u.mode_ext==g.MPG_MD_MS_LR&&ms_convert(u.l3_side,l);for(var v=0;v<u.channels_out;++v){var y=u.l3_side.tt[l][v];u.masking_lower=Math.pow(10,u.PSY.mask_adjust*.1),init_outer_loop(u,y),ie.calc_xmin(F,p[l][v],y,N[l][v])!=0&&(L=0),c+=w[l][v]}}for(var l=0;l<u.mode_gr;l++)for(var v=0;v<u.channels_out;v++)c>d&&(w[l][v]*=d,w[l][v]/=c);return L},this.calc_target_bits=function(F,x,p,N,q,w){var u=F.internal_flags,L=u.l3_side,E,c,d,b,l=0;u.bitrate_index=u.VBR_max_bitrate;var v=new MeanBits(l);for(w[0]=$.ResvFrameBegin(F,v),l=v.bits,u.bitrate_index=1,l=C.getframebits(F)-u.sideinfo_len*8,q[0]=l/(u.mode_gr*u.channels_out),l=F.VBR_mean_bitrate_kbps*F.framesize*1e3,(u.substep_shaping&1)!=0&&(l*=1.09),l/=F.out_samplerate,l-=u.sideinfo_len*8,l/=u.mode_gr*u.channels_out,E=.93+.07*(11-F.compression_ratio)/(11-5.5),E<.9&&(E=.9),E>1&&(E=1),c=0;c<u.mode_gr;c++){var y=0;for(d=0;d<u.channels_out;d++){if(N[c][d]=int(E*l),x[c][d]>700){var T=int((x[c][d]-700)/1.4),G=L.tt[c][d];N[c][d]=int(E*l),G.block_type==g.SHORT_TYPE&&T<l/2&&(T=l/2),T>l*3/2?T=l*3/2:T<0&&(T=0),N[c][d]+=T}N[c][d]>LameInternalFlags.MAX_BITS_PER_CHANNEL&&(N[c][d]=LameInternalFlags.MAX_BITS_PER_CHANNEL),y+=N[c][d]}if(y>LameInternalFlags.MAX_BITS_PER_GRANULE)for(d=0;d<u.channels_out;++d)N[c][d]*=LameInternalFlags.MAX_BITS_PER_GRANULE,N[c][d]/=y}if(u.mode_ext==g.MPG_MD_MS_LR)for(c=0;c<u.mode_gr;c++)ie.reduce_side(N[c],p[c],l*u.channels_out,LameInternalFlags.MAX_BITS_PER_GRANULE);for(b=0,c=0;c<u.mode_gr;c++)for(d=0;d<u.channels_out;d++)N[c][d]>LameInternalFlags.MAX_BITS_PER_CHANNEL&&(N[c][d]=LameInternalFlags.MAX_BITS_PER_CHANNEL),b+=N[c][d];if(b>w[0])for(c=0;c<u.mode_gr;c++)for(d=0;d<u.channels_out;d++)N[c][d]*=w[0],N[c][d]/=b}}var g2=y2,jo=P.assert;function E2(){var C;this.setModules=function($){C=$},this.ResvFrameBegin=function($,ie){var Z=$.internal_flags,Re,J=Z.l3_side,me=C.getframebits($);ie.bits=(me-Z.sideinfo_len*8)/Z.mode_gr;var Fe=8*256*Z.mode_gr-8;$.brate>320?Re=8*int($.brate*1e3/($.out_samplerate/1152)/8+.5):(Re=8*1440,$.strict_ISO&&(Re=8*int(32e4/($.out_samplerate/1152)/8+.5))),Z.ResvMax=Re-me,Z.ResvMax>Fe&&(Z.ResvMax=Fe),(Z.ResvMax<0||$.disable_reservoir)&&(Z.ResvMax=0);var Oe=ie.bits*Z.mode_gr+Math.min(Z.ResvSize,Z.ResvMax);return Oe>Re&&(Oe=Re),jo(Z.ResvMax%8==0),jo(Z.ResvMax>=0),J.resvDrain_pre=0,Z.pinfo!=null&&(Z.pinfo.mean_bits=ie.bits/2,Z.pinfo.resvsize=Z.ResvSize),Oe},this.ResvMaxBits=function($,ie,Z,Re){var J=$.internal_flags,me,Fe=J.ResvSize,Oe=J.ResvMax;Re!=0&&(Fe+=ie),(J.substep_shaping&1)!=0&&(Oe*=.9),Z.bits=ie,Fe*10>Oe*9?(me=Fe-Oe*9/10,Z.bits+=me,J.substep_shaping|=128):(me=0,J.substep_shaping&=127,!$.disable_reservoir&&(J.substep_shaping&1)==0&&(Z.bits-=.1*ie));var z=Fe<J.ResvMax*6/10?Fe:J.ResvMax*6/10;return z-=me,z<0&&(z=0),z},this.ResvAdjust=function($,ie){$.ResvSize-=ie.part2_3_length+ie.part2_length},this.ResvFrameEnd=function($,ie){var Z,Re=$.l3_side;$.ResvSize+=ie*$.mode_gr;var J=0;Re.resvDrain_post=0,Re.resvDrain_pre=0,(Z=$.ResvSize%8)!=0&&(J+=Z),Z=$.ResvSize-J-$.ResvMax,Z>0&&(jo(Z%8==0),jo(Z>=0),J+=Z);{var me=Math.min(Re.main_data_begin*8,J)/8;Re.resvDrain_pre+=8*me,J-=8*me,$.ResvSize-=8*me,Re.main_data_begin-=me}Re.resvDrain_post+=J,$.ResvSize-=J}}var T2=E2;function w2(){var C="http://www.mp3dev.org/",$=3,ie=98,Z=4,Re=0,J=93;this.getLameVersion=function(){return $+"."+ie+"."+Z},this.getLameShortVersion=function(){return $+"."+ie+"."+Z},this.getLameVeryShortVersion=function(){return"LAME"+$+"."+ie+"r"},this.getPsyVersion=function(){return Re+"."+J},this.getLameUrl=function(){return C},this.getLameOsBitness=function(){return"32bits"}}var R2=w2,A2=P.System,es=P.VbrMode,C1=P.ShortBlock,I2=P.Arrays,zo=P.new_byte,C2=P.assert;Vi.NUMTOCENTRIES=100,Vi.MAXFRAMESIZE=2880;function Vi(){var C,$,ie;this.setModules=function(l,v,y){C=l,$=v,ie=y};var Z=1,Re=2,J=4,me=8,Fe=Vi.NUMTOCENTRIES,Oe=Vi.MAXFRAMESIZE,z=Fe+4+4+4+4+4,ve=z+9+1+1+8+1+1+3+1+1+2+4+2+2,pe=128,M=64,X=32,o=null,I="Xing",U="Info",F=[0,49345,49537,320,49921,960,640,49729,50689,1728,1920,51009,1280,50625,50305,1088,52225,3264,3456,52545,3840,53185,52865,3648,2560,51905,52097,2880,51457,2496,2176,51265,55297,6336,6528,55617,6912,56257,55937,6720,7680,57025,57217,8e3,56577,7616,7296,56385,5120,54465,54657,5440,55041,6080,5760,54849,53761,4800,4992,54081,4352,53697,53377,4160,61441,12480,12672,61761,13056,62401,62081,12864,13824,63169,63361,14144,62721,13760,13440,62529,15360,64705,64897,15680,65281,16320,16e3,65089,64001,15040,15232,64321,14592,63937,63617,14400,10240,59585,59777,10560,60161,11200,10880,59969,60929,11968,12160,61249,11520,60865,60545,11328,58369,9408,9600,58689,9984,59329,59009,9792,8704,58049,58241,9024,57601,8640,8320,57409,40961,24768,24960,41281,25344,41921,41601,25152,26112,42689,42881,26432,42241,26048,25728,42049,27648,44225,44417,27968,44801,28608,28288,44609,43521,27328,27520,43841,26880,43457,43137,26688,30720,47297,47489,31040,47873,31680,31360,47681,48641,32448,32640,48961,32e3,48577,48257,31808,46081,29888,30080,46401,30464,47041,46721,30272,29184,45761,45953,29504,45313,29120,28800,45121,20480,37057,37249,20800,37633,21440,21120,37441,38401,22208,22400,38721,21760,38337,38017,21568,39937,23744,23936,40257,24320,40897,40577,24128,23040,39617,39809,23360,39169,22976,22656,38977,34817,18624,18816,35137,19200,35777,35457,19008,19968,36545,36737,20288,36097,19904,19584,35905,17408,33985,34177,17728,34561,18368,18048,34369,33281,17088,17280,33601,16640,33217,32897,16448];function x(l,v){if(l.nVbrNumFrames++,l.sum+=v,l.seen++,!(l.seen<l.want)&&(l.pos<l.size&&(l.bag[l.pos]=l.sum,l.pos++,l.seen=0),l.pos==l.size)){for(var y=1;y<l.size;y+=2)l.bag[y/2]=l.bag[y];l.want*=2,l.pos/=2}}function p(l,v){if(!(l.pos<=0))for(var y=1;y<Fe;++y){var T=y/Fe,G,H,j=0|Math.floor(T*l.pos);j>l.pos-1&&(j=l.pos-1),G=l.bag[j],H=l.sum;var be=0|256*G/H;be>255&&(be=255),v[y]=255&be}}this.addVbrFrame=function(l){var v=l.internal_flags,y=Tables.bitrate_table[l.version][v.bitrate_index];C2(v.VBR_seek_table.bag!=null),x(v.VBR_seek_table,y)};function N(l,v){var y=l[v+0]&255;return y<<=8,y|=l[v+1]&255,y<<=8,y|=l[v+2]&255,y<<=8,y|=l[v+3]&255,y}function q(l,v,y){l[v+0]=255&(y>>24&255),l[v+1]=255&(y>>16&255),l[v+2]=255&(y>>8&255),l[v+3]=255&(y&255)}function w(l,v,y){l[v+0]=255&(y>>8&255),l[v+1]=255&(y&255)}function u(l,v){return new String(l,v,I.length(),o).equals(I)||new String(l,v,U.length(),o).equals(U)}function L(l,v,y){return 255&(l<<v|y&~(-1<<v))}function E(l,v){var y=l.internal_flags;v[0]=L(v[0],8,255),v[1]=L(v[1],3,7),v[1]=L(v[1],1,l.out_samplerate<16e3?0:1),v[1]=L(v[1],1,l.version),v[1]=L(v[1],2,4-3),v[1]=L(v[1],1,l.error_protection?0:1),v[2]=L(v[2],4,y.bitrate_index),v[2]=L(v[2],2,y.samplerate_index),v[2]=L(v[2],1,0),v[2]=L(v[2],1,l.extension),v[3]=L(v[3],2,l.mode.ordinal()),v[3]=L(v[3],2,y.mode_ext),v[3]=L(v[3],1,l.copyright),v[3]=L(v[3],1,l.original),v[3]=L(v[3],2,l.emphasis),v[0]=255;var T=255&(v[1]&241),G;l.version==1?G=pe:l.out_samplerate<16e3?G=X:G=M,l.VBR==es.vbr_off&&(G=l.brate);var H;l.free_format?H=0:H=255&16*C.BitrateIndex(G,l.version,l.out_samplerate),l.version==1?(v[1]=255&(T|10),T=255&(v[2]&13),v[2]=255&(H|T)):(v[1]=255&(T|2),T=255&(v[2]&13),v[2]=255&(H|T))}this.getVbrTag=function(l){var v=new VBRTagData,y=0;v.flags=0;var T=l[y+1]>>3&1,G=l[y+2]>>2&3,H=l[y+3]>>6&3,j=l[y+2]>>4&15;if(j=Tables.bitrate_table[T][j],l[y+1]>>4==14?v.samprate=Tables.samplerate_table[2][G]:v.samprate=Tables.samplerate_table[T][G],T!=0?H!=3?y+=32+4:y+=17+4:H!=3?y+=17+4:y+=9+4,!u(l,y))return null;y+=4,v.hId=T;var be=v.flags=N(l,y);if(y+=4,(be&Z)!=0&&(v.frames=N(l,y),y+=4),(be&Re)!=0&&(v.bytes=N(l,y),y+=4),(be&J)!=0){if(v.toc!=null)for(var f=0;f<Fe;f++)v.toc[f]=l[y+f];y+=Fe}v.vbrScale=-1,(be&me)!=0&&(v.vbrScale=N(l,y),y+=4),v.headersize=(T+1)*72e3*j/v.samprate,y+=21;var S=l[y+0]<<4;S+=l[y+1]>>4;var ce=(l[y+1]&15)<<8;return ce+=l[y+2]&255,(S<0||S>3e3)&&(S=-1),(ce<0||ce>3e3)&&(ce=-1),v.encDelay=S,v.encPadding=ce,v},this.InitVbrTag=function(l){var v=l.internal_flags,y;l.version==1?y=pe:l.out_samplerate<16e3?y=X:y=M,l.VBR==es.vbr_off&&(y=l.brate);var T=(l.version+1)*72e3*y/l.out_samplerate,G=v.sideinfo_len+ve;if(v.VBR_seek_table.TotalFrameSize=T,T<G||T>Oe){l.bWriteVbrTag=!1;return}v.VBR_seek_table.nVbrNumFrames=0,v.VBR_seek_table.nBytesWritten=0,v.VBR_seek_table.sum=0,v.VBR_seek_table.seen=0,v.VBR_seek_table.want=1,v.VBR_seek_table.pos=0,v.VBR_seek_table.bag==null&&(v.VBR_seek_table.bag=new int[400],v.VBR_seek_table.size=400);var H=zo(Oe);E(l,H);for(var j=v.VBR_seek_table.TotalFrameSize,be=0;be<j;++be)$.add_dummy_byte(l,H[be]&255,1)};function c(l,v){var y=v^l;return v=v>>8^F[y&255],v}this.updateMusicCRC=function(l,v,y,T){for(var G=0;G<T;++G)l[0]=c(v[y+G],l[0])};function d(l,v,y,T,G){var H=l.internal_flags,j=0,be=l.encoder_delay,f=l.encoder_padding,S=100-10*l.VBR_q-l.quality,ce=ie.getLameVeryShortVersion(),xe,ke=0,Ve,Xe=[1,5,3,2,4,0,3],Ge=0|(l.lowpassfreq/100+.5>255?255:l.lowpassfreq/100+.5),it=0,We=0,je=0,Tt=l.internal_flags.noise_shaping,kt=0,At=0,Ht=0,Yt=0,Qt=0,gr=(l.exp_nspsytune&1)!=0,kn=(l.exp_nspsytune&2)!=0,Ur=!1,Vr=!1,xn=l.internal_flags.nogap_total,Ia=l.internal_flags.nogap_current,Ca=l.ATHtype,bn=0,Br;switch(l.VBR){case vbr_abr:Br=l.VBR_mean_bitrate_kbps;break;case vbr_off:Br=l.brate;break;default:Br=l.VBR_min_bitrate_kbps}switch(l.VBR.ordinal()<Xe.length?xe=Xe[l.VBR.ordinal()]:xe=0,Ve=16*ke+xe,H.findReplayGain&&(H.RadioGain>510&&(H.RadioGain=510),H.RadioGain<-510&&(H.RadioGain=-510),We=8192,We|=3072,H.RadioGain>=0?We|=H.RadioGain:(We|=512,We|=-H.RadioGain)),H.findPeakSample&&(it=Math.abs(0|H.PeakSample/32767*Math.pow(2,23)+.5)),xn!=-1&&(Ia>0&&(Vr=!0),Ia<xn-1&&(Ur=!0)),bn=Ca+((gr?1:0)<<4)+((kn?1:0)<<5)+((Ur?1:0)<<6)+((Vr?1:0)<<7),S<0&&(S=0),l.mode){case MONO:kt=0;break;case STEREO:kt=1;break;case DUAL_CHANNEL:kt=2;break;case JOINT_STEREO:l.force_ms?kt=4:kt=3;break;case NOT_SET:default:kt=7;break}l.in_samplerate<=32e3?Ht=0:l.in_samplerate==48e3?Ht=2:l.in_samplerate>48e3?Ht=3:Ht=1,(l.short_blocks==C1.short_block_forced||l.short_blocks==C1.short_block_dispensed||l.lowpassfreq==-1&&l.highpassfreq==-1||l.scale_left<l.scale_right||l.scale_left>l.scale_right||l.disable_reservoir&&l.brate<320||l.noATH||l.ATHonly||Ca==0||l.in_samplerate<=32e3)&&(At=1),Yt=Tt+(kt<<2)+(At<<5)+(Ht<<6),Qt=H.nMusicCRC,q(y,T+j,S),j+=4;for(var oa=0;oa<9;oa++)y[T+j+oa]=255&ce.charAt(oa);j+=9,y[T+j]=255&Ve,j++,y[T+j]=255&Ge,j++,q(y,T+j,it),j+=4,w(y,T+j,We),j+=2,w(y,T+j,je),j+=2,y[T+j]=255&bn,j++,Br>=255?y[T+j]=255:y[T+j]=255&Br,j++,y[T+j]=255&be>>4,y[T+j+1]=255&(be<<4)+(f>>8),y[T+j+2]=255&f,j+=3,y[T+j]=255&Yt,j++,y[T+j++]=0,w(y,T+j,l.preset),j+=2,q(y,T+j,v),j+=4,w(y,T+j,Qt),j+=2;for(var ji=0;ji<j;ji++)G=c(y[T+ji],G);return w(y,T+j,G),j+=2,j}function b(l){l.seek(0);var v=zo(10);l.readFully(v);var y;return new String(v,"ISO-8859-1").startsWith("ID3")?y=0:y=((v[6]&127)<<21|(v[7]&127)<<14|(v[8]&127)<<7|v[9]&127)+v.length,y}this.getLameTagFrame=function(l,v){var y=l.internal_flags;if(!l.bWriteVbrTag||y.Class_ID!=Mt.LAME_ID||y.VBR_seek_table.pos<=0)return 0;if(v.length<y.VBR_seek_table.TotalFrameSize)return y.VBR_seek_table.TotalFrameSize;I2.fill(v,0,y.VBR_seek_table.TotalFrameSize,0),E(l,v);var T=zo(Fe);if(l.free_format)for(var G=1;G<Fe;++G)T[G]=255&255*G/100;else p(y.VBR_seek_table,T);var H=y.sideinfo_len;l.error_protection&&(H-=2),l.VBR==es.vbr_off?(v[H++]=255&U.charAt(0),v[H++]=255&U.charAt(1),v[H++]=255&U.charAt(2),v[H++]=255&U.charAt(3)):(v[H++]=255&I.charAt(0),v[H++]=255&I.charAt(1),v[H++]=255&I.charAt(2),v[H++]=255&I.charAt(3)),q(v,H,Z+Re+J+me),H+=4,q(v,H,y.VBR_seek_table.nVbrNumFrames),H+=4;var j=y.VBR_seek_table.nBytesWritten+y.VBR_seek_table.TotalFrameSize;q(v,H,0|j),H+=4,A2.arraycopy(T,0,v,H,T.length),H+=T.length,l.error_protection&&$.CRC_writeheader(y,v);for(var be=0,G=0;G<H;G++)be=c(v[G],be);return H+=d(l,j,v,H,be),y.VBR_seek_table.TotalFrameSize},this.putVbrTag=function(l,v){var y=l.internal_flags;if(y.VBR_seek_table.pos<=0||(v.seek(v.length()),v.length()==0))return-1;var T=b(v);v.seek(T);var G=zo(Oe),H=getLameTagFrame(l,G);return H>G.length?-1:(H<1||v.write(G,0,H),0)}}var M2=Vi,M1=P.new_byte,B1=P.assert,Mt=d2,B2=_2,qi=Mr,N2=na,P2=g2,F2=$0,L2=T2,sr=Rr,Wn=aa;function D2(){var C,$;this.setModules=function(ie,Z){C=ie,$=Z}}function O2(){var C,$,ie;this.setModules=function(Z,Re,J){C=Z,$=Re,ie=J}}function k2(){}function H2(){var C,$;this.setModules=function(ie,Z){C=ie,$=Z}}function U2(C,$,ie){arguments.length!=3&&(console.error("WARN: Mp3Encoder(channels, samplerate, kbps) not specified"),C=1,$=44100,ie=128);var Z=new Mt,Re=new D2,J=new qi,me=new Wn,Fe=new B2,Oe=new N2,z=new P2,ve=new M2,pe=new R2,M=new H2,X=new L2,o=new F2,I=new O2,U=new k2;Z.setModules(J,me,Fe,Oe,z,ve,pe,M,U),me.setModules(J,U,pe,ve),M.setModules(me,pe),Fe.setModules(Z),z.setModules(me,X,Oe,o),Oe.setModules(o,X,Z.enc.psy),X.setModules(me),o.setModules(Oe),ve.setModules(Z,me,pe),Re.setModules(I,U),I.setModules(pe,M,Fe);var F=Z.lame_init();F.num_channels=C,F.in_samplerate=$,F.brate=ie,F.mode=sr.STEREO,F.quality=3,F.bWriteVbrTag=!1,F.disable_reservoir=!0,F.write_id3tag_automatic=!1;var x=Z.lame_init_params(F);B1(x==0);var p=1152,N=0|1.25*p+7200,q=M1(N);this.encodeBuffer=function(w,u){C==1&&(u=w),B1(w.length==u.length),w.length>p&&(p=w.length,N=0|1.25*p+7200,q=M1(N));var L=Z.lame_encode_buffer(F,w,u,w.length,q,0,N);return new Int8Array(q.subarray(0,L))},this.flush=function(){var w=Z.lame_encode_flush(F,q,0,N);return new Int8Array(q.subarray(0,w))}}function On(){this.dataOffset=0,this.dataLen=0,this.channels=0,this.sampleRate=0}function Go(C){return C.charCodeAt(0)<<24|C.charCodeAt(1)<<16|C.charCodeAt(2)<<8|C.charCodeAt(3)}On.RIFF=Go("RIFF"),On.WAVE=Go("WAVE"),On.fmt_=Go("fmt "),On.data=Go("data"),On.readHeader=function(C){var $=new On,ie=C.getUint32(0,!1);if(On.RIFF==ie){var Z=C.getUint32(4,!0);if(On.WAVE==C.getUint32(8,!1)&&On.fmt_==C.getUint32(12,!1)){var Re=C.getUint32(16,!0),J=16+4;switch(Re){case 16:case 18:$.channels=C.getUint16(J+2,!0),$.sampleRate=C.getUint32(J+4,!0);break;default:throw"extended fmt chunk not implemented"}J+=Re;for(var me=On.data,Fe=0;me!=ie&&(ie=C.getUint32(J,!1),Fe=C.getUint32(J+4,!0),me!=ie);)J+=Fe+8;return $.dataLen=Fe,$.dataOffset=J+8,$}}};var V2=U2,N1=function(C,$){if(!(C instanceof $))throw new TypeError("Cannot call a class as a function")},P1=function(){function C($,ie){for(var Z=0;Z<ie.length;Z++){var Re=ie[Z];Re.enumerable=Re.enumerable||!1,Re.configurable=!0,"value"in Re&&(Re.writable=!0),Object.defineProperty($,Re.key,Re)}}return function($,ie,Z){return ie&&C($.prototype,ie),Z&&C($,Z),$}}(),q2=function(){function C($){N1(this,C),this.config={sampleRate:44100,bitRate:128},Object.assign(this.config,$),this.mp3Encoder=new V2(1,this.config.sampleRate,this.config.bitRate),this.maxSamples=1152,this.samplesMono=null,this.clearBuffer()}return P1(C,[{key:"clearBuffer",value:function(){this.dataBuffer=[]}},{key:"appendToBuffer",value:function(ie){this.dataBuffer.push(new Int8Array(ie))}},{key:"floatTo16BitPCM",value:function(ie,Z){for(var Re=0;Re<ie.length;Re++){var J=Math.max(-1,Math.min(1,ie[Re]));Z[Re]=J<0?J*32768:J*32767}}},{key:"convertBuffer",value:function(ie){var Z=new Float32Array(ie),Re=new Int16Array(ie.length);return this.floatTo16BitPCM(Z,Re),Re}},{key:"encode",value:function(ie){this.samplesMono=this.convertBuffer(ie);for(var Z=this.samplesMono.length,Re=0;Z>=0;Re+=this.maxSamples){var J=this.samplesMono.subarray(Re,Re+this.maxSamples),me=this.mp3Encoder.encodeBuffer(J);this.appendToBuffer(me),Z-=this.maxSamples}}},{key:"finish",value:function(){return this.appendToBuffer(this.mp3Encoder.flush()),this.dataBuffer}}]),C}(),j2=function(){function C($){N1(this,C),this.config={bitRate:128,startRecordingAt:300,deviceId:null},this.activeStream=null,this.context=null,this.microphone=null,this.processor=null,this.startTime=0,Object.assign(this.config,$)}return P1(C,[{key:"addMicrophoneListener",value:function(ie){var Z=this;this.activeStream=ie,this.timerToStart=setTimeout(function(){delete Z.timerToStart},this.config.startRecordingAt),this.microphone=this.context.createMediaStreamSource(ie),this.processor=this.context.createScriptProcessor(0,1,1),this.processor.onaudioprocess=function(Re){Z.timerToStart||Z.lameEncoder.encode(Re.inputBuffer.getChannelData(0))},this.microphone.connect(this.processor),this.processor.connect(this.context.destination)}},{key:"stop",value:function(){return this.processor&&this.microphone&&(this.microphone.disconnect(),this.processor.disconnect(),this.context&&this.context.state!=="closed"&&this.context.close(),this.processor.onaudioprocess=null,this.activeStream.getAudioTracks().forEach(function(ie){return ie.stop()})),this}},{key:"start",value:function(){var ie=this,Z=window.AudioContext||window.webkitAudioContext;this.context=new Z,this.config.sampleRate=this.context.sampleRate,this.lameEncoder=new q2(this.config);var Re=this.config.deviceId?{deviceId:{exact:this.config.deviceId}}:!0;return new Promise(function(J,me){navigator.mediaDevices.getUserMedia({audio:Re}).then(function(Fe){ie.addMicrophoneListener(Fe),J(Fe)}).catch(function(Fe){me(Fe)})})}},{key:"getMp3",value:function(){var ie=this,Z=this.lameEncoder.finish();return new Promise(function(Re,J){Z.length===0?J(new Error("No buffer to send")):(Re([Z,new Blob(Z,{type:"audio/mp3"})]),ie.lameEncoder.clearBuffer())})}}]),C}();return j2})});var _f=z1((m8,vf)=>{vf.exports=typeof self=="object"?self.FormData:window.FormData});function Wi(e,t){let r,n={mimeType:"video/webm;codecs=vp9",videoBitsPerSecond:128e3,audioBitsPerSecond:64e3},a=new MediaRecorder(e,n);a.ondataavailable=s=>{s.data.size>0&&t.push(s.data),r&&r()},a.start();function i(){return new Promise(s=>{a.state=="recording"?(r=s,a.stop(),e.getTracks().forEach(m=>{m.stop()})):s()})}return i}async function us(e,t={cameraId:void 0,microphoneId:void 0},r={width:640,height:480}){let{cameraId:n,microphoneId:a}=t,i={audio:{deviceId:a},video:{deviceId:n,width:r.width,height:r.height,frameRate:15}},s=await navigator.mediaDevices.getUserMedia(i),m=Wi(s,e);return{cameraStream:s,stopCameraRecording:m}}var K1=G1(X1()),ds;function W1(){let e=new K1.default({bitRate:128});function t(){e.start().then(()=>{}).catch(n=>{console.error(n)})}async function r(){return await e.stop().getMp3().then(async([a,i])=>({buffer:a,blob:i})).catch(a=>{alert("We could not retrieve your message"),console.log(a)})}return ds=r,{start:t,stop:r}}var Y1="script_not_called_inside_body",$1="incompatible_navigator",Z1="required_field_not_provided",Q1="not_shared_first_screen",Yi="multiple_monitors_detected",Wo="proctoring_already_started",Na="proctoring_not_started",J1="proctoring_running",eu="no_videos_recorded";async function vs(e,t){let{allowOnlyFirstMonitor:r,onStopSharingScreenCallback:n}=t,a={video:{cursor:"always"},audio:!1},i=await navigator.mediaDevices.getDisplayMedia(a),s=i.getVideoTracks();if(s[0].onended=n,navigator.userAgent.indexOf("Firefox")>-1&&!s.find(re=>re.label=="Primary Monitor")&&r)throw Yi;if(!(s.find(k=>["screen:0:0","Primary Monitor"].includes(k.label))!=null)&&r)throw s.forEach(k=>{k.stop()}),Q1;let h=Wi(i,e);return{screenStream:i,stopScreenRecorder:h}}var tu={Unknown:0,NonRetryableStatus:1,InvalidEvent:2,SizeLimitExceeded:3,KillSwitch:4,QueueFull:5};var En="function",zr="object",Tn="undefined",$t="prototype",$i="hasOwnProperty";var Qr=Object,ri=Qr[$t],ni=Qr.assign,Yo=Qr.create,$o=Qr.defineProperty,la=ri[$i];var ai=null;function dn(e){return e===void 0&&(e=!0),(!ai||!e)&&(typeof globalThis!==Tn&&globalThis&&(ai=globalThis),typeof self!==Tn&&self&&(ai=self),typeof window!==Tn&&window&&(ai=window),typeof global!==Tn&&global&&(ai=global)),ai}function ii(e){throw new TypeError(e)}function oi(e){var t=Yo;if(t)return t(e);if(e==null)return{};var r=typeof e;r!==zr&&r!==En&&ii("Object prototype may only be an Object:"+e);function n(){}return n[$t]=e,new n}var r3=(dn()||{}).Symbol,n3=(dn()||{}).Reflect;var Q2=function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var a in t)ri[$i].call(t,a)&&(e[a]=t[a])}return e},tr=ni||Q2,_s=function(e,t){return _s=Qr.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var a in n)n[$i](a)&&(r[a]=n[a])},_s(e,t)};function dt(e,t){typeof t!==En&&t!==null&&ii("Class extends value "+String(t)+" is not a constructor or null"),_s(e,t);function r(){this.constructor=e}e[$t]=t===null?oi(t):(r[$t]=t[$t],new r)}function Zo(e,t){for(var r=0,n=t.length,a=e.length;r<n;r++,a++)e[a]=t[r];return e}var Qo="constructor",Yn="prototype",Jo="function",e0="_dynInstFuncs",ps="_isDynProxy",si="_dynClass",J2="_dynCls$",Ss="_dynInstChk",Zi=Ss,iu="_dfOpts",ru="_unknown_",ed="__proto__",ms="useBaseInst",nu="setInstFuncs",n0=Object,Qi=n0.getPrototypeOf,au=0;function ua(e,t){return e&&n0[Yn].hasOwnProperty.call(e,t)}function ou(e){return e&&(e===n0[Yn]||e===Array[Yn])}function xs(e){return ou(e)||e===Function[Yn]}function Pa(e){if(e){if(Qi)return Qi(e);var t=e[ed]||e[Yn]||(e[Qo]?e[Qo][Yn]:null);if(t)return t}return null}function t0(e,t){var r=[],n=n0.getOwnPropertyNames;if(n)r=n(e);else for(var a in e)typeof a=="string"&&ua(e,a)&&r.push(a);if(r&&r.length>0)for(var i=0;i<r.length;i++)t(r[i])}function bs(e,t,r){return t!==Qo&&typeof e[t]===Jo&&(r||ua(e,t))}function r0(e){throw new TypeError("DynamicProto: "+e)}function td(e){var t={};return t0(e,function(r){!t[r]&&bs(e,r,!1)&&(t[r]=e[r])}),t}function ys(e,t){for(var r=e.length-1;r>=0;r--)if(e[r]===t)return!0;return!1}function rd(e,t,r,n){function a(_,h,k){var re=h[k];if(re[ps]&&n){var oe=_[e0]||{};oe[Zi]!==!1&&(re=(oe[h[si]]||{})[k]||re)}return function(){return re.apply(_,arguments)}}var i={};t0(r,function(_){i[_]=a(t,r,_)});for(var s=Pa(e),m=[];s&&!xs(s)&&!ys(m,s);)t0(s,function(_){!i[_]&&bs(s,_,!Qi)&&(i[_]=a(t,s,_))}),m.push(s),s=Pa(s);return i}function nd(e,t,r,n){var a=null;if(e&&ua(r,si)){var i=e[e0]||{};if(a=(i[r[si]]||{})[t],a||r0("Missing ["+t+"] "+Jo),!a[Ss]&&i[Zi]!==!1){for(var s=!ua(e,t),m=Pa(e),_=[];s&&m&&!xs(m)&&!ys(_,m);){var h=m[t];if(h){s=h===n;break}_.push(m),m=Pa(m)}try{s&&(e[t]=a),a[Ss]=1}catch{i[Zi]=!1}}}return a}function ad(e,t,r){var n=t[e];return n===r&&(n=Pa(t)[e]),typeof n!==Jo&&r0("["+e+"] is not a "+Jo),n}function id(e,t,r,n,a){function i(_,h){var k=function(){var re=nd(this,h,_,k)||ad(h,_,k);return re.apply(this,arguments)};return k[ps]=1,k}if(!ou(e)){var s=r[e0]=r[e0]||{},m=s[t]=s[t]||{};s[Zi]!==!1&&(s[Zi]=!!a),t0(r,function(_){bs(r,_,!1)&&r[_]!==n[_]&&(m[_]=r[_],delete r[_],(!ua(e,_)||e[_]&&!e[_][ps])&&(e[_]=i(e,_)))})}}function od(e,t){if(Qi)for(var r=[],n=Pa(t);n&&!xs(n)&&!ys(r,n);){if(n===e)return!0;r.push(n),n=Pa(n)}return!1}function hs(e,t){return ua(e,Yn)?e.name||t||ru:((e||{})[Qo]||{}).name||t||ru}function gs(e,t,r,n){ua(e,Yn)||r0("theClass is an invalid class definition.");var a=e[Yn];od(a,t)||r0("["+hs(e)+"] is not in class hierarchy of ["+hs(t)+"]");var i=null;ua(a,si)?i=a[si]:(i=J2+hs(e,"_")+"$"+au,au++,a[si]=i);var s=gs[iu],m=!!s[ms];m&&n&&n[ms]!==void 0&&(m=!!n[ms]);var _=td(t),h=rd(a,t,_,m);r(t,h);var k=!!Qi&&!!s[nu];k&&n&&(k=!!n[nu]),id(a,i,t,_,k!==!1)}var sd={setInstFuncs:!0,useBaseInst:!0};gs[iu]=sd;var bt=gs;var Pe;(function(e){e[e.CRITICAL=1]="CRITICAL",e[e.WARNING=2]="WARNING"})(Pe||(Pe={}));var Ie={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,InvalidEvent:70,FailedMonitorAjaxSetRequestHeader:71,SendBrowserInfoOnUserInit:72,PluginException:73,NotificationException:74,SnippetScriptLoadFailure:99,InvalidInstrumentationKey:100,CannotParseAiBlobValue:101,InvalidContentBlob:102,TrackPageActionEventFailed:103,FailedAddingCustomDefinedRequestContext:104,InMemoryStorageBufferFull:105};var ld="on",su="attachEvent",lu="addEventListener";var hu="toISOString",pu="endsWith",ud="startsWith",uu="indexOf",cu="map",fu="reduce",Ts="trim",Su="toString",cd="__proto__",fd="constructor",du=$o,A3=Qr.freeze,I3=Qr.seal,vu=Qr.keys,ws=String[$t],dd=ws[Ts],vd=ws[pu],C3=ws[ud],_d=Date[$t],md=_d[hu],hd=Array.isArray,xu=ri[Su],pd=la[Su],M3=pd.call(Qr),Sd=/-([a-z])/g,xd=/([^\w\d_$])/g,bd=/^(\d+[\w\d_$])/,_u=Object.getPrototypeOf;function bu(e){if(e){if(_u)return _u(e);var t=e[cd]||e[$t]||e[fd];if(t)return t}return null}function Jt(e){return e===void 0||typeof e===Tn}function Le(e){return e===null||Jt(e)}function Rs(e){return!Le(e)}function Ji(e,t){return!!(e&&la.call(e,t))}function wn(e){return!!(e&&typeof e===zr)}function lt(e){return!!(e&&typeof e===En)}function Rn(e,t,r,n){n===void 0&&(n=!1);var a=!1;if(!Le(e))try{Le(e[lu])?Le(e[su])||(e[su](ld+t,r),a=!0):(e[lu](t,r,n),a=!0)}catch{}return a}function As(e){var t=e;return t&&rt(t)&&(t=t.replace(Sd,function(r,n){return n.toUpperCase()}),t=t.replace(xd,"_"),t=t.replace(bd,function(r,n){return"_"+n})),t}function It(e,t){if(e)for(var r in e)la.call(e,r)&&t.call(e,r,e[r])}function Is(e,t){var r=!1;return e&&t&&!(r=e===t)&&(r=vd?e[pu](t):yd(e,t)),r}function yd(e,t){var r=!1,n=t?t.length:0,a=e?e.length:0;if(n&&a&&a>=n&&!(r=e===t)){for(var i=a-1,s=n-1;s>=0;s--){if(e[i]!=t[s])return!1;i--}r=!0}return r}function vr(e,t){return e&&t?e.indexOf(t)!==-1:!1}var _r=hd||gd;function gd(e){return!!(e&&xu.call(e)==="[object Array]")}function li(e){return!!(e&&xu.call(e)==="[object Error]")}function rt(e){return typeof e=="string"}function ui(e){return typeof e=="number"}function Nr(e){if(e)return md?e[hu]():Ed(e)}function Ed(e){if(e&&e.getUTCFullYear){var t=function(r){var n=String(r);return n.length===1&&(n="0"+n),n};return e.getUTCFullYear()+"-"+t(e.getUTCMonth()+1)+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())+"."+String((e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}}function nt(e,t,r){var n=e.length;try{for(var a=0;a<n&&!(a in e&&t.call(r||e,e[a],a,e)===-1);a++);}catch{}}function Un(e,t,r){if(e){if(e[uu])return e[uu](t,r);var n=e.length,a=r||0;try{for(var i=Math.max(a>=0?a:n-Math.abs(a),0);i<n;i++)if(i in e&&e[i]===t)return i}catch{}}return-1}function Fa(e,t,r){var n;if(e){if(e[cu])return e[cu](t,r);var a=e.length,i=r||e;n=new Array(a);try{for(var s=0;s<a;s++)s in e&&(n[s]=t.call(i,e[s],e))}catch{}}return n}function a0(e,t,r){var n;if(e){if(e[fu])return e[fu](t,r);var a=e.length,i=0;if(arguments.length>=3)n=arguments[2];else{for(;i<a&&!(i in e);)i++;n=e[i++]}for(;i<a;)i in e&&(n=t(n,e[i],i,e)),i++}return n}function rr(e){return e&&(e=dd&&e[Ts]?e[Ts]():e.replace?e.replace(/^\s+|\s+$/g,""):e),e}var mu=!{toString:null}.propertyIsEnumerable("toString"),Es=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];function vn(e){var t=typeof e;if(t!==En&&(t!==zr||e===null)&&ii("objKeys called on non-object"),!mu&&vu)return vu(e);var r=[];for(var n in e)e&&la.call(e,n)&&r.push(n);if(mu)for(var a=Es.length,i=0;i<a;i++)e&&la.call(e,Es[i])&&r.push(Es[i]);return r}function ca(e,t,r,n){if(du)try{var a={enumerable:!0,configurable:!0};return r&&(a.get=r),n&&(a.set=n),du(e,t,a),!0}catch{}return!1}function mr(){var e=Date;return e.now?e.now():new e().getTime()}function xt(e){return li(e)?e.name:""}function St(e,t,r,n,a){var i=r;return e&&(i=e[t],i!==r&&(!a||a(i))&&(!n||n(r))&&(i=r,e[t]=i)),i}function hr(e,t,r){var n;return e?(n=e[t],!n&&Le(n)&&(n=Jt(r)?{}:r,e[t]=n)):n=Jt(r)?{}:r,n}function i0(e){return!e}function ci(e){return!!e}function Ir(e){throw new Error(e)}function Cs(e,t,r){if(e&&t&&e!==t&&wn(e)&&wn(t)){var n=function(i){if(rt(i)){var s=t[i];lt(s)?(!r||r(i,!0,t,e))&&(e[i]=function(m){return function(){var _=arguments;return t[m].apply(t,_)}}(i)):(!r||r(i,!1,t,e))&&(Ji(e,i)&&delete e[i],ca(e,i,function(){return t[i]},function(m){t[i]=m})||(e[i]=s))}};for(var a in t)n(a)}return e}function Ms(e){return function(){function t(){var r=this;e&&It(e,function(n,a){r[n]=a})}return t}()}function o0(e){return e&&ni&&(e=Qr(ni({},e))),e}var yu="window",Td="document",wd="documentMode",Rd="navigator",Ad="history",Id="location",Cd="console",Md="performance",gu="JSON",Bd="crypto",Nd="msCrypto",Pd="ReactNative",Fs="msie",Ls="trident/",Bs=null,Ns=null,Fd=!1,fi=null,Ps=null;function Eu(e,t){var r=!1;if(e){try{if(r=t in e,!r){var n=e[$t];n&&(r=t in n)}}catch{}if(!r)try{var a=new e;r=!Jt(a[t])}catch{}}return r}function nr(e){var t=dn();return t&&t[e]?t[e]:e===yu&&La()?window:null}function La(){return Boolean(typeof window===zr&&window)}function Vn(){return La()?window:nr(yu)}function s0(){return Boolean(typeof document===zr&&document)}function lr(){return s0()?document:nr(Td)}function Ds(){return Boolean(typeof navigator===zr&&navigator)}function Cr(){return Ds()?navigator:nr(Rd)}function Tu(){return Boolean(typeof history===zr&&history)}function Os(){return Tu()?history:nr(Ad)}function Jr(e){if(e&&Fd){var t=nr("__mockLocation");if(t)return t}return typeof location===zr&&location?location:nr(Id)}function ks(){return typeof console!==Tn?console:nr(Cd)}function en(){return nr(Md)}function An(){return Boolean(typeof JSON===zr&&JSON||nr(gu)!==null)}function pr(){return An()?JSON||nr(gu):null}function Hs(){return nr(Bd)}function Us(){return nr(Nd)}function Vs(){var e=Cr();return e&&e.product?e.product===Pd:!1}function Da(){var e=Cr();if(e&&(e.userAgent!==Ns||Bs===null)){Ns=e.userAgent;var t=(Ns||"").toLowerCase();Bs=vr(t,Fs)||vr(t,Ls)}return Bs}function di(e){if(e===void 0&&(e=null),!e){var t=Cr()||{};e=t?(t.userAgent||"").toLowerCase():""}var r=(e||"").toLowerCase();if(vr(r,Fs)){var n=lr()||{};return Math.max(parseInt(r.split(Fs)[1]),n[wd]||0)}else if(vr(r,Ls)){var a=parseInt(r.split(Ls)[1]);if(a)return a+4}return null}function ot(e){var t=Object[$t].toString.call(e),r="";return t==="[object Error]"?r="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e.name+"'":An()&&(r=pr().stringify(e)),t+r}function Oa(){return Ps===null&&(Ps=Ds()&&Boolean(Cr().sendBeacon)),Ps}function l0(e){var t=!1;try{var r=nr("fetch");t=!!r;var n=nr("Request");t&&e&&n&&(t=Eu(n,"keepalive"))}catch{}return t}function u0(){return fi===null&&(fi=typeof XDomainRequest<"u",fi&&ka()&&(fi=fi&&!Eu(nr("XMLHttpRequest"),"withCredentials"))),fi}function ka(){var e=!1;try{var t=nr("XMLHttpRequest");e=!!t}catch{}return e}var qs=["eventsSent","eventsDiscarded","eventsSendRequest","perfEvent"],f0=null,c0;function Ld(e,t){return function(){var r=arguments,n=js(t);if(n){var a=n.listener;a&&a[e]&&a[e].apply(a,r)}}}function Dd(){var e=nr("Microsoft");return e&&(f0=e.ApplicationInsights),f0}function js(e){var t=f0;return!t&&e.disableDbgExt!==!0&&(t=f0||Dd()),t?t.ChromeDbgExt:null}function wu(e){if(!c0){c0={};for(var t=0;t<qs.length;t++)c0[qs[t]]=Ld(qs[t],e)}return c0}var Od="AI (Internal): ",kd="AI: ",Hd="AITR_",Ud="errorToConsole",Vd="warnToConsole";function Ru(e){return e?'"'+e.replace(/\"/g,"")+'"':""}function Au(e,t){var r=ks();if(r){var n="log";r[e]&&(n=e),lt(r[n])&&r[n](t)}}var $n=function(){function e(t,r,n,a){n===void 0&&(n=!1);var i=this;i.messageId=t,i.message=(n?kd:Od)+t;var s="";An()&&(s=pr().stringify(a));var m=(r?" message:"+Ru(r):"")+(a?" props:"+Ru(s):"");i.message+=m}return e.dataType="MessageData",e}();function Zn(e,t){return(e||{}).logger||new vi(t)}var vi=function(){function e(t){this.identifier="DiagnosticLogger",this.queue=[];var r=0,n={};bt(e,this,function(a){Le(t)&&(t={}),a.consoleLoggingLevel=function(){return i("loggingLevelConsole",0)},a.telemetryLoggingLevel=function(){return i("loggingLevelTelemetry",1)},a.maxInternalMessageLimit=function(){return i("maxMessageLimit",25)},a.enableDebugExceptions=function(){return i("enableDebugExceptions",!1)},a.throwInternal=function(_,h,k,re,oe){oe===void 0&&(oe=!1);var te=new $n(h,k,oe,re);if(a.enableDebugExceptions())throw te;var D=_===Pe.CRITICAL?Ud:Vd;if(Jt(te.message))m("throw"+(_===Pe.CRITICAL?"Critical":"Warning"),te);else{var Se=a.consoleLoggingLevel();if(oe){var P=+te.messageId;!n[P]&&Se>=_&&(a[D](te.message),n[P]=!0)}else Se>=_&&a[D](te.message);a.logInternalMessage(_,te)}},a.warnToConsole=function(_){Au("warn",_),m("warning",_)},a.errorToConsole=function(_){Au("error",_),m("error",_)},a.resetInternalMessageCount=function(){r=0,n={}},a.logInternalMessage=function(_,h){if(!s()){var k=!0,re=Hd+h.messageId;if(n[re]?k=!1:n[re]=!0,k&&(_<=a.telemetryLoggingLevel()&&(a.queue.push(h),r++,m(_===Pe.CRITICAL?"error":"warn",h)),r===a.maxInternalMessageLimit())){var oe="Internal events throttle limit per PageView reached for this app.",te=new $n(Ie.MessageLimitPerPVExceeded,oe,!1);a.queue.push(te),_===Pe.CRITICAL?a.errorToConsole(oe):a.warnToConsole(oe)}}};function i(_,h){var k=t[_];return Le(k)?h:k}function s(){return r>=a.maxInternalMessageLimit()}function m(_,h){var k=js(t);k&&k.diagLog&&k.diagLog(_,h)}})}return e}();var _i="ctx",qd=null,eo=function(){function e(t,r,n){var a=this,i=!1;if(a.start=mr(),a.name=t,a.isAsync=n,a.isChildEvt=function(){return!1},lt(r)){var s;i=ca(a,"payload",function(){return!s&&lt(r)&&(s=r(),r=null),s})}a.getCtx=function(m){return m?m===e.ParentContextKey||m===e.ChildrenContextKey?a[m]:(a[_i]||{})[m]:null},a.setCtx=function(m,_){if(m)if(m===e.ParentContextKey)a[m]||(a.isChildEvt=function(){return!0}),a[m]=_;else if(m===e.ChildrenContextKey)a[m]=_;else{var h=a[_i]=a[_i]||{};h[m]=_}},a.complete=function(){var m=0,_=a.getCtx(e.ChildrenContextKey);if(_r(_))for(var h=0;h<_.length;h++){var k=_[h];k&&(m+=k.time)}a.time=mr()-a.start,a.exTime=a.time-m,a.complete=function(){},!i&&lt(r)&&(a.payload=r())}}return e.ParentContextKey="parent",e.ChildrenContextKey="childEvts",e}();var Gs=function(){function e(t){this.ctx={},bt(e,this,function(r){r.create=function(n,a,i){return new eo(n,a,i)},r.fire=function(n){n&&(n.complete(),t&&lt(t.perfEvent)&&t.perfEvent(n))},r.setCtx=function(n,a){if(n){var i=r[_i]=r[_i]||{};i[n]=a}},r.getCtx=function(n){return(r[_i]||{})[n]}})}return e}();var zs="CoreUtils.doPerf";function qn(e,t,r,n,a){if(e){var i=e;if(lt(i.getPerfMgr)&&(i=i.getPerfMgr()),i){var s=void 0,m=i.getCtx(zs);try{if(s=i.create(t(),n,a),s){if(m&&s.setCtx&&(s.setCtx(eo.ParentContextKey,m),m.getCtx&&m.setCtx)){var _=m.getCtx(eo.ChildrenContextKey);_||(_=[],m.setCtx(eo.ChildrenContextKey,_)),_.push(s)}return i.setCtx(zs,s),r(s)}}catch(h){s&&s.setCtx&&s.setCtx("exception",h)}finally{s&&i.fire(s),i.setCtx(zs,m)}}}return r()}function Xs(){return qd}var Iu=function(){function e(t,r){var n=this,a=null,i=lt(t.processTelemetry),s=lt(t.setNextPlugin);n._hasRun=!1,n.getPlugin=function(){return t},n.getNext=function(){return a},n.setNext=function(m){a=m},n.processTelemetry=function(m,_){_||(_=r);var h=t?t.identifier:"TelemetryPluginChain";qn(_?_.core():null,function(){return h+":processTelemetry"},function(){if(t&&i){n._hasRun=!0;try{_.setNext(a),s&&t.setNextPlugin(a),a&&(a._hasRun=!1),t.processTelemetry(m,_)}catch(re){var k=a&&a._hasRun;(!a||!k)&&_.diagLog().throwInternal(Pe.CRITICAL,Ie.PluginException,"Plugin ["+t.identifier+"] failed during processTelemetry - "+ot(re)),a&&!k&&a.processTelemetry(m,_)}}else a&&(n._hasRun=!0,a.processTelemetry(m,_))},function(){return{item:m}},!m.sync)}}return e}();function Ks(e,t){var r=[];if(e&&e.length>0)for(var n=null,a=0;a<e.length;a++){var i=e[a];if(i&&lt(i.processTelemetry)){var s=new Iu(i,t);r.push(s),n&&n.setNext(s),n=s}}return r.length>0?r[0]:null}function jd(e,t,r){var n=[],a=!r;if(e)for(;e;){var i=e.getPlugin();(a||i===r)&&(a=!0,n.push(i)),e=e.getNext()}return a||n.push(r),Ks(n,t)}function zd(e,t,r){var n=e,a=!1;return r&&e&&(n=[],nt(e,function(i){(a||i===r)&&(a=!0,n.push(i))})),r&&!a&&(n||(n=[]),n.push(r)),Ks(n,t)}var Qn=function(){function e(t,r,n,a){var i=this,s=null;a!==null&&(t&&lt(t.getPlugin)?s=jd(t,i,a||t.getPlugin()):a?s=zd(t,i,a):Jt(a)&&(s=Ks(t,i))),i.core=function(){return n},i.diagLog=function(){return Zn(n,r)},i.getCfg=function(){return r},i.getExtCfg=function(m,_){_===void 0&&(_={});var h;if(r){var k=r.extensionConfig;k&&m&&(h=k[m])}return h||_},i.getConfig=function(m,_,h){h===void 0&&(h=!1);var k,re=i.getExtCfg(m,null);return re&&!Le(re[_])?k=re[_]:r&&!Le(r[_])&&(k=r[_]),Le(k)?h:k},i.hasNext=function(){return s!=null},i.getNext=function(){return s},i.setNext=function(m){s=m},i.processNext=function(m){var _=s;_&&(s=_.getNext(),_.processTelemetry(m,i))},i.createNew=function(m,_){return m===void 0&&(m=null),new e(m||s,r,n,_)}}return e}();var Cu="iKey",d0="extensionConfig";var v0="getPlugin",In=function(){function e(){var t=this,r=!1,n=null,a=null;t.core=null,t.diagLog=function(i){return t._getTelCtx(i).diagLog()},t.isInitialized=function(){return r},t.setInitialized=function(i){r=i},t.setNextPlugin=function(i){a=i},t.processNext=function(i,s){s?s.processNext(i):a&&lt(a.processTelemetry)&&a.processTelemetry(i,null)},t._getTelCtx=function(i){i===void 0&&(i=null);var s=i;if(!s){var m=n||new Qn(null,{},t.core);a&&a[v0]?s=m.createNew(null,a[v0]):s=m.createNew(null,a)}return s},t._baseTelInit=function(i,s,m,_){i&&St(i,d0,[],null,Le),!_&&s&&(_=s.getProcessTelContext().getNext());var h=a;a&&a[v0]&&(h=a[v0]()),t.core=s,n=new Qn(_,i,s,h),r=!0}}return e.prototype.initialize=function(t,r,n,a){this._baseTelInit(t,r,n,a)},e}();var Ws="processTelemetry",Mu="priority",Bu="setNextPlugin",Nu="isInitialized";function to(e,t){for(var r=[],n=null,a=e.getNext();a;){var i=a.getPlugin();i&&(n&&lt(n[Bu])&&lt(i[Ws])&&n[Bu](i),(!lt(i[Nu])||!i[Nu]())&&r.push(i),n=i,a=a.getNext())}nt(r,function(s){s.initialize(e.getCfg(),e.core(),t,e.getNext())})}function Ys(e){return e.sort(function(t,r){var n=0,a=lt(r[Ws]);return lt(t[Ws])?n=a?t[Mu]-r[Mu]:1:a&&(n=-1),n})}var $s=500,Gd="Channel has invalid priority",Pu=function(e){dt(t,e);function t(){var r=e.call(this)||this;r.identifier="ChannelControllerPlugin",r.priority=$s;var n;bt(t,r,function(m,_){m.setNextPlugin=function(h){},m.processTelemetry=function(h,k){n&&nt(n,function(re){if(re.length>0){var oe=r._getTelCtx(k).createNew(re);oe.processNext(h)}})},m.getChannelControls=function(){return n},m.initialize=function(h,k,re){m.isInitialized()||(_.initialize(h,k,re),s((h||{}).channels,re),nt(n,function(oe){return to(new Qn(oe,h,k),re)}))}});function a(m){nt(m,function(_){_.priority<$s&&Ir(Gd+_.identifier)})}function i(m){m&&m.length>0&&(m=m.sort(function(_,h){return _.priority-h.priority}),a(m),n.push(m))}function s(m,_){if(n=[],m&&nt(m,function(k){return i(k)}),_){var h=[];nt(_,function(k){k.priority>$s&&h.push(k)}),i(h)}}return r}return t._staticInit=function(){var r=t.prototype;ca(r,"ChannelControls",r.getChannelControls),ca(r,"channelQueue",r.getChannelControls)}(),t}(In);var Fu="toGMTString",Lu="toUTCString",tl="cookie",Zs="expires",Js="enabled",Du="isCookieUseDisabled",Ou="disableCookiesUsage",fa="_ckMgr",Cn="",_0=null,Qs=null,ku=null,ro=lr(),Hu={},h0={};function Xd(e,t){var r=Ha[fa]||h0[fa];return r||(r=Ha[fa]=Ha(e,t),h0[fa]=r),r}function m0(e){return e?e.isEnabled():!0}function Kd(e){var t=e.cookieCfg=e.cookieCfg||{};if(St(t,"domain",e.cookieDomain,Rs,Le),St(t,"path",e.cookiePath||"/",null,Le),Le(t[Js])){var r=void 0;Jt(e[Du])||(r=!e[Du]),Jt(e[Ou])||(r=!e[Ou]),t[Js]=r}return t}function Ua(e,t){var r;if(e)r=e.getCookieMgr();else if(t){var n=t.cookieCfg;n[fa]?r=n[fa]:r=Ha(t)}return r||(r=Xd(t,(e||{}).logger)),r}function Ha(e,t){var r=Kd(e||h0),n=r.path||"/",a=r.domain,i=r[Js]!==!1,s={isEnabled:function(){var m=i&&el(t),_=h0[fa];return m&&_&&s!==_&&(m=m0(_)),m},setEnabled:function(m){i=m!==!1},set:function(m,_,h,k,re){var oe=!1;if(m0(s)){var te={},D=rr(_||Cn),Se=D.indexOf(";");if(Se!==-1&&(D=rr(_.substring(0,Se)),te=ju(_.substring(Se+1))),St(te,"domain",k||a,ci,Jt),!Le(h)){var P=Da();if(Jt(te[Zs])){var se=mr(),ue=se+h*1e3;if(ue>0){var De=new Date;De.setTime(ue),St(te,Zs,Uu(De,P?Fu:Lu)||Uu(De,P?Fu:Lu)||Cn,ci)}}P||St(te,"max-age",Cn+h,null,Jt)}var et=Jr();et&&et.protocol==="https:"&&(St(te,"secure",null,null,Jt),Qs===null&&(Qs=!rl((Cr()||{}).userAgent)),Qs&&St(te,"SameSite","None",null,Jt)),St(te,"path",re||n,null,Jt);var ut=r.setCookie||qu;ut(m,Vu(D,te)),oe=!0}return oe},get:function(m){var _=Cn;return m0(s)&&(_=(r.getCookie||Wd)(m)),_},del:function(m,_){var h=!1;return m0(s)&&(h=s.purge(m,_)),h},purge:function(m,_){var h,k=!1;if(el(t)){var re=(h={},h.path=_||"/",h[Zs]="Thu, 01 Jan 1970 00:00:01 GMT",h);Da()||(re["max-age"]="0");var oe=r.delCookie||qu;oe(m,Vu(Cn,re)),k=!0}return k}};return s[fa]=s,s}function el(e){if(_0===null){_0=!1;try{var t=ro||{};_0=t[tl]!==void 0}catch(r){e&&e.throwInternal(Pe.WARNING,Ie.CannotAccessCookie,"Cannot access document.cookie - "+xt(r),{exception:ot(r)})}}return _0}function ju(e){var t={};if(e&&e.length){var r=rr(e).split(";");nt(r,function(n){if(n=rr(n||Cn),n){var a=n.indexOf("=");a===-1?t[n]=null:t[rr(n.substring(0,a))]=rr(n.substring(a+1))}})}return t}function Uu(e,t){return lt(e[t])?e[t]():null}function Vu(e,t){var r=e||Cn;return It(t,function(n,a){r+="; "+n+(Le(a)?Cn:"="+a)}),r}function Wd(e){var t=Cn;if(ro){var r=ro[tl]||Cn;ku!==r&&(Hu=ju(r),ku=r),t=rr(Hu[e]||Cn)}return t}function qu(e,t){ro&&(ro[tl]=e+"="+t)}function rl(e){return rt(e)?!!(vr(e,"CPU iPhone OS 12")||vr(e,"iPad; CPU OS 12")||vr(e,"Macintosh; Intel Mac OS X 10_14")&&vr(e,"Version/")&&vr(e,"Safari")||vr(e,"Macintosh; Intel Mac OS X 10_14")&&Is(e,"AppleWebKit/605.1.15 (KHTML, like Gecko)")||vr(e,"Chrome/5")||vr(e,"Chrome/6")||vr(e,"UnrealEngine")&&!vr(e,"Chrome")||vr(e,"UCBrowser/12")||vr(e,"UCBrowser/11")):!1}var Yd="Extensions must provide callback to initialize",zu="_notificationManager";function $d(e,t){return new Gs(t)}var Gu=function(){function e(){var t=!1,r,n,a,i,s;bt(e,this,function(m){m._extensions=new Array,n=new Pu,m.logger=new vi({loggingLevelConsole:Pe.CRITICAL}),r=[],m.isInitialized=function(){return t},m.initialize=function(_,h,k,re){m.isInitialized()&&Ir("Core should not be initialized more than once"),(!_||Le(_.instrumentationKey))&&Ir("Please provide instrumentation key"),a=re,m[zu]=re,m.config=_||{},re&&m.config.disableDbgExt!==!0&&re.addNotificationListener(wu(_)),m.config.enablePerfMgr&&St(m.config,"createPerfMgr",$d),_.extensions=Le(_.extensions)?[]:_.extensions;var oe=hr(_,d0);oe.NotificationManager=re,k&&(m.logger=k);var te=[];te.push.apply(te,Zo(Zo([],h,!1),_.extensions,!1)),te=Ys(te);var D=[],Se=[],P={};nt(te,function(se){(Le(se)||Le(se.initialize))&&Ir(Yd);var ue=se.priority,De=se.identifier;se&&ue&&(Le(P[ue])?P[ue]=De:k.warnToConsole("Two extensions have same priority #"+ue+" - "+P[ue]+", "+De)),!ue||ue<n.priority?D.push(se):Se.push(se)}),te.push(n),D.push(n),te=Ys(te),m._extensions=te,to(new Qn([n],_,m),te),to(new Qn(D,_,m),te),m._extensions=D,m.getTransmissionControls().length===0&&Ir("No channels available"),t=!0,m.releaseQueue()},m.getTransmissionControls=function(){return n.getChannelControls()},m.track=function(_){St(_,Cu,m.config.instrumentationKey,null,i0),St(_,"time",Nr(new Date),null,i0),St(_,"ver","4.0",null,Le),m.isInitialized()?m.getProcessTelContext().processNext(_):r.push(_)},m.getProcessTelContext=function(){var _=m._extensions,h=_;return(!_||_.length===0)&&(h=[n]),new Qn(h,m.config,m)},m.getNotifyMgr=function(){return a||(a=oi({addNotificationListener:function(_){},removeNotificationListener:function(_){},eventsSent:function(_){},eventsDiscarded:function(_,h){},eventsSendRequest:function(_,h){}}),m[zu]=a),a},m.getCookieMgr=function(){return s||(s=Ha(m.config,m.logger)),s},m.setCookieMgr=function(_){s=_},m.getPerfMgr=function(){return i||m.config&&m.config.enablePerfMgr&&lt(m.config.createPerfMgr)&&(i=m.config.createPerfMgr(m,m.getNotifyMgr())),i||Xs()},m.setPerfMgr=function(_){i=_},m.eventCnt=function(){return r.length},m.releaseQueue=function(){r.length>0&&(nt(r,function(_){m.getProcessTelContext().processNext(_)}),r=[])}})}return e}();var Xu=function(){function e(t){this.listeners=[];var r=!!(t||{}).perfEvtsSendAll;bt(e,this,function(n){n.addNotificationListener=function(a){n.listeners.push(a)},n.removeNotificationListener=function(a){for(var i=Un(n.listeners,a);i>-1;)n.listeners.splice(i,1),i=Un(n.listeners,a)},n.eventsSent=function(a){nt(n.listeners,function(i){i&&i.eventsSent&&setTimeout(function(){return i.eventsSent(a)},0)})},n.eventsDiscarded=function(a,i){nt(n.listeners,function(s){s&&s.eventsDiscarded&&setTimeout(function(){return s.eventsDiscarded(a,i)},0)})},n.eventsSendRequest=function(a,i){nt(n.listeners,function(s){if(s&&s.eventsSendRequest)if(i)setTimeout(function(){return s.eventsSendRequest(a,i)},0);else try{s.eventsSendRequest(a,i)}catch{}})},n.perfEvent=function(a){a&&(r||!a.isChildEvt())&&nt(n.listeners,function(i){if(i&&i.perfEvent)if(a.isAsync)setTimeout(function(){return i.perfEvent(a)},0);else try{i.perfEvent(a)}catch{}})}})}return e}();var nl=function(e){dt(t,e);function t(){var r=e.call(this)||this,n=0;return bt(t,r,function(a,i){a.initialize=function(_,h,k,re){i.initialize(_,h,k||new vi(_),re||new Xu(_))},a.track=function(_){qn(a.getPerfMgr(),function(){return"AppInsightsCore:track"},function(){_===null&&(m(_),Ir("Invalid telemetry item")),s(_),i.track(_)},function(){return{item:_}},!_.sync)},a.addNotificationListener=function(_){var h=a.getNotifyMgr();h&&h.addNotificationListener(_)},a.removeNotificationListener=function(_){var h=a.getNotifyMgr();h&&h.removeNotificationListener(_)},a.pollInternalLogs=function(_){var h=a.config.diagnosticLogInterval;return(!h||!(h>0))&&(h=1e4),n&&a.stopPollingInternalLogs(),n=setInterval(function(){var k=a.logger?a.logger.queue:[];nt(k,function(re){var oe={name:_||"InternalMessageId: "+re.messageId,iKey:a.config.instrumentationKey,time:Nr(new Date),baseType:$n.dataType,baseData:{message:re.message}};a.track(oe)}),k.length=0},h),n},a.stopPollingInternalLogs=function(){!n||(clearInterval(n),n=0)};function s(_){if(Le(_.name))throw m(_),Error("telemetry name required")}function m(_){var h=a.getNotifyMgr();h&&h.eventsDiscarded([_],tu.InvalidEvent)}}),r}return t}(Gu);var Ku=4294967296,Va=4294967295,Wu=!1,no=123456789,ao=987654321;function Zd(e){e<0&&(e>>>=0),no=123456789+e&Va,ao=987654321-e&Va,Wu=!0}function Qd(){try{var e=mr()&2147483647;Zd((Math.random()*Ku^e)+e)}catch{}}function mi(e){var t,r=Hs()||Us();return r&&r.getRandomValues?t=r.getRandomValues(new Uint32Array(1))[0]&Va:Da()?(Wu||Qd(),t=Yu()&Va):t=Math.floor(Ku*Math.random()|0),e||(t>>>=0),t}function Yu(e){ao=36969*(ao&65535)+(ao>>16)&Va,no=18e3*(no&65535)+(no>>16)&Va;var t=(ao<<16)+(no&65535)>>>0&Va|0;return e||(t>>>=0),t}var $u="visibilitychange",Zu="pagehide";function p0(e,t){var r=!1,n=Vn();n&&(r=Rn(n,e,t),r=Rn(n.body,e,t)||r);var a=lr();return a&&(r=Rn(a,e,t)||r),r}function al(e,t,r){var n=!1;if(t&&e&&_r(e)){var a=[];nt(e,function(i){rt(i)&&(!r||Un(r,i)===-1?n=p0(i,t)||n:a.push(i))}),!n&&a.length>0&&(n=al(a,t))}return n}function il(e,t){return al(["beforeunload","unload","pagehide"],e,t)}function io(e,t){function r(a){var i=lr();e&&i&&i.visibilityState==="hidden"&&e(a)}var n=!1;return(!t||Un(t,Zu)===-1)&&(n=p0(Zu,e)),(!t||Un(t,$u)===-1)&&(n=p0($u,r)||n),!n&&t&&(n=io(e)),n}function hi(e){e===void 0&&(e=22);for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r=mi()>>>0,n=0,a="";a.length<e;)n++,a+=t.charAt(r&63),r>>>=6,n===5&&(r=(mi()<<2&4294967295|r&3)>>>0,n=0);return a}function Gr(){for(var e=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],t="",r,n=0;n<4;n++)r=mi(),t+=e[r&15]+e[r>>4&15]+e[r>>8&15]+e[r>>12&15]+e[r>>16&15]+e[r>>20&15]+e[r>>24&15]+e[r>>28&15];var a=e[8+(mi()&3)|0];return t.substr(0,8)+t.substr(9,4)+"4"+t.substr(13,3)+a+t.substr(16,3)+t.substr(19,12)}var Ju="_aiHooks",ec=["req","rsp","hkErr","fnErr"];function sl(e,t){if(e)for(var r=0;r<e.length&&!t(e[r],r);r++);}function ol(e,t,r,n,a){a>=0&&a<=2&&sl(e,function(i,s){var m=i.cbks,_=m[ec[a]];if(_){t.ctx=function(){var re=n[s]=n[s]||{};return re};try{_.apply(t.inst,r)}catch(re){var h=t.err;try{var k=m[ec[2]];k&&(t.err=re,k.apply(t.inst,r))}catch{}finally{t.err=h}}}})}function rv(e){return function(){var t=this,r=arguments,n=e.h,a={name:e.n,inst:t,ctx:null,set:_},i=[],s=m([a],r);function m(k,re){return sl(re,function(oe){k.push(oe)}),k}function _(k,re){r=m([],r),r[k]=re,s=m([a],r)}ol(n,a,s,i,0);var h=e.f;try{a.rslt=h.apply(t,r)}catch(k){throw a.err=k,ol(n,a,s,i,3),k}return ol(n,a,s,i,1),a.rslt}}function tc(e,t,r){var n=null;return e&&(Ji(e,t)?n=e:r&&(n=tc(bu(e),t,!1))),n}function ll(e,t,r){return e?oo(e[$t],t,r,!1):null}function oo(e,t,r,n){if(n===void 0&&(n=!0),e&&t&&r){var a=tc(e,t,n);if(a){var i=a[t];if(typeof i===En){var s=i[Ju];if(!s){s={i:0,n:t,f:i,h:[]};var m=rv(s);m[Ju]=s,a[t]=m}var _={id:s.i,cbks:r,rm:function(){var h=this.id;sl(s.h,function(k,re){if(k.id===h)return s.h.splice(re,1),1})}};return s.i++,s.h.push(_),_}}}return null}var Nt={requestContextHeader:"Request-Context",requestContextTargetKey:"appId",requestContextAppIdFormat:"appId=cid-v1:",requestIdHeader:"Request-Id",traceParentHeader:"traceparent",traceStateHeader:"tracestate",sdkContextHeader:"Sdk-Context",sdkContextHeaderAppIdRequest:"appId",requestContextHeaderLowerCase:"request-context"};function ul(e,t,r){var n=t.length,a=rc(e,t);if(a.length!==n){for(var i=0,s=a;r[s]!==void 0;)i++,s=a.substring(0,150-3)+nc(i);a=s}return a}function rc(e,t){var r;return t&&(t=rr(t.toString()),t.length>150&&(r=t.substring(0,150),e&&e.throwInternal(Pe.WARNING,Ie.NameTooLong,"name is too long. It has been truncated to "+150+" characters.",{name:t},!0))),r||t}function Pt(e,t,r){r===void 0&&(r=1024);var n;return t&&(r=r||1024,t=rr(t),t.toString().length>r&&(n=t.toString().substring(0,r),e&&e.throwInternal(Pe.WARNING,Ie.StringValueTooLong,"string value is too long. It has been truncated to "+r+" characters.",{value:t},!0))),n||t}function Jn(e,t){return dl(e,t,2048,Ie.UrlTooLong)}function so(e,t){var r;return t&&t.length>32768&&(r=t.substring(0,32768),e&&e.throwInternal(Pe.WARNING,Ie.MessageTruncated,"message is too long, it has been truncated to "+32768+" characters.",{message:t},!0)),r||t}function cl(e,t){var r;if(t){var n=""+t;n.length>32768&&(r=n.substring(0,32768),e&&e.throwInternal(Pe.WARNING,Ie.ExceptionTruncated,"exception is too long, it has been truncated to "+32768+" characters.",{exception:t},!0))}return r||t}function Pr(e,t){if(t){var r={};It(t,function(n,a){if(wn(a)&&An())try{a=pr().stringify(a)}catch(i){e&&e.throwInternal(Pe.WARNING,Ie.CannotSerializeObjectNonSerializable,"custom property is not valid",{exception:i},!0)}a=Pt(e,a,8192),n=ul(e,n,r),r[n]=a}),t=r}return t}function Fr(e,t){if(t){var r={};It(t,function(n,a){n=ul(e,n,r),r[n]=a}),t=r}return t}function fl(e,t){return t&&dl(e,t,128,Ie.IdTooLong).toString()}function dl(e,t,r,n){var a;return t&&(t=rr(t),t.length>r&&(a=t.substring(0,r),e&&e.throwInternal(Pe.WARNING,n,"input is too long, it has been truncated to "+r+" characters.",{data:t},!0))),a||t}function nc(e){var t="00"+e;return t.substr(t.length-3)}function qa(e){var t=null;if(lt(Event))t=new Event(e);else{var r=lr();r&&r.createEvent&&(t=r.createEvent("Event"),t.initEvent(e,!0,!0))}return t}function _n(e,t){return t===void 0&&(t=!1),e==null?t:e.toString().toLowerCase()==="true"}function tn(e){(isNaN(e)||e<0)&&(e=0),e=Math.round(e);var t=""+e%1e3,r=""+Math.floor(e/1e3)%60,n=""+Math.floor(e/(1e3*60))%60,a=""+Math.floor(e/(1e3*60*60))%24,i=Math.floor(e/(1e3*60*60*24));return t=t.length===1?"00"+t:t.length===2?"0"+t:t,r=r.length<2?"0"+r:r,n=n.length<2?"0"+n:n,a=a.length<2?"0"+a:a,(i>0?i+".":"")+a+":"+n+":"+r+"."+t}function vl(e,t){var r=null;return nt(e,function(n){if(n.identifier===t)return r=n,-1}),r}function _l(e,t,r,n,a){return!a&&rt(e)&&(e==="Script error."||e==="Script error")}var Mn="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",pi="sampleRate",Si="ProcessLegacy",lo="http.method",S0="https://dc.services.visualstudio.com",ur="not_specified",x0="iKey";var da;(function(e){e[e.LocalStorage=0]="LocalStorage",e[e.SessionStorage=1]="SessionStorage"})(da||(da={}));var mn;(function(e){e[e.AI=0]="AI",e[e.AI_AND_W3C=1]="AI_AND_W3C",e[e.W3C=2]="W3C"})(mn||(mn={}));var ja=void 0,za=void 0;function ml(){return y0()?b0(da.LocalStorage):null}function b0(e){try{if(Le(dn()))return null;var t=new Date,r=nr(e===da.LocalStorage?"localStorage":"sessionStorage");r.setItem(t.toString(),t.toString());var n=r.getItem(t.toString())!==t.toString();if(r.removeItem(t.toString()),!n)return r}catch{}return null}function hl(){return Ga()?b0(da.SessionStorage):null}function pl(){ja=!1,za=!1}function y0(){return ja===void 0&&(ja=!!b0(da.LocalStorage)),ja}function Sl(e,t){var r=ml();if(r!==null)try{return r.getItem(t)}catch(n){ja=!1,e.throwInternal(Pe.WARNING,Ie.BrowserCannotReadLocalStorage,"Browser failed read of local storage. "+xt(n),{exception:ot(n)})}return null}function xl(e,t,r){var n=ml();if(n!==null)try{return n.setItem(t,r),!0}catch(a){ja=!1,e.throwInternal(Pe.WARNING,Ie.BrowserCannotWriteLocalStorage,"Browser failed write to local storage. "+xt(a),{exception:ot(a)})}return!1}function bl(e,t){var r=ml();if(r!==null)try{return r.removeItem(t),!0}catch(n){ja=!1,e.throwInternal(Pe.WARNING,Ie.BrowserFailedRemovalFromLocalStorage,"Browser failed removal of local storage item. "+xt(n),{exception:ot(n)})}return!1}function Ga(){return za===void 0&&(za=!!b0(da.SessionStorage)),za}function xi(e,t){var r=hl();if(r!==null)try{return r.getItem(t)}catch(n){za=!1,e.throwInternal(Pe.WARNING,Ie.BrowserCannotReadSessionStorage,"Browser failed read of session storage. "+xt(n),{exception:ot(n)})}return null}function bi(e,t,r){var n=hl();if(n!==null)try{return n.setItem(t,r),!0}catch(a){za=!1,e.throwInternal(Pe.WARNING,Ie.BrowserCannotWriteSessionStorage,"Browser failed write to session storage. "+xt(a),{exception:ot(a)})}return!1}function yl(e,t){var r=hl();if(r!==null)try{return r.removeItem(t),!0}catch(n){za=!1,e.throwInternal(Pe.WARNING,Ie.BrowserFailedRemovalFromSessionStorage,"Browser failed removal of session storage item. "+xt(n),{exception:ot(n)})}return!1}var ac=lr()||{},ic=0,lv=[null,null,null,null,null];function uo(e){var t=ic,r=lv,n=r[t];return ac.createElement?r[t]||(n=r[t]=ac.createElement("a")):n={host:gl(e,!0)},n.href=e,t++,t>=r.length&&(t=0),ic=t,n}function g0(e){var t,r=uo(e);return r&&(t=r.href),t}function E0(e,t){return e?e.toUpperCase()+" "+t:t}function gl(e,t){var r=T0(e,t)||"";if(r){var n=r.match(/(www[0-9]?\.)?(.[^/:]+)(\:[\d]+)?/i);if(n!=null&&n.length>3&&rt(n[2])&&n[2].length>0)return n[2]+(n[3]||"")}return r}function T0(e,t){var r=null;if(e){var n=e.match(/(\w*):\/\/(.[^/:]+)(\:[\d]+)?/i);if(n!=null&&n.length>2&&rt(n[2])&&n[2].length>0&&(r=n[2]||"",t&&n.length>2)){var a=(n[1]||"").toLowerCase(),i=n[3]||"";(a==="http"&&i===":80"||a==="https"&&i===":443")&&(i=""),r+=i}}return r}var cv=["https://dc.services.visualstudio.com/v2/track","https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"];function Xa(e){return cv.indexOf(e.toLowerCase())!==-1}var ea={correlationIdPrefix:"cid-v1:",canIncludeCorrelationHeader:function(e,t,r){if(!t||e&&e.disableCorrelationHeaders)return!1;if(e&&e.correlationHeaderExcludePatterns){for(var n=0;n<e.correlationHeaderExcludePatterns.length;n++)if(e.correlationHeaderExcludePatterns[n].test(t))return!1}var a=uo(t).host.toLowerCase();if(a&&(a.indexOf(":443")!==-1||a.indexOf(":80")!==-1)&&(a=(T0(t,!0)||"").toLowerCase()),(!e||!e.enableCorsCorrelation)&&a&&a!==r)return!1;var i=e&&e.correlationHeaderDomains;if(i){var s;if(nt(i,function(h){var k=new RegExp(h.toLowerCase().replace(/\\/g,"\\\\").replace(/\./g,"\\.").replace(/\*/g,".*"));s=s||k.test(a)}),!s)return!1}var m=e&&e.correlationHeaderExcludedDomains;if(!m||m.length===0)return!0;for(var n=0;n<m.length;n++){var _=new RegExp(m[n].toLowerCase().replace(/\\/g,"\\\\").replace(/\./g,"\\.").replace(/\*/g,".*"));if(_.test(a))return!1}return a&&a.length>0},getCorrelationContext:function(e){if(e){var t=ea.getCorrelationContextValue(e,Nt.requestContextTargetKey);if(t&&t!==ea.correlationIdPrefix)return t}},getCorrelationContextValue:function(e,t){if(e)for(var r=e.split(","),n=0;n<r.length;++n){var a=r[n].split("=");if(a.length===2&&a[0]===t)return a[1]}}};function oc(e,t,r,n){var a,i=n,s=n;if(t&&t.length>0){var m=uo(t);if(a=m.host,!i)if(m.pathname!=null){var _=m.pathname.length===0?"/":m.pathname;_.charAt(0)!=="/"&&(_="/"+_),s=m.pathname,i=Pt(e,r?r+" "+_:_)}else i=Pt(e,t)}else a=n,i=n;return{target:a,name:i,data:s}}function yi(){var e=en();if(e&&e.now&&e.timing){var t=e.now()+e.timing.navigationStart;if(t>0)return t}return mr()}function Sr(e,t){var r=null;return e!==0&&t!==0&&!Le(e)&&!Le(t)&&(r=t-e),r}var fv=";",dv="=";function El(e){if(!e)return{};var t=e.split(fv),r=a0(t,function(a,i){var s=i.split(dv);if(s.length===2){var m=s[0].toLowerCase(),_=s[1];a[m]=_}return a},{});if(vn(r).length>0){if(r.endpointsuffix){var n=r.location?r.location+".":"";r.ingestionendpoint=r.ingestionendpoint||"https://"+n+"dc."+r.endpointsuffix}r.ingestionendpoint=r.ingestionendpoint||S0}return r}var Tl=function(){function e(){}return e}();var wl=function(e){dt(t,e);function t(){return e.call(this)||this}return t}(Tl);var sc=function(){function e(){this.ver=1,this.sampleRate=100,this.tags={}}return e}();var w0=function(e){dt(t,e);function t(r,n,a){var i=e.call(this)||this;return i.name=Pt(r,a)||ur,i.data=n,i.time=Nr(new Date),i.aiDataContract={time:1,iKey:1,name:1,sampleRate:function(){return i.sampleRate===100?4:1},tags:1,data:1},i}return t}(sc);var R0=function(){function e(){this.ver=2,this.properties={},this.measurements={}}return e}();var rn=function(e){dt(t,e);function t(r,n,a,i){var s=e.call(this)||this;return s.aiDataContract={ver:1,name:1,properties:0,measurements:0},s.name=Pt(r,n)||ur,s.properties=Pr(r,a),s.measurements=Fr(r,i),s}return t.envelopeType="Microsoft.ApplicationInsights.{0}.Event",t.dataType="EventData",t}(R0);var lc=function(){function e(){}return e}();var uc=function(){function e(){this.ver=2,this.exceptions=[],this.properties={},this.measurements={}}return e}();var cc=function(){function e(){this.hasFullStack=!0,this.parsedStack=[]}return e}();var vv="<no_method>",Ei="error",hn="stack",Al="stackDetails",fc="errorSrc",Il="message",_c="description";function Cl(e,t){var r=e;return r&&!rt(r)&&(JSON&&JSON.stringify?(r=JSON.stringify(e),t&&(!r||r==="{}")&&(lt(e.toString)?r=e.toString():r=""+e)):r=""+e+" - (Missing JSON.stringify)"),r||""}function mc(e,t){var r=e;return e&&(r&&!rt(r)&&(r=e[Il]||e[_c]||r),r&&!rt(r)&&(r=Cl(r,!0)),e.filename&&(r=r+" @"+(e.filename||"")+":"+(e.lineno||"?")+":"+(e.colno||"?"))),t&&t!=="String"&&t!=="Object"&&t!=="Error"&&(r||"").indexOf(t)===-1&&(r=t+": "+r),r||""}function _v(e){try{if(wn(e))return"hasFullStack"in e&&"typeName"in e}catch{}return!1}function mv(e){try{if(wn(e))return"ver"in e&&"exceptions"in e&&"properties"in e}catch{}return!1}function dc(e){return e&&e.src&&rt(e.src)&&e.obj&&_r(e.obj)}function gi(e){var t=e||"";rt(t)||(rt(t[hn])?t=t[hn]:t=""+t);var r=t.split(`
15
+ `);return{src:t,obj:r}}function hv(e){for(var t=[],r=e.split(`
16
+ `),n=0;n<r.length;n++){var a=r[n];r[n+1]&&(a+="@"+r[n+1],n++),t.push(a)}return{src:e,obj:t}}function hc(e){var t=null;if(e)try{if(e[hn])t=gi(e[hn]);else if(e[Ei]&&e[Ei][hn])t=gi(e[Ei][hn]);else if(e.exception&&e.exception[hn])t=gi(e.exception[hn]);else if(dc(e))t=e;else if(dc(e[Al]))t=e[Al];else if(window&&window.opera&&e[Il])t=hv(e.message);else if(rt(e))t=gi(e);else{var r=e[Il]||e[_c]||"";rt(e[fc])&&(r&&(r+=`
17
+ `),r+=" from "+e[fc]),r&&(t=gi(r))}}catch(n){t=gi(n)}return t||{src:"",obj:null}}function pv(e){var t="";return e&&(e.obj?nt(e.obj,function(r){t+=r+`
18
+ `}):t=e.src||""),t}function Sv(e){var t,r=e.obj;if(r&&r.length>0){t=[];var n=0,a=0;nt(r,function(D){var Se=D.toString();if(Ml.regex.test(Se)){var P=new Ml(Se,n++);a+=P.sizeInBytes,t.push(P)}});var i=32*1024;if(a>i)for(var s=0,m=t.length-1,_=0,h=s,k=m;s<m;){var re=t[s].sizeInBytes,oe=t[m].sizeInBytes;if(_+=re+oe,_>i){var te=k-h+1;t.splice(h,te);break}h=s,k=m,s++,m--}}return t}function A0(e){var t="";if(e&&(t=e.typeName||e.name||"",!t))try{var r=/function (.{1,200})\(/,n=r.exec(e.constructor.toString());t=n&&n.length>1?n[1]:""}catch{}return t}function Rl(e){if(e)try{if(!rt(e)){var t=A0(e),r=Cl(e,!1);return(!r||r==="{}")&&(e[Ei]&&(e=e[Ei],t=A0(e)),r=Cl(e,!0)),r.indexOf(t)!==0&&t!=="String"?t+":"+r:r}}catch{}return""+(e||"")}var wr=function(e){dt(t,e);function t(r,n,a,i,s,m){var _=e.call(this)||this;return _.aiDataContract={ver:1,exceptions:1,severityLevel:0,properties:0,measurements:0},mv(n)?(_.exceptions=n.exceptions,_.properties=n.properties,_.measurements=n.measurements,n.severityLevel&&(_.severityLevel=n.severityLevel),n.id&&(_.id=n.id),n.problemGroup&&(_.problemGroup=n.problemGroup),_.ver=2,Le(n.isManual)||(_.isManual=n.isManual)):(a||(a={}),_.exceptions=[new vc(r,n,a)],_.properties=Pr(r,a),_.measurements=Fr(r,i),s&&(_.severityLevel=s),m&&(_.id=m)),_}return t.CreateAutoException=function(r,n,a,i,s,m,_,h){var k=A0(s||m||r);return{message:mc(r,k),url:n,lineNumber:a,columnNumber:i,error:Rl(s||m||r),evt:Rl(m||r),typeName:k,stackDetails:hc(_||s||m),errorSrc:h}},t.CreateFromInterface=function(r,n,a,i){var s=n.exceptions&&Fa(n.exceptions,function(_){return vc.CreateFromInterface(r,_)}),m=new t(r,tr(tr({},n),{exceptions:s}),a,i);return m},t.prototype.toInterface=function(){var r=this,n=r.exceptions,a=r.properties,i=r.measurements,s=r.severityLevel,m=r.problemGroup,_=r.id,h=r.isManual,k=n instanceof Array&&Fa(n,function(re){return re.toInterface()})||void 0;return{ver:"4.0",exceptions:k,severityLevel:s,properties:a,measurements:i,problemGroup:m,id:_,isManual:h}},t.CreateSimpleException=function(r,n,a,i,s,m){return{exceptions:[{hasFullStack:!0,message:r,stack:s,typeName:n}]}},t.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",t.dataType="ExceptionData",t.formatError=Rl,t}(uc);var vc=function(e){dt(t,e);function t(r,n,a){var i=e.call(this)||this;if(i.aiDataContract={id:0,outerId:0,typeName:1,message:1,hasFullStack:0,stack:0,parsedStack:2},_v(n))i.typeName=n.typeName,i.message=n.message,i[hn]=n[hn],i.parsedStack=n.parsedStack,i.hasFullStack=n.hasFullStack;else{var s=n,m=s&&s.evt;li(s)||(s=s[Ei]||m||s),i.typeName=Pt(r,A0(s))||ur,i.message=so(r,mc(n||s,i.typeName))||ur;var _=n[Al]||hc(n);i.parsedStack=Sv(_),i[hn]=cl(r,pv(_)),i.hasFullStack=_r(i.parsedStack)&&i.parsedStack.length>0,a&&(a.typeName=a.typeName||i.typeName)}return i}return t.prototype.toInterface=function(){var r=this.parsedStack instanceof Array&&Fa(this.parsedStack,function(a){return a.toInterface()}),n={id:this.id,outerId:this.outerId,typeName:this.typeName,message:this.message,hasFullStack:this.hasFullStack,stack:this[hn],parsedStack:r||void 0};return n},t.CreateFromInterface=function(r,n){var a=n.parsedStack instanceof Array&&Fa(n.parsedStack,function(s){return Ml.CreateFromInterface(s)})||n.parsedStack,i=new t(r,tr(tr({},n),{parsedStack:a}));return i},t}(cc);var Ml=function(e){dt(t,e);function t(r,n){var a=e.call(this)||this;if(a.sizeInBytes=0,a.aiDataContract={level:1,method:1,assembly:0,fileName:0,line:0},typeof r=="string"){var i=r;a.level=n,a.method=vv,a.assembly=rr(i),a.fileName="",a.line=0;var s=i.match(t.regex);s&&s.length>=5&&(a.method=rr(s[2])||a.method,a.fileName=rr(s[4]),a.line=parseInt(s[5])||0)}else a.level=r.level,a.method=r.method,a.assembly=r.assembly,a.fileName=r.fileName,a.line=r.line,a.sizeInBytes=0;return a.sizeInBytes+=a.method.length,a.sizeInBytes+=a.fileName.length,a.sizeInBytes+=a.assembly.length,a.sizeInBytes+=t.baseSize,a.sizeInBytes+=a.level.toString().length,a.sizeInBytes+=a.line.toString().length,a}return t.CreateFromInterface=function(r){return new t(r,null)},t.prototype.toInterface=function(){return{level:this.level,method:this.method,assembly:this.assembly,fileName:this.fileName,line:this.line}},t.regex=/^([\s]+at)?[\s]{0,50}([^\@\()]+?)[\s]{0,50}(\@|\()([^\(\n]+):([0-9]+):([0-9]+)(\)?)$/,t.baseSize=58,t}(lc);var pc=function(){function e(){this.ver=2,this.metrics=[],this.properties={},this.measurements={}}return e}();var I0;(function(e){e[e.Measurement=0]="Measurement",e[e.Aggregation=1]="Aggregation"})(I0||(I0={}));var Sc=function(){function e(){this.kind=I0.Measurement}return e}();var xc=function(e){dt(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.aiDataContract={name:1,kind:0,value:1,count:0,min:0,max:0,stdDev:0},r}return t}(Sc);var nn=function(e){dt(t,e);function t(r,n,a,i,s,m,_,h,k){var re=e.call(this)||this;re.aiDataContract={ver:1,metrics:1,properties:0};var oe=new xc;return oe.count=i>0?i:void 0,oe.max=isNaN(m)||m===null?void 0:m,oe.min=isNaN(s)||s===null?void 0:s,oe.name=Pt(r,n)||ur,oe.value=a,oe.stdDev=isNaN(_)||_===null?void 0:_,re.metrics=[oe],re.properties=Pr(r,h),re.measurements=Fr(r,k),re}return t.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",t.dataType="MetricData",t}(pc);var co=function(e){dt(t,e);function t(){var r=e.call(this)||this;return r.ver=2,r.properties={},r.measurements={},r}return t}(R0);var Lr=function(e){dt(t,e);function t(r,n,a,i,s,m,_){var h=e.call(this)||this;return h.aiDataContract={ver:1,name:0,url:0,duration:0,properties:0,measurements:0,id:0},h.id=fl(r,_),h.url=Jn(r,a),h.name=Pt(r,n)||ur,isNaN(i)||(h.duration=tn(i)),h.properties=Pr(r,s),h.measurements=Fr(r,m),h}return t.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",t.dataType="PageviewData",t}(co);var bc=function(){function e(){this.ver=2,this.success=!0,this.properties={},this.measurements={}}return e}();var an=function(e){dt(t,e);function t(r,n,a,i,s,m,_,h,k,re,oe,te){k===void 0&&(k="Ajax");var D=e.call(this)||this;D.aiDataContract={id:1,ver:1,name:0,resultCode:0,duration:0,success:0,data:0,target:0,type:0,properties:0,measurements:0,kind:0,value:0,count:0,min:0,max:0,stdDev:0,dependencyKind:0,dependencySource:0,commandName:0,dependencyTypeName:0},D.id=n,D.duration=tn(s),D.success=m,D.resultCode=_+"",D.type=Pt(r,k);var Se=oc(r,a,h,i);return D.data=Jn(r,i)||Se.data,D.target=Pt(r,Se.target),re&&(D.target="".concat(D.target," | ").concat(re)),D.name=Pt(r,Se.name),D.properties=Pr(r,oe),D.measurements=Fr(r,te),D}return t.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",t.dataType="RemoteDependencyData",t}(bc);var yc=function(){function e(){this.ver=2,this.properties={},this.measurements={}}return e}();var Bn=function(e){dt(t,e);function t(r,n,a,i,s){var m=e.call(this)||this;return m.aiDataContract={ver:1,message:1,severityLevel:0,properties:0},n=n||ur,m.message=so(r,n),m.properties=Pr(r,i),m.measurements=Fr(r,s),a&&(m.severityLevel=a),m}return t.envelopeType="Microsoft.ApplicationInsights.{0}.Message",t.dataType="MessageData",t}(yc);var gc=function(e){dt(t,e);function t(){var r=e.call(this)||this;return r.ver=2,r.properties={},r.measurements={},r}return t}(co);var Nn=function(e){dt(t,e);function t(r,n,a,i,s,m,_){var h=e.call(this)||this;return h.aiDataContract={ver:1,name:0,url:0,duration:0,perfTotal:0,networkConnect:0,sentRequest:0,receivedResponse:0,domProcessing:0,properties:0,measurements:0},h.url=Jn(r,a),h.name=Pt(r,n)||ur,h.properties=Pr(r,s),h.measurements=Fr(r,m),_&&(h.domProcessing=_.domProcessing,h.duration=_.duration,h.networkConnect=_.networkConnect,h.perfTotal=_.perfTotal,h.receivedResponse=_.receivedResponse,h.sentRequest=_.sentRequest),h}return t.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",t.dataType="PageviewPerformanceData",t}(gc);var jn=function(e){dt(t,e);function t(r,n){var a=e.call(this)||this;return a.aiDataContract={baseType:1,baseData:1},a.baseType=r,a.baseData=n,a}return t}(wl);var Ti;(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"})(Ti||(Ti={}));function _a(e){var t="ai."+e+".";return function(r){return t+r}}var fo=_a("application"),xr=_a("device"),C0=_a("location"),wi=_a("operation"),Bl=_a("session"),va=_a("user"),Ka=_a("cloud"),vo=_a("internal"),Ri=function(e){dt(t,e);function t(){return e.call(this)||this}return t}(Ms({applicationVersion:fo("ver"),applicationBuild:fo("build"),applicationTypeId:fo("typeId"),applicationId:fo("applicationId"),applicationLayer:fo("layer"),deviceId:xr("id"),deviceIp:xr("ip"),deviceLanguage:xr("language"),deviceLocale:xr("locale"),deviceModel:xr("model"),deviceFriendlyName:xr("friendlyName"),deviceNetwork:xr("network"),deviceNetworkName:xr("networkName"),deviceOEMName:xr("oemName"),deviceOS:xr("os"),deviceOSVersion:xr("osVersion"),deviceRoleInstance:xr("roleInstance"),deviceRoleName:xr("roleName"),deviceScreenResolution:xr("screenResolution"),deviceType:xr("type"),deviceMachineName:xr("machineName"),deviceVMName:xr("vmName"),deviceBrowser:xr("browser"),deviceBrowserVersion:xr("browserVersion"),locationIp:C0("ip"),locationCountry:C0("country"),locationProvince:C0("province"),locationCity:C0("city"),operationId:wi("id"),operationName:wi("name"),operationParentId:wi("parentId"),operationRootId:wi("rootId"),operationSyntheticSource:wi("syntheticSource"),operationCorrelationVector:wi("correlationVector"),sessionId:Bl("id"),sessionIsFirst:Bl("isFirst"),sessionIsNew:Bl("isNew"),userAccountAcquisitionDate:va("accountAcquisitionDate"),userAccountId:va("accountId"),userAgent:va("userAgent"),userId:va("id"),userStoreRegion:va("storeRegion"),userAuthUserId:va("authUserId"),userAnonymousUserAcquisitionDate:va("anonUserAcquisitionDate"),userAuthenticatedUserAcquisitionDate:va("authUserAcquisitionDate"),cloudName:Ka("name"),cloudRole:Ka("role"),cloudRoleVer:Ka("roleVer"),cloudRoleInstance:Ka("roleInstance"),cloudEnvironment:Ka("environment"),cloudLocation:Ka("location"),cloudDeploymentUnit:Ka("deploymentUnit"),internalNodeName:vo("nodeName"),internalSdkVersion:vo("sdkVersion"),internalAgentVersion:vo("agentVersion"),internalSnippet:vo("snippet"),internalSdkSrc:vo("sdkSrc")}));var pn=function(){function e(){}return e.create=function(t,r,n,a,i,s){if(n=Pt(a,n)||ur,Le(t)||Le(r)||Le(n))throw Error("Input doesn't contain all required fields");var m="";t[x0]&&(m=t[x0],delete t[x0]);var _={name:n,time:Nr(new Date),iKey:m,ext:s||{},tags:[],data:{},baseType:r,baseData:t};return Le(i)||It(i,function(h,k){_.data[h]=k}),_},e}();var Dr={UserExt:"user",DeviceExt:"device",TraceExt:"trace",WebExt:"web",AppExt:"app",OSExt:"os",SessionExt:"ses",SDKExt:"sdk"},Ft=new Ri;var ma="AppInsightsPropertiesPlugin",_o="AppInsightsChannelPlugin",Nl="ApplicationInsightsAnalytics";var Ec=function(){function e(t,r,n,a){bt(e,this,function(i){var s=null,m=[],_=!1,h;n&&(h=n.logger);function k(){n&&nt(n.getTransmissionControls(),function(oe){nt(oe,function(te){return te.flush(!0)})})}function re(oe){m.push(oe),s||(s=setInterval(function(){var te=m.slice(0),D=!1;m=[],nt(te,function(Se){Se()?D=!0:m.push(Se)}),m.length===0&&(clearInterval(s),s=null),D&&k()},100))}i.trackPageView=function(oe,te){var D=oe.name;if(Le(D)||typeof D!="string"){var Se=lr();D=oe.name=Se&&Se.title||""}var P=oe.uri;if(Le(P)||typeof P!="string"){var se=Jr();P=oe.uri=se&&se.href||""}if(!a.isPerformanceTimingSupported()){t.sendPageViewInternal(oe,te),k(),h.throwInternal(Pe.WARNING,Ie.NavigationTimingNotSupported,"trackPageView: navigation timing API used for calculation of page duration is not supported in this browser. This page view will be collected without duration and timing info.");return}var ue=!1,De,et=a.getPerformanceTiming().navigationStart;et>0&&(De=Sr(et,+new Date),a.shouldCollectDuration(De)||(De=void 0));var ut;!Le(te)&&!Le(te.duration)&&(ut=te.duration),(r||!isNaN(ut))&&(isNaN(ut)&&(te||(te={}),te.duration=De),t.sendPageViewInternal(oe,te),k(),ue=!0);var ht=6e4;te||(te={}),re(function(){var st=!1;try{if(a.isPerformanceTimingDataReady()){st=!0;var yt={name:D,uri:P};a.populatePageViewPerformanceEvent(yt),!yt.isValid&&!ue?(te.duration=De,t.sendPageViewInternal(oe,te)):(ue||(te.duration=yt.durationMs,t.sendPageViewInternal(oe,te)),_||(t.sendPageViewPerformanceInternal(yt,te),_=!0))}else et>0&&Sr(et,+new Date)>ht&&(st=!0,ue||(te.duration=ht,t.sendPageViewInternal(oe,te)))}catch(Vt){h.throwInternal(Pe.CRITICAL,Ie.TrackPVFailedCalc,"trackPageView failed on page load calculation: "+xt(Vt),{exception:ot(Vt)})}return st})}})}return e}();var Tc=function(){function e(t,r){this.prevPageVisitDataKeyName="prevPageVisitData",this.pageVisitTimeTrackingHandler=r,this._logger=t}return e.prototype.trackPreviousPageVisit=function(t,r){try{var n=this.restartPageVisitTimer(t,r);n&&this.pageVisitTimeTrackingHandler(n.pageName,n.pageUrl,n.pageVisitTime)}catch(a){this._logger.warnToConsole("Auto track page visit time failed, metric will not be collected: "+ot(a))}},e.prototype.restartPageVisitTimer=function(t,r){try{var n=this.stopPageVisitTimer();return this.startPageVisitTimer(t,r),n}catch(a){return this._logger.warnToConsole("Call to restart failed: "+ot(a)),null}},e.prototype.startPageVisitTimer=function(t,r){try{if(Ga()){xi(this._logger,this.prevPageVisitDataKeyName)!=null&&Ir("Cannot call startPageVisit consecutively without first calling stopPageVisit");var n=new Tv(t,r),a=pr().stringify(n);bi(this._logger,this.prevPageVisitDataKeyName,a)}}catch(i){this._logger.warnToConsole("Call to start failed: "+ot(i))}},e.prototype.stopPageVisitTimer=function(){try{if(Ga()){var t=mr(),r=xi(this._logger,this.prevPageVisitDataKeyName);if(r&&An()){var n=pr().parse(r);return n.pageVisitTime=t-n.pageVisitStartTime,yl(this._logger,this.prevPageVisitDataKeyName),n}else return null}return null}catch(a){return this._logger.warnToConsole("Stop page visit timer failed: "+ot(a)),null}},e}();var Tv=function(){function e(t,r){this.pageVisitStartTime=mr(),this.pageName=t,this.pageUrl=r}return e}();var wc=function(){function e(t){this.MAX_DURATION_ALLOWED=36e5,t&&(this._logger=t.logger)}return e.prototype.populatePageViewPerformanceEvent=function(t){t.isValid=!1;var r=this.getPerformanceNavigationTiming(),n=this.getPerformanceTiming(),a=0,i=0,s=0,m=0,_=0;(r||n)&&(r?(a=r.duration,i=r.startTime===0?r.connectEnd:Sr(r.startTime,r.connectEnd),s=Sr(r.requestStart,r.responseStart),m=Sr(r.responseStart,r.responseEnd),_=Sr(r.responseEnd,r.loadEventEnd)):(a=Sr(n.navigationStart,n.loadEventEnd),i=Sr(n.navigationStart,n.connectEnd),s=Sr(n.requestStart,n.responseStart),m=Sr(n.responseStart,n.responseEnd),_=Sr(n.responseEnd,n.loadEventEnd)),a===0?this._logger.throwInternal(Pe.WARNING,Ie.ErrorPVCalc,"error calculating page view performance.",{total:a,network:i,request:s,response:m,dom:_}):this.shouldCollectDuration(a,i,s,m,_)?a<Math.floor(i)+Math.floor(s)+Math.floor(m)+Math.floor(_)?this._logger.throwInternal(Pe.WARNING,Ie.ClientPerformanceMathError,"client performance math error.",{total:a,network:i,request:s,response:m,dom:_}):(t.durationMs=a,t.perfTotal=t.duration=tn(a),t.networkConnect=tn(i),t.sentRequest=tn(s),t.receivedResponse=tn(m),t.domProcessing=tn(_),t.isValid=!0):this._logger.throwInternal(Pe.WARNING,Ie.InvalidDurationValue,"Invalid page load duration value. Browser perf data won't be sent.",{total:a,network:i,request:s,response:m,dom:_}))},e.prototype.getPerformanceTiming=function(){return this.isPerformanceTimingSupported()?en().timing:null},e.prototype.getPerformanceNavigationTiming=function(){return this.isPerformanceNavigationTimingSupported()?en().getEntriesByType("navigation")[0]:null},e.prototype.isPerformanceNavigationTimingSupported=function(){var t=en();return t&&t.getEntriesByType&&t.getEntriesByType("navigation").length>0},e.prototype.isPerformanceTimingSupported=function(){var t=en();return t&&t.timing},e.prototype.isPerformanceTimingDataReady=function(){var t=en(),r=t?t.timing:0;return r&&r.domainLookupStart>0&&r.navigationStart>0&&r.responseStart>0&&r.requestStart>0&&r.loadEventEnd>0&&r.responseEnd>0&&r.connectEnd>0&&r.domLoading>0},e.prototype.shouldCollectDuration=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var n=Cr()||{},a=["googlebot","adsbot-google","apis-google","mediapartners-google"],i=n.userAgent,s=!1;if(i)for(var m=0;m<a.length;m++)s=s||i.toLowerCase().indexOf(a[m])!==-1;if(s)return!1;for(var m=0;m<t.length;m++)if(t[m]<0||t[m]>=this.MAX_DURATION_ALLOWED)return!1;return!0},e}();var Rc="duration",Pl="event";function mo(e,t){e&&e.dispatchEvent&&t&&e.dispatchEvent(t)}function wv(e){if(e&&e.reason){var t=e.reason;return!rt(t)&&lt(t.toString)?t.toString():ot(t)}return e||""}var Fl=function(e){dt(t,e);function t(){var r=e.call(this)||this;r.identifier=Nl,r.priority=180,r.autoRoutePVDelay=500;var n,a,i,s=0,m,_;return bt(t,r,function(h,k){var re=Jr(!0);m=re&&re.href||"",h.getCookieMgr=function(){return Ua(h.core)},h.processTelemetry=function(P,se){qn(h.core,function(){return h.identifier+":processTelemetry"},function(){var ue=!1,De=h._telemetryInitializers.length;se=h._getTelCtx(se);for(var et=0;et<De;++et){var ut=h._telemetryInitializers[et];if(ut)try{if(ut.apply(null,[P])===!1){ue=!0;break}}catch(ht){se.diagLog().throwInternal(Pe.CRITICAL,Ie.TelemetryInitializerFailed,"One of telemetry initializers failed, telemetry item will not be sent: "+xt(ht),{exception:ot(ht)},!0)}}ue||h.processNext(P,se)},function(){return{item:P}},!P.sync)},h.trackEvent=function(P,se){try{var ue=pn.create(P,rn.dataType,rn.envelopeType,h.diagLog(),se);h.core.track(ue)}catch(De){h.diagLog().throwInternal(Pe.WARNING,Ie.TrackTraceFailed,"trackTrace failed, trace will not be collected: "+xt(De),{exception:ot(De)})}},h.startTrackEvent=function(P){try{n.start(P)}catch(se){h.diagLog().throwInternal(Pe.CRITICAL,Ie.StartTrackEventFailed,"startTrackEvent failed, event will not be collected: "+xt(se),{exception:ot(se)})}},h.stopTrackEvent=function(P,se,ue){try{n.stop(P,void 0,se)}catch(De){h.diagLog().throwInternal(Pe.CRITICAL,Ie.StopTrackEventFailed,"stopTrackEvent failed, event will not be collected: "+xt(De),{exception:ot(De)})}},h.trackTrace=function(P,se){try{var ue=pn.create(P,Bn.dataType,Bn.envelopeType,h.diagLog(),se);h.core.track(ue)}catch(De){h.diagLog().throwInternal(Pe.WARNING,Ie.TrackTraceFailed,"trackTrace failed, trace will not be collected: "+xt(De),{exception:ot(De)})}},h.trackMetric=function(P,se){try{var ue=pn.create(P,nn.dataType,nn.envelopeType,h.diagLog(),se);h.core.track(ue)}catch(De){h.diagLog().throwInternal(Pe.CRITICAL,Ie.TrackMetricFailed,"trackMetric failed, metric will not be collected: "+xt(De),{exception:ot(De)})}},h.trackPageView=function(P,se){try{var ue=P||{};h._pageViewManager.trackPageView(ue,tr(tr(tr({},ue.properties),ue.measurements),se)),h.config.autoTrackPageVisitTime&&h._pageVisitTimeManager.trackPreviousPageVisit(ue.name,ue.uri)}catch(De){h.diagLog().throwInternal(Pe.CRITICAL,Ie.TrackPVFailed,"trackPageView failed, page view will not be collected: "+xt(De),{exception:ot(De)})}},h.sendPageViewInternal=function(P,se,ue){var De=lr();De&&(P.refUri=P.refUri===void 0?De.referrer:P.refUri);var et=pn.create(P,Lr.dataType,Lr.envelopeType,h.diagLog(),se,ue);h.core.track(et),s=0},h.sendPageViewPerformanceInternal=function(P,se,ue){var De=pn.create(P,Nn.dataType,Nn.envelopeType,h.diagLog(),se,ue);h.core.track(De)},h.trackPageViewPerformance=function(P,se){try{h._pageViewPerformanceManager.populatePageViewPerformanceEvent(P),h.sendPageViewPerformanceInternal(P,se)}catch(ue){h.diagLog().throwInternal(Pe.CRITICAL,Ie.TrackPVFailed,"trackPageViewPerformance failed, page view will not be collected: "+xt(ue),{exception:ot(ue)})}},h.startTrackPage=function(P){try{if(typeof P!="string"){var se=lr();P=se&&se.title||""}a.start(P)}catch(ue){h.diagLog().throwInternal(Pe.CRITICAL,Ie.StartTrackFailed,"startTrackPage failed, page view may not be collected: "+xt(ue),{exception:ot(ue)})}},h.stopTrackPage=function(P,se,ue,De){try{if(typeof P!="string"){var et=lr();P=et&&et.title||""}if(typeof se!="string"){var ut=Jr();se=ut&&ut.href||""}a.stop(P,se,ue,De),h.config.autoTrackPageVisitTime&&h._pageVisitTimeManager.trackPreviousPageVisit(P,se)}catch(ht){h.diagLog().throwInternal(Pe.CRITICAL,Ie.StopTrackFailed,"stopTrackPage failed, page view will not be collected: "+xt(ht),{exception:ot(ht)})}},h.sendExceptionInternal=function(P,se,ue){var De=P.exception||P.error||new Error(ur),et=new wr(h.diagLog(),De,P.properties||se,P.measurements,P.severityLevel,P.id).toInterface(),ut=pn.create(et,wr.dataType,wr.envelopeType,h.diagLog(),se,ue);h.core.track(ut)},h.trackException=function(P,se){try{h.sendExceptionInternal(P,se)}catch(ue){h.diagLog().throwInternal(Pe.CRITICAL,Ie.TrackExceptionFailed,"trackException failed, exception will not be collected: "+xt(ue),{exception:ot(ue)})}},h._onerror=function(P){var se=P&&P.error,ue=P&&P.evt;try{if(!ue){var De=Vn();De&&(ue=De[Pl])}var et=P&&P.url||(lr()||{}).URL,ut=P.errorSrc||"window.onerror@"+et+":"+(P.lineNumber||0)+":"+(P.columnNumber||0),ht={errorSrc:ut,url:et,lineNumber:P.lineNumber||0,columnNumber:P.columnNumber||0,message:P.message};_l(P.message,P.url,P.lineNumber,P.columnNumber,P.error)?Se(wr.CreateAutoException("Script error: The browser's same-origin policy prevents us from getting the details of this exception. Consider using the 'crossorigin' attribute.",et,P.lineNumber||0,P.columnNumber||0,se,ue,null,ut),ht):(P.errorSrc||(P.errorSrc=ut),h.trackException({exception:P,severityLevel:Ti.Error},ht))}catch(yt){var st=se?se.name+", "+se.message:"null";h.diagLog().throwInternal(Pe.CRITICAL,Ie.ExceptionWhileLoggingError,"_onError threw exception while logging error, error will not be collected: "+xt(yt),{exception:ot(yt),errorString:st})}},h.addTelemetryInitializer=function(P){h._telemetryInitializers.push(P)},h.initialize=function(P,se,ue,De){if(!h.isInitialized()){if(Le(se))throw Error("Error initializing");k.initialize(P,se,ue,De),h.setInitialized(!1);var et=h._getTelCtx(),ut=h.identifier;h.config=et.getExtCfg(ut);var ht=t.getDefaultConfig(P);ht!==void 0&&It(ht,function(pt,Lt){h.config[pt]=et.getConfig(ut,pt,Lt),h.config[pt]===void 0&&(h.config[pt]=Lt)}),h.config.isStorageUseDisabled&&pl();var st={instrumentationKey:function(){return P.instrumentationKey},accountId:function(){return h.config.accountId||P.accountId},sessionRenewalMs:function(){return h.config.sessionRenewalMs||P.sessionRenewalMs},sessionExpirationMs:function(){return h.config.sessionExpirationMs||P.sessionExpirationMs},sampleRate:function(){return h.config.samplingPercentage||P.samplingPercentage},sdkExtension:function(){return h.config.sdkExtension||P.sdkExtension},isBrowserLinkTrackingEnabled:function(){return h.config.isBrowserLinkTrackingEnabled||P.isBrowserLinkTrackingEnabled},appId:function(){return h.config.appId||P.appId}};h._pageViewPerformanceManager=new wc(h.core),h._pageViewManager=new Ec(r,h.config.overridePageViewDuration,h.core,h._pageViewPerformanceManager),h._pageVisitTimeManager=new Tc(h.diagLog(),function(pt,Lt,Bt){return oe(pt,Lt,Bt)}),h._telemetryInitializers=h._telemetryInitializers||[],te(st),n=new Ac(h.diagLog(),"trackEvent"),n.action=function(pt,Lt,Bt,Ct){Ct||(Ct={}),Ct[Rc]=Bt.toString(),h.trackEvent({name:pt,properties:Ct})},a=new Ac(h.diagLog(),"trackPageView"),a.action=function(pt,Lt,Bt,Ct,Ze){Le(Ct)&&(Ct={}),Ct[Rc]=Bt.toString();var g={name:pt,uri:Lt,properties:Ct,measurements:Ze};h.sendPageViewInternal(g,Ct)};var yt=Vn(),Vt=Os(),zt=Jr(!0),Zt=r;if(h.config.disableExceptionTracking===!1&&!h.config.autoExceptionInstrumented&&yt){var kr="onerror",Tr=yt[kr];yt.onerror=function(pt,Lt,Bt,Ct,Ze){var g=yt[Pl],K=Tr&&Tr(pt,Lt,Bt,Ct,Ze);return K!==!0&&Zt._onerror(wr.CreateAutoException(pt,Lt,Bt,Ct,Ze,g)),K},h.config.autoExceptionInstrumented=!0}if(h.config.disableExceptionTracking===!1&&h.config.enableUnhandledPromiseRejectionTracking===!0&&!h.config.autoUnhandledPromiseInstrumented&&yt){var ar="onunhandledrejection",fr=yt[ar];yt[ar]=function(pt){var Lt=yt[Pl],Bt=fr&&fr.call(yt,pt);return Bt!==!0&&Zt._onerror(wr.CreateAutoException(wv(pt),zt?zt.href:"",0,0,pt,Lt)),Bt},h.config.autoUnhandledPromiseInstrumented=!0}if(h.config.enableAutoRouteTracking===!0&&Vt&&lt(Vt.pushState)&&lt(Vt.replaceState)&&yt&&typeof Event<"u"){var Wt=r;nt(ue,function(pt){pt.identifier===ma&&(i=pt)}),Vt.pushState=function(pt){return function(){var Bt=pt.apply(this,arguments);return mo(yt,qa(Wt.config.namePrefix+"pushState")),mo(yt,qa(Wt.config.namePrefix+"locationchange")),Bt}}(Vt.pushState),Vt.replaceState=function(pt){return function(){var Bt=pt.apply(this,arguments);return mo(yt,qa(Wt.config.namePrefix+"replaceState")),mo(yt,qa(Wt.config.namePrefix+"locationchange")),Bt}}(Vt.replaceState),yt.addEventListener&&(yt.addEventListener(Wt.config.namePrefix+"popstate",function(){mo(yt,qa(Wt.config.namePrefix+"locationchange"))}),yt.addEventListener(Wt.config.namePrefix+"locationchange",function(){if(i&&i.context&&i.context.telemetryTrace){i.context.telemetryTrace.traceID=Gr();var pt="_unknown_";zt&&zt.pathname&&(pt=zt.pathname+(zt.hash||"")),i.context.telemetryTrace.name=Pt(Wt.diagLog(),pt)}_&&(m=_),_=zt&&zt.href||"",setTimeout(function(Lt){Wt.trackPageView({refUri:Lt,properties:{duration:0}})}.bind(r,m),Wt.autoRoutePVDelay)}))}h.setInitialized(!0)}};function oe(P,se,ue){var De={PageName:P,PageUrl:se};h.trackMetric({name:"PageVisitTime",average:ue,max:ue,min:ue,sampleCount:1},De)}function te(P){if(!P.isBrowserLinkTrackingEnabled()){var se=["/browserLinkSignalR/","/__browserLink/"],ue=function(De){if(De.baseType===an.dataType){var et=De.baseData;if(et){for(var ut=0;ut<se.length;ut++)if(et.target&&et.target.indexOf(se[ut])>=0)return!1}}return!0};D(ue)}}function D(P){h._telemetryInitializers.push(P)}function Se(P,se){var ue=pn.create(P,wr.dataType,wr.envelopeType,h.diagLog(),se);h.core.track(ue)}}),r}return t.getDefaultConfig=function(r){return r||(r={}),r.sessionRenewalMs=30*60*1e3,r.sessionExpirationMs=24*60*60*1e3,r.disableExceptionTracking=_n(r.disableExceptionTracking),r.autoTrackPageVisitTime=_n(r.autoTrackPageVisitTime),r.overridePageViewDuration=_n(r.overridePageViewDuration),r.enableUnhandledPromiseRejectionTracking=_n(r.enableUnhandledPromiseRejectionTracking),(isNaN(r.samplingPercentage)||r.samplingPercentage<=0||r.samplingPercentage>=100)&&(r.samplingPercentage=100),r.isStorageUseDisabled=_n(r.isStorageUseDisabled),r.isBrowserLinkTrackingEnabled=_n(r.isBrowserLinkTrackingEnabled),r.enableAutoRouteTracking=_n(r.enableAutoRouteTracking),r.namePrefix=r.namePrefix||"",r.enableDebug=_n(r.enableDebug),r.disableFlushOnBeforeUnload=_n(r.disableFlushOnBeforeUnload),r.disableFlushOnUnload=_n(r.disableFlushOnUnload,r.disableFlushOnBeforeUnload),r},t.Version="2.7.4",t}(In);var Ac=function(){function e(t,r){var n=this,a={};n.start=function(i){typeof a[i]<"u"&&t.throwInternal(Pe.WARNING,Ie.StartCalledMoreThanOnce,"start was called more than once for this event without calling stop.",{name:i,key:i},!0),a[i]=+new Date},n.stop=function(i,s,m,_){var h=a[i];if(isNaN(h))t.throwInternal(Pe.WARNING,Ie.StopCalledWithoutStart,"stop was called without a corresponding start.",{name:i,key:i},!0);else{var k=+new Date,re=Sr(h,k);n.action(i,s,re,m,_)}delete a[i],a[i]=void 0}}return e}();var Ic=function(){function e(t,r){var n=[],a=!1;this._get=function(){return n},this._set=function(i){return n=i,n},bt(e,this,function(i){i.enqueue=function(s){if(i.count()>=r.eventsLimitInMem()){a||(t.throwInternal(Pe.WARNING,Ie.InMemoryStorageBufferFull,"Maximum in-memory buffer size reached: "+i.count(),!0),a=!0);return}n.push(s)},i.count=function(){return n.length},i.size=function(){for(var s=n.length,m=0;m<n.length;m++)s+=n[m].length;return r.emitLineDelimitedJson()||(s+=2),s},i.clear=function(){n=[],a=!1},i.getItems=function(){return n.slice(0)},i.batchPayloads=function(s){if(s&&s.length>0){var m=r.emitLineDelimitedJson()?s.join(`
19
+ `):"["+s.join(",")+"]";return m}return null}})}return e}(),Cc=function(e){dt(t,e);function t(r,n){var a=e.call(this,r,n)||this;return bt(t,a,function(i,s){i.markAsSent=function(m){s.clear()},i.clearSent=function(m){}}),a}return t}(Ic);var Mc=function(e){dt(t,e);function t(r,n){var a=e.call(this,r,n)||this,i=!1;return bt(t,a,function(s,m){var _=oe(t.BUFFER_KEY),h=oe(t.SENT_BUFFER_KEY),k=s._set(_.concat(h));k.length>t.MAX_BUFFER_SIZE&&(k.length=t.MAX_BUFFER_SIZE),te(t.SENT_BUFFER_KEY,[]),te(t.BUFFER_KEY,k),s.enqueue=function(D){if(s.count()>=t.MAX_BUFFER_SIZE){i||(r.throwInternal(Pe.WARNING,Ie.SessionStorageBufferFull,"Maximum buffer size reached: "+s.count(),!0),i=!0);return}m.enqueue(D),te(t.BUFFER_KEY,s._get())},s.clear=function(){m.clear(),te(t.BUFFER_KEY,s._get()),te(t.SENT_BUFFER_KEY,[]),i=!1},s.markAsSent=function(D){te(t.BUFFER_KEY,s._set(re(D,s._get())));var Se=oe(t.SENT_BUFFER_KEY);Se instanceof Array&&D instanceof Array&&(Se=Se.concat(D),Se.length>t.MAX_BUFFER_SIZE&&(r.throwInternal(Pe.CRITICAL,Ie.SessionStorageBufferFull,"Sent buffer reached its maximum size: "+Se.length,!0),Se.length=t.MAX_BUFFER_SIZE),te(t.SENT_BUFFER_KEY,Se))},s.clearSent=function(D){var Se=oe(t.SENT_BUFFER_KEY);Se=re(D,Se),te(t.SENT_BUFFER_KEY,Se)};function re(D,Se){var P=[];return nt(Se,function(se){!lt(se)&&Un(D,se)===-1&&P.push(se)}),P}function oe(D){var Se=D;try{Se=n.namePrefix&&n.namePrefix()?n.namePrefix()+"_"+Se:Se;var P=xi(r,Se);if(P){var se=pr().parse(P);if(rt(se)&&(se=pr().parse(se)),se&&_r(se))return se}}catch(ue){r.throwInternal(Pe.CRITICAL,Ie.FailedToRestoreStorageBuffer," storage key: "+Se+", "+xt(ue),{exception:ot(ue)})}return[]}function te(D,Se){var P=D;try{P=n.namePrefix&&n.namePrefix()?n.namePrefix()+"_"+P:P;var se=JSON.stringify(Se);bi(r,P,se)}catch(ue){bi(r,P,JSON.stringify([])),r.throwInternal(Pe.WARNING,Ie.FailedToSetStorageBuffer," storage key: "+P+", "+xt(ue)+". Buffer cleared",{exception:ot(ue)})}}}),a}return t.BUFFER_KEY="AI_buffer",t.SENT_BUFFER_KEY="AI_sentBuffer",t.MAX_BUFFER_SIZE=2e3,t}(Ic);var Ll="baseType",Kt="baseData",Er="properties",Bc="true";function cr(e,t,r){return St(e,t,r,ci)}function Rv(e,t,r){var n=r.tags=r.tags||{},a=t.ext=t.ext||{},i=t.tags=t.tags||[],s=a.user;s&&(cr(n,Ft.userAuthUserId,s.authId),cr(n,Ft.userId,s.id||s.localId));var m=a.app;m&&cr(n,Ft.sessionId,m.sesId);var _=a.device;_&&(cr(n,Ft.deviceId,_.id||_.localId),cr(n,Ft.deviceType,_.deviceClass),cr(n,Ft.deviceIp,_.ip),cr(n,Ft.deviceModel,_.model),cr(n,Ft.deviceType,_.deviceType));var h=t.ext.web;if(h){cr(n,Ft.deviceLanguage,h.browserLang),cr(n,Ft.deviceBrowserVersion,h.browserVer),cr(n,Ft.deviceBrowser,h.browser);var k=r.data=r.data||{},re=k[Kt]=k[Kt]||{},oe=re[Er]=re[Er]||{};cr(oe,"domain",h.domain),cr(oe,"isManual",h.isManual?Bc:null),cr(oe,"screenRes",h.screenRes),cr(oe,"userConsent",h.userConsent?Bc:null)}var te=a.os;te&&cr(n,Ft.deviceOS,te.name);var D=a.trace;D&&(cr(n,Ft.operationParentId,D.parentID),cr(n,Ft.operationName,Pt(e,D.name)),cr(n,Ft.operationId,D.traceID));for(var Se={},P=i.length-1;P>=0;P--){var se=i[P];It(se,function(De,et){Se[De]=et}),i.splice(P,1)}It(i,function(De,et){Se[De]=et});var ue=tr(tr({},n),Se);ue[Ft.internalSdkVersion]||(ue[Ft.internalSdkVersion]="javascript:".concat(Av.Version)),r.tags=o0(ue)}function ha(e,t,r){Le(e)||It(e,function(n,a){ui(a)?r[n]=a:rt(a)?t[n]=a:An()&&(t[n]=pr().stringify(a))})}function Wa(e,t){Le(e)||It(e,function(r,n){e[r]=n||t})}function Ya(e,t,r,n){var a=new w0(e,n,t);cr(a,"sampleRate",r[pi]),(r[Kt]||{}).startTime&&(a.time=Nr(r[Kt].startTime)),a.iKey=r.iKey;var i=r.iKey.replace(/-/g,"");return a.name=a.name.replace("{0}",i),Rv(e,r,a),r.tags=r.tags||[],o0(a)}function $a(e,t){Le(t[Kt])&&e.throwInternal(Pe.CRITICAL,Ie.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.")}var Av={Version:"2.7.4"};function Nc(e,t,r){$a(e,t);var n=t[Kt].measurements||{},a=t[Kt][Er]||{};ha(t.data,a,n),Le(r)||Wa(a,r);var i=t[Kt];if(Le(i))return e.warnToConsole("Invalid input for dependency data"),null;var s=i[Er]&&i[Er][lo]?i[Er][lo]:"GET",m=new an(e,i.id,i.target,i.name,i.duration,i.success,i.responseCode,s,i.type,i.correlationContext,a,n),_=new jn(an.dataType,m);return Ya(e,an.envelopeType,t,_)}function Dl(e,t,r){$a(e,t);var n={},a={};t[Ll]!==rn.dataType&&(n.baseTypeSource=t[Ll]),t[Ll]===rn.dataType?(n=t[Kt][Er]||{},a=t[Kt].measurements||{}):t[Kt]&&ha(t[Kt],n,a),ha(t.data,n,a),Le(r)||Wa(n,r);var i=t[Kt].name,s=new rn(e,i,n,a),m=new jn(rn.dataType,s);return Ya(e,rn.envelopeType,t,m)}function Pc(e,t,r){$a(e,t);var n=t[Kt].measurements||{},a=t[Kt][Er]||{};ha(t.data,a,n),Le(r)||Wa(a,r);var i=t[Kt],s=wr.CreateFromInterface(e,i,a,n),m=new jn(wr.dataType,s);return Ya(e,wr.envelopeType,t,m)}function Fc(e,t,r){$a(e,t);var n=t[Kt],a=n[Er]||{},i=n.measurements||{};ha(t.data,a,i),Le(r)||Wa(a,r);var s=new nn(e,n.name,n.average,n.sampleCount,n.min,n.max,n.stdDev,a,i),m=new jn(nn.dataType,s);return Ya(e,nn.envelopeType,t,m)}function Lc(e,t,r){$a(e,t);var n="duration",a,i=t[Kt];!Le(i)&&!Le(i[Er])&&!Le(i[Er][n])?(a=i[Er][n],delete i[Er][n]):!Le(t.data)&&!Le(t.data[n])&&(a=t.data[n],delete t.data[n]);var s=t[Kt],m;((t.ext||{}).trace||{}).traceID&&(m=t.ext.trace.traceID);var _=s.id||m,h=s.name,k=s.uri,re=s[Er]||{},oe=s.measurements||{};if(Le(s.refUri)||(re.refUri=s.refUri),Le(s.pageType)||(re.pageType=s.pageType),Le(s.isLoggedIn)||(re.isLoggedIn=s.isLoggedIn.toString()),!Le(s[Er])){var te=s[Er];It(te,function(P,se){re[P]=se})}ha(t.data,re,oe),Le(r)||Wa(re,r);var D=new Lr(e,h,k,a,re,oe,_),Se=new jn(Lr.dataType,D);return Ya(e,Lr.envelopeType,t,Se)}function Dc(e,t,r){$a(e,t);var n=t[Kt],a=n.name,i=n.uri||n.url,s=n[Er]||{},m=n.measurements||{};ha(t.data,s,m),Le(r)||Wa(s,r);var _=new Nn(e,a,i,void 0,s,m,n),h=new jn(Nn.dataType,_);return Ya(e,Nn.envelopeType,t,h)}function Oc(e,t,r){$a(e,t);var n=t[Kt].message,a=t[Kt].severityLevel,i=t[Kt][Er]||{},s=t[Kt].measurements||{};ha(t.data,i,s),Le(r)||Wa(i,r);var m=new Bn(e,n,a,i,s),_=new jn(Bn.dataType,m);return Ya(e,Bn.envelopeType,t,_)}var kc=function(){function e(t){bt(e,this,function(r){r.serialize=function(s){var m=n(s,"root");try{return pr().stringify(m)}catch(_){t.throwInternal(Pe.CRITICAL,Ie.CannotSerializeObject,_&&lt(_.toString)?_.toString():"Error serializing object",null,!0)}};function n(s,m){var _="__aiCircularRefCheck",h={};if(!s)return t.throwInternal(Pe.CRITICAL,Ie.CannotSerializeObject,"cannot serialize object because it is null or undefined",{name:m},!0),h;if(s[_])return t.throwInternal(Pe.WARNING,Ie.CircularReferenceDetected,"Circular reference detected while serializing object",{name:m},!0),h;if(!s.aiDataContract){if(m==="measurements")h=i(s,"number",m);else if(m==="properties")h=i(s,"string",m);else if(m==="tags")h=i(s,"string",m);else if(_r(s))h=a(s,m);else{t.throwInternal(Pe.WARNING,Ie.CannotSerializeObjectNonSerializable,"Attempting to serialize an object which does not implement ISerializable",{name:m},!0);try{pr().stringify(s),h=s}catch(k){t.throwInternal(Pe.CRITICAL,Ie.CannotSerializeObject,k&&lt(k.toString)?k.toString():"Error serializing object",null,!0)}}return h}return s[_]=!0,It(s.aiDataContract,function(k,re){var oe=lt(re)?re()&1:re&1,te=lt(re)?re()&4:re&4,D=re&2,Se=s[k]!==void 0,P=wn(s[k])&&s[k]!==null;if(oe&&!Se&&!D)t.throwInternal(Pe.CRITICAL,Ie.MissingRequiredFieldSpecification,"Missing required field specification. The field is required but not present on source",{field:k,name:m});else if(!te){var se=void 0;P?D?se=a(s[k],k):se=n(s[k],k):se=s[k],se!==void 0&&(h[k]=se)}}),delete s[_],h}function a(s,m){var _;if(s)if(!_r(s))t.throwInternal(Pe.CRITICAL,Ie.ItemNotInArray,`This field was specified as an array in the contract but the item is not an array.\r
20
+ `,{name:m},!0);else{_=[];for(var h=0;h<s.length;h++){var k=s[h],re=n(k,m+"["+h+"]");_.push(re)}}return _}function i(s,m,_){var h;return s&&(h={},It(s,function(k,re){if(m==="string")re===void 0?h[k]="undefined":re===null?h[k]="null":re.toString?h[k]=re.toString():h[k]="invalid field: toString() is not defined.";else if(m==="number")if(re===void 0)h[k]="undefined";else if(re===null)h[k]="null";else{var oe=parseFloat(re);isNaN(oe)?h[k]="NaN":h[k]=oe}else h[k]="invalid field: "+_+" is of unknown type.",t.throwInternal(Pe.CRITICAL,h[k],null,!0)})),h}})}return e}();var Iv=function(){function e(){var t=Vn(),r=lr(),n=!1,a=!0;bt(e,this,function(i){try{if(t&&Rn(t,"online",_)&&(Rn(t,"offline",h),n=!0),r){var s=r.body||r;Jt(s.ononline)||(s.ononline=_,s.onoffline=h,n=!0)}if(n){var m=Cr();m&&!Le(m.onLine)&&(a=m.onLine)}}catch{n=!1}i.isListening=n,i.isOnline=function(){var k=!0,re=Cr();return n?k=a:re&&!Le(re.onLine)&&(k=re.onLine),k},i.isOffline=function(){return!i.isOnline()};function _(){a=!0}function h(){a=!1}})}return e.Offline=new e,e}();var Ol=Iv.Offline;var Cv=8,Hc=function(){function e(){}return e.prototype.getHashCodeScore=function(t){var r=this.getHashCode(t)/e.INT_MAX_VALUE;return r*100},e.prototype.getHashCode=function(t){if(t==="")return 0;for(;t.length<Cv;)t=t.concat(t);for(var r=5381,n=0;n<t.length;++n)r=(r<<5)+r+t.charCodeAt(n),r=r&r;return Math.abs(r)},e.INT_MAX_VALUE=2147483647,e}();var Uc=function(){function e(){var t=this,r=new Hc,n=new Ri;t.getSamplingScore=function(a){var i=0;return a.tags&&a.tags[n.userId]?i=r.getHashCodeScore(a.tags[n.userId]):a.ext&&a.ext.user&&a.ext.user.id?i=r.getHashCodeScore(a.ext.user.id):a.tags&&a.tags[n.operationId]?i=r.getHashCodeScore(a.tags[n.operationId]):a.ext&&a.ext.telemetryTrace&&a.ext.telemetryTrace.traceID?i=r.getHashCodeScore(a.ext.telemetryTrace.traceID):i=Math.random()*100,i}}return e}();var Vc=function(){function e(t,r){this.INT_MAX_VALUE=2147483647;var n=r||Zn(null);(t>100||t<0)&&(n.throwInternal(Pe.WARNING,Ie.SampleRateOutOfRange,"Sampling rate is out of range (0..100). Sampling will be disabled, you may be sending too much data which may affect your AI service level.",{samplingRate:t},!0),t=100),this.sampleRate=t,this.samplingScoreGenerator=new Uc}return e.prototype.isSampledIn=function(t){var r=this.sampleRate,n=!1;return r==null||r>=100||t.baseType===nn.dataType?!0:(n=this.samplingScoreGenerator.getSamplingScore(t)<r,n)},e}();var ta,Mv=65e3;function M0(e){try{return e.responseText}catch{}return null}function qc(){return{endpointUrl:function(){return"https://dc.services.visualstudio.com/v2/track"},emitLineDelimitedJson:function(){return!1},maxBatchInterval:function(){return 15e3},maxBatchSizeInBytes:function(){return 102400},disableTelemetry:function(){return!1},enableSessionStorageBuffer:function(){return!0},isRetryDisabled:function(){return!1},isBeaconApiDisabled:function(){return!0},disableXhr:function(){return!1},onunloadDisableFetch:function(){return!1},onunloadDisableBeacon:function(){return!1},instrumentationKey:function(){},namePrefix:function(){},samplingPercentage:function(){return 100},customHeaders:function(){},convertUndefined:function(){},eventsLimitInMem:function(){return 1e4}}}var Bv=(ta={},ta[rn.dataType]=Dl,ta[Bn.dataType]=Oc,ta[Lr.dataType]=Lc,ta[Nn.dataType]=Dc,ta[wr.dataType]=Pc,ta[nn.dataType]=Fc,ta[an.dataType]=Nc,ta),kl=function(e){dt(t,e);function t(){var r=e.call(this)||this;r.priority=1001,r.identifier=_o;var n,a,i,s=!1,m,_,h,k={},re=0,oe,te;return r._senderConfig=qc(),bt(t,r,function(D,Se){function P(){Ir("Method not implemented.")}D.pause=function(){fr(),s=!0},D.resume=function(){s&&(s=!1,a=null,D._buffer.size()>D._senderConfig.maxBatchSizeInBytes()&&D.triggerSend(!0,null,10),ar())},D.flush=function(){if(!s){fr();try{D.triggerSend(!0,null,1)}catch(K){D.diagLog().throwInternal(Pe.CRITICAL,Ie.FlushFailed,"flush failed, telemetry will not be collected: "+xt(K),{exception:ot(K)})}}},D.onunloadFlush=function(){if(!s)if((D._senderConfig.onunloadDisableBeacon()===!1||D._senderConfig.isBeaconApiDisabled()===!1)&&Oa())try{D.triggerSend(!0,et,2)}catch(K){D.diagLog().throwInternal(Pe.CRITICAL,Ie.FailedToSendQueuedTelemetry,"failed to flush with beacon sender on page unload, telemetry will not be collected: "+xt(K),{exception:ot(K)})}else D.flush()},D.teardown=P,D.addHeader=function(K,we){k[K]=we},D.initialize=function(K,we,He,Q){Se.initialize(K,we,He,Q);var fe=D._getTelCtx(),Ee=D.identifier;_=new kc(we.logger),n=0,a=null,i=0,D._sender=null,h=0;var ge=D.diagLog(),Te=qc();It(Te,function($e,Qe){D._senderConfig[$e]=function(){return fe.getConfig(Ee,$e,Qe())}}),D._buffer=D._senderConfig.enableSessionStorageBuffer()&&Ga()?new Mc(ge,D._senderConfig):new Cc(ge,D._senderConfig),D._sample=new Vc(D._senderConfig.samplingPercentage(),ge),g(K)||ge.throwInternal(Pe.CRITICAL,Ie.InvalidInstrumentationKey,"Invalid Instrumentation key "+K.instrumentationKey),!Xa(D._senderConfig.endpointUrl())&&D._senderConfig.customHeaders()&&D._senderConfig.customHeaders().length>0&&nt(D._senderConfig.customHeaders(),function($e){r.addHeader($e.header,$e.value)});var Ue=D._senderConfig,Ae=null;!Ue.disableXhr()&&u0()?Ae=Lt:!Ue.disableXhr()&&ka()&&(Ae=st),!Ae&&l0()&&(Ae=Vt),oe=Ae||st,!Ue.isBeaconApiDisabled()&&Oa()&&(Ae=ht),D._sender=Ae||st,!Ue.onunloadDisableFetch()&&l0(!0)?te=yt:Oa()?te=ht:!Ue.disableXhr()&&u0()?te=Lt:!Ue.disableXhr()&&ka()?te=st:te=oe},D.processTelemetry=function(K,we){we=D._getTelCtx(we);try{if(D._senderConfig.disableTelemetry())return;if(!K){we.diagLog().throwInternal(Pe.CRITICAL,Ie.CannotSendEmptyTelemetry,"Cannot send empty telemetry");return}if(K.baseData&&!K.baseType){we.diagLog().throwInternal(Pe.CRITICAL,Ie.InvalidEvent,"Cannot send telemetry without baseData and baseType");return}if(K.baseType||(K.baseType="EventData"),!D._sender){we.diagLog().throwInternal(Pe.CRITICAL,Ie.SenderNotInitialized,"Sender was not initialized");return}if(se(K))K[pi]=D._sample.sampleRate;else{we.diagLog().throwInternal(Pe.WARNING,Ie.TelemetrySampledAndNotSent,"Telemetry item was sampled out and not sent",{SampleRate:D._sample.sampleRate});return}var He=D._senderConfig.convertUndefined()||void 0,Q=K.iKey||D._senderConfig.instrumentationKey(),fe=t.constructEnvelope(K,Q,we.diagLog(),He);if(!fe){we.diagLog().throwInternal(Pe.CRITICAL,Ie.CreateEnvelopeError,"Unable to create an AppInsights envelope");return}var Ee=!1;if(K.tags&&K.tags[Si]&&(nt(K.tags[Si],function(Ae){try{Ae&&Ae(fe)===!1&&(Ee=!0,we.diagLog().warnToConsole("Telemetry processor check returns false"))}catch($e){we.diagLog().throwInternal(Pe.CRITICAL,Ie.TelemetryInitializerFailed,"One of telemetry initializers failed, telemetry item will not be sent: "+xt($e),{exception:ot($e)},!0)}}),delete K.tags[Si]),Ee)return;var ge=_.serialize(fe),Te=D._buffer,Ue=Te.size();Ue+ge.length>D._senderConfig.maxBatchSizeInBytes()&&D.triggerSend(!0,null,10),Te.enqueue(ge),ar()}catch(Ae){we.diagLog().throwInternal(Pe.WARNING,Ie.FailedAddingTelemetryToBuffer,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+xt(Ae),{exception:ot(Ae)})}D.processNext(K,we)},D._xhrReadyStateChange=function(K,we,He){K.readyState===4&&ue(K.status,we,K.responseURL,He,pt(K),M0(K)||K.response)},D.triggerSend=function(K,we,He){if(K===void 0&&(K=!0),!s)try{var Q=D._buffer;if(D._senderConfig.disableTelemetry())Q.clear();else{if(Q.count()>0){var fe=Q.getItems();Ze(He||0,K),we?we.call(r,fe,K):D._sender(fe,K)}i=+new Date}fr()}catch(ge){var Ee=di();(!Ee||Ee>9)&&D.diagLog().throwInternal(Pe.CRITICAL,Ie.TransmissionFailed,"Telemetry transmission failed, some telemetry will be lost: "+xt(ge),{exception:ot(ge)})}},D._onError=function(K,we,He){D.diagLog().throwInternal(Pe.WARNING,Ie.OnError,"Failed to send telemetry.",{message:we}),D._buffer.clearSent(K)},D._onPartialSuccess=function(K,we){for(var He=[],Q=[],fe=we.errors.reverse(),Ee=0,ge=fe;Ee<ge.length;Ee++){var Te=ge[Ee],Ue=K.splice(Te.index,1)[0];Wt(Te.statusCode)?Q.push(Ue):He.push(Ue)}K.length>0&&D._onSuccess(K,we.itemsAccepted),He.length>0&&D._onError(He,pt(null,["partial success",we.itemsAccepted,"of",we.itemsReceived].join(" "))),Q.length>0&&(kr(Q),D.diagLog().throwInternal(Pe.WARNING,Ie.TransmissionFailed,"Partial success. Delivered: "+K.length+", Failed: "+He.length+". Will retry to send "+Q.length+" our of "+we.itemsReceived+" items"))},D._onSuccess=function(K,we){D._buffer.clearSent(K)},D._xdrOnLoad=function(K,we){var He=M0(K);if(K&&(He+""=="200"||He===""))n=0,D._onSuccess(we,0);else{var Q=Zt(He);Q&&Q.itemsReceived&&Q.itemsReceived>Q.itemsAccepted&&!D._senderConfig.isRetryDisabled()?D._onPartialSuccess(we,Q):D._onError(we,Bt(K))}};function se(K){return D._sample.isSampledIn(K)}function ue(K,we,He,Q,fe,Ee){var ge=null;if(D._appId||(ge=Zt(Ee),ge&&ge.appId&&(D._appId=ge.appId)),(K<200||K>=300)&&K!==0){if((K===301||K===307||K===308)&&!De(He)){D._onError(we,fe);return}!D._senderConfig.isRetryDisabled()&&Wt(K)?(kr(we),D.diagLog().throwInternal(Pe.WARNING,Ie.TransmissionFailed,". Response code "+K+". Will retry to send "+we.length+" items.")):D._onError(we,fe)}else if(Ol.isOffline()){if(!D._senderConfig.isRetryDisabled()){var Te=10;kr(we,Te),D.diagLog().throwInternal(Pe.WARNING,Ie.TransmissionFailed,". Offline - Response Code: ".concat(K,". Offline status: ").concat(Ol.isOffline(),". Will retry to send ").concat(we.length," items."))}}else De(He),K===206?(ge||(ge=Zt(Ee)),ge&&!D._senderConfig.isRetryDisabled()?D._onPartialSuccess(we,ge):D._onError(we,fe)):(n=0,D._onSuccess(we,Q))}function De(K){return h>=10?!1:!Le(K)&&K!==""&&K!==D._senderConfig.endpointUrl()?(D._senderConfig.endpointUrl=function(){return K},++h,!0):!1}function et(K,we){te?te(K,!1):ht(K,we)}function ut(K){var we=Cr(),He=D._buffer,Q=D._senderConfig.endpointUrl(),fe=D._buffer.batchPayloads(K),Ee=new Blob([fe],{type:"text/plain;charset=UTF-8"}),ge=we.sendBeacon(Q,Ee);return ge&&(He.markAsSent(K),D._onSuccess(K,K.length)),ge}function ht(K,we){if(_r(K)&&K.length>0&&!ut(K)){for(var He=[],Q=0;Q<K.length;Q++){var fe=K[Q];ut([fe])||He.push(fe)}He.length>0&&(oe(He,!0),D.diagLog().throwInternal(Pe.WARNING,Ie.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with normal sender."))}}function st(K,we){var He=new XMLHttpRequest,Q=D._senderConfig.endpointUrl();try{He[Mn]=!0}catch{}He.open("POST",Q,we),He.setRequestHeader("Content-type","application/json"),Xa(Q)&&He.setRequestHeader(Nt.sdkContextHeader,Nt.sdkContextHeaderAppIdRequest),nt(vn(k),function(Ee){He.setRequestHeader(Ee,k[Ee])}),He.onreadystatechange=function(){return D._xhrReadyStateChange(He,K,K.length)},He.onerror=function(Ee){return D._onError(K,pt(He),Ee)};var fe=D._buffer.batchPayloads(K);He.send(fe),D._buffer.markAsSent(K)}function yt(K,we){if(_r(K)){for(var He=K.length,Q=0;Q<K.length;Q++)He+=K[Q].length;re+He<=Mv?zt(K,!1):Oa()?ht(K,we):(oe&&oe(K,!0),D.diagLog().throwInternal(Pe.WARNING,Ie.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with xhrSender."))}}function Vt(K,we){zt(K,!0)}function zt(K,we){var He,Q=D._senderConfig.endpointUrl(),fe=D._buffer.batchPayloads(K),Ee=new Blob([fe],{type:"application/json"}),ge=new Headers,Te=fe.length,Ue=!1,Ae=!1;Xa(Q)&&ge.append(Nt.sdkContextHeader,Nt.sdkContextHeaderAppIdRequest),nt(vn(k),function(de){ge.append(de,k[de])});var $e=(He={method:"POST",headers:ge,body:Ee},He[Mn]=!0,He);we||($e.keepalive=!0,Ue=!0,re+=Te);var Qe=new Request(Q,$e);try{Qe[Mn]=!0}catch{}D._buffer.markAsSent(K);try{fetch(Qe).then(function(de){we||(re-=Te,Te=0),Ae||(Ae=!0,de.ok?de.text().then(function(ir){ue(de.status,K,de.url,K.length,de.statusText,ir)}):D._onError(K,de.statusText))}).catch(function(de){we||(re-=Te,Te=0),Ae||(Ae=!0,D._onError(K,de.message))})}catch(de){Ae||D._onError(K,ot(de))}Ue&&!Ae&&(Ae=!0,D._onSuccess(K,K.length))}function Zt(K){try{if(K&&K!==""){var we=pr().parse(K);if(we&&we.itemsReceived&&we.itemsReceived>=we.itemsAccepted&&we.itemsReceived-we.itemsAccepted===we.errors.length)return we}}catch(He){D.diagLog().throwInternal(Pe.CRITICAL,Ie.InvalidBackendResponse,"Cannot parse the response. "+xt(He),{response:K})}return null}function kr(K,we){if(we===void 0&&(we=1),!(!K||K.length===0)){var He=D._buffer;He.clearSent(K),n++;for(var Q=0,fe=K;Q<fe.length;Q++){var Ee=fe[Q];He.enqueue(Ee)}Tr(we),ar()}}function Tr(K){var we=10,He;if(n<=1)He=we;else{var Q=(Math.pow(2,n)-1)/2,fe=Math.floor(Math.random()*Q*we)+1;fe=K*fe,He=Math.max(Math.min(fe,3600),we)}var Ee=mr()+He*1e3;a=Ee}function ar(){if(!m&&!s){var K=a?Math.max(0,a-mr()):0,we=Math.max(D._senderConfig.maxBatchInterval(),K);m=setTimeout(function(){m=null,D.triggerSend(!0,null,1)},we)}}function fr(){clearTimeout(m),m=null,a=null}function Wt(K){return K===408||K===429||K===500||K===503}function pt(K,we){return K?"XMLHttpRequest,Status:"+K.status+",Response:"+M0(K)||K.response||"":we}function Lt(K,we){var He=D._buffer,Q=Vn(),fe=new XDomainRequest;fe.onload=function(){return D._xdrOnLoad(fe,K)},fe.onerror=function(Ue){return D._onError(K,Bt(fe),Ue)};var Ee=Q&&Q.location&&Q.location.protocol||"";if(D._senderConfig.endpointUrl().lastIndexOf(Ee,0)!==0){D.diagLog().throwInternal(Pe.WARNING,Ie.TransmissionFailed,". Cannot send XDomain request. The endpoint URL protocol doesn't match the hosting page protocol."),He.clear();return}var ge=D._senderConfig.endpointUrl().replace(/^(https?:)/,"");fe.open("POST",ge);var Te=He.batchPayloads(K);fe.send(Te),He.markAsSent(K)}function Bt(K,we){return K?"XDomainRequest,Response:"+M0(K)||"":we}function Ct(){var K="getNotifyMgr";return D.core[K]?D.core[K]():D.core._notificationManager}function Ze(K,we){var He=Ct();if(He&&He.eventsSendRequest)try{He.eventsSendRequest(K,we)}catch(Q){D.diagLog().throwInternal(Pe.CRITICAL,Ie.NotificationException,"send request notification failed: "+xt(Q),{exception:ot(Q)})}}function g(K){var we=Le(K.disableInstrumentationKeyValidation)?!1:K.disableInstrumentationKeyValidation;if(we)return!0;var He="^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$",Q=new RegExp(He);return Q.test(K.instrumentationKey)}}),r}return t.constructEnvelope=function(r,n,a,i){var s;n!==r.iKey&&!Le(n)?s=tr(tr({},r),{iKey:n}):s=r;var m=Bv[s.baseType]||Dl;return m(a,s,i)},t}(In);var Nv="ai_session",Hl=function(){function e(){}return e}();var jc=function(){function e(t,r){var n=this,a,i,s=Zn(r),m=Ua(r);bt(e,n,function(_){t||(t={}),lt(t.sessionExpirationMs)||(t.sessionExpirationMs=function(){return e.acquisitionSpan}),lt(t.sessionRenewalMs)||(t.sessionRenewalMs=function(){return e.renewalSpan}),_.config=t;var h=_.config.sessionCookiePostfix&&_.config.sessionCookiePostfix()?_.config.sessionCookiePostfix():_.config.namePrefix&&_.config.namePrefix()?_.config.namePrefix():"";a=function(){return Nv+h},_.automaticSession=new Hl,_.update=function(){var Se=mr(),P=!1,se=_.automaticSession;se.id||(P=!k(se,Se));var ue=_.config.sessionExpirationMs();if(!P&&ue>0){var De=_.config.sessionRenewalMs(),et=Se-se.acquisitionDate,ut=Se-se.renewalDate;P=et<0||ut<0,P=P||et>ue,P=P||ut>De}P?oe(Se):(!i||Se-i>e.cookieUpdateInterval)&&te(se,Se)},_.backup=function(){var Se=_.automaticSession;D(Se.id,Se.acquisitionDate,Se.renewalDate)};function k(Se,P){var se=!1,ue=m.get(a());if(ue&&lt(ue.split))se=re(Se,ue);else{var De=Sl(s,a());De&&(se=re(Se,De))}return se||!!Se.id}function re(Se,P){var se=!1,ue=", session will be reset",De=P.split("|");if(De.length>=2)try{var et=+De[1]||0,ut=+De[2]||0;isNaN(et)||et<=0?s.throwInternal(Pe.WARNING,Ie.SessionRenewalDateIsZero,"AI session acquisition date is 0"+ue):isNaN(ut)||ut<=0?s.throwInternal(Pe.WARNING,Ie.SessionRenewalDateIsZero,"AI session renewal date is 0"+ue):De[0]&&(Se.id=De[0],Se.acquisitionDate=et,Se.renewalDate=ut,se=!0)}catch(ht){s.throwInternal(Pe.CRITICAL,Ie.ErrorParsingAISessionCookie,"Error parsing ai_session value ["+(P||"")+"]"+ue+" - "+xt(ht),{exception:ot(ht)})}return se}function oe(Se){var P=_.config||{},se=(P.getNewId?P.getNewId():null)||hi;_.automaticSession.id=se(P.idLength?P.idLength():22),_.automaticSession.acquisitionDate=Se,te(_.automaticSession,Se),y0()||s.throwInternal(Pe.WARNING,Ie.BrowserDoesNotSupportLocalStorage,"Browser does not support local storage. Session durations will be inaccurate.")}function te(Se,P){var se=Se.acquisitionDate;Se.renewalDate=P;var ue=_.config,De=ue.sessionRenewalMs(),et=se+ue.sessionExpirationMs()-P,ut=[Se.id,se,P],ht=0;et<De?ht=et/1e3:ht=De/1e3;var st=ue.cookieDomain?ue.cookieDomain():null;m.set(a(),ut.join("|"),ue.sessionExpirationMs()>0?ht:null,st),i=P}function D(Se,P,se){xl(s,a(),[Se,P,se].join("|"))}})}return e.acquisitionSpan=864e5,e.renewalSpan=18e5,e.cookieUpdateInterval=6e4,e}();var zc=function(){function e(){}return e}();var Gc=function(){function e(){this.id="browser",this.deviceClass="Browser"}return e}();var Pv="2.7.4",Xc=function(){function e(t){this.sdkVersion=(t.sdkExtension&&t.sdkExtension()?t.sdkExtension()+"_":"")+"javascript:"+Pv}return e}();function Kc(e){return!(typeof e!="string"||!e||e.match(/,|;|=| |\|/))}var Wc=function(){function e(t,r){this.isNewUser=!1,this.isUserCookieSet=!1;var n=Zn(r),a=Ua(r),i;bt(e,this,function(s){s.config=t;var m=s.config.userCookiePostfix&&s.config.userCookiePostfix()?s.config.userCookiePostfix():"";i=function(){return e.userCookieName+m};var _=a.get(i());if(_){s.isNewUser=!1;var h=_.split(e.cookieSeparator);h.length>0&&(s.id=h[0],s.isUserCookieSet=!!s.id)}function k(){var se=t||{},ue=(se.getNewId?se.getNewId():null)||hi,De=ue(se.idLength?t.idLength():22);return De}function re(se){var ue=Nr(new Date);s.accountAcquisitionDate=ue,s.isNewUser=!0;var De=[se,ue];return De}function oe(se){var ue=31536e3;s.isUserCookieSet=a.set(i(),se,ue)}if(!s.id){s.id=k();var te=re(s.id);oe(te.join(e.cookieSeparator));var D=t.namePrefix&&t.namePrefix()?t.namePrefix()+"ai_session":"ai_session";bl(n,D)}s.accountId=t.accountId?t.accountId():void 0;var Se=a.get(e.authUserCookieName);if(Se){Se=decodeURI(Se);var P=Se.split(e.cookieSeparator);P[0]&&(s.authenticatedId=P[0]),P.length>1&&P[1]&&(s.accountId=P[1])}s.setAuthenticatedUserContext=function(se,ue,De){De===void 0&&(De=!1);var et=!Kc(se)||ue&&!Kc(ue);if(et){n.throwInternal(Pe.WARNING,Ie.SetAuthContextFailedAccountName,"Setting auth user context failed. User auth/account id should be of type string, and not contain commas, semi-colons, equal signs, spaces, or vertical-bars.",!0);return}s.authenticatedId=se;var ut=s.authenticatedId;ue&&(s.accountId=ue,ut=[s.authenticatedId,s.accountId].join(e.cookieSeparator)),De&&a.set(e.authUserCookieName,encodeURI(ut))},s.clearAuthenticatedUserContext=function(){s.authenticatedId=null,s.accountId=null,a.del(e.authUserCookieName)},s.update=function(se){if(s.id!==se||!s.isUserCookieSet){var ue=se||k(),De=re(ue);oe(De.join(e.cookieSeparator))}}})}return e.cookieSeparator="|",e.userCookieName="ai_user",e.authUserCookieName="ai_authUser",e}();var Yc=function(){function e(){}return e}();var $c=function(){function e(t,r,n,a){var i=this;i.traceID=t||Gr(),i.parentID=r,i.name=n;var s=Jr();!n&&s&&s.pathname&&(i.name=s.pathname),i.name=Pt(a,i.name)}return e}();var B0="ext",N0="tags";function Ai(e,t){e&&e[t]&&vn(e[t]).length===0&&delete e[t]}var Zc=function(){function e(t,r){var n=this,a=t.logger;this.appId=function(){return null},this.getSessionId=function(){return null},bt(e,this,function(i){i.application=new zc,i.internal=new Xc(r),La()&&(i.sessionManager=new jc(r,t),i.device=new Gc,i.location=new Yc,i.user=new Wc(r,t),i.telemetryTrace=new $c(void 0,void 0,void 0,a),i.session=new Hl),i.getSessionId=function(){var s=i.session,m=null;if(s&&rt(s.id))m=s.id;else{var _=(i.sessionManager||{}).automaticSession;m=_&&rt(_.id)?_.id:null}return m},i.applySessionContext=function(s,m){St(hr(s.ext,Dr.AppExt),"sesId",i.getSessionId(),rt)},i.applyOperatingSystemContxt=function(s,m){St(s.ext,Dr.OSExt,i.os)},i.applyApplicationContext=function(s,m){var _=i.application;if(_){var h=hr(s,N0);St(h,Ft.applicationVersion,_.ver,rt),St(h,Ft.applicationBuild,_.build,rt)}},i.applyDeviceContext=function(s,m){var _=i.device;if(_){var h=hr(hr(s,B0),Dr.DeviceExt);St(h,"localId",_.id,rt),St(h,"ip",_.ip,rt),St(h,"model",_.model,rt),St(h,"deviceClass",_.deviceClass,rt)}},i.applyInternalContext=function(s,m){var _=i.internal;if(_){var h=hr(s,N0);St(h,Ft.internalAgentVersion,_.agentVersion,rt),St(h,Ft.internalSdkVersion,_.sdkVersion,rt),(s.baseType===$n.dataType||s.baseType===Lr.dataType)&&(St(h,Ft.internalSnippet,_.snippetVer,rt),St(h,Ft.internalSdkSrc,_.sdkSrc,rt))}},i.applyLocationContext=function(s,m){var _=n.location;_&&St(hr(s,N0,[]),Ft.locationIp,_.ip,rt)},i.applyOperationContext=function(s,m){var _=i.telemetryTrace;if(_){var h=hr(hr(s,B0),Dr.TraceExt,{traceID:void 0,parentID:void 0});St(h,"traceID",_.traceID,rt),St(h,"name",_.name,rt),St(h,"parentID",_.parentID,rt)}},i.applyWebContext=function(s,m){var _=n.web;_&&St(hr(s,B0),Dr.WebExt,_)},i.applyUserContext=function(s,m){var _=i.user;if(_){var h=hr(s,N0,[]);St(h,Ft.userAccountId,_.accountId,rt);var k=hr(hr(s,B0),Dr.UserExt);St(k,"id",_.id,rt),St(k,"authId",_.authenticatedId,rt)}},i.cleanUp=function(s,m){var _=s.ext;_&&(Ai(_,Dr.DeviceExt),Ai(_,Dr.UserExt),Ai(_,Dr.WebExt),Ai(_,Dr.OSExt),Ai(_,Dr.AppExt),Ai(_,Dr.TraceExt))}})}return e}();var Fv=function(e){dt(t,e);function t(){var r=e.call(this)||this;r.priority=110,r.identifier=ma;var n,a;return bt(t,r,function(i,s){i.initialize=function(_,h,k,re){s.initialize(_,h,k,re);var oe=i._getTelCtx(),te=i.identifier,D=t.getDefaultConfig();a=a||{},It(D,function(Se,P){a[Se]=function(){return oe.getConfig(te,Se,P())}}),i.context=new Zc(h,a),n=vl(k,_o),i.context.appId=function(){return n?n._appId:null},i._extConfig=a},i.processTelemetry=function(_,h){if(!Le(_)){h=i._getTelCtx(h),_.name===Lr.envelopeType&&h.diagLog().resetInternalMessageCount();var k=i.context||{};k.session&&typeof i.context.session.id!="string"&&k.sessionManager&&k.sessionManager.update();var re=k.user;if(re&&!re.isUserCookieSet&&re.update(k.user.id),m(_,h),re&&re.isNewUser){re.isNewUser=!1;var oe=new $n(Ie.SendBrowserInfoOnUserInit,(Cr()||{}).userAgent||"");h.diagLog().logInternalMessage(Pe.CRITICAL,oe)}i.processNext(_,h)}};function m(_,h){hr(_,"tags",[]),hr(_,"ext",{});var k=i.context;k.applySessionContext(_,h),k.applyApplicationContext(_,h),k.applyDeviceContext(_,h),k.applyOperationContext(_,h),k.applyUserContext(_,h),k.applyOperatingSystemContxt(_,h),k.applyWebContext(_,h),k.applyLocationContext(_,h),k.applyInternalContext(_,h),k.cleanUp(_,h)}}),r}return t.getDefaultConfig=function(){var r={instrumentationKey:function(){},accountId:function(){return null},sessionRenewalMs:function(){return 18e5},samplingPercentage:function(){return 100},sessionExpirationMs:function(){return 864e5},cookieDomain:function(){return null},sdkExtension:function(){return null},isBrowserLinkTrackingEnabled:function(){return!1},appId:function(){return null},getSessionId:function(){return null},namePrefix:function(){},sessionCookiePostfix:function(){},userCookiePostfix:function(){},idLength:function(){return 22},getNewId:function(){return null}};return r},t}(In),Ul=Fv;var on="properties";function Qc(e,t,r){var n=0,a=e[t],i=e[r];return a&&i&&(n=Sr(a,i)),n}function Za(e,t,r,n,a){var i=0,s=Qc(r,n,a);return s&&(i=pa(e,t,tn(s))),i}function pa(e,t,r){var n="ajaxPerf",a=0;if(e&&t&&r){var i=e[n]=e[n]||{};i[t]=r,a=1}return a}function Lv(e,t){var r=e.perfTiming,n=t[on]||{},a=0,i="name",s="Start",m="End",_="domainLookup",h="connect",k="redirect",re="request",oe="response",te="duration",D="startTime",Se=_+s,P=_+m,se=h+s,ue=h+m,De=re+s,et=re+m,ut=oe+s,ht=oe+m,st=k+s,yt=k=m,Vt="transferSize",zt="encodedBodySize",Zt="decodedBodySize",kr="serverTiming";if(r){a|=Za(n,k,r,st,yt),a|=Za(n,_,r,Se,P),a|=Za(n,h,r,se,ue),a|=Za(n,re,r,De,et),a|=Za(n,oe,r,ut,ht),a|=Za(n,"networkConnect",r,D,ue),a|=Za(n,"sentRequest",r,De,ht);var Tr=r[te];Tr||(Tr=Qc(r,D,ht)||0),a|=pa(n,te,Tr),a|=pa(n,"perfTotal",Tr);var ar=r[kr];if(ar){var fr={};nt(ar,function(Wt,pt){var Lt=As(Wt[i]||""+pt),Bt=fr[Lt]||{};It(Wt,function(Ct,Ze){(Ct!==i&&rt(Ze)||ui(Ze))&&(Bt[Ct]&&(Ze=Bt[Ct]+";"+Ze),(Ze||!rt(Ze))&&(Bt[Ct]=Ze))}),fr[Lt]=Bt}),a|=pa(n,kr,fr)}a|=pa(n,Vt,r[Vt]),a|=pa(n,zt,r[zt]),a|=pa(n,Zt,r[Zt])}else e.perfMark&&(a|=pa(n,"missing",e.perfAttempts));a&&(t[on]=n)}var Dv=function(){function e(){var t=this;t.openDone=!1,t.setRequestHeaderDone=!1,t.sendDone=!1,t.abortDone=!1,t.stateChangeAttached=!1}return e}();var Vl=function(){function e(t,r,n){var a=this,i=n,s="responseText";a.perfMark=null,a.completed=!1,a.requestHeadersSize=null,a.requestHeaders=null,a.responseReceivingDuration=null,a.callbackDuration=null,a.ajaxTotalDuration=null,a.aborted=0,a.pageUrl=null,a.requestUrl=null,a.requestSize=0,a.method=null,a.status=null,a.requestSentTime=null,a.responseStartedTime=null,a.responseFinishedTime=null,a.callbackFinishedTime=null,a.endTime=null,a.xhrMonitoringState=new Dv,a.clientFailure=0,a.traceID=t,a.spanID=r,bt(e,a,function(m){m.getAbsoluteUrl=function(){return m.requestUrl?g0(m.requestUrl):null},m.getPathName=function(){return m.requestUrl?Jn(i,E0(m.method,m.requestUrl)):null},m.CreateTrackItem=function(_,h,k){var re;if(m.ajaxTotalDuration=Math.round(Sr(m.requestSentTime,m.responseFinishedTime)*1e3)/1e3,m.ajaxTotalDuration<0)return null;var oe=(re={id:"|"+m.traceID+"."+m.spanID,target:m.getAbsoluteUrl(),name:m.getPathName(),type:_,startTime:null,duration:m.ajaxTotalDuration,success:+m.status>=200&&+m.status<400,responseCode:+m.status,method:m.method},re[on]={HttpMethod:m.method},re);if(m.requestSentTime&&(oe.startTime=new Date,oe.startTime.setTime(m.requestSentTime)),Lv(m,oe),h&&vn(m.requestHeaders).length>0&&(oe[on]=oe[on]||{},oe[on].requestHeaders=m.requestHeaders),k){var te=k();if(te){var D=te.correlationContext;if(D&&(oe.correlationContext=D),te.headerMap&&vn(te.headerMap).length>0&&(oe[on]=oe[on]||{},oe[on].responseHeaders=te.headerMap),m.errorStatusText&&m.status>=400){var Se=te.type;oe[on]=oe[on]||{},(Se===""||Se==="text")&&(oe[on][s]=te[s]?te.statusText+" - "+te[s]:te.statusText),Se==="json"&&(oe[on][s]=te.response?te.statusText+" - "+JSON.stringify(te.response):te.statusText)}}}return oe}})}return e}();var ql=function(){function e(t,r){var n=this;n.traceFlag=e.DEFAULT_TRACE_FLAG,n.version=e.DEFAULT_VERSION,t&&e.isValidTraceId(t)?n.traceId=t:n.traceId=Gr(),r&&e.isValidSpanId(r)?n.spanId=r:n.spanId=Gr().substr(0,16)}return e.isValidTraceId=function(t){return t.match(/^[0-9a-f]{32}$/)&&t!=="00000000000000000000000000000000"},e.isValidSpanId=function(t){return t.match(/^[0-9a-f]{16}$/)&&t!=="0000000000000000"},e.prototype.toString=function(){var t=this;return"".concat(t.version,"-").concat(t.traceId,"-").concat(t.spanId,"-").concat(t.traceFlag)},e.DEFAULT_TRACE_FLAG="01",e.DEFAULT_VERSION="00",e}();var Jc="ai.ajxmn.",po="diagLog",sn="ajaxData",tf="throwInternal",So="fetch",ef=0;function Ov(){var e=dn();return!e||Le(e.Request)||Le(e.Request[$t])||Le(e[So])?null:e[So]}function kv(e){var t=!1;if(ka()){var r=XMLHttpRequest[$t];t=!Le(r)&&!Le(r.open)&&!Le(r.send)&&!Le(r.abort)}var n=di();if(n&&n<9&&(t=!1),t)try{var a=new XMLHttpRequest;a[sn]={};var i=XMLHttpRequest[$t].open;XMLHttpRequest[$t].open=i}catch(s){t=!1,xo(e,Ie.FailedMonitorAjaxOpen,"Failed to enable XMLHttpRequest monitoring, extension is not supported",{exception:ot(s)})}return t}function P0(e){var t="";try{!Le(e)&&!Le(e[sn])&&!Le(e[sn].requestUrl)&&(t+="(url: '"+e[sn].requestUrl+"')")}catch{}return t}function xo(e,t,r,n,a){e[po]()[tf](Pe.CRITICAL,t,r,n,a)}function Ii(e,t,r,n,a){e[po]()[tf](Pe.WARNING,t,r,n,a)}function ho(e,t,r){return function(n){xo(e,t,r,{ajaxDiagnosticsMessage:P0(n.inst),exception:ot(n.err)})}}function Ci(e,t){return e&&t?e.indexOf(t):-1}var jl=function(e){dt(t,e);function t(){var r=e.call(this)||this;r.identifier=t.identifier,r.priority=120;var n="trackDependencyDataInternal",a=Jr(),i=!1,s=!1,m=a&&a.host&&a.host.toLowerCase(),_=t.getEmptyConfig(),h=!1,k=!1,re=0,oe,te,D,Se,P=!1,se=0,ue=!1,De=[],et={},ut,ht;return bt(t,r,function(st,yt){st.initialize=function(Q,fe,Ee,ge){if(!st.isInitialized()){yt.initialize(Q,fe,Ee,ge);var Te=st._getTelCtx(),Ue=t.getDefaultConfig();It(Ue,function(ir,br){_[ir]=Te.getConfig(t.identifier,ir,br)});var Ae=_.distributedTracingMode;if(h=_.enableRequestHeaderTracking,k=_.enableAjaxErrorStatusText,P=_.enableAjaxPerfTracking,se=_.maxAjaxCallsPerView,ue=_.enableResponseHeaderTracking,ut=_.excludeRequestFromAutoTrackingPatterns,ht=_.addRequestContext,D=Ae===mn.AI||Ae===mn.AI_AND_W3C,te=Ae===mn.AI_AND_W3C||Ae===mn.W3C,P){var $e=Q.instrumentationKey||"unkwn";$e.length>5?Se=Jc+$e.substring($e.length-5)+".":Se=Jc+$e+"."}if(_.disableAjaxTracking===!1&&kr(),zt(),Ee.length>0&&Ee){for(var Qe=void 0,de=0;!Qe&&de<Ee.length;)Ee[de]&&Ee[de].identifier===ma&&(Qe=Ee[de]),de++;Qe&&(oe=Qe.context)}}},st.teardown=function(){nt(De,function(Q){Q.rm()}),De=[],i=!1,s=!1,st.setInitialized(!1)},st.trackDependencyData=function(Q,fe){st[n](Q,fe)},st.includeCorrelationHeaders=function(Q,fe,Ee,ge){var Te=st._currentWindowHost||m;if(fe){if(ea.canIncludeCorrelationHeader(_,Q.getAbsoluteUrl(),Te)){if(Ee||(Ee={}),Ee.headers=new Headers(Ee.headers||(fe instanceof Request?fe.headers||{}:{})),D){var Ue="|"+Q.traceID+"."+Q.spanID;Ee.headers.set(Nt.requestIdHeader,Ue),h&&(Q.requestHeaders[Nt.requestIdHeader]=Ue)}var Ae=_.appId||oe&&oe.appId();if(Ae&&(Ee.headers.set(Nt.requestContextHeader,Nt.requestContextAppIdFormat+Ae),h&&(Q.requestHeaders[Nt.requestContextHeader]=Nt.requestContextAppIdFormat+Ae)),te){var $e=new ql(Q.traceID,Q.spanID);Ee.headers.set(Nt.traceParentHeader,$e.toString()),h&&(Q.requestHeaders[Nt.traceParentHeader]=$e.toString())}}return Ee}else if(ge){if(ea.canIncludeCorrelationHeader(_,Q.getAbsoluteUrl(),Te)){if(D){var Ue="|"+Q.traceID+"."+Q.spanID;ge.setRequestHeader(Nt.requestIdHeader,Ue),h&&(Q.requestHeaders[Nt.requestIdHeader]=Ue)}var Ae=_.appId||oe&&oe.appId();if(Ae&&(ge.setRequestHeader(Nt.requestContextHeader,Nt.requestContextAppIdFormat+Ae),h&&(Q.requestHeaders[Nt.requestContextHeader]=Nt.requestContextAppIdFormat+Ae)),te){var $e=new ql(Q.traceID,Q.spanID);ge.setRequestHeader(Nt.traceParentHeader,$e.toString()),h&&(Q.requestHeaders[Nt.traceParentHeader]=$e.toString())}}return ge}},st[n]=function(Q,fe,Ee){if(se===-1||re<se){(_.distributedTracingMode===mn.W3C||_.distributedTracingMode===mn.AI_AND_W3C)&&typeof Q.id=="string"&&Q.id[Q.id.length-1]!=="."&&(Q.id+="."),Le(Q.startTime)&&(Q.startTime=new Date);var ge=pn.create(Q,an.dataType,an.envelopeType,st[po](),fe,Ee);st.core.track(ge)}else re===se&&xo(st,Ie.MaxAjaxPerPVExceeded,"Maximum ajax per page view limit reached, ajax monitoring is paused until the next trackPageView(). In order to increase the limit set the maxAjaxCallsPerView configuration parameter.",!0);++re};function Vt(Q){var fe=!0;return(Q||_.ignoreHeaders)&&nt(_.ignoreHeaders,function(Ee){if(Ee.toLowerCase()===Q.toLowerCase())return fe=!1,-1}),fe}function zt(){var Q=Ov();if(!!Q){var fe=dn(),Ee=Q.polyfill;_.disableFetchTracking===!1?(De.push(oo(fe,So,{req:function(ge,Te,Ue){var Ae;if(i&&!Tr(null,Te,Ue)&&!(Ee&&s)){var $e=ge.ctx();Ae=g(Te,Ue);var Qe=st.includeCorrelationHeaders(Ae,Te,Ue);Qe!==Ue&&ge.set(1,Qe),$e.data=Ae}},rsp:function(ge,Te){var Ue=ge.ctx().data;Ue&&(ge.rslt=ge.rslt.then(function(Ae){return we(ge,(Ae||{}).status,Te,Ae,Ue,function(){var $e={statusText:Ae.statusText,headerMap:null,correlationContext:He(Ae)};if(ue){var Qe={};Ae.headers.forEach(function(de,ir){Vt(ir)&&(Qe[ir]=de)}),$e.headerMap=Qe}return $e}),Ae}).catch(function(Ae){throw we(ge,0,Te,null,Ue,null,{error:Ae.message}),Ae}))},hkErr:ho(st,Ie.FailedMonitorAjaxOpen,"Failed to monitor Window.fetch, monitoring data for this fetch call may be incorrect.")})),i=!0):Ee&&De.push(oo(fe,So,{req:function(ge,Te,Ue){Tr(null,Te,Ue)}})),Ee&&(fe[So].polyfill=Ee)}}function Zt(Q,fe,Ee){De.push(ll(Q,fe,Ee))}function kr(){kv(st)&&!s&&(Zt(XMLHttpRequest,"open",{req:function(Q,fe,Ee,ge){var Te=Q.inst,Ue=Te[sn];!Tr(Te,Ee)&&ar(Te,!0)&&((!Ue||!Ue.xhrMonitoringState.openDone)&&fr(Te,fe,Ee,ge),Wt(Te))},hkErr:ho(st,Ie.FailedMonitorAjaxOpen,"Failed to monitor XMLHttpRequest.open, monitoring data for this ajax call may be incorrect.")}),Zt(XMLHttpRequest,"send",{req:function(Q,fe){var Ee=Q.inst,ge=Ee[sn];ar(Ee)&&!ge.xhrMonitoringState.sendDone&&(Ct("xhr",ge),ge.requestSentTime=yi(),st.includeCorrelationHeaders(ge,void 0,void 0,Ee),ge.xhrMonitoringState.sendDone=!0)},hkErr:ho(st,Ie.FailedMonitorAjaxSend,"Failed to monitor XMLHttpRequest, monitoring data for this ajax call may be incorrect.")}),Zt(XMLHttpRequest,"abort",{req:function(Q){var fe=Q.inst,Ee=fe[sn];ar(fe)&&!Ee.xhrMonitoringState.abortDone&&(Ee.aborted=1,Ee.xhrMonitoringState.abortDone=!0)},hkErr:ho(st,Ie.FailedMonitorAjaxAbort,"Failed to monitor XMLHttpRequest.abort, monitoring data for this ajax call may be incorrect.")}),h&&Zt(XMLHttpRequest,"setRequestHeader",{req:function(Q,fe,Ee){var ge=Q.inst;ar(ge)&&Vt(fe)&&(ge[sn].requestHeaders[fe]=Ee)},hkErr:ho(st,Ie.FailedMonitorAjaxSetRequestHeader,"Failed to monitor XMLHttpRequest.setRequestHeader, monitoring data for this ajax call may be incorrect.")}),s=!0)}function Tr(Q,fe,Ee){var ge=!1,Te=((rt(fe)?fe:(fe||{}).url||"")||"").toLowerCase();if(nt(ut,function($e){var Qe=$e;rt($e)&&(Qe=new RegExp($e)),ge||(ge=Qe.test(Te))}),ge)return ge;var Ue=Ci(Te,"?"),Ae=Ci(Te,"#");return(Ue===-1||Ae!==-1&&Ae<Ue)&&(Ue=Ae),Ue!==-1&&(Te=Te.substring(0,Ue)),Le(Q)?Le(fe)||(ge=(typeof fe=="object"?fe[Mn]===!0:!1)||(Ee?Ee[Mn]===!0:!1)):ge=Q[Mn]===!0||Te[Mn]===!0,!ge&&Te&&Xa(Te)&&(ge=!0),ge?et[Te]||(et[Te]=1):et[Te]&&(ge=!0),ge}function ar(Q,fe){var Ee=!0,ge=s;return Le(Q)||(Ee=fe===!0||!Le(Q[sn])),ge&&Ee}function fr(Q,fe,Ee,ge){var Te=oe&&oe.telemetryTrace&&oe.telemetryTrace.traceID||Gr(),Ue=Gr().substr(0,16),Ae=new Vl(Te,Ue,st[po]());Ae.method=fe,Ae.requestUrl=Ee,Ae.xhrMonitoringState.openDone=!0,Ae.requestHeaders={},Ae.async=ge,Ae.errorStatusText=k,Q[sn]=Ae}function Wt(Q){Q[sn].xhrMonitoringState.stateChangeAttached=Rn(Q,"readystatechange",function(){try{Q&&Q.readyState===4&&ar(Q)&&Lt(Q)}catch(Ee){var fe=ot(Ee);(!fe||Ci(fe.toLowerCase(),"c00c023f")===-1)&&xo(st,Ie.FailedMonitorAjaxRSC,"Failed to monitor XMLHttpRequest 'readystatechange' event handler, monitoring data for this ajax call may be incorrect.",{ajaxDiagnosticsMessage:P0(Q),exception:fe})}})}function pt(Q){try{var fe=Q.responseType;if(fe===""||fe==="text")return Q.responseText}catch{}return null}function Lt(Q){var fe=Q[sn];fe.responseFinishedTime=yi(),fe.status=Q.status;function Ee(ge,Te){var Ue=Te||{};Ue.ajaxDiagnosticsMessage=P0(Q),ge&&(Ue.exception=ot(ge)),Ii(st,Ie.FailedMonitorAjaxDur,"Failed to calculate the duration of the ajax call, monitoring data for this ajax call won't be sent.",Ue)}Ze("xmlhttprequest",fe,function(){try{var ge=fe.CreateTrackItem("Ajax",h,function(){var Ue={statusText:Q.statusText,headerMap:null,correlationContext:Bt(Q),type:Q.responseType,responseText:pt(Q),response:Q.response};if(ue){var Ae=Q.getAllResponseHeaders();if(Ae){var $e=rr(Ae).split(/[\r\n]+/),Qe={};nt($e,function(de){var ir=de.split(": "),br=ir.shift(),yr=ir.join(": ");Vt(br)&&(Qe[br]=yr)}),Ue.headerMap=Qe}}return Ue}),Te=void 0;try{ht&&(Te=ht({status:Q.status,xhr:Q}))}catch{Ii(st,Ie.FailedAddingCustomDefinedRequestContext,"Failed to add custom defined request context as configured call back may missing a null check.")}ge?(Te!==void 0&&(ge.properties=tr(tr({},ge.properties),Te)),st[n](ge)):Ee(null,{requestSentTime:fe.requestSentTime,responseFinishedTime:fe.responseFinishedTime})}finally{try{Q[sn]=null}catch{}}},function(ge){Ee(ge,null)})}function Bt(Q){try{var fe=Q.getAllResponseHeaders();if(fe!==null){var Ee=Ci(fe.toLowerCase(),Nt.requestContextHeaderLowerCase);if(Ee!==-1){var ge=Q.getResponseHeader(Nt.requestContextHeader);return ea.getCorrelationContext(ge)}}}catch(Te){Ii(st,Ie.FailedMonitorAjaxGetCorrelationHeader,"Failed to get Request-Context correlation header as it may be not included in the response or not accessible.",{ajaxDiagnosticsMessage:P0(Q),exception:ot(Te)})}}function Ct(Q,fe){if(fe.requestUrl&&Se&&P){var Ee=en();if(Ee&&lt(Ee.mark)){ef++;var ge=Se+Q+"#"+ef;Ee.mark(ge);var Te=Ee.getEntriesByName(ge);Te&&Te.length===1&&(fe.perfMark=Te[0])}}}function Ze(Q,fe,Ee,ge){var Te=fe.perfMark,Ue=en(),Ae=_.maxAjaxPerfLookupAttempts,$e=_.ajaxPerfLookupDelay,Qe=fe.requestUrl,de=0;(function ir(){try{if(Ue&&Te){de++;for(var br=null,yr=Ue.getEntries(),Rr=yr.length-1;Rr>=0;Rr--){var Et=yr[Rr];if(Et){if(Et.entryType==="resource")Et.initiatorType===Q&&(Ci(Et.name,Qe)!==-1||Ci(Qe,Et.name)!==-1)&&(br=Et);else if(Et.entryType==="mark"&&Et.name===Te.name){fe.perfTiming=br;break}if(Et.startTime<Te.startTime-1e3)break}}}!Te||fe.perfTiming||de>=Ae||fe.async===!1?(Te&&lt(Ue.clearMarks)&&Ue.clearMarks(Te.name),fe.perfAttempts=de,Ee()):setTimeout(ir,$e)}catch(ga){ge(ga)}})()}function g(Q,fe){var Ee=oe&&oe.telemetryTrace&&oe.telemetryTrace.traceID||Gr(),ge=Gr().substr(0,16),Te=new Vl(Ee,ge,st[po]());Te.requestSentTime=yi(),Te.errorStatusText=k,Q instanceof Request?Te.requestUrl=Q?Q.url:"":Te.requestUrl=Q;var Ue="GET";fe&&fe.method?Ue=fe.method:Q&&Q instanceof Request&&(Ue=Q.method),Te.method=Ue;var Ae={};if(h){var $e=new Headers((fe?fe.headers:0)||(Q instanceof Request?Q.headers||{}:{}));$e.forEach(function(Qe,de){Vt(de)&&(Ae[de]=Qe)})}return Te.requestHeaders=Ae,Ct("fetch",Te),Te}function K(Q){var fe="";try{Le(Q)||(typeof Q=="string"?fe+="(url: '".concat(Q,"')"):fe+="(url: '".concat(Q.url,"')"))}catch(Ee){xo(st,Ie.FailedMonitorAjaxOpen,"Failed to grab failed fetch diagnostics message",{exception:ot(Ee)})}return fe}function we(Q,fe,Ee,ge,Te,Ue,Ae){if(!Te)return;function $e(Qe,de,ir){var br=ir||{};br.fetchDiagnosticsMessage=K(Ee),de&&(br.exception=ot(de)),Ii(st,Qe,"Failed to calculate the duration of the fetch call, monitoring data for this fetch call won't be sent.",br)}Te.responseFinishedTime=yi(),Te.status=fe,Ze("fetch",Te,function(){var Qe=Te.CreateTrackItem("Fetch",h,Ue),de;try{ht&&(de=ht({status:fe,request:Ee,response:ge}))}catch{Ii(st,Ie.FailedAddingCustomDefinedRequestContext,"Failed to add custom defined request context as configured call back may missing a null check.")}Qe?(de!==void 0&&(Qe.properties=tr(tr({},Qe.properties),de)),st[n](Qe)):$e(Ie.FailedMonitorAjaxDur,null,{requestSentTime:Te.requestSentTime,responseFinishedTime:Te.responseFinishedTime})},function(Qe){$e(Ie.FailedMonitorAjaxGetCorrelationHeader,Qe,null)})}function He(Q){if(Q&&Q.headers)try{var fe=Q.headers.get(Nt.requestContextHeader);return ea.getCorrelationContext(fe)}catch(Ee){Ii(st,Ie.FailedMonitorAjaxGetCorrelationHeader,"Failed to get Request-Context correlation header as it may be not included in the response or not accessible.",{fetchDiagnosticsMessage:K(Q),exception:ot(Ee)})}}}),r}return t.getDefaultConfig=function(){var r={maxAjaxCallsPerView:500,disableAjaxTracking:!1,disableFetchTracking:!0,excludeRequestFromAutoTrackingPatterns:void 0,disableCorrelationHeaders:!1,distributedTracingMode:mn.AI_AND_W3C,correlationHeaderExcludedDomains:["*.blob.core.windows.net","*.blob.core.chinacloudapi.cn","*.blob.core.cloudapi.de","*.blob.core.usgovcloudapi.net"],correlationHeaderDomains:void 0,correlationHeaderExcludePatterns:void 0,appId:void 0,enableCorsCorrelation:!1,enableRequestHeaderTracking:!1,enableResponseHeaderTracking:!1,enableAjaxErrorStatusText:!1,enableAjaxPerfTracking:!1,maxAjaxPerfLookupAttempts:3,ajaxPerfLookupDelay:25,ignoreHeaders:["Authorization","X-API-Key","WWW-Authenticate"],addRequestContext:void 0};return r},t.getEmptyConfig=function(){var r=this.getDefaultConfig();return It(r,function(n){r[n]=void 0}),r},t.prototype.processTelemetry=function(r,n){this.processNext(r,n)},t.identifier="AjaxDependencyPlugin",t}(In);var zl,rf=["snippet","dependencies","properties","_snippetVersion","appInsightsNew","getSKUDefaults"];var Gl=function(){function e(t){var r=this;r._snippetVersion=""+(t.sv||t.version||""),t.queue=t.queue||[],t.version=t.version||2;var n=t.config||{};if(n.connectionString){var a=El(n.connectionString),i=a.ingestionendpoint;n.endpointUrl=i?"".concat(i,"/v2/track"):n.endpointUrl,n.instrumentationKey=a.instrumentationkey||n.instrumentationKey}r.appInsights=new Fl,r.properties=new Ul,r.dependencies=new jl,r.core=new nl,r._sender=new kl,r.snippet=t,r.config=n,r.getSKUDefaults()}return e.prototype.getCookieMgr=function(){return this.appInsights.getCookieMgr()},e.prototype.trackEvent=function(t,r){this.appInsights.trackEvent(t,r)},e.prototype.trackPageView=function(t){var r=t||{};this.appInsights.trackPageView(r)},e.prototype.trackPageViewPerformance=function(t){var r=t||{};this.appInsights.trackPageViewPerformance(r)},e.prototype.trackException=function(t,r){t&&!t.exception&&t.error&&(t.exception=t.error),this.appInsights.trackException(t,r)},e.prototype._onerror=function(t){this.appInsights._onerror(t)},e.prototype.trackTrace=function(t,r){this.appInsights.trackTrace(t,r)},e.prototype.trackMetric=function(t,r){this.appInsights.trackMetric(t,r)},e.prototype.startTrackPage=function(t){this.appInsights.startTrackPage(t)},e.prototype.stopTrackPage=function(t,r,n,a){this.appInsights.stopTrackPage(t,r,n,a)},e.prototype.startTrackEvent=function(t){this.appInsights.startTrackEvent(t)},e.prototype.stopTrackEvent=function(t,r,n){this.appInsights.stopTrackEvent(t,r,n)},e.prototype.addTelemetryInitializer=function(t){return this.appInsights.addTelemetryInitializer(t)},e.prototype.setAuthenticatedUserContext=function(t,r,n){n===void 0&&(n=!1),this.properties.context.user.setAuthenticatedUserContext(t,r,n)},e.prototype.clearAuthenticatedUserContext=function(){this.properties.context.user.clearAuthenticatedUserContext()},e.prototype.trackDependencyData=function(t){this.dependencies.trackDependencyData(t)},e.prototype.flush=function(t){var r=this;t===void 0&&(t=!0),qn(this.core,function(){return"AISKU.flush"},function(){nt(r.core.getTransmissionControls(),function(n){nt(n,function(a){a.flush(t)})})},null,t)},e.prototype.onunloadFlush=function(t){t===void 0&&(t=!0),nt(this.core.getTransmissionControls(),function(r){nt(r,function(n){n.onunloadFlush?n.onunloadFlush():n.flush(t)})})},e.prototype.loadAppInsights=function(t,r,n){var a=this;t===void 0&&(t=!1);var i=this;function s(m){if(m){var _="";Le(i._snippetVersion)||(_+=i._snippetVersion),t&&(_+=".lg"),i.context&&i.context.internal&&(i.context.internal.snippetVer=_||"-"),It(i,function(h,k){rt(h)&&!lt(k)&&h&&h[0]!=="_"&&rf.indexOf(h)===-1&&(m[h]=k)})}}return t&&i.config.extensions&&i.config.extensions.length>0&&Ir("Extensions not allowed in legacy mode"),qn(i.core,function(){return"AISKU.loadAppInsights"},function(){var m=[];m.push(i._sender),m.push(i.properties),m.push(i.dependencies),m.push(i.appInsights),i.core.initialize(i.config,m,r,n),i.context=i.properties.context,zl&&i.context&&(i.context.internal.sdkSrc=zl),s(i.snippet),i.emptyQueue(),i.pollInternalLogs(),i.addHousekeepingBeforeUnload(a)}),i},e.prototype.updateSnippetDefinitions=function(t){Cs(t,this,function(r){return r&&rf.indexOf(r)===-1})},e.prototype.emptyQueue=function(){var t=this;try{if(_r(t.snippet.queue)){for(var r=t.snippet.queue.length,n=0;n<r;n++){var a=t.snippet.queue[n];a()}t.snippet.queue=void 0,delete t.snippet.queue}}catch(s){var i={};s&&lt(s.toString)&&(i.exception=s.toString())}},e.prototype.pollInternalLogs=function(){this.core.pollInternalLogs()},e.prototype.stopPollingInternalLogs=function(){this.core.stopPollingInternalLogs()},e.prototype.addHousekeepingBeforeUnload=function(t){if(La()||s0()){var r=function(){t.onunloadFlush(!1),nt(t.appInsights.core._extensions,function(i){if(i.identifier===ma)return i&&i.context&&i.context._sessionManager&&i.context._sessionManager.backup(),-1})},n=!1,a=t.appInsights.config.disablePageUnloadEvents;t.appInsights.config.disableFlushOnBeforeUnload||(n=il(r,a),n=io(r,a)||n,!n&&!Vs()&&t.appInsights.core.logger.throwInternal(Pe.CRITICAL,Ie.FailedToAddHandlerForOnBeforeUnload,"Could not add handler for beforeunload and pagehide")),!n&&!t.appInsights.config.disableFlushOnUnload&&io(r,a)}},e.prototype.getSender=function(){return this._sender},e.prototype.getSKUDefaults=function(){var t=this;t.config.diagnosticLogInterval=t.config.diagnosticLogInterval&&t.config.diagnosticLogInterval>0?t.config.diagnosticLogInterval:1e4},e}();(function(){var e=null,t=!1,r=["://js.monitor.azure.com/","://az416426.vo.msecnd.net/"];try{var n=(document||{}).currentScript;n&&(e=n.src)}catch{}if(e)try{var a=e.toLowerCase();if(a){for(var i="",s=0;s<r.length;s++)if(a.indexOf(r[s])!==-1){i="cdn"+(s+1),a.indexOf("/scripts/")===-1&&(a.indexOf("/next/")!==-1?i+="-next":a.indexOf("/beta/")!==-1&&(i+="-beta")),zl=i+(t?".mod":"");break}}}catch{}})();var Mi,nf=e=>(Mi=new Gl({config:{instrumentationKey:e}}),Mi.loadAppInsights(),Mi),bo={START:"start",FINISH:"finish",ERROR:"error",UPLOAD_VIDEO:"upload_video",START_RECORD:"start_record",FILE:"file"},Hv=e=>Mi.trackException({exception:e}),yo=(e,t)=>Mi.trackEvent({name:e,properties:t}),Uv=(e,t,r)=>Mi.trackPageView({name:e,uri:t,properties:r}),ft={trackPage:Uv,trackError:Hv,registerStart:(e,t,r)=>yo(bo.START,{proctoringId:e,success:t,description:r}),registerFinish:(e,t,r)=>yo(bo.FINISH,{proctoringId:e,success:t,description:r}),registerError:(e,t)=>yo(bo.ERROR,{proctoringId:e,description:t}),registerUploadVideo:(e,t,r,n)=>yo(bo.UPLOAD_VIDEO,{proctoringId:e,success:t,description:r,uploadTime:n}),registerRecord:(e,t,r)=>yo(bo.START_RECORD,{proctoringId:e,success:t,description:r})};function go(e,t){return function(){return e.apply(t,arguments)}}var{toString:of}=Object.prototype,{getPrototypeOf:Wl}=Object,Yl=(e=>t=>{let r=of.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),ra=e=>(e=e.toLowerCase(),t=>Yl(t)===e),L0=e=>t=>typeof t===e,{isArray:Eo}=Array,Xl=L0("undefined");function Vv(e){return e!==null&&!Xl(e)&&e.constructor!==null&&!Xl(e.constructor)&&Bi(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}var sf=ra("ArrayBuffer");function qv(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&sf(e.buffer),t}var jv=L0("string"),Bi=L0("function"),lf=L0("number"),uf=e=>e!==null&&typeof e=="object",zv=e=>e===!0||e===!1,F0=e=>{if(Yl(e)!=="object")return!1;let t=Wl(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},Gv=ra("Date"),Xv=ra("File"),Kv=ra("Blob"),Wv=ra("FileList"),Yv=e=>uf(e)&&Bi(e.pipe),$v=e=>{let t="[object FormData]";return e&&(typeof FormData=="function"&&e instanceof FormData||of.call(e)===t||Bi(e.toString)&&e.toString()===t)},Zv=ra("URLSearchParams"),Qv=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function D0(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,a;if(typeof e!="object"&&(e=[e]),Eo(e))for(n=0,a=e.length;n<a;n++)t.call(null,e[n],n,e);else{let i=r?Object.getOwnPropertyNames(e):Object.keys(e),s=i.length,m;for(n=0;n<s;n++)m=i[n],t.call(null,e[m],m,e)}}function Kl(){let e={},t=(r,n)=>{F0(e[n])&&F0(r)?e[n]=Kl(e[n],r):F0(r)?e[n]=Kl({},r):Eo(r)?e[n]=r.slice():e[n]=r};for(let r=0,n=arguments.length;r<n;r++)arguments[r]&&D0(arguments[r],t);return e}var Jv=(e,t,r,{allOwnKeys:n}={})=>(D0(t,(a,i)=>{r&&Bi(a)?e[i]=go(a,r):e[i]=a},{allOwnKeys:n}),e),e_=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),t_=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},r_=(e,t,r,n)=>{let a,i,s,m={};if(t=t||{},e==null)return t;do{for(a=Object.getOwnPropertyNames(e),i=a.length;i-- >0;)s=a[i],(!n||n(s,e,t))&&!m[s]&&(t[s]=e[s],m[s]=!0);e=r!==!1&&Wl(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},n_=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;let n=e.indexOf(t,r);return n!==-1&&n===r},a_=e=>{if(!e)return null;if(Eo(e))return e;let t=e.length;if(!lf(t))return null;let r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},i_=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Wl(Uint8Array)),o_=(e,t)=>{let n=(e&&e[Symbol.iterator]).call(e),a;for(;(a=n.next())&&!a.done;){let i=a.value;t.call(e,i[0],i[1])}},s_=(e,t)=>{let r,n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},l_=ra("HTMLFormElement"),u_=e=>e.toLowerCase().replace(/[_-\s]([a-z\d])(\w*)/g,function(r,n,a){return n.toUpperCase()+a}),af=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),c_=ra("RegExp"),cf=(e,t)=>{let r=Object.getOwnPropertyDescriptors(e),n={};D0(r,(a,i)=>{t(a,i,e)!==!1&&(n[i]=a)}),Object.defineProperties(e,n)},f_=e=>{cf(e,(t,r)=>{let n=e[r];if(!!Bi(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not read-only method '"+r+"'")})}})},d_=(e,t)=>{let r={},n=a=>{a.forEach(i=>{r[i]=!0})};return Eo(e)?n(e):n(String(e).split(t)),r},v_=()=>{},__=(e,t)=>(e=+e,Number.isFinite(e)?e:t),ye={isArray:Eo,isArrayBuffer:sf,isBuffer:Vv,isFormData:$v,isArrayBufferView:qv,isString:jv,isNumber:lf,isBoolean:zv,isObject:uf,isPlainObject:F0,isUndefined:Xl,isDate:Gv,isFile:Xv,isBlob:Kv,isRegExp:c_,isFunction:Bi,isStream:Yv,isURLSearchParams:Zv,isTypedArray:i_,isFileList:Wv,forEach:D0,merge:Kl,extend:Jv,trim:Qv,stripBOM:e_,inherits:t_,toFlatObject:r_,kindOf:Yl,kindOfTest:ra,endsWith:n_,toArray:a_,forEachEntry:o_,matchAll:s_,isHTMLForm:l_,hasOwnProperty:af,hasOwnProp:af,reduceDescriptors:cf,freezeMethods:f_,toObjectSet:d_,toCamelCase:u_,noop:v_,toFiniteNumber:__};function Ni(e,t,r,n,a){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),a&&(this.response=a)}ye.inherits(Ni,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var ff=Ni.prototype,df={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{df[e]={value:e}});Object.defineProperties(Ni,df);Object.defineProperty(ff,"isAxiosError",{value:!0});Ni.from=(e,t,r,n,a,i)=>{let s=Object.create(ff);return ye.toFlatObject(e,s,function(_){return _!==Error.prototype},m=>m!=="isAxiosError"),Ni.call(s,e.message,t,r,n,a),s.cause=e,s.name=e.name,i&&Object.assign(s,i),s};var Rt=Ni;var mf=G1(_f(),1),hf=mf.default;function $l(e){return ye.isPlainObject(e)||ye.isArray(e)}function Sf(e){return ye.endsWith(e,"[]")?e.slice(0,-2):e}function pf(e,t,r){return e?e.concat(t).map(function(a,i){return a=Sf(a),!r&&i?"["+a+"]":a}).join(r?".":""):t}function m_(e){return ye.isArray(e)&&!e.some($l)}var h_=ye.toFlatObject(ye,{},null,function(t){return/^is[A-Z]/.test(t)});function p_(e){return e&&ye.isFunction(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator]}function S_(e,t,r){if(!ye.isObject(e))throw new TypeError("target must be an object");t=t||new(hf||FormData),r=ye.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(Se,P){return!ye.isUndefined(P[Se])});let n=r.metaTokens,a=r.visitor||k,i=r.dots,s=r.indexes,_=(r.Blob||typeof Blob<"u"&&Blob)&&p_(t);if(!ye.isFunction(a))throw new TypeError("visitor must be a function");function h(D){if(D===null)return"";if(ye.isDate(D))return D.toISOString();if(!_&&ye.isBlob(D))throw new Rt("Blob is not supported. Use a Buffer instead.");return ye.isArrayBuffer(D)||ye.isTypedArray(D)?_&&typeof Blob=="function"?new Blob([D]):Buffer.from(D):D}function k(D,Se,P){let se=D;if(D&&!P&&typeof D=="object"){if(ye.endsWith(Se,"{}"))Se=n?Se:Se.slice(0,-2),D=JSON.stringify(D);else if(ye.isArray(D)&&m_(D)||ye.isFileList(D)||ye.endsWith(Se,"[]")&&(se=ye.toArray(D)))return Se=Sf(Se),se.forEach(function(De,et){!(ye.isUndefined(De)||De===null)&&t.append(s===!0?pf([Se],et,i):s===null?Se:Se+"[]",h(De))}),!1}return $l(D)?!0:(t.append(pf(P,Se,i),h(D)),!1)}let re=[],oe=Object.assign(h_,{defaultVisitor:k,convertValue:h,isVisitable:$l});function te(D,Se){if(!ye.isUndefined(D)){if(re.indexOf(D)!==-1)throw Error("Circular reference detected in "+Se.join("."));re.push(D),ye.forEach(D,function(se,ue){(!(ye.isUndefined(se)||se===null)&&a.call(t,se,ye.isString(ue)?ue.trim():ue,Se,oe))===!0&&te(se,Se?Se.concat(ue):[ue])}),re.pop()}}if(!ye.isObject(e))throw new TypeError("data must be an object");return te(e),t}var Sa=S_;function xf(e){let t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return t[n]})}function bf(e,t){this._pairs=[],e&&Sa(e,this,t)}var yf=bf.prototype;yf.append=function(t,r){this._pairs.push([t,r])};yf.toString=function(t){let r=t?function(n){return t.call(this,n,xf)}:xf;return this._pairs.map(function(a){return r(a[0])+"="+r(a[1])},"").join("&")};var O0=bf;function x_(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function To(e,t,r){if(!t)return e;let n=r&&r.encode||x_,a=r&&r.serialize,i;if(a?i=a(t,r):i=ye.isURLSearchParams(t)?t.toString():new O0(t,r).toString(n),i){let s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+i}return e}var Zl=class{constructor(){this.handlers=[]}use(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){ye.forEach(this.handlers,function(n){n!==null&&t(n)})}},Ql=Zl;var k0={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1};var gf=typeof URLSearchParams<"u"?URLSearchParams:O0;var Ef=FormData;var b_=(()=>{let e;return typeof navigator<"u"&&((e=navigator.product)==="ReactNative"||e==="NativeScript"||e==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),Or={isBrowser:!0,classes:{URLSearchParams:gf,FormData:Ef,Blob},isStandardBrowserEnv:b_,protocols:["http","https","file","blob","url","data"]};function Jl(e,t){return Sa(e,new Or.classes.URLSearchParams,Object.assign({visitor:function(r,n,a,i){return Or.isNode&&ye.isBuffer(r)?(this.append(n,r.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},t))}function y_(e){return ye.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function g_(e){let t={},r=Object.keys(e),n,a=r.length,i;for(n=0;n<a;n++)i=r[n],t[i]=e[i];return t}function E_(e){function t(r,n,a,i){let s=r[i++],m=Number.isFinite(+s),_=i>=r.length;return s=!s&&ye.isArray(a)?a.length:s,_?(ye.hasOwnProp(a,s)?a[s]=[a[s],n]:a[s]=n,!m):((!a[s]||!ye.isObject(a[s]))&&(a[s]=[]),t(r,n,a[s],i)&&ye.isArray(a[s])&&(a[s]=g_(a[s])),!m)}if(ye.isFormData(e)&&ye.isFunction(e.entries)){let r={};return ye.forEachEntry(e,(n,a)=>{t(y_(n),a,r,0)}),r}return null}var H0=E_;function e1(e,t,r){let n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new Rt("Request failed with status code "+r.status,[Rt.ERR_BAD_REQUEST,Rt.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}var Tf=Or.isStandardBrowserEnv?function(){return{write:function(r,n,a,i,s,m){let _=[];_.push(r+"="+encodeURIComponent(n)),ye.isNumber(a)&&_.push("expires="+new Date(a).toGMTString()),ye.isString(i)&&_.push("path="+i),ye.isString(s)&&_.push("domain="+s),m===!0&&_.push("secure"),document.cookie=_.join("; ")},read:function(r){let n=document.cookie.match(new RegExp("(^|;\\s*)("+r+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove:function(r){this.write(r,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function t1(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function r1(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}function wo(e,t){return e&&!t1(t)?r1(e,t):t}var wf=Or.isStandardBrowserEnv?function(){let t=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a"),n;function a(i){let s=i;return t&&(r.setAttribute("href",s),s=r.href),r.setAttribute("href",s),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:r.pathname.charAt(0)==="/"?r.pathname:"/"+r.pathname}}return n=a(window.location.href),function(s){let m=ye.isString(s)?a(s):s;return m.protocol===n.protocol&&m.host===n.host}}():function(){return function(){return!0}}();function Rf(e,t,r){Rt.call(this,e??"canceled",Rt.ERR_CANCELED,t,r),this.name="CanceledError"}ye.inherits(Rf,Rt,{__CANCEL__:!0});var xa=Rf;function n1(e){let t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}var T_=ye.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Af=e=>{let t={},r,n,a;return e&&e.split(`
21
+ `).forEach(function(s){a=s.indexOf(":"),r=s.substring(0,a).trim().toLowerCase(),n=s.substring(a+1).trim(),!(!r||t[r]&&T_[r])&&(r==="set-cookie"?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)}),t};var If=Symbol("internals"),Mf=Symbol("defaults");function Ao(e){return e&&String(e).trim().toLowerCase()}function U0(e){return e===!1||e==null?e:ye.isArray(e)?e.map(U0):String(e)}function w_(e){let t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g,n;for(;n=r.exec(e);)t[n[1]]=n[2];return t}function Cf(e,t,r,n){if(ye.isFunction(n))return n.call(this,t,r);if(!!ye.isString(t)){if(ye.isString(n))return t.indexOf(n)!==-1;if(ye.isRegExp(n))return n.test(t)}}function R_(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,n)=>r.toUpperCase()+n)}function A_(e,t){let r=ye.toCamelCase(" "+t);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+r,{value:function(a,i,s){return this[n].call(this,t,a,i,s)},configurable:!0})})}function Ro(e,t){t=t.toLowerCase();let r=Object.keys(e),n=r.length,a;for(;n-- >0;)if(a=r[n],t===a.toLowerCase())return a;return null}function Pi(e,t){e&&this.set(e),this[Mf]=t||null}Object.assign(Pi.prototype,{set:function(e,t,r){let n=this;function a(i,s,m){let _=Ao(s);if(!_)throw new Error("header name must be a non-empty string");let h=Ro(n,_);h&&m!==!0&&(n[h]===!1||m===!1)||(n[h||s]=U0(i))}return ye.isPlainObject(e)?ye.forEach(e,(i,s)=>{a(i,s,t)}):a(t,e,r),this},get:function(e,t){if(e=Ao(e),!e)return;let r=Ro(this,e);if(r){let n=this[r];if(!t)return n;if(t===!0)return w_(n);if(ye.isFunction(t))return t.call(this,n,r);if(ye.isRegExp(t))return t.exec(n);throw new TypeError("parser must be boolean|regexp|function")}},has:function(e,t){if(e=Ao(e),e){let r=Ro(this,e);return!!(r&&(!t||Cf(this,this[r],r,t)))}return!1},delete:function(e,t){let r=this,n=!1;function a(i){if(i=Ao(i),i){let s=Ro(r,i);s&&(!t||Cf(r,r[s],s,t))&&(delete r[s],n=!0)}}return ye.isArray(e)?e.forEach(a):a(e),n},clear:function(){return Object.keys(this).forEach(this.delete.bind(this))},normalize:function(e){let t=this,r={};return ye.forEach(this,(n,a)=>{let i=Ro(r,a);if(i){t[i]=U0(n),delete t[a];return}let s=e?R_(a):String(a).trim();s!==a&&delete t[a],t[s]=U0(n),r[s]=!0}),this},toJSON:function(e){let t=Object.create(null);return ye.forEach(Object.assign({},this[Mf]||null,this),(r,n)=>{r==null||r===!1||(t[n]=e&&ye.isArray(r)?r.join(", "):r)}),t}});Object.assign(Pi,{from:function(e){return ye.isString(e)?new this(Af(e)):e instanceof this?e:new this(e)},accessor:function(e){let r=(this[If]=this[If]={accessors:{}}).accessors,n=this.prototype;function a(i){let s=Ao(i);r[s]||(A_(n,i),r[s]=!0)}return ye.isArray(e)?e.forEach(a):a(e),this}});Pi.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent"]);ye.freezeMethods(Pi.prototype);ye.freezeMethods(Pi);var Pn=Pi;function I_(e,t){e=e||10;let r=new Array(e),n=new Array(e),a=0,i=0,s;return t=t!==void 0?t:1e3,function(_){let h=Date.now(),k=n[i];s||(s=h),r[a]=_,n[a]=h;let re=i,oe=0;for(;re!==a;)oe+=r[re++],re=re%e;if(a=(a+1)%e,a===i&&(i=(i+1)%e),h-s<t)return;let te=k&&h-k;return te?Math.round(oe*1e3/te):void 0}}var Bf=I_;function Nf(e,t){let r=0,n=Bf(50,250);return a=>{let i=a.loaded,s=a.lengthComputable?a.total:void 0,m=i-r,_=n(m),h=i<=s;r=i;let k={loaded:i,total:s,progress:s?i/s:void 0,bytes:m,rate:_||void 0,estimated:_&&s&&h?(s-i)/_:void 0};k[t?"download":"upload"]=!0,e(k)}}function Io(e){return new Promise(function(r,n){let a=e.data,i=Pn.from(e.headers).normalize(),s=e.responseType,m;function _(){e.cancelToken&&e.cancelToken.unsubscribe(m),e.signal&&e.signal.removeEventListener("abort",m)}ye.isFormData(a)&&Or.isStandardBrowserEnv&&i.setContentType(!1);let h=new XMLHttpRequest;if(e.auth){let te=e.auth.username||"",D=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";i.set("Authorization","Basic "+btoa(te+":"+D))}let k=wo(e.baseURL,e.url);h.open(e.method.toUpperCase(),To(k,e.params,e.paramsSerializer),!0),h.timeout=e.timeout;function re(){if(!h)return;let te=Pn.from("getAllResponseHeaders"in h&&h.getAllResponseHeaders()),Se={data:!s||s==="text"||s==="json"?h.responseText:h.response,status:h.status,statusText:h.statusText,headers:te,config:e,request:h};e1(function(se){r(se),_()},function(se){n(se),_()},Se),h=null}if("onloadend"in h?h.onloadend=re:h.onreadystatechange=function(){!h||h.readyState!==4||h.status===0&&!(h.responseURL&&h.responseURL.indexOf("file:")===0)||setTimeout(re)},h.onabort=function(){!h||(n(new Rt("Request aborted",Rt.ECONNABORTED,e,h)),h=null)},h.onerror=function(){n(new Rt("Network Error",Rt.ERR_NETWORK,e,h)),h=null},h.ontimeout=function(){let D=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded",Se=e.transitional||k0;e.timeoutErrorMessage&&(D=e.timeoutErrorMessage),n(new Rt(D,Se.clarifyTimeoutError?Rt.ETIMEDOUT:Rt.ECONNABORTED,e,h)),h=null},Or.isStandardBrowserEnv){let te=(e.withCredentials||wf(k))&&e.xsrfCookieName&&Tf.read(e.xsrfCookieName);te&&i.set(e.xsrfHeaderName,te)}a===void 0&&i.setContentType(null),"setRequestHeader"in h&&ye.forEach(i.toJSON(),function(D,Se){h.setRequestHeader(Se,D)}),ye.isUndefined(e.withCredentials)||(h.withCredentials=!!e.withCredentials),s&&s!=="json"&&(h.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&h.addEventListener("progress",Nf(e.onDownloadProgress,!0)),typeof e.onUploadProgress=="function"&&h.upload&&h.upload.addEventListener("progress",Nf(e.onUploadProgress)),(e.cancelToken||e.signal)&&(m=te=>{!h||(n(!te||te.type?new xa(null,e,h):te),h.abort(),h=null)},e.cancelToken&&e.cancelToken.subscribe(m),e.signal&&(e.signal.aborted?m():e.signal.addEventListener("abort",m)));let oe=n1(k);if(oe&&Or.protocols.indexOf(oe)===-1){n(new Rt("Unsupported protocol "+oe+":",Rt.ERR_BAD_REQUEST,e));return}h.send(a||null)})}var Pf={http:Io,xhr:Io},a1={getAdapter:e=>{if(ye.isString(e)){let t=Pf[e];if(!e)throw Error(ye.hasOwnProp(e)?`Adapter '${e}' is not available in the build`:`Can not resolve adapter '${e}'`);return t}if(!ye.isFunction(e))throw new TypeError("adapter is not a function");return e},adapters:Pf};var C_={"Content-Type":"application/x-www-form-urlencoded"};function M_(){let e;return typeof XMLHttpRequest<"u"?e=a1.getAdapter("xhr"):typeof process<"u"&&ye.kindOf(process)==="process"&&(e=a1.getAdapter("http")),e}function B_(e,t,r){if(ye.isString(e))try{return(t||JSON.parse)(e),ye.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}var V0={transitional:k0,adapter:M_(),transformRequest:[function(t,r){let n=r.getContentType()||"",a=n.indexOf("application/json")>-1,i=ye.isObject(t);if(i&&ye.isHTMLForm(t)&&(t=new FormData(t)),ye.isFormData(t))return a&&a?JSON.stringify(H0(t)):t;if(ye.isArrayBuffer(t)||ye.isBuffer(t)||ye.isStream(t)||ye.isFile(t)||ye.isBlob(t))return t;if(ye.isArrayBufferView(t))return t.buffer;if(ye.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let m;if(i){if(n.indexOf("application/x-www-form-urlencoded")>-1)return Jl(t,this.formSerializer).toString();if((m=ye.isFileList(t))||n.indexOf("multipart/form-data")>-1){let _=this.env&&this.env.FormData;return Sa(m?{"files[]":t}:t,_&&new _,this.formSerializer)}}return i||a?(r.setContentType("application/json",!1),B_(t)):t}],transformResponse:[function(t){let r=this.transitional||V0.transitional,n=r&&r.forcedJSONParsing,a=this.responseType==="json";if(t&&ye.isString(t)&&(n&&!this.responseType||a)){let s=!(r&&r.silentJSONParsing)&&a;try{return JSON.parse(t)}catch(m){if(s)throw m.name==="SyntaxError"?Rt.from(m,Rt.ERR_BAD_RESPONSE,this,null,this.response):m}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Or.classes.FormData,Blob:Or.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};ye.forEach(["delete","get","head"],function(t){V0.headers[t]={}});ye.forEach(["post","put","patch"],function(t){V0.headers[t]=ye.merge(C_)});var Fi=V0;function Co(e,t){let r=this||Fi,n=t||r,a=Pn.from(n.headers),i=n.data;return ye.forEach(e,function(m){i=m.call(r,i,a.normalize(),t?t.status:void 0)}),a.normalize(),i}function Mo(e){return!!(e&&e.__CANCEL__)}function i1(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new xa}function q0(e){return i1(e),e.headers=Pn.from(e.headers),e.data=Co.call(e,e.transformRequest),(e.adapter||Fi.adapter)(e).then(function(n){return i1(e),n.data=Co.call(e,e.transformResponse,n),n.headers=Pn.from(n.headers),n},function(n){return Mo(n)||(i1(e),n&&n.response&&(n.response.data=Co.call(e,e.transformResponse,n.response),n.response.headers=Pn.from(n.response.headers))),Promise.reject(n)})}function ba(e,t){t=t||{};let r={};function n(h,k){return ye.isPlainObject(h)&&ye.isPlainObject(k)?ye.merge(h,k):ye.isPlainObject(k)?ye.merge({},k):ye.isArray(k)?k.slice():k}function a(h){if(ye.isUndefined(t[h])){if(!ye.isUndefined(e[h]))return n(void 0,e[h])}else return n(e[h],t[h])}function i(h){if(!ye.isUndefined(t[h]))return n(void 0,t[h])}function s(h){if(ye.isUndefined(t[h])){if(!ye.isUndefined(e[h]))return n(void 0,e[h])}else return n(void 0,t[h])}function m(h){if(h in t)return n(e[h],t[h]);if(h in e)return n(void 0,e[h])}let _={url:i,method:i,data:i,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:m};return ye.forEach(Object.keys(e).concat(Object.keys(t)),function(k){let re=_[k]||a,oe=re(k);ye.isUndefined(oe)&&re!==m||(r[k]=oe)}),r}var j0="1.1.3";var o1={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{o1[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});var Ff={};o1.transitional=function(t,r,n){function a(i,s){return"[Axios v"+j0+"] Transitional option '"+i+"'"+s+(n?". "+n:"")}return(i,s,m)=>{if(t===!1)throw new Rt(a(s," has been removed"+(r?" in "+r:"")),Rt.ERR_DEPRECATED);return r&&!Ff[s]&&(Ff[s]=!0,console.warn(a(s," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(i,s,m):!0}};function N_(e,t,r){if(typeof e!="object")throw new Rt("options must be an object",Rt.ERR_BAD_OPTION_VALUE);let n=Object.keys(e),a=n.length;for(;a-- >0;){let i=n[a],s=t[i];if(s){let m=e[i],_=m===void 0||s(m,i,e);if(_!==!0)throw new Rt("option "+i+" must be "+_,Rt.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new Rt("Unknown option "+i,Rt.ERR_BAD_OPTION)}}var z0={assertOptions:N_,validators:o1};var ya=z0.validators,Li=class{constructor(t){this.defaults=t,this.interceptors={request:new Ql,response:new Ql}}request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=ba(this.defaults,r);let{transitional:n,paramsSerializer:a}=r;n!==void 0&&z0.assertOptions(n,{silentJSONParsing:ya.transitional(ya.boolean),forcedJSONParsing:ya.transitional(ya.boolean),clarifyTimeoutError:ya.transitional(ya.boolean)},!1),a!==void 0&&z0.assertOptions(a,{encode:ya.function,serialize:ya.function},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let i=r.headers&&ye.merge(r.headers.common,r.headers[r.method]);i&&ye.forEach(["delete","get","head","post","put","patch","common"],function(D){delete r.headers[D]}),r.headers=new Pn(r.headers,i);let s=[],m=!0;this.interceptors.request.forEach(function(D){typeof D.runWhen=="function"&&D.runWhen(r)===!1||(m=m&&D.synchronous,s.unshift(D.fulfilled,D.rejected))});let _=[];this.interceptors.response.forEach(function(D){_.push(D.fulfilled,D.rejected)});let h,k=0,re;if(!m){let te=[q0.bind(this),void 0];for(te.unshift.apply(te,s),te.push.apply(te,_),re=te.length,h=Promise.resolve(r);k<re;)h=h.then(te[k++],te[k++]);return h}re=s.length;let oe=r;for(k=0;k<re;){let te=s[k++],D=s[k++];try{oe=te(oe)}catch(Se){D.call(this,Se);break}}try{h=q0.call(this,oe)}catch(te){return Promise.reject(te)}for(k=0,re=_.length;k<re;)h=h.then(_[k++],_[k++]);return h}getUri(t){t=ba(this.defaults,t);let r=wo(t.baseURL,t.url);return To(r,t.params,t.paramsSerializer)}};ye.forEach(["delete","get","head","options"],function(t){Li.prototype[t]=function(r,n){return this.request(ba(n||{},{method:t,url:r,data:(n||{}).data}))}});ye.forEach(["post","put","patch"],function(t){function r(n){return function(i,s,m){return this.request(ba(m||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:i,data:s}))}}Li.prototype[t]=r(),Li.prototype[t+"Form"]=r(!0)});var Bo=Li;var No=class{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(i){r=i});let n=this;this.promise.then(a=>{if(!n._listeners)return;let i=n._listeners.length;for(;i-- >0;)n._listeners[i](a);n._listeners=null}),this.promise.then=a=>{let i,s=new Promise(m=>{n.subscribe(m),i=m}).then(a);return s.cancel=function(){n.unsubscribe(i)},s},t(function(i,s,m){n.reason||(n.reason=new xa(i,s,m),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;let r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}static source(){let t;return{token:new No(function(a){t=a}),cancel:t}}},Lf=No;function s1(e){return function(r){return e.apply(null,r)}}function l1(e){return ye.isObject(e)&&e.isAxiosError===!0}function Df(e){let t=new Bo(e),r=go(Bo.prototype.request,t);return ye.extend(r,Bo.prototype,t,{allOwnKeys:!0}),ye.extend(r,t,null,{allOwnKeys:!0}),r.create=function(a){return Df(ba(e,a))},r}var Xr=Df(Fi);Xr.Axios=Bo;Xr.CanceledError=xa;Xr.CancelToken=Lf;Xr.isCancel=Mo;Xr.VERSION=j0;Xr.toFormData=Sa;Xr.AxiosError=Rt;Xr.Cancel=Xr.CanceledError;Xr.all=function(t){return Promise.all(t)};Xr.spread=s1;Xr.isAxiosError=l1;Xr.formToJSON=e=>H0(ye.isHTMLForm(e)?new FormData(e):e);var u1=Xr;var{Axios:NS,AxiosError:PS,CanceledError:FS,isCancel:LS,CancelToken:DS,VERSION:OS,all:kS,Cancel:HS,isAxiosError:US,spread:VS,toFormData:qS}=u1,Po=u1;var c1="https://proctoring-api.easyproctor.tech/api";async function f1(e){e&&(c1="https://proctoring-api-hml.easyproctor.tech/api")}async function ln(e){let{url:t,method:r,body:n,jwt:a}=e,i=await fetch(c1+t,{method:r,body:n!=null?JSON.stringify(n):void 0,headers:{Authorization:`Bearer ${a}`,"Content-Type":"application/json","Access-Control-Allow-Origin":"*"}});if(i.status>=400)throw"N\xE3o foi poss\xEDvel realizar a requisi\xE7\xE3o, tente novamente mais tarde";let s=i.headers.get("content-type");return(s?s.includes("application/json"):!1)?await i.json():null}async function d1(e){let{url:t,method:r,body:n,jwt:a}=e,i=await Po.request({url:c1+t,method:r,headers:{Authorization:`Bearer ${a}`,"Access-Control-Allow-Origin":"*"},data:n});if(i.status>=400)throw"N\xE3o foi poss\xEDvel realizar a requisi\xE7\xE3o, tente novamente mais tarde";return i}var Fo="",P_,F_=!0;function L_(e){ft.registerError(e,Fo)}async function v1(e,t,r,n){try{let{file:a,onProgress:i}=e;Fo+=`Upload: ${a.type}
22
+ `;let s=_=>{let h=_.loadedBytes/a.size*100;i&&i(Math.round(h))},m=await d1({url:"/AzureKey/signed-url",method:"POST",jwt:n,body:{objectName:a.name,contentType:a.type}});await Po.request({url:m.data,method:"PUT",headers:{"x-ms-blob-type":"BlockBlob"},data:a,onUploadProgress:_=>{s({loadedBytes:_.loaded})}})}catch(a){await D_(e,r,n).catch(async()=>{throw L_(t),a})}}async function D_(e,t,r){try{let{file:n,onProgress:a}=e,i=m=>{let _=m.loadedBytes/n.size*100;a&&a(Math.round(_))},s=await d1({url:"/AwsKey/signed-url",method:"POST",jwt:r,body:{objectName:n.name,contentType:n.type}});await Po.request({url:s.data,method:"PUT",headers:{"Content-Type":n.type},data:n,onUploadProgress:m=>{i({loadedBytes:m.loaded})}}).then(()=>{ln({url:"/Proctoring/aws-to-azure",method:"POST",jwt:r,body:{objectName:`${n.name}`}})})}catch(n){Fo+=`
30
23
  \u2022 Error on AWS upload
31
- `,dm+=a;try{yI(r)}catch(n){throw n}throw a}}function yI(r){try{let{file:e,onProgress:t}=r,a=URL.createObjectURL(e),n=document.createElement("a");document.body.appendChild(n),n.style.display="none",n.href=a,n.download=e.name,n.click(),window.URL.revokeObjectURL(a),pI=!1,clearInterval(uI),t&&t(Math.round(100))}catch(e){throw dm+=`
32
- \u2022 Error on machine download -> ${r.file.name}
33
- `,e}}async function ng(){let r=await navigator.mediaDevices.enumerateDevices();return{cameras:r.filter(t=>t.kind=="videoinput"&&t.deviceId).map(t=>({label:t.label||"Generic Device",id:t.deviceId})),microphones:r.filter(t=>t.kind=="audioinput"&&t.deviceId).map(t=>({label:t.label||"Generic Device",id:t.deviceId}))}}async function ig(){try{let r={audio:!0,video:!0};return(await navigator.mediaDevices.getUserMedia(r)).getTracks().forEach(t=>{t.stop()}),!0}catch{return!1}}async function mp(){return new Promise((r,e)=>{typeof PresentationRequest>"u"&&r(!1),new PresentationRequest("receiver.html").getAvailability().then(a=>{let n=a.value;a.addEventListener("change",function(){n=a.value}),setTimeout(()=>{r(n)},1e3)}).catch(a=>e(a))})}var xI="EasyProctorPlugin",gI=2;function sg(r){return new Promise((e,t)=>{let a=indexedDB.open(xI,gI);a.onupgradeneeded=()=>{a.result.createObjectStore("exams",{keyPath:"id"})},a.onerror=n=>{console.log(n),t("N\xE3o foi poss\xEDvel inicializar a biblioteca, por favor, entre em contato com o suporte e informe o erro acima")},a.onsuccess=()=>{let s=a.result.transaction(r,"readwrite").objectStore(r);e(s)}})}async function og(r,e){let t=await sg(r);return new Promise((a,n)=>{let i=t.put(e);i.onsuccess=()=>a(),i.onerror=s=>n(s)})}async function um(r){let e=await sg(r);return new Promise((t,a)=>{let n=e.getAll();n.onsuccess=()=>{let i=n.result[0];t(i)},n.onerror=i=>a(i)})}async function lg(r){let e=await sg(r);return new Promise((t,a)=>{let n=e.clear();n.onsuccess=()=>t(),n.onerror=i=>a(i)})}document.write('<script src="https://www.webrtc-experiment.com/EBML.js"><\/script>');var cg={cameraId:void 0,microphoneId:void 0,allowMultipleMonitors:!1,allowOnlyFirstMonitor:!0,captureScreen:!0,proctoringType:"IMAGE",insights:""},Ul="",h3=!0,Cn;function vI(r,e=!1){if(["examId","clientId","token"].forEach(P=>{let Z=P;if(!r[Z])throw Hg+": "+Z}),!navigator.mediaDevices.getDisplayMedia||!window.indexedDB)throw qg;function t(P){let Z=URL.createObjectURL(P),Re=document.createElement("a");document.body.appendChild(Re),Re.style.display="none",Re.href=Z,Re.download=P.name,Re.click(),window.URL.revokeObjectURL(Z)}let a=[],n=[],i="",s=0,o,l=[],c,p,M,S,O=null,E=0,q=20;function C(){a=[],n=[],i="",s=0,o=void 0,l=[]}async function W(P,Z={width:640,height:480}){if(!document.body)throw St.registerError(i,"Script n\xE3o chamado dentro do body!"),Lg;if(O!=null)throw St.registerError(i,Cm),Cm;let Re=null,ke=null,{cameraId:ne,microphoneId:ue,allowOnlyFirstMonitor:Ne,captureScreen:Se}=P;h3=Se;try{let Pe;if(Se)try{let{screenStream:Te,stopScreenRecorder:it}=await Bp(n,{allowOnlyFirstMonitor:Ne,onStopSharingScreenCallback:()=>S&&S()});ke=it,St.registerRecord(i,!0,"Start Screen Recorder"),Pe=Te}catch(Te){St.registerRecord(i,!1,`Start Screen Recorder Error: ${Te}`)}let Fe=new MediaStream;try{let Te=await wp(a,{cameraId:ne,microphoneId:ue},Z);Fe=Te.cameraStream,Re=await Te.stopCameraRecording,St.registerRecord(i,!0,"Start Camera Recorder")}catch(Te){St.registerRecord(i,!1,`Start Camera Recorder Error: ${Te}`)}try{yr(),St.registerRecord(i,!0,"Start Audio Recorder")}catch(Te){St.registerRecord(i,!1,`Start Audio Recorder Error: ${Te}`)}return Se?O=async function(){await Promise.all([Re(),ke()]),O=null}:O=async function(){await Promise.all([Re()]),O=null},{_screenStream:Pe,cameraStream:Fe,start:pr}}catch(Pe){throw O=null,ke&&await ke(),Re&&await Re(),a=[],n=[],Pe}}let ae=()=>{Date.now()-s>1e4&&(c&&c(),l.push({begin:Date.now()-s,alert:25,end:0}))},Ce=()=>{navigator.mediaDevices.ondevicechange=P=>{p&&p()}},et=()=>{let P=l[l.length-1];P&&(M&&M(),P.end=Date.now()-s)},gt=P=>{P&&(window.addEventListener("blur",ae),window.addEventListener("focus",et)),navigator.mediaDevices.ondevicechange=Ce},_t=()=>{window.removeEventListener("blur",ae),window.removeEventListener("focus",et)},dt=async P=>{let{buffer:Z,blob:Re}=await Cr(),ke=a,ne=Z,ue=n;if(!ke)throw St.registerError(i,js),js;let Ne=`EP_${i}_camera_${P}.webm`,Se=`EP_${i}_audio_${P}.mp3`,Pe=`EP_${i}_screen_${P}.webm`,Fe=new File([],"null"),Te=new File([],"null"),it;try{Fe=new File(ke,Ne,{type:"video/webm"}),St.registerRecord(i,!0,`Camera Recorder File
34
- name: ${Fe.name}
35
- size: ${Fe.size}`)}catch(lt){St.registerRecord(i,!1,`Camera Recorder File Error: ${lt}`)}try{Te=new File(ne,Se,{type:Re.type}),St.registerRecord(i,!0,`Audio Recorder File
36
- name: ${Te.name}
37
- size: ${Te.size}`)}catch(lt){St.registerRecord(i,!1,`Audio Recorder File Error: ${lt}`)}if(ue.length!=0)try{it=new File(ue,Pe,{type:"video/webm"}),St.registerRecord(i,!0,`Screen Recorder File
38
- name: ${it.name}
39
- size: ${it.size}`)}catch(lt){St.registerRecord(i,!1,`Screen Recorder File Error: ${lt}`)}return{cameraFile:Fe,audioFile:Te,screenFile:it}};async function Tt(){eg(e),Cn=await ln({url:"/AzureKey",method:"GET",jwt:r.token}),rg(Cn.account,Cn.containerName,Cn.sas),Ul=Cn.azureBlobUrl,OP(Cn.insights)}async function pr(P=cg,Z={width:640,height:480}){if(E>=Date.now()-q)throw Cm;E=Date.now();let{cameraId:Re,microphoneId:ke,allowOnlyFirstMonitor:ne=!0,allowMultipleMonitors:ue=!1,captureScreen:Ne=!0,proctoringType:Se}=P;try{await Tt()}catch(Fe){throw St.registerError(i,"Erro no initConfig!"),O&&O(),Fe}if(!ue&&await mp())throw St.registerError(i,"Multiplas telas detectadas!"),ec;await um("exams")!=null&&(await lg("exams"),O=null);try{let{cameraStream:Fe,_screenStream:Te}=await W({cameraId:Re,microphoneId:ke,allowOnlyFirstMonitor:ne,captureScreen:Ne,proctoringType:Se},Z),it;try{it=await ln({url:"/Proctoring/server-hour",method:"GET",jwt:r.token})}catch(pe){St.registerError(i,"N\xE3o foi poss\xEDvel requisitar a data do servidor!"+pe)}o=it?new Date(it.toString()):new Date,s=o.getTime();let lt=await ln({url:`/proctoring/start/${r.examId}`,method:"POST",body:{clientId:r.clientId,proctoringType:Se},jwt:r.token});return lt.cameraStream=Fe,lt.screenStream=Te,await og("exams",{id:lt.id,examId:r.examId,sessions:[]}),i=lt.id,St.registerStart(i,!0,""),gt(Ne),lt}catch(Fe){throw O&&O(),St.registerStart(i,!1,""+Fe),Fe}}async function yr(){let{start:P}=await zg();P()}async function Cr(){let{buffer:P,blob:Z}=await Ap();return{buffer:P,blob:Z}}async function Ia(P=cg,Z={width:640,height:480}){let{cameraId:Re,microphoneId:ke,allowOnlyFirstMonitor:ne=!0,captureScreen:ue=!0,proctoringType:Ne="VIDEO"}=P;ig(),yr();let{cameraStream:Se,_screenStream:Pe}=await W({cameraId:Re,microphoneId:ke,allowOnlyFirstMonitor:ne,captureScreen:ue,proctoringType:Ne},Z);return{cameraStream:Se,_screenStream:Pe}}async function oa(){S=void 0,O&&await O(),_t(),await lg("exams");let P=a,Z=n;return a=[],n=[],l=[],O=null,{cameraBlob:P,screenBlob:Z}}async function Lr(){let P=await um("exams");if(!O||!P)throw St.registerError(i,"Proctoring n\xE3o iniciado!"),js;S=void 0,await O();let Z;try{Z=await ln({url:"/Proctoring/server-hour",method:"GET",jwt:r.token})}catch(ue){St.registerError(i,"N\xE3o foi poss\xEDvel requisitar a data do servidor!"+ue)}let{cameraFile:Re,audioFile:ke,screenFile:ne}=await dt(P.sessions.length);P.sessions.push({alerts:l,cameraFile:Re,audioFile:ke,screenFile:ne,id:""+P.sessions.length+1,start:o?o.toISOString():(Z?new Date(Z.toString()):new Date).toISOString(),end:Z?new Date(Z.toString()).toISOString():new Date().toISOString()}),await og("exams",P),C()}async function Vr(P=cg,Z,Re={width:640,height:480}){C();let{cameraId:ke,microphoneId:ne,allowOnlyFirstMonitor:ue=!0,allowMultipleMonitors:Ne=!1,captureScreen:Se=!0,proctoringType:Pe}=P;try{await Tt()}catch(pe){throw St.registerError(i,"Erro no initConfig!"),pe}if(!Ne&&await mp())throw St.registerError(i,"Multiplas telas detectadas!"),ec;if(O)throw St.registerError(i,"Proctoring j\xE1 est\xE1 rodando!"),kg;let Fe=await um("exams");if(Fe){if(Fe&&Fe.examId!=Z)throw St.registerError(i,"Proctoring n\xE3o iniciado!"),js}else throw St.registerError(i,"Proctoring n\xE3o iniciado!"),js;let{cameraStream:Te,_screenStream:it}=await W({cameraId:ke,microphoneId:ne,allowOnlyFirstMonitor:ue,captureScreen:Se,proctoringType:Pe},Re),lt;try{lt=await ln({url:"/Proctoring/server-hour",method:"GET",jwt:r.token})}catch(pe){St.registerError(i,"N\xE3o foi poss\xEDvel requisitar a data do servidor!"+pe)}return i=Fe.id,o=lt?new Date(lt.toString()):new Date,s=o.getTime(),{cameraStream:Te,_screenStream:it}}async function Sr(P={}){let Z=0,{onProgress:Re}=P,ke=await um("exams");if(!ke)throw St.registerError(i,"Proctoring n\xE3o iniciado!"),js;let ne,ue=new File([],"null"),Ne=new File([],"null"),Se,Pe=[];try{try{Ul==""&&(eg(e),Cn=await ln({url:"/AzureKey",method:"GET",jwt:r.token}),rg(Cn.account,Cn.containerName,Cn.sas),Ul=Cn.azureBlobUrl)}catch{throw St.registerError(i,"Erro ao buscar credenciais!"),"Erro ao buscar credenciais!"}if(S=void 0,O){await O(),Z++;try{ne=await ln({url:"/Proctoring/server-hour",method:"GET",jwt:r.token})}catch(Dt){throw St.registerError(i,"N\xE3o foi poss\xEDvel requisitar a data do servidor!"+Dt),"N\xE3o foi poss\xEDvel requisitar a data do servidor! -> "+Dt}await Fe(),Z++,ke.sessions.push({alerts:l,cameraFile:ue,audioFile:Ne,screenFile:Se,id:""+ke.sessions.length+1,start:o?o.toISOString():(ne?new Date(ne.toString()):new Date).toISOString(),end:ne?new Date(ne.toString()).toISOString():new Date().toISOString()}),Z++}if(ke.sessions.length==0)throw St.registerError(i,"Nenhum v\xEDdeo gravado!"),Fg;let pe=ne?new Date(ne.toString()).toISOString():new Date().toISOString();it(),Z++;let qr=Pe.length,ra=Array(qr).fill(0),aa=()=>{Re&&Re(ra.reduce((Dt,Bs)=>Dt+=Bs,0)/qr)},fa=[];ke.sessions.forEach(Dt=>{fa.push({alerts:Dt.alerts,id:Dt.id,end:Dt.end,start:Dt.start,videoCameraUrl:Dt.cameraFile.name,audioCameraUrl:Dt.audioFile.name,videoScreenUrl:Dt.screenFile?Dt.screenFile.name:""})});try{await ln({url:"/proctoring/save-screen",method:"POST",jwt:r.token,body:{proctoringId:i,alerts:[...fa[fa.length-1].alerts]}})}catch(Dt){throw St.registerFinish(i,!1,"save-screen error: "+Dt),"save-screen error: "+Dt}try{await ln({url:`/proctoring/finish/${r.examId}`,method:"POST",body:{endDate:pe,videoCameraUrl:`${Ul}/`+fa[fa.length-1].videoCameraUrl,audioCameraUrl:`${Ul}/`+fa[fa.length-1].audioCameraUrl,videoScreenUrl:h3?`${Ul}/`+fa[fa.length-1].videoScreenUrl:""},jwt:r.token}),St.registerFinish(i,!0,"")}catch(Dt){St.registerFinish(i,!1,"finish error: "+Dt)}if(lt(),ot()==="1.0.0.0")try{St.registerUploadVideo(i,!0,"Starting upload");let Dt=performance.now(),Bs=Pe.map((jl,Ti)=>(St.registerUploadVideo(i,!0,`file: ${jl.name}, size ${jl.size}`),ag({file:jl,onProgress:dp=>{ra[Ti]=dp,aa()}},i,Cn,r.token))),pm=performance.now();await Promise.all(Bs);let Ei=pm-Dt;St.registerUploadVideo(i,!0,"Finish upload",Ei)}catch(Dt){St.registerUploadVideo(i,!1,""+Dt)}}catch(pe){switch(console.log(`Erro no fluxo de finish, iniciando download de backup
40
- Error: `+pe),St.registerError(i,`Erro no fluxo de finish, iniciando download de backup
41
- `+pe),Z){case 0:O&&await O();case 1:await Fe();case 2:Te();case 3:it();case 4:lt()}console.log("Enviando tracker de error"),St.registerUploadVideo(i,!1,"Download feito como backup no Catch")}a=[],n=[],l=[],O=null;async function Fe(){let pe=await dt(ke.sessions.length);ue=pe.cameraFile,Ne=pe.audioFile,Se=pe.screenFile}function Te(){ke.sessions.push({alerts:l,cameraFile:ue,audioFile:Ne,screenFile:Se,id:""+ke.sessions.length+1,start:o?o.toISOString():new Date().toISOString(),end:new Date().toISOString()}),_t()}function it(){ke.sessions.forEach(pe=>{pe.cameraFile&&Pe.push(pe.cameraFile),pe.audioFile&&Pe.push(pe.audioFile),pe.screenFile!=null&&Pe.push(pe.screenFile)})}function lt(){if(ot()!=="1.0.0.0")try{St.registerUploadVideo(i,!0,"Starting download"),Pe.map(pe=>{St.registerUploadVideo(i,!0,`file: ${pe.name}, size ${pe.size}`),t(pe)}),Re&&Re(Math.round(100)),St.registerUploadVideo(i,!0,"Finish download")}catch(pe){console.log("Enviando tracker de error"),St.registerUploadVideo(i,!1,"erro no download "+pe)}}}function At(P){M=P}function tr(P){S=P}function Qt(P){c=P}function $t(P){p=P}let ot=()=>{let P=window.navigator.userAgent.split("SEB/");return P.length>1?P[1]:"1.0.0.0"};return{start:pr,startAudio:yr,checkDevices:Ia,finish:Sr,finishAudio:Cr,closeCheckDevices:oa,pause:Lr,resume:Vr,onFocus:At,onLostFocus:Qt,onChangeDevices:$t,enumarateDevices:ng,checkPermissions:ig,checkIfhasMultipleMonitors:mp,onStopSharingScreen:tr}}typeof window<"u"&&(window.useProctoring=vI);})();
24
+ `,Fo+=n;try{O_(e)}catch(a){throw a}throw n}}function O_(e){try{let{file:t,onProgress:r}=e,n=URL.createObjectURL(t),a=document.createElement("a");document.body.appendChild(a),a.style.display="none",a.href=n,a.download=t.name,a.click(),window.URL.revokeObjectURL(n),F_=!1,clearInterval(P_),r&&r(Math.round(100))}catch(t){throw Fo+=`
25
+ \u2022 Error on machine download -> ${e.file.name}
26
+ `,t}}async function _1(){let e=await navigator.mediaDevices.enumerateDevices();return{cameras:e.filter(r=>r.kind=="videoinput"&&r.deviceId).map(r=>({label:r.label||"Generic Device",id:r.deviceId})),microphones:e.filter(r=>r.kind=="audioinput"&&r.deviceId).map(r=>({label:r.label||"Generic Device",id:r.deviceId}))}}async function m1(){try{let e={audio:!0,video:!0};return(await navigator.mediaDevices.getUserMedia(e)).getTracks().forEach(r=>{r.stop()}),!0}catch{return!1}}async function G0(){return new Promise((e,t)=>{typeof PresentationRequest>"u"&&e(!1),new PresentationRequest("receiver.html").getAvailability().then(n=>{let a=n.value;n.addEventListener("change",function(){a=n.value}),setTimeout(()=>{e(a)},1e3)}).catch(n=>t(n))})}var k_="EasyProctorPlugin",H_=2;function h1(e){return new Promise((t,r)=>{let n=indexedDB.open(k_,H_);n.onupgradeneeded=()=>{n.result.createObjectStore("exams",{keyPath:"id"})},n.onerror=a=>{console.log(a),r("N\xE3o foi poss\xEDvel inicializar a biblioteca, por favor, entre em contato com o suporte e informe o erro acima")},n.onsuccess=()=>{let s=n.result.transaction(e,"readwrite").objectStore(e);t(s)}})}async function p1(e,t){let r=await h1(e);return new Promise((n,a)=>{let i=r.put(t);i.onsuccess=()=>n(),i.onerror=s=>a(s)})}async function Lo(e){let t=await h1(e);return new Promise((r,n)=>{let a=t.getAll();a.onsuccess=()=>{let i=a.result[0];r(i)},a.onerror=i=>n(i)})}async function S1(e){let t=await h1(e);return new Promise((r,n)=>{let a=t.clear();a.onsuccess=()=>r(),a.onerror=i=>n(i)})}document.write('<script src="https://www.webrtc-experiment.com/EBML.js"><\/script>');var x1={cameraId:void 0,microphoneId:void 0,allowMultipleMonitors:!1,allowOnlyFirstMonitor:!0,captureScreen:!0,proctoringType:"IMAGE",insights:""},Di="",Of=!0,Oi;function U_(e,t=!1){if(["examId","clientId","token"].forEach(g=>{let K=g;if(!e[K])throw Z1+": "+K}),!navigator.mediaDevices.getDisplayMedia||!window.indexedDB)throw $1;function r(g){let K=URL.createObjectURL(g),we=document.createElement("a");document.body.appendChild(we),we.style.display="none",we.href=K,we.download=g.name,we.click(),window.URL.revokeObjectURL(K)}let n=[],a=[],i="",s=0,m,_=[],h,k,re,oe,te=null,D=0,Se=20;function P(){n=[],a=[],i="",s=0,m=void 0,_=[]}async function se(g,K={width:640,height:480}){if(!document.body)throw ft.registerError(i,"Script n\xE3o chamado dentro do body!"),Y1;if(te!=null)throw ft.registerError(i,Wo),Wo;let we=null,He=null,{cameraId:Q,microphoneId:fe,allowOnlyFirstMonitor:Ee,captureScreen:ge}=g;Of=ge;try{let Te;if(ge)try{let{screenStream:Ae,stopScreenRecorder:$e}=await vs(a,{allowOnlyFirstMonitor:Ee,onStopSharingScreenCallback:()=>oe&&oe()});He=$e,ft.registerRecord(i,!0,"Start Screen Recorder"),Te=Ae}catch(Ae){ft.registerRecord(i,!1,`Start Screen Recorder Error: ${Ae}`)}let Ue=new MediaStream;try{let Ae=await us(n,{cameraId:Q,microphoneId:fe},K);Ue=Ae.cameraStream,we=await Ae.stopCameraRecording,ft.registerRecord(i,!0,"Start Camera Recorder")}catch(Ae){ft.registerRecord(i,!1,`Start Camera Recorder Error: ${Ae}`)}try{zt(),ft.registerRecord(i,!0,"Start Audio Recorder")}catch(Ae){ft.registerRecord(i,!1,`Start Audio Recorder Error: ${Ae}`)}return ge?te=async function(){await Promise.all([we(),He()]),te=null}:te=async function(){await Promise.all([we()]),te=null},{_screenStream:Te,cameraStream:Ue,start:Vt}}catch(Te){throw te=null,He&&await He(),we&&await we(),n=[],a=[],Te}}let ue=()=>{Date.now()-s>1e4&&(h&&h(),_.push({begin:Date.now()-s,alert:25,end:0}))},De=()=>{navigator.mediaDevices.ondevicechange=g=>{k&&k()}},et=()=>{let g=_[_.length-1];g&&(re&&re(),g.end=Date.now()-s)},ut=g=>{g&&(window.addEventListener("blur",ue),window.addEventListener("focus",et)),navigator.mediaDevices.ondevicechange=De},ht=()=>{window.removeEventListener("blur",ue),window.removeEventListener("focus",et)},st=async g=>{let{buffer:K,blob:we}=await Zt(),He=n,Q=K,fe=a;if(!He)throw ft.registerError(i,Na),Na;let Ee=`EP_${i}_camera_${g}.webm`,ge=`EP_${i}_audio_${g}.mp3`,Te=`EP_${i}_screen_${g}.webm`,Ue=new File([],"null"),Ae=new File([],"null"),$e;try{Ue=new File(He,Ee,{type:"video/webm"}),ft.registerRecord(i,!0,`Camera Recorder File
27
+ name: ${Ue.name}
28
+ size: ${Ue.size}`)}catch(Qe){ft.registerRecord(i,!1,`Camera Recorder File Error: ${Qe}`)}try{Ae=new File(Q,ge,{type:we.type}),ft.registerRecord(i,!0,`Audio Recorder File
29
+ name: ${Ae.name}
30
+ size: ${Ae.size}`)}catch(Qe){ft.registerRecord(i,!1,`Audio Recorder File Error: ${Qe}`)}if(fe.length!=0)try{$e=new File(fe,Te,{type:"video/webm"}),ft.registerRecord(i,!0,`Screen Recorder File
31
+ name: ${$e.name}
32
+ size: ${$e.size}`)}catch(Qe){ft.registerRecord(i,!1,`Screen Recorder File Error: ${Qe}`)}return{cameraFile:Ue,audioFile:Ae,screenFile:$e}};async function yt(){f1(t),Oi=await ln({url:"/AzureKey",method:"GET",jwt:e.token}),Di=Oi.azureBlobUrl,nf(Oi.insights)}async function Vt(g=x1,K={width:640,height:480}){if(D>=Date.now()-Se)throw Wo;D=Date.now();let{cameraId:we,microphoneId:He,allowOnlyFirstMonitor:Q=!0,allowMultipleMonitors:fe=!1,captureScreen:Ee=!0,proctoringType:ge}=g;try{await yt()}catch(Ue){throw ft.registerError(i,"Erro no initConfig!"),te&&te(),Ue}if(!fe&&await G0())throw ft.registerError(i,"Multiplas telas detectadas!"),Yi;await Lo("exams")!=null&&(await S1("exams"),te=null);try{let{cameraStream:Ue,_screenStream:Ae}=await se({cameraId:we,microphoneId:He,allowOnlyFirstMonitor:Q,captureScreen:Ee,proctoringType:ge},K),$e;try{$e=await ln({url:"/Proctoring/server-hour",method:"GET",jwt:e.token})}catch(de){ft.registerError(i,"N\xE3o foi poss\xEDvel requisitar a data do servidor!"+de)}m=$e?new Date($e.toString()):new Date,s=m.getTime();let Qe=await ln({url:`/proctoring/start/${e.examId}`,method:"POST",body:{clientId:e.clientId,proctoringType:ge},jwt:e.token});return Qe.cameraStream=Ue,Qe.screenStream=Ae,await p1("exams",{id:Qe.id,examId:e.examId,sessions:[]}),i=Qe.id,ft.registerStart(i,!0,""),ut(Ee),Qe}catch(Ue){throw te&&te(),ft.registerStart(i,!1,""+Ue),Ue}}async function zt(){let{start:g}=await W1();g()}async function Zt(){let{buffer:g,blob:K}=await ds();return{buffer:g,blob:K}}async function kr(g=x1,K={width:640,height:480}){let{cameraId:we,microphoneId:He,allowOnlyFirstMonitor:Q=!0,captureScreen:fe=!0,proctoringType:Ee="VIDEO"}=g;m1(),zt();let{cameraStream:ge,_screenStream:Te}=await se({cameraId:we,microphoneId:He,allowOnlyFirstMonitor:Q,captureScreen:fe,proctoringType:Ee},K);return{cameraStream:ge,_screenStream:Te}}async function Tr(){oe=void 0,te&&await te(),ht(),await S1("exams");let g=n,K=a;return n=[],a=[],_=[],te=null,{cameraBlob:g,screenBlob:K}}async function ar(){let g=await Lo("exams");if(!te||!g)throw ft.registerError(i,"Proctoring n\xE3o iniciado!"),Na;oe=void 0,await te();let K;try{K=await ln({url:"/Proctoring/server-hour",method:"GET",jwt:e.token})}catch(fe){ft.registerError(i,"N\xE3o foi poss\xEDvel requisitar a data do servidor!"+fe)}let{cameraFile:we,audioFile:He,screenFile:Q}=await st(g.sessions.length);g.sessions.push({alerts:_,cameraFile:we,audioFile:He,screenFile:Q,id:""+g.sessions.length+1,start:m?m.toISOString():(K?new Date(K.toString()):new Date).toISOString(),end:K?new Date(K.toString()).toISOString():new Date().toISOString()}),await p1("exams",g),P()}async function fr(g=x1,K,we={width:640,height:480}){P();let{cameraId:He,microphoneId:Q,allowOnlyFirstMonitor:fe=!0,allowMultipleMonitors:Ee=!1,captureScreen:ge=!0,proctoringType:Te}=g;try{await yt()}catch(de){throw ft.registerError(i,"Erro no initConfig!"),de}if(!Ee&&await G0())throw ft.registerError(i,"Multiplas telas detectadas!"),Yi;if(te)throw ft.registerError(i,"Proctoring j\xE1 est\xE1 rodando!"),J1;let Ue=await Lo("exams");if(Ue){if(Ue&&Ue.examId!=K)throw ft.registerError(i,"Proctoring n\xE3o iniciado!"),Na}else throw ft.registerError(i,"Proctoring n\xE3o iniciado!"),Na;let{cameraStream:Ae,_screenStream:$e}=await se({cameraId:He,microphoneId:Q,allowOnlyFirstMonitor:fe,captureScreen:ge,proctoringType:Te},we),Qe;try{Qe=await ln({url:"/Proctoring/server-hour",method:"GET",jwt:e.token})}catch(de){ft.registerError(i,"N\xE3o foi poss\xEDvel requisitar a data do servidor!"+de)}return i=Ue.id,m=Qe?new Date(Qe.toString()):new Date,s=m.getTime(),{cameraStream:Ae,_screenStream:$e}}async function Wt(g={}){let K=0,{onProgress:we}=g,He=await Lo("exams");if(!He)throw ft.registerError(i,"Proctoring n\xE3o iniciado!"),Na;let Q,fe=new File([],"null"),Ee=new File([],"null"),ge,Te=[];try{try{Di==""&&(f1(t),Oi=await ln({url:"/AzureKey",method:"GET",jwt:e.token}),Di=Oi.azureBlobUrl)}catch{throw ft.registerError(i,"Erro ao buscar credenciais!"),"Erro ao buscar credenciais!"}if(oe=void 0,te){await te(),K++;try{Q=await ln({url:"/Proctoring/server-hour",method:"GET",jwt:e.token})}catch(Et){throw ft.registerError(i,"N\xE3o foi poss\xEDvel requisitar a data do servidor!"+Et),"N\xE3o foi poss\xEDvel requisitar a data do servidor! -> "+Et}await Ue(),K++,He.sessions.push({alerts:_,cameraFile:fe,audioFile:Ee,screenFile:ge,id:""+He.sessions.length+1,start:m?m.toISOString():(Q?new Date(Q.toString()):new Date).toISOString(),end:Q?new Date(Q.toString()).toISOString():new Date().toISOString()}),K++}if(He.sessions.length==0)throw ft.registerError(i,"Nenhum v\xEDdeo gravado!"),eu;let de=Q?new Date(Q.toString()).toISOString():new Date().toISOString();$e(),K++;let ir=Te.length,br=Array(ir).fill(0),yr=()=>{we&&we(br.reduce((Et,ga)=>Et+=ga,0)/ir)},Rr=[];He.sessions.forEach(Et=>{Rr.push({alerts:Et.alerts,id:Et.id,end:Et.end,start:Et.start,videoCameraUrl:Et.cameraFile.name,audioCameraUrl:Et.audioFile.name,videoScreenUrl:Et.screenFile?Et.screenFile.name:""})});try{await ln({url:"/proctoring/save-screen",method:"POST",jwt:e.token,body:{proctoringId:i,alerts:[...Rr[Rr.length-1].alerts]}})}catch(Et){throw ft.registerFinish(i,!1,"save-screen error: "+Et),"save-screen error: "+Et}try{await ln({url:`/proctoring/finish/${e.examId}`,method:"POST",body:{endDate:de,videoCameraUrl:`${Di}/`+Rr[Rr.length-1].videoCameraUrl,audioCameraUrl:`${Di}/`+Rr[Rr.length-1].audioCameraUrl,videoScreenUrl:Of?`${Di}/`+Rr[Rr.length-1].videoScreenUrl:""},jwt:e.token}),ft.registerFinish(i,!0,"")}catch(Et){ft.registerFinish(i,!1,"finish error: "+Et)}if(Qe(),Ze()==="1.0.0.0")try{ft.registerUploadVideo(i,!0,"Starting upload");let Et=performance.now(),ga=Te.map((ki,Gn)=>(ft.registerUploadVideo(i,!0,`file: ${ki.name}, size ${ki.size}`),v1({file:ki,onProgress:X0=>{br[Gn]=X0,yr()}},i,Oi,e.token))),Do=performance.now();await Promise.all(ga);let zn=Do-Et;ft.registerUploadVideo(i,!0,"Finish upload",zn)}catch(Et){ft.registerUploadVideo(i,!1,""+Et)}}catch(de){switch(console.log(`Erro no fluxo de finish, iniciando download de backup
33
+ Error: `+de),ft.registerError(i,`Erro no fluxo de finish, iniciando download de backup
34
+ `+de),K){case 0:te&&await te();case 1:await Ue();case 2:Ae();case 3:$e();case 4:Qe()}console.log("Enviando tracker de error"),ft.registerUploadVideo(i,!1,"Download feito como backup no Catch")}n=[],a=[],_=[],te=null;async function Ue(){let de=await st(He.sessions.length);fe=de.cameraFile,Ee=de.audioFile,ge=de.screenFile}function Ae(){He.sessions.push({alerts:_,cameraFile:fe,audioFile:Ee,screenFile:ge,id:""+He.sessions.length+1,start:m?m.toISOString():new Date().toISOString(),end:new Date().toISOString()}),ht()}function $e(){He.sessions.forEach(de=>{de.cameraFile&&Te.push(de.cameraFile),de.audioFile&&Te.push(de.audioFile),de.screenFile!=null&&Te.push(de.screenFile)})}function Qe(){if(Ze()!=="1.0.0.0")try{ft.registerUploadVideo(i,!0,"Starting download"),Te.map(de=>{ft.registerUploadVideo(i,!0,`file: ${de.name}, size ${de.size}`),r(de)}),we&&we(Math.round(100)),ft.registerUploadVideo(i,!0,"Finish download")}catch(de){console.log("Enviando tracker de error"),ft.registerUploadVideo(i,!1,"erro no download "+de)}}}function pt(g){re=g}function Lt(g){oe=g}function Bt(g){h=g}function Ct(g){k=g}let Ze=()=>{let g=window.navigator.userAgent.split("SEB/");return g.length>1?g[1]:"1.0.0.0"};return{start:Vt,startAudio:zt,checkDevices:kr,finish:Wt,finishAudio:Zt,closeCheckDevices:Tr,pause:ar,resume:fr,onFocus:pt,onLostFocus:Bt,onChangeDevices:Ct,enumarateDevices:_1,checkPermissions:m1,checkIfhasMultipleMonitors:G0,onStopSharingScreen:Lt}}typeof window<"u"&&(window.useProctoring=U_);})();
42
35
  /*!
43
36
  * Microsoft Dynamic Proto Utility, 1.1.4
44
37
  * Copyright (c) Microsoft and contributors. All rights reserved.
45
38
  */
46
- /*! *****************************************************************************
47
- Copyright (c) Microsoft Corporation.
48
-
49
- Permission to use, copy, modify, and/or distribute this software for any
50
- purpose with or without fee is hereby granted.
51
-
52
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
53
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
54
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
55
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
56
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
57
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
58
- PERFORMANCE OF THIS SOFTWARE.
59
- ***************************************************************************** */