From a8bbcb1aabe1f0af1ed893671d67039d134a3ad8 Mon Sep 17 00:00:00 2001 From: 0o-de-lally <1364012+0o-de-lally@users.noreply.github.com> Date: Tue, 12 Sep 2023 13:41:00 -0400 Subject: [PATCH] try with input "local" --- action.yml | 3 ++ dist/post_run/index.js | 2 +- dist/setup/index.js | 2 +- src/cache.ts | 4 ++- src/post_run.ts | 8 ++++-- src/setup.ts | 64 ++++++++++++++++++++++-------------------- 6 files changed, 47 insertions(+), 36 deletions(-) diff --git a/action.yml b/action.yml index ea88609..654937c 100644 --- a/action.yml +++ b/action.yml @@ -8,6 +8,9 @@ inputs: token: description: "Used to pull the latest release from sccache. When running this action outside of github.com, you have to pass a personal access token for github.com." default: ${{ github.server_url == 'https://github.com' && github.token || '' }} + local: + description: "Creates a single cache artifact. Uses the local cache of the runner, saving and restoring. Will not create duplicate caches, only a single `sccache` bundle" + default: "true" runs: using: "node16" main: "dist/setup/index.js" diff --git a/dist/post_run/index.js b/dist/post_run/index.js index ac21167..c224902 100644 --- a/dist/post_run/index.js +++ b/dist/post_run/index.js @@ -1,4 +1,4 @@ -(()=>{var __webpack_modules__={3782:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.deduplicate=t.pleaseRestore=t.pleaseSave=void 0;const o=a(7799);const p=n(a(2186));const l=n(a(5438));const d="sccache";const pleaseSave=()=>s(void 0,void 0,void 0,(function*(){const e=process.env.SCCACHE_CACHE_DIR;console.log(e);if(!e){console.log(`no sccache dir found in SCCACHE_CACHE_DIR ${e}`);return}yield(0,o.saveCache)([e],d)}));t.pleaseSave=pleaseSave;const pleaseRestore=()=>s(void 0,void 0,void 0,(function*(){console.log("restore sccache files");const e=process.env.SCCACHE_CACHE_DIR;console.log(e);if(!e){console.log(`no sccache dir found in SCCACHE_CACHE_DIR ${e}`);return}yield(0,o.restoreCache)([e],d).then((e=>{console.log(`successfully restored cache: ${JSON.stringify(e)}`)}))}));t.pleaseRestore=pleaseRestore;const deduplicate=()=>s(void 0,void 0,void 0,(function*(){console.log("trying to deduplicate cache");const e=p.getInput("token",{required:true});const t=l.getOctokit(e);const a=yield t.rest.actions.deleteActionsCacheByKey({owner:l.context.repo.owner,repo:l.context.repo.repo,key:d}).then((()=>"successfully deleted cache")).catch((e=>{console.log(`catch: ${e}`);return"nothing to delete"}));console.log(`delete cache api response: ${a}`)}));t.deduplicate=deduplicate},6735:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});const o=n(a(2186));const p=a(3782);const l=a(2802);const postRun=()=>s(void 0,void 0,void 0,(function*(){yield(0,l.show_stats)();yield(0,p.deduplicate)();yield(0,p.pleaseSave)()}));postRun().catch((e=>{o.error(e);o.setFailed(e.message)}))},2802:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.show_stats=void 0;const o=n(a(2186));const p=n(a(1514));function show_stats(){return s(this,void 0,void 0,(function*(){o.debug("show stats");const e={stdout:e=>{t.push(e.toString())}};const t=[];yield p.getExecOutput(`${process.env.SCCACHE_PATH}`,["--show-stats"],{listeners:e})}))}t.show_stats=show_stats},7799:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.saveCache=t.restoreCache=t.isFeatureAvailable=t.ReserveCacheError=t.ValidationError=void 0;const o=n(a(2186));const p=n(a(1017));const l=n(a(1518));const d=n(a(8245));const c=a(6490);class ValidationError extends Error{constructor(e){super(e);this.name="ValidationError";Object.setPrototypeOf(this,ValidationError.prototype)}}t.ValidationError=ValidationError;class ReserveCacheError extends Error{constructor(e){super(e);this.name="ReserveCacheError";Object.setPrototypeOf(this,ReserveCacheError.prototype)}}t.ReserveCacheError=ReserveCacheError;function checkPaths(e){if(!e||e.length===0){throw new ValidationError(`Path Validation Error: At least one directory or file path is required`)}}function checkKey(e){if(e.length>512){throw new ValidationError(`Key Validation Error: ${e} cannot be larger than 512 characters.`)}const t=/^[^,]*$/;if(!t.test(e)){throw new ValidationError(`Key Validation Error: ${e} cannot contain commas.`)}}function isFeatureAvailable(){return!!process.env["ACTIONS_CACHE_URL"]}t.isFeatureAvailable=isFeatureAvailable;function restoreCache(e,t,a,r,i=false){return s(this,void 0,void 0,(function*(){checkPaths(e);a=a||[];const n=[t,...a];o.debug("Resolved Keys:");o.debug(JSON.stringify(n));if(n.length>10){throw new ValidationError(`Key Validation Error: Keys are limited to a maximum of 10.`)}for(const e of n){checkKey(e)}const s=yield l.getCompressionMethod();let m="";try{const t=yield d.getCacheEntry(n,e,{compressionMethod:s,enableCrossOsArchive:i});if(!(t===null||t===void 0?void 0:t.archiveLocation)){return undefined}if(r===null||r===void 0?void 0:r.lookupOnly){o.info("Lookup only - skipping download");return t.cacheKey}m=p.join(yield l.createTempDirectory(),l.getCacheFileName(s));o.debug(`Archive Path: ${m}`);yield d.downloadCache(t.archiveLocation,m,r);if(o.isDebug()){yield(0,c.listTar)(m,s)}const a=l.getArchiveFileSizeInBytes(m);o.info(`Cache Size: ~${Math.round(a/(1024*1024))} MB (${a} B)`);yield(0,c.extractTar)(m,s);o.info("Cache restored successfully");return t.cacheKey}catch(e){const t=e;if(t.name===ValidationError.name){throw e}else{o.warning(`Failed to restore: ${e.message}`)}}finally{try{yield l.unlinkFile(m)}catch(e){o.debug(`Failed to delete archive: ${e}`)}}return undefined}))}t.restoreCache=restoreCache;function saveCache(e,t,a,r=false){var i,n,m,u,h;return s(this,void 0,void 0,(function*(){checkPaths(e);checkKey(t);const s=yield l.getCompressionMethod();let g=-1;const y=yield l.resolvePaths(e);o.debug("Cache Paths:");o.debug(`${JSON.stringify(y)}`);if(y.length===0){throw new Error(`Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved.`)}const v=yield l.createTempDirectory();const b=p.join(v,l.getCacheFileName(s));o.debug(`Archive Path: ${b}`);try{yield(0,c.createTar)(v,y,s);if(o.isDebug()){yield(0,c.listTar)(b,s)}const p=10*1024*1024*1024;const x=l.getArchiveFileSizeInBytes(b);o.debug(`File Size: ${x}`);if(x>p&&!l.isGhes()){throw new Error(`Cache size of ~${Math.round(x/(1024*1024))} MB (${x} B) is over the 10GB limit, not saving cache.`)}o.debug("Reserving Cache");const w=yield d.reserveCache(t,e,{compressionMethod:s,enableCrossOsArchive:r,cacheSize:x});if((i=w===null||w===void 0?void 0:w.result)===null||i===void 0?void 0:i.cacheId){g=(n=w===null||w===void 0?void 0:w.result)===null||n===void 0?void 0:n.cacheId}else if((w===null||w===void 0?void 0:w.statusCode)===400){throw new Error((u=(m=w===null||w===void 0?void 0:w.error)===null||m===void 0?void 0:m.message)!==null&&u!==void 0?u:`Cache size of ~${Math.round(x/(1024*1024))} MB (${x} B) is over the data cap limit, not saving cache.`)}else{throw new ReserveCacheError(`Unable to reserve cache with key ${t}, another job may be creating this cache. More details: ${(h=w===null||w===void 0?void 0:w.error)===null||h===void 0?void 0:h.message}`)}o.debug(`Saving Cache (ID: ${g})`);yield d.saveCache(g,b,a)}catch(e){const t=e;if(t.name===ValidationError.name){throw e}else if(t.name===ReserveCacheError.name){o.info(`Failed to save: ${t.message}`)}else{o.warning(`Failed to save: ${t.message}`)}}finally{try{yield l.unlinkFile(b)}catch(e){o.debug(`Failed to delete archive: ${e}`)}}return g}))}t.saveCache=saveCache},8245:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.saveCache=t.reserveCache=t.downloadCache=t.getCacheEntry=t.getCacheVersion=void 0;const o=n(a(2186));const p=a(6255);const l=a(5526);const d=n(a(6113));const c=n(a(7147));const m=a(7310);const u=n(a(1518));const h=a(5500);const g=a(6215);const y=a(3981);const v="1.0";function getCacheApiUrl(e){const t=process.env["ACTIONS_CACHE_URL"]||"";if(!t){throw new Error("Cache Service Url not found, unable to restore cache.")}const a=`${t}_apis/artifactcache/${e}`;o.debug(`Resource Url: ${a}`);return a}function createAcceptHeader(e,t){return`${e};api-version=${t}`}function getRequestOptions(){const e={headers:{Accept:createAcceptHeader("application/json","6.0-preview.1")}};return e}function createHttpClient(){const e=process.env["ACTIONS_RUNTIME_TOKEN"]||"";const t=new l.BearerCredentialHandler(e);return new p.HttpClient("actions/cache",[t],getRequestOptions())}function getCacheVersion(e,t,a=false){const r=e;if(t){r.push(t)}if(process.platform==="win32"&&!a){r.push("windows-only")}r.push(v);return d.createHash("sha256").update(r.join("|")).digest("hex")}t.getCacheVersion=getCacheVersion;function getCacheEntry(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();const i=getCacheVersion(t,a===null||a===void 0?void 0:a.compressionMethod,a===null||a===void 0?void 0:a.enableCrossOsArchive);const n=`cache?keys=${encodeURIComponent(e.join(","))}&version=${i}`;const p=yield(0,y.retryTypedResponse)("getCacheEntry",(()=>s(this,void 0,void 0,(function*(){return r.getJson(getCacheApiUrl(n))}))));if(p.statusCode===204){if(o.isDebug()){yield printCachesListForDiagnostics(e[0],r,i)}return null}if(!(0,y.isSuccessStatusCode)(p.statusCode)){throw new Error(`Cache service responded with ${p.statusCode}`)}const l=p.result;const d=l===null||l===void 0?void 0:l.archiveLocation;if(!d){throw new Error("Cache not found.")}o.setSecret(d);o.debug(`Cache Result:`);o.debug(JSON.stringify(l));return l}))}t.getCacheEntry=getCacheEntry;function printCachesListForDiagnostics(e,t,a){return s(this,void 0,void 0,(function*(){const r=`caches?key=${encodeURIComponent(e)}`;const i=yield(0,y.retryTypedResponse)("listCache",(()=>s(this,void 0,void 0,(function*(){return t.getJson(getCacheApiUrl(r))}))));if(i.statusCode===200){const t=i.result;const r=t===null||t===void 0?void 0:t.totalCount;if(r&&r>0){o.debug(`No matching cache found for cache key '${e}', version '${a} and scope ${process.env["GITHUB_REF"]}. There exist one or more cache(s) with similar key but they have different version or scope. See more info on cache matching here: https://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows#matching-a-cache-key \nOther caches with similar key:`);for(const e of(t===null||t===void 0?void 0:t.artifactCaches)||[]){o.debug(`Cache Key: ${e===null||e===void 0?void 0:e.cacheKey}, Cache Version: ${e===null||e===void 0?void 0:e.cacheVersion}, Cache Scope: ${e===null||e===void 0?void 0:e.scope}, Cache Created: ${e===null||e===void 0?void 0:e.creationTime}`)}}}}))}function downloadCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=new m.URL(e);const i=(0,g.getDownloadOptions)(a);if(r.hostname.endsWith(".blob.core.windows.net")){if(i.useAzureSdk){yield(0,h.downloadCacheStorageSDK)(e,t,i)}else if(i.concurrentBlobDownloads){yield(0,h.downloadCacheHttpClientConcurrent)(e,t,i)}else{yield(0,h.downloadCacheHttpClient)(e,t)}}else{yield(0,h.downloadCacheHttpClient)(e,t)}}))}t.downloadCache=downloadCache;function reserveCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();const i=getCacheVersion(t,a===null||a===void 0?void 0:a.compressionMethod,a===null||a===void 0?void 0:a.enableCrossOsArchive);const n={key:e,version:i,cacheSize:a===null||a===void 0?void 0:a.cacheSize};const o=yield(0,y.retryTypedResponse)("reserveCache",(()=>s(this,void 0,void 0,(function*(){return r.postJson(getCacheApiUrl("caches"),n)}))));return o}))}t.reserveCache=reserveCache;function getContentRange(e,t){return`bytes ${e}-${t}/*`}function uploadChunk(e,t,a,r,i){return s(this,void 0,void 0,(function*(){o.debug(`Uploading chunk of size ${i-r+1} bytes at offset ${r} with content range: ${getContentRange(r,i)}`);const n={"Content-Type":"application/octet-stream","Content-Range":getContentRange(r,i)};const p=yield(0,y.retryHttpClientResponse)(`uploadChunk (start: ${r}, end: ${i})`,(()=>s(this,void 0,void 0,(function*(){return e.sendStream("PATCH",t,a(),n)}))));if(!(0,y.isSuccessStatusCode)(p.message.statusCode)){throw new Error(`Cache service responded with ${p.message.statusCode} during upload chunk.`)}}))}function uploadFile(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=u.getArchiveFileSizeInBytes(a);const n=getCacheApiUrl(`caches/${t.toString()}`);const p=c.openSync(a,"r");const l=(0,g.getUploadOptions)(r);const d=u.assertDefined("uploadConcurrency",l.uploadConcurrency);const m=u.assertDefined("uploadChunkSize",l.uploadChunkSize);const h=[...new Array(d).keys()];o.debug("Awaiting all uploads");let y=0;try{yield Promise.all(h.map((()=>s(this,void 0,void 0,(function*(){while(yc.createReadStream(a,{fd:p,start:r,end:s,autoClose:false}).on("error",(e=>{throw new Error(`Cache upload failed because file read failed with ${e.message}`)}))),r,s)}})))))}finally{c.closeSync(p)}return}))}function commitCache(e,t,a){return s(this,void 0,void 0,(function*(){const r={size:a};return yield(0,y.retryTypedResponse)("commitCache",(()=>s(this,void 0,void 0,(function*(){return e.postJson(getCacheApiUrl(`caches/${t.toString()}`),r)}))))}))}function saveCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();o.debug("Upload cache");yield uploadFile(r,e,t,a);o.debug("Commiting cache");const i=u.getArchiveFileSizeInBytes(t);o.info(`Cache Size: ~${Math.round(i/(1024*1024))} MB (${i} B)`);const n=yield commitCache(r,e,i);if(!(0,y.isSuccessStatusCode)(n.statusCode)){throw new Error(`Cache service responded with ${n.statusCode} during commit cache.`)}o.info("Cache saved successfully")}))}t.saveCache=saveCache},1518:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};Object.defineProperty(t,"__esModule",{value:true});t.isGhes=t.assertDefined=t.getGnuTarPathOnWindows=t.getCacheFileName=t.getCompressionMethod=t.unlinkFile=t.resolvePaths=t.getArchiveFileSizeInBytes=t.createTempDirectory=void 0;const p=n(a(2186));const l=n(a(1514));const d=n(a(8090));const c=n(a(7436));const m=n(a(7147));const u=n(a(1017));const h=n(a(5911));const g=n(a(3837));const y=a(4138);const v=a(8840);function createTempDirectory(){return s(this,void 0,void 0,(function*(){const e=process.platform==="win32";let t=process.env["RUNNER_TEMP"]||"";if(!t){let a;if(e){a=process.env["USERPROFILE"]||"C:\\"}else{if(process.platform==="darwin"){a="/Users"}else{a="/home"}}t=u.join(a,"actions","temp")}const a=u.join(t,(0,y.v4)());yield c.mkdirP(a);return a}))}t.createTempDirectory=createTempDirectory;function getArchiveFileSizeInBytes(e){return m.statSync(e).size}t.getArchiveFileSizeInBytes=getArchiveFileSizeInBytes;function resolvePaths(e){var t,a,r,i;var n;return s(this,void 0,void 0,(function*(){const s=[];const l=(n=process.env["GITHUB_WORKSPACE"])!==null&&n!==void 0?n:process.cwd();const c=yield d.create(e.join("\n"),{implicitDescendants:false});try{for(var m=true,h=o(c.globGenerator()),g;g=yield h.next(),t=g.done,!t;){i=g.value;m=false;try{const e=i;const t=u.relative(l,e).replace(new RegExp(`\\${u.sep}`,"g"),"/");p.debug(`Matched: ${t}`);if(t===""){s.push(".")}else{s.push(`${t}`)}}finally{m=true}}}catch(e){a={error:e}}finally{try{if(!m&&!t&&(r=h.return))yield r.call(h)}finally{if(a)throw a.error}}return s}))}t.resolvePaths=resolvePaths;function unlinkFile(e){return s(this,void 0,void 0,(function*(){return g.promisify(m.unlink)(e)}))}t.unlinkFile=unlinkFile;function getVersion(e,t=[]){return s(this,void 0,void 0,(function*(){let a="";t.push("--version");p.debug(`Checking ${e} ${t.join(" ")}`);try{yield l.exec(`${e}`,t,{ignoreReturnCode:true,silent:true,listeners:{stdout:e=>a+=e.toString(),stderr:e=>a+=e.toString()}})}catch(e){p.debug(e.message)}a=a.trim();p.debug(a);return a}))}function getCompressionMethod(){return s(this,void 0,void 0,(function*(){const e=yield getVersion("zstd",["--quiet"]);const t=h.clean(e);p.debug(`zstd version: ${t}`);if(e===""){return v.CompressionMethod.Gzip}else{return v.CompressionMethod.ZstdWithoutLong}}))}t.getCompressionMethod=getCompressionMethod;function getCacheFileName(e){return e===v.CompressionMethod.Gzip?v.CacheFilename.Gzip:v.CacheFilename.Zstd}t.getCacheFileName=getCacheFileName;function getGnuTarPathOnWindows(){return s(this,void 0,void 0,(function*(){if(m.existsSync(v.GnuTarPathOnWindows)){return v.GnuTarPathOnWindows}const e=yield getVersion("tar");return e.toLowerCase().includes("gnu tar")?c.which("tar"):""}))}t.getGnuTarPathOnWindows=getGnuTarPathOnWindows;function assertDefined(e,t){if(t===undefined){throw Error(`Expected ${e} but value was undefiend`)}return t}t.assertDefined=assertDefined;function isGhes(){const e=new URL(process.env["GITHUB_SERVER_URL"]||"https://github.com");return e.hostname.toUpperCase()!=="GITHUB.COM"}t.isGhes=isGhes},8840:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ManifestFilename=t.TarFilename=t.SystemTarPathOnWindows=t.GnuTarPathOnWindows=t.SocketTimeout=t.DefaultRetryDelay=t.DefaultRetryAttempts=t.ArchiveToolType=t.CompressionMethod=t.CacheFilename=void 0;var a;(function(e){e["Gzip"]="cache.tgz";e["Zstd"]="cache.tzst"})(a=t.CacheFilename||(t.CacheFilename={}));var r;(function(e){e["Gzip"]="gzip";e["ZstdWithoutLong"]="zstd-without-long";e["Zstd"]="zstd"})(r=t.CompressionMethod||(t.CompressionMethod={}));var i;(function(e){e["GNU"]="gnu";e["BSD"]="bsd"})(i=t.ArchiveToolType||(t.ArchiveToolType={}));t.DefaultRetryAttempts=2;t.DefaultRetryDelay=5e3;t.SocketTimeout=5e3;t.GnuTarPathOnWindows=`${process.env["PROGRAMFILES"]}\\Git\\usr\\bin\\tar.exe`;t.SystemTarPathOnWindows=`${process.env["SYSTEMDRIVE"]}\\Windows\\System32\\tar.exe`;t.TarFilename="cache.tar";t.ManifestFilename="manifest.txt"},5500:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.downloadCacheStorageSDK=t.downloadCacheHttpClientConcurrent=t.downloadCacheHttpClient=t.DownloadProgress=void 0;const o=n(a(2186));const p=a(6255);const l=a(4100);const d=n(a(4300));const c=n(a(7147));const m=n(a(2781));const u=n(a(3837));const h=n(a(1518));const g=a(8840);const y=a(3981);const v=a(2557);function pipeResponseToStream(e,t){return s(this,void 0,void 0,(function*(){const a=u.promisify(m.pipeline);yield a(e.message,t)}))}class DownloadProgress{constructor(e){this.contentLength=e;this.segmentIndex=0;this.segmentSize=0;this.segmentOffset=0;this.receivedBytes=0;this.displayedComplete=false;this.startTime=Date.now()}nextSegment(e){this.segmentOffset=this.segmentOffset+this.segmentSize;this.segmentIndex=this.segmentIndex+1;this.segmentSize=e;this.receivedBytes=0;o.debug(`Downloading segment at offset ${this.segmentOffset} with length ${this.segmentSize}...`)}setReceivedBytes(e){this.receivedBytes=e}getTransferredBytes(){return this.segmentOffset+this.receivedBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete){return}const e=this.segmentOffset+this.receivedBytes;const t=(100*(e/this.contentLength)).toFixed(1);const a=Date.now()-this.startTime;const r=(e/(1024*1024)/(a/1e3)).toFixed(1);o.info(`Received ${e} of ${this.contentLength} (${t}%), ${r} MBs/sec`);if(this.isDone()){this.displayedComplete=true}}onProgress(){return e=>{this.setReceivedBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){const displayCallback=()=>{this.display();if(!this.isDone()){this.timeoutHandle=setTimeout(displayCallback,e)}};this.timeoutHandle=setTimeout(displayCallback,e)}stopDisplayTimer(){if(this.timeoutHandle){clearTimeout(this.timeoutHandle);this.timeoutHandle=undefined}this.display()}}t.DownloadProgress=DownloadProgress;function downloadCacheHttpClient(e,t){return s(this,void 0,void 0,(function*(){const a=c.createWriteStream(t);const r=new p.HttpClient("actions/cache");const i=yield(0,y.retryHttpClientResponse)("downloadCache",(()=>s(this,void 0,void 0,(function*(){return r.get(e)}))));i.message.socket.setTimeout(g.SocketTimeout,(()=>{i.message.destroy();o.debug(`Aborting download, socket timed out after ${g.SocketTimeout} ms`)}));yield pipeResponseToStream(i,a);const n=i.message.headers["content-length"];if(n){const e=parseInt(n);const a=h.getArchiveFileSizeInBytes(t);if(a!==e){throw new Error(`Incomplete download. Expected file size: ${e}, actual file size: ${a}`)}}else{o.debug("Unable to validate download, no Content-Length header")}}))}t.downloadCacheHttpClient=downloadCacheHttpClient;function downloadCacheHttpClientConcurrent(e,t,a){var r;return s(this,void 0,void 0,(function*(){const i=yield c.promises.open(t,"w");const n=new p.HttpClient("actions/cache",undefined,{socketTimeout:a.timeoutInMs,keepAlive:true});try{const t=yield(0,y.retryHttpClientResponse)("downloadCacheMetadata",(()=>s(this,void 0,void 0,(function*(){return yield n.request("HEAD",e,null,{})}))));const o=t.message.headers["content-length"];if(o===undefined||o===null){throw new Error("Content-Length not found on blob response")}const p=parseInt(o);if(Number.isNaN(p)){throw new Error(`Could not interpret Content-Length: ${p}`)}const l=[];const d=4*1024*1024;for(let t=0;ts(this,void 0,void 0,(function*(){return yield downloadSegmentRetry(n,e,t,a)}))})}l.reverse();let c=0;let m=0;const u=new DownloadProgress(p);u.startDisplayTimer();const h=u.onProgress();const g=[];let v;const waitAndWrite=()=>s(this,void 0,void 0,(function*(){const e=yield Promise.race(Object.values(g));yield i.write(e.buffer,0,e.count,e.offset);c--;delete g[e.offset];m+=e.count;h({loadedBytes:m})}));while(v=l.pop()){g[v.offset]=v.promiseGetter();c++;if(c>=((r=a.downloadConcurrency)!==null&&r!==void 0?r:10)){yield waitAndWrite()}}while(c>0){yield waitAndWrite()}}finally{n.dispose();yield i.close()}}))}t.downloadCacheHttpClientConcurrent=downloadCacheHttpClientConcurrent;function downloadSegmentRetry(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=5;let n=0;while(true){try{const i=3e4;const n=yield promiseWithTimeout(i,downloadSegment(e,t,a,r));if(typeof n==="string"){throw new Error("downloadSegmentRetry failed due to timeout")}return n}catch(e){if(n>=i){throw e}n++}}}))}function downloadSegment(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=yield(0,y.retryHttpClientResponse)("downloadCachePart",(()=>s(this,void 0,void 0,(function*(){return yield e.get(t,{Range:`bytes=${a}-${a+r-1}`})}))));if(!i.readBodyBuffer){throw new Error("Expected HttpClientResponse to implement readBodyBuffer")}return{offset:a,count:r,buffer:yield i.readBodyBuffer()}}))}function downloadCacheStorageSDK(e,t,a){var r;return s(this,void 0,void 0,(function*(){const i=new l.BlockBlobClient(e,undefined,{retryOptions:{tryTimeoutInMs:a.timeoutInMs}});const n=yield i.getProperties();const s=(r=n.contentLength)!==null&&r!==void 0?r:-1;if(s<0){o.debug("Unable to determine content length, downloading file with http-client...");yield downloadCacheHttpClient(e,t)}else{const e=Math.min(134217728,d.constants.MAX_LENGTH);const r=new DownloadProgress(s);const n=c.openSync(t,"w");try{r.startDisplayTimer();const t=new v.AbortController;const o=t.signal;while(!r.isDone()){const p=r.segmentOffset+r.segmentSize;const l=Math.min(e,s-p);r.nextSegment(l);const d=yield promiseWithTimeout(a.segmentTimeoutInMs||36e5,i.downloadToBuffer(p,l,{abortSignal:o,concurrency:a.downloadConcurrency,onProgress:r.onProgress()}));if(d==="timeout"){t.abort();throw new Error("Aborting cache download as the download time exceeded the timeout.")}else if(Buffer.isBuffer(d)){c.writeFileSync(n,d)}}}finally{r.stopDisplayTimer();c.closeSync(n)}}}))}t.downloadCacheStorageSDK=downloadCacheStorageSDK;const promiseWithTimeout=(e,t)=>s(void 0,void 0,void 0,(function*(){let a;const r=new Promise((t=>{a=setTimeout((()=>t("timeout")),e)}));return Promise.race([t,r]).then((e=>{clearTimeout(a);return e}))}))},3981:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.retryHttpClientResponse=t.retryTypedResponse=t.retry=t.isRetryableStatusCode=t.isServerErrorStatusCode=t.isSuccessStatusCode=void 0;const o=n(a(2186));const p=a(6255);const l=a(8840);function isSuccessStatusCode(e){if(!e){return false}return e>=200&&e<300}t.isSuccessStatusCode=isSuccessStatusCode;function isServerErrorStatusCode(e){if(!e){return true}return e>=500}t.isServerErrorStatusCode=isServerErrorStatusCode;function isRetryableStatusCode(e){if(!e){return false}const t=[p.HttpCodes.BadGateway,p.HttpCodes.ServiceUnavailable,p.HttpCodes.GatewayTimeout];return t.includes(e)}t.isRetryableStatusCode=isRetryableStatusCode;function sleep(e){return s(this,void 0,void 0,(function*(){return new Promise((t=>setTimeout(t,e)))}))}function retry(e,t,a,r=l.DefaultRetryAttempts,i=l.DefaultRetryDelay,n=undefined){return s(this,void 0,void 0,(function*(){let s="";let p=1;while(p<=r){let l=undefined;let d=undefined;let c=false;try{l=yield t()}catch(e){if(n){l=n(e)}c=true;s=e.message}if(l){d=a(l);if(!isServerErrorStatusCode(d)){return l}}if(d){c=isRetryableStatusCode(d);s=`Cache service responded with ${d}`}o.debug(`${e} - Attempt ${p} of ${r} failed with error: ${s}`);if(!c){o.debug(`${e} - Error is not retryable`);break}yield sleep(i);p++}throw Error(`${e} failed: ${s}`)}))}t.retry=retry;function retryTypedResponse(e,t,a=l.DefaultRetryAttempts,r=l.DefaultRetryDelay){return s(this,void 0,void 0,(function*(){return yield retry(e,t,(e=>e.statusCode),a,r,(e=>{if(e instanceof p.HttpClientError){return{statusCode:e.statusCode,result:null,headers:{},error:e}}else{return undefined}}))}))}t.retryTypedResponse=retryTypedResponse;function retryHttpClientResponse(e,t,a=l.DefaultRetryAttempts,r=l.DefaultRetryDelay){return s(this,void 0,void 0,(function*(){return yield retry(e,t,(e=>e.message.statusCode),a,r)}))}t.retryHttpClientResponse=retryHttpClientResponse},6490:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.createTar=t.extractTar=t.listTar=void 0;const o=a(1514);const p=n(a(7436));const l=a(7147);const d=n(a(1017));const c=n(a(1518));const m=a(8840);const u=process.platform==="win32";function getTarPath(){return s(this,void 0,void 0,(function*(){switch(process.platform){case"win32":{const e=yield c.getGnuTarPathOnWindows();const t=m.SystemTarPathOnWindows;if(e){return{path:e,type:m.ArchiveToolType.GNU}}else if((0,l.existsSync)(t)){return{path:t,type:m.ArchiveToolType.BSD}}break}case"darwin":{const e=yield p.which("gtar",false);if(e){return{path:e,type:m.ArchiveToolType.GNU}}else{return{path:yield p.which("tar",true),type:m.ArchiveToolType.BSD}}}default:break}return{path:yield p.which("tar",true),type:m.ArchiveToolType.GNU}}))}function getTarArgs(e,t,a,r=""){return s(this,void 0,void 0,(function*(){const i=[`"${e.path}"`];const n=c.getCacheFileName(t);const s="cache.tar";const o=getWorkingDirectory();const p=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(a){case"create":i.push("--posix","-cf",p?s:n.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"--exclude",p?s:n.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P","-C",o.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"--files-from",m.ManifestFilename);break;case"extract":i.push("-xf",p?s:r.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P","-C",o.replace(new RegExp(`\\${d.sep}`,"g"),"/"));break;case"list":i.push("-tf",p?s:r.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P");break}if(e.type===m.ArchiveToolType.GNU){switch(process.platform){case"win32":i.push("--force-local");break;case"darwin":i.push("--delay-directory-restore");break}}return i}))}function getCommands(e,t,a=""){return s(this,void 0,void 0,(function*(){let r;const i=yield getTarPath();const n=yield getTarArgs(i,e,t,a);const s=t!=="create"?yield getDecompressionProgram(i,e,a):yield getCompressionProgram(i,e);const o=i.type===m.ArchiveToolType.BSD&&e!==m.CompressionMethod.Gzip&&u;if(o&&t!=="create"){r=[[...s].join(" "),[...n].join(" ")]}else{r=[[...n].join(" "),[...s].join(" ")]}if(o){return r}return[r.join(" ")]}))}function getWorkingDirectory(){var e;return(e=process.env["GITHUB_WORKSPACE"])!==null&&e!==void 0?e:process.cwd()}function getDecompressionProgram(e,t,a){return s(this,void 0,void 0,(function*(){const r=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(t){case m.CompressionMethod.Zstd:return r?["zstd -d --long=30 --force -o",m.TarFilename,a.replace(new RegExp(`\\${d.sep}`,"g"),"/")]:["--use-compress-program",u?'"zstd -d --long=30"':"unzstd --long=30"];case m.CompressionMethod.ZstdWithoutLong:return r?["zstd -d --force -o",m.TarFilename,a.replace(new RegExp(`\\${d.sep}`,"g"),"/")]:["--use-compress-program",u?'"zstd -d"':"unzstd"];default:return["-z"]}}))}function getCompressionProgram(e,t){return s(this,void 0,void 0,(function*(){const a=c.getCacheFileName(t);const r=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(t){case m.CompressionMethod.Zstd:return r?["zstd -T0 --long=30 --force -o",a.replace(new RegExp(`\\${d.sep}`,"g"),"/"),m.TarFilename]:["--use-compress-program",u?'"zstd -T0 --long=30"':"zstdmt --long=30"];case m.CompressionMethod.ZstdWithoutLong:return r?["zstd -T0 --force -o",a.replace(new RegExp(`\\${d.sep}`,"g"),"/"),m.TarFilename]:["--use-compress-program",u?'"zstd -T0"':"zstdmt"];default:return["-z"]}}))}function execCommands(e,t){return s(this,void 0,void 0,(function*(){for(const a of e){try{yield(0,o.exec)(a,undefined,{cwd:t,env:Object.assign(Object.assign({},process.env),{MSYS:"winsymlinks:nativestrict"})})}catch(e){throw new Error(`${a.split(" ")[0]} failed with error: ${e===null||e===void 0?void 0:e.message}`)}}}))}function listTar(e,t){return s(this,void 0,void 0,(function*(){const a=yield getCommands(t,"list",e);yield execCommands(a)}))}t.listTar=listTar;function extractTar(e,t){return s(this,void 0,void 0,(function*(){const a=getWorkingDirectory();yield p.mkdirP(a);const r=yield getCommands(t,"extract",e);yield execCommands(r)}))}t.extractTar=extractTar;function createTar(e,t,a){return s(this,void 0,void 0,(function*(){(0,l.writeFileSync)(d.join(e,m.ManifestFilename),t.join("\n"));const r=yield getCommands(a,"create");yield execCommands(r,e)}))}t.createTar=createTar},6215:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getDownloadOptions=t.getUploadOptions=void 0;const s=n(a(2186));function getUploadOptions(e){const t={uploadConcurrency:4,uploadChunkSize:32*1024*1024};if(e){if(typeof e.uploadConcurrency==="number"){t.uploadConcurrency=e.uploadConcurrency}if(typeof e.uploadChunkSize==="number"){t.uploadChunkSize=e.uploadChunkSize}}s.debug(`Upload concurrency: ${t.uploadConcurrency}`);s.debug(`Upload chunk size: ${t.uploadChunkSize}`);return t}t.getUploadOptions=getUploadOptions;function getDownloadOptions(e){const t={useAzureSdk:false,concurrentBlobDownloads:true,downloadConcurrency:8,timeoutInMs:3e4,segmentTimeoutInMs:6e5,lookupOnly:false};if(e){if(typeof e.useAzureSdk==="boolean"){t.useAzureSdk=e.useAzureSdk}if(typeof e.concurrentBlobDownloads==="boolean"){t.concurrentBlobDownloads=e.concurrentBlobDownloads}if(typeof e.downloadConcurrency==="number"){t.downloadConcurrency=e.downloadConcurrency}if(typeof e.timeoutInMs==="number"){t.timeoutInMs=e.timeoutInMs}if(typeof e.segmentTimeoutInMs==="number"){t.segmentTimeoutInMs=e.segmentTimeoutInMs}if(typeof e.lookupOnly==="boolean"){t.lookupOnly=e.lookupOnly}}const a=process.env["SEGMENT_DOWNLOAD_TIMEOUT_MINS"];if(a&&!isNaN(Number(a))&&isFinite(Number(a))){t.segmentTimeoutInMs=Number(a)*60*1e3}s.debug(`Use Azure SDK: ${t.useAzureSdk}`);s.debug(`Download concurrency: ${t.downloadConcurrency}`);s.debug(`Request timeout (ms): ${t.timeoutInMs}`);s.debug(`Cache segment download timeout mins env var: ${process.env["SEGMENT_DOWNLOAD_TIMEOUT_MINS"]}`);s.debug(`Segment download timeout (ms): ${t.segmentTimeoutInMs}`);s.debug(`Lookup only: ${t.lookupOnly}`);return t}t.getDownloadOptions=getDownloadOptions},4138:(e,t,a)=>{var r=a(1610);var i=a(8373);var n=i;n.v1=r;n.v4=i;e.exports=n},5694:e=>{var t=[];for(var a=0;a<256;++a){t[a]=(a+256).toString(16).substr(1)}function bytesToUuid(e,a){var r=a||0;var i=t;return[i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]]].join("")}e.exports=bytesToUuid},4069:(e,t,a)=>{var r=a(6113);e.exports=function nodeRNG(){return r.randomBytes(16)}},1610:(e,t,a)=>{var r=a(4069);var i=a(5694);var n;var s;var o=0;var p=0;function v1(e,t,a){var l=t&&a||0;var d=t||[];e=e||{};var c=e.node||n;var m=e.clockseq!==undefined?e.clockseq:s;if(c==null||m==null){var u=r();if(c==null){c=n=[u[0]|1,u[1],u[2],u[3],u[4],u[5]]}if(m==null){m=s=(u[6]<<8|u[7])&16383}}var h=e.msecs!==undefined?e.msecs:(new Date).getTime();var g=e.nsecs!==undefined?e.nsecs:p+1;var y=h-o+(g-p)/1e4;if(y<0&&e.clockseq===undefined){m=m+1&16383}if((y<0||h>o)&&e.nsecs===undefined){g=0}if(g>=1e4){throw new Error("uuid.v1(): Can't create more than 10M uuids/sec")}o=h;p=g;s=m;h+=122192928e5;var v=((h&268435455)*1e4+g)%4294967296;d[l++]=v>>>24&255;d[l++]=v>>>16&255;d[l++]=v>>>8&255;d[l++]=v&255;var b=h/4294967296*1e4&268435455;d[l++]=b>>>8&255;d[l++]=b&255;d[l++]=b>>>24&15|16;d[l++]=b>>>16&255;d[l++]=m>>>8|128;d[l++]=m&255;for(var x=0;x<6;++x){d[l+x]=c[x]}return t?t:i(d)}e.exports=v1},8373:(e,t,a)=>{var r=a(4069);var i=a(5694);function v4(e,t,a){var n=t&&a||0;if(typeof e=="string"){t=e==="binary"?new Array(16):null;e=null}e=e||{};var s=e.random||(e.rng||r)();s[6]=s[6]&15|64;s[8]=s[8]&63|128;if(t){for(var o=0;o<16;++o){t[n+o]=s[o]}}return t||i(s)}e.exports=v4},7351:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issue=t.issueCommand=void 0;const s=n(a(2037));const o=a(5278);function issueCommand(e,t,a){const r=new Command(e,t,a);process.stdout.write(r.toString()+s.EOL)}t.issueCommand=issueCommand;function issue(e,t=""){issueCommand(e,{},t)}t.issue=issue;const p="::";class Command{constructor(e,t,a){if(!e){e="missing.command"}this.command=e;this.properties=t;this.message=a}toString(){let e=p+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let t=true;for(const a in this.properties){if(this.properties.hasOwnProperty(a)){const r=this.properties[a];if(r){if(t){t=false}else{e+=","}e+=`${a}=${escapeProperty(r)}`}}}}e+=`${p}${escapeData(this.message)}`;return e}}function escapeData(e){return o.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return o.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},2186:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getIDToken=t.getState=t.saveState=t.group=t.endGroup=t.startGroup=t.info=t.notice=t.warning=t.error=t.debug=t.isDebug=t.setFailed=t.setCommandEcho=t.setOutput=t.getBooleanInput=t.getMultilineInput=t.getInput=t.addPath=t.setSecret=t.exportVariable=t.ExitCode=void 0;const o=a(7351);const p=a(717);const l=a(5278);const d=n(a(2037));const c=n(a(1017));const m=a(8041);var u;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(u=t.ExitCode||(t.ExitCode={}));function exportVariable(e,t){const a=l.toCommandValue(t);process.env[e]=a;const r=process.env["GITHUB_ENV"]||"";if(r){return p.issueFileCommand("ENV",p.prepareKeyValueMessage(e,t))}o.issueCommand("set-env",{name:e},a)}t.exportVariable=exportVariable;function setSecret(e){o.issueCommand("add-mask",{},e)}t.setSecret=setSecret;function addPath(e){const t=process.env["GITHUB_PATH"]||"";if(t){p.issueFileCommand("PATH",e)}else{o.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${c.delimiter}${process.env["PATH"]}`}t.addPath=addPath;function getInput(e,t){const a=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(t&&t.required&&!a){throw new Error(`Input required and not supplied: ${e}`)}if(t&&t.trimWhitespace===false){return a}return a.trim()}t.getInput=getInput;function getMultilineInput(e,t){const a=getInput(e,t).split("\n").filter((e=>e!==""));if(t&&t.trimWhitespace===false){return a}return a.map((e=>e.trim()))}t.getMultilineInput=getMultilineInput;function getBooleanInput(e,t){const a=["true","True","TRUE"];const r=["false","False","FALSE"];const i=getInput(e,t);if(a.includes(i))return true;if(r.includes(i))return false;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${e}\n`+`Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}t.getBooleanInput=getBooleanInput;function setOutput(e,t){const a=process.env["GITHUB_OUTPUT"]||"";if(a){return p.issueFileCommand("OUTPUT",p.prepareKeyValueMessage(e,t))}process.stdout.write(d.EOL);o.issueCommand("set-output",{name:e},l.toCommandValue(t))}t.setOutput=setOutput;function setCommandEcho(e){o.issue("echo",e?"on":"off")}t.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=u.Failure;error(e)}t.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}t.isDebug=isDebug;function debug(e){o.issueCommand("debug",{},e)}t.debug=debug;function error(e,t={}){o.issueCommand("error",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.error=error;function warning(e,t={}){o.issueCommand("warning",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.warning=warning;function notice(e,t={}){o.issueCommand("notice",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.notice=notice;function info(e){process.stdout.write(e+d.EOL)}t.info=info;function startGroup(e){o.issue("group",e)}t.startGroup=startGroup;function endGroup(){o.issue("endgroup")}t.endGroup=endGroup;function group(e,t){return s(this,void 0,void 0,(function*(){startGroup(e);let a;try{a=yield t()}finally{endGroup()}return a}))}t.group=group;function saveState(e,t){const a=process.env["GITHUB_STATE"]||"";if(a){return p.issueFileCommand("STATE",p.prepareKeyValueMessage(e,t))}o.issueCommand("save-state",{name:e},l.toCommandValue(t))}t.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}t.getState=getState;function getIDToken(e){return s(this,void 0,void 0,(function*(){return yield m.OidcClient.getIDToken(e)}))}t.getIDToken=getIDToken;var h=a(1327);Object.defineProperty(t,"summary",{enumerable:true,get:function(){return h.summary}});var g=a(1327);Object.defineProperty(t,"markdownSummary",{enumerable:true,get:function(){return g.markdownSummary}});var y=a(2981);Object.defineProperty(t,"toPosixPath",{enumerable:true,get:function(){return y.toPosixPath}});Object.defineProperty(t,"toWin32Path",{enumerable:true,get:function(){return y.toWin32Path}});Object.defineProperty(t,"toPlatformPath",{enumerable:true,get:function(){return y.toPlatformPath}})},717:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.prepareKeyValueMessage=t.issueFileCommand=void 0;const s=n(a(7147));const o=n(a(2037));const p=a(5840);const l=a(5278);function issueFileCommand(e,t){const a=process.env[`GITHUB_${e}`];if(!a){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!s.existsSync(a)){throw new Error(`Missing file at path: ${a}`)}s.appendFileSync(a,`${l.toCommandValue(t)}${o.EOL}`,{encoding:"utf8"})}t.issueFileCommand=issueFileCommand;function prepareKeyValueMessage(e,t){const a=`ghadelimiter_${p.v4()}`;const r=l.toCommandValue(t);if(e.includes(a)){throw new Error(`Unexpected input: name should not contain the delimiter "${a}"`)}if(r.includes(a)){throw new Error(`Unexpected input: value should not contain the delimiter "${a}"`)}return`${e}<<${a}${o.EOL}${r}${o.EOL}${a}`}t.prepareKeyValueMessage=prepareKeyValueMessage},8041:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.OidcClient=void 0;const i=a(6255);const n=a(5526);const s=a(2186);class OidcClient{static createHttpClient(e=true,t=10){const a={allowRetries:e,maxRetries:t};return new i.HttpClient("actions/oidc-client",[new n.BearerCredentialHandler(OidcClient.getRequestToken())],a)}static getRequestToken(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_TOKEN env variable")}return e}static getIDTokenUrl(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_URL"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable")}return e}static getCall(e){var t;return r(this,void 0,void 0,(function*(){const a=OidcClient.createHttpClient();const r=yield a.getJson(e).catch((e=>{throw new Error(`Failed to get ID Token. \n \n Error Code : ${e.statusCode}\n \n Error Message: ${e.result.message}`)}));const i=(t=r.result)===null||t===void 0?void 0:t.value;if(!i){throw new Error("Response json body do not have ID Token field")}return i}))}static getIDToken(e){return r(this,void 0,void 0,(function*(){try{let t=OidcClient.getIDTokenUrl();if(e){const a=encodeURIComponent(e);t=`${t}&audience=${a}`}s.debug(`ID token url is ${t}`);const a=yield OidcClient.getCall(t);s.setSecret(a);return a}catch(e){throw new Error(`Error message: ${e.message}`)}}))}}t.OidcClient=OidcClient},2981:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.toPlatformPath=t.toWin32Path=t.toPosixPath=void 0;const s=n(a(1017));function toPosixPath(e){return e.replace(/[\\]/g,"/")}t.toPosixPath=toPosixPath;function toWin32Path(e){return e.replace(/[/]/g,"\\")}t.toWin32Path=toWin32Path;function toPlatformPath(e){return e.replace(/[/\\]/g,s.sep)}t.toPlatformPath=toPlatformPath},1327:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.summary=t.markdownSummary=t.SUMMARY_DOCS_URL=t.SUMMARY_ENV_VAR=void 0;const i=a(2037);const n=a(7147);const{access:s,appendFile:o,writeFile:p}=n.promises;t.SUMMARY_ENV_VAR="GITHUB_STEP_SUMMARY";t.SUMMARY_DOCS_URL="https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary";class Summary{constructor(){this._buffer=""}filePath(){return r(this,void 0,void 0,(function*(){if(this._filePath){return this._filePath}const e=process.env[t.SUMMARY_ENV_VAR];if(!e){throw new Error(`Unable to find environment variable for $${t.SUMMARY_ENV_VAR}. Check if your runtime environment supports job summaries.`)}try{yield s(e,n.constants.R_OK|n.constants.W_OK)}catch(t){throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}this._filePath=e;return this._filePath}))}wrap(e,t,a={}){const r=Object.entries(a).map((([e,t])=>` ${e}="${t}"`)).join("");if(!t){return`<${e}${r}>`}return`<${e}${r}>${t}`}write(e){return r(this,void 0,void 0,(function*(){const t=!!(e===null||e===void 0?void 0:e.overwrite);const a=yield this.filePath();const r=t?p:o;yield r(a,this._buffer,{encoding:"utf8"});return this.emptyBuffer()}))}clear(){return r(this,void 0,void 0,(function*(){return this.emptyBuffer().write({overwrite:true})}))}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){this._buffer="";return this}addRaw(e,t=false){this._buffer+=e;return t?this.addEOL():this}addEOL(){return this.addRaw(i.EOL)}addCodeBlock(e,t){const a=Object.assign({},t&&{lang:t});const r=this.wrap("pre",this.wrap("code",e),a);return this.addRaw(r).addEOL()}addList(e,t=false){const a=t?"ol":"ul";const r=e.map((e=>this.wrap("li",e))).join("");const i=this.wrap(a,r);return this.addRaw(i).addEOL()}addTable(e){const t=e.map((e=>{const t=e.map((e=>{if(typeof e==="string"){return this.wrap("td",e)}const{header:t,data:a,colspan:r,rowspan:i}=e;const n=t?"th":"td";const s=Object.assign(Object.assign({},r&&{colspan:r}),i&&{rowspan:i});return this.wrap(n,a,s)})).join("");return this.wrap("tr",t)})).join("");const a=this.wrap("table",t);return this.addRaw(a).addEOL()}addDetails(e,t){const a=this.wrap("details",this.wrap("summary",e)+t);return this.addRaw(a).addEOL()}addImage(e,t,a){const{width:r,height:i}=a||{};const n=Object.assign(Object.assign({},r&&{width:r}),i&&{height:i});const s=this.wrap("img",null,Object.assign({src:e,alt:t},n));return this.addRaw(s).addEOL()}addHeading(e,t){const a=`h${t}`;const r=["h1","h2","h3","h4","h5","h6"].includes(a)?a:"h1";const i=this.wrap(r,e);return this.addRaw(i).addEOL()}addSeparator(){const e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){const e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,t){const a=Object.assign({},t&&{cite:t});const r=this.wrap("blockquote",e,a);return this.addRaw(r).addEOL()}addLink(e,t){const a=this.wrap("a",e,{href:t});return this.addRaw(a).addEOL()}}const l=new Summary;t.markdownSummary=l;t.summary=l},5278:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.toCommandProperties=t.toCommandValue=void 0;function toCommandValue(e){if(e===null||e===undefined){return""}else if(typeof e==="string"||e instanceof String){return e}return JSON.stringify(e)}t.toCommandValue=toCommandValue;function toCommandProperties(e){if(!Object.keys(e).length){return{}}return{title:e.title,file:e.file,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}}t.toCommandProperties=toCommandProperties},1514:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getExecOutput=t.exec=void 0;const o=a(1576);const p=n(a(8159));function exec(e,t,a){return s(this,void 0,void 0,(function*(){const r=p.argStringToArray(e);if(r.length===0){throw new Error(`Parameter 'commandLine' cannot be null or empty.`)}const i=r[0];t=r.slice(1).concat(t||[]);const n=new p.ToolRunner(i,t,a);return n.exec()}))}t.exec=exec;function getExecOutput(e,t,a){var r,i;return s(this,void 0,void 0,(function*(){let n="";let s="";const p=new o.StringDecoder("utf8");const l=new o.StringDecoder("utf8");const d=(r=a===null||a===void 0?void 0:a.listeners)===null||r===void 0?void 0:r.stdout;const c=(i=a===null||a===void 0?void 0:a.listeners)===null||i===void 0?void 0:i.stderr;const stdErrListener=e=>{s+=l.write(e);if(c){c(e)}};const stdOutListener=e=>{n+=p.write(e);if(d){d(e)}};const m=Object.assign(Object.assign({},a===null||a===void 0?void 0:a.listeners),{stdout:stdOutListener,stderr:stdErrListener});const u=yield exec(e,t,Object.assign(Object.assign({},a),{listeners:m}));n+=p.end();s+=l.end();return{exitCode:u,stdout:n,stderr:s}}))}t.getExecOutput=getExecOutput},8159:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.argStringToArray=t.ToolRunner=void 0;const o=n(a(2037));const p=n(a(2361));const l=n(a(2081));const d=n(a(1017));const c=n(a(7436));const m=n(a(1962));const u=a(9512);const h=process.platform==="win32";class ToolRunner extends p.EventEmitter{constructor(e,t,a){super();if(!e){throw new Error("Parameter 'toolPath' cannot be null or empty.")}this.toolPath=e;this.args=t||[];this.options=a||{}}_debug(e){if(this.options.listeners&&this.options.listeners.debug){this.options.listeners.debug(e)}}_getCommandString(e,t){const a=this._getSpawnFileName();const r=this._getSpawnArgs(e);let i=t?"":"[command]";if(h){if(this._isCmdFile()){i+=a;for(const e of r){i+=` ${e}`}}else if(e.windowsVerbatimArguments){i+=`"${a}"`;for(const e of r){i+=` ${e}`}}else{i+=this._windowsQuoteCmdArg(a);for(const e of r){i+=` ${this._windowsQuoteCmdArg(e)}`}}}else{i+=a;for(const e of r){i+=` ${e}`}}return i}_processLineBuffer(e,t,a){try{let r=t+e.toString();let i=r.indexOf(o.EOL);while(i>-1){const e=r.substring(0,i);a(e);r=r.substring(i+o.EOL.length);i=r.indexOf(o.EOL)}return r}catch(e){this._debug(`error processing line. Failed with error ${e}`);return""}}_getSpawnFileName(){if(h){if(this._isCmdFile()){return process.env["COMSPEC"]||"cmd.exe"}}return this.toolPath}_getSpawnArgs(e){if(h){if(this._isCmdFile()){let t=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(const a of this.args){t+=" ";t+=e.windowsVerbatimArguments?a:this._windowsQuoteCmdArg(a)}t+='"';return[t]}}return this.args}_endsWith(e,t){return e.endsWith(t)}_isCmdFile(){const e=this.toolPath.toUpperCase();return this._endsWith(e,".CMD")||this._endsWith(e,".BAT")}_windowsQuoteCmdArg(e){if(!this._isCmdFile()){return this._uvQuoteCmdArg(e)}if(!e){return'""'}const t=[" ","\t","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'];let a=false;for(const r of e){if(t.some((e=>e===r))){a=true;break}}if(!a){return e}let r='"';let i=true;for(let t=e.length;t>0;t--){r+=e[t-1];if(i&&e[t-1]==="\\"){r+="\\"}else if(e[t-1]==='"'){i=true;r+='"'}else{i=false}}r+='"';return r.split("").reverse().join("")}_uvQuoteCmdArg(e){if(!e){return'""'}if(!e.includes(" ")&&!e.includes("\t")&&!e.includes('"')){return e}if(!e.includes('"')&&!e.includes("\\")){return`"${e}"`}let t='"';let a=true;for(let r=e.length;r>0;r--){t+=e[r-1];if(a&&e[r-1]==="\\"){t+="\\"}else if(e[r-1]==='"'){a=true;t+="\\"}else{a=false}}t+='"';return t.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};const t={cwd:e.cwd||process.cwd(),env:e.env||process.env,silent:e.silent||false,windowsVerbatimArguments:e.windowsVerbatimArguments||false,failOnStdErr:e.failOnStdErr||false,ignoreReturnCode:e.ignoreReturnCode||false,delay:e.delay||1e4};t.outStream=e.outStream||process.stdout;t.errStream=e.errStream||process.stderr;return t}_getSpawnOptions(e,t){e=e||{};const a={};a.cwd=e.cwd;a.env=e.env;a["windowsVerbatimArguments"]=e.windowsVerbatimArguments||this._isCmdFile();if(e.windowsVerbatimArguments){a.argv0=`"${t}"`}return a}exec(){return s(this,void 0,void 0,(function*(){if(!m.isRooted(this.toolPath)&&(this.toolPath.includes("/")||h&&this.toolPath.includes("\\"))){this.toolPath=d.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)}this.toolPath=yield c.which(this.toolPath,true);return new Promise(((e,t)=>s(this,void 0,void 0,(function*(){this._debug(`exec tool: ${this.toolPath}`);this._debug("arguments:");for(const e of this.args){this._debug(` ${e}`)}const a=this._cloneExecOptions(this.options);if(!a.silent&&a.outStream){a.outStream.write(this._getCommandString(a)+o.EOL)}const r=new ExecState(a,this.toolPath);r.on("debug",(e=>{this._debug(e)}));if(this.options.cwd&&!(yield m.exists(this.options.cwd))){return t(new Error(`The cwd: ${this.options.cwd} does not exist!`))}const i=this._getSpawnFileName();const n=l.spawn(i,this._getSpawnArgs(a),this._getSpawnOptions(this.options,i));let s="";if(n.stdout){n.stdout.on("data",(e=>{if(this.options.listeners&&this.options.listeners.stdout){this.options.listeners.stdout(e)}if(!a.silent&&a.outStream){a.outStream.write(e)}s=this._processLineBuffer(e,s,(e=>{if(this.options.listeners&&this.options.listeners.stdline){this.options.listeners.stdline(e)}}))}))}let p="";if(n.stderr){n.stderr.on("data",(e=>{r.processStderr=true;if(this.options.listeners&&this.options.listeners.stderr){this.options.listeners.stderr(e)}if(!a.silent&&a.errStream&&a.outStream){const t=a.failOnStdErr?a.errStream:a.outStream;t.write(e)}p=this._processLineBuffer(e,p,(e=>{if(this.options.listeners&&this.options.listeners.errline){this.options.listeners.errline(e)}}))}))}n.on("error",(e=>{r.processError=e.message;r.processExited=true;r.processClosed=true;r.CheckComplete()}));n.on("exit",(e=>{r.processExitCode=e;r.processExited=true;this._debug(`Exit code ${e} received from tool '${this.toolPath}'`);r.CheckComplete()}));n.on("close",(e=>{r.processExitCode=e;r.processExited=true;r.processClosed=true;this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);r.CheckComplete()}));r.on("done",((a,r)=>{if(s.length>0){this.emit("stdline",s)}if(p.length>0){this.emit("errline",p)}n.removeAllListeners();if(a){t(a)}else{e(r)}}));if(this.options.input){if(!n.stdin){throw new Error("child process missing stdin")}n.stdin.end(this.options.input)}}))))}))}}t.ToolRunner=ToolRunner;function argStringToArray(e){const t=[];let a=false;let r=false;let i="";function append(e){if(r&&e!=='"'){i+="\\"}i+=e;r=false}for(let n=0;n0){t.push(i);i=""}continue}append(s)}if(i.length>0){t.push(i.trim())}return t}t.argStringToArray=argStringToArray;class ExecState extends p.EventEmitter{constructor(e,t){super();this.processClosed=false;this.processError="";this.processExitCode=0;this.processExited=false;this.processStderr=false;this.delay=1e4;this.done=false;this.timeout=null;if(!t){throw new Error("toolPath must not be empty")}this.options=e;this.toolPath=t;if(e.delay){this.delay=e.delay}}CheckComplete(){if(this.done){return}if(this.processClosed){this._setResult()}else if(this.processExited){this.timeout=u.setTimeout(ExecState.HandleTimeout,this.delay,this)}}_debug(e){this.emit("debug",e)}_setResult(){let e;if(this.processExited){if(this.processError){e=new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`)}else if(this.processExitCode!==0&&!this.options.ignoreReturnCode){e=new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`)}else if(this.processStderr&&this.options.failOnStdErr){e=new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`)}}if(this.timeout){clearTimeout(this.timeout);this.timeout=null}this.done=true;this.emit("done",e,this.processExitCode)}static HandleTimeout(e){if(e.done){return}if(!e.processClosed&&e.processExited){const t=`The STDIO streams did not close within ${e.delay/1e3} seconds of the exit event from process '${e.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;e._debug(t)}e._setResult()}}},4087:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Context=void 0;const r=a(7147);const i=a(2037);class Context{constructor(){var e,t,a;this.payload={};if(process.env.GITHUB_EVENT_PATH){if(r.existsSync(process.env.GITHUB_EVENT_PATH)){this.payload=JSON.parse(r.readFileSync(process.env.GITHUB_EVENT_PATH,{encoding:"utf8"}))}else{const e=process.env.GITHUB_EVENT_PATH;process.stdout.write(`GITHUB_EVENT_PATH ${e} does not exist${i.EOL}`)}}this.eventName=process.env.GITHUB_EVENT_NAME;this.sha=process.env.GITHUB_SHA;this.ref=process.env.GITHUB_REF;this.workflow=process.env.GITHUB_WORKFLOW;this.action=process.env.GITHUB_ACTION;this.actor=process.env.GITHUB_ACTOR;this.job=process.env.GITHUB_JOB;this.runNumber=parseInt(process.env.GITHUB_RUN_NUMBER,10);this.runId=parseInt(process.env.GITHUB_RUN_ID,10);this.apiUrl=(e=process.env.GITHUB_API_URL)!==null&&e!==void 0?e:`https://api.github.com`;this.serverUrl=(t=process.env.GITHUB_SERVER_URL)!==null&&t!==void 0?t:`https://github.com`;this.graphqlUrl=(a=process.env.GITHUB_GRAPHQL_URL)!==null&&a!==void 0?a:`https://api.github.com/graphql`}get issue(){const e=this.payload;return Object.assign(Object.assign({},this.repo),{number:(e.issue||e.pull_request||e).number})}get repo(){if(process.env.GITHUB_REPOSITORY){const[e,t]=process.env.GITHUB_REPOSITORY.split("/");return{owner:e,repo:t}}if(this.payload.repository){return{owner:this.payload.repository.owner.login,repo:this.payload.repository.name}}throw new Error("context.repo requires a GITHUB_REPOSITORY environment variable like 'owner/repo'")}}t.Context=Context},5438:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokit=t.context=void 0;const s=n(a(4087));const o=a(3030);t.context=new s.Context;function getOctokit(e,t,...a){const r=o.GitHub.plugin(...a);return new r(o.getOctokitOptions(e,t))}t.getOctokit=getOctokit},7914:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getApiBaseUrl=t.getProxyAgent=t.getAuthString=void 0;const s=n(a(6255));function getAuthString(e,t){if(!e&&!t.auth){throw new Error("Parameter token or opts.auth is required")}else if(e&&t.auth){throw new Error("Parameters token and opts.auth may not both be specified")}return typeof t.auth==="string"?t.auth:`token ${e}`}t.getAuthString=getAuthString;function getProxyAgent(e){const t=new s.HttpClient;return t.getAgent(e)}t.getProxyAgent=getProxyAgent;function getApiBaseUrl(){return process.env["GITHUB_API_URL"]||"https://api.github.com"}t.getApiBaseUrl=getApiBaseUrl},3030:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokitOptions=t.GitHub=t.defaults=t.context=void 0;const s=n(a(4087));const o=n(a(7914));const p=a(6762);const l=a(3044);const d=a(4193);t.context=new s.Context;const c=o.getApiBaseUrl();t.defaults={baseUrl:c,request:{agent:o.getProxyAgent(c)}};t.GitHub=p.Octokit.plugin(l.restEndpointMethods,d.paginateRest).defaults(t.defaults);function getOctokitOptions(e,t){const a=Object.assign({},t||{});const r=o.getAuthString(e,a);if(r){a.auth=r}return a}t.getOctokitOptions=getOctokitOptions},8090:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.create=void 0;const i=a(8298);function create(e,t){return r(this,void 0,void 0,(function*(){return yield i.DefaultGlobber.create(e,t)}))}t.create=create},1026:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOptions=void 0;const s=n(a(2186));function getOptions(e){const t={followSymbolicLinks:true,implicitDescendants:true,omitBrokenSymbolicLinks:true};if(e){if(typeof e.followSymbolicLinks==="boolean"){t.followSymbolicLinks=e.followSymbolicLinks;s.debug(`followSymbolicLinks '${t.followSymbolicLinks}'`)}if(typeof e.implicitDescendants==="boolean"){t.implicitDescendants=e.implicitDescendants;s.debug(`implicitDescendants '${t.implicitDescendants}'`)}if(typeof e.omitBrokenSymbolicLinks==="boolean"){t.omitBrokenSymbolicLinks=e.omitBrokenSymbolicLinks;s.debug(`omitBrokenSymbolicLinks '${t.omitBrokenSymbolicLinks}'`)}}return t}t.getOptions=getOptions},8298:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};var p=this&&this.__await||function(e){return this instanceof p?(this.v=e,this):new p(e)};var l=this&&this.__asyncGenerator||function(e,t,a){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=a.apply(e,t||[]),i,n=[];return i={},verb("next"),verb("throw"),verb("return"),i[Symbol.asyncIterator]=function(){return this},i;function verb(e){if(r[e])i[e]=function(t){return new Promise((function(a,r){n.push([e,t,a,r])>1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof p?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};Object.defineProperty(t,"__esModule",{value:true});t.DefaultGlobber=void 0;const d=n(a(2186));const c=n(a(7147));const m=n(a(1026));const u=n(a(1017));const h=n(a(9005));const g=a(1063);const y=a(4536);const v=a(9117);const b=process.platform==="win32";class DefaultGlobber{constructor(e){this.patterns=[];this.searchPaths=[];this.options=m.getOptions(e)}getSearchPaths(){return this.searchPaths.slice()}glob(){var e,t;return s(this,void 0,void 0,(function*(){const a=[];try{for(var r=o(this.globGenerator()),i;i=yield r.next(),!i.done;){const e=i.value;a.push(e)}}catch(t){e={error:t}}finally{try{if(i&&!i.done&&(t=r.return))yield t.call(r)}finally{if(e)throw e.error}}return a}))}globGenerator(){return l(this,arguments,(function*globGenerator_1(){const e=m.getOptions(this.options);const t=[];for(const a of this.patterns){t.push(a);if(e.implicitDescendants&&(a.trailingSeparator||a.segments[a.segments.length-1]!=="**")){t.push(new y.Pattern(a.negate,true,a.segments.concat("**")))}}const a=[];for(const e of h.getSearchPaths(t)){d.debug(`Search path '${e}'`);try{yield p(c.promises.lstat(e))}catch(e){if(e.code==="ENOENT"){continue}throw e}a.unshift(new v.SearchState(e,1))}const r=[];while(a.length){const i=a.pop();const n=h.match(t,i.path);const s=!!n||h.partialMatch(t,i.path);if(!n&&!s){continue}const o=yield p(DefaultGlobber.stat(i,e,r));if(!o){continue}if(o.isDirectory()){if(n&g.MatchKind.Directory){yield yield p(i.path)}else if(!s){continue}const e=i.level+1;const t=(yield p(c.promises.readdir(i.path))).map((t=>new v.SearchState(u.join(i.path,t),e)));a.push(...t.reverse())}else if(n&g.MatchKind.File){yield yield p(i.path)}}}))}static create(e,t){return s(this,void 0,void 0,(function*(){const a=new DefaultGlobber(t);if(b){e=e.replace(/\r\n/g,"\n");e=e.replace(/\r/g,"\n")}const r=e.split("\n").map((e=>e.trim()));for(const e of r){if(!e||e.startsWith("#")){continue}else{a.patterns.push(new y.Pattern(e))}}a.searchPaths.push(...h.getSearchPaths(a.patterns));return a}))}static stat(e,t,a){return s(this,void 0,void 0,(function*(){let r;if(t.followSymbolicLinks){try{r=yield c.promises.stat(e.path)}catch(a){if(a.code==="ENOENT"){if(t.omitBrokenSymbolicLinks){d.debug(`Broken symlink '${e.path}'`);return undefined}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw a}}else{r=yield c.promises.lstat(e.path)}if(r.isDirectory()&&t.followSymbolicLinks){const t=yield c.promises.realpath(e.path);while(a.length>=e.level){a.pop()}if(a.some((e=>e===t))){d.debug(`Symlink cycle detected for path '${e.path}' and realpath '${t}'`);return undefined}a.push(t)}return r}))}}t.DefaultGlobber=DefaultGlobber},1063:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MatchKind=void 0;var a;(function(e){e[e["None"]=0]="None";e[e["Directory"]=1]="Directory";e[e["File"]=2]="File";e[e["All"]=3]="All"})(a=t.MatchKind||(t.MatchKind={}))},1849:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.safeTrimTrailingSeparator=t.normalizeSeparators=t.hasRoot=t.hasAbsoluteRoot=t.ensureAbsoluteRoot=t.dirname=void 0;const o=n(a(1017));const p=s(a(9491));const l=process.platform==="win32";function dirname(e){e=safeTrimTrailingSeparator(e);if(l&&/^\\\\[^\\]+(\\[^\\]+)?$/.test(e)){return e}let t=o.dirname(e);if(l&&/^\\\\[^\\]+\\[^\\]+\\$/.test(t)){t=safeTrimTrailingSeparator(t)}return t}t.dirname=dirname;function ensureAbsoluteRoot(e,t){p.default(e,`ensureAbsoluteRoot parameter 'root' must not be empty`);p.default(t,`ensureAbsoluteRoot parameter 'itemPath' must not be empty`);if(hasAbsoluteRoot(t)){return t}if(l){if(t.match(/^[A-Z]:[^\\/]|^[A-Z]:$/i)){let e=process.cwd();p.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);if(t[0].toUpperCase()===e[0].toUpperCase()){if(t.length===2){return`${t[0]}:\\${e.substr(3)}`}else{if(!e.endsWith("\\")){e+="\\"}return`${t[0]}:\\${e.substr(3)}${t.substr(2)}`}}else{return`${t[0]}:\\${t.substr(2)}`}}else if(normalizeSeparators(t).match(/^\\$|^\\[^\\]/)){const e=process.cwd();p.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);return`${e[0]}:\\${t.substr(1)}`}}p.default(hasAbsoluteRoot(e),`ensureAbsoluteRoot parameter 'root' must have an absolute root`);if(e.endsWith("/")||l&&e.endsWith("\\")){}else{e+=o.sep}return e+t}t.ensureAbsoluteRoot=ensureAbsoluteRoot;function hasAbsoluteRoot(e){p.default(e,`hasAbsoluteRoot parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(l){return e.startsWith("\\\\")||/^[A-Z]:\\/i.test(e)}return e.startsWith("/")}t.hasAbsoluteRoot=hasAbsoluteRoot;function hasRoot(e){p.default(e,`isRooted parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(l){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.hasRoot=hasRoot;function normalizeSeparators(e){e=e||"";if(l){e=e.replace(/\//g,"\\");const t=/^\\\\+[^\\]/.test(e);return(t?"\\":"")+e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}t.normalizeSeparators=normalizeSeparators;function safeTrimTrailingSeparator(e){if(!e){return""}e=normalizeSeparators(e);if(!e.endsWith(o.sep)){return e}if(e===o.sep){return e}if(l&&/^[A-Z]:\\$/i.test(e)){return e}return e.substr(0,e.length-1)}t.safeTrimTrailingSeparator=safeTrimTrailingSeparator},6836:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Path=void 0;const o=n(a(1017));const p=n(a(1849));const l=s(a(9491));const d=process.platform==="win32";class Path{constructor(e){this.segments=[];if(typeof e==="string"){l.default(e,`Parameter 'itemPath' must not be empty`);e=p.safeTrimTrailingSeparator(e);if(!p.hasRoot(e)){this.segments=e.split(o.sep)}else{let t=e;let a=p.dirname(t);while(a!==t){const e=o.basename(t);this.segments.unshift(e);t=a;a=p.dirname(t)}this.segments.unshift(t)}}else{l.default(e.length>0,`Parameter 'itemPath' must not be an empty array`);for(let t=0;t!e.negate));const t={};for(const a of e){const e=p?a.searchPath.toUpperCase():a.searchPath;t[e]="candidate"}const a=[];for(const r of e){const e=p?r.searchPath.toUpperCase():r.searchPath;if(t[e]==="included"){continue}let i=false;let n=e;let o=s.dirname(n);while(o!==n){if(t[o]){i=true;break}n=o;o=s.dirname(n)}if(!i){a.push(r.searchPath);t[e]="included"}}return a}t.getSearchPaths=getSearchPaths;function match(e,t){let a=o.MatchKind.None;for(const r of e){if(r.negate){a&=~r.match(t)}else{a|=r.match(t)}}return a}t.match=match;function partialMatch(e,t){return e.some((e=>!e.negate&&e.partialMatch(t)))}t.partialMatch=partialMatch},4536:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Pattern=void 0;const o=n(a(2037));const p=n(a(1017));const l=n(a(1849));const d=s(a(9491));const c=a(3973);const m=a(1063);const u=a(6836);const h=process.platform==="win32";class Pattern{constructor(e,t=false,a,r){this.negate=false;let i;if(typeof e==="string"){i=e.trim()}else{a=a||[];d.default(a.length,`Parameter 'segments' must not empty`);const t=Pattern.getLiteral(a[0]);d.default(t&&l.hasAbsoluteRoot(t),`Parameter 'segments' first element must be a root path`);i=new u.Path(a).toString().trim();if(e){i=`!${i}`}}while(i.startsWith("!")){this.negate=!this.negate;i=i.substr(1).trim()}i=Pattern.fixupPattern(i,r);this.segments=new u.Path(i).segments;this.trailingSeparator=l.normalizeSeparators(i).endsWith(p.sep);i=l.safeTrimTrailingSeparator(i);let n=false;const s=this.segments.map((e=>Pattern.getLiteral(e))).filter((e=>!n&&!(n=e==="")));this.searchPath=new u.Path(s).toString();this.rootRegExp=new RegExp(Pattern.regExpEscape(s[0]),h?"i":"");this.isImplicitPattern=t;const o={dot:true,nobrace:true,nocase:h,nocomment:true,noext:true,nonegate:true};i=h?i.replace(/\\/g,"/"):i;this.minimatch=new c.Minimatch(i,o)}match(e){if(this.segments[this.segments.length-1]==="**"){e=l.normalizeSeparators(e);if(!e.endsWith(p.sep)&&this.isImplicitPattern===false){e=`${e}${p.sep}`}}else{e=l.safeTrimTrailingSeparator(e)}if(this.minimatch.match(e)){return this.trailingSeparator?m.MatchKind.Directory:m.MatchKind.All}return m.MatchKind.None}partialMatch(e){e=l.safeTrimTrailingSeparator(e);if(l.dirname(e)===e){return this.rootRegExp.test(e)}return this.minimatch.matchOne(e.split(h?/\\+/:/\/+/),this.minimatch.set[0],true)}static globEscape(e){return(h?e:e.replace(/\\/g,"\\\\")).replace(/(\[)(?=[^/]+\])/g,"[[]").replace(/\?/g,"[?]").replace(/\*/g,"[*]")}static fixupPattern(e,t){d.default(e,"pattern cannot be empty");const a=new u.Path(e).segments.map((e=>Pattern.getLiteral(e)));d.default(a.every(((e,t)=>(e!=="."||t===0)&&e!=="..")),`Invalid pattern '${e}'. Relative pathing '.' and '..' is not allowed.`);d.default(!l.hasRoot(e)||a[0],`Invalid pattern '${e}'. Root segment must not contain globs.`);e=l.normalizeSeparators(e);if(e==="."||e.startsWith(`.${p.sep}`)){e=Pattern.globEscape(process.cwd())+e.substr(1)}else if(e==="~"||e.startsWith(`~${p.sep}`)){t=t||o.homedir();d.default(t,"Unable to determine HOME directory");d.default(l.hasAbsoluteRoot(t),`Expected HOME directory to be a rooted path. Actual '${t}'`);e=Pattern.globEscape(t)+e.substr(1)}else if(h&&(e.match(/^[A-Z]:$/i)||e.match(/^[A-Z]:[^\\]/i))){let t=l.ensureAbsoluteRoot("C:\\dummy-root",e.substr(0,2));if(e.length>2&&!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(2)}else if(h&&(e==="\\"||e.match(/^\\[^\\]/))){let t=l.ensureAbsoluteRoot("C:\\dummy-root","\\");if(!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(1)}else{e=l.ensureAbsoluteRoot(Pattern.globEscape(process.cwd()),e)}return l.normalizeSeparators(e)}static getLiteral(e){let t="";for(let a=0;a=0){if(r.length>1){return""}if(r){t+=r;a=i;continue}}}t+=r}return t}static regExpEscape(e){return e.replace(/[[\\^$.|?*+()]/g,"\\$&")}}t.Pattern=Pattern},9117:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SearchState=void 0;class SearchState{constructor(e,t){this.path=e;this.level=t}}t.SearchState=SearchState},5526:function(e,t){"use strict";var a=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.PersonalAccessTokenCredentialHandler=t.BearerCredentialHandler=t.BasicCredentialHandler=void 0;class BasicCredentialHandler{constructor(e,t){this.username=e;this.password=t}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`${this.username}:${this.password}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.BasicCredentialHandler=BasicCredentialHandler;class BearerCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Bearer ${this.token}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.BearerCredentialHandler=BearerCredentialHandler;class PersonalAccessTokenCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`PAT:${this.token}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.PersonalAccessTokenCredentialHandler=PersonalAccessTokenCredentialHandler},6255:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.HttpClient=t.isHttps=t.HttpClientResponse=t.HttpClientError=t.getProxyUrl=t.MediaTypes=t.Headers=t.HttpCodes=void 0;const o=n(a(3685));const p=n(a(5687));const l=n(a(9835));const d=n(a(4294));var c;(function(e){e[e["OK"]=200]="OK";e[e["MultipleChoices"]=300]="MultipleChoices";e[e["MovedPermanently"]=301]="MovedPermanently";e[e["ResourceMoved"]=302]="ResourceMoved";e[e["SeeOther"]=303]="SeeOther";e[e["NotModified"]=304]="NotModified";e[e["UseProxy"]=305]="UseProxy";e[e["SwitchProxy"]=306]="SwitchProxy";e[e["TemporaryRedirect"]=307]="TemporaryRedirect";e[e["PermanentRedirect"]=308]="PermanentRedirect";e[e["BadRequest"]=400]="BadRequest";e[e["Unauthorized"]=401]="Unauthorized";e[e["PaymentRequired"]=402]="PaymentRequired";e[e["Forbidden"]=403]="Forbidden";e[e["NotFound"]=404]="NotFound";e[e["MethodNotAllowed"]=405]="MethodNotAllowed";e[e["NotAcceptable"]=406]="NotAcceptable";e[e["ProxyAuthenticationRequired"]=407]="ProxyAuthenticationRequired";e[e["RequestTimeout"]=408]="RequestTimeout";e[e["Conflict"]=409]="Conflict";e[e["Gone"]=410]="Gone";e[e["TooManyRequests"]=429]="TooManyRequests";e[e["InternalServerError"]=500]="InternalServerError";e[e["NotImplemented"]=501]="NotImplemented";e[e["BadGateway"]=502]="BadGateway";e[e["ServiceUnavailable"]=503]="ServiceUnavailable";e[e["GatewayTimeout"]=504]="GatewayTimeout"})(c=t.HttpCodes||(t.HttpCodes={}));var m;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(m=t.Headers||(t.Headers={}));var u;(function(e){e["ApplicationJson"]="application/json"})(u=t.MediaTypes||(t.MediaTypes={}));function getProxyUrl(e){const t=l.getProxyUrl(new URL(e));return t?t.href:""}t.getProxyUrl=getProxyUrl;const h=[c.MovedPermanently,c.ResourceMoved,c.SeeOther,c.TemporaryRedirect,c.PermanentRedirect];const g=[c.BadGateway,c.ServiceUnavailable,c.GatewayTimeout];const y=["OPTIONS","GET","DELETE","HEAD"];const v=10;const b=5;class HttpClientError extends Error{constructor(e,t){super(e);this.name="HttpClientError";this.statusCode=t;Object.setPrototypeOf(this,HttpClientError.prototype)}}t.HttpClientError=HttpClientError;class HttpClientResponse{constructor(e){this.message=e}readBody(){return s(this,void 0,void 0,(function*(){return new Promise((e=>s(this,void 0,void 0,(function*(){let t=Buffer.alloc(0);this.message.on("data",(e=>{t=Buffer.concat([t,e])}));this.message.on("end",(()=>{e(t.toString())}))}))))}))}readBodyBuffer(){return s(this,void 0,void 0,(function*(){return new Promise((e=>s(this,void 0,void 0,(function*(){const t=[];this.message.on("data",(e=>{t.push(e)}));this.message.on("end",(()=>{e(Buffer.concat(t))}))}))))}))}}t.HttpClientResponse=HttpClientResponse;function isHttps(e){const t=new URL(e);return t.protocol==="https:"}t.isHttps=isHttps;class HttpClient{constructor(e,t,a){this._ignoreSslError=false;this._allowRedirects=true;this._allowRedirectDowngrade=false;this._maxRedirects=50;this._allowRetries=false;this._maxRetries=1;this._keepAlive=false;this._disposed=false;this.userAgent=e;this.handlers=t||[];this.requestOptions=a;if(a){if(a.ignoreSslError!=null){this._ignoreSslError=a.ignoreSslError}this._socketTimeout=a.socketTimeout;if(a.allowRedirects!=null){this._allowRedirects=a.allowRedirects}if(a.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=a.allowRedirectDowngrade}if(a.maxRedirects!=null){this._maxRedirects=Math.max(a.maxRedirects,0)}if(a.keepAlive!=null){this._keepAlive=a.keepAlive}if(a.allowRetries!=null){this._allowRetries=a.allowRetries}if(a.maxRetries!=null){this._maxRetries=a.maxRetries}}}options(e,t){return s(this,void 0,void 0,(function*(){return this.request("OPTIONS",e,null,t||{})}))}get(e,t){return s(this,void 0,void 0,(function*(){return this.request("GET",e,null,t||{})}))}del(e,t){return s(this,void 0,void 0,(function*(){return this.request("DELETE",e,null,t||{})}))}post(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("POST",e,t,a||{})}))}patch(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("PATCH",e,t,a||{})}))}put(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("PUT",e,t,a||{})}))}head(e,t){return s(this,void 0,void 0,(function*(){return this.request("HEAD",e,null,t||{})}))}sendStream(e,t,a,r){return s(this,void 0,void 0,(function*(){return this.request(e,t,a,r)}))}getJson(e,t={}){return s(this,void 0,void 0,(function*(){t[m.Accept]=this._getExistingOrDefaultHeader(t,m.Accept,u.ApplicationJson);const a=yield this.get(e,t);return this._processResponse(a,this.requestOptions)}))}postJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.post(e,r,a);return this._processResponse(i,this.requestOptions)}))}putJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.put(e,r,a);return this._processResponse(i,this.requestOptions)}))}patchJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.patch(e,r,a);return this._processResponse(i,this.requestOptions)}))}request(e,t,a,r){return s(this,void 0,void 0,(function*(){if(this._disposed){throw new Error("Client has already been disposed.")}const i=new URL(t);let n=this._prepareRequest(e,i,r);const s=this._allowRetries&&y.includes(e)?this._maxRetries+1:1;let o=0;let p;do{p=yield this.requestRaw(n,a);if(p&&p.message&&p.message.statusCode===c.Unauthorized){let e;for(const t of this.handlers){if(t.canHandleAuthentication(p)){e=t;break}}if(e){return e.handleAuthentication(this,n,a)}else{return p}}let t=this._maxRedirects;while(p.message.statusCode&&h.includes(p.message.statusCode)&&this._allowRedirects&&t>0){const s=p.message.headers["location"];if(!s){break}const o=new URL(s);if(i.protocol==="https:"&&i.protocol!==o.protocol&&!this._allowRedirectDowngrade){throw new Error("Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.")}yield p.readBody();if(o.hostname!==i.hostname){for(const e in r){if(e.toLowerCase()==="authorization"){delete r[e]}}}n=this._prepareRequest(e,o,r);p=yield this.requestRaw(n,a);t--}if(!p.message.statusCode||!g.includes(p.message.statusCode)){return p}o+=1;if(o{function callbackForResult(e,t){if(e){r(e)}else if(!t){r(new Error("Unknown error"))}else{a(t)}}this.requestRawWithCallback(e,t,callbackForResult)}))}))}requestRawWithCallback(e,t,a){if(typeof t==="string"){if(!e.options.headers){e.options.headers={}}e.options.headers["Content-Length"]=Buffer.byteLength(t,"utf8")}let r=false;function handleResult(e,t){if(!r){r=true;a(e,t)}}const i=e.httpModule.request(e.options,(e=>{const t=new HttpClientResponse(e);handleResult(undefined,t)}));let n;i.on("socket",(e=>{n=e}));i.setTimeout(this._socketTimeout||3*6e4,(()=>{if(n){n.end()}handleResult(new Error(`Request timeout: ${e.options.path}`))}));i.on("error",(function(e){handleResult(e)}));if(t&&typeof t==="string"){i.write(t,"utf8")}if(t&&typeof t!=="string"){t.on("close",(function(){i.end()}));t.pipe(i)}else{i.end()}}getAgent(e){const t=new URL(e);return this._getAgent(t)}_prepareRequest(e,t,a){const r={};r.parsedUrl=t;const i=r.parsedUrl.protocol==="https:";r.httpModule=i?p:o;const n=i?443:80;r.options={};r.options.host=r.parsedUrl.hostname;r.options.port=r.parsedUrl.port?parseInt(r.parsedUrl.port):n;r.options.path=(r.parsedUrl.pathname||"")+(r.parsedUrl.search||"");r.options.method=e;r.options.headers=this._mergeHeaders(a);if(this.userAgent!=null){r.options.headers["user-agent"]=this.userAgent}r.options.agent=this._getAgent(r.parsedUrl);if(this.handlers){for(const e of this.handlers){e.prepareRequest(r.options)}}return r}_mergeHeaders(e){if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},lowercaseKeys(this.requestOptions.headers),lowercaseKeys(e||{}))}return lowercaseKeys(e||{})}_getExistingOrDefaultHeader(e,t,a){let r;if(this.requestOptions&&this.requestOptions.headers){r=lowercaseKeys(this.requestOptions.headers)[t]}return e[t]||r||a}_getAgent(e){let t;const a=l.getProxyUrl(e);const r=a&&a.hostname;if(this._keepAlive&&r){t=this._proxyAgent}if(this._keepAlive&&!r){t=this._agent}if(t){return t}const i=e.protocol==="https:";let n=100;if(this.requestOptions){n=this.requestOptions.maxSockets||o.globalAgent.maxSockets}if(a&&a.hostname){const e={maxSockets:n,keepAlive:this._keepAlive,proxy:Object.assign(Object.assign({},(a.username||a.password)&&{proxyAuth:`${a.username}:${a.password}`}),{host:a.hostname,port:a.port})};let r;const s=a.protocol==="https:";if(i){r=s?d.httpsOverHttps:d.httpsOverHttp}else{r=s?d.httpOverHttps:d.httpOverHttp}t=r(e);this._proxyAgent=t}if(this._keepAlive&&!t){const e={keepAlive:this._keepAlive,maxSockets:n};t=i?new p.Agent(e):new o.Agent(e);this._agent=t}if(!t){t=i?p.globalAgent:o.globalAgent}if(i&&this._ignoreSslError){t.options=Object.assign(t.options||{},{rejectUnauthorized:false})}return t}_performExponentialBackoff(e){return s(this,void 0,void 0,(function*(){e=Math.min(v,e);const t=b*Math.pow(2,e);return new Promise((e=>setTimeout((()=>e()),t)))}))}_processResponse(e,t){return s(this,void 0,void 0,(function*(){return new Promise(((a,r)=>s(this,void 0,void 0,(function*(){const i=e.message.statusCode||0;const n={statusCode:i,result:null,headers:{}};if(i===c.NotFound){a(n)}function dateTimeDeserializer(e,t){if(typeof t==="string"){const e=new Date(t);if(!isNaN(e.valueOf())){return e}}return t}let s;let o;try{o=yield e.readBody();if(o&&o.length>0){if(t&&t.deserializeDates){s=JSON.parse(o,dateTimeDeserializer)}else{s=JSON.parse(o)}n.result=s}n.headers=e.message.headers}catch(e){}if(i>299){let e;if(s&&s.message){e=s.message}else if(o&&o.length>0){e=o}else{e=`Failed request: (${i})`}const t=new HttpClientError(e,i);t.result=n.result;r(t)}else{a(n)}}))))}))}}t.HttpClient=HttpClient;const lowercaseKeys=e=>Object.keys(e).reduce(((t,a)=>(t[a.toLowerCase()]=e[a],t)),{})},9835:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.checkBypass=t.getProxyUrl=void 0;function getProxyUrl(e){const t=e.protocol==="https:";if(checkBypass(e)){return undefined}const a=(()=>{if(t){return process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{return process.env["http_proxy"]||process.env["HTTP_PROXY"]}})();if(a){try{return new URL(a)}catch(e){if(!a.startsWith("http://")&&!a.startsWith("https://"))return new URL(`http://${a}`)}}else{return undefined}}t.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}const t=e.hostname;if(isLoopbackAddress(t)){return true}const a=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!a){return false}let r;if(e.port){r=Number(e.port)}else if(e.protocol==="http:"){r=80}else if(e.protocol==="https:"){r=443}const i=[e.hostname.toUpperCase()];if(typeof r==="number"){i.push(`${i[0]}:${r}`)}for(const e of a.split(",").map((e=>e.trim().toUpperCase())).filter((e=>e))){if(e==="*"||i.some((t=>t===e||t.endsWith(`.${e}`)||e.startsWith(".")&&t.endsWith(`${e}`)))){return true}}return false}t.checkBypass=checkBypass;function isLoopbackAddress(e){const t=e.toLowerCase();return t==="localhost"||t.startsWith("127.")||t.startsWith("[::1]")||t.startsWith("[0:0:0:0:0:0:0:1]")}},1962:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o;Object.defineProperty(t,"__esModule",{value:true});t.getCmdPath=t.tryGetExecutablePath=t.isRooted=t.isDirectory=t.exists=t.READONLY=t.UV_FS_O_EXLOCK=t.IS_WINDOWS=t.unlink=t.symlink=t.stat=t.rmdir=t.rm=t.rename=t.readlink=t.readdir=t.open=t.mkdir=t.lstat=t.copyFile=t.chmod=void 0;const p=n(a(7147));const l=n(a(1017));o=p.promises,t.chmod=o.chmod,t.copyFile=o.copyFile,t.lstat=o.lstat,t.mkdir=o.mkdir,t.open=o.open,t.readdir=o.readdir,t.readlink=o.readlink,t.rename=o.rename,t.rm=o.rm,t.rmdir=o.rmdir,t.stat=o.stat,t.symlink=o.symlink,t.unlink=o.unlink;t.IS_WINDOWS=process.platform==="win32";t.UV_FS_O_EXLOCK=268435456;t.READONLY=p.constants.O_RDONLY;function exists(e){return s(this,void 0,void 0,(function*(){try{yield t.stat(e)}catch(e){if(e.code==="ENOENT"){return false}throw e}return true}))}t.exists=exists;function isDirectory(e,a=false){return s(this,void 0,void 0,(function*(){const r=a?yield t.stat(e):yield t.lstat(e);return r.isDirectory()}))}t.isDirectory=isDirectory;function isRooted(e){e=normalizeSeparators(e);if(!e){throw new Error('isRooted() parameter "p" cannot be empty')}if(t.IS_WINDOWS){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.isRooted=isRooted;function tryGetExecutablePath(e,a){return s(this,void 0,void 0,(function*(){let r=undefined;try{r=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(r&&r.isFile()){if(t.IS_WINDOWS){const t=l.extname(e).toUpperCase();if(a.some((e=>e.toUpperCase()===t))){return e}}else{if(isUnixExecutable(r)){return e}}}const i=e;for(const n of a){e=i+n;r=undefined;try{r=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(r&&r.isFile()){if(t.IS_WINDOWS){try{const a=l.dirname(e);const r=l.basename(e).toUpperCase();for(const i of yield t.readdir(a)){if(r===i.toUpperCase()){e=l.join(a,i);break}}}catch(t){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${t}`)}return e}else{if(isUnixExecutable(r)){return e}}}}return""}))}t.tryGetExecutablePath=tryGetExecutablePath;function normalizeSeparators(e){e=e||"";if(t.IS_WINDOWS){e=e.replace(/\//g,"\\");return e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}function isUnixExecutable(e){return(e.mode&1)>0||(e.mode&8)>0&&e.gid===process.getgid()||(e.mode&64)>0&&e.uid===process.getuid()}function getCmdPath(){var e;return(e=process.env["COMSPEC"])!==null&&e!==void 0?e:`cmd.exe`}t.getCmdPath=getCmdPath},7436:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.findInPath=t.which=t.mkdirP=t.rmRF=t.mv=t.cp=void 0;const o=a(9491);const p=n(a(1017));const l=n(a(1962));function cp(e,t,a={}){return s(this,void 0,void 0,(function*(){const{force:r,recursive:i,copySourceDirectory:n}=readCopyOptions(a);const s=(yield l.exists(t))?yield l.stat(t):null;if(s&&s.isFile()&&!r){return}const o=s&&s.isDirectory()&&n?p.join(t,p.basename(e)):t;if(!(yield l.exists(e))){throw new Error(`no such file or directory: ${e}`)}const d=yield l.stat(e);if(d.isDirectory()){if(!i){throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`)}else{yield cpDirRecursive(e,o,0,r)}}else{if(p.relative(e,o)===""){throw new Error(`'${o}' and '${e}' are the same file`)}yield copyFile(e,o,r)}}))}t.cp=cp;function mv(e,t,a={}){return s(this,void 0,void 0,(function*(){if(yield l.exists(t)){let r=true;if(yield l.isDirectory(t)){t=p.join(t,p.basename(e));r=yield l.exists(t)}if(r){if(a.force==null||a.force){yield rmRF(t)}else{throw new Error("Destination already exists")}}}yield mkdirP(p.dirname(t));yield l.rename(e,t)}))}t.mv=mv;function rmRF(e){return s(this,void 0,void 0,(function*(){if(l.IS_WINDOWS){if(/[*"<>|]/.test(e)){throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows')}}try{yield l.rm(e,{force:true,maxRetries:3,recursive:true,retryDelay:300})}catch(e){throw new Error(`File was unable to be removed ${e}`)}}))}t.rmRF=rmRF;function mkdirP(e){return s(this,void 0,void 0,(function*(){o.ok(e,"a path argument must be provided");yield l.mkdir(e,{recursive:true})}))}t.mkdirP=mkdirP;function which(e,t){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}if(t){const t=yield which(e,false);if(!t){if(l.IS_WINDOWS){throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`)}else{throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`)}}return t}const a=yield findInPath(e);if(a&&a.length>0){return a[0]}return""}))}t.which=which;function findInPath(e){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}const t=[];if(l.IS_WINDOWS&&process.env["PATHEXT"]){for(const e of process.env["PATHEXT"].split(p.delimiter)){if(e){t.push(e)}}}if(l.isRooted(e)){const a=yield l.tryGetExecutablePath(e,t);if(a){return[a]}return[]}if(e.includes(p.sep)){return[]}const a=[];if(process.env.PATH){for(const e of process.env.PATH.split(p.delimiter)){if(e){a.push(e)}}}const r=[];for(const i of a){const a=yield l.tryGetExecutablePath(p.join(i,e),t);if(a){r.push(a)}}return r}))}t.findInPath=findInPath;function readCopyOptions(e){const t=e.force==null?true:e.force;const a=Boolean(e.recursive);const r=e.copySourceDirectory==null?true:Boolean(e.copySourceDirectory);return{force:t,recursive:a,copySourceDirectory:r}}function cpDirRecursive(e,t,a,r){return s(this,void 0,void 0,(function*(){if(a>=255)return;a++;yield mkdirP(t);const i=yield l.readdir(e);for(const n of i){const i=`${e}/${n}`;const s=`${t}/${n}`;const o=yield l.lstat(i);if(o.isDirectory()){yield cpDirRecursive(i,s,a,r)}else{yield copyFile(i,s,r)}}yield l.chmod(t,(yield l.stat(e)).mode)}))}function copyFile(e,t,a){return s(this,void 0,void 0,(function*(){if((yield l.lstat(e)).isSymbolicLink()){try{yield l.lstat(t);yield l.unlink(t)}catch(e){if(e.code==="EPERM"){yield l.chmod(t,"0666");yield l.unlink(t)}}const a=yield l.readlink(e);yield l.symlink(a,t,l.IS_WINDOWS?"junction":null)}else if(!(yield l.exists(t))||a){yield l.copyFile(e,t)}}))}},2557:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a=new WeakMap;const r=new WeakMap;class AbortSignal{constructor(){this.onabort=null;a.set(this,[]);r.set(this,false)}get aborted(){if(!r.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}return r.get(this)}static get none(){return new AbortSignal}addEventListener(e,t){if(!a.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}const r=a.get(this);r.push(t)}removeEventListener(e,t){if(!a.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}const r=a.get(this);const i=r.indexOf(t);if(i>-1){r.splice(i,1)}}dispatchEvent(e){throw new Error("This is a stub dispatchEvent implementation that should not be used. It only exists for type-checking purposes.")}}function abortSignal(e){if(e.aborted){return}if(e.onabort){e.onabort.call(e)}const t=a.get(e);if(t){t.slice().forEach((t=>{t.call(e,{type:"abort"})}))}r.set(e,true)}class AbortError extends Error{constructor(e){super(e);this.name="AbortError"}}class AbortController{constructor(e){this._signal=new AbortSignal;if(!e){return}if(!Array.isArray(e)){e=arguments}for(const t of e){if(t.aborted){this.abort()}else{t.addEventListener("abort",(()=>{this.abort()}))}}}get signal(){return this._signal}abort(){abortSignal(this._signal)}static timeout(e){const t=new AbortSignal;const a=setTimeout(abortSignal,e,t);if(typeof a.unref==="function"){a.unref()}return t}}t.AbortController=AbortController;t.AbortError=AbortError;t.AbortSignal=AbortSignal},9645:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(1333);class AzureKeyCredential{get key(){return this._key}constructor(e){if(!e){throw new Error("key must be a non-empty string")}this._key=e}update(e){this._key=e}}class AzureNamedKeyCredential{get key(){return this._key}get name(){return this._name}constructor(e,t){if(!e||!t){throw new TypeError("name and key must be non-empty strings")}this._name=e;this._key=t}update(e,t){if(!e||!t){throw new TypeError("newName and newKey must be non-empty strings")}this._name=e;this._key=t}}function isNamedKeyCredential(e){return r.isObjectWithProperties(e,["name","key"])&&typeof e.key==="string"&&typeof e.name==="string"}class AzureSASCredential{get signature(){return this._signature}constructor(e){if(!e){throw new Error("shared access signature must be a non-empty string")}this._signature=e}update(e){if(!e){throw new Error("shared access signature must be a non-empty string")}this._signature=e}}function isSASCredential(e){return r.isObjectWithProperties(e,["signature"])&&typeof e.signature==="string"}function isTokenCredential(e){const t=e;return t&&typeof t.getToken==="function"&&(t.signRequest===undefined||t.getToken.length>0)}t.AzureKeyCredential=AzureKeyCredential;t.AzureNamedKeyCredential=AzureNamedKeyCredential;t.AzureSASCredential=AzureSASCredential;t.isNamedKeyCredential=isNamedKeyCredential;t.isSASCredential=isSASCredential;t.isTokenCredential=isTokenCredential},4607:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5840);var i=a(3837);var n=a(2107);var s=a(6189);var o=a(1333);var p=a(3233);var l=a(9645);var d=a(2037);var c=a(3685);var m=a(5687);var u=a(2557);var h=a(4294);var g=a(2781);var y=a(6279);var v=a(467);var b=a(4175);function _interopDefaultLegacy(e){return e&&typeof e==="object"&&"default"in e?e:{default:e}}function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(a){if(a!=="default"){var r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:true,get:function(){return e[a]}})}}))}t["default"]=e;return Object.freeze(t)}var x=_interopNamespace(s);var w=_interopNamespace(d);var S=_interopNamespace(c);var N=_interopNamespace(m);var T=_interopNamespace(h);var E=_interopDefaultLegacy(y);var _=_interopDefaultLegacy(v);function getHeaderKey(e){return e.toLowerCase()}function isHttpHeadersLike(e){if(e&&typeof e==="object"){const t=e;if(typeof t.rawHeaders==="function"&&typeof t.clone==="function"&&typeof t.get==="function"&&typeof t.set==="function"&&typeof t.contains==="function"&&typeof t.remove==="function"&&typeof t.headersArray==="function"&&typeof t.headerValues==="function"&&typeof t.headerNames==="function"&&typeof t.toJson==="function"){return true}}return false}class HttpHeaders{constructor(e){this._headersMap={};if(e){for(const t in e){this.set(t,e[t])}}}set(e,t){this._headersMap[getHeaderKey(e)]={name:e,value:t.toString()}}get(e){const t=this._headersMap[getHeaderKey(e)];return!t?undefined:t.value}contains(e){return!!this._headersMap[getHeaderKey(e)]}remove(e){const t=this.contains(e);delete this._headersMap[getHeaderKey(e)];return t}rawHeaders(){return this.toJson({preserveCase:true})}headersArray(){const e=[];for(const t in this._headersMap){e.push(this._headersMap[t])}return e}headerNames(){const e=[];const t=this.headersArray();for(let a=0;a{a=a.then(e)}));return a}function promiseToCallback(e){if(typeof e.then!=="function"){throw new Error("The provided input is not a Promise.")}return t=>{e.then((e=>t(undefined,e))).catch((e=>{t(e)}))}}function promiseToServiceCallback(e){if(typeof e.then!=="function"){throw new Error("The provided input is not a Promise.")}return t=>{e.then((e=>process.nextTick(t,undefined,e.parsedBody,e.request,e))).catch((e=>{process.nextTick(t,e)}))}}function prepareXMLRootList(e,t,a,r){if(!Array.isArray(e)){e=[e]}if(!a||!r){return{[t]:e}}const i={[t]:e};i[C]={[a]:r};return i}function applyMixins(e,t){const a=e;t.forEach((e=>{Object.getOwnPropertyNames(e.prototype).forEach((t=>{a.prototype[t]=e.prototype[t]}))}))}const D=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function isDuration(e){return D.test(e)}function replaceAll(e,t,a){return!e||!t?e:e.split(t).join(a||"")}function isPrimitiveType(e){return typeof e!=="object"&&typeof e!=="function"||e===null}function getEnvironmentValue(e){if(process.env[e]){return process.env[e]}else if(process.env[e.toLowerCase()]){return process.env[e.toLowerCase()]}return undefined}function isObject(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}class Serializer{constructor(e={},t){this.modelMappers=e;this.isXML=t}validateConstraints(e,t,a){const failValidation=(e,r)=>{throw new Error(`"${a}" with value "${t}" should satisfy the constraint "${e}": ${r}.`)};if(e.constraints&&t!=undefined){const a=t;const{ExclusiveMaximum:r,ExclusiveMinimum:i,InclusiveMaximum:n,InclusiveMinimum:s,MaxItems:o,MaxLength:p,MinItems:l,MinLength:d,MultipleOf:c,Pattern:m,UniqueItems:u}=e.constraints;if(r!=undefined&&a>=r){failValidation("ExclusiveMaximum",r)}if(i!=undefined&&a<=i){failValidation("ExclusiveMinimum",i)}if(n!=undefined&&a>n){failValidation("InclusiveMaximum",n)}if(s!=undefined&&ao){failValidation("MaxItems",o)}if(p!=undefined&&h.length>p){failValidation("MaxLength",p)}if(l!=undefined&&h.lengtha.indexOf(e)!==t))){failValidation("UniqueItems",u)}}}serialize(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};let p={};const l=e.type.name;if(!a){a=e.serializedName}if(l.match(/^Sequence$/i)!==null){p=[]}if(e.isConstant){t=e.defaultValue}const{required:d,nullable:c}=e;if(d&&c&&t===undefined){throw new Error(`${a} cannot be undefined.`)}if(d&&!c&&t==undefined){throw new Error(`${a} cannot be null or undefined.`)}if(!d&&c===false&&t===null){throw new Error(`${a} cannot be null.`)}if(t==undefined){p=t}else{if(l.match(/^any$/i)!==null){p=t}else if(l.match(/^(Number|String|Boolean|Object|Stream|Uuid)$/i)!==null){p=serializeBasicTypes(l,a,t)}else if(l.match(/^Enum$/i)!==null){const r=e;p=serializeEnumType(a,r.type.allowedValues,t)}else if(l.match(/^(Date|DateTime|TimeSpan|DateTimeRfc1123|UnixTime)$/i)!==null){p=serializeDateTypes(l,t,a)}else if(l.match(/^ByteArray$/i)!==null){p=serializeByteArrayType(a,t)}else if(l.match(/^Base64Url$/i)!==null){p=serializeBase64UrlType(a,t)}else if(l.match(/^Sequence$/i)!==null){p=serializeSequenceType(this,e,t,a,Boolean(this.isXML),o)}else if(l.match(/^Dictionary$/i)!==null){p=serializeDictionaryType(this,e,t,a,Boolean(this.isXML),o)}else if(l.match(/^Composite$/i)!==null){p=serializeCompositeType(this,e,t,a,Boolean(this.isXML),o)}}return p}deserialize(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};if(t==undefined){if(this.isXML&&e.type.name==="Sequence"&&!e.xmlIsWrapped){t=[]}if(e.defaultValue!==undefined){t=e.defaultValue}return t}let p;const l=e.type.name;if(!a){a=e.serializedName}if(l.match(/^Composite$/i)!==null){p=deserializeCompositeType(this,e,t,a,o)}else{if(this.isXML){const e=o.xmlCharKey;const a=t;if(a[C]!=undefined&&a[e]!=undefined){t=a[e]}}if(l.match(/^Number$/i)!==null){p=parseFloat(t);if(isNaN(p)){p=t}}else if(l.match(/^Boolean$/i)!==null){if(t==="true"){p=true}else if(t==="false"){p=false}else{p=t}}else if(l.match(/^(String|Enum|Object|Stream|Uuid|TimeSpan|any)$/i)!==null){p=t}else if(l.match(/^(Date|DateTime|DateTimeRfc1123)$/i)!==null){p=new Date(t)}else if(l.match(/^UnixTime$/i)!==null){p=unixTimeToDate(t)}else if(l.match(/^ByteArray$/i)!==null){p=decodeString(t)}else if(l.match(/^Base64Url$/i)!==null){p=base64UrlToByteArray(t)}else if(l.match(/^Sequence$/i)!==null){p=deserializeSequenceType(this,e,t,a,o)}else if(l.match(/^Dictionary$/i)!==null){p=deserializeDictionaryType(this,e,t,a,o)}}if(e.isConstant){p=e.defaultValue}return p}}function trimEnd(e,t){let a=e.length;while(a-1>=0&&e[a-1]===t){--a}return e.substr(0,a)}function bufferToBase64Url(e){if(!e){return undefined}if(!(e instanceof Uint8Array)){throw new Error(`Please provide an input of type Uint8Array for converting to Base64Url.`)}const t=encodeByteArray(e);return trimEnd(t,"=").replace(/\+/g,"-").replace(/\//g,"_")}function base64UrlToByteArray(e){if(!e){return undefined}if(e&&typeof e.valueOf()!=="string"){throw new Error("Please provide an input of type string for converting to Uint8Array")}e=e.replace(/-/g,"+").replace(/_/g,"/");return decodeString(e)}function splitSerializeName(e){const t=[];let a="";if(e){const r=e.split(".");for(const e of r){if(e.charAt(e.length-1)==="\\"){a+=e.substr(0,e.length-1)+"."}else{a+=e;t.push(a);a=""}}}return t}function dateToUnixTime(e){if(!e){return undefined}if(typeof e.valueOf()==="string"){e=new Date(e)}return Math.floor(e.getTime()/1e3)}function unixTimeToDate(e){if(!e){return undefined}return new Date(e*1e3)}function serializeBasicTypes(e,t,a){if(a!==null&&a!==undefined){if(e.match(/^Number$/i)!==null){if(typeof a!=="number"){throw new Error(`${t} with value ${a} must be of type number.`)}}else if(e.match(/^String$/i)!==null){if(typeof a.valueOf()!=="string"){throw new Error(`${t} with value "${a}" must be of type string.`)}}else if(e.match(/^Uuid$/i)!==null){if(!(typeof a.valueOf()==="string"&&isValidUuid(a))){throw new Error(`${t} with value "${a}" must be of type string and a valid uuid.`)}}else if(e.match(/^Boolean$/i)!==null){if(typeof a!=="boolean"){throw new Error(`${t} with value ${a} must be of type boolean.`)}}else if(e.match(/^Stream$/i)!==null){const e=typeof a;if(e!=="string"&&e!=="function"&&!(a instanceof ArrayBuffer)&&!ArrayBuffer.isView(a)&&!((typeof Blob==="function"||typeof Blob==="object")&&a instanceof Blob)){throw new Error(`${t} must be a string, Blob, ArrayBuffer, ArrayBufferView, or a function returning NodeJS.ReadableStream.`)}}}return a}function serializeEnumType(e,t,a){if(!t){throw new Error(`Please provide a set of allowedValues to validate ${e} as an Enum Type.`)}const r=t.some((e=>{if(typeof e.valueOf()==="string"){return e.toLowerCase()===a.toLowerCase()}return e===a}));if(!r){throw new Error(`${a} is not a valid value for ${e}. The valid values are: ${JSON.stringify(t)}.`)}return a}function serializeByteArrayType(e,t){let a="";if(t!=undefined){if(!(t instanceof Uint8Array)){throw new Error(`${e} must be of type Uint8Array.`)}a=encodeByteArray(t)}return a}function serializeBase64UrlType(e,t){let a="";if(t!=undefined){if(!(t instanceof Uint8Array)){throw new Error(`${e} must be of type Uint8Array.`)}a=bufferToBase64Url(t)||""}return a}function serializeDateTypes(e,t,a){if(t!=undefined){if(e.match(/^Date$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in ISO8601 format.`)}t=t instanceof Date?t.toISOString().substring(0,10):new Date(t).toISOString().substring(0,10)}else if(e.match(/^DateTime$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in ISO8601 format.`)}t=t instanceof Date?t.toISOString():new Date(t).toISOString()}else if(e.match(/^DateTimeRfc1123$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in RFC-1123 format.`)}t=t instanceof Date?t.toUTCString():new Date(t).toUTCString()}else if(e.match(/^UnixTime$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in RFC-1123/ISO8601 format `+`for it to be serialized in UnixTime/Epoch format.`)}t=dateToUnixTime(t)}else if(e.match(/^TimeSpan$/i)!==null){if(!isDuration(t)){throw new Error(`${a} must be a string in ISO 8601 format. Instead was "${t}".`)}}}return t}function serializeSequenceType(e,t,a,r,i,n){if(!Array.isArray(a)){throw new Error(`${r} must be of type Array.`)}const s=t.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 ${r}.`)}const o=[];for(let t=0;te!==i));if(o){s[i]=e.serialize(p,a[i],r+'["'+i+'"]',n)}}}return s}return a}function getXmlObjectValue(e,t,a,r){if(!a||!e.xmlNamespace){return t}const i=e.xmlNamespacePrefix?`xmlns:${e.xmlNamespacePrefix}`:"xmlns";const n={[i]:e.xmlNamespace};if(["Composite"].includes(e.type.name)){if(t[C]){return t}else{const e=Object.assign({},t);e[C]=n;return e}}const s={};s[r.xmlCharKey]=t;s[C]=n;return s}function isSpecialXmlProperty(e,t){return[C,t.xmlCharKey].includes(e)}function deserializeCompositeType(e,t,a,r,i){var n,s;const o=(n=i.xmlCharKey)!==null&&n!==void 0?n:O;if(getPolymorphicDiscriminatorRecursively(e,t)){t=getPolymorphicMapper(e,t,a,"serializedName")}const p=resolveModelProperties(e,t,r);let l={};const d=[];for(const n of Object.keys(p)){const c=p[n];const m=splitSerializeName(p[n].serializedName);d.push(m[0]);const{serializedName:u,xmlName:h,xmlElementName:g}=c;let y=r;if(u!==""&&u!==undefined){y=r+"."+u}const v=c.headerCollectionPrefix;if(v){const t={};for(const r of Object.keys(a)){if(r.startsWith(v)){t[r.substring(v.length)]=e.deserialize(c.type.value,a[r],y,i)}d.push(r)}l[n]=t}else if(e.isXML){if(c.xmlIsAttribute&&a[C]){l[n]=e.deserialize(c,a[C][h],y,i)}else if(c.xmlIsMsText){if(a[o]!==undefined){l[n]=a[o]}else if(typeof a==="string"){l[n]=a}}else{const t=g||h||u;if(c.xmlIsWrapped){const t=a[h];const r=(s=t===null||t===void 0?void 0:t[g])!==null&&s!==void 0?s:[];l[n]=e.deserialize(c,r,y,i);d.push(h)}else{const r=a[t];l[n]=e.deserialize(c,r,y,i);d.push(t)}}}else{let r;let s=a;for(const e of m){if(!s)break;s=s[e]}r=s;const o=t.type.polymorphicDiscriminator;if(o&&n===o.clientName&&r==undefined){r=t.serializedName}let d;if(Array.isArray(a[n])&&p[n].serializedName===""){r=a[n];const t=e.deserialize(c,r,y,i);for(const[e,a]of Object.entries(l)){if(!Object.prototype.hasOwnProperty.call(t,e)){t[e]=a}}l=t}else if(r!==undefined||c.defaultValue!==undefined){d=e.deserialize(c,r,y,i);l[n]=d}}}const c=t.type.additionalProperties;if(c){const isAdditionalProperty=e=>{for(const t in p){const a=splitSerializeName(p[t].serializedName);if(a[0]===e){return false}}return true};for(const t in a){if(isAdditionalProperty(t)){l[t]=e.deserialize(c,a[t],r+'["'+t+'"]',i)}}}else if(a){for(const e of Object.keys(a)){if(l[e]===undefined&&!d.includes(e)&&!isSpecialXmlProperty(e,i)){l[e]=a[e]}}}return l}function deserializeDictionaryType(e,t,a,r,i){const n=t.type.value;if(!n||typeof n!=="object"){throw new Error(`"value" metadata for a Dictionary must be defined in the `+`mapper and it must of type "object" in ${r}`)}if(a){const t={};for(const s of Object.keys(a)){t[s]=e.deserialize(n,a[s],r,i)}return t}return a}function deserializeSequenceType(e,t,a,r,i){const n=t.type.element;if(!n||typeof n!=="object"){throw new Error(`element" metadata for an Array must be defined in the `+`mapper and it must of type "object" in ${r}`)}if(a){if(!Array.isArray(a)){a=[a]}const t=[];for(let s=0;s0}keys(){return Object.keys(this._rawQuery)}set(e,t){const a=t;if(e){if(a!==undefined&&a!==null){const t=Array.isArray(a)?a:a.toString();this._rawQuery[e]=t}else{delete this._rawQuery[e]}}}get(e){return e?this._rawQuery[e]:undefined}toString(){let e="";for(const t in this._rawQuery){if(e){e+="&"}const a=this._rawQuery[t];if(Array.isArray(a)){const r=[];for(const e of a){r.push(`${t}=${e}`)}e+=r.join("&")}else{e+=`${t}=${a}`}}return e}static parse(e){const t=new URLQuery;if(e){if(e.startsWith("?")){e=e.substring(1)}let a="ParameterName";let r="";let i="";for(let n=0;nisAlphaNumericCharacter(e)))}function readUntilCharacter(e,...t){return readWhile(e,(e=>t.indexOf(e)===-1))}function nextScheme(e){const t=readWhileLetterOrDigit(e);e._currentToken=URLToken.scheme(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else{e._currentState="HOST"}}function nextSchemeOrHost(e){const t=readUntilCharacter(e,":","/","?");if(!hasCurrentCharacter(e)){e._currentToken=URLToken.host(t);e._currentState="DONE"}else if(getCurrentCharacter(e)===":"){if(peekCharacters(e,3)==="://"){e._currentToken=URLToken.scheme(t);e._currentState="HOST"}else{e._currentToken=URLToken.host(t);e._currentState="PORT"}}else{e._currentToken=URLToken.host(t);if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}}function nextHost(e){if(peekCharacters(e,3)==="://"){nextCharacter(e,3)}const t=readUntilCharacter(e,":","/","?");e._currentToken=URLToken.host(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else if(getCurrentCharacter(e)===":"){e._currentState="PORT"}else if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}function nextPort(e){if(getCurrentCharacter(e)===":"){nextCharacter(e)}const t=readUntilCharacter(e,"/","?");e._currentToken=URLToken.port(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}function nextPath(e){const t=readUntilCharacter(e,"?");e._currentToken=URLToken.path(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else{e._currentState="QUERY"}}function nextQuery(e){if(getCurrentCharacter(e)==="?"){nextCharacter(e)}const t=readRemaining(e);e._currentToken=URLToken.query(t);e._currentState="DONE"}function createProxyAgent(e,t,a){const r=URLBuilder.parse(t.host).getHost();if(!r){throw new Error("Expecting a non-empty host in proxy settings.")}if(!isValidPort(t.port)){throw new Error("Expecting a valid port number in the range of [0, 65535] in proxy settings.")}const i={proxy:{host:r,port:t.port,headers:a&&a.rawHeaders()||{}}};if(t.username&&t.password){i.proxy.proxyAuth=`${t.username}:${t.password}`}else if(t.username){i.proxy.proxyAuth=`${t.username}`}const n=isUrlHttps(e);const s=isUrlHttps(t.host);const o={isHttps:n,agent:createTunnel(n,s,i)};return o}function isUrlHttps(e){const t=URLBuilder.parse(e).getScheme()||"";return t.toLowerCase()==="https"}function createTunnel(e,t,a){if(e&&t){return T.httpsOverHttps(a)}else if(e&&!t){return T.httpsOverHttp(a)}else if(!e&&t){return T.httpOverHttps(a)}else{return T.httpOverHttp(a)}}function isValidPort(e){return 0<=e&&e<=65535}const I="REDACTED";const B=["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","WWW-Authenticate"];const L=["api-version"];class Sanitizer{constructor({allowedHeaderNames:e=[],allowedQueryParameters:t=[]}={}){e=Array.isArray(e)?B.concat(e):B;t=Array.isArray(t)?L.concat(t):L;this.allowedHeaderNames=new Set(e.map((e=>e.toLowerCase())));this.allowedQueryParameters=new Set(t.map((e=>e.toLowerCase())))}sanitize(e){const t=new Set;return JSON.stringify(e,((e,a)=>{if(a instanceof Error){return Object.assign(Object.assign({},a),{name:a.name,message:a.message})}if(e==="_headersMap"){return this.sanitizeHeaders(a)}else if(e==="url"){return this.sanitizeUrl(a)}else if(e==="query"){return this.sanitizeQuery(a)}else if(e==="body"){return undefined}else if(e==="response"){return undefined}else if(e==="operationSpec"){return undefined}else if(Array.isArray(a)||isObject(a)){if(t.has(a)){return"[Circular]"}t.add(a)}return a}),2)}sanitizeHeaders(e){return this.sanitizeObject(e,this.allowedHeaderNames,((e,t)=>e[t].value))}sanitizeQuery(e){return this.sanitizeObject(e,this.allowedQueryParameters,((e,t)=>e[t]))}sanitizeObject(e,t,a){if(typeof e!=="object"||e===null){return e}const r={};for(const i of Object.keys(e)){if(t.has(i.toLowerCase())){r[i]=a(e,i)}else{r[i]=I}}return r}sanitizeUrl(e){if(typeof e!=="string"||e===null){return e}const t=URLBuilder.parse(e);const a=t.getQuery();if(!a){return e}const r=URLQuery.parse(a);for(const e of r.keys()){if(!this.allowedQueryParameters.has(e.toLowerCase())){r.set(e,I)}}t.setQuery(r.toString());return t.toString()}}const M=i.inspect.custom;const k=new Sanitizer;class RestError extends Error{constructor(e,t,a,r,i){super(e);this.name="RestError";this.code=t;this.statusCode=a;this.request=r;this.response=i;Object.setPrototypeOf(this,RestError.prototype)}[M](){return`RestError: ${this.message} \n ${k.sanitize(this)}`}}RestError.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR";RestError.PARSE_ERROR="PARSE_ERROR";const z=p.createClientLogger("core-http");function getCachedAgent(e,t){return e?t.httpsAgent:t.httpAgent}class ReportTransform extends g.Transform{constructor(e){super();this.progressCallback=e;this.loadedBytes=0}_transform(e,t,a){this.push(e);this.loadedBytes+=e.length;this.progressCallback({loadedBytes:this.loadedBytes});a(undefined)}}function isReadableStream(e){return e&&typeof e.pipe==="function"}function isStreamComplete(e,t){return new Promise((a=>{e.once("close",(()=>{t===null||t===void 0?void 0:t.abort();a()}));e.once("end",a);e.once("error",a)}))}function parseHeaders(e){const t=new HttpHeaders;e.forEach(((e,a)=>{t.set(a,e)}));return t}class NodeFetchHttpClient{constructor(){this.proxyAgentMap=new Map;this.keepAliveAgents={}}async sendRequest(e){var t;if(!e&&typeof e!=="object"){throw new Error("'httpRequest' (WebResourceLike) cannot be null or undefined and must be of type object.")}const a=new u.AbortController;let r;if(e.abortSignal){if(e.abortSignal.aborted){throw new u.AbortError("The operation was aborted.")}r=e=>{if(e.type==="abort"){a.abort()}};e.abortSignal.addEventListener("abort",r)}if(e.timeout){setTimeout((()=>{a.abort()}),e.timeout)}if(e.formData){const t=e.formData;const a=new E["default"];const appendFormValue=(e,t)=>{if(typeof t==="function"){t=t()}if(t&&Object.prototype.hasOwnProperty.call(t,"value")&&Object.prototype.hasOwnProperty.call(t,"options")){a.append(e,t.value,t.options)}else{a.append(e,t)}};for(const e of Object.keys(t)){const a=t[e];if(Array.isArray(a)){for(let t=0;t{var t;(t=e.abortSignal)===null||t===void 0?void 0:t.removeEventListener("abort",r);return})).catch((e=>{z.warning("Error when cleaning up abortListener on httpRequest",e)}))}}}getOrCreateAgent(e){var t;const a=isUrlHttps(e.url);if(e.proxySettings){const{host:r,port:i,username:n,password:s}=e.proxySettings;const o=`${r}:${i}:${n}:${s}`;const p=(t=this.proxyAgentMap.get(o))!==null&&t!==void 0?t:{};let l=getCachedAgent(a,p);if(l){return l}const d=createProxyAgent(e.url,e.proxySettings,e.headers);l=d.agent;if(d.isHttps){p.httpsAgent=d.agent}else{p.httpAgent=d.agent}this.proxyAgentMap.set(o,p);return l}else if(e.keepAlive){let t=getCachedAgent(a,this.keepAliveAgents);if(t){return t}const r={keepAlive:e.keepAlive};if(a){t=this.keepAliveAgents.httpsAgent=new N.Agent(r)}else{t=this.keepAliveAgents.httpAgent=new S.Agent(r)}return t}else{return a?N.globalAgent:S.globalAgent}}async fetch(e,t){return _["default"](e,t)}async prepareRequest(e){const t={};t.agent=this.getOrCreateAgent(e);t.compress=e.decompressResponse;return t}async processRequest(e){}}t.HttpPipelineLogLevel=void 0;(function(e){e[e["OFF"]=0]="OFF";e[e["ERROR"]=1]="ERROR";e[e["WARNING"]=2]="WARNING";e[e["INFO"]=3]="INFO"})(t.HttpPipelineLogLevel||(t.HttpPipelineLogLevel={}));function operationOptionsToRequestOptionsBase(e){const{requestOptions:t,tracingOptions:a}=e,r=n.__rest(e,["requestOptions","tracingOptions"]);let i=r;if(t){i=Object.assign(Object.assign({},i),t)}if(a){i.tracingContext=a.tracingContext;i.spanOptions=a===null||a===void 0?void 0:a.spanOptions}return i}class BaseRequestPolicy{constructor(e,t){this._nextPolicy=e;this._options=t}shouldLog(e){return this._options.shouldLog(e)}log(e,t){this._options.log(e,t)}}class RequestPolicyOptions{constructor(e){this._logger=e}shouldLog(e){return!!this._logger&&e!==t.HttpPipelineLogLevel.OFF&&e<=this._logger.minimumLogLevel}log(e,t){if(this._logger&&this.shouldLog(e)){this._logger.log(e,t)}}}const j={explicitCharkey:false,trim:false,normalize:false,normalizeTags:false,attrkey:C,explicitArray:true,ignoreAttrs:false,mergeAttrs:false,explicitRoot:true,validator:undefined,xmlns:false,explicitChildren:false,preserveChildrenOrder:false,childkey:"$$",charsAsChildren:false,includeWhiteChars:false,async:false,strict:true,attrNameProcessors:undefined,attrValueProcessors:undefined,tagNameProcessors:undefined,valueProcessors:undefined,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:true},doctype:undefined,renderOpts:{pretty:true,indent:" ",newline:"\n"},headless:false,chunkSize:1e4,emptyTag:"",cdata:false};const q=Object.assign({},j);q.explicitArray=false;const U=Object.assign({},j);U.explicitArray=false;U.renderOpts={pretty:false};function stringifyXML(e,t={}){var a;U.rootName=t.rootName;U.charkey=(a=t.xmlCharKey)!==null&&a!==void 0?a:O;const r=new x.Builder(U);return r.buildObject(e)}function parseXML(e,t={}){var a;q.explicitRoot=!!t.includeRoot;q.charkey=(a=t.xmlCharKey)!==null&&a!==void 0?a:O;const r=new x.Parser(q);return new Promise(((t,a)=>{if(!e){a(new Error("Document is empty"))}else{r.parseString(e,((e,r)=>{if(e){a(e)}else{t(r)}}))}}))}function deserializationPolicy(e,t){return{create:(a,r)=>new DeserializationPolicy(a,r,e,t)}}const H=["application/json","text/json"];const V=["application/xml","application/atom+xml"];const G={expectedContentTypes:{json:H,xml:V}};class DeserializationPolicy extends BaseRequestPolicy{constructor(e,t,a,r={}){var i;super(e,t);this.jsonContentTypes=a&&a.json||H;this.xmlContentTypes=a&&a.xml||V;this.xmlCharKey=(i=r.xmlCharKey)!==null&&i!==void 0?i:O}async sendRequest(e){return this._nextPolicy.sendRequest(e).then((e=>deserializeResponseBody(this.jsonContentTypes,this.xmlContentTypes,e,{xmlCharKey:this.xmlCharKey})))}}function getOperationResponse(e){let t;const a=e.request;const r=a.operationSpec;if(r){const i=a.operationResponseGetter;if(!i){t=r.responses[e.status]}else{t=i(r,e)}}return t}function shouldDeserializeResponse(e){const t=e.request.shouldDeserialize;let a;if(t===undefined){a=true}else if(typeof t==="boolean"){a=t}else{a=t(e)}return a}function deserializeResponseBody(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};return parse(e,t,a,o).then((e=>{if(!shouldDeserializeResponse(e)){return e}const t=e.request.operationSpec;if(!t||!t.responses){return e}const i=getOperationResponse(e);const{error:n,shouldReturnResponse:s}=handleErrorResponse(e,t,i);if(n){throw n}else if(s){return e}if(i){if(i.bodyMapper){let a=e.parsedBody;if(t.isXML&&i.bodyMapper.type.name===A.Sequence){a=typeof a==="object"?a[i.bodyMapper.xmlElementName]:[]}try{e.parsedBody=t.serializer.deserialize(i.bodyMapper,a,"operationRes.parsedBody",r)}catch(t){const a=new RestError(`Error ${t} occurred in deserializing the responseBody - ${e.bodyAsText}`,undefined,e.status,e.request,e);throw a}}else if(t.httpMethod==="HEAD"){e.parsedBody=a.status>=200&&a.status<300}if(i.headersMapper){e.parsedHeaders=t.serializer.deserialize(i.headersMapper,e.headers.toJson(),"operationRes.parsedHeaders",r)}}return e}))}function isOperationSpecEmpty(e){const t=Object.keys(e.responses);return t.length===0||t.length===1&&t[0]==="default"}function handleErrorResponse(e,t,a){var r;const i=200<=e.status&&e.status<300;const n=isOperationSpecEmpty(t)?i:!!a;if(n){if(a){if(!a.isError){return{error:null,shouldReturnResponse:false}}}else{return{error:null,shouldReturnResponse:false}}}const s=a!==null&&a!==void 0?a:t.responses.default;const o=((r=e.request.streamResponseStatusCodes)===null||r===void 0?void 0:r.has(e.status))||e.request.streamResponseBody;const p=o?`Unexpected status code: ${e.status}`:e.bodyAsText;const l=new RestError(p,undefined,e.status,e.request,e);if(!s){throw l}const d=s.bodyMapper;const c=s.headersMapper;try{if(e.parsedBody){const a=e.parsedBody;let r;if(d){let e=a;if(t.isXML&&d.type.name===A.Sequence){e=typeof a==="object"?a[d.xmlElementName]:[]}r=t.serializer.deserialize(d,e,"error.response.parsedBody")}const i=a.error||r||a;l.code=i.code;if(i.message){l.message=i.message}if(d){l.response.parsedBody=r}}if(e.headers&&c){l.response.parsedHeaders=t.serializer.deserialize(c,e.headers.toJson(),"operationRes.parsedHeaders")}}catch(t){l.message=`Error "${t.message}" occurred in deserializing the responseBody - "${e.bodyAsText}" for the default response.`}return{error:l,shouldReturnResponse:false}}function parse(e,t,a,r){var i;const errorHandler=e=>{const t=`Error "${e}" occurred while parsing the response body - ${a.bodyAsText}.`;const r=e.code||RestError.PARSE_ERROR;const i=new RestError(t,r,a.status,a.request,a);return Promise.reject(i)};const n=((i=a.request.streamResponseStatusCodes)===null||i===void 0?void 0:i.has(a.status))||a.request.streamResponseBody;if(!n&&a.bodyAsText){const i=a.bodyAsText;const n=a.headers.get("Content-Type")||"";const s=!n?[]:n.split(";").map((e=>e.toLowerCase()));if(s.length===0||s.some((t=>e.indexOf(t)!==-1))){return new Promise((e=>{a.parsedBody=JSON.parse(i);e(a)})).catch(errorHandler)}else if(s.some((e=>t.indexOf(e)!==-1))){return parseXML(i,r).then((e=>{a.parsedBody=e;return a})).catch(errorHandler)}}return Promise.resolve(a)}const X={enable:true};function keepAlivePolicy(e){return{create:(t,a)=>new KeepAlivePolicy(t,a,e||X)}}class KeepAlivePolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.keepAliveOptions=a}async sendRequest(e){e.keepAlive=this.keepAliveOptions.enable;return this._nextPolicy.sendRequest(e)}}const $=["GET","HEAD"];const W={handleRedirects:true,maxRetries:20};function redirectPolicy(e=20){return{create:(t,a)=>new RedirectPolicy(t,a,e)}}class RedirectPolicy extends BaseRequestPolicy{constructor(e,t,a=20){super(e,t);this.maxRetries=a}sendRequest(e){return this._nextPolicy.sendRequest(e).then((e=>handleRedirect(this,e,0)))}}function handleRedirect(e,t,a){const{request:r,status:i}=t;const n=t.headers.get("location");if(n&&(i===300||i===301&&$.includes(r.method)||i===302&&$.includes(r.method)||i===303&&r.method==="POST"||i===307)&&(!e.maxRetries||ahandleRedirect(e,t,a+1)))}return Promise.resolve(t)}const K=3;const Q=1e3*30;const Y=1e3*90;const J=1e3*3;function isNumber(e){return typeof e==="number"}function shouldRetry(e,t,a,r,i){if(!t(r,i)){return false}return a.retryCountnew ExponentialRetryPolicy(r,i,e,t,a)}}t.RetryMode=void 0;(function(e){e[e["Exponential"]=0]="Exponential"})(t.RetryMode||(t.RetryMode={}));const Z={maxRetries:K,retryDelayInMs:Q,maxRetryDelayInMs:Y};class ExponentialRetryPolicy extends BaseRequestPolicy{constructor(e,t,a,r,i){super(e,t);this.retryCount=isNumber(a)?a:K;this.retryInterval=isNumber(r)?r:Q;this.maxRetryInterval=isNumber(i)?i:Y}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then((t=>retry$1(this,e,t))).catch((t=>retry$1(this,e,t.response,undefined,t)))}}async function retry$1(e,t,a,r,i){function shouldPolicyRetry(e){const t=e===null||e===void 0?void 0:e.status;if(t===503&&(a===null||a===void 0?void 0:a.headers.get(P.HeaderConstants.RETRY_AFTER))){return false}if(t===undefined||t<500&&t!==408||t===501||t===505){return false}return true}r=updateRetryData({retryInterval:e.retryInterval,minRetryInterval:0,maxRetryInterval:e.maxRetryInterval},r,i);const n=t.abortSignal&&t.abortSignal.aborted;if(!n&&shouldRetry(e.retryCount,shouldPolicyRetry,r,a)){z.info(`Retrying request in ${r.retryInterval}`);try{await o.delay(r.retryInterval);const a=await e._nextPolicy.sendRequest(t.clone());return retry$1(e,t,a,r)}catch(i){return retry$1(e,t,a,r,i)}}else if(n||i||!a){const e=r.error||new RestError("Failed to send the request.",RestError.REQUEST_SEND_ERROR,a&&a.status,a&&a.request,a);throw e}else{return a}}function logPolicy(e={}){return{create:(t,a)=>new LogPolicy(t,a,e)}}class LogPolicy extends BaseRequestPolicy{constructor(e,t,{logger:a=z.info,allowedHeaderNames:r=[],allowedQueryParameters:i=[]}={}){super(e,t);this.logger=a;this.sanitizer=new Sanitizer({allowedHeaderNames:r,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){if(!this.logger.enabled)return this._nextPolicy.sendRequest(e);this.logRequest(e);return this._nextPolicy.sendRequest(e).then((e=>this.logResponse(e)))}logRequest(e){this.logger(`Request: ${this.sanitizer.sanitize(e)}`)}logResponse(e){this.logger(`Response status code: ${e.status}`);this.logger(`Headers: ${this.sanitizer.sanitize(e.headers)}`);return e}}function getPathStringFromParameter(e){return getPathStringFromParameterPath(e.parameterPath,e.mapper)}function getPathStringFromParameterPath(e,t){let a;if(typeof e==="string"){a=e}else if(Array.isArray(e)){a=e.join(".")}else{a=t.serializedName}return a}function getStreamResponseStatusCodes(e){const t=new Set;for(const a in e.responses){const r=e.responses[a];if(r.bodyMapper&&r.bodyMapper.type.name===A.Stream){t.add(Number(a))}}return t}function getDefaultUserAgentKey(){return P.HeaderConstants.USER_AGENT}function getPlatformSpecificData(){const e={key:"Node",value:process.version};const t={key:"OS",value:`(${w.arch()}-${w.type()}-${w.release()})`};return[e,t]}function getRuntimeInfo(){const e={key:"core-http",value:P.coreHttpVersion};return[e]}function getUserAgentString(e,t=" ",a="/"){return e.map((e=>{const t=e.value?`${a}${e.value}`:"";return`${e.key}${t}`})).join(t)}const ee=getDefaultUserAgentKey;function getDefaultUserAgentValue(){const e=getRuntimeInfo();const t=getPlatformSpecificData();const a=getUserAgentString(e.concat(t));return a}function userAgentPolicy(e){const t=!e||e.key===undefined||e.key===null?getDefaultUserAgentKey():e.key;const a=!e||e.value===undefined||e.value===null?getDefaultUserAgentValue():e.value;return{create:(e,r)=>new UserAgentPolicy(e,r,t,a)}}class UserAgentPolicy extends BaseRequestPolicy{constructor(e,t,a,r){super(e,t);this._nextPolicy=e;this._options=t;this.headerKey=a;this.headerValue=r}sendRequest(e){this.addUserAgentHeader(e);return this._nextPolicy.sendRequest(e)}addUserAgentHeader(e){if(!e.headers){e.headers=new HttpHeaders}if(!e.headers.get(this.headerKey)&&this.headerValue){e.headers.set(this.headerKey,this.headerValue)}}}t.QueryCollectionFormat=void 0;(function(e){e["Csv"]=",";e["Ssv"]=" ";e["Tsv"]="\t";e["Pipes"]="|";e["Multi"]="Multi"})(t.QueryCollectionFormat||(t.QueryCollectionFormat={}));const te={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function beginRefresh(e,t,a){async function tryGetAccessToken(){if(Date.now()e.getToken(t,a);r=beginRefresh(tryGetAccessToken,n.retryIntervalInMs,(o=i===null||i===void 0?void 0:i.expiresOnTimestamp)!==null&&o!==void 0?o:Date.now()).then((e=>{r=null;i=e;return i})).catch((e=>{r=null;i=null;throw e}))}return r}return async e=>{if(s.mustRefresh)return refresh(e);if(s.shouldRefresh){refresh(e)}return i}}function bearerTokenAuthenticationPolicy(e,t){const a=createTokenCycler(e,t);class BearerTokenAuthenticationPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){if(!e.url.toLowerCase().startsWith("https://")){throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.")}const{token:t}=await a({abortSignal:e.abortSignal,tracingOptions:{tracingContext:e.tracingContext}});e.headers.set(P.HeaderConstants.AUTHORIZATION,`Bearer ${t}`);return this._nextPolicy.sendRequest(e)}}return{create:(e,t)=>new BearerTokenAuthenticationPolicy(e,t)}}function disableResponseDecompressionPolicy(){return{create:(e,t)=>new DisableResponseDecompressionPolicy(e,t)}}class DisableResponseDecompressionPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){e.decompressResponse=false;return this._nextPolicy.sendRequest(e)}}function generateClientRequestIdPolicy(e="x-ms-client-request-id"){return{create:(t,a)=>new GenerateClientRequestIdPolicy(t,a,e)}}class GenerateClientRequestIdPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this._requestIdHeaderName=a}sendRequest(e){if(!e.headers.contains(this._requestIdHeaderName)){e.headers.set(this._requestIdHeaderName,e.requestId)}return this._nextPolicy.sendRequest(e)}}let ae;function getCachedDefaultHttpClient(){if(!ae){ae=new NodeFetchHttpClient}return ae}function ndJsonPolicy(){return{create:(e,t)=>new NdJsonPolicy(e,t)}}class NdJsonPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){if(typeof e.body==="string"&&e.body.startsWith("[")){const t=JSON.parse(e.body);if(Array.isArray(t)){e.body=t.map((e=>JSON.stringify(e)+"\n")).join("")}}return this._nextPolicy.sendRequest(e)}}const re=[];let ie=false;const ne=new Map;function loadEnvironmentProxyValue(){if(!process){return undefined}const e=getEnvironmentValue(P.HTTPS_PROXY);const t=getEnvironmentValue(P.ALL_PROXY);const a=getEnvironmentValue(P.HTTP_PROXY);return e||t||a}function isBypassed(e,t,a){if(t.length===0){return false}const r=URLBuilder.parse(e).getHost();if(a===null||a===void 0?void 0:a.has(r)){return a.get(r)}let i=false;for(const e of t){if(e[0]==="."){if(r.endsWith(e)){i=true}else{if(r.length===e.length-1&&r===e.slice(1)){i=true}}}else{if(r===e){i=true}}}a===null||a===void 0?void 0:a.set(r,i);return i}function loadNoProxy(){const e=getEnvironmentValue(P.NO_PROXY);ie=true;if(e){return e.split(",").map((e=>e.trim())).filter((e=>e.length))}return[]}function getDefaultProxySettings(e){if(!e){e=loadEnvironmentProxyValue();if(!e){return undefined}}const{username:t,password:a,urlWithoutAuth:r}=extractAuthFromUrl(e);const i=URLBuilder.parse(r);const n=i.getScheme()?i.getScheme()+"://":"";return{host:n+i.getHost(),port:Number.parseInt(i.getPort()||"80"),username:t,password:a}}function proxyPolicy(e,t){if(!e){e=getDefaultProxySettings()}if(!ie){re.push(...loadNoProxy())}return{create:(a,r)=>new ProxyPolicy(a,r,e,t===null||t===void 0?void 0:t.customNoProxyList)}}function extractAuthFromUrl(e){const t=e.indexOf("@");if(t===-1){return{urlWithoutAuth:e}}const a=e.indexOf("://");const r=a!==-1?a+3:0;const i=e.substring(r,t);const n=i.indexOf(":");const s=n!==-1;const o=s?i.substring(0,n):i;const p=s?i.substring(n+1):undefined;const l=e.substring(0,r)+e.substring(t+1);return{username:o,password:p,urlWithoutAuth:l}}class ProxyPolicy extends BaseRequestPolicy{constructor(e,t,a,r){super(e,t);this.proxySettings=a;this.customNoProxyList=r}sendRequest(e){var t;if(!e.proxySettings&&!isBypassed(e.url,(t=this.customNoProxyList)!==null&&t!==void 0?t:re,this.customNoProxyList?undefined:ne)){e.proxySettings=this.proxySettings}return this._nextPolicy.sendRequest(e)}}function rpRegistrationPolicy(e=30){return{create:(t,a)=>new RPRegistrationPolicy(t,a,e)}}class RPRegistrationPolicy extends BaseRequestPolicy{constructor(e,t,a=30){super(e,t);this._retryTimeout=a}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then((t=>registerIfNeeded(this,e,t)))}}function registerIfNeeded(e,t,a){if(a.status===409){const r=checkRPNotRegisteredError(a.bodyAsText);if(r){const i=extractSubscriptionUrl(t.url);return registerRP(e,i,r,t).catch((()=>false)).then((r=>{if(r){t.headers.set("x-ms-client-request-id",generateUuid());return e._nextPolicy.sendRequest(t.clone())}return a}))}}return Promise.resolve(a)}function getRequestEssentials(e,t=false){const a=e.clone();if(t){a.url=e.url}a.headers.set("x-ms-client-request-id",generateUuid());a.headers.set("Content-Type","application/json; charset=utf-8");return a}function checkRPNotRegisteredError(e){let t,a;if(e){try{a=JSON.parse(e)}catch(e){}if(a&&a.error&&a.error.message&&a.error.code&&a.error.code==="MissingSubscriptionRegistration"){const e=a.error.message.match(/.*'(.*)'/i);if(e){t=e.pop()}}}return t}function extractSubscriptionUrl(e){let t;const a=e.match(/.*\/subscriptions\/[a-f0-9-]+\//gi);if(a&&a[0]){t=a[0]}else{throw new Error(`Unable to extract subscriptionId from the given url - ${e}.`)}return t}async function registerRP(e,t,a,r){const i=`${t}providers/${a}/register?api-version=2016-02-01`;const n=`${t}providers/${a}?api-version=2016-02-01`;const s=getRequestEssentials(r);s.method="POST";s.url=i;const o=await e._nextPolicy.sendRequest(s);if(o.status!==200){throw new Error(`Autoregistration of ${a} failed. Please try registering manually.`)}return getRegistrationStatus(e,n,r)}async function getRegistrationStatus(e,t,a){const r=getRequestEssentials(a);r.url=t;r.method="GET";const i=await e._nextPolicy.sendRequest(r);const n=i.parsedBody;if(i.parsedBody&&n.registrationState&&n.registrationState==="Registered"){return true}else{await o.delay(e._retryTimeout*1e3);return getRegistrationStatus(e,t,a)}}function signingPolicy(e){return{create:(t,a)=>new SigningPolicy(t,a,e)}}class SigningPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.authenticationProvider=a}signRequest(e){return this.authenticationProvider.signRequest(e)}sendRequest(e){return this.signRequest(e).then((e=>this._nextPolicy.sendRequest(e)))}}function systemErrorRetryPolicy(e,t,a,r){return{create:(i,n)=>new SystemErrorRetryPolicy(i,n,e,t,a,r)}}class SystemErrorRetryPolicy extends BaseRequestPolicy{constructor(e,t,a,r,i,n){super(e,t);this.retryCount=isNumber(a)?a:K;this.retryInterval=isNumber(r)?r:Q;this.minRetryInterval=isNumber(i)?i:J;this.maxRetryInterval=isNumber(n)?n:Y}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).catch((t=>retry(this,e,t.response,t)))}}async function retry(e,t,a,r,i){i=updateRetryData(e,i,r);function shouldPolicyRetry(e,t){if(t&&t.code&&(t.code==="ETIMEDOUT"||t.code==="ESOCKETTIMEDOUT"||t.code==="ECONNREFUSED"||t.code==="ECONNRESET"||t.code==="ENOENT")){return true}return false}if(shouldRetry(e.retryCount,shouldPolicyRetry,i,a,r)){try{await o.delay(i.retryInterval);return e._nextPolicy.sendRequest(t.clone())}catch(r){return retry(e,t,a,r,i)}}else{if(r){return Promise.reject(i.error)}return a}}const se=3;const oe=P.HttpConstants.StatusCodes;function throttlingRetryPolicy(){return{create:(e,t)=>new ThrottlingRetryPolicy(e,t)}}const pe="The operation was aborted.";class ThrottlingRetryPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.numberOfRetries=0;this._handleResponse=a||this._defaultResponseHandler}async sendRequest(e){const t=await this._nextPolicy.sendRequest(e.clone());if(t.status!==oe.TooManyRequests&&t.status!==oe.ServiceUnavailable){return t}else{return this._handleResponse(e,t)}}async _defaultResponseHandler(e,t){var a;const r=t.headers.get(P.HeaderConstants.RETRY_AFTER);if(r){const t=ThrottlingRetryPolicy.parseRetryAfterHeader(r);if(t){this.numberOfRetries+=1;await o.delay(t,{abortSignal:e.abortSignal,abortErrorMsg:pe});if((a=e.abortSignal)===null||a===void 0?void 0:a.aborted){throw new u.AbortError(pe)}if(this.numberOfRetries{let a=undefined;const r=this;const i=t;return{create(t,n){const s=getCredentialScopes(i,r.baseUri);if(!s){throw new Error(`When using credential, the ServiceClient must contain a baseUri or a credentialScopes in ServiceClientOptions. Unable to create a bearerTokenAuthenticationPolicy`)}if(a===undefined||a===null){a=bearerTokenAuthenticationPolicy(e,s)}return a.create(t,n)}}};r=wrappedPolicyFactory()}else if(e&&typeof e.signRequest==="function"){z.info("ServiceClient: creating signing policy from provided credentials");r=signingPolicy(e)}else if(e!==undefined&&e!==null){throw new Error("The credentials argument must implement the TokenCredential interface")}z.info("ServiceClient: using default request policies");a=createDefaultRequestPolicyFactories(r,t);if(t.requestPolicyFactories){const e=t.requestPolicyFactories(a);if(e){a=e}}}this._requestPolicyFactories=a}sendRequest(e){if(e===null||e===undefined||typeof e!=="object"){throw new Error("options cannot be null or undefined and it must be of type object.")}let t;try{if(isWebResourceLike(e)){e.validateRequestProperties();t=e}else{t=new WebResource;t=t.prepare(e)}}catch(e){return Promise.reject(e)}let a=this._httpClient;if(this._requestPolicyFactories&&this._requestPolicyFactories.length>0){for(let e=this._requestPolicyFactories.length-1;e>=0;--e){a=this._requestPolicyFactories[e].create(a,this._requestPolicyOptions)}}return a.sendRequest(t)}async sendOperationRequest(e,a,r){var i;if(typeof e.options==="function"){r=e.options;e.options=undefined}const n=(i=e.options)===null||i===void 0?void 0:i.serializerOptions;const s=new WebResource;let o;try{const r=a.baseUrl||this.baseUri;if(!r){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=a.httpMethod;s.operationSpec=a;const i=URLBuilder.parse(r);if(a.path){i.appendPath(a.path)}if(a.urlParameters&&a.urlParameters.length>0){for(const t of a.urlParameters){let r=getOperationArgumentValueFromParameter(this,e,t,a.serializer);r=a.serializer.serialize(t.mapper,r,getPathStringFromParameter(t),n);if(!t.skipEncoding){r=encodeURIComponent(r)}i.replaceAll(`{${t.mapper.serializedName||getPathStringFromParameter(t)}}`,r)}}if(a.queryParameters&&a.queryParameters.length>0){for(const r of a.queryParameters){let s=getOperationArgumentValueFromParameter(this,e,r,a.serializer);if(s!==undefined&&s!==null){s=a.serializer.serialize(r.mapper,s,getPathStringFromParameter(r),n);if(r.collectionFormat!==undefined&&r.collectionFormat!==null){if(r.collectionFormat===t.QueryCollectionFormat.Multi){if(s.length===0){continue}else{for(const e in s){const t=s[e];s[e]=t===undefined||t===null?"":t.toString()}}}else if(r.collectionFormat===t.QueryCollectionFormat.Ssv||r.collectionFormat===t.QueryCollectionFormat.Tsv){s=s.join(r.collectionFormat)}}if(!r.skipEncoding){if(Array.isArray(s)){for(const e in s){if(s[e]!==undefined&&s[e]!==null){s[e]=encodeURIComponent(s[e])}}}else{s=encodeURIComponent(s)}}if(r.collectionFormat!==undefined&&r.collectionFormat!==null&&r.collectionFormat!==t.QueryCollectionFormat.Multi&&r.collectionFormat!==t.QueryCollectionFormat.Ssv&&r.collectionFormat!==t.QueryCollectionFormat.Tsv){s=s.join(r.collectionFormat)}i.setQueryParameter(r.mapper.serializedName||getPathStringFromParameter(r),s)}}}s.url=i.toString();const p=a.contentType||this.requestContentType;if(p&&a.requestBody){s.headers.set("Content-Type",p)}if(a.headerParameters){for(const t of a.headerParameters){let r=getOperationArgumentValueFromParameter(this,e,t,a.serializer);if(r!==undefined&&r!==null){r=a.serializer.serialize(t.mapper,r,getPathStringFromParameter(t),n);const e=t.mapper.headerCollectionPrefix;if(e){for(const t of Object.keys(r)){s.headers.set(e+t,r[t])}}else{s.headers.set(t.mapper.serializedName||getPathStringFromParameter(t),r)}}}}const l=e.options;if(l){if(l.customHeaders){for(const e in l.customHeaders){s.headers.set(e,l.customHeaders[e])}}if(l.abortSignal){s.abortSignal=l.abortSignal}if(l.timeout){s.timeout=l.timeout}if(l.onUploadProgress){s.onUploadProgress=l.onUploadProgress}if(l.onDownloadProgress){s.onDownloadProgress=l.onDownloadProgress}if(l.spanOptions){s.spanOptions=l.spanOptions}if(l.tracingContext){s.tracingContext=l.tracingContext}if(l.shouldDeserialize!==undefined&&l.shouldDeserialize!==null){s.shouldDeserialize=l.shouldDeserialize}}s.withCredentials=this._withCredentials;serializeRequestBody(this,s,e,a);if(s.streamResponseStatusCodes===undefined){s.streamResponseStatusCodes=getStreamResponseStatusCodes(a)}let d;let c;try{d=await this.sendRequest(s)}catch(e){c=e}if(c){if(c.response){c.details=flattenResponse(c.response,a.responses[c.statusCode]||a.responses["default"])}o=Promise.reject(c)}else{o=Promise.resolve(flattenResponse(d,a.responses[d.status]))}}catch(e){o=Promise.reject(e)}const p=r;if(p){o.then((e=>p(null,e._response.parsedBody,e._response.request,e._response))).catch((e=>p(e)))}return o}}function serializeRequestBody(e,t,a,r){var i,n,s,o,p,l;const d=(n=(i=a.options)===null||i===void 0?void 0:i.serializerOptions)!==null&&n!==void 0?n:{};const c={rootName:(s=d.rootName)!==null&&s!==void 0?s:"",includeRoot:(o=d.includeRoot)!==null&&o!==void 0?o:false,xmlCharKey:(p=d.xmlCharKey)!==null&&p!==void 0?p:O};const m=d.xmlCharKey;if(r.requestBody&&r.requestBody.mapper){t.body=getOperationArgumentValueFromParameter(e,a,r.requestBody,r.serializer);const i=r.requestBody.mapper;const{required:n,xmlName:s,xmlElementName:o,serializedName:p,xmlNamespace:d,xmlNamespacePrefix:u}=i;const h=i.type.name;try{if(t.body!==undefined&&t.body!==null||n){const e=getPathStringFromParameter(r.requestBody);t.body=r.serializer.serialize(i,t.body,e,c);const a=h===A.Stream;if(r.isXML){const e=u?`xmlns:${u}`:"xmlns";const r=getXmlValueWithNamespace(d,e,h,t.body,c);if(h===A.Sequence){t.body=stringifyXML(prepareXMLRootList(r,o||s||p,e,d),{rootName:s||p,xmlCharKey:m})}else if(!a){t.body=stringifyXML(r,{rootName:s||p,xmlCharKey:m})}}else if(h===A.String&&(((l=r.contentType)===null||l===void 0?void 0:l.match("text/plain"))||r.mediaType==="text")){return}else if(!a){t.body=JSON.stringify(t.body)}}}catch(e){throw new Error(`Error "${e.message}" occurred in serializing the payload - ${JSON.stringify(p,undefined," ")}.`)}}else if(r.formDataParameters&&r.formDataParameters.length>0){t.formData={};for(const i of r.formDataParameters){const n=getOperationArgumentValueFromParameter(e,a,i,r.serializer);if(n!==undefined&&n!==null){const e=i.mapper.serializedName||getPathStringFromParameter(i);t.formData[e]=r.serializer.serialize(i.mapper,n,getPathStringFromParameter(i),c)}}}}function getXmlValueWithNamespace(e,t,a,r,i){if(e&&!["Composite","Sequence","Dictionary"].includes(a)){const a={};a[i.xmlCharKey]=r;a[C]={[t]:e};return a}return r}function getValueOrFunctionResult(e,t){let a;if(typeof e==="string"){a=e}else{a=t();if(typeof e==="function"){a=e(a)}}return a}function createDefaultRequestPolicyFactories(e,t){const a=[];if(t.generateClientRequestIdHeader){a.push(generateClientRequestIdPolicy(t.clientRequestIdHeaderName))}if(e){a.push(e)}const r=getValueOrFunctionResult(t.userAgentHeaderName,ee);const i=getValueOrFunctionResult(t.userAgent,getDefaultUserAgentValue);if(r&&i){a.push(userAgentPolicy({key:r,value:i}))}a.push(redirectPolicy());a.push(rpRegistrationPolicy(t.rpRegistrationRetryTimeout));if(!t.noRetryPolicy){a.push(exponentialRetryPolicy());a.push(systemErrorRetryPolicy());a.push(throttlingRetryPolicy())}a.push(deserializationPolicy(t.deserializationContentTypes));if(o.isNode){a.push(proxyPolicy(t.proxySettings))}a.push(logPolicy({logger:z.info}));return a}function createPipelineFromOptions(e,t){const a=[];if(e.sendStreamingJson){a.push(ndJsonPolicy())}let r=undefined;if(e.userAgentOptions&&e.userAgentOptions.userAgentPrefix){const t=[];t.push(e.userAgentOptions.userAgentPrefix);const a=getDefaultUserAgentValue();if(t.indexOf(a)===-1){t.push(a)}r=t.join(" ")}const i=Object.assign(Object.assign({},X),e.keepAliveOptions);const n=Object.assign(Object.assign({},Z),e.retryOptions);const s=Object.assign(Object.assign({},W),e.redirectOptions);if(o.isNode){a.push(proxyPolicy(e.proxyOptions))}const p=Object.assign(Object.assign({},G),e.deserializationOptions);const l=Object.assign({},e.loggingOptions);a.push(tracingPolicy({userAgent:r}),keepAlivePolicy(i),userAgentPolicy({value:r}),generateClientRequestIdPolicy(),deserializationPolicy(p.expectedContentTypes),throttlingRetryPolicy(),systemErrorRetryPolicy(),exponentialRetryPolicy(n.maxRetries,n.retryDelayInMs,n.maxRetryDelayInMs));if(s.handleRedirects){a.push(redirectPolicy(s.maxRetries))}if(t){a.push(t)}a.push(logPolicy(l));if(o.isNode&&e.decompressResponse===false){a.push(disableResponseDecompressionPolicy())}return{httpClient:e.httpClient,requestPolicyFactories:a}}function getOperationArgumentValueFromParameter(e,t,a,r){return getOperationArgumentValueFromParameterPath(e,t,a.parameterPath,a.mapper,r)}function getOperationArgumentValueFromParameterPath(e,t,a,r,i){var n;let s;if(typeof a==="string"){a=[a]}const o=(n=t.options)===null||n===void 0?void 0:n.serializerOptions;if(Array.isArray(a)){if(a.length>0){if(r.isConstant){s=r.defaultValue}else{let i=getPropertyFromParameterPath(t,a);if(!i.propertyFound){i=getPropertyFromParameterPath(e,a)}let n=false;if(!i.propertyFound){n=r.required||a[0]==="options"&&a.length===2}s=n?r.defaultValue:i.propertyValue}const n=getPathStringFromParameterPath(a,r);i.serialize(r,s,n,o)}}else{if(r.required){s={}}for(const n in a){const p=r.type.modelProperties[n];const l=a[n];const d=getOperationArgumentValueFromParameterPath(e,t,l,p,i);const c=getPathStringFromParameterPath(l,p);i.serialize(p,d,c,o);if(d!==undefined&&d!==null){if(!s){s={}}s[n]=d}}}return s}function getPropertyFromParameterPath(e,t){const a={propertyFound:false};let r=0;for(;rObject.defineProperty(t,"_response",{value:e});if(r){const t=r.type.name;if(t==="Stream"){return addOperationResponse(Object.assign(Object.assign({},a),{blobBody:e.blobBody,readableStreamBody:e.readableStreamBody}))}const i=t==="Composite"&&r.type.modelProperties||{};const n=Object.keys(i).some((e=>i[e].serializedName===""));if(t==="Sequence"||n){const t=[...e.parsedBody||[]];for(const a of Object.keys(i)){if(i[a].serializedName){t[a]=e.parsedBody[a]}}if(a){for(const e of Object.keys(a)){t[e]=a[e]}}addOperationResponse(t);return t}if(t==="Composite"||t==="Dictionary"){return addOperationResponse(Object.assign(Object.assign({},a),e.parsedBody))}}if(r||e.request.method==="HEAD"||isPrimitiveType(e.parsedBody)){return addOperationResponse(Object.assign(Object.assign({},a),{body:e.parsedBody}))}return addOperationResponse(Object.assign(Object.assign({},a),e.parsedBody))}function getCredentialScopes(e,t){if(e===null||e===void 0?void 0:e.credentialScopes){return e.credentialScopes}if(t){return`${t}/.default`}return undefined}function createSpanFunction(e){return b.createSpanFunction(e)}const de=2*60*1e3;class ExpiringAccessTokenCache{constructor(e=de){this.cachedToken=undefined;this.tokenRefreshBufferMs=e}setCachedToken(e){this.cachedToken=e}getCachedToken(){if(this.cachedToken&&Date.now()+this.tokenRefreshBufferMs>=this.cachedToken.expiresOnTimestamp){this.cachedToken=undefined}return this.cachedToken}}class AccessTokenRefresher{constructor(e,t,a=3e4){this.credential=e;this.scopes=t;this.requiredMillisecondsBeforeNewRefresh=a;this.lastCalled=0}isReady(){return!this.lastCalled||Date.now()-this.lastCalled>this.requiredMillisecondsBeforeNewRefresh}async getToken(e){this.lastCalled=Date.now();const t=await this.credential.getToken(this.scopes,e);this.promise=undefined;return t||undefined}refresh(e){if(!this.promise){this.promise=this.getToken(e)}return this.promise}}const ce=P.HeaderConstants;const me="Basic";class BasicAuthenticationCredentials{constructor(e,t,a=me){this.authorizationScheme=me;if(e===null||e===undefined||typeof e.valueOf()!=="string"){throw new Error("userName cannot be null or undefined and must be of type string.")}if(t===null||t===undefined||typeof t.valueOf()!=="string"){throw new Error("password cannot be null or undefined and must be of type string.")}this.userName=e;this.password=t;this.authorizationScheme=a}signRequest(e){const t=`${this.userName}:${this.password}`;const a=`${this.authorizationScheme} ${encodeString(t)}`;if(!e.headers)e.headers=new HttpHeaders;e.headers.set(ce.AUTHORIZATION,a);return Promise.resolve(e)}}class ApiKeyCredentials{constructor(e){if(!e||e&&!e.inHeader&&!e.inQuery){throw new Error(`options cannot be null or undefined. Either "inHeader" or "inQuery" property of the options object needs to be provided.`)}this.inHeader=e.inHeader;this.inQuery=e.inQuery}signRequest(e){if(!e){return Promise.reject(new Error(`webResource cannot be null or undefined and must be of type "object".`))}if(this.inHeader){if(!e.headers){e.headers=new HttpHeaders}for(const t in this.inHeader){e.headers.set(t,this.inHeader[t])}}if(this.inQuery){if(!e.url){return Promise.reject(new Error(`url cannot be null in the request object.`))}if(e.url.indexOf("?")<0){e.url+="?"}for(const t in this.inQuery){if(!e.url.endsWith("?")){e.url+="&"}e.url+=`${t}=${this.inQuery[t]}`}}return Promise.resolve(e)}}class TopicCredentials extends ApiKeyCredentials{constructor(e){if(!e||e&&typeof e!=="string"){throw new Error("topicKey cannot be null or undefined and must be of type string.")}const t={inHeader:{"aeg-sas-key":e}};super(t)}}Object.defineProperty(t,"delay",{enumerable:true,get:function(){return o.delay}});Object.defineProperty(t,"isNode",{enumerable:true,get:function(){return o.isNode}});Object.defineProperty(t,"isTokenCredential",{enumerable:true,get:function(){return l.isTokenCredential}});t.AccessTokenRefresher=AccessTokenRefresher;t.ApiKeyCredentials=ApiKeyCredentials;t.BaseRequestPolicy=BaseRequestPolicy;t.BasicAuthenticationCredentials=BasicAuthenticationCredentials;t.Constants=P;t.DefaultHttpClient=NodeFetchHttpClient;t.ExpiringAccessTokenCache=ExpiringAccessTokenCache;t.HttpHeaders=HttpHeaders;t.MapperType=A;t.RequestPolicyOptions=RequestPolicyOptions;t.RestError=RestError;t.Serializer=Serializer;t.ServiceClient=ServiceClient;t.TopicCredentials=TopicCredentials;t.URLBuilder=URLBuilder;t.URLQuery=URLQuery;t.WebResource=WebResource;t.XML_ATTRKEY=C;t.XML_CHARKEY=O;t.applyMixins=applyMixins;t.bearerTokenAuthenticationPolicy=bearerTokenAuthenticationPolicy;t.createPipelineFromOptions=createPipelineFromOptions;t.createSpanFunction=createSpanFunction;t.deserializationPolicy=deserializationPolicy;t.deserializeResponseBody=deserializeResponseBody;t.disableResponseDecompressionPolicy=disableResponseDecompressionPolicy;t.encodeUri=encodeUri;t.executePromisesSequentially=executePromisesSequentially;t.exponentialRetryPolicy=exponentialRetryPolicy;t.flattenResponse=flattenResponse;t.generateClientRequestIdPolicy=generateClientRequestIdPolicy;t.generateUuid=generateUuid;t.getDefaultProxySettings=getDefaultProxySettings;t.getDefaultUserAgentValue=getDefaultUserAgentValue;t.isDuration=isDuration;t.isValidUuid=isValidUuid;t.keepAlivePolicy=keepAlivePolicy;t.logPolicy=logPolicy;t.operationOptionsToRequestOptionsBase=operationOptionsToRequestOptionsBase;t.parseXML=parseXML;t.promiseToCallback=promiseToCallback;t.promiseToServiceCallback=promiseToServiceCallback;t.proxyPolicy=proxyPolicy;t.redirectPolicy=redirectPolicy;t.serializeObject=serializeObject;t.signingPolicy=signingPolicy;t.stringifyXML=stringifyXML;t.stripRequest=stripRequest;t.stripResponse=stripResponse;t.systemErrorRetryPolicy=systemErrorRetryPolicy;t.throttlingRetryPolicy=throttlingRetryPolicy;t.tracingPolicy=tracingPolicy;t.userAgentPolicy=userAgentPolicy},6279:(e,t,a)=>{var r=a(5443);var i=a(3837);var n=a(1017);var s=a(3685);var o=a(5687);var p=a(7310).parse;var l=a(7147);var d=a(2781).Stream;var c=a(3583);var m=a(4812);var u=a(3971);e.exports=FormData;i.inherits(FormData,r);function FormData(e){if(!(this instanceof FormData)){return new FormData(e)}this._overheadLength=0;this._valueLength=0;this._valuesToMeasure=[];r.call(this);e=e||{};for(var t in e){this[t]=e[t]}}FormData.LINE_BREAK="\r\n";FormData.DEFAULT_CONTENT_TYPE="application/octet-stream";FormData.prototype.append=function(e,t,a){a=a||{};if(typeof a=="string"){a={filename:a}}var n=r.prototype.append.bind(this);if(typeof t=="number"){t=""+t}if(i.isArray(t)){this._error(new Error("Arrays are not supported."));return}var s=this._multiPartHeader(e,t,a);var o=this._multiPartFooter();n(s);n(t);n(o);this._trackLength(s,t,a)};FormData.prototype._trackLength=function(e,t,a){var r=0;if(a.knownLength!=null){r+=+a.knownLength}else if(Buffer.isBuffer(t)){r=t.length}else if(typeof t==="string"){r=Buffer.byteLength(t)}this._valueLength+=r;this._overheadLength+=Buffer.byteLength(e)+FormData.LINE_BREAK.length;if(!t||!t.path&&!(t.readable&&t.hasOwnProperty("httpVersion"))&&!(t instanceof d)){return}if(!a.knownLength){this._valuesToMeasure.push(t)}};FormData.prototype._lengthRetriever=function(e,t){if(e.hasOwnProperty("fd")){if(e.end!=undefined&&e.end!=Infinity&&e.start!=undefined){t(null,e.end+1-(e.start?e.start:0))}else{l.stat(e.path,(function(a,r){var i;if(a){t(a);return}i=r.size-(e.start?e.start:0);t(null,i)}))}}else if(e.hasOwnProperty("httpVersion")){t(null,+e.headers["content-length"])}else if(e.hasOwnProperty("httpModule")){e.on("response",(function(a){e.pause();t(null,+a.headers["content-length"])}));e.resume()}else{t("Unknown stream")}};FormData.prototype._multiPartHeader=function(e,t,a){if(typeof a.header=="string"){return a.header}var r=this._getContentDisposition(t,a);var i=this._getContentType(t,a);var n="";var s={"Content-Disposition":["form-data",'name="'+e+'"'].concat(r||[]),"Content-Type":[].concat(i||[])};if(typeof a.header=="object"){u(s,a.header)}var o;for(var p in s){if(!s.hasOwnProperty(p))continue;o=s[p];if(o==null){continue}if(!Array.isArray(o)){o=[o]}if(o.length){n+=p+": "+o.join("; ")+FormData.LINE_BREAK}}return"--"+this.getBoundary()+FormData.LINE_BREAK+n+FormData.LINE_BREAK};FormData.prototype._getContentDisposition=function(e,t){var a,r;if(typeof t.filepath==="string"){a=n.normalize(t.filepath).replace(/\\/g,"/")}else if(t.filename||e.name||e.path){a=n.basename(t.filename||e.name||e.path)}else if(e.readable&&e.hasOwnProperty("httpVersion")){a=n.basename(e.client._httpMessage.path||"")}if(a){r='filename="'+a+'"'}return r};FormData.prototype._getContentType=function(e,t){var a=t.contentType;if(!a&&e.name){a=c.lookup(e.name)}if(!a&&e.path){a=c.lookup(e.path)}if(!a&&e.readable&&e.hasOwnProperty("httpVersion")){a=e.headers["content-type"]}if(!a&&(t.filepath||t.filename)){a=c.lookup(t.filepath||t.filename)}if(!a&&typeof e=="object"){a=FormData.DEFAULT_CONTENT_TYPE}return a};FormData.prototype._multiPartFooter=function(){return function(e){var t=FormData.LINE_BREAK;var a=this._streams.length===0;if(a){t+=this._lastBoundary()}e(t)}.bind(this)};FormData.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+FormData.LINE_BREAK};FormData.prototype.getHeaders=function(e){var t;var a={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e){if(e.hasOwnProperty(t)){a[t.toLowerCase()]=e[t]}}return a};FormData.prototype.setBoundary=function(e){this._boundary=e};FormData.prototype.getBoundary=function(){if(!this._boundary){this._generateBoundary()}return this._boundary};FormData.prototype.getBuffer=function(){var e=new Buffer.alloc(0);var t=this.getBoundary();for(var a=0,r=this._streams.length;a{e.exports=function(e,t){Object.keys(t).forEach((function(a){e[a]=e[a]||t[a]}));return e}},2107:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var B=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);B(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var L=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new L(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},7094:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(3233);var i=a(2557);var n=a(1333);const s=r.createClientLogger("core-lro");const o=2e3;const p=["succeeded","canceled","failed"];function deserializeState(e){try{return JSON.parse(e).state}catch(t){throw new Error(`Unable to deserialize input state: ${e}`)}}function setStateError(e){const{state:t,stateProxy:a,isOperationError:r}=e;return e=>{if(r(e)){a.setError(t,e);a.setFailed(t)}throw e}}function appendReadableErrorMessage(e,t){let a=e;if(a.slice(-1)!=="."){a=a+"."}return a+" "+t}function simplifyError(e){let t=e.message;let a=e.code;let r=e;while(r.innererror){r=r.innererror;a=r.code;t=appendReadableErrorMessage(t,r.message)}return{code:a,message:t}}function processOperationStatus(e){const{state:t,stateProxy:a,status:r,isDone:i,processResult:n,getError:o,response:p,setErrorAsResult:l}=e;switch(r){case"succeeded":{a.setSucceeded(t);break}case"failed":{const e=o===null||o===void 0?void 0:o(p);let r="";if(e){const{code:t,message:a}=simplifyError(e);r=`. ${t}. ${a}`}const i=`The long-running operation has failed${r}`;a.setError(t,new Error(i));a.setFailed(t);s.warning(i);break}case"canceled":{a.setCanceled(t);break}}if((i===null||i===void 0?void 0:i(p,t))||i===undefined&&["succeeded","canceled"].concat(l?[]:["failed"]).includes(r)){a.setResult(t,buildResult({response:p,state:t,processResult:n}))}}function buildResult(e){const{processResult:t,response:a,state:r}=e;return t?t(a,r):a}async function initOperation(e){const{init:t,stateProxy:a,processResult:r,getOperationStatus:i,withOperationLocation:n,setErrorAsResult:o}=e;const{operationLocation:p,resourceLocation:l,metadata:d,response:c}=await t();if(p)n===null||n===void 0?void 0:n(p,false);const m={metadata:d,operationLocation:p,resourceLocation:l};s.verbose(`LRO: Operation description:`,m);const u=a.initState(m);const h=i({response:c,state:u,operationLocation:p});processOperationStatus({state:u,status:h,stateProxy:a,response:c,setErrorAsResult:o,processResult:r});return u}async function pollOperationHelper(e){const{poll:t,state:a,stateProxy:r,operationLocation:i,getOperationStatus:n,getResourceLocation:o,isOperationError:l,options:d}=e;const c=await t(i,d).catch(setStateError({state:a,stateProxy:r,isOperationError:l}));const m=n(c,a);s.verbose(`LRO: Status:\n\tPolling from: ${a.config.operationLocation}\n\tOperation status: ${m}\n\tPolling status: ${p.includes(m)?"Stopped":"Running"}`);if(m==="succeeded"){const e=o(c,a);if(e!==undefined){return{response:await t(e).catch(setStateError({state:a,stateProxy:r,isOperationError:l})),status:m}}}return{response:c,status:m}}async function pollOperation(e){const{poll:t,state:a,stateProxy:r,options:i,getOperationStatus:n,getResourceLocation:s,getOperationLocation:o,isOperationError:l,withOperationLocation:d,getPollingInterval:c,processResult:m,getError:u,updateState:h,setDelay:g,isDone:y,setErrorAsResult:v}=e;const{operationLocation:b}=a.config;if(b!==undefined){const{response:e,status:x}=await pollOperationHelper({poll:t,getOperationStatus:n,state:a,stateProxy:r,operationLocation:b,getResourceLocation:s,isOperationError:l,options:i});processOperationStatus({status:x,response:e,state:a,stateProxy:r,isDone:y,processResult:m,getError:u,setErrorAsResult:v});if(!p.includes(x)){const t=c===null||c===void 0?void 0:c(e);if(t)g(t);const r=o===null||o===void 0?void 0:o(e,a);if(r!==undefined){const e=b!==r;a.config.operationLocation=r;d===null||d===void 0?void 0:d(r,e)}else d===null||d===void 0?void 0:d(b,false)}h===null||h===void 0?void 0:h(a,e)}}function getOperationLocationPollingUrl(e){const{azureAsyncOperation:t,operationLocation:a}=e;return a!==null&&a!==void 0?a:t}function getLocationHeader(e){return e.headers["location"]}function getOperationLocationHeader(e){return e.headers["operation-location"]}function getAzureAsyncOperationHeader(e){return e.headers["azure-asyncoperation"]}function findResourceLocation(e){var t;const{location:a,requestMethod:r,requestPath:i,resourceLocationConfig:n}=e;switch(r){case"PUT":{return i}case"DELETE":{return undefined}case"PATCH":{return(t=getDefault())!==null&&t!==void 0?t:i}default:{return getDefault()}}function getDefault(){switch(n){case"azure-async-operation":{return undefined}case"original-uri":{return i}case"location":default:{return a}}}}function inferLroMode(e){const{rawResponse:t,requestMethod:a,requestPath:r,resourceLocationConfig:i}=e;const n=getOperationLocationHeader(t);const s=getAzureAsyncOperationHeader(t);const o=getOperationLocationPollingUrl({operationLocation:n,azureAsyncOperation:s});const p=getLocationHeader(t);const l=a===null||a===void 0?void 0:a.toLocaleUpperCase();if(o!==undefined){return{mode:"OperationLocation",operationLocation:o,resourceLocation:findResourceLocation({requestMethod:l,location:p,requestPath:r,resourceLocationConfig:i})}}else if(p!==undefined){return{mode:"ResourceLocation",operationLocation:p}}else if(l==="PUT"&&r){return{mode:"Body",operationLocation:r}}else{return undefined}}function transformStatus(e){const{status:t,statusCode:a}=e;if(typeof t!=="string"&&t!==undefined){throw new Error(`Polling was unsuccessful. Expected status to have a string value or no value but it has instead: ${t}. This doesn't necessarily indicate the operation has failed. Check your Azure subscription or resource status for more information.`)}switch(t===null||t===void 0?void 0:t.toLocaleLowerCase()){case undefined:return toOperationStatus(a);case"succeeded":return"succeeded";case"failed":return"failed";case"running":case"accepted":case"started":case"canceling":case"cancelling":return"running";case"canceled":case"cancelled":return"canceled";default:{s.verbose(`LRO: unrecognized operation status: ${t}`);return t}}}function getStatus(e){var t;const{status:a}=(t=e.body)!==null&&t!==void 0?t:{};return transformStatus({status:a,statusCode:e.statusCode})}function getProvisioningState(e){var t,a;const{properties:r,provisioningState:i}=(t=e.body)!==null&&t!==void 0?t:{};const n=(a=r===null||r===void 0?void 0:r.provisioningState)!==null&&a!==void 0?a:i;return transformStatus({status:n,statusCode:e.statusCode})}function toOperationStatus(e){if(e===202){return"running"}else if(e<300){return"succeeded"}else{return"failed"}}function parseRetryAfter({rawResponse:e}){const t=e.headers["retry-after"];if(t!==undefined){const e=parseInt(t);return isNaN(e)?calculatePollingIntervalFromDate(new Date(t)):e*1e3}return undefined}function getErrorFromResponse(e){const t=e.flatResponse.error;if(!t){s.warning(`The long-running operation failed but there is no error property in the response's body`);return}if(!t.code||!t.message){s.warning(`The long-running operation failed but the error property in the response's body doesn't contain code or message`);return}return t}function calculatePollingIntervalFromDate(e){const t=Math.floor((new Date).getTime());const a=e.getTime();if(t{const e=await i.sendInitialRequest();const t=inferLroMode({rawResponse:e.rawResponse,requestPath:i.requestPath,requestMethod:i.requestMethod,resourceLocationConfig:a});return Object.assign({response:e,operationLocation:t===null||t===void 0?void 0:t.operationLocation,resourceLocation:t===null||t===void 0?void 0:t.resourceLocation},(t===null||t===void 0?void 0:t.mode)?{metadata:{mode:t.mode}}:{})},stateProxy:t,processResult:r?({flatResponse:e},t)=>r(e,t):({flatResponse:e})=>e,getOperationStatus:getStatusFromInitialResponse,setErrorAsResult:n})}function getOperationLocation({rawResponse:e},t){var a;const r=(a=t.config.metadata)===null||a===void 0?void 0:a["mode"];switch(r){case"OperationLocation":{return getOperationLocationPollingUrl({operationLocation:getOperationLocationHeader(e),azureAsyncOperation:getAzureAsyncOperationHeader(e)})}case"ResourceLocation":{return getLocationHeader(e)}case"Body":default:{return undefined}}}function getOperationStatus({rawResponse:e},t){var a;const r=(a=t.config.metadata)===null||a===void 0?void 0:a["mode"];switch(r){case"OperationLocation":{return getStatus(e)}case"ResourceLocation":{return toOperationStatus(e.statusCode)}case"Body":{return getProvisioningState(e)}default:throw new Error(`Internal error: Unexpected operation mode: ${r}`)}}function getResourceLocation({flatResponse:e},t){if(typeof e==="object"){const a=e.resourceLocation;if(a!==undefined){t.config.resourceLocation=a}}return t.config.resourceLocation}function isOperationError(e){return e.name==="RestError"}async function pollHttpOperation(e){const{lro:t,stateProxy:a,options:r,processResult:i,updateState:n,setDelay:s,state:o,setErrorAsResult:p}=e;return pollOperation({state:o,stateProxy:a,setDelay:s,processResult:i?({flatResponse:e},t)=>i(e,t):({flatResponse:e})=>e,getError:getErrorFromResponse,updateState:n,getPollingInterval:parseRetryAfter,getOperationLocation:getOperationLocation,getOperationStatus:getOperationStatus,isOperationError:isOperationError,getResourceLocation:getResourceLocation,options:r,poll:async(e,a)=>t.sendPollRequest(e,a),setErrorAsResult:p})}const createStateProxy$1=()=>({initState:e=>({status:"running",config:e}),setCanceled:e=>e.status="canceled",setError:(e,t)=>e.error=t,setResult:(e,t)=>e.result=t,setRunning:e=>e.status="running",setSucceeded:e=>e.status="succeeded",setFailed:e=>e.status="failed",getError:e=>e.error,getResult:e=>e.result,isCanceled:e=>e.status==="canceled",isFailed:e=>e.status==="failed",isRunning:e=>e.status==="running",isSucceeded:e=>e.status==="succeeded"});function buildCreatePoller(e){const{getOperationLocation:t,getStatusFromInitialResponse:a,getStatusFromPollResponse:r,isOperationError:s,getResourceLocation:p,getPollingInterval:l,getError:d,resolveOnUnsuccessful:c}=e;return async({init:e,poll:m},u)=>{const{processResult:h,updateState:g,withOperationLocation:y,intervalInMs:v=o,restoreFrom:b}=u||{};const x=createStateProxy$1();const w=y?(()=>{let e=false;return(t,a)=>{if(a)y(t);else if(!e)y(t);e=true}})():undefined;const S=b?deserializeState(b):await initOperation({init:e,stateProxy:x,processResult:h,getOperationStatus:a,withOperationLocation:w,setErrorAsResult:!c});let N;const T=new i.AbortController;const E=new Map;const handleProgressEvents=async()=>E.forEach((e=>e(S)));const _="Operation was canceled";let P=v;const C={getOperationState:()=>S,getResult:()=>S.result,isDone:()=>["succeeded","failed","canceled"].includes(S.status),isStopped:()=>N===undefined,stopPolling:()=>{T.abort()},toString:()=>JSON.stringify({state:S}),onProgress:e=>{const t=Symbol();E.set(t,e);return()=>E.delete(t)},pollUntilDone:e=>N!==null&&N!==void 0?N:N=(async()=>{const{abortSignal:t}=e||{};const{signal:a}=t?new i.AbortController([t,T.signal]):T;if(!C.isDone()){await C.poll({abortSignal:a});while(!C.isDone()){await n.delay(P,{abortSignal:a});await C.poll({abortSignal:a})}}if(c){return C.getResult()}else{switch(S.status){case"succeeded":return C.getResult();case"canceled":throw new Error(_);case"failed":throw S.error;case"notStarted":case"running":throw new Error(`Polling completed without succeeding or failing`)}}})().finally((()=>{N=undefined})),async poll(e){if(c){if(C.isDone())return}else{switch(S.status){case"succeeded":return;case"canceled":throw new Error(_);case"failed":throw S.error}}await pollOperation({poll:m,state:S,stateProxy:x,getOperationLocation:t,isOperationError:s,withOperationLocation:w,getPollingInterval:l,getOperationStatus:r,getResourceLocation:p,processResult:h,getError:d,updateState:g,options:e,setDelay:e=>{P=e},setErrorAsResult:!c});await handleProgressEvents();if(!c){switch(S.status){case"canceled":throw new Error(_);case"failed":throw S.error}}}};return C}}async function createHttpPoller(e,t){const{resourceLocationConfig:a,intervalInMs:r,processResult:i,restoreFrom:n,updateState:s,withOperationLocation:o,resolveOnUnsuccessful:p=false}=t||{};return buildCreatePoller({getStatusFromInitialResponse:getStatusFromInitialResponse,getStatusFromPollResponse:getOperationStatus,isOperationError:isOperationError,getOperationLocation:getOperationLocation,getResourceLocation:getResourceLocation,getPollingInterval:parseRetryAfter,getError:getErrorFromResponse,resolveOnUnsuccessful:p})({init:async()=>{const t=await e.sendInitialRequest();const r=inferLroMode({rawResponse:t.rawResponse,requestPath:e.requestPath,requestMethod:e.requestMethod,resourceLocationConfig:a});return Object.assign({response:t,operationLocation:r===null||r===void 0?void 0:r.operationLocation,resourceLocation:r===null||r===void 0?void 0:r.resourceLocation},(r===null||r===void 0?void 0:r.mode)?{metadata:{mode:r.mode}}:{})},poll:e.sendPollRequest},{intervalInMs:r,withOperationLocation:o,restoreFrom:n,updateState:s,processResult:i?({flatResponse:e},t)=>i(e,t):({flatResponse:e})=>e})}const createStateProxy=()=>({initState:e=>({config:e,isStarted:true}),setCanceled:e=>e.isCancelled=true,setError:(e,t)=>e.error=t,setResult:(e,t)=>e.result=t,setRunning:e=>e.isStarted=true,setSucceeded:e=>e.isCompleted=true,setFailed:()=>{},getError:e=>e.error,getResult:e=>e.result,isCanceled:e=>!!e.isCancelled,isFailed:e=>!!e.error,isRunning:e=>!!e.isStarted,isSucceeded:e=>Boolean(e.isCompleted&&!e.isCancelled&&!e.error)});class GenericPollOperation{constructor(e,t,a,r,i,n,s){this.state=e;this.lro=t;this.setErrorAsResult=a;this.lroResourceLocationConfig=r;this.processResult=i;this.updateState=n;this.isDone=s}setPollerConfig(e){this.pollerConfig=e}async update(e){var t;const a=createStateProxy();if(!this.state.isStarted){this.state=Object.assign(Object.assign({},this.state),await initHttpOperation({lro:this.lro,stateProxy:a,resourceLocationConfig:this.lroResourceLocationConfig,processResult:this.processResult,setErrorAsResult:this.setErrorAsResult}))}const r=this.updateState;const i=this.isDone;if(!this.state.isCompleted&&this.state.error===undefined){await pollHttpOperation({lro:this.lro,state:this.state,stateProxy:a,processResult:this.processResult,updateState:r?(e,{rawResponse:t})=>r(e,t):undefined,isDone:i?({flatResponse:e},t)=>i(e,t):undefined,options:e,setDelay:e=>{this.pollerConfig.intervalInMs=e},setErrorAsResult:this.setErrorAsResult})}(t=e===null||e===void 0?void 0:e.fireProgress)===null||t===void 0?void 0:t.call(e,this.state);return this}async cancel(){s.error("`cancelOperation` is deprecated because it wasn't implemented");return this}toString(){return JSON.stringify({state:this.state})}}class PollerStoppedError extends Error{constructor(e){super(e);this.name="PollerStoppedError";Object.setPrototypeOf(this,PollerStoppedError.prototype)}}class PollerCancelledError extends Error{constructor(e){super(e);this.name="PollerCancelledError";Object.setPrototypeOf(this,PollerCancelledError.prototype)}}class Poller{constructor(e){this.resolveOnUnsuccessful=false;this.stopped=true;this.pollProgressCallbacks=[];this.operation=e;this.promise=new Promise(((e,t)=>{this.resolve=e;this.reject=t}));this.promise.catch((()=>{}))}async startPolling(e={}){if(this.stopped){this.stopped=false}while(!this.isStopped()&&!this.isDone()){await this.poll(e);await this.delay()}}async pollOnce(e={}){if(!this.isDone()){this.operation=await this.operation.update({abortSignal:e.abortSignal,fireProgress:this.fireProgress.bind(this)})}this.processUpdatedState()}fireProgress(e){for(const t of this.pollProgressCallbacks){t(e)}}async cancelOnce(e={}){this.operation=await this.operation.cancel(e)}poll(e={}){if(!this.pollOncePromise){this.pollOncePromise=this.pollOnce(e);const clearPollOncePromise=()=>{this.pollOncePromise=undefined};this.pollOncePromise.then(clearPollOncePromise,clearPollOncePromise).catch(this.reject)}return this.pollOncePromise}processUpdatedState(){if(this.operation.state.error){this.stopped=true;if(!this.resolveOnUnsuccessful){this.reject(this.operation.state.error);throw this.operation.state.error}}if(this.operation.state.isCancelled){this.stopped=true;if(!this.resolveOnUnsuccessful){const e=new PollerCancelledError("Operation was canceled");this.reject(e);throw e}}if(this.isDone()&&this.resolve){this.resolve(this.getResult())}}async pollUntilDone(e={}){if(this.stopped){this.startPolling(e).catch(this.reject)}this.processUpdatedState();return this.promise}onProgress(e){this.pollProgressCallbacks.push(e);return()=>{this.pollProgressCallbacks=this.pollProgressCallbacks.filter((t=>t!==e))}}isDone(){const e=this.operation.state;return Boolean(e.isCompleted||e.isCancelled||e.error)}stopPolling(){if(!this.stopped){this.stopped=true;if(this.reject){this.reject(new PollerStoppedError("This poller is already stopped"))}}}isStopped(){return this.stopped}cancelOperation(e={}){if(!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(){const e=this.operation.state;return e.result}toString(){return this.operation.toString()}}class LroEngine extends Poller{constructor(e,t){const{intervalInMs:a=o,resumeFrom:r,resolveOnUnsuccessful:i=false,isDone:n,lroResourceLocationConfig:s,processResult:p,updateState:l}=t||{};const d=r?deserializeState(r):{};const c=new GenericPollOperation(d,e,!i,s,p,l,n);super(c);this.resolveOnUnsuccessful=i;this.config={intervalInMs:a};c.setPollerConfig(this.config)}delay(){return new Promise((e=>setTimeout((()=>e()),this.config.intervalInMs)))}}t.LroEngine=LroEngine;t.Poller=Poller;t.PollerCancelledError=PollerCancelledError;t.PollerStoppedError=PollerStoppedError;t.createHttpPoller=createHttpPoller},4559:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(6429);function getPagedAsyncIterator(e){var t;const a=getItemAsyncIterator(e);return{next(){return a.next()},[Symbol.asyncIterator](){return this},byPage:(t=e===null||e===void 0?void 0:e.byPage)!==null&&t!==void 0?t:t=>{const{continuationToken:a,maxPageSize:r}=t!==null&&t!==void 0?t:{};return getPageAsyncIterator(e,{pageLink:a,maxPageSize:r})}}}function getItemAsyncIterator(e){return r.__asyncGenerator(this,arguments,(function*getItemAsyncIterator_1(){var t,a,i,n;const s=getPageAsyncIterator(e);const o=yield r.__await(s.next());if(!Array.isArray(o.value)){const{toElements:i}=e;if(i){yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(i(o.value))));try{for(var p=r.__asyncValues(s),l;l=yield r.__await(p.next()),!l.done;){const e=l.value;yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(i(e))))}}catch(e){t={error:e}}finally{try{if(l&&!l.done&&(a=p.return))yield r.__await(a.call(p))}finally{if(t)throw t.error}}}else{yield yield r.__await(o.value);yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(s)))}}else{yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(o.value)));try{for(var d=r.__asyncValues(s),c;c=yield r.__await(d.next()),!c.done;){const e=c.value;yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(e)))}}catch(e){i={error:e}}finally{try{if(c&&!c.done&&(n=d.return))yield r.__await(n.call(d))}finally{if(i)throw i.error}}}}))}function getPageAsyncIterator(e,t={}){return r.__asyncGenerator(this,arguments,(function*getPageAsyncIterator_1(){const{pageLink:a,maxPageSize:i}=t;let n=yield r.__await(e.getPage(a!==null&&a!==void 0?a:e.firstPageLink,i));if(!n){return yield r.__await(void 0)}yield yield r.__await(n.page);while(n.nextPageLink){n=yield r.__await(e.getPage(n.nextPageLink,i));if(!n){return yield r.__await(void 0)}yield yield r.__await(n.page)}}))}t.getPagedAsyncIterator=getPagedAsyncIterator},6429:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var B=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);B(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var L=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new L(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},4175:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5163);(function(e){e[e["INTERNAL"]=0]="INTERNAL";e[e["SERVER"]=1]="SERVER";e[e["CLIENT"]=2]="CLIENT";e[e["PRODUCER"]=3]="PRODUCER";e[e["CONSUMER"]=4]="CONSUMER"})(t.SpanKind||(t.SpanKind={}));function getSpan(e){return r.trace.getSpan(e)}function setSpan(e,t){return r.trace.setSpan(e,t)}function setSpanContext(e,t){return r.trace.setSpanContext(e,t)}function getSpanContext(e){return r.trace.getSpanContext(e)}function isSpanContextValid(e){return r.trace.isSpanContextValid(e)}function getTracer(e,t){return r.trace.getTracer(e||"azure/core-tracing",t)}const i=r.context;(function(e){e[e["UNSET"]=0]="UNSET";e[e["OK"]=1]="OK";e[e["ERROR"]=2]="ERROR"})(t.SpanStatusCode||(t.SpanStatusCode={}));function isTracingDisabled(){var e;if(typeof process==="undefined"){return false}const t=(e=process.env.AZURE_TRACING_DISABLED)===null||e===void 0?void 0:e.toLowerCase();if(t==="false"||t==="0"){return false}return Boolean(t)}function createSpanFunction(e){return function(a,n){const s=getTracer();const o=(n===null||n===void 0?void 0:n.tracingOptions)||{};const p=Object.assign({kind:t.SpanKind.INTERNAL},o.spanOptions);const l=e.packagePrefix?`${e.packagePrefix}.${a}`:a;let d;if(isTracingDisabled()){d=r.trace.wrapSpanContext(r.INVALID_SPAN_CONTEXT)}else{d=s.startSpan(l,p,o.tracingContext)}if(e.namespace){d.setAttribute("az.namespace",e.namespace)}let c=o.spanOptions||{};if(d.isRecording()&&e.namespace){c=Object.assign(Object.assign({},o.spanOptions),{attributes:Object.assign(Object.assign({},p.attributes),{"az.namespace":e.namespace})})}const m=Object.assign(Object.assign({},o),{spanOptions:c,tracingContext:setSpan(o.tracingContext||i.active(),d)});const u=Object.assign(Object.assign({},n),{tracingOptions:m});return{span:d,updatedOptions:u}}}const n="00";function extractSpanContextFromTraceParentHeader(e){const t=e.split("-");if(t.length!==4){return}const[a,r,i,s]=t;if(a!==n){return}const o=parseInt(s,16);const p={spanId:i,traceId:r,traceFlags:o};return p}function getTraceParentHeader(e){const t=[];if(!e.traceId){t.push("traceId")}if(!e.spanId){t.push("spanId")}if(t.length){return}const a=e.traceFlags||0;const r=a.toString(16);const i=r.length===1?`0${r}`:r;return`${n}-${e.traceId}-${e.spanId}-${i}`}t.context=i;t.createSpanFunction=createSpanFunction;t.extractSpanContextFromTraceParentHeader=extractSpanContextFromTraceParentHeader;t.getSpan=getSpan;t.getSpanContext=getSpanContext;t.getTraceParentHeader=getTraceParentHeader;t.getTracer=getTracer;t.isSpanContextValid=isSpanContextValid;t.setSpan=setSpan;t.setSpanContext=setSpanContext},1333:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(2557);var i=a(6113);function createAbortablePromise(e,t){const{cleanupBeforeAbort:a,abortSignal:i,abortErrorMsg:n}=t!==null&&t!==void 0?t:{};return new Promise(((t,s)=>{function rejectOnAbort(){s(new r.AbortError(n!==null&&n!==void 0?n:"The operation was aborted."))}function removeListeners(){i===null||i===void 0?void 0:i.removeEventListener("abort",onAbort)}function onAbort(){a===null||a===void 0?void 0:a();removeListeners();rejectOnAbort()}if(i===null||i===void 0?void 0:i.aborted){return rejectOnAbort()}try{e((e=>{removeListeners();t(e)}),(e=>{removeListeners();s(e)}))}catch(e){s(e)}i===null||i===void 0?void 0:i.addEventListener("abort",onAbort)}))}const n="The delay was aborted.";function delay(e,t){let a;const{abortSignal:r,abortErrorMsg:i}=t!==null&&t!==void 0?t:{};return createAbortablePromise((t=>{a=setTimeout(t,e)}),{cleanupBeforeAbort:()=>clearTimeout(a),abortSignal:r,abortErrorMsg:i!==null&&i!==void 0?i:n})}function getRandomIntegerInclusive(e,t){e=Math.ceil(e);t=Math.floor(t);const a=Math.floor(Math.random()*(t-e+1));return a+e}function isObject(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}function isError(e){if(isObject(e)){const t=typeof e.name==="string";const a=typeof e.message==="string";return t&&a}return false}function getErrorMessage(e){if(isError(e)){return e.message}else{let t;try{if(typeof e==="object"&&e){t=JSON.stringify(e)}else{t=String(e)}}catch(e){t="[unable to stringify input]"}return`Unknown error ${t}`}}async function computeSha256Hmac(e,t,a){const r=Buffer.from(e,"base64");return i.createHmac("sha256",r).update(t).digest(a)}async function computeSha256Hash(e,t){return i.createHash("sha256").update(e).digest(t)}function isDefined(e){return typeof e!=="undefined"&&e!==null}function isObjectWithProperties(e,t){if(!isDefined(e)||typeof e!=="object"){return false}for(const a of t){if(!objectHasProperty(e,a)){return false}}return true}function objectHasProperty(e,t){return isDefined(e)&&typeof e==="object"&&t in e}function generateUUID(){let e="";for(let t=0;t<32;t++){const a=Math.floor(Math.random()*16);if(t===12){e+="4"}else if(t===16){e+=a&3|8}else{e+=a.toString(16)}if(t===7||t===11||t===15||t===19){e+="-"}}return e}var s;let o=typeof((s=globalThis===null||globalThis===void 0?void 0:globalThis.crypto)===null||s===void 0?void 0:s.randomUUID)==="function"?globalThis.crypto.randomUUID.bind(globalThis.crypto):i.randomUUID;if(!o){o=generateUUID}function randomUUID(){return o()}var p,l,d,c;const m=typeof window!=="undefined"&&typeof window.document!=="undefined";const u=typeof self==="object"&&typeof(self===null||self===void 0?void 0:self.importScripts)==="function"&&(((p=self.constructor)===null||p===void 0?void 0:p.name)==="DedicatedWorkerGlobalScope"||((l=self.constructor)===null||l===void 0?void 0:l.name)==="ServiceWorkerGlobalScope"||((d=self.constructor)===null||d===void 0?void 0:d.name)==="SharedWorkerGlobalScope");const h=typeof process!=="undefined"&&Boolean(process.version)&&Boolean((c=process.versions)===null||c===void 0?void 0:c.node);const g=typeof Deno!=="undefined"&&typeof Deno.version!=="undefined"&&typeof Deno.version.deno!=="undefined";const y=typeof Bun!=="undefined"&&typeof Bun.version!=="undefined";const v=typeof navigator!=="undefined"&&(navigator===null||navigator===void 0?void 0:navigator.product)==="ReactNative";function uint8ArrayToString(e,t){switch(t){case"utf-8":return uint8ArrayToUtf8String(e);case"base64":return uint8ArrayToBase64(e);case"base64url":return uint8ArrayToBase64Url(e)}}function stringToUint8Array(e,t){switch(t){case"utf-8":return utf8StringToUint8Array(e);case"base64":return base64ToUint8Array(e);case"base64url":return base64UrlToUint8Array(e)}}function uint8ArrayToBase64(e){return Buffer.from(e).toString("base64")}function uint8ArrayToBase64Url(e){return Buffer.from(e).toString("base64url")}function uint8ArrayToUtf8String(e){return Buffer.from(e).toString("utf-8")}function utf8StringToUint8Array(e){return Buffer.from(e)}function base64ToUint8Array(e){return Buffer.from(e,"base64")}function base64UrlToUint8Array(e){return Buffer.from(e,"base64url")}t.computeSha256Hash=computeSha256Hash;t.computeSha256Hmac=computeSha256Hmac;t.createAbortablePromise=createAbortablePromise;t.delay=delay;t.getErrorMessage=getErrorMessage;t.getRandomIntegerInclusive=getRandomIntegerInclusive;t.isBrowser=m;t.isBun=y;t.isDefined=isDefined;t.isDeno=g;t.isError=isError;t.isNode=h;t.isObject=isObject;t.isObjectWithProperties=isObjectWithProperties;t.isReactNative=v;t.isWebWorker=u;t.objectHasProperty=objectHasProperty;t.randomUUID=randomUUID;t.stringToUint8Array=stringToUint8Array;t.uint8ArrayToString=uint8ArrayToString},3233:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(2037);var i=a(3837);function _interopDefaultLegacy(e){return e&&typeof e==="object"&&"default"in e?e:{default:e}}var n=_interopDefaultLegacy(i);function log(e,...t){process.stderr.write(`${n["default"].format(e,...t)}${r.EOL}`)}const s=typeof process!=="undefined"&&process.env&&process.env.DEBUG||undefined;let o;let p=[];let l=[];const d=[];if(s){enable(s)}const c=Object.assign((e=>createDebugger(e)),{enable:enable,enabled:enabled,disable:disable,log:log});function enable(e){o=e;p=[];l=[];const t=/\*/g;const a=e.split(",").map((e=>e.trim().replace(t,".*?")));for(const e of a){if(e.startsWith("-")){l.push(new RegExp(`^${e.substr(1)}$`))}else{p.push(new RegExp(`^${e}$`))}}for(const e of d){e.enabled=enabled(e.namespace)}}function enabled(e){if(e.endsWith("*")){return true}for(const t of l){if(t.test(e)){return false}}for(const t of p){if(t.test(e)){return true}}return false}function disable(){const e=o||"";enable("");return e}function createDebugger(e){const t=Object.assign(debug,{enabled:enabled(e),destroy:destroy,log:c.log,namespace:e,extend:extend});function debug(...a){if(!t.enabled){return}if(a.length>0){a[0]=`${e} ${a[0]}`}t.log(...a)}d.push(t);return t}function destroy(){const e=d.indexOf(this);if(e>=0){d.splice(e,1);return true}return false}function extend(e){const t=createDebugger(`${this.namespace}:${e}`);t.log=this.log;return t}var m=c;const u=new Set;const h=typeof process!=="undefined"&&process.env&&process.env.AZURE_LOG_LEVEL||undefined;let g;const y=m("azure");y.log=(...e)=>{m.log(...e)};const v=["verbose","info","warning","error"];if(h){if(isAzureLogLevel(h)){setLogLevel(h)}else{console.error(`AZURE_LOG_LEVEL set to unknown log level '${h}'; logging is not enabled. Acceptable values: ${v.join(", ")}.`)}}function setLogLevel(e){if(e&&!isAzureLogLevel(e)){throw new Error(`Unknown log level '${e}'. Acceptable values: ${v.join(",")}`)}g=e;const t=[];for(const e of u){if(shouldEnable(e)){t.push(e.namespace)}}m.enable(t.join(","))}function getLogLevel(){return g}const b={verbose:400,info:300,warning:200,error:100};function createClientLogger(e){const t=y.extend(e);patchLogMethod(y,t);return{error:createLogger(t,"error"),warning:createLogger(t,"warning"),info:createLogger(t,"info"),verbose:createLogger(t,"verbose")}}function patchLogMethod(e,t){t.log=(...t)=>{e.log(...t)}}function createLogger(e,t){const a=Object.assign(e.extend(t),{level:t});patchLogMethod(e,a);if(shouldEnable(a)){const e=m.disable();m.enable(e+","+a.namespace)}u.add(a);return a}function shouldEnable(e){return Boolean(g&&b[e.level]<=b[g])}function isAzureLogLevel(e){return v.includes(e)}t.AzureLogger=y;t.createClientLogger=createClientLogger;t.getLogLevel=getLogLevel;t.setLogLevel=setLogLevel},4100:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(4607);var i=a(679);var n=a(4175);var s=a(3233);var o=a(2557);var p=a(2037);var l=a(6113);var d=a(2781);a(4559);var c=a(7094);var m=a(2361);var u=a(7147);var h=a(3837);function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(a){if(a!=="default"){var r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:true,get:function(){return e[a]}})}}))}t["default"]=e;return Object.freeze(t)}var g=_interopNamespace(r);var y=_interopNamespace(p);var v=_interopNamespace(u);var b=_interopNamespace(h);const x={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:true,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"}}}}};const w={serializedName:"Logging",type:{name:"Composite",className:"Logging",modelProperties:{version:{serializedName:"Version",required:true,xmlName:"Version",type:{name:"String"}},deleteProperty:{serializedName:"Delete",required:true,xmlName:"Delete",type:{name:"Boolean"}},read:{serializedName:"Read",required:true,xmlName:"Read",type:{name:"Boolean"}},write:{serializedName:"Write",required:true,xmlName:"Write",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}};const S={serializedName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy",modelProperties:{enabled:{serializedName:"Enabled",required:true,xmlName:"Enabled",type:{name:"Boolean"}},days:{constraints:{InclusiveMinimum:1},serializedName:"Days",xmlName:"Days",type:{name:"Number"}}}}};const N={serializedName:"Metrics",type:{name:"Composite",className:"Metrics",modelProperties:{version:{serializedName:"Version",xmlName:"Version",type:{name:"String"}},enabled:{serializedName:"Enabled",required:true,xmlName:"Enabled",type:{name:"Boolean"}},includeAPIs:{serializedName:"IncludeAPIs",xmlName:"IncludeAPIs",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}};const T={serializedName:"CorsRule",type:{name:"Composite",className:"CorsRule",modelProperties:{allowedOrigins:{serializedName:"AllowedOrigins",required:true,xmlName:"AllowedOrigins",type:{name:"String"}},allowedMethods:{serializedName:"AllowedMethods",required:true,xmlName:"AllowedMethods",type:{name:"String"}},allowedHeaders:{serializedName:"AllowedHeaders",required:true,xmlName:"AllowedHeaders",type:{name:"String"}},exposedHeaders:{serializedName:"ExposedHeaders",required:true,xmlName:"ExposedHeaders",type:{name:"String"}},maxAgeInSeconds:{constraints:{InclusiveMinimum:0},serializedName:"MaxAgeInSeconds",required:true,xmlName:"MaxAgeInSeconds",type:{name:"Number"}}}}};const E={serializedName:"StaticWebsite",type:{name:"Composite",className:"StaticWebsite",modelProperties:{enabled:{serializedName:"Enabled",required:true,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"}}}}};const _={serializedName:"StorageError",type:{name:"Composite",className:"StorageError",modelProperties:{message:{serializedName:"Message",xmlName:"Message",type:{name:"String"}},code:{serializedName:"Code",xmlName:"Code",type:{name:"String"}}}}};const P={serializedName:"BlobServiceStatistics",xmlName:"StorageServiceStats",type:{name:"Composite",className:"BlobServiceStatistics",modelProperties:{geoReplication:{serializedName:"GeoReplication",xmlName:"GeoReplication",type:{name:"Composite",className:"GeoReplication"}}}}};const C={serializedName:"GeoReplication",type:{name:"Composite",className:"GeoReplication",modelProperties:{status:{serializedName:"Status",required:true,xmlName:"Status",type:{name:"Enum",allowedValues:["live","bootstrap","unavailable"]}},lastSyncOn:{serializedName:"LastSyncTime",required:true,xmlName:"LastSyncTime",type:{name:"DateTimeRfc1123"}}}}};const O={serializedName:"ListContainersSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListContainersSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,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:true,xmlName:"Containers",xmlIsWrapped:true,xmlElementName:"Container",type:{name:"Sequence",element:{type:{name:"Composite",className:"ContainerItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const R={serializedName:"ContainerItem",xmlName:"Container",type:{name:"Composite",className:"ContainerItem",modelProperties:{name:{serializedName:"Name",required:true,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"}}}}}}};const D={serializedName:"ContainerProperties",type:{name:"Composite",className:"ContainerProperties",modelProperties:{lastModified:{serializedName:"Last-Modified",required:true,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:true,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"}}}}};const A={serializedName:"KeyInfo",type:{name:"Composite",className:"KeyInfo",modelProperties:{startsOn:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"String"}},expiresOn:{serializedName:"Expiry",required:true,xmlName:"Expiry",type:{name:"String"}}}}};const I={serializedName:"UserDelegationKey",type:{name:"Composite",className:"UserDelegationKey",modelProperties:{signedObjectId:{serializedName:"SignedOid",required:true,xmlName:"SignedOid",type:{name:"String"}},signedTenantId:{serializedName:"SignedTid",required:true,xmlName:"SignedTid",type:{name:"String"}},signedStartsOn:{serializedName:"SignedStart",required:true,xmlName:"SignedStart",type:{name:"String"}},signedExpiresOn:{serializedName:"SignedExpiry",required:true,xmlName:"SignedExpiry",type:{name:"String"}},signedService:{serializedName:"SignedService",required:true,xmlName:"SignedService",type:{name:"String"}},signedVersion:{serializedName:"SignedVersion",required:true,xmlName:"SignedVersion",type:{name:"String"}},value:{serializedName:"Value",required:true,xmlName:"Value",type:{name:"String"}}}}};const B={serializedName:"FilterBlobSegment",xmlName:"EnumerationResults",type:{name:"Composite",className:"FilterBlobSegment",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},where:{serializedName:"Where",required:true,xmlName:"Where",type:{name:"String"}},blobs:{serializedName:"Blobs",required:true,xmlName:"Blobs",xmlIsWrapped:true,xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"FilterBlobItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const L={serializedName:"FilterBlobItem",xmlName:"Blob",type:{name:"Composite",className:"FilterBlobItem",modelProperties:{name:{serializedName:"Name",required:true,xmlName:"Name",type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",type:{name:"String"}},tags:{serializedName:"Tags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags"}}}}};const M={serializedName:"BlobTags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags",modelProperties:{blobTagSet:{serializedName:"BlobTagSet",required:true,xmlName:"TagSet",xmlIsWrapped:true,xmlElementName:"Tag",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobTag"}}}}}}};const k={serializedName:"BlobTag",xmlName:"Tag",type:{name:"Composite",className:"BlobTag",modelProperties:{key:{serializedName:"Key",required:true,xmlName:"Key",type:{name:"String"}},value:{serializedName:"Value",required:true,xmlName:"Value",type:{name:"String"}}}}};const z={serializedName:"SignedIdentifier",xmlName:"SignedIdentifier",type:{name:"Composite",className:"SignedIdentifier",modelProperties:{id:{serializedName:"Id",required:true,xmlName:"Id",type:{name:"String"}},accessPolicy:{serializedName:"AccessPolicy",xmlName:"AccessPolicy",type:{name:"Composite",className:"AccessPolicy"}}}}};const j={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"}}}}};const q={serializedName:"ListBlobsFlatSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsFlatSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",xmlIsAttribute:true,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"}}}}};const U={serializedName:"BlobFlatListSegment",xmlName:"Blobs",type:{name:"Composite",className:"BlobFlatListSegment",modelProperties:{blobItems:{serializedName:"BlobItems",required:true,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}};const H={serializedName:"BlobItemInternal",xmlName:"Blob",type:{name:"Composite",className:"BlobItemInternal",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}},deleted:{serializedName:"Deleted",required:true,xmlName:"Deleted",type:{name:"Boolean"}},snapshot:{serializedName:"Snapshot",required:true,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"}}}}};const V={serializedName:"BlobName",type:{name:"Composite",className:"BlobName",modelProperties:{encoded:{serializedName:"Encoded",xmlName:"Encoded",xmlIsAttribute:true,type:{name:"Boolean"}},content:{serializedName:"content",xmlName:"content",xmlIsMsText:true,type:{name:"String"}}}}};const G={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:true,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:true,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","Cold"]}},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"}}}}};const X={serializedName:"ListBlobsHierarchySegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsHierarchySegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",xmlIsAttribute:true,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"}}}}};const $={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:true,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}};const W={serializedName:"BlobPrefix",type:{name:"Composite",className:"BlobPrefix",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}}}}};const K={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"}}}}}}};const Q={serializedName:"BlockList",type:{name:"Composite",className:"BlockList",modelProperties:{committedBlocks:{serializedName:"CommittedBlocks",xmlName:"CommittedBlocks",xmlIsWrapped:true,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}},uncommittedBlocks:{serializedName:"UncommittedBlocks",xmlName:"UncommittedBlocks",xmlIsWrapped:true,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}}}}};const Y={serializedName:"Block",type:{name:"Composite",className:"Block",modelProperties:{name:{serializedName:"Name",required:true,xmlName:"Name",type:{name:"String"}},size:{serializedName:"Size",required:true,xmlName:"Size",type:{name:"Number"}}}}};const J={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"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const Z={serializedName:"PageRange",xmlName:"PageRange",type:{name:"Composite",className:"PageRange",modelProperties:{start:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:true,xmlName:"End",type:{name:"Number"}}}}};const ee={serializedName:"ClearRange",xmlName:"ClearRange",type:{name:"Composite",className:"ClearRange",modelProperties:{start:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:true,xmlName:"End",type:{name:"Number"}}}}};const te={serializedName:"QueryRequest",xmlName:"QueryRequest",type:{name:"Composite",className:"QueryRequest",modelProperties:{queryType:{serializedName:"QueryType",required:true,xmlName:"QueryType",type:{name:"String"}},expression:{serializedName:"Expression",required:true,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"}}}}};const ae={serializedName:"QuerySerialization",type:{name:"Composite",className:"QuerySerialization",modelProperties:{format:{serializedName:"Format",xmlName:"Format",type:{name:"Composite",className:"QueryFormat"}}}}};const re={serializedName:"QueryFormat",type:{name:"Composite",className:"QueryFormat",modelProperties:{type:{serializedName:"Type",required:true,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"}}}}};const ie={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"}}}}};const ne={serializedName:"JsonTextConfiguration",xmlName:"JsonTextConfiguration",type:{name:"Composite",className:"JsonTextConfiguration",modelProperties:{recordSeparator:{serializedName:"RecordSeparator",xmlName:"RecordSeparator",type:{name:"String"}}}}};const se={serializedName:"ArrowConfiguration",xmlName:"ArrowConfiguration",type:{name:"Composite",className:"ArrowConfiguration",modelProperties:{schema:{serializedName:"Schema",required:true,xmlName:"Schema",xmlIsWrapped:true,xmlElementName:"Field",type:{name:"Sequence",element:{type:{name:"Composite",className:"ArrowField"}}}}}}};const oe={serializedName:"ArrowField",xmlName:"Field",type:{name:"Composite",className:"ArrowField",modelProperties:{type:{serializedName:"Type",required:true,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"}}}}};const pe={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"}}}}};const le={serializedName:"Service_setPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceSetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const de={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"}}}}};const ce={serializedName:"Service_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const me={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"}}}}};const ue={serializedName:"Service_getStatisticsExceptionHeaders",type:{name:"Composite",className:"ServiceGetStatisticsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const fe={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"}}}}};const he={serializedName:"Service_listContainersSegmentExceptionHeaders",type:{name:"Composite",className:"ServiceListContainersSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ge={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"}}}}};const ye={serializedName:"Service_getUserDelegationKeyExceptionHeaders",type:{name:"Composite",className:"ServiceGetUserDelegationKeyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ve={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"}}}}};const be={serializedName:"Service_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ServiceGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const xe={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"}}}}};const we={serializedName:"Service_submitBatchExceptionHeaders",type:{name:"Composite",className:"ServiceSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Se={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"}}}}};const Ne={serializedName:"Service_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ServiceFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Te={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"}}}}};const Ee={serializedName:"Container_createExceptionHeaders",type:{name:"Composite",className:"ContainerCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const _e={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"}}}}};const Pe={serializedName:"Container_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ContainerGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ce={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"}}}}};const Oe={serializedName:"Container_deleteExceptionHeaders",type:{name:"Composite",className:"ContainerDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Re={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"}}}}};const De={serializedName:"Container_setMetadataExceptionHeaders",type:{name:"Composite",className:"ContainerSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ae={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"}}}}};const Ie={serializedName:"Container_getAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Be={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"}}}}};const Le={serializedName:"Container_setAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerSetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Me={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"}}}}};const ke={serializedName:"Container_restoreExceptionHeaders",type:{name:"Composite",className:"ContainerRestoreExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ze={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"}}}}};const je={serializedName:"Container_renameExceptionHeaders",type:{name:"Composite",className:"ContainerRenameExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const qe={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"}}}}};const Ue={serializedName:"Container_submitBatchExceptionHeaders",type:{name:"Composite",className:"ContainerSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Fe={serializedName:"Container_filterBlobsHeaders",type:{name:"Composite",className:"ContainerFilterBlobsHeaders",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"}}}}};const He={serializedName:"Container_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ContainerFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ve={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"}}}}};const Ge={serializedName:"Container_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Xe={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"}}}}};const $e={serializedName:"Container_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const We={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"}}}}};const Ke={serializedName:"Container_renewLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Qe={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"}}}}};const Ye={serializedName:"Container_breakLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Je={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"}}}}};const Ze={serializedName:"Container_changeLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const et={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"}}}}};const tt={serializedName:"Container_listBlobFlatSegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobFlatSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const rt={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"}}}}};const it={serializedName:"Container_listBlobHierarchySegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobHierarchySegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const nt={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"]}}}}};const st={serializedName:"Container_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ot={serializedName:"Blob_downloadHeaders",type:{name:"Composite",className:"BlobDownloadHeaders",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-"},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"}}}}};const pt={serializedName:"Blob_downloadExceptionHeaders",type:{name:"Composite",className:"BlobDownloadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const dt={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"}}}}};const ct={serializedName:"Blob_getPropertiesExceptionHeaders",type:{name:"Composite",className:"BlobGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const mt={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"}}}}};const ut={serializedName:"Blob_deleteExceptionHeaders",type:{name:"Composite",className:"BlobDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ft={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"}}}}};const ht={serializedName:"Blob_undeleteExceptionHeaders",type:{name:"Composite",className:"BlobUndeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const yt={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"}}}}};const vt={serializedName:"Blob_setExpiryExceptionHeaders",type:{name:"Composite",className:"BlobSetExpiryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const bt={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"}}}}};const xt={serializedName:"Blob_setHttpHeadersExceptionHeaders",type:{name:"Composite",className:"BlobSetHttpHeadersExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const wt={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"]}}}}};const St={serializedName:"Blob_setImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobSetImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Nt={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"}}}}};const Tt={serializedName:"Blob_deleteImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobDeleteImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Et={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"}}}}};const _t={serializedName:"Blob_setLegalHoldExceptionHeaders",type:{name:"Composite",className:"BlobSetLegalHoldExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Pt={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"}}}}};const Ct={serializedName:"Blob_setMetadataExceptionHeaders",type:{name:"Composite",className:"BlobSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ot={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"}}}}};const Rt={serializedName:"Blob_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"BlobAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Dt={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"}}}}};const At={serializedName:"Blob_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"BlobReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const It={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"}}}}};const Bt={serializedName:"Blob_renewLeaseExceptionHeaders",type:{name:"Composite",className:"BlobRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Lt={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"}}}}};const Mt={serializedName:"Blob_changeLeaseExceptionHeaders",type:{name:"Composite",className:"BlobChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const kt={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"}}}}};const zt={serializedName:"Blob_breakLeaseExceptionHeaders",type:{name:"Composite",className:"BlobBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const jt={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"}}}}};const qt={serializedName:"Blob_createSnapshotExceptionHeaders",type:{name:"Composite",className:"BlobCreateSnapshotExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ut={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"}}}}};const Ft={serializedName:"Blob_startCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobStartCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ht={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:true,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"}},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"}}}}};const Vt={serializedName:"Blob_copyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Gt={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"}}}}};const Xt={serializedName:"Blob_abortCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobAbortCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const $t={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"}}}}};const Wt={serializedName:"Blob_setTierExceptionHeaders",type:{name:"Composite",className:"BlobSetTierExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Kt={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"]}}}}};const Qt={serializedName:"Blob_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"BlobGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Yt={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"}}}}};const Jt={serializedName:"Blob_queryExceptionHeaders",type:{name:"Composite",className:"BlobQueryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Zt={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"}}}}};const ea={serializedName:"Blob_getTagsExceptionHeaders",type:{name:"Composite",className:"BlobGetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ta={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"}}}}};const aa={serializedName:"Blob_setTagsExceptionHeaders",type:{name:"Composite",className:"BlobSetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ra={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"}}}}};const ia={serializedName:"PageBlob_createExceptionHeaders",type:{name:"Composite",className:"PageBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const na={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"}}}}};const sa={serializedName:"PageBlob_uploadPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const oa={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"}}}}};const pa={serializedName:"PageBlob_clearPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobClearPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const la={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"}}}}};const da={serializedName:"PageBlob_uploadPagesFromURLExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ca={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"}}}}};const ma={serializedName:"PageBlob_getPageRangesExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ua={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"}}}}};const fa={serializedName:"PageBlob_getPageRangesDiffExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesDiffExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ha={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"}}}}};const ga={serializedName:"PageBlob_resizeExceptionHeaders",type:{name:"Composite",className:"PageBlobResizeExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ya={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"}}}}};const va={serializedName:"PageBlob_updateSequenceNumberExceptionHeaders",type:{name:"Composite",className:"PageBlobUpdateSequenceNumberExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ba={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"}}}}};const xa={serializedName:"PageBlob_copyIncrementalExceptionHeaders",type:{name:"Composite",className:"PageBlobCopyIncrementalExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const wa={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"}}}}};const Sa={serializedName:"AppendBlob_createExceptionHeaders",type:{name:"Composite",className:"AppendBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Na={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"}}}}};const Ta={serializedName:"AppendBlob_appendBlockExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ea={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"}}}}};const _a={serializedName:"AppendBlob_appendBlockFromUrlExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Pa={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"}}}}};const Ca={serializedName:"AppendBlob_sealExceptionHeaders",type:{name:"Composite",className:"AppendBlobSealExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Oa={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"}}}}};const Ra={serializedName:"BlockBlob_uploadExceptionHeaders",type:{name:"Composite",className:"BlockBlobUploadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Da={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"}}}}};const Aa={serializedName:"BlockBlob_putBlobFromUrlExceptionHeaders",type:{name:"Composite",className:"BlockBlobPutBlobFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ia={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"}}}}};const Ba={serializedName:"BlockBlob_stageBlockExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const La={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"}}}}};const Ma={serializedName:"BlockBlob_stageBlockFromURLExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ka={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"}}}}};const za={serializedName:"BlockBlob_commitBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobCommitBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ja={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"}}}}};const qa={serializedName:"BlockBlob_getBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobGetBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};var Ua=Object.freeze({__proto__:null,BlobServiceProperties:x,Logging:w,RetentionPolicy:S,Metrics:N,CorsRule:T,StaticWebsite:E,StorageError:_,BlobServiceStatistics:P,GeoReplication:C,ListContainersSegmentResponse:O,ContainerItem:R,ContainerProperties:D,KeyInfo:A,UserDelegationKey:I,FilterBlobSegment:B,FilterBlobItem:L,BlobTags:M,BlobTag:k,SignedIdentifier:z,AccessPolicy:j,ListBlobsFlatSegmentResponse:q,BlobFlatListSegment:U,BlobItemInternal:H,BlobName:V,BlobPropertiesInternal:G,ListBlobsHierarchySegmentResponse:X,BlobHierarchyListSegment:$,BlobPrefix:W,BlockLookupList:K,BlockList:Q,Block:Y,PageList:J,PageRange:Z,ClearRange:ee,QueryRequest:te,QuerySerialization:ae,QueryFormat:re,DelimitedTextConfiguration:ie,JsonTextConfiguration:ne,ArrowConfiguration:se,ArrowField:oe,ServiceSetPropertiesHeaders:pe,ServiceSetPropertiesExceptionHeaders:le,ServiceGetPropertiesHeaders:de,ServiceGetPropertiesExceptionHeaders:ce,ServiceGetStatisticsHeaders:me,ServiceGetStatisticsExceptionHeaders:ue,ServiceListContainersSegmentHeaders:fe,ServiceListContainersSegmentExceptionHeaders:he,ServiceGetUserDelegationKeyHeaders:ge,ServiceGetUserDelegationKeyExceptionHeaders:ye,ServiceGetAccountInfoHeaders:ve,ServiceGetAccountInfoExceptionHeaders:be,ServiceSubmitBatchHeaders:xe,ServiceSubmitBatchExceptionHeaders:we,ServiceFilterBlobsHeaders:Se,ServiceFilterBlobsExceptionHeaders:Ne,ContainerCreateHeaders:Te,ContainerCreateExceptionHeaders:Ee,ContainerGetPropertiesHeaders:_e,ContainerGetPropertiesExceptionHeaders:Pe,ContainerDeleteHeaders:Ce,ContainerDeleteExceptionHeaders:Oe,ContainerSetMetadataHeaders:Re,ContainerSetMetadataExceptionHeaders:De,ContainerGetAccessPolicyHeaders:Ae,ContainerGetAccessPolicyExceptionHeaders:Ie,ContainerSetAccessPolicyHeaders:Be,ContainerSetAccessPolicyExceptionHeaders:Le,ContainerRestoreHeaders:Me,ContainerRestoreExceptionHeaders:ke,ContainerRenameHeaders:ze,ContainerRenameExceptionHeaders:je,ContainerSubmitBatchHeaders:qe,ContainerSubmitBatchExceptionHeaders:Ue,ContainerFilterBlobsHeaders:Fe,ContainerFilterBlobsExceptionHeaders:He,ContainerAcquireLeaseHeaders:Ve,ContainerAcquireLeaseExceptionHeaders:Ge,ContainerReleaseLeaseHeaders:Xe,ContainerReleaseLeaseExceptionHeaders:$e,ContainerRenewLeaseHeaders:We,ContainerRenewLeaseExceptionHeaders:Ke,ContainerBreakLeaseHeaders:Qe,ContainerBreakLeaseExceptionHeaders:Ye,ContainerChangeLeaseHeaders:Je,ContainerChangeLeaseExceptionHeaders:Ze,ContainerListBlobFlatSegmentHeaders:et,ContainerListBlobFlatSegmentExceptionHeaders:tt,ContainerListBlobHierarchySegmentHeaders:rt,ContainerListBlobHierarchySegmentExceptionHeaders:it,ContainerGetAccountInfoHeaders:nt,ContainerGetAccountInfoExceptionHeaders:st,BlobDownloadHeaders:ot,BlobDownloadExceptionHeaders:pt,BlobGetPropertiesHeaders:dt,BlobGetPropertiesExceptionHeaders:ct,BlobDeleteHeaders:mt,BlobDeleteExceptionHeaders:ut,BlobUndeleteHeaders:ft,BlobUndeleteExceptionHeaders:ht,BlobSetExpiryHeaders:yt,BlobSetExpiryExceptionHeaders:vt,BlobSetHttpHeadersHeaders:bt,BlobSetHttpHeadersExceptionHeaders:xt,BlobSetImmutabilityPolicyHeaders:wt,BlobSetImmutabilityPolicyExceptionHeaders:St,BlobDeleteImmutabilityPolicyHeaders:Nt,BlobDeleteImmutabilityPolicyExceptionHeaders:Tt,BlobSetLegalHoldHeaders:Et,BlobSetLegalHoldExceptionHeaders:_t,BlobSetMetadataHeaders:Pt,BlobSetMetadataExceptionHeaders:Ct,BlobAcquireLeaseHeaders:Ot,BlobAcquireLeaseExceptionHeaders:Rt,BlobReleaseLeaseHeaders:Dt,BlobReleaseLeaseExceptionHeaders:At,BlobRenewLeaseHeaders:It,BlobRenewLeaseExceptionHeaders:Bt,BlobChangeLeaseHeaders:Lt,BlobChangeLeaseExceptionHeaders:Mt,BlobBreakLeaseHeaders:kt,BlobBreakLeaseExceptionHeaders:zt,BlobCreateSnapshotHeaders:jt,BlobCreateSnapshotExceptionHeaders:qt,BlobStartCopyFromURLHeaders:Ut,BlobStartCopyFromURLExceptionHeaders:Ft,BlobCopyFromURLHeaders:Ht,BlobCopyFromURLExceptionHeaders:Vt,BlobAbortCopyFromURLHeaders:Gt,BlobAbortCopyFromURLExceptionHeaders:Xt,BlobSetTierHeaders:$t,BlobSetTierExceptionHeaders:Wt,BlobGetAccountInfoHeaders:Kt,BlobGetAccountInfoExceptionHeaders:Qt,BlobQueryHeaders:Yt,BlobQueryExceptionHeaders:Jt,BlobGetTagsHeaders:Zt,BlobGetTagsExceptionHeaders:ea,BlobSetTagsHeaders:ta,BlobSetTagsExceptionHeaders:aa,PageBlobCreateHeaders:ra,PageBlobCreateExceptionHeaders:ia,PageBlobUploadPagesHeaders:na,PageBlobUploadPagesExceptionHeaders:sa,PageBlobClearPagesHeaders:oa,PageBlobClearPagesExceptionHeaders:pa,PageBlobUploadPagesFromURLHeaders:la,PageBlobUploadPagesFromURLExceptionHeaders:da,PageBlobGetPageRangesHeaders:ca,PageBlobGetPageRangesExceptionHeaders:ma,PageBlobGetPageRangesDiffHeaders:ua,PageBlobGetPageRangesDiffExceptionHeaders:fa,PageBlobResizeHeaders:ha,PageBlobResizeExceptionHeaders:ga,PageBlobUpdateSequenceNumberHeaders:ya,PageBlobUpdateSequenceNumberExceptionHeaders:va,PageBlobCopyIncrementalHeaders:ba,PageBlobCopyIncrementalExceptionHeaders:xa,AppendBlobCreateHeaders:wa,AppendBlobCreateExceptionHeaders:Sa,AppendBlobAppendBlockHeaders:Na,AppendBlobAppendBlockExceptionHeaders:Ta,AppendBlobAppendBlockFromUrlHeaders:Ea,AppendBlobAppendBlockFromUrlExceptionHeaders:_a,AppendBlobSealHeaders:Pa,AppendBlobSealExceptionHeaders:Ca,BlockBlobUploadHeaders:Oa,BlockBlobUploadExceptionHeaders:Ra,BlockBlobPutBlobFromUrlHeaders:Da,BlockBlobPutBlobFromUrlExceptionHeaders:Aa,BlockBlobStageBlockHeaders:Ia,BlockBlobStageBlockExceptionHeaders:Ba,BlockBlobStageBlockFromURLHeaders:La,BlockBlobStageBlockFromURLExceptionHeaders:Ma,BlockBlobCommitBlockListHeaders:ka,BlockBlobCommitBlockListExceptionHeaders:za,BlockBlobGetBlockListHeaders:ja,BlockBlobGetBlockListExceptionHeaders:qa});const Fa={parameterPath:["options","contentType"],mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Content-Type",type:{name:"String"}}};const Ha={parameterPath:"blobServiceProperties",mapper:x};const Va={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Ga={parameterPath:"url",mapper:{serializedName:"url",required:true,xmlName:"url",type:{name:"String"}},skipEncoding:true};const Xa={parameterPath:"restype",mapper:{defaultValue:"service",isConstant:true,serializedName:"restype",type:{name:"String"}}};const $a={parameterPath:"comp",mapper:{defaultValue:"properties",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Wa={parameterPath:["options","timeoutInSeconds"],mapper:{constraints:{InclusiveMinimum:0},serializedName:"timeout",xmlName:"timeout",type:{name:"Number"}}};const Ka={parameterPath:"version",mapper:{defaultValue:"2023-01-03",isConstant:true,serializedName:"x-ms-version",type:{name:"String"}}};const Qa={parameterPath:["options","requestId"],mapper:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}}};const Ya={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Ja={parameterPath:"comp",mapper:{defaultValue:"stats",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Za={parameterPath:"comp",mapper:{defaultValue:"list",isConstant:true,serializedName:"comp",type:{name:"String"}}};const er={parameterPath:["options","prefix"],mapper:{serializedName:"prefix",xmlName:"prefix",type:{name:"String"}}};const tr={parameterPath:["options","marker"],mapper:{serializedName:"marker",xmlName:"marker",type:{name:"String"}}};const ar={parameterPath:["options","maxPageSize"],mapper:{constraints:{InclusiveMinimum:1},serializedName:"maxresults",xmlName:"maxresults",type:{name:"Number"}}};const rr={parameterPath:["options","include"],mapper:{serializedName:"include",xmlName:"include",xmlElementName:"ListContainersIncludeType",type:{name:"Sequence",element:{type:{name:"Enum",allowedValues:["metadata","deleted","system"]}}}},collectionFormat:r.QueryCollectionFormat.Csv};const ir={parameterPath:"keyInfo",mapper:A};const nr={parameterPath:"comp",mapper:{defaultValue:"userdelegationkey",isConstant:true,serializedName:"comp",type:{name:"String"}}};const sr={parameterPath:"restype",mapper:{defaultValue:"account",isConstant:true,serializedName:"restype",type:{name:"String"}}};const or={parameterPath:"body",mapper:{serializedName:"body",required:true,xmlName:"body",type:{name:"Stream"}}};const pr={parameterPath:"comp",mapper:{defaultValue:"batch",isConstant:true,serializedName:"comp",type:{name:"String"}}};const lr={parameterPath:"contentLength",mapper:{serializedName:"Content-Length",required:true,xmlName:"Content-Length",type:{name:"Number"}}};const dr={parameterPath:"multipartContentType",mapper:{serializedName:"Content-Type",required:true,xmlName:"Content-Type",type:{name:"String"}}};const cr={parameterPath:"comp",mapper:{defaultValue:"blobs",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mr={parameterPath:["options","where"],mapper:{serializedName:"where",xmlName:"where",type:{name:"String"}}};const ur={parameterPath:"restype",mapper:{defaultValue:"container",isConstant:true,serializedName:"restype",type:{name:"String"}}};const fr={parameterPath:["options","metadata"],mapper:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-meta-"}};const hr={parameterPath:["options","access"],mapper:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}}};const gr={parameterPath:["options","containerEncryptionScope","defaultEncryptionScope"],mapper:{serializedName:"x-ms-default-encryption-scope",xmlName:"x-ms-default-encryption-scope",type:{name:"String"}}};const yr={parameterPath:["options","containerEncryptionScope","preventEncryptionScopeOverride"],mapper:{serializedName:"x-ms-deny-encryption-scope-override",xmlName:"x-ms-deny-encryption-scope-override",type:{name:"Boolean"}}};const vr={parameterPath:["options","leaseAccessConditions","leaseId"],mapper:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}}};const br={parameterPath:["options","modifiedAccessConditions","ifModifiedSince"],mapper:{serializedName:"If-Modified-Since",xmlName:"If-Modified-Since",type:{name:"DateTimeRfc1123"}}};const xr={parameterPath:["options","modifiedAccessConditions","ifUnmodifiedSince"],mapper:{serializedName:"If-Unmodified-Since",xmlName:"If-Unmodified-Since",type:{name:"DateTimeRfc1123"}}};const wr={parameterPath:"comp",mapper:{defaultValue:"metadata",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Sr={parameterPath:"comp",mapper:{defaultValue:"acl",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Nr={parameterPath:["options","containerAcl"],mapper:{serializedName:"containerAcl",xmlName:"SignedIdentifiers",xmlIsWrapped:true,xmlElementName:"SignedIdentifier",type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}}}};const Tr={parameterPath:"comp",mapper:{defaultValue:"undelete",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Er={parameterPath:["options","deletedContainerName"],mapper:{serializedName:"x-ms-deleted-container-name",xmlName:"x-ms-deleted-container-name",type:{name:"String"}}};const _r={parameterPath:["options","deletedContainerVersion"],mapper:{serializedName:"x-ms-deleted-container-version",xmlName:"x-ms-deleted-container-version",type:{name:"String"}}};const Pr={parameterPath:"comp",mapper:{defaultValue:"rename",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Cr={parameterPath:"sourceContainerName",mapper:{serializedName:"x-ms-source-container-name",required:true,xmlName:"x-ms-source-container-name",type:{name:"String"}}};const Or={parameterPath:["options","sourceLeaseId"],mapper:{serializedName:"x-ms-source-lease-id",xmlName:"x-ms-source-lease-id",type:{name:"String"}}};const Rr={parameterPath:"comp",mapper:{defaultValue:"lease",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Dr={parameterPath:"action",mapper:{defaultValue:"acquire",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const Ar={parameterPath:["options","duration"],mapper:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Number"}}};const Ir={parameterPath:["options","proposedLeaseId"],mapper:{serializedName:"x-ms-proposed-lease-id",xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}};const Br={parameterPath:"action",mapper:{defaultValue:"release",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const Lr={parameterPath:"leaseId",mapper:{serializedName:"x-ms-lease-id",required:true,xmlName:"x-ms-lease-id",type:{name:"String"}}};const Mr={parameterPath:"action",mapper:{defaultValue:"renew",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const kr={parameterPath:"action",mapper:{defaultValue:"break",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const zr={parameterPath:["options","breakPeriod"],mapper:{serializedName:"x-ms-lease-break-period",xmlName:"x-ms-lease-break-period",type:{name:"Number"}}};const jr={parameterPath:"action",mapper:{defaultValue:"change",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const qr={parameterPath:"proposedLeaseId",mapper:{serializedName:"x-ms-proposed-lease-id",required:true,xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}};const Ur={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:r.QueryCollectionFormat.Csv};const Fr={parameterPath:"delimiter",mapper:{serializedName:"delimiter",required:true,xmlName:"delimiter",type:{name:"String"}}};const Hr={parameterPath:["options","snapshot"],mapper:{serializedName:"snapshot",xmlName:"snapshot",type:{name:"String"}}};const Vr={parameterPath:["options","versionId"],mapper:{serializedName:"versionid",xmlName:"versionid",type:{name:"String"}}};const Gr={parameterPath:["options","range"],mapper:{serializedName:"x-ms-range",xmlName:"x-ms-range",type:{name:"String"}}};const Xr={parameterPath:["options","rangeGetContentMD5"],mapper:{serializedName:"x-ms-range-get-content-md5",xmlName:"x-ms-range-get-content-md5",type:{name:"Boolean"}}};const $r={parameterPath:["options","rangeGetContentCRC64"],mapper:{serializedName:"x-ms-range-get-content-crc64",xmlName:"x-ms-range-get-content-crc64",type:{name:"Boolean"}}};const Wr={parameterPath:["options","cpkInfo","encryptionKey"],mapper:{serializedName:"x-ms-encryption-key",xmlName:"x-ms-encryption-key",type:{name:"String"}}};const Kr={parameterPath:["options","cpkInfo","encryptionKeySha256"],mapper:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}}};const Qr={parameterPath:["options","cpkInfo","encryptionAlgorithm"],mapper:{serializedName:"x-ms-encryption-algorithm",xmlName:"x-ms-encryption-algorithm",type:{name:"String"}}};const Yr={parameterPath:["options","modifiedAccessConditions","ifMatch"],mapper:{serializedName:"If-Match",xmlName:"If-Match",type:{name:"String"}}};const Jr={parameterPath:["options","modifiedAccessConditions","ifNoneMatch"],mapper:{serializedName:"If-None-Match",xmlName:"If-None-Match",type:{name:"String"}}};const Zr={parameterPath:["options","modifiedAccessConditions","ifTags"],mapper:{serializedName:"x-ms-if-tags",xmlName:"x-ms-if-tags",type:{name:"String"}}};const ei={parameterPath:["options","deleteSnapshots"],mapper:{serializedName:"x-ms-delete-snapshots",xmlName:"x-ms-delete-snapshots",type:{name:"Enum",allowedValues:["include","only"]}}};const ti={parameterPath:["options","blobDeleteType"],mapper:{serializedName:"deletetype",xmlName:"deletetype",type:{name:"String"}}};const ai={parameterPath:"comp",mapper:{defaultValue:"expiry",isConstant:true,serializedName:"comp",type:{name:"String"}}};const ri={parameterPath:"expiryOptions",mapper:{serializedName:"x-ms-expiry-option",required:true,xmlName:"x-ms-expiry-option",type:{name:"String"}}};const ii={parameterPath:["options","expiresOn"],mapper:{serializedName:"x-ms-expiry-time",xmlName:"x-ms-expiry-time",type:{name:"String"}}};const ni={parameterPath:["options","blobHttpHeaders","blobCacheControl"],mapper:{serializedName:"x-ms-blob-cache-control",xmlName:"x-ms-blob-cache-control",type:{name:"String"}}};const si={parameterPath:["options","blobHttpHeaders","blobContentType"],mapper:{serializedName:"x-ms-blob-content-type",xmlName:"x-ms-blob-content-type",type:{name:"String"}}};const oi={parameterPath:["options","blobHttpHeaders","blobContentMD5"],mapper:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}}};const pi={parameterPath:["options","blobHttpHeaders","blobContentEncoding"],mapper:{serializedName:"x-ms-blob-content-encoding",xmlName:"x-ms-blob-content-encoding",type:{name:"String"}}};const li={parameterPath:["options","blobHttpHeaders","blobContentLanguage"],mapper:{serializedName:"x-ms-blob-content-language",xmlName:"x-ms-blob-content-language",type:{name:"String"}}};const di={parameterPath:["options","blobHttpHeaders","blobContentDisposition"],mapper:{serializedName:"x-ms-blob-content-disposition",xmlName:"x-ms-blob-content-disposition",type:{name:"String"}}};const ci={parameterPath:"comp",mapper:{defaultValue:"immutabilityPolicies",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mi={parameterPath:["options","immutabilityPolicyExpiry"],mapper:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}}};const ui={parameterPath:["options","immutabilityPolicyMode"],mapper:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}}};const fi={parameterPath:"comp",mapper:{defaultValue:"legalhold",isConstant:true,serializedName:"comp",type:{name:"String"}}};const hi={parameterPath:"legalHold",mapper:{serializedName:"x-ms-legal-hold",required:true,xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}};const gi={parameterPath:["options","encryptionScope"],mapper:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}}};const yi={parameterPath:"comp",mapper:{defaultValue:"snapshot",isConstant:true,serializedName:"comp",type:{name:"String"}}};const vi={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","Cold"]}}};const bi={parameterPath:["options","rehydratePriority"],mapper:{serializedName:"x-ms-rehydrate-priority",xmlName:"x-ms-rehydrate-priority",type:{name:"Enum",allowedValues:["High","Standard"]}}};const xi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfModifiedSince"],mapper:{serializedName:"x-ms-source-if-modified-since",xmlName:"x-ms-source-if-modified-since",type:{name:"DateTimeRfc1123"}}};const wi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfUnmodifiedSince"],mapper:{serializedName:"x-ms-source-if-unmodified-since",xmlName:"x-ms-source-if-unmodified-since",type:{name:"DateTimeRfc1123"}}};const Si={parameterPath:["options","sourceModifiedAccessConditions","sourceIfMatch"],mapper:{serializedName:"x-ms-source-if-match",xmlName:"x-ms-source-if-match",type:{name:"String"}}};const Ni={parameterPath:["options","sourceModifiedAccessConditions","sourceIfNoneMatch"],mapper:{serializedName:"x-ms-source-if-none-match",xmlName:"x-ms-source-if-none-match",type:{name:"String"}}};const Ti={parameterPath:["options","sourceModifiedAccessConditions","sourceIfTags"],mapper:{serializedName:"x-ms-source-if-tags",xmlName:"x-ms-source-if-tags",type:{name:"String"}}};const Ei={parameterPath:"copySource",mapper:{serializedName:"x-ms-copy-source",required:true,xmlName:"x-ms-copy-source",type:{name:"String"}}};const _i={parameterPath:["options","blobTagsString"],mapper:{serializedName:"x-ms-tags",xmlName:"x-ms-tags",type:{name:"String"}}};const Pi={parameterPath:["options","sealBlob"],mapper:{serializedName:"x-ms-seal-blob",xmlName:"x-ms-seal-blob",type:{name:"Boolean"}}};const Ci={parameterPath:["options","legalHold"],mapper:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}};const Oi={parameterPath:"xMsRequiresSync",mapper:{defaultValue:"true",isConstant:true,serializedName:"x-ms-requires-sync",type:{name:"String"}}};const Ri={parameterPath:["options","sourceContentMD5"],mapper:{serializedName:"x-ms-source-content-md5",xmlName:"x-ms-source-content-md5",type:{name:"ByteArray"}}};const Di={parameterPath:["options","copySourceAuthorization"],mapper:{serializedName:"x-ms-copy-source-authorization",xmlName:"x-ms-copy-source-authorization",type:{name:"String"}}};const Ai={parameterPath:["options","copySourceTags"],mapper:{serializedName:"x-ms-copy-source-tag-option",xmlName:"x-ms-copy-source-tag-option",type:{name:"Enum",allowedValues:["REPLACE","COPY"]}}};const Ii={parameterPath:"comp",mapper:{defaultValue:"copy",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Bi={parameterPath:"copyActionAbortConstant",mapper:{defaultValue:"abort",isConstant:true,serializedName:"x-ms-copy-action",type:{name:"String"}}};const Li={parameterPath:"copyId",mapper:{serializedName:"copyid",required:true,xmlName:"copyid",type:{name:"String"}}};const Mi={parameterPath:"comp",mapper:{defaultValue:"tier",isConstant:true,serializedName:"comp",type:{name:"String"}}};const ki={parameterPath:"tier",mapper:{serializedName:"x-ms-access-tier",required:true,xmlName:"x-ms-access-tier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive","Cold"]}}};const zi={parameterPath:["options","queryRequest"],mapper:te};const ji={parameterPath:"comp",mapper:{defaultValue:"query",isConstant:true,serializedName:"comp",type:{name:"String"}}};const qi={parameterPath:"comp",mapper:{defaultValue:"tags",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Ui={parameterPath:["options","tags"],mapper:M};const Fi={parameterPath:["options","transactionalContentMD5"],mapper:{serializedName:"Content-MD5",xmlName:"Content-MD5",type:{name:"ByteArray"}}};const Hi={parameterPath:["options","transactionalContentCrc64"],mapper:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}};const Vi={parameterPath:"blobType",mapper:{defaultValue:"PageBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const Gi={parameterPath:"blobContentLength",mapper:{serializedName:"x-ms-blob-content-length",required:true,xmlName:"x-ms-blob-content-length",type:{name:"Number"}}};const Xi={parameterPath:["options","blobSequenceNumber"],mapper:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}}};const $i={parameterPath:["options","contentType"],mapper:{defaultValue:"application/octet-stream",isConstant:true,serializedName:"Content-Type",type:{name:"String"}}};const Wi={parameterPath:"body",mapper:{serializedName:"body",required:true,xmlName:"body",type:{name:"Stream"}}};const Ki={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Qi={parameterPath:"comp",mapper:{defaultValue:"page",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Yi={parameterPath:"pageWrite",mapper:{defaultValue:"update",isConstant:true,serializedName:"x-ms-page-write",type:{name:"String"}}};const Ji={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThanOrEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-le",xmlName:"x-ms-if-sequence-number-le",type:{name:"Number"}}};const Zi={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThan"],mapper:{serializedName:"x-ms-if-sequence-number-lt",xmlName:"x-ms-if-sequence-number-lt",type:{name:"Number"}}};const en={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-eq",xmlName:"x-ms-if-sequence-number-eq",type:{name:"Number"}}};const tn={parameterPath:"pageWrite",mapper:{defaultValue:"clear",isConstant:true,serializedName:"x-ms-page-write",type:{name:"String"}}};const an={parameterPath:"sourceUrl",mapper:{serializedName:"x-ms-copy-source",required:true,xmlName:"x-ms-copy-source",type:{name:"String"}}};const rn={parameterPath:"sourceRange",mapper:{serializedName:"x-ms-source-range",required:true,xmlName:"x-ms-source-range",type:{name:"String"}}};const nn={parameterPath:["options","sourceContentCrc64"],mapper:{serializedName:"x-ms-source-content-crc64",xmlName:"x-ms-source-content-crc64",type:{name:"ByteArray"}}};const sn={parameterPath:"range",mapper:{serializedName:"x-ms-range",required:true,xmlName:"x-ms-range",type:{name:"String"}}};const on={parameterPath:"comp",mapper:{defaultValue:"pagelist",isConstant:true,serializedName:"comp",type:{name:"String"}}};const pn={parameterPath:["options","prevsnapshot"],mapper:{serializedName:"prevsnapshot",xmlName:"prevsnapshot",type:{name:"String"}}};const ln={parameterPath:["options","prevSnapshotUrl"],mapper:{serializedName:"x-ms-previous-snapshot-url",xmlName:"x-ms-previous-snapshot-url",type:{name:"String"}}};const dn={parameterPath:"sequenceNumberAction",mapper:{serializedName:"x-ms-sequence-number-action",required:true,xmlName:"x-ms-sequence-number-action",type:{name:"Enum",allowedValues:["max","update","increment"]}}};const cn={parameterPath:"comp",mapper:{defaultValue:"incrementalcopy",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mn={parameterPath:"blobType",mapper:{defaultValue:"AppendBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const un={parameterPath:"comp",mapper:{defaultValue:"appendblock",isConstant:true,serializedName:"comp",type:{name:"String"}}};const fn={parameterPath:["options","appendPositionAccessConditions","maxSize"],mapper:{serializedName:"x-ms-blob-condition-maxsize",xmlName:"x-ms-blob-condition-maxsize",type:{name:"Number"}}};const hn={parameterPath:["options","appendPositionAccessConditions","appendPosition"],mapper:{serializedName:"x-ms-blob-condition-appendpos",xmlName:"x-ms-blob-condition-appendpos",type:{name:"Number"}}};const gn={parameterPath:["options","sourceRange"],mapper:{serializedName:"x-ms-source-range",xmlName:"x-ms-source-range",type:{name:"String"}}};const yn={parameterPath:"comp",mapper:{defaultValue:"seal",isConstant:true,serializedName:"comp",type:{name:"String"}}};const vn={parameterPath:"blobType",mapper:{defaultValue:"BlockBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const bn={parameterPath:["options","copySourceBlobProperties"],mapper:{serializedName:"x-ms-copy-source-blob-properties",xmlName:"x-ms-copy-source-blob-properties",type:{name:"Boolean"}}};const xn={parameterPath:"comp",mapper:{defaultValue:"block",isConstant:true,serializedName:"comp",type:{name:"String"}}};const wn={parameterPath:"blockId",mapper:{serializedName:"blockid",required:true,xmlName:"blockid",type:{name:"String"}}};const Sn={parameterPath:"blocks",mapper:K};const Nn={parameterPath:"comp",mapper:{defaultValue:"blocklist",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Tn={parameterPath:"listType",mapper:{defaultValue:"committed",serializedName:"blocklisttype",required:true,xmlName:"blocklisttype",type:{name:"Enum",allowedValues:["committed","uncommitted","all"]}}};class Service{constructor(e){this.client=e}setProperties(e,t){const a={blobServiceProperties:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,_n)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Pn)}getStatistics(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Cn)}listContainersSegment(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,On)}getUserDelegationKey(e,t){const a={keyInfo:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Rn)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Dn)}submitBatch(e,t,a,r){const i={contentLength:e,multipartContentType:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,An)}filterBlobs(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,In)}}const En=new g.Serializer(Ua,true);const _n={path:"/",httpMethod:"PUT",responses:{202:{headersMapper:pe},default:{bodyMapper:_,headersMapper:le}},requestBody:Ha,queryParameters:[Xa,$a,Wa],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const Pn={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:x,headersMapper:de},default:{bodyMapper:_,headersMapper:ce}},queryParameters:[Xa,$a,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const Cn={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:P,headersMapper:me},default:{bodyMapper:_,headersMapper:ue}},queryParameters:[Xa,Wa,Ja],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const On={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:O,headersMapper:fe},default:{bodyMapper:_,headersMapper:he}},queryParameters:[Wa,Za,er,tr,ar,rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const Rn={path:"/",httpMethod:"POST",responses:{200:{bodyMapper:I,headersMapper:ge},default:{bodyMapper:_,headersMapper:ye}},requestBody:ir,queryParameters:[Xa,Wa,nr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const Dn={path:"/",httpMethod:"GET",responses:{200:{headersMapper:ve},default:{bodyMapper:_,headersMapper:be}},queryParameters:[$a,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:En};const An={path:"/",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:xe},default:{bodyMapper:_,headersMapper:we}},requestBody:or,queryParameters:[Wa,pr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,lr,dr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const In={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:B,headersMapper:Se},default:{bodyMapper:_,headersMapper:Ne}},queryParameters:[Wa,tr,ar,cr,mr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};class Container{constructor(e){this.client=e}create(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ln)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Mn)}delete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,kn)}setMetadata(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,zn)}getAccessPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,jn)}setAccessPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,qn)}restore(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Un)}rename(e,t){const a={sourceContainerName:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Fn)}submitBatch(e,t,a,r){const i={contentLength:e,multipartContentType:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Hn)}filterBlobs(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Vn)}acquireLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Gn)}releaseLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Xn)}renewLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,$n)}breakLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Wn)}changeLease(e,t,a){const r={leaseId:e,proposedLeaseId:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Kn)}listBlobFlatSegment(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Qn)}listBlobHierarchySegment(e,t){const a={delimiter:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Yn)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Jn)}}const Bn=new g.Serializer(Ua,true);const Ln={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Te},default:{bodyMapper:_,headersMapper:Ee}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,hr,gr,yr],isXML:true,serializer:Bn};const Mn={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:_e},default:{bodyMapper:_,headersMapper:Pe}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr],isXML:true,serializer:Bn};const kn={path:"/{containerName}",httpMethod:"DELETE",responses:{202:{headersMapper:Ce},default:{bodyMapper:_,headersMapper:Oe}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr],isXML:true,serializer:Bn};const zn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Re},default:{bodyMapper:_,headersMapper:De}},queryParameters:[Wa,ur,wr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br],isXML:true,serializer:Bn};const jn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}},serializedName:"SignedIdentifiers",xmlName:"SignedIdentifiers",xmlIsWrapped:true,xmlElementName:"SignedIdentifier"},headersMapper:Ae},default:{bodyMapper:_,headersMapper:Ie}},queryParameters:[Wa,ur,Sr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr],isXML:true,serializer:Bn};const qn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Be},default:{bodyMapper:_,headersMapper:Le}},requestBody:Nr,queryParameters:[Wa,ur,Sr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,hr,vr,br,xr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Bn};const Un={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Me},default:{bodyMapper:_,headersMapper:ke}},queryParameters:[Wa,ur,Tr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,Er,_r],isXML:true,serializer:Bn};const Fn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:ze},default:{bodyMapper:_,headersMapper:je}},queryParameters:[Wa,ur,Pr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,Cr,Or],isXML:true,serializer:Bn};const Hn={path:"/{containerName}",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:qe},default:{bodyMapper:_,headersMapper:Ue}},requestBody:or,queryParameters:[Wa,pr,ur],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,lr,dr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Bn};const Vn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:B,headersMapper:Fe},default:{bodyMapper:_,headersMapper:He}},queryParameters:[Wa,tr,ar,cr,mr,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Bn};const Gn={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Ve},default:{bodyMapper:_,headersMapper:Ge}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Dr,Ar,Ir],isXML:true,serializer:Bn};const Xn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Xe},default:{bodyMapper:_,headersMapper:$e}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Br,Lr],isXML:true,serializer:Bn};const $n={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:We},default:{bodyMapper:_,headersMapper:Ke}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,Mr],isXML:true,serializer:Bn};const Wn={path:"/{containerName}",httpMethod:"PUT",responses:{202:{headersMapper:Qe},default:{bodyMapper:_,headersMapper:Ye}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,kr,zr],isXML:true,serializer:Bn};const Kn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Je},default:{bodyMapper:_,headersMapper:Ze}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,jr,qr],isXML:true,serializer:Bn};const Qn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:q,headersMapper:et},default:{bodyMapper:_,headersMapper:tt}},queryParameters:[Wa,Za,er,tr,ar,ur,Ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Bn};const Yn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:X,headersMapper:rt},default:{bodyMapper:_,headersMapper:it}},queryParameters:[Wa,Za,er,tr,ar,ur,Ur,Fr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Bn};const Jn={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:nt},default:{bodyMapper:_,headersMapper:st}},queryParameters:[$a,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:Bn};class Blob$1{constructor(e){this.client=e}download(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,es)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ts)}delete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,as)}undelete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,rs)}setExpiry(e,t){const a={expiryOptions:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,is)}setHttpHeaders(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ns)}setImmutabilityPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ss)}deleteImmutabilityPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,os)}setLegalHold(e,t){const a={legalHold:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ps)}setMetadata(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ls)}acquireLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ds)}releaseLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,cs)}renewLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ms)}changeLease(e,t,a){const r={leaseId:e,proposedLeaseId:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,us)}breakLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,fs)}createSnapshot(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,hs)}startCopyFromURL(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,gs)}copyFromURL(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ys)}abortCopyFromURL(e,t){const a={copyId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,vs)}setTier(e,t){const a={tier:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,bs)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,xs)}query(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ws)}getTags(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ss)}setTags(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ns)}}const Zn=new g.Serializer(Ua,true);const es={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ot},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ot},default:{bodyMapper:_,headersMapper:pt}},queryParameters:[Wa,Hr,Vr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Xr,$r,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const ts={path:"/{containerName}/{blob}",httpMethod:"HEAD",responses:{200:{headersMapper:dt},default:{bodyMapper:_,headersMapper:ct}},queryParameters:[Wa,Hr,Vr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const as={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{202:{headersMapper:mt},default:{bodyMapper:_,headersMapper:ut}},queryParameters:[Wa,Hr,Vr,ti],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,ei],isXML:true,serializer:Zn};const rs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ft},default:{bodyMapper:_,headersMapper:ht}},queryParameters:[Wa,Tr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Zn};const is={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:yt},default:{bodyMapper:_,headersMapper:vt}},queryParameters:[Wa,ai],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,ri,ii],isXML:true,serializer:Zn};const ns={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:bt},default:{bodyMapper:_,headersMapper:xt}},queryParameters:[$a,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,ni,si,oi,pi,li,di],isXML:true,serializer:Zn};const ss={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:wt},default:{bodyMapper:_,headersMapper:St}},queryParameters:[Wa,ci],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,xr,mi,ui],isXML:true,serializer:Zn};const os={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{200:{headersMapper:Nt},default:{bodyMapper:_,headersMapper:Tt}},queryParameters:[Wa,ci],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Zn};const ps={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Et},default:{bodyMapper:_,headersMapper:_t}},queryParameters:[Wa,fi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,hi],isXML:true,serializer:Zn};const ls={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Pt},default:{bodyMapper:_,headersMapper:Ct}},queryParameters:[Wa,wr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi],isXML:true,serializer:Zn};const ds={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ot},default:{bodyMapper:_,headersMapper:Rt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Dr,Ar,Ir,Yr,Jr,Zr],isXML:true,serializer:Zn};const cs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Dt},default:{bodyMapper:_,headersMapper:At}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Br,Lr,Yr,Jr,Zr],isXML:true,serializer:Zn};const ms={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:It},default:{bodyMapper:_,headersMapper:Bt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,Mr,Yr,Jr,Zr],isXML:true,serializer:Zn};const us={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Lt},default:{bodyMapper:_,headersMapper:Mt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,jr,qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const fs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:kt},default:{bodyMapper:_,headersMapper:zt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,kr,zr,Yr,Jr,Zr],isXML:true,serializer:Zn};const hs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:jt},default:{bodyMapper:_,headersMapper:qt}},queryParameters:[Wa,yi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi],isXML:true,serializer:Zn};const gs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Ut},default:{bodyMapper:_,headersMapper:Ft}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Yr,Jr,Zr,mi,ui,vi,bi,xi,wi,Si,Ni,Ti,Ei,_i,Pi,Ci],isXML:true,serializer:Zn};const ys={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Ht},default:{bodyMapper:_,headersMapper:Vt}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Yr,Jr,Zr,mi,ui,gi,vi,xi,wi,Si,Ni,Ei,_i,Ci,Oi,Ri,Di,Ai],isXML:true,serializer:Zn};const vs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:Gt},default:{bodyMapper:_,headersMapper:Xt}},queryParameters:[Wa,Ii,Li],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Bi],isXML:true,serializer:Zn};const bs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:$t},202:{headersMapper:$t},default:{bodyMapper:_,headersMapper:Wt}},queryParameters:[Wa,Hr,Vr,Mi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr,bi,ki],isXML:true,serializer:Zn};const xs={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{headersMapper:Kt},default:{bodyMapper:_,headersMapper:Qt}},queryParameters:[$a,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:Zn};const ws={path:"/{containerName}/{blob}",httpMethod:"POST",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Yt},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Yt},default:{bodyMapper:_,headersMapper:Jt}},requestBody:zi,queryParameters:[Wa,Hr,ji],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Zn};const Ss={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:M,headersMapper:Zt},default:{bodyMapper:_,headersMapper:ea}},queryParameters:[Wa,Hr,Vr,qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr],isXML:true,serializer:Zn};const Ns={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:ta},default:{bodyMapper:_,headersMapper:aa}},requestBody:Ui,queryParameters:[Wa,Vr,qi],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,vr,Zr,Fi,Hi],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Zn};class PageBlob{constructor(e){this.client=e}create(e,t,a){const r={contentLength:e,blobContentLength:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,_s)}uploadPages(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Ps)}clearPages(e,t){const a={contentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Cs)}uploadPagesFromURL(e,t,a,r,i){const n={sourceUrl:e,sourceRange:t,contentLength:a,range:r,options:g.operationOptionsToRequestOptionsBase(i||{})};return this.client.sendOperationRequest(n,Os)}getPageRanges(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Rs)}getPageRangesDiff(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ds)}resize(e,t){const a={blobContentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,As)}updateSequenceNumber(e,t){const a={sequenceNumberAction:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Is)}copyIncremental(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Bs)}}const Ts=new g.Serializer(Ua,true);const Es=new g.Serializer(Ua,false);const _s={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ra},default:{bodyMapper:_,headersMapper:ia}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Vi,Gi,Xi],isXML:true,serializer:Ts};const Ps={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:na},default:{bodyMapper:_,headersMapper:sa}},requestBody:Wi,queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,br,xr,Gr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Fi,Hi,$i,Ki,Yi,Ji,Zi,en],mediaType:"binary",serializer:Es};const Cs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:oa},default:{bodyMapper:_,headersMapper:pa}},queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Gr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Ji,Zi,en,tn],isXML:true,serializer:Ts};const Os={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:la},default:{bodyMapper:_,headersMapper:da}},queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,xi,wi,Si,Ni,Ri,Di,Yi,Ji,Zi,en,an,rn,nn,sn],isXML:true,serializer:Ts};const Rs={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:J,headersMapper:ca},default:{bodyMapper:_,headersMapper:ma}},queryParameters:[Wa,tr,ar,Hr,on],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Yr,Jr,Zr],isXML:true,serializer:Ts};const Ds={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:J,headersMapper:ua},default:{bodyMapper:_,headersMapper:fa}},queryParameters:[Wa,tr,ar,Hr,on,pn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Yr,Jr,Zr,ln],isXML:true,serializer:Ts};const As={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ha},default:{bodyMapper:_,headersMapper:ga}},queryParameters:[$a,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Gi],isXML:true,serializer:Ts};const Is={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ya},default:{bodyMapper:_,headersMapper:va}},queryParameters:[$a,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,Xi,dn],isXML:true,serializer:Ts};const Bs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:ba},default:{bodyMapper:_,headersMapper:xa}},queryParameters:[Wa,cn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Yr,Jr,Zr,Ei],isXML:true,serializer:Ts};class AppendBlob{constructor(e){this.client=e}create(e,t){const a={contentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ks)}appendBlock(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,zs)}appendBlockFromUrl(e,t,a){const r={sourceUrl:e,contentLength:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,js)}seal(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,qs)}}const Ls=new g.Serializer(Ua,true);const Ms=new g.Serializer(Ua,false);const ks={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:wa},default:{bodyMapper:_,headersMapper:Sa}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,_i,Ci,mn],isXML:true,serializer:Ls};const zs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Na},default:{bodyMapper:_,headersMapper:Ta}},requestBody:Wi,queryParameters:[Wa,un],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Fi,Hi,$i,Ki,fn,hn],mediaType:"binary",serializer:Ms};const js={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ea},default:{bodyMapper:_,headersMapper:_a}},queryParameters:[Wa,un],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,xi,wi,Si,Ni,Ri,Di,Fi,an,nn,fn,hn,gn],isXML:true,serializer:Ls};const qs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Pa},default:{bodyMapper:_,headersMapper:Ca}},queryParameters:[Wa,yn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,hn],isXML:true,serializer:Ls};class BlockBlob{constructor(e){this.client=e}upload(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Hs)}putBlobFromUrl(e,t,a){const r={contentLength:e,copySource:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Vs)}stageBlock(e,t,a,r){const i={blockId:e,contentLength:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Gs)}stageBlockFromURL(e,t,a,r){const i={blockId:e,contentLength:t,sourceUrl:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Xs)}commitBlockList(e,t){const a={blocks:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,$s)}getBlockList(e,t){const a={listType:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Ws)}}const Us=new g.Serializer(Ua,true);const Fs=new g.Serializer(Ua,false);const Hs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Oa},default:{bodyMapper:_,headersMapper:Ra}},requestBody:Wi,queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Fi,Hi,$i,Ki,vn],mediaType:"binary",serializer:Fs};const Vs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Da},default:{bodyMapper:_,headersMapper:Aa}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,gi,vi,xi,wi,Si,Ni,Ti,Ei,_i,Ri,Di,Ai,Fi,vn,bn],isXML:true,serializer:Us};const Gs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ia},default:{bodyMapper:_,headersMapper:Ba}},requestBody:Wi,queryParameters:[Wa,xn,wn],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,Wr,Kr,Qr,gi,Fi,Hi,$i,Ki],mediaType:"binary",serializer:Fs};const Xs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:La},default:{bodyMapper:_,headersMapper:Ma}},queryParameters:[Wa,xn,wn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,Wr,Kr,Qr,gi,xi,wi,Si,Ni,Ri,Di,an,nn,gn],isXML:true,serializer:Us};const $s={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ka},default:{bodyMapper:_,headersMapper:za}},requestBody:Sn,queryParameters:[Wa,Nn],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Fi,Hi],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Us};const Ws={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:Q,headersMapper:ja},default:{bodyMapper:_,headersMapper:qa}},queryParameters:[Wa,Hr,Nn,Tn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr],isXML:true,serializer:Us};const Ks=s.createClientLogger("storage-blob");const Qs="12.15.0";const Ys="2023-01-03";const Js=256*1024*1024;const Zs=4e3*1024*1024;const eo=5e4;const to=8*1024*1024;const ao=4*1024*1024;const ro=5;const io=100*1e3;const no="https://storage.azure.com/.default";const so={Parameters:{FORCE_BROWSER_NO_CACHE:"_",SIGNATURE:"sig",SNAPSHOT:"snapshot",VERSIONID:"versionid",TIMEOUT:"timeout"}};const oo={HTTP_ACCEPTED:202,HTTP_CONFLICT:409,HTTP_NOT_FOUND:404,HTTP_PRECON_FAILED:412,HTTP_RANGE_NOT_SATISFIABLE:416};const po={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"};const lo="";const co="*";const mo=1*1024*1024;const uo=256;const fo=4*mo;const ho="\r\n";const go="HTTP/1.1";const yo="AES256";const vo=`DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;`;const bo=["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"];const xo=["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"];const wo="BlobUsesCustomerSpecifiedEncryption";const So="BlobDoesNotUseCustomerSpecifiedEncryption";const No=["10000","10001","10002","10003","10004","10100","10101","10102","10103","10104","11000","11001","11002","11003","11004","11100","11101","11102","11103","11104"];function escapeURLPath(e){const t=r.URLBuilder.parse(e);let a=t.getPath();a=a||"/";a=escape(a);t.setPath(a);return t.toString()}function getProxyUriFromDevConnString(e){let t="";if(e.search("DevelopmentStorageProxyUri=")!==-1){const a=e.split(";");for(const e of a){if(e.trim().startsWith("DevelopmentStorageProxyUri=")){t=e.trim().match("DevelopmentStorageProxyUri=(.*)")[1]}}}return t}function getValueInConnString(e,t){const a=e.split(";");for(const e of a){if(e.trim().startsWith(t)){return e.trim().match(t+"=(.*)")[1]}}return""}function extractConnectionStringParts(e){let t="";if(e.startsWith("UseDevelopmentStorage=true")){t=getProxyUriFromDevConnString(e);e=vo}let a=getValueInConnString(e,"BlobEndpoint");a=a.endsWith("/")?a.slice(0,-1):a;if(e.search("DefaultEndpointsProtocol=")!==-1&&e.search("AccountKey=")!==-1){let r="";let i="";let n=Buffer.from("accountKey","base64");let s="";i=getValueInConnString(e,"AccountName");n=Buffer.from(getValueInConnString(e,"AccountKey"),"base64");if(!a){r=getValueInConnString(e,"DefaultEndpointsProtocol");const t=r.toLowerCase();if(t!=="https"&&t!=="http"){throw new Error("Invalid DefaultEndpointsProtocol in the provided Connection String. Expecting 'https' or 'http'")}s=getValueInConnString(e,"EndpointSuffix");if(!s){throw new Error("Invalid EndpointSuffix in the provided Connection String")}a=`${r}://${i}.blob.${s}`}if(!i){throw new Error("Invalid AccountName in the provided Connection String")}else if(n.length===0){throw new Error("Invalid AccountKey in the provided Connection String")}return{kind:"AccountConnString",url:a,accountName:i,accountKey:n,proxyUri:t}}else{const t=getValueInConnString(e,"SharedAccessSignature");const r=getAccountNameFromUrl(a);if(!a){throw new Error("Invalid BlobEndpoint in the provided SAS Connection String")}else if(!t){throw new Error("Invalid SharedAccessSignature in the provided SAS Connection String")}return{kind:"SASConnString",url:a,accountName:r,accountSas:t}}}function escape(e){return encodeURIComponent(e).replace(/%2F/g,"/").replace(/'/g,"%27").replace(/\+/g,"%20").replace(/%25/g,"%")}function appendToURLPath(e,t){const a=r.URLBuilder.parse(e);let i=a.getPath();i=i?i.endsWith("/")?`${i}${t}`:`${i}/${t}`:t;a.setPath(i);const n=new URL(a.toString());return n.toString()}function setURLParameter(e,t,a){const i=r.URLBuilder.parse(e);i.setQueryParameter(t,a);return i.toString()}function getURLParameter(e,t){const a=r.URLBuilder.parse(e);return a.getQueryParameterValue(t)}function setURLHost(e,t){const a=r.URLBuilder.parse(e);a.setHost(t);return a.toString()}function getURLPath(e){const t=r.URLBuilder.parse(e);return t.getPath()}function getURLScheme(e){const t=r.URLBuilder.parse(e);return t.getScheme()}function getURLPathAndQuery(e){const t=r.URLBuilder.parse(e);const a=t.getPath();if(!a){throw new RangeError("Invalid url without valid path.")}let i=t.getQuery()||"";i=i.trim();if(i!==""){i=i.startsWith("?")?i:`?${i}`}return`${a}${i}`}function getURLQueries(e){let t=r.URLBuilder.parse(e).getQuery();if(!t){return{}}t=t.trim();t=t.startsWith("?")?t.substr(1):t;let a=t.split("&");a=a.filter((e=>{const t=e.indexOf("=");const a=e.lastIndexOf("=");return t>0&&t===a&&ai){e=e.slice(0,i)}const n=e+padStart(t.toString(),a-e.length,"0");return base64encode(n)}async function delay(e,t,a){return new Promise(((r,i)=>{let n;const abortHandler=()=>{if(n!==undefined){clearTimeout(n)}i(a)};const resolveHandler=()=>{if(t!==undefined){t.removeEventListener("abort",abortHandler)}r()};n=setTimeout(resolveHandler,e);if(t!==undefined){t.addEventListener("abort",abortHandler)}}))}function padStart(e,t,a=" "){if(String.prototype.padStart){return e.padStart(t,a)}a=a||" ";if(e.length>t){return e}else{t=t-e.length;if(t>a.length){a+=a.repeat(t/a.length)}return a.slice(0,t)+e}}function iEqual(e,t){return e.toLocaleLowerCase()===t.toLocaleLowerCase()}function getAccountNameFromUrl(e){const t=r.URLBuilder.parse(e);let a;try{if(t.getHost().split(".")[1]==="blob"){a=t.getHost().split(".")[0]}else if(isIpEndpointStyle(t)){a=t.getPath().split("/")[1]}else{a=""}return a}catch(e){throw new Error("Unable to extract accountName with provided information.")}}function isIpEndpointStyle(e){if(e.getHost()===undefined){return false}const t=e.getHost()+(e.getPort()===undefined?"":":"+e.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(t)||e.getPort()!==undefined&&No.includes(e.getPort())}function toBlobTagsString(e){if(e===undefined){return undefined}const t=[];for(const a in e){if(Object.prototype.hasOwnProperty.call(e,a)){const r=e[a];t.push(`${encodeURIComponent(a)}=${encodeURIComponent(r)}`)}}return t.join("&")}function toBlobTags(e){if(e===undefined){return undefined}const t={blobTagSet:[]};for(const a in e){if(Object.prototype.hasOwnProperty.call(e,a)){const r=e[a];t.blobTagSet.push({key:a,value:r})}}return t}function toTags(e){if(e===undefined){return undefined}const t={};for(const a of e.blobTagSet){t[a.key]=a.value}return t}function toQuerySerialization(e){if(e===undefined){return undefined}switch(e.kind){case"csv":return{format:{type:"delimited",delimitedTextConfiguration:{columnSeparator:e.columnSeparator||",",fieldQuote:e.fieldQuote||"",recordSeparator:e.recordSeparator,escapeChar:e.escapeCharacter||"",headersPresent:e.hasHeaders||false}}};case"json":return{format:{type:"json",jsonTextConfiguration:{recordSeparator:e.recordSeparator}}};case"arrow":return{format:{type:"arrow",arrowConfiguration:{schema:e.schema}}};case"parquet":return{format:{type:"parquet"}};default:throw Error("Invalid BlobQueryTextConfiguration.")}}function parseObjectReplicationRecord(e){if(!e){return undefined}if("policy-id"in e){return undefined}const t=[];for(const a in e){const r=a.split("_");const i="or-";if(r[0].startsWith(i)){r[0]=r[0].substring(i.length)}const n={ruleId:r[1],replicationStatus:e[a]};const s=t.findIndex((e=>e.policyId===r[0]));if(s>-1){t[s].rules.push(n)}else{t.push({policyId:r[0],rules:[n]})}}return t}function attachCredential(e,t){e.credential=t;return e}function httpAuthorizationToString(e){return e?e.scheme+" "+e.value:undefined}function BlobNameToString(e){if(e.encoded){return decodeURIComponent(e.content)}else{return e.content}}function ConvertInternalResponseOfListBlobFlat(e){return Object.assign(Object.assign({},e),{segment:{blobItems:e.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))}})}function ConvertInternalResponseOfListBlobHierarchy(e){var t;return Object.assign(Object.assign({},e),{segment:{blobPrefixes:(t=e.segment.blobPrefixes)===null||t===void 0?void 0:t.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t})),blobItems:e.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))}})}function*ExtractPageRangeInfoItems(e){let t=[];let a=[];if(e.pageRange)t=e.pageRange;if(e.clearRange)a=e.clearRange;let r=0;let i=0;while(r=1?Math.floor(a.maxTries):To.maxTries,tryTimeoutInMs:a.tryTimeoutInMs&&a.tryTimeoutInMs>=0?a.tryTimeoutInMs:To.tryTimeoutInMs,retryDelayInMs:a.retryDelayInMs&&a.retryDelayInMs>=0?Math.min(a.retryDelayInMs,a.maxRetryDelayInMs?a.maxRetryDelayInMs:To.maxRetryDelayInMs):To.retryDelayInMs,maxRetryDelayInMs:a.maxRetryDelayInMs&&a.maxRetryDelayInMs>=0?a.maxRetryDelayInMs:To.maxRetryDelayInMs,secondaryHost:a.secondaryHost?a.secondaryHost:To.secondaryHost}}async sendRequest(e){return this.attemptSendRequest(e,false,1)}async attemptSendRequest(e,t,a){const r=e.clone();const i=t||!this.retryOptions.secondaryHost||!(e.method==="GET"||e.method==="HEAD"||e.method==="OPTIONS")||a%2===1;if(!i){r.url=setURLHost(r.url,this.retryOptions.secondaryHost)}if(this.retryOptions.tryTimeoutInMs){r.url=setURLParameter(r.url,so.Parameters.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString())}let n;try{Ks.info(`RetryPolicy: =====> Try=${a} ${i?"Primary":"Secondary"}`);n=await this._nextPolicy.sendRequest(r);if(!this.shouldRetry(i,a,n)){return n}t=t||!i&&n.status===404}catch(e){Ks.error(`RetryPolicy: Caught error, message: ${e.message}, code: ${e.code}`);if(!this.shouldRetry(i,a,n,e)){throw e}}await this.delay(i,a,e.abortSignal);return this.attemptSendRequest(e,t,++a)}shouldRetry(e,t,a,r){if(t>=this.retryOptions.maxTries){Ks.info(`RetryPolicy: Attempt(s) ${t} >= maxTries ${this.retryOptions.maxTries}, no further try.`);return false}const i=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(r){for(const e of i){if(r.name.toUpperCase().includes(e)||r.message.toUpperCase().includes(e)||r.code&&r.code.toString().toUpperCase()===e){Ks.info(`RetryPolicy: Network error ${e} found, will retry.`);return true}}}if(a||r){const t=a?a.status:r?r.statusCode:0;if(!e&&t===404){Ks.info(`RetryPolicy: Secondary access with 404, will retry.`);return true}if(t===503||t===500){Ks.info(`RetryPolicy: Will retry for status code ${t}.`);return true}}if((r===null||r===void 0?void 0:r.code)==="PARSE_ERROR"&&(r===null||r===void 0?void 0:r.message.startsWith(`Error "Error: Unclosed root tag`))){Ks.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry.");return true}return false}async delay(e,a,r){let i=0;if(e){switch(this.retryOptions.retryPolicyType){case t.StorageRetryPolicyType.EXPONENTIAL:i=Math.min((Math.pow(2,a-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;case t.StorageRetryPolicyType.FIXED:i=this.retryOptions.retryDelayInMs;break}}else{i=Math.random()*1e3}Ks.info(`RetryPolicy: Delay for ${i}ms`);return delay(i,r,Eo)}}class StorageRetryPolicyFactory{constructor(e){this.retryOptions=e}create(e,t){return new StorageRetryPolicy(e,t,this.retryOptions)}}class CredentialPolicy extends r.BaseRequestPolicy{sendRequest(e){return this._nextPolicy.sendRequest(this.signRequest(e))}signRequest(e){return e}}class AnonymousCredentialPolicy extends CredentialPolicy{constructor(e,t){super(e,t)}}class Credential{create(e,t){throw new Error("Method should be implemented in children classes.")}}class AnonymousCredential extends Credential{create(e,t){return new AnonymousCredentialPolicy(e,t)}}class TelemetryPolicy extends r.BaseRequestPolicy{constructor(e,t,a){super(e,t);this.telemetry=a}async sendRequest(e){if(r.isNode){if(!e.headers){e.headers=new r.HttpHeaders}if(!e.headers.get(po.USER_AGENT)){e.headers.set(po.USER_AGENT,this.telemetry)}}return this._nextPolicy.sendRequest(e)}}class TelemetryPolicyFactory{constructor(e){const t=[];if(r.isNode){if(e){const a=e.userAgentPrefix||"";if(a.length>0&&t.indexOf(a)===-1){t.push(a)}}const a=`azsdk-js-storageblob/${Qs}`;if(t.indexOf(a)===-1){t.push(a)}let r=`(NODE-VERSION ${process.version})`;if(y){r=`(NODE-VERSION ${process.version}; ${y.type()} ${y.release()})`}if(t.indexOf(r)===-1){t.push(r)}}this.telemetryString=t.join(" ")}create(e,t){return new TelemetryPolicy(e,t,this.telemetryString)}}const _o=new r.DefaultHttpClient;function getCachedDefaultHttpClient(){return _o}const Po={DefaultScope:"/.default",HeaderConstants:{AUTHORIZATION:"authorization"}};const Co={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function beginRefresh(e,t,a){async function tryGetAccessToken(){if(Date.now()e.getToken(t,a);r=beginRefresh(tryGetAccessToken,n.retryIntervalInMs,(o=i===null||i===void 0?void 0:i.expiresOnTimestamp)!==null&&o!==void 0?o:Date.now()).then((e=>{r=null;i=e;return i})).catch((e=>{r=null;i=null;throw e}))}return r}return async e=>{if(s.mustRefresh)return refresh(e);if(s.shouldRefresh){refresh(e)}return i}}function getChallenge(e){const t=e.headers.get("WWW-Authenticate");if(e.status===401&&t){return t}return}function parseChallenge(e){const t=e.slice("Bearer ".length);const a=`${t.trim()} `.split(" ").filter((e=>e));const r=a.map((e=>(([e,t])=>({[e]:t}))(e.trim().split("="))));return r.reduce(((e,t)=>Object.assign(Object.assign({},e),t)),{})}function storageBearerTokenChallengeAuthenticationPolicy(e,t){let a=createTokenCycler(e,t);class StorageBearerTokenChallengeAuthenticationPolicy extends r.BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(t){if(!t.url.toLowerCase().startsWith("https://")){throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.")}const i=a;const n=(await i({abortSignal:t.abortSignal,tracingOptions:{tracingContext:t.tracingContext}})).token;t.headers.set(Po.HeaderConstants.AUTHORIZATION,`Bearer ${n}`);const s=await this._nextPolicy.sendRequest(t);if((s===null||s===void 0?void 0:s.status)===401){const i=getChallenge(s);if(i){const n=parseChallenge(i);const s=n.resource_id+Po.DefaultScope;const o=r.URLBuilder.parse(n.authorization_uri);const p=o.getPath().split("/");const l=p[1];const d=createTokenCycler(e,s);const c=(await d({abortSignal:t.abortSignal,tracingOptions:{tracingContext:t.tracingContext},tenantId:l})).token;a=d;t.headers.set(Po.HeaderConstants.AUTHORIZATION,`Bearer ${c}`);return this._nextPolicy.sendRequest(t)}}return s}}return{create:(e,t)=>new StorageBearerTokenChallengeAuthenticationPolicy(e,t)}}function isPipelineLike(e){if(!e||typeof e!=="object"){return false}const t=e;return Array.isArray(t.factories)&&typeof t.options==="object"&&typeof t.toServiceClientOptions==="function"}class Pipeline{constructor(e,t={}){this.factories=e;this.options=Object.assign(Object.assign({},t),{httpClient:t.httpClient||getCachedDefaultHttpClient()})}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}}function newPipeline(e,t={}){var a;if(e===undefined){e=new AnonymousCredential}const i=new TelemetryPolicyFactory(t.userAgentOptions);const n=[r.tracingPolicy({userAgent:i.telemetryString}),r.keepAlivePolicy(t.keepAliveOptions),i,r.generateClientRequestIdPolicy(),new StorageBrowserPolicyFactory,new StorageRetryPolicyFactory(t.retryOptions),r.deserializationPolicy(undefined,{xmlCharKey:"#"}),r.logPolicy({logger:Ks.info,allowedHeaderNames:bo,allowedQueryParameters:xo})];if(r.isNode){n.push(r.proxyPolicy(t.proxyOptions));n.push(r.disableResponseDecompressionPolicy())}n.push(r.isTokenCredential(e)?attachCredential(storageBearerTokenChallengeAuthenticationPolicy(e,(a=t.audience)!==null&&a!==void 0?a:no),e):e);return new Pipeline(n,t)}class StorageSharedKeyCredentialPolicy extends CredentialPolicy{constructor(e,t,a){super(e,t);this.factory=a}signRequest(e){e.headers.set(po.X_MS_DATE,(new Date).toUTCString());if(e.body&&(typeof e.body==="string"||e.body!==undefined)&&e.body.length>0){e.headers.set(po.CONTENT_LENGTH,Buffer.byteLength(e.body))}const t=[e.method.toUpperCase(),this.getHeaderValueToSign(e,po.CONTENT_LANGUAGE),this.getHeaderValueToSign(e,po.CONTENT_ENCODING),this.getHeaderValueToSign(e,po.CONTENT_LENGTH),this.getHeaderValueToSign(e,po.CONTENT_MD5),this.getHeaderValueToSign(e,po.CONTENT_TYPE),this.getHeaderValueToSign(e,po.DATE),this.getHeaderValueToSign(e,po.IF_MODIFIED_SINCE),this.getHeaderValueToSign(e,po.IF_MATCH),this.getHeaderValueToSign(e,po.IF_NONE_MATCH),this.getHeaderValueToSign(e,po.IF_UNMODIFIED_SINCE),this.getHeaderValueToSign(e,po.RANGE)].join("\n")+"\n"+this.getCanonicalizedHeadersString(e)+this.getCanonicalizedResourceString(e);const a=this.factory.computeHMACSHA256(t);e.headers.set(po.AUTHORIZATION,`SharedKey ${this.factory.accountName}:${a}`);return e}getHeaderValueToSign(e,t){const a=e.headers.get(t);if(!a){return""}if(t===po.CONTENT_LENGTH&&a==="0"){return""}return a}getCanonicalizedHeadersString(e){let t=e.headers.headersArray().filter((e=>e.name.toLowerCase().startsWith(po.PREFIX_FOR_STORAGE)));t.sort(((e,t)=>e.name.toLowerCase().localeCompare(t.name.toLowerCase())));t=t.filter(((e,t,a)=>{if(t>0&&e.name.toLowerCase()===a[t-1].name.toLowerCase()){return false}return true}));let a="";t.forEach((e=>{a+=`${e.name.toLowerCase().trimRight()}:${e.value.trimLeft()}\n`}));return a}getCanonicalizedResourceString(e){const t=getURLPath(e.url)||"/";let a="";a+=`/${this.factory.accountName}${t}`;const r=getURLQueries(e.url);const i={};if(r){const e=[];for(const t in r){if(Object.prototype.hasOwnProperty.call(r,t)){const a=t.toLowerCase();i[a]=r[t];e.push(a)}}e.sort();for(const t of e){a+=`\n${t}:${decodeURIComponent(i[t])}`}}return a}}class StorageSharedKeyCredential extends Credential{constructor(e,t){super();this.accountName=e;this.accountKey=Buffer.from(t,"base64")}create(e,t){return new StorageSharedKeyCredentialPolicy(e,t,this)}computeHMACSHA256(e){return l.createHmac("sha256",this.accountKey).update(e,"utf8").digest("base64")}}const Oo="azure-storage-blob";const Ro="12.15.0";class StorageClientContext extends g.ServiceClient{constructor(e,t){if(e===undefined){throw new Error("'url' cannot be null")}if(!t){t={}}if(!t.userAgent){const e=g.getDefaultUserAgentValue();t.userAgent=`${Oo}/${Ro} ${e}`}super(undefined,t);this.requestContentType="application/json; charset=utf-8";this.baseUri=t.endpoint||"{url}";this.url=e;this.version=t.version||"2023-01-03"}}class StorageClient{constructor(e,t){this.url=escapeURLPath(e);this.accountName=getAccountNameFromUrl(e);this.pipeline=t;this.storageClientContext=new StorageClientContext(this.url,t.toServiceClientOptions());this.isHttps=iEqual(getURLScheme(this.url)||"","https");this.credential=new AnonymousCredential;for(const e of this.pipeline.factories){if(r.isNode&&e instanceof StorageSharedKeyCredential||e instanceof AnonymousCredential){this.credential=e}else if(r.isTokenCredential(e.credential)){this.credential=e.credential}}const a=this.storageClientContext;a.requestContentType=undefined}}const Do=n.createSpanFunction({packagePrefix:"Azure.Storage.Blob",namespace:"Microsoft.Storage"});function convertTracingToRequestOptionsBase(e){var t,a;return{spanOptions:(t=e===null||e===void 0?void 0:e.tracingOptions)===null||t===void 0?void 0:t.spanOptions,tracingContext:(a=e===null||e===void 0?void 0:e.tracingOptions)===null||a===void 0?void 0:a.tracingContext}}class BlobSASPermissions{constructor(){this.read=false;this.add=false;this.create=false;this.write=false;this.delete=false;this.deleteVersion=false;this.tag=false;this.move=false;this.execute=false;this.setImmutabilityPolicy=false;this.permanentDelete=false}static parse(e){const t=new BlobSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"x":t.deleteVersion=true;break;case"t":t.tag=true;break;case"m":t.move=true;break;case"e":t.execute=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;default:throw new RangeError(`Invalid permission: ${a}`)}}return t}static from(e){const t=new BlobSASPermissions;if(e.read){t.read=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.deleteVersion){t.deleteVersion=true}if(e.tag){t.tag=true}if(e.move){t.move=true}if(e.execute){t.execute=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.tag){e.push("t")}if(this.move){e.push("m")}if(this.execute){e.push("e")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}return e.join("")}}class ContainerSASPermissions{constructor(){this.read=false;this.add=false;this.create=false;this.write=false;this.delete=false;this.deleteVersion=false;this.list=false;this.tag=false;this.move=false;this.execute=false;this.setImmutabilityPolicy=false;this.permanentDelete=false;this.filterByTags=false}static parse(e){const t=new ContainerSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"l":t.list=true;break;case"t":t.tag=true;break;case"x":t.deleteVersion=true;break;case"m":t.move=true;break;case"e":t.execute=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;case"f":t.filterByTags=true;break;default:throw new RangeError(`Invalid permission ${a}`)}}return t}static from(e){const t=new ContainerSASPermissions;if(e.read){t.read=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.list){t.list=true}if(e.deleteVersion){t.deleteVersion=true}if(e.tag){t.tag=true}if(e.move){t.move=true}if(e.execute){t.execute=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}if(e.filterByTags){t.filterByTags=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.list){e.push("l")}if(this.tag){e.push("t")}if(this.move){e.push("m")}if(this.execute){e.push("e")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}if(this.filterByTags){e.push("f")}return e.join("")}}class UserDelegationKeyCredential{constructor(e,t){this.accountName=e;this.userDelegationKey=t;this.key=Buffer.from(t.value,"base64")}computeHMACSHA256(e){return l.createHmac("sha256",this.key).update(e,"utf8").digest("base64")}}function ipRangeToString(e){return e.end?`${e.start}-${e.end}`:e.start}t.SASProtocol=void 0;(function(e){e["Https"]="https";e["HttpsAndHttp"]="https,http"})(t.SASProtocol||(t.SASProtocol={}));class SASQueryParameters{constructor(e,t,a,r,i,n,s,o,p,l,d,c,m,u,h,g,y,v,b,x){this.version=e;this.signature=t;if(a!==undefined&&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.encryptionScope=a.encryptionScope;this.resource=a.resource;this.cacheControl=a.cacheControl;this.contentDisposition=a.contentDisposition;this.contentEncoding=a.contentEncoding;this.contentLanguage=a.contentLanguage;this.contentType=a.contentType;if(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}}else{this.services=r;this.resourceTypes=i;this.expiresOn=o;this.permissions=a;this.protocol=n;this.startsOn=s;this.ipRangeInner=p;this.encryptionScope=x;this.identifier=l;this.resource=d;this.cacheControl=c;this.contentDisposition=m;this.contentEncoding=u;this.contentLanguage=h;this.contentType=g;if(y){this.signedOid=y.signedObjectId;this.signedTenantId=y.signedTenantId;this.signedStartsOn=y.signedStartsOn;this.signedExpiresOn=y.signedExpiresOn;this.signedService=y.signedService;this.signedVersion=y.signedVersion;this.preauthorizedAgentObjectId=v;this.correlationId=b}}}get ipRange(){if(this.ipRangeInner){return{end:this.ipRangeInner.end,start:this.ipRangeInner.start}}return undefined}toString(){const e=["sv","ss","srt","spr","st","se","sip","si","ses","skoid","sktid","skt","ske","sks","skv","sr","sp","sig","rscc","rscd","rsce","rscl","rsct","saoid","scid"];const t=[];for(const 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?truncatedISO8061Date(this.startsOn,false):undefined);break;case"se":this.tryAppendQueryParameter(t,a,this.expiresOn?truncatedISO8061Date(this.expiresOn,false):undefined);break;case"sip":this.tryAppendQueryParameter(t,a,this.ipRange?ipRangeToString(this.ipRange):undefined);break;case"si":this.tryAppendQueryParameter(t,a,this.identifier);break;case"ses":this.tryAppendQueryParameter(t,a,this.encryptionScope);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?truncatedISO8061Date(this.signedStartsOn,false):undefined);break;case"ske":this.tryAppendQueryParameter(t,a,this.signedExpiresOn?truncatedISO8061Date(this.signedExpiresOn,false):undefined);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){if(!a){return}t=encodeURIComponent(t);a=encodeURIComponent(a);if(t.length>0&&a.length>0){e.push(`${t}=${a}`)}}}function generateBlobSASQueryParameters(e,t,a){const r=e.version?e.version:Ys;const i=t instanceof StorageSharedKeyCredential?t:undefined;let n;if(i===undefined&&a!==undefined){n=new UserDelegationKeyCredential(a,t)}if(i===undefined&&n===undefined){throw TypeError("Invalid sharedKeyCredential, userDelegationKey or accountName.")}if(r>="2020-12-06"){if(i!==undefined){return generateBlobSASQueryParameters20201206(e,i)}else{return generateBlobSASQueryParametersUDK20201206(e,n)}}if(r>="2018-11-09"){if(i!==undefined){return generateBlobSASQueryParameters20181109(e,i)}else{if(r>="2020-02-10"){return generateBlobSASQueryParametersUDK20200210(e,n)}else{return generateBlobSASQueryParametersUDK20181109(e,n)}}}if(r>="2015-04-05"){if(i!==undefined){return generateBlobSASQueryParameters20150405(e,i)}else{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 generateBlobSASQueryParameters20150405(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";if(e.blobName){a="b"}let r;if(e.permissions){if(e.blobName){r=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{r=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const i=[r?r:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const n=t.computeHMACSHA256(i);return new SASQueryParameters(e.version,n,r,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType)}function generateBlobSASQueryParameters20181109(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType)}function generateBlobSASQueryParameters20201206(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.encryptionScope,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,undefined,undefined,undefined,e.encryptionScope)}function generateBlobSASQueryParametersUDK20181109(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey)}function generateBlobSASQueryParametersUDK20200210(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,undefined,e.correlationId,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId)}function generateBlobSASQueryParametersUDK20201206(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,undefined,e.correlationId,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.encryptionScope,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId,e.encryptionScope)}function getCanonicalName(e,t,a){const r=[`/blob/${e}/${t}`];if(a){r.push(`/${a}`)}return r.join("")}function SASSignatureValuesSanityCheckAndAutofill(e){const t=e.version?e.version:Ys;if(e.snapshotTime&&t<"2018-11-09"){throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.")}if(e.blobName===undefined&&e.snapshotTime){throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.")}if(e.versionId&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.")}if(e.blobName===undefined&&e.versionId){throw RangeError("Must provide 'blobName' when providing 'versionId'.")}if(e.permissions&&e.permissions.setImmutabilityPolicy&&t<"2020-08-04"){throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.")}if(e.permissions&&e.permissions.deleteVersion&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.")}if(e.permissions&&e.permissions.permanentDelete&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'y' permission.")}if(e.permissions&&e.permissions.tag&&t<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.")}if(t<"2020-02-10"&&e.permissions&&(e.permissions.move||e.permissions.execute)){throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.")}if(t<"2021-04-10"&&e.permissions&&e.permissions.filterByTags){throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.")}if(t<"2020-02-10"&&(e.preauthorizedAgentObjectId||e.correlationId)){throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.")}if(e.encryptionScope&&t<"2020-12-06"){throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.")}e.version=t;return e}class BlobLeaseClient{constructor(e,t){const a=new StorageClientContext(e.url,e.pipeline.toServiceClientOptions());this._url=e.url;if(e.name===undefined){this._isContainer=true;this._containerOrBlobOperation=new Container(a)}else{this._isContainer=false;this._containerOrBlobOperation=new Blob$1(a)}if(!t){t=r.generateUuid()}this._leaseId=t}get leaseId(){return this._leaseId}get url(){return this._url}async acquireLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-acquireLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions}),proposedLeaseId:this._leaseId},convertTracingToRequestOptionsBase(d)))}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}async changeLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-changeLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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{const a=await this._containerOrBlobOperation.changeLease(this._leaseId,e,Object.assign({abortSignal:t.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions})},convertTracingToRequestOptionsBase(d)));this._leaseId=e;return a}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}async releaseLease(e={}){var t,a,r,i,s,o;const{span:p,updatedOptions:l}=Do("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)!==lo||((r=e.conditions)===null||r===void 0?void 0:r.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==lo||((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})},convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async renewLease(e={}){var t,a,r,i,s,o;const{span:p,updatedOptions:l}=Do("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)!==lo||((r=e.conditions)===null||r===void 0?void 0:r.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==lo||((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})},convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async breakLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-breakLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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{const a=Object.assign({abortSignal:t.abortSignal,breakPeriod:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions})},convertTracingToRequestOptionsBase(d));return await this._containerOrBlobOperation.breakLease(a)}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}}class RetriableReadableStream extends d.Readable{constructor(e,t,a,r,i={}){super({highWaterMark:i.highWaterMark});this.retries=0;this.sourceDataHandler=e=>{if(this.options.doInjectErrorOnce){this.options.doInjectErrorOnce=undefined;this.source.pause();this.source.removeAllListeners("data");this.source.emit("end");return}this.offset+=e.length;if(this.onProgress){this.onProgress({loadedBytes:this.offset-this.start})}if(!this.push(e)){this.source.pause()}};this.sourceErrorOrEndHandler=e=>{if(e&&e.name==="AbortError"){this.destroy(e);return}this.removeSourceEventHandlers();if(this.offset-1===this.end){this.push(null)}else if(this.offset<=this.end){if(this.retries{this.source=e;this.setSourceEventHandlers();return})).catch((e=>{this.destroy(e)}))}else{this.destroy(new Error(`Data corruption failure: received less data than required and reached maxRetires limitation. Received data offset: ${this.offset-1}, data needed offset: ${this.end}, retries: ${this.retries}, max retries: ${this.maxRetryRequests}`))}}else{this.destroy(new Error(`Data corruption failure: Received more data than original request, data needed offset is ${this.end}, received offset: ${this.offset-1}`))}};this.getter=t;this.source=e;this.start=a;this.offset=a;this.end=a+r-1;this.maxRetryRequests=i.maxRetryRequests&&i.maxRetryRequests>=0?i.maxRetryRequests:0;this.onProgress=i.onProgress;this.options=i;this.setSourceEventHandlers()}_read(){this.source.resume()}setSourceEventHandlers(){this.source.on("data",this.sourceDataHandler);this.source.on("end",this.sourceErrorOrEndHandler);this.source.on("error",this.sourceErrorOrEndHandler)}removeSourceEventHandlers(){this.source.removeListener("data",this.sourceDataHandler);this.source.removeListener("end",this.sourceErrorOrEndHandler);this.source.removeListener("error",this.sourceErrorOrEndHandler)}_destroy(e,t){this.removeSourceEventHandlers();this.source.destroy();t(e===null?undefined:e)}}class BlobDownloadResponse{constructor(e,t,a,r,i={}){this.originalResponse=e;this.blobDownloadStream=new RetriableReadableStream(this.originalResponse.readableStreamBody,t,a,r,i)}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(){return this.originalResponse.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 tagCount(){return this.originalResponse.tagCount}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 lastAccessed(){return this.originalResponse.lastAccessed}get createdOn(){return this.originalResponse.createdOn}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 versionId(){return this.originalResponse.versionId}get isCurrentVersion(){return this.originalResponse.isCurrentVersion}get encryptionKeySha256(){return this.originalResponse.encryptionKeySha256}get contentCrc64(){return this.originalResponse.contentCrc64}get objectReplicationDestinationPolicyId(){return this.originalResponse.objectReplicationDestinationPolicyId}get objectReplicationSourceProperties(){return this.originalResponse.objectReplicationSourceProperties}get isSealed(){return this.originalResponse.isSealed}get immutabilityPolicyExpiresOn(){return this.originalResponse.immutabilityPolicyExpiresOn}get immutabilityPolicyMode(){return this.originalResponse.immutabilityPolicyMode}get legalHold(){return this.originalResponse.legalHold}get contentAsBlob(){return this.originalResponse.blobBody}get readableStreamBody(){return r.isNode?this.blobDownloadStream:undefined}get _response(){return this.originalResponse._response}}const Ao=16;const Io=new Uint8Array([79,98,106,1]);const Bo="avro.codec";const Lo="avro.schema";class AvroParser{static async readFixedBytes(e,t,a={}){const r=await e.read(t,{abortSignal:a.abortSignal});if(r.length!==t){throw new Error("Hit stream end.")}return r}static async readByte(e,t={}){const a=await AvroParser.readFixedBytes(e,1,t);return a[0]}static async readZigZagLong(e,t={}){let a=0;let r=0;let i,n,s;do{i=await AvroParser.readByte(e,t);n=i&128;a|=(i&127)<Number.MAX_SAFE_INTEGER){throw new Error("Integer overflow.")}return r}return a>>1^-(a&1)}static async readLong(e,t={}){return AvroParser.readZigZagLong(e,t)}static async readInt(e,t={}){return AvroParser.readZigZagLong(e,t)}static async readNull(){return null}static async readBoolean(e,t={}){const a=await AvroParser.readByte(e,t);if(a===1){return true}else if(a===0){return false}else{throw new Error("Byte was not a boolean.")}}static async readFloat(e,t={}){const a=await AvroParser.readFixedBytes(e,4,t);const r=new DataView(a.buffer,a.byteOffset,a.byteLength);return r.getFloat32(0,true)}static async readDouble(e,t={}){const a=await AvroParser.readFixedBytes(e,8,t);const r=new DataView(a.buffer,a.byteOffset,a.byteLength);return r.getFloat64(0,true)}static async readBytes(e,t={}){const a=await AvroParser.readLong(e,t);if(a<0){throw new Error("Bytes size was negative.")}return e.read(a,{abortSignal:t.abortSignal})}static async readString(e,t={}){const a=await AvroParser.readBytes(e,t);const r=new TextDecoder;return r.decode(a)}static async readMapPair(e,t,a={}){const r=await AvroParser.readString(e,a);const i=await t(e,a);return{key:r,value:i}}static async readMap(e,t,a={}){const readPairMethod=(e,a={})=>AvroParser.readMapPair(e,t,a);const r=await AvroParser.readArray(e,readPairMethod,a);const i={};for(const e of r){i[e.key]=e.value}return i}static async readArray(e,t,a={}){const r=[];for(let i=await AvroParser.readLong(e,a);i!==0;i=await AvroParser.readLong(e,a)){if(i<0){await AvroParser.readLong(e,a);i=-i}while(i--){const i=await t(e,a);r.push(i)}}return r}}var Mo;(function(e){e["RECORD"]="record";e["ENUM"]="enum";e["ARRAY"]="array";e["MAP"]="map";e["UNION"]="union";e["FIXED"]="fixed"})(Mo||(Mo={}));var ko;(function(e){e["NULL"]="null";e["BOOLEAN"]="boolean";e["INT"]="int";e["LONG"]="long";e["FLOAT"]="float";e["DOUBLE"]="double";e["BYTES"]="bytes";e["STRING"]="string"})(ko||(ko={}));class AvroType{static fromSchema(e){if(typeof e==="string"){return AvroType.fromStringSchema(e)}else if(Array.isArray(e)){return AvroType.fromArraySchema(e)}else{return AvroType.fromObjectSchema(e)}}static fromStringSchema(e){switch(e){case ko.NULL:case ko.BOOLEAN:case ko.INT:case ko.LONG:case ko.FLOAT:case ko.DOUBLE:case ko.BYTES:case ko.STRING:return new AvroPrimitiveType(e);default:throw new Error(`Unexpected Avro type ${e}`)}}static fromArraySchema(e){return new AvroUnionType(e.map(AvroType.fromSchema))}static fromObjectSchema(e){const t=e.type;try{return AvroType.fromStringSchema(t)}catch(e){}switch(t){case Mo.RECORD:if(e.aliases){throw new Error(`aliases currently is not supported, schema: ${e}`)}if(!e.name){throw new Error(`Required attribute 'name' doesn't exist on schema: ${e}`)}const a={};if(!e.fields){throw new Error(`Required attribute 'fields' doesn't exist on schema: ${e}`)}for(const t of e.fields){a[t.name]=AvroType.fromSchema(t.type)}return new AvroRecordType(a,e.name);case Mo.ENUM:if(e.aliases){throw new Error(`aliases currently is not supported, schema: ${e}`)}if(!e.symbols){throw new Error(`Required attribute 'symbols' doesn't exist on schema: ${e}`)}return new AvroEnumType(e.symbols);case Mo.MAP:if(!e.values){throw new Error(`Required attribute 'values' doesn't exist on schema: ${e}`)}return new AvroMapType(AvroType.fromSchema(e.values));case Mo.ARRAY:case Mo.FIXED:default:throw new Error(`Unexpected Avro type ${t} in ${e}`)}}}class AvroPrimitiveType extends AvroType{constructor(e){super();this._primitive=e}read(e,t={}){switch(this._primitive){case ko.NULL:return AvroParser.readNull();case ko.BOOLEAN:return AvroParser.readBoolean(e,t);case ko.INT:return AvroParser.readInt(e,t);case ko.LONG:return AvroParser.readLong(e,t);case ko.FLOAT:return AvroParser.readFloat(e,t);case ko.DOUBLE:return AvroParser.readDouble(e,t);case ko.BYTES:return AvroParser.readBytes(e,t);case ko.STRING:return AvroParser.readString(e,t);default:throw new Error("Unknown Avro Primitive")}}}class AvroEnumType extends AvroType{constructor(e){super();this._symbols=e}async read(e,t={}){const a=await AvroParser.readInt(e,t);return this._symbols[a]}}class AvroUnionType extends AvroType{constructor(e){super();this._types=e}async read(e,t={}){const a=await AvroParser.readInt(e,t);return this._types[a].read(e,t)}}class AvroMapType extends AvroType{constructor(e){super();this._itemType=e}read(e,t={}){const readItemMethod=(e,t)=>this._itemType.read(e,t);return AvroParser.readMap(e,readItemMethod,t)}}class AvroRecordType extends AvroType{constructor(e,t){super();this._fields=e;this._name=t}async read(e,t={}){const a={};a["$schema"]=this._name;for(const r in this._fields){if(Object.prototype.hasOwnProperty.call(this._fields,r)){a[r]=await this._fields[r].read(e,t)}}return a}}function arraysEqual(e,t){if(e===t)return true;if(e==null||t==null)return false;if(e.length!==t.length)return false;for(let a=0;a0){for(let t=0;t0}parseObjects(e={}){return i.__asyncGenerator(this,arguments,(function*parseObjects_1(){if(!this._initialized){yield i.__await(this.initialize(e))}while(this.hasNext()){const t=yield i.__await(this._itemType.read(this._dataStream,{abortSignal:e.abortSignal}));this._itemsRemainingInBlock--;this._objectIndex++;if(this._itemsRemainingInBlock===0){const t=yield i.__await(AvroParser.readFixedBytes(this._dataStream,Ao,{abortSignal:e.abortSignal}));this._blockOffset=this._initialBlockOffset+this._dataStream.position;this._objectIndex=0;if(!arraysEqual(this._syncMarker,t)){throw new Error("Stream is not a valid Avro file.")}try{this._itemsRemainingInBlock=yield i.__await(AvroParser.readLong(this._dataStream,{abortSignal:e.abortSignal}))}catch(e){this._itemsRemainingInBlock=0}if(this._itemsRemainingInBlock>0){yield i.__await(AvroParser.readLong(this._dataStream,{abortSignal:e.abortSignal}))}}yield yield i.__await(t)}}))}}class AvroReadable{}const zo=new o.AbortError("Reading from the avro stream was aborted.");class AvroReadableFromStream extends AvroReadable{constructor(e){super();this._readable=e;this._position=0}toUint8Array(e){if(typeof e==="string"){return Buffer.from(e)}return e}get position(){return this._position}async read(e,t={}){var a;if((a=t.abortSignal)===null||a===void 0?void 0:a.aborted){throw zo}if(e<0){throw new Error(`size parameter should be positive: ${e}`)}if(e===0){return new Uint8Array}if(!this._readable.readable){throw new Error("Stream no longer readable.")}const r=this._readable.read(e);if(r){this._position+=r.length;return this.toUint8Array(r)}else{return new Promise(((a,r)=>{const cleanUp=()=>{this._readable.removeListener("readable",readableCallback);this._readable.removeListener("error",rejectCallback);this._readable.removeListener("end",rejectCallback);this._readable.removeListener("close",rejectCallback);if(t.abortSignal){t.abortSignal.removeEventListener("abort",abortHandler)}};const readableCallback=()=>{const t=this._readable.read(e);if(t){this._position+=t.length;cleanUp();a(this.toUint8Array(t))}};const rejectCallback=()=>{cleanUp();r()};const abortHandler=()=>{cleanUp();r(zo)};this._readable.on("readable",readableCallback);this._readable.once("error",rejectCallback);this._readable.once("end",rejectCallback);this._readable.once("close",rejectCallback);if(t.abortSignal){t.abortSignal.addEventListener("abort",abortHandler)}}))}}}class BlobQuickQueryStream extends d.Readable{constructor(e,t={}){super();this.avroPaused=true;this.source=e;this.onProgress=t.onProgress;this.onError=t.onError;this.avroReader=new AvroReader(new AvroReadableFromStream(this.source));this.avroIter=this.avroReader.parseObjects({abortSignal:t.abortSignal})}_read(){if(this.avroPaused){this.readInternal().catch((e=>{this.emit("error",e)}))}}async readInternal(){this.avroPaused=false;let e;do{e=await this.avroIter.next();if(e.done){break}const t=e.value;const a=t.$schema;if(typeof a!=="string"){throw Error("Missing schema in avro record.")}switch(a){case"com.microsoft.azure.storage.queryBlobContents.resultData":{const e=t.data;if(e instanceof Uint8Array===false){throw Error("Invalid data in avro result record.")}if(!this.push(Buffer.from(e))){this.avroPaused=true}}break;case"com.microsoft.azure.storage.queryBlobContents.progress":{const e=t.bytesScanned;if(typeof e!=="number"){throw Error("Invalid bytesScanned in avro progress record.")}if(this.onProgress){this.onProgress({loadedBytes:e})}}break;case"com.microsoft.azure.storage.queryBlobContents.end":if(this.onProgress){const e=t.totalBytes;if(typeof e!=="number"){throw Error("Invalid totalBytes in avro end record.")}this.onProgress({loadedBytes:e})}this.push(null);break;case"com.microsoft.azure.storage.queryBlobContents.error":if(this.onError){const e=t.fatal;if(typeof e!=="boolean"){throw Error("Invalid fatal in avro error record.")}const a=t.name;if(typeof a!=="string"){throw Error("Invalid name in avro error record.")}const r=t.description;if(typeof r!=="string"){throw Error("Invalid description in avro error record.")}const i=t.position;if(typeof i!=="number"){throw Error("Invalid position in avro error record.")}this.onError({position:i,name:a,isFatal:e,description:r})}break;default:throw Error(`Unknown schema ${a} in avro progress record.`)}}while(!e.done&&!this.avroPaused)}}class BlobQueryResponse{constructor(e,t={}){this.originalResponse=e;this.blobDownloadStream=new BlobQuickQueryStream(this.originalResponse.readableStreamBody,t)}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(){return undefined}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(){return undefined}get readableStreamBody(){return r.isNode?this.blobDownloadStream:undefined}get _response(){return this.originalResponse._response}}t.BlockBlobTier=void 0;(function(e){e["Hot"]="Hot";e["Cool"]="Cool";e["Cold"]="Cold";e["Archive"]="Archive"})(t.BlockBlobTier||(t.BlockBlobTier={}));t.PremiumPageBlobTier=void 0;(function(e){e["P4"]="P4";e["P6"]="P6";e["P10"]="P10";e["P15"]="P15";e["P20"]="P20";e["P30"]="P30";e["P40"]="P40";e["P50"]="P50";e["P60"]="P60";e["P70"]="P70";e["P80"]="P80"})(t.PremiumPageBlobTier||(t.PremiumPageBlobTier={}));function toAccessTier(e){if(e===undefined){return undefined}return e}function ensureCpkIfSpecified(e,t){if(e&&!t){throw new RangeError("Customer-provided encryption key must be used over HTTPS.")}if(e&&!e.encryptionAlgorithm){e.encryptionAlgorithm=yo}}t.StorageBlobAudience=void 0;(function(e){e["StorageOAuthScopes"]="https://storage.azure.com/.default";e["DiskComputeOAuthScopes"]="https://disk.compute.azure.com/.default"})(t.StorageBlobAudience||(t.StorageBlobAudience={}));function rangeResponseFromModel(e){const t=(e._response.parsedBody.pageRange||[]).map((e=>({offset:e.start,count:e.end-e.start})));const a=(e._response.parsedBody.clearRange||[]).map((e=>({offset:e.start,count:e.end-e.start})));return Object.assign(Object.assign({},e),{pageRange:t,clearRange:a,_response:Object.assign(Object.assign({},e._response),{parsedBody:{pageRange:t,clearRange:a}})})}class BlobBeginCopyFromUrlPoller extends c.Poller{constructor(e){const{blobClient:t,copySource:a,intervalInMs:r=15e3,onProgress:i,resumeFrom:n,startCopyFromURLOptions:s}=e;let o;if(n){o=JSON.parse(n).state}const p=makeBlobBeginCopyFromURLPollOperation(Object.assign(Object.assign({},o),{blobClient:t,copySource:a,startCopyFromURLOptions:s}));super(p);if(typeof i==="function"){this.onProgress(i)}this.intervalInMs=r}delay(){return r.delay(this.intervalInMs)}}const jo=async function cancel(e={}){const t=this.state;const{copyId:a}=t;if(t.isCompleted){return makeBlobBeginCopyFromURLPollOperation(t)}if(!a){t.isCancelled=true;return makeBlobBeginCopyFromURLPollOperation(t)}await t.blobClient.abortCopyFromURL(a,{abortSignal:e.abortSignal});t.isCancelled=true;return makeBlobBeginCopyFromURLPollOperation(t)};const qo=async function update(e={}){const t=this.state;const{blobClient:a,copySource:r,startCopyFromURLOptions:i}=t;if(!t.isStarted){t.isStarted=true;const e=await a.startCopyFromURL(r,i);t.copyId=e.copyId;if(e.copyStatus==="success"){t.result=e;t.isCompleted=true}}else if(!t.isCompleted){try{const a=await t.blobClient.getProperties({abortSignal:e.abortSignal});const{copyStatus:r,copyProgress:i}=a;const n=t.copyProgress;if(i){t.copyProgress=i}if(r==="pending"&&i!==n&&typeof e.fireProgress==="function"){e.fireProgress(t)}else if(r==="success"){t.result=a;t.isCompleted=true}else if(r==="failed"){t.error=new Error(`Blob copy failed with reason: "${a.copyStatusDescription||"unknown"}"`);t.isCompleted=true}}catch(e){t.error=e;t.isCompleted=true}}return makeBlobBeginCopyFromURLPollOperation(t)};const Uo=function toString(){return JSON.stringify({state:this.state},((e,t)=>{if(e==="blobClient"){return undefined}return t}))};function makeBlobBeginCopyFromURLPollOperation(e){return{state:Object.assign({},e),cancel:jo,toString:Uo,update:qo}}function rangeToString(e){if(e.offset<0){throw new RangeError(`Range.offset cannot be smaller than 0.`)}if(e.count&&e.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 e.count?`bytes=${e.offset}-${e.offset+e.count-1}`:`bytes=${e.offset}-`}var Fo;(function(e){e[e["Good"]=0]="Good";e[e["Error"]=1]="Error"})(Fo||(Fo={}));class Batch{constructor(e=5){this.actives=0;this.completed=0;this.offset=0;this.operations=[];this.state=Fo.Good;if(e<1){throw new RangeError("concurrency must be larger than 0")}this.concurrency=e;this.emitter=new m.EventEmitter}addOperation(e){this.operations.push((async()=>{try{this.actives++;await e();this.actives--;this.completed++;this.parallelExecute()}catch(e){this.emitter.emit("error",e)}}))}async do(){if(this.operations.length===0){return Promise.resolve()}this.parallelExecute();return new Promise(((e,t)=>{this.emitter.on("finish",e);this.emitter.on("error",(e=>{this.state=Fo.Error;t(e)}))}))}nextOperation(){if(this.offset=this.operations.length){this.emitter.emit("finish");return}while(this.actives=this.byteLength){this.push(null)}if(!e){e=this.readableHighWaterMark}const t=[];let a=0;while(ae-a){const r=this.byteOffsetInCurrentBuffer+e-a;t.push(this.buffers[this.bufferIndex].slice(this.byteOffsetInCurrentBuffer,r));this.pushedBytesLength+=e-a;this.byteOffsetInCurrentBuffer=r;a=e;break}else{const e=this.byteOffsetInCurrentBuffer+n;t.push(this.buffers[this.bufferIndex].slice(this.byteOffsetInCurrentBuffer,e));if(n===i){this.byteOffsetInCurrentBuffer=0;this.bufferIndex++}else{this.byteOffsetInCurrentBuffer=e}this.pushedBytesLength+=n;a+=n}}if(t.length>1){this.push(Buffer.concat(t))}else if(t.length===1){this.push(t[0])}}}const Ho=a(4300).constants.MAX_LENGTH;class PooledBuffer{constructor(e,t,a){this.buffers=[];this.capacity=e;this._size=0;const r=Math.ceil(e/Ho);for(let t=0;t0){e[0]=e[0].slice(n)}}getReadableStream(){return new BuffersStream(this.buffers,this.size)}}class BufferScheduler{constructor(e,t,a,r,i,n){this.emitter=new m.EventEmitter;this.offset=0;this.isStreamEnd=false;this.isError=false;this.executingOutgoingHandlers=0;this.numBuffers=0;this.unresolvedDataArray=[];this.unresolvedLength=0;this.incoming=[];this.outgoing=[];if(t<=0){throw new RangeError(`bufferSize must be larger than 0, current is ${t}`)}if(a<=0){throw new RangeError(`maxBuffers must be larger than 0, current is ${a}`)}if(i<=0){throw new RangeError(`concurrency must be larger than 0, current is ${i}`)}this.bufferSize=t;this.maxBuffers=a;this.readable=e;this.outgoingHandler=r;this.concurrency=i;this.encoding=n}async do(){return new Promise(((e,t)=>{this.readable.on("data",(e=>{e=typeof e==="string"?Buffer.from(e,this.encoding):e;this.appendUnresolvedData(e);if(!this.resolveData()){this.readable.pause()}}));this.readable.on("error",(e=>{this.emitter.emit("error",e)}));this.readable.on("end",(()=>{this.isStreamEnd=true;this.emitter.emit("checkEnd")}));this.emitter.on("error",(e=>{this.isError=true;this.readable.pause();t(e)}));this.emitter.on("checkEnd",(()=>{if(this.outgoing.length>0){this.triggerOutgoingHandlers();return}if(this.isStreamEnd&&this.executingOutgoingHandlers===0){if(this.unresolvedLength>0&&this.unresolvedLengtha.getReadableStream()),a.size,this.offset).then(e).catch(t)}else if(this.unresolvedLength>=this.bufferSize){return}else{e()}}}))}))}appendUnresolvedData(e){this.unresolvedDataArray.push(e);this.unresolvedLength+=e.length}shiftBufferFromUnresolvedDataArray(e){if(!e){e=new PooledBuffer(this.bufferSize,this.unresolvedDataArray,this.unresolvedLength)}else{e.fill(this.unresolvedDataArray,this.unresolvedLength)}this.unresolvedLength-=e.size;return e}resolveData(){while(this.unresolvedLength>=this.bufferSize){let e;if(this.incoming.length>0){e=this.incoming.shift();this.shiftBufferFromUnresolvedDataArray(e)}else{if(this.numBuffers=this.concurrency){return}e=this.outgoing.shift();if(e){this.triggerOutgoingHandler(e)}}while(e)}async triggerOutgoingHandler(e){const t=e.size;this.executingOutgoingHandlers++;this.offset+=t;try{await this.outgoingHandler((()=>e.getReadableStream()),t,this.offset-t)}catch(e){this.emitter.emit("error",e);return}this.executingOutgoingHandlers--;this.reuseBuffer(e);this.emitter.emit("checkEnd")}reuseBuffer(e){this.incoming.push(e);if(!this.isError&&this.resolveData()&&!this.isStreamEnd){this.readable.resume()}}}async function streamToBuffer(e,t,a,r,i){let n=0;const s=r-a;return new Promise(((r,o)=>{const p=setTimeout((()=>o(new Error(`The operation cannot be completed in timeout.`))),io);e.on("readable",(()=>{if(n>=s){clearTimeout(p);r();return}let o=e.read();if(!o){return}if(typeof o==="string"){o=Buffer.from(o,i)}const l=n+o.length>s?s-n:o.length;t.fill(o.slice(0,l),a+n,a+n+l);n+=l}));e.on("end",(()=>{clearTimeout(p);if(n{clearTimeout(p);o(e)}))}))}async function streamToBuffer2(e,t,a){let r=0;const i=t.length;return new Promise(((n,s)=>{e.on("readable",(()=>{let n=e.read();if(!n){return}if(typeof n==="string"){n=Buffer.from(n,a)}if(r+n.length>i){s(new Error(`Stream exceeds buffer size. Buffer size: ${i}`));return}t.fill(n,r,r+n.length);r+=n.length}));e.on("end",(()=>{n(r)}));e.on("error",s)}))}async function readStreamToLocalFile(e,t){return new Promise(((a,r)=>{const i=v.createWriteStream(t);e.on("error",(e=>{r(e)}));i.on("error",(e=>{r(e)}));i.on("close",a);e.pipe(i)}))}const Vo=b.promisify(v.stat);const Go=v.createReadStream;class BlobClient extends StorageClient{constructor(e,t,a,i){i=i||{};let n;let s;if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;if(a&&typeof a!=="string"){i=a}n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);({blobName:this._name,containerName:this._containerName}=this.getBlobAndContainerNamesFromUrl());this.blobContext=new Blob$1(this.storageClientContext);this._snapshot=getURLParameter(this.url,so.Parameters.SNAPSHOT);this._versionId=getURLParameter(this.url,so.Parameters.VERSIONID)}get name(){return this._name}get containerName(){return this._containerName}withSnapshot(e){return new BlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}withVersion(e){return new BlobClient(setURLParameter(this.url,so.Parameters.VERSIONID,e.length===0?undefined:e),this.pipeline)}getAppendBlobClient(){return new AppendBlobClient(this.url,this.pipeline)}getBlockBlobClient(){return new BlockBlobClient(this.url,this.pipeline)}getPageBlobClient(){return new PageBlobClient(this.url,this.pipeline)}async download(e=0,t,a={}){var i;a.conditions=a.conditions||{};a.conditions=a.conditions||{};ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);const{span:s,updatedOptions:o}=Do("BlobClient-download",a);try{const n=await this.blobContext.download(Object.assign({abortSignal:a.abortSignal,leaseAccessConditions:a.conditions,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(i=a.conditions)===null||i===void 0?void 0:i.tagConditions}),requestOptions:{onDownloadProgress:r.isNode?undefined:a.onProgress},range:e===0&&!t?undefined:rangeToString({offset:e,count:t}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey},convertTracingToRequestOptionsBase(o)));const p=Object.assign(Object.assign({},n),{_response:n._response,objectReplicationDestinationPolicyId:n.objectReplicationPolicyId,objectReplicationSourceProperties:parseObjectReplicationRecord(n.objectReplicationRules)});if(!r.isNode){return p}if(a.maxRetryRequests===undefined||a.maxRetryRequests<0){a.maxRetryRequests=ro}if(n.contentLength===undefined){throw new RangeError(`File download response doesn't contain valid content length header`)}if(!n.etag){throw new RangeError(`File download response doesn't contain valid etag header`)}return new BlobDownloadResponse(p,(async t=>{var r;const i={leaseAccessConditions:a.conditions,modifiedAccessConditions:{ifMatch:a.conditions.ifMatch||n.etag,ifModifiedSince:a.conditions.ifModifiedSince,ifNoneMatch:a.conditions.ifNoneMatch,ifUnmodifiedSince:a.conditions.ifUnmodifiedSince,ifTags:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions},range:rangeToString({count:e+n.contentLength-t,offset:t}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey};return(await this.blobContext.download(Object.assign({abortSignal:a.abortSignal},i))).readableStreamBody}),e,n.contentLength,{maxRetryRequests:a.maxRetryRequests,onProgress:a.onProgress})}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async exists(e={}){const{span:t,updatedOptions:a}=Do("BlobClient-exists",e);try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);await this.getProperties({abortSignal:e.abortSignal,customerProvidedKey:e.customerProvidedKey,conditions:e.conditions,tracingOptions:a.tracingOptions});return true}catch(e){if(e.statusCode===404){return false}else if(e.statusCode===409&&(e.details.errorCode===wo||e.details.errorCode===So)){return true}t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async getProperties(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-getProperties",e);try{e.conditions=e.conditions||{};ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);const 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},convertTracingToRequestOptionsBase(r)));return Object.assign(Object.assign({},i),{_response:i._response,objectReplicationDestinationPolicyId:i.objectReplicationPolicyId,objectReplicationSourceProperties:parseObjectReplicationRecord(i.objectReplicationRules)})}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async delete(e={}){var t;const{span:a,updatedOptions:r}=Do("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})},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async deleteIfExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("BlobClient-deleteIfExists",e);try{const e=await this.delete(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="BlobNotFound"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when deleting a blob or snapshot only if it exists."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async undelete(e={}){const{span:t,updatedOptions:a}=Do("BlobClient-undelete",e);try{return await this.blobContext.undelete(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setHTTPHeaders(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setHTTPHeaders",t);t.conditions=t.conditions||{};try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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})},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setMetadata(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setMetadata",t);t.conditions=t.conditions||{};try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setTags(e,t={}){var a;const{span:r,updatedOptions:i}=Do("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})},convertTracingToRequestOptionsBase(i)),{tags:toBlobTags(e)}))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async getTags(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-getTags",e);try{const 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})},convertTracingToRequestOptionsBase(r)));const n=Object.assign(Object.assign({},i),{_response:i._response,tags:toTags({blobTagSet:i.blobTagSet})||{}});return n}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}getBlobLeaseClient(e){return new BlobLeaseClient(this,e)}async createSnapshot(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-createSnapshot",e);e.conditions=e.conditions||{};try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);return 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},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async beginCopyFromURL(e,t={}){const a={abortCopyFromURL:(...e)=>this.abortCopyFromURL(...e),getProperties:(...e)=>this.getProperties(...e),startCopyFromURL:(...e)=>this.startCopyFromURL(...e)};const r=new BlobBeginCopyFromUrlPoller({blobClient:a,copySource:e,intervalInMs:t.intervalInMs,onProgress:t.onProgress,resumeFrom:t.resumeFrom,startCopyFromURLOptions:t});await r.poll();return r}async abortCopyFromURL(e,t={}){const{span:a,updatedOptions:r}=Do("BlobClient-abortCopyFromURL",t);try{return await this.blobContext.abortCopyFromURL(e,Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async syncCopyFromURL(e,t={}){var a,r,i;const{span:s,updatedOptions:o}=Do("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:httpAuthorizationToString(t.sourceAuthorization),tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags),immutabilityPolicyExpiry:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,encryptionScope:t.encryptionScope,copySourceTags:t.copySourceTags},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async setAccessTier(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setAccessTier",t);try{return await this.blobContext.setTier(toAccessTier(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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async downloadToBuffer(e,t,a,r={}){let i;let s=0;let o=0;let p=r;if(e instanceof Buffer){i=e;s=t||0;o=typeof a==="number"?a:0}else{s=typeof e==="number"?e:0;o=typeof t==="number"?t:0;p=a||{}}const{span:l,updatedOptions:d}=Do("BlobClient-downloadToBuffer",p);try{if(!p.blockSize){p.blockSize=0}if(p.blockSize<0){throw new RangeError("blockSize option must be >= 0")}if(p.blockSize===0){p.blockSize=ao}if(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(!p.conditions){p.conditions={}}if(!o){const e=await this.getProperties(Object.assign(Object.assign({},p),{tracingOptions:Object.assign(Object.assign({},p.tracingOptions),convertTracingToRequestOptionsBase(d))}));o=e.contentLength-s;if(o<0){throw new RangeError(`offset ${s} shouldn't be larger than blob size ${e.contentLength}`)}}if(!i){try{i=Buffer.alloc(o)}catch(e){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".\t ${e.message}`)}}if(i.length{let t=s+o;if(a+p.blockSize{if(!(this.credential instanceof StorageSharedKeyCredential)){throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential")}const a=generateBlobSASQueryParameters(Object.assign({containerName:this._containerName,blobName:this._name,snapshotTime:this._snapshot,versionId:this._versionId},e),this.credential).toString();t(appendToURLQuery(this.url,a))}))}async deleteImmutabilityPolicy(e){const{span:t,updatedOptions:a}=Do("BlobClient-deleteImmutabilityPolicy",e);try{return await this.blobContext.deleteImmutabilityPolicy(Object.assign({abortSignal:e===null||e===void 0?void 0:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setImmutabilityPolicy(e,t){const{span:a,updatedOptions:r}=Do("BlobClient-setImmutabilityPolicy",t);try{return await this.blobContext.setImmutabilityPolicy(Object.assign({abortSignal:t===null||t===void 0?void 0:t.abortSignal,immutabilityPolicyExpiry:e.expiriesOn,immutabilityPolicyMode:e.policyMode,modifiedAccessConditions:t===null||t===void 0?void 0:t.modifiedAccessCondition},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async setLegalHold(e,t){const{span:a,updatedOptions:r}=Do("BlobClient-setLegalHold",t);try{return await this.blobContext.setLegalHold(e,Object.assign({abortSignal:t===null||t===void 0?void 0:t.abortSignal},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}}class AppendBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.appendBlobContext=new AppendBlob(this.storageClientContext)}withSnapshot(e){return new AppendBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async create(e={}){var t,a,r;const{span:i,updatedOptions:s}=Do("AppendBlobClient-create",e);e.conditions=e.conditions||{};try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);return 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:(r=e.immutabilityPolicy)===null||r===void 0?void 0:r.policyMode,legalHold:e.legalHold,blobTagsString:toBlobTagsString(e.tags)},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async createIfNotExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("AppendBlobClient-createIfNotExists",e);const s={ifNoneMatch:co};try{const e=await this.create(Object.assign(Object.assign({},i),{conditions:s}));return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="BlobAlreadyExists"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a blob only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async seal(e={}){var t;const{span:a,updatedOptions:r}=Do("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})},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async appendBlock(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("AppendBlobClient-appendBlock",a);a.conditions=a.conditions||{};try{ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);return 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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),requestOptions:{onUploadProgress:a.onProgress},transactionalContentMD5:a.transactionalContentMD5,transactionalContentCrc64:a.transactionalContentCrc64,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async appendBlockFromURL(e,t,a,r={}){var i;const{span:s,updatedOptions:o}=Do("AppendBlobClient-appendBlockFromURL",r);r.conditions=r.conditions||{};r.sourceConditions=r.sourceConditions||{};try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.appendBlobContext.appendBlockFromUrl(e,0,Object.assign({abortSignal:r.abortSignal,sourceRange:rangeToString({offset:t,count:a}),sourceContentMD5:r.sourceContentMD5,sourceContentCrc64:r.sourceContentCrc64,leaseAccessConditions:r.conditions,appendPositionAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:r.sourceConditions.ifMatch,sourceIfModifiedSince:r.sourceConditions.ifModifiedSince,sourceIfNoneMatch:r.sourceConditions.ifNoneMatch,sourceIfUnmodifiedSince:r.sourceConditions.ifUnmodifiedSince},copySourceAuthorization:httpAuthorizationToString(r.sourceAuthorization),cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}}class BlockBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;if(a&&typeof a!=="string"){i=a}n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.blockBlobContext=new BlockBlob(this.storageClientContext);this._blobContext=new Blob$1(this.storageClientContext)}withSnapshot(e){return new BlockBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async query(e,t={}){var a;ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);const{span:i,updatedOptions:s}=Do("BlockBlobClient-query",t);try{if(!r.isNode){throw new Error("This operation currently is only supported in Node.js.")}ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);const n=await this._blobContext.query(Object.assign({abortSignal:t.abortSignal,queryRequest:{queryType:"SQL",expression:e,inputSerialization:toQuerySerialization(t.inputTextConfiguration),outputSerialization:toQuerySerialization(t.outputTextConfiguration)},leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),cpkInfo:t.customerProvidedKey},convertTracingToRequestOptionsBase(s)));return new BlobQueryResponse(n,{abortSignal:t.abortSignal,onProgress:t.onProgress,onError:t.onError})}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async upload(e,t,a={}){var r,i,s;a.conditions=a.conditions||{};const{span:o,updatedOptions:p}=Do("BlockBlobClient-upload",a);try{ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);return 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:(r=a.conditions)===null||r===void 0?void 0:r.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:toAccessTier(a.tier),blobTagsString:toBlobTagsString(a.tags)},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async syncUploadFromURL(e,t={}){var a,r,i,s,o;t.conditions=t.conditions||{};const{span:p,updatedOptions:l}=Do("BlockBlobClient-syncUploadFromURL",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.sourceConditions)===null||r===void 0?void 0:r.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:httpAuthorizationToString(t.sourceAuthorization),tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags),copySourceTags:t.copySourceTags}),convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async stageBlock(e,t,a,r={}){const{span:i,updatedOptions:s}=Do("BlockBlobClient-stageBlock",r);try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.blockBlobContext.stageBlock(e,a,t,Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,requestOptions:{onUploadProgress:r.onProgress},transactionalContentMD5:r.transactionalContentMD5,transactionalContentCrc64:r.transactionalContentCrc64,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async stageBlockFromURL(e,t,a=0,r,i={}){const{span:s,updatedOptions:o}=Do("BlockBlobClient-stageBlockFromURL",i);try{ensureCpkIfSpecified(i.customerProvidedKey,this.isHttps);return await this.blockBlobContext.stageBlockFromURL(e,0,t,Object.assign({abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,sourceContentMD5:i.sourceContentMD5,sourceContentCrc64:i.sourceContentCrc64,sourceRange:a===0&&!r?undefined:rangeToString({offset:a,count:r}),cpkInfo:i.customerProvidedKey,encryptionScope:i.encryptionScope,copySourceAuthorization:httpAuthorizationToString(i.sourceAuthorization)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async commitBlockList(e,t={}){var a,r,i;t.conditions=t.conditions||{};const{span:s,updatedOptions:o}=Do("BlockBlobClient-commitBlockList",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async getBlockList(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlockBlobClient-getBlockList",t);try{const n=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})},convertTracingToRequestOptionsBase(i)));if(!n.committedBlocks){n.committedBlocks=[]}if(!n.uncommittedBlocks){n.uncommittedBlocks=[]}return n}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async uploadData(e,t={}){const{span:a,updatedOptions:i}=Do("BlockBlobClient-uploadData",t);try{if(r.isNode){let t;if(e instanceof Buffer){t=e}else if(e instanceof ArrayBuffer){t=Buffer.from(e)}else{e=e;t=Buffer.from(e.buffer,e.byteOffset,e.byteLength)}return this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.byteLength,i)}else{const t=new Blob([e]);return this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.size,i)}}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadBrowserData(e,t={}){const{span:a,updatedOptions:r}=Do("BlockBlobClient-uploadBrowserData",t);try{const t=new Blob([e]);return await this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.size,r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadSeekableInternal(e,t,a={}){if(!a.blockSize){a.blockSize=0}if(a.blockSize<0||a.blockSize>Zs){throw new RangeError(`blockSize option must be >= 0 and <= ${Zs}`)}if(a.maxSingleShotSize!==0&&!a.maxSingleShotSize){a.maxSingleShotSize=Js}if(a.maxSingleShotSize<0||a.maxSingleShotSize>Js){throw new RangeError(`maxSingleShotSize option must be >= 0 and <= ${Js}`)}if(a.blockSize===0){if(t>Zs*eo){throw new RangeError(`${t} is too larger to upload to a block blob.`)}if(t>a.maxSingleShotSize){a.blockSize=Math.ceil(t/eo);if(a.blockSizeeo){throw new RangeError(`The buffer's size is too big or the BlockSize is too small;`+`the number of blocks must be <= ${eo}`)}const o=[];const p=r.generateUuid();let l=0;const d=new Batch(a.concurrency);for(let r=0;r{const i=generateBlockID(p,r);const d=a.blockSize*r;const c=r===n-1?t:d+a.blockSize;const m=c-d;o.push(i);await this.stageBlock(i,e(d,m),m,{abortSignal:a.abortSignal,conditions:a.conditions,encryptionScope:a.encryptionScope,tracingOptions:s.tracingOptions});l+=m;if(a.onProgress){a.onProgress({loadedBytes:l})}}))}await d.do();return this.commitBlockList(o,s)}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async uploadFile(e,t={}){const{span:a,updatedOptions:r}=Do("BlockBlobClient-uploadFile",t);try{const i=(await Vo(e)).size;return await this.uploadSeekableInternal(((t,a)=>()=>Go(e,{autoClose:true,end:a?t+a-1:Infinity,start:t})),i,Object.assign(Object.assign({},t),{tracingOptions:Object.assign(Object.assign({},t.tracingOptions),convertTracingToRequestOptionsBase(r))}))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadStream(e,t=to,a=5,i={}){if(!i.blobHTTPHeaders){i.blobHTTPHeaders={}}if(!i.conditions){i.conditions={}}const{span:s,updatedOptions:o}=Do("BlockBlobClient-uploadStream",i);try{let n=0;const p=r.generateUuid();let l=0;const d=[];const c=new BufferScheduler(e,t,a,(async(e,t)=>{const a=generateBlockID(p,n);d.push(a);n++;await this.stageBlock(a,e,t,{conditions:i.conditions,encryptionScope:i.encryptionScope,tracingOptions:o.tracingOptions});l+=t;if(i.onProgress){i.onProgress({loadedBytes:l})}}),Math.ceil(a/4*3));await c.do();return await this.commitBlockList(d,Object.assign(Object.assign({},i),{tracingOptions:Object.assign(Object.assign({},i.tracingOptions),convertTracingToRequestOptionsBase(o))}))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}}class PageBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.pageBlobContext=new PageBlob(this.storageClientContext)}withSnapshot(e){return new PageBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async create(e,t={}){var a,r,i;t.conditions=t.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-create",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async createIfNotExists(e,t={}){var a,r;const{span:i,updatedOptions:s}=Do("PageBlobClient-createIfNotExists",t);try{const a={ifNoneMatch:co};const r=await this.create(e,Object.assign(Object.assign({},t),{conditions:a,tracingOptions:s.tracingOptions}));return Object.assign(Object.assign({succeeded:true},r),{_response:r._response})}catch(e){if(((a=e.details)===null||a===void 0?void 0:a.errorCode)==="BlobAlreadyExists"){i.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a blob only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(r=e.response)===null||r===void 0?void 0:r.parsedHeaders),{_response:e.response})}i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async uploadPages(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-uploadPages",r);try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.pageBlobContext.uploadPages(a,e,Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),requestOptions:{onUploadProgress:r.onProgress},range:rangeToString({offset:t,count:a}),sequenceNumberAccessConditions:r.conditions,transactionalContentMD5:r.transactionalContentMD5,transactionalContentCrc64:r.transactionalContentCrc64,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async uploadPagesFromURL(e,t,a,r,i={}){var s;i.conditions=i.conditions||{};i.sourceConditions=i.sourceConditions||{};const{span:o,updatedOptions:p}=Do("PageBlobClient-uploadPagesFromURL",i);try{ensureCpkIfSpecified(i.customerProvidedKey,this.isHttps);return await this.pageBlobContext.uploadPagesFromURL(e,rangeToString({offset:t,count:r}),0,rangeToString({offset:a,count:r}),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:httpAuthorizationToString(i.sourceAuthorization)},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async clearPages(e=0,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),range:rangeToString({offset:e,count:t}),sequenceNumberAccessConditions:a.conditions,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async getPageRanges(e=0,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(s))).then(rangeResponseFromModel)}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async listPageRangesSegment(e=0,t,a,r={}){var i;const{span:s,updatedOptions:o}=Do("PageBlobClient-getPageRangesSegment",r);try{return await this.pageBlobContext.getPageRanges(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),range:rangeToString({offset:e,count:t}),marker:a,maxPageSize:r.maxPageSize},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}listPageRangeItemSegments(e=0,t,a,r={}){return i.__asyncGenerator(this,arguments,(function*listPageRangeItemSegments_1(){let n;if(!!a||a===undefined){do{n=yield i.__await(this.listPageRangesSegment(e,t,a,r));a=n.continuationToken;yield yield i.__await(yield i.__await(n))}while(a)}}))}listPageRangeItems(e=0,t,a={}){return i.__asyncGenerator(this,arguments,(function*listPageRangeItems_1(){var r,n;let s;try{for(var o=i.__asyncValues(this.listPageRangeItemSegments(e,t,s,a)),p;p=yield i.__await(o.next()),!p.done;){const e=p.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(ExtractPageRangeInfoItems(e))))}}catch(e){r={error:e}}finally{try{if(p&&!p.done&&(n=o.return))yield i.__await(n.call(o))}finally{if(r)throw r.error}}}))}listPageRanges(e=0,t,a={}){a.conditions=a.conditions||{};const r=this.listPageRangeItems(e,t,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(r={})=>this.listPageRangeItemSegments(e,t,r.continuationToken,Object.assign({maxPageSize:r.maxPageSize},a))}}async getPageRangesDiff(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-getPageRangesDiff",r);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),prevsnapshot:a,range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(o))).then(rangeResponseFromModel)}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async listPageRangesDiffSegment(e,t,a,r,i){var s;const{span:o,updatedOptions:p}=Do("PageBlobClient-getPageRangesDiffSegment",i);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:i===null||i===void 0?void 0:i.abortSignal,leaseAccessConditions:i===null||i===void 0?void 0:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i===null||i===void 0?void 0:i.conditions),{ifTags:(s=i===null||i===void 0?void 0:i.conditions)===null||s===void 0?void 0:s.tagConditions}),prevsnapshot:a,range:rangeToString({offset:e,count:t}),marker:r,maxPageSize:i===null||i===void 0?void 0:i.maxPageSize},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}listPageRangeDiffItemSegments(e,t,a,r,n){return i.__asyncGenerator(this,arguments,(function*listPageRangeDiffItemSegments_1(){let s;if(!!r||r===undefined){do{s=yield i.__await(this.listPageRangesDiffSegment(e,t,a,r,n));r=s.continuationToken;yield yield i.__await(yield i.__await(s))}while(r)}}))}listPageRangeDiffItems(e,t,a,r){return i.__asyncGenerator(this,arguments,(function*listPageRangeDiffItems_1(){var n,s;let o;try{for(var p=i.__asyncValues(this.listPageRangeDiffItemSegments(e,t,a,o,r)),l;l=yield i.__await(p.next()),!l.done;){const e=l.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(ExtractPageRangeInfoItems(e))))}}catch(e){n={error:e}}finally{try{if(l&&!l.done&&(s=p.return))yield i.__await(s.call(p))}finally{if(n)throw n.error}}}))}listPageRangesDiff(e,t,a,r={}){r.conditions=r.conditions||{};const i=this.listPageRangeDiffItems(e,t,a,Object.assign({},r));return{next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(i={})=>this.listPageRangeDiffItemSegments(e,t,a,i.continuationToken,Object.assign({maxPageSize:i.maxPageSize},r))}}async getPageRangesDiffForManagedDisks(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-GetPageRangesDiffForManagedDisks",r);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),prevSnapshotUrl:a,range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(o))).then(rangeResponseFromModel)}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async resize(e,t={}){var a;t.conditions=t.conditions||{};const{span:r,updatedOptions:i}=Do("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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async updateSequenceNumber(e,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions})},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async startCopyIncremental(e,t={}){var a;const{span:r,updatedOptions:i}=Do("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})},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}}async function getBodyAsText(e){let t=Buffer.alloc(fo);const a=await streamToBuffer2(e.readableStreamBody,t);t=t.slice(0,a);return t.toString()}function utf8ByteLength(e){return Buffer.byteLength(e)}const Xo=": ";const $o=" ";const Wo=-1;class BatchResponseParser{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}${ho}`;this.batchResponseEnding=`--${this.responseBatchBoundary}--`}async parseBatchResponse(){if(this.batchResponse._response.status!==oo.HTTP_ACCEPTED){throw new Error(`Invalid state: batch request failed with status: '${this.batchResponse._response.status}'.`)}const e=await getBodyAsText(this.batchResponse);const t=e.split(this.batchResponseEnding)[0].split(this.perResponsePrefix).slice(1);const 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.")}const i=new Array(a);let n=0;let s=0;for(let e=0;e=0&&m{if(this.keys[e]===undefined||this.keys[e]===Ko.UNLOCKED){this.keys[e]=Ko.LOCKED;t()}else{this.onUnlockEvent(e,(()=>{this.keys[e]=Ko.LOCKED;t()}))}}))}static async unlock(e){return new Promise((t=>{if(this.keys[e]===Ko.LOCKED){this.emitUnlockEvent(e)}delete this.keys[e];t()}))}static onUnlockEvent(e,t){if(this.listeners[e]===undefined){this.listeners[e]=[t]}else{this.listeners[e].push(t)}}static emitUnlockEvent(e){if(this.listeners[e]!==undefined&&this.listeners[e].length>0){const t=this.listeners[e].shift();setImmediate((()=>{t.call(this)}))}}}Mutex.keys={};Mutex.listeners={};class BlobBatch{constructor(){this.batch="batch";this.batchRequest=new InnerBatchRequest}getMultiPartContentType(){return this.batchRequest.getMultipartContentType()}getHttpRequestBody(){return this.batchRequest.getHttpRequestBody()}getSubRequests(){return this.batchRequest.getSubRequests()}async addSubRequestInternal(e,t){await Mutex.lock(this.batch);try{this.batchRequest.preAddSubRequest(e);await t();this.batchRequest.postAddSubRequest(e)}finally{await Mutex.unlock(this.batch)}}setBatchType(e){if(!this.batchType){this.batchType=e}if(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 i;let s;if(typeof e==="string"&&(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t))){i=e;s=t}else if(e instanceof BlobClient){i=e.url;s=e.credential;a=t}else{throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.")}if(!a){a={}}const{span:o,updatedOptions:p}=Do("BatchDeleteRequest-addSubRequest",a);try{this.setBatchType("delete");await this.addSubRequestInternal({url:i,credential:s},(async()=>{await new BlobClient(i,this.batchRequest.createPipeline(s)).delete(p)}))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async setBlobAccessTier(e,t,a,i){let s;let o;let p;if(typeof e==="string"&&(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t))){s=e;o=t;p=a}else if(e instanceof BlobClient){s=e.url;o=e.credential;p=t;i=a}else{throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.")}if(!i){i={}}const{span:l,updatedOptions:d}=Do("BatchSetTierRequest-addSubRequest",i);try{this.setBatchType("setAccessTier");await this.addSubRequestInternal({url:s,credential:o},(async()=>{await new BlobClient(s,this.batchRequest.createPipeline(o)).setAccessTier(p,d)}))}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}}class InnerBatchRequest{constructor(){this.operationCount=0;this.body="";const e=r.generateUuid();this.boundary=`batch_${e}`;this.subRequestPrefix=`--${this.boundary}${ho}${po.CONTENT_TYPE}: application/http${ho}${po.CONTENT_TRANSFER_ENCODING}: binary`;this.multipartContentType=`multipart/mixed; boundary=${this.boundary}`;this.batchRequestEnding=`--${this.boundary}--`;this.subRequests=new Map}createPipeline(e){const t=e instanceof AnonymousCredential;const a=3+(t?0:1);const i=new Array(a);i[0]=r.deserializationPolicy();i[1]=new BatchHeaderFilterPolicyFactory;if(!t){i[2]=r.isTokenCredential(e)?attachCredential(r.bearerTokenAuthenticationPolicy(e,no),e):e}i[a-1]=new BatchRequestAssemblePolicyFactory(this);return new Pipeline(i,{})}appendSubRequestToBody(e){this.body+=[this.subRequestPrefix,`${po.CONTENT_ID}: ${this.operationCount}`,"",`${e.method.toString()} ${getURLPathAndQuery(e.url)} ${go}${ho}`].join(ho);for(const t of e.headers.headersArray()){this.body+=`${t.name}: ${t.value}${ho}`}this.body+=ho}preAddSubRequest(e){if(this.operationCount>=uo){throw new RangeError(`Cannot exceed ${uo} sub requests in a single batch`)}const t=getURLPath(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}${ho}`}getMultipartContentType(){return this.multipartContentType}getSubRequests(){return this.subRequests}}class BatchRequestAssemblePolicy extends r.BaseRequestPolicy{constructor(e,t,a){super(t,a);this.dummyResponse={request:new r.WebResource,status:200,headers:new r.HttpHeaders};this.batchRequest=e}async sendRequest(e){await this.batchRequest.appendSubRequestToBody(e);return this.dummyResponse}}class BatchRequestAssemblePolicyFactory{constructor(e){this.batchRequest=e}create(e,t){return new BatchRequestAssemblePolicy(this.batchRequest,e,t)}}class BatchHeaderFilterPolicy extends r.BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){let t="";for(const a of e.headers.headersArray()){if(iEqual(a.name,po.X_MS_VERSION)){t=a.name}}if(t!==""){e.headers.remove(t)}return this._nextPolicy.sendRequest(e)}}class BatchHeaderFilterPolicyFactory{create(e,t){return new BatchHeaderFilterPolicy(e,t)}}class BlobBatchClient{constructor(e,t,a){let r;if(isPipelineLike(t)){r=t}else if(!t){r=newPipeline(new AnonymousCredential,a)}else{r=newPipeline(t,a)}const i=new StorageClientContext(e,r.toServiceClientOptions());const n=getURLPath(e);if(n&&n!=="/"){this.serviceOrContainerContext=new Container(i)}else{this.serviceOrContainerContext=new Service(i)}}createBatch(){return new BlobBatch}async deleteBlobs(e,t,a){const r=new BlobBatch;for(const i of e){if(typeof i==="string"){await r.deleteBlob(i,t,a)}else{await r.deleteBlob(i,t)}}return this.submitBatch(r)}async setBlobsAccessTier(e,t,a,r){const i=new BlobBatch;for(const n of e){if(typeof n==="string"){await i.setBlobAccessTier(n,t,a,r)}else{await i.setBlobAccessTier(n,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.")}const{span:a,updatedOptions:r}=Do("BlobBatchClient-submitBatch",t);try{const i=e.getHttpRequestBody();const n=await this.serviceOrContainerContext.submitBatch(utf8ByteLength(i),e.getMultiPartContentType(),i,Object.assign(Object.assign({},t),convertTracingToRequestOptionsBase(r)));const s=new BatchResponseParser(n,e.getSubRequests());const o=await s.parseBatchResponse();const p={_response:n._response,contentType:n.contentType,errorCode:n.errorCode,requestId:n.requestId,clientRequestId:n.clientRequestId,version:n.version,subResponses:o.subResponses,subResponsesSucceededCount:o.subResponsesSucceededCount,subResponsesFailedCount:o.subResponsesFailedCount};return p}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}}class ContainerClient extends StorageClient{constructor(e,t,a){let i;let n;a=a||{};if(isPipelineLike(t)){n=e;i=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){n=e;i=newPipeline(t,a)}else if(!t&&typeof t!=="string"){n=e;i=newPipeline(new AnonymousCredential,a)}else if(t&&typeof t==="string"){const s=t;const o=extractConnectionStringParts(e);if(o.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(o.accountName,o.accountKey);n=appendToURLPath(o.url,encodeURIComponent(s));if(!a.proxyOptions){a.proxyOptions=r.getDefaultProxySettings(o.proxyUri)}i=newPipeline(e,a)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(o.kind==="SASConnString"){n=appendToURLPath(o.url,encodeURIComponent(s))+"?"+o.accountSas;i=newPipeline(new AnonymousCredential,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(n,i);this._containerName=this.getContainerNameFromUrl();this.containerContext=new Container(this.storageClientContext)}get containerName(){return this._containerName}async create(e={}){const{span:t,updatedOptions:a}=Do("ContainerClient-create",e);try{return await this.containerContext.create(Object.assign(Object.assign({},e),convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async createIfNotExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("ContainerClient-createIfNotExists",e);try{const e=await this.create(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="ContainerAlreadyExists"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a container only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async exists(e={}){const{span:t,updatedOptions:a}=Do("ContainerClient-exists",e);try{await this.getProperties({abortSignal:e.abortSignal,tracingOptions:a.tracingOptions});return true}catch(e){if(e.statusCode===404){t.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when checking container existence"});return false}t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}getBlobClient(e){return new BlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getAppendBlobClient(e){return new AppendBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getBlockBlobClient(e){return new BlockBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getPageBlobClient(e){return new PageBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}async getProperties(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-getProperties",e);try{return await this.containerContext.getProperties(Object.assign(Object.assign({abortSignal:e.abortSignal},e.conditions),convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async delete(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-delete",e);try{return await this.containerContext.delete(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:e.conditions},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async deleteIfExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("ContainerClient-deleteIfExists",e);try{const e=await this.delete(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="ContainerNotFound"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when deleting a container only if it exists."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setMetadata(e,t={}){if(!t.conditions){t.conditions={}}if(t.conditions.ifUnmodifiedSince){throw new RangeError("the IfUnmodifiedSince must have their default values because they are ignored by the blob service")}const{span:a,updatedOptions:r}=Do("ContainerClient-setMetadata",t);try{return await this.containerContext.setMetadata(Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:e,modifiedAccessConditions:t.conditions},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async getAccessPolicy(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-getAccessPolicy",e);try{const r=await this.containerContext.getAccessPolicy(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions},convertTracingToRequestOptionsBase(a)));const i={_response:r._response,blobPublicAccess:r.blobPublicAccess,date:r.date,etag:r.etag,errorCode:r.errorCode,lastModified:r.lastModified,requestId:r.requestId,clientRequestId:r.clientRequestId,signedIdentifiers:[],version:r.version};for(const e of r){let t=undefined;if(e.accessPolicy){t={permissions:e.accessPolicy.permissions};if(e.accessPolicy.expiresOn){t.expiresOn=new Date(e.accessPolicy.expiresOn)}if(e.accessPolicy.startsOn){t.startsOn=new Date(e.accessPolicy.startsOn)}}i.signedIdentifiers.push({accessPolicy:t,id:e.id})}return i}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setAccessPolicy(e,t,a={}){a.conditions=a.conditions||{};const{span:r,updatedOptions:i}=Do("ContainerClient-setAccessPolicy",a);try{const n=[];for(const e of t||[]){n.push({accessPolicy:{expiresOn:e.accessPolicy.expiresOn?truncatedISO8061Date(e.accessPolicy.expiresOn):"",permissions:e.accessPolicy.permissions,startsOn:e.accessPolicy.startsOn?truncatedISO8061Date(e.accessPolicy.startsOn):""},id:e.id})}return await this.containerContext.setAccessPolicy(Object.assign({abortSignal:a.abortSignal,access:e,containerAcl:n,leaseAccessConditions:a.conditions,modifiedAccessConditions:a.conditions},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}getBlobLeaseClient(e){return new BlobLeaseClient(this,e)}async uploadBlockBlob(e,t,a,r={}){const{span:i,updatedOptions:s}=Do("ContainerClient-uploadBlockBlob",r);try{const r=this.getBlockBlobClient(e);const n=await r.upload(t,a,s);return{blockBlobClient:r,response:n}}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async deleteBlob(e,t={}){const{span:a,updatedOptions:r}=Do("ContainerClient-deleteBlob",t);try{let i=this.getBlobClient(e);if(t.versionId){i=i.withVersion(t.versionId)}return await i.delete(r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async listBlobFlatSegment(e,t={}){const{span:a,updatedOptions:r}=Do("ContainerClient-listBlobFlatSegment",t);try{const i=await this.containerContext.listBlobFlatSegment(Object.assign(Object.assign({marker:e},t),convertTracingToRequestOptionsBase(r)));const n=Object.assign(Object.assign({},i),{_response:Object.assign(Object.assign({},i._response),{parsedBody:ConvertInternalResponseOfListBlobFlat(i._response.parsedBody)}),segment:Object.assign(Object.assign({},i.segment),{blobItems:i.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name),tags:toTags(e.blobTags),objectReplicationSourceProperties:parseObjectReplicationRecord(e.objectReplicationMetadata)});return t}))})});return n}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async listBlobHierarchySegment(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("ContainerClient-listBlobHierarchySegment",a);try{const n=await this.containerContext.listBlobHierarchySegment(e,Object.assign(Object.assign({marker:t},a),convertTracingToRequestOptionsBase(s)));const o=Object.assign(Object.assign({},n),{_response:Object.assign(Object.assign({},n._response),{parsedBody:ConvertInternalResponseOfListBlobHierarchy(n._response.parsedBody)}),segment:Object.assign(Object.assign({},n.segment),{blobItems:n.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name),tags:toTags(e.blobTags),objectReplicationSourceProperties:parseObjectReplicationRecord(e.objectReplicationMetadata)});return t})),blobPrefixes:(r=n.segment.blobPrefixes)===null||r===void 0?void 0:r.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))})});return o}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}listSegments(e,t={}){return i.__asyncGenerator(this,arguments,(function*listSegments_1(){let a;if(!!e||e===undefined){do{a=yield i.__await(this.listBlobFlatSegment(e,t));e=a.continuationToken;yield yield i.__await(yield i.__await(a))}while(e)}}))}listItems(e={}){return i.__asyncGenerator(this,arguments,(function*listItems_1(){var t,a;let r;try{for(var n=i.__asyncValues(this.listSegments(r,e)),s;s=yield i.__await(n.next()),!s.done;){const e=s.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.segment.blobItems)))}}catch(e){t={error:e}}finally{try{if(s&&!s.done&&(a=n.return))yield i.__await(a.call(n))}finally{if(t)throw t.error}}}))}listBlobsFlat(e={}){const t=[];if(e.includeCopy){t.push("copy")}if(e.includeDeleted){t.push("deleted")}if(e.includeMetadata){t.push("metadata")}if(e.includeSnapshots){t.push("snapshots")}if(e.includeVersions){t.push("versions")}if(e.includeUncommitedBlobs){t.push("uncommittedblobs")}if(e.includeTags){t.push("tags")}if(e.includeDeletedWithVersions){t.push("deletedwithversions")}if(e.includeImmutabilityPolicy){t.push("immutabilitypolicy")}if(e.includeLegalHold){t.push("legalhold")}if(e.prefix===""){e.prefix=undefined}const a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{});const r=this.listItems(a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(e={})=>this.listSegments(e.continuationToken,Object.assign({maxPageSize:e.maxPageSize},a))}}listHierarchySegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*listHierarchySegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.listBlobHierarchySegment(e,t,a));t=r.continuationToken;yield yield i.__await(yield i.__await(r))}while(t)}}))}listItemsByHierarchy(e,t={}){return i.__asyncGenerator(this,arguments,(function*listItemsByHierarchy_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.listHierarchySegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;const t=e.segment;if(t.blobPrefixes){for(const e of t.blobPrefixes){yield yield i.__await(Object.assign({kind:"prefix"},e))}}for(const e of t.blobItems){yield yield i.__await(Object.assign({kind:"blob"},e))}}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}listBlobsByHierarchy(e,t={}){if(e===""){throw new RangeError("delimiter should contain one or more characters")}const a=[];if(t.includeCopy){a.push("copy")}if(t.includeDeleted){a.push("deleted")}if(t.includeMetadata){a.push("metadata")}if(t.includeSnapshots){a.push("snapshots")}if(t.includeVersions){a.push("versions")}if(t.includeUncommitedBlobs){a.push("uncommittedblobs")}if(t.includeTags){a.push("tags")}if(t.includeDeletedWithVersions){a.push("deletedwithversions")}if(t.includeImmutabilityPolicy){a.push("immutabilitypolicy")}if(t.includeLegalHold){a.push("legalhold")}if(t.prefix===""){t.prefix=undefined}const r=Object.assign(Object.assign({},t),a.length>0?{include:a}:{});const i=this.listItemsByHierarchy(e,r);return{async next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.listHierarchySegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},r))}}async findBlobsByTagsSegment(e,t,a={}){const{span:r,updatedOptions:i}=Do("ContainerClient-findBlobsByTagsSegment",a);try{const n=await this.containerContext.filterBlobs(Object.assign({abortSignal:a.abortSignal,where:e,marker:t,maxPageSize:a.maxPageSize},convertTracingToRequestOptionsBase(i)));const s=Object.assign(Object.assign({},n),{_response:n._response,blobs:n.blobs.map((e=>{var t;let a="";if(((t=e.tags)===null||t===void 0?void 0:t.blobTagSet.length)===1){a=e.tags.blobTagSet[0].value}return Object.assign(Object.assign({},e),{tags:toTags(e.tags),tagValue:a})}))});return s}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}findBlobsByTagsSegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsSegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.findBlobsByTagsSegment(e,t,a));r.blobs=r.blobs||[];t=r.continuationToken;yield yield i.__await(r)}while(t)}}))}findBlobsByTagsItems(e,t={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsItems_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.findBlobsByTagsSegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.blobs)))}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}findBlobsByTags(e,t={}){const a=Object.assign({},t);const r=this.findBlobsByTagsItems(e,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.findBlobsByTagsSegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},a))}}getContainerNameFromUrl(){let e;try{const t=r.URLBuilder.parse(this.url);if(t.getHost().split(".")[1]==="blob"){e=t.getPath().split("/")[1]}else if(isIpEndpointStyle(t)){e=t.getPath().split("/")[2]}else{e=t.getPath().split("/")[1]}e=decodeURIComponent(e);if(!e){throw new Error("Provided containerName is invalid.")}return e}catch(e){throw new Error("Unable to extract containerName with provided information.")}}generateSasUrl(e){return new Promise((t=>{if(!(this.credential instanceof StorageSharedKeyCredential)){throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential")}const a=generateBlobSASQueryParameters(Object.assign({containerName:this._containerName},e),this.credential).toString();t(appendToURLQuery(this.url,a))}))}getBlobBatchClient(){return new BlobBatchClient(this.url,this.pipeline)}}class AccountSASPermissions{constructor(){this.read=false;this.write=false;this.delete=false;this.deleteVersion=false;this.list=false;this.add=false;this.create=false;this.update=false;this.process=false;this.tag=false;this.filter=false;this.setImmutabilityPolicy=false;this.permanentDelete=false}static parse(e){const t=new AccountSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"x":t.deleteVersion=true;break;case"l":t.list=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"u":t.update=true;break;case"p":t.process=true;break;case"t":t.tag=true;break;case"f":t.filter=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;default:throw new RangeError(`Invalid permission character: ${a}`)}}return t}static from(e){const t=new AccountSASPermissions;if(e.read){t.read=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.deleteVersion){t.deleteVersion=true}if(e.filter){t.filter=true}if(e.tag){t.tag=true}if(e.list){t.list=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.update){t.update=true}if(e.process){t.process=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.filter){e.push("f")}if(this.tag){e.push("t")}if(this.list){e.push("l")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.update){e.push("u")}if(this.process){e.push("p")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}return e.join("")}}class AccountSASResourceTypes{constructor(){this.service=false;this.container=false;this.object=false}static parse(e){const t=new AccountSASResourceTypes;for(const a of e){switch(a){case"s":t.service=true;break;case"c":t.container=true;break;case"o":t.object=true;break;default:throw new RangeError(`Invalid resource type: ${a}`)}}return t}toString(){const e=[];if(this.service){e.push("s")}if(this.container){e.push("c")}if(this.object){e.push("o")}return e.join("")}}class AccountSASServices{constructor(){this.blob=false;this.file=false;this.queue=false;this.table=false}static parse(e){const t=new AccountSASServices;for(const a of e){switch(a){case"b":t.blob=true;break;case"f":t.file=true;break;case"q":t.queue=true;break;case"t":t.table=true;break;default:throw new RangeError(`Invalid service character: ${a}`)}}return t}toString(){const e=[];if(this.blob){e.push("b")}if(this.table){e.push("t")}if(this.queue){e.push("q")}if(this.file){e.push("f")}return e.join("")}}function generateAccountSASQueryParameters(e,t){const a=e.version?e.version:Ys;if(e.permissions&&e.permissions.setImmutabilityPolicy&&a<"2020-08-04"){throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.")}if(e.permissions&&e.permissions.deleteVersion&&a<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when provided 'x' permission.")}if(e.permissions&&e.permissions.permanentDelete&&a<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when provided 'y' permission.")}if(e.permissions&&e.permissions.tag&&a<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when provided 't' permission.")}if(e.permissions&&e.permissions.filter&&a<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when provided 'f' permission.")}if(e.encryptionScope&&a<"2020-12-06"){throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.")}const r=AccountSASPermissions.parse(e.permissions.toString());const i=AccountSASServices.parse(e.services).toString();const n=AccountSASResourceTypes.parse(e.resourceTypes).toString();let s;if(a>="2020-12-06"){s=[t.accountName,r,i,n,e.startsOn?truncatedISO8061Date(e.startsOn,false):"",truncatedISO8061Date(e.expiresOn,false),e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",a,e.encryptionScope?e.encryptionScope:"",""].join("\n")}else{s=[t.accountName,r,i,n,e.startsOn?truncatedISO8061Date(e.startsOn,false):"",truncatedISO8061Date(e.expiresOn,false),e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",a,""].join("\n")}const o=t.computeHMACSHA256(s);return new SASQueryParameters(a,o,r.toString(),i,n,e.protocol,e.startsOn,e.expiresOn,e.ipRange,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,e.encryptionScope)}class BlobServiceClient extends StorageClient{constructor(e,t,a){let i;if(isPipelineLike(t)){i=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){i=newPipeline(t,a)}else{i=newPipeline(new AnonymousCredential,a)}super(e,i);this.serviceContext=new Service(this.storageClientContext)}static fromConnectionString(e,t){t=t||{};const a=extractConnectionStringParts(e);if(a.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(a.accountName,a.accountKey);if(!t.proxyOptions){t.proxyOptions=r.getDefaultProxySettings(a.proxyUri)}const i=newPipeline(e,t);return new BlobServiceClient(a.url,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(a.kind==="SASConnString"){const e=newPipeline(new AnonymousCredential,t);return new BlobServiceClient(a.url+"?"+a.accountSas,e)}else{throw new Error("Connection string must be either an Account connection string or a SAS connection string")}}getContainerClient(e){return new ContainerClient(appendToURLPath(this.url,encodeURIComponent(e)),this.pipeline)}async createContainer(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-createContainer",t);try{const t=this.getContainerClient(e);const i=await t.create(r);return{containerClient:t,containerCreateResponse:i}}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async deleteContainer(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-deleteContainer",t);try{const t=this.getContainerClient(e);return await t.delete(r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async undeleteContainer(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-undeleteContainer",a);try{const n=this.getContainerClient(a.destinationContainerName||e);const s=new Container(n["storageClientContext"]);const o=await s.restore(Object.assign({deletedContainerName:e,deletedContainerVersion:t},i));return{containerClient:n,containerUndeleteResponse:o}}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async renameContainer(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("BlobServiceClient-renameContainer",a);try{const n=this.getContainerClient(t);const o=new Container(n["storageClientContext"]);const p=await o.rename(e,Object.assign(Object.assign({},s),{sourceLeaseId:(r=a.sourceCondition)===null||r===void 0?void 0:r.leaseId}));return{containerClient:n,containerRenameResponse:p}}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async getProperties(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getProperties",e);try{return await this.serviceContext.getProperties(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setProperties(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-setProperties",t);try{return await this.serviceContext.setProperties(e,Object.assign({abortSignal:t.abortSignal},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async getStatistics(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getStatistics",e);try{return await this.serviceContext.getStatistics(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async getAccountInfo(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getAccountInfo",e);try{return await this.serviceContext.getAccountInfo(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async listContainersSegment(e,t={}){const{span:a,updatedOptions:r}=Do("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}),convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async findBlobsByTagsSegment(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-findBlobsByTagsSegment",a);try{const n=await this.serviceContext.filterBlobs(Object.assign({abortSignal:a.abortSignal,where:e,marker:t,maxPageSize:a.maxPageSize},convertTracingToRequestOptionsBase(i)));const s=Object.assign(Object.assign({},n),{_response:n._response,blobs:n.blobs.map((e=>{var t;let a="";if(((t=e.tags)===null||t===void 0?void 0:t.blobTagSet.length)===1){a=e.tags.blobTagSet[0].value}return Object.assign(Object.assign({},e),{tags:toTags(e.tags),tagValue:a})}))});return s}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}findBlobsByTagsSegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsSegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.findBlobsByTagsSegment(e,t,a));r.blobs=r.blobs||[];t=r.continuationToken;yield yield i.__await(r)}while(t)}}))}findBlobsByTagsItems(e,t={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsItems_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.findBlobsByTagsSegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.blobs)))}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}findBlobsByTags(e,t={}){const a=Object.assign({},t);const r=this.findBlobsByTagsItems(e,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.findBlobsByTagsSegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},a))}}listSegments(e,t={}){return i.__asyncGenerator(this,arguments,(function*listSegments_1(){let a;if(!!e||e===undefined){do{a=yield i.__await(this.listContainersSegment(e,t));a.containerItems=a.containerItems||[];e=a.continuationToken;yield yield i.__await(yield i.__await(a))}while(e)}}))}listItems(e={}){return i.__asyncGenerator(this,arguments,(function*listItems_1(){var t,a;let r;try{for(var n=i.__asyncValues(this.listSegments(r,e)),s;s=yield i.__await(n.next()),!s.done;){const e=s.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.containerItems)))}}catch(e){t={error:e}}finally{try{if(s&&!s.done&&(a=n.return))yield i.__await(a.call(n))}finally{if(t)throw t.error}}}))}listContainers(e={}){if(e.prefix===""){e.prefix=undefined}const t=[];if(e.includeDeleted){t.push("deleted")}if(e.includeMetadata){t.push("metadata")}if(e.includeSystem){t.push("system")}const a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{});const r=this.listItems(a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(e={})=>this.listSegments(e.continuationToken,Object.assign({maxPageSize:e.maxPageSize},a))}}async getUserDelegationKey(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-getUserDelegationKey",a);try{const n=await this.serviceContext.getUserDelegationKey({startsOn:truncatedISO8061Date(e,false),expiresOn:truncatedISO8061Date(t,false)},Object.assign({abortSignal:a.abortSignal},convertTracingToRequestOptionsBase(i)));const s={signedObjectId:n.signedObjectId,signedTenantId:n.signedTenantId,signedStartsOn:new Date(n.signedStartsOn),signedExpiresOn:new Date(n.signedExpiresOn),signedService:n.signedService,signedVersion:n.signedVersion,value:n.value};const o=Object.assign({_response:n._response,requestId:n.requestId,clientRequestId:n.clientRequestId,version:n.version,date:n.date,errorCode:n.errorCode},s);return o}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}getBlobBatchClient(){return new BlobBatchClient(this.url,this.pipeline)}generateAccountSasUrl(e,t=AccountSASPermissions.parse("r"),a="sco",r={}){if(!(this.credential instanceof StorageSharedKeyCredential)){throw RangeError("Can only generate the account SAS when the client is initialized with a shared key credential")}if(e===undefined){const t=new Date;e=new Date(t.getTime()+3600*1e3)}const i=generateAccountSASQueryParameters(Object.assign({permissions:t,expiresOn:e,resourceTypes:a,services:AccountSASServices.parse("b").toString()},r),this.credential).toString();return appendToURLQuery(this.url,i)}}t.KnownEncryptionAlgorithmType=void 0;(function(e){e["AES256"]="AES256"})(t.KnownEncryptionAlgorithmType||(t.KnownEncryptionAlgorithmType={}));Object.defineProperty(t,"BaseRequestPolicy",{enumerable:true,get:function(){return r.BaseRequestPolicy}});Object.defineProperty(t,"HttpHeaders",{enumerable:true,get:function(){return r.HttpHeaders}});Object.defineProperty(t,"RequestPolicyOptions",{enumerable:true,get:function(){return r.RequestPolicyOptions}});Object.defineProperty(t,"RestError",{enumerable:true,get:function(){return r.RestError}});Object.defineProperty(t,"WebResource",{enumerable:true,get:function(){return r.WebResource}});Object.defineProperty(t,"deserializationPolicy",{enumerable:true,get:function(){return r.deserializationPolicy}});t.AccountSASPermissions=AccountSASPermissions;t.AccountSASResourceTypes=AccountSASResourceTypes;t.AccountSASServices=AccountSASServices;t.AnonymousCredential=AnonymousCredential;t.AnonymousCredentialPolicy=AnonymousCredentialPolicy;t.AppendBlobClient=AppendBlobClient;t.BlobBatch=BlobBatch;t.BlobBatchClient=BlobBatchClient;t.BlobClient=BlobClient;t.BlobLeaseClient=BlobLeaseClient;t.BlobSASPermissions=BlobSASPermissions;t.BlobServiceClient=BlobServiceClient;t.BlockBlobClient=BlockBlobClient;t.ContainerClient=ContainerClient;t.ContainerSASPermissions=ContainerSASPermissions;t.Credential=Credential;t.CredentialPolicy=CredentialPolicy;t.PageBlobClient=PageBlobClient;t.Pipeline=Pipeline;t.SASQueryParameters=SASQueryParameters;t.StorageBrowserPolicy=StorageBrowserPolicy;t.StorageBrowserPolicyFactory=StorageBrowserPolicyFactory;t.StorageOAuthScopes=no;t.StorageRetryPolicy=StorageRetryPolicy;t.StorageRetryPolicyFactory=StorageRetryPolicyFactory;t.StorageSharedKeyCredential=StorageSharedKeyCredential;t.StorageSharedKeyCredentialPolicy=StorageSharedKeyCredentialPolicy;t.generateAccountSASQueryParameters=generateAccountSASQueryParameters;t.generateBlobSASQueryParameters=generateBlobSASQueryParameters;t.isPipelineLike=isPipelineLike;t.logger=Ks;t.newPipeline=newPipeline},679:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var B=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);B(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var L=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new L(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},334:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a=/^v1\./;const r=/^ghs_/;const i=/^ghu_/;async function auth(e){const t=e.split(/\./).length===3;const n=a.test(e)||r.test(e);const s=i.test(e);const o=t?"app":n?"installation":s?"user-to-server":"oauth";return{type:"token",token:e,tokenType:o}}function withAuthorizationPrefix(e){if(e.split(/\./).length===3){return`bearer ${e}`}return`token ${e}`}async function hook(e,t,a,r){const i=t.endpoint.merge(a,r);i.headers.authorization=withAuthorizationPrefix(e);return t(i)}const n=function createTokenAuth(e){if(!e){throw new Error("[@octokit/auth-token] No token passed to createTokenAuth")}if(typeof e!=="string"){throw new Error("[@octokit/auth-token] Token passed to createTokenAuth is not a string")}e=e.replace(/^(token|bearer) +/i,"");return Object.assign(auth.bind(null,e),{hook:hook.bind(null,e)})};t.createTokenAuth=n},6762:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5030);var i=a(3682);var n=a(6234);var s=a(8467);var o=a(334);function _objectWithoutPropertiesLoose(e,t){if(e==null)return{};var a={};var r=Object.keys(e);var i,n;for(n=0;n=0)continue;a[i]=e[i]}return a}function _objectWithoutProperties(e,t){if(e==null)return{};var a=_objectWithoutPropertiesLoose(e,t);var r,i;if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);for(i=0;i=0)continue;if(!Object.prototype.propertyIsEnumerable.call(e,r))continue;a[r]=e[r]}}return a}const p="3.6.0";const l=["authStrategy"];class Octokit{constructor(e={}){const t=new i.Collection;const a={baseUrl:n.request.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:t.bind(null,"request")}),mediaType:{previews:[],format:""}};a.headers["user-agent"]=[e.userAgent,`octokit-core.js/${p} ${r.getUserAgent()}`].filter(Boolean).join(" ");if(e.baseUrl){a.baseUrl=e.baseUrl}if(e.previews){a.mediaType.previews=e.previews}if(e.timeZone){a.headers["time-zone"]=e.timeZone}this.request=n.request.defaults(a);this.graphql=s.withCustomRequest(this.request).defaults(a);this.log=Object.assign({debug:()=>{},info:()=>{},warn:console.warn.bind(console),error:console.error.bind(console)},e.log);this.hook=t;if(!e.authStrategy){if(!e.auth){this.auth=async()=>({type:"unauthenticated"})}else{const a=o.createTokenAuth(e.auth);t.wrap("request",a.hook);this.auth=a}}else{const{authStrategy:a}=e,r=_objectWithoutProperties(e,l);const i=a(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:r},e.auth));t.wrap("request",i.hook);this.auth=i}const d=this.constructor;d.plugins.forEach((t=>{Object.assign(this,t(this,e))}))}static defaults(e){const t=class extends(this){constructor(...t){const a=t[0]||{};if(typeof e==="function"){super(e(a));return}super(Object.assign({},e,a,a.userAgent&&e.userAgent?{userAgent:`${a.userAgent} ${e.userAgent}`}:null))}};return t}static plugin(...e){var t;const a=this.plugins;const r=(t=class extends(this){},t.plugins=a.concat(e.filter((e=>!a.includes(e)))),t);return r}}Octokit.VERSION=p;Octokit.plugins=[];t.Octokit=Octokit},9440:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(3287);var i=a(5030);function lowercaseKeys(e){if(!e){return{}}return Object.keys(e).reduce(((t,a)=>{t[a.toLowerCase()]=e[a];return t}),{})}function mergeDeep(e,t){const a=Object.assign({},e);Object.keys(t).forEach((i=>{if(r.isPlainObject(t[i])){if(!(i in e))Object.assign(a,{[i]:t[i]});else a[i]=mergeDeep(e[i],t[i])}else{Object.assign(a,{[i]:t[i]})}}));return a}function removeUndefinedProperties(e){for(const t in e){if(e[t]===undefined){delete e[t]}}return e}function merge(e,t,a){if(typeof t==="string"){let[e,r]=t.split(" ");a=Object.assign(r?{method:e,url:r}:{url:e},a)}else{a=Object.assign({},t)}a.headers=lowercaseKeys(a.headers);removeUndefinedProperties(a);removeUndefinedProperties(a.headers);const r=mergeDeep(e||{},a);if(e&&e.mediaType.previews.length){r.mediaType.previews=e.mediaType.previews.filter((e=>!r.mediaType.previews.includes(e))).concat(r.mediaType.previews)}r.mediaType.previews=r.mediaType.previews.map((e=>e.replace(/-preview/,"")));return r}function addQueryParameters(e,t){const a=/\?/.test(e)?"&":"?";const r=Object.keys(t);if(r.length===0){return e}return e+a+r.map((e=>{if(e==="q"){return"q="+t.q.split("+").map(encodeURIComponent).join("+")}return`${e}=${encodeURIComponent(t[e])}`})).join("&")}const n=/\{[^}]+\}/g;function removeNonChars(e){return e.replace(/^\W+|\W+$/g,"").split(/,/)}function extractUrlVariableNames(e){const t=e.match(n);if(!t){return[]}return t.map(removeNonChars).reduce(((e,t)=>e.concat(t)),[])}function omit(e,t){return Object.keys(e).filter((e=>!t.includes(e))).reduce(((t,a)=>{t[a]=e[a];return t}),{})}function encodeReserved(e){return e.split(/(%[0-9A-Fa-f]{2})/g).map((function(e){if(!/%[0-9A-Fa-f]/.test(e)){e=encodeURI(e).replace(/%5B/g,"[").replace(/%5D/g,"]")}return e})).join("")}function encodeUnreserved(e){return encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function encodeValue(e,t,a){t=e==="+"||e==="#"?encodeReserved(t):encodeUnreserved(t);if(a){return encodeUnreserved(a)+"="+t}else{return t}}function isDefined(e){return e!==undefined&&e!==null}function isKeyOperator(e){return e===";"||e==="&"||e==="?"}function getValues(e,t,a,r){var i=e[a],n=[];if(isDefined(i)&&i!==""){if(typeof i==="string"||typeof i==="number"||typeof i==="boolean"){i=i.toString();if(r&&r!=="*"){i=i.substring(0,parseInt(r,10))}n.push(encodeValue(t,i,isKeyOperator(t)?a:""))}else{if(r==="*"){if(Array.isArray(i)){i.filter(isDefined).forEach((function(e){n.push(encodeValue(t,e,isKeyOperator(t)?a:""))}))}else{Object.keys(i).forEach((function(e){if(isDefined(i[e])){n.push(encodeValue(t,i[e],e))}}))}}else{const e=[];if(Array.isArray(i)){i.filter(isDefined).forEach((function(a){e.push(encodeValue(t,a))}))}else{Object.keys(i).forEach((function(a){if(isDefined(i[a])){e.push(encodeUnreserved(a));e.push(encodeValue(t,i[a].toString()))}}))}if(isKeyOperator(t)){n.push(encodeUnreserved(a)+"="+e.join(","))}else if(e.length!==0){n.push(e.join(","))}}}}else{if(t===";"){if(isDefined(i)){n.push(encodeUnreserved(a))}}else if(i===""&&(t==="&"||t==="?")){n.push(encodeUnreserved(a)+"=")}else if(i===""){n.push("")}}return n}function parseUrl(e){return{expand:expand.bind(null,e)}}function expand(e,t){var a=["+","#",".","/",";","?","&"];return e.replace(/\{([^\{\}]+)\}|([^\{\}]+)/g,(function(e,r,i){if(r){let e="";const i=[];if(a.indexOf(r.charAt(0))!==-1){e=r.charAt(0);r=r.substr(1)}r.split(/,/g).forEach((function(a){var r=/([^:\*]*)(?::(\d+)|(\*))?/.exec(a);i.push(getValues(t,e,r[1],r[2]||r[3]))}));if(e&&e!=="+"){var n=",";if(e==="?"){n="&"}else if(e!=="#"){n=e}return(i.length!==0?e:"")+i.join(n)}else{return i.join(",")}}else{return encodeReserved(i)}}))}function parse(e){let t=e.method.toUpperCase();let a=(e.url||"/").replace(/:([a-z]\w+)/g,"{$1}");let r=Object.assign({},e.headers);let i;let n=omit(e,["method","baseUrl","url","headers","request","mediaType"]);const s=extractUrlVariableNames(a);a=parseUrl(a).expand(n);if(!/^http/.test(a)){a=e.baseUrl+a}const o=Object.keys(e).filter((e=>s.includes(e))).concat("baseUrl");const p=omit(n,o);const l=/application\/octet-stream/i.test(r.accept);if(!l){if(e.mediaType.format){r.accept=r.accept.split(/,/).map((t=>t.replace(/application\/vnd(\.\w+)(\.v3)?(\.\w+)?(\+json)?$/,`application/vnd$1$2.${e.mediaType.format}`))).join(",")}if(e.mediaType.previews.length){const t=r.accept.match(/[\w-]+(?=-preview)/g)||[];r.accept=t.concat(e.mediaType.previews).map((t=>{const a=e.mediaType.format?`.${e.mediaType.format}`:"+json";return`application/vnd.github.${t}-preview${a}`})).join(",")}}if(["GET","HEAD"].includes(t)){a=addQueryParameters(a,p)}else{if("data"in p){i=p.data}else{if(Object.keys(p).length){i=p}else{r["content-length"]=0}}}if(!r["content-type"]&&typeof i!=="undefined"){r["content-type"]="application/json; charset=utf-8"}if(["PATCH","PUT"].includes(t)&&typeof i==="undefined"){i=""}return Object.assign({method:t,url:a,headers:r},typeof i!=="undefined"?{body:i}:null,e.request?{request:e.request}:null)}function endpointWithDefaults(e,t,a){return parse(merge(e,t,a))}function withDefaults(e,t){const a=merge(e,t);const r=endpointWithDefaults.bind(null,a);return Object.assign(r,{DEFAULTS:a,defaults:withDefaults.bind(null,a),merge:merge.bind(null,a),parse:parse})}const s="6.0.12";const o=`octokit-endpoint.js/${s} ${i.getUserAgent()}`;const p={method:"GET",baseUrl:"https://api.github.com",headers:{accept:"application/vnd.github.v3+json","user-agent":o},mediaType:{format:"",previews:[]}};const l=withDefaults(null,p);t.endpoint=l},8467:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(6234);var i=a(5030);const n="4.8.0";function _buildMessageForResponseErrors(e){return`Request failed due to following response errors:\n`+e.errors.map((e=>` - ${e.message}`)).join("\n")}class GraphqlResponseError extends Error{constructor(e,t,a){super(_buildMessageForResponseErrors(a));this.request=e;this.headers=t;this.response=a;this.name="GraphqlResponseError";this.errors=a.errors;this.data=a.data;if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}}}const s=["method","baseUrl","url","headers","request","query","mediaType"];const o=["query","method","url"];const p=/\/api\/v3\/?$/;function graphql(e,t,a){if(a){if(typeof t==="string"&&"query"in a){return Promise.reject(new Error(`[@octokit/graphql] "query" cannot be used as variable name`))}for(const e in a){if(!o.includes(e))continue;return Promise.reject(new Error(`[@octokit/graphql] "${e}" cannot be used as variable name`))}}const r=typeof t==="string"?Object.assign({query:t},a):t;const i=Object.keys(r).reduce(((e,t)=>{if(s.includes(t)){e[t]=r[t];return e}if(!e.variables){e.variables={}}e.variables[t]=r[t];return e}),{});const n=r.baseUrl||e.endpoint.DEFAULTS.baseUrl;if(p.test(n)){i.url=n.replace(p,"/api/graphql")}return e(i).then((e=>{if(e.data.errors){const t={};for(const a of Object.keys(e.headers)){t[a]=e.headers[a]}throw new GraphqlResponseError(i,t,e.data)}return e.data.data}))}function withDefaults(e,t){const a=e.defaults(t);const newApi=(e,t)=>graphql(a,e,t);return Object.assign(newApi,{defaults:withDefaults.bind(null,a),endpoint:r.request.endpoint})}const l=withDefaults(r.request,{headers:{"user-agent":`octokit-graphql.js/${n} ${i.getUserAgent()}`},method:"POST",url:"/graphql"});function withCustomRequest(e){return withDefaults(e,{method:"POST",url:"/graphql"})}t.GraphqlResponseError=GraphqlResponseError;t.graphql=l;t.withCustomRequest=withCustomRequest},4193:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a="2.21.3";function ownKeys(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function _objectSpread2(e){for(var t=1;t({async next(){if(!o)return{done:true};try{const e=await i({method:n,url:o,headers:s});const t=normalizePaginatedListResponse(e);o=((t.headers.link||"").match(/<([^>]+)>;\s*rel="next"/)||[])[1];return{value:t}}catch(e){if(e.status!==409)throw e;o="";return{value:{status:200,headers:{},data:[]}}}}})}}function paginate(e,t,a,r){if(typeof a==="function"){r=a;a=undefined}return gather(e,[],iterator(e,t,a)[Symbol.asyncIterator](),r)}function gather(e,t,a,r){return a.next().then((i=>{if(i.done){return t}let n=false;function done(){n=true}t=t.concat(r?r(i.value,done):i.value.data);if(n){return t}return gather(e,t,a,r)}))}const r=Object.assign(paginate,{iterator:iterator});const i=["GET /app/hook/deliveries","GET /app/installations","GET /applications/grants","GET /authorizations","GET /enterprises/{enterprise}/actions/permissions/organizations","GET /enterprises/{enterprise}/actions/runner-groups","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/organizations","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/runners","GET /enterprises/{enterprise}/actions/runners","GET /enterprises/{enterprise}/audit-log","GET /enterprises/{enterprise}/secret-scanning/alerts","GET /enterprises/{enterprise}/settings/billing/advanced-security","GET /events","GET /gists","GET /gists/public","GET /gists/starred","GET /gists/{gist_id}/comments","GET /gists/{gist_id}/commits","GET /gists/{gist_id}/forks","GET /installation/repositories","GET /issues","GET /licenses","GET /marketplace_listing/plans","GET /marketplace_listing/plans/{plan_id}/accounts","GET /marketplace_listing/stubbed/plans","GET /marketplace_listing/stubbed/plans/{plan_id}/accounts","GET /networks/{owner}/{repo}/events","GET /notifications","GET /organizations","GET /orgs/{org}/actions/cache/usage-by-repository","GET /orgs/{org}/actions/permissions/repositories","GET /orgs/{org}/actions/runner-groups","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners","GET /orgs/{org}/actions/runners","GET /orgs/{org}/actions/secrets","GET /orgs/{org}/actions/secrets/{secret_name}/repositories","GET /orgs/{org}/audit-log","GET /orgs/{org}/blocks","GET /orgs/{org}/code-scanning/alerts","GET /orgs/{org}/codespaces","GET /orgs/{org}/credential-authorizations","GET /orgs/{org}/dependabot/secrets","GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories","GET /orgs/{org}/events","GET /orgs/{org}/external-groups","GET /orgs/{org}/failed_invitations","GET /orgs/{org}/hooks","GET /orgs/{org}/hooks/{hook_id}/deliveries","GET /orgs/{org}/installations","GET /orgs/{org}/invitations","GET /orgs/{org}/invitations/{invitation_id}/teams","GET /orgs/{org}/issues","GET /orgs/{org}/members","GET /orgs/{org}/migrations","GET /orgs/{org}/migrations/{migration_id}/repositories","GET /orgs/{org}/outside_collaborators","GET /orgs/{org}/packages","GET /orgs/{org}/packages/{package_type}/{package_name}/versions","GET /orgs/{org}/projects","GET /orgs/{org}/public_members","GET /orgs/{org}/repos","GET /orgs/{org}/secret-scanning/alerts","GET /orgs/{org}/settings/billing/advanced-security","GET /orgs/{org}/team-sync/groups","GET /orgs/{org}/teams","GET /orgs/{org}/teams/{team_slug}/discussions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions","GET /orgs/{org}/teams/{team_slug}/invitations","GET /orgs/{org}/teams/{team_slug}/members","GET /orgs/{org}/teams/{team_slug}/projects","GET /orgs/{org}/teams/{team_slug}/repos","GET /orgs/{org}/teams/{team_slug}/teams","GET /projects/columns/{column_id}/cards","GET /projects/{project_id}/collaborators","GET /projects/{project_id}/columns","GET /repos/{owner}/{repo}/actions/artifacts","GET /repos/{owner}/{repo}/actions/caches","GET /repos/{owner}/{repo}/actions/runners","GET /repos/{owner}/{repo}/actions/runs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts","GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs","GET /repos/{owner}/{repo}/actions/secrets","GET /repos/{owner}/{repo}/actions/workflows","GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs","GET /repos/{owner}/{repo}/assignees","GET /repos/{owner}/{repo}/branches","GET /repos/{owner}/{repo}/check-runs/{check_run_id}/annotations","GET /repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs","GET /repos/{owner}/{repo}/code-scanning/alerts","GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances","GET /repos/{owner}/{repo}/code-scanning/analyses","GET /repos/{owner}/{repo}/codespaces","GET /repos/{owner}/{repo}/codespaces/devcontainers","GET /repos/{owner}/{repo}/codespaces/secrets","GET /repos/{owner}/{repo}/collaborators","GET /repos/{owner}/{repo}/comments","GET /repos/{owner}/{repo}/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/commits","GET /repos/{owner}/{repo}/commits/{commit_sha}/comments","GET /repos/{owner}/{repo}/commits/{commit_sha}/pulls","GET /repos/{owner}/{repo}/commits/{ref}/check-runs","GET /repos/{owner}/{repo}/commits/{ref}/check-suites","GET /repos/{owner}/{repo}/commits/{ref}/status","GET /repos/{owner}/{repo}/commits/{ref}/statuses","GET /repos/{owner}/{repo}/contributors","GET /repos/{owner}/{repo}/dependabot/secrets","GET /repos/{owner}/{repo}/deployments","GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses","GET /repos/{owner}/{repo}/environments","GET /repos/{owner}/{repo}/events","GET /repos/{owner}/{repo}/forks","GET /repos/{owner}/{repo}/git/matching-refs/{ref}","GET /repos/{owner}/{repo}/hooks","GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries","GET /repos/{owner}/{repo}/invitations","GET /repos/{owner}/{repo}/issues","GET /repos/{owner}/{repo}/issues/comments","GET /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/issues/events","GET /repos/{owner}/{repo}/issues/{issue_number}/comments","GET /repos/{owner}/{repo}/issues/{issue_number}/events","GET /repos/{owner}/{repo}/issues/{issue_number}/labels","GET /repos/{owner}/{repo}/issues/{issue_number}/reactions","GET /repos/{owner}/{repo}/issues/{issue_number}/timeline","GET /repos/{owner}/{repo}/keys","GET /repos/{owner}/{repo}/labels","GET /repos/{owner}/{repo}/milestones","GET /repos/{owner}/{repo}/milestones/{milestone_number}/labels","GET /repos/{owner}/{repo}/notifications","GET /repos/{owner}/{repo}/pages/builds","GET /repos/{owner}/{repo}/projects","GET /repos/{owner}/{repo}/pulls","GET /repos/{owner}/{repo}/pulls/comments","GET /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/pulls/{pull_number}/comments","GET /repos/{owner}/{repo}/pulls/{pull_number}/commits","GET /repos/{owner}/{repo}/pulls/{pull_number}/files","GET /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments","GET /repos/{owner}/{repo}/releases","GET /repos/{owner}/{repo}/releases/{release_id}/assets","GET /repos/{owner}/{repo}/releases/{release_id}/reactions","GET /repos/{owner}/{repo}/secret-scanning/alerts","GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations","GET /repos/{owner}/{repo}/stargazers","GET /repos/{owner}/{repo}/subscribers","GET /repos/{owner}/{repo}/tags","GET /repos/{owner}/{repo}/teams","GET /repos/{owner}/{repo}/topics","GET /repositories","GET /repositories/{repository_id}/environments/{environment_name}/secrets","GET /search/code","GET /search/commits","GET /search/issues","GET /search/labels","GET /search/repositories","GET /search/topics","GET /search/users","GET /teams/{team_id}/discussions","GET /teams/{team_id}/discussions/{discussion_number}/comments","GET /teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /teams/{team_id}/discussions/{discussion_number}/reactions","GET /teams/{team_id}/invitations","GET /teams/{team_id}/members","GET /teams/{team_id}/projects","GET /teams/{team_id}/repos","GET /teams/{team_id}/teams","GET /user/blocks","GET /user/codespaces","GET /user/codespaces/secrets","GET /user/emails","GET /user/followers","GET /user/following","GET /user/gpg_keys","GET /user/installations","GET /user/installations/{installation_id}/repositories","GET /user/issues","GET /user/keys","GET /user/marketplace_purchases","GET /user/marketplace_purchases/stubbed","GET /user/memberships/orgs","GET /user/migrations","GET /user/migrations/{migration_id}/repositories","GET /user/orgs","GET /user/packages","GET /user/packages/{package_type}/{package_name}/versions","GET /user/public_emails","GET /user/repos","GET /user/repository_invitations","GET /user/starred","GET /user/subscriptions","GET /user/teams","GET /users","GET /users/{username}/events","GET /users/{username}/events/orgs/{org}","GET /users/{username}/events/public","GET /users/{username}/followers","GET /users/{username}/following","GET /users/{username}/gists","GET /users/{username}/gpg_keys","GET /users/{username}/keys","GET /users/{username}/orgs","GET /users/{username}/packages","GET /users/{username}/projects","GET /users/{username}/received_events","GET /users/{username}/received_events/public","GET /users/{username}/repos","GET /users/{username}/starred","GET /users/{username}/subscriptions"];function isPaginatingEndpoint(e){if(typeof e==="string"){return i.includes(e)}else{return false}}function paginateRest(e){return{paginate:Object.assign(paginate.bind(null,e),{iterator:iterator.bind(null,e)})}}paginateRest.VERSION=a;t.composePaginateRest=r;t.isPaginatingEndpoint=isPaginatingEndpoint;t.paginateRest=paginateRest;t.paginatingEndpoints=i},3044:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function ownKeys(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);if(t){r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))}a.push.apply(a,r)}return a}function _objectSpread2(e){for(var t=1;t{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var r=a(8932);var i=_interopDefault(a(1223));const n=i((e=>console.warn(e)));const s=i((e=>console.warn(e)));class RequestError extends Error{constructor(e,t,a){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="HttpError";this.status=t;let i;if("headers"in a&&typeof a.headers!=="undefined"){i=a.headers}if("response"in a){this.response=a.response;i=a.response.headers}const o=Object.assign({},a.request);if(a.request.headers.authorization){o.headers=Object.assign({},a.request.headers,{authorization:a.request.headers.authorization.replace(/ .*$/," [REDACTED]")})}o.url=o.url.replace(/\bclient_secret=\w+/g,"client_secret=[REDACTED]").replace(/\baccess_token=\w+/g,"access_token=[REDACTED]");this.request=o;Object.defineProperty(this,"code",{get(){n(new r.Deprecation("[@octokit/request-error] `error.code` is deprecated, use `error.status`."));return t}});Object.defineProperty(this,"headers",{get(){s(new r.Deprecation("[@octokit/request-error] `error.headers` is deprecated, use `error.response.headers`."));return i||{}}})}}t.RequestError=RequestError},6234:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var r=a(9440);var i=a(5030);var n=a(3287);var s=_interopDefault(a(467));var o=a(537);const p="5.6.3";function getBufferResponse(e){return e.arrayBuffer()}function fetchWrapper(e){const t=e.request&&e.request.log?e.request.log:console;if(n.isPlainObject(e.body)||Array.isArray(e.body)){e.body=JSON.stringify(e.body)}let a={};let r;let i;const p=e.request&&e.request.fetch||s;return p(e.url,Object.assign({method:e.method,body:e.body,headers:e.headers,redirect:e.redirect},e.request)).then((async n=>{i=n.url;r=n.status;for(const e of n.headers){a[e[0]]=e[1]}if("deprecation"in a){const r=a.link&&a.link.match(/<([^>]+)>; rel="deprecation"/);const i=r&&r.pop();t.warn(`[@octokit/request] "${e.method} ${e.url}" is deprecated. It is scheduled to be removed on ${a.sunset}${i?`. See ${i}`:""}`)}if(r===204||r===205){return}if(e.method==="HEAD"){if(r<400){return}throw new o.RequestError(n.statusText,r,{response:{url:i,status:r,headers:a,data:undefined},request:e})}if(r===304){throw new o.RequestError("Not modified",r,{response:{url:i,status:r,headers:a,data:await getResponseData(n)},request:e})}if(r>=400){const t=await getResponseData(n);const s=new o.RequestError(toErrorMessage(t),r,{response:{url:i,status:r,headers:a,data:t},request:e});throw s}return getResponseData(n)})).then((e=>({status:r,url:i,headers:a,data:e}))).catch((t=>{if(t instanceof o.RequestError)throw t;throw new o.RequestError(t.message,500,{request:e})}))}async function getResponseData(e){const t=e.headers.get("content-type");if(/application\/json/.test(t)){return e.json()}if(!t||/^text\/|charset=utf-8$/.test(t)){return e.text()}return getBufferResponse(e)}function toErrorMessage(e){if(typeof e==="string")return e;if("message"in e){if(Array.isArray(e.errors)){return`${e.message}: ${e.errors.map(JSON.stringify).join(", ")}`}return e.message}return`Unknown error: ${JSON.stringify(e)}`}function withDefaults(e,t){const a=e.defaults(t);const newApi=function(e,t){const r=a.merge(e,t);if(!r.request||!r.request.hook){return fetchWrapper(a.parse(r))}const request=(e,t)=>fetchWrapper(a.parse(a.merge(e,t)));Object.assign(request,{endpoint:a,defaults:withDefaults.bind(null,a)});return r.request.hook(request,r)};return Object.assign(newApi,{endpoint:a,defaults:withDefaults.bind(null,a)})}const l=withDefaults(r.endpoint,{headers:{"user-agent":`octokit-request.js/${p} ${i.getUserAgent()}`}});t.request=l},7171:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ContextAPI=void 0;const r=a(4118);const i=a(5135);const n=a(1877);const s="context";const o=new r.NoopContextManager;class ContextAPI{constructor(){}static getInstance(){if(!this._instance){this._instance=new ContextAPI}return this._instance}setGlobalContextManager(e){return(0,i.registerGlobal)(s,e,n.DiagAPI.instance())}active(){return this._getContextManager().active()}with(e,t,a,...r){return this._getContextManager().with(e,t,a,...r)}bind(e,t){return this._getContextManager().bind(e,t)}_getContextManager(){return(0,i.getGlobal)(s)||o}disable(){this._getContextManager().disable();(0,i.unregisterGlobal)(s,n.DiagAPI.instance())}}t.ContextAPI=ContextAPI},1877:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagAPI=void 0;const r=a(7978);const i=a(9639);const n=a(8077);const s=a(5135);const o="diag";class DiagAPI{constructor(){function _logProxy(e){return function(...t){const a=(0,s.getGlobal)("diag");if(!a)return;return a[e](...t)}}const e=this;const setLogger=(t,a={logLevel:n.DiagLogLevel.INFO})=>{var r,o,p;if(t===e){const t=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");e.error((r=t.stack)!==null&&r!==void 0?r:t.message);return false}if(typeof a==="number"){a={logLevel:a}}const l=(0,s.getGlobal)("diag");const d=(0,i.createLogLevelDiagLogger)((o=a.logLevel)!==null&&o!==void 0?o:n.DiagLogLevel.INFO,t);if(l&&!a.suppressOverrideMessage){const e=(p=(new Error).stack)!==null&&p!==void 0?p:"";l.warn(`Current logger will be overwritten from ${e}`);d.warn(`Current logger will overwrite one already registered from ${e}`)}return(0,s.registerGlobal)("diag",d,e,true)};e.setLogger=setLogger;e.disable=()=>{(0,s.unregisterGlobal)(o,e)};e.createComponentLogger=e=>new r.DiagComponentLogger(e);e.verbose=_logProxy("verbose");e.debug=_logProxy("debug");e.info=_logProxy("info");e.warn=_logProxy("warn");e.error=_logProxy("error")}static instance(){if(!this._instance){this._instance=new DiagAPI}return this._instance}}t.DiagAPI=DiagAPI},7696:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MetricsAPI=void 0;const r=a(2647);const i=a(5135);const n=a(1877);const s="metrics";class MetricsAPI{constructor(){}static getInstance(){if(!this._instance){this._instance=new MetricsAPI}return this._instance}setGlobalMeterProvider(e){return(0,i.registerGlobal)(s,e,n.DiagAPI.instance())}getMeterProvider(){return(0,i.getGlobal)(s)||r.NOOP_METER_PROVIDER}getMeter(e,t,a){return this.getMeterProvider().getMeter(e,t,a)}disable(){(0,i.unregisterGlobal)(s,n.DiagAPI.instance())}}t.MetricsAPI=MetricsAPI},9909:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.PropagationAPI=void 0;const r=a(5135);const i=a(2368);const n=a(865);const s=a(7682);const o=a(8136);const p=a(1877);const l="propagation";const d=new i.NoopTextMapPropagator;class PropagationAPI{constructor(){this.createBaggage=o.createBaggage;this.getBaggage=s.getBaggage;this.getActiveBaggage=s.getActiveBaggage;this.setBaggage=s.setBaggage;this.deleteBaggage=s.deleteBaggage}static getInstance(){if(!this._instance){this._instance=new PropagationAPI}return this._instance}setGlobalPropagator(e){return(0,r.registerGlobal)(l,e,p.DiagAPI.instance())}inject(e,t,a=n.defaultTextMapSetter){return this._getGlobalPropagator().inject(e,t,a)}extract(e,t,a=n.defaultTextMapGetter){return this._getGlobalPropagator().extract(e,t,a)}fields(){return this._getGlobalPropagator().fields()}disable(){(0,r.unregisterGlobal)(l,p.DiagAPI.instance())}_getGlobalPropagator(){return(0,r.getGlobal)(l)||d}}t.PropagationAPI=PropagationAPI},1539:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceAPI=void 0;const r=a(5135);const i=a(2285);const n=a(9745);const s=a(3326);const o=a(1877);const p="trace";class TraceAPI{constructor(){this._proxyTracerProvider=new i.ProxyTracerProvider;this.wrapSpanContext=n.wrapSpanContext;this.isSpanContextValid=n.isSpanContextValid;this.deleteSpan=s.deleteSpan;this.getSpan=s.getSpan;this.getActiveSpan=s.getActiveSpan;this.getSpanContext=s.getSpanContext;this.setSpan=s.setSpan;this.setSpanContext=s.setSpanContext}static getInstance(){if(!this._instance){this._instance=new TraceAPI}return this._instance}setGlobalTracerProvider(e){const t=(0,r.registerGlobal)(p,this._proxyTracerProvider,o.DiagAPI.instance());if(t){this._proxyTracerProvider.setDelegate(e)}return t}getTracerProvider(){return(0,r.getGlobal)(p)||this._proxyTracerProvider}getTracer(e,t){return this.getTracerProvider().getTracer(e,t)}disable(){(0,r.unregisterGlobal)(p,o.DiagAPI.instance());this._proxyTracerProvider=new i.ProxyTracerProvider}}t.TraceAPI=TraceAPI},7682:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.deleteBaggage=t.setBaggage=t.getActiveBaggage=t.getBaggage=void 0;const r=a(7171);const i=a(8242);const n=(0,i.createContextKey)("OpenTelemetry Baggage Key");function getBaggage(e){return e.getValue(n)||undefined}t.getBaggage=getBaggage;function getActiveBaggage(){return getBaggage(r.ContextAPI.getInstance().active())}t.getActiveBaggage=getActiveBaggage;function setBaggage(e,t){return e.setValue(n,t)}t.setBaggage=setBaggage;function deleteBaggage(e){return e.deleteValue(n)}t.deleteBaggage=deleteBaggage},4811:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.BaggageImpl=void 0;class BaggageImpl{constructor(e){this._entries=e?new Map(e):new Map}getEntry(e){const t=this._entries.get(e);if(!t){return undefined}return Object.assign({},t)}getAllEntries(){return Array.from(this._entries.entries()).map((([e,t])=>[e,t]))}setEntry(e,t){const a=new BaggageImpl(this._entries);a._entries.set(e,t);return a}removeEntry(e){const t=new BaggageImpl(this._entries);t._entries.delete(e);return t}removeEntries(...e){const t=new BaggageImpl(this._entries);for(const a of e){t._entries.delete(a)}return t}clear(){return new BaggageImpl}}t.BaggageImpl=BaggageImpl},3542:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.baggageEntryMetadataSymbol=void 0;t.baggageEntryMetadataSymbol=Symbol("BaggageEntryMetadata")},8136:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.baggageEntryMetadataFromString=t.createBaggage=void 0;const r=a(1877);const i=a(4811);const n=a(3542);const s=r.DiagAPI.instance();function createBaggage(e={}){return new i.BaggageImpl(new Map(Object.entries(e)))}t.createBaggage=createBaggage;function baggageEntryMetadataFromString(e){if(typeof e!=="string"){s.error(`Cannot create baggage metadata from unknown type: ${typeof e}`);e=""}return{__TYPE__:n.baggageEntryMetadataSymbol,toString(){return e}}}t.baggageEntryMetadataFromString=baggageEntryMetadataFromString},7393:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.context=void 0;const r=a(7171);t.context=r.ContextAPI.getInstance()},4118:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopContextManager=void 0;const r=a(8242);class NoopContextManager{active(){return r.ROOT_CONTEXT}with(e,t,a,...r){return t.call(a,...r)}bind(e,t){return t}enable(){return this}disable(){return this}}t.NoopContextManager=NoopContextManager},8242:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ROOT_CONTEXT=t.createContextKey=void 0;function createContextKey(e){return Symbol.for(e)}t.createContextKey=createContextKey;class BaseContext{constructor(e){const t=this;t._currentContext=e?new Map(e):new Map;t.getValue=e=>t._currentContext.get(e);t.setValue=(e,a)=>{const r=new BaseContext(t._currentContext);r._currentContext.set(e,a);return r};t.deleteValue=e=>{const a=new BaseContext(t._currentContext);a._currentContext.delete(e);return a}}}t.ROOT_CONTEXT=new BaseContext},9721:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.diag=void 0;const r=a(1877);t.diag=r.DiagAPI.instance()},7978:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagComponentLogger=void 0;const r=a(5135);class DiagComponentLogger{constructor(e){this._namespace=e.namespace||"DiagComponentLogger"}debug(...e){return logProxy("debug",this._namespace,e)}error(...e){return logProxy("error",this._namespace,e)}info(...e){return logProxy("info",this._namespace,e)}warn(...e){return logProxy("warn",this._namespace,e)}verbose(...e){return logProxy("verbose",this._namespace,e)}}t.DiagComponentLogger=DiagComponentLogger;function logProxy(e,t,a){const i=(0,r.getGlobal)("diag");if(!i){return}a.unshift(t);return i[e](...a)}},3041:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagConsoleLogger=void 0;const a=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}];class DiagConsoleLogger{constructor(){function _consoleFunc(e){return function(...t){if(console){let a=console[e];if(typeof a!=="function"){a=console.log}if(typeof a==="function"){return a.apply(console,t)}}}}for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createLogLevelDiagLogger=void 0;const r=a(8077);function createLogLevelDiagLogger(e,t){if(er.DiagLogLevel.ALL){e=r.DiagLogLevel.ALL}t=t||{};function _filterFunc(a,r){const i=t[a];if(typeof i==="function"&&e>=r){return i.bind(t)}return function(){}}return{error:_filterFunc("error",r.DiagLogLevel.ERROR),warn:_filterFunc("warn",r.DiagLogLevel.WARN),info:_filterFunc("info",r.DiagLogLevel.INFO),debug:_filterFunc("debug",r.DiagLogLevel.DEBUG),verbose:_filterFunc("verbose",r.DiagLogLevel.VERBOSE)}}t.createLogLevelDiagLogger=createLogLevelDiagLogger},8077:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagLogLevel=void 0;var a;(function(e){e[e["NONE"]=0]="NONE";e[e["ERROR"]=30]="ERROR";e[e["WARN"]=50]="WARN";e[e["INFO"]=60]="INFO";e[e["DEBUG"]=70]="DEBUG";e[e["VERBOSE"]=80]="VERBOSE";e[e["ALL"]=9999]="ALL"})(a=t.DiagLogLevel||(t.DiagLogLevel={}))},5163:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.trace=t.propagation=t.metrics=t.diag=t.context=t.INVALID_SPAN_CONTEXT=t.INVALID_TRACEID=t.INVALID_SPANID=t.isValidSpanId=t.isValidTraceId=t.isSpanContextValid=t.createTraceState=t.TraceFlags=t.SpanStatusCode=t.SpanKind=t.SamplingDecision=t.ProxyTracerProvider=t.ProxyTracer=t.defaultTextMapSetter=t.defaultTextMapGetter=t.ValueType=t.createNoopMeter=t.DiagLogLevel=t.DiagConsoleLogger=t.ROOT_CONTEXT=t.createContextKey=t.baggageEntryMetadataFromString=void 0;var r=a(8136);Object.defineProperty(t,"baggageEntryMetadataFromString",{enumerable:true,get:function(){return r.baggageEntryMetadataFromString}});var i=a(8242);Object.defineProperty(t,"createContextKey",{enumerable:true,get:function(){return i.createContextKey}});Object.defineProperty(t,"ROOT_CONTEXT",{enumerable:true,get:function(){return i.ROOT_CONTEXT}});var n=a(3041);Object.defineProperty(t,"DiagConsoleLogger",{enumerable:true,get:function(){return n.DiagConsoleLogger}});var s=a(8077);Object.defineProperty(t,"DiagLogLevel",{enumerable:true,get:function(){return s.DiagLogLevel}});var o=a(4837);Object.defineProperty(t,"createNoopMeter",{enumerable:true,get:function(){return o.createNoopMeter}});var p=a(9999);Object.defineProperty(t,"ValueType",{enumerable:true,get:function(){return p.ValueType}});var l=a(865);Object.defineProperty(t,"defaultTextMapGetter",{enumerable:true,get:function(){return l.defaultTextMapGetter}});Object.defineProperty(t,"defaultTextMapSetter",{enumerable:true,get:function(){return l.defaultTextMapSetter}});var d=a(3503);Object.defineProperty(t,"ProxyTracer",{enumerable:true,get:function(){return d.ProxyTracer}});var c=a(2285);Object.defineProperty(t,"ProxyTracerProvider",{enumerable:true,get:function(){return c.ProxyTracerProvider}});var m=a(3209);Object.defineProperty(t,"SamplingDecision",{enumerable:true,get:function(){return m.SamplingDecision}});var u=a(1424);Object.defineProperty(t,"SpanKind",{enumerable:true,get:function(){return u.SpanKind}});var h=a(8845);Object.defineProperty(t,"SpanStatusCode",{enumerable:true,get:function(){return h.SpanStatusCode}});var g=a(6905);Object.defineProperty(t,"TraceFlags",{enumerable:true,get:function(){return g.TraceFlags}});var y=a(2615);Object.defineProperty(t,"createTraceState",{enumerable:true,get:function(){return y.createTraceState}});var v=a(9745);Object.defineProperty(t,"isSpanContextValid",{enumerable:true,get:function(){return v.isSpanContextValid}});Object.defineProperty(t,"isValidTraceId",{enumerable:true,get:function(){return v.isValidTraceId}});Object.defineProperty(t,"isValidSpanId",{enumerable:true,get:function(){return v.isValidSpanId}});var b=a(1760);Object.defineProperty(t,"INVALID_SPANID",{enumerable:true,get:function(){return b.INVALID_SPANID}});Object.defineProperty(t,"INVALID_TRACEID",{enumerable:true,get:function(){return b.INVALID_TRACEID}});Object.defineProperty(t,"INVALID_SPAN_CONTEXT",{enumerable:true,get:function(){return b.INVALID_SPAN_CONTEXT}});const x=a(7393);Object.defineProperty(t,"context",{enumerable:true,get:function(){return x.context}});const w=a(9721);Object.defineProperty(t,"diag",{enumerable:true,get:function(){return w.diag}});const S=a(2601);Object.defineProperty(t,"metrics",{enumerable:true,get:function(){return S.metrics}});const N=a(7591);Object.defineProperty(t,"propagation",{enumerable:true,get:function(){return N.propagation}});const T=a(8989);Object.defineProperty(t,"trace",{enumerable:true,get:function(){return T.trace}});t["default"]={context:x.context,diag:w.diag,metrics:S.metrics,propagation:N.propagation,trace:T.trace}},5135:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.unregisterGlobal=t.getGlobal=t.registerGlobal=void 0;const r=a(9957);const i=a(8996);const n=a(1522);const s=i.VERSION.split(".")[0];const o=Symbol.for(`opentelemetry.js.api.${s}`);const p=r._globalThis;function registerGlobal(e,t,a,r=false){var n;const s=p[o]=(n=p[o])!==null&&n!==void 0?n:{version:i.VERSION};if(!r&&s[e]){const t=new Error(`@opentelemetry/api: Attempted duplicate registration of API: ${e}`);a.error(t.stack||t.message);return false}if(s.version!==i.VERSION){const t=new Error(`@opentelemetry/api: Registration of version v${s.version} for ${e} does not match previously registered API v${i.VERSION}`);a.error(t.stack||t.message);return false}s[e]=t;a.debug(`@opentelemetry/api: Registered a global for ${e} v${i.VERSION}.`);return true}t.registerGlobal=registerGlobal;function getGlobal(e){var t,a;const r=(t=p[o])===null||t===void 0?void 0:t.version;if(!r||!(0,n.isCompatible)(r)){return}return(a=p[o])===null||a===void 0?void 0:a[e]}t.getGlobal=getGlobal;function unregisterGlobal(e,t){t.debug(`@opentelemetry/api: Unregistering a global for ${e} v${i.VERSION}.`);const a=p[o];if(a){delete a[e]}}t.unregisterGlobal=unregisterGlobal},1522:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.isCompatible=t._makeCompatibilityCheck=void 0;const r=a(8996);const i=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;function _makeCompatibilityCheck(e){const t=new Set([e]);const a=new Set;const r=e.match(i);if(!r){return()=>false}const n={major:+r[1],minor:+r[2],patch:+r[3],prerelease:r[4]};if(n.prerelease!=null){return function isExactmatch(t){return t===e}}function _reject(e){a.add(e);return false}function _accept(e){t.add(e);return true}return function isCompatible(e){if(t.has(e)){return true}if(a.has(e)){return false}const r=e.match(i);if(!r){return _reject(e)}const s={major:+r[1],minor:+r[2],patch:+r[3],prerelease:r[4]};if(s.prerelease!=null){return _reject(e)}if(n.major!==s.major){return _reject(e)}if(n.major===0){if(n.minor===s.minor&&n.patch<=s.patch){return _accept(e)}return _reject(e)}if(n.minor<=s.minor){return _accept(e)}return _reject(e)}}t._makeCompatibilityCheck=_makeCompatibilityCheck;t.isCompatible=_makeCompatibilityCheck(r.VERSION)},2601:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.metrics=void 0;const r=a(7696);t.metrics=r.MetricsAPI.getInstance()},9999:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ValueType=void 0;var a;(function(e){e[e["INT"]=0]="INT";e[e["DOUBLE"]=1]="DOUBLE"})(a=t.ValueType||(t.ValueType={}))},4837:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createNoopMeter=t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC=t.NOOP_OBSERVABLE_GAUGE_METRIC=t.NOOP_OBSERVABLE_COUNTER_METRIC=t.NOOP_UP_DOWN_COUNTER_METRIC=t.NOOP_HISTOGRAM_METRIC=t.NOOP_COUNTER_METRIC=t.NOOP_METER=t.NoopObservableUpDownCounterMetric=t.NoopObservableGaugeMetric=t.NoopObservableCounterMetric=t.NoopObservableMetric=t.NoopHistogramMetric=t.NoopUpDownCounterMetric=t.NoopCounterMetric=t.NoopMetric=t.NoopMeter=void 0;class NoopMeter{constructor(){}createHistogram(e,a){return t.NOOP_HISTOGRAM_METRIC}createCounter(e,a){return t.NOOP_COUNTER_METRIC}createUpDownCounter(e,a){return t.NOOP_UP_DOWN_COUNTER_METRIC}createObservableGauge(e,a){return t.NOOP_OBSERVABLE_GAUGE_METRIC}createObservableCounter(e,a){return t.NOOP_OBSERVABLE_COUNTER_METRIC}createObservableUpDownCounter(e,a){return t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC}addBatchObservableCallback(e,t){}removeBatchObservableCallback(e){}}t.NoopMeter=NoopMeter;class NoopMetric{}t.NoopMetric=NoopMetric;class NoopCounterMetric extends NoopMetric{add(e,t){}}t.NoopCounterMetric=NoopCounterMetric;class NoopUpDownCounterMetric extends NoopMetric{add(e,t){}}t.NoopUpDownCounterMetric=NoopUpDownCounterMetric;class NoopHistogramMetric extends NoopMetric{record(e,t){}}t.NoopHistogramMetric=NoopHistogramMetric;class NoopObservableMetric{addCallback(e){}removeCallback(e){}}t.NoopObservableMetric=NoopObservableMetric;class NoopObservableCounterMetric extends NoopObservableMetric{}t.NoopObservableCounterMetric=NoopObservableCounterMetric;class NoopObservableGaugeMetric extends NoopObservableMetric{}t.NoopObservableGaugeMetric=NoopObservableGaugeMetric;class NoopObservableUpDownCounterMetric extends NoopObservableMetric{}t.NoopObservableUpDownCounterMetric=NoopObservableUpDownCounterMetric;t.NOOP_METER=new NoopMeter;t.NOOP_COUNTER_METRIC=new NoopCounterMetric;t.NOOP_HISTOGRAM_METRIC=new NoopHistogramMetric;t.NOOP_UP_DOWN_COUNTER_METRIC=new NoopUpDownCounterMetric;t.NOOP_OBSERVABLE_COUNTER_METRIC=new NoopObservableCounterMetric;t.NOOP_OBSERVABLE_GAUGE_METRIC=new NoopObservableGaugeMetric;t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC=new NoopObservableUpDownCounterMetric;function createNoopMeter(){return t.NOOP_METER}t.createNoopMeter=createNoopMeter},2647:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NOOP_METER_PROVIDER=t.NoopMeterProvider=void 0;const r=a(4837);class NoopMeterProvider{getMeter(e,t,a){return r.NOOP_METER}}t.NoopMeterProvider=NoopMeterProvider;t.NOOP_METER_PROVIDER=new NoopMeterProvider},9957:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__exportStar||function(e,t){for(var a in e)if(a!=="default"&&!Object.prototype.hasOwnProperty.call(t,a))r(t,e,a)};Object.defineProperty(t,"__esModule",{value:true});i(a(7200),t)},9406:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t._globalThis=void 0;t._globalThis=typeof globalThis==="object"?globalThis:global},7200:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__exportStar||function(e,t){for(var a in e)if(a!=="default"&&!Object.prototype.hasOwnProperty.call(t,a))r(t,e,a)};Object.defineProperty(t,"__esModule",{value:true});i(a(9406),t)},7591:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.propagation=void 0;const r=a(9909);t.propagation=r.PropagationAPI.getInstance()},2368:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTextMapPropagator=void 0;class NoopTextMapPropagator{inject(e,t){}extract(e,t){return e}fields(){return[]}}t.NoopTextMapPropagator=NoopTextMapPropagator},865:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.defaultTextMapSetter=t.defaultTextMapGetter=void 0;t.defaultTextMapGetter={get(e,t){if(e==null){return undefined}return e[t]},keys(e){if(e==null){return[]}return Object.keys(e)}};t.defaultTextMapSetter={set(e,t,a){if(e==null){return}e[t]=a}}},8989:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.trace=void 0;const r=a(1539);t.trace=r.TraceAPI.getInstance()},1462:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NonRecordingSpan=void 0;const r=a(1760);class NonRecordingSpan{constructor(e=r.INVALID_SPAN_CONTEXT){this._spanContext=e}spanContext(){return this._spanContext}setAttribute(e,t){return this}setAttributes(e){return this}addEvent(e,t){return this}setStatus(e){return this}updateName(e){return this}end(e){}isRecording(){return false}recordException(e,t,a){}}t.NonRecordingSpan=NonRecordingSpan},7606:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTracer=void 0;const r=a(7171);const i=a(3326);const n=a(1462);const s=a(9745);const o=r.ContextAPI.getInstance();class NoopTracer{startSpan(e,t,a=o.active()){const r=Boolean(t===null||t===void 0?void 0:t.root);if(r){return new n.NonRecordingSpan}const p=a&&(0,i.getSpanContext)(a);if(isSpanContext(p)&&(0,s.isSpanContextValid)(p)){return new n.NonRecordingSpan(p)}else{return new n.NonRecordingSpan}}startActiveSpan(e,t,a,r){let n;let s;let p;if(arguments.length<2){return}else if(arguments.length===2){p=t}else if(arguments.length===3){n=t;p=a}else{n=t;s=a;p=r}const l=s!==null&&s!==void 0?s:o.active();const d=this.startSpan(e,n,l);const c=(0,i.setSpan)(l,d);return o.with(c,p,undefined,d)}}t.NoopTracer=NoopTracer;function isSpanContext(e){return typeof e==="object"&&typeof e["spanId"]==="string"&&typeof e["traceId"]==="string"&&typeof e["traceFlags"]==="number"}},3259:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTracerProvider=void 0;const r=a(7606);class NoopTracerProvider{getTracer(e,t,a){return new r.NoopTracer}}t.NoopTracerProvider=NoopTracerProvider},3503:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ProxyTracer=void 0;const r=a(7606);const i=new r.NoopTracer;class ProxyTracer{constructor(e,t,a,r){this._provider=e;this.name=t;this.version=a;this.options=r}startSpan(e,t,a){return this._getTracer().startSpan(e,t,a)}startActiveSpan(e,t,a,r){const i=this._getTracer();return Reflect.apply(i.startActiveSpan,i,arguments)}_getTracer(){if(this._delegate){return this._delegate}const e=this._provider.getDelegateTracer(this.name,this.version,this.options);if(!e){return i}this._delegate=e;return this._delegate}}t.ProxyTracer=ProxyTracer},2285:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ProxyTracerProvider=void 0;const r=a(3503);const i=a(3259);const n=new i.NoopTracerProvider;class ProxyTracerProvider{getTracer(e,t,a){var i;return(i=this.getDelegateTracer(e,t,a))!==null&&i!==void 0?i:new r.ProxyTracer(this,e,t,a)}getDelegate(){var e;return(e=this._delegate)!==null&&e!==void 0?e:n}setDelegate(e){this._delegate=e}getDelegateTracer(e,t,a){var r;return(r=this._delegate)===null||r===void 0?void 0:r.getTracer(e,t,a)}}t.ProxyTracerProvider=ProxyTracerProvider},3209:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SamplingDecision=void 0;var a;(function(e){e[e["NOT_RECORD"]=0]="NOT_RECORD";e[e["RECORD"]=1]="RECORD";e[e["RECORD_AND_SAMPLED"]=2]="RECORD_AND_SAMPLED"})(a=t.SamplingDecision||(t.SamplingDecision={}))},3326:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getSpanContext=t.setSpanContext=t.deleteSpan=t.setSpan=t.getActiveSpan=t.getSpan=void 0;const r=a(8242);const i=a(1462);const n=a(7171);const s=(0,r.createContextKey)("OpenTelemetry Context Key SPAN");function getSpan(e){return e.getValue(s)||undefined}t.getSpan=getSpan;function getActiveSpan(){return getSpan(n.ContextAPI.getInstance().active())}t.getActiveSpan=getActiveSpan;function setSpan(e,t){return e.setValue(s,t)}t.setSpan=setSpan;function deleteSpan(e){return e.deleteValue(s)}t.deleteSpan=deleteSpan;function setSpanContext(e,t){return setSpan(e,new i.NonRecordingSpan(t))}t.setSpanContext=setSpanContext;function getSpanContext(e){var t;return(t=getSpan(e))===null||t===void 0?void 0:t.spanContext()}t.getSpanContext=getSpanContext},2110:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceStateImpl=void 0;const r=a(4864);const i=32;const n=512;const s=",";const o="=";class TraceStateImpl{constructor(e){this._internalState=new Map;if(e)this._parse(e)}set(e,t){const a=this._clone();if(a._internalState.has(e)){a._internalState.delete(e)}a._internalState.set(e,t);return a}unset(e){const t=this._clone();t._internalState.delete(e);return t}get(e){return this._internalState.get(e)}serialize(){return this._keys().reduce(((e,t)=>{e.push(t+o+this.get(t));return e}),[]).join(s)}_parse(e){if(e.length>n)return;this._internalState=e.split(s).reverse().reduce(((e,t)=>{const a=t.trim();const i=a.indexOf(o);if(i!==-1){const n=a.slice(0,i);const s=a.slice(i+1,t.length);if((0,r.validateKey)(n)&&(0,r.validateValue)(s)){e.set(n,s)}else{}}return e}),new Map);if(this._internalState.size>i){this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,i))}}_keys(){return Array.from(this._internalState.keys()).reverse()}_clone(){const e=new TraceStateImpl;e._internalState=new Map(this._internalState);return e}}t.TraceStateImpl=TraceStateImpl},4864:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.validateValue=t.validateKey=void 0;const a="[_0-9a-z-*/]";const r=`[a-z]${a}{0,255}`;const i=`[a-z0-9]${a}{0,240}@[a-z]${a}{0,13}`;const n=new RegExp(`^(?:${r}|${i})$`);const s=/^[ -~]{0,255}[!-~]$/;const o=/,|=/;function validateKey(e){return n.test(e)}t.validateKey=validateKey;function validateValue(e){return s.test(e)&&!o.test(e)}t.validateValue=validateValue},2615:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createTraceState=void 0;const r=a(2110);function createTraceState(e){return new r.TraceStateImpl(e)}t.createTraceState=createTraceState},1760:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.INVALID_SPAN_CONTEXT=t.INVALID_TRACEID=t.INVALID_SPANID=void 0;const r=a(6905);t.INVALID_SPANID="0000000000000000";t.INVALID_TRACEID="00000000000000000000000000000000";t.INVALID_SPAN_CONTEXT={traceId:t.INVALID_TRACEID,spanId:t.INVALID_SPANID,traceFlags:r.TraceFlags.NONE}},1424:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SpanKind=void 0;var a;(function(e){e[e["INTERNAL"]=0]="INTERNAL";e[e["SERVER"]=1]="SERVER";e[e["CLIENT"]=2]="CLIENT";e[e["PRODUCER"]=3]="PRODUCER";e[e["CONSUMER"]=4]="CONSUMER"})(a=t.SpanKind||(t.SpanKind={}))},9745:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.wrapSpanContext=t.isSpanContextValid=t.isValidSpanId=t.isValidTraceId=void 0;const r=a(1760);const i=a(1462);const n=/^([0-9a-f]{32})$/i;const s=/^[0-9a-f]{16}$/i;function isValidTraceId(e){return n.test(e)&&e!==r.INVALID_TRACEID}t.isValidTraceId=isValidTraceId;function isValidSpanId(e){return s.test(e)&&e!==r.INVALID_SPANID}t.isValidSpanId=isValidSpanId;function isSpanContextValid(e){return isValidTraceId(e.traceId)&&isValidSpanId(e.spanId)}t.isSpanContextValid=isSpanContextValid;function wrapSpanContext(e){return new i.NonRecordingSpan(e)}t.wrapSpanContext=wrapSpanContext},8845:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SpanStatusCode=void 0;var a;(function(e){e[e["UNSET"]=0]="UNSET";e[e["OK"]=1]="OK";e[e["ERROR"]=2]="ERROR"})(a=t.SpanStatusCode||(t.SpanStatusCode={}))},6905:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceFlags=void 0;var a;(function(e){e[e["NONE"]=0]="NONE";e[e["SAMPLED"]=1]="SAMPLED"})(a=t.TraceFlags||(t.TraceFlags={}))},8996:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.VERSION=void 0;t.VERSION="1.5.0"},4812:(e,t,a)=>{e.exports={parallel:a(8210),serial:a(445),serialOrdered:a(3578)}},1700:e=>{e.exports=abort;function abort(e){Object.keys(e.jobs).forEach(clean.bind(e));e.jobs={}}function clean(e){if(typeof this.jobs[e]=="function"){this.jobs[e]()}}},2794:(e,t,a)=>{var r=a(5295);e.exports=async;function async(e){var t=false;r((function(){t=true}));return function async_callback(a,i){if(t){e(a,i)}else{r((function nextTick_callback(){e(a,i)}))}}}},5295:e=>{e.exports=defer;function defer(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;if(t){t(e)}else{setTimeout(e,0)}}},9023:(e,t,a)=>{var r=a(2794),i=a(1700);e.exports=iterate;function iterate(e,t,a,r){var n=a["keyedList"]?a["keyedList"][a.index]:a.index;a.jobs[n]=runJob(t,n,e[n],(function(e,t){if(!(n in a.jobs)){return}delete a.jobs[n];if(e){i(a)}else{a.results[n]=t}r(e,a.results)}))}function runJob(e,t,a,i){var n;if(e.length==2){n=e(a,r(i))}else{n=e(a,t,r(i))}return n}},2474:e=>{e.exports=state;function state(e,t){var a=!Array.isArray(e),r={index:0,keyedList:a||t?Object.keys(e):null,jobs:{},results:a?{}:[],size:a?Object.keys(e).length:e.length};if(t){r.keyedList.sort(a?t:function(a,r){return t(e[a],e[r])})}return r}},7942:(e,t,a)=>{var r=a(1700),i=a(2794);e.exports=terminator;function terminator(e){if(!Object.keys(this.jobs).length){return}this.index=this.size;r(this);i(e)(null,this.results)}},8210:(e,t,a)=>{var r=a(9023),i=a(2474),n=a(7942);e.exports=parallel;function parallel(e,t,a){var s=i(e);while(s.index<(s["keyedList"]||e).length){r(e,t,s,(function(e,t){if(e){a(e,t);return}if(Object.keys(s.jobs).length===0){a(null,s.results);return}}));s.index++}return n.bind(s,a)}},445:(e,t,a)=>{var r=a(3578);e.exports=serial;function serial(e,t,a){return r(e,t,null,a)}},3578:(e,t,a)=>{var r=a(9023),i=a(2474),n=a(7942);e.exports=serialOrdered;e.exports.ascending=ascending;e.exports.descending=descending;function serialOrdered(e,t,a,s){var o=i(e,a);r(e,t,o,(function iteratorHandler(a,i){if(a){s(a,i);return}o.index++;if(o.index<(o["keyedList"]||e).length){r(e,t,o,iteratorHandler);return}s(null,o.results)}));return n.bind(o,s)}function ascending(e,t){return et?1:0}function descending(e,t){return-1*ascending(e,t)}},9417:e=>{"use strict";e.exports=balanced;function balanced(e,t,a){if(e instanceof RegExp)e=maybeMatch(e,a);if(t instanceof RegExp)t=maybeMatch(t,a);var r=range(e,t,a);return r&&{start:r[0],end:r[1],pre:a.slice(0,r[0]),body:a.slice(r[0]+e.length,r[1]),post:a.slice(r[1]+t.length)}}function maybeMatch(e,t){var a=t.match(e);return a?a[0]:null}balanced.range=range;function range(e,t,a){var r,i,n,s,o;var p=a.indexOf(e);var l=a.indexOf(t,p+1);var d=p;if(p>=0&&l>0){if(e===t){return[p,l]}r=[];n=a.length;while(d>=0&&!o){if(d==p){r.push(d);p=a.indexOf(e,d+1)}else if(r.length==1){o=[r.pop(),l]}else{i=r.pop();if(i=0?p:l}if(r.length){o=[n,s]}}return o}},3682:(e,t,a)=>{var r=a(4670);var i=a(5549);var n=a(6819);var s=Function.bind;var o=s.bind(s);function bindApi(e,t,a){var r=o(n,null).apply(null,a?[t,a]:[t]);e.api={remove:r};e.remove=r;["before","error","after","wrap"].forEach((function(r){var n=a?[t,r,a]:[t,r];e[r]=e.api[r]=o(i,null).apply(null,n)}))}function HookSingular(){var e="h";var t={registry:{}};var a=r.bind(null,t,e);bindApi(a,t,e);return a}function HookCollection(){var e={registry:{}};var t=r.bind(null,e);bindApi(t,e);return t}var p=false;function Hook(){if(!p){console.warn('[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4');p=true}return HookCollection()}Hook.Singular=HookSingular.bind();Hook.Collection=HookCollection.bind();e.exports=Hook;e.exports.Hook=Hook;e.exports.Singular=Hook.Singular;e.exports.Collection=Hook.Collection},5549:e=>{e.exports=addHook;function addHook(e,t,a,r){var i=r;if(!e.registry[a]){e.registry[a]=[]}if(t==="before"){r=function(e,t){return Promise.resolve().then(i.bind(null,t)).then(e.bind(null,t))}}if(t==="after"){r=function(e,t){var a;return Promise.resolve().then(e.bind(null,t)).then((function(e){a=e;return i(a,t)})).then((function(){return a}))}}if(t==="error"){r=function(e,t){return Promise.resolve().then(e.bind(null,t)).catch((function(e){return i(e,t)}))}}e.registry[a].push({hook:r,orig:i})}},4670:e=>{e.exports=register;function register(e,t,a,r){if(typeof a!=="function"){throw new Error("method for before hook must be a function")}if(!r){r={}}if(Array.isArray(t)){return t.reverse().reduce((function(t,a){return register.bind(null,e,a,t,r)}),a)()}return Promise.resolve().then((function(){if(!e.registry[t]){return a(r)}return e.registry[t].reduce((function(e,t){return t.hook.bind(null,e,r)}),a)()}))}},6819:e=>{e.exports=removeHook;function removeHook(e,t,a){if(!e.registry[t]){return}var r=e.registry[t].map((function(e){return e.orig})).indexOf(a);if(r===-1){return}e.registry[t].splice(r,1)}},3717:(e,t,a)=>{var r=a(6891);var i=a(9417);e.exports=expandTop;var n="\0SLASH"+Math.random()+"\0";var s="\0OPEN"+Math.random()+"\0";var o="\0CLOSE"+Math.random()+"\0";var p="\0COMMA"+Math.random()+"\0";var l="\0PERIOD"+Math.random()+"\0";function numeric(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function escapeBraces(e){return e.split("\\\\").join(n).split("\\{").join(s).split("\\}").join(o).split("\\,").join(p).split("\\.").join(l)}function unescapeBraces(e){return e.split(n).join("\\").split(s).join("{").split(o).join("}").split(p).join(",").split(l).join(".")}function parseCommaParts(e){if(!e)return[""];var t=[];var a=i("{","}",e);if(!a)return e.split(",");var r=a.pre;var n=a.body;var s=a.post;var o=r.split(",");o[o.length-1]+="{"+n+"}";var p=parseCommaParts(s);if(s.length){o[o.length-1]+=p.shift();o.push.apply(o,p)}t.push.apply(t,o);return t}function expandTop(e){if(!e)return[];if(e.substr(0,2)==="{}"){e="\\{\\}"+e.substr(2)}return expand(escapeBraces(e),true).map(unescapeBraces)}function identity(e){return e}function embrace(e){return"{"+e+"}"}function isPadded(e){return/^-?0\d/.test(e)}function lte(e,t){return e<=t}function gte(e,t){return e>=t}function expand(e,t){var a=[];var n=i("{","}",e);if(!n||/\$$/.test(n.pre))return[e];var s=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(n.body);var p=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(n.body);var l=s||p;var d=n.body.indexOf(",")>=0;if(!l&&!d){if(n.post.match(/,.*\}/)){e=n.pre+"{"+n.body+o+n.post;return expand(e)}return[e]}var c;if(l){c=n.body.split(/\.\./)}else{c=parseCommaParts(n.body);if(c.length===1){c=expand(c[0],false).map(embrace);if(c.length===1){var m=n.post.length?expand(n.post,false):[""];return m.map((function(e){return n.pre+c[0]+e}))}}}var u=n.pre;var m=n.post.length?expand(n.post,false):[""];var h;if(l){var g=numeric(c[0]);var y=numeric(c[1]);var v=Math.max(c[0].length,c[1].length);var b=c.length==3?Math.abs(numeric(c[2])):1;var x=lte;var w=y0){var _=new Array(E+1).join("0");if(N<0)T="-"+_+T.slice(1);else T=_+T}}}h.push(T)}}else{h=r(c,(function(e){return expand(e,false)}))}for(var P=0;P{var r=a(3837);var i=a(2781).Stream;var n=a(8611);e.exports=CombinedStream;function CombinedStream(){this.writable=false;this.readable=true;this.dataSize=0;this.maxDataSize=2*1024*1024;this.pauseStreams=true;this._released=false;this._streams=[];this._currentStream=null;this._insideLoop=false;this._pendingNext=false}r.inherits(CombinedStream,i);CombinedStream.create=function(e){var t=new this;e=e||{};for(var a in e){t[a]=e[a]}return t};CombinedStream.isStreamLike=function(e){return typeof e!=="function"&&typeof e!=="string"&&typeof e!=="boolean"&&typeof e!=="number"&&!Buffer.isBuffer(e)};CombinedStream.prototype.append=function(e){var t=CombinedStream.isStreamLike(e);if(t){if(!(e instanceof n)){var a=n.create(e,{maxDataSize:Infinity,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this));e=a}this._handleErrors(e);if(this.pauseStreams){e.pause()}}this._streams.push(e);return this};CombinedStream.prototype.pipe=function(e,t){i.prototype.pipe.call(this,e,t);this.resume();return e};CombinedStream.prototype._getNext=function(){this._currentStream=null;if(this._insideLoop){this._pendingNext=true;return}this._insideLoop=true;try{do{this._pendingNext=false;this._realGetNext()}while(this._pendingNext)}finally{this._insideLoop=false}};CombinedStream.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e=="undefined"){this.end();return}if(typeof e!=="function"){this._pipeNext(e);return}var t=e;t(function(e){var t=CombinedStream.isStreamLike(e);if(t){e.on("data",this._checkDataSize.bind(this));this._handleErrors(e)}this._pipeNext(e)}.bind(this))};CombinedStream.prototype._pipeNext=function(e){this._currentStream=e;var t=CombinedStream.isStreamLike(e);if(t){e.on("end",this._getNext.bind(this));e.pipe(this,{end:false});return}var a=e;this.write(a);this._getNext()};CombinedStream.prototype._handleErrors=function(e){var t=this;e.on("error",(function(e){t._emitError(e)}))};CombinedStream.prototype.write=function(e){this.emit("data",e)};CombinedStream.prototype.pause=function(){if(!this.pauseStreams){return}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function")this._currentStream.pause();this.emit("pause")};CombinedStream.prototype.resume=function(){if(!this._released){this._released=true;this.writable=true;this._getNext()}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function")this._currentStream.resume();this.emit("resume")};CombinedStream.prototype.end=function(){this._reset();this.emit("end")};CombinedStream.prototype.destroy=function(){this._reset();this.emit("close")};CombinedStream.prototype._reset=function(){this.writable=false;this._streams=[];this._currentStream=null};CombinedStream.prototype._checkDataSize=function(){this._updateDataSize();if(this.dataSize<=this.maxDataSize){return}var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))};CombinedStream.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach((function(t){if(!t.dataSize){return}e.dataSize+=t.dataSize}));if(this._currentStream&&this._currentStream.dataSize){this.dataSize+=this._currentStream.dataSize}};CombinedStream.prototype._emitError=function(e){this._reset();this.emit("error",e)}},6891:e=>{e.exports=function(e,a){var r=[];for(var i=0;i{var r=a(2781).Stream;var i=a(3837);e.exports=DelayedStream;function DelayedStream(){this.source=null;this.dataSize=0;this.maxDataSize=1024*1024;this.pauseStream=true;this._maxDataSizeExceeded=false;this._released=false;this._bufferedEvents=[]}i.inherits(DelayedStream,r);DelayedStream.create=function(e,t){var a=new this;t=t||{};for(var r in t){a[r]=t[r]}a.source=e;var i=e.emit;e.emit=function(){a._handleEmit(arguments);return i.apply(e,arguments)};e.on("error",(function(){}));if(a.pauseStream){e.pause()}return a};Object.defineProperty(DelayedStream.prototype,"readable",{configurable:true,enumerable:true,get:function(){return this.source.readable}});DelayedStream.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};DelayedStream.prototype.resume=function(){if(!this._released){this.release()}this.source.resume()};DelayedStream.prototype.pause=function(){this.source.pause()};DelayedStream.prototype.release=function(){this._released=true;this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this));this._bufferedEvents=[]};DelayedStream.prototype.pipe=function(){var e=r.prototype.pipe.apply(this,arguments);this.resume();return e};DelayedStream.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}if(e[0]==="data"){this.dataSize+=e[1].length;this._checkIfMaxDataSizeExceeded()}this._bufferedEvents.push(e)};DelayedStream.prototype._checkIfMaxDataSizeExceeded=function(){if(this._maxDataSizeExceeded){return}if(this.dataSize<=this.maxDataSize){return}this._maxDataSizeExceeded=true;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}},8932:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});class Deprecation extends Error{constructor(e){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="Deprecation"}}t.Deprecation=Deprecation},3287:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true}); +(()=>{var __webpack_modules__={3782:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.deduplicate=t.pleaseRestore=t.pleaseSave=void 0;const o=a(7799);const p=n(a(2186));const l=n(a(5438));const d="sccache";const pleaseSave=()=>s(void 0,void 0,void 0,(function*(){const e=process.env.SCCACHE_CACHE_DIR;console.log(e);if(!e){console.log(`no sccache dir found in SCCACHE_CACHE_DIR ${e}`);return}yield(0,o.saveCache)([e],d)}));t.pleaseSave=pleaseSave;const pleaseRestore=()=>s(void 0,void 0,void 0,(function*(){console.log("restore sccache files");const e=process.env.SCCACHE_CACHE_DIR;console.log(e);if(!e){console.log(`no sccache dir found in SCCACHE_CACHE_DIR ${e}`);return}yield(0,o.restoreCache)([e],d).then((t=>{if(!t){console.log(`no cache matching "${e}" to restore`)}}))}));t.pleaseRestore=pleaseRestore;const deduplicate=()=>s(void 0,void 0,void 0,(function*(){console.log("trying to deduplicate cache");const e=p.getInput("token",{required:true});const t=l.getOctokit(e);const a=yield t.rest.actions.deleteActionsCacheByKey({owner:l.context.repo.owner,repo:l.context.repo.repo,key:d}).then((()=>"successfully deleted cache")).catch((e=>{console.log(`catch: ${e}`);return"nothing to delete"}));console.log(`delete cache api response: ${a}`)}));t.deduplicate=deduplicate},6735:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});const o=n(a(2186));const p=a(3782);const l=a(2802);const postRun=()=>s(void 0,void 0,void 0,(function*(){yield(0,l.show_stats)();const e=o.getInput("local",{required:false});if(e=="true"){yield(0,p.deduplicate)();yield(0,p.pleaseSave)()}}));postRun().catch((e=>{o.error(e);o.setFailed(e.message)}))},2802:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.show_stats=void 0;const o=n(a(2186));const p=n(a(1514));function show_stats(){return s(this,void 0,void 0,(function*(){o.debug("show stats");const e={stdout:e=>{t.push(e.toString())}};const t=[];yield p.getExecOutput(`${process.env.SCCACHE_PATH}`,["--show-stats"],{listeners:e})}))}t.show_stats=show_stats},7799:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.saveCache=t.restoreCache=t.isFeatureAvailable=t.ReserveCacheError=t.ValidationError=void 0;const o=n(a(2186));const p=n(a(1017));const l=n(a(1518));const d=n(a(8245));const c=a(6490);class ValidationError extends Error{constructor(e){super(e);this.name="ValidationError";Object.setPrototypeOf(this,ValidationError.prototype)}}t.ValidationError=ValidationError;class ReserveCacheError extends Error{constructor(e){super(e);this.name="ReserveCacheError";Object.setPrototypeOf(this,ReserveCacheError.prototype)}}t.ReserveCacheError=ReserveCacheError;function checkPaths(e){if(!e||e.length===0){throw new ValidationError(`Path Validation Error: At least one directory or file path is required`)}}function checkKey(e){if(e.length>512){throw new ValidationError(`Key Validation Error: ${e} cannot be larger than 512 characters.`)}const t=/^[^,]*$/;if(!t.test(e)){throw new ValidationError(`Key Validation Error: ${e} cannot contain commas.`)}}function isFeatureAvailable(){return!!process.env["ACTIONS_CACHE_URL"]}t.isFeatureAvailable=isFeatureAvailable;function restoreCache(e,t,a,r,i=false){return s(this,void 0,void 0,(function*(){checkPaths(e);a=a||[];const n=[t,...a];o.debug("Resolved Keys:");o.debug(JSON.stringify(n));if(n.length>10){throw new ValidationError(`Key Validation Error: Keys are limited to a maximum of 10.`)}for(const e of n){checkKey(e)}const s=yield l.getCompressionMethod();let m="";try{const t=yield d.getCacheEntry(n,e,{compressionMethod:s,enableCrossOsArchive:i});if(!(t===null||t===void 0?void 0:t.archiveLocation)){return undefined}if(r===null||r===void 0?void 0:r.lookupOnly){o.info("Lookup only - skipping download");return t.cacheKey}m=p.join(yield l.createTempDirectory(),l.getCacheFileName(s));o.debug(`Archive Path: ${m}`);yield d.downloadCache(t.archiveLocation,m,r);if(o.isDebug()){yield(0,c.listTar)(m,s)}const a=l.getArchiveFileSizeInBytes(m);o.info(`Cache Size: ~${Math.round(a/(1024*1024))} MB (${a} B)`);yield(0,c.extractTar)(m,s);o.info("Cache restored successfully");return t.cacheKey}catch(e){const t=e;if(t.name===ValidationError.name){throw e}else{o.warning(`Failed to restore: ${e.message}`)}}finally{try{yield l.unlinkFile(m)}catch(e){o.debug(`Failed to delete archive: ${e}`)}}return undefined}))}t.restoreCache=restoreCache;function saveCache(e,t,a,r=false){var i,n,m,u,h;return s(this,void 0,void 0,(function*(){checkPaths(e);checkKey(t);const s=yield l.getCompressionMethod();let g=-1;const y=yield l.resolvePaths(e);o.debug("Cache Paths:");o.debug(`${JSON.stringify(y)}`);if(y.length===0){throw new Error(`Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved.`)}const v=yield l.createTempDirectory();const b=p.join(v,l.getCacheFileName(s));o.debug(`Archive Path: ${b}`);try{yield(0,c.createTar)(v,y,s);if(o.isDebug()){yield(0,c.listTar)(b,s)}const p=10*1024*1024*1024;const x=l.getArchiveFileSizeInBytes(b);o.debug(`File Size: ${x}`);if(x>p&&!l.isGhes()){throw new Error(`Cache size of ~${Math.round(x/(1024*1024))} MB (${x} B) is over the 10GB limit, not saving cache.`)}o.debug("Reserving Cache");const w=yield d.reserveCache(t,e,{compressionMethod:s,enableCrossOsArchive:r,cacheSize:x});if((i=w===null||w===void 0?void 0:w.result)===null||i===void 0?void 0:i.cacheId){g=(n=w===null||w===void 0?void 0:w.result)===null||n===void 0?void 0:n.cacheId}else if((w===null||w===void 0?void 0:w.statusCode)===400){throw new Error((u=(m=w===null||w===void 0?void 0:w.error)===null||m===void 0?void 0:m.message)!==null&&u!==void 0?u:`Cache size of ~${Math.round(x/(1024*1024))} MB (${x} B) is over the data cap limit, not saving cache.`)}else{throw new ReserveCacheError(`Unable to reserve cache with key ${t}, another job may be creating this cache. More details: ${(h=w===null||w===void 0?void 0:w.error)===null||h===void 0?void 0:h.message}`)}o.debug(`Saving Cache (ID: ${g})`);yield d.saveCache(g,b,a)}catch(e){const t=e;if(t.name===ValidationError.name){throw e}else if(t.name===ReserveCacheError.name){o.info(`Failed to save: ${t.message}`)}else{o.warning(`Failed to save: ${t.message}`)}}finally{try{yield l.unlinkFile(b)}catch(e){o.debug(`Failed to delete archive: ${e}`)}}return g}))}t.saveCache=saveCache},8245:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.saveCache=t.reserveCache=t.downloadCache=t.getCacheEntry=t.getCacheVersion=void 0;const o=n(a(2186));const p=a(6255);const l=a(5526);const d=n(a(6113));const c=n(a(7147));const m=a(7310);const u=n(a(1518));const h=a(5500);const g=a(6215);const y=a(3981);const v="1.0";function getCacheApiUrl(e){const t=process.env["ACTIONS_CACHE_URL"]||"";if(!t){throw new Error("Cache Service Url not found, unable to restore cache.")}const a=`${t}_apis/artifactcache/${e}`;o.debug(`Resource Url: ${a}`);return a}function createAcceptHeader(e,t){return`${e};api-version=${t}`}function getRequestOptions(){const e={headers:{Accept:createAcceptHeader("application/json","6.0-preview.1")}};return e}function createHttpClient(){const e=process.env["ACTIONS_RUNTIME_TOKEN"]||"";const t=new l.BearerCredentialHandler(e);return new p.HttpClient("actions/cache",[t],getRequestOptions())}function getCacheVersion(e,t,a=false){const r=e;if(t){r.push(t)}if(process.platform==="win32"&&!a){r.push("windows-only")}r.push(v);return d.createHash("sha256").update(r.join("|")).digest("hex")}t.getCacheVersion=getCacheVersion;function getCacheEntry(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();const i=getCacheVersion(t,a===null||a===void 0?void 0:a.compressionMethod,a===null||a===void 0?void 0:a.enableCrossOsArchive);const n=`cache?keys=${encodeURIComponent(e.join(","))}&version=${i}`;const p=yield(0,y.retryTypedResponse)("getCacheEntry",(()=>s(this,void 0,void 0,(function*(){return r.getJson(getCacheApiUrl(n))}))));if(p.statusCode===204){if(o.isDebug()){yield printCachesListForDiagnostics(e[0],r,i)}return null}if(!(0,y.isSuccessStatusCode)(p.statusCode)){throw new Error(`Cache service responded with ${p.statusCode}`)}const l=p.result;const d=l===null||l===void 0?void 0:l.archiveLocation;if(!d){throw new Error("Cache not found.")}o.setSecret(d);o.debug(`Cache Result:`);o.debug(JSON.stringify(l));return l}))}t.getCacheEntry=getCacheEntry;function printCachesListForDiagnostics(e,t,a){return s(this,void 0,void 0,(function*(){const r=`caches?key=${encodeURIComponent(e)}`;const i=yield(0,y.retryTypedResponse)("listCache",(()=>s(this,void 0,void 0,(function*(){return t.getJson(getCacheApiUrl(r))}))));if(i.statusCode===200){const t=i.result;const r=t===null||t===void 0?void 0:t.totalCount;if(r&&r>0){o.debug(`No matching cache found for cache key '${e}', version '${a} and scope ${process.env["GITHUB_REF"]}. There exist one or more cache(s) with similar key but they have different version or scope. See more info on cache matching here: https://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows#matching-a-cache-key \nOther caches with similar key:`);for(const e of(t===null||t===void 0?void 0:t.artifactCaches)||[]){o.debug(`Cache Key: ${e===null||e===void 0?void 0:e.cacheKey}, Cache Version: ${e===null||e===void 0?void 0:e.cacheVersion}, Cache Scope: ${e===null||e===void 0?void 0:e.scope}, Cache Created: ${e===null||e===void 0?void 0:e.creationTime}`)}}}}))}function downloadCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=new m.URL(e);const i=(0,g.getDownloadOptions)(a);if(r.hostname.endsWith(".blob.core.windows.net")){if(i.useAzureSdk){yield(0,h.downloadCacheStorageSDK)(e,t,i)}else if(i.concurrentBlobDownloads){yield(0,h.downloadCacheHttpClientConcurrent)(e,t,i)}else{yield(0,h.downloadCacheHttpClient)(e,t)}}else{yield(0,h.downloadCacheHttpClient)(e,t)}}))}t.downloadCache=downloadCache;function reserveCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();const i=getCacheVersion(t,a===null||a===void 0?void 0:a.compressionMethod,a===null||a===void 0?void 0:a.enableCrossOsArchive);const n={key:e,version:i,cacheSize:a===null||a===void 0?void 0:a.cacheSize};const o=yield(0,y.retryTypedResponse)("reserveCache",(()=>s(this,void 0,void 0,(function*(){return r.postJson(getCacheApiUrl("caches"),n)}))));return o}))}t.reserveCache=reserveCache;function getContentRange(e,t){return`bytes ${e}-${t}/*`}function uploadChunk(e,t,a,r,i){return s(this,void 0,void 0,(function*(){o.debug(`Uploading chunk of size ${i-r+1} bytes at offset ${r} with content range: ${getContentRange(r,i)}`);const n={"Content-Type":"application/octet-stream","Content-Range":getContentRange(r,i)};const p=yield(0,y.retryHttpClientResponse)(`uploadChunk (start: ${r}, end: ${i})`,(()=>s(this,void 0,void 0,(function*(){return e.sendStream("PATCH",t,a(),n)}))));if(!(0,y.isSuccessStatusCode)(p.message.statusCode)){throw new Error(`Cache service responded with ${p.message.statusCode} during upload chunk.`)}}))}function uploadFile(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=u.getArchiveFileSizeInBytes(a);const n=getCacheApiUrl(`caches/${t.toString()}`);const p=c.openSync(a,"r");const l=(0,g.getUploadOptions)(r);const d=u.assertDefined("uploadConcurrency",l.uploadConcurrency);const m=u.assertDefined("uploadChunkSize",l.uploadChunkSize);const h=[...new Array(d).keys()];o.debug("Awaiting all uploads");let y=0;try{yield Promise.all(h.map((()=>s(this,void 0,void 0,(function*(){while(yc.createReadStream(a,{fd:p,start:r,end:s,autoClose:false}).on("error",(e=>{throw new Error(`Cache upload failed because file read failed with ${e.message}`)}))),r,s)}})))))}finally{c.closeSync(p)}return}))}function commitCache(e,t,a){return s(this,void 0,void 0,(function*(){const r={size:a};return yield(0,y.retryTypedResponse)("commitCache",(()=>s(this,void 0,void 0,(function*(){return e.postJson(getCacheApiUrl(`caches/${t.toString()}`),r)}))))}))}function saveCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();o.debug("Upload cache");yield uploadFile(r,e,t,a);o.debug("Commiting cache");const i=u.getArchiveFileSizeInBytes(t);o.info(`Cache Size: ~${Math.round(i/(1024*1024))} MB (${i} B)`);const n=yield commitCache(r,e,i);if(!(0,y.isSuccessStatusCode)(n.statusCode)){throw new Error(`Cache service responded with ${n.statusCode} during commit cache.`)}o.info("Cache saved successfully")}))}t.saveCache=saveCache},1518:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};Object.defineProperty(t,"__esModule",{value:true});t.isGhes=t.assertDefined=t.getGnuTarPathOnWindows=t.getCacheFileName=t.getCompressionMethod=t.unlinkFile=t.resolvePaths=t.getArchiveFileSizeInBytes=t.createTempDirectory=void 0;const p=n(a(2186));const l=n(a(1514));const d=n(a(8090));const c=n(a(7436));const m=n(a(7147));const u=n(a(1017));const h=n(a(5911));const g=n(a(3837));const y=a(4138);const v=a(8840);function createTempDirectory(){return s(this,void 0,void 0,(function*(){const e=process.platform==="win32";let t=process.env["RUNNER_TEMP"]||"";if(!t){let a;if(e){a=process.env["USERPROFILE"]||"C:\\"}else{if(process.platform==="darwin"){a="/Users"}else{a="/home"}}t=u.join(a,"actions","temp")}const a=u.join(t,(0,y.v4)());yield c.mkdirP(a);return a}))}t.createTempDirectory=createTempDirectory;function getArchiveFileSizeInBytes(e){return m.statSync(e).size}t.getArchiveFileSizeInBytes=getArchiveFileSizeInBytes;function resolvePaths(e){var t,a,r,i;var n;return s(this,void 0,void 0,(function*(){const s=[];const l=(n=process.env["GITHUB_WORKSPACE"])!==null&&n!==void 0?n:process.cwd();const c=yield d.create(e.join("\n"),{implicitDescendants:false});try{for(var m=true,h=o(c.globGenerator()),g;g=yield h.next(),t=g.done,!t;){i=g.value;m=false;try{const e=i;const t=u.relative(l,e).replace(new RegExp(`\\${u.sep}`,"g"),"/");p.debug(`Matched: ${t}`);if(t===""){s.push(".")}else{s.push(`${t}`)}}finally{m=true}}}catch(e){a={error:e}}finally{try{if(!m&&!t&&(r=h.return))yield r.call(h)}finally{if(a)throw a.error}}return s}))}t.resolvePaths=resolvePaths;function unlinkFile(e){return s(this,void 0,void 0,(function*(){return g.promisify(m.unlink)(e)}))}t.unlinkFile=unlinkFile;function getVersion(e,t=[]){return s(this,void 0,void 0,(function*(){let a="";t.push("--version");p.debug(`Checking ${e} ${t.join(" ")}`);try{yield l.exec(`${e}`,t,{ignoreReturnCode:true,silent:true,listeners:{stdout:e=>a+=e.toString(),stderr:e=>a+=e.toString()}})}catch(e){p.debug(e.message)}a=a.trim();p.debug(a);return a}))}function getCompressionMethod(){return s(this,void 0,void 0,(function*(){const e=yield getVersion("zstd",["--quiet"]);const t=h.clean(e);p.debug(`zstd version: ${t}`);if(e===""){return v.CompressionMethod.Gzip}else{return v.CompressionMethod.ZstdWithoutLong}}))}t.getCompressionMethod=getCompressionMethod;function getCacheFileName(e){return e===v.CompressionMethod.Gzip?v.CacheFilename.Gzip:v.CacheFilename.Zstd}t.getCacheFileName=getCacheFileName;function getGnuTarPathOnWindows(){return s(this,void 0,void 0,(function*(){if(m.existsSync(v.GnuTarPathOnWindows)){return v.GnuTarPathOnWindows}const e=yield getVersion("tar");return e.toLowerCase().includes("gnu tar")?c.which("tar"):""}))}t.getGnuTarPathOnWindows=getGnuTarPathOnWindows;function assertDefined(e,t){if(t===undefined){throw Error(`Expected ${e} but value was undefiend`)}return t}t.assertDefined=assertDefined;function isGhes(){const e=new URL(process.env["GITHUB_SERVER_URL"]||"https://github.com");return e.hostname.toUpperCase()!=="GITHUB.COM"}t.isGhes=isGhes},8840:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ManifestFilename=t.TarFilename=t.SystemTarPathOnWindows=t.GnuTarPathOnWindows=t.SocketTimeout=t.DefaultRetryDelay=t.DefaultRetryAttempts=t.ArchiveToolType=t.CompressionMethod=t.CacheFilename=void 0;var a;(function(e){e["Gzip"]="cache.tgz";e["Zstd"]="cache.tzst"})(a=t.CacheFilename||(t.CacheFilename={}));var r;(function(e){e["Gzip"]="gzip";e["ZstdWithoutLong"]="zstd-without-long";e["Zstd"]="zstd"})(r=t.CompressionMethod||(t.CompressionMethod={}));var i;(function(e){e["GNU"]="gnu";e["BSD"]="bsd"})(i=t.ArchiveToolType||(t.ArchiveToolType={}));t.DefaultRetryAttempts=2;t.DefaultRetryDelay=5e3;t.SocketTimeout=5e3;t.GnuTarPathOnWindows=`${process.env["PROGRAMFILES"]}\\Git\\usr\\bin\\tar.exe`;t.SystemTarPathOnWindows=`${process.env["SYSTEMDRIVE"]}\\Windows\\System32\\tar.exe`;t.TarFilename="cache.tar";t.ManifestFilename="manifest.txt"},5500:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.downloadCacheStorageSDK=t.downloadCacheHttpClientConcurrent=t.downloadCacheHttpClient=t.DownloadProgress=void 0;const o=n(a(2186));const p=a(6255);const l=a(4100);const d=n(a(4300));const c=n(a(7147));const m=n(a(2781));const u=n(a(3837));const h=n(a(1518));const g=a(8840);const y=a(3981);const v=a(2557);function pipeResponseToStream(e,t){return s(this,void 0,void 0,(function*(){const a=u.promisify(m.pipeline);yield a(e.message,t)}))}class DownloadProgress{constructor(e){this.contentLength=e;this.segmentIndex=0;this.segmentSize=0;this.segmentOffset=0;this.receivedBytes=0;this.displayedComplete=false;this.startTime=Date.now()}nextSegment(e){this.segmentOffset=this.segmentOffset+this.segmentSize;this.segmentIndex=this.segmentIndex+1;this.segmentSize=e;this.receivedBytes=0;o.debug(`Downloading segment at offset ${this.segmentOffset} with length ${this.segmentSize}...`)}setReceivedBytes(e){this.receivedBytes=e}getTransferredBytes(){return this.segmentOffset+this.receivedBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete){return}const e=this.segmentOffset+this.receivedBytes;const t=(100*(e/this.contentLength)).toFixed(1);const a=Date.now()-this.startTime;const r=(e/(1024*1024)/(a/1e3)).toFixed(1);o.info(`Received ${e} of ${this.contentLength} (${t}%), ${r} MBs/sec`);if(this.isDone()){this.displayedComplete=true}}onProgress(){return e=>{this.setReceivedBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){const displayCallback=()=>{this.display();if(!this.isDone()){this.timeoutHandle=setTimeout(displayCallback,e)}};this.timeoutHandle=setTimeout(displayCallback,e)}stopDisplayTimer(){if(this.timeoutHandle){clearTimeout(this.timeoutHandle);this.timeoutHandle=undefined}this.display()}}t.DownloadProgress=DownloadProgress;function downloadCacheHttpClient(e,t){return s(this,void 0,void 0,(function*(){const a=c.createWriteStream(t);const r=new p.HttpClient("actions/cache");const i=yield(0,y.retryHttpClientResponse)("downloadCache",(()=>s(this,void 0,void 0,(function*(){return r.get(e)}))));i.message.socket.setTimeout(g.SocketTimeout,(()=>{i.message.destroy();o.debug(`Aborting download, socket timed out after ${g.SocketTimeout} ms`)}));yield pipeResponseToStream(i,a);const n=i.message.headers["content-length"];if(n){const e=parseInt(n);const a=h.getArchiveFileSizeInBytes(t);if(a!==e){throw new Error(`Incomplete download. Expected file size: ${e}, actual file size: ${a}`)}}else{o.debug("Unable to validate download, no Content-Length header")}}))}t.downloadCacheHttpClient=downloadCacheHttpClient;function downloadCacheHttpClientConcurrent(e,t,a){var r;return s(this,void 0,void 0,(function*(){const i=yield c.promises.open(t,"w");const n=new p.HttpClient("actions/cache",undefined,{socketTimeout:a.timeoutInMs,keepAlive:true});try{const t=yield(0,y.retryHttpClientResponse)("downloadCacheMetadata",(()=>s(this,void 0,void 0,(function*(){return yield n.request("HEAD",e,null,{})}))));const o=t.message.headers["content-length"];if(o===undefined||o===null){throw new Error("Content-Length not found on blob response")}const p=parseInt(o);if(Number.isNaN(p)){throw new Error(`Could not interpret Content-Length: ${p}`)}const l=[];const d=4*1024*1024;for(let t=0;ts(this,void 0,void 0,(function*(){return yield downloadSegmentRetry(n,e,t,a)}))})}l.reverse();let c=0;let m=0;const u=new DownloadProgress(p);u.startDisplayTimer();const h=u.onProgress();const g=[];let v;const waitAndWrite=()=>s(this,void 0,void 0,(function*(){const e=yield Promise.race(Object.values(g));yield i.write(e.buffer,0,e.count,e.offset);c--;delete g[e.offset];m+=e.count;h({loadedBytes:m})}));while(v=l.pop()){g[v.offset]=v.promiseGetter();c++;if(c>=((r=a.downloadConcurrency)!==null&&r!==void 0?r:10)){yield waitAndWrite()}}while(c>0){yield waitAndWrite()}}finally{n.dispose();yield i.close()}}))}t.downloadCacheHttpClientConcurrent=downloadCacheHttpClientConcurrent;function downloadSegmentRetry(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=5;let n=0;while(true){try{const i=3e4;const n=yield promiseWithTimeout(i,downloadSegment(e,t,a,r));if(typeof n==="string"){throw new Error("downloadSegmentRetry failed due to timeout")}return n}catch(e){if(n>=i){throw e}n++}}}))}function downloadSegment(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=yield(0,y.retryHttpClientResponse)("downloadCachePart",(()=>s(this,void 0,void 0,(function*(){return yield e.get(t,{Range:`bytes=${a}-${a+r-1}`})}))));if(!i.readBodyBuffer){throw new Error("Expected HttpClientResponse to implement readBodyBuffer")}return{offset:a,count:r,buffer:yield i.readBodyBuffer()}}))}function downloadCacheStorageSDK(e,t,a){var r;return s(this,void 0,void 0,(function*(){const i=new l.BlockBlobClient(e,undefined,{retryOptions:{tryTimeoutInMs:a.timeoutInMs}});const n=yield i.getProperties();const s=(r=n.contentLength)!==null&&r!==void 0?r:-1;if(s<0){o.debug("Unable to determine content length, downloading file with http-client...");yield downloadCacheHttpClient(e,t)}else{const e=Math.min(134217728,d.constants.MAX_LENGTH);const r=new DownloadProgress(s);const n=c.openSync(t,"w");try{r.startDisplayTimer();const t=new v.AbortController;const o=t.signal;while(!r.isDone()){const p=r.segmentOffset+r.segmentSize;const l=Math.min(e,s-p);r.nextSegment(l);const d=yield promiseWithTimeout(a.segmentTimeoutInMs||36e5,i.downloadToBuffer(p,l,{abortSignal:o,concurrency:a.downloadConcurrency,onProgress:r.onProgress()}));if(d==="timeout"){t.abort();throw new Error("Aborting cache download as the download time exceeded the timeout.")}else if(Buffer.isBuffer(d)){c.writeFileSync(n,d)}}}finally{r.stopDisplayTimer();c.closeSync(n)}}}))}t.downloadCacheStorageSDK=downloadCacheStorageSDK;const promiseWithTimeout=(e,t)=>s(void 0,void 0,void 0,(function*(){let a;const r=new Promise((t=>{a=setTimeout((()=>t("timeout")),e)}));return Promise.race([t,r]).then((e=>{clearTimeout(a);return e}))}))},3981:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.retryHttpClientResponse=t.retryTypedResponse=t.retry=t.isRetryableStatusCode=t.isServerErrorStatusCode=t.isSuccessStatusCode=void 0;const o=n(a(2186));const p=a(6255);const l=a(8840);function isSuccessStatusCode(e){if(!e){return false}return e>=200&&e<300}t.isSuccessStatusCode=isSuccessStatusCode;function isServerErrorStatusCode(e){if(!e){return true}return e>=500}t.isServerErrorStatusCode=isServerErrorStatusCode;function isRetryableStatusCode(e){if(!e){return false}const t=[p.HttpCodes.BadGateway,p.HttpCodes.ServiceUnavailable,p.HttpCodes.GatewayTimeout];return t.includes(e)}t.isRetryableStatusCode=isRetryableStatusCode;function sleep(e){return s(this,void 0,void 0,(function*(){return new Promise((t=>setTimeout(t,e)))}))}function retry(e,t,a,r=l.DefaultRetryAttempts,i=l.DefaultRetryDelay,n=undefined){return s(this,void 0,void 0,(function*(){let s="";let p=1;while(p<=r){let l=undefined;let d=undefined;let c=false;try{l=yield t()}catch(e){if(n){l=n(e)}c=true;s=e.message}if(l){d=a(l);if(!isServerErrorStatusCode(d)){return l}}if(d){c=isRetryableStatusCode(d);s=`Cache service responded with ${d}`}o.debug(`${e} - Attempt ${p} of ${r} failed with error: ${s}`);if(!c){o.debug(`${e} - Error is not retryable`);break}yield sleep(i);p++}throw Error(`${e} failed: ${s}`)}))}t.retry=retry;function retryTypedResponse(e,t,a=l.DefaultRetryAttempts,r=l.DefaultRetryDelay){return s(this,void 0,void 0,(function*(){return yield retry(e,t,(e=>e.statusCode),a,r,(e=>{if(e instanceof p.HttpClientError){return{statusCode:e.statusCode,result:null,headers:{},error:e}}else{return undefined}}))}))}t.retryTypedResponse=retryTypedResponse;function retryHttpClientResponse(e,t,a=l.DefaultRetryAttempts,r=l.DefaultRetryDelay){return s(this,void 0,void 0,(function*(){return yield retry(e,t,(e=>e.message.statusCode),a,r)}))}t.retryHttpClientResponse=retryHttpClientResponse},6490:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.createTar=t.extractTar=t.listTar=void 0;const o=a(1514);const p=n(a(7436));const l=a(7147);const d=n(a(1017));const c=n(a(1518));const m=a(8840);const u=process.platform==="win32";function getTarPath(){return s(this,void 0,void 0,(function*(){switch(process.platform){case"win32":{const e=yield c.getGnuTarPathOnWindows();const t=m.SystemTarPathOnWindows;if(e){return{path:e,type:m.ArchiveToolType.GNU}}else if((0,l.existsSync)(t)){return{path:t,type:m.ArchiveToolType.BSD}}break}case"darwin":{const e=yield p.which("gtar",false);if(e){return{path:e,type:m.ArchiveToolType.GNU}}else{return{path:yield p.which("tar",true),type:m.ArchiveToolType.BSD}}}default:break}return{path:yield p.which("tar",true),type:m.ArchiveToolType.GNU}}))}function getTarArgs(e,t,a,r=""){return s(this,void 0,void 0,(function*(){const i=[`"${e.path}"`];const n=c.getCacheFileName(t);const s="cache.tar";const o=getWorkingDirectory();const p=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(a){case"create":i.push("--posix","-cf",p?s:n.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"--exclude",p?s:n.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P","-C",o.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"--files-from",m.ManifestFilename);break;case"extract":i.push("-xf",p?s:r.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P","-C",o.replace(new RegExp(`\\${d.sep}`,"g"),"/"));break;case"list":i.push("-tf",p?s:r.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P");break}if(e.type===m.ArchiveToolType.GNU){switch(process.platform){case"win32":i.push("--force-local");break;case"darwin":i.push("--delay-directory-restore");break}}return i}))}function getCommands(e,t,a=""){return s(this,void 0,void 0,(function*(){let r;const i=yield getTarPath();const n=yield getTarArgs(i,e,t,a);const s=t!=="create"?yield getDecompressionProgram(i,e,a):yield getCompressionProgram(i,e);const o=i.type===m.ArchiveToolType.BSD&&e!==m.CompressionMethod.Gzip&&u;if(o&&t!=="create"){r=[[...s].join(" "),[...n].join(" ")]}else{r=[[...n].join(" "),[...s].join(" ")]}if(o){return r}return[r.join(" ")]}))}function getWorkingDirectory(){var e;return(e=process.env["GITHUB_WORKSPACE"])!==null&&e!==void 0?e:process.cwd()}function getDecompressionProgram(e,t,a){return s(this,void 0,void 0,(function*(){const r=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(t){case m.CompressionMethod.Zstd:return r?["zstd -d --long=30 --force -o",m.TarFilename,a.replace(new RegExp(`\\${d.sep}`,"g"),"/")]:["--use-compress-program",u?'"zstd -d --long=30"':"unzstd --long=30"];case m.CompressionMethod.ZstdWithoutLong:return r?["zstd -d --force -o",m.TarFilename,a.replace(new RegExp(`\\${d.sep}`,"g"),"/")]:["--use-compress-program",u?'"zstd -d"':"unzstd"];default:return["-z"]}}))}function getCompressionProgram(e,t){return s(this,void 0,void 0,(function*(){const a=c.getCacheFileName(t);const r=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(t){case m.CompressionMethod.Zstd:return r?["zstd -T0 --long=30 --force -o",a.replace(new RegExp(`\\${d.sep}`,"g"),"/"),m.TarFilename]:["--use-compress-program",u?'"zstd -T0 --long=30"':"zstdmt --long=30"];case m.CompressionMethod.ZstdWithoutLong:return r?["zstd -T0 --force -o",a.replace(new RegExp(`\\${d.sep}`,"g"),"/"),m.TarFilename]:["--use-compress-program",u?'"zstd -T0"':"zstdmt"];default:return["-z"]}}))}function execCommands(e,t){return s(this,void 0,void 0,(function*(){for(const a of e){try{yield(0,o.exec)(a,undefined,{cwd:t,env:Object.assign(Object.assign({},process.env),{MSYS:"winsymlinks:nativestrict"})})}catch(e){throw new Error(`${a.split(" ")[0]} failed with error: ${e===null||e===void 0?void 0:e.message}`)}}}))}function listTar(e,t){return s(this,void 0,void 0,(function*(){const a=yield getCommands(t,"list",e);yield execCommands(a)}))}t.listTar=listTar;function extractTar(e,t){return s(this,void 0,void 0,(function*(){const a=getWorkingDirectory();yield p.mkdirP(a);const r=yield getCommands(t,"extract",e);yield execCommands(r)}))}t.extractTar=extractTar;function createTar(e,t,a){return s(this,void 0,void 0,(function*(){(0,l.writeFileSync)(d.join(e,m.ManifestFilename),t.join("\n"));const r=yield getCommands(a,"create");yield execCommands(r,e)}))}t.createTar=createTar},6215:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getDownloadOptions=t.getUploadOptions=void 0;const s=n(a(2186));function getUploadOptions(e){const t={uploadConcurrency:4,uploadChunkSize:32*1024*1024};if(e){if(typeof e.uploadConcurrency==="number"){t.uploadConcurrency=e.uploadConcurrency}if(typeof e.uploadChunkSize==="number"){t.uploadChunkSize=e.uploadChunkSize}}s.debug(`Upload concurrency: ${t.uploadConcurrency}`);s.debug(`Upload chunk size: ${t.uploadChunkSize}`);return t}t.getUploadOptions=getUploadOptions;function getDownloadOptions(e){const t={useAzureSdk:false,concurrentBlobDownloads:true,downloadConcurrency:8,timeoutInMs:3e4,segmentTimeoutInMs:6e5,lookupOnly:false};if(e){if(typeof e.useAzureSdk==="boolean"){t.useAzureSdk=e.useAzureSdk}if(typeof e.concurrentBlobDownloads==="boolean"){t.concurrentBlobDownloads=e.concurrentBlobDownloads}if(typeof e.downloadConcurrency==="number"){t.downloadConcurrency=e.downloadConcurrency}if(typeof e.timeoutInMs==="number"){t.timeoutInMs=e.timeoutInMs}if(typeof e.segmentTimeoutInMs==="number"){t.segmentTimeoutInMs=e.segmentTimeoutInMs}if(typeof e.lookupOnly==="boolean"){t.lookupOnly=e.lookupOnly}}const a=process.env["SEGMENT_DOWNLOAD_TIMEOUT_MINS"];if(a&&!isNaN(Number(a))&&isFinite(Number(a))){t.segmentTimeoutInMs=Number(a)*60*1e3}s.debug(`Use Azure SDK: ${t.useAzureSdk}`);s.debug(`Download concurrency: ${t.downloadConcurrency}`);s.debug(`Request timeout (ms): ${t.timeoutInMs}`);s.debug(`Cache segment download timeout mins env var: ${process.env["SEGMENT_DOWNLOAD_TIMEOUT_MINS"]}`);s.debug(`Segment download timeout (ms): ${t.segmentTimeoutInMs}`);s.debug(`Lookup only: ${t.lookupOnly}`);return t}t.getDownloadOptions=getDownloadOptions},4138:(e,t,a)=>{var r=a(1610);var i=a(8373);var n=i;n.v1=r;n.v4=i;e.exports=n},5694:e=>{var t=[];for(var a=0;a<256;++a){t[a]=(a+256).toString(16).substr(1)}function bytesToUuid(e,a){var r=a||0;var i=t;return[i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]]].join("")}e.exports=bytesToUuid},4069:(e,t,a)=>{var r=a(6113);e.exports=function nodeRNG(){return r.randomBytes(16)}},1610:(e,t,a)=>{var r=a(4069);var i=a(5694);var n;var s;var o=0;var p=0;function v1(e,t,a){var l=t&&a||0;var d=t||[];e=e||{};var c=e.node||n;var m=e.clockseq!==undefined?e.clockseq:s;if(c==null||m==null){var u=r();if(c==null){c=n=[u[0]|1,u[1],u[2],u[3],u[4],u[5]]}if(m==null){m=s=(u[6]<<8|u[7])&16383}}var h=e.msecs!==undefined?e.msecs:(new Date).getTime();var g=e.nsecs!==undefined?e.nsecs:p+1;var y=h-o+(g-p)/1e4;if(y<0&&e.clockseq===undefined){m=m+1&16383}if((y<0||h>o)&&e.nsecs===undefined){g=0}if(g>=1e4){throw new Error("uuid.v1(): Can't create more than 10M uuids/sec")}o=h;p=g;s=m;h+=122192928e5;var v=((h&268435455)*1e4+g)%4294967296;d[l++]=v>>>24&255;d[l++]=v>>>16&255;d[l++]=v>>>8&255;d[l++]=v&255;var b=h/4294967296*1e4&268435455;d[l++]=b>>>8&255;d[l++]=b&255;d[l++]=b>>>24&15|16;d[l++]=b>>>16&255;d[l++]=m>>>8|128;d[l++]=m&255;for(var x=0;x<6;++x){d[l+x]=c[x]}return t?t:i(d)}e.exports=v1},8373:(e,t,a)=>{var r=a(4069);var i=a(5694);function v4(e,t,a){var n=t&&a||0;if(typeof e=="string"){t=e==="binary"?new Array(16):null;e=null}e=e||{};var s=e.random||(e.rng||r)();s[6]=s[6]&15|64;s[8]=s[8]&63|128;if(t){for(var o=0;o<16;++o){t[n+o]=s[o]}}return t||i(s)}e.exports=v4},7351:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issue=t.issueCommand=void 0;const s=n(a(2037));const o=a(5278);function issueCommand(e,t,a){const r=new Command(e,t,a);process.stdout.write(r.toString()+s.EOL)}t.issueCommand=issueCommand;function issue(e,t=""){issueCommand(e,{},t)}t.issue=issue;const p="::";class Command{constructor(e,t,a){if(!e){e="missing.command"}this.command=e;this.properties=t;this.message=a}toString(){let e=p+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let t=true;for(const a in this.properties){if(this.properties.hasOwnProperty(a)){const r=this.properties[a];if(r){if(t){t=false}else{e+=","}e+=`${a}=${escapeProperty(r)}`}}}}e+=`${p}${escapeData(this.message)}`;return e}}function escapeData(e){return o.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return o.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},2186:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getIDToken=t.getState=t.saveState=t.group=t.endGroup=t.startGroup=t.info=t.notice=t.warning=t.error=t.debug=t.isDebug=t.setFailed=t.setCommandEcho=t.setOutput=t.getBooleanInput=t.getMultilineInput=t.getInput=t.addPath=t.setSecret=t.exportVariable=t.ExitCode=void 0;const o=a(7351);const p=a(717);const l=a(5278);const d=n(a(2037));const c=n(a(1017));const m=a(8041);var u;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(u=t.ExitCode||(t.ExitCode={}));function exportVariable(e,t){const a=l.toCommandValue(t);process.env[e]=a;const r=process.env["GITHUB_ENV"]||"";if(r){return p.issueFileCommand("ENV",p.prepareKeyValueMessage(e,t))}o.issueCommand("set-env",{name:e},a)}t.exportVariable=exportVariable;function setSecret(e){o.issueCommand("add-mask",{},e)}t.setSecret=setSecret;function addPath(e){const t=process.env["GITHUB_PATH"]||"";if(t){p.issueFileCommand("PATH",e)}else{o.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${c.delimiter}${process.env["PATH"]}`}t.addPath=addPath;function getInput(e,t){const a=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(t&&t.required&&!a){throw new Error(`Input required and not supplied: ${e}`)}if(t&&t.trimWhitespace===false){return a}return a.trim()}t.getInput=getInput;function getMultilineInput(e,t){const a=getInput(e,t).split("\n").filter((e=>e!==""));if(t&&t.trimWhitespace===false){return a}return a.map((e=>e.trim()))}t.getMultilineInput=getMultilineInput;function getBooleanInput(e,t){const a=["true","True","TRUE"];const r=["false","False","FALSE"];const i=getInput(e,t);if(a.includes(i))return true;if(r.includes(i))return false;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${e}\n`+`Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}t.getBooleanInput=getBooleanInput;function setOutput(e,t){const a=process.env["GITHUB_OUTPUT"]||"";if(a){return p.issueFileCommand("OUTPUT",p.prepareKeyValueMessage(e,t))}process.stdout.write(d.EOL);o.issueCommand("set-output",{name:e},l.toCommandValue(t))}t.setOutput=setOutput;function setCommandEcho(e){o.issue("echo",e?"on":"off")}t.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=u.Failure;error(e)}t.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}t.isDebug=isDebug;function debug(e){o.issueCommand("debug",{},e)}t.debug=debug;function error(e,t={}){o.issueCommand("error",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.error=error;function warning(e,t={}){o.issueCommand("warning",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.warning=warning;function notice(e,t={}){o.issueCommand("notice",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.notice=notice;function info(e){process.stdout.write(e+d.EOL)}t.info=info;function startGroup(e){o.issue("group",e)}t.startGroup=startGroup;function endGroup(){o.issue("endgroup")}t.endGroup=endGroup;function group(e,t){return s(this,void 0,void 0,(function*(){startGroup(e);let a;try{a=yield t()}finally{endGroup()}return a}))}t.group=group;function saveState(e,t){const a=process.env["GITHUB_STATE"]||"";if(a){return p.issueFileCommand("STATE",p.prepareKeyValueMessage(e,t))}o.issueCommand("save-state",{name:e},l.toCommandValue(t))}t.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}t.getState=getState;function getIDToken(e){return s(this,void 0,void 0,(function*(){return yield m.OidcClient.getIDToken(e)}))}t.getIDToken=getIDToken;var h=a(1327);Object.defineProperty(t,"summary",{enumerable:true,get:function(){return h.summary}});var g=a(1327);Object.defineProperty(t,"markdownSummary",{enumerable:true,get:function(){return g.markdownSummary}});var y=a(2981);Object.defineProperty(t,"toPosixPath",{enumerable:true,get:function(){return y.toPosixPath}});Object.defineProperty(t,"toWin32Path",{enumerable:true,get:function(){return y.toWin32Path}});Object.defineProperty(t,"toPlatformPath",{enumerable:true,get:function(){return y.toPlatformPath}})},717:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.prepareKeyValueMessage=t.issueFileCommand=void 0;const s=n(a(7147));const o=n(a(2037));const p=a(5840);const l=a(5278);function issueFileCommand(e,t){const a=process.env[`GITHUB_${e}`];if(!a){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!s.existsSync(a)){throw new Error(`Missing file at path: ${a}`)}s.appendFileSync(a,`${l.toCommandValue(t)}${o.EOL}`,{encoding:"utf8"})}t.issueFileCommand=issueFileCommand;function prepareKeyValueMessage(e,t){const a=`ghadelimiter_${p.v4()}`;const r=l.toCommandValue(t);if(e.includes(a)){throw new Error(`Unexpected input: name should not contain the delimiter "${a}"`)}if(r.includes(a)){throw new Error(`Unexpected input: value should not contain the delimiter "${a}"`)}return`${e}<<${a}${o.EOL}${r}${o.EOL}${a}`}t.prepareKeyValueMessage=prepareKeyValueMessage},8041:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.OidcClient=void 0;const i=a(6255);const n=a(5526);const s=a(2186);class OidcClient{static createHttpClient(e=true,t=10){const a={allowRetries:e,maxRetries:t};return new i.HttpClient("actions/oidc-client",[new n.BearerCredentialHandler(OidcClient.getRequestToken())],a)}static getRequestToken(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_TOKEN env variable")}return e}static getIDTokenUrl(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_URL"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable")}return e}static getCall(e){var t;return r(this,void 0,void 0,(function*(){const a=OidcClient.createHttpClient();const r=yield a.getJson(e).catch((e=>{throw new Error(`Failed to get ID Token. \n \n Error Code : ${e.statusCode}\n \n Error Message: ${e.result.message}`)}));const i=(t=r.result)===null||t===void 0?void 0:t.value;if(!i){throw new Error("Response json body do not have ID Token field")}return i}))}static getIDToken(e){return r(this,void 0,void 0,(function*(){try{let t=OidcClient.getIDTokenUrl();if(e){const a=encodeURIComponent(e);t=`${t}&audience=${a}`}s.debug(`ID token url is ${t}`);const a=yield OidcClient.getCall(t);s.setSecret(a);return a}catch(e){throw new Error(`Error message: ${e.message}`)}}))}}t.OidcClient=OidcClient},2981:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.toPlatformPath=t.toWin32Path=t.toPosixPath=void 0;const s=n(a(1017));function toPosixPath(e){return e.replace(/[\\]/g,"/")}t.toPosixPath=toPosixPath;function toWin32Path(e){return e.replace(/[/]/g,"\\")}t.toWin32Path=toWin32Path;function toPlatformPath(e){return e.replace(/[/\\]/g,s.sep)}t.toPlatformPath=toPlatformPath},1327:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.summary=t.markdownSummary=t.SUMMARY_DOCS_URL=t.SUMMARY_ENV_VAR=void 0;const i=a(2037);const n=a(7147);const{access:s,appendFile:o,writeFile:p}=n.promises;t.SUMMARY_ENV_VAR="GITHUB_STEP_SUMMARY";t.SUMMARY_DOCS_URL="https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary";class Summary{constructor(){this._buffer=""}filePath(){return r(this,void 0,void 0,(function*(){if(this._filePath){return this._filePath}const e=process.env[t.SUMMARY_ENV_VAR];if(!e){throw new Error(`Unable to find environment variable for $${t.SUMMARY_ENV_VAR}. Check if your runtime environment supports job summaries.`)}try{yield s(e,n.constants.R_OK|n.constants.W_OK)}catch(t){throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}this._filePath=e;return this._filePath}))}wrap(e,t,a={}){const r=Object.entries(a).map((([e,t])=>` ${e}="${t}"`)).join("");if(!t){return`<${e}${r}>`}return`<${e}${r}>${t}`}write(e){return r(this,void 0,void 0,(function*(){const t=!!(e===null||e===void 0?void 0:e.overwrite);const a=yield this.filePath();const r=t?p:o;yield r(a,this._buffer,{encoding:"utf8"});return this.emptyBuffer()}))}clear(){return r(this,void 0,void 0,(function*(){return this.emptyBuffer().write({overwrite:true})}))}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){this._buffer="";return this}addRaw(e,t=false){this._buffer+=e;return t?this.addEOL():this}addEOL(){return this.addRaw(i.EOL)}addCodeBlock(e,t){const a=Object.assign({},t&&{lang:t});const r=this.wrap("pre",this.wrap("code",e),a);return this.addRaw(r).addEOL()}addList(e,t=false){const a=t?"ol":"ul";const r=e.map((e=>this.wrap("li",e))).join("");const i=this.wrap(a,r);return this.addRaw(i).addEOL()}addTable(e){const t=e.map((e=>{const t=e.map((e=>{if(typeof e==="string"){return this.wrap("td",e)}const{header:t,data:a,colspan:r,rowspan:i}=e;const n=t?"th":"td";const s=Object.assign(Object.assign({},r&&{colspan:r}),i&&{rowspan:i});return this.wrap(n,a,s)})).join("");return this.wrap("tr",t)})).join("");const a=this.wrap("table",t);return this.addRaw(a).addEOL()}addDetails(e,t){const a=this.wrap("details",this.wrap("summary",e)+t);return this.addRaw(a).addEOL()}addImage(e,t,a){const{width:r,height:i}=a||{};const n=Object.assign(Object.assign({},r&&{width:r}),i&&{height:i});const s=this.wrap("img",null,Object.assign({src:e,alt:t},n));return this.addRaw(s).addEOL()}addHeading(e,t){const a=`h${t}`;const r=["h1","h2","h3","h4","h5","h6"].includes(a)?a:"h1";const i=this.wrap(r,e);return this.addRaw(i).addEOL()}addSeparator(){const e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){const e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,t){const a=Object.assign({},t&&{cite:t});const r=this.wrap("blockquote",e,a);return this.addRaw(r).addEOL()}addLink(e,t){const a=this.wrap("a",e,{href:t});return this.addRaw(a).addEOL()}}const l=new Summary;t.markdownSummary=l;t.summary=l},5278:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.toCommandProperties=t.toCommandValue=void 0;function toCommandValue(e){if(e===null||e===undefined){return""}else if(typeof e==="string"||e instanceof String){return e}return JSON.stringify(e)}t.toCommandValue=toCommandValue;function toCommandProperties(e){if(!Object.keys(e).length){return{}}return{title:e.title,file:e.file,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}}t.toCommandProperties=toCommandProperties},1514:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getExecOutput=t.exec=void 0;const o=a(1576);const p=n(a(8159));function exec(e,t,a){return s(this,void 0,void 0,(function*(){const r=p.argStringToArray(e);if(r.length===0){throw new Error(`Parameter 'commandLine' cannot be null or empty.`)}const i=r[0];t=r.slice(1).concat(t||[]);const n=new p.ToolRunner(i,t,a);return n.exec()}))}t.exec=exec;function getExecOutput(e,t,a){var r,i;return s(this,void 0,void 0,(function*(){let n="";let s="";const p=new o.StringDecoder("utf8");const l=new o.StringDecoder("utf8");const d=(r=a===null||a===void 0?void 0:a.listeners)===null||r===void 0?void 0:r.stdout;const c=(i=a===null||a===void 0?void 0:a.listeners)===null||i===void 0?void 0:i.stderr;const stdErrListener=e=>{s+=l.write(e);if(c){c(e)}};const stdOutListener=e=>{n+=p.write(e);if(d){d(e)}};const m=Object.assign(Object.assign({},a===null||a===void 0?void 0:a.listeners),{stdout:stdOutListener,stderr:stdErrListener});const u=yield exec(e,t,Object.assign(Object.assign({},a),{listeners:m}));n+=p.end();s+=l.end();return{exitCode:u,stdout:n,stderr:s}}))}t.getExecOutput=getExecOutput},8159:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.argStringToArray=t.ToolRunner=void 0;const o=n(a(2037));const p=n(a(2361));const l=n(a(2081));const d=n(a(1017));const c=n(a(7436));const m=n(a(1962));const u=a(9512);const h=process.platform==="win32";class ToolRunner extends p.EventEmitter{constructor(e,t,a){super();if(!e){throw new Error("Parameter 'toolPath' cannot be null or empty.")}this.toolPath=e;this.args=t||[];this.options=a||{}}_debug(e){if(this.options.listeners&&this.options.listeners.debug){this.options.listeners.debug(e)}}_getCommandString(e,t){const a=this._getSpawnFileName();const r=this._getSpawnArgs(e);let i=t?"":"[command]";if(h){if(this._isCmdFile()){i+=a;for(const e of r){i+=` ${e}`}}else if(e.windowsVerbatimArguments){i+=`"${a}"`;for(const e of r){i+=` ${e}`}}else{i+=this._windowsQuoteCmdArg(a);for(const e of r){i+=` ${this._windowsQuoteCmdArg(e)}`}}}else{i+=a;for(const e of r){i+=` ${e}`}}return i}_processLineBuffer(e,t,a){try{let r=t+e.toString();let i=r.indexOf(o.EOL);while(i>-1){const e=r.substring(0,i);a(e);r=r.substring(i+o.EOL.length);i=r.indexOf(o.EOL)}return r}catch(e){this._debug(`error processing line. Failed with error ${e}`);return""}}_getSpawnFileName(){if(h){if(this._isCmdFile()){return process.env["COMSPEC"]||"cmd.exe"}}return this.toolPath}_getSpawnArgs(e){if(h){if(this._isCmdFile()){let t=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(const a of this.args){t+=" ";t+=e.windowsVerbatimArguments?a:this._windowsQuoteCmdArg(a)}t+='"';return[t]}}return this.args}_endsWith(e,t){return e.endsWith(t)}_isCmdFile(){const e=this.toolPath.toUpperCase();return this._endsWith(e,".CMD")||this._endsWith(e,".BAT")}_windowsQuoteCmdArg(e){if(!this._isCmdFile()){return this._uvQuoteCmdArg(e)}if(!e){return'""'}const t=[" ","\t","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'];let a=false;for(const r of e){if(t.some((e=>e===r))){a=true;break}}if(!a){return e}let r='"';let i=true;for(let t=e.length;t>0;t--){r+=e[t-1];if(i&&e[t-1]==="\\"){r+="\\"}else if(e[t-1]==='"'){i=true;r+='"'}else{i=false}}r+='"';return r.split("").reverse().join("")}_uvQuoteCmdArg(e){if(!e){return'""'}if(!e.includes(" ")&&!e.includes("\t")&&!e.includes('"')){return e}if(!e.includes('"')&&!e.includes("\\")){return`"${e}"`}let t='"';let a=true;for(let r=e.length;r>0;r--){t+=e[r-1];if(a&&e[r-1]==="\\"){t+="\\"}else if(e[r-1]==='"'){a=true;t+="\\"}else{a=false}}t+='"';return t.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};const t={cwd:e.cwd||process.cwd(),env:e.env||process.env,silent:e.silent||false,windowsVerbatimArguments:e.windowsVerbatimArguments||false,failOnStdErr:e.failOnStdErr||false,ignoreReturnCode:e.ignoreReturnCode||false,delay:e.delay||1e4};t.outStream=e.outStream||process.stdout;t.errStream=e.errStream||process.stderr;return t}_getSpawnOptions(e,t){e=e||{};const a={};a.cwd=e.cwd;a.env=e.env;a["windowsVerbatimArguments"]=e.windowsVerbatimArguments||this._isCmdFile();if(e.windowsVerbatimArguments){a.argv0=`"${t}"`}return a}exec(){return s(this,void 0,void 0,(function*(){if(!m.isRooted(this.toolPath)&&(this.toolPath.includes("/")||h&&this.toolPath.includes("\\"))){this.toolPath=d.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)}this.toolPath=yield c.which(this.toolPath,true);return new Promise(((e,t)=>s(this,void 0,void 0,(function*(){this._debug(`exec tool: ${this.toolPath}`);this._debug("arguments:");for(const e of this.args){this._debug(` ${e}`)}const a=this._cloneExecOptions(this.options);if(!a.silent&&a.outStream){a.outStream.write(this._getCommandString(a)+o.EOL)}const r=new ExecState(a,this.toolPath);r.on("debug",(e=>{this._debug(e)}));if(this.options.cwd&&!(yield m.exists(this.options.cwd))){return t(new Error(`The cwd: ${this.options.cwd} does not exist!`))}const i=this._getSpawnFileName();const n=l.spawn(i,this._getSpawnArgs(a),this._getSpawnOptions(this.options,i));let s="";if(n.stdout){n.stdout.on("data",(e=>{if(this.options.listeners&&this.options.listeners.stdout){this.options.listeners.stdout(e)}if(!a.silent&&a.outStream){a.outStream.write(e)}s=this._processLineBuffer(e,s,(e=>{if(this.options.listeners&&this.options.listeners.stdline){this.options.listeners.stdline(e)}}))}))}let p="";if(n.stderr){n.stderr.on("data",(e=>{r.processStderr=true;if(this.options.listeners&&this.options.listeners.stderr){this.options.listeners.stderr(e)}if(!a.silent&&a.errStream&&a.outStream){const t=a.failOnStdErr?a.errStream:a.outStream;t.write(e)}p=this._processLineBuffer(e,p,(e=>{if(this.options.listeners&&this.options.listeners.errline){this.options.listeners.errline(e)}}))}))}n.on("error",(e=>{r.processError=e.message;r.processExited=true;r.processClosed=true;r.CheckComplete()}));n.on("exit",(e=>{r.processExitCode=e;r.processExited=true;this._debug(`Exit code ${e} received from tool '${this.toolPath}'`);r.CheckComplete()}));n.on("close",(e=>{r.processExitCode=e;r.processExited=true;r.processClosed=true;this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);r.CheckComplete()}));r.on("done",((a,r)=>{if(s.length>0){this.emit("stdline",s)}if(p.length>0){this.emit("errline",p)}n.removeAllListeners();if(a){t(a)}else{e(r)}}));if(this.options.input){if(!n.stdin){throw new Error("child process missing stdin")}n.stdin.end(this.options.input)}}))))}))}}t.ToolRunner=ToolRunner;function argStringToArray(e){const t=[];let a=false;let r=false;let i="";function append(e){if(r&&e!=='"'){i+="\\"}i+=e;r=false}for(let n=0;n0){t.push(i);i=""}continue}append(s)}if(i.length>0){t.push(i.trim())}return t}t.argStringToArray=argStringToArray;class ExecState extends p.EventEmitter{constructor(e,t){super();this.processClosed=false;this.processError="";this.processExitCode=0;this.processExited=false;this.processStderr=false;this.delay=1e4;this.done=false;this.timeout=null;if(!t){throw new Error("toolPath must not be empty")}this.options=e;this.toolPath=t;if(e.delay){this.delay=e.delay}}CheckComplete(){if(this.done){return}if(this.processClosed){this._setResult()}else if(this.processExited){this.timeout=u.setTimeout(ExecState.HandleTimeout,this.delay,this)}}_debug(e){this.emit("debug",e)}_setResult(){let e;if(this.processExited){if(this.processError){e=new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`)}else if(this.processExitCode!==0&&!this.options.ignoreReturnCode){e=new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`)}else if(this.processStderr&&this.options.failOnStdErr){e=new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`)}}if(this.timeout){clearTimeout(this.timeout);this.timeout=null}this.done=true;this.emit("done",e,this.processExitCode)}static HandleTimeout(e){if(e.done){return}if(!e.processClosed&&e.processExited){const t=`The STDIO streams did not close within ${e.delay/1e3} seconds of the exit event from process '${e.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;e._debug(t)}e._setResult()}}},4087:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Context=void 0;const r=a(7147);const i=a(2037);class Context{constructor(){var e,t,a;this.payload={};if(process.env.GITHUB_EVENT_PATH){if(r.existsSync(process.env.GITHUB_EVENT_PATH)){this.payload=JSON.parse(r.readFileSync(process.env.GITHUB_EVENT_PATH,{encoding:"utf8"}))}else{const e=process.env.GITHUB_EVENT_PATH;process.stdout.write(`GITHUB_EVENT_PATH ${e} does not exist${i.EOL}`)}}this.eventName=process.env.GITHUB_EVENT_NAME;this.sha=process.env.GITHUB_SHA;this.ref=process.env.GITHUB_REF;this.workflow=process.env.GITHUB_WORKFLOW;this.action=process.env.GITHUB_ACTION;this.actor=process.env.GITHUB_ACTOR;this.job=process.env.GITHUB_JOB;this.runNumber=parseInt(process.env.GITHUB_RUN_NUMBER,10);this.runId=parseInt(process.env.GITHUB_RUN_ID,10);this.apiUrl=(e=process.env.GITHUB_API_URL)!==null&&e!==void 0?e:`https://api.github.com`;this.serverUrl=(t=process.env.GITHUB_SERVER_URL)!==null&&t!==void 0?t:`https://github.com`;this.graphqlUrl=(a=process.env.GITHUB_GRAPHQL_URL)!==null&&a!==void 0?a:`https://api.github.com/graphql`}get issue(){const e=this.payload;return Object.assign(Object.assign({},this.repo),{number:(e.issue||e.pull_request||e).number})}get repo(){if(process.env.GITHUB_REPOSITORY){const[e,t]=process.env.GITHUB_REPOSITORY.split("/");return{owner:e,repo:t}}if(this.payload.repository){return{owner:this.payload.repository.owner.login,repo:this.payload.repository.name}}throw new Error("context.repo requires a GITHUB_REPOSITORY environment variable like 'owner/repo'")}}t.Context=Context},5438:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokit=t.context=void 0;const s=n(a(4087));const o=a(3030);t.context=new s.Context;function getOctokit(e,t,...a){const r=o.GitHub.plugin(...a);return new r(o.getOctokitOptions(e,t))}t.getOctokit=getOctokit},7914:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getApiBaseUrl=t.getProxyAgent=t.getAuthString=void 0;const s=n(a(6255));function getAuthString(e,t){if(!e&&!t.auth){throw new Error("Parameter token or opts.auth is required")}else if(e&&t.auth){throw new Error("Parameters token and opts.auth may not both be specified")}return typeof t.auth==="string"?t.auth:`token ${e}`}t.getAuthString=getAuthString;function getProxyAgent(e){const t=new s.HttpClient;return t.getAgent(e)}t.getProxyAgent=getProxyAgent;function getApiBaseUrl(){return process.env["GITHUB_API_URL"]||"https://api.github.com"}t.getApiBaseUrl=getApiBaseUrl},3030:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokitOptions=t.GitHub=t.defaults=t.context=void 0;const s=n(a(4087));const o=n(a(7914));const p=a(6762);const l=a(3044);const d=a(4193);t.context=new s.Context;const c=o.getApiBaseUrl();t.defaults={baseUrl:c,request:{agent:o.getProxyAgent(c)}};t.GitHub=p.Octokit.plugin(l.restEndpointMethods,d.paginateRest).defaults(t.defaults);function getOctokitOptions(e,t){const a=Object.assign({},t||{});const r=o.getAuthString(e,a);if(r){a.auth=r}return a}t.getOctokitOptions=getOctokitOptions},8090:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.create=void 0;const i=a(8298);function create(e,t){return r(this,void 0,void 0,(function*(){return yield i.DefaultGlobber.create(e,t)}))}t.create=create},1026:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOptions=void 0;const s=n(a(2186));function getOptions(e){const t={followSymbolicLinks:true,implicitDescendants:true,omitBrokenSymbolicLinks:true};if(e){if(typeof e.followSymbolicLinks==="boolean"){t.followSymbolicLinks=e.followSymbolicLinks;s.debug(`followSymbolicLinks '${t.followSymbolicLinks}'`)}if(typeof e.implicitDescendants==="boolean"){t.implicitDescendants=e.implicitDescendants;s.debug(`implicitDescendants '${t.implicitDescendants}'`)}if(typeof e.omitBrokenSymbolicLinks==="boolean"){t.omitBrokenSymbolicLinks=e.omitBrokenSymbolicLinks;s.debug(`omitBrokenSymbolicLinks '${t.omitBrokenSymbolicLinks}'`)}}return t}t.getOptions=getOptions},8298:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};var p=this&&this.__await||function(e){return this instanceof p?(this.v=e,this):new p(e)};var l=this&&this.__asyncGenerator||function(e,t,a){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=a.apply(e,t||[]),i,n=[];return i={},verb("next"),verb("throw"),verb("return"),i[Symbol.asyncIterator]=function(){return this},i;function verb(e){if(r[e])i[e]=function(t){return new Promise((function(a,r){n.push([e,t,a,r])>1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof p?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};Object.defineProperty(t,"__esModule",{value:true});t.DefaultGlobber=void 0;const d=n(a(2186));const c=n(a(7147));const m=n(a(1026));const u=n(a(1017));const h=n(a(9005));const g=a(1063);const y=a(4536);const v=a(9117);const b=process.platform==="win32";class DefaultGlobber{constructor(e){this.patterns=[];this.searchPaths=[];this.options=m.getOptions(e)}getSearchPaths(){return this.searchPaths.slice()}glob(){var e,t;return s(this,void 0,void 0,(function*(){const a=[];try{for(var r=o(this.globGenerator()),i;i=yield r.next(),!i.done;){const e=i.value;a.push(e)}}catch(t){e={error:t}}finally{try{if(i&&!i.done&&(t=r.return))yield t.call(r)}finally{if(e)throw e.error}}return a}))}globGenerator(){return l(this,arguments,(function*globGenerator_1(){const e=m.getOptions(this.options);const t=[];for(const a of this.patterns){t.push(a);if(e.implicitDescendants&&(a.trailingSeparator||a.segments[a.segments.length-1]!=="**")){t.push(new y.Pattern(a.negate,true,a.segments.concat("**")))}}const a=[];for(const e of h.getSearchPaths(t)){d.debug(`Search path '${e}'`);try{yield p(c.promises.lstat(e))}catch(e){if(e.code==="ENOENT"){continue}throw e}a.unshift(new v.SearchState(e,1))}const r=[];while(a.length){const i=a.pop();const n=h.match(t,i.path);const s=!!n||h.partialMatch(t,i.path);if(!n&&!s){continue}const o=yield p(DefaultGlobber.stat(i,e,r));if(!o){continue}if(o.isDirectory()){if(n&g.MatchKind.Directory){yield yield p(i.path)}else if(!s){continue}const e=i.level+1;const t=(yield p(c.promises.readdir(i.path))).map((t=>new v.SearchState(u.join(i.path,t),e)));a.push(...t.reverse())}else if(n&g.MatchKind.File){yield yield p(i.path)}}}))}static create(e,t){return s(this,void 0,void 0,(function*(){const a=new DefaultGlobber(t);if(b){e=e.replace(/\r\n/g,"\n");e=e.replace(/\r/g,"\n")}const r=e.split("\n").map((e=>e.trim()));for(const e of r){if(!e||e.startsWith("#")){continue}else{a.patterns.push(new y.Pattern(e))}}a.searchPaths.push(...h.getSearchPaths(a.patterns));return a}))}static stat(e,t,a){return s(this,void 0,void 0,(function*(){let r;if(t.followSymbolicLinks){try{r=yield c.promises.stat(e.path)}catch(a){if(a.code==="ENOENT"){if(t.omitBrokenSymbolicLinks){d.debug(`Broken symlink '${e.path}'`);return undefined}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw a}}else{r=yield c.promises.lstat(e.path)}if(r.isDirectory()&&t.followSymbolicLinks){const t=yield c.promises.realpath(e.path);while(a.length>=e.level){a.pop()}if(a.some((e=>e===t))){d.debug(`Symlink cycle detected for path '${e.path}' and realpath '${t}'`);return undefined}a.push(t)}return r}))}}t.DefaultGlobber=DefaultGlobber},1063:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MatchKind=void 0;var a;(function(e){e[e["None"]=0]="None";e[e["Directory"]=1]="Directory";e[e["File"]=2]="File";e[e["All"]=3]="All"})(a=t.MatchKind||(t.MatchKind={}))},1849:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.safeTrimTrailingSeparator=t.normalizeSeparators=t.hasRoot=t.hasAbsoluteRoot=t.ensureAbsoluteRoot=t.dirname=void 0;const o=n(a(1017));const p=s(a(9491));const l=process.platform==="win32";function dirname(e){e=safeTrimTrailingSeparator(e);if(l&&/^\\\\[^\\]+(\\[^\\]+)?$/.test(e)){return e}let t=o.dirname(e);if(l&&/^\\\\[^\\]+\\[^\\]+\\$/.test(t)){t=safeTrimTrailingSeparator(t)}return t}t.dirname=dirname;function ensureAbsoluteRoot(e,t){p.default(e,`ensureAbsoluteRoot parameter 'root' must not be empty`);p.default(t,`ensureAbsoluteRoot parameter 'itemPath' must not be empty`);if(hasAbsoluteRoot(t)){return t}if(l){if(t.match(/^[A-Z]:[^\\/]|^[A-Z]:$/i)){let e=process.cwd();p.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);if(t[0].toUpperCase()===e[0].toUpperCase()){if(t.length===2){return`${t[0]}:\\${e.substr(3)}`}else{if(!e.endsWith("\\")){e+="\\"}return`${t[0]}:\\${e.substr(3)}${t.substr(2)}`}}else{return`${t[0]}:\\${t.substr(2)}`}}else if(normalizeSeparators(t).match(/^\\$|^\\[^\\]/)){const e=process.cwd();p.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);return`${e[0]}:\\${t.substr(1)}`}}p.default(hasAbsoluteRoot(e),`ensureAbsoluteRoot parameter 'root' must have an absolute root`);if(e.endsWith("/")||l&&e.endsWith("\\")){}else{e+=o.sep}return e+t}t.ensureAbsoluteRoot=ensureAbsoluteRoot;function hasAbsoluteRoot(e){p.default(e,`hasAbsoluteRoot parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(l){return e.startsWith("\\\\")||/^[A-Z]:\\/i.test(e)}return e.startsWith("/")}t.hasAbsoluteRoot=hasAbsoluteRoot;function hasRoot(e){p.default(e,`isRooted parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(l){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.hasRoot=hasRoot;function normalizeSeparators(e){e=e||"";if(l){e=e.replace(/\//g,"\\");const t=/^\\\\+[^\\]/.test(e);return(t?"\\":"")+e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}t.normalizeSeparators=normalizeSeparators;function safeTrimTrailingSeparator(e){if(!e){return""}e=normalizeSeparators(e);if(!e.endsWith(o.sep)){return e}if(e===o.sep){return e}if(l&&/^[A-Z]:\\$/i.test(e)){return e}return e.substr(0,e.length-1)}t.safeTrimTrailingSeparator=safeTrimTrailingSeparator},6836:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Path=void 0;const o=n(a(1017));const p=n(a(1849));const l=s(a(9491));const d=process.platform==="win32";class Path{constructor(e){this.segments=[];if(typeof e==="string"){l.default(e,`Parameter 'itemPath' must not be empty`);e=p.safeTrimTrailingSeparator(e);if(!p.hasRoot(e)){this.segments=e.split(o.sep)}else{let t=e;let a=p.dirname(t);while(a!==t){const e=o.basename(t);this.segments.unshift(e);t=a;a=p.dirname(t)}this.segments.unshift(t)}}else{l.default(e.length>0,`Parameter 'itemPath' must not be an empty array`);for(let t=0;t!e.negate));const t={};for(const a of e){const e=p?a.searchPath.toUpperCase():a.searchPath;t[e]="candidate"}const a=[];for(const r of e){const e=p?r.searchPath.toUpperCase():r.searchPath;if(t[e]==="included"){continue}let i=false;let n=e;let o=s.dirname(n);while(o!==n){if(t[o]){i=true;break}n=o;o=s.dirname(n)}if(!i){a.push(r.searchPath);t[e]="included"}}return a}t.getSearchPaths=getSearchPaths;function match(e,t){let a=o.MatchKind.None;for(const r of e){if(r.negate){a&=~r.match(t)}else{a|=r.match(t)}}return a}t.match=match;function partialMatch(e,t){return e.some((e=>!e.negate&&e.partialMatch(t)))}t.partialMatch=partialMatch},4536:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Pattern=void 0;const o=n(a(2037));const p=n(a(1017));const l=n(a(1849));const d=s(a(9491));const c=a(3973);const m=a(1063);const u=a(6836);const h=process.platform==="win32";class Pattern{constructor(e,t=false,a,r){this.negate=false;let i;if(typeof e==="string"){i=e.trim()}else{a=a||[];d.default(a.length,`Parameter 'segments' must not empty`);const t=Pattern.getLiteral(a[0]);d.default(t&&l.hasAbsoluteRoot(t),`Parameter 'segments' first element must be a root path`);i=new u.Path(a).toString().trim();if(e){i=`!${i}`}}while(i.startsWith("!")){this.negate=!this.negate;i=i.substr(1).trim()}i=Pattern.fixupPattern(i,r);this.segments=new u.Path(i).segments;this.trailingSeparator=l.normalizeSeparators(i).endsWith(p.sep);i=l.safeTrimTrailingSeparator(i);let n=false;const s=this.segments.map((e=>Pattern.getLiteral(e))).filter((e=>!n&&!(n=e==="")));this.searchPath=new u.Path(s).toString();this.rootRegExp=new RegExp(Pattern.regExpEscape(s[0]),h?"i":"");this.isImplicitPattern=t;const o={dot:true,nobrace:true,nocase:h,nocomment:true,noext:true,nonegate:true};i=h?i.replace(/\\/g,"/"):i;this.minimatch=new c.Minimatch(i,o)}match(e){if(this.segments[this.segments.length-1]==="**"){e=l.normalizeSeparators(e);if(!e.endsWith(p.sep)&&this.isImplicitPattern===false){e=`${e}${p.sep}`}}else{e=l.safeTrimTrailingSeparator(e)}if(this.minimatch.match(e)){return this.trailingSeparator?m.MatchKind.Directory:m.MatchKind.All}return m.MatchKind.None}partialMatch(e){e=l.safeTrimTrailingSeparator(e);if(l.dirname(e)===e){return this.rootRegExp.test(e)}return this.minimatch.matchOne(e.split(h?/\\+/:/\/+/),this.minimatch.set[0],true)}static globEscape(e){return(h?e:e.replace(/\\/g,"\\\\")).replace(/(\[)(?=[^/]+\])/g,"[[]").replace(/\?/g,"[?]").replace(/\*/g,"[*]")}static fixupPattern(e,t){d.default(e,"pattern cannot be empty");const a=new u.Path(e).segments.map((e=>Pattern.getLiteral(e)));d.default(a.every(((e,t)=>(e!=="."||t===0)&&e!=="..")),`Invalid pattern '${e}'. Relative pathing '.' and '..' is not allowed.`);d.default(!l.hasRoot(e)||a[0],`Invalid pattern '${e}'. Root segment must not contain globs.`);e=l.normalizeSeparators(e);if(e==="."||e.startsWith(`.${p.sep}`)){e=Pattern.globEscape(process.cwd())+e.substr(1)}else if(e==="~"||e.startsWith(`~${p.sep}`)){t=t||o.homedir();d.default(t,"Unable to determine HOME directory");d.default(l.hasAbsoluteRoot(t),`Expected HOME directory to be a rooted path. Actual '${t}'`);e=Pattern.globEscape(t)+e.substr(1)}else if(h&&(e.match(/^[A-Z]:$/i)||e.match(/^[A-Z]:[^\\]/i))){let t=l.ensureAbsoluteRoot("C:\\dummy-root",e.substr(0,2));if(e.length>2&&!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(2)}else if(h&&(e==="\\"||e.match(/^\\[^\\]/))){let t=l.ensureAbsoluteRoot("C:\\dummy-root","\\");if(!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(1)}else{e=l.ensureAbsoluteRoot(Pattern.globEscape(process.cwd()),e)}return l.normalizeSeparators(e)}static getLiteral(e){let t="";for(let a=0;a=0){if(r.length>1){return""}if(r){t+=r;a=i;continue}}}t+=r}return t}static regExpEscape(e){return e.replace(/[[\\^$.|?*+()]/g,"\\$&")}}t.Pattern=Pattern},9117:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SearchState=void 0;class SearchState{constructor(e,t){this.path=e;this.level=t}}t.SearchState=SearchState},5526:function(e,t){"use strict";var a=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.PersonalAccessTokenCredentialHandler=t.BearerCredentialHandler=t.BasicCredentialHandler=void 0;class BasicCredentialHandler{constructor(e,t){this.username=e;this.password=t}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`${this.username}:${this.password}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.BasicCredentialHandler=BasicCredentialHandler;class BearerCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Bearer ${this.token}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.BearerCredentialHandler=BearerCredentialHandler;class PersonalAccessTokenCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`PAT:${this.token}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.PersonalAccessTokenCredentialHandler=PersonalAccessTokenCredentialHandler},6255:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.HttpClient=t.isHttps=t.HttpClientResponse=t.HttpClientError=t.getProxyUrl=t.MediaTypes=t.Headers=t.HttpCodes=void 0;const o=n(a(3685));const p=n(a(5687));const l=n(a(9835));const d=n(a(4294));var c;(function(e){e[e["OK"]=200]="OK";e[e["MultipleChoices"]=300]="MultipleChoices";e[e["MovedPermanently"]=301]="MovedPermanently";e[e["ResourceMoved"]=302]="ResourceMoved";e[e["SeeOther"]=303]="SeeOther";e[e["NotModified"]=304]="NotModified";e[e["UseProxy"]=305]="UseProxy";e[e["SwitchProxy"]=306]="SwitchProxy";e[e["TemporaryRedirect"]=307]="TemporaryRedirect";e[e["PermanentRedirect"]=308]="PermanentRedirect";e[e["BadRequest"]=400]="BadRequest";e[e["Unauthorized"]=401]="Unauthorized";e[e["PaymentRequired"]=402]="PaymentRequired";e[e["Forbidden"]=403]="Forbidden";e[e["NotFound"]=404]="NotFound";e[e["MethodNotAllowed"]=405]="MethodNotAllowed";e[e["NotAcceptable"]=406]="NotAcceptable";e[e["ProxyAuthenticationRequired"]=407]="ProxyAuthenticationRequired";e[e["RequestTimeout"]=408]="RequestTimeout";e[e["Conflict"]=409]="Conflict";e[e["Gone"]=410]="Gone";e[e["TooManyRequests"]=429]="TooManyRequests";e[e["InternalServerError"]=500]="InternalServerError";e[e["NotImplemented"]=501]="NotImplemented";e[e["BadGateway"]=502]="BadGateway";e[e["ServiceUnavailable"]=503]="ServiceUnavailable";e[e["GatewayTimeout"]=504]="GatewayTimeout"})(c=t.HttpCodes||(t.HttpCodes={}));var m;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(m=t.Headers||(t.Headers={}));var u;(function(e){e["ApplicationJson"]="application/json"})(u=t.MediaTypes||(t.MediaTypes={}));function getProxyUrl(e){const t=l.getProxyUrl(new URL(e));return t?t.href:""}t.getProxyUrl=getProxyUrl;const h=[c.MovedPermanently,c.ResourceMoved,c.SeeOther,c.TemporaryRedirect,c.PermanentRedirect];const g=[c.BadGateway,c.ServiceUnavailable,c.GatewayTimeout];const y=["OPTIONS","GET","DELETE","HEAD"];const v=10;const b=5;class HttpClientError extends Error{constructor(e,t){super(e);this.name="HttpClientError";this.statusCode=t;Object.setPrototypeOf(this,HttpClientError.prototype)}}t.HttpClientError=HttpClientError;class HttpClientResponse{constructor(e){this.message=e}readBody(){return s(this,void 0,void 0,(function*(){return new Promise((e=>s(this,void 0,void 0,(function*(){let t=Buffer.alloc(0);this.message.on("data",(e=>{t=Buffer.concat([t,e])}));this.message.on("end",(()=>{e(t.toString())}))}))))}))}readBodyBuffer(){return s(this,void 0,void 0,(function*(){return new Promise((e=>s(this,void 0,void 0,(function*(){const t=[];this.message.on("data",(e=>{t.push(e)}));this.message.on("end",(()=>{e(Buffer.concat(t))}))}))))}))}}t.HttpClientResponse=HttpClientResponse;function isHttps(e){const t=new URL(e);return t.protocol==="https:"}t.isHttps=isHttps;class HttpClient{constructor(e,t,a){this._ignoreSslError=false;this._allowRedirects=true;this._allowRedirectDowngrade=false;this._maxRedirects=50;this._allowRetries=false;this._maxRetries=1;this._keepAlive=false;this._disposed=false;this.userAgent=e;this.handlers=t||[];this.requestOptions=a;if(a){if(a.ignoreSslError!=null){this._ignoreSslError=a.ignoreSslError}this._socketTimeout=a.socketTimeout;if(a.allowRedirects!=null){this._allowRedirects=a.allowRedirects}if(a.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=a.allowRedirectDowngrade}if(a.maxRedirects!=null){this._maxRedirects=Math.max(a.maxRedirects,0)}if(a.keepAlive!=null){this._keepAlive=a.keepAlive}if(a.allowRetries!=null){this._allowRetries=a.allowRetries}if(a.maxRetries!=null){this._maxRetries=a.maxRetries}}}options(e,t){return s(this,void 0,void 0,(function*(){return this.request("OPTIONS",e,null,t||{})}))}get(e,t){return s(this,void 0,void 0,(function*(){return this.request("GET",e,null,t||{})}))}del(e,t){return s(this,void 0,void 0,(function*(){return this.request("DELETE",e,null,t||{})}))}post(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("POST",e,t,a||{})}))}patch(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("PATCH",e,t,a||{})}))}put(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("PUT",e,t,a||{})}))}head(e,t){return s(this,void 0,void 0,(function*(){return this.request("HEAD",e,null,t||{})}))}sendStream(e,t,a,r){return s(this,void 0,void 0,(function*(){return this.request(e,t,a,r)}))}getJson(e,t={}){return s(this,void 0,void 0,(function*(){t[m.Accept]=this._getExistingOrDefaultHeader(t,m.Accept,u.ApplicationJson);const a=yield this.get(e,t);return this._processResponse(a,this.requestOptions)}))}postJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.post(e,r,a);return this._processResponse(i,this.requestOptions)}))}putJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.put(e,r,a);return this._processResponse(i,this.requestOptions)}))}patchJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.patch(e,r,a);return this._processResponse(i,this.requestOptions)}))}request(e,t,a,r){return s(this,void 0,void 0,(function*(){if(this._disposed){throw new Error("Client has already been disposed.")}const i=new URL(t);let n=this._prepareRequest(e,i,r);const s=this._allowRetries&&y.includes(e)?this._maxRetries+1:1;let o=0;let p;do{p=yield this.requestRaw(n,a);if(p&&p.message&&p.message.statusCode===c.Unauthorized){let e;for(const t of this.handlers){if(t.canHandleAuthentication(p)){e=t;break}}if(e){return e.handleAuthentication(this,n,a)}else{return p}}let t=this._maxRedirects;while(p.message.statusCode&&h.includes(p.message.statusCode)&&this._allowRedirects&&t>0){const s=p.message.headers["location"];if(!s){break}const o=new URL(s);if(i.protocol==="https:"&&i.protocol!==o.protocol&&!this._allowRedirectDowngrade){throw new Error("Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.")}yield p.readBody();if(o.hostname!==i.hostname){for(const e in r){if(e.toLowerCase()==="authorization"){delete r[e]}}}n=this._prepareRequest(e,o,r);p=yield this.requestRaw(n,a);t--}if(!p.message.statusCode||!g.includes(p.message.statusCode)){return p}o+=1;if(o{function callbackForResult(e,t){if(e){r(e)}else if(!t){r(new Error("Unknown error"))}else{a(t)}}this.requestRawWithCallback(e,t,callbackForResult)}))}))}requestRawWithCallback(e,t,a){if(typeof t==="string"){if(!e.options.headers){e.options.headers={}}e.options.headers["Content-Length"]=Buffer.byteLength(t,"utf8")}let r=false;function handleResult(e,t){if(!r){r=true;a(e,t)}}const i=e.httpModule.request(e.options,(e=>{const t=new HttpClientResponse(e);handleResult(undefined,t)}));let n;i.on("socket",(e=>{n=e}));i.setTimeout(this._socketTimeout||3*6e4,(()=>{if(n){n.end()}handleResult(new Error(`Request timeout: ${e.options.path}`))}));i.on("error",(function(e){handleResult(e)}));if(t&&typeof t==="string"){i.write(t,"utf8")}if(t&&typeof t!=="string"){t.on("close",(function(){i.end()}));t.pipe(i)}else{i.end()}}getAgent(e){const t=new URL(e);return this._getAgent(t)}_prepareRequest(e,t,a){const r={};r.parsedUrl=t;const i=r.parsedUrl.protocol==="https:";r.httpModule=i?p:o;const n=i?443:80;r.options={};r.options.host=r.parsedUrl.hostname;r.options.port=r.parsedUrl.port?parseInt(r.parsedUrl.port):n;r.options.path=(r.parsedUrl.pathname||"")+(r.parsedUrl.search||"");r.options.method=e;r.options.headers=this._mergeHeaders(a);if(this.userAgent!=null){r.options.headers["user-agent"]=this.userAgent}r.options.agent=this._getAgent(r.parsedUrl);if(this.handlers){for(const e of this.handlers){e.prepareRequest(r.options)}}return r}_mergeHeaders(e){if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},lowercaseKeys(this.requestOptions.headers),lowercaseKeys(e||{}))}return lowercaseKeys(e||{})}_getExistingOrDefaultHeader(e,t,a){let r;if(this.requestOptions&&this.requestOptions.headers){r=lowercaseKeys(this.requestOptions.headers)[t]}return e[t]||r||a}_getAgent(e){let t;const a=l.getProxyUrl(e);const r=a&&a.hostname;if(this._keepAlive&&r){t=this._proxyAgent}if(this._keepAlive&&!r){t=this._agent}if(t){return t}const i=e.protocol==="https:";let n=100;if(this.requestOptions){n=this.requestOptions.maxSockets||o.globalAgent.maxSockets}if(a&&a.hostname){const e={maxSockets:n,keepAlive:this._keepAlive,proxy:Object.assign(Object.assign({},(a.username||a.password)&&{proxyAuth:`${a.username}:${a.password}`}),{host:a.hostname,port:a.port})};let r;const s=a.protocol==="https:";if(i){r=s?d.httpsOverHttps:d.httpsOverHttp}else{r=s?d.httpOverHttps:d.httpOverHttp}t=r(e);this._proxyAgent=t}if(this._keepAlive&&!t){const e={keepAlive:this._keepAlive,maxSockets:n};t=i?new p.Agent(e):new o.Agent(e);this._agent=t}if(!t){t=i?p.globalAgent:o.globalAgent}if(i&&this._ignoreSslError){t.options=Object.assign(t.options||{},{rejectUnauthorized:false})}return t}_performExponentialBackoff(e){return s(this,void 0,void 0,(function*(){e=Math.min(v,e);const t=b*Math.pow(2,e);return new Promise((e=>setTimeout((()=>e()),t)))}))}_processResponse(e,t){return s(this,void 0,void 0,(function*(){return new Promise(((a,r)=>s(this,void 0,void 0,(function*(){const i=e.message.statusCode||0;const n={statusCode:i,result:null,headers:{}};if(i===c.NotFound){a(n)}function dateTimeDeserializer(e,t){if(typeof t==="string"){const e=new Date(t);if(!isNaN(e.valueOf())){return e}}return t}let s;let o;try{o=yield e.readBody();if(o&&o.length>0){if(t&&t.deserializeDates){s=JSON.parse(o,dateTimeDeserializer)}else{s=JSON.parse(o)}n.result=s}n.headers=e.message.headers}catch(e){}if(i>299){let e;if(s&&s.message){e=s.message}else if(o&&o.length>0){e=o}else{e=`Failed request: (${i})`}const t=new HttpClientError(e,i);t.result=n.result;r(t)}else{a(n)}}))))}))}}t.HttpClient=HttpClient;const lowercaseKeys=e=>Object.keys(e).reduce(((t,a)=>(t[a.toLowerCase()]=e[a],t)),{})},9835:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.checkBypass=t.getProxyUrl=void 0;function getProxyUrl(e){const t=e.protocol==="https:";if(checkBypass(e)){return undefined}const a=(()=>{if(t){return process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{return process.env["http_proxy"]||process.env["HTTP_PROXY"]}})();if(a){try{return new URL(a)}catch(e){if(!a.startsWith("http://")&&!a.startsWith("https://"))return new URL(`http://${a}`)}}else{return undefined}}t.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}const t=e.hostname;if(isLoopbackAddress(t)){return true}const a=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!a){return false}let r;if(e.port){r=Number(e.port)}else if(e.protocol==="http:"){r=80}else if(e.protocol==="https:"){r=443}const i=[e.hostname.toUpperCase()];if(typeof r==="number"){i.push(`${i[0]}:${r}`)}for(const e of a.split(",").map((e=>e.trim().toUpperCase())).filter((e=>e))){if(e==="*"||i.some((t=>t===e||t.endsWith(`.${e}`)||e.startsWith(".")&&t.endsWith(`${e}`)))){return true}}return false}t.checkBypass=checkBypass;function isLoopbackAddress(e){const t=e.toLowerCase();return t==="localhost"||t.startsWith("127.")||t.startsWith("[::1]")||t.startsWith("[0:0:0:0:0:0:0:1]")}},1962:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o;Object.defineProperty(t,"__esModule",{value:true});t.getCmdPath=t.tryGetExecutablePath=t.isRooted=t.isDirectory=t.exists=t.READONLY=t.UV_FS_O_EXLOCK=t.IS_WINDOWS=t.unlink=t.symlink=t.stat=t.rmdir=t.rm=t.rename=t.readlink=t.readdir=t.open=t.mkdir=t.lstat=t.copyFile=t.chmod=void 0;const p=n(a(7147));const l=n(a(1017));o=p.promises,t.chmod=o.chmod,t.copyFile=o.copyFile,t.lstat=o.lstat,t.mkdir=o.mkdir,t.open=o.open,t.readdir=o.readdir,t.readlink=o.readlink,t.rename=o.rename,t.rm=o.rm,t.rmdir=o.rmdir,t.stat=o.stat,t.symlink=o.symlink,t.unlink=o.unlink;t.IS_WINDOWS=process.platform==="win32";t.UV_FS_O_EXLOCK=268435456;t.READONLY=p.constants.O_RDONLY;function exists(e){return s(this,void 0,void 0,(function*(){try{yield t.stat(e)}catch(e){if(e.code==="ENOENT"){return false}throw e}return true}))}t.exists=exists;function isDirectory(e,a=false){return s(this,void 0,void 0,(function*(){const r=a?yield t.stat(e):yield t.lstat(e);return r.isDirectory()}))}t.isDirectory=isDirectory;function isRooted(e){e=normalizeSeparators(e);if(!e){throw new Error('isRooted() parameter "p" cannot be empty')}if(t.IS_WINDOWS){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.isRooted=isRooted;function tryGetExecutablePath(e,a){return s(this,void 0,void 0,(function*(){let r=undefined;try{r=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(r&&r.isFile()){if(t.IS_WINDOWS){const t=l.extname(e).toUpperCase();if(a.some((e=>e.toUpperCase()===t))){return e}}else{if(isUnixExecutable(r)){return e}}}const i=e;for(const n of a){e=i+n;r=undefined;try{r=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(r&&r.isFile()){if(t.IS_WINDOWS){try{const a=l.dirname(e);const r=l.basename(e).toUpperCase();for(const i of yield t.readdir(a)){if(r===i.toUpperCase()){e=l.join(a,i);break}}}catch(t){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${t}`)}return e}else{if(isUnixExecutable(r)){return e}}}}return""}))}t.tryGetExecutablePath=tryGetExecutablePath;function normalizeSeparators(e){e=e||"";if(t.IS_WINDOWS){e=e.replace(/\//g,"\\");return e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}function isUnixExecutable(e){return(e.mode&1)>0||(e.mode&8)>0&&e.gid===process.getgid()||(e.mode&64)>0&&e.uid===process.getuid()}function getCmdPath(){var e;return(e=process.env["COMSPEC"])!==null&&e!==void 0?e:`cmd.exe`}t.getCmdPath=getCmdPath},7436:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.findInPath=t.which=t.mkdirP=t.rmRF=t.mv=t.cp=void 0;const o=a(9491);const p=n(a(1017));const l=n(a(1962));function cp(e,t,a={}){return s(this,void 0,void 0,(function*(){const{force:r,recursive:i,copySourceDirectory:n}=readCopyOptions(a);const s=(yield l.exists(t))?yield l.stat(t):null;if(s&&s.isFile()&&!r){return}const o=s&&s.isDirectory()&&n?p.join(t,p.basename(e)):t;if(!(yield l.exists(e))){throw new Error(`no such file or directory: ${e}`)}const d=yield l.stat(e);if(d.isDirectory()){if(!i){throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`)}else{yield cpDirRecursive(e,o,0,r)}}else{if(p.relative(e,o)===""){throw new Error(`'${o}' and '${e}' are the same file`)}yield copyFile(e,o,r)}}))}t.cp=cp;function mv(e,t,a={}){return s(this,void 0,void 0,(function*(){if(yield l.exists(t)){let r=true;if(yield l.isDirectory(t)){t=p.join(t,p.basename(e));r=yield l.exists(t)}if(r){if(a.force==null||a.force){yield rmRF(t)}else{throw new Error("Destination already exists")}}}yield mkdirP(p.dirname(t));yield l.rename(e,t)}))}t.mv=mv;function rmRF(e){return s(this,void 0,void 0,(function*(){if(l.IS_WINDOWS){if(/[*"<>|]/.test(e)){throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows')}}try{yield l.rm(e,{force:true,maxRetries:3,recursive:true,retryDelay:300})}catch(e){throw new Error(`File was unable to be removed ${e}`)}}))}t.rmRF=rmRF;function mkdirP(e){return s(this,void 0,void 0,(function*(){o.ok(e,"a path argument must be provided");yield l.mkdir(e,{recursive:true})}))}t.mkdirP=mkdirP;function which(e,t){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}if(t){const t=yield which(e,false);if(!t){if(l.IS_WINDOWS){throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`)}else{throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`)}}return t}const a=yield findInPath(e);if(a&&a.length>0){return a[0]}return""}))}t.which=which;function findInPath(e){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}const t=[];if(l.IS_WINDOWS&&process.env["PATHEXT"]){for(const e of process.env["PATHEXT"].split(p.delimiter)){if(e){t.push(e)}}}if(l.isRooted(e)){const a=yield l.tryGetExecutablePath(e,t);if(a){return[a]}return[]}if(e.includes(p.sep)){return[]}const a=[];if(process.env.PATH){for(const e of process.env.PATH.split(p.delimiter)){if(e){a.push(e)}}}const r=[];for(const i of a){const a=yield l.tryGetExecutablePath(p.join(i,e),t);if(a){r.push(a)}}return r}))}t.findInPath=findInPath;function readCopyOptions(e){const t=e.force==null?true:e.force;const a=Boolean(e.recursive);const r=e.copySourceDirectory==null?true:Boolean(e.copySourceDirectory);return{force:t,recursive:a,copySourceDirectory:r}}function cpDirRecursive(e,t,a,r){return s(this,void 0,void 0,(function*(){if(a>=255)return;a++;yield mkdirP(t);const i=yield l.readdir(e);for(const n of i){const i=`${e}/${n}`;const s=`${t}/${n}`;const o=yield l.lstat(i);if(o.isDirectory()){yield cpDirRecursive(i,s,a,r)}else{yield copyFile(i,s,r)}}yield l.chmod(t,(yield l.stat(e)).mode)}))}function copyFile(e,t,a){return s(this,void 0,void 0,(function*(){if((yield l.lstat(e)).isSymbolicLink()){try{yield l.lstat(t);yield l.unlink(t)}catch(e){if(e.code==="EPERM"){yield l.chmod(t,"0666");yield l.unlink(t)}}const a=yield l.readlink(e);yield l.symlink(a,t,l.IS_WINDOWS?"junction":null)}else if(!(yield l.exists(t))||a){yield l.copyFile(e,t)}}))}},2557:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a=new WeakMap;const r=new WeakMap;class AbortSignal{constructor(){this.onabort=null;a.set(this,[]);r.set(this,false)}get aborted(){if(!r.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}return r.get(this)}static get none(){return new AbortSignal}addEventListener(e,t){if(!a.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}const r=a.get(this);r.push(t)}removeEventListener(e,t){if(!a.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}const r=a.get(this);const i=r.indexOf(t);if(i>-1){r.splice(i,1)}}dispatchEvent(e){throw new Error("This is a stub dispatchEvent implementation that should not be used. It only exists for type-checking purposes.")}}function abortSignal(e){if(e.aborted){return}if(e.onabort){e.onabort.call(e)}const t=a.get(e);if(t){t.slice().forEach((t=>{t.call(e,{type:"abort"})}))}r.set(e,true)}class AbortError extends Error{constructor(e){super(e);this.name="AbortError"}}class AbortController{constructor(e){this._signal=new AbortSignal;if(!e){return}if(!Array.isArray(e)){e=arguments}for(const t of e){if(t.aborted){this.abort()}else{t.addEventListener("abort",(()=>{this.abort()}))}}}get signal(){return this._signal}abort(){abortSignal(this._signal)}static timeout(e){const t=new AbortSignal;const a=setTimeout(abortSignal,e,t);if(typeof a.unref==="function"){a.unref()}return t}}t.AbortController=AbortController;t.AbortError=AbortError;t.AbortSignal=AbortSignal},9645:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(1333);class AzureKeyCredential{get key(){return this._key}constructor(e){if(!e){throw new Error("key must be a non-empty string")}this._key=e}update(e){this._key=e}}class AzureNamedKeyCredential{get key(){return this._key}get name(){return this._name}constructor(e,t){if(!e||!t){throw new TypeError("name and key must be non-empty strings")}this._name=e;this._key=t}update(e,t){if(!e||!t){throw new TypeError("newName and newKey must be non-empty strings")}this._name=e;this._key=t}}function isNamedKeyCredential(e){return r.isObjectWithProperties(e,["name","key"])&&typeof e.key==="string"&&typeof e.name==="string"}class AzureSASCredential{get signature(){return this._signature}constructor(e){if(!e){throw new Error("shared access signature must be a non-empty string")}this._signature=e}update(e){if(!e){throw new Error("shared access signature must be a non-empty string")}this._signature=e}}function isSASCredential(e){return r.isObjectWithProperties(e,["signature"])&&typeof e.signature==="string"}function isTokenCredential(e){const t=e;return t&&typeof t.getToken==="function"&&(t.signRequest===undefined||t.getToken.length>0)}t.AzureKeyCredential=AzureKeyCredential;t.AzureNamedKeyCredential=AzureNamedKeyCredential;t.AzureSASCredential=AzureSASCredential;t.isNamedKeyCredential=isNamedKeyCredential;t.isSASCredential=isSASCredential;t.isTokenCredential=isTokenCredential},4607:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5840);var i=a(3837);var n=a(2107);var s=a(6189);var o=a(1333);var p=a(3233);var l=a(9645);var d=a(2037);var c=a(3685);var m=a(5687);var u=a(2557);var h=a(4294);var g=a(2781);var y=a(6279);var v=a(467);var b=a(4175);function _interopDefaultLegacy(e){return e&&typeof e==="object"&&"default"in e?e:{default:e}}function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(a){if(a!=="default"){var r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:true,get:function(){return e[a]}})}}))}t["default"]=e;return Object.freeze(t)}var x=_interopNamespace(s);var w=_interopNamespace(d);var S=_interopNamespace(c);var N=_interopNamespace(m);var T=_interopNamespace(h);var E=_interopDefaultLegacy(y);var _=_interopDefaultLegacy(v);function getHeaderKey(e){return e.toLowerCase()}function isHttpHeadersLike(e){if(e&&typeof e==="object"){const t=e;if(typeof t.rawHeaders==="function"&&typeof t.clone==="function"&&typeof t.get==="function"&&typeof t.set==="function"&&typeof t.contains==="function"&&typeof t.remove==="function"&&typeof t.headersArray==="function"&&typeof t.headerValues==="function"&&typeof t.headerNames==="function"&&typeof t.toJson==="function"){return true}}return false}class HttpHeaders{constructor(e){this._headersMap={};if(e){for(const t in e){this.set(t,e[t])}}}set(e,t){this._headersMap[getHeaderKey(e)]={name:e,value:t.toString()}}get(e){const t=this._headersMap[getHeaderKey(e)];return!t?undefined:t.value}contains(e){return!!this._headersMap[getHeaderKey(e)]}remove(e){const t=this.contains(e);delete this._headersMap[getHeaderKey(e)];return t}rawHeaders(){return this.toJson({preserveCase:true})}headersArray(){const e=[];for(const t in this._headersMap){e.push(this._headersMap[t])}return e}headerNames(){const e=[];const t=this.headersArray();for(let a=0;a{a=a.then(e)}));return a}function promiseToCallback(e){if(typeof e.then!=="function"){throw new Error("The provided input is not a Promise.")}return t=>{e.then((e=>t(undefined,e))).catch((e=>{t(e)}))}}function promiseToServiceCallback(e){if(typeof e.then!=="function"){throw new Error("The provided input is not a Promise.")}return t=>{e.then((e=>process.nextTick(t,undefined,e.parsedBody,e.request,e))).catch((e=>{process.nextTick(t,e)}))}}function prepareXMLRootList(e,t,a,r){if(!Array.isArray(e)){e=[e]}if(!a||!r){return{[t]:e}}const i={[t]:e};i[C]={[a]:r};return i}function applyMixins(e,t){const a=e;t.forEach((e=>{Object.getOwnPropertyNames(e.prototype).forEach((t=>{a.prototype[t]=e.prototype[t]}))}))}const D=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function isDuration(e){return D.test(e)}function replaceAll(e,t,a){return!e||!t?e:e.split(t).join(a||"")}function isPrimitiveType(e){return typeof e!=="object"&&typeof e!=="function"||e===null}function getEnvironmentValue(e){if(process.env[e]){return process.env[e]}else if(process.env[e.toLowerCase()]){return process.env[e.toLowerCase()]}return undefined}function isObject(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}class Serializer{constructor(e={},t){this.modelMappers=e;this.isXML=t}validateConstraints(e,t,a){const failValidation=(e,r)=>{throw new Error(`"${a}" with value "${t}" should satisfy the constraint "${e}": ${r}.`)};if(e.constraints&&t!=undefined){const a=t;const{ExclusiveMaximum:r,ExclusiveMinimum:i,InclusiveMaximum:n,InclusiveMinimum:s,MaxItems:o,MaxLength:p,MinItems:l,MinLength:d,MultipleOf:c,Pattern:m,UniqueItems:u}=e.constraints;if(r!=undefined&&a>=r){failValidation("ExclusiveMaximum",r)}if(i!=undefined&&a<=i){failValidation("ExclusiveMinimum",i)}if(n!=undefined&&a>n){failValidation("InclusiveMaximum",n)}if(s!=undefined&&ao){failValidation("MaxItems",o)}if(p!=undefined&&h.length>p){failValidation("MaxLength",p)}if(l!=undefined&&h.lengtha.indexOf(e)!==t))){failValidation("UniqueItems",u)}}}serialize(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};let p={};const l=e.type.name;if(!a){a=e.serializedName}if(l.match(/^Sequence$/i)!==null){p=[]}if(e.isConstant){t=e.defaultValue}const{required:d,nullable:c}=e;if(d&&c&&t===undefined){throw new Error(`${a} cannot be undefined.`)}if(d&&!c&&t==undefined){throw new Error(`${a} cannot be null or undefined.`)}if(!d&&c===false&&t===null){throw new Error(`${a} cannot be null.`)}if(t==undefined){p=t}else{if(l.match(/^any$/i)!==null){p=t}else if(l.match(/^(Number|String|Boolean|Object|Stream|Uuid)$/i)!==null){p=serializeBasicTypes(l,a,t)}else if(l.match(/^Enum$/i)!==null){const r=e;p=serializeEnumType(a,r.type.allowedValues,t)}else if(l.match(/^(Date|DateTime|TimeSpan|DateTimeRfc1123|UnixTime)$/i)!==null){p=serializeDateTypes(l,t,a)}else if(l.match(/^ByteArray$/i)!==null){p=serializeByteArrayType(a,t)}else if(l.match(/^Base64Url$/i)!==null){p=serializeBase64UrlType(a,t)}else if(l.match(/^Sequence$/i)!==null){p=serializeSequenceType(this,e,t,a,Boolean(this.isXML),o)}else if(l.match(/^Dictionary$/i)!==null){p=serializeDictionaryType(this,e,t,a,Boolean(this.isXML),o)}else if(l.match(/^Composite$/i)!==null){p=serializeCompositeType(this,e,t,a,Boolean(this.isXML),o)}}return p}deserialize(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};if(t==undefined){if(this.isXML&&e.type.name==="Sequence"&&!e.xmlIsWrapped){t=[]}if(e.defaultValue!==undefined){t=e.defaultValue}return t}let p;const l=e.type.name;if(!a){a=e.serializedName}if(l.match(/^Composite$/i)!==null){p=deserializeCompositeType(this,e,t,a,o)}else{if(this.isXML){const e=o.xmlCharKey;const a=t;if(a[C]!=undefined&&a[e]!=undefined){t=a[e]}}if(l.match(/^Number$/i)!==null){p=parseFloat(t);if(isNaN(p)){p=t}}else if(l.match(/^Boolean$/i)!==null){if(t==="true"){p=true}else if(t==="false"){p=false}else{p=t}}else if(l.match(/^(String|Enum|Object|Stream|Uuid|TimeSpan|any)$/i)!==null){p=t}else if(l.match(/^(Date|DateTime|DateTimeRfc1123)$/i)!==null){p=new Date(t)}else if(l.match(/^UnixTime$/i)!==null){p=unixTimeToDate(t)}else if(l.match(/^ByteArray$/i)!==null){p=decodeString(t)}else if(l.match(/^Base64Url$/i)!==null){p=base64UrlToByteArray(t)}else if(l.match(/^Sequence$/i)!==null){p=deserializeSequenceType(this,e,t,a,o)}else if(l.match(/^Dictionary$/i)!==null){p=deserializeDictionaryType(this,e,t,a,o)}}if(e.isConstant){p=e.defaultValue}return p}}function trimEnd(e,t){let a=e.length;while(a-1>=0&&e[a-1]===t){--a}return e.substr(0,a)}function bufferToBase64Url(e){if(!e){return undefined}if(!(e instanceof Uint8Array)){throw new Error(`Please provide an input of type Uint8Array for converting to Base64Url.`)}const t=encodeByteArray(e);return trimEnd(t,"=").replace(/\+/g,"-").replace(/\//g,"_")}function base64UrlToByteArray(e){if(!e){return undefined}if(e&&typeof e.valueOf()!=="string"){throw new Error("Please provide an input of type string for converting to Uint8Array")}e=e.replace(/-/g,"+").replace(/_/g,"/");return decodeString(e)}function splitSerializeName(e){const t=[];let a="";if(e){const r=e.split(".");for(const e of r){if(e.charAt(e.length-1)==="\\"){a+=e.substr(0,e.length-1)+"."}else{a+=e;t.push(a);a=""}}}return t}function dateToUnixTime(e){if(!e){return undefined}if(typeof e.valueOf()==="string"){e=new Date(e)}return Math.floor(e.getTime()/1e3)}function unixTimeToDate(e){if(!e){return undefined}return new Date(e*1e3)}function serializeBasicTypes(e,t,a){if(a!==null&&a!==undefined){if(e.match(/^Number$/i)!==null){if(typeof a!=="number"){throw new Error(`${t} with value ${a} must be of type number.`)}}else if(e.match(/^String$/i)!==null){if(typeof a.valueOf()!=="string"){throw new Error(`${t} with value "${a}" must be of type string.`)}}else if(e.match(/^Uuid$/i)!==null){if(!(typeof a.valueOf()==="string"&&isValidUuid(a))){throw new Error(`${t} with value "${a}" must be of type string and a valid uuid.`)}}else if(e.match(/^Boolean$/i)!==null){if(typeof a!=="boolean"){throw new Error(`${t} with value ${a} must be of type boolean.`)}}else if(e.match(/^Stream$/i)!==null){const e=typeof a;if(e!=="string"&&e!=="function"&&!(a instanceof ArrayBuffer)&&!ArrayBuffer.isView(a)&&!((typeof Blob==="function"||typeof Blob==="object")&&a instanceof Blob)){throw new Error(`${t} must be a string, Blob, ArrayBuffer, ArrayBufferView, or a function returning NodeJS.ReadableStream.`)}}}return a}function serializeEnumType(e,t,a){if(!t){throw new Error(`Please provide a set of allowedValues to validate ${e} as an Enum Type.`)}const r=t.some((e=>{if(typeof e.valueOf()==="string"){return e.toLowerCase()===a.toLowerCase()}return e===a}));if(!r){throw new Error(`${a} is not a valid value for ${e}. The valid values are: ${JSON.stringify(t)}.`)}return a}function serializeByteArrayType(e,t){let a="";if(t!=undefined){if(!(t instanceof Uint8Array)){throw new Error(`${e} must be of type Uint8Array.`)}a=encodeByteArray(t)}return a}function serializeBase64UrlType(e,t){let a="";if(t!=undefined){if(!(t instanceof Uint8Array)){throw new Error(`${e} must be of type Uint8Array.`)}a=bufferToBase64Url(t)||""}return a}function serializeDateTypes(e,t,a){if(t!=undefined){if(e.match(/^Date$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in ISO8601 format.`)}t=t instanceof Date?t.toISOString().substring(0,10):new Date(t).toISOString().substring(0,10)}else if(e.match(/^DateTime$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in ISO8601 format.`)}t=t instanceof Date?t.toISOString():new Date(t).toISOString()}else if(e.match(/^DateTimeRfc1123$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in RFC-1123 format.`)}t=t instanceof Date?t.toUTCString():new Date(t).toUTCString()}else if(e.match(/^UnixTime$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in RFC-1123/ISO8601 format `+`for it to be serialized in UnixTime/Epoch format.`)}t=dateToUnixTime(t)}else if(e.match(/^TimeSpan$/i)!==null){if(!isDuration(t)){throw new Error(`${a} must be a string in ISO 8601 format. Instead was "${t}".`)}}}return t}function serializeSequenceType(e,t,a,r,i,n){if(!Array.isArray(a)){throw new Error(`${r} must be of type Array.`)}const s=t.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 ${r}.`)}const o=[];for(let t=0;te!==i));if(o){s[i]=e.serialize(p,a[i],r+'["'+i+'"]',n)}}}return s}return a}function getXmlObjectValue(e,t,a,r){if(!a||!e.xmlNamespace){return t}const i=e.xmlNamespacePrefix?`xmlns:${e.xmlNamespacePrefix}`:"xmlns";const n={[i]:e.xmlNamespace};if(["Composite"].includes(e.type.name)){if(t[C]){return t}else{const e=Object.assign({},t);e[C]=n;return e}}const s={};s[r.xmlCharKey]=t;s[C]=n;return s}function isSpecialXmlProperty(e,t){return[C,t.xmlCharKey].includes(e)}function deserializeCompositeType(e,t,a,r,i){var n,s;const o=(n=i.xmlCharKey)!==null&&n!==void 0?n:O;if(getPolymorphicDiscriminatorRecursively(e,t)){t=getPolymorphicMapper(e,t,a,"serializedName")}const p=resolveModelProperties(e,t,r);let l={};const d=[];for(const n of Object.keys(p)){const c=p[n];const m=splitSerializeName(p[n].serializedName);d.push(m[0]);const{serializedName:u,xmlName:h,xmlElementName:g}=c;let y=r;if(u!==""&&u!==undefined){y=r+"."+u}const v=c.headerCollectionPrefix;if(v){const t={};for(const r of Object.keys(a)){if(r.startsWith(v)){t[r.substring(v.length)]=e.deserialize(c.type.value,a[r],y,i)}d.push(r)}l[n]=t}else if(e.isXML){if(c.xmlIsAttribute&&a[C]){l[n]=e.deserialize(c,a[C][h],y,i)}else if(c.xmlIsMsText){if(a[o]!==undefined){l[n]=a[o]}else if(typeof a==="string"){l[n]=a}}else{const t=g||h||u;if(c.xmlIsWrapped){const t=a[h];const r=(s=t===null||t===void 0?void 0:t[g])!==null&&s!==void 0?s:[];l[n]=e.deserialize(c,r,y,i);d.push(h)}else{const r=a[t];l[n]=e.deserialize(c,r,y,i);d.push(t)}}}else{let r;let s=a;for(const e of m){if(!s)break;s=s[e]}r=s;const o=t.type.polymorphicDiscriminator;if(o&&n===o.clientName&&r==undefined){r=t.serializedName}let d;if(Array.isArray(a[n])&&p[n].serializedName===""){r=a[n];const t=e.deserialize(c,r,y,i);for(const[e,a]of Object.entries(l)){if(!Object.prototype.hasOwnProperty.call(t,e)){t[e]=a}}l=t}else if(r!==undefined||c.defaultValue!==undefined){d=e.deserialize(c,r,y,i);l[n]=d}}}const c=t.type.additionalProperties;if(c){const isAdditionalProperty=e=>{for(const t in p){const a=splitSerializeName(p[t].serializedName);if(a[0]===e){return false}}return true};for(const t in a){if(isAdditionalProperty(t)){l[t]=e.deserialize(c,a[t],r+'["'+t+'"]',i)}}}else if(a){for(const e of Object.keys(a)){if(l[e]===undefined&&!d.includes(e)&&!isSpecialXmlProperty(e,i)){l[e]=a[e]}}}return l}function deserializeDictionaryType(e,t,a,r,i){const n=t.type.value;if(!n||typeof n!=="object"){throw new Error(`"value" metadata for a Dictionary must be defined in the `+`mapper and it must of type "object" in ${r}`)}if(a){const t={};for(const s of Object.keys(a)){t[s]=e.deserialize(n,a[s],r,i)}return t}return a}function deserializeSequenceType(e,t,a,r,i){const n=t.type.element;if(!n||typeof n!=="object"){throw new Error(`element" metadata for an Array must be defined in the `+`mapper and it must of type "object" in ${r}`)}if(a){if(!Array.isArray(a)){a=[a]}const t=[];for(let s=0;s0}keys(){return Object.keys(this._rawQuery)}set(e,t){const a=t;if(e){if(a!==undefined&&a!==null){const t=Array.isArray(a)?a:a.toString();this._rawQuery[e]=t}else{delete this._rawQuery[e]}}}get(e){return e?this._rawQuery[e]:undefined}toString(){let e="";for(const t in this._rawQuery){if(e){e+="&"}const a=this._rawQuery[t];if(Array.isArray(a)){const r=[];for(const e of a){r.push(`${t}=${e}`)}e+=r.join("&")}else{e+=`${t}=${a}`}}return e}static parse(e){const t=new URLQuery;if(e){if(e.startsWith("?")){e=e.substring(1)}let a="ParameterName";let r="";let i="";for(let n=0;nisAlphaNumericCharacter(e)))}function readUntilCharacter(e,...t){return readWhile(e,(e=>t.indexOf(e)===-1))}function nextScheme(e){const t=readWhileLetterOrDigit(e);e._currentToken=URLToken.scheme(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else{e._currentState="HOST"}}function nextSchemeOrHost(e){const t=readUntilCharacter(e,":","/","?");if(!hasCurrentCharacter(e)){e._currentToken=URLToken.host(t);e._currentState="DONE"}else if(getCurrentCharacter(e)===":"){if(peekCharacters(e,3)==="://"){e._currentToken=URLToken.scheme(t);e._currentState="HOST"}else{e._currentToken=URLToken.host(t);e._currentState="PORT"}}else{e._currentToken=URLToken.host(t);if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}}function nextHost(e){if(peekCharacters(e,3)==="://"){nextCharacter(e,3)}const t=readUntilCharacter(e,":","/","?");e._currentToken=URLToken.host(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else if(getCurrentCharacter(e)===":"){e._currentState="PORT"}else if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}function nextPort(e){if(getCurrentCharacter(e)===":"){nextCharacter(e)}const t=readUntilCharacter(e,"/","?");e._currentToken=URLToken.port(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}function nextPath(e){const t=readUntilCharacter(e,"?");e._currentToken=URLToken.path(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else{e._currentState="QUERY"}}function nextQuery(e){if(getCurrentCharacter(e)==="?"){nextCharacter(e)}const t=readRemaining(e);e._currentToken=URLToken.query(t);e._currentState="DONE"}function createProxyAgent(e,t,a){const r=URLBuilder.parse(t.host).getHost();if(!r){throw new Error("Expecting a non-empty host in proxy settings.")}if(!isValidPort(t.port)){throw new Error("Expecting a valid port number in the range of [0, 65535] in proxy settings.")}const i={proxy:{host:r,port:t.port,headers:a&&a.rawHeaders()||{}}};if(t.username&&t.password){i.proxy.proxyAuth=`${t.username}:${t.password}`}else if(t.username){i.proxy.proxyAuth=`${t.username}`}const n=isUrlHttps(e);const s=isUrlHttps(t.host);const o={isHttps:n,agent:createTunnel(n,s,i)};return o}function isUrlHttps(e){const t=URLBuilder.parse(e).getScheme()||"";return t.toLowerCase()==="https"}function createTunnel(e,t,a){if(e&&t){return T.httpsOverHttps(a)}else if(e&&!t){return T.httpsOverHttp(a)}else if(!e&&t){return T.httpOverHttps(a)}else{return T.httpOverHttp(a)}}function isValidPort(e){return 0<=e&&e<=65535}const I="REDACTED";const B=["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","WWW-Authenticate"];const L=["api-version"];class Sanitizer{constructor({allowedHeaderNames:e=[],allowedQueryParameters:t=[]}={}){e=Array.isArray(e)?B.concat(e):B;t=Array.isArray(t)?L.concat(t):L;this.allowedHeaderNames=new Set(e.map((e=>e.toLowerCase())));this.allowedQueryParameters=new Set(t.map((e=>e.toLowerCase())))}sanitize(e){const t=new Set;return JSON.stringify(e,((e,a)=>{if(a instanceof Error){return Object.assign(Object.assign({},a),{name:a.name,message:a.message})}if(e==="_headersMap"){return this.sanitizeHeaders(a)}else if(e==="url"){return this.sanitizeUrl(a)}else if(e==="query"){return this.sanitizeQuery(a)}else if(e==="body"){return undefined}else if(e==="response"){return undefined}else if(e==="operationSpec"){return undefined}else if(Array.isArray(a)||isObject(a)){if(t.has(a)){return"[Circular]"}t.add(a)}return a}),2)}sanitizeHeaders(e){return this.sanitizeObject(e,this.allowedHeaderNames,((e,t)=>e[t].value))}sanitizeQuery(e){return this.sanitizeObject(e,this.allowedQueryParameters,((e,t)=>e[t]))}sanitizeObject(e,t,a){if(typeof e!=="object"||e===null){return e}const r={};for(const i of Object.keys(e)){if(t.has(i.toLowerCase())){r[i]=a(e,i)}else{r[i]=I}}return r}sanitizeUrl(e){if(typeof e!=="string"||e===null){return e}const t=URLBuilder.parse(e);const a=t.getQuery();if(!a){return e}const r=URLQuery.parse(a);for(const e of r.keys()){if(!this.allowedQueryParameters.has(e.toLowerCase())){r.set(e,I)}}t.setQuery(r.toString());return t.toString()}}const M=i.inspect.custom;const k=new Sanitizer;class RestError extends Error{constructor(e,t,a,r,i){super(e);this.name="RestError";this.code=t;this.statusCode=a;this.request=r;this.response=i;Object.setPrototypeOf(this,RestError.prototype)}[M](){return`RestError: ${this.message} \n ${k.sanitize(this)}`}}RestError.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR";RestError.PARSE_ERROR="PARSE_ERROR";const z=p.createClientLogger("core-http");function getCachedAgent(e,t){return e?t.httpsAgent:t.httpAgent}class ReportTransform extends g.Transform{constructor(e){super();this.progressCallback=e;this.loadedBytes=0}_transform(e,t,a){this.push(e);this.loadedBytes+=e.length;this.progressCallback({loadedBytes:this.loadedBytes});a(undefined)}}function isReadableStream(e){return e&&typeof e.pipe==="function"}function isStreamComplete(e,t){return new Promise((a=>{e.once("close",(()=>{t===null||t===void 0?void 0:t.abort();a()}));e.once("end",a);e.once("error",a)}))}function parseHeaders(e){const t=new HttpHeaders;e.forEach(((e,a)=>{t.set(a,e)}));return t}class NodeFetchHttpClient{constructor(){this.proxyAgentMap=new Map;this.keepAliveAgents={}}async sendRequest(e){var t;if(!e&&typeof e!=="object"){throw new Error("'httpRequest' (WebResourceLike) cannot be null or undefined and must be of type object.")}const a=new u.AbortController;let r;if(e.abortSignal){if(e.abortSignal.aborted){throw new u.AbortError("The operation was aborted.")}r=e=>{if(e.type==="abort"){a.abort()}};e.abortSignal.addEventListener("abort",r)}if(e.timeout){setTimeout((()=>{a.abort()}),e.timeout)}if(e.formData){const t=e.formData;const a=new E["default"];const appendFormValue=(e,t)=>{if(typeof t==="function"){t=t()}if(t&&Object.prototype.hasOwnProperty.call(t,"value")&&Object.prototype.hasOwnProperty.call(t,"options")){a.append(e,t.value,t.options)}else{a.append(e,t)}};for(const e of Object.keys(t)){const a=t[e];if(Array.isArray(a)){for(let t=0;t{var t;(t=e.abortSignal)===null||t===void 0?void 0:t.removeEventListener("abort",r);return})).catch((e=>{z.warning("Error when cleaning up abortListener on httpRequest",e)}))}}}getOrCreateAgent(e){var t;const a=isUrlHttps(e.url);if(e.proxySettings){const{host:r,port:i,username:n,password:s}=e.proxySettings;const o=`${r}:${i}:${n}:${s}`;const p=(t=this.proxyAgentMap.get(o))!==null&&t!==void 0?t:{};let l=getCachedAgent(a,p);if(l){return l}const d=createProxyAgent(e.url,e.proxySettings,e.headers);l=d.agent;if(d.isHttps){p.httpsAgent=d.agent}else{p.httpAgent=d.agent}this.proxyAgentMap.set(o,p);return l}else if(e.keepAlive){let t=getCachedAgent(a,this.keepAliveAgents);if(t){return t}const r={keepAlive:e.keepAlive};if(a){t=this.keepAliveAgents.httpsAgent=new N.Agent(r)}else{t=this.keepAliveAgents.httpAgent=new S.Agent(r)}return t}else{return a?N.globalAgent:S.globalAgent}}async fetch(e,t){return _["default"](e,t)}async prepareRequest(e){const t={};t.agent=this.getOrCreateAgent(e);t.compress=e.decompressResponse;return t}async processRequest(e){}}t.HttpPipelineLogLevel=void 0;(function(e){e[e["OFF"]=0]="OFF";e[e["ERROR"]=1]="ERROR";e[e["WARNING"]=2]="WARNING";e[e["INFO"]=3]="INFO"})(t.HttpPipelineLogLevel||(t.HttpPipelineLogLevel={}));function operationOptionsToRequestOptionsBase(e){const{requestOptions:t,tracingOptions:a}=e,r=n.__rest(e,["requestOptions","tracingOptions"]);let i=r;if(t){i=Object.assign(Object.assign({},i),t)}if(a){i.tracingContext=a.tracingContext;i.spanOptions=a===null||a===void 0?void 0:a.spanOptions}return i}class BaseRequestPolicy{constructor(e,t){this._nextPolicy=e;this._options=t}shouldLog(e){return this._options.shouldLog(e)}log(e,t){this._options.log(e,t)}}class RequestPolicyOptions{constructor(e){this._logger=e}shouldLog(e){return!!this._logger&&e!==t.HttpPipelineLogLevel.OFF&&e<=this._logger.minimumLogLevel}log(e,t){if(this._logger&&this.shouldLog(e)){this._logger.log(e,t)}}}const j={explicitCharkey:false,trim:false,normalize:false,normalizeTags:false,attrkey:C,explicitArray:true,ignoreAttrs:false,mergeAttrs:false,explicitRoot:true,validator:undefined,xmlns:false,explicitChildren:false,preserveChildrenOrder:false,childkey:"$$",charsAsChildren:false,includeWhiteChars:false,async:false,strict:true,attrNameProcessors:undefined,attrValueProcessors:undefined,tagNameProcessors:undefined,valueProcessors:undefined,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:true},doctype:undefined,renderOpts:{pretty:true,indent:" ",newline:"\n"},headless:false,chunkSize:1e4,emptyTag:"",cdata:false};const q=Object.assign({},j);q.explicitArray=false;const U=Object.assign({},j);U.explicitArray=false;U.renderOpts={pretty:false};function stringifyXML(e,t={}){var a;U.rootName=t.rootName;U.charkey=(a=t.xmlCharKey)!==null&&a!==void 0?a:O;const r=new x.Builder(U);return r.buildObject(e)}function parseXML(e,t={}){var a;q.explicitRoot=!!t.includeRoot;q.charkey=(a=t.xmlCharKey)!==null&&a!==void 0?a:O;const r=new x.Parser(q);return new Promise(((t,a)=>{if(!e){a(new Error("Document is empty"))}else{r.parseString(e,((e,r)=>{if(e){a(e)}else{t(r)}}))}}))}function deserializationPolicy(e,t){return{create:(a,r)=>new DeserializationPolicy(a,r,e,t)}}const H=["application/json","text/json"];const V=["application/xml","application/atom+xml"];const G={expectedContentTypes:{json:H,xml:V}};class DeserializationPolicy extends BaseRequestPolicy{constructor(e,t,a,r={}){var i;super(e,t);this.jsonContentTypes=a&&a.json||H;this.xmlContentTypes=a&&a.xml||V;this.xmlCharKey=(i=r.xmlCharKey)!==null&&i!==void 0?i:O}async sendRequest(e){return this._nextPolicy.sendRequest(e).then((e=>deserializeResponseBody(this.jsonContentTypes,this.xmlContentTypes,e,{xmlCharKey:this.xmlCharKey})))}}function getOperationResponse(e){let t;const a=e.request;const r=a.operationSpec;if(r){const i=a.operationResponseGetter;if(!i){t=r.responses[e.status]}else{t=i(r,e)}}return t}function shouldDeserializeResponse(e){const t=e.request.shouldDeserialize;let a;if(t===undefined){a=true}else if(typeof t==="boolean"){a=t}else{a=t(e)}return a}function deserializeResponseBody(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};return parse(e,t,a,o).then((e=>{if(!shouldDeserializeResponse(e)){return e}const t=e.request.operationSpec;if(!t||!t.responses){return e}const i=getOperationResponse(e);const{error:n,shouldReturnResponse:s}=handleErrorResponse(e,t,i);if(n){throw n}else if(s){return e}if(i){if(i.bodyMapper){let a=e.parsedBody;if(t.isXML&&i.bodyMapper.type.name===A.Sequence){a=typeof a==="object"?a[i.bodyMapper.xmlElementName]:[]}try{e.parsedBody=t.serializer.deserialize(i.bodyMapper,a,"operationRes.parsedBody",r)}catch(t){const a=new RestError(`Error ${t} occurred in deserializing the responseBody - ${e.bodyAsText}`,undefined,e.status,e.request,e);throw a}}else if(t.httpMethod==="HEAD"){e.parsedBody=a.status>=200&&a.status<300}if(i.headersMapper){e.parsedHeaders=t.serializer.deserialize(i.headersMapper,e.headers.toJson(),"operationRes.parsedHeaders",r)}}return e}))}function isOperationSpecEmpty(e){const t=Object.keys(e.responses);return t.length===0||t.length===1&&t[0]==="default"}function handleErrorResponse(e,t,a){var r;const i=200<=e.status&&e.status<300;const n=isOperationSpecEmpty(t)?i:!!a;if(n){if(a){if(!a.isError){return{error:null,shouldReturnResponse:false}}}else{return{error:null,shouldReturnResponse:false}}}const s=a!==null&&a!==void 0?a:t.responses.default;const o=((r=e.request.streamResponseStatusCodes)===null||r===void 0?void 0:r.has(e.status))||e.request.streamResponseBody;const p=o?`Unexpected status code: ${e.status}`:e.bodyAsText;const l=new RestError(p,undefined,e.status,e.request,e);if(!s){throw l}const d=s.bodyMapper;const c=s.headersMapper;try{if(e.parsedBody){const a=e.parsedBody;let r;if(d){let e=a;if(t.isXML&&d.type.name===A.Sequence){e=typeof a==="object"?a[d.xmlElementName]:[]}r=t.serializer.deserialize(d,e,"error.response.parsedBody")}const i=a.error||r||a;l.code=i.code;if(i.message){l.message=i.message}if(d){l.response.parsedBody=r}}if(e.headers&&c){l.response.parsedHeaders=t.serializer.deserialize(c,e.headers.toJson(),"operationRes.parsedHeaders")}}catch(t){l.message=`Error "${t.message}" occurred in deserializing the responseBody - "${e.bodyAsText}" for the default response.`}return{error:l,shouldReturnResponse:false}}function parse(e,t,a,r){var i;const errorHandler=e=>{const t=`Error "${e}" occurred while parsing the response body - ${a.bodyAsText}.`;const r=e.code||RestError.PARSE_ERROR;const i=new RestError(t,r,a.status,a.request,a);return Promise.reject(i)};const n=((i=a.request.streamResponseStatusCodes)===null||i===void 0?void 0:i.has(a.status))||a.request.streamResponseBody;if(!n&&a.bodyAsText){const i=a.bodyAsText;const n=a.headers.get("Content-Type")||"";const s=!n?[]:n.split(";").map((e=>e.toLowerCase()));if(s.length===0||s.some((t=>e.indexOf(t)!==-1))){return new Promise((e=>{a.parsedBody=JSON.parse(i);e(a)})).catch(errorHandler)}else if(s.some((e=>t.indexOf(e)!==-1))){return parseXML(i,r).then((e=>{a.parsedBody=e;return a})).catch(errorHandler)}}return Promise.resolve(a)}const X={enable:true};function keepAlivePolicy(e){return{create:(t,a)=>new KeepAlivePolicy(t,a,e||X)}}class KeepAlivePolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.keepAliveOptions=a}async sendRequest(e){e.keepAlive=this.keepAliveOptions.enable;return this._nextPolicy.sendRequest(e)}}const $=["GET","HEAD"];const W={handleRedirects:true,maxRetries:20};function redirectPolicy(e=20){return{create:(t,a)=>new RedirectPolicy(t,a,e)}}class RedirectPolicy extends BaseRequestPolicy{constructor(e,t,a=20){super(e,t);this.maxRetries=a}sendRequest(e){return this._nextPolicy.sendRequest(e).then((e=>handleRedirect(this,e,0)))}}function handleRedirect(e,t,a){const{request:r,status:i}=t;const n=t.headers.get("location");if(n&&(i===300||i===301&&$.includes(r.method)||i===302&&$.includes(r.method)||i===303&&r.method==="POST"||i===307)&&(!e.maxRetries||ahandleRedirect(e,t,a+1)))}return Promise.resolve(t)}const K=3;const Q=1e3*30;const Y=1e3*90;const J=1e3*3;function isNumber(e){return typeof e==="number"}function shouldRetry(e,t,a,r,i){if(!t(r,i)){return false}return a.retryCountnew ExponentialRetryPolicy(r,i,e,t,a)}}t.RetryMode=void 0;(function(e){e[e["Exponential"]=0]="Exponential"})(t.RetryMode||(t.RetryMode={}));const Z={maxRetries:K,retryDelayInMs:Q,maxRetryDelayInMs:Y};class ExponentialRetryPolicy extends BaseRequestPolicy{constructor(e,t,a,r,i){super(e,t);this.retryCount=isNumber(a)?a:K;this.retryInterval=isNumber(r)?r:Q;this.maxRetryInterval=isNumber(i)?i:Y}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then((t=>retry$1(this,e,t))).catch((t=>retry$1(this,e,t.response,undefined,t)))}}async function retry$1(e,t,a,r,i){function shouldPolicyRetry(e){const t=e===null||e===void 0?void 0:e.status;if(t===503&&(a===null||a===void 0?void 0:a.headers.get(P.HeaderConstants.RETRY_AFTER))){return false}if(t===undefined||t<500&&t!==408||t===501||t===505){return false}return true}r=updateRetryData({retryInterval:e.retryInterval,minRetryInterval:0,maxRetryInterval:e.maxRetryInterval},r,i);const n=t.abortSignal&&t.abortSignal.aborted;if(!n&&shouldRetry(e.retryCount,shouldPolicyRetry,r,a)){z.info(`Retrying request in ${r.retryInterval}`);try{await o.delay(r.retryInterval);const a=await e._nextPolicy.sendRequest(t.clone());return retry$1(e,t,a,r)}catch(i){return retry$1(e,t,a,r,i)}}else if(n||i||!a){const e=r.error||new RestError("Failed to send the request.",RestError.REQUEST_SEND_ERROR,a&&a.status,a&&a.request,a);throw e}else{return a}}function logPolicy(e={}){return{create:(t,a)=>new LogPolicy(t,a,e)}}class LogPolicy extends BaseRequestPolicy{constructor(e,t,{logger:a=z.info,allowedHeaderNames:r=[],allowedQueryParameters:i=[]}={}){super(e,t);this.logger=a;this.sanitizer=new Sanitizer({allowedHeaderNames:r,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){if(!this.logger.enabled)return this._nextPolicy.sendRequest(e);this.logRequest(e);return this._nextPolicy.sendRequest(e).then((e=>this.logResponse(e)))}logRequest(e){this.logger(`Request: ${this.sanitizer.sanitize(e)}`)}logResponse(e){this.logger(`Response status code: ${e.status}`);this.logger(`Headers: ${this.sanitizer.sanitize(e.headers)}`);return e}}function getPathStringFromParameter(e){return getPathStringFromParameterPath(e.parameterPath,e.mapper)}function getPathStringFromParameterPath(e,t){let a;if(typeof e==="string"){a=e}else if(Array.isArray(e)){a=e.join(".")}else{a=t.serializedName}return a}function getStreamResponseStatusCodes(e){const t=new Set;for(const a in e.responses){const r=e.responses[a];if(r.bodyMapper&&r.bodyMapper.type.name===A.Stream){t.add(Number(a))}}return t}function getDefaultUserAgentKey(){return P.HeaderConstants.USER_AGENT}function getPlatformSpecificData(){const e={key:"Node",value:process.version};const t={key:"OS",value:`(${w.arch()}-${w.type()}-${w.release()})`};return[e,t]}function getRuntimeInfo(){const e={key:"core-http",value:P.coreHttpVersion};return[e]}function getUserAgentString(e,t=" ",a="/"){return e.map((e=>{const t=e.value?`${a}${e.value}`:"";return`${e.key}${t}`})).join(t)}const ee=getDefaultUserAgentKey;function getDefaultUserAgentValue(){const e=getRuntimeInfo();const t=getPlatformSpecificData();const a=getUserAgentString(e.concat(t));return a}function userAgentPolicy(e){const t=!e||e.key===undefined||e.key===null?getDefaultUserAgentKey():e.key;const a=!e||e.value===undefined||e.value===null?getDefaultUserAgentValue():e.value;return{create:(e,r)=>new UserAgentPolicy(e,r,t,a)}}class UserAgentPolicy extends BaseRequestPolicy{constructor(e,t,a,r){super(e,t);this._nextPolicy=e;this._options=t;this.headerKey=a;this.headerValue=r}sendRequest(e){this.addUserAgentHeader(e);return this._nextPolicy.sendRequest(e)}addUserAgentHeader(e){if(!e.headers){e.headers=new HttpHeaders}if(!e.headers.get(this.headerKey)&&this.headerValue){e.headers.set(this.headerKey,this.headerValue)}}}t.QueryCollectionFormat=void 0;(function(e){e["Csv"]=",";e["Ssv"]=" ";e["Tsv"]="\t";e["Pipes"]="|";e["Multi"]="Multi"})(t.QueryCollectionFormat||(t.QueryCollectionFormat={}));const te={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function beginRefresh(e,t,a){async function tryGetAccessToken(){if(Date.now()e.getToken(t,a);r=beginRefresh(tryGetAccessToken,n.retryIntervalInMs,(o=i===null||i===void 0?void 0:i.expiresOnTimestamp)!==null&&o!==void 0?o:Date.now()).then((e=>{r=null;i=e;return i})).catch((e=>{r=null;i=null;throw e}))}return r}return async e=>{if(s.mustRefresh)return refresh(e);if(s.shouldRefresh){refresh(e)}return i}}function bearerTokenAuthenticationPolicy(e,t){const a=createTokenCycler(e,t);class BearerTokenAuthenticationPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){if(!e.url.toLowerCase().startsWith("https://")){throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.")}const{token:t}=await a({abortSignal:e.abortSignal,tracingOptions:{tracingContext:e.tracingContext}});e.headers.set(P.HeaderConstants.AUTHORIZATION,`Bearer ${t}`);return this._nextPolicy.sendRequest(e)}}return{create:(e,t)=>new BearerTokenAuthenticationPolicy(e,t)}}function disableResponseDecompressionPolicy(){return{create:(e,t)=>new DisableResponseDecompressionPolicy(e,t)}}class DisableResponseDecompressionPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){e.decompressResponse=false;return this._nextPolicy.sendRequest(e)}}function generateClientRequestIdPolicy(e="x-ms-client-request-id"){return{create:(t,a)=>new GenerateClientRequestIdPolicy(t,a,e)}}class GenerateClientRequestIdPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this._requestIdHeaderName=a}sendRequest(e){if(!e.headers.contains(this._requestIdHeaderName)){e.headers.set(this._requestIdHeaderName,e.requestId)}return this._nextPolicy.sendRequest(e)}}let ae;function getCachedDefaultHttpClient(){if(!ae){ae=new NodeFetchHttpClient}return ae}function ndJsonPolicy(){return{create:(e,t)=>new NdJsonPolicy(e,t)}}class NdJsonPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){if(typeof e.body==="string"&&e.body.startsWith("[")){const t=JSON.parse(e.body);if(Array.isArray(t)){e.body=t.map((e=>JSON.stringify(e)+"\n")).join("")}}return this._nextPolicy.sendRequest(e)}}const re=[];let ie=false;const ne=new Map;function loadEnvironmentProxyValue(){if(!process){return undefined}const e=getEnvironmentValue(P.HTTPS_PROXY);const t=getEnvironmentValue(P.ALL_PROXY);const a=getEnvironmentValue(P.HTTP_PROXY);return e||t||a}function isBypassed(e,t,a){if(t.length===0){return false}const r=URLBuilder.parse(e).getHost();if(a===null||a===void 0?void 0:a.has(r)){return a.get(r)}let i=false;for(const e of t){if(e[0]==="."){if(r.endsWith(e)){i=true}else{if(r.length===e.length-1&&r===e.slice(1)){i=true}}}else{if(r===e){i=true}}}a===null||a===void 0?void 0:a.set(r,i);return i}function loadNoProxy(){const e=getEnvironmentValue(P.NO_PROXY);ie=true;if(e){return e.split(",").map((e=>e.trim())).filter((e=>e.length))}return[]}function getDefaultProxySettings(e){if(!e){e=loadEnvironmentProxyValue();if(!e){return undefined}}const{username:t,password:a,urlWithoutAuth:r}=extractAuthFromUrl(e);const i=URLBuilder.parse(r);const n=i.getScheme()?i.getScheme()+"://":"";return{host:n+i.getHost(),port:Number.parseInt(i.getPort()||"80"),username:t,password:a}}function proxyPolicy(e,t){if(!e){e=getDefaultProxySettings()}if(!ie){re.push(...loadNoProxy())}return{create:(a,r)=>new ProxyPolicy(a,r,e,t===null||t===void 0?void 0:t.customNoProxyList)}}function extractAuthFromUrl(e){const t=e.indexOf("@");if(t===-1){return{urlWithoutAuth:e}}const a=e.indexOf("://");const r=a!==-1?a+3:0;const i=e.substring(r,t);const n=i.indexOf(":");const s=n!==-1;const o=s?i.substring(0,n):i;const p=s?i.substring(n+1):undefined;const l=e.substring(0,r)+e.substring(t+1);return{username:o,password:p,urlWithoutAuth:l}}class ProxyPolicy extends BaseRequestPolicy{constructor(e,t,a,r){super(e,t);this.proxySettings=a;this.customNoProxyList=r}sendRequest(e){var t;if(!e.proxySettings&&!isBypassed(e.url,(t=this.customNoProxyList)!==null&&t!==void 0?t:re,this.customNoProxyList?undefined:ne)){e.proxySettings=this.proxySettings}return this._nextPolicy.sendRequest(e)}}function rpRegistrationPolicy(e=30){return{create:(t,a)=>new RPRegistrationPolicy(t,a,e)}}class RPRegistrationPolicy extends BaseRequestPolicy{constructor(e,t,a=30){super(e,t);this._retryTimeout=a}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then((t=>registerIfNeeded(this,e,t)))}}function registerIfNeeded(e,t,a){if(a.status===409){const r=checkRPNotRegisteredError(a.bodyAsText);if(r){const i=extractSubscriptionUrl(t.url);return registerRP(e,i,r,t).catch((()=>false)).then((r=>{if(r){t.headers.set("x-ms-client-request-id",generateUuid());return e._nextPolicy.sendRequest(t.clone())}return a}))}}return Promise.resolve(a)}function getRequestEssentials(e,t=false){const a=e.clone();if(t){a.url=e.url}a.headers.set("x-ms-client-request-id",generateUuid());a.headers.set("Content-Type","application/json; charset=utf-8");return a}function checkRPNotRegisteredError(e){let t,a;if(e){try{a=JSON.parse(e)}catch(e){}if(a&&a.error&&a.error.message&&a.error.code&&a.error.code==="MissingSubscriptionRegistration"){const e=a.error.message.match(/.*'(.*)'/i);if(e){t=e.pop()}}}return t}function extractSubscriptionUrl(e){let t;const a=e.match(/.*\/subscriptions\/[a-f0-9-]+\//gi);if(a&&a[0]){t=a[0]}else{throw new Error(`Unable to extract subscriptionId from the given url - ${e}.`)}return t}async function registerRP(e,t,a,r){const i=`${t}providers/${a}/register?api-version=2016-02-01`;const n=`${t}providers/${a}?api-version=2016-02-01`;const s=getRequestEssentials(r);s.method="POST";s.url=i;const o=await e._nextPolicy.sendRequest(s);if(o.status!==200){throw new Error(`Autoregistration of ${a} failed. Please try registering manually.`)}return getRegistrationStatus(e,n,r)}async function getRegistrationStatus(e,t,a){const r=getRequestEssentials(a);r.url=t;r.method="GET";const i=await e._nextPolicy.sendRequest(r);const n=i.parsedBody;if(i.parsedBody&&n.registrationState&&n.registrationState==="Registered"){return true}else{await o.delay(e._retryTimeout*1e3);return getRegistrationStatus(e,t,a)}}function signingPolicy(e){return{create:(t,a)=>new SigningPolicy(t,a,e)}}class SigningPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.authenticationProvider=a}signRequest(e){return this.authenticationProvider.signRequest(e)}sendRequest(e){return this.signRequest(e).then((e=>this._nextPolicy.sendRequest(e)))}}function systemErrorRetryPolicy(e,t,a,r){return{create:(i,n)=>new SystemErrorRetryPolicy(i,n,e,t,a,r)}}class SystemErrorRetryPolicy extends BaseRequestPolicy{constructor(e,t,a,r,i,n){super(e,t);this.retryCount=isNumber(a)?a:K;this.retryInterval=isNumber(r)?r:Q;this.minRetryInterval=isNumber(i)?i:J;this.maxRetryInterval=isNumber(n)?n:Y}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).catch((t=>retry(this,e,t.response,t)))}}async function retry(e,t,a,r,i){i=updateRetryData(e,i,r);function shouldPolicyRetry(e,t){if(t&&t.code&&(t.code==="ETIMEDOUT"||t.code==="ESOCKETTIMEDOUT"||t.code==="ECONNREFUSED"||t.code==="ECONNRESET"||t.code==="ENOENT")){return true}return false}if(shouldRetry(e.retryCount,shouldPolicyRetry,i,a,r)){try{await o.delay(i.retryInterval);return e._nextPolicy.sendRequest(t.clone())}catch(r){return retry(e,t,a,r,i)}}else{if(r){return Promise.reject(i.error)}return a}}const se=3;const oe=P.HttpConstants.StatusCodes;function throttlingRetryPolicy(){return{create:(e,t)=>new ThrottlingRetryPolicy(e,t)}}const pe="The operation was aborted.";class ThrottlingRetryPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.numberOfRetries=0;this._handleResponse=a||this._defaultResponseHandler}async sendRequest(e){const t=await this._nextPolicy.sendRequest(e.clone());if(t.status!==oe.TooManyRequests&&t.status!==oe.ServiceUnavailable){return t}else{return this._handleResponse(e,t)}}async _defaultResponseHandler(e,t){var a;const r=t.headers.get(P.HeaderConstants.RETRY_AFTER);if(r){const t=ThrottlingRetryPolicy.parseRetryAfterHeader(r);if(t){this.numberOfRetries+=1;await o.delay(t,{abortSignal:e.abortSignal,abortErrorMsg:pe});if((a=e.abortSignal)===null||a===void 0?void 0:a.aborted){throw new u.AbortError(pe)}if(this.numberOfRetries{let a=undefined;const r=this;const i=t;return{create(t,n){const s=getCredentialScopes(i,r.baseUri);if(!s){throw new Error(`When using credential, the ServiceClient must contain a baseUri or a credentialScopes in ServiceClientOptions. Unable to create a bearerTokenAuthenticationPolicy`)}if(a===undefined||a===null){a=bearerTokenAuthenticationPolicy(e,s)}return a.create(t,n)}}};r=wrappedPolicyFactory()}else if(e&&typeof e.signRequest==="function"){z.info("ServiceClient: creating signing policy from provided credentials");r=signingPolicy(e)}else if(e!==undefined&&e!==null){throw new Error("The credentials argument must implement the TokenCredential interface")}z.info("ServiceClient: using default request policies");a=createDefaultRequestPolicyFactories(r,t);if(t.requestPolicyFactories){const e=t.requestPolicyFactories(a);if(e){a=e}}}this._requestPolicyFactories=a}sendRequest(e){if(e===null||e===undefined||typeof e!=="object"){throw new Error("options cannot be null or undefined and it must be of type object.")}let t;try{if(isWebResourceLike(e)){e.validateRequestProperties();t=e}else{t=new WebResource;t=t.prepare(e)}}catch(e){return Promise.reject(e)}let a=this._httpClient;if(this._requestPolicyFactories&&this._requestPolicyFactories.length>0){for(let e=this._requestPolicyFactories.length-1;e>=0;--e){a=this._requestPolicyFactories[e].create(a,this._requestPolicyOptions)}}return a.sendRequest(t)}async sendOperationRequest(e,a,r){var i;if(typeof e.options==="function"){r=e.options;e.options=undefined}const n=(i=e.options)===null||i===void 0?void 0:i.serializerOptions;const s=new WebResource;let o;try{const r=a.baseUrl||this.baseUri;if(!r){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=a.httpMethod;s.operationSpec=a;const i=URLBuilder.parse(r);if(a.path){i.appendPath(a.path)}if(a.urlParameters&&a.urlParameters.length>0){for(const t of a.urlParameters){let r=getOperationArgumentValueFromParameter(this,e,t,a.serializer);r=a.serializer.serialize(t.mapper,r,getPathStringFromParameter(t),n);if(!t.skipEncoding){r=encodeURIComponent(r)}i.replaceAll(`{${t.mapper.serializedName||getPathStringFromParameter(t)}}`,r)}}if(a.queryParameters&&a.queryParameters.length>0){for(const r of a.queryParameters){let s=getOperationArgumentValueFromParameter(this,e,r,a.serializer);if(s!==undefined&&s!==null){s=a.serializer.serialize(r.mapper,s,getPathStringFromParameter(r),n);if(r.collectionFormat!==undefined&&r.collectionFormat!==null){if(r.collectionFormat===t.QueryCollectionFormat.Multi){if(s.length===0){continue}else{for(const e in s){const t=s[e];s[e]=t===undefined||t===null?"":t.toString()}}}else if(r.collectionFormat===t.QueryCollectionFormat.Ssv||r.collectionFormat===t.QueryCollectionFormat.Tsv){s=s.join(r.collectionFormat)}}if(!r.skipEncoding){if(Array.isArray(s)){for(const e in s){if(s[e]!==undefined&&s[e]!==null){s[e]=encodeURIComponent(s[e])}}}else{s=encodeURIComponent(s)}}if(r.collectionFormat!==undefined&&r.collectionFormat!==null&&r.collectionFormat!==t.QueryCollectionFormat.Multi&&r.collectionFormat!==t.QueryCollectionFormat.Ssv&&r.collectionFormat!==t.QueryCollectionFormat.Tsv){s=s.join(r.collectionFormat)}i.setQueryParameter(r.mapper.serializedName||getPathStringFromParameter(r),s)}}}s.url=i.toString();const p=a.contentType||this.requestContentType;if(p&&a.requestBody){s.headers.set("Content-Type",p)}if(a.headerParameters){for(const t of a.headerParameters){let r=getOperationArgumentValueFromParameter(this,e,t,a.serializer);if(r!==undefined&&r!==null){r=a.serializer.serialize(t.mapper,r,getPathStringFromParameter(t),n);const e=t.mapper.headerCollectionPrefix;if(e){for(const t of Object.keys(r)){s.headers.set(e+t,r[t])}}else{s.headers.set(t.mapper.serializedName||getPathStringFromParameter(t),r)}}}}const l=e.options;if(l){if(l.customHeaders){for(const e in l.customHeaders){s.headers.set(e,l.customHeaders[e])}}if(l.abortSignal){s.abortSignal=l.abortSignal}if(l.timeout){s.timeout=l.timeout}if(l.onUploadProgress){s.onUploadProgress=l.onUploadProgress}if(l.onDownloadProgress){s.onDownloadProgress=l.onDownloadProgress}if(l.spanOptions){s.spanOptions=l.spanOptions}if(l.tracingContext){s.tracingContext=l.tracingContext}if(l.shouldDeserialize!==undefined&&l.shouldDeserialize!==null){s.shouldDeserialize=l.shouldDeserialize}}s.withCredentials=this._withCredentials;serializeRequestBody(this,s,e,a);if(s.streamResponseStatusCodes===undefined){s.streamResponseStatusCodes=getStreamResponseStatusCodes(a)}let d;let c;try{d=await this.sendRequest(s)}catch(e){c=e}if(c){if(c.response){c.details=flattenResponse(c.response,a.responses[c.statusCode]||a.responses["default"])}o=Promise.reject(c)}else{o=Promise.resolve(flattenResponse(d,a.responses[d.status]))}}catch(e){o=Promise.reject(e)}const p=r;if(p){o.then((e=>p(null,e._response.parsedBody,e._response.request,e._response))).catch((e=>p(e)))}return o}}function serializeRequestBody(e,t,a,r){var i,n,s,o,p,l;const d=(n=(i=a.options)===null||i===void 0?void 0:i.serializerOptions)!==null&&n!==void 0?n:{};const c={rootName:(s=d.rootName)!==null&&s!==void 0?s:"",includeRoot:(o=d.includeRoot)!==null&&o!==void 0?o:false,xmlCharKey:(p=d.xmlCharKey)!==null&&p!==void 0?p:O};const m=d.xmlCharKey;if(r.requestBody&&r.requestBody.mapper){t.body=getOperationArgumentValueFromParameter(e,a,r.requestBody,r.serializer);const i=r.requestBody.mapper;const{required:n,xmlName:s,xmlElementName:o,serializedName:p,xmlNamespace:d,xmlNamespacePrefix:u}=i;const h=i.type.name;try{if(t.body!==undefined&&t.body!==null||n){const e=getPathStringFromParameter(r.requestBody);t.body=r.serializer.serialize(i,t.body,e,c);const a=h===A.Stream;if(r.isXML){const e=u?`xmlns:${u}`:"xmlns";const r=getXmlValueWithNamespace(d,e,h,t.body,c);if(h===A.Sequence){t.body=stringifyXML(prepareXMLRootList(r,o||s||p,e,d),{rootName:s||p,xmlCharKey:m})}else if(!a){t.body=stringifyXML(r,{rootName:s||p,xmlCharKey:m})}}else if(h===A.String&&(((l=r.contentType)===null||l===void 0?void 0:l.match("text/plain"))||r.mediaType==="text")){return}else if(!a){t.body=JSON.stringify(t.body)}}}catch(e){throw new Error(`Error "${e.message}" occurred in serializing the payload - ${JSON.stringify(p,undefined," ")}.`)}}else if(r.formDataParameters&&r.formDataParameters.length>0){t.formData={};for(const i of r.formDataParameters){const n=getOperationArgumentValueFromParameter(e,a,i,r.serializer);if(n!==undefined&&n!==null){const e=i.mapper.serializedName||getPathStringFromParameter(i);t.formData[e]=r.serializer.serialize(i.mapper,n,getPathStringFromParameter(i),c)}}}}function getXmlValueWithNamespace(e,t,a,r,i){if(e&&!["Composite","Sequence","Dictionary"].includes(a)){const a={};a[i.xmlCharKey]=r;a[C]={[t]:e};return a}return r}function getValueOrFunctionResult(e,t){let a;if(typeof e==="string"){a=e}else{a=t();if(typeof e==="function"){a=e(a)}}return a}function createDefaultRequestPolicyFactories(e,t){const a=[];if(t.generateClientRequestIdHeader){a.push(generateClientRequestIdPolicy(t.clientRequestIdHeaderName))}if(e){a.push(e)}const r=getValueOrFunctionResult(t.userAgentHeaderName,ee);const i=getValueOrFunctionResult(t.userAgent,getDefaultUserAgentValue);if(r&&i){a.push(userAgentPolicy({key:r,value:i}))}a.push(redirectPolicy());a.push(rpRegistrationPolicy(t.rpRegistrationRetryTimeout));if(!t.noRetryPolicy){a.push(exponentialRetryPolicy());a.push(systemErrorRetryPolicy());a.push(throttlingRetryPolicy())}a.push(deserializationPolicy(t.deserializationContentTypes));if(o.isNode){a.push(proxyPolicy(t.proxySettings))}a.push(logPolicy({logger:z.info}));return a}function createPipelineFromOptions(e,t){const a=[];if(e.sendStreamingJson){a.push(ndJsonPolicy())}let r=undefined;if(e.userAgentOptions&&e.userAgentOptions.userAgentPrefix){const t=[];t.push(e.userAgentOptions.userAgentPrefix);const a=getDefaultUserAgentValue();if(t.indexOf(a)===-1){t.push(a)}r=t.join(" ")}const i=Object.assign(Object.assign({},X),e.keepAliveOptions);const n=Object.assign(Object.assign({},Z),e.retryOptions);const s=Object.assign(Object.assign({},W),e.redirectOptions);if(o.isNode){a.push(proxyPolicy(e.proxyOptions))}const p=Object.assign(Object.assign({},G),e.deserializationOptions);const l=Object.assign({},e.loggingOptions);a.push(tracingPolicy({userAgent:r}),keepAlivePolicy(i),userAgentPolicy({value:r}),generateClientRequestIdPolicy(),deserializationPolicy(p.expectedContentTypes),throttlingRetryPolicy(),systemErrorRetryPolicy(),exponentialRetryPolicy(n.maxRetries,n.retryDelayInMs,n.maxRetryDelayInMs));if(s.handleRedirects){a.push(redirectPolicy(s.maxRetries))}if(t){a.push(t)}a.push(logPolicy(l));if(o.isNode&&e.decompressResponse===false){a.push(disableResponseDecompressionPolicy())}return{httpClient:e.httpClient,requestPolicyFactories:a}}function getOperationArgumentValueFromParameter(e,t,a,r){return getOperationArgumentValueFromParameterPath(e,t,a.parameterPath,a.mapper,r)}function getOperationArgumentValueFromParameterPath(e,t,a,r,i){var n;let s;if(typeof a==="string"){a=[a]}const o=(n=t.options)===null||n===void 0?void 0:n.serializerOptions;if(Array.isArray(a)){if(a.length>0){if(r.isConstant){s=r.defaultValue}else{let i=getPropertyFromParameterPath(t,a);if(!i.propertyFound){i=getPropertyFromParameterPath(e,a)}let n=false;if(!i.propertyFound){n=r.required||a[0]==="options"&&a.length===2}s=n?r.defaultValue:i.propertyValue}const n=getPathStringFromParameterPath(a,r);i.serialize(r,s,n,o)}}else{if(r.required){s={}}for(const n in a){const p=r.type.modelProperties[n];const l=a[n];const d=getOperationArgumentValueFromParameterPath(e,t,l,p,i);const c=getPathStringFromParameterPath(l,p);i.serialize(p,d,c,o);if(d!==undefined&&d!==null){if(!s){s={}}s[n]=d}}}return s}function getPropertyFromParameterPath(e,t){const a={propertyFound:false};let r=0;for(;rObject.defineProperty(t,"_response",{value:e});if(r){const t=r.type.name;if(t==="Stream"){return addOperationResponse(Object.assign(Object.assign({},a),{blobBody:e.blobBody,readableStreamBody:e.readableStreamBody}))}const i=t==="Composite"&&r.type.modelProperties||{};const n=Object.keys(i).some((e=>i[e].serializedName===""));if(t==="Sequence"||n){const t=[...e.parsedBody||[]];for(const a of Object.keys(i)){if(i[a].serializedName){t[a]=e.parsedBody[a]}}if(a){for(const e of Object.keys(a)){t[e]=a[e]}}addOperationResponse(t);return t}if(t==="Composite"||t==="Dictionary"){return addOperationResponse(Object.assign(Object.assign({},a),e.parsedBody))}}if(r||e.request.method==="HEAD"||isPrimitiveType(e.parsedBody)){return addOperationResponse(Object.assign(Object.assign({},a),{body:e.parsedBody}))}return addOperationResponse(Object.assign(Object.assign({},a),e.parsedBody))}function getCredentialScopes(e,t){if(e===null||e===void 0?void 0:e.credentialScopes){return e.credentialScopes}if(t){return`${t}/.default`}return undefined}function createSpanFunction(e){return b.createSpanFunction(e)}const de=2*60*1e3;class ExpiringAccessTokenCache{constructor(e=de){this.cachedToken=undefined;this.tokenRefreshBufferMs=e}setCachedToken(e){this.cachedToken=e}getCachedToken(){if(this.cachedToken&&Date.now()+this.tokenRefreshBufferMs>=this.cachedToken.expiresOnTimestamp){this.cachedToken=undefined}return this.cachedToken}}class AccessTokenRefresher{constructor(e,t,a=3e4){this.credential=e;this.scopes=t;this.requiredMillisecondsBeforeNewRefresh=a;this.lastCalled=0}isReady(){return!this.lastCalled||Date.now()-this.lastCalled>this.requiredMillisecondsBeforeNewRefresh}async getToken(e){this.lastCalled=Date.now();const t=await this.credential.getToken(this.scopes,e);this.promise=undefined;return t||undefined}refresh(e){if(!this.promise){this.promise=this.getToken(e)}return this.promise}}const ce=P.HeaderConstants;const me="Basic";class BasicAuthenticationCredentials{constructor(e,t,a=me){this.authorizationScheme=me;if(e===null||e===undefined||typeof e.valueOf()!=="string"){throw new Error("userName cannot be null or undefined and must be of type string.")}if(t===null||t===undefined||typeof t.valueOf()!=="string"){throw new Error("password cannot be null or undefined and must be of type string.")}this.userName=e;this.password=t;this.authorizationScheme=a}signRequest(e){const t=`${this.userName}:${this.password}`;const a=`${this.authorizationScheme} ${encodeString(t)}`;if(!e.headers)e.headers=new HttpHeaders;e.headers.set(ce.AUTHORIZATION,a);return Promise.resolve(e)}}class ApiKeyCredentials{constructor(e){if(!e||e&&!e.inHeader&&!e.inQuery){throw new Error(`options cannot be null or undefined. Either "inHeader" or "inQuery" property of the options object needs to be provided.`)}this.inHeader=e.inHeader;this.inQuery=e.inQuery}signRequest(e){if(!e){return Promise.reject(new Error(`webResource cannot be null or undefined and must be of type "object".`))}if(this.inHeader){if(!e.headers){e.headers=new HttpHeaders}for(const t in this.inHeader){e.headers.set(t,this.inHeader[t])}}if(this.inQuery){if(!e.url){return Promise.reject(new Error(`url cannot be null in the request object.`))}if(e.url.indexOf("?")<0){e.url+="?"}for(const t in this.inQuery){if(!e.url.endsWith("?")){e.url+="&"}e.url+=`${t}=${this.inQuery[t]}`}}return Promise.resolve(e)}}class TopicCredentials extends ApiKeyCredentials{constructor(e){if(!e||e&&typeof e!=="string"){throw new Error("topicKey cannot be null or undefined and must be of type string.")}const t={inHeader:{"aeg-sas-key":e}};super(t)}}Object.defineProperty(t,"delay",{enumerable:true,get:function(){return o.delay}});Object.defineProperty(t,"isNode",{enumerable:true,get:function(){return o.isNode}});Object.defineProperty(t,"isTokenCredential",{enumerable:true,get:function(){return l.isTokenCredential}});t.AccessTokenRefresher=AccessTokenRefresher;t.ApiKeyCredentials=ApiKeyCredentials;t.BaseRequestPolicy=BaseRequestPolicy;t.BasicAuthenticationCredentials=BasicAuthenticationCredentials;t.Constants=P;t.DefaultHttpClient=NodeFetchHttpClient;t.ExpiringAccessTokenCache=ExpiringAccessTokenCache;t.HttpHeaders=HttpHeaders;t.MapperType=A;t.RequestPolicyOptions=RequestPolicyOptions;t.RestError=RestError;t.Serializer=Serializer;t.ServiceClient=ServiceClient;t.TopicCredentials=TopicCredentials;t.URLBuilder=URLBuilder;t.URLQuery=URLQuery;t.WebResource=WebResource;t.XML_ATTRKEY=C;t.XML_CHARKEY=O;t.applyMixins=applyMixins;t.bearerTokenAuthenticationPolicy=bearerTokenAuthenticationPolicy;t.createPipelineFromOptions=createPipelineFromOptions;t.createSpanFunction=createSpanFunction;t.deserializationPolicy=deserializationPolicy;t.deserializeResponseBody=deserializeResponseBody;t.disableResponseDecompressionPolicy=disableResponseDecompressionPolicy;t.encodeUri=encodeUri;t.executePromisesSequentially=executePromisesSequentially;t.exponentialRetryPolicy=exponentialRetryPolicy;t.flattenResponse=flattenResponse;t.generateClientRequestIdPolicy=generateClientRequestIdPolicy;t.generateUuid=generateUuid;t.getDefaultProxySettings=getDefaultProxySettings;t.getDefaultUserAgentValue=getDefaultUserAgentValue;t.isDuration=isDuration;t.isValidUuid=isValidUuid;t.keepAlivePolicy=keepAlivePolicy;t.logPolicy=logPolicy;t.operationOptionsToRequestOptionsBase=operationOptionsToRequestOptionsBase;t.parseXML=parseXML;t.promiseToCallback=promiseToCallback;t.promiseToServiceCallback=promiseToServiceCallback;t.proxyPolicy=proxyPolicy;t.redirectPolicy=redirectPolicy;t.serializeObject=serializeObject;t.signingPolicy=signingPolicy;t.stringifyXML=stringifyXML;t.stripRequest=stripRequest;t.stripResponse=stripResponse;t.systemErrorRetryPolicy=systemErrorRetryPolicy;t.throttlingRetryPolicy=throttlingRetryPolicy;t.tracingPolicy=tracingPolicy;t.userAgentPolicy=userAgentPolicy},6279:(e,t,a)=>{var r=a(5443);var i=a(3837);var n=a(1017);var s=a(3685);var o=a(5687);var p=a(7310).parse;var l=a(7147);var d=a(2781).Stream;var c=a(3583);var m=a(4812);var u=a(3971);e.exports=FormData;i.inherits(FormData,r);function FormData(e){if(!(this instanceof FormData)){return new FormData(e)}this._overheadLength=0;this._valueLength=0;this._valuesToMeasure=[];r.call(this);e=e||{};for(var t in e){this[t]=e[t]}}FormData.LINE_BREAK="\r\n";FormData.DEFAULT_CONTENT_TYPE="application/octet-stream";FormData.prototype.append=function(e,t,a){a=a||{};if(typeof a=="string"){a={filename:a}}var n=r.prototype.append.bind(this);if(typeof t=="number"){t=""+t}if(i.isArray(t)){this._error(new Error("Arrays are not supported."));return}var s=this._multiPartHeader(e,t,a);var o=this._multiPartFooter();n(s);n(t);n(o);this._trackLength(s,t,a)};FormData.prototype._trackLength=function(e,t,a){var r=0;if(a.knownLength!=null){r+=+a.knownLength}else if(Buffer.isBuffer(t)){r=t.length}else if(typeof t==="string"){r=Buffer.byteLength(t)}this._valueLength+=r;this._overheadLength+=Buffer.byteLength(e)+FormData.LINE_BREAK.length;if(!t||!t.path&&!(t.readable&&t.hasOwnProperty("httpVersion"))&&!(t instanceof d)){return}if(!a.knownLength){this._valuesToMeasure.push(t)}};FormData.prototype._lengthRetriever=function(e,t){if(e.hasOwnProperty("fd")){if(e.end!=undefined&&e.end!=Infinity&&e.start!=undefined){t(null,e.end+1-(e.start?e.start:0))}else{l.stat(e.path,(function(a,r){var i;if(a){t(a);return}i=r.size-(e.start?e.start:0);t(null,i)}))}}else if(e.hasOwnProperty("httpVersion")){t(null,+e.headers["content-length"])}else if(e.hasOwnProperty("httpModule")){e.on("response",(function(a){e.pause();t(null,+a.headers["content-length"])}));e.resume()}else{t("Unknown stream")}};FormData.prototype._multiPartHeader=function(e,t,a){if(typeof a.header=="string"){return a.header}var r=this._getContentDisposition(t,a);var i=this._getContentType(t,a);var n="";var s={"Content-Disposition":["form-data",'name="'+e+'"'].concat(r||[]),"Content-Type":[].concat(i||[])};if(typeof a.header=="object"){u(s,a.header)}var o;for(var p in s){if(!s.hasOwnProperty(p))continue;o=s[p];if(o==null){continue}if(!Array.isArray(o)){o=[o]}if(o.length){n+=p+": "+o.join("; ")+FormData.LINE_BREAK}}return"--"+this.getBoundary()+FormData.LINE_BREAK+n+FormData.LINE_BREAK};FormData.prototype._getContentDisposition=function(e,t){var a,r;if(typeof t.filepath==="string"){a=n.normalize(t.filepath).replace(/\\/g,"/")}else if(t.filename||e.name||e.path){a=n.basename(t.filename||e.name||e.path)}else if(e.readable&&e.hasOwnProperty("httpVersion")){a=n.basename(e.client._httpMessage.path||"")}if(a){r='filename="'+a+'"'}return r};FormData.prototype._getContentType=function(e,t){var a=t.contentType;if(!a&&e.name){a=c.lookup(e.name)}if(!a&&e.path){a=c.lookup(e.path)}if(!a&&e.readable&&e.hasOwnProperty("httpVersion")){a=e.headers["content-type"]}if(!a&&(t.filepath||t.filename)){a=c.lookup(t.filepath||t.filename)}if(!a&&typeof e=="object"){a=FormData.DEFAULT_CONTENT_TYPE}return a};FormData.prototype._multiPartFooter=function(){return function(e){var t=FormData.LINE_BREAK;var a=this._streams.length===0;if(a){t+=this._lastBoundary()}e(t)}.bind(this)};FormData.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+FormData.LINE_BREAK};FormData.prototype.getHeaders=function(e){var t;var a={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e){if(e.hasOwnProperty(t)){a[t.toLowerCase()]=e[t]}}return a};FormData.prototype.setBoundary=function(e){this._boundary=e};FormData.prototype.getBoundary=function(){if(!this._boundary){this._generateBoundary()}return this._boundary};FormData.prototype.getBuffer=function(){var e=new Buffer.alloc(0);var t=this.getBoundary();for(var a=0,r=this._streams.length;a{e.exports=function(e,t){Object.keys(t).forEach((function(a){e[a]=e[a]||t[a]}));return e}},2107:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var B=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);B(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var L=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new L(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},7094:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(3233);var i=a(2557);var n=a(1333);const s=r.createClientLogger("core-lro");const o=2e3;const p=["succeeded","canceled","failed"];function deserializeState(e){try{return JSON.parse(e).state}catch(t){throw new Error(`Unable to deserialize input state: ${e}`)}}function setStateError(e){const{state:t,stateProxy:a,isOperationError:r}=e;return e=>{if(r(e)){a.setError(t,e);a.setFailed(t)}throw e}}function appendReadableErrorMessage(e,t){let a=e;if(a.slice(-1)!=="."){a=a+"."}return a+" "+t}function simplifyError(e){let t=e.message;let a=e.code;let r=e;while(r.innererror){r=r.innererror;a=r.code;t=appendReadableErrorMessage(t,r.message)}return{code:a,message:t}}function processOperationStatus(e){const{state:t,stateProxy:a,status:r,isDone:i,processResult:n,getError:o,response:p,setErrorAsResult:l}=e;switch(r){case"succeeded":{a.setSucceeded(t);break}case"failed":{const e=o===null||o===void 0?void 0:o(p);let r="";if(e){const{code:t,message:a}=simplifyError(e);r=`. ${t}. ${a}`}const i=`The long-running operation has failed${r}`;a.setError(t,new Error(i));a.setFailed(t);s.warning(i);break}case"canceled":{a.setCanceled(t);break}}if((i===null||i===void 0?void 0:i(p,t))||i===undefined&&["succeeded","canceled"].concat(l?[]:["failed"]).includes(r)){a.setResult(t,buildResult({response:p,state:t,processResult:n}))}}function buildResult(e){const{processResult:t,response:a,state:r}=e;return t?t(a,r):a}async function initOperation(e){const{init:t,stateProxy:a,processResult:r,getOperationStatus:i,withOperationLocation:n,setErrorAsResult:o}=e;const{operationLocation:p,resourceLocation:l,metadata:d,response:c}=await t();if(p)n===null||n===void 0?void 0:n(p,false);const m={metadata:d,operationLocation:p,resourceLocation:l};s.verbose(`LRO: Operation description:`,m);const u=a.initState(m);const h=i({response:c,state:u,operationLocation:p});processOperationStatus({state:u,status:h,stateProxy:a,response:c,setErrorAsResult:o,processResult:r});return u}async function pollOperationHelper(e){const{poll:t,state:a,stateProxy:r,operationLocation:i,getOperationStatus:n,getResourceLocation:o,isOperationError:l,options:d}=e;const c=await t(i,d).catch(setStateError({state:a,stateProxy:r,isOperationError:l}));const m=n(c,a);s.verbose(`LRO: Status:\n\tPolling from: ${a.config.operationLocation}\n\tOperation status: ${m}\n\tPolling status: ${p.includes(m)?"Stopped":"Running"}`);if(m==="succeeded"){const e=o(c,a);if(e!==undefined){return{response:await t(e).catch(setStateError({state:a,stateProxy:r,isOperationError:l})),status:m}}}return{response:c,status:m}}async function pollOperation(e){const{poll:t,state:a,stateProxy:r,options:i,getOperationStatus:n,getResourceLocation:s,getOperationLocation:o,isOperationError:l,withOperationLocation:d,getPollingInterval:c,processResult:m,getError:u,updateState:h,setDelay:g,isDone:y,setErrorAsResult:v}=e;const{operationLocation:b}=a.config;if(b!==undefined){const{response:e,status:x}=await pollOperationHelper({poll:t,getOperationStatus:n,state:a,stateProxy:r,operationLocation:b,getResourceLocation:s,isOperationError:l,options:i});processOperationStatus({status:x,response:e,state:a,stateProxy:r,isDone:y,processResult:m,getError:u,setErrorAsResult:v});if(!p.includes(x)){const t=c===null||c===void 0?void 0:c(e);if(t)g(t);const r=o===null||o===void 0?void 0:o(e,a);if(r!==undefined){const e=b!==r;a.config.operationLocation=r;d===null||d===void 0?void 0:d(r,e)}else d===null||d===void 0?void 0:d(b,false)}h===null||h===void 0?void 0:h(a,e)}}function getOperationLocationPollingUrl(e){const{azureAsyncOperation:t,operationLocation:a}=e;return a!==null&&a!==void 0?a:t}function getLocationHeader(e){return e.headers["location"]}function getOperationLocationHeader(e){return e.headers["operation-location"]}function getAzureAsyncOperationHeader(e){return e.headers["azure-asyncoperation"]}function findResourceLocation(e){var t;const{location:a,requestMethod:r,requestPath:i,resourceLocationConfig:n}=e;switch(r){case"PUT":{return i}case"DELETE":{return undefined}case"PATCH":{return(t=getDefault())!==null&&t!==void 0?t:i}default:{return getDefault()}}function getDefault(){switch(n){case"azure-async-operation":{return undefined}case"original-uri":{return i}case"location":default:{return a}}}}function inferLroMode(e){const{rawResponse:t,requestMethod:a,requestPath:r,resourceLocationConfig:i}=e;const n=getOperationLocationHeader(t);const s=getAzureAsyncOperationHeader(t);const o=getOperationLocationPollingUrl({operationLocation:n,azureAsyncOperation:s});const p=getLocationHeader(t);const l=a===null||a===void 0?void 0:a.toLocaleUpperCase();if(o!==undefined){return{mode:"OperationLocation",operationLocation:o,resourceLocation:findResourceLocation({requestMethod:l,location:p,requestPath:r,resourceLocationConfig:i})}}else if(p!==undefined){return{mode:"ResourceLocation",operationLocation:p}}else if(l==="PUT"&&r){return{mode:"Body",operationLocation:r}}else{return undefined}}function transformStatus(e){const{status:t,statusCode:a}=e;if(typeof t!=="string"&&t!==undefined){throw new Error(`Polling was unsuccessful. Expected status to have a string value or no value but it has instead: ${t}. This doesn't necessarily indicate the operation has failed. Check your Azure subscription or resource status for more information.`)}switch(t===null||t===void 0?void 0:t.toLocaleLowerCase()){case undefined:return toOperationStatus(a);case"succeeded":return"succeeded";case"failed":return"failed";case"running":case"accepted":case"started":case"canceling":case"cancelling":return"running";case"canceled":case"cancelled":return"canceled";default:{s.verbose(`LRO: unrecognized operation status: ${t}`);return t}}}function getStatus(e){var t;const{status:a}=(t=e.body)!==null&&t!==void 0?t:{};return transformStatus({status:a,statusCode:e.statusCode})}function getProvisioningState(e){var t,a;const{properties:r,provisioningState:i}=(t=e.body)!==null&&t!==void 0?t:{};const n=(a=r===null||r===void 0?void 0:r.provisioningState)!==null&&a!==void 0?a:i;return transformStatus({status:n,statusCode:e.statusCode})}function toOperationStatus(e){if(e===202){return"running"}else if(e<300){return"succeeded"}else{return"failed"}}function parseRetryAfter({rawResponse:e}){const t=e.headers["retry-after"];if(t!==undefined){const e=parseInt(t);return isNaN(e)?calculatePollingIntervalFromDate(new Date(t)):e*1e3}return undefined}function getErrorFromResponse(e){const t=e.flatResponse.error;if(!t){s.warning(`The long-running operation failed but there is no error property in the response's body`);return}if(!t.code||!t.message){s.warning(`The long-running operation failed but the error property in the response's body doesn't contain code or message`);return}return t}function calculatePollingIntervalFromDate(e){const t=Math.floor((new Date).getTime());const a=e.getTime();if(t{const e=await i.sendInitialRequest();const t=inferLroMode({rawResponse:e.rawResponse,requestPath:i.requestPath,requestMethod:i.requestMethod,resourceLocationConfig:a});return Object.assign({response:e,operationLocation:t===null||t===void 0?void 0:t.operationLocation,resourceLocation:t===null||t===void 0?void 0:t.resourceLocation},(t===null||t===void 0?void 0:t.mode)?{metadata:{mode:t.mode}}:{})},stateProxy:t,processResult:r?({flatResponse:e},t)=>r(e,t):({flatResponse:e})=>e,getOperationStatus:getStatusFromInitialResponse,setErrorAsResult:n})}function getOperationLocation({rawResponse:e},t){var a;const r=(a=t.config.metadata)===null||a===void 0?void 0:a["mode"];switch(r){case"OperationLocation":{return getOperationLocationPollingUrl({operationLocation:getOperationLocationHeader(e),azureAsyncOperation:getAzureAsyncOperationHeader(e)})}case"ResourceLocation":{return getLocationHeader(e)}case"Body":default:{return undefined}}}function getOperationStatus({rawResponse:e},t){var a;const r=(a=t.config.metadata)===null||a===void 0?void 0:a["mode"];switch(r){case"OperationLocation":{return getStatus(e)}case"ResourceLocation":{return toOperationStatus(e.statusCode)}case"Body":{return getProvisioningState(e)}default:throw new Error(`Internal error: Unexpected operation mode: ${r}`)}}function getResourceLocation({flatResponse:e},t){if(typeof e==="object"){const a=e.resourceLocation;if(a!==undefined){t.config.resourceLocation=a}}return t.config.resourceLocation}function isOperationError(e){return e.name==="RestError"}async function pollHttpOperation(e){const{lro:t,stateProxy:a,options:r,processResult:i,updateState:n,setDelay:s,state:o,setErrorAsResult:p}=e;return pollOperation({state:o,stateProxy:a,setDelay:s,processResult:i?({flatResponse:e},t)=>i(e,t):({flatResponse:e})=>e,getError:getErrorFromResponse,updateState:n,getPollingInterval:parseRetryAfter,getOperationLocation:getOperationLocation,getOperationStatus:getOperationStatus,isOperationError:isOperationError,getResourceLocation:getResourceLocation,options:r,poll:async(e,a)=>t.sendPollRequest(e,a),setErrorAsResult:p})}const createStateProxy$1=()=>({initState:e=>({status:"running",config:e}),setCanceled:e=>e.status="canceled",setError:(e,t)=>e.error=t,setResult:(e,t)=>e.result=t,setRunning:e=>e.status="running",setSucceeded:e=>e.status="succeeded",setFailed:e=>e.status="failed",getError:e=>e.error,getResult:e=>e.result,isCanceled:e=>e.status==="canceled",isFailed:e=>e.status==="failed",isRunning:e=>e.status==="running",isSucceeded:e=>e.status==="succeeded"});function buildCreatePoller(e){const{getOperationLocation:t,getStatusFromInitialResponse:a,getStatusFromPollResponse:r,isOperationError:s,getResourceLocation:p,getPollingInterval:l,getError:d,resolveOnUnsuccessful:c}=e;return async({init:e,poll:m},u)=>{const{processResult:h,updateState:g,withOperationLocation:y,intervalInMs:v=o,restoreFrom:b}=u||{};const x=createStateProxy$1();const w=y?(()=>{let e=false;return(t,a)=>{if(a)y(t);else if(!e)y(t);e=true}})():undefined;const S=b?deserializeState(b):await initOperation({init:e,stateProxy:x,processResult:h,getOperationStatus:a,withOperationLocation:w,setErrorAsResult:!c});let N;const T=new i.AbortController;const E=new Map;const handleProgressEvents=async()=>E.forEach((e=>e(S)));const _="Operation was canceled";let P=v;const C={getOperationState:()=>S,getResult:()=>S.result,isDone:()=>["succeeded","failed","canceled"].includes(S.status),isStopped:()=>N===undefined,stopPolling:()=>{T.abort()},toString:()=>JSON.stringify({state:S}),onProgress:e=>{const t=Symbol();E.set(t,e);return()=>E.delete(t)},pollUntilDone:e=>N!==null&&N!==void 0?N:N=(async()=>{const{abortSignal:t}=e||{};const{signal:a}=t?new i.AbortController([t,T.signal]):T;if(!C.isDone()){await C.poll({abortSignal:a});while(!C.isDone()){await n.delay(P,{abortSignal:a});await C.poll({abortSignal:a})}}if(c){return C.getResult()}else{switch(S.status){case"succeeded":return C.getResult();case"canceled":throw new Error(_);case"failed":throw S.error;case"notStarted":case"running":throw new Error(`Polling completed without succeeding or failing`)}}})().finally((()=>{N=undefined})),async poll(e){if(c){if(C.isDone())return}else{switch(S.status){case"succeeded":return;case"canceled":throw new Error(_);case"failed":throw S.error}}await pollOperation({poll:m,state:S,stateProxy:x,getOperationLocation:t,isOperationError:s,withOperationLocation:w,getPollingInterval:l,getOperationStatus:r,getResourceLocation:p,processResult:h,getError:d,updateState:g,options:e,setDelay:e=>{P=e},setErrorAsResult:!c});await handleProgressEvents();if(!c){switch(S.status){case"canceled":throw new Error(_);case"failed":throw S.error}}}};return C}}async function createHttpPoller(e,t){const{resourceLocationConfig:a,intervalInMs:r,processResult:i,restoreFrom:n,updateState:s,withOperationLocation:o,resolveOnUnsuccessful:p=false}=t||{};return buildCreatePoller({getStatusFromInitialResponse:getStatusFromInitialResponse,getStatusFromPollResponse:getOperationStatus,isOperationError:isOperationError,getOperationLocation:getOperationLocation,getResourceLocation:getResourceLocation,getPollingInterval:parseRetryAfter,getError:getErrorFromResponse,resolveOnUnsuccessful:p})({init:async()=>{const t=await e.sendInitialRequest();const r=inferLroMode({rawResponse:t.rawResponse,requestPath:e.requestPath,requestMethod:e.requestMethod,resourceLocationConfig:a});return Object.assign({response:t,operationLocation:r===null||r===void 0?void 0:r.operationLocation,resourceLocation:r===null||r===void 0?void 0:r.resourceLocation},(r===null||r===void 0?void 0:r.mode)?{metadata:{mode:r.mode}}:{})},poll:e.sendPollRequest},{intervalInMs:r,withOperationLocation:o,restoreFrom:n,updateState:s,processResult:i?({flatResponse:e},t)=>i(e,t):({flatResponse:e})=>e})}const createStateProxy=()=>({initState:e=>({config:e,isStarted:true}),setCanceled:e=>e.isCancelled=true,setError:(e,t)=>e.error=t,setResult:(e,t)=>e.result=t,setRunning:e=>e.isStarted=true,setSucceeded:e=>e.isCompleted=true,setFailed:()=>{},getError:e=>e.error,getResult:e=>e.result,isCanceled:e=>!!e.isCancelled,isFailed:e=>!!e.error,isRunning:e=>!!e.isStarted,isSucceeded:e=>Boolean(e.isCompleted&&!e.isCancelled&&!e.error)});class GenericPollOperation{constructor(e,t,a,r,i,n,s){this.state=e;this.lro=t;this.setErrorAsResult=a;this.lroResourceLocationConfig=r;this.processResult=i;this.updateState=n;this.isDone=s}setPollerConfig(e){this.pollerConfig=e}async update(e){var t;const a=createStateProxy();if(!this.state.isStarted){this.state=Object.assign(Object.assign({},this.state),await initHttpOperation({lro:this.lro,stateProxy:a,resourceLocationConfig:this.lroResourceLocationConfig,processResult:this.processResult,setErrorAsResult:this.setErrorAsResult}))}const r=this.updateState;const i=this.isDone;if(!this.state.isCompleted&&this.state.error===undefined){await pollHttpOperation({lro:this.lro,state:this.state,stateProxy:a,processResult:this.processResult,updateState:r?(e,{rawResponse:t})=>r(e,t):undefined,isDone:i?({flatResponse:e},t)=>i(e,t):undefined,options:e,setDelay:e=>{this.pollerConfig.intervalInMs=e},setErrorAsResult:this.setErrorAsResult})}(t=e===null||e===void 0?void 0:e.fireProgress)===null||t===void 0?void 0:t.call(e,this.state);return this}async cancel(){s.error("`cancelOperation` is deprecated because it wasn't implemented");return this}toString(){return JSON.stringify({state:this.state})}}class PollerStoppedError extends Error{constructor(e){super(e);this.name="PollerStoppedError";Object.setPrototypeOf(this,PollerStoppedError.prototype)}}class PollerCancelledError extends Error{constructor(e){super(e);this.name="PollerCancelledError";Object.setPrototypeOf(this,PollerCancelledError.prototype)}}class Poller{constructor(e){this.resolveOnUnsuccessful=false;this.stopped=true;this.pollProgressCallbacks=[];this.operation=e;this.promise=new Promise(((e,t)=>{this.resolve=e;this.reject=t}));this.promise.catch((()=>{}))}async startPolling(e={}){if(this.stopped){this.stopped=false}while(!this.isStopped()&&!this.isDone()){await this.poll(e);await this.delay()}}async pollOnce(e={}){if(!this.isDone()){this.operation=await this.operation.update({abortSignal:e.abortSignal,fireProgress:this.fireProgress.bind(this)})}this.processUpdatedState()}fireProgress(e){for(const t of this.pollProgressCallbacks){t(e)}}async cancelOnce(e={}){this.operation=await this.operation.cancel(e)}poll(e={}){if(!this.pollOncePromise){this.pollOncePromise=this.pollOnce(e);const clearPollOncePromise=()=>{this.pollOncePromise=undefined};this.pollOncePromise.then(clearPollOncePromise,clearPollOncePromise).catch(this.reject)}return this.pollOncePromise}processUpdatedState(){if(this.operation.state.error){this.stopped=true;if(!this.resolveOnUnsuccessful){this.reject(this.operation.state.error);throw this.operation.state.error}}if(this.operation.state.isCancelled){this.stopped=true;if(!this.resolveOnUnsuccessful){const e=new PollerCancelledError("Operation was canceled");this.reject(e);throw e}}if(this.isDone()&&this.resolve){this.resolve(this.getResult())}}async pollUntilDone(e={}){if(this.stopped){this.startPolling(e).catch(this.reject)}this.processUpdatedState();return this.promise}onProgress(e){this.pollProgressCallbacks.push(e);return()=>{this.pollProgressCallbacks=this.pollProgressCallbacks.filter((t=>t!==e))}}isDone(){const e=this.operation.state;return Boolean(e.isCompleted||e.isCancelled||e.error)}stopPolling(){if(!this.stopped){this.stopped=true;if(this.reject){this.reject(new PollerStoppedError("This poller is already stopped"))}}}isStopped(){return this.stopped}cancelOperation(e={}){if(!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(){const e=this.operation.state;return e.result}toString(){return this.operation.toString()}}class LroEngine extends Poller{constructor(e,t){const{intervalInMs:a=o,resumeFrom:r,resolveOnUnsuccessful:i=false,isDone:n,lroResourceLocationConfig:s,processResult:p,updateState:l}=t||{};const d=r?deserializeState(r):{};const c=new GenericPollOperation(d,e,!i,s,p,l,n);super(c);this.resolveOnUnsuccessful=i;this.config={intervalInMs:a};c.setPollerConfig(this.config)}delay(){return new Promise((e=>setTimeout((()=>e()),this.config.intervalInMs)))}}t.LroEngine=LroEngine;t.Poller=Poller;t.PollerCancelledError=PollerCancelledError;t.PollerStoppedError=PollerStoppedError;t.createHttpPoller=createHttpPoller},4559:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(6429);function getPagedAsyncIterator(e){var t;const a=getItemAsyncIterator(e);return{next(){return a.next()},[Symbol.asyncIterator](){return this},byPage:(t=e===null||e===void 0?void 0:e.byPage)!==null&&t!==void 0?t:t=>{const{continuationToken:a,maxPageSize:r}=t!==null&&t!==void 0?t:{};return getPageAsyncIterator(e,{pageLink:a,maxPageSize:r})}}}function getItemAsyncIterator(e){return r.__asyncGenerator(this,arguments,(function*getItemAsyncIterator_1(){var t,a,i,n;const s=getPageAsyncIterator(e);const o=yield r.__await(s.next());if(!Array.isArray(o.value)){const{toElements:i}=e;if(i){yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(i(o.value))));try{for(var p=r.__asyncValues(s),l;l=yield r.__await(p.next()),!l.done;){const e=l.value;yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(i(e))))}}catch(e){t={error:e}}finally{try{if(l&&!l.done&&(a=p.return))yield r.__await(a.call(p))}finally{if(t)throw t.error}}}else{yield yield r.__await(o.value);yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(s)))}}else{yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(o.value)));try{for(var d=r.__asyncValues(s),c;c=yield r.__await(d.next()),!c.done;){const e=c.value;yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(e)))}}catch(e){i={error:e}}finally{try{if(c&&!c.done&&(n=d.return))yield r.__await(n.call(d))}finally{if(i)throw i.error}}}}))}function getPageAsyncIterator(e,t={}){return r.__asyncGenerator(this,arguments,(function*getPageAsyncIterator_1(){const{pageLink:a,maxPageSize:i}=t;let n=yield r.__await(e.getPage(a!==null&&a!==void 0?a:e.firstPageLink,i));if(!n){return yield r.__await(void 0)}yield yield r.__await(n.page);while(n.nextPageLink){n=yield r.__await(e.getPage(n.nextPageLink,i));if(!n){return yield r.__await(void 0)}yield yield r.__await(n.page)}}))}t.getPagedAsyncIterator=getPagedAsyncIterator},6429:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var B=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);B(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var L=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new L(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},4175:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5163);(function(e){e[e["INTERNAL"]=0]="INTERNAL";e[e["SERVER"]=1]="SERVER";e[e["CLIENT"]=2]="CLIENT";e[e["PRODUCER"]=3]="PRODUCER";e[e["CONSUMER"]=4]="CONSUMER"})(t.SpanKind||(t.SpanKind={}));function getSpan(e){return r.trace.getSpan(e)}function setSpan(e,t){return r.trace.setSpan(e,t)}function setSpanContext(e,t){return r.trace.setSpanContext(e,t)}function getSpanContext(e){return r.trace.getSpanContext(e)}function isSpanContextValid(e){return r.trace.isSpanContextValid(e)}function getTracer(e,t){return r.trace.getTracer(e||"azure/core-tracing",t)}const i=r.context;(function(e){e[e["UNSET"]=0]="UNSET";e[e["OK"]=1]="OK";e[e["ERROR"]=2]="ERROR"})(t.SpanStatusCode||(t.SpanStatusCode={}));function isTracingDisabled(){var e;if(typeof process==="undefined"){return false}const t=(e=process.env.AZURE_TRACING_DISABLED)===null||e===void 0?void 0:e.toLowerCase();if(t==="false"||t==="0"){return false}return Boolean(t)}function createSpanFunction(e){return function(a,n){const s=getTracer();const o=(n===null||n===void 0?void 0:n.tracingOptions)||{};const p=Object.assign({kind:t.SpanKind.INTERNAL},o.spanOptions);const l=e.packagePrefix?`${e.packagePrefix}.${a}`:a;let d;if(isTracingDisabled()){d=r.trace.wrapSpanContext(r.INVALID_SPAN_CONTEXT)}else{d=s.startSpan(l,p,o.tracingContext)}if(e.namespace){d.setAttribute("az.namespace",e.namespace)}let c=o.spanOptions||{};if(d.isRecording()&&e.namespace){c=Object.assign(Object.assign({},o.spanOptions),{attributes:Object.assign(Object.assign({},p.attributes),{"az.namespace":e.namespace})})}const m=Object.assign(Object.assign({},o),{spanOptions:c,tracingContext:setSpan(o.tracingContext||i.active(),d)});const u=Object.assign(Object.assign({},n),{tracingOptions:m});return{span:d,updatedOptions:u}}}const n="00";function extractSpanContextFromTraceParentHeader(e){const t=e.split("-");if(t.length!==4){return}const[a,r,i,s]=t;if(a!==n){return}const o=parseInt(s,16);const p={spanId:i,traceId:r,traceFlags:o};return p}function getTraceParentHeader(e){const t=[];if(!e.traceId){t.push("traceId")}if(!e.spanId){t.push("spanId")}if(t.length){return}const a=e.traceFlags||0;const r=a.toString(16);const i=r.length===1?`0${r}`:r;return`${n}-${e.traceId}-${e.spanId}-${i}`}t.context=i;t.createSpanFunction=createSpanFunction;t.extractSpanContextFromTraceParentHeader=extractSpanContextFromTraceParentHeader;t.getSpan=getSpan;t.getSpanContext=getSpanContext;t.getTraceParentHeader=getTraceParentHeader;t.getTracer=getTracer;t.isSpanContextValid=isSpanContextValid;t.setSpan=setSpan;t.setSpanContext=setSpanContext},1333:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(2557);var i=a(6113);function createAbortablePromise(e,t){const{cleanupBeforeAbort:a,abortSignal:i,abortErrorMsg:n}=t!==null&&t!==void 0?t:{};return new Promise(((t,s)=>{function rejectOnAbort(){s(new r.AbortError(n!==null&&n!==void 0?n:"The operation was aborted."))}function removeListeners(){i===null||i===void 0?void 0:i.removeEventListener("abort",onAbort)}function onAbort(){a===null||a===void 0?void 0:a();removeListeners();rejectOnAbort()}if(i===null||i===void 0?void 0:i.aborted){return rejectOnAbort()}try{e((e=>{removeListeners();t(e)}),(e=>{removeListeners();s(e)}))}catch(e){s(e)}i===null||i===void 0?void 0:i.addEventListener("abort",onAbort)}))}const n="The delay was aborted.";function delay(e,t){let a;const{abortSignal:r,abortErrorMsg:i}=t!==null&&t!==void 0?t:{};return createAbortablePromise((t=>{a=setTimeout(t,e)}),{cleanupBeforeAbort:()=>clearTimeout(a),abortSignal:r,abortErrorMsg:i!==null&&i!==void 0?i:n})}function getRandomIntegerInclusive(e,t){e=Math.ceil(e);t=Math.floor(t);const a=Math.floor(Math.random()*(t-e+1));return a+e}function isObject(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}function isError(e){if(isObject(e)){const t=typeof e.name==="string";const a=typeof e.message==="string";return t&&a}return false}function getErrorMessage(e){if(isError(e)){return e.message}else{let t;try{if(typeof e==="object"&&e){t=JSON.stringify(e)}else{t=String(e)}}catch(e){t="[unable to stringify input]"}return`Unknown error ${t}`}}async function computeSha256Hmac(e,t,a){const r=Buffer.from(e,"base64");return i.createHmac("sha256",r).update(t).digest(a)}async function computeSha256Hash(e,t){return i.createHash("sha256").update(e).digest(t)}function isDefined(e){return typeof e!=="undefined"&&e!==null}function isObjectWithProperties(e,t){if(!isDefined(e)||typeof e!=="object"){return false}for(const a of t){if(!objectHasProperty(e,a)){return false}}return true}function objectHasProperty(e,t){return isDefined(e)&&typeof e==="object"&&t in e}function generateUUID(){let e="";for(let t=0;t<32;t++){const a=Math.floor(Math.random()*16);if(t===12){e+="4"}else if(t===16){e+=a&3|8}else{e+=a.toString(16)}if(t===7||t===11||t===15||t===19){e+="-"}}return e}var s;let o=typeof((s=globalThis===null||globalThis===void 0?void 0:globalThis.crypto)===null||s===void 0?void 0:s.randomUUID)==="function"?globalThis.crypto.randomUUID.bind(globalThis.crypto):i.randomUUID;if(!o){o=generateUUID}function randomUUID(){return o()}var p,l,d,c;const m=typeof window!=="undefined"&&typeof window.document!=="undefined";const u=typeof self==="object"&&typeof(self===null||self===void 0?void 0:self.importScripts)==="function"&&(((p=self.constructor)===null||p===void 0?void 0:p.name)==="DedicatedWorkerGlobalScope"||((l=self.constructor)===null||l===void 0?void 0:l.name)==="ServiceWorkerGlobalScope"||((d=self.constructor)===null||d===void 0?void 0:d.name)==="SharedWorkerGlobalScope");const h=typeof process!=="undefined"&&Boolean(process.version)&&Boolean((c=process.versions)===null||c===void 0?void 0:c.node);const g=typeof Deno!=="undefined"&&typeof Deno.version!=="undefined"&&typeof Deno.version.deno!=="undefined";const y=typeof Bun!=="undefined"&&typeof Bun.version!=="undefined";const v=typeof navigator!=="undefined"&&(navigator===null||navigator===void 0?void 0:navigator.product)==="ReactNative";function uint8ArrayToString(e,t){switch(t){case"utf-8":return uint8ArrayToUtf8String(e);case"base64":return uint8ArrayToBase64(e);case"base64url":return uint8ArrayToBase64Url(e)}}function stringToUint8Array(e,t){switch(t){case"utf-8":return utf8StringToUint8Array(e);case"base64":return base64ToUint8Array(e);case"base64url":return base64UrlToUint8Array(e)}}function uint8ArrayToBase64(e){return Buffer.from(e).toString("base64")}function uint8ArrayToBase64Url(e){return Buffer.from(e).toString("base64url")}function uint8ArrayToUtf8String(e){return Buffer.from(e).toString("utf-8")}function utf8StringToUint8Array(e){return Buffer.from(e)}function base64ToUint8Array(e){return Buffer.from(e,"base64")}function base64UrlToUint8Array(e){return Buffer.from(e,"base64url")}t.computeSha256Hash=computeSha256Hash;t.computeSha256Hmac=computeSha256Hmac;t.createAbortablePromise=createAbortablePromise;t.delay=delay;t.getErrorMessage=getErrorMessage;t.getRandomIntegerInclusive=getRandomIntegerInclusive;t.isBrowser=m;t.isBun=y;t.isDefined=isDefined;t.isDeno=g;t.isError=isError;t.isNode=h;t.isObject=isObject;t.isObjectWithProperties=isObjectWithProperties;t.isReactNative=v;t.isWebWorker=u;t.objectHasProperty=objectHasProperty;t.randomUUID=randomUUID;t.stringToUint8Array=stringToUint8Array;t.uint8ArrayToString=uint8ArrayToString},3233:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(2037);var i=a(3837);function _interopDefaultLegacy(e){return e&&typeof e==="object"&&"default"in e?e:{default:e}}var n=_interopDefaultLegacy(i);function log(e,...t){process.stderr.write(`${n["default"].format(e,...t)}${r.EOL}`)}const s=typeof process!=="undefined"&&process.env&&process.env.DEBUG||undefined;let o;let p=[];let l=[];const d=[];if(s){enable(s)}const c=Object.assign((e=>createDebugger(e)),{enable:enable,enabled:enabled,disable:disable,log:log});function enable(e){o=e;p=[];l=[];const t=/\*/g;const a=e.split(",").map((e=>e.trim().replace(t,".*?")));for(const e of a){if(e.startsWith("-")){l.push(new RegExp(`^${e.substr(1)}$`))}else{p.push(new RegExp(`^${e}$`))}}for(const e of d){e.enabled=enabled(e.namespace)}}function enabled(e){if(e.endsWith("*")){return true}for(const t of l){if(t.test(e)){return false}}for(const t of p){if(t.test(e)){return true}}return false}function disable(){const e=o||"";enable("");return e}function createDebugger(e){const t=Object.assign(debug,{enabled:enabled(e),destroy:destroy,log:c.log,namespace:e,extend:extend});function debug(...a){if(!t.enabled){return}if(a.length>0){a[0]=`${e} ${a[0]}`}t.log(...a)}d.push(t);return t}function destroy(){const e=d.indexOf(this);if(e>=0){d.splice(e,1);return true}return false}function extend(e){const t=createDebugger(`${this.namespace}:${e}`);t.log=this.log;return t}var m=c;const u=new Set;const h=typeof process!=="undefined"&&process.env&&process.env.AZURE_LOG_LEVEL||undefined;let g;const y=m("azure");y.log=(...e)=>{m.log(...e)};const v=["verbose","info","warning","error"];if(h){if(isAzureLogLevel(h)){setLogLevel(h)}else{console.error(`AZURE_LOG_LEVEL set to unknown log level '${h}'; logging is not enabled. Acceptable values: ${v.join(", ")}.`)}}function setLogLevel(e){if(e&&!isAzureLogLevel(e)){throw new Error(`Unknown log level '${e}'. Acceptable values: ${v.join(",")}`)}g=e;const t=[];for(const e of u){if(shouldEnable(e)){t.push(e.namespace)}}m.enable(t.join(","))}function getLogLevel(){return g}const b={verbose:400,info:300,warning:200,error:100};function createClientLogger(e){const t=y.extend(e);patchLogMethod(y,t);return{error:createLogger(t,"error"),warning:createLogger(t,"warning"),info:createLogger(t,"info"),verbose:createLogger(t,"verbose")}}function patchLogMethod(e,t){t.log=(...t)=>{e.log(...t)}}function createLogger(e,t){const a=Object.assign(e.extend(t),{level:t});patchLogMethod(e,a);if(shouldEnable(a)){const e=m.disable();m.enable(e+","+a.namespace)}u.add(a);return a}function shouldEnable(e){return Boolean(g&&b[e.level]<=b[g])}function isAzureLogLevel(e){return v.includes(e)}t.AzureLogger=y;t.createClientLogger=createClientLogger;t.getLogLevel=getLogLevel;t.setLogLevel=setLogLevel},4100:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(4607);var i=a(679);var n=a(4175);var s=a(3233);var o=a(2557);var p=a(2037);var l=a(6113);var d=a(2781);a(4559);var c=a(7094);var m=a(2361);var u=a(7147);var h=a(3837);function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(a){if(a!=="default"){var r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:true,get:function(){return e[a]}})}}))}t["default"]=e;return Object.freeze(t)}var g=_interopNamespace(r);var y=_interopNamespace(p);var v=_interopNamespace(u);var b=_interopNamespace(h);const x={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:true,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"}}}}};const w={serializedName:"Logging",type:{name:"Composite",className:"Logging",modelProperties:{version:{serializedName:"Version",required:true,xmlName:"Version",type:{name:"String"}},deleteProperty:{serializedName:"Delete",required:true,xmlName:"Delete",type:{name:"Boolean"}},read:{serializedName:"Read",required:true,xmlName:"Read",type:{name:"Boolean"}},write:{serializedName:"Write",required:true,xmlName:"Write",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}};const S={serializedName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy",modelProperties:{enabled:{serializedName:"Enabled",required:true,xmlName:"Enabled",type:{name:"Boolean"}},days:{constraints:{InclusiveMinimum:1},serializedName:"Days",xmlName:"Days",type:{name:"Number"}}}}};const N={serializedName:"Metrics",type:{name:"Composite",className:"Metrics",modelProperties:{version:{serializedName:"Version",xmlName:"Version",type:{name:"String"}},enabled:{serializedName:"Enabled",required:true,xmlName:"Enabled",type:{name:"Boolean"}},includeAPIs:{serializedName:"IncludeAPIs",xmlName:"IncludeAPIs",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}};const T={serializedName:"CorsRule",type:{name:"Composite",className:"CorsRule",modelProperties:{allowedOrigins:{serializedName:"AllowedOrigins",required:true,xmlName:"AllowedOrigins",type:{name:"String"}},allowedMethods:{serializedName:"AllowedMethods",required:true,xmlName:"AllowedMethods",type:{name:"String"}},allowedHeaders:{serializedName:"AllowedHeaders",required:true,xmlName:"AllowedHeaders",type:{name:"String"}},exposedHeaders:{serializedName:"ExposedHeaders",required:true,xmlName:"ExposedHeaders",type:{name:"String"}},maxAgeInSeconds:{constraints:{InclusiveMinimum:0},serializedName:"MaxAgeInSeconds",required:true,xmlName:"MaxAgeInSeconds",type:{name:"Number"}}}}};const E={serializedName:"StaticWebsite",type:{name:"Composite",className:"StaticWebsite",modelProperties:{enabled:{serializedName:"Enabled",required:true,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"}}}}};const _={serializedName:"StorageError",type:{name:"Composite",className:"StorageError",modelProperties:{message:{serializedName:"Message",xmlName:"Message",type:{name:"String"}},code:{serializedName:"Code",xmlName:"Code",type:{name:"String"}}}}};const P={serializedName:"BlobServiceStatistics",xmlName:"StorageServiceStats",type:{name:"Composite",className:"BlobServiceStatistics",modelProperties:{geoReplication:{serializedName:"GeoReplication",xmlName:"GeoReplication",type:{name:"Composite",className:"GeoReplication"}}}}};const C={serializedName:"GeoReplication",type:{name:"Composite",className:"GeoReplication",modelProperties:{status:{serializedName:"Status",required:true,xmlName:"Status",type:{name:"Enum",allowedValues:["live","bootstrap","unavailable"]}},lastSyncOn:{serializedName:"LastSyncTime",required:true,xmlName:"LastSyncTime",type:{name:"DateTimeRfc1123"}}}}};const O={serializedName:"ListContainersSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListContainersSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,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:true,xmlName:"Containers",xmlIsWrapped:true,xmlElementName:"Container",type:{name:"Sequence",element:{type:{name:"Composite",className:"ContainerItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const R={serializedName:"ContainerItem",xmlName:"Container",type:{name:"Composite",className:"ContainerItem",modelProperties:{name:{serializedName:"Name",required:true,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"}}}}}}};const D={serializedName:"ContainerProperties",type:{name:"Composite",className:"ContainerProperties",modelProperties:{lastModified:{serializedName:"Last-Modified",required:true,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:true,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"}}}}};const A={serializedName:"KeyInfo",type:{name:"Composite",className:"KeyInfo",modelProperties:{startsOn:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"String"}},expiresOn:{serializedName:"Expiry",required:true,xmlName:"Expiry",type:{name:"String"}}}}};const I={serializedName:"UserDelegationKey",type:{name:"Composite",className:"UserDelegationKey",modelProperties:{signedObjectId:{serializedName:"SignedOid",required:true,xmlName:"SignedOid",type:{name:"String"}},signedTenantId:{serializedName:"SignedTid",required:true,xmlName:"SignedTid",type:{name:"String"}},signedStartsOn:{serializedName:"SignedStart",required:true,xmlName:"SignedStart",type:{name:"String"}},signedExpiresOn:{serializedName:"SignedExpiry",required:true,xmlName:"SignedExpiry",type:{name:"String"}},signedService:{serializedName:"SignedService",required:true,xmlName:"SignedService",type:{name:"String"}},signedVersion:{serializedName:"SignedVersion",required:true,xmlName:"SignedVersion",type:{name:"String"}},value:{serializedName:"Value",required:true,xmlName:"Value",type:{name:"String"}}}}};const B={serializedName:"FilterBlobSegment",xmlName:"EnumerationResults",type:{name:"Composite",className:"FilterBlobSegment",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},where:{serializedName:"Where",required:true,xmlName:"Where",type:{name:"String"}},blobs:{serializedName:"Blobs",required:true,xmlName:"Blobs",xmlIsWrapped:true,xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"FilterBlobItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const L={serializedName:"FilterBlobItem",xmlName:"Blob",type:{name:"Composite",className:"FilterBlobItem",modelProperties:{name:{serializedName:"Name",required:true,xmlName:"Name",type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",type:{name:"String"}},tags:{serializedName:"Tags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags"}}}}};const M={serializedName:"BlobTags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags",modelProperties:{blobTagSet:{serializedName:"BlobTagSet",required:true,xmlName:"TagSet",xmlIsWrapped:true,xmlElementName:"Tag",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobTag"}}}}}}};const k={serializedName:"BlobTag",xmlName:"Tag",type:{name:"Composite",className:"BlobTag",modelProperties:{key:{serializedName:"Key",required:true,xmlName:"Key",type:{name:"String"}},value:{serializedName:"Value",required:true,xmlName:"Value",type:{name:"String"}}}}};const z={serializedName:"SignedIdentifier",xmlName:"SignedIdentifier",type:{name:"Composite",className:"SignedIdentifier",modelProperties:{id:{serializedName:"Id",required:true,xmlName:"Id",type:{name:"String"}},accessPolicy:{serializedName:"AccessPolicy",xmlName:"AccessPolicy",type:{name:"Composite",className:"AccessPolicy"}}}}};const j={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"}}}}};const q={serializedName:"ListBlobsFlatSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsFlatSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",xmlIsAttribute:true,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"}}}}};const U={serializedName:"BlobFlatListSegment",xmlName:"Blobs",type:{name:"Composite",className:"BlobFlatListSegment",modelProperties:{blobItems:{serializedName:"BlobItems",required:true,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}};const H={serializedName:"BlobItemInternal",xmlName:"Blob",type:{name:"Composite",className:"BlobItemInternal",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}},deleted:{serializedName:"Deleted",required:true,xmlName:"Deleted",type:{name:"Boolean"}},snapshot:{serializedName:"Snapshot",required:true,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"}}}}};const V={serializedName:"BlobName",type:{name:"Composite",className:"BlobName",modelProperties:{encoded:{serializedName:"Encoded",xmlName:"Encoded",xmlIsAttribute:true,type:{name:"Boolean"}},content:{serializedName:"content",xmlName:"content",xmlIsMsText:true,type:{name:"String"}}}}};const G={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:true,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:true,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","Cold"]}},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"}}}}};const X={serializedName:"ListBlobsHierarchySegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsHierarchySegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",xmlIsAttribute:true,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"}}}}};const $={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:true,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}};const W={serializedName:"BlobPrefix",type:{name:"Composite",className:"BlobPrefix",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}}}}};const K={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"}}}}}}};const Q={serializedName:"BlockList",type:{name:"Composite",className:"BlockList",modelProperties:{committedBlocks:{serializedName:"CommittedBlocks",xmlName:"CommittedBlocks",xmlIsWrapped:true,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}},uncommittedBlocks:{serializedName:"UncommittedBlocks",xmlName:"UncommittedBlocks",xmlIsWrapped:true,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}}}}};const Y={serializedName:"Block",type:{name:"Composite",className:"Block",modelProperties:{name:{serializedName:"Name",required:true,xmlName:"Name",type:{name:"String"}},size:{serializedName:"Size",required:true,xmlName:"Size",type:{name:"Number"}}}}};const J={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"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const Z={serializedName:"PageRange",xmlName:"PageRange",type:{name:"Composite",className:"PageRange",modelProperties:{start:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:true,xmlName:"End",type:{name:"Number"}}}}};const ee={serializedName:"ClearRange",xmlName:"ClearRange",type:{name:"Composite",className:"ClearRange",modelProperties:{start:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:true,xmlName:"End",type:{name:"Number"}}}}};const te={serializedName:"QueryRequest",xmlName:"QueryRequest",type:{name:"Composite",className:"QueryRequest",modelProperties:{queryType:{serializedName:"QueryType",required:true,xmlName:"QueryType",type:{name:"String"}},expression:{serializedName:"Expression",required:true,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"}}}}};const ae={serializedName:"QuerySerialization",type:{name:"Composite",className:"QuerySerialization",modelProperties:{format:{serializedName:"Format",xmlName:"Format",type:{name:"Composite",className:"QueryFormat"}}}}};const re={serializedName:"QueryFormat",type:{name:"Composite",className:"QueryFormat",modelProperties:{type:{serializedName:"Type",required:true,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"}}}}};const ie={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"}}}}};const ne={serializedName:"JsonTextConfiguration",xmlName:"JsonTextConfiguration",type:{name:"Composite",className:"JsonTextConfiguration",modelProperties:{recordSeparator:{serializedName:"RecordSeparator",xmlName:"RecordSeparator",type:{name:"String"}}}}};const se={serializedName:"ArrowConfiguration",xmlName:"ArrowConfiguration",type:{name:"Composite",className:"ArrowConfiguration",modelProperties:{schema:{serializedName:"Schema",required:true,xmlName:"Schema",xmlIsWrapped:true,xmlElementName:"Field",type:{name:"Sequence",element:{type:{name:"Composite",className:"ArrowField"}}}}}}};const oe={serializedName:"ArrowField",xmlName:"Field",type:{name:"Composite",className:"ArrowField",modelProperties:{type:{serializedName:"Type",required:true,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"}}}}};const pe={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"}}}}};const le={serializedName:"Service_setPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceSetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const de={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"}}}}};const ce={serializedName:"Service_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const me={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"}}}}};const ue={serializedName:"Service_getStatisticsExceptionHeaders",type:{name:"Composite",className:"ServiceGetStatisticsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const fe={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"}}}}};const he={serializedName:"Service_listContainersSegmentExceptionHeaders",type:{name:"Composite",className:"ServiceListContainersSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ge={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"}}}}};const ye={serializedName:"Service_getUserDelegationKeyExceptionHeaders",type:{name:"Composite",className:"ServiceGetUserDelegationKeyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ve={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"}}}}};const be={serializedName:"Service_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ServiceGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const xe={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"}}}}};const we={serializedName:"Service_submitBatchExceptionHeaders",type:{name:"Composite",className:"ServiceSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Se={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"}}}}};const Ne={serializedName:"Service_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ServiceFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Te={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"}}}}};const Ee={serializedName:"Container_createExceptionHeaders",type:{name:"Composite",className:"ContainerCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const _e={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"}}}}};const Pe={serializedName:"Container_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ContainerGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ce={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"}}}}};const Oe={serializedName:"Container_deleteExceptionHeaders",type:{name:"Composite",className:"ContainerDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Re={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"}}}}};const De={serializedName:"Container_setMetadataExceptionHeaders",type:{name:"Composite",className:"ContainerSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ae={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"}}}}};const Ie={serializedName:"Container_getAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Be={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"}}}}};const Le={serializedName:"Container_setAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerSetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Me={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"}}}}};const ke={serializedName:"Container_restoreExceptionHeaders",type:{name:"Composite",className:"ContainerRestoreExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ze={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"}}}}};const je={serializedName:"Container_renameExceptionHeaders",type:{name:"Composite",className:"ContainerRenameExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const qe={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"}}}}};const Ue={serializedName:"Container_submitBatchExceptionHeaders",type:{name:"Composite",className:"ContainerSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Fe={serializedName:"Container_filterBlobsHeaders",type:{name:"Composite",className:"ContainerFilterBlobsHeaders",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"}}}}};const He={serializedName:"Container_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ContainerFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ve={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"}}}}};const Ge={serializedName:"Container_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Xe={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"}}}}};const $e={serializedName:"Container_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const We={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"}}}}};const Ke={serializedName:"Container_renewLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Qe={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"}}}}};const Ye={serializedName:"Container_breakLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Je={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"}}}}};const Ze={serializedName:"Container_changeLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const et={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"}}}}};const tt={serializedName:"Container_listBlobFlatSegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobFlatSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const rt={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"}}}}};const it={serializedName:"Container_listBlobHierarchySegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobHierarchySegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const nt={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"]}}}}};const st={serializedName:"Container_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ot={serializedName:"Blob_downloadHeaders",type:{name:"Composite",className:"BlobDownloadHeaders",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-"},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"}}}}};const pt={serializedName:"Blob_downloadExceptionHeaders",type:{name:"Composite",className:"BlobDownloadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const dt={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"}}}}};const ct={serializedName:"Blob_getPropertiesExceptionHeaders",type:{name:"Composite",className:"BlobGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const mt={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"}}}}};const ut={serializedName:"Blob_deleteExceptionHeaders",type:{name:"Composite",className:"BlobDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ft={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"}}}}};const ht={serializedName:"Blob_undeleteExceptionHeaders",type:{name:"Composite",className:"BlobUndeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const yt={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"}}}}};const vt={serializedName:"Blob_setExpiryExceptionHeaders",type:{name:"Composite",className:"BlobSetExpiryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const bt={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"}}}}};const xt={serializedName:"Blob_setHttpHeadersExceptionHeaders",type:{name:"Composite",className:"BlobSetHttpHeadersExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const wt={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"]}}}}};const St={serializedName:"Blob_setImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobSetImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Nt={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"}}}}};const Tt={serializedName:"Blob_deleteImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobDeleteImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Et={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"}}}}};const _t={serializedName:"Blob_setLegalHoldExceptionHeaders",type:{name:"Composite",className:"BlobSetLegalHoldExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Pt={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"}}}}};const Ct={serializedName:"Blob_setMetadataExceptionHeaders",type:{name:"Composite",className:"BlobSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ot={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"}}}}};const Rt={serializedName:"Blob_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"BlobAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Dt={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"}}}}};const At={serializedName:"Blob_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"BlobReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const It={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"}}}}};const Bt={serializedName:"Blob_renewLeaseExceptionHeaders",type:{name:"Composite",className:"BlobRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Lt={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"}}}}};const Mt={serializedName:"Blob_changeLeaseExceptionHeaders",type:{name:"Composite",className:"BlobChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const kt={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"}}}}};const zt={serializedName:"Blob_breakLeaseExceptionHeaders",type:{name:"Composite",className:"BlobBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const jt={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"}}}}};const qt={serializedName:"Blob_createSnapshotExceptionHeaders",type:{name:"Composite",className:"BlobCreateSnapshotExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ut={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"}}}}};const Ft={serializedName:"Blob_startCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobStartCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ht={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:true,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"}},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"}}}}};const Vt={serializedName:"Blob_copyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Gt={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"}}}}};const Xt={serializedName:"Blob_abortCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobAbortCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const $t={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"}}}}};const Wt={serializedName:"Blob_setTierExceptionHeaders",type:{name:"Composite",className:"BlobSetTierExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Kt={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"]}}}}};const Qt={serializedName:"Blob_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"BlobGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Yt={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"}}}}};const Jt={serializedName:"Blob_queryExceptionHeaders",type:{name:"Composite",className:"BlobQueryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Zt={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"}}}}};const ea={serializedName:"Blob_getTagsExceptionHeaders",type:{name:"Composite",className:"BlobGetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ta={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"}}}}};const aa={serializedName:"Blob_setTagsExceptionHeaders",type:{name:"Composite",className:"BlobSetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ra={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"}}}}};const ia={serializedName:"PageBlob_createExceptionHeaders",type:{name:"Composite",className:"PageBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const na={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"}}}}};const sa={serializedName:"PageBlob_uploadPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const oa={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"}}}}};const pa={serializedName:"PageBlob_clearPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobClearPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const la={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"}}}}};const da={serializedName:"PageBlob_uploadPagesFromURLExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ca={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"}}}}};const ma={serializedName:"PageBlob_getPageRangesExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ua={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"}}}}};const fa={serializedName:"PageBlob_getPageRangesDiffExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesDiffExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ha={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"}}}}};const ga={serializedName:"PageBlob_resizeExceptionHeaders",type:{name:"Composite",className:"PageBlobResizeExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ya={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"}}}}};const va={serializedName:"PageBlob_updateSequenceNumberExceptionHeaders",type:{name:"Composite",className:"PageBlobUpdateSequenceNumberExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ba={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"}}}}};const xa={serializedName:"PageBlob_copyIncrementalExceptionHeaders",type:{name:"Composite",className:"PageBlobCopyIncrementalExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const wa={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"}}}}};const Sa={serializedName:"AppendBlob_createExceptionHeaders",type:{name:"Composite",className:"AppendBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Na={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"}}}}};const Ta={serializedName:"AppendBlob_appendBlockExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ea={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"}}}}};const _a={serializedName:"AppendBlob_appendBlockFromUrlExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Pa={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"}}}}};const Ca={serializedName:"AppendBlob_sealExceptionHeaders",type:{name:"Composite",className:"AppendBlobSealExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Oa={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"}}}}};const Ra={serializedName:"BlockBlob_uploadExceptionHeaders",type:{name:"Composite",className:"BlockBlobUploadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Da={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"}}}}};const Aa={serializedName:"BlockBlob_putBlobFromUrlExceptionHeaders",type:{name:"Composite",className:"BlockBlobPutBlobFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ia={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"}}}}};const Ba={serializedName:"BlockBlob_stageBlockExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const La={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"}}}}};const Ma={serializedName:"BlockBlob_stageBlockFromURLExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ka={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"}}}}};const za={serializedName:"BlockBlob_commitBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobCommitBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ja={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"}}}}};const qa={serializedName:"BlockBlob_getBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobGetBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};var Ua=Object.freeze({__proto__:null,BlobServiceProperties:x,Logging:w,RetentionPolicy:S,Metrics:N,CorsRule:T,StaticWebsite:E,StorageError:_,BlobServiceStatistics:P,GeoReplication:C,ListContainersSegmentResponse:O,ContainerItem:R,ContainerProperties:D,KeyInfo:A,UserDelegationKey:I,FilterBlobSegment:B,FilterBlobItem:L,BlobTags:M,BlobTag:k,SignedIdentifier:z,AccessPolicy:j,ListBlobsFlatSegmentResponse:q,BlobFlatListSegment:U,BlobItemInternal:H,BlobName:V,BlobPropertiesInternal:G,ListBlobsHierarchySegmentResponse:X,BlobHierarchyListSegment:$,BlobPrefix:W,BlockLookupList:K,BlockList:Q,Block:Y,PageList:J,PageRange:Z,ClearRange:ee,QueryRequest:te,QuerySerialization:ae,QueryFormat:re,DelimitedTextConfiguration:ie,JsonTextConfiguration:ne,ArrowConfiguration:se,ArrowField:oe,ServiceSetPropertiesHeaders:pe,ServiceSetPropertiesExceptionHeaders:le,ServiceGetPropertiesHeaders:de,ServiceGetPropertiesExceptionHeaders:ce,ServiceGetStatisticsHeaders:me,ServiceGetStatisticsExceptionHeaders:ue,ServiceListContainersSegmentHeaders:fe,ServiceListContainersSegmentExceptionHeaders:he,ServiceGetUserDelegationKeyHeaders:ge,ServiceGetUserDelegationKeyExceptionHeaders:ye,ServiceGetAccountInfoHeaders:ve,ServiceGetAccountInfoExceptionHeaders:be,ServiceSubmitBatchHeaders:xe,ServiceSubmitBatchExceptionHeaders:we,ServiceFilterBlobsHeaders:Se,ServiceFilterBlobsExceptionHeaders:Ne,ContainerCreateHeaders:Te,ContainerCreateExceptionHeaders:Ee,ContainerGetPropertiesHeaders:_e,ContainerGetPropertiesExceptionHeaders:Pe,ContainerDeleteHeaders:Ce,ContainerDeleteExceptionHeaders:Oe,ContainerSetMetadataHeaders:Re,ContainerSetMetadataExceptionHeaders:De,ContainerGetAccessPolicyHeaders:Ae,ContainerGetAccessPolicyExceptionHeaders:Ie,ContainerSetAccessPolicyHeaders:Be,ContainerSetAccessPolicyExceptionHeaders:Le,ContainerRestoreHeaders:Me,ContainerRestoreExceptionHeaders:ke,ContainerRenameHeaders:ze,ContainerRenameExceptionHeaders:je,ContainerSubmitBatchHeaders:qe,ContainerSubmitBatchExceptionHeaders:Ue,ContainerFilterBlobsHeaders:Fe,ContainerFilterBlobsExceptionHeaders:He,ContainerAcquireLeaseHeaders:Ve,ContainerAcquireLeaseExceptionHeaders:Ge,ContainerReleaseLeaseHeaders:Xe,ContainerReleaseLeaseExceptionHeaders:$e,ContainerRenewLeaseHeaders:We,ContainerRenewLeaseExceptionHeaders:Ke,ContainerBreakLeaseHeaders:Qe,ContainerBreakLeaseExceptionHeaders:Ye,ContainerChangeLeaseHeaders:Je,ContainerChangeLeaseExceptionHeaders:Ze,ContainerListBlobFlatSegmentHeaders:et,ContainerListBlobFlatSegmentExceptionHeaders:tt,ContainerListBlobHierarchySegmentHeaders:rt,ContainerListBlobHierarchySegmentExceptionHeaders:it,ContainerGetAccountInfoHeaders:nt,ContainerGetAccountInfoExceptionHeaders:st,BlobDownloadHeaders:ot,BlobDownloadExceptionHeaders:pt,BlobGetPropertiesHeaders:dt,BlobGetPropertiesExceptionHeaders:ct,BlobDeleteHeaders:mt,BlobDeleteExceptionHeaders:ut,BlobUndeleteHeaders:ft,BlobUndeleteExceptionHeaders:ht,BlobSetExpiryHeaders:yt,BlobSetExpiryExceptionHeaders:vt,BlobSetHttpHeadersHeaders:bt,BlobSetHttpHeadersExceptionHeaders:xt,BlobSetImmutabilityPolicyHeaders:wt,BlobSetImmutabilityPolicyExceptionHeaders:St,BlobDeleteImmutabilityPolicyHeaders:Nt,BlobDeleteImmutabilityPolicyExceptionHeaders:Tt,BlobSetLegalHoldHeaders:Et,BlobSetLegalHoldExceptionHeaders:_t,BlobSetMetadataHeaders:Pt,BlobSetMetadataExceptionHeaders:Ct,BlobAcquireLeaseHeaders:Ot,BlobAcquireLeaseExceptionHeaders:Rt,BlobReleaseLeaseHeaders:Dt,BlobReleaseLeaseExceptionHeaders:At,BlobRenewLeaseHeaders:It,BlobRenewLeaseExceptionHeaders:Bt,BlobChangeLeaseHeaders:Lt,BlobChangeLeaseExceptionHeaders:Mt,BlobBreakLeaseHeaders:kt,BlobBreakLeaseExceptionHeaders:zt,BlobCreateSnapshotHeaders:jt,BlobCreateSnapshotExceptionHeaders:qt,BlobStartCopyFromURLHeaders:Ut,BlobStartCopyFromURLExceptionHeaders:Ft,BlobCopyFromURLHeaders:Ht,BlobCopyFromURLExceptionHeaders:Vt,BlobAbortCopyFromURLHeaders:Gt,BlobAbortCopyFromURLExceptionHeaders:Xt,BlobSetTierHeaders:$t,BlobSetTierExceptionHeaders:Wt,BlobGetAccountInfoHeaders:Kt,BlobGetAccountInfoExceptionHeaders:Qt,BlobQueryHeaders:Yt,BlobQueryExceptionHeaders:Jt,BlobGetTagsHeaders:Zt,BlobGetTagsExceptionHeaders:ea,BlobSetTagsHeaders:ta,BlobSetTagsExceptionHeaders:aa,PageBlobCreateHeaders:ra,PageBlobCreateExceptionHeaders:ia,PageBlobUploadPagesHeaders:na,PageBlobUploadPagesExceptionHeaders:sa,PageBlobClearPagesHeaders:oa,PageBlobClearPagesExceptionHeaders:pa,PageBlobUploadPagesFromURLHeaders:la,PageBlobUploadPagesFromURLExceptionHeaders:da,PageBlobGetPageRangesHeaders:ca,PageBlobGetPageRangesExceptionHeaders:ma,PageBlobGetPageRangesDiffHeaders:ua,PageBlobGetPageRangesDiffExceptionHeaders:fa,PageBlobResizeHeaders:ha,PageBlobResizeExceptionHeaders:ga,PageBlobUpdateSequenceNumberHeaders:ya,PageBlobUpdateSequenceNumberExceptionHeaders:va,PageBlobCopyIncrementalHeaders:ba,PageBlobCopyIncrementalExceptionHeaders:xa,AppendBlobCreateHeaders:wa,AppendBlobCreateExceptionHeaders:Sa,AppendBlobAppendBlockHeaders:Na,AppendBlobAppendBlockExceptionHeaders:Ta,AppendBlobAppendBlockFromUrlHeaders:Ea,AppendBlobAppendBlockFromUrlExceptionHeaders:_a,AppendBlobSealHeaders:Pa,AppendBlobSealExceptionHeaders:Ca,BlockBlobUploadHeaders:Oa,BlockBlobUploadExceptionHeaders:Ra,BlockBlobPutBlobFromUrlHeaders:Da,BlockBlobPutBlobFromUrlExceptionHeaders:Aa,BlockBlobStageBlockHeaders:Ia,BlockBlobStageBlockExceptionHeaders:Ba,BlockBlobStageBlockFromURLHeaders:La,BlockBlobStageBlockFromURLExceptionHeaders:Ma,BlockBlobCommitBlockListHeaders:ka,BlockBlobCommitBlockListExceptionHeaders:za,BlockBlobGetBlockListHeaders:ja,BlockBlobGetBlockListExceptionHeaders:qa});const Fa={parameterPath:["options","contentType"],mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Content-Type",type:{name:"String"}}};const Ha={parameterPath:"blobServiceProperties",mapper:x};const Va={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Ga={parameterPath:"url",mapper:{serializedName:"url",required:true,xmlName:"url",type:{name:"String"}},skipEncoding:true};const Xa={parameterPath:"restype",mapper:{defaultValue:"service",isConstant:true,serializedName:"restype",type:{name:"String"}}};const $a={parameterPath:"comp",mapper:{defaultValue:"properties",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Wa={parameterPath:["options","timeoutInSeconds"],mapper:{constraints:{InclusiveMinimum:0},serializedName:"timeout",xmlName:"timeout",type:{name:"Number"}}};const Ka={parameterPath:"version",mapper:{defaultValue:"2023-01-03",isConstant:true,serializedName:"x-ms-version",type:{name:"String"}}};const Qa={parameterPath:["options","requestId"],mapper:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}}};const Ya={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Ja={parameterPath:"comp",mapper:{defaultValue:"stats",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Za={parameterPath:"comp",mapper:{defaultValue:"list",isConstant:true,serializedName:"comp",type:{name:"String"}}};const er={parameterPath:["options","prefix"],mapper:{serializedName:"prefix",xmlName:"prefix",type:{name:"String"}}};const tr={parameterPath:["options","marker"],mapper:{serializedName:"marker",xmlName:"marker",type:{name:"String"}}};const ar={parameterPath:["options","maxPageSize"],mapper:{constraints:{InclusiveMinimum:1},serializedName:"maxresults",xmlName:"maxresults",type:{name:"Number"}}};const rr={parameterPath:["options","include"],mapper:{serializedName:"include",xmlName:"include",xmlElementName:"ListContainersIncludeType",type:{name:"Sequence",element:{type:{name:"Enum",allowedValues:["metadata","deleted","system"]}}}},collectionFormat:r.QueryCollectionFormat.Csv};const ir={parameterPath:"keyInfo",mapper:A};const nr={parameterPath:"comp",mapper:{defaultValue:"userdelegationkey",isConstant:true,serializedName:"comp",type:{name:"String"}}};const sr={parameterPath:"restype",mapper:{defaultValue:"account",isConstant:true,serializedName:"restype",type:{name:"String"}}};const or={parameterPath:"body",mapper:{serializedName:"body",required:true,xmlName:"body",type:{name:"Stream"}}};const pr={parameterPath:"comp",mapper:{defaultValue:"batch",isConstant:true,serializedName:"comp",type:{name:"String"}}};const lr={parameterPath:"contentLength",mapper:{serializedName:"Content-Length",required:true,xmlName:"Content-Length",type:{name:"Number"}}};const dr={parameterPath:"multipartContentType",mapper:{serializedName:"Content-Type",required:true,xmlName:"Content-Type",type:{name:"String"}}};const cr={parameterPath:"comp",mapper:{defaultValue:"blobs",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mr={parameterPath:["options","where"],mapper:{serializedName:"where",xmlName:"where",type:{name:"String"}}};const ur={parameterPath:"restype",mapper:{defaultValue:"container",isConstant:true,serializedName:"restype",type:{name:"String"}}};const fr={parameterPath:["options","metadata"],mapper:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-meta-"}};const hr={parameterPath:["options","access"],mapper:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}}};const gr={parameterPath:["options","containerEncryptionScope","defaultEncryptionScope"],mapper:{serializedName:"x-ms-default-encryption-scope",xmlName:"x-ms-default-encryption-scope",type:{name:"String"}}};const yr={parameterPath:["options","containerEncryptionScope","preventEncryptionScopeOverride"],mapper:{serializedName:"x-ms-deny-encryption-scope-override",xmlName:"x-ms-deny-encryption-scope-override",type:{name:"Boolean"}}};const vr={parameterPath:["options","leaseAccessConditions","leaseId"],mapper:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}}};const br={parameterPath:["options","modifiedAccessConditions","ifModifiedSince"],mapper:{serializedName:"If-Modified-Since",xmlName:"If-Modified-Since",type:{name:"DateTimeRfc1123"}}};const xr={parameterPath:["options","modifiedAccessConditions","ifUnmodifiedSince"],mapper:{serializedName:"If-Unmodified-Since",xmlName:"If-Unmodified-Since",type:{name:"DateTimeRfc1123"}}};const wr={parameterPath:"comp",mapper:{defaultValue:"metadata",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Sr={parameterPath:"comp",mapper:{defaultValue:"acl",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Nr={parameterPath:["options","containerAcl"],mapper:{serializedName:"containerAcl",xmlName:"SignedIdentifiers",xmlIsWrapped:true,xmlElementName:"SignedIdentifier",type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}}}};const Tr={parameterPath:"comp",mapper:{defaultValue:"undelete",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Er={parameterPath:["options","deletedContainerName"],mapper:{serializedName:"x-ms-deleted-container-name",xmlName:"x-ms-deleted-container-name",type:{name:"String"}}};const _r={parameterPath:["options","deletedContainerVersion"],mapper:{serializedName:"x-ms-deleted-container-version",xmlName:"x-ms-deleted-container-version",type:{name:"String"}}};const Pr={parameterPath:"comp",mapper:{defaultValue:"rename",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Cr={parameterPath:"sourceContainerName",mapper:{serializedName:"x-ms-source-container-name",required:true,xmlName:"x-ms-source-container-name",type:{name:"String"}}};const Or={parameterPath:["options","sourceLeaseId"],mapper:{serializedName:"x-ms-source-lease-id",xmlName:"x-ms-source-lease-id",type:{name:"String"}}};const Rr={parameterPath:"comp",mapper:{defaultValue:"lease",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Dr={parameterPath:"action",mapper:{defaultValue:"acquire",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const Ar={parameterPath:["options","duration"],mapper:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Number"}}};const Ir={parameterPath:["options","proposedLeaseId"],mapper:{serializedName:"x-ms-proposed-lease-id",xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}};const Br={parameterPath:"action",mapper:{defaultValue:"release",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const Lr={parameterPath:"leaseId",mapper:{serializedName:"x-ms-lease-id",required:true,xmlName:"x-ms-lease-id",type:{name:"String"}}};const Mr={parameterPath:"action",mapper:{defaultValue:"renew",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const kr={parameterPath:"action",mapper:{defaultValue:"break",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const zr={parameterPath:["options","breakPeriod"],mapper:{serializedName:"x-ms-lease-break-period",xmlName:"x-ms-lease-break-period",type:{name:"Number"}}};const jr={parameterPath:"action",mapper:{defaultValue:"change",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const qr={parameterPath:"proposedLeaseId",mapper:{serializedName:"x-ms-proposed-lease-id",required:true,xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}};const Ur={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:r.QueryCollectionFormat.Csv};const Fr={parameterPath:"delimiter",mapper:{serializedName:"delimiter",required:true,xmlName:"delimiter",type:{name:"String"}}};const Hr={parameterPath:["options","snapshot"],mapper:{serializedName:"snapshot",xmlName:"snapshot",type:{name:"String"}}};const Vr={parameterPath:["options","versionId"],mapper:{serializedName:"versionid",xmlName:"versionid",type:{name:"String"}}};const Gr={parameterPath:["options","range"],mapper:{serializedName:"x-ms-range",xmlName:"x-ms-range",type:{name:"String"}}};const Xr={parameterPath:["options","rangeGetContentMD5"],mapper:{serializedName:"x-ms-range-get-content-md5",xmlName:"x-ms-range-get-content-md5",type:{name:"Boolean"}}};const $r={parameterPath:["options","rangeGetContentCRC64"],mapper:{serializedName:"x-ms-range-get-content-crc64",xmlName:"x-ms-range-get-content-crc64",type:{name:"Boolean"}}};const Wr={parameterPath:["options","cpkInfo","encryptionKey"],mapper:{serializedName:"x-ms-encryption-key",xmlName:"x-ms-encryption-key",type:{name:"String"}}};const Kr={parameterPath:["options","cpkInfo","encryptionKeySha256"],mapper:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}}};const Qr={parameterPath:["options","cpkInfo","encryptionAlgorithm"],mapper:{serializedName:"x-ms-encryption-algorithm",xmlName:"x-ms-encryption-algorithm",type:{name:"String"}}};const Yr={parameterPath:["options","modifiedAccessConditions","ifMatch"],mapper:{serializedName:"If-Match",xmlName:"If-Match",type:{name:"String"}}};const Jr={parameterPath:["options","modifiedAccessConditions","ifNoneMatch"],mapper:{serializedName:"If-None-Match",xmlName:"If-None-Match",type:{name:"String"}}};const Zr={parameterPath:["options","modifiedAccessConditions","ifTags"],mapper:{serializedName:"x-ms-if-tags",xmlName:"x-ms-if-tags",type:{name:"String"}}};const ei={parameterPath:["options","deleteSnapshots"],mapper:{serializedName:"x-ms-delete-snapshots",xmlName:"x-ms-delete-snapshots",type:{name:"Enum",allowedValues:["include","only"]}}};const ti={parameterPath:["options","blobDeleteType"],mapper:{serializedName:"deletetype",xmlName:"deletetype",type:{name:"String"}}};const ai={parameterPath:"comp",mapper:{defaultValue:"expiry",isConstant:true,serializedName:"comp",type:{name:"String"}}};const ri={parameterPath:"expiryOptions",mapper:{serializedName:"x-ms-expiry-option",required:true,xmlName:"x-ms-expiry-option",type:{name:"String"}}};const ii={parameterPath:["options","expiresOn"],mapper:{serializedName:"x-ms-expiry-time",xmlName:"x-ms-expiry-time",type:{name:"String"}}};const ni={parameterPath:["options","blobHttpHeaders","blobCacheControl"],mapper:{serializedName:"x-ms-blob-cache-control",xmlName:"x-ms-blob-cache-control",type:{name:"String"}}};const si={parameterPath:["options","blobHttpHeaders","blobContentType"],mapper:{serializedName:"x-ms-blob-content-type",xmlName:"x-ms-blob-content-type",type:{name:"String"}}};const oi={parameterPath:["options","blobHttpHeaders","blobContentMD5"],mapper:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}}};const pi={parameterPath:["options","blobHttpHeaders","blobContentEncoding"],mapper:{serializedName:"x-ms-blob-content-encoding",xmlName:"x-ms-blob-content-encoding",type:{name:"String"}}};const li={parameterPath:["options","blobHttpHeaders","blobContentLanguage"],mapper:{serializedName:"x-ms-blob-content-language",xmlName:"x-ms-blob-content-language",type:{name:"String"}}};const di={parameterPath:["options","blobHttpHeaders","blobContentDisposition"],mapper:{serializedName:"x-ms-blob-content-disposition",xmlName:"x-ms-blob-content-disposition",type:{name:"String"}}};const ci={parameterPath:"comp",mapper:{defaultValue:"immutabilityPolicies",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mi={parameterPath:["options","immutabilityPolicyExpiry"],mapper:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}}};const ui={parameterPath:["options","immutabilityPolicyMode"],mapper:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}}};const fi={parameterPath:"comp",mapper:{defaultValue:"legalhold",isConstant:true,serializedName:"comp",type:{name:"String"}}};const hi={parameterPath:"legalHold",mapper:{serializedName:"x-ms-legal-hold",required:true,xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}};const gi={parameterPath:["options","encryptionScope"],mapper:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}}};const yi={parameterPath:"comp",mapper:{defaultValue:"snapshot",isConstant:true,serializedName:"comp",type:{name:"String"}}};const vi={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","Cold"]}}};const bi={parameterPath:["options","rehydratePriority"],mapper:{serializedName:"x-ms-rehydrate-priority",xmlName:"x-ms-rehydrate-priority",type:{name:"Enum",allowedValues:["High","Standard"]}}};const xi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfModifiedSince"],mapper:{serializedName:"x-ms-source-if-modified-since",xmlName:"x-ms-source-if-modified-since",type:{name:"DateTimeRfc1123"}}};const wi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfUnmodifiedSince"],mapper:{serializedName:"x-ms-source-if-unmodified-since",xmlName:"x-ms-source-if-unmodified-since",type:{name:"DateTimeRfc1123"}}};const Si={parameterPath:["options","sourceModifiedAccessConditions","sourceIfMatch"],mapper:{serializedName:"x-ms-source-if-match",xmlName:"x-ms-source-if-match",type:{name:"String"}}};const Ni={parameterPath:["options","sourceModifiedAccessConditions","sourceIfNoneMatch"],mapper:{serializedName:"x-ms-source-if-none-match",xmlName:"x-ms-source-if-none-match",type:{name:"String"}}};const Ti={parameterPath:["options","sourceModifiedAccessConditions","sourceIfTags"],mapper:{serializedName:"x-ms-source-if-tags",xmlName:"x-ms-source-if-tags",type:{name:"String"}}};const Ei={parameterPath:"copySource",mapper:{serializedName:"x-ms-copy-source",required:true,xmlName:"x-ms-copy-source",type:{name:"String"}}};const _i={parameterPath:["options","blobTagsString"],mapper:{serializedName:"x-ms-tags",xmlName:"x-ms-tags",type:{name:"String"}}};const Pi={parameterPath:["options","sealBlob"],mapper:{serializedName:"x-ms-seal-blob",xmlName:"x-ms-seal-blob",type:{name:"Boolean"}}};const Ci={parameterPath:["options","legalHold"],mapper:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}};const Oi={parameterPath:"xMsRequiresSync",mapper:{defaultValue:"true",isConstant:true,serializedName:"x-ms-requires-sync",type:{name:"String"}}};const Ri={parameterPath:["options","sourceContentMD5"],mapper:{serializedName:"x-ms-source-content-md5",xmlName:"x-ms-source-content-md5",type:{name:"ByteArray"}}};const Di={parameterPath:["options","copySourceAuthorization"],mapper:{serializedName:"x-ms-copy-source-authorization",xmlName:"x-ms-copy-source-authorization",type:{name:"String"}}};const Ai={parameterPath:["options","copySourceTags"],mapper:{serializedName:"x-ms-copy-source-tag-option",xmlName:"x-ms-copy-source-tag-option",type:{name:"Enum",allowedValues:["REPLACE","COPY"]}}};const Ii={parameterPath:"comp",mapper:{defaultValue:"copy",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Bi={parameterPath:"copyActionAbortConstant",mapper:{defaultValue:"abort",isConstant:true,serializedName:"x-ms-copy-action",type:{name:"String"}}};const Li={parameterPath:"copyId",mapper:{serializedName:"copyid",required:true,xmlName:"copyid",type:{name:"String"}}};const Mi={parameterPath:"comp",mapper:{defaultValue:"tier",isConstant:true,serializedName:"comp",type:{name:"String"}}};const ki={parameterPath:"tier",mapper:{serializedName:"x-ms-access-tier",required:true,xmlName:"x-ms-access-tier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive","Cold"]}}};const zi={parameterPath:["options","queryRequest"],mapper:te};const ji={parameterPath:"comp",mapper:{defaultValue:"query",isConstant:true,serializedName:"comp",type:{name:"String"}}};const qi={parameterPath:"comp",mapper:{defaultValue:"tags",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Ui={parameterPath:["options","tags"],mapper:M};const Fi={parameterPath:["options","transactionalContentMD5"],mapper:{serializedName:"Content-MD5",xmlName:"Content-MD5",type:{name:"ByteArray"}}};const Hi={parameterPath:["options","transactionalContentCrc64"],mapper:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}};const Vi={parameterPath:"blobType",mapper:{defaultValue:"PageBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const Gi={parameterPath:"blobContentLength",mapper:{serializedName:"x-ms-blob-content-length",required:true,xmlName:"x-ms-blob-content-length",type:{name:"Number"}}};const Xi={parameterPath:["options","blobSequenceNumber"],mapper:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}}};const $i={parameterPath:["options","contentType"],mapper:{defaultValue:"application/octet-stream",isConstant:true,serializedName:"Content-Type",type:{name:"String"}}};const Wi={parameterPath:"body",mapper:{serializedName:"body",required:true,xmlName:"body",type:{name:"Stream"}}};const Ki={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Qi={parameterPath:"comp",mapper:{defaultValue:"page",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Yi={parameterPath:"pageWrite",mapper:{defaultValue:"update",isConstant:true,serializedName:"x-ms-page-write",type:{name:"String"}}};const Ji={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThanOrEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-le",xmlName:"x-ms-if-sequence-number-le",type:{name:"Number"}}};const Zi={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThan"],mapper:{serializedName:"x-ms-if-sequence-number-lt",xmlName:"x-ms-if-sequence-number-lt",type:{name:"Number"}}};const en={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-eq",xmlName:"x-ms-if-sequence-number-eq",type:{name:"Number"}}};const tn={parameterPath:"pageWrite",mapper:{defaultValue:"clear",isConstant:true,serializedName:"x-ms-page-write",type:{name:"String"}}};const an={parameterPath:"sourceUrl",mapper:{serializedName:"x-ms-copy-source",required:true,xmlName:"x-ms-copy-source",type:{name:"String"}}};const rn={parameterPath:"sourceRange",mapper:{serializedName:"x-ms-source-range",required:true,xmlName:"x-ms-source-range",type:{name:"String"}}};const nn={parameterPath:["options","sourceContentCrc64"],mapper:{serializedName:"x-ms-source-content-crc64",xmlName:"x-ms-source-content-crc64",type:{name:"ByteArray"}}};const sn={parameterPath:"range",mapper:{serializedName:"x-ms-range",required:true,xmlName:"x-ms-range",type:{name:"String"}}};const on={parameterPath:"comp",mapper:{defaultValue:"pagelist",isConstant:true,serializedName:"comp",type:{name:"String"}}};const pn={parameterPath:["options","prevsnapshot"],mapper:{serializedName:"prevsnapshot",xmlName:"prevsnapshot",type:{name:"String"}}};const ln={parameterPath:["options","prevSnapshotUrl"],mapper:{serializedName:"x-ms-previous-snapshot-url",xmlName:"x-ms-previous-snapshot-url",type:{name:"String"}}};const dn={parameterPath:"sequenceNumberAction",mapper:{serializedName:"x-ms-sequence-number-action",required:true,xmlName:"x-ms-sequence-number-action",type:{name:"Enum",allowedValues:["max","update","increment"]}}};const cn={parameterPath:"comp",mapper:{defaultValue:"incrementalcopy",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mn={parameterPath:"blobType",mapper:{defaultValue:"AppendBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const un={parameterPath:"comp",mapper:{defaultValue:"appendblock",isConstant:true,serializedName:"comp",type:{name:"String"}}};const fn={parameterPath:["options","appendPositionAccessConditions","maxSize"],mapper:{serializedName:"x-ms-blob-condition-maxsize",xmlName:"x-ms-blob-condition-maxsize",type:{name:"Number"}}};const hn={parameterPath:["options","appendPositionAccessConditions","appendPosition"],mapper:{serializedName:"x-ms-blob-condition-appendpos",xmlName:"x-ms-blob-condition-appendpos",type:{name:"Number"}}};const gn={parameterPath:["options","sourceRange"],mapper:{serializedName:"x-ms-source-range",xmlName:"x-ms-source-range",type:{name:"String"}}};const yn={parameterPath:"comp",mapper:{defaultValue:"seal",isConstant:true,serializedName:"comp",type:{name:"String"}}};const vn={parameterPath:"blobType",mapper:{defaultValue:"BlockBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const bn={parameterPath:["options","copySourceBlobProperties"],mapper:{serializedName:"x-ms-copy-source-blob-properties",xmlName:"x-ms-copy-source-blob-properties",type:{name:"Boolean"}}};const xn={parameterPath:"comp",mapper:{defaultValue:"block",isConstant:true,serializedName:"comp",type:{name:"String"}}};const wn={parameterPath:"blockId",mapper:{serializedName:"blockid",required:true,xmlName:"blockid",type:{name:"String"}}};const Sn={parameterPath:"blocks",mapper:K};const Nn={parameterPath:"comp",mapper:{defaultValue:"blocklist",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Tn={parameterPath:"listType",mapper:{defaultValue:"committed",serializedName:"blocklisttype",required:true,xmlName:"blocklisttype",type:{name:"Enum",allowedValues:["committed","uncommitted","all"]}}};class Service{constructor(e){this.client=e}setProperties(e,t){const a={blobServiceProperties:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,_n)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Pn)}getStatistics(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Cn)}listContainersSegment(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,On)}getUserDelegationKey(e,t){const a={keyInfo:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Rn)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Dn)}submitBatch(e,t,a,r){const i={contentLength:e,multipartContentType:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,An)}filterBlobs(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,In)}}const En=new g.Serializer(Ua,true);const _n={path:"/",httpMethod:"PUT",responses:{202:{headersMapper:pe},default:{bodyMapper:_,headersMapper:le}},requestBody:Ha,queryParameters:[Xa,$a,Wa],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const Pn={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:x,headersMapper:de},default:{bodyMapper:_,headersMapper:ce}},queryParameters:[Xa,$a,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const Cn={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:P,headersMapper:me},default:{bodyMapper:_,headersMapper:ue}},queryParameters:[Xa,Wa,Ja],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const On={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:O,headersMapper:fe},default:{bodyMapper:_,headersMapper:he}},queryParameters:[Wa,Za,er,tr,ar,rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const Rn={path:"/",httpMethod:"POST",responses:{200:{bodyMapper:I,headersMapper:ge},default:{bodyMapper:_,headersMapper:ye}},requestBody:ir,queryParameters:[Xa,Wa,nr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const Dn={path:"/",httpMethod:"GET",responses:{200:{headersMapper:ve},default:{bodyMapper:_,headersMapper:be}},queryParameters:[$a,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:En};const An={path:"/",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:xe},default:{bodyMapper:_,headersMapper:we}},requestBody:or,queryParameters:[Wa,pr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,lr,dr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const In={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:B,headersMapper:Se},default:{bodyMapper:_,headersMapper:Ne}},queryParameters:[Wa,tr,ar,cr,mr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};class Container{constructor(e){this.client=e}create(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ln)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Mn)}delete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,kn)}setMetadata(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,zn)}getAccessPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,jn)}setAccessPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,qn)}restore(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Un)}rename(e,t){const a={sourceContainerName:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Fn)}submitBatch(e,t,a,r){const i={contentLength:e,multipartContentType:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Hn)}filterBlobs(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Vn)}acquireLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Gn)}releaseLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Xn)}renewLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,$n)}breakLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Wn)}changeLease(e,t,a){const r={leaseId:e,proposedLeaseId:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Kn)}listBlobFlatSegment(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Qn)}listBlobHierarchySegment(e,t){const a={delimiter:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Yn)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Jn)}}const Bn=new g.Serializer(Ua,true);const Ln={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Te},default:{bodyMapper:_,headersMapper:Ee}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,hr,gr,yr],isXML:true,serializer:Bn};const Mn={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:_e},default:{bodyMapper:_,headersMapper:Pe}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr],isXML:true,serializer:Bn};const kn={path:"/{containerName}",httpMethod:"DELETE",responses:{202:{headersMapper:Ce},default:{bodyMapper:_,headersMapper:Oe}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr],isXML:true,serializer:Bn};const zn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Re},default:{bodyMapper:_,headersMapper:De}},queryParameters:[Wa,ur,wr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br],isXML:true,serializer:Bn};const jn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}},serializedName:"SignedIdentifiers",xmlName:"SignedIdentifiers",xmlIsWrapped:true,xmlElementName:"SignedIdentifier"},headersMapper:Ae},default:{bodyMapper:_,headersMapper:Ie}},queryParameters:[Wa,ur,Sr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr],isXML:true,serializer:Bn};const qn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Be},default:{bodyMapper:_,headersMapper:Le}},requestBody:Nr,queryParameters:[Wa,ur,Sr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,hr,vr,br,xr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Bn};const Un={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Me},default:{bodyMapper:_,headersMapper:ke}},queryParameters:[Wa,ur,Tr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,Er,_r],isXML:true,serializer:Bn};const Fn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:ze},default:{bodyMapper:_,headersMapper:je}},queryParameters:[Wa,ur,Pr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,Cr,Or],isXML:true,serializer:Bn};const Hn={path:"/{containerName}",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:qe},default:{bodyMapper:_,headersMapper:Ue}},requestBody:or,queryParameters:[Wa,pr,ur],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,lr,dr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Bn};const Vn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:B,headersMapper:Fe},default:{bodyMapper:_,headersMapper:He}},queryParameters:[Wa,tr,ar,cr,mr,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Bn};const Gn={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Ve},default:{bodyMapper:_,headersMapper:Ge}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Dr,Ar,Ir],isXML:true,serializer:Bn};const Xn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Xe},default:{bodyMapper:_,headersMapper:$e}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Br,Lr],isXML:true,serializer:Bn};const $n={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:We},default:{bodyMapper:_,headersMapper:Ke}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,Mr],isXML:true,serializer:Bn};const Wn={path:"/{containerName}",httpMethod:"PUT",responses:{202:{headersMapper:Qe},default:{bodyMapper:_,headersMapper:Ye}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,kr,zr],isXML:true,serializer:Bn};const Kn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Je},default:{bodyMapper:_,headersMapper:Ze}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,jr,qr],isXML:true,serializer:Bn};const Qn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:q,headersMapper:et},default:{bodyMapper:_,headersMapper:tt}},queryParameters:[Wa,Za,er,tr,ar,ur,Ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Bn};const Yn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:X,headersMapper:rt},default:{bodyMapper:_,headersMapper:it}},queryParameters:[Wa,Za,er,tr,ar,ur,Ur,Fr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Bn};const Jn={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:nt},default:{bodyMapper:_,headersMapper:st}},queryParameters:[$a,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:Bn};class Blob$1{constructor(e){this.client=e}download(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,es)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ts)}delete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,as)}undelete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,rs)}setExpiry(e,t){const a={expiryOptions:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,is)}setHttpHeaders(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ns)}setImmutabilityPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ss)}deleteImmutabilityPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,os)}setLegalHold(e,t){const a={legalHold:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ps)}setMetadata(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ls)}acquireLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ds)}releaseLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,cs)}renewLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ms)}changeLease(e,t,a){const r={leaseId:e,proposedLeaseId:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,us)}breakLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,fs)}createSnapshot(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,hs)}startCopyFromURL(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,gs)}copyFromURL(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ys)}abortCopyFromURL(e,t){const a={copyId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,vs)}setTier(e,t){const a={tier:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,bs)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,xs)}query(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ws)}getTags(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ss)}setTags(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ns)}}const Zn=new g.Serializer(Ua,true);const es={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ot},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ot},default:{bodyMapper:_,headersMapper:pt}},queryParameters:[Wa,Hr,Vr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Xr,$r,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const ts={path:"/{containerName}/{blob}",httpMethod:"HEAD",responses:{200:{headersMapper:dt},default:{bodyMapper:_,headersMapper:ct}},queryParameters:[Wa,Hr,Vr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const as={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{202:{headersMapper:mt},default:{bodyMapper:_,headersMapper:ut}},queryParameters:[Wa,Hr,Vr,ti],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,ei],isXML:true,serializer:Zn};const rs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ft},default:{bodyMapper:_,headersMapper:ht}},queryParameters:[Wa,Tr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Zn};const is={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:yt},default:{bodyMapper:_,headersMapper:vt}},queryParameters:[Wa,ai],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,ri,ii],isXML:true,serializer:Zn};const ns={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:bt},default:{bodyMapper:_,headersMapper:xt}},queryParameters:[$a,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,ni,si,oi,pi,li,di],isXML:true,serializer:Zn};const ss={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:wt},default:{bodyMapper:_,headersMapper:St}},queryParameters:[Wa,ci],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,xr,mi,ui],isXML:true,serializer:Zn};const os={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{200:{headersMapper:Nt},default:{bodyMapper:_,headersMapper:Tt}},queryParameters:[Wa,ci],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Zn};const ps={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Et},default:{bodyMapper:_,headersMapper:_t}},queryParameters:[Wa,fi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,hi],isXML:true,serializer:Zn};const ls={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Pt},default:{bodyMapper:_,headersMapper:Ct}},queryParameters:[Wa,wr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi],isXML:true,serializer:Zn};const ds={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ot},default:{bodyMapper:_,headersMapper:Rt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Dr,Ar,Ir,Yr,Jr,Zr],isXML:true,serializer:Zn};const cs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Dt},default:{bodyMapper:_,headersMapper:At}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Br,Lr,Yr,Jr,Zr],isXML:true,serializer:Zn};const ms={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:It},default:{bodyMapper:_,headersMapper:Bt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,Mr,Yr,Jr,Zr],isXML:true,serializer:Zn};const us={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Lt},default:{bodyMapper:_,headersMapper:Mt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,jr,qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const fs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:kt},default:{bodyMapper:_,headersMapper:zt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,kr,zr,Yr,Jr,Zr],isXML:true,serializer:Zn};const hs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:jt},default:{bodyMapper:_,headersMapper:qt}},queryParameters:[Wa,yi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi],isXML:true,serializer:Zn};const gs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Ut},default:{bodyMapper:_,headersMapper:Ft}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Yr,Jr,Zr,mi,ui,vi,bi,xi,wi,Si,Ni,Ti,Ei,_i,Pi,Ci],isXML:true,serializer:Zn};const ys={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Ht},default:{bodyMapper:_,headersMapper:Vt}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Yr,Jr,Zr,mi,ui,gi,vi,xi,wi,Si,Ni,Ei,_i,Ci,Oi,Ri,Di,Ai],isXML:true,serializer:Zn};const vs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:Gt},default:{bodyMapper:_,headersMapper:Xt}},queryParameters:[Wa,Ii,Li],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Bi],isXML:true,serializer:Zn};const bs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:$t},202:{headersMapper:$t},default:{bodyMapper:_,headersMapper:Wt}},queryParameters:[Wa,Hr,Vr,Mi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr,bi,ki],isXML:true,serializer:Zn};const xs={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{headersMapper:Kt},default:{bodyMapper:_,headersMapper:Qt}},queryParameters:[$a,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:Zn};const ws={path:"/{containerName}/{blob}",httpMethod:"POST",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Yt},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Yt},default:{bodyMapper:_,headersMapper:Jt}},requestBody:zi,queryParameters:[Wa,Hr,ji],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Zn};const Ss={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:M,headersMapper:Zt},default:{bodyMapper:_,headersMapper:ea}},queryParameters:[Wa,Hr,Vr,qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr],isXML:true,serializer:Zn};const Ns={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:ta},default:{bodyMapper:_,headersMapper:aa}},requestBody:Ui,queryParameters:[Wa,Vr,qi],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,vr,Zr,Fi,Hi],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Zn};class PageBlob{constructor(e){this.client=e}create(e,t,a){const r={contentLength:e,blobContentLength:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,_s)}uploadPages(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Ps)}clearPages(e,t){const a={contentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Cs)}uploadPagesFromURL(e,t,a,r,i){const n={sourceUrl:e,sourceRange:t,contentLength:a,range:r,options:g.operationOptionsToRequestOptionsBase(i||{})};return this.client.sendOperationRequest(n,Os)}getPageRanges(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Rs)}getPageRangesDiff(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ds)}resize(e,t){const a={blobContentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,As)}updateSequenceNumber(e,t){const a={sequenceNumberAction:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Is)}copyIncremental(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Bs)}}const Ts=new g.Serializer(Ua,true);const Es=new g.Serializer(Ua,false);const _s={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ra},default:{bodyMapper:_,headersMapper:ia}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Vi,Gi,Xi],isXML:true,serializer:Ts};const Ps={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:na},default:{bodyMapper:_,headersMapper:sa}},requestBody:Wi,queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,br,xr,Gr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Fi,Hi,$i,Ki,Yi,Ji,Zi,en],mediaType:"binary",serializer:Es};const Cs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:oa},default:{bodyMapper:_,headersMapper:pa}},queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Gr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Ji,Zi,en,tn],isXML:true,serializer:Ts};const Os={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:la},default:{bodyMapper:_,headersMapper:da}},queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,xi,wi,Si,Ni,Ri,Di,Yi,Ji,Zi,en,an,rn,nn,sn],isXML:true,serializer:Ts};const Rs={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:J,headersMapper:ca},default:{bodyMapper:_,headersMapper:ma}},queryParameters:[Wa,tr,ar,Hr,on],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Yr,Jr,Zr],isXML:true,serializer:Ts};const Ds={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:J,headersMapper:ua},default:{bodyMapper:_,headersMapper:fa}},queryParameters:[Wa,tr,ar,Hr,on,pn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Yr,Jr,Zr,ln],isXML:true,serializer:Ts};const As={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ha},default:{bodyMapper:_,headersMapper:ga}},queryParameters:[$a,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Gi],isXML:true,serializer:Ts};const Is={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ya},default:{bodyMapper:_,headersMapper:va}},queryParameters:[$a,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,Xi,dn],isXML:true,serializer:Ts};const Bs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:ba},default:{bodyMapper:_,headersMapper:xa}},queryParameters:[Wa,cn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Yr,Jr,Zr,Ei],isXML:true,serializer:Ts};class AppendBlob{constructor(e){this.client=e}create(e,t){const a={contentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ks)}appendBlock(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,zs)}appendBlockFromUrl(e,t,a){const r={sourceUrl:e,contentLength:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,js)}seal(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,qs)}}const Ls=new g.Serializer(Ua,true);const Ms=new g.Serializer(Ua,false);const ks={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:wa},default:{bodyMapper:_,headersMapper:Sa}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,_i,Ci,mn],isXML:true,serializer:Ls};const zs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Na},default:{bodyMapper:_,headersMapper:Ta}},requestBody:Wi,queryParameters:[Wa,un],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Fi,Hi,$i,Ki,fn,hn],mediaType:"binary",serializer:Ms};const js={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ea},default:{bodyMapper:_,headersMapper:_a}},queryParameters:[Wa,un],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,xi,wi,Si,Ni,Ri,Di,Fi,an,nn,fn,hn,gn],isXML:true,serializer:Ls};const qs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Pa},default:{bodyMapper:_,headersMapper:Ca}},queryParameters:[Wa,yn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,hn],isXML:true,serializer:Ls};class BlockBlob{constructor(e){this.client=e}upload(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Hs)}putBlobFromUrl(e,t,a){const r={contentLength:e,copySource:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Vs)}stageBlock(e,t,a,r){const i={blockId:e,contentLength:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Gs)}stageBlockFromURL(e,t,a,r){const i={blockId:e,contentLength:t,sourceUrl:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Xs)}commitBlockList(e,t){const a={blocks:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,$s)}getBlockList(e,t){const a={listType:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Ws)}}const Us=new g.Serializer(Ua,true);const Fs=new g.Serializer(Ua,false);const Hs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Oa},default:{bodyMapper:_,headersMapper:Ra}},requestBody:Wi,queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Fi,Hi,$i,Ki,vn],mediaType:"binary",serializer:Fs};const Vs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Da},default:{bodyMapper:_,headersMapper:Aa}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,gi,vi,xi,wi,Si,Ni,Ti,Ei,_i,Ri,Di,Ai,Fi,vn,bn],isXML:true,serializer:Us};const Gs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ia},default:{bodyMapper:_,headersMapper:Ba}},requestBody:Wi,queryParameters:[Wa,xn,wn],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,Wr,Kr,Qr,gi,Fi,Hi,$i,Ki],mediaType:"binary",serializer:Fs};const Xs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:La},default:{bodyMapper:_,headersMapper:Ma}},queryParameters:[Wa,xn,wn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,Wr,Kr,Qr,gi,xi,wi,Si,Ni,Ri,Di,an,nn,gn],isXML:true,serializer:Us};const $s={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ka},default:{bodyMapper:_,headersMapper:za}},requestBody:Sn,queryParameters:[Wa,Nn],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Fi,Hi],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Us};const Ws={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:Q,headersMapper:ja},default:{bodyMapper:_,headersMapper:qa}},queryParameters:[Wa,Hr,Nn,Tn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr],isXML:true,serializer:Us};const Ks=s.createClientLogger("storage-blob");const Qs="12.15.0";const Ys="2023-01-03";const Js=256*1024*1024;const Zs=4e3*1024*1024;const eo=5e4;const to=8*1024*1024;const ao=4*1024*1024;const ro=5;const io=100*1e3;const no="https://storage.azure.com/.default";const so={Parameters:{FORCE_BROWSER_NO_CACHE:"_",SIGNATURE:"sig",SNAPSHOT:"snapshot",VERSIONID:"versionid",TIMEOUT:"timeout"}};const oo={HTTP_ACCEPTED:202,HTTP_CONFLICT:409,HTTP_NOT_FOUND:404,HTTP_PRECON_FAILED:412,HTTP_RANGE_NOT_SATISFIABLE:416};const po={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"};const lo="";const co="*";const mo=1*1024*1024;const uo=256;const fo=4*mo;const ho="\r\n";const go="HTTP/1.1";const yo="AES256";const vo=`DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;`;const bo=["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"];const xo=["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"];const wo="BlobUsesCustomerSpecifiedEncryption";const So="BlobDoesNotUseCustomerSpecifiedEncryption";const No=["10000","10001","10002","10003","10004","10100","10101","10102","10103","10104","11000","11001","11002","11003","11004","11100","11101","11102","11103","11104"];function escapeURLPath(e){const t=r.URLBuilder.parse(e);let a=t.getPath();a=a||"/";a=escape(a);t.setPath(a);return t.toString()}function getProxyUriFromDevConnString(e){let t="";if(e.search("DevelopmentStorageProxyUri=")!==-1){const a=e.split(";");for(const e of a){if(e.trim().startsWith("DevelopmentStorageProxyUri=")){t=e.trim().match("DevelopmentStorageProxyUri=(.*)")[1]}}}return t}function getValueInConnString(e,t){const a=e.split(";");for(const e of a){if(e.trim().startsWith(t)){return e.trim().match(t+"=(.*)")[1]}}return""}function extractConnectionStringParts(e){let t="";if(e.startsWith("UseDevelopmentStorage=true")){t=getProxyUriFromDevConnString(e);e=vo}let a=getValueInConnString(e,"BlobEndpoint");a=a.endsWith("/")?a.slice(0,-1):a;if(e.search("DefaultEndpointsProtocol=")!==-1&&e.search("AccountKey=")!==-1){let r="";let i="";let n=Buffer.from("accountKey","base64");let s="";i=getValueInConnString(e,"AccountName");n=Buffer.from(getValueInConnString(e,"AccountKey"),"base64");if(!a){r=getValueInConnString(e,"DefaultEndpointsProtocol");const t=r.toLowerCase();if(t!=="https"&&t!=="http"){throw new Error("Invalid DefaultEndpointsProtocol in the provided Connection String. Expecting 'https' or 'http'")}s=getValueInConnString(e,"EndpointSuffix");if(!s){throw new Error("Invalid EndpointSuffix in the provided Connection String")}a=`${r}://${i}.blob.${s}`}if(!i){throw new Error("Invalid AccountName in the provided Connection String")}else if(n.length===0){throw new Error("Invalid AccountKey in the provided Connection String")}return{kind:"AccountConnString",url:a,accountName:i,accountKey:n,proxyUri:t}}else{const t=getValueInConnString(e,"SharedAccessSignature");const r=getAccountNameFromUrl(a);if(!a){throw new Error("Invalid BlobEndpoint in the provided SAS Connection String")}else if(!t){throw new Error("Invalid SharedAccessSignature in the provided SAS Connection String")}return{kind:"SASConnString",url:a,accountName:r,accountSas:t}}}function escape(e){return encodeURIComponent(e).replace(/%2F/g,"/").replace(/'/g,"%27").replace(/\+/g,"%20").replace(/%25/g,"%")}function appendToURLPath(e,t){const a=r.URLBuilder.parse(e);let i=a.getPath();i=i?i.endsWith("/")?`${i}${t}`:`${i}/${t}`:t;a.setPath(i);const n=new URL(a.toString());return n.toString()}function setURLParameter(e,t,a){const i=r.URLBuilder.parse(e);i.setQueryParameter(t,a);return i.toString()}function getURLParameter(e,t){const a=r.URLBuilder.parse(e);return a.getQueryParameterValue(t)}function setURLHost(e,t){const a=r.URLBuilder.parse(e);a.setHost(t);return a.toString()}function getURLPath(e){const t=r.URLBuilder.parse(e);return t.getPath()}function getURLScheme(e){const t=r.URLBuilder.parse(e);return t.getScheme()}function getURLPathAndQuery(e){const t=r.URLBuilder.parse(e);const a=t.getPath();if(!a){throw new RangeError("Invalid url without valid path.")}let i=t.getQuery()||"";i=i.trim();if(i!==""){i=i.startsWith("?")?i:`?${i}`}return`${a}${i}`}function getURLQueries(e){let t=r.URLBuilder.parse(e).getQuery();if(!t){return{}}t=t.trim();t=t.startsWith("?")?t.substr(1):t;let a=t.split("&");a=a.filter((e=>{const t=e.indexOf("=");const a=e.lastIndexOf("=");return t>0&&t===a&&ai){e=e.slice(0,i)}const n=e+padStart(t.toString(),a-e.length,"0");return base64encode(n)}async function delay(e,t,a){return new Promise(((r,i)=>{let n;const abortHandler=()=>{if(n!==undefined){clearTimeout(n)}i(a)};const resolveHandler=()=>{if(t!==undefined){t.removeEventListener("abort",abortHandler)}r()};n=setTimeout(resolveHandler,e);if(t!==undefined){t.addEventListener("abort",abortHandler)}}))}function padStart(e,t,a=" "){if(String.prototype.padStart){return e.padStart(t,a)}a=a||" ";if(e.length>t){return e}else{t=t-e.length;if(t>a.length){a+=a.repeat(t/a.length)}return a.slice(0,t)+e}}function iEqual(e,t){return e.toLocaleLowerCase()===t.toLocaleLowerCase()}function getAccountNameFromUrl(e){const t=r.URLBuilder.parse(e);let a;try{if(t.getHost().split(".")[1]==="blob"){a=t.getHost().split(".")[0]}else if(isIpEndpointStyle(t)){a=t.getPath().split("/")[1]}else{a=""}return a}catch(e){throw new Error("Unable to extract accountName with provided information.")}}function isIpEndpointStyle(e){if(e.getHost()===undefined){return false}const t=e.getHost()+(e.getPort()===undefined?"":":"+e.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(t)||e.getPort()!==undefined&&No.includes(e.getPort())}function toBlobTagsString(e){if(e===undefined){return undefined}const t=[];for(const a in e){if(Object.prototype.hasOwnProperty.call(e,a)){const r=e[a];t.push(`${encodeURIComponent(a)}=${encodeURIComponent(r)}`)}}return t.join("&")}function toBlobTags(e){if(e===undefined){return undefined}const t={blobTagSet:[]};for(const a in e){if(Object.prototype.hasOwnProperty.call(e,a)){const r=e[a];t.blobTagSet.push({key:a,value:r})}}return t}function toTags(e){if(e===undefined){return undefined}const t={};for(const a of e.blobTagSet){t[a.key]=a.value}return t}function toQuerySerialization(e){if(e===undefined){return undefined}switch(e.kind){case"csv":return{format:{type:"delimited",delimitedTextConfiguration:{columnSeparator:e.columnSeparator||",",fieldQuote:e.fieldQuote||"",recordSeparator:e.recordSeparator,escapeChar:e.escapeCharacter||"",headersPresent:e.hasHeaders||false}}};case"json":return{format:{type:"json",jsonTextConfiguration:{recordSeparator:e.recordSeparator}}};case"arrow":return{format:{type:"arrow",arrowConfiguration:{schema:e.schema}}};case"parquet":return{format:{type:"parquet"}};default:throw Error("Invalid BlobQueryTextConfiguration.")}}function parseObjectReplicationRecord(e){if(!e){return undefined}if("policy-id"in e){return undefined}const t=[];for(const a in e){const r=a.split("_");const i="or-";if(r[0].startsWith(i)){r[0]=r[0].substring(i.length)}const n={ruleId:r[1],replicationStatus:e[a]};const s=t.findIndex((e=>e.policyId===r[0]));if(s>-1){t[s].rules.push(n)}else{t.push({policyId:r[0],rules:[n]})}}return t}function attachCredential(e,t){e.credential=t;return e}function httpAuthorizationToString(e){return e?e.scheme+" "+e.value:undefined}function BlobNameToString(e){if(e.encoded){return decodeURIComponent(e.content)}else{return e.content}}function ConvertInternalResponseOfListBlobFlat(e){return Object.assign(Object.assign({},e),{segment:{blobItems:e.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))}})}function ConvertInternalResponseOfListBlobHierarchy(e){var t;return Object.assign(Object.assign({},e),{segment:{blobPrefixes:(t=e.segment.blobPrefixes)===null||t===void 0?void 0:t.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t})),blobItems:e.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))}})}function*ExtractPageRangeInfoItems(e){let t=[];let a=[];if(e.pageRange)t=e.pageRange;if(e.clearRange)a=e.clearRange;let r=0;let i=0;while(r=1?Math.floor(a.maxTries):To.maxTries,tryTimeoutInMs:a.tryTimeoutInMs&&a.tryTimeoutInMs>=0?a.tryTimeoutInMs:To.tryTimeoutInMs,retryDelayInMs:a.retryDelayInMs&&a.retryDelayInMs>=0?Math.min(a.retryDelayInMs,a.maxRetryDelayInMs?a.maxRetryDelayInMs:To.maxRetryDelayInMs):To.retryDelayInMs,maxRetryDelayInMs:a.maxRetryDelayInMs&&a.maxRetryDelayInMs>=0?a.maxRetryDelayInMs:To.maxRetryDelayInMs,secondaryHost:a.secondaryHost?a.secondaryHost:To.secondaryHost}}async sendRequest(e){return this.attemptSendRequest(e,false,1)}async attemptSendRequest(e,t,a){const r=e.clone();const i=t||!this.retryOptions.secondaryHost||!(e.method==="GET"||e.method==="HEAD"||e.method==="OPTIONS")||a%2===1;if(!i){r.url=setURLHost(r.url,this.retryOptions.secondaryHost)}if(this.retryOptions.tryTimeoutInMs){r.url=setURLParameter(r.url,so.Parameters.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString())}let n;try{Ks.info(`RetryPolicy: =====> Try=${a} ${i?"Primary":"Secondary"}`);n=await this._nextPolicy.sendRequest(r);if(!this.shouldRetry(i,a,n)){return n}t=t||!i&&n.status===404}catch(e){Ks.error(`RetryPolicy: Caught error, message: ${e.message}, code: ${e.code}`);if(!this.shouldRetry(i,a,n,e)){throw e}}await this.delay(i,a,e.abortSignal);return this.attemptSendRequest(e,t,++a)}shouldRetry(e,t,a,r){if(t>=this.retryOptions.maxTries){Ks.info(`RetryPolicy: Attempt(s) ${t} >= maxTries ${this.retryOptions.maxTries}, no further try.`);return false}const i=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(r){for(const e of i){if(r.name.toUpperCase().includes(e)||r.message.toUpperCase().includes(e)||r.code&&r.code.toString().toUpperCase()===e){Ks.info(`RetryPolicy: Network error ${e} found, will retry.`);return true}}}if(a||r){const t=a?a.status:r?r.statusCode:0;if(!e&&t===404){Ks.info(`RetryPolicy: Secondary access with 404, will retry.`);return true}if(t===503||t===500){Ks.info(`RetryPolicy: Will retry for status code ${t}.`);return true}}if((r===null||r===void 0?void 0:r.code)==="PARSE_ERROR"&&(r===null||r===void 0?void 0:r.message.startsWith(`Error "Error: Unclosed root tag`))){Ks.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry.");return true}return false}async delay(e,a,r){let i=0;if(e){switch(this.retryOptions.retryPolicyType){case t.StorageRetryPolicyType.EXPONENTIAL:i=Math.min((Math.pow(2,a-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;case t.StorageRetryPolicyType.FIXED:i=this.retryOptions.retryDelayInMs;break}}else{i=Math.random()*1e3}Ks.info(`RetryPolicy: Delay for ${i}ms`);return delay(i,r,Eo)}}class StorageRetryPolicyFactory{constructor(e){this.retryOptions=e}create(e,t){return new StorageRetryPolicy(e,t,this.retryOptions)}}class CredentialPolicy extends r.BaseRequestPolicy{sendRequest(e){return this._nextPolicy.sendRequest(this.signRequest(e))}signRequest(e){return e}}class AnonymousCredentialPolicy extends CredentialPolicy{constructor(e,t){super(e,t)}}class Credential{create(e,t){throw new Error("Method should be implemented in children classes.")}}class AnonymousCredential extends Credential{create(e,t){return new AnonymousCredentialPolicy(e,t)}}class TelemetryPolicy extends r.BaseRequestPolicy{constructor(e,t,a){super(e,t);this.telemetry=a}async sendRequest(e){if(r.isNode){if(!e.headers){e.headers=new r.HttpHeaders}if(!e.headers.get(po.USER_AGENT)){e.headers.set(po.USER_AGENT,this.telemetry)}}return this._nextPolicy.sendRequest(e)}}class TelemetryPolicyFactory{constructor(e){const t=[];if(r.isNode){if(e){const a=e.userAgentPrefix||"";if(a.length>0&&t.indexOf(a)===-1){t.push(a)}}const a=`azsdk-js-storageblob/${Qs}`;if(t.indexOf(a)===-1){t.push(a)}let r=`(NODE-VERSION ${process.version})`;if(y){r=`(NODE-VERSION ${process.version}; ${y.type()} ${y.release()})`}if(t.indexOf(r)===-1){t.push(r)}}this.telemetryString=t.join(" ")}create(e,t){return new TelemetryPolicy(e,t,this.telemetryString)}}const _o=new r.DefaultHttpClient;function getCachedDefaultHttpClient(){return _o}const Po={DefaultScope:"/.default",HeaderConstants:{AUTHORIZATION:"authorization"}};const Co={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function beginRefresh(e,t,a){async function tryGetAccessToken(){if(Date.now()e.getToken(t,a);r=beginRefresh(tryGetAccessToken,n.retryIntervalInMs,(o=i===null||i===void 0?void 0:i.expiresOnTimestamp)!==null&&o!==void 0?o:Date.now()).then((e=>{r=null;i=e;return i})).catch((e=>{r=null;i=null;throw e}))}return r}return async e=>{if(s.mustRefresh)return refresh(e);if(s.shouldRefresh){refresh(e)}return i}}function getChallenge(e){const t=e.headers.get("WWW-Authenticate");if(e.status===401&&t){return t}return}function parseChallenge(e){const t=e.slice("Bearer ".length);const a=`${t.trim()} `.split(" ").filter((e=>e));const r=a.map((e=>(([e,t])=>({[e]:t}))(e.trim().split("="))));return r.reduce(((e,t)=>Object.assign(Object.assign({},e),t)),{})}function storageBearerTokenChallengeAuthenticationPolicy(e,t){let a=createTokenCycler(e,t);class StorageBearerTokenChallengeAuthenticationPolicy extends r.BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(t){if(!t.url.toLowerCase().startsWith("https://")){throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.")}const i=a;const n=(await i({abortSignal:t.abortSignal,tracingOptions:{tracingContext:t.tracingContext}})).token;t.headers.set(Po.HeaderConstants.AUTHORIZATION,`Bearer ${n}`);const s=await this._nextPolicy.sendRequest(t);if((s===null||s===void 0?void 0:s.status)===401){const i=getChallenge(s);if(i){const n=parseChallenge(i);const s=n.resource_id+Po.DefaultScope;const o=r.URLBuilder.parse(n.authorization_uri);const p=o.getPath().split("/");const l=p[1];const d=createTokenCycler(e,s);const c=(await d({abortSignal:t.abortSignal,tracingOptions:{tracingContext:t.tracingContext},tenantId:l})).token;a=d;t.headers.set(Po.HeaderConstants.AUTHORIZATION,`Bearer ${c}`);return this._nextPolicy.sendRequest(t)}}return s}}return{create:(e,t)=>new StorageBearerTokenChallengeAuthenticationPolicy(e,t)}}function isPipelineLike(e){if(!e||typeof e!=="object"){return false}const t=e;return Array.isArray(t.factories)&&typeof t.options==="object"&&typeof t.toServiceClientOptions==="function"}class Pipeline{constructor(e,t={}){this.factories=e;this.options=Object.assign(Object.assign({},t),{httpClient:t.httpClient||getCachedDefaultHttpClient()})}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}}function newPipeline(e,t={}){var a;if(e===undefined){e=new AnonymousCredential}const i=new TelemetryPolicyFactory(t.userAgentOptions);const n=[r.tracingPolicy({userAgent:i.telemetryString}),r.keepAlivePolicy(t.keepAliveOptions),i,r.generateClientRequestIdPolicy(),new StorageBrowserPolicyFactory,new StorageRetryPolicyFactory(t.retryOptions),r.deserializationPolicy(undefined,{xmlCharKey:"#"}),r.logPolicy({logger:Ks.info,allowedHeaderNames:bo,allowedQueryParameters:xo})];if(r.isNode){n.push(r.proxyPolicy(t.proxyOptions));n.push(r.disableResponseDecompressionPolicy())}n.push(r.isTokenCredential(e)?attachCredential(storageBearerTokenChallengeAuthenticationPolicy(e,(a=t.audience)!==null&&a!==void 0?a:no),e):e);return new Pipeline(n,t)}class StorageSharedKeyCredentialPolicy extends CredentialPolicy{constructor(e,t,a){super(e,t);this.factory=a}signRequest(e){e.headers.set(po.X_MS_DATE,(new Date).toUTCString());if(e.body&&(typeof e.body==="string"||e.body!==undefined)&&e.body.length>0){e.headers.set(po.CONTENT_LENGTH,Buffer.byteLength(e.body))}const t=[e.method.toUpperCase(),this.getHeaderValueToSign(e,po.CONTENT_LANGUAGE),this.getHeaderValueToSign(e,po.CONTENT_ENCODING),this.getHeaderValueToSign(e,po.CONTENT_LENGTH),this.getHeaderValueToSign(e,po.CONTENT_MD5),this.getHeaderValueToSign(e,po.CONTENT_TYPE),this.getHeaderValueToSign(e,po.DATE),this.getHeaderValueToSign(e,po.IF_MODIFIED_SINCE),this.getHeaderValueToSign(e,po.IF_MATCH),this.getHeaderValueToSign(e,po.IF_NONE_MATCH),this.getHeaderValueToSign(e,po.IF_UNMODIFIED_SINCE),this.getHeaderValueToSign(e,po.RANGE)].join("\n")+"\n"+this.getCanonicalizedHeadersString(e)+this.getCanonicalizedResourceString(e);const a=this.factory.computeHMACSHA256(t);e.headers.set(po.AUTHORIZATION,`SharedKey ${this.factory.accountName}:${a}`);return e}getHeaderValueToSign(e,t){const a=e.headers.get(t);if(!a){return""}if(t===po.CONTENT_LENGTH&&a==="0"){return""}return a}getCanonicalizedHeadersString(e){let t=e.headers.headersArray().filter((e=>e.name.toLowerCase().startsWith(po.PREFIX_FOR_STORAGE)));t.sort(((e,t)=>e.name.toLowerCase().localeCompare(t.name.toLowerCase())));t=t.filter(((e,t,a)=>{if(t>0&&e.name.toLowerCase()===a[t-1].name.toLowerCase()){return false}return true}));let a="";t.forEach((e=>{a+=`${e.name.toLowerCase().trimRight()}:${e.value.trimLeft()}\n`}));return a}getCanonicalizedResourceString(e){const t=getURLPath(e.url)||"/";let a="";a+=`/${this.factory.accountName}${t}`;const r=getURLQueries(e.url);const i={};if(r){const e=[];for(const t in r){if(Object.prototype.hasOwnProperty.call(r,t)){const a=t.toLowerCase();i[a]=r[t];e.push(a)}}e.sort();for(const t of e){a+=`\n${t}:${decodeURIComponent(i[t])}`}}return a}}class StorageSharedKeyCredential extends Credential{constructor(e,t){super();this.accountName=e;this.accountKey=Buffer.from(t,"base64")}create(e,t){return new StorageSharedKeyCredentialPolicy(e,t,this)}computeHMACSHA256(e){return l.createHmac("sha256",this.accountKey).update(e,"utf8").digest("base64")}}const Oo="azure-storage-blob";const Ro="12.15.0";class StorageClientContext extends g.ServiceClient{constructor(e,t){if(e===undefined){throw new Error("'url' cannot be null")}if(!t){t={}}if(!t.userAgent){const e=g.getDefaultUserAgentValue();t.userAgent=`${Oo}/${Ro} ${e}`}super(undefined,t);this.requestContentType="application/json; charset=utf-8";this.baseUri=t.endpoint||"{url}";this.url=e;this.version=t.version||"2023-01-03"}}class StorageClient{constructor(e,t){this.url=escapeURLPath(e);this.accountName=getAccountNameFromUrl(e);this.pipeline=t;this.storageClientContext=new StorageClientContext(this.url,t.toServiceClientOptions());this.isHttps=iEqual(getURLScheme(this.url)||"","https");this.credential=new AnonymousCredential;for(const e of this.pipeline.factories){if(r.isNode&&e instanceof StorageSharedKeyCredential||e instanceof AnonymousCredential){this.credential=e}else if(r.isTokenCredential(e.credential)){this.credential=e.credential}}const a=this.storageClientContext;a.requestContentType=undefined}}const Do=n.createSpanFunction({packagePrefix:"Azure.Storage.Blob",namespace:"Microsoft.Storage"});function convertTracingToRequestOptionsBase(e){var t,a;return{spanOptions:(t=e===null||e===void 0?void 0:e.tracingOptions)===null||t===void 0?void 0:t.spanOptions,tracingContext:(a=e===null||e===void 0?void 0:e.tracingOptions)===null||a===void 0?void 0:a.tracingContext}}class BlobSASPermissions{constructor(){this.read=false;this.add=false;this.create=false;this.write=false;this.delete=false;this.deleteVersion=false;this.tag=false;this.move=false;this.execute=false;this.setImmutabilityPolicy=false;this.permanentDelete=false}static parse(e){const t=new BlobSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"x":t.deleteVersion=true;break;case"t":t.tag=true;break;case"m":t.move=true;break;case"e":t.execute=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;default:throw new RangeError(`Invalid permission: ${a}`)}}return t}static from(e){const t=new BlobSASPermissions;if(e.read){t.read=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.deleteVersion){t.deleteVersion=true}if(e.tag){t.tag=true}if(e.move){t.move=true}if(e.execute){t.execute=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.tag){e.push("t")}if(this.move){e.push("m")}if(this.execute){e.push("e")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}return e.join("")}}class ContainerSASPermissions{constructor(){this.read=false;this.add=false;this.create=false;this.write=false;this.delete=false;this.deleteVersion=false;this.list=false;this.tag=false;this.move=false;this.execute=false;this.setImmutabilityPolicy=false;this.permanentDelete=false;this.filterByTags=false}static parse(e){const t=new ContainerSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"l":t.list=true;break;case"t":t.tag=true;break;case"x":t.deleteVersion=true;break;case"m":t.move=true;break;case"e":t.execute=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;case"f":t.filterByTags=true;break;default:throw new RangeError(`Invalid permission ${a}`)}}return t}static from(e){const t=new ContainerSASPermissions;if(e.read){t.read=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.list){t.list=true}if(e.deleteVersion){t.deleteVersion=true}if(e.tag){t.tag=true}if(e.move){t.move=true}if(e.execute){t.execute=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}if(e.filterByTags){t.filterByTags=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.list){e.push("l")}if(this.tag){e.push("t")}if(this.move){e.push("m")}if(this.execute){e.push("e")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}if(this.filterByTags){e.push("f")}return e.join("")}}class UserDelegationKeyCredential{constructor(e,t){this.accountName=e;this.userDelegationKey=t;this.key=Buffer.from(t.value,"base64")}computeHMACSHA256(e){return l.createHmac("sha256",this.key).update(e,"utf8").digest("base64")}}function ipRangeToString(e){return e.end?`${e.start}-${e.end}`:e.start}t.SASProtocol=void 0;(function(e){e["Https"]="https";e["HttpsAndHttp"]="https,http"})(t.SASProtocol||(t.SASProtocol={}));class SASQueryParameters{constructor(e,t,a,r,i,n,s,o,p,l,d,c,m,u,h,g,y,v,b,x){this.version=e;this.signature=t;if(a!==undefined&&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.encryptionScope=a.encryptionScope;this.resource=a.resource;this.cacheControl=a.cacheControl;this.contentDisposition=a.contentDisposition;this.contentEncoding=a.contentEncoding;this.contentLanguage=a.contentLanguage;this.contentType=a.contentType;if(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}}else{this.services=r;this.resourceTypes=i;this.expiresOn=o;this.permissions=a;this.protocol=n;this.startsOn=s;this.ipRangeInner=p;this.encryptionScope=x;this.identifier=l;this.resource=d;this.cacheControl=c;this.contentDisposition=m;this.contentEncoding=u;this.contentLanguage=h;this.contentType=g;if(y){this.signedOid=y.signedObjectId;this.signedTenantId=y.signedTenantId;this.signedStartsOn=y.signedStartsOn;this.signedExpiresOn=y.signedExpiresOn;this.signedService=y.signedService;this.signedVersion=y.signedVersion;this.preauthorizedAgentObjectId=v;this.correlationId=b}}}get ipRange(){if(this.ipRangeInner){return{end:this.ipRangeInner.end,start:this.ipRangeInner.start}}return undefined}toString(){const e=["sv","ss","srt","spr","st","se","sip","si","ses","skoid","sktid","skt","ske","sks","skv","sr","sp","sig","rscc","rscd","rsce","rscl","rsct","saoid","scid"];const t=[];for(const 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?truncatedISO8061Date(this.startsOn,false):undefined);break;case"se":this.tryAppendQueryParameter(t,a,this.expiresOn?truncatedISO8061Date(this.expiresOn,false):undefined);break;case"sip":this.tryAppendQueryParameter(t,a,this.ipRange?ipRangeToString(this.ipRange):undefined);break;case"si":this.tryAppendQueryParameter(t,a,this.identifier);break;case"ses":this.tryAppendQueryParameter(t,a,this.encryptionScope);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?truncatedISO8061Date(this.signedStartsOn,false):undefined);break;case"ske":this.tryAppendQueryParameter(t,a,this.signedExpiresOn?truncatedISO8061Date(this.signedExpiresOn,false):undefined);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){if(!a){return}t=encodeURIComponent(t);a=encodeURIComponent(a);if(t.length>0&&a.length>0){e.push(`${t}=${a}`)}}}function generateBlobSASQueryParameters(e,t,a){const r=e.version?e.version:Ys;const i=t instanceof StorageSharedKeyCredential?t:undefined;let n;if(i===undefined&&a!==undefined){n=new UserDelegationKeyCredential(a,t)}if(i===undefined&&n===undefined){throw TypeError("Invalid sharedKeyCredential, userDelegationKey or accountName.")}if(r>="2020-12-06"){if(i!==undefined){return generateBlobSASQueryParameters20201206(e,i)}else{return generateBlobSASQueryParametersUDK20201206(e,n)}}if(r>="2018-11-09"){if(i!==undefined){return generateBlobSASQueryParameters20181109(e,i)}else{if(r>="2020-02-10"){return generateBlobSASQueryParametersUDK20200210(e,n)}else{return generateBlobSASQueryParametersUDK20181109(e,n)}}}if(r>="2015-04-05"){if(i!==undefined){return generateBlobSASQueryParameters20150405(e,i)}else{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 generateBlobSASQueryParameters20150405(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";if(e.blobName){a="b"}let r;if(e.permissions){if(e.blobName){r=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{r=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const i=[r?r:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const n=t.computeHMACSHA256(i);return new SASQueryParameters(e.version,n,r,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType)}function generateBlobSASQueryParameters20181109(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType)}function generateBlobSASQueryParameters20201206(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.encryptionScope,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,undefined,undefined,undefined,e.encryptionScope)}function generateBlobSASQueryParametersUDK20181109(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey)}function generateBlobSASQueryParametersUDK20200210(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,undefined,e.correlationId,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId)}function generateBlobSASQueryParametersUDK20201206(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,undefined,e.correlationId,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.encryptionScope,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId,e.encryptionScope)}function getCanonicalName(e,t,a){const r=[`/blob/${e}/${t}`];if(a){r.push(`/${a}`)}return r.join("")}function SASSignatureValuesSanityCheckAndAutofill(e){const t=e.version?e.version:Ys;if(e.snapshotTime&&t<"2018-11-09"){throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.")}if(e.blobName===undefined&&e.snapshotTime){throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.")}if(e.versionId&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.")}if(e.blobName===undefined&&e.versionId){throw RangeError("Must provide 'blobName' when providing 'versionId'.")}if(e.permissions&&e.permissions.setImmutabilityPolicy&&t<"2020-08-04"){throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.")}if(e.permissions&&e.permissions.deleteVersion&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.")}if(e.permissions&&e.permissions.permanentDelete&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'y' permission.")}if(e.permissions&&e.permissions.tag&&t<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.")}if(t<"2020-02-10"&&e.permissions&&(e.permissions.move||e.permissions.execute)){throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.")}if(t<"2021-04-10"&&e.permissions&&e.permissions.filterByTags){throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.")}if(t<"2020-02-10"&&(e.preauthorizedAgentObjectId||e.correlationId)){throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.")}if(e.encryptionScope&&t<"2020-12-06"){throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.")}e.version=t;return e}class BlobLeaseClient{constructor(e,t){const a=new StorageClientContext(e.url,e.pipeline.toServiceClientOptions());this._url=e.url;if(e.name===undefined){this._isContainer=true;this._containerOrBlobOperation=new Container(a)}else{this._isContainer=false;this._containerOrBlobOperation=new Blob$1(a)}if(!t){t=r.generateUuid()}this._leaseId=t}get leaseId(){return this._leaseId}get url(){return this._url}async acquireLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-acquireLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions}),proposedLeaseId:this._leaseId},convertTracingToRequestOptionsBase(d)))}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}async changeLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-changeLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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{const a=await this._containerOrBlobOperation.changeLease(this._leaseId,e,Object.assign({abortSignal:t.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions})},convertTracingToRequestOptionsBase(d)));this._leaseId=e;return a}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}async releaseLease(e={}){var t,a,r,i,s,o;const{span:p,updatedOptions:l}=Do("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)!==lo||((r=e.conditions)===null||r===void 0?void 0:r.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==lo||((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})},convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async renewLease(e={}){var t,a,r,i,s,o;const{span:p,updatedOptions:l}=Do("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)!==lo||((r=e.conditions)===null||r===void 0?void 0:r.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==lo||((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})},convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async breakLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-breakLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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{const a=Object.assign({abortSignal:t.abortSignal,breakPeriod:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions})},convertTracingToRequestOptionsBase(d));return await this._containerOrBlobOperation.breakLease(a)}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}}class RetriableReadableStream extends d.Readable{constructor(e,t,a,r,i={}){super({highWaterMark:i.highWaterMark});this.retries=0;this.sourceDataHandler=e=>{if(this.options.doInjectErrorOnce){this.options.doInjectErrorOnce=undefined;this.source.pause();this.source.removeAllListeners("data");this.source.emit("end");return}this.offset+=e.length;if(this.onProgress){this.onProgress({loadedBytes:this.offset-this.start})}if(!this.push(e)){this.source.pause()}};this.sourceErrorOrEndHandler=e=>{if(e&&e.name==="AbortError"){this.destroy(e);return}this.removeSourceEventHandlers();if(this.offset-1===this.end){this.push(null)}else if(this.offset<=this.end){if(this.retries{this.source=e;this.setSourceEventHandlers();return})).catch((e=>{this.destroy(e)}))}else{this.destroy(new Error(`Data corruption failure: received less data than required and reached maxRetires limitation. Received data offset: ${this.offset-1}, data needed offset: ${this.end}, retries: ${this.retries}, max retries: ${this.maxRetryRequests}`))}}else{this.destroy(new Error(`Data corruption failure: Received more data than original request, data needed offset is ${this.end}, received offset: ${this.offset-1}`))}};this.getter=t;this.source=e;this.start=a;this.offset=a;this.end=a+r-1;this.maxRetryRequests=i.maxRetryRequests&&i.maxRetryRequests>=0?i.maxRetryRequests:0;this.onProgress=i.onProgress;this.options=i;this.setSourceEventHandlers()}_read(){this.source.resume()}setSourceEventHandlers(){this.source.on("data",this.sourceDataHandler);this.source.on("end",this.sourceErrorOrEndHandler);this.source.on("error",this.sourceErrorOrEndHandler)}removeSourceEventHandlers(){this.source.removeListener("data",this.sourceDataHandler);this.source.removeListener("end",this.sourceErrorOrEndHandler);this.source.removeListener("error",this.sourceErrorOrEndHandler)}_destroy(e,t){this.removeSourceEventHandlers();this.source.destroy();t(e===null?undefined:e)}}class BlobDownloadResponse{constructor(e,t,a,r,i={}){this.originalResponse=e;this.blobDownloadStream=new RetriableReadableStream(this.originalResponse.readableStreamBody,t,a,r,i)}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(){return this.originalResponse.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 tagCount(){return this.originalResponse.tagCount}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 lastAccessed(){return this.originalResponse.lastAccessed}get createdOn(){return this.originalResponse.createdOn}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 versionId(){return this.originalResponse.versionId}get isCurrentVersion(){return this.originalResponse.isCurrentVersion}get encryptionKeySha256(){return this.originalResponse.encryptionKeySha256}get contentCrc64(){return this.originalResponse.contentCrc64}get objectReplicationDestinationPolicyId(){return this.originalResponse.objectReplicationDestinationPolicyId}get objectReplicationSourceProperties(){return this.originalResponse.objectReplicationSourceProperties}get isSealed(){return this.originalResponse.isSealed}get immutabilityPolicyExpiresOn(){return this.originalResponse.immutabilityPolicyExpiresOn}get immutabilityPolicyMode(){return this.originalResponse.immutabilityPolicyMode}get legalHold(){return this.originalResponse.legalHold}get contentAsBlob(){return this.originalResponse.blobBody}get readableStreamBody(){return r.isNode?this.blobDownloadStream:undefined}get _response(){return this.originalResponse._response}}const Ao=16;const Io=new Uint8Array([79,98,106,1]);const Bo="avro.codec";const Lo="avro.schema";class AvroParser{static async readFixedBytes(e,t,a={}){const r=await e.read(t,{abortSignal:a.abortSignal});if(r.length!==t){throw new Error("Hit stream end.")}return r}static async readByte(e,t={}){const a=await AvroParser.readFixedBytes(e,1,t);return a[0]}static async readZigZagLong(e,t={}){let a=0;let r=0;let i,n,s;do{i=await AvroParser.readByte(e,t);n=i&128;a|=(i&127)<Number.MAX_SAFE_INTEGER){throw new Error("Integer overflow.")}return r}return a>>1^-(a&1)}static async readLong(e,t={}){return AvroParser.readZigZagLong(e,t)}static async readInt(e,t={}){return AvroParser.readZigZagLong(e,t)}static async readNull(){return null}static async readBoolean(e,t={}){const a=await AvroParser.readByte(e,t);if(a===1){return true}else if(a===0){return false}else{throw new Error("Byte was not a boolean.")}}static async readFloat(e,t={}){const a=await AvroParser.readFixedBytes(e,4,t);const r=new DataView(a.buffer,a.byteOffset,a.byteLength);return r.getFloat32(0,true)}static async readDouble(e,t={}){const a=await AvroParser.readFixedBytes(e,8,t);const r=new DataView(a.buffer,a.byteOffset,a.byteLength);return r.getFloat64(0,true)}static async readBytes(e,t={}){const a=await AvroParser.readLong(e,t);if(a<0){throw new Error("Bytes size was negative.")}return e.read(a,{abortSignal:t.abortSignal})}static async readString(e,t={}){const a=await AvroParser.readBytes(e,t);const r=new TextDecoder;return r.decode(a)}static async readMapPair(e,t,a={}){const r=await AvroParser.readString(e,a);const i=await t(e,a);return{key:r,value:i}}static async readMap(e,t,a={}){const readPairMethod=(e,a={})=>AvroParser.readMapPair(e,t,a);const r=await AvroParser.readArray(e,readPairMethod,a);const i={};for(const e of r){i[e.key]=e.value}return i}static async readArray(e,t,a={}){const r=[];for(let i=await AvroParser.readLong(e,a);i!==0;i=await AvroParser.readLong(e,a)){if(i<0){await AvroParser.readLong(e,a);i=-i}while(i--){const i=await t(e,a);r.push(i)}}return r}}var Mo;(function(e){e["RECORD"]="record";e["ENUM"]="enum";e["ARRAY"]="array";e["MAP"]="map";e["UNION"]="union";e["FIXED"]="fixed"})(Mo||(Mo={}));var ko;(function(e){e["NULL"]="null";e["BOOLEAN"]="boolean";e["INT"]="int";e["LONG"]="long";e["FLOAT"]="float";e["DOUBLE"]="double";e["BYTES"]="bytes";e["STRING"]="string"})(ko||(ko={}));class AvroType{static fromSchema(e){if(typeof e==="string"){return AvroType.fromStringSchema(e)}else if(Array.isArray(e)){return AvroType.fromArraySchema(e)}else{return AvroType.fromObjectSchema(e)}}static fromStringSchema(e){switch(e){case ko.NULL:case ko.BOOLEAN:case ko.INT:case ko.LONG:case ko.FLOAT:case ko.DOUBLE:case ko.BYTES:case ko.STRING:return new AvroPrimitiveType(e);default:throw new Error(`Unexpected Avro type ${e}`)}}static fromArraySchema(e){return new AvroUnionType(e.map(AvroType.fromSchema))}static fromObjectSchema(e){const t=e.type;try{return AvroType.fromStringSchema(t)}catch(e){}switch(t){case Mo.RECORD:if(e.aliases){throw new Error(`aliases currently is not supported, schema: ${e}`)}if(!e.name){throw new Error(`Required attribute 'name' doesn't exist on schema: ${e}`)}const a={};if(!e.fields){throw new Error(`Required attribute 'fields' doesn't exist on schema: ${e}`)}for(const t of e.fields){a[t.name]=AvroType.fromSchema(t.type)}return new AvroRecordType(a,e.name);case Mo.ENUM:if(e.aliases){throw new Error(`aliases currently is not supported, schema: ${e}`)}if(!e.symbols){throw new Error(`Required attribute 'symbols' doesn't exist on schema: ${e}`)}return new AvroEnumType(e.symbols);case Mo.MAP:if(!e.values){throw new Error(`Required attribute 'values' doesn't exist on schema: ${e}`)}return new AvroMapType(AvroType.fromSchema(e.values));case Mo.ARRAY:case Mo.FIXED:default:throw new Error(`Unexpected Avro type ${t} in ${e}`)}}}class AvroPrimitiveType extends AvroType{constructor(e){super();this._primitive=e}read(e,t={}){switch(this._primitive){case ko.NULL:return AvroParser.readNull();case ko.BOOLEAN:return AvroParser.readBoolean(e,t);case ko.INT:return AvroParser.readInt(e,t);case ko.LONG:return AvroParser.readLong(e,t);case ko.FLOAT:return AvroParser.readFloat(e,t);case ko.DOUBLE:return AvroParser.readDouble(e,t);case ko.BYTES:return AvroParser.readBytes(e,t);case ko.STRING:return AvroParser.readString(e,t);default:throw new Error("Unknown Avro Primitive")}}}class AvroEnumType extends AvroType{constructor(e){super();this._symbols=e}async read(e,t={}){const a=await AvroParser.readInt(e,t);return this._symbols[a]}}class AvroUnionType extends AvroType{constructor(e){super();this._types=e}async read(e,t={}){const a=await AvroParser.readInt(e,t);return this._types[a].read(e,t)}}class AvroMapType extends AvroType{constructor(e){super();this._itemType=e}read(e,t={}){const readItemMethod=(e,t)=>this._itemType.read(e,t);return AvroParser.readMap(e,readItemMethod,t)}}class AvroRecordType extends AvroType{constructor(e,t){super();this._fields=e;this._name=t}async read(e,t={}){const a={};a["$schema"]=this._name;for(const r in this._fields){if(Object.prototype.hasOwnProperty.call(this._fields,r)){a[r]=await this._fields[r].read(e,t)}}return a}}function arraysEqual(e,t){if(e===t)return true;if(e==null||t==null)return false;if(e.length!==t.length)return false;for(let a=0;a0){for(let t=0;t0}parseObjects(e={}){return i.__asyncGenerator(this,arguments,(function*parseObjects_1(){if(!this._initialized){yield i.__await(this.initialize(e))}while(this.hasNext()){const t=yield i.__await(this._itemType.read(this._dataStream,{abortSignal:e.abortSignal}));this._itemsRemainingInBlock--;this._objectIndex++;if(this._itemsRemainingInBlock===0){const t=yield i.__await(AvroParser.readFixedBytes(this._dataStream,Ao,{abortSignal:e.abortSignal}));this._blockOffset=this._initialBlockOffset+this._dataStream.position;this._objectIndex=0;if(!arraysEqual(this._syncMarker,t)){throw new Error("Stream is not a valid Avro file.")}try{this._itemsRemainingInBlock=yield i.__await(AvroParser.readLong(this._dataStream,{abortSignal:e.abortSignal}))}catch(e){this._itemsRemainingInBlock=0}if(this._itemsRemainingInBlock>0){yield i.__await(AvroParser.readLong(this._dataStream,{abortSignal:e.abortSignal}))}}yield yield i.__await(t)}}))}}class AvroReadable{}const zo=new o.AbortError("Reading from the avro stream was aborted.");class AvroReadableFromStream extends AvroReadable{constructor(e){super();this._readable=e;this._position=0}toUint8Array(e){if(typeof e==="string"){return Buffer.from(e)}return e}get position(){return this._position}async read(e,t={}){var a;if((a=t.abortSignal)===null||a===void 0?void 0:a.aborted){throw zo}if(e<0){throw new Error(`size parameter should be positive: ${e}`)}if(e===0){return new Uint8Array}if(!this._readable.readable){throw new Error("Stream no longer readable.")}const r=this._readable.read(e);if(r){this._position+=r.length;return this.toUint8Array(r)}else{return new Promise(((a,r)=>{const cleanUp=()=>{this._readable.removeListener("readable",readableCallback);this._readable.removeListener("error",rejectCallback);this._readable.removeListener("end",rejectCallback);this._readable.removeListener("close",rejectCallback);if(t.abortSignal){t.abortSignal.removeEventListener("abort",abortHandler)}};const readableCallback=()=>{const t=this._readable.read(e);if(t){this._position+=t.length;cleanUp();a(this.toUint8Array(t))}};const rejectCallback=()=>{cleanUp();r()};const abortHandler=()=>{cleanUp();r(zo)};this._readable.on("readable",readableCallback);this._readable.once("error",rejectCallback);this._readable.once("end",rejectCallback);this._readable.once("close",rejectCallback);if(t.abortSignal){t.abortSignal.addEventListener("abort",abortHandler)}}))}}}class BlobQuickQueryStream extends d.Readable{constructor(e,t={}){super();this.avroPaused=true;this.source=e;this.onProgress=t.onProgress;this.onError=t.onError;this.avroReader=new AvroReader(new AvroReadableFromStream(this.source));this.avroIter=this.avroReader.parseObjects({abortSignal:t.abortSignal})}_read(){if(this.avroPaused){this.readInternal().catch((e=>{this.emit("error",e)}))}}async readInternal(){this.avroPaused=false;let e;do{e=await this.avroIter.next();if(e.done){break}const t=e.value;const a=t.$schema;if(typeof a!=="string"){throw Error("Missing schema in avro record.")}switch(a){case"com.microsoft.azure.storage.queryBlobContents.resultData":{const e=t.data;if(e instanceof Uint8Array===false){throw Error("Invalid data in avro result record.")}if(!this.push(Buffer.from(e))){this.avroPaused=true}}break;case"com.microsoft.azure.storage.queryBlobContents.progress":{const e=t.bytesScanned;if(typeof e!=="number"){throw Error("Invalid bytesScanned in avro progress record.")}if(this.onProgress){this.onProgress({loadedBytes:e})}}break;case"com.microsoft.azure.storage.queryBlobContents.end":if(this.onProgress){const e=t.totalBytes;if(typeof e!=="number"){throw Error("Invalid totalBytes in avro end record.")}this.onProgress({loadedBytes:e})}this.push(null);break;case"com.microsoft.azure.storage.queryBlobContents.error":if(this.onError){const e=t.fatal;if(typeof e!=="boolean"){throw Error("Invalid fatal in avro error record.")}const a=t.name;if(typeof a!=="string"){throw Error("Invalid name in avro error record.")}const r=t.description;if(typeof r!=="string"){throw Error("Invalid description in avro error record.")}const i=t.position;if(typeof i!=="number"){throw Error("Invalid position in avro error record.")}this.onError({position:i,name:a,isFatal:e,description:r})}break;default:throw Error(`Unknown schema ${a} in avro progress record.`)}}while(!e.done&&!this.avroPaused)}}class BlobQueryResponse{constructor(e,t={}){this.originalResponse=e;this.blobDownloadStream=new BlobQuickQueryStream(this.originalResponse.readableStreamBody,t)}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(){return undefined}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(){return undefined}get readableStreamBody(){return r.isNode?this.blobDownloadStream:undefined}get _response(){return this.originalResponse._response}}t.BlockBlobTier=void 0;(function(e){e["Hot"]="Hot";e["Cool"]="Cool";e["Cold"]="Cold";e["Archive"]="Archive"})(t.BlockBlobTier||(t.BlockBlobTier={}));t.PremiumPageBlobTier=void 0;(function(e){e["P4"]="P4";e["P6"]="P6";e["P10"]="P10";e["P15"]="P15";e["P20"]="P20";e["P30"]="P30";e["P40"]="P40";e["P50"]="P50";e["P60"]="P60";e["P70"]="P70";e["P80"]="P80"})(t.PremiumPageBlobTier||(t.PremiumPageBlobTier={}));function toAccessTier(e){if(e===undefined){return undefined}return e}function ensureCpkIfSpecified(e,t){if(e&&!t){throw new RangeError("Customer-provided encryption key must be used over HTTPS.")}if(e&&!e.encryptionAlgorithm){e.encryptionAlgorithm=yo}}t.StorageBlobAudience=void 0;(function(e){e["StorageOAuthScopes"]="https://storage.azure.com/.default";e["DiskComputeOAuthScopes"]="https://disk.compute.azure.com/.default"})(t.StorageBlobAudience||(t.StorageBlobAudience={}));function rangeResponseFromModel(e){const t=(e._response.parsedBody.pageRange||[]).map((e=>({offset:e.start,count:e.end-e.start})));const a=(e._response.parsedBody.clearRange||[]).map((e=>({offset:e.start,count:e.end-e.start})));return Object.assign(Object.assign({},e),{pageRange:t,clearRange:a,_response:Object.assign(Object.assign({},e._response),{parsedBody:{pageRange:t,clearRange:a}})})}class BlobBeginCopyFromUrlPoller extends c.Poller{constructor(e){const{blobClient:t,copySource:a,intervalInMs:r=15e3,onProgress:i,resumeFrom:n,startCopyFromURLOptions:s}=e;let o;if(n){o=JSON.parse(n).state}const p=makeBlobBeginCopyFromURLPollOperation(Object.assign(Object.assign({},o),{blobClient:t,copySource:a,startCopyFromURLOptions:s}));super(p);if(typeof i==="function"){this.onProgress(i)}this.intervalInMs=r}delay(){return r.delay(this.intervalInMs)}}const jo=async function cancel(e={}){const t=this.state;const{copyId:a}=t;if(t.isCompleted){return makeBlobBeginCopyFromURLPollOperation(t)}if(!a){t.isCancelled=true;return makeBlobBeginCopyFromURLPollOperation(t)}await t.blobClient.abortCopyFromURL(a,{abortSignal:e.abortSignal});t.isCancelled=true;return makeBlobBeginCopyFromURLPollOperation(t)};const qo=async function update(e={}){const t=this.state;const{blobClient:a,copySource:r,startCopyFromURLOptions:i}=t;if(!t.isStarted){t.isStarted=true;const e=await a.startCopyFromURL(r,i);t.copyId=e.copyId;if(e.copyStatus==="success"){t.result=e;t.isCompleted=true}}else if(!t.isCompleted){try{const a=await t.blobClient.getProperties({abortSignal:e.abortSignal});const{copyStatus:r,copyProgress:i}=a;const n=t.copyProgress;if(i){t.copyProgress=i}if(r==="pending"&&i!==n&&typeof e.fireProgress==="function"){e.fireProgress(t)}else if(r==="success"){t.result=a;t.isCompleted=true}else if(r==="failed"){t.error=new Error(`Blob copy failed with reason: "${a.copyStatusDescription||"unknown"}"`);t.isCompleted=true}}catch(e){t.error=e;t.isCompleted=true}}return makeBlobBeginCopyFromURLPollOperation(t)};const Uo=function toString(){return JSON.stringify({state:this.state},((e,t)=>{if(e==="blobClient"){return undefined}return t}))};function makeBlobBeginCopyFromURLPollOperation(e){return{state:Object.assign({},e),cancel:jo,toString:Uo,update:qo}}function rangeToString(e){if(e.offset<0){throw new RangeError(`Range.offset cannot be smaller than 0.`)}if(e.count&&e.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 e.count?`bytes=${e.offset}-${e.offset+e.count-1}`:`bytes=${e.offset}-`}var Fo;(function(e){e[e["Good"]=0]="Good";e[e["Error"]=1]="Error"})(Fo||(Fo={}));class Batch{constructor(e=5){this.actives=0;this.completed=0;this.offset=0;this.operations=[];this.state=Fo.Good;if(e<1){throw new RangeError("concurrency must be larger than 0")}this.concurrency=e;this.emitter=new m.EventEmitter}addOperation(e){this.operations.push((async()=>{try{this.actives++;await e();this.actives--;this.completed++;this.parallelExecute()}catch(e){this.emitter.emit("error",e)}}))}async do(){if(this.operations.length===0){return Promise.resolve()}this.parallelExecute();return new Promise(((e,t)=>{this.emitter.on("finish",e);this.emitter.on("error",(e=>{this.state=Fo.Error;t(e)}))}))}nextOperation(){if(this.offset=this.operations.length){this.emitter.emit("finish");return}while(this.actives=this.byteLength){this.push(null)}if(!e){e=this.readableHighWaterMark}const t=[];let a=0;while(ae-a){const r=this.byteOffsetInCurrentBuffer+e-a;t.push(this.buffers[this.bufferIndex].slice(this.byteOffsetInCurrentBuffer,r));this.pushedBytesLength+=e-a;this.byteOffsetInCurrentBuffer=r;a=e;break}else{const e=this.byteOffsetInCurrentBuffer+n;t.push(this.buffers[this.bufferIndex].slice(this.byteOffsetInCurrentBuffer,e));if(n===i){this.byteOffsetInCurrentBuffer=0;this.bufferIndex++}else{this.byteOffsetInCurrentBuffer=e}this.pushedBytesLength+=n;a+=n}}if(t.length>1){this.push(Buffer.concat(t))}else if(t.length===1){this.push(t[0])}}}const Ho=a(4300).constants.MAX_LENGTH;class PooledBuffer{constructor(e,t,a){this.buffers=[];this.capacity=e;this._size=0;const r=Math.ceil(e/Ho);for(let t=0;t0){e[0]=e[0].slice(n)}}getReadableStream(){return new BuffersStream(this.buffers,this.size)}}class BufferScheduler{constructor(e,t,a,r,i,n){this.emitter=new m.EventEmitter;this.offset=0;this.isStreamEnd=false;this.isError=false;this.executingOutgoingHandlers=0;this.numBuffers=0;this.unresolvedDataArray=[];this.unresolvedLength=0;this.incoming=[];this.outgoing=[];if(t<=0){throw new RangeError(`bufferSize must be larger than 0, current is ${t}`)}if(a<=0){throw new RangeError(`maxBuffers must be larger than 0, current is ${a}`)}if(i<=0){throw new RangeError(`concurrency must be larger than 0, current is ${i}`)}this.bufferSize=t;this.maxBuffers=a;this.readable=e;this.outgoingHandler=r;this.concurrency=i;this.encoding=n}async do(){return new Promise(((e,t)=>{this.readable.on("data",(e=>{e=typeof e==="string"?Buffer.from(e,this.encoding):e;this.appendUnresolvedData(e);if(!this.resolveData()){this.readable.pause()}}));this.readable.on("error",(e=>{this.emitter.emit("error",e)}));this.readable.on("end",(()=>{this.isStreamEnd=true;this.emitter.emit("checkEnd")}));this.emitter.on("error",(e=>{this.isError=true;this.readable.pause();t(e)}));this.emitter.on("checkEnd",(()=>{if(this.outgoing.length>0){this.triggerOutgoingHandlers();return}if(this.isStreamEnd&&this.executingOutgoingHandlers===0){if(this.unresolvedLength>0&&this.unresolvedLengtha.getReadableStream()),a.size,this.offset).then(e).catch(t)}else if(this.unresolvedLength>=this.bufferSize){return}else{e()}}}))}))}appendUnresolvedData(e){this.unresolvedDataArray.push(e);this.unresolvedLength+=e.length}shiftBufferFromUnresolvedDataArray(e){if(!e){e=new PooledBuffer(this.bufferSize,this.unresolvedDataArray,this.unresolvedLength)}else{e.fill(this.unresolvedDataArray,this.unresolvedLength)}this.unresolvedLength-=e.size;return e}resolveData(){while(this.unresolvedLength>=this.bufferSize){let e;if(this.incoming.length>0){e=this.incoming.shift();this.shiftBufferFromUnresolvedDataArray(e)}else{if(this.numBuffers=this.concurrency){return}e=this.outgoing.shift();if(e){this.triggerOutgoingHandler(e)}}while(e)}async triggerOutgoingHandler(e){const t=e.size;this.executingOutgoingHandlers++;this.offset+=t;try{await this.outgoingHandler((()=>e.getReadableStream()),t,this.offset-t)}catch(e){this.emitter.emit("error",e);return}this.executingOutgoingHandlers--;this.reuseBuffer(e);this.emitter.emit("checkEnd")}reuseBuffer(e){this.incoming.push(e);if(!this.isError&&this.resolveData()&&!this.isStreamEnd){this.readable.resume()}}}async function streamToBuffer(e,t,a,r,i){let n=0;const s=r-a;return new Promise(((r,o)=>{const p=setTimeout((()=>o(new Error(`The operation cannot be completed in timeout.`))),io);e.on("readable",(()=>{if(n>=s){clearTimeout(p);r();return}let o=e.read();if(!o){return}if(typeof o==="string"){o=Buffer.from(o,i)}const l=n+o.length>s?s-n:o.length;t.fill(o.slice(0,l),a+n,a+n+l);n+=l}));e.on("end",(()=>{clearTimeout(p);if(n{clearTimeout(p);o(e)}))}))}async function streamToBuffer2(e,t,a){let r=0;const i=t.length;return new Promise(((n,s)=>{e.on("readable",(()=>{let n=e.read();if(!n){return}if(typeof n==="string"){n=Buffer.from(n,a)}if(r+n.length>i){s(new Error(`Stream exceeds buffer size. Buffer size: ${i}`));return}t.fill(n,r,r+n.length);r+=n.length}));e.on("end",(()=>{n(r)}));e.on("error",s)}))}async function readStreamToLocalFile(e,t){return new Promise(((a,r)=>{const i=v.createWriteStream(t);e.on("error",(e=>{r(e)}));i.on("error",(e=>{r(e)}));i.on("close",a);e.pipe(i)}))}const Vo=b.promisify(v.stat);const Go=v.createReadStream;class BlobClient extends StorageClient{constructor(e,t,a,i){i=i||{};let n;let s;if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;if(a&&typeof a!=="string"){i=a}n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);({blobName:this._name,containerName:this._containerName}=this.getBlobAndContainerNamesFromUrl());this.blobContext=new Blob$1(this.storageClientContext);this._snapshot=getURLParameter(this.url,so.Parameters.SNAPSHOT);this._versionId=getURLParameter(this.url,so.Parameters.VERSIONID)}get name(){return this._name}get containerName(){return this._containerName}withSnapshot(e){return new BlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}withVersion(e){return new BlobClient(setURLParameter(this.url,so.Parameters.VERSIONID,e.length===0?undefined:e),this.pipeline)}getAppendBlobClient(){return new AppendBlobClient(this.url,this.pipeline)}getBlockBlobClient(){return new BlockBlobClient(this.url,this.pipeline)}getPageBlobClient(){return new PageBlobClient(this.url,this.pipeline)}async download(e=0,t,a={}){var i;a.conditions=a.conditions||{};a.conditions=a.conditions||{};ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);const{span:s,updatedOptions:o}=Do("BlobClient-download",a);try{const n=await this.blobContext.download(Object.assign({abortSignal:a.abortSignal,leaseAccessConditions:a.conditions,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(i=a.conditions)===null||i===void 0?void 0:i.tagConditions}),requestOptions:{onDownloadProgress:r.isNode?undefined:a.onProgress},range:e===0&&!t?undefined:rangeToString({offset:e,count:t}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey},convertTracingToRequestOptionsBase(o)));const p=Object.assign(Object.assign({},n),{_response:n._response,objectReplicationDestinationPolicyId:n.objectReplicationPolicyId,objectReplicationSourceProperties:parseObjectReplicationRecord(n.objectReplicationRules)});if(!r.isNode){return p}if(a.maxRetryRequests===undefined||a.maxRetryRequests<0){a.maxRetryRequests=ro}if(n.contentLength===undefined){throw new RangeError(`File download response doesn't contain valid content length header`)}if(!n.etag){throw new RangeError(`File download response doesn't contain valid etag header`)}return new BlobDownloadResponse(p,(async t=>{var r;const i={leaseAccessConditions:a.conditions,modifiedAccessConditions:{ifMatch:a.conditions.ifMatch||n.etag,ifModifiedSince:a.conditions.ifModifiedSince,ifNoneMatch:a.conditions.ifNoneMatch,ifUnmodifiedSince:a.conditions.ifUnmodifiedSince,ifTags:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions},range:rangeToString({count:e+n.contentLength-t,offset:t}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey};return(await this.blobContext.download(Object.assign({abortSignal:a.abortSignal},i))).readableStreamBody}),e,n.contentLength,{maxRetryRequests:a.maxRetryRequests,onProgress:a.onProgress})}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async exists(e={}){const{span:t,updatedOptions:a}=Do("BlobClient-exists",e);try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);await this.getProperties({abortSignal:e.abortSignal,customerProvidedKey:e.customerProvidedKey,conditions:e.conditions,tracingOptions:a.tracingOptions});return true}catch(e){if(e.statusCode===404){return false}else if(e.statusCode===409&&(e.details.errorCode===wo||e.details.errorCode===So)){return true}t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async getProperties(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-getProperties",e);try{e.conditions=e.conditions||{};ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);const 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},convertTracingToRequestOptionsBase(r)));return Object.assign(Object.assign({},i),{_response:i._response,objectReplicationDestinationPolicyId:i.objectReplicationPolicyId,objectReplicationSourceProperties:parseObjectReplicationRecord(i.objectReplicationRules)})}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async delete(e={}){var t;const{span:a,updatedOptions:r}=Do("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})},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async deleteIfExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("BlobClient-deleteIfExists",e);try{const e=await this.delete(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="BlobNotFound"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when deleting a blob or snapshot only if it exists."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async undelete(e={}){const{span:t,updatedOptions:a}=Do("BlobClient-undelete",e);try{return await this.blobContext.undelete(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setHTTPHeaders(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setHTTPHeaders",t);t.conditions=t.conditions||{};try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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})},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setMetadata(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setMetadata",t);t.conditions=t.conditions||{};try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setTags(e,t={}){var a;const{span:r,updatedOptions:i}=Do("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})},convertTracingToRequestOptionsBase(i)),{tags:toBlobTags(e)}))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async getTags(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-getTags",e);try{const 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})},convertTracingToRequestOptionsBase(r)));const n=Object.assign(Object.assign({},i),{_response:i._response,tags:toTags({blobTagSet:i.blobTagSet})||{}});return n}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}getBlobLeaseClient(e){return new BlobLeaseClient(this,e)}async createSnapshot(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-createSnapshot",e);e.conditions=e.conditions||{};try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);return 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},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async beginCopyFromURL(e,t={}){const a={abortCopyFromURL:(...e)=>this.abortCopyFromURL(...e),getProperties:(...e)=>this.getProperties(...e),startCopyFromURL:(...e)=>this.startCopyFromURL(...e)};const r=new BlobBeginCopyFromUrlPoller({blobClient:a,copySource:e,intervalInMs:t.intervalInMs,onProgress:t.onProgress,resumeFrom:t.resumeFrom,startCopyFromURLOptions:t});await r.poll();return r}async abortCopyFromURL(e,t={}){const{span:a,updatedOptions:r}=Do("BlobClient-abortCopyFromURL",t);try{return await this.blobContext.abortCopyFromURL(e,Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async syncCopyFromURL(e,t={}){var a,r,i;const{span:s,updatedOptions:o}=Do("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:httpAuthorizationToString(t.sourceAuthorization),tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags),immutabilityPolicyExpiry:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,encryptionScope:t.encryptionScope,copySourceTags:t.copySourceTags},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async setAccessTier(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setAccessTier",t);try{return await this.blobContext.setTier(toAccessTier(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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async downloadToBuffer(e,t,a,r={}){let i;let s=0;let o=0;let p=r;if(e instanceof Buffer){i=e;s=t||0;o=typeof a==="number"?a:0}else{s=typeof e==="number"?e:0;o=typeof t==="number"?t:0;p=a||{}}const{span:l,updatedOptions:d}=Do("BlobClient-downloadToBuffer",p);try{if(!p.blockSize){p.blockSize=0}if(p.blockSize<0){throw new RangeError("blockSize option must be >= 0")}if(p.blockSize===0){p.blockSize=ao}if(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(!p.conditions){p.conditions={}}if(!o){const e=await this.getProperties(Object.assign(Object.assign({},p),{tracingOptions:Object.assign(Object.assign({},p.tracingOptions),convertTracingToRequestOptionsBase(d))}));o=e.contentLength-s;if(o<0){throw new RangeError(`offset ${s} shouldn't be larger than blob size ${e.contentLength}`)}}if(!i){try{i=Buffer.alloc(o)}catch(e){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".\t ${e.message}`)}}if(i.length{let t=s+o;if(a+p.blockSize{if(!(this.credential instanceof StorageSharedKeyCredential)){throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential")}const a=generateBlobSASQueryParameters(Object.assign({containerName:this._containerName,blobName:this._name,snapshotTime:this._snapshot,versionId:this._versionId},e),this.credential).toString();t(appendToURLQuery(this.url,a))}))}async deleteImmutabilityPolicy(e){const{span:t,updatedOptions:a}=Do("BlobClient-deleteImmutabilityPolicy",e);try{return await this.blobContext.deleteImmutabilityPolicy(Object.assign({abortSignal:e===null||e===void 0?void 0:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setImmutabilityPolicy(e,t){const{span:a,updatedOptions:r}=Do("BlobClient-setImmutabilityPolicy",t);try{return await this.blobContext.setImmutabilityPolicy(Object.assign({abortSignal:t===null||t===void 0?void 0:t.abortSignal,immutabilityPolicyExpiry:e.expiriesOn,immutabilityPolicyMode:e.policyMode,modifiedAccessConditions:t===null||t===void 0?void 0:t.modifiedAccessCondition},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async setLegalHold(e,t){const{span:a,updatedOptions:r}=Do("BlobClient-setLegalHold",t);try{return await this.blobContext.setLegalHold(e,Object.assign({abortSignal:t===null||t===void 0?void 0:t.abortSignal},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}}class AppendBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.appendBlobContext=new AppendBlob(this.storageClientContext)}withSnapshot(e){return new AppendBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async create(e={}){var t,a,r;const{span:i,updatedOptions:s}=Do("AppendBlobClient-create",e);e.conditions=e.conditions||{};try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);return 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:(r=e.immutabilityPolicy)===null||r===void 0?void 0:r.policyMode,legalHold:e.legalHold,blobTagsString:toBlobTagsString(e.tags)},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async createIfNotExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("AppendBlobClient-createIfNotExists",e);const s={ifNoneMatch:co};try{const e=await this.create(Object.assign(Object.assign({},i),{conditions:s}));return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="BlobAlreadyExists"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a blob only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async seal(e={}){var t;const{span:a,updatedOptions:r}=Do("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})},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async appendBlock(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("AppendBlobClient-appendBlock",a);a.conditions=a.conditions||{};try{ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);return 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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),requestOptions:{onUploadProgress:a.onProgress},transactionalContentMD5:a.transactionalContentMD5,transactionalContentCrc64:a.transactionalContentCrc64,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async appendBlockFromURL(e,t,a,r={}){var i;const{span:s,updatedOptions:o}=Do("AppendBlobClient-appendBlockFromURL",r);r.conditions=r.conditions||{};r.sourceConditions=r.sourceConditions||{};try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.appendBlobContext.appendBlockFromUrl(e,0,Object.assign({abortSignal:r.abortSignal,sourceRange:rangeToString({offset:t,count:a}),sourceContentMD5:r.sourceContentMD5,sourceContentCrc64:r.sourceContentCrc64,leaseAccessConditions:r.conditions,appendPositionAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:r.sourceConditions.ifMatch,sourceIfModifiedSince:r.sourceConditions.ifModifiedSince,sourceIfNoneMatch:r.sourceConditions.ifNoneMatch,sourceIfUnmodifiedSince:r.sourceConditions.ifUnmodifiedSince},copySourceAuthorization:httpAuthorizationToString(r.sourceAuthorization),cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}}class BlockBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;if(a&&typeof a!=="string"){i=a}n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.blockBlobContext=new BlockBlob(this.storageClientContext);this._blobContext=new Blob$1(this.storageClientContext)}withSnapshot(e){return new BlockBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async query(e,t={}){var a;ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);const{span:i,updatedOptions:s}=Do("BlockBlobClient-query",t);try{if(!r.isNode){throw new Error("This operation currently is only supported in Node.js.")}ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);const n=await this._blobContext.query(Object.assign({abortSignal:t.abortSignal,queryRequest:{queryType:"SQL",expression:e,inputSerialization:toQuerySerialization(t.inputTextConfiguration),outputSerialization:toQuerySerialization(t.outputTextConfiguration)},leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),cpkInfo:t.customerProvidedKey},convertTracingToRequestOptionsBase(s)));return new BlobQueryResponse(n,{abortSignal:t.abortSignal,onProgress:t.onProgress,onError:t.onError})}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async upload(e,t,a={}){var r,i,s;a.conditions=a.conditions||{};const{span:o,updatedOptions:p}=Do("BlockBlobClient-upload",a);try{ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);return 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:(r=a.conditions)===null||r===void 0?void 0:r.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:toAccessTier(a.tier),blobTagsString:toBlobTagsString(a.tags)},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async syncUploadFromURL(e,t={}){var a,r,i,s,o;t.conditions=t.conditions||{};const{span:p,updatedOptions:l}=Do("BlockBlobClient-syncUploadFromURL",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.sourceConditions)===null||r===void 0?void 0:r.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:httpAuthorizationToString(t.sourceAuthorization),tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags),copySourceTags:t.copySourceTags}),convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async stageBlock(e,t,a,r={}){const{span:i,updatedOptions:s}=Do("BlockBlobClient-stageBlock",r);try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.blockBlobContext.stageBlock(e,a,t,Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,requestOptions:{onUploadProgress:r.onProgress},transactionalContentMD5:r.transactionalContentMD5,transactionalContentCrc64:r.transactionalContentCrc64,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async stageBlockFromURL(e,t,a=0,r,i={}){const{span:s,updatedOptions:o}=Do("BlockBlobClient-stageBlockFromURL",i);try{ensureCpkIfSpecified(i.customerProvidedKey,this.isHttps);return await this.blockBlobContext.stageBlockFromURL(e,0,t,Object.assign({abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,sourceContentMD5:i.sourceContentMD5,sourceContentCrc64:i.sourceContentCrc64,sourceRange:a===0&&!r?undefined:rangeToString({offset:a,count:r}),cpkInfo:i.customerProvidedKey,encryptionScope:i.encryptionScope,copySourceAuthorization:httpAuthorizationToString(i.sourceAuthorization)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async commitBlockList(e,t={}){var a,r,i;t.conditions=t.conditions||{};const{span:s,updatedOptions:o}=Do("BlockBlobClient-commitBlockList",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async getBlockList(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlockBlobClient-getBlockList",t);try{const n=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})},convertTracingToRequestOptionsBase(i)));if(!n.committedBlocks){n.committedBlocks=[]}if(!n.uncommittedBlocks){n.uncommittedBlocks=[]}return n}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async uploadData(e,t={}){const{span:a,updatedOptions:i}=Do("BlockBlobClient-uploadData",t);try{if(r.isNode){let t;if(e instanceof Buffer){t=e}else if(e instanceof ArrayBuffer){t=Buffer.from(e)}else{e=e;t=Buffer.from(e.buffer,e.byteOffset,e.byteLength)}return this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.byteLength,i)}else{const t=new Blob([e]);return this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.size,i)}}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadBrowserData(e,t={}){const{span:a,updatedOptions:r}=Do("BlockBlobClient-uploadBrowserData",t);try{const t=new Blob([e]);return await this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.size,r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadSeekableInternal(e,t,a={}){if(!a.blockSize){a.blockSize=0}if(a.blockSize<0||a.blockSize>Zs){throw new RangeError(`blockSize option must be >= 0 and <= ${Zs}`)}if(a.maxSingleShotSize!==0&&!a.maxSingleShotSize){a.maxSingleShotSize=Js}if(a.maxSingleShotSize<0||a.maxSingleShotSize>Js){throw new RangeError(`maxSingleShotSize option must be >= 0 and <= ${Js}`)}if(a.blockSize===0){if(t>Zs*eo){throw new RangeError(`${t} is too larger to upload to a block blob.`)}if(t>a.maxSingleShotSize){a.blockSize=Math.ceil(t/eo);if(a.blockSizeeo){throw new RangeError(`The buffer's size is too big or the BlockSize is too small;`+`the number of blocks must be <= ${eo}`)}const o=[];const p=r.generateUuid();let l=0;const d=new Batch(a.concurrency);for(let r=0;r{const i=generateBlockID(p,r);const d=a.blockSize*r;const c=r===n-1?t:d+a.blockSize;const m=c-d;o.push(i);await this.stageBlock(i,e(d,m),m,{abortSignal:a.abortSignal,conditions:a.conditions,encryptionScope:a.encryptionScope,tracingOptions:s.tracingOptions});l+=m;if(a.onProgress){a.onProgress({loadedBytes:l})}}))}await d.do();return this.commitBlockList(o,s)}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async uploadFile(e,t={}){const{span:a,updatedOptions:r}=Do("BlockBlobClient-uploadFile",t);try{const i=(await Vo(e)).size;return await this.uploadSeekableInternal(((t,a)=>()=>Go(e,{autoClose:true,end:a?t+a-1:Infinity,start:t})),i,Object.assign(Object.assign({},t),{tracingOptions:Object.assign(Object.assign({},t.tracingOptions),convertTracingToRequestOptionsBase(r))}))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadStream(e,t=to,a=5,i={}){if(!i.blobHTTPHeaders){i.blobHTTPHeaders={}}if(!i.conditions){i.conditions={}}const{span:s,updatedOptions:o}=Do("BlockBlobClient-uploadStream",i);try{let n=0;const p=r.generateUuid();let l=0;const d=[];const c=new BufferScheduler(e,t,a,(async(e,t)=>{const a=generateBlockID(p,n);d.push(a);n++;await this.stageBlock(a,e,t,{conditions:i.conditions,encryptionScope:i.encryptionScope,tracingOptions:o.tracingOptions});l+=t;if(i.onProgress){i.onProgress({loadedBytes:l})}}),Math.ceil(a/4*3));await c.do();return await this.commitBlockList(d,Object.assign(Object.assign({},i),{tracingOptions:Object.assign(Object.assign({},i.tracingOptions),convertTracingToRequestOptionsBase(o))}))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}}class PageBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.pageBlobContext=new PageBlob(this.storageClientContext)}withSnapshot(e){return new PageBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async create(e,t={}){var a,r,i;t.conditions=t.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-create",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async createIfNotExists(e,t={}){var a,r;const{span:i,updatedOptions:s}=Do("PageBlobClient-createIfNotExists",t);try{const a={ifNoneMatch:co};const r=await this.create(e,Object.assign(Object.assign({},t),{conditions:a,tracingOptions:s.tracingOptions}));return Object.assign(Object.assign({succeeded:true},r),{_response:r._response})}catch(e){if(((a=e.details)===null||a===void 0?void 0:a.errorCode)==="BlobAlreadyExists"){i.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a blob only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(r=e.response)===null||r===void 0?void 0:r.parsedHeaders),{_response:e.response})}i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async uploadPages(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-uploadPages",r);try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.pageBlobContext.uploadPages(a,e,Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),requestOptions:{onUploadProgress:r.onProgress},range:rangeToString({offset:t,count:a}),sequenceNumberAccessConditions:r.conditions,transactionalContentMD5:r.transactionalContentMD5,transactionalContentCrc64:r.transactionalContentCrc64,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async uploadPagesFromURL(e,t,a,r,i={}){var s;i.conditions=i.conditions||{};i.sourceConditions=i.sourceConditions||{};const{span:o,updatedOptions:p}=Do("PageBlobClient-uploadPagesFromURL",i);try{ensureCpkIfSpecified(i.customerProvidedKey,this.isHttps);return await this.pageBlobContext.uploadPagesFromURL(e,rangeToString({offset:t,count:r}),0,rangeToString({offset:a,count:r}),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:httpAuthorizationToString(i.sourceAuthorization)},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async clearPages(e=0,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),range:rangeToString({offset:e,count:t}),sequenceNumberAccessConditions:a.conditions,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async getPageRanges(e=0,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(s))).then(rangeResponseFromModel)}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async listPageRangesSegment(e=0,t,a,r={}){var i;const{span:s,updatedOptions:o}=Do("PageBlobClient-getPageRangesSegment",r);try{return await this.pageBlobContext.getPageRanges(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),range:rangeToString({offset:e,count:t}),marker:a,maxPageSize:r.maxPageSize},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}listPageRangeItemSegments(e=0,t,a,r={}){return i.__asyncGenerator(this,arguments,(function*listPageRangeItemSegments_1(){let n;if(!!a||a===undefined){do{n=yield i.__await(this.listPageRangesSegment(e,t,a,r));a=n.continuationToken;yield yield i.__await(yield i.__await(n))}while(a)}}))}listPageRangeItems(e=0,t,a={}){return i.__asyncGenerator(this,arguments,(function*listPageRangeItems_1(){var r,n;let s;try{for(var o=i.__asyncValues(this.listPageRangeItemSegments(e,t,s,a)),p;p=yield i.__await(o.next()),!p.done;){const e=p.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(ExtractPageRangeInfoItems(e))))}}catch(e){r={error:e}}finally{try{if(p&&!p.done&&(n=o.return))yield i.__await(n.call(o))}finally{if(r)throw r.error}}}))}listPageRanges(e=0,t,a={}){a.conditions=a.conditions||{};const r=this.listPageRangeItems(e,t,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(r={})=>this.listPageRangeItemSegments(e,t,r.continuationToken,Object.assign({maxPageSize:r.maxPageSize},a))}}async getPageRangesDiff(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-getPageRangesDiff",r);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),prevsnapshot:a,range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(o))).then(rangeResponseFromModel)}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async listPageRangesDiffSegment(e,t,a,r,i){var s;const{span:o,updatedOptions:p}=Do("PageBlobClient-getPageRangesDiffSegment",i);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:i===null||i===void 0?void 0:i.abortSignal,leaseAccessConditions:i===null||i===void 0?void 0:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i===null||i===void 0?void 0:i.conditions),{ifTags:(s=i===null||i===void 0?void 0:i.conditions)===null||s===void 0?void 0:s.tagConditions}),prevsnapshot:a,range:rangeToString({offset:e,count:t}),marker:r,maxPageSize:i===null||i===void 0?void 0:i.maxPageSize},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}listPageRangeDiffItemSegments(e,t,a,r,n){return i.__asyncGenerator(this,arguments,(function*listPageRangeDiffItemSegments_1(){let s;if(!!r||r===undefined){do{s=yield i.__await(this.listPageRangesDiffSegment(e,t,a,r,n));r=s.continuationToken;yield yield i.__await(yield i.__await(s))}while(r)}}))}listPageRangeDiffItems(e,t,a,r){return i.__asyncGenerator(this,arguments,(function*listPageRangeDiffItems_1(){var n,s;let o;try{for(var p=i.__asyncValues(this.listPageRangeDiffItemSegments(e,t,a,o,r)),l;l=yield i.__await(p.next()),!l.done;){const e=l.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(ExtractPageRangeInfoItems(e))))}}catch(e){n={error:e}}finally{try{if(l&&!l.done&&(s=p.return))yield i.__await(s.call(p))}finally{if(n)throw n.error}}}))}listPageRangesDiff(e,t,a,r={}){r.conditions=r.conditions||{};const i=this.listPageRangeDiffItems(e,t,a,Object.assign({},r));return{next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(i={})=>this.listPageRangeDiffItemSegments(e,t,a,i.continuationToken,Object.assign({maxPageSize:i.maxPageSize},r))}}async getPageRangesDiffForManagedDisks(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-GetPageRangesDiffForManagedDisks",r);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),prevSnapshotUrl:a,range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(o))).then(rangeResponseFromModel)}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async resize(e,t={}){var a;t.conditions=t.conditions||{};const{span:r,updatedOptions:i}=Do("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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async updateSequenceNumber(e,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions})},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async startCopyIncremental(e,t={}){var a;const{span:r,updatedOptions:i}=Do("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})},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}}async function getBodyAsText(e){let t=Buffer.alloc(fo);const a=await streamToBuffer2(e.readableStreamBody,t);t=t.slice(0,a);return t.toString()}function utf8ByteLength(e){return Buffer.byteLength(e)}const Xo=": ";const $o=" ";const Wo=-1;class BatchResponseParser{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}${ho}`;this.batchResponseEnding=`--${this.responseBatchBoundary}--`}async parseBatchResponse(){if(this.batchResponse._response.status!==oo.HTTP_ACCEPTED){throw new Error(`Invalid state: batch request failed with status: '${this.batchResponse._response.status}'.`)}const e=await getBodyAsText(this.batchResponse);const t=e.split(this.batchResponseEnding)[0].split(this.perResponsePrefix).slice(1);const 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.")}const i=new Array(a);let n=0;let s=0;for(let e=0;e=0&&m{if(this.keys[e]===undefined||this.keys[e]===Ko.UNLOCKED){this.keys[e]=Ko.LOCKED;t()}else{this.onUnlockEvent(e,(()=>{this.keys[e]=Ko.LOCKED;t()}))}}))}static async unlock(e){return new Promise((t=>{if(this.keys[e]===Ko.LOCKED){this.emitUnlockEvent(e)}delete this.keys[e];t()}))}static onUnlockEvent(e,t){if(this.listeners[e]===undefined){this.listeners[e]=[t]}else{this.listeners[e].push(t)}}static emitUnlockEvent(e){if(this.listeners[e]!==undefined&&this.listeners[e].length>0){const t=this.listeners[e].shift();setImmediate((()=>{t.call(this)}))}}}Mutex.keys={};Mutex.listeners={};class BlobBatch{constructor(){this.batch="batch";this.batchRequest=new InnerBatchRequest}getMultiPartContentType(){return this.batchRequest.getMultipartContentType()}getHttpRequestBody(){return this.batchRequest.getHttpRequestBody()}getSubRequests(){return this.batchRequest.getSubRequests()}async addSubRequestInternal(e,t){await Mutex.lock(this.batch);try{this.batchRequest.preAddSubRequest(e);await t();this.batchRequest.postAddSubRequest(e)}finally{await Mutex.unlock(this.batch)}}setBatchType(e){if(!this.batchType){this.batchType=e}if(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 i;let s;if(typeof e==="string"&&(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t))){i=e;s=t}else if(e instanceof BlobClient){i=e.url;s=e.credential;a=t}else{throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.")}if(!a){a={}}const{span:o,updatedOptions:p}=Do("BatchDeleteRequest-addSubRequest",a);try{this.setBatchType("delete");await this.addSubRequestInternal({url:i,credential:s},(async()=>{await new BlobClient(i,this.batchRequest.createPipeline(s)).delete(p)}))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async setBlobAccessTier(e,t,a,i){let s;let o;let p;if(typeof e==="string"&&(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t))){s=e;o=t;p=a}else if(e instanceof BlobClient){s=e.url;o=e.credential;p=t;i=a}else{throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.")}if(!i){i={}}const{span:l,updatedOptions:d}=Do("BatchSetTierRequest-addSubRequest",i);try{this.setBatchType("setAccessTier");await this.addSubRequestInternal({url:s,credential:o},(async()=>{await new BlobClient(s,this.batchRequest.createPipeline(o)).setAccessTier(p,d)}))}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}}class InnerBatchRequest{constructor(){this.operationCount=0;this.body="";const e=r.generateUuid();this.boundary=`batch_${e}`;this.subRequestPrefix=`--${this.boundary}${ho}${po.CONTENT_TYPE}: application/http${ho}${po.CONTENT_TRANSFER_ENCODING}: binary`;this.multipartContentType=`multipart/mixed; boundary=${this.boundary}`;this.batchRequestEnding=`--${this.boundary}--`;this.subRequests=new Map}createPipeline(e){const t=e instanceof AnonymousCredential;const a=3+(t?0:1);const i=new Array(a);i[0]=r.deserializationPolicy();i[1]=new BatchHeaderFilterPolicyFactory;if(!t){i[2]=r.isTokenCredential(e)?attachCredential(r.bearerTokenAuthenticationPolicy(e,no),e):e}i[a-1]=new BatchRequestAssemblePolicyFactory(this);return new Pipeline(i,{})}appendSubRequestToBody(e){this.body+=[this.subRequestPrefix,`${po.CONTENT_ID}: ${this.operationCount}`,"",`${e.method.toString()} ${getURLPathAndQuery(e.url)} ${go}${ho}`].join(ho);for(const t of e.headers.headersArray()){this.body+=`${t.name}: ${t.value}${ho}`}this.body+=ho}preAddSubRequest(e){if(this.operationCount>=uo){throw new RangeError(`Cannot exceed ${uo} sub requests in a single batch`)}const t=getURLPath(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}${ho}`}getMultipartContentType(){return this.multipartContentType}getSubRequests(){return this.subRequests}}class BatchRequestAssemblePolicy extends r.BaseRequestPolicy{constructor(e,t,a){super(t,a);this.dummyResponse={request:new r.WebResource,status:200,headers:new r.HttpHeaders};this.batchRequest=e}async sendRequest(e){await this.batchRequest.appendSubRequestToBody(e);return this.dummyResponse}}class BatchRequestAssemblePolicyFactory{constructor(e){this.batchRequest=e}create(e,t){return new BatchRequestAssemblePolicy(this.batchRequest,e,t)}}class BatchHeaderFilterPolicy extends r.BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){let t="";for(const a of e.headers.headersArray()){if(iEqual(a.name,po.X_MS_VERSION)){t=a.name}}if(t!==""){e.headers.remove(t)}return this._nextPolicy.sendRequest(e)}}class BatchHeaderFilterPolicyFactory{create(e,t){return new BatchHeaderFilterPolicy(e,t)}}class BlobBatchClient{constructor(e,t,a){let r;if(isPipelineLike(t)){r=t}else if(!t){r=newPipeline(new AnonymousCredential,a)}else{r=newPipeline(t,a)}const i=new StorageClientContext(e,r.toServiceClientOptions());const n=getURLPath(e);if(n&&n!=="/"){this.serviceOrContainerContext=new Container(i)}else{this.serviceOrContainerContext=new Service(i)}}createBatch(){return new BlobBatch}async deleteBlobs(e,t,a){const r=new BlobBatch;for(const i of e){if(typeof i==="string"){await r.deleteBlob(i,t,a)}else{await r.deleteBlob(i,t)}}return this.submitBatch(r)}async setBlobsAccessTier(e,t,a,r){const i=new BlobBatch;for(const n of e){if(typeof n==="string"){await i.setBlobAccessTier(n,t,a,r)}else{await i.setBlobAccessTier(n,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.")}const{span:a,updatedOptions:r}=Do("BlobBatchClient-submitBatch",t);try{const i=e.getHttpRequestBody();const n=await this.serviceOrContainerContext.submitBatch(utf8ByteLength(i),e.getMultiPartContentType(),i,Object.assign(Object.assign({},t),convertTracingToRequestOptionsBase(r)));const s=new BatchResponseParser(n,e.getSubRequests());const o=await s.parseBatchResponse();const p={_response:n._response,contentType:n.contentType,errorCode:n.errorCode,requestId:n.requestId,clientRequestId:n.clientRequestId,version:n.version,subResponses:o.subResponses,subResponsesSucceededCount:o.subResponsesSucceededCount,subResponsesFailedCount:o.subResponsesFailedCount};return p}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}}class ContainerClient extends StorageClient{constructor(e,t,a){let i;let n;a=a||{};if(isPipelineLike(t)){n=e;i=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){n=e;i=newPipeline(t,a)}else if(!t&&typeof t!=="string"){n=e;i=newPipeline(new AnonymousCredential,a)}else if(t&&typeof t==="string"){const s=t;const o=extractConnectionStringParts(e);if(o.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(o.accountName,o.accountKey);n=appendToURLPath(o.url,encodeURIComponent(s));if(!a.proxyOptions){a.proxyOptions=r.getDefaultProxySettings(o.proxyUri)}i=newPipeline(e,a)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(o.kind==="SASConnString"){n=appendToURLPath(o.url,encodeURIComponent(s))+"?"+o.accountSas;i=newPipeline(new AnonymousCredential,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(n,i);this._containerName=this.getContainerNameFromUrl();this.containerContext=new Container(this.storageClientContext)}get containerName(){return this._containerName}async create(e={}){const{span:t,updatedOptions:a}=Do("ContainerClient-create",e);try{return await this.containerContext.create(Object.assign(Object.assign({},e),convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async createIfNotExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("ContainerClient-createIfNotExists",e);try{const e=await this.create(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="ContainerAlreadyExists"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a container only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async exists(e={}){const{span:t,updatedOptions:a}=Do("ContainerClient-exists",e);try{await this.getProperties({abortSignal:e.abortSignal,tracingOptions:a.tracingOptions});return true}catch(e){if(e.statusCode===404){t.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when checking container existence"});return false}t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}getBlobClient(e){return new BlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getAppendBlobClient(e){return new AppendBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getBlockBlobClient(e){return new BlockBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getPageBlobClient(e){return new PageBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}async getProperties(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-getProperties",e);try{return await this.containerContext.getProperties(Object.assign(Object.assign({abortSignal:e.abortSignal},e.conditions),convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async delete(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-delete",e);try{return await this.containerContext.delete(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:e.conditions},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async deleteIfExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("ContainerClient-deleteIfExists",e);try{const e=await this.delete(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="ContainerNotFound"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when deleting a container only if it exists."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setMetadata(e,t={}){if(!t.conditions){t.conditions={}}if(t.conditions.ifUnmodifiedSince){throw new RangeError("the IfUnmodifiedSince must have their default values because they are ignored by the blob service")}const{span:a,updatedOptions:r}=Do("ContainerClient-setMetadata",t);try{return await this.containerContext.setMetadata(Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:e,modifiedAccessConditions:t.conditions},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async getAccessPolicy(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-getAccessPolicy",e);try{const r=await this.containerContext.getAccessPolicy(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions},convertTracingToRequestOptionsBase(a)));const i={_response:r._response,blobPublicAccess:r.blobPublicAccess,date:r.date,etag:r.etag,errorCode:r.errorCode,lastModified:r.lastModified,requestId:r.requestId,clientRequestId:r.clientRequestId,signedIdentifiers:[],version:r.version};for(const e of r){let t=undefined;if(e.accessPolicy){t={permissions:e.accessPolicy.permissions};if(e.accessPolicy.expiresOn){t.expiresOn=new Date(e.accessPolicy.expiresOn)}if(e.accessPolicy.startsOn){t.startsOn=new Date(e.accessPolicy.startsOn)}}i.signedIdentifiers.push({accessPolicy:t,id:e.id})}return i}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setAccessPolicy(e,t,a={}){a.conditions=a.conditions||{};const{span:r,updatedOptions:i}=Do("ContainerClient-setAccessPolicy",a);try{const n=[];for(const e of t||[]){n.push({accessPolicy:{expiresOn:e.accessPolicy.expiresOn?truncatedISO8061Date(e.accessPolicy.expiresOn):"",permissions:e.accessPolicy.permissions,startsOn:e.accessPolicy.startsOn?truncatedISO8061Date(e.accessPolicy.startsOn):""},id:e.id})}return await this.containerContext.setAccessPolicy(Object.assign({abortSignal:a.abortSignal,access:e,containerAcl:n,leaseAccessConditions:a.conditions,modifiedAccessConditions:a.conditions},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}getBlobLeaseClient(e){return new BlobLeaseClient(this,e)}async uploadBlockBlob(e,t,a,r={}){const{span:i,updatedOptions:s}=Do("ContainerClient-uploadBlockBlob",r);try{const r=this.getBlockBlobClient(e);const n=await r.upload(t,a,s);return{blockBlobClient:r,response:n}}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async deleteBlob(e,t={}){const{span:a,updatedOptions:r}=Do("ContainerClient-deleteBlob",t);try{let i=this.getBlobClient(e);if(t.versionId){i=i.withVersion(t.versionId)}return await i.delete(r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async listBlobFlatSegment(e,t={}){const{span:a,updatedOptions:r}=Do("ContainerClient-listBlobFlatSegment",t);try{const i=await this.containerContext.listBlobFlatSegment(Object.assign(Object.assign({marker:e},t),convertTracingToRequestOptionsBase(r)));const n=Object.assign(Object.assign({},i),{_response:Object.assign(Object.assign({},i._response),{parsedBody:ConvertInternalResponseOfListBlobFlat(i._response.parsedBody)}),segment:Object.assign(Object.assign({},i.segment),{blobItems:i.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name),tags:toTags(e.blobTags),objectReplicationSourceProperties:parseObjectReplicationRecord(e.objectReplicationMetadata)});return t}))})});return n}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async listBlobHierarchySegment(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("ContainerClient-listBlobHierarchySegment",a);try{const n=await this.containerContext.listBlobHierarchySegment(e,Object.assign(Object.assign({marker:t},a),convertTracingToRequestOptionsBase(s)));const o=Object.assign(Object.assign({},n),{_response:Object.assign(Object.assign({},n._response),{parsedBody:ConvertInternalResponseOfListBlobHierarchy(n._response.parsedBody)}),segment:Object.assign(Object.assign({},n.segment),{blobItems:n.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name),tags:toTags(e.blobTags),objectReplicationSourceProperties:parseObjectReplicationRecord(e.objectReplicationMetadata)});return t})),blobPrefixes:(r=n.segment.blobPrefixes)===null||r===void 0?void 0:r.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))})});return o}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}listSegments(e,t={}){return i.__asyncGenerator(this,arguments,(function*listSegments_1(){let a;if(!!e||e===undefined){do{a=yield i.__await(this.listBlobFlatSegment(e,t));e=a.continuationToken;yield yield i.__await(yield i.__await(a))}while(e)}}))}listItems(e={}){return i.__asyncGenerator(this,arguments,(function*listItems_1(){var t,a;let r;try{for(var n=i.__asyncValues(this.listSegments(r,e)),s;s=yield i.__await(n.next()),!s.done;){const e=s.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.segment.blobItems)))}}catch(e){t={error:e}}finally{try{if(s&&!s.done&&(a=n.return))yield i.__await(a.call(n))}finally{if(t)throw t.error}}}))}listBlobsFlat(e={}){const t=[];if(e.includeCopy){t.push("copy")}if(e.includeDeleted){t.push("deleted")}if(e.includeMetadata){t.push("metadata")}if(e.includeSnapshots){t.push("snapshots")}if(e.includeVersions){t.push("versions")}if(e.includeUncommitedBlobs){t.push("uncommittedblobs")}if(e.includeTags){t.push("tags")}if(e.includeDeletedWithVersions){t.push("deletedwithversions")}if(e.includeImmutabilityPolicy){t.push("immutabilitypolicy")}if(e.includeLegalHold){t.push("legalhold")}if(e.prefix===""){e.prefix=undefined}const a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{});const r=this.listItems(a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(e={})=>this.listSegments(e.continuationToken,Object.assign({maxPageSize:e.maxPageSize},a))}}listHierarchySegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*listHierarchySegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.listBlobHierarchySegment(e,t,a));t=r.continuationToken;yield yield i.__await(yield i.__await(r))}while(t)}}))}listItemsByHierarchy(e,t={}){return i.__asyncGenerator(this,arguments,(function*listItemsByHierarchy_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.listHierarchySegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;const t=e.segment;if(t.blobPrefixes){for(const e of t.blobPrefixes){yield yield i.__await(Object.assign({kind:"prefix"},e))}}for(const e of t.blobItems){yield yield i.__await(Object.assign({kind:"blob"},e))}}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}listBlobsByHierarchy(e,t={}){if(e===""){throw new RangeError("delimiter should contain one or more characters")}const a=[];if(t.includeCopy){a.push("copy")}if(t.includeDeleted){a.push("deleted")}if(t.includeMetadata){a.push("metadata")}if(t.includeSnapshots){a.push("snapshots")}if(t.includeVersions){a.push("versions")}if(t.includeUncommitedBlobs){a.push("uncommittedblobs")}if(t.includeTags){a.push("tags")}if(t.includeDeletedWithVersions){a.push("deletedwithversions")}if(t.includeImmutabilityPolicy){a.push("immutabilitypolicy")}if(t.includeLegalHold){a.push("legalhold")}if(t.prefix===""){t.prefix=undefined}const r=Object.assign(Object.assign({},t),a.length>0?{include:a}:{});const i=this.listItemsByHierarchy(e,r);return{async next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.listHierarchySegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},r))}}async findBlobsByTagsSegment(e,t,a={}){const{span:r,updatedOptions:i}=Do("ContainerClient-findBlobsByTagsSegment",a);try{const n=await this.containerContext.filterBlobs(Object.assign({abortSignal:a.abortSignal,where:e,marker:t,maxPageSize:a.maxPageSize},convertTracingToRequestOptionsBase(i)));const s=Object.assign(Object.assign({},n),{_response:n._response,blobs:n.blobs.map((e=>{var t;let a="";if(((t=e.tags)===null||t===void 0?void 0:t.blobTagSet.length)===1){a=e.tags.blobTagSet[0].value}return Object.assign(Object.assign({},e),{tags:toTags(e.tags),tagValue:a})}))});return s}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}findBlobsByTagsSegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsSegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.findBlobsByTagsSegment(e,t,a));r.blobs=r.blobs||[];t=r.continuationToken;yield yield i.__await(r)}while(t)}}))}findBlobsByTagsItems(e,t={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsItems_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.findBlobsByTagsSegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.blobs)))}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}findBlobsByTags(e,t={}){const a=Object.assign({},t);const r=this.findBlobsByTagsItems(e,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.findBlobsByTagsSegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},a))}}getContainerNameFromUrl(){let e;try{const t=r.URLBuilder.parse(this.url);if(t.getHost().split(".")[1]==="blob"){e=t.getPath().split("/")[1]}else if(isIpEndpointStyle(t)){e=t.getPath().split("/")[2]}else{e=t.getPath().split("/")[1]}e=decodeURIComponent(e);if(!e){throw new Error("Provided containerName is invalid.")}return e}catch(e){throw new Error("Unable to extract containerName with provided information.")}}generateSasUrl(e){return new Promise((t=>{if(!(this.credential instanceof StorageSharedKeyCredential)){throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential")}const a=generateBlobSASQueryParameters(Object.assign({containerName:this._containerName},e),this.credential).toString();t(appendToURLQuery(this.url,a))}))}getBlobBatchClient(){return new BlobBatchClient(this.url,this.pipeline)}}class AccountSASPermissions{constructor(){this.read=false;this.write=false;this.delete=false;this.deleteVersion=false;this.list=false;this.add=false;this.create=false;this.update=false;this.process=false;this.tag=false;this.filter=false;this.setImmutabilityPolicy=false;this.permanentDelete=false}static parse(e){const t=new AccountSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"x":t.deleteVersion=true;break;case"l":t.list=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"u":t.update=true;break;case"p":t.process=true;break;case"t":t.tag=true;break;case"f":t.filter=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;default:throw new RangeError(`Invalid permission character: ${a}`)}}return t}static from(e){const t=new AccountSASPermissions;if(e.read){t.read=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.deleteVersion){t.deleteVersion=true}if(e.filter){t.filter=true}if(e.tag){t.tag=true}if(e.list){t.list=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.update){t.update=true}if(e.process){t.process=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.filter){e.push("f")}if(this.tag){e.push("t")}if(this.list){e.push("l")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.update){e.push("u")}if(this.process){e.push("p")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}return e.join("")}}class AccountSASResourceTypes{constructor(){this.service=false;this.container=false;this.object=false}static parse(e){const t=new AccountSASResourceTypes;for(const a of e){switch(a){case"s":t.service=true;break;case"c":t.container=true;break;case"o":t.object=true;break;default:throw new RangeError(`Invalid resource type: ${a}`)}}return t}toString(){const e=[];if(this.service){e.push("s")}if(this.container){e.push("c")}if(this.object){e.push("o")}return e.join("")}}class AccountSASServices{constructor(){this.blob=false;this.file=false;this.queue=false;this.table=false}static parse(e){const t=new AccountSASServices;for(const a of e){switch(a){case"b":t.blob=true;break;case"f":t.file=true;break;case"q":t.queue=true;break;case"t":t.table=true;break;default:throw new RangeError(`Invalid service character: ${a}`)}}return t}toString(){const e=[];if(this.blob){e.push("b")}if(this.table){e.push("t")}if(this.queue){e.push("q")}if(this.file){e.push("f")}return e.join("")}}function generateAccountSASQueryParameters(e,t){const a=e.version?e.version:Ys;if(e.permissions&&e.permissions.setImmutabilityPolicy&&a<"2020-08-04"){throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.")}if(e.permissions&&e.permissions.deleteVersion&&a<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when provided 'x' permission.")}if(e.permissions&&e.permissions.permanentDelete&&a<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when provided 'y' permission.")}if(e.permissions&&e.permissions.tag&&a<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when provided 't' permission.")}if(e.permissions&&e.permissions.filter&&a<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when provided 'f' permission.")}if(e.encryptionScope&&a<"2020-12-06"){throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.")}const r=AccountSASPermissions.parse(e.permissions.toString());const i=AccountSASServices.parse(e.services).toString();const n=AccountSASResourceTypes.parse(e.resourceTypes).toString();let s;if(a>="2020-12-06"){s=[t.accountName,r,i,n,e.startsOn?truncatedISO8061Date(e.startsOn,false):"",truncatedISO8061Date(e.expiresOn,false),e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",a,e.encryptionScope?e.encryptionScope:"",""].join("\n")}else{s=[t.accountName,r,i,n,e.startsOn?truncatedISO8061Date(e.startsOn,false):"",truncatedISO8061Date(e.expiresOn,false),e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",a,""].join("\n")}const o=t.computeHMACSHA256(s);return new SASQueryParameters(a,o,r.toString(),i,n,e.protocol,e.startsOn,e.expiresOn,e.ipRange,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,e.encryptionScope)}class BlobServiceClient extends StorageClient{constructor(e,t,a){let i;if(isPipelineLike(t)){i=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){i=newPipeline(t,a)}else{i=newPipeline(new AnonymousCredential,a)}super(e,i);this.serviceContext=new Service(this.storageClientContext)}static fromConnectionString(e,t){t=t||{};const a=extractConnectionStringParts(e);if(a.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(a.accountName,a.accountKey);if(!t.proxyOptions){t.proxyOptions=r.getDefaultProxySettings(a.proxyUri)}const i=newPipeline(e,t);return new BlobServiceClient(a.url,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(a.kind==="SASConnString"){const e=newPipeline(new AnonymousCredential,t);return new BlobServiceClient(a.url+"?"+a.accountSas,e)}else{throw new Error("Connection string must be either an Account connection string or a SAS connection string")}}getContainerClient(e){return new ContainerClient(appendToURLPath(this.url,encodeURIComponent(e)),this.pipeline)}async createContainer(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-createContainer",t);try{const t=this.getContainerClient(e);const i=await t.create(r);return{containerClient:t,containerCreateResponse:i}}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async deleteContainer(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-deleteContainer",t);try{const t=this.getContainerClient(e);return await t.delete(r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async undeleteContainer(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-undeleteContainer",a);try{const n=this.getContainerClient(a.destinationContainerName||e);const s=new Container(n["storageClientContext"]);const o=await s.restore(Object.assign({deletedContainerName:e,deletedContainerVersion:t},i));return{containerClient:n,containerUndeleteResponse:o}}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async renameContainer(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("BlobServiceClient-renameContainer",a);try{const n=this.getContainerClient(t);const o=new Container(n["storageClientContext"]);const p=await o.rename(e,Object.assign(Object.assign({},s),{sourceLeaseId:(r=a.sourceCondition)===null||r===void 0?void 0:r.leaseId}));return{containerClient:n,containerRenameResponse:p}}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async getProperties(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getProperties",e);try{return await this.serviceContext.getProperties(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setProperties(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-setProperties",t);try{return await this.serviceContext.setProperties(e,Object.assign({abortSignal:t.abortSignal},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async getStatistics(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getStatistics",e);try{return await this.serviceContext.getStatistics(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async getAccountInfo(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getAccountInfo",e);try{return await this.serviceContext.getAccountInfo(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async listContainersSegment(e,t={}){const{span:a,updatedOptions:r}=Do("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}),convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async findBlobsByTagsSegment(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-findBlobsByTagsSegment",a);try{const n=await this.serviceContext.filterBlobs(Object.assign({abortSignal:a.abortSignal,where:e,marker:t,maxPageSize:a.maxPageSize},convertTracingToRequestOptionsBase(i)));const s=Object.assign(Object.assign({},n),{_response:n._response,blobs:n.blobs.map((e=>{var t;let a="";if(((t=e.tags)===null||t===void 0?void 0:t.blobTagSet.length)===1){a=e.tags.blobTagSet[0].value}return Object.assign(Object.assign({},e),{tags:toTags(e.tags),tagValue:a})}))});return s}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}findBlobsByTagsSegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsSegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.findBlobsByTagsSegment(e,t,a));r.blobs=r.blobs||[];t=r.continuationToken;yield yield i.__await(r)}while(t)}}))}findBlobsByTagsItems(e,t={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsItems_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.findBlobsByTagsSegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.blobs)))}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}findBlobsByTags(e,t={}){const a=Object.assign({},t);const r=this.findBlobsByTagsItems(e,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.findBlobsByTagsSegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},a))}}listSegments(e,t={}){return i.__asyncGenerator(this,arguments,(function*listSegments_1(){let a;if(!!e||e===undefined){do{a=yield i.__await(this.listContainersSegment(e,t));a.containerItems=a.containerItems||[];e=a.continuationToken;yield yield i.__await(yield i.__await(a))}while(e)}}))}listItems(e={}){return i.__asyncGenerator(this,arguments,(function*listItems_1(){var t,a;let r;try{for(var n=i.__asyncValues(this.listSegments(r,e)),s;s=yield i.__await(n.next()),!s.done;){const e=s.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.containerItems)))}}catch(e){t={error:e}}finally{try{if(s&&!s.done&&(a=n.return))yield i.__await(a.call(n))}finally{if(t)throw t.error}}}))}listContainers(e={}){if(e.prefix===""){e.prefix=undefined}const t=[];if(e.includeDeleted){t.push("deleted")}if(e.includeMetadata){t.push("metadata")}if(e.includeSystem){t.push("system")}const a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{});const r=this.listItems(a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(e={})=>this.listSegments(e.continuationToken,Object.assign({maxPageSize:e.maxPageSize},a))}}async getUserDelegationKey(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-getUserDelegationKey",a);try{const n=await this.serviceContext.getUserDelegationKey({startsOn:truncatedISO8061Date(e,false),expiresOn:truncatedISO8061Date(t,false)},Object.assign({abortSignal:a.abortSignal},convertTracingToRequestOptionsBase(i)));const s={signedObjectId:n.signedObjectId,signedTenantId:n.signedTenantId,signedStartsOn:new Date(n.signedStartsOn),signedExpiresOn:new Date(n.signedExpiresOn),signedService:n.signedService,signedVersion:n.signedVersion,value:n.value};const o=Object.assign({_response:n._response,requestId:n.requestId,clientRequestId:n.clientRequestId,version:n.version,date:n.date,errorCode:n.errorCode},s);return o}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}getBlobBatchClient(){return new BlobBatchClient(this.url,this.pipeline)}generateAccountSasUrl(e,t=AccountSASPermissions.parse("r"),a="sco",r={}){if(!(this.credential instanceof StorageSharedKeyCredential)){throw RangeError("Can only generate the account SAS when the client is initialized with a shared key credential")}if(e===undefined){const t=new Date;e=new Date(t.getTime()+3600*1e3)}const i=generateAccountSASQueryParameters(Object.assign({permissions:t,expiresOn:e,resourceTypes:a,services:AccountSASServices.parse("b").toString()},r),this.credential).toString();return appendToURLQuery(this.url,i)}}t.KnownEncryptionAlgorithmType=void 0;(function(e){e["AES256"]="AES256"})(t.KnownEncryptionAlgorithmType||(t.KnownEncryptionAlgorithmType={}));Object.defineProperty(t,"BaseRequestPolicy",{enumerable:true,get:function(){return r.BaseRequestPolicy}});Object.defineProperty(t,"HttpHeaders",{enumerable:true,get:function(){return r.HttpHeaders}});Object.defineProperty(t,"RequestPolicyOptions",{enumerable:true,get:function(){return r.RequestPolicyOptions}});Object.defineProperty(t,"RestError",{enumerable:true,get:function(){return r.RestError}});Object.defineProperty(t,"WebResource",{enumerable:true,get:function(){return r.WebResource}});Object.defineProperty(t,"deserializationPolicy",{enumerable:true,get:function(){return r.deserializationPolicy}});t.AccountSASPermissions=AccountSASPermissions;t.AccountSASResourceTypes=AccountSASResourceTypes;t.AccountSASServices=AccountSASServices;t.AnonymousCredential=AnonymousCredential;t.AnonymousCredentialPolicy=AnonymousCredentialPolicy;t.AppendBlobClient=AppendBlobClient;t.BlobBatch=BlobBatch;t.BlobBatchClient=BlobBatchClient;t.BlobClient=BlobClient;t.BlobLeaseClient=BlobLeaseClient;t.BlobSASPermissions=BlobSASPermissions;t.BlobServiceClient=BlobServiceClient;t.BlockBlobClient=BlockBlobClient;t.ContainerClient=ContainerClient;t.ContainerSASPermissions=ContainerSASPermissions;t.Credential=Credential;t.CredentialPolicy=CredentialPolicy;t.PageBlobClient=PageBlobClient;t.Pipeline=Pipeline;t.SASQueryParameters=SASQueryParameters;t.StorageBrowserPolicy=StorageBrowserPolicy;t.StorageBrowserPolicyFactory=StorageBrowserPolicyFactory;t.StorageOAuthScopes=no;t.StorageRetryPolicy=StorageRetryPolicy;t.StorageRetryPolicyFactory=StorageRetryPolicyFactory;t.StorageSharedKeyCredential=StorageSharedKeyCredential;t.StorageSharedKeyCredentialPolicy=StorageSharedKeyCredentialPolicy;t.generateAccountSASQueryParameters=generateAccountSASQueryParameters;t.generateBlobSASQueryParameters=generateBlobSASQueryParameters;t.isPipelineLike=isPipelineLike;t.logger=Ks;t.newPipeline=newPipeline},679:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var B=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);B(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var L=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new L(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},334:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a=/^v1\./;const r=/^ghs_/;const i=/^ghu_/;async function auth(e){const t=e.split(/\./).length===3;const n=a.test(e)||r.test(e);const s=i.test(e);const o=t?"app":n?"installation":s?"user-to-server":"oauth";return{type:"token",token:e,tokenType:o}}function withAuthorizationPrefix(e){if(e.split(/\./).length===3){return`bearer ${e}`}return`token ${e}`}async function hook(e,t,a,r){const i=t.endpoint.merge(a,r);i.headers.authorization=withAuthorizationPrefix(e);return t(i)}const n=function createTokenAuth(e){if(!e){throw new Error("[@octokit/auth-token] No token passed to createTokenAuth")}if(typeof e!=="string"){throw new Error("[@octokit/auth-token] Token passed to createTokenAuth is not a string")}e=e.replace(/^(token|bearer) +/i,"");return Object.assign(auth.bind(null,e),{hook:hook.bind(null,e)})};t.createTokenAuth=n},6762:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5030);var i=a(3682);var n=a(6234);var s=a(8467);var o=a(334);function _objectWithoutPropertiesLoose(e,t){if(e==null)return{};var a={};var r=Object.keys(e);var i,n;for(n=0;n=0)continue;a[i]=e[i]}return a}function _objectWithoutProperties(e,t){if(e==null)return{};var a=_objectWithoutPropertiesLoose(e,t);var r,i;if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);for(i=0;i=0)continue;if(!Object.prototype.propertyIsEnumerable.call(e,r))continue;a[r]=e[r]}}return a}const p="3.6.0";const l=["authStrategy"];class Octokit{constructor(e={}){const t=new i.Collection;const a={baseUrl:n.request.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:t.bind(null,"request")}),mediaType:{previews:[],format:""}};a.headers["user-agent"]=[e.userAgent,`octokit-core.js/${p} ${r.getUserAgent()}`].filter(Boolean).join(" ");if(e.baseUrl){a.baseUrl=e.baseUrl}if(e.previews){a.mediaType.previews=e.previews}if(e.timeZone){a.headers["time-zone"]=e.timeZone}this.request=n.request.defaults(a);this.graphql=s.withCustomRequest(this.request).defaults(a);this.log=Object.assign({debug:()=>{},info:()=>{},warn:console.warn.bind(console),error:console.error.bind(console)},e.log);this.hook=t;if(!e.authStrategy){if(!e.auth){this.auth=async()=>({type:"unauthenticated"})}else{const a=o.createTokenAuth(e.auth);t.wrap("request",a.hook);this.auth=a}}else{const{authStrategy:a}=e,r=_objectWithoutProperties(e,l);const i=a(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:r},e.auth));t.wrap("request",i.hook);this.auth=i}const d=this.constructor;d.plugins.forEach((t=>{Object.assign(this,t(this,e))}))}static defaults(e){const t=class extends(this){constructor(...t){const a=t[0]||{};if(typeof e==="function"){super(e(a));return}super(Object.assign({},e,a,a.userAgent&&e.userAgent?{userAgent:`${a.userAgent} ${e.userAgent}`}:null))}};return t}static plugin(...e){var t;const a=this.plugins;const r=(t=class extends(this){},t.plugins=a.concat(e.filter((e=>!a.includes(e)))),t);return r}}Octokit.VERSION=p;Octokit.plugins=[];t.Octokit=Octokit},9440:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(3287);var i=a(5030);function lowercaseKeys(e){if(!e){return{}}return Object.keys(e).reduce(((t,a)=>{t[a.toLowerCase()]=e[a];return t}),{})}function mergeDeep(e,t){const a=Object.assign({},e);Object.keys(t).forEach((i=>{if(r.isPlainObject(t[i])){if(!(i in e))Object.assign(a,{[i]:t[i]});else a[i]=mergeDeep(e[i],t[i])}else{Object.assign(a,{[i]:t[i]})}}));return a}function removeUndefinedProperties(e){for(const t in e){if(e[t]===undefined){delete e[t]}}return e}function merge(e,t,a){if(typeof t==="string"){let[e,r]=t.split(" ");a=Object.assign(r?{method:e,url:r}:{url:e},a)}else{a=Object.assign({},t)}a.headers=lowercaseKeys(a.headers);removeUndefinedProperties(a);removeUndefinedProperties(a.headers);const r=mergeDeep(e||{},a);if(e&&e.mediaType.previews.length){r.mediaType.previews=e.mediaType.previews.filter((e=>!r.mediaType.previews.includes(e))).concat(r.mediaType.previews)}r.mediaType.previews=r.mediaType.previews.map((e=>e.replace(/-preview/,"")));return r}function addQueryParameters(e,t){const a=/\?/.test(e)?"&":"?";const r=Object.keys(t);if(r.length===0){return e}return e+a+r.map((e=>{if(e==="q"){return"q="+t.q.split("+").map(encodeURIComponent).join("+")}return`${e}=${encodeURIComponent(t[e])}`})).join("&")}const n=/\{[^}]+\}/g;function removeNonChars(e){return e.replace(/^\W+|\W+$/g,"").split(/,/)}function extractUrlVariableNames(e){const t=e.match(n);if(!t){return[]}return t.map(removeNonChars).reduce(((e,t)=>e.concat(t)),[])}function omit(e,t){return Object.keys(e).filter((e=>!t.includes(e))).reduce(((t,a)=>{t[a]=e[a];return t}),{})}function encodeReserved(e){return e.split(/(%[0-9A-Fa-f]{2})/g).map((function(e){if(!/%[0-9A-Fa-f]/.test(e)){e=encodeURI(e).replace(/%5B/g,"[").replace(/%5D/g,"]")}return e})).join("")}function encodeUnreserved(e){return encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function encodeValue(e,t,a){t=e==="+"||e==="#"?encodeReserved(t):encodeUnreserved(t);if(a){return encodeUnreserved(a)+"="+t}else{return t}}function isDefined(e){return e!==undefined&&e!==null}function isKeyOperator(e){return e===";"||e==="&"||e==="?"}function getValues(e,t,a,r){var i=e[a],n=[];if(isDefined(i)&&i!==""){if(typeof i==="string"||typeof i==="number"||typeof i==="boolean"){i=i.toString();if(r&&r!=="*"){i=i.substring(0,parseInt(r,10))}n.push(encodeValue(t,i,isKeyOperator(t)?a:""))}else{if(r==="*"){if(Array.isArray(i)){i.filter(isDefined).forEach((function(e){n.push(encodeValue(t,e,isKeyOperator(t)?a:""))}))}else{Object.keys(i).forEach((function(e){if(isDefined(i[e])){n.push(encodeValue(t,i[e],e))}}))}}else{const e=[];if(Array.isArray(i)){i.filter(isDefined).forEach((function(a){e.push(encodeValue(t,a))}))}else{Object.keys(i).forEach((function(a){if(isDefined(i[a])){e.push(encodeUnreserved(a));e.push(encodeValue(t,i[a].toString()))}}))}if(isKeyOperator(t)){n.push(encodeUnreserved(a)+"="+e.join(","))}else if(e.length!==0){n.push(e.join(","))}}}}else{if(t===";"){if(isDefined(i)){n.push(encodeUnreserved(a))}}else if(i===""&&(t==="&"||t==="?")){n.push(encodeUnreserved(a)+"=")}else if(i===""){n.push("")}}return n}function parseUrl(e){return{expand:expand.bind(null,e)}}function expand(e,t){var a=["+","#",".","/",";","?","&"];return e.replace(/\{([^\{\}]+)\}|([^\{\}]+)/g,(function(e,r,i){if(r){let e="";const i=[];if(a.indexOf(r.charAt(0))!==-1){e=r.charAt(0);r=r.substr(1)}r.split(/,/g).forEach((function(a){var r=/([^:\*]*)(?::(\d+)|(\*))?/.exec(a);i.push(getValues(t,e,r[1],r[2]||r[3]))}));if(e&&e!=="+"){var n=",";if(e==="?"){n="&"}else if(e!=="#"){n=e}return(i.length!==0?e:"")+i.join(n)}else{return i.join(",")}}else{return encodeReserved(i)}}))}function parse(e){let t=e.method.toUpperCase();let a=(e.url||"/").replace(/:([a-z]\w+)/g,"{$1}");let r=Object.assign({},e.headers);let i;let n=omit(e,["method","baseUrl","url","headers","request","mediaType"]);const s=extractUrlVariableNames(a);a=parseUrl(a).expand(n);if(!/^http/.test(a)){a=e.baseUrl+a}const o=Object.keys(e).filter((e=>s.includes(e))).concat("baseUrl");const p=omit(n,o);const l=/application\/octet-stream/i.test(r.accept);if(!l){if(e.mediaType.format){r.accept=r.accept.split(/,/).map((t=>t.replace(/application\/vnd(\.\w+)(\.v3)?(\.\w+)?(\+json)?$/,`application/vnd$1$2.${e.mediaType.format}`))).join(",")}if(e.mediaType.previews.length){const t=r.accept.match(/[\w-]+(?=-preview)/g)||[];r.accept=t.concat(e.mediaType.previews).map((t=>{const a=e.mediaType.format?`.${e.mediaType.format}`:"+json";return`application/vnd.github.${t}-preview${a}`})).join(",")}}if(["GET","HEAD"].includes(t)){a=addQueryParameters(a,p)}else{if("data"in p){i=p.data}else{if(Object.keys(p).length){i=p}else{r["content-length"]=0}}}if(!r["content-type"]&&typeof i!=="undefined"){r["content-type"]="application/json; charset=utf-8"}if(["PATCH","PUT"].includes(t)&&typeof i==="undefined"){i=""}return Object.assign({method:t,url:a,headers:r},typeof i!=="undefined"?{body:i}:null,e.request?{request:e.request}:null)}function endpointWithDefaults(e,t,a){return parse(merge(e,t,a))}function withDefaults(e,t){const a=merge(e,t);const r=endpointWithDefaults.bind(null,a);return Object.assign(r,{DEFAULTS:a,defaults:withDefaults.bind(null,a),merge:merge.bind(null,a),parse:parse})}const s="6.0.12";const o=`octokit-endpoint.js/${s} ${i.getUserAgent()}`;const p={method:"GET",baseUrl:"https://api.github.com",headers:{accept:"application/vnd.github.v3+json","user-agent":o},mediaType:{format:"",previews:[]}};const l=withDefaults(null,p);t.endpoint=l},8467:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(6234);var i=a(5030);const n="4.8.0";function _buildMessageForResponseErrors(e){return`Request failed due to following response errors:\n`+e.errors.map((e=>` - ${e.message}`)).join("\n")}class GraphqlResponseError extends Error{constructor(e,t,a){super(_buildMessageForResponseErrors(a));this.request=e;this.headers=t;this.response=a;this.name="GraphqlResponseError";this.errors=a.errors;this.data=a.data;if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}}}const s=["method","baseUrl","url","headers","request","query","mediaType"];const o=["query","method","url"];const p=/\/api\/v3\/?$/;function graphql(e,t,a){if(a){if(typeof t==="string"&&"query"in a){return Promise.reject(new Error(`[@octokit/graphql] "query" cannot be used as variable name`))}for(const e in a){if(!o.includes(e))continue;return Promise.reject(new Error(`[@octokit/graphql] "${e}" cannot be used as variable name`))}}const r=typeof t==="string"?Object.assign({query:t},a):t;const i=Object.keys(r).reduce(((e,t)=>{if(s.includes(t)){e[t]=r[t];return e}if(!e.variables){e.variables={}}e.variables[t]=r[t];return e}),{});const n=r.baseUrl||e.endpoint.DEFAULTS.baseUrl;if(p.test(n)){i.url=n.replace(p,"/api/graphql")}return e(i).then((e=>{if(e.data.errors){const t={};for(const a of Object.keys(e.headers)){t[a]=e.headers[a]}throw new GraphqlResponseError(i,t,e.data)}return e.data.data}))}function withDefaults(e,t){const a=e.defaults(t);const newApi=(e,t)=>graphql(a,e,t);return Object.assign(newApi,{defaults:withDefaults.bind(null,a),endpoint:r.request.endpoint})}const l=withDefaults(r.request,{headers:{"user-agent":`octokit-graphql.js/${n} ${i.getUserAgent()}`},method:"POST",url:"/graphql"});function withCustomRequest(e){return withDefaults(e,{method:"POST",url:"/graphql"})}t.GraphqlResponseError=GraphqlResponseError;t.graphql=l;t.withCustomRequest=withCustomRequest},4193:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a="2.21.3";function ownKeys(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function _objectSpread2(e){for(var t=1;t({async next(){if(!o)return{done:true};try{const e=await i({method:n,url:o,headers:s});const t=normalizePaginatedListResponse(e);o=((t.headers.link||"").match(/<([^>]+)>;\s*rel="next"/)||[])[1];return{value:t}}catch(e){if(e.status!==409)throw e;o="";return{value:{status:200,headers:{},data:[]}}}}})}}function paginate(e,t,a,r){if(typeof a==="function"){r=a;a=undefined}return gather(e,[],iterator(e,t,a)[Symbol.asyncIterator](),r)}function gather(e,t,a,r){return a.next().then((i=>{if(i.done){return t}let n=false;function done(){n=true}t=t.concat(r?r(i.value,done):i.value.data);if(n){return t}return gather(e,t,a,r)}))}const r=Object.assign(paginate,{iterator:iterator});const i=["GET /app/hook/deliveries","GET /app/installations","GET /applications/grants","GET /authorizations","GET /enterprises/{enterprise}/actions/permissions/organizations","GET /enterprises/{enterprise}/actions/runner-groups","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/organizations","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/runners","GET /enterprises/{enterprise}/actions/runners","GET /enterprises/{enterprise}/audit-log","GET /enterprises/{enterprise}/secret-scanning/alerts","GET /enterprises/{enterprise}/settings/billing/advanced-security","GET /events","GET /gists","GET /gists/public","GET /gists/starred","GET /gists/{gist_id}/comments","GET /gists/{gist_id}/commits","GET /gists/{gist_id}/forks","GET /installation/repositories","GET /issues","GET /licenses","GET /marketplace_listing/plans","GET /marketplace_listing/plans/{plan_id}/accounts","GET /marketplace_listing/stubbed/plans","GET /marketplace_listing/stubbed/plans/{plan_id}/accounts","GET /networks/{owner}/{repo}/events","GET /notifications","GET /organizations","GET /orgs/{org}/actions/cache/usage-by-repository","GET /orgs/{org}/actions/permissions/repositories","GET /orgs/{org}/actions/runner-groups","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners","GET /orgs/{org}/actions/runners","GET /orgs/{org}/actions/secrets","GET /orgs/{org}/actions/secrets/{secret_name}/repositories","GET /orgs/{org}/audit-log","GET /orgs/{org}/blocks","GET /orgs/{org}/code-scanning/alerts","GET /orgs/{org}/codespaces","GET /orgs/{org}/credential-authorizations","GET /orgs/{org}/dependabot/secrets","GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories","GET /orgs/{org}/events","GET /orgs/{org}/external-groups","GET /orgs/{org}/failed_invitations","GET /orgs/{org}/hooks","GET /orgs/{org}/hooks/{hook_id}/deliveries","GET /orgs/{org}/installations","GET /orgs/{org}/invitations","GET /orgs/{org}/invitations/{invitation_id}/teams","GET /orgs/{org}/issues","GET /orgs/{org}/members","GET /orgs/{org}/migrations","GET /orgs/{org}/migrations/{migration_id}/repositories","GET /orgs/{org}/outside_collaborators","GET /orgs/{org}/packages","GET /orgs/{org}/packages/{package_type}/{package_name}/versions","GET /orgs/{org}/projects","GET /orgs/{org}/public_members","GET /orgs/{org}/repos","GET /orgs/{org}/secret-scanning/alerts","GET /orgs/{org}/settings/billing/advanced-security","GET /orgs/{org}/team-sync/groups","GET /orgs/{org}/teams","GET /orgs/{org}/teams/{team_slug}/discussions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions","GET /orgs/{org}/teams/{team_slug}/invitations","GET /orgs/{org}/teams/{team_slug}/members","GET /orgs/{org}/teams/{team_slug}/projects","GET /orgs/{org}/teams/{team_slug}/repos","GET /orgs/{org}/teams/{team_slug}/teams","GET /projects/columns/{column_id}/cards","GET /projects/{project_id}/collaborators","GET /projects/{project_id}/columns","GET /repos/{owner}/{repo}/actions/artifacts","GET /repos/{owner}/{repo}/actions/caches","GET /repos/{owner}/{repo}/actions/runners","GET /repos/{owner}/{repo}/actions/runs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts","GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs","GET /repos/{owner}/{repo}/actions/secrets","GET /repos/{owner}/{repo}/actions/workflows","GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs","GET /repos/{owner}/{repo}/assignees","GET /repos/{owner}/{repo}/branches","GET /repos/{owner}/{repo}/check-runs/{check_run_id}/annotations","GET /repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs","GET /repos/{owner}/{repo}/code-scanning/alerts","GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances","GET /repos/{owner}/{repo}/code-scanning/analyses","GET /repos/{owner}/{repo}/codespaces","GET /repos/{owner}/{repo}/codespaces/devcontainers","GET /repos/{owner}/{repo}/codespaces/secrets","GET /repos/{owner}/{repo}/collaborators","GET /repos/{owner}/{repo}/comments","GET /repos/{owner}/{repo}/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/commits","GET /repos/{owner}/{repo}/commits/{commit_sha}/comments","GET /repos/{owner}/{repo}/commits/{commit_sha}/pulls","GET /repos/{owner}/{repo}/commits/{ref}/check-runs","GET /repos/{owner}/{repo}/commits/{ref}/check-suites","GET /repos/{owner}/{repo}/commits/{ref}/status","GET /repos/{owner}/{repo}/commits/{ref}/statuses","GET /repos/{owner}/{repo}/contributors","GET /repos/{owner}/{repo}/dependabot/secrets","GET /repos/{owner}/{repo}/deployments","GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses","GET /repos/{owner}/{repo}/environments","GET /repos/{owner}/{repo}/events","GET /repos/{owner}/{repo}/forks","GET /repos/{owner}/{repo}/git/matching-refs/{ref}","GET /repos/{owner}/{repo}/hooks","GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries","GET /repos/{owner}/{repo}/invitations","GET /repos/{owner}/{repo}/issues","GET /repos/{owner}/{repo}/issues/comments","GET /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/issues/events","GET /repos/{owner}/{repo}/issues/{issue_number}/comments","GET /repos/{owner}/{repo}/issues/{issue_number}/events","GET /repos/{owner}/{repo}/issues/{issue_number}/labels","GET /repos/{owner}/{repo}/issues/{issue_number}/reactions","GET /repos/{owner}/{repo}/issues/{issue_number}/timeline","GET /repos/{owner}/{repo}/keys","GET /repos/{owner}/{repo}/labels","GET /repos/{owner}/{repo}/milestones","GET /repos/{owner}/{repo}/milestones/{milestone_number}/labels","GET /repos/{owner}/{repo}/notifications","GET /repos/{owner}/{repo}/pages/builds","GET /repos/{owner}/{repo}/projects","GET /repos/{owner}/{repo}/pulls","GET /repos/{owner}/{repo}/pulls/comments","GET /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/pulls/{pull_number}/comments","GET /repos/{owner}/{repo}/pulls/{pull_number}/commits","GET /repos/{owner}/{repo}/pulls/{pull_number}/files","GET /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments","GET /repos/{owner}/{repo}/releases","GET /repos/{owner}/{repo}/releases/{release_id}/assets","GET /repos/{owner}/{repo}/releases/{release_id}/reactions","GET /repos/{owner}/{repo}/secret-scanning/alerts","GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations","GET /repos/{owner}/{repo}/stargazers","GET /repos/{owner}/{repo}/subscribers","GET /repos/{owner}/{repo}/tags","GET /repos/{owner}/{repo}/teams","GET /repos/{owner}/{repo}/topics","GET /repositories","GET /repositories/{repository_id}/environments/{environment_name}/secrets","GET /search/code","GET /search/commits","GET /search/issues","GET /search/labels","GET /search/repositories","GET /search/topics","GET /search/users","GET /teams/{team_id}/discussions","GET /teams/{team_id}/discussions/{discussion_number}/comments","GET /teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /teams/{team_id}/discussions/{discussion_number}/reactions","GET /teams/{team_id}/invitations","GET /teams/{team_id}/members","GET /teams/{team_id}/projects","GET /teams/{team_id}/repos","GET /teams/{team_id}/teams","GET /user/blocks","GET /user/codespaces","GET /user/codespaces/secrets","GET /user/emails","GET /user/followers","GET /user/following","GET /user/gpg_keys","GET /user/installations","GET /user/installations/{installation_id}/repositories","GET /user/issues","GET /user/keys","GET /user/marketplace_purchases","GET /user/marketplace_purchases/stubbed","GET /user/memberships/orgs","GET /user/migrations","GET /user/migrations/{migration_id}/repositories","GET /user/orgs","GET /user/packages","GET /user/packages/{package_type}/{package_name}/versions","GET /user/public_emails","GET /user/repos","GET /user/repository_invitations","GET /user/starred","GET /user/subscriptions","GET /user/teams","GET /users","GET /users/{username}/events","GET /users/{username}/events/orgs/{org}","GET /users/{username}/events/public","GET /users/{username}/followers","GET /users/{username}/following","GET /users/{username}/gists","GET /users/{username}/gpg_keys","GET /users/{username}/keys","GET /users/{username}/orgs","GET /users/{username}/packages","GET /users/{username}/projects","GET /users/{username}/received_events","GET /users/{username}/received_events/public","GET /users/{username}/repos","GET /users/{username}/starred","GET /users/{username}/subscriptions"];function isPaginatingEndpoint(e){if(typeof e==="string"){return i.includes(e)}else{return false}}function paginateRest(e){return{paginate:Object.assign(paginate.bind(null,e),{iterator:iterator.bind(null,e)})}}paginateRest.VERSION=a;t.composePaginateRest=r;t.isPaginatingEndpoint=isPaginatingEndpoint;t.paginateRest=paginateRest;t.paginatingEndpoints=i},3044:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function ownKeys(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);if(t){r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))}a.push.apply(a,r)}return a}function _objectSpread2(e){for(var t=1;t{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var r=a(8932);var i=_interopDefault(a(1223));const n=i((e=>console.warn(e)));const s=i((e=>console.warn(e)));class RequestError extends Error{constructor(e,t,a){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="HttpError";this.status=t;let i;if("headers"in a&&typeof a.headers!=="undefined"){i=a.headers}if("response"in a){this.response=a.response;i=a.response.headers}const o=Object.assign({},a.request);if(a.request.headers.authorization){o.headers=Object.assign({},a.request.headers,{authorization:a.request.headers.authorization.replace(/ .*$/," [REDACTED]")})}o.url=o.url.replace(/\bclient_secret=\w+/g,"client_secret=[REDACTED]").replace(/\baccess_token=\w+/g,"access_token=[REDACTED]");this.request=o;Object.defineProperty(this,"code",{get(){n(new r.Deprecation("[@octokit/request-error] `error.code` is deprecated, use `error.status`."));return t}});Object.defineProperty(this,"headers",{get(){s(new r.Deprecation("[@octokit/request-error] `error.headers` is deprecated, use `error.response.headers`."));return i||{}}})}}t.RequestError=RequestError},6234:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var r=a(9440);var i=a(5030);var n=a(3287);var s=_interopDefault(a(467));var o=a(537);const p="5.6.3";function getBufferResponse(e){return e.arrayBuffer()}function fetchWrapper(e){const t=e.request&&e.request.log?e.request.log:console;if(n.isPlainObject(e.body)||Array.isArray(e.body)){e.body=JSON.stringify(e.body)}let a={};let r;let i;const p=e.request&&e.request.fetch||s;return p(e.url,Object.assign({method:e.method,body:e.body,headers:e.headers,redirect:e.redirect},e.request)).then((async n=>{i=n.url;r=n.status;for(const e of n.headers){a[e[0]]=e[1]}if("deprecation"in a){const r=a.link&&a.link.match(/<([^>]+)>; rel="deprecation"/);const i=r&&r.pop();t.warn(`[@octokit/request] "${e.method} ${e.url}" is deprecated. It is scheduled to be removed on ${a.sunset}${i?`. See ${i}`:""}`)}if(r===204||r===205){return}if(e.method==="HEAD"){if(r<400){return}throw new o.RequestError(n.statusText,r,{response:{url:i,status:r,headers:a,data:undefined},request:e})}if(r===304){throw new o.RequestError("Not modified",r,{response:{url:i,status:r,headers:a,data:await getResponseData(n)},request:e})}if(r>=400){const t=await getResponseData(n);const s=new o.RequestError(toErrorMessage(t),r,{response:{url:i,status:r,headers:a,data:t},request:e});throw s}return getResponseData(n)})).then((e=>({status:r,url:i,headers:a,data:e}))).catch((t=>{if(t instanceof o.RequestError)throw t;throw new o.RequestError(t.message,500,{request:e})}))}async function getResponseData(e){const t=e.headers.get("content-type");if(/application\/json/.test(t)){return e.json()}if(!t||/^text\/|charset=utf-8$/.test(t)){return e.text()}return getBufferResponse(e)}function toErrorMessage(e){if(typeof e==="string")return e;if("message"in e){if(Array.isArray(e.errors)){return`${e.message}: ${e.errors.map(JSON.stringify).join(", ")}`}return e.message}return`Unknown error: ${JSON.stringify(e)}`}function withDefaults(e,t){const a=e.defaults(t);const newApi=function(e,t){const r=a.merge(e,t);if(!r.request||!r.request.hook){return fetchWrapper(a.parse(r))}const request=(e,t)=>fetchWrapper(a.parse(a.merge(e,t)));Object.assign(request,{endpoint:a,defaults:withDefaults.bind(null,a)});return r.request.hook(request,r)};return Object.assign(newApi,{endpoint:a,defaults:withDefaults.bind(null,a)})}const l=withDefaults(r.endpoint,{headers:{"user-agent":`octokit-request.js/${p} ${i.getUserAgent()}`}});t.request=l},7171:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ContextAPI=void 0;const r=a(4118);const i=a(5135);const n=a(1877);const s="context";const o=new r.NoopContextManager;class ContextAPI{constructor(){}static getInstance(){if(!this._instance){this._instance=new ContextAPI}return this._instance}setGlobalContextManager(e){return(0,i.registerGlobal)(s,e,n.DiagAPI.instance())}active(){return this._getContextManager().active()}with(e,t,a,...r){return this._getContextManager().with(e,t,a,...r)}bind(e,t){return this._getContextManager().bind(e,t)}_getContextManager(){return(0,i.getGlobal)(s)||o}disable(){this._getContextManager().disable();(0,i.unregisterGlobal)(s,n.DiagAPI.instance())}}t.ContextAPI=ContextAPI},1877:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagAPI=void 0;const r=a(7978);const i=a(9639);const n=a(8077);const s=a(5135);const o="diag";class DiagAPI{constructor(){function _logProxy(e){return function(...t){const a=(0,s.getGlobal)("diag");if(!a)return;return a[e](...t)}}const e=this;const setLogger=(t,a={logLevel:n.DiagLogLevel.INFO})=>{var r,o,p;if(t===e){const t=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");e.error((r=t.stack)!==null&&r!==void 0?r:t.message);return false}if(typeof a==="number"){a={logLevel:a}}const l=(0,s.getGlobal)("diag");const d=(0,i.createLogLevelDiagLogger)((o=a.logLevel)!==null&&o!==void 0?o:n.DiagLogLevel.INFO,t);if(l&&!a.suppressOverrideMessage){const e=(p=(new Error).stack)!==null&&p!==void 0?p:"";l.warn(`Current logger will be overwritten from ${e}`);d.warn(`Current logger will overwrite one already registered from ${e}`)}return(0,s.registerGlobal)("diag",d,e,true)};e.setLogger=setLogger;e.disable=()=>{(0,s.unregisterGlobal)(o,e)};e.createComponentLogger=e=>new r.DiagComponentLogger(e);e.verbose=_logProxy("verbose");e.debug=_logProxy("debug");e.info=_logProxy("info");e.warn=_logProxy("warn");e.error=_logProxy("error")}static instance(){if(!this._instance){this._instance=new DiagAPI}return this._instance}}t.DiagAPI=DiagAPI},7696:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MetricsAPI=void 0;const r=a(2647);const i=a(5135);const n=a(1877);const s="metrics";class MetricsAPI{constructor(){}static getInstance(){if(!this._instance){this._instance=new MetricsAPI}return this._instance}setGlobalMeterProvider(e){return(0,i.registerGlobal)(s,e,n.DiagAPI.instance())}getMeterProvider(){return(0,i.getGlobal)(s)||r.NOOP_METER_PROVIDER}getMeter(e,t,a){return this.getMeterProvider().getMeter(e,t,a)}disable(){(0,i.unregisterGlobal)(s,n.DiagAPI.instance())}}t.MetricsAPI=MetricsAPI},9909:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.PropagationAPI=void 0;const r=a(5135);const i=a(2368);const n=a(865);const s=a(7682);const o=a(8136);const p=a(1877);const l="propagation";const d=new i.NoopTextMapPropagator;class PropagationAPI{constructor(){this.createBaggage=o.createBaggage;this.getBaggage=s.getBaggage;this.getActiveBaggage=s.getActiveBaggage;this.setBaggage=s.setBaggage;this.deleteBaggage=s.deleteBaggage}static getInstance(){if(!this._instance){this._instance=new PropagationAPI}return this._instance}setGlobalPropagator(e){return(0,r.registerGlobal)(l,e,p.DiagAPI.instance())}inject(e,t,a=n.defaultTextMapSetter){return this._getGlobalPropagator().inject(e,t,a)}extract(e,t,a=n.defaultTextMapGetter){return this._getGlobalPropagator().extract(e,t,a)}fields(){return this._getGlobalPropagator().fields()}disable(){(0,r.unregisterGlobal)(l,p.DiagAPI.instance())}_getGlobalPropagator(){return(0,r.getGlobal)(l)||d}}t.PropagationAPI=PropagationAPI},1539:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceAPI=void 0;const r=a(5135);const i=a(2285);const n=a(9745);const s=a(3326);const o=a(1877);const p="trace";class TraceAPI{constructor(){this._proxyTracerProvider=new i.ProxyTracerProvider;this.wrapSpanContext=n.wrapSpanContext;this.isSpanContextValid=n.isSpanContextValid;this.deleteSpan=s.deleteSpan;this.getSpan=s.getSpan;this.getActiveSpan=s.getActiveSpan;this.getSpanContext=s.getSpanContext;this.setSpan=s.setSpan;this.setSpanContext=s.setSpanContext}static getInstance(){if(!this._instance){this._instance=new TraceAPI}return this._instance}setGlobalTracerProvider(e){const t=(0,r.registerGlobal)(p,this._proxyTracerProvider,o.DiagAPI.instance());if(t){this._proxyTracerProvider.setDelegate(e)}return t}getTracerProvider(){return(0,r.getGlobal)(p)||this._proxyTracerProvider}getTracer(e,t){return this.getTracerProvider().getTracer(e,t)}disable(){(0,r.unregisterGlobal)(p,o.DiagAPI.instance());this._proxyTracerProvider=new i.ProxyTracerProvider}}t.TraceAPI=TraceAPI},7682:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.deleteBaggage=t.setBaggage=t.getActiveBaggage=t.getBaggage=void 0;const r=a(7171);const i=a(8242);const n=(0,i.createContextKey)("OpenTelemetry Baggage Key");function getBaggage(e){return e.getValue(n)||undefined}t.getBaggage=getBaggage;function getActiveBaggage(){return getBaggage(r.ContextAPI.getInstance().active())}t.getActiveBaggage=getActiveBaggage;function setBaggage(e,t){return e.setValue(n,t)}t.setBaggage=setBaggage;function deleteBaggage(e){return e.deleteValue(n)}t.deleteBaggage=deleteBaggage},4811:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.BaggageImpl=void 0;class BaggageImpl{constructor(e){this._entries=e?new Map(e):new Map}getEntry(e){const t=this._entries.get(e);if(!t){return undefined}return Object.assign({},t)}getAllEntries(){return Array.from(this._entries.entries()).map((([e,t])=>[e,t]))}setEntry(e,t){const a=new BaggageImpl(this._entries);a._entries.set(e,t);return a}removeEntry(e){const t=new BaggageImpl(this._entries);t._entries.delete(e);return t}removeEntries(...e){const t=new BaggageImpl(this._entries);for(const a of e){t._entries.delete(a)}return t}clear(){return new BaggageImpl}}t.BaggageImpl=BaggageImpl},3542:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.baggageEntryMetadataSymbol=void 0;t.baggageEntryMetadataSymbol=Symbol("BaggageEntryMetadata")},8136:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.baggageEntryMetadataFromString=t.createBaggage=void 0;const r=a(1877);const i=a(4811);const n=a(3542);const s=r.DiagAPI.instance();function createBaggage(e={}){return new i.BaggageImpl(new Map(Object.entries(e)))}t.createBaggage=createBaggage;function baggageEntryMetadataFromString(e){if(typeof e!=="string"){s.error(`Cannot create baggage metadata from unknown type: ${typeof e}`);e=""}return{__TYPE__:n.baggageEntryMetadataSymbol,toString(){return e}}}t.baggageEntryMetadataFromString=baggageEntryMetadataFromString},7393:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.context=void 0;const r=a(7171);t.context=r.ContextAPI.getInstance()},4118:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopContextManager=void 0;const r=a(8242);class NoopContextManager{active(){return r.ROOT_CONTEXT}with(e,t,a,...r){return t.call(a,...r)}bind(e,t){return t}enable(){return this}disable(){return this}}t.NoopContextManager=NoopContextManager},8242:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ROOT_CONTEXT=t.createContextKey=void 0;function createContextKey(e){return Symbol.for(e)}t.createContextKey=createContextKey;class BaseContext{constructor(e){const t=this;t._currentContext=e?new Map(e):new Map;t.getValue=e=>t._currentContext.get(e);t.setValue=(e,a)=>{const r=new BaseContext(t._currentContext);r._currentContext.set(e,a);return r};t.deleteValue=e=>{const a=new BaseContext(t._currentContext);a._currentContext.delete(e);return a}}}t.ROOT_CONTEXT=new BaseContext},9721:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.diag=void 0;const r=a(1877);t.diag=r.DiagAPI.instance()},7978:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagComponentLogger=void 0;const r=a(5135);class DiagComponentLogger{constructor(e){this._namespace=e.namespace||"DiagComponentLogger"}debug(...e){return logProxy("debug",this._namespace,e)}error(...e){return logProxy("error",this._namespace,e)}info(...e){return logProxy("info",this._namespace,e)}warn(...e){return logProxy("warn",this._namespace,e)}verbose(...e){return logProxy("verbose",this._namespace,e)}}t.DiagComponentLogger=DiagComponentLogger;function logProxy(e,t,a){const i=(0,r.getGlobal)("diag");if(!i){return}a.unshift(t);return i[e](...a)}},3041:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagConsoleLogger=void 0;const a=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}];class DiagConsoleLogger{constructor(){function _consoleFunc(e){return function(...t){if(console){let a=console[e];if(typeof a!=="function"){a=console.log}if(typeof a==="function"){return a.apply(console,t)}}}}for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createLogLevelDiagLogger=void 0;const r=a(8077);function createLogLevelDiagLogger(e,t){if(er.DiagLogLevel.ALL){e=r.DiagLogLevel.ALL}t=t||{};function _filterFunc(a,r){const i=t[a];if(typeof i==="function"&&e>=r){return i.bind(t)}return function(){}}return{error:_filterFunc("error",r.DiagLogLevel.ERROR),warn:_filterFunc("warn",r.DiagLogLevel.WARN),info:_filterFunc("info",r.DiagLogLevel.INFO),debug:_filterFunc("debug",r.DiagLogLevel.DEBUG),verbose:_filterFunc("verbose",r.DiagLogLevel.VERBOSE)}}t.createLogLevelDiagLogger=createLogLevelDiagLogger},8077:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagLogLevel=void 0;var a;(function(e){e[e["NONE"]=0]="NONE";e[e["ERROR"]=30]="ERROR";e[e["WARN"]=50]="WARN";e[e["INFO"]=60]="INFO";e[e["DEBUG"]=70]="DEBUG";e[e["VERBOSE"]=80]="VERBOSE";e[e["ALL"]=9999]="ALL"})(a=t.DiagLogLevel||(t.DiagLogLevel={}))},5163:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.trace=t.propagation=t.metrics=t.diag=t.context=t.INVALID_SPAN_CONTEXT=t.INVALID_TRACEID=t.INVALID_SPANID=t.isValidSpanId=t.isValidTraceId=t.isSpanContextValid=t.createTraceState=t.TraceFlags=t.SpanStatusCode=t.SpanKind=t.SamplingDecision=t.ProxyTracerProvider=t.ProxyTracer=t.defaultTextMapSetter=t.defaultTextMapGetter=t.ValueType=t.createNoopMeter=t.DiagLogLevel=t.DiagConsoleLogger=t.ROOT_CONTEXT=t.createContextKey=t.baggageEntryMetadataFromString=void 0;var r=a(8136);Object.defineProperty(t,"baggageEntryMetadataFromString",{enumerable:true,get:function(){return r.baggageEntryMetadataFromString}});var i=a(8242);Object.defineProperty(t,"createContextKey",{enumerable:true,get:function(){return i.createContextKey}});Object.defineProperty(t,"ROOT_CONTEXT",{enumerable:true,get:function(){return i.ROOT_CONTEXT}});var n=a(3041);Object.defineProperty(t,"DiagConsoleLogger",{enumerable:true,get:function(){return n.DiagConsoleLogger}});var s=a(8077);Object.defineProperty(t,"DiagLogLevel",{enumerable:true,get:function(){return s.DiagLogLevel}});var o=a(4837);Object.defineProperty(t,"createNoopMeter",{enumerable:true,get:function(){return o.createNoopMeter}});var p=a(9999);Object.defineProperty(t,"ValueType",{enumerable:true,get:function(){return p.ValueType}});var l=a(865);Object.defineProperty(t,"defaultTextMapGetter",{enumerable:true,get:function(){return l.defaultTextMapGetter}});Object.defineProperty(t,"defaultTextMapSetter",{enumerable:true,get:function(){return l.defaultTextMapSetter}});var d=a(3503);Object.defineProperty(t,"ProxyTracer",{enumerable:true,get:function(){return d.ProxyTracer}});var c=a(2285);Object.defineProperty(t,"ProxyTracerProvider",{enumerable:true,get:function(){return c.ProxyTracerProvider}});var m=a(3209);Object.defineProperty(t,"SamplingDecision",{enumerable:true,get:function(){return m.SamplingDecision}});var u=a(1424);Object.defineProperty(t,"SpanKind",{enumerable:true,get:function(){return u.SpanKind}});var h=a(8845);Object.defineProperty(t,"SpanStatusCode",{enumerable:true,get:function(){return h.SpanStatusCode}});var g=a(6905);Object.defineProperty(t,"TraceFlags",{enumerable:true,get:function(){return g.TraceFlags}});var y=a(2615);Object.defineProperty(t,"createTraceState",{enumerable:true,get:function(){return y.createTraceState}});var v=a(9745);Object.defineProperty(t,"isSpanContextValid",{enumerable:true,get:function(){return v.isSpanContextValid}});Object.defineProperty(t,"isValidTraceId",{enumerable:true,get:function(){return v.isValidTraceId}});Object.defineProperty(t,"isValidSpanId",{enumerable:true,get:function(){return v.isValidSpanId}});var b=a(1760);Object.defineProperty(t,"INVALID_SPANID",{enumerable:true,get:function(){return b.INVALID_SPANID}});Object.defineProperty(t,"INVALID_TRACEID",{enumerable:true,get:function(){return b.INVALID_TRACEID}});Object.defineProperty(t,"INVALID_SPAN_CONTEXT",{enumerable:true,get:function(){return b.INVALID_SPAN_CONTEXT}});const x=a(7393);Object.defineProperty(t,"context",{enumerable:true,get:function(){return x.context}});const w=a(9721);Object.defineProperty(t,"diag",{enumerable:true,get:function(){return w.diag}});const S=a(2601);Object.defineProperty(t,"metrics",{enumerable:true,get:function(){return S.metrics}});const N=a(7591);Object.defineProperty(t,"propagation",{enumerable:true,get:function(){return N.propagation}});const T=a(8989);Object.defineProperty(t,"trace",{enumerable:true,get:function(){return T.trace}});t["default"]={context:x.context,diag:w.diag,metrics:S.metrics,propagation:N.propagation,trace:T.trace}},5135:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.unregisterGlobal=t.getGlobal=t.registerGlobal=void 0;const r=a(9957);const i=a(8996);const n=a(1522);const s=i.VERSION.split(".")[0];const o=Symbol.for(`opentelemetry.js.api.${s}`);const p=r._globalThis;function registerGlobal(e,t,a,r=false){var n;const s=p[o]=(n=p[o])!==null&&n!==void 0?n:{version:i.VERSION};if(!r&&s[e]){const t=new Error(`@opentelemetry/api: Attempted duplicate registration of API: ${e}`);a.error(t.stack||t.message);return false}if(s.version!==i.VERSION){const t=new Error(`@opentelemetry/api: Registration of version v${s.version} for ${e} does not match previously registered API v${i.VERSION}`);a.error(t.stack||t.message);return false}s[e]=t;a.debug(`@opentelemetry/api: Registered a global for ${e} v${i.VERSION}.`);return true}t.registerGlobal=registerGlobal;function getGlobal(e){var t,a;const r=(t=p[o])===null||t===void 0?void 0:t.version;if(!r||!(0,n.isCompatible)(r)){return}return(a=p[o])===null||a===void 0?void 0:a[e]}t.getGlobal=getGlobal;function unregisterGlobal(e,t){t.debug(`@opentelemetry/api: Unregistering a global for ${e} v${i.VERSION}.`);const a=p[o];if(a){delete a[e]}}t.unregisterGlobal=unregisterGlobal},1522:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.isCompatible=t._makeCompatibilityCheck=void 0;const r=a(8996);const i=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;function _makeCompatibilityCheck(e){const t=new Set([e]);const a=new Set;const r=e.match(i);if(!r){return()=>false}const n={major:+r[1],minor:+r[2],patch:+r[3],prerelease:r[4]};if(n.prerelease!=null){return function isExactmatch(t){return t===e}}function _reject(e){a.add(e);return false}function _accept(e){t.add(e);return true}return function isCompatible(e){if(t.has(e)){return true}if(a.has(e)){return false}const r=e.match(i);if(!r){return _reject(e)}const s={major:+r[1],minor:+r[2],patch:+r[3],prerelease:r[4]};if(s.prerelease!=null){return _reject(e)}if(n.major!==s.major){return _reject(e)}if(n.major===0){if(n.minor===s.minor&&n.patch<=s.patch){return _accept(e)}return _reject(e)}if(n.minor<=s.minor){return _accept(e)}return _reject(e)}}t._makeCompatibilityCheck=_makeCompatibilityCheck;t.isCompatible=_makeCompatibilityCheck(r.VERSION)},2601:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.metrics=void 0;const r=a(7696);t.metrics=r.MetricsAPI.getInstance()},9999:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ValueType=void 0;var a;(function(e){e[e["INT"]=0]="INT";e[e["DOUBLE"]=1]="DOUBLE"})(a=t.ValueType||(t.ValueType={}))},4837:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createNoopMeter=t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC=t.NOOP_OBSERVABLE_GAUGE_METRIC=t.NOOP_OBSERVABLE_COUNTER_METRIC=t.NOOP_UP_DOWN_COUNTER_METRIC=t.NOOP_HISTOGRAM_METRIC=t.NOOP_COUNTER_METRIC=t.NOOP_METER=t.NoopObservableUpDownCounterMetric=t.NoopObservableGaugeMetric=t.NoopObservableCounterMetric=t.NoopObservableMetric=t.NoopHistogramMetric=t.NoopUpDownCounterMetric=t.NoopCounterMetric=t.NoopMetric=t.NoopMeter=void 0;class NoopMeter{constructor(){}createHistogram(e,a){return t.NOOP_HISTOGRAM_METRIC}createCounter(e,a){return t.NOOP_COUNTER_METRIC}createUpDownCounter(e,a){return t.NOOP_UP_DOWN_COUNTER_METRIC}createObservableGauge(e,a){return t.NOOP_OBSERVABLE_GAUGE_METRIC}createObservableCounter(e,a){return t.NOOP_OBSERVABLE_COUNTER_METRIC}createObservableUpDownCounter(e,a){return t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC}addBatchObservableCallback(e,t){}removeBatchObservableCallback(e){}}t.NoopMeter=NoopMeter;class NoopMetric{}t.NoopMetric=NoopMetric;class NoopCounterMetric extends NoopMetric{add(e,t){}}t.NoopCounterMetric=NoopCounterMetric;class NoopUpDownCounterMetric extends NoopMetric{add(e,t){}}t.NoopUpDownCounterMetric=NoopUpDownCounterMetric;class NoopHistogramMetric extends NoopMetric{record(e,t){}}t.NoopHistogramMetric=NoopHistogramMetric;class NoopObservableMetric{addCallback(e){}removeCallback(e){}}t.NoopObservableMetric=NoopObservableMetric;class NoopObservableCounterMetric extends NoopObservableMetric{}t.NoopObservableCounterMetric=NoopObservableCounterMetric;class NoopObservableGaugeMetric extends NoopObservableMetric{}t.NoopObservableGaugeMetric=NoopObservableGaugeMetric;class NoopObservableUpDownCounterMetric extends NoopObservableMetric{}t.NoopObservableUpDownCounterMetric=NoopObservableUpDownCounterMetric;t.NOOP_METER=new NoopMeter;t.NOOP_COUNTER_METRIC=new NoopCounterMetric;t.NOOP_HISTOGRAM_METRIC=new NoopHistogramMetric;t.NOOP_UP_DOWN_COUNTER_METRIC=new NoopUpDownCounterMetric;t.NOOP_OBSERVABLE_COUNTER_METRIC=new NoopObservableCounterMetric;t.NOOP_OBSERVABLE_GAUGE_METRIC=new NoopObservableGaugeMetric;t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC=new NoopObservableUpDownCounterMetric;function createNoopMeter(){return t.NOOP_METER}t.createNoopMeter=createNoopMeter},2647:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NOOP_METER_PROVIDER=t.NoopMeterProvider=void 0;const r=a(4837);class NoopMeterProvider{getMeter(e,t,a){return r.NOOP_METER}}t.NoopMeterProvider=NoopMeterProvider;t.NOOP_METER_PROVIDER=new NoopMeterProvider},9957:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__exportStar||function(e,t){for(var a in e)if(a!=="default"&&!Object.prototype.hasOwnProperty.call(t,a))r(t,e,a)};Object.defineProperty(t,"__esModule",{value:true});i(a(7200),t)},9406:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t._globalThis=void 0;t._globalThis=typeof globalThis==="object"?globalThis:global},7200:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__exportStar||function(e,t){for(var a in e)if(a!=="default"&&!Object.prototype.hasOwnProperty.call(t,a))r(t,e,a)};Object.defineProperty(t,"__esModule",{value:true});i(a(9406),t)},7591:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.propagation=void 0;const r=a(9909);t.propagation=r.PropagationAPI.getInstance()},2368:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTextMapPropagator=void 0;class NoopTextMapPropagator{inject(e,t){}extract(e,t){return e}fields(){return[]}}t.NoopTextMapPropagator=NoopTextMapPropagator},865:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.defaultTextMapSetter=t.defaultTextMapGetter=void 0;t.defaultTextMapGetter={get(e,t){if(e==null){return undefined}return e[t]},keys(e){if(e==null){return[]}return Object.keys(e)}};t.defaultTextMapSetter={set(e,t,a){if(e==null){return}e[t]=a}}},8989:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.trace=void 0;const r=a(1539);t.trace=r.TraceAPI.getInstance()},1462:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NonRecordingSpan=void 0;const r=a(1760);class NonRecordingSpan{constructor(e=r.INVALID_SPAN_CONTEXT){this._spanContext=e}spanContext(){return this._spanContext}setAttribute(e,t){return this}setAttributes(e){return this}addEvent(e,t){return this}setStatus(e){return this}updateName(e){return this}end(e){}isRecording(){return false}recordException(e,t,a){}}t.NonRecordingSpan=NonRecordingSpan},7606:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTracer=void 0;const r=a(7171);const i=a(3326);const n=a(1462);const s=a(9745);const o=r.ContextAPI.getInstance();class NoopTracer{startSpan(e,t,a=o.active()){const r=Boolean(t===null||t===void 0?void 0:t.root);if(r){return new n.NonRecordingSpan}const p=a&&(0,i.getSpanContext)(a);if(isSpanContext(p)&&(0,s.isSpanContextValid)(p)){return new n.NonRecordingSpan(p)}else{return new n.NonRecordingSpan}}startActiveSpan(e,t,a,r){let n;let s;let p;if(arguments.length<2){return}else if(arguments.length===2){p=t}else if(arguments.length===3){n=t;p=a}else{n=t;s=a;p=r}const l=s!==null&&s!==void 0?s:o.active();const d=this.startSpan(e,n,l);const c=(0,i.setSpan)(l,d);return o.with(c,p,undefined,d)}}t.NoopTracer=NoopTracer;function isSpanContext(e){return typeof e==="object"&&typeof e["spanId"]==="string"&&typeof e["traceId"]==="string"&&typeof e["traceFlags"]==="number"}},3259:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTracerProvider=void 0;const r=a(7606);class NoopTracerProvider{getTracer(e,t,a){return new r.NoopTracer}}t.NoopTracerProvider=NoopTracerProvider},3503:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ProxyTracer=void 0;const r=a(7606);const i=new r.NoopTracer;class ProxyTracer{constructor(e,t,a,r){this._provider=e;this.name=t;this.version=a;this.options=r}startSpan(e,t,a){return this._getTracer().startSpan(e,t,a)}startActiveSpan(e,t,a,r){const i=this._getTracer();return Reflect.apply(i.startActiveSpan,i,arguments)}_getTracer(){if(this._delegate){return this._delegate}const e=this._provider.getDelegateTracer(this.name,this.version,this.options);if(!e){return i}this._delegate=e;return this._delegate}}t.ProxyTracer=ProxyTracer},2285:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ProxyTracerProvider=void 0;const r=a(3503);const i=a(3259);const n=new i.NoopTracerProvider;class ProxyTracerProvider{getTracer(e,t,a){var i;return(i=this.getDelegateTracer(e,t,a))!==null&&i!==void 0?i:new r.ProxyTracer(this,e,t,a)}getDelegate(){var e;return(e=this._delegate)!==null&&e!==void 0?e:n}setDelegate(e){this._delegate=e}getDelegateTracer(e,t,a){var r;return(r=this._delegate)===null||r===void 0?void 0:r.getTracer(e,t,a)}}t.ProxyTracerProvider=ProxyTracerProvider},3209:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SamplingDecision=void 0;var a;(function(e){e[e["NOT_RECORD"]=0]="NOT_RECORD";e[e["RECORD"]=1]="RECORD";e[e["RECORD_AND_SAMPLED"]=2]="RECORD_AND_SAMPLED"})(a=t.SamplingDecision||(t.SamplingDecision={}))},3326:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getSpanContext=t.setSpanContext=t.deleteSpan=t.setSpan=t.getActiveSpan=t.getSpan=void 0;const r=a(8242);const i=a(1462);const n=a(7171);const s=(0,r.createContextKey)("OpenTelemetry Context Key SPAN");function getSpan(e){return e.getValue(s)||undefined}t.getSpan=getSpan;function getActiveSpan(){return getSpan(n.ContextAPI.getInstance().active())}t.getActiveSpan=getActiveSpan;function setSpan(e,t){return e.setValue(s,t)}t.setSpan=setSpan;function deleteSpan(e){return e.deleteValue(s)}t.deleteSpan=deleteSpan;function setSpanContext(e,t){return setSpan(e,new i.NonRecordingSpan(t))}t.setSpanContext=setSpanContext;function getSpanContext(e){var t;return(t=getSpan(e))===null||t===void 0?void 0:t.spanContext()}t.getSpanContext=getSpanContext},2110:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceStateImpl=void 0;const r=a(4864);const i=32;const n=512;const s=",";const o="=";class TraceStateImpl{constructor(e){this._internalState=new Map;if(e)this._parse(e)}set(e,t){const a=this._clone();if(a._internalState.has(e)){a._internalState.delete(e)}a._internalState.set(e,t);return a}unset(e){const t=this._clone();t._internalState.delete(e);return t}get(e){return this._internalState.get(e)}serialize(){return this._keys().reduce(((e,t)=>{e.push(t+o+this.get(t));return e}),[]).join(s)}_parse(e){if(e.length>n)return;this._internalState=e.split(s).reverse().reduce(((e,t)=>{const a=t.trim();const i=a.indexOf(o);if(i!==-1){const n=a.slice(0,i);const s=a.slice(i+1,t.length);if((0,r.validateKey)(n)&&(0,r.validateValue)(s)){e.set(n,s)}else{}}return e}),new Map);if(this._internalState.size>i){this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,i))}}_keys(){return Array.from(this._internalState.keys()).reverse()}_clone(){const e=new TraceStateImpl;e._internalState=new Map(this._internalState);return e}}t.TraceStateImpl=TraceStateImpl},4864:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.validateValue=t.validateKey=void 0;const a="[_0-9a-z-*/]";const r=`[a-z]${a}{0,255}`;const i=`[a-z0-9]${a}{0,240}@[a-z]${a}{0,13}`;const n=new RegExp(`^(?:${r}|${i})$`);const s=/^[ -~]{0,255}[!-~]$/;const o=/,|=/;function validateKey(e){return n.test(e)}t.validateKey=validateKey;function validateValue(e){return s.test(e)&&!o.test(e)}t.validateValue=validateValue},2615:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createTraceState=void 0;const r=a(2110);function createTraceState(e){return new r.TraceStateImpl(e)}t.createTraceState=createTraceState},1760:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.INVALID_SPAN_CONTEXT=t.INVALID_TRACEID=t.INVALID_SPANID=void 0;const r=a(6905);t.INVALID_SPANID="0000000000000000";t.INVALID_TRACEID="00000000000000000000000000000000";t.INVALID_SPAN_CONTEXT={traceId:t.INVALID_TRACEID,spanId:t.INVALID_SPANID,traceFlags:r.TraceFlags.NONE}},1424:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SpanKind=void 0;var a;(function(e){e[e["INTERNAL"]=0]="INTERNAL";e[e["SERVER"]=1]="SERVER";e[e["CLIENT"]=2]="CLIENT";e[e["PRODUCER"]=3]="PRODUCER";e[e["CONSUMER"]=4]="CONSUMER"})(a=t.SpanKind||(t.SpanKind={}))},9745:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.wrapSpanContext=t.isSpanContextValid=t.isValidSpanId=t.isValidTraceId=void 0;const r=a(1760);const i=a(1462);const n=/^([0-9a-f]{32})$/i;const s=/^[0-9a-f]{16}$/i;function isValidTraceId(e){return n.test(e)&&e!==r.INVALID_TRACEID}t.isValidTraceId=isValidTraceId;function isValidSpanId(e){return s.test(e)&&e!==r.INVALID_SPANID}t.isValidSpanId=isValidSpanId;function isSpanContextValid(e){return isValidTraceId(e.traceId)&&isValidSpanId(e.spanId)}t.isSpanContextValid=isSpanContextValid;function wrapSpanContext(e){return new i.NonRecordingSpan(e)}t.wrapSpanContext=wrapSpanContext},8845:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SpanStatusCode=void 0;var a;(function(e){e[e["UNSET"]=0]="UNSET";e[e["OK"]=1]="OK";e[e["ERROR"]=2]="ERROR"})(a=t.SpanStatusCode||(t.SpanStatusCode={}))},6905:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceFlags=void 0;var a;(function(e){e[e["NONE"]=0]="NONE";e[e["SAMPLED"]=1]="SAMPLED"})(a=t.TraceFlags||(t.TraceFlags={}))},8996:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.VERSION=void 0;t.VERSION="1.5.0"},4812:(e,t,a)=>{e.exports={parallel:a(8210),serial:a(445),serialOrdered:a(3578)}},1700:e=>{e.exports=abort;function abort(e){Object.keys(e.jobs).forEach(clean.bind(e));e.jobs={}}function clean(e){if(typeof this.jobs[e]=="function"){this.jobs[e]()}}},2794:(e,t,a)=>{var r=a(5295);e.exports=async;function async(e){var t=false;r((function(){t=true}));return function async_callback(a,i){if(t){e(a,i)}else{r((function nextTick_callback(){e(a,i)}))}}}},5295:e=>{e.exports=defer;function defer(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;if(t){t(e)}else{setTimeout(e,0)}}},9023:(e,t,a)=>{var r=a(2794),i=a(1700);e.exports=iterate;function iterate(e,t,a,r){var n=a["keyedList"]?a["keyedList"][a.index]:a.index;a.jobs[n]=runJob(t,n,e[n],(function(e,t){if(!(n in a.jobs)){return}delete a.jobs[n];if(e){i(a)}else{a.results[n]=t}r(e,a.results)}))}function runJob(e,t,a,i){var n;if(e.length==2){n=e(a,r(i))}else{n=e(a,t,r(i))}return n}},2474:e=>{e.exports=state;function state(e,t){var a=!Array.isArray(e),r={index:0,keyedList:a||t?Object.keys(e):null,jobs:{},results:a?{}:[],size:a?Object.keys(e).length:e.length};if(t){r.keyedList.sort(a?t:function(a,r){return t(e[a],e[r])})}return r}},7942:(e,t,a)=>{var r=a(1700),i=a(2794);e.exports=terminator;function terminator(e){if(!Object.keys(this.jobs).length){return}this.index=this.size;r(this);i(e)(null,this.results)}},8210:(e,t,a)=>{var r=a(9023),i=a(2474),n=a(7942);e.exports=parallel;function parallel(e,t,a){var s=i(e);while(s.index<(s["keyedList"]||e).length){r(e,t,s,(function(e,t){if(e){a(e,t);return}if(Object.keys(s.jobs).length===0){a(null,s.results);return}}));s.index++}return n.bind(s,a)}},445:(e,t,a)=>{var r=a(3578);e.exports=serial;function serial(e,t,a){return r(e,t,null,a)}},3578:(e,t,a)=>{var r=a(9023),i=a(2474),n=a(7942);e.exports=serialOrdered;e.exports.ascending=ascending;e.exports.descending=descending;function serialOrdered(e,t,a,s){var o=i(e,a);r(e,t,o,(function iteratorHandler(a,i){if(a){s(a,i);return}o.index++;if(o.index<(o["keyedList"]||e).length){r(e,t,o,iteratorHandler);return}s(null,o.results)}));return n.bind(o,s)}function ascending(e,t){return et?1:0}function descending(e,t){return-1*ascending(e,t)}},9417:e=>{"use strict";e.exports=balanced;function balanced(e,t,a){if(e instanceof RegExp)e=maybeMatch(e,a);if(t instanceof RegExp)t=maybeMatch(t,a);var r=range(e,t,a);return r&&{start:r[0],end:r[1],pre:a.slice(0,r[0]),body:a.slice(r[0]+e.length,r[1]),post:a.slice(r[1]+t.length)}}function maybeMatch(e,t){var a=t.match(e);return a?a[0]:null}balanced.range=range;function range(e,t,a){var r,i,n,s,o;var p=a.indexOf(e);var l=a.indexOf(t,p+1);var d=p;if(p>=0&&l>0){if(e===t){return[p,l]}r=[];n=a.length;while(d>=0&&!o){if(d==p){r.push(d);p=a.indexOf(e,d+1)}else if(r.length==1){o=[r.pop(),l]}else{i=r.pop();if(i=0?p:l}if(r.length){o=[n,s]}}return o}},3682:(e,t,a)=>{var r=a(4670);var i=a(5549);var n=a(6819);var s=Function.bind;var o=s.bind(s);function bindApi(e,t,a){var r=o(n,null).apply(null,a?[t,a]:[t]);e.api={remove:r};e.remove=r;["before","error","after","wrap"].forEach((function(r){var n=a?[t,r,a]:[t,r];e[r]=e.api[r]=o(i,null).apply(null,n)}))}function HookSingular(){var e="h";var t={registry:{}};var a=r.bind(null,t,e);bindApi(a,t,e);return a}function HookCollection(){var e={registry:{}};var t=r.bind(null,e);bindApi(t,e);return t}var p=false;function Hook(){if(!p){console.warn('[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4');p=true}return HookCollection()}Hook.Singular=HookSingular.bind();Hook.Collection=HookCollection.bind();e.exports=Hook;e.exports.Hook=Hook;e.exports.Singular=Hook.Singular;e.exports.Collection=Hook.Collection},5549:e=>{e.exports=addHook;function addHook(e,t,a,r){var i=r;if(!e.registry[a]){e.registry[a]=[]}if(t==="before"){r=function(e,t){return Promise.resolve().then(i.bind(null,t)).then(e.bind(null,t))}}if(t==="after"){r=function(e,t){var a;return Promise.resolve().then(e.bind(null,t)).then((function(e){a=e;return i(a,t)})).then((function(){return a}))}}if(t==="error"){r=function(e,t){return Promise.resolve().then(e.bind(null,t)).catch((function(e){return i(e,t)}))}}e.registry[a].push({hook:r,orig:i})}},4670:e=>{e.exports=register;function register(e,t,a,r){if(typeof a!=="function"){throw new Error("method for before hook must be a function")}if(!r){r={}}if(Array.isArray(t)){return t.reverse().reduce((function(t,a){return register.bind(null,e,a,t,r)}),a)()}return Promise.resolve().then((function(){if(!e.registry[t]){return a(r)}return e.registry[t].reduce((function(e,t){return t.hook.bind(null,e,r)}),a)()}))}},6819:e=>{e.exports=removeHook;function removeHook(e,t,a){if(!e.registry[t]){return}var r=e.registry[t].map((function(e){return e.orig})).indexOf(a);if(r===-1){return}e.registry[t].splice(r,1)}},3717:(e,t,a)=>{var r=a(6891);var i=a(9417);e.exports=expandTop;var n="\0SLASH"+Math.random()+"\0";var s="\0OPEN"+Math.random()+"\0";var o="\0CLOSE"+Math.random()+"\0";var p="\0COMMA"+Math.random()+"\0";var l="\0PERIOD"+Math.random()+"\0";function numeric(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function escapeBraces(e){return e.split("\\\\").join(n).split("\\{").join(s).split("\\}").join(o).split("\\,").join(p).split("\\.").join(l)}function unescapeBraces(e){return e.split(n).join("\\").split(s).join("{").split(o).join("}").split(p).join(",").split(l).join(".")}function parseCommaParts(e){if(!e)return[""];var t=[];var a=i("{","}",e);if(!a)return e.split(",");var r=a.pre;var n=a.body;var s=a.post;var o=r.split(",");o[o.length-1]+="{"+n+"}";var p=parseCommaParts(s);if(s.length){o[o.length-1]+=p.shift();o.push.apply(o,p)}t.push.apply(t,o);return t}function expandTop(e){if(!e)return[];if(e.substr(0,2)==="{}"){e="\\{\\}"+e.substr(2)}return expand(escapeBraces(e),true).map(unescapeBraces)}function identity(e){return e}function embrace(e){return"{"+e+"}"}function isPadded(e){return/^-?0\d/.test(e)}function lte(e,t){return e<=t}function gte(e,t){return e>=t}function expand(e,t){var a=[];var n=i("{","}",e);if(!n||/\$$/.test(n.pre))return[e];var s=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(n.body);var p=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(n.body);var l=s||p;var d=n.body.indexOf(",")>=0;if(!l&&!d){if(n.post.match(/,.*\}/)){e=n.pre+"{"+n.body+o+n.post;return expand(e)}return[e]}var c;if(l){c=n.body.split(/\.\./)}else{c=parseCommaParts(n.body);if(c.length===1){c=expand(c[0],false).map(embrace);if(c.length===1){var m=n.post.length?expand(n.post,false):[""];return m.map((function(e){return n.pre+c[0]+e}))}}}var u=n.pre;var m=n.post.length?expand(n.post,false):[""];var h;if(l){var g=numeric(c[0]);var y=numeric(c[1]);var v=Math.max(c[0].length,c[1].length);var b=c.length==3?Math.abs(numeric(c[2])):1;var x=lte;var w=y0){var _=new Array(E+1).join("0");if(N<0)T="-"+_+T.slice(1);else T=_+T}}}h.push(T)}}else{h=r(c,(function(e){return expand(e,false)}))}for(var P=0;P{var r=a(3837);var i=a(2781).Stream;var n=a(8611);e.exports=CombinedStream;function CombinedStream(){this.writable=false;this.readable=true;this.dataSize=0;this.maxDataSize=2*1024*1024;this.pauseStreams=true;this._released=false;this._streams=[];this._currentStream=null;this._insideLoop=false;this._pendingNext=false}r.inherits(CombinedStream,i);CombinedStream.create=function(e){var t=new this;e=e||{};for(var a in e){t[a]=e[a]}return t};CombinedStream.isStreamLike=function(e){return typeof e!=="function"&&typeof e!=="string"&&typeof e!=="boolean"&&typeof e!=="number"&&!Buffer.isBuffer(e)};CombinedStream.prototype.append=function(e){var t=CombinedStream.isStreamLike(e);if(t){if(!(e instanceof n)){var a=n.create(e,{maxDataSize:Infinity,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this));e=a}this._handleErrors(e);if(this.pauseStreams){e.pause()}}this._streams.push(e);return this};CombinedStream.prototype.pipe=function(e,t){i.prototype.pipe.call(this,e,t);this.resume();return e};CombinedStream.prototype._getNext=function(){this._currentStream=null;if(this._insideLoop){this._pendingNext=true;return}this._insideLoop=true;try{do{this._pendingNext=false;this._realGetNext()}while(this._pendingNext)}finally{this._insideLoop=false}};CombinedStream.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e=="undefined"){this.end();return}if(typeof e!=="function"){this._pipeNext(e);return}var t=e;t(function(e){var t=CombinedStream.isStreamLike(e);if(t){e.on("data",this._checkDataSize.bind(this));this._handleErrors(e)}this._pipeNext(e)}.bind(this))};CombinedStream.prototype._pipeNext=function(e){this._currentStream=e;var t=CombinedStream.isStreamLike(e);if(t){e.on("end",this._getNext.bind(this));e.pipe(this,{end:false});return}var a=e;this.write(a);this._getNext()};CombinedStream.prototype._handleErrors=function(e){var t=this;e.on("error",(function(e){t._emitError(e)}))};CombinedStream.prototype.write=function(e){this.emit("data",e)};CombinedStream.prototype.pause=function(){if(!this.pauseStreams){return}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function")this._currentStream.pause();this.emit("pause")};CombinedStream.prototype.resume=function(){if(!this._released){this._released=true;this.writable=true;this._getNext()}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function")this._currentStream.resume();this.emit("resume")};CombinedStream.prototype.end=function(){this._reset();this.emit("end")};CombinedStream.prototype.destroy=function(){this._reset();this.emit("close")};CombinedStream.prototype._reset=function(){this.writable=false;this._streams=[];this._currentStream=null};CombinedStream.prototype._checkDataSize=function(){this._updateDataSize();if(this.dataSize<=this.maxDataSize){return}var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))};CombinedStream.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach((function(t){if(!t.dataSize){return}e.dataSize+=t.dataSize}));if(this._currentStream&&this._currentStream.dataSize){this.dataSize+=this._currentStream.dataSize}};CombinedStream.prototype._emitError=function(e){this._reset();this.emit("error",e)}},6891:e=>{e.exports=function(e,a){var r=[];for(var i=0;i{var r=a(2781).Stream;var i=a(3837);e.exports=DelayedStream;function DelayedStream(){this.source=null;this.dataSize=0;this.maxDataSize=1024*1024;this.pauseStream=true;this._maxDataSizeExceeded=false;this._released=false;this._bufferedEvents=[]}i.inherits(DelayedStream,r);DelayedStream.create=function(e,t){var a=new this;t=t||{};for(var r in t){a[r]=t[r]}a.source=e;var i=e.emit;e.emit=function(){a._handleEmit(arguments);return i.apply(e,arguments)};e.on("error",(function(){}));if(a.pauseStream){e.pause()}return a};Object.defineProperty(DelayedStream.prototype,"readable",{configurable:true,enumerable:true,get:function(){return this.source.readable}});DelayedStream.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};DelayedStream.prototype.resume=function(){if(!this._released){this.release()}this.source.resume()};DelayedStream.prototype.pause=function(){this.source.pause()};DelayedStream.prototype.release=function(){this._released=true;this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this));this._bufferedEvents=[]};DelayedStream.prototype.pipe=function(){var e=r.prototype.pipe.apply(this,arguments);this.resume();return e};DelayedStream.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}if(e[0]==="data"){this.dataSize+=e[1].length;this._checkIfMaxDataSizeExceeded()}this._bufferedEvents.push(e)};DelayedStream.prototype._checkIfMaxDataSizeExceeded=function(){if(this._maxDataSizeExceeded){return}if(this.dataSize<=this.maxDataSize){return}this._maxDataSizeExceeded=true;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}},8932:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});class Deprecation extends Error{constructor(e){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="Deprecation"}}t.Deprecation=Deprecation},3287:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true}); /*! * is-plain-object * diff --git a/dist/setup/index.js b/dist/setup/index.js index f1f368b..95a2d03 100644 --- a/dist/setup/index.js +++ b/dist/setup/index.js @@ -1,4 +1,4 @@ -(()=>{var __webpack_modules__={3782:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.deduplicate=t.pleaseRestore=t.pleaseSave=void 0;const o=a(7799);const p=n(a(2186));const l=n(a(5438));const d="sccache";const pleaseSave=()=>s(void 0,void 0,void 0,(function*(){const e=process.env.SCCACHE_CACHE_DIR;console.log(e);if(!e){console.log(`no sccache dir found in SCCACHE_CACHE_DIR ${e}`);return}yield(0,o.saveCache)([e],d)}));t.pleaseSave=pleaseSave;const pleaseRestore=()=>s(void 0,void 0,void 0,(function*(){console.log("restore sccache files");const e=process.env.SCCACHE_CACHE_DIR;console.log(e);if(!e){console.log(`no sccache dir found in SCCACHE_CACHE_DIR ${e}`);return}yield(0,o.restoreCache)([e],d).then((e=>{console.log(`successfully restored cache: ${JSON.stringify(e)}`)}))}));t.pleaseRestore=pleaseRestore;const deduplicate=()=>s(void 0,void 0,void 0,(function*(){console.log("trying to deduplicate cache");const e=p.getInput("token",{required:true});const t=l.getOctokit(e);const a=yield t.rest.actions.deleteActionsCacheByKey({owner:l.context.repo.owner,repo:l.context.repo.repo,key:d}).then((()=>"successfully deleted cache")).catch((e=>{console.log(`catch: ${e}`);return"nothing to delete"}));console.log(`delete cache api response: ${a}`)}));t.deduplicate=deduplicate},7391:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});const o=n(a(2186));const p=a(7784);const l=a(5438);const d=n(a(7147));const c=n(a(6113));const m=a(3782);const u=a(1514);function setup(){return s(this,void 0,void 0,(function*(){let e=o.getInput("version");if(e.length===0){const t=o.getInput("token",{required:true});const a=(0,l.getOctokit)(t);const r=yield a.rest.repos.getLatestRelease({owner:"mozilla",repo:"sccache"});e=r.data.tag_name}o.info(`try to setup sccache version: ${e}`);const t=getFilename(e);const a=getDirname(e);const r=`https://github.com/mozilla/sccache/releases/download/${e}/${t}`;const i=`${r}.sha256`;o.info(`sccache download from url: ${r}`);const n=yield(0,p.downloadTool)(r);const s=yield(0,p.downloadTool)(i);const h=yield d.promises.readFile(n);const g=c.createHash("sha256");g.update(h);const y=g.digest("hex");const v=(yield d.promises.readFile(s)).toString().trim();if(y!==v){o.setFailed("Checksum verification failed");return}o.info(`Correct checksum: ${y}`);let b;if(getExtension()=="zip"){b=yield(0,p.extractZip)(n)}else{b=yield(0,p.extractTar)(n)}o.info(`sccache extracted to: ${b}`);const x=yield(0,p.cacheDir)(`${b}/${a}`,"sccache",e);o.info(`sccache cached to: ${x}`);o.addPath(`${x}`);o.exportVariable("SCCACHE_PATH",`${x}/sccache`);o.exportVariable("ACTIONS_CACHE_URL",process.env.ACTIONS_CACHE_URL||"");o.exportVariable("ACTIONS_RUNTIME_TOKEN",process.env.ACTIONS_RUNTIME_TOKEN||"");let w="";let S="";const N={};N.listeners={stdout:e=>{w+=e.toString()},stderr:e=>{S+=e.toString()}};yield(0,u.exec)(`${x}/sccache`,["--show-stats","--stats-format","json"],N).catch((e=>{console.log(`exec error: ${e}`);console.log(S)}));const T=JSON.parse(w);console.log(`\n${T.cache_location}`);let E=T.cache_location.split(":")[1].trim().slice(1,-1);o.exportVariable("SCCACHE_CACHE_DIR",E);yield(0,m.pleaseRestore)();o.exportVariable("RUSTC_WRAPPER",`sccache`)}))}function getFilename(e){return`sccache-${e}-${getArch()}-${getPlatform()}.${getExtension()}`}function getDirname(e){return`sccache-${e}-${getArch()}-${getPlatform()}`}function getArch(){switch(process.arch){case"x64":return"x86_64";case"arm64":return"aarch64";default:return Error('Unsupported arch "${process.arch}"')}}function getPlatform(){switch(process.platform){case"darwin":return"apple-darwin";case"win32":return"pc-windows-msvc";case"linux":return"unknown-linux-musl";default:return Error('Unsupported platform "${process.platform}"')}}function getExtension(){switch(process.platform){case"win32":return"zip";default:return"tar.gz"}}setup().catch((e=>{o.error(e);o.setFailed(e.message)}))},7799:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.saveCache=t.restoreCache=t.isFeatureAvailable=t.ReserveCacheError=t.ValidationError=void 0;const o=n(a(2186));const p=n(a(1017));const l=n(a(1518));const d=n(a(8245));const c=a(6490);class ValidationError extends Error{constructor(e){super(e);this.name="ValidationError";Object.setPrototypeOf(this,ValidationError.prototype)}}t.ValidationError=ValidationError;class ReserveCacheError extends Error{constructor(e){super(e);this.name="ReserveCacheError";Object.setPrototypeOf(this,ReserveCacheError.prototype)}}t.ReserveCacheError=ReserveCacheError;function checkPaths(e){if(!e||e.length===0){throw new ValidationError(`Path Validation Error: At least one directory or file path is required`)}}function checkKey(e){if(e.length>512){throw new ValidationError(`Key Validation Error: ${e} cannot be larger than 512 characters.`)}const t=/^[^,]*$/;if(!t.test(e)){throw new ValidationError(`Key Validation Error: ${e} cannot contain commas.`)}}function isFeatureAvailable(){return!!process.env["ACTIONS_CACHE_URL"]}t.isFeatureAvailable=isFeatureAvailable;function restoreCache(e,t,a,r,i=false){return s(this,void 0,void 0,(function*(){checkPaths(e);a=a||[];const n=[t,...a];o.debug("Resolved Keys:");o.debug(JSON.stringify(n));if(n.length>10){throw new ValidationError(`Key Validation Error: Keys are limited to a maximum of 10.`)}for(const e of n){checkKey(e)}const s=yield l.getCompressionMethod();let m="";try{const t=yield d.getCacheEntry(n,e,{compressionMethod:s,enableCrossOsArchive:i});if(!(t===null||t===void 0?void 0:t.archiveLocation)){return undefined}if(r===null||r===void 0?void 0:r.lookupOnly){o.info("Lookup only - skipping download");return t.cacheKey}m=p.join(yield l.createTempDirectory(),l.getCacheFileName(s));o.debug(`Archive Path: ${m}`);yield d.downloadCache(t.archiveLocation,m,r);if(o.isDebug()){yield(0,c.listTar)(m,s)}const a=l.getArchiveFileSizeInBytes(m);o.info(`Cache Size: ~${Math.round(a/(1024*1024))} MB (${a} B)`);yield(0,c.extractTar)(m,s);o.info("Cache restored successfully");return t.cacheKey}catch(e){const t=e;if(t.name===ValidationError.name){throw e}else{o.warning(`Failed to restore: ${e.message}`)}}finally{try{yield l.unlinkFile(m)}catch(e){o.debug(`Failed to delete archive: ${e}`)}}return undefined}))}t.restoreCache=restoreCache;function saveCache(e,t,a,r=false){var i,n,m,u,h;return s(this,void 0,void 0,(function*(){checkPaths(e);checkKey(t);const s=yield l.getCompressionMethod();let g=-1;const y=yield l.resolvePaths(e);o.debug("Cache Paths:");o.debug(`${JSON.stringify(y)}`);if(y.length===0){throw new Error(`Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved.`)}const v=yield l.createTempDirectory();const b=p.join(v,l.getCacheFileName(s));o.debug(`Archive Path: ${b}`);try{yield(0,c.createTar)(v,y,s);if(o.isDebug()){yield(0,c.listTar)(b,s)}const p=10*1024*1024*1024;const x=l.getArchiveFileSizeInBytes(b);o.debug(`File Size: ${x}`);if(x>p&&!l.isGhes()){throw new Error(`Cache size of ~${Math.round(x/(1024*1024))} MB (${x} B) is over the 10GB limit, not saving cache.`)}o.debug("Reserving Cache");const w=yield d.reserveCache(t,e,{compressionMethod:s,enableCrossOsArchive:r,cacheSize:x});if((i=w===null||w===void 0?void 0:w.result)===null||i===void 0?void 0:i.cacheId){g=(n=w===null||w===void 0?void 0:w.result)===null||n===void 0?void 0:n.cacheId}else if((w===null||w===void 0?void 0:w.statusCode)===400){throw new Error((u=(m=w===null||w===void 0?void 0:w.error)===null||m===void 0?void 0:m.message)!==null&&u!==void 0?u:`Cache size of ~${Math.round(x/(1024*1024))} MB (${x} B) is over the data cap limit, not saving cache.`)}else{throw new ReserveCacheError(`Unable to reserve cache with key ${t}, another job may be creating this cache. More details: ${(h=w===null||w===void 0?void 0:w.error)===null||h===void 0?void 0:h.message}`)}o.debug(`Saving Cache (ID: ${g})`);yield d.saveCache(g,b,a)}catch(e){const t=e;if(t.name===ValidationError.name){throw e}else if(t.name===ReserveCacheError.name){o.info(`Failed to save: ${t.message}`)}else{o.warning(`Failed to save: ${t.message}`)}}finally{try{yield l.unlinkFile(b)}catch(e){o.debug(`Failed to delete archive: ${e}`)}}return g}))}t.saveCache=saveCache},8245:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.saveCache=t.reserveCache=t.downloadCache=t.getCacheEntry=t.getCacheVersion=void 0;const o=n(a(2186));const p=a(6255);const l=a(5526);const d=n(a(6113));const c=n(a(7147));const m=a(7310);const u=n(a(1518));const h=a(5500);const g=a(6215);const y=a(3981);const v="1.0";function getCacheApiUrl(e){const t=process.env["ACTIONS_CACHE_URL"]||"";if(!t){throw new Error("Cache Service Url not found, unable to restore cache.")}const a=`${t}_apis/artifactcache/${e}`;o.debug(`Resource Url: ${a}`);return a}function createAcceptHeader(e,t){return`${e};api-version=${t}`}function getRequestOptions(){const e={headers:{Accept:createAcceptHeader("application/json","6.0-preview.1")}};return e}function createHttpClient(){const e=process.env["ACTIONS_RUNTIME_TOKEN"]||"";const t=new l.BearerCredentialHandler(e);return new p.HttpClient("actions/cache",[t],getRequestOptions())}function getCacheVersion(e,t,a=false){const r=e;if(t){r.push(t)}if(process.platform==="win32"&&!a){r.push("windows-only")}r.push(v);return d.createHash("sha256").update(r.join("|")).digest("hex")}t.getCacheVersion=getCacheVersion;function getCacheEntry(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();const i=getCacheVersion(t,a===null||a===void 0?void 0:a.compressionMethod,a===null||a===void 0?void 0:a.enableCrossOsArchive);const n=`cache?keys=${encodeURIComponent(e.join(","))}&version=${i}`;const p=yield(0,y.retryTypedResponse)("getCacheEntry",(()=>s(this,void 0,void 0,(function*(){return r.getJson(getCacheApiUrl(n))}))));if(p.statusCode===204){if(o.isDebug()){yield printCachesListForDiagnostics(e[0],r,i)}return null}if(!(0,y.isSuccessStatusCode)(p.statusCode)){throw new Error(`Cache service responded with ${p.statusCode}`)}const l=p.result;const d=l===null||l===void 0?void 0:l.archiveLocation;if(!d){throw new Error("Cache not found.")}o.setSecret(d);o.debug(`Cache Result:`);o.debug(JSON.stringify(l));return l}))}t.getCacheEntry=getCacheEntry;function printCachesListForDiagnostics(e,t,a){return s(this,void 0,void 0,(function*(){const r=`caches?key=${encodeURIComponent(e)}`;const i=yield(0,y.retryTypedResponse)("listCache",(()=>s(this,void 0,void 0,(function*(){return t.getJson(getCacheApiUrl(r))}))));if(i.statusCode===200){const t=i.result;const r=t===null||t===void 0?void 0:t.totalCount;if(r&&r>0){o.debug(`No matching cache found for cache key '${e}', version '${a} and scope ${process.env["GITHUB_REF"]}. There exist one or more cache(s) with similar key but they have different version or scope. See more info on cache matching here: https://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows#matching-a-cache-key \nOther caches with similar key:`);for(const e of(t===null||t===void 0?void 0:t.artifactCaches)||[]){o.debug(`Cache Key: ${e===null||e===void 0?void 0:e.cacheKey}, Cache Version: ${e===null||e===void 0?void 0:e.cacheVersion}, Cache Scope: ${e===null||e===void 0?void 0:e.scope}, Cache Created: ${e===null||e===void 0?void 0:e.creationTime}`)}}}}))}function downloadCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=new m.URL(e);const i=(0,g.getDownloadOptions)(a);if(r.hostname.endsWith(".blob.core.windows.net")){if(i.useAzureSdk){yield(0,h.downloadCacheStorageSDK)(e,t,i)}else if(i.concurrentBlobDownloads){yield(0,h.downloadCacheHttpClientConcurrent)(e,t,i)}else{yield(0,h.downloadCacheHttpClient)(e,t)}}else{yield(0,h.downloadCacheHttpClient)(e,t)}}))}t.downloadCache=downloadCache;function reserveCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();const i=getCacheVersion(t,a===null||a===void 0?void 0:a.compressionMethod,a===null||a===void 0?void 0:a.enableCrossOsArchive);const n={key:e,version:i,cacheSize:a===null||a===void 0?void 0:a.cacheSize};const o=yield(0,y.retryTypedResponse)("reserveCache",(()=>s(this,void 0,void 0,(function*(){return r.postJson(getCacheApiUrl("caches"),n)}))));return o}))}t.reserveCache=reserveCache;function getContentRange(e,t){return`bytes ${e}-${t}/*`}function uploadChunk(e,t,a,r,i){return s(this,void 0,void 0,(function*(){o.debug(`Uploading chunk of size ${i-r+1} bytes at offset ${r} with content range: ${getContentRange(r,i)}`);const n={"Content-Type":"application/octet-stream","Content-Range":getContentRange(r,i)};const p=yield(0,y.retryHttpClientResponse)(`uploadChunk (start: ${r}, end: ${i})`,(()=>s(this,void 0,void 0,(function*(){return e.sendStream("PATCH",t,a(),n)}))));if(!(0,y.isSuccessStatusCode)(p.message.statusCode)){throw new Error(`Cache service responded with ${p.message.statusCode} during upload chunk.`)}}))}function uploadFile(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=u.getArchiveFileSizeInBytes(a);const n=getCacheApiUrl(`caches/${t.toString()}`);const p=c.openSync(a,"r");const l=(0,g.getUploadOptions)(r);const d=u.assertDefined("uploadConcurrency",l.uploadConcurrency);const m=u.assertDefined("uploadChunkSize",l.uploadChunkSize);const h=[...new Array(d).keys()];o.debug("Awaiting all uploads");let y=0;try{yield Promise.all(h.map((()=>s(this,void 0,void 0,(function*(){while(yc.createReadStream(a,{fd:p,start:r,end:s,autoClose:false}).on("error",(e=>{throw new Error(`Cache upload failed because file read failed with ${e.message}`)}))),r,s)}})))))}finally{c.closeSync(p)}return}))}function commitCache(e,t,a){return s(this,void 0,void 0,(function*(){const r={size:a};return yield(0,y.retryTypedResponse)("commitCache",(()=>s(this,void 0,void 0,(function*(){return e.postJson(getCacheApiUrl(`caches/${t.toString()}`),r)}))))}))}function saveCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();o.debug("Upload cache");yield uploadFile(r,e,t,a);o.debug("Commiting cache");const i=u.getArchiveFileSizeInBytes(t);o.info(`Cache Size: ~${Math.round(i/(1024*1024))} MB (${i} B)`);const n=yield commitCache(r,e,i);if(!(0,y.isSuccessStatusCode)(n.statusCode)){throw new Error(`Cache service responded with ${n.statusCode} during commit cache.`)}o.info("Cache saved successfully")}))}t.saveCache=saveCache},1518:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};Object.defineProperty(t,"__esModule",{value:true});t.isGhes=t.assertDefined=t.getGnuTarPathOnWindows=t.getCacheFileName=t.getCompressionMethod=t.unlinkFile=t.resolvePaths=t.getArchiveFileSizeInBytes=t.createTempDirectory=void 0;const p=n(a(2186));const l=n(a(1514));const d=n(a(8090));const c=n(a(7436));const m=n(a(7147));const u=n(a(1017));const h=n(a(5911));const g=n(a(3837));const y=a(4138);const v=a(8840);function createTempDirectory(){return s(this,void 0,void 0,(function*(){const e=process.platform==="win32";let t=process.env["RUNNER_TEMP"]||"";if(!t){let a;if(e){a=process.env["USERPROFILE"]||"C:\\"}else{if(process.platform==="darwin"){a="/Users"}else{a="/home"}}t=u.join(a,"actions","temp")}const a=u.join(t,(0,y.v4)());yield c.mkdirP(a);return a}))}t.createTempDirectory=createTempDirectory;function getArchiveFileSizeInBytes(e){return m.statSync(e).size}t.getArchiveFileSizeInBytes=getArchiveFileSizeInBytes;function resolvePaths(e){var t,a,r,i;var n;return s(this,void 0,void 0,(function*(){const s=[];const l=(n=process.env["GITHUB_WORKSPACE"])!==null&&n!==void 0?n:process.cwd();const c=yield d.create(e.join("\n"),{implicitDescendants:false});try{for(var m=true,h=o(c.globGenerator()),g;g=yield h.next(),t=g.done,!t;){i=g.value;m=false;try{const e=i;const t=u.relative(l,e).replace(new RegExp(`\\${u.sep}`,"g"),"/");p.debug(`Matched: ${t}`);if(t===""){s.push(".")}else{s.push(`${t}`)}}finally{m=true}}}catch(e){a={error:e}}finally{try{if(!m&&!t&&(r=h.return))yield r.call(h)}finally{if(a)throw a.error}}return s}))}t.resolvePaths=resolvePaths;function unlinkFile(e){return s(this,void 0,void 0,(function*(){return g.promisify(m.unlink)(e)}))}t.unlinkFile=unlinkFile;function getVersion(e,t=[]){return s(this,void 0,void 0,(function*(){let a="";t.push("--version");p.debug(`Checking ${e} ${t.join(" ")}`);try{yield l.exec(`${e}`,t,{ignoreReturnCode:true,silent:true,listeners:{stdout:e=>a+=e.toString(),stderr:e=>a+=e.toString()}})}catch(e){p.debug(e.message)}a=a.trim();p.debug(a);return a}))}function getCompressionMethod(){return s(this,void 0,void 0,(function*(){const e=yield getVersion("zstd",["--quiet"]);const t=h.clean(e);p.debug(`zstd version: ${t}`);if(e===""){return v.CompressionMethod.Gzip}else{return v.CompressionMethod.ZstdWithoutLong}}))}t.getCompressionMethod=getCompressionMethod;function getCacheFileName(e){return e===v.CompressionMethod.Gzip?v.CacheFilename.Gzip:v.CacheFilename.Zstd}t.getCacheFileName=getCacheFileName;function getGnuTarPathOnWindows(){return s(this,void 0,void 0,(function*(){if(m.existsSync(v.GnuTarPathOnWindows)){return v.GnuTarPathOnWindows}const e=yield getVersion("tar");return e.toLowerCase().includes("gnu tar")?c.which("tar"):""}))}t.getGnuTarPathOnWindows=getGnuTarPathOnWindows;function assertDefined(e,t){if(t===undefined){throw Error(`Expected ${e} but value was undefiend`)}return t}t.assertDefined=assertDefined;function isGhes(){const e=new URL(process.env["GITHUB_SERVER_URL"]||"https://github.com");return e.hostname.toUpperCase()!=="GITHUB.COM"}t.isGhes=isGhes},8840:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ManifestFilename=t.TarFilename=t.SystemTarPathOnWindows=t.GnuTarPathOnWindows=t.SocketTimeout=t.DefaultRetryDelay=t.DefaultRetryAttempts=t.ArchiveToolType=t.CompressionMethod=t.CacheFilename=void 0;var a;(function(e){e["Gzip"]="cache.tgz";e["Zstd"]="cache.tzst"})(a=t.CacheFilename||(t.CacheFilename={}));var r;(function(e){e["Gzip"]="gzip";e["ZstdWithoutLong"]="zstd-without-long";e["Zstd"]="zstd"})(r=t.CompressionMethod||(t.CompressionMethod={}));var i;(function(e){e["GNU"]="gnu";e["BSD"]="bsd"})(i=t.ArchiveToolType||(t.ArchiveToolType={}));t.DefaultRetryAttempts=2;t.DefaultRetryDelay=5e3;t.SocketTimeout=5e3;t.GnuTarPathOnWindows=`${process.env["PROGRAMFILES"]}\\Git\\usr\\bin\\tar.exe`;t.SystemTarPathOnWindows=`${process.env["SYSTEMDRIVE"]}\\Windows\\System32\\tar.exe`;t.TarFilename="cache.tar";t.ManifestFilename="manifest.txt"},5500:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.downloadCacheStorageSDK=t.downloadCacheHttpClientConcurrent=t.downloadCacheHttpClient=t.DownloadProgress=void 0;const o=n(a(2186));const p=a(6255);const l=a(4100);const d=n(a(4300));const c=n(a(7147));const m=n(a(2781));const u=n(a(3837));const h=n(a(1518));const g=a(8840);const y=a(3981);const v=a(2557);function pipeResponseToStream(e,t){return s(this,void 0,void 0,(function*(){const a=u.promisify(m.pipeline);yield a(e.message,t)}))}class DownloadProgress{constructor(e){this.contentLength=e;this.segmentIndex=0;this.segmentSize=0;this.segmentOffset=0;this.receivedBytes=0;this.displayedComplete=false;this.startTime=Date.now()}nextSegment(e){this.segmentOffset=this.segmentOffset+this.segmentSize;this.segmentIndex=this.segmentIndex+1;this.segmentSize=e;this.receivedBytes=0;o.debug(`Downloading segment at offset ${this.segmentOffset} with length ${this.segmentSize}...`)}setReceivedBytes(e){this.receivedBytes=e}getTransferredBytes(){return this.segmentOffset+this.receivedBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete){return}const e=this.segmentOffset+this.receivedBytes;const t=(100*(e/this.contentLength)).toFixed(1);const a=Date.now()-this.startTime;const r=(e/(1024*1024)/(a/1e3)).toFixed(1);o.info(`Received ${e} of ${this.contentLength} (${t}%), ${r} MBs/sec`);if(this.isDone()){this.displayedComplete=true}}onProgress(){return e=>{this.setReceivedBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){const displayCallback=()=>{this.display();if(!this.isDone()){this.timeoutHandle=setTimeout(displayCallback,e)}};this.timeoutHandle=setTimeout(displayCallback,e)}stopDisplayTimer(){if(this.timeoutHandle){clearTimeout(this.timeoutHandle);this.timeoutHandle=undefined}this.display()}}t.DownloadProgress=DownloadProgress;function downloadCacheHttpClient(e,t){return s(this,void 0,void 0,(function*(){const a=c.createWriteStream(t);const r=new p.HttpClient("actions/cache");const i=yield(0,y.retryHttpClientResponse)("downloadCache",(()=>s(this,void 0,void 0,(function*(){return r.get(e)}))));i.message.socket.setTimeout(g.SocketTimeout,(()=>{i.message.destroy();o.debug(`Aborting download, socket timed out after ${g.SocketTimeout} ms`)}));yield pipeResponseToStream(i,a);const n=i.message.headers["content-length"];if(n){const e=parseInt(n);const a=h.getArchiveFileSizeInBytes(t);if(a!==e){throw new Error(`Incomplete download. Expected file size: ${e}, actual file size: ${a}`)}}else{o.debug("Unable to validate download, no Content-Length header")}}))}t.downloadCacheHttpClient=downloadCacheHttpClient;function downloadCacheHttpClientConcurrent(e,t,a){var r;return s(this,void 0,void 0,(function*(){const i=yield c.promises.open(t,"w");const n=new p.HttpClient("actions/cache",undefined,{socketTimeout:a.timeoutInMs,keepAlive:true});try{const t=yield(0,y.retryHttpClientResponse)("downloadCacheMetadata",(()=>s(this,void 0,void 0,(function*(){return yield n.request("HEAD",e,null,{})}))));const o=t.message.headers["content-length"];if(o===undefined||o===null){throw new Error("Content-Length not found on blob response")}const p=parseInt(o);if(Number.isNaN(p)){throw new Error(`Could not interpret Content-Length: ${p}`)}const l=[];const d=4*1024*1024;for(let t=0;ts(this,void 0,void 0,(function*(){return yield downloadSegmentRetry(n,e,t,a)}))})}l.reverse();let c=0;let m=0;const u=new DownloadProgress(p);u.startDisplayTimer();const h=u.onProgress();const g=[];let v;const waitAndWrite=()=>s(this,void 0,void 0,(function*(){const e=yield Promise.race(Object.values(g));yield i.write(e.buffer,0,e.count,e.offset);c--;delete g[e.offset];m+=e.count;h({loadedBytes:m})}));while(v=l.pop()){g[v.offset]=v.promiseGetter();c++;if(c>=((r=a.downloadConcurrency)!==null&&r!==void 0?r:10)){yield waitAndWrite()}}while(c>0){yield waitAndWrite()}}finally{n.dispose();yield i.close()}}))}t.downloadCacheHttpClientConcurrent=downloadCacheHttpClientConcurrent;function downloadSegmentRetry(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=5;let n=0;while(true){try{const i=3e4;const n=yield promiseWithTimeout(i,downloadSegment(e,t,a,r));if(typeof n==="string"){throw new Error("downloadSegmentRetry failed due to timeout")}return n}catch(e){if(n>=i){throw e}n++}}}))}function downloadSegment(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=yield(0,y.retryHttpClientResponse)("downloadCachePart",(()=>s(this,void 0,void 0,(function*(){return yield e.get(t,{Range:`bytes=${a}-${a+r-1}`})}))));if(!i.readBodyBuffer){throw new Error("Expected HttpClientResponse to implement readBodyBuffer")}return{offset:a,count:r,buffer:yield i.readBodyBuffer()}}))}function downloadCacheStorageSDK(e,t,a){var r;return s(this,void 0,void 0,(function*(){const i=new l.BlockBlobClient(e,undefined,{retryOptions:{tryTimeoutInMs:a.timeoutInMs}});const n=yield i.getProperties();const s=(r=n.contentLength)!==null&&r!==void 0?r:-1;if(s<0){o.debug("Unable to determine content length, downloading file with http-client...");yield downloadCacheHttpClient(e,t)}else{const e=Math.min(134217728,d.constants.MAX_LENGTH);const r=new DownloadProgress(s);const n=c.openSync(t,"w");try{r.startDisplayTimer();const t=new v.AbortController;const o=t.signal;while(!r.isDone()){const p=r.segmentOffset+r.segmentSize;const l=Math.min(e,s-p);r.nextSegment(l);const d=yield promiseWithTimeout(a.segmentTimeoutInMs||36e5,i.downloadToBuffer(p,l,{abortSignal:o,concurrency:a.downloadConcurrency,onProgress:r.onProgress()}));if(d==="timeout"){t.abort();throw new Error("Aborting cache download as the download time exceeded the timeout.")}else if(Buffer.isBuffer(d)){c.writeFileSync(n,d)}}}finally{r.stopDisplayTimer();c.closeSync(n)}}}))}t.downloadCacheStorageSDK=downloadCacheStorageSDK;const promiseWithTimeout=(e,t)=>s(void 0,void 0,void 0,(function*(){let a;const r=new Promise((t=>{a=setTimeout((()=>t("timeout")),e)}));return Promise.race([t,r]).then((e=>{clearTimeout(a);return e}))}))},3981:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.retryHttpClientResponse=t.retryTypedResponse=t.retry=t.isRetryableStatusCode=t.isServerErrorStatusCode=t.isSuccessStatusCode=void 0;const o=n(a(2186));const p=a(6255);const l=a(8840);function isSuccessStatusCode(e){if(!e){return false}return e>=200&&e<300}t.isSuccessStatusCode=isSuccessStatusCode;function isServerErrorStatusCode(e){if(!e){return true}return e>=500}t.isServerErrorStatusCode=isServerErrorStatusCode;function isRetryableStatusCode(e){if(!e){return false}const t=[p.HttpCodes.BadGateway,p.HttpCodes.ServiceUnavailable,p.HttpCodes.GatewayTimeout];return t.includes(e)}t.isRetryableStatusCode=isRetryableStatusCode;function sleep(e){return s(this,void 0,void 0,(function*(){return new Promise((t=>setTimeout(t,e)))}))}function retry(e,t,a,r=l.DefaultRetryAttempts,i=l.DefaultRetryDelay,n=undefined){return s(this,void 0,void 0,(function*(){let s="";let p=1;while(p<=r){let l=undefined;let d=undefined;let c=false;try{l=yield t()}catch(e){if(n){l=n(e)}c=true;s=e.message}if(l){d=a(l);if(!isServerErrorStatusCode(d)){return l}}if(d){c=isRetryableStatusCode(d);s=`Cache service responded with ${d}`}o.debug(`${e} - Attempt ${p} of ${r} failed with error: ${s}`);if(!c){o.debug(`${e} - Error is not retryable`);break}yield sleep(i);p++}throw Error(`${e} failed: ${s}`)}))}t.retry=retry;function retryTypedResponse(e,t,a=l.DefaultRetryAttempts,r=l.DefaultRetryDelay){return s(this,void 0,void 0,(function*(){return yield retry(e,t,(e=>e.statusCode),a,r,(e=>{if(e instanceof p.HttpClientError){return{statusCode:e.statusCode,result:null,headers:{},error:e}}else{return undefined}}))}))}t.retryTypedResponse=retryTypedResponse;function retryHttpClientResponse(e,t,a=l.DefaultRetryAttempts,r=l.DefaultRetryDelay){return s(this,void 0,void 0,(function*(){return yield retry(e,t,(e=>e.message.statusCode),a,r)}))}t.retryHttpClientResponse=retryHttpClientResponse},6490:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.createTar=t.extractTar=t.listTar=void 0;const o=a(1514);const p=n(a(7436));const l=a(7147);const d=n(a(1017));const c=n(a(1518));const m=a(8840);const u=process.platform==="win32";function getTarPath(){return s(this,void 0,void 0,(function*(){switch(process.platform){case"win32":{const e=yield c.getGnuTarPathOnWindows();const t=m.SystemTarPathOnWindows;if(e){return{path:e,type:m.ArchiveToolType.GNU}}else if((0,l.existsSync)(t)){return{path:t,type:m.ArchiveToolType.BSD}}break}case"darwin":{const e=yield p.which("gtar",false);if(e){return{path:e,type:m.ArchiveToolType.GNU}}else{return{path:yield p.which("tar",true),type:m.ArchiveToolType.BSD}}}default:break}return{path:yield p.which("tar",true),type:m.ArchiveToolType.GNU}}))}function getTarArgs(e,t,a,r=""){return s(this,void 0,void 0,(function*(){const i=[`"${e.path}"`];const n=c.getCacheFileName(t);const s="cache.tar";const o=getWorkingDirectory();const p=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(a){case"create":i.push("--posix","-cf",p?s:n.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"--exclude",p?s:n.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P","-C",o.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"--files-from",m.ManifestFilename);break;case"extract":i.push("-xf",p?s:r.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P","-C",o.replace(new RegExp(`\\${d.sep}`,"g"),"/"));break;case"list":i.push("-tf",p?s:r.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P");break}if(e.type===m.ArchiveToolType.GNU){switch(process.platform){case"win32":i.push("--force-local");break;case"darwin":i.push("--delay-directory-restore");break}}return i}))}function getCommands(e,t,a=""){return s(this,void 0,void 0,(function*(){let r;const i=yield getTarPath();const n=yield getTarArgs(i,e,t,a);const s=t!=="create"?yield getDecompressionProgram(i,e,a):yield getCompressionProgram(i,e);const o=i.type===m.ArchiveToolType.BSD&&e!==m.CompressionMethod.Gzip&&u;if(o&&t!=="create"){r=[[...s].join(" "),[...n].join(" ")]}else{r=[[...n].join(" "),[...s].join(" ")]}if(o){return r}return[r.join(" ")]}))}function getWorkingDirectory(){var e;return(e=process.env["GITHUB_WORKSPACE"])!==null&&e!==void 0?e:process.cwd()}function getDecompressionProgram(e,t,a){return s(this,void 0,void 0,(function*(){const r=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(t){case m.CompressionMethod.Zstd:return r?["zstd -d --long=30 --force -o",m.TarFilename,a.replace(new RegExp(`\\${d.sep}`,"g"),"/")]:["--use-compress-program",u?'"zstd -d --long=30"':"unzstd --long=30"];case m.CompressionMethod.ZstdWithoutLong:return r?["zstd -d --force -o",m.TarFilename,a.replace(new RegExp(`\\${d.sep}`,"g"),"/")]:["--use-compress-program",u?'"zstd -d"':"unzstd"];default:return["-z"]}}))}function getCompressionProgram(e,t){return s(this,void 0,void 0,(function*(){const a=c.getCacheFileName(t);const r=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(t){case m.CompressionMethod.Zstd:return r?["zstd -T0 --long=30 --force -o",a.replace(new RegExp(`\\${d.sep}`,"g"),"/"),m.TarFilename]:["--use-compress-program",u?'"zstd -T0 --long=30"':"zstdmt --long=30"];case m.CompressionMethod.ZstdWithoutLong:return r?["zstd -T0 --force -o",a.replace(new RegExp(`\\${d.sep}`,"g"),"/"),m.TarFilename]:["--use-compress-program",u?'"zstd -T0"':"zstdmt"];default:return["-z"]}}))}function execCommands(e,t){return s(this,void 0,void 0,(function*(){for(const a of e){try{yield(0,o.exec)(a,undefined,{cwd:t,env:Object.assign(Object.assign({},process.env),{MSYS:"winsymlinks:nativestrict"})})}catch(e){throw new Error(`${a.split(" ")[0]} failed with error: ${e===null||e===void 0?void 0:e.message}`)}}}))}function listTar(e,t){return s(this,void 0,void 0,(function*(){const a=yield getCommands(t,"list",e);yield execCommands(a)}))}t.listTar=listTar;function extractTar(e,t){return s(this,void 0,void 0,(function*(){const a=getWorkingDirectory();yield p.mkdirP(a);const r=yield getCommands(t,"extract",e);yield execCommands(r)}))}t.extractTar=extractTar;function createTar(e,t,a){return s(this,void 0,void 0,(function*(){(0,l.writeFileSync)(d.join(e,m.ManifestFilename),t.join("\n"));const r=yield getCommands(a,"create");yield execCommands(r,e)}))}t.createTar=createTar},6215:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getDownloadOptions=t.getUploadOptions=void 0;const s=n(a(2186));function getUploadOptions(e){const t={uploadConcurrency:4,uploadChunkSize:32*1024*1024};if(e){if(typeof e.uploadConcurrency==="number"){t.uploadConcurrency=e.uploadConcurrency}if(typeof e.uploadChunkSize==="number"){t.uploadChunkSize=e.uploadChunkSize}}s.debug(`Upload concurrency: ${t.uploadConcurrency}`);s.debug(`Upload chunk size: ${t.uploadChunkSize}`);return t}t.getUploadOptions=getUploadOptions;function getDownloadOptions(e){const t={useAzureSdk:false,concurrentBlobDownloads:true,downloadConcurrency:8,timeoutInMs:3e4,segmentTimeoutInMs:6e5,lookupOnly:false};if(e){if(typeof e.useAzureSdk==="boolean"){t.useAzureSdk=e.useAzureSdk}if(typeof e.concurrentBlobDownloads==="boolean"){t.concurrentBlobDownloads=e.concurrentBlobDownloads}if(typeof e.downloadConcurrency==="number"){t.downloadConcurrency=e.downloadConcurrency}if(typeof e.timeoutInMs==="number"){t.timeoutInMs=e.timeoutInMs}if(typeof e.segmentTimeoutInMs==="number"){t.segmentTimeoutInMs=e.segmentTimeoutInMs}if(typeof e.lookupOnly==="boolean"){t.lookupOnly=e.lookupOnly}}const a=process.env["SEGMENT_DOWNLOAD_TIMEOUT_MINS"];if(a&&!isNaN(Number(a))&&isFinite(Number(a))){t.segmentTimeoutInMs=Number(a)*60*1e3}s.debug(`Use Azure SDK: ${t.useAzureSdk}`);s.debug(`Download concurrency: ${t.downloadConcurrency}`);s.debug(`Request timeout (ms): ${t.timeoutInMs}`);s.debug(`Cache segment download timeout mins env var: ${process.env["SEGMENT_DOWNLOAD_TIMEOUT_MINS"]}`);s.debug(`Segment download timeout (ms): ${t.segmentTimeoutInMs}`);s.debug(`Lookup only: ${t.lookupOnly}`);return t}t.getDownloadOptions=getDownloadOptions},4138:(e,t,a)=>{var r=a(1610);var i=a(8373);var n=i;n.v1=r;n.v4=i;e.exports=n},5694:e=>{var t=[];for(var a=0;a<256;++a){t[a]=(a+256).toString(16).substr(1)}function bytesToUuid(e,a){var r=a||0;var i=t;return[i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]]].join("")}e.exports=bytesToUuid},4069:(e,t,a)=>{var r=a(6113);e.exports=function nodeRNG(){return r.randomBytes(16)}},1610:(e,t,a)=>{var r=a(4069);var i=a(5694);var n;var s;var o=0;var p=0;function v1(e,t,a){var l=t&&a||0;var d=t||[];e=e||{};var c=e.node||n;var m=e.clockseq!==undefined?e.clockseq:s;if(c==null||m==null){var u=r();if(c==null){c=n=[u[0]|1,u[1],u[2],u[3],u[4],u[5]]}if(m==null){m=s=(u[6]<<8|u[7])&16383}}var h=e.msecs!==undefined?e.msecs:(new Date).getTime();var g=e.nsecs!==undefined?e.nsecs:p+1;var y=h-o+(g-p)/1e4;if(y<0&&e.clockseq===undefined){m=m+1&16383}if((y<0||h>o)&&e.nsecs===undefined){g=0}if(g>=1e4){throw new Error("uuid.v1(): Can't create more than 10M uuids/sec")}o=h;p=g;s=m;h+=122192928e5;var v=((h&268435455)*1e4+g)%4294967296;d[l++]=v>>>24&255;d[l++]=v>>>16&255;d[l++]=v>>>8&255;d[l++]=v&255;var b=h/4294967296*1e4&268435455;d[l++]=b>>>8&255;d[l++]=b&255;d[l++]=b>>>24&15|16;d[l++]=b>>>16&255;d[l++]=m>>>8|128;d[l++]=m&255;for(var x=0;x<6;++x){d[l+x]=c[x]}return t?t:i(d)}e.exports=v1},8373:(e,t,a)=>{var r=a(4069);var i=a(5694);function v4(e,t,a){var n=t&&a||0;if(typeof e=="string"){t=e==="binary"?new Array(16):null;e=null}e=e||{};var s=e.random||(e.rng||r)();s[6]=s[6]&15|64;s[8]=s[8]&63|128;if(t){for(var o=0;o<16;++o){t[n+o]=s[o]}}return t||i(s)}e.exports=v4},7351:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issue=t.issueCommand=void 0;const s=n(a(2037));const o=a(5278);function issueCommand(e,t,a){const r=new Command(e,t,a);process.stdout.write(r.toString()+s.EOL)}t.issueCommand=issueCommand;function issue(e,t=""){issueCommand(e,{},t)}t.issue=issue;const p="::";class Command{constructor(e,t,a){if(!e){e="missing.command"}this.command=e;this.properties=t;this.message=a}toString(){let e=p+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let t=true;for(const a in this.properties){if(this.properties.hasOwnProperty(a)){const r=this.properties[a];if(r){if(t){t=false}else{e+=","}e+=`${a}=${escapeProperty(r)}`}}}}e+=`${p}${escapeData(this.message)}`;return e}}function escapeData(e){return o.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return o.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},2186:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getIDToken=t.getState=t.saveState=t.group=t.endGroup=t.startGroup=t.info=t.notice=t.warning=t.error=t.debug=t.isDebug=t.setFailed=t.setCommandEcho=t.setOutput=t.getBooleanInput=t.getMultilineInput=t.getInput=t.addPath=t.setSecret=t.exportVariable=t.ExitCode=void 0;const o=a(7351);const p=a(717);const l=a(5278);const d=n(a(2037));const c=n(a(1017));const m=a(8041);var u;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(u=t.ExitCode||(t.ExitCode={}));function exportVariable(e,t){const a=l.toCommandValue(t);process.env[e]=a;const r=process.env["GITHUB_ENV"]||"";if(r){return p.issueFileCommand("ENV",p.prepareKeyValueMessage(e,t))}o.issueCommand("set-env",{name:e},a)}t.exportVariable=exportVariable;function setSecret(e){o.issueCommand("add-mask",{},e)}t.setSecret=setSecret;function addPath(e){const t=process.env["GITHUB_PATH"]||"";if(t){p.issueFileCommand("PATH",e)}else{o.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${c.delimiter}${process.env["PATH"]}`}t.addPath=addPath;function getInput(e,t){const a=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(t&&t.required&&!a){throw new Error(`Input required and not supplied: ${e}`)}if(t&&t.trimWhitespace===false){return a}return a.trim()}t.getInput=getInput;function getMultilineInput(e,t){const a=getInput(e,t).split("\n").filter((e=>e!==""));if(t&&t.trimWhitespace===false){return a}return a.map((e=>e.trim()))}t.getMultilineInput=getMultilineInput;function getBooleanInput(e,t){const a=["true","True","TRUE"];const r=["false","False","FALSE"];const i=getInput(e,t);if(a.includes(i))return true;if(r.includes(i))return false;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${e}\n`+`Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}t.getBooleanInput=getBooleanInput;function setOutput(e,t){const a=process.env["GITHUB_OUTPUT"]||"";if(a){return p.issueFileCommand("OUTPUT",p.prepareKeyValueMessage(e,t))}process.stdout.write(d.EOL);o.issueCommand("set-output",{name:e},l.toCommandValue(t))}t.setOutput=setOutput;function setCommandEcho(e){o.issue("echo",e?"on":"off")}t.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=u.Failure;error(e)}t.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}t.isDebug=isDebug;function debug(e){o.issueCommand("debug",{},e)}t.debug=debug;function error(e,t={}){o.issueCommand("error",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.error=error;function warning(e,t={}){o.issueCommand("warning",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.warning=warning;function notice(e,t={}){o.issueCommand("notice",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.notice=notice;function info(e){process.stdout.write(e+d.EOL)}t.info=info;function startGroup(e){o.issue("group",e)}t.startGroup=startGroup;function endGroup(){o.issue("endgroup")}t.endGroup=endGroup;function group(e,t){return s(this,void 0,void 0,(function*(){startGroup(e);let a;try{a=yield t()}finally{endGroup()}return a}))}t.group=group;function saveState(e,t){const a=process.env["GITHUB_STATE"]||"";if(a){return p.issueFileCommand("STATE",p.prepareKeyValueMessage(e,t))}o.issueCommand("save-state",{name:e},l.toCommandValue(t))}t.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}t.getState=getState;function getIDToken(e){return s(this,void 0,void 0,(function*(){return yield m.OidcClient.getIDToken(e)}))}t.getIDToken=getIDToken;var h=a(1327);Object.defineProperty(t,"summary",{enumerable:true,get:function(){return h.summary}});var g=a(1327);Object.defineProperty(t,"markdownSummary",{enumerable:true,get:function(){return g.markdownSummary}});var y=a(2981);Object.defineProperty(t,"toPosixPath",{enumerable:true,get:function(){return y.toPosixPath}});Object.defineProperty(t,"toWin32Path",{enumerable:true,get:function(){return y.toWin32Path}});Object.defineProperty(t,"toPlatformPath",{enumerable:true,get:function(){return y.toPlatformPath}})},717:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.prepareKeyValueMessage=t.issueFileCommand=void 0;const s=n(a(7147));const o=n(a(2037));const p=a(5840);const l=a(5278);function issueFileCommand(e,t){const a=process.env[`GITHUB_${e}`];if(!a){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!s.existsSync(a)){throw new Error(`Missing file at path: ${a}`)}s.appendFileSync(a,`${l.toCommandValue(t)}${o.EOL}`,{encoding:"utf8"})}t.issueFileCommand=issueFileCommand;function prepareKeyValueMessage(e,t){const a=`ghadelimiter_${p.v4()}`;const r=l.toCommandValue(t);if(e.includes(a)){throw new Error(`Unexpected input: name should not contain the delimiter "${a}"`)}if(r.includes(a)){throw new Error(`Unexpected input: value should not contain the delimiter "${a}"`)}return`${e}<<${a}${o.EOL}${r}${o.EOL}${a}`}t.prepareKeyValueMessage=prepareKeyValueMessage},8041:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.OidcClient=void 0;const i=a(6255);const n=a(5526);const s=a(2186);class OidcClient{static createHttpClient(e=true,t=10){const a={allowRetries:e,maxRetries:t};return new i.HttpClient("actions/oidc-client",[new n.BearerCredentialHandler(OidcClient.getRequestToken())],a)}static getRequestToken(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_TOKEN env variable")}return e}static getIDTokenUrl(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_URL"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable")}return e}static getCall(e){var t;return r(this,void 0,void 0,(function*(){const a=OidcClient.createHttpClient();const r=yield a.getJson(e).catch((e=>{throw new Error(`Failed to get ID Token. \n \n Error Code : ${e.statusCode}\n \n Error Message: ${e.result.message}`)}));const i=(t=r.result)===null||t===void 0?void 0:t.value;if(!i){throw new Error("Response json body do not have ID Token field")}return i}))}static getIDToken(e){return r(this,void 0,void 0,(function*(){try{let t=OidcClient.getIDTokenUrl();if(e){const a=encodeURIComponent(e);t=`${t}&audience=${a}`}s.debug(`ID token url is ${t}`);const a=yield OidcClient.getCall(t);s.setSecret(a);return a}catch(e){throw new Error(`Error message: ${e.message}`)}}))}}t.OidcClient=OidcClient},2981:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.toPlatformPath=t.toWin32Path=t.toPosixPath=void 0;const s=n(a(1017));function toPosixPath(e){return e.replace(/[\\]/g,"/")}t.toPosixPath=toPosixPath;function toWin32Path(e){return e.replace(/[/]/g,"\\")}t.toWin32Path=toWin32Path;function toPlatformPath(e){return e.replace(/[/\\]/g,s.sep)}t.toPlatformPath=toPlatformPath},1327:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.summary=t.markdownSummary=t.SUMMARY_DOCS_URL=t.SUMMARY_ENV_VAR=void 0;const i=a(2037);const n=a(7147);const{access:s,appendFile:o,writeFile:p}=n.promises;t.SUMMARY_ENV_VAR="GITHUB_STEP_SUMMARY";t.SUMMARY_DOCS_URL="https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary";class Summary{constructor(){this._buffer=""}filePath(){return r(this,void 0,void 0,(function*(){if(this._filePath){return this._filePath}const e=process.env[t.SUMMARY_ENV_VAR];if(!e){throw new Error(`Unable to find environment variable for $${t.SUMMARY_ENV_VAR}. Check if your runtime environment supports job summaries.`)}try{yield s(e,n.constants.R_OK|n.constants.W_OK)}catch(t){throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}this._filePath=e;return this._filePath}))}wrap(e,t,a={}){const r=Object.entries(a).map((([e,t])=>` ${e}="${t}"`)).join("");if(!t){return`<${e}${r}>`}return`<${e}${r}>${t}`}write(e){return r(this,void 0,void 0,(function*(){const t=!!(e===null||e===void 0?void 0:e.overwrite);const a=yield this.filePath();const r=t?p:o;yield r(a,this._buffer,{encoding:"utf8"});return this.emptyBuffer()}))}clear(){return r(this,void 0,void 0,(function*(){return this.emptyBuffer().write({overwrite:true})}))}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){this._buffer="";return this}addRaw(e,t=false){this._buffer+=e;return t?this.addEOL():this}addEOL(){return this.addRaw(i.EOL)}addCodeBlock(e,t){const a=Object.assign({},t&&{lang:t});const r=this.wrap("pre",this.wrap("code",e),a);return this.addRaw(r).addEOL()}addList(e,t=false){const a=t?"ol":"ul";const r=e.map((e=>this.wrap("li",e))).join("");const i=this.wrap(a,r);return this.addRaw(i).addEOL()}addTable(e){const t=e.map((e=>{const t=e.map((e=>{if(typeof e==="string"){return this.wrap("td",e)}const{header:t,data:a,colspan:r,rowspan:i}=e;const n=t?"th":"td";const s=Object.assign(Object.assign({},r&&{colspan:r}),i&&{rowspan:i});return this.wrap(n,a,s)})).join("");return this.wrap("tr",t)})).join("");const a=this.wrap("table",t);return this.addRaw(a).addEOL()}addDetails(e,t){const a=this.wrap("details",this.wrap("summary",e)+t);return this.addRaw(a).addEOL()}addImage(e,t,a){const{width:r,height:i}=a||{};const n=Object.assign(Object.assign({},r&&{width:r}),i&&{height:i});const s=this.wrap("img",null,Object.assign({src:e,alt:t},n));return this.addRaw(s).addEOL()}addHeading(e,t){const a=`h${t}`;const r=["h1","h2","h3","h4","h5","h6"].includes(a)?a:"h1";const i=this.wrap(r,e);return this.addRaw(i).addEOL()}addSeparator(){const e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){const e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,t){const a=Object.assign({},t&&{cite:t});const r=this.wrap("blockquote",e,a);return this.addRaw(r).addEOL()}addLink(e,t){const a=this.wrap("a",e,{href:t});return this.addRaw(a).addEOL()}}const l=new Summary;t.markdownSummary=l;t.summary=l},5278:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.toCommandProperties=t.toCommandValue=void 0;function toCommandValue(e){if(e===null||e===undefined){return""}else if(typeof e==="string"||e instanceof String){return e}return JSON.stringify(e)}t.toCommandValue=toCommandValue;function toCommandProperties(e){if(!Object.keys(e).length){return{}}return{title:e.title,file:e.file,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}}t.toCommandProperties=toCommandProperties},1514:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getExecOutput=t.exec=void 0;const o=a(1576);const p=n(a(8159));function exec(e,t,a){return s(this,void 0,void 0,(function*(){const r=p.argStringToArray(e);if(r.length===0){throw new Error(`Parameter 'commandLine' cannot be null or empty.`)}const i=r[0];t=r.slice(1).concat(t||[]);const n=new p.ToolRunner(i,t,a);return n.exec()}))}t.exec=exec;function getExecOutput(e,t,a){var r,i;return s(this,void 0,void 0,(function*(){let n="";let s="";const p=new o.StringDecoder("utf8");const l=new o.StringDecoder("utf8");const d=(r=a===null||a===void 0?void 0:a.listeners)===null||r===void 0?void 0:r.stdout;const c=(i=a===null||a===void 0?void 0:a.listeners)===null||i===void 0?void 0:i.stderr;const stdErrListener=e=>{s+=l.write(e);if(c){c(e)}};const stdOutListener=e=>{n+=p.write(e);if(d){d(e)}};const m=Object.assign(Object.assign({},a===null||a===void 0?void 0:a.listeners),{stdout:stdOutListener,stderr:stdErrListener});const u=yield exec(e,t,Object.assign(Object.assign({},a),{listeners:m}));n+=p.end();s+=l.end();return{exitCode:u,stdout:n,stderr:s}}))}t.getExecOutput=getExecOutput},8159:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.argStringToArray=t.ToolRunner=void 0;const o=n(a(2037));const p=n(a(2361));const l=n(a(2081));const d=n(a(1017));const c=n(a(7436));const m=n(a(1962));const u=a(9512);const h=process.platform==="win32";class ToolRunner extends p.EventEmitter{constructor(e,t,a){super();if(!e){throw new Error("Parameter 'toolPath' cannot be null or empty.")}this.toolPath=e;this.args=t||[];this.options=a||{}}_debug(e){if(this.options.listeners&&this.options.listeners.debug){this.options.listeners.debug(e)}}_getCommandString(e,t){const a=this._getSpawnFileName();const r=this._getSpawnArgs(e);let i=t?"":"[command]";if(h){if(this._isCmdFile()){i+=a;for(const e of r){i+=` ${e}`}}else if(e.windowsVerbatimArguments){i+=`"${a}"`;for(const e of r){i+=` ${e}`}}else{i+=this._windowsQuoteCmdArg(a);for(const e of r){i+=` ${this._windowsQuoteCmdArg(e)}`}}}else{i+=a;for(const e of r){i+=` ${e}`}}return i}_processLineBuffer(e,t,a){try{let r=t+e.toString();let i=r.indexOf(o.EOL);while(i>-1){const e=r.substring(0,i);a(e);r=r.substring(i+o.EOL.length);i=r.indexOf(o.EOL)}return r}catch(e){this._debug(`error processing line. Failed with error ${e}`);return""}}_getSpawnFileName(){if(h){if(this._isCmdFile()){return process.env["COMSPEC"]||"cmd.exe"}}return this.toolPath}_getSpawnArgs(e){if(h){if(this._isCmdFile()){let t=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(const a of this.args){t+=" ";t+=e.windowsVerbatimArguments?a:this._windowsQuoteCmdArg(a)}t+='"';return[t]}}return this.args}_endsWith(e,t){return e.endsWith(t)}_isCmdFile(){const e=this.toolPath.toUpperCase();return this._endsWith(e,".CMD")||this._endsWith(e,".BAT")}_windowsQuoteCmdArg(e){if(!this._isCmdFile()){return this._uvQuoteCmdArg(e)}if(!e){return'""'}const t=[" ","\t","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'];let a=false;for(const r of e){if(t.some((e=>e===r))){a=true;break}}if(!a){return e}let r='"';let i=true;for(let t=e.length;t>0;t--){r+=e[t-1];if(i&&e[t-1]==="\\"){r+="\\"}else if(e[t-1]==='"'){i=true;r+='"'}else{i=false}}r+='"';return r.split("").reverse().join("")}_uvQuoteCmdArg(e){if(!e){return'""'}if(!e.includes(" ")&&!e.includes("\t")&&!e.includes('"')){return e}if(!e.includes('"')&&!e.includes("\\")){return`"${e}"`}let t='"';let a=true;for(let r=e.length;r>0;r--){t+=e[r-1];if(a&&e[r-1]==="\\"){t+="\\"}else if(e[r-1]==='"'){a=true;t+="\\"}else{a=false}}t+='"';return t.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};const t={cwd:e.cwd||process.cwd(),env:e.env||process.env,silent:e.silent||false,windowsVerbatimArguments:e.windowsVerbatimArguments||false,failOnStdErr:e.failOnStdErr||false,ignoreReturnCode:e.ignoreReturnCode||false,delay:e.delay||1e4};t.outStream=e.outStream||process.stdout;t.errStream=e.errStream||process.stderr;return t}_getSpawnOptions(e,t){e=e||{};const a={};a.cwd=e.cwd;a.env=e.env;a["windowsVerbatimArguments"]=e.windowsVerbatimArguments||this._isCmdFile();if(e.windowsVerbatimArguments){a.argv0=`"${t}"`}return a}exec(){return s(this,void 0,void 0,(function*(){if(!m.isRooted(this.toolPath)&&(this.toolPath.includes("/")||h&&this.toolPath.includes("\\"))){this.toolPath=d.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)}this.toolPath=yield c.which(this.toolPath,true);return new Promise(((e,t)=>s(this,void 0,void 0,(function*(){this._debug(`exec tool: ${this.toolPath}`);this._debug("arguments:");for(const e of this.args){this._debug(` ${e}`)}const a=this._cloneExecOptions(this.options);if(!a.silent&&a.outStream){a.outStream.write(this._getCommandString(a)+o.EOL)}const r=new ExecState(a,this.toolPath);r.on("debug",(e=>{this._debug(e)}));if(this.options.cwd&&!(yield m.exists(this.options.cwd))){return t(new Error(`The cwd: ${this.options.cwd} does not exist!`))}const i=this._getSpawnFileName();const n=l.spawn(i,this._getSpawnArgs(a),this._getSpawnOptions(this.options,i));let s="";if(n.stdout){n.stdout.on("data",(e=>{if(this.options.listeners&&this.options.listeners.stdout){this.options.listeners.stdout(e)}if(!a.silent&&a.outStream){a.outStream.write(e)}s=this._processLineBuffer(e,s,(e=>{if(this.options.listeners&&this.options.listeners.stdline){this.options.listeners.stdline(e)}}))}))}let p="";if(n.stderr){n.stderr.on("data",(e=>{r.processStderr=true;if(this.options.listeners&&this.options.listeners.stderr){this.options.listeners.stderr(e)}if(!a.silent&&a.errStream&&a.outStream){const t=a.failOnStdErr?a.errStream:a.outStream;t.write(e)}p=this._processLineBuffer(e,p,(e=>{if(this.options.listeners&&this.options.listeners.errline){this.options.listeners.errline(e)}}))}))}n.on("error",(e=>{r.processError=e.message;r.processExited=true;r.processClosed=true;r.CheckComplete()}));n.on("exit",(e=>{r.processExitCode=e;r.processExited=true;this._debug(`Exit code ${e} received from tool '${this.toolPath}'`);r.CheckComplete()}));n.on("close",(e=>{r.processExitCode=e;r.processExited=true;r.processClosed=true;this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);r.CheckComplete()}));r.on("done",((a,r)=>{if(s.length>0){this.emit("stdline",s)}if(p.length>0){this.emit("errline",p)}n.removeAllListeners();if(a){t(a)}else{e(r)}}));if(this.options.input){if(!n.stdin){throw new Error("child process missing stdin")}n.stdin.end(this.options.input)}}))))}))}}t.ToolRunner=ToolRunner;function argStringToArray(e){const t=[];let a=false;let r=false;let i="";function append(e){if(r&&e!=='"'){i+="\\"}i+=e;r=false}for(let n=0;n0){t.push(i);i=""}continue}append(s)}if(i.length>0){t.push(i.trim())}return t}t.argStringToArray=argStringToArray;class ExecState extends p.EventEmitter{constructor(e,t){super();this.processClosed=false;this.processError="";this.processExitCode=0;this.processExited=false;this.processStderr=false;this.delay=1e4;this.done=false;this.timeout=null;if(!t){throw new Error("toolPath must not be empty")}this.options=e;this.toolPath=t;if(e.delay){this.delay=e.delay}}CheckComplete(){if(this.done){return}if(this.processClosed){this._setResult()}else if(this.processExited){this.timeout=u.setTimeout(ExecState.HandleTimeout,this.delay,this)}}_debug(e){this.emit("debug",e)}_setResult(){let e;if(this.processExited){if(this.processError){e=new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`)}else if(this.processExitCode!==0&&!this.options.ignoreReturnCode){e=new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`)}else if(this.processStderr&&this.options.failOnStdErr){e=new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`)}}if(this.timeout){clearTimeout(this.timeout);this.timeout=null}this.done=true;this.emit("done",e,this.processExitCode)}static HandleTimeout(e){if(e.done){return}if(!e.processClosed&&e.processExited){const t=`The STDIO streams did not close within ${e.delay/1e3} seconds of the exit event from process '${e.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;e._debug(t)}e._setResult()}}},4087:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Context=void 0;const r=a(7147);const i=a(2037);class Context{constructor(){var e,t,a;this.payload={};if(process.env.GITHUB_EVENT_PATH){if(r.existsSync(process.env.GITHUB_EVENT_PATH)){this.payload=JSON.parse(r.readFileSync(process.env.GITHUB_EVENT_PATH,{encoding:"utf8"}))}else{const e=process.env.GITHUB_EVENT_PATH;process.stdout.write(`GITHUB_EVENT_PATH ${e} does not exist${i.EOL}`)}}this.eventName=process.env.GITHUB_EVENT_NAME;this.sha=process.env.GITHUB_SHA;this.ref=process.env.GITHUB_REF;this.workflow=process.env.GITHUB_WORKFLOW;this.action=process.env.GITHUB_ACTION;this.actor=process.env.GITHUB_ACTOR;this.job=process.env.GITHUB_JOB;this.runNumber=parseInt(process.env.GITHUB_RUN_NUMBER,10);this.runId=parseInt(process.env.GITHUB_RUN_ID,10);this.apiUrl=(e=process.env.GITHUB_API_URL)!==null&&e!==void 0?e:`https://api.github.com`;this.serverUrl=(t=process.env.GITHUB_SERVER_URL)!==null&&t!==void 0?t:`https://github.com`;this.graphqlUrl=(a=process.env.GITHUB_GRAPHQL_URL)!==null&&a!==void 0?a:`https://api.github.com/graphql`}get issue(){const e=this.payload;return Object.assign(Object.assign({},this.repo),{number:(e.issue||e.pull_request||e).number})}get repo(){if(process.env.GITHUB_REPOSITORY){const[e,t]=process.env.GITHUB_REPOSITORY.split("/");return{owner:e,repo:t}}if(this.payload.repository){return{owner:this.payload.repository.owner.login,repo:this.payload.repository.name}}throw new Error("context.repo requires a GITHUB_REPOSITORY environment variable like 'owner/repo'")}}t.Context=Context},5438:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokit=t.context=void 0;const s=n(a(4087));const o=a(3030);t.context=new s.Context;function getOctokit(e,t,...a){const r=o.GitHub.plugin(...a);return new r(o.getOctokitOptions(e,t))}t.getOctokit=getOctokit},7914:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getApiBaseUrl=t.getProxyAgent=t.getAuthString=void 0;const s=n(a(6255));function getAuthString(e,t){if(!e&&!t.auth){throw new Error("Parameter token or opts.auth is required")}else if(e&&t.auth){throw new Error("Parameters token and opts.auth may not both be specified")}return typeof t.auth==="string"?t.auth:`token ${e}`}t.getAuthString=getAuthString;function getProxyAgent(e){const t=new s.HttpClient;return t.getAgent(e)}t.getProxyAgent=getProxyAgent;function getApiBaseUrl(){return process.env["GITHUB_API_URL"]||"https://api.github.com"}t.getApiBaseUrl=getApiBaseUrl},3030:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokitOptions=t.GitHub=t.defaults=t.context=void 0;const s=n(a(4087));const o=n(a(7914));const p=a(6762);const l=a(3044);const d=a(4193);t.context=new s.Context;const c=o.getApiBaseUrl();t.defaults={baseUrl:c,request:{agent:o.getProxyAgent(c)}};t.GitHub=p.Octokit.plugin(l.restEndpointMethods,d.paginateRest).defaults(t.defaults);function getOctokitOptions(e,t){const a=Object.assign({},t||{});const r=o.getAuthString(e,a);if(r){a.auth=r}return a}t.getOctokitOptions=getOctokitOptions},8090:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.create=void 0;const i=a(8298);function create(e,t){return r(this,void 0,void 0,(function*(){return yield i.DefaultGlobber.create(e,t)}))}t.create=create},1026:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOptions=void 0;const s=n(a(2186));function getOptions(e){const t={followSymbolicLinks:true,implicitDescendants:true,omitBrokenSymbolicLinks:true};if(e){if(typeof e.followSymbolicLinks==="boolean"){t.followSymbolicLinks=e.followSymbolicLinks;s.debug(`followSymbolicLinks '${t.followSymbolicLinks}'`)}if(typeof e.implicitDescendants==="boolean"){t.implicitDescendants=e.implicitDescendants;s.debug(`implicitDescendants '${t.implicitDescendants}'`)}if(typeof e.omitBrokenSymbolicLinks==="boolean"){t.omitBrokenSymbolicLinks=e.omitBrokenSymbolicLinks;s.debug(`omitBrokenSymbolicLinks '${t.omitBrokenSymbolicLinks}'`)}}return t}t.getOptions=getOptions},8298:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};var p=this&&this.__await||function(e){return this instanceof p?(this.v=e,this):new p(e)};var l=this&&this.__asyncGenerator||function(e,t,a){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=a.apply(e,t||[]),i,n=[];return i={},verb("next"),verb("throw"),verb("return"),i[Symbol.asyncIterator]=function(){return this},i;function verb(e){if(r[e])i[e]=function(t){return new Promise((function(a,r){n.push([e,t,a,r])>1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof p?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};Object.defineProperty(t,"__esModule",{value:true});t.DefaultGlobber=void 0;const d=n(a(2186));const c=n(a(7147));const m=n(a(1026));const u=n(a(1017));const h=n(a(9005));const g=a(1063);const y=a(4536);const v=a(9117);const b=process.platform==="win32";class DefaultGlobber{constructor(e){this.patterns=[];this.searchPaths=[];this.options=m.getOptions(e)}getSearchPaths(){return this.searchPaths.slice()}glob(){var e,t;return s(this,void 0,void 0,(function*(){const a=[];try{for(var r=o(this.globGenerator()),i;i=yield r.next(),!i.done;){const e=i.value;a.push(e)}}catch(t){e={error:t}}finally{try{if(i&&!i.done&&(t=r.return))yield t.call(r)}finally{if(e)throw e.error}}return a}))}globGenerator(){return l(this,arguments,(function*globGenerator_1(){const e=m.getOptions(this.options);const t=[];for(const a of this.patterns){t.push(a);if(e.implicitDescendants&&(a.trailingSeparator||a.segments[a.segments.length-1]!=="**")){t.push(new y.Pattern(a.negate,true,a.segments.concat("**")))}}const a=[];for(const e of h.getSearchPaths(t)){d.debug(`Search path '${e}'`);try{yield p(c.promises.lstat(e))}catch(e){if(e.code==="ENOENT"){continue}throw e}a.unshift(new v.SearchState(e,1))}const r=[];while(a.length){const i=a.pop();const n=h.match(t,i.path);const s=!!n||h.partialMatch(t,i.path);if(!n&&!s){continue}const o=yield p(DefaultGlobber.stat(i,e,r));if(!o){continue}if(o.isDirectory()){if(n&g.MatchKind.Directory){yield yield p(i.path)}else if(!s){continue}const e=i.level+1;const t=(yield p(c.promises.readdir(i.path))).map((t=>new v.SearchState(u.join(i.path,t),e)));a.push(...t.reverse())}else if(n&g.MatchKind.File){yield yield p(i.path)}}}))}static create(e,t){return s(this,void 0,void 0,(function*(){const a=new DefaultGlobber(t);if(b){e=e.replace(/\r\n/g,"\n");e=e.replace(/\r/g,"\n")}const r=e.split("\n").map((e=>e.trim()));for(const e of r){if(!e||e.startsWith("#")){continue}else{a.patterns.push(new y.Pattern(e))}}a.searchPaths.push(...h.getSearchPaths(a.patterns));return a}))}static stat(e,t,a){return s(this,void 0,void 0,(function*(){let r;if(t.followSymbolicLinks){try{r=yield c.promises.stat(e.path)}catch(a){if(a.code==="ENOENT"){if(t.omitBrokenSymbolicLinks){d.debug(`Broken symlink '${e.path}'`);return undefined}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw a}}else{r=yield c.promises.lstat(e.path)}if(r.isDirectory()&&t.followSymbolicLinks){const t=yield c.promises.realpath(e.path);while(a.length>=e.level){a.pop()}if(a.some((e=>e===t))){d.debug(`Symlink cycle detected for path '${e.path}' and realpath '${t}'`);return undefined}a.push(t)}return r}))}}t.DefaultGlobber=DefaultGlobber},1063:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MatchKind=void 0;var a;(function(e){e[e["None"]=0]="None";e[e["Directory"]=1]="Directory";e[e["File"]=2]="File";e[e["All"]=3]="All"})(a=t.MatchKind||(t.MatchKind={}))},1849:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.safeTrimTrailingSeparator=t.normalizeSeparators=t.hasRoot=t.hasAbsoluteRoot=t.ensureAbsoluteRoot=t.dirname=void 0;const o=n(a(1017));const p=s(a(9491));const l=process.platform==="win32";function dirname(e){e=safeTrimTrailingSeparator(e);if(l&&/^\\\\[^\\]+(\\[^\\]+)?$/.test(e)){return e}let t=o.dirname(e);if(l&&/^\\\\[^\\]+\\[^\\]+\\$/.test(t)){t=safeTrimTrailingSeparator(t)}return t}t.dirname=dirname;function ensureAbsoluteRoot(e,t){p.default(e,`ensureAbsoluteRoot parameter 'root' must not be empty`);p.default(t,`ensureAbsoluteRoot parameter 'itemPath' must not be empty`);if(hasAbsoluteRoot(t)){return t}if(l){if(t.match(/^[A-Z]:[^\\/]|^[A-Z]:$/i)){let e=process.cwd();p.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);if(t[0].toUpperCase()===e[0].toUpperCase()){if(t.length===2){return`${t[0]}:\\${e.substr(3)}`}else{if(!e.endsWith("\\")){e+="\\"}return`${t[0]}:\\${e.substr(3)}${t.substr(2)}`}}else{return`${t[0]}:\\${t.substr(2)}`}}else if(normalizeSeparators(t).match(/^\\$|^\\[^\\]/)){const e=process.cwd();p.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);return`${e[0]}:\\${t.substr(1)}`}}p.default(hasAbsoluteRoot(e),`ensureAbsoluteRoot parameter 'root' must have an absolute root`);if(e.endsWith("/")||l&&e.endsWith("\\")){}else{e+=o.sep}return e+t}t.ensureAbsoluteRoot=ensureAbsoluteRoot;function hasAbsoluteRoot(e){p.default(e,`hasAbsoluteRoot parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(l){return e.startsWith("\\\\")||/^[A-Z]:\\/i.test(e)}return e.startsWith("/")}t.hasAbsoluteRoot=hasAbsoluteRoot;function hasRoot(e){p.default(e,`isRooted parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(l){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.hasRoot=hasRoot;function normalizeSeparators(e){e=e||"";if(l){e=e.replace(/\//g,"\\");const t=/^\\\\+[^\\]/.test(e);return(t?"\\":"")+e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}t.normalizeSeparators=normalizeSeparators;function safeTrimTrailingSeparator(e){if(!e){return""}e=normalizeSeparators(e);if(!e.endsWith(o.sep)){return e}if(e===o.sep){return e}if(l&&/^[A-Z]:\\$/i.test(e)){return e}return e.substr(0,e.length-1)}t.safeTrimTrailingSeparator=safeTrimTrailingSeparator},6836:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Path=void 0;const o=n(a(1017));const p=n(a(1849));const l=s(a(9491));const d=process.platform==="win32";class Path{constructor(e){this.segments=[];if(typeof e==="string"){l.default(e,`Parameter 'itemPath' must not be empty`);e=p.safeTrimTrailingSeparator(e);if(!p.hasRoot(e)){this.segments=e.split(o.sep)}else{let t=e;let a=p.dirname(t);while(a!==t){const e=o.basename(t);this.segments.unshift(e);t=a;a=p.dirname(t)}this.segments.unshift(t)}}else{l.default(e.length>0,`Parameter 'itemPath' must not be an empty array`);for(let t=0;t!e.negate));const t={};for(const a of e){const e=p?a.searchPath.toUpperCase():a.searchPath;t[e]="candidate"}const a=[];for(const r of e){const e=p?r.searchPath.toUpperCase():r.searchPath;if(t[e]==="included"){continue}let i=false;let n=e;let o=s.dirname(n);while(o!==n){if(t[o]){i=true;break}n=o;o=s.dirname(n)}if(!i){a.push(r.searchPath);t[e]="included"}}return a}t.getSearchPaths=getSearchPaths;function match(e,t){let a=o.MatchKind.None;for(const r of e){if(r.negate){a&=~r.match(t)}else{a|=r.match(t)}}return a}t.match=match;function partialMatch(e,t){return e.some((e=>!e.negate&&e.partialMatch(t)))}t.partialMatch=partialMatch},4536:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Pattern=void 0;const o=n(a(2037));const p=n(a(1017));const l=n(a(1849));const d=s(a(9491));const c=a(3973);const m=a(1063);const u=a(6836);const h=process.platform==="win32";class Pattern{constructor(e,t=false,a,r){this.negate=false;let i;if(typeof e==="string"){i=e.trim()}else{a=a||[];d.default(a.length,`Parameter 'segments' must not empty`);const t=Pattern.getLiteral(a[0]);d.default(t&&l.hasAbsoluteRoot(t),`Parameter 'segments' first element must be a root path`);i=new u.Path(a).toString().trim();if(e){i=`!${i}`}}while(i.startsWith("!")){this.negate=!this.negate;i=i.substr(1).trim()}i=Pattern.fixupPattern(i,r);this.segments=new u.Path(i).segments;this.trailingSeparator=l.normalizeSeparators(i).endsWith(p.sep);i=l.safeTrimTrailingSeparator(i);let n=false;const s=this.segments.map((e=>Pattern.getLiteral(e))).filter((e=>!n&&!(n=e==="")));this.searchPath=new u.Path(s).toString();this.rootRegExp=new RegExp(Pattern.regExpEscape(s[0]),h?"i":"");this.isImplicitPattern=t;const o={dot:true,nobrace:true,nocase:h,nocomment:true,noext:true,nonegate:true};i=h?i.replace(/\\/g,"/"):i;this.minimatch=new c.Minimatch(i,o)}match(e){if(this.segments[this.segments.length-1]==="**"){e=l.normalizeSeparators(e);if(!e.endsWith(p.sep)&&this.isImplicitPattern===false){e=`${e}${p.sep}`}}else{e=l.safeTrimTrailingSeparator(e)}if(this.minimatch.match(e)){return this.trailingSeparator?m.MatchKind.Directory:m.MatchKind.All}return m.MatchKind.None}partialMatch(e){e=l.safeTrimTrailingSeparator(e);if(l.dirname(e)===e){return this.rootRegExp.test(e)}return this.minimatch.matchOne(e.split(h?/\\+/:/\/+/),this.minimatch.set[0],true)}static globEscape(e){return(h?e:e.replace(/\\/g,"\\\\")).replace(/(\[)(?=[^/]+\])/g,"[[]").replace(/\?/g,"[?]").replace(/\*/g,"[*]")}static fixupPattern(e,t){d.default(e,"pattern cannot be empty");const a=new u.Path(e).segments.map((e=>Pattern.getLiteral(e)));d.default(a.every(((e,t)=>(e!=="."||t===0)&&e!=="..")),`Invalid pattern '${e}'. Relative pathing '.' and '..' is not allowed.`);d.default(!l.hasRoot(e)||a[0],`Invalid pattern '${e}'. Root segment must not contain globs.`);e=l.normalizeSeparators(e);if(e==="."||e.startsWith(`.${p.sep}`)){e=Pattern.globEscape(process.cwd())+e.substr(1)}else if(e==="~"||e.startsWith(`~${p.sep}`)){t=t||o.homedir();d.default(t,"Unable to determine HOME directory");d.default(l.hasAbsoluteRoot(t),`Expected HOME directory to be a rooted path. Actual '${t}'`);e=Pattern.globEscape(t)+e.substr(1)}else if(h&&(e.match(/^[A-Z]:$/i)||e.match(/^[A-Z]:[^\\]/i))){let t=l.ensureAbsoluteRoot("C:\\dummy-root",e.substr(0,2));if(e.length>2&&!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(2)}else if(h&&(e==="\\"||e.match(/^\\[^\\]/))){let t=l.ensureAbsoluteRoot("C:\\dummy-root","\\");if(!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(1)}else{e=l.ensureAbsoluteRoot(Pattern.globEscape(process.cwd()),e)}return l.normalizeSeparators(e)}static getLiteral(e){let t="";for(let a=0;a=0){if(r.length>1){return""}if(r){t+=r;a=i;continue}}}t+=r}return t}static regExpEscape(e){return e.replace(/[[\\^$.|?*+()]/g,"\\$&")}}t.Pattern=Pattern},9117:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SearchState=void 0;class SearchState{constructor(e,t){this.path=e;this.level=t}}t.SearchState=SearchState},5526:function(e,t){"use strict";var a=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.PersonalAccessTokenCredentialHandler=t.BearerCredentialHandler=t.BasicCredentialHandler=void 0;class BasicCredentialHandler{constructor(e,t){this.username=e;this.password=t}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`${this.username}:${this.password}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.BasicCredentialHandler=BasicCredentialHandler;class BearerCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Bearer ${this.token}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.BearerCredentialHandler=BearerCredentialHandler;class PersonalAccessTokenCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`PAT:${this.token}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.PersonalAccessTokenCredentialHandler=PersonalAccessTokenCredentialHandler},6255:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.HttpClient=t.isHttps=t.HttpClientResponse=t.HttpClientError=t.getProxyUrl=t.MediaTypes=t.Headers=t.HttpCodes=void 0;const o=n(a(3685));const p=n(a(5687));const l=n(a(9835));const d=n(a(4294));var c;(function(e){e[e["OK"]=200]="OK";e[e["MultipleChoices"]=300]="MultipleChoices";e[e["MovedPermanently"]=301]="MovedPermanently";e[e["ResourceMoved"]=302]="ResourceMoved";e[e["SeeOther"]=303]="SeeOther";e[e["NotModified"]=304]="NotModified";e[e["UseProxy"]=305]="UseProxy";e[e["SwitchProxy"]=306]="SwitchProxy";e[e["TemporaryRedirect"]=307]="TemporaryRedirect";e[e["PermanentRedirect"]=308]="PermanentRedirect";e[e["BadRequest"]=400]="BadRequest";e[e["Unauthorized"]=401]="Unauthorized";e[e["PaymentRequired"]=402]="PaymentRequired";e[e["Forbidden"]=403]="Forbidden";e[e["NotFound"]=404]="NotFound";e[e["MethodNotAllowed"]=405]="MethodNotAllowed";e[e["NotAcceptable"]=406]="NotAcceptable";e[e["ProxyAuthenticationRequired"]=407]="ProxyAuthenticationRequired";e[e["RequestTimeout"]=408]="RequestTimeout";e[e["Conflict"]=409]="Conflict";e[e["Gone"]=410]="Gone";e[e["TooManyRequests"]=429]="TooManyRequests";e[e["InternalServerError"]=500]="InternalServerError";e[e["NotImplemented"]=501]="NotImplemented";e[e["BadGateway"]=502]="BadGateway";e[e["ServiceUnavailable"]=503]="ServiceUnavailable";e[e["GatewayTimeout"]=504]="GatewayTimeout"})(c=t.HttpCodes||(t.HttpCodes={}));var m;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(m=t.Headers||(t.Headers={}));var u;(function(e){e["ApplicationJson"]="application/json"})(u=t.MediaTypes||(t.MediaTypes={}));function getProxyUrl(e){const t=l.getProxyUrl(new URL(e));return t?t.href:""}t.getProxyUrl=getProxyUrl;const h=[c.MovedPermanently,c.ResourceMoved,c.SeeOther,c.TemporaryRedirect,c.PermanentRedirect];const g=[c.BadGateway,c.ServiceUnavailable,c.GatewayTimeout];const y=["OPTIONS","GET","DELETE","HEAD"];const v=10;const b=5;class HttpClientError extends Error{constructor(e,t){super(e);this.name="HttpClientError";this.statusCode=t;Object.setPrototypeOf(this,HttpClientError.prototype)}}t.HttpClientError=HttpClientError;class HttpClientResponse{constructor(e){this.message=e}readBody(){return s(this,void 0,void 0,(function*(){return new Promise((e=>s(this,void 0,void 0,(function*(){let t=Buffer.alloc(0);this.message.on("data",(e=>{t=Buffer.concat([t,e])}));this.message.on("end",(()=>{e(t.toString())}))}))))}))}readBodyBuffer(){return s(this,void 0,void 0,(function*(){return new Promise((e=>s(this,void 0,void 0,(function*(){const t=[];this.message.on("data",(e=>{t.push(e)}));this.message.on("end",(()=>{e(Buffer.concat(t))}))}))))}))}}t.HttpClientResponse=HttpClientResponse;function isHttps(e){const t=new URL(e);return t.protocol==="https:"}t.isHttps=isHttps;class HttpClient{constructor(e,t,a){this._ignoreSslError=false;this._allowRedirects=true;this._allowRedirectDowngrade=false;this._maxRedirects=50;this._allowRetries=false;this._maxRetries=1;this._keepAlive=false;this._disposed=false;this.userAgent=e;this.handlers=t||[];this.requestOptions=a;if(a){if(a.ignoreSslError!=null){this._ignoreSslError=a.ignoreSslError}this._socketTimeout=a.socketTimeout;if(a.allowRedirects!=null){this._allowRedirects=a.allowRedirects}if(a.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=a.allowRedirectDowngrade}if(a.maxRedirects!=null){this._maxRedirects=Math.max(a.maxRedirects,0)}if(a.keepAlive!=null){this._keepAlive=a.keepAlive}if(a.allowRetries!=null){this._allowRetries=a.allowRetries}if(a.maxRetries!=null){this._maxRetries=a.maxRetries}}}options(e,t){return s(this,void 0,void 0,(function*(){return this.request("OPTIONS",e,null,t||{})}))}get(e,t){return s(this,void 0,void 0,(function*(){return this.request("GET",e,null,t||{})}))}del(e,t){return s(this,void 0,void 0,(function*(){return this.request("DELETE",e,null,t||{})}))}post(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("POST",e,t,a||{})}))}patch(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("PATCH",e,t,a||{})}))}put(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("PUT",e,t,a||{})}))}head(e,t){return s(this,void 0,void 0,(function*(){return this.request("HEAD",e,null,t||{})}))}sendStream(e,t,a,r){return s(this,void 0,void 0,(function*(){return this.request(e,t,a,r)}))}getJson(e,t={}){return s(this,void 0,void 0,(function*(){t[m.Accept]=this._getExistingOrDefaultHeader(t,m.Accept,u.ApplicationJson);const a=yield this.get(e,t);return this._processResponse(a,this.requestOptions)}))}postJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.post(e,r,a);return this._processResponse(i,this.requestOptions)}))}putJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.put(e,r,a);return this._processResponse(i,this.requestOptions)}))}patchJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.patch(e,r,a);return this._processResponse(i,this.requestOptions)}))}request(e,t,a,r){return s(this,void 0,void 0,(function*(){if(this._disposed){throw new Error("Client has already been disposed.")}const i=new URL(t);let n=this._prepareRequest(e,i,r);const s=this._allowRetries&&y.includes(e)?this._maxRetries+1:1;let o=0;let p;do{p=yield this.requestRaw(n,a);if(p&&p.message&&p.message.statusCode===c.Unauthorized){let e;for(const t of this.handlers){if(t.canHandleAuthentication(p)){e=t;break}}if(e){return e.handleAuthentication(this,n,a)}else{return p}}let t=this._maxRedirects;while(p.message.statusCode&&h.includes(p.message.statusCode)&&this._allowRedirects&&t>0){const s=p.message.headers["location"];if(!s){break}const o=new URL(s);if(i.protocol==="https:"&&i.protocol!==o.protocol&&!this._allowRedirectDowngrade){throw new Error("Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.")}yield p.readBody();if(o.hostname!==i.hostname){for(const e in r){if(e.toLowerCase()==="authorization"){delete r[e]}}}n=this._prepareRequest(e,o,r);p=yield this.requestRaw(n,a);t--}if(!p.message.statusCode||!g.includes(p.message.statusCode)){return p}o+=1;if(o{function callbackForResult(e,t){if(e){r(e)}else if(!t){r(new Error("Unknown error"))}else{a(t)}}this.requestRawWithCallback(e,t,callbackForResult)}))}))}requestRawWithCallback(e,t,a){if(typeof t==="string"){if(!e.options.headers){e.options.headers={}}e.options.headers["Content-Length"]=Buffer.byteLength(t,"utf8")}let r=false;function handleResult(e,t){if(!r){r=true;a(e,t)}}const i=e.httpModule.request(e.options,(e=>{const t=new HttpClientResponse(e);handleResult(undefined,t)}));let n;i.on("socket",(e=>{n=e}));i.setTimeout(this._socketTimeout||3*6e4,(()=>{if(n){n.end()}handleResult(new Error(`Request timeout: ${e.options.path}`))}));i.on("error",(function(e){handleResult(e)}));if(t&&typeof t==="string"){i.write(t,"utf8")}if(t&&typeof t!=="string"){t.on("close",(function(){i.end()}));t.pipe(i)}else{i.end()}}getAgent(e){const t=new URL(e);return this._getAgent(t)}_prepareRequest(e,t,a){const r={};r.parsedUrl=t;const i=r.parsedUrl.protocol==="https:";r.httpModule=i?p:o;const n=i?443:80;r.options={};r.options.host=r.parsedUrl.hostname;r.options.port=r.parsedUrl.port?parseInt(r.parsedUrl.port):n;r.options.path=(r.parsedUrl.pathname||"")+(r.parsedUrl.search||"");r.options.method=e;r.options.headers=this._mergeHeaders(a);if(this.userAgent!=null){r.options.headers["user-agent"]=this.userAgent}r.options.agent=this._getAgent(r.parsedUrl);if(this.handlers){for(const e of this.handlers){e.prepareRequest(r.options)}}return r}_mergeHeaders(e){if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},lowercaseKeys(this.requestOptions.headers),lowercaseKeys(e||{}))}return lowercaseKeys(e||{})}_getExistingOrDefaultHeader(e,t,a){let r;if(this.requestOptions&&this.requestOptions.headers){r=lowercaseKeys(this.requestOptions.headers)[t]}return e[t]||r||a}_getAgent(e){let t;const a=l.getProxyUrl(e);const r=a&&a.hostname;if(this._keepAlive&&r){t=this._proxyAgent}if(this._keepAlive&&!r){t=this._agent}if(t){return t}const i=e.protocol==="https:";let n=100;if(this.requestOptions){n=this.requestOptions.maxSockets||o.globalAgent.maxSockets}if(a&&a.hostname){const e={maxSockets:n,keepAlive:this._keepAlive,proxy:Object.assign(Object.assign({},(a.username||a.password)&&{proxyAuth:`${a.username}:${a.password}`}),{host:a.hostname,port:a.port})};let r;const s=a.protocol==="https:";if(i){r=s?d.httpsOverHttps:d.httpsOverHttp}else{r=s?d.httpOverHttps:d.httpOverHttp}t=r(e);this._proxyAgent=t}if(this._keepAlive&&!t){const e={keepAlive:this._keepAlive,maxSockets:n};t=i?new p.Agent(e):new o.Agent(e);this._agent=t}if(!t){t=i?p.globalAgent:o.globalAgent}if(i&&this._ignoreSslError){t.options=Object.assign(t.options||{},{rejectUnauthorized:false})}return t}_performExponentialBackoff(e){return s(this,void 0,void 0,(function*(){e=Math.min(v,e);const t=b*Math.pow(2,e);return new Promise((e=>setTimeout((()=>e()),t)))}))}_processResponse(e,t){return s(this,void 0,void 0,(function*(){return new Promise(((a,r)=>s(this,void 0,void 0,(function*(){const i=e.message.statusCode||0;const n={statusCode:i,result:null,headers:{}};if(i===c.NotFound){a(n)}function dateTimeDeserializer(e,t){if(typeof t==="string"){const e=new Date(t);if(!isNaN(e.valueOf())){return e}}return t}let s;let o;try{o=yield e.readBody();if(o&&o.length>0){if(t&&t.deserializeDates){s=JSON.parse(o,dateTimeDeserializer)}else{s=JSON.parse(o)}n.result=s}n.headers=e.message.headers}catch(e){}if(i>299){let e;if(s&&s.message){e=s.message}else if(o&&o.length>0){e=o}else{e=`Failed request: (${i})`}const t=new HttpClientError(e,i);t.result=n.result;r(t)}else{a(n)}}))))}))}}t.HttpClient=HttpClient;const lowercaseKeys=e=>Object.keys(e).reduce(((t,a)=>(t[a.toLowerCase()]=e[a],t)),{})},9835:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.checkBypass=t.getProxyUrl=void 0;function getProxyUrl(e){const t=e.protocol==="https:";if(checkBypass(e)){return undefined}const a=(()=>{if(t){return process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{return process.env["http_proxy"]||process.env["HTTP_PROXY"]}})();if(a){try{return new URL(a)}catch(e){if(!a.startsWith("http://")&&!a.startsWith("https://"))return new URL(`http://${a}`)}}else{return undefined}}t.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}const t=e.hostname;if(isLoopbackAddress(t)){return true}const a=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!a){return false}let r;if(e.port){r=Number(e.port)}else if(e.protocol==="http:"){r=80}else if(e.protocol==="https:"){r=443}const i=[e.hostname.toUpperCase()];if(typeof r==="number"){i.push(`${i[0]}:${r}`)}for(const e of a.split(",").map((e=>e.trim().toUpperCase())).filter((e=>e))){if(e==="*"||i.some((t=>t===e||t.endsWith(`.${e}`)||e.startsWith(".")&&t.endsWith(`${e}`)))){return true}}return false}t.checkBypass=checkBypass;function isLoopbackAddress(e){const t=e.toLowerCase();return t==="localhost"||t.startsWith("127.")||t.startsWith("[::1]")||t.startsWith("[0:0:0:0:0:0:0:1]")}},1962:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o;Object.defineProperty(t,"__esModule",{value:true});t.getCmdPath=t.tryGetExecutablePath=t.isRooted=t.isDirectory=t.exists=t.READONLY=t.UV_FS_O_EXLOCK=t.IS_WINDOWS=t.unlink=t.symlink=t.stat=t.rmdir=t.rm=t.rename=t.readlink=t.readdir=t.open=t.mkdir=t.lstat=t.copyFile=t.chmod=void 0;const p=n(a(7147));const l=n(a(1017));o=p.promises,t.chmod=o.chmod,t.copyFile=o.copyFile,t.lstat=o.lstat,t.mkdir=o.mkdir,t.open=o.open,t.readdir=o.readdir,t.readlink=o.readlink,t.rename=o.rename,t.rm=o.rm,t.rmdir=o.rmdir,t.stat=o.stat,t.symlink=o.symlink,t.unlink=o.unlink;t.IS_WINDOWS=process.platform==="win32";t.UV_FS_O_EXLOCK=268435456;t.READONLY=p.constants.O_RDONLY;function exists(e){return s(this,void 0,void 0,(function*(){try{yield t.stat(e)}catch(e){if(e.code==="ENOENT"){return false}throw e}return true}))}t.exists=exists;function isDirectory(e,a=false){return s(this,void 0,void 0,(function*(){const r=a?yield t.stat(e):yield t.lstat(e);return r.isDirectory()}))}t.isDirectory=isDirectory;function isRooted(e){e=normalizeSeparators(e);if(!e){throw new Error('isRooted() parameter "p" cannot be empty')}if(t.IS_WINDOWS){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.isRooted=isRooted;function tryGetExecutablePath(e,a){return s(this,void 0,void 0,(function*(){let r=undefined;try{r=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(r&&r.isFile()){if(t.IS_WINDOWS){const t=l.extname(e).toUpperCase();if(a.some((e=>e.toUpperCase()===t))){return e}}else{if(isUnixExecutable(r)){return e}}}const i=e;for(const n of a){e=i+n;r=undefined;try{r=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(r&&r.isFile()){if(t.IS_WINDOWS){try{const a=l.dirname(e);const r=l.basename(e).toUpperCase();for(const i of yield t.readdir(a)){if(r===i.toUpperCase()){e=l.join(a,i);break}}}catch(t){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${t}`)}return e}else{if(isUnixExecutable(r)){return e}}}}return""}))}t.tryGetExecutablePath=tryGetExecutablePath;function normalizeSeparators(e){e=e||"";if(t.IS_WINDOWS){e=e.replace(/\//g,"\\");return e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}function isUnixExecutable(e){return(e.mode&1)>0||(e.mode&8)>0&&e.gid===process.getgid()||(e.mode&64)>0&&e.uid===process.getuid()}function getCmdPath(){var e;return(e=process.env["COMSPEC"])!==null&&e!==void 0?e:`cmd.exe`}t.getCmdPath=getCmdPath},7436:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.findInPath=t.which=t.mkdirP=t.rmRF=t.mv=t.cp=void 0;const o=a(9491);const p=n(a(1017));const l=n(a(1962));function cp(e,t,a={}){return s(this,void 0,void 0,(function*(){const{force:r,recursive:i,copySourceDirectory:n}=readCopyOptions(a);const s=(yield l.exists(t))?yield l.stat(t):null;if(s&&s.isFile()&&!r){return}const o=s&&s.isDirectory()&&n?p.join(t,p.basename(e)):t;if(!(yield l.exists(e))){throw new Error(`no such file or directory: ${e}`)}const d=yield l.stat(e);if(d.isDirectory()){if(!i){throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`)}else{yield cpDirRecursive(e,o,0,r)}}else{if(p.relative(e,o)===""){throw new Error(`'${o}' and '${e}' are the same file`)}yield copyFile(e,o,r)}}))}t.cp=cp;function mv(e,t,a={}){return s(this,void 0,void 0,(function*(){if(yield l.exists(t)){let r=true;if(yield l.isDirectory(t)){t=p.join(t,p.basename(e));r=yield l.exists(t)}if(r){if(a.force==null||a.force){yield rmRF(t)}else{throw new Error("Destination already exists")}}}yield mkdirP(p.dirname(t));yield l.rename(e,t)}))}t.mv=mv;function rmRF(e){return s(this,void 0,void 0,(function*(){if(l.IS_WINDOWS){if(/[*"<>|]/.test(e)){throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows')}}try{yield l.rm(e,{force:true,maxRetries:3,recursive:true,retryDelay:300})}catch(e){throw new Error(`File was unable to be removed ${e}`)}}))}t.rmRF=rmRF;function mkdirP(e){return s(this,void 0,void 0,(function*(){o.ok(e,"a path argument must be provided");yield l.mkdir(e,{recursive:true})}))}t.mkdirP=mkdirP;function which(e,t){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}if(t){const t=yield which(e,false);if(!t){if(l.IS_WINDOWS){throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`)}else{throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`)}}return t}const a=yield findInPath(e);if(a&&a.length>0){return a[0]}return""}))}t.which=which;function findInPath(e){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}const t=[];if(l.IS_WINDOWS&&process.env["PATHEXT"]){for(const e of process.env["PATHEXT"].split(p.delimiter)){if(e){t.push(e)}}}if(l.isRooted(e)){const a=yield l.tryGetExecutablePath(e,t);if(a){return[a]}return[]}if(e.includes(p.sep)){return[]}const a=[];if(process.env.PATH){for(const e of process.env.PATH.split(p.delimiter)){if(e){a.push(e)}}}const r=[];for(const i of a){const a=yield l.tryGetExecutablePath(p.join(i,e),t);if(a){r.push(a)}}return r}))}t.findInPath=findInPath;function readCopyOptions(e){const t=e.force==null?true:e.force;const a=Boolean(e.recursive);const r=e.copySourceDirectory==null?true:Boolean(e.copySourceDirectory);return{force:t,recursive:a,copySourceDirectory:r}}function cpDirRecursive(e,t,a,r){return s(this,void 0,void 0,(function*(){if(a>=255)return;a++;yield mkdirP(t);const i=yield l.readdir(e);for(const n of i){const i=`${e}/${n}`;const s=`${t}/${n}`;const o=yield l.lstat(i);if(o.isDirectory()){yield cpDirRecursive(i,s,a,r)}else{yield copyFile(i,s,r)}}yield l.chmod(t,(yield l.stat(e)).mode)}))}function copyFile(e,t,a){return s(this,void 0,void 0,(function*(){if((yield l.lstat(e)).isSymbolicLink()){try{yield l.lstat(t);yield l.unlink(t)}catch(e){if(e.code==="EPERM"){yield l.chmod(t,"0666");yield l.unlink(t)}}const a=yield l.readlink(e);yield l.symlink(a,t,l.IS_WINDOWS?"junction":null)}else if(!(yield l.exists(t))||a){yield l.copyFile(e,t)}}))}},2473:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t._readLinuxVersionFile=t._getOsVersion=t._findMatch=void 0;const o=n(a(5911));const p=a(2186);const l=a(2037);const d=a(2081);const c=a(7147);function _findMatch(t,a,r,i){return s(this,void 0,void 0,(function*(){const n=l.platform();let s;let d;let c;for(const s of r){const r=s.version;p.debug(`check ${r} satisfies ${t}`);if(o.satisfies(r,t)&&(!a||s.stable===a)){c=s.files.find((t=>{p.debug(`${t.arch}===${i} && ${t.platform}===${n}`);let a=t.arch===i&&t.platform===n;if(a&&t.platform_version){const r=e.exports._getOsVersion();if(r===t.platform_version){a=true}else{a=o.satisfies(r,t.platform_version)}}return a}));if(c){p.debug(`matched ${s.version}`);d=s;break}}}if(d&&c){s=Object.assign({},d);s.files=[c]}return s}))}t._findMatch=_findMatch;function _getOsVersion(){const t=l.platform();let a="";if(t==="darwin"){a=d.execSync("sw_vers -productVersion").toString()}else if(t==="linux"){const t=e.exports._readLinuxVersionFile();if(t){const e=t.split("\n");for(const t of e){const e=t.split("=");if(e.length===2&&(e[0].trim()==="VERSION_ID"||e[0].trim()==="DISTRIB_RELEASE")){a=e[1].trim().replace(/^"/,"").replace(/"$/,"");break}}}}return a}t._getOsVersion=_getOsVersion;function _readLinuxVersionFile(){const e="/etc/lsb-release";const t="/etc/os-release";let a="";if(c.existsSync(e)){a=c.readFileSync(e).toString()}else if(c.existsSync(t)){a=c.readFileSync(t).toString()}return a}t._readLinuxVersionFile=_readLinuxVersionFile},8279:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.RetryHelper=void 0;const o=n(a(2186));class RetryHelper{constructor(e,t,a){if(e<1){throw new Error("max attempts should be greater than or equal to 1")}this.maxAttempts=e;this.minSeconds=Math.floor(t);this.maxSeconds=Math.floor(a);if(this.minSeconds>this.maxSeconds){throw new Error("min seconds should be less than or equal to max seconds")}}execute(e,t){return s(this,void 0,void 0,(function*(){let a=1;while(asetTimeout(t,e*1e3)))}))}}t.RetryHelper=RetryHelper},7784:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.evaluateVersions=t.isExplicitVersion=t.findFromManifest=t.getManifestFromRepo=t.findAllVersions=t.find=t.cacheFile=t.cacheDir=t.extractZip=t.extractXar=t.extractTar=t.extract7z=t.downloadTool=t.HTTPError=void 0;const p=n(a(2186));const l=n(a(7436));const d=n(a(7147));const c=n(a(2473));const m=n(a(2037));const u=n(a(1017));const h=n(a(6255));const g=n(a(5911));const y=n(a(2781));const v=n(a(3837));const b=a(9491);const x=o(a(7468));const w=a(1514);const S=a(8279);class HTTPError extends Error{constructor(e){super(`Unexpected HTTP response: ${e}`);this.httpStatusCode=e;Object.setPrototypeOf(this,new.target.prototype)}}t.HTTPError=HTTPError;const N=process.platform==="win32";const T=process.platform==="darwin";const E="actions/tool-cache";function downloadTool(e,t,a,r){return s(this,void 0,void 0,(function*(){t=t||u.join(_getTempDirectory(),x.default());yield l.mkdirP(u.dirname(t));p.debug(`Downloading ${e}`);p.debug(`Destination ${t}`);const i=3;const n=_getGlobal("TEST_DOWNLOAD_TOOL_RETRY_MIN_SECONDS",10);const o=_getGlobal("TEST_DOWNLOAD_TOOL_RETRY_MAX_SECONDS",20);const d=new S.RetryHelper(i,n,o);return yield d.execute((()=>s(this,void 0,void 0,(function*(){return yield downloadToolAttempt(e,t||"",a,r)}))),(e=>{if(e instanceof HTTPError&&e.httpStatusCode){if(e.httpStatusCode<500&&e.httpStatusCode!==408&&e.httpStatusCode!==429){return false}}return true}))}))}t.downloadTool=downloadTool;function downloadToolAttempt(e,t,a,r){return s(this,void 0,void 0,(function*(){if(d.existsSync(t)){throw new Error(`Destination file path ${t} already exists`)}const i=new h.HttpClient(E,[],{allowRetries:false});if(a){p.debug("set auth");if(r===undefined){r={}}r.authorization=a}const n=yield i.get(e,r);if(n.message.statusCode!==200){const t=new HTTPError(n.message.statusCode);p.debug(`Failed to download from "${e}". Code(${n.message.statusCode}) Message(${n.message.statusMessage})`);throw t}const s=v.promisify(y.pipeline);const o=_getGlobal("TEST_DOWNLOAD_TOOL_RESPONSE_MESSAGE_FACTORY",(()=>n.message));const c=o();let m=false;try{yield s(c,d.createWriteStream(t));p.debug("download complete");m=true;return t}finally{if(!m){p.debug("download failed");try{yield l.rmRF(t)}catch(e){p.debug(`Failed to delete '${t}'. ${e.message}`)}}}}))}function extract7z(e,t,a){return s(this,void 0,void 0,(function*(){b.ok(N,"extract7z() not supported on current OS");b.ok(e,'parameter "file" is required');t=yield _createExtractFolder(t);const r=process.cwd();process.chdir(t);if(a){try{const t=p.isDebug()?"-bb1":"-bb0";const i=["x",t,"-bd","-sccUTF-8",e];const n={silent:true};yield w.exec(`"${a}"`,i,n)}finally{process.chdir(r)}}else{const a=u.join(__dirname,"..","scripts","Invoke-7zdec.ps1").replace(/'/g,"''").replace(/"|\n|\r/g,"");const i=e.replace(/'/g,"''").replace(/"|\n|\r/g,"");const n=t.replace(/'/g,"''").replace(/"|\n|\r/g,"");const s=`& '${a}' -Source '${i}' -Target '${n}'`;const o=["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",s];const p={silent:true};try{const e=yield l.which("powershell",true);yield w.exec(`"${e}"`,o,p)}finally{process.chdir(r)}}return t}))}t.extract7z=extract7z;function extractTar(e,t,a="xz"){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'file' is required")}t=yield _createExtractFolder(t);p.debug("Checking tar --version");let r="";yield w.exec("tar --version",[],{ignoreReturnCode:true,silent:true,listeners:{stdout:e=>r+=e.toString(),stderr:e=>r+=e.toString()}});p.debug(r.trim());const i=r.toUpperCase().includes("GNU TAR");let n;if(a instanceof Array){n=a}else{n=[a]}if(p.isDebug()&&!a.includes("v")){n.push("-v")}let s=t;let o=e;if(N&&i){n.push("--force-local");s=t.replace(/\\/g,"/");o=e.replace(/\\/g,"/")}if(i){n.push("--warning=no-unknown-keyword");n.push("--overwrite")}n.push("-C",s,"-f",o);yield w.exec(`tar`,n);return t}))}t.extractTar=extractTar;function extractXar(e,t,a=[]){return s(this,void 0,void 0,(function*(){b.ok(T,"extractXar() not supported on current OS");b.ok(e,'parameter "file" is required');t=yield _createExtractFolder(t);let r;if(a instanceof Array){r=a}else{r=[a]}r.push("-x","-C",t,"-f",e);if(p.isDebug()){r.push("-v")}const i=yield l.which("xar",true);yield w.exec(`"${i}"`,_unique(r));return t}))}t.extractXar=extractXar;function extractZip(e,t){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'file' is required")}t=yield _createExtractFolder(t);if(N){yield extractZipWin(e,t)}else{yield extractZipNix(e,t)}return t}))}t.extractZip=extractZip;function extractZipWin(e,t){return s(this,void 0,void 0,(function*(){const a=e.replace(/'/g,"''").replace(/"|\n|\r/g,"");const r=t.replace(/'/g,"''").replace(/"|\n|\r/g,"");const i=yield l.which("pwsh",false);if(i){const e=[`$ErrorActionPreference = 'Stop' ;`,`try { Add-Type -AssemblyName System.IO.Compression.ZipFile } catch { } ;`,`try { [System.IO.Compression.ZipFile]::ExtractToDirectory('${a}', '${r}', $true) }`,`catch { if (($_.Exception.GetType().FullName -eq 'System.Management.Automation.MethodException') -or ($_.Exception.GetType().FullName -eq 'System.Management.Automation.RuntimeException') ){ Expand-Archive -LiteralPath '${a}' -DestinationPath '${r}' -Force } else { throw $_ } } ;`].join(" ");const t=["-NoLogo","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",e];p.debug(`Using pwsh at path: ${i}`);yield w.exec(`"${i}"`,t)}else{const e=[`$ErrorActionPreference = 'Stop' ;`,`try { Add-Type -AssemblyName System.IO.Compression.FileSystem } catch { } ;`,`if ((Get-Command -Name Expand-Archive -Module Microsoft.PowerShell.Archive -ErrorAction Ignore)) { Expand-Archive -LiteralPath '${a}' -DestinationPath '${r}' -Force }`,`else {[System.IO.Compression.ZipFile]::ExtractToDirectory('${a}', '${r}', $true) }`].join(" ");const t=["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",e];const i=yield l.which("powershell",true);p.debug(`Using powershell at path: ${i}`);yield w.exec(`"${i}"`,t)}}))}function extractZipNix(e,t){return s(this,void 0,void 0,(function*(){const a=yield l.which("unzip",true);const r=[e];if(!p.isDebug()){r.unshift("-q")}r.unshift("-o");yield w.exec(`"${a}"`,r,{cwd:t})}))}function cacheDir(e,t,a,r){return s(this,void 0,void 0,(function*(){a=g.clean(a)||a;r=r||m.arch();p.debug(`Caching tool ${t} ${a} ${r}`);p.debug(`source dir: ${e}`);if(!d.statSync(e).isDirectory()){throw new Error("sourceDir is not a directory")}const i=yield _createToolPath(t,a,r);for(const t of d.readdirSync(e)){const a=u.join(e,t);yield l.cp(a,i,{recursive:true})}_completeToolPath(t,a,r);return i}))}t.cacheDir=cacheDir;function cacheFile(e,t,a,r,i){return s(this,void 0,void 0,(function*(){r=g.clean(r)||r;i=i||m.arch();p.debug(`Caching tool ${a} ${r} ${i}`);p.debug(`source file: ${e}`);if(!d.statSync(e).isFile()){throw new Error("sourceFile is not a file")}const n=yield _createToolPath(a,r,i);const s=u.join(n,t);p.debug(`destination file ${s}`);yield l.cp(e,s);_completeToolPath(a,r,i);return n}))}t.cacheFile=cacheFile;function find(e,t,a){if(!e){throw new Error("toolName parameter is required")}if(!t){throw new Error("versionSpec parameter is required")}a=a||m.arch();if(!isExplicitVersion(t)){const r=findAllVersions(e,a);const i=evaluateVersions(r,t);t=i}let r="";if(t){t=g.clean(t)||"";const i=u.join(_getCacheDirectory(),e,t,a);p.debug(`checking cache: ${i}`);if(d.existsSync(i)&&d.existsSync(`${i}.complete`)){p.debug(`Found tool in cache ${e} ${t} ${a}`);r=i}else{p.debug("not found")}}return r}t.find=find;function findAllVersions(e,t){const a=[];t=t||m.arch();const r=u.join(_getCacheDirectory(),e);if(d.existsSync(r)){const e=d.readdirSync(r);for(const i of e){if(isExplicitVersion(i)){const e=u.join(r,i,t||"");if(d.existsSync(e)&&d.existsSync(`${e}.complete`)){a.push(i)}}}}return a}t.findAllVersions=findAllVersions;function getManifestFromRepo(e,t,a,r="master"){return s(this,void 0,void 0,(function*(){let i=[];const n=`https://api.github.com/repos/${e}/${t}/git/trees/${r}`;const s=new h.HttpClient("tool-cache");const o={};if(a){p.debug("set auth");o.authorization=a}const l=yield s.getJson(n,o);if(!l.result){return i}let d="";for(const e of l.result.tree){if(e.path==="versions-manifest.json"){d=e.url;break}}o["accept"]="application/vnd.github.VERSION.raw";let c=yield(yield s.get(d,o)).readBody();if(c){c=c.replace(/^\uFEFF/,"");try{i=JSON.parse(c)}catch(e){p.debug("Invalid json")}}return i}))}t.getManifestFromRepo=getManifestFromRepo;function findFromManifest(e,t,a,r=m.arch()){return s(this,void 0,void 0,(function*(){const i=yield c._findMatch(e,t,a,r);return i}))}t.findFromManifest=findFromManifest;function _createExtractFolder(e){return s(this,void 0,void 0,(function*(){if(!e){e=u.join(_getTempDirectory(),x.default())}yield l.mkdirP(e);return e}))}function _createToolPath(e,t,a){return s(this,void 0,void 0,(function*(){const r=u.join(_getCacheDirectory(),e,g.clean(t)||t,a||"");p.debug(`destination ${r}`);const i=`${r}.complete`;yield l.rmRF(r);yield l.rmRF(i);yield l.mkdirP(r);return r}))}function _completeToolPath(e,t,a){const r=u.join(_getCacheDirectory(),e,g.clean(t)||t,a||"");const i=`${r}.complete`;d.writeFileSync(i,"");p.debug("finished caching tool")}function isExplicitVersion(e){const t=g.clean(e)||"";p.debug(`isExplicit: ${t}`);const a=g.valid(t)!=null;p.debug(`explicit? ${a}`);return a}t.isExplicitVersion=isExplicitVersion;function evaluateVersions(e,t){let a="";p.debug(`evaluating ${e.length} versions`);e=e.sort(((e,t)=>{if(g.gt(e,t)){return 1}return-1}));for(let r=e.length-1;r>=0;r--){const i=e[r];const n=g.satisfies(i,t);if(n){a=i;break}}if(a){p.debug(`matched: ${a}`)}else{p.debug("match not found")}return a}t.evaluateVersions=evaluateVersions;function _getCacheDirectory(){const e=process.env["RUNNER_TOOL_CACHE"]||"";b.ok(e,"Expected RUNNER_TOOL_CACHE to be defined");return e}function _getTempDirectory(){const e=process.env["RUNNER_TEMP"]||"";b.ok(e,"Expected RUNNER_TEMP to be defined");return e}function _getGlobal(e,t){const a=global[e];return a!==undefined?a:t}function _unique(e){return Array.from(new Set(e))}},7701:e=>{var t=[];for(var a=0;a<256;++a){t[a]=(a+256).toString(16).substr(1)}function bytesToUuid(e,a){var r=a||0;var i=t;return[i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]]].join("")}e.exports=bytesToUuid},7269:(e,t,a)=>{var r=a(6113);e.exports=function nodeRNG(){return r.randomBytes(16)}},7468:(e,t,a)=>{var r=a(7269);var i=a(7701);function v4(e,t,a){var n=t&&a||0;if(typeof e=="string"){t=e==="binary"?new Array(16):null;e=null}e=e||{};var s=e.random||(e.rng||r)();s[6]=s[6]&15|64;s[8]=s[8]&63|128;if(t){for(var o=0;o<16;++o){t[n+o]=s[o]}}return t||i(s)}e.exports=v4},2557:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a=new WeakMap;const r=new WeakMap;class AbortSignal{constructor(){this.onabort=null;a.set(this,[]);r.set(this,false)}get aborted(){if(!r.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}return r.get(this)}static get none(){return new AbortSignal}addEventListener(e,t){if(!a.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}const r=a.get(this);r.push(t)}removeEventListener(e,t){if(!a.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}const r=a.get(this);const i=r.indexOf(t);if(i>-1){r.splice(i,1)}}dispatchEvent(e){throw new Error("This is a stub dispatchEvent implementation that should not be used. It only exists for type-checking purposes.")}}function abortSignal(e){if(e.aborted){return}if(e.onabort){e.onabort.call(e)}const t=a.get(e);if(t){t.slice().forEach((t=>{t.call(e,{type:"abort"})}))}r.set(e,true)}class AbortError extends Error{constructor(e){super(e);this.name="AbortError"}}class AbortController{constructor(e){this._signal=new AbortSignal;if(!e){return}if(!Array.isArray(e)){e=arguments}for(const t of e){if(t.aborted){this.abort()}else{t.addEventListener("abort",(()=>{this.abort()}))}}}get signal(){return this._signal}abort(){abortSignal(this._signal)}static timeout(e){const t=new AbortSignal;const a=setTimeout(abortSignal,e,t);if(typeof a.unref==="function"){a.unref()}return t}}t.AbortController=AbortController;t.AbortError=AbortError;t.AbortSignal=AbortSignal},9645:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(1333);class AzureKeyCredential{get key(){return this._key}constructor(e){if(!e){throw new Error("key must be a non-empty string")}this._key=e}update(e){this._key=e}}class AzureNamedKeyCredential{get key(){return this._key}get name(){return this._name}constructor(e,t){if(!e||!t){throw new TypeError("name and key must be non-empty strings")}this._name=e;this._key=t}update(e,t){if(!e||!t){throw new TypeError("newName and newKey must be non-empty strings")}this._name=e;this._key=t}}function isNamedKeyCredential(e){return r.isObjectWithProperties(e,["name","key"])&&typeof e.key==="string"&&typeof e.name==="string"}class AzureSASCredential{get signature(){return this._signature}constructor(e){if(!e){throw new Error("shared access signature must be a non-empty string")}this._signature=e}update(e){if(!e){throw new Error("shared access signature must be a non-empty string")}this._signature=e}}function isSASCredential(e){return r.isObjectWithProperties(e,["signature"])&&typeof e.signature==="string"}function isTokenCredential(e){const t=e;return t&&typeof t.getToken==="function"&&(t.signRequest===undefined||t.getToken.length>0)}t.AzureKeyCredential=AzureKeyCredential;t.AzureNamedKeyCredential=AzureNamedKeyCredential;t.AzureSASCredential=AzureSASCredential;t.isNamedKeyCredential=isNamedKeyCredential;t.isSASCredential=isSASCredential;t.isTokenCredential=isTokenCredential},4607:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5840);var i=a(3837);var n=a(2107);var s=a(6189);var o=a(1333);var p=a(3233);var l=a(9645);var d=a(2037);var c=a(3685);var m=a(5687);var u=a(2557);var h=a(4294);var g=a(2781);var y=a(6279);var v=a(467);var b=a(4175);function _interopDefaultLegacy(e){return e&&typeof e==="object"&&"default"in e?e:{default:e}}function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(a){if(a!=="default"){var r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:true,get:function(){return e[a]}})}}))}t["default"]=e;return Object.freeze(t)}var x=_interopNamespace(s);var w=_interopNamespace(d);var S=_interopNamespace(c);var N=_interopNamespace(m);var T=_interopNamespace(h);var E=_interopDefaultLegacy(y);var _=_interopDefaultLegacy(v);function getHeaderKey(e){return e.toLowerCase()}function isHttpHeadersLike(e){if(e&&typeof e==="object"){const t=e;if(typeof t.rawHeaders==="function"&&typeof t.clone==="function"&&typeof t.get==="function"&&typeof t.set==="function"&&typeof t.contains==="function"&&typeof t.remove==="function"&&typeof t.headersArray==="function"&&typeof t.headerValues==="function"&&typeof t.headerNames==="function"&&typeof t.toJson==="function"){return true}}return false}class HttpHeaders{constructor(e){this._headersMap={};if(e){for(const t in e){this.set(t,e[t])}}}set(e,t){this._headersMap[getHeaderKey(e)]={name:e,value:t.toString()}}get(e){const t=this._headersMap[getHeaderKey(e)];return!t?undefined:t.value}contains(e){return!!this._headersMap[getHeaderKey(e)]}remove(e){const t=this.contains(e);delete this._headersMap[getHeaderKey(e)];return t}rawHeaders(){return this.toJson({preserveCase:true})}headersArray(){const e=[];for(const t in this._headersMap){e.push(this._headersMap[t])}return e}headerNames(){const e=[];const t=this.headersArray();for(let a=0;a{a=a.then(e)}));return a}function promiseToCallback(e){if(typeof e.then!=="function"){throw new Error("The provided input is not a Promise.")}return t=>{e.then((e=>t(undefined,e))).catch((e=>{t(e)}))}}function promiseToServiceCallback(e){if(typeof e.then!=="function"){throw new Error("The provided input is not a Promise.")}return t=>{e.then((e=>process.nextTick(t,undefined,e.parsedBody,e.request,e))).catch((e=>{process.nextTick(t,e)}))}}function prepareXMLRootList(e,t,a,r){if(!Array.isArray(e)){e=[e]}if(!a||!r){return{[t]:e}}const i={[t]:e};i[C]={[a]:r};return i}function applyMixins(e,t){const a=e;t.forEach((e=>{Object.getOwnPropertyNames(e.prototype).forEach((t=>{a.prototype[t]=e.prototype[t]}))}))}const D=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function isDuration(e){return D.test(e)}function replaceAll(e,t,a){return!e||!t?e:e.split(t).join(a||"")}function isPrimitiveType(e){return typeof e!=="object"&&typeof e!=="function"||e===null}function getEnvironmentValue(e){if(process.env[e]){return process.env[e]}else if(process.env[e.toLowerCase()]){return process.env[e.toLowerCase()]}return undefined}function isObject(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}class Serializer{constructor(e={},t){this.modelMappers=e;this.isXML=t}validateConstraints(e,t,a){const failValidation=(e,r)=>{throw new Error(`"${a}" with value "${t}" should satisfy the constraint "${e}": ${r}.`)};if(e.constraints&&t!=undefined){const a=t;const{ExclusiveMaximum:r,ExclusiveMinimum:i,InclusiveMaximum:n,InclusiveMinimum:s,MaxItems:o,MaxLength:p,MinItems:l,MinLength:d,MultipleOf:c,Pattern:m,UniqueItems:u}=e.constraints;if(r!=undefined&&a>=r){failValidation("ExclusiveMaximum",r)}if(i!=undefined&&a<=i){failValidation("ExclusiveMinimum",i)}if(n!=undefined&&a>n){failValidation("InclusiveMaximum",n)}if(s!=undefined&&ao){failValidation("MaxItems",o)}if(p!=undefined&&h.length>p){failValidation("MaxLength",p)}if(l!=undefined&&h.lengtha.indexOf(e)!==t))){failValidation("UniqueItems",u)}}}serialize(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};let p={};const l=e.type.name;if(!a){a=e.serializedName}if(l.match(/^Sequence$/i)!==null){p=[]}if(e.isConstant){t=e.defaultValue}const{required:d,nullable:c}=e;if(d&&c&&t===undefined){throw new Error(`${a} cannot be undefined.`)}if(d&&!c&&t==undefined){throw new Error(`${a} cannot be null or undefined.`)}if(!d&&c===false&&t===null){throw new Error(`${a} cannot be null.`)}if(t==undefined){p=t}else{if(l.match(/^any$/i)!==null){p=t}else if(l.match(/^(Number|String|Boolean|Object|Stream|Uuid)$/i)!==null){p=serializeBasicTypes(l,a,t)}else if(l.match(/^Enum$/i)!==null){const r=e;p=serializeEnumType(a,r.type.allowedValues,t)}else if(l.match(/^(Date|DateTime|TimeSpan|DateTimeRfc1123|UnixTime)$/i)!==null){p=serializeDateTypes(l,t,a)}else if(l.match(/^ByteArray$/i)!==null){p=serializeByteArrayType(a,t)}else if(l.match(/^Base64Url$/i)!==null){p=serializeBase64UrlType(a,t)}else if(l.match(/^Sequence$/i)!==null){p=serializeSequenceType(this,e,t,a,Boolean(this.isXML),o)}else if(l.match(/^Dictionary$/i)!==null){p=serializeDictionaryType(this,e,t,a,Boolean(this.isXML),o)}else if(l.match(/^Composite$/i)!==null){p=serializeCompositeType(this,e,t,a,Boolean(this.isXML),o)}}return p}deserialize(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};if(t==undefined){if(this.isXML&&e.type.name==="Sequence"&&!e.xmlIsWrapped){t=[]}if(e.defaultValue!==undefined){t=e.defaultValue}return t}let p;const l=e.type.name;if(!a){a=e.serializedName}if(l.match(/^Composite$/i)!==null){p=deserializeCompositeType(this,e,t,a,o)}else{if(this.isXML){const e=o.xmlCharKey;const a=t;if(a[C]!=undefined&&a[e]!=undefined){t=a[e]}}if(l.match(/^Number$/i)!==null){p=parseFloat(t);if(isNaN(p)){p=t}}else if(l.match(/^Boolean$/i)!==null){if(t==="true"){p=true}else if(t==="false"){p=false}else{p=t}}else if(l.match(/^(String|Enum|Object|Stream|Uuid|TimeSpan|any)$/i)!==null){p=t}else if(l.match(/^(Date|DateTime|DateTimeRfc1123)$/i)!==null){p=new Date(t)}else if(l.match(/^UnixTime$/i)!==null){p=unixTimeToDate(t)}else if(l.match(/^ByteArray$/i)!==null){p=decodeString(t)}else if(l.match(/^Base64Url$/i)!==null){p=base64UrlToByteArray(t)}else if(l.match(/^Sequence$/i)!==null){p=deserializeSequenceType(this,e,t,a,o)}else if(l.match(/^Dictionary$/i)!==null){p=deserializeDictionaryType(this,e,t,a,o)}}if(e.isConstant){p=e.defaultValue}return p}}function trimEnd(e,t){let a=e.length;while(a-1>=0&&e[a-1]===t){--a}return e.substr(0,a)}function bufferToBase64Url(e){if(!e){return undefined}if(!(e instanceof Uint8Array)){throw new Error(`Please provide an input of type Uint8Array for converting to Base64Url.`)}const t=encodeByteArray(e);return trimEnd(t,"=").replace(/\+/g,"-").replace(/\//g,"_")}function base64UrlToByteArray(e){if(!e){return undefined}if(e&&typeof e.valueOf()!=="string"){throw new Error("Please provide an input of type string for converting to Uint8Array")}e=e.replace(/-/g,"+").replace(/_/g,"/");return decodeString(e)}function splitSerializeName(e){const t=[];let a="";if(e){const r=e.split(".");for(const e of r){if(e.charAt(e.length-1)==="\\"){a+=e.substr(0,e.length-1)+"."}else{a+=e;t.push(a);a=""}}}return t}function dateToUnixTime(e){if(!e){return undefined}if(typeof e.valueOf()==="string"){e=new Date(e)}return Math.floor(e.getTime()/1e3)}function unixTimeToDate(e){if(!e){return undefined}return new Date(e*1e3)}function serializeBasicTypes(e,t,a){if(a!==null&&a!==undefined){if(e.match(/^Number$/i)!==null){if(typeof a!=="number"){throw new Error(`${t} with value ${a} must be of type number.`)}}else if(e.match(/^String$/i)!==null){if(typeof a.valueOf()!=="string"){throw new Error(`${t} with value "${a}" must be of type string.`)}}else if(e.match(/^Uuid$/i)!==null){if(!(typeof a.valueOf()==="string"&&isValidUuid(a))){throw new Error(`${t} with value "${a}" must be of type string and a valid uuid.`)}}else if(e.match(/^Boolean$/i)!==null){if(typeof a!=="boolean"){throw new Error(`${t} with value ${a} must be of type boolean.`)}}else if(e.match(/^Stream$/i)!==null){const e=typeof a;if(e!=="string"&&e!=="function"&&!(a instanceof ArrayBuffer)&&!ArrayBuffer.isView(a)&&!((typeof Blob==="function"||typeof Blob==="object")&&a instanceof Blob)){throw new Error(`${t} must be a string, Blob, ArrayBuffer, ArrayBufferView, or a function returning NodeJS.ReadableStream.`)}}}return a}function serializeEnumType(e,t,a){if(!t){throw new Error(`Please provide a set of allowedValues to validate ${e} as an Enum Type.`)}const r=t.some((e=>{if(typeof e.valueOf()==="string"){return e.toLowerCase()===a.toLowerCase()}return e===a}));if(!r){throw new Error(`${a} is not a valid value for ${e}. The valid values are: ${JSON.stringify(t)}.`)}return a}function serializeByteArrayType(e,t){let a="";if(t!=undefined){if(!(t instanceof Uint8Array)){throw new Error(`${e} must be of type Uint8Array.`)}a=encodeByteArray(t)}return a}function serializeBase64UrlType(e,t){let a="";if(t!=undefined){if(!(t instanceof Uint8Array)){throw new Error(`${e} must be of type Uint8Array.`)}a=bufferToBase64Url(t)||""}return a}function serializeDateTypes(e,t,a){if(t!=undefined){if(e.match(/^Date$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in ISO8601 format.`)}t=t instanceof Date?t.toISOString().substring(0,10):new Date(t).toISOString().substring(0,10)}else if(e.match(/^DateTime$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in ISO8601 format.`)}t=t instanceof Date?t.toISOString():new Date(t).toISOString()}else if(e.match(/^DateTimeRfc1123$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in RFC-1123 format.`)}t=t instanceof Date?t.toUTCString():new Date(t).toUTCString()}else if(e.match(/^UnixTime$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in RFC-1123/ISO8601 format `+`for it to be serialized in UnixTime/Epoch format.`)}t=dateToUnixTime(t)}else if(e.match(/^TimeSpan$/i)!==null){if(!isDuration(t)){throw new Error(`${a} must be a string in ISO 8601 format. Instead was "${t}".`)}}}return t}function serializeSequenceType(e,t,a,r,i,n){if(!Array.isArray(a)){throw new Error(`${r} must be of type Array.`)}const s=t.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 ${r}.`)}const o=[];for(let t=0;te!==i));if(o){s[i]=e.serialize(p,a[i],r+'["'+i+'"]',n)}}}return s}return a}function getXmlObjectValue(e,t,a,r){if(!a||!e.xmlNamespace){return t}const i=e.xmlNamespacePrefix?`xmlns:${e.xmlNamespacePrefix}`:"xmlns";const n={[i]:e.xmlNamespace};if(["Composite"].includes(e.type.name)){if(t[C]){return t}else{const e=Object.assign({},t);e[C]=n;return e}}const s={};s[r.xmlCharKey]=t;s[C]=n;return s}function isSpecialXmlProperty(e,t){return[C,t.xmlCharKey].includes(e)}function deserializeCompositeType(e,t,a,r,i){var n,s;const o=(n=i.xmlCharKey)!==null&&n!==void 0?n:O;if(getPolymorphicDiscriminatorRecursively(e,t)){t=getPolymorphicMapper(e,t,a,"serializedName")}const p=resolveModelProperties(e,t,r);let l={};const d=[];for(const n of Object.keys(p)){const c=p[n];const m=splitSerializeName(p[n].serializedName);d.push(m[0]);const{serializedName:u,xmlName:h,xmlElementName:g}=c;let y=r;if(u!==""&&u!==undefined){y=r+"."+u}const v=c.headerCollectionPrefix;if(v){const t={};for(const r of Object.keys(a)){if(r.startsWith(v)){t[r.substring(v.length)]=e.deserialize(c.type.value,a[r],y,i)}d.push(r)}l[n]=t}else if(e.isXML){if(c.xmlIsAttribute&&a[C]){l[n]=e.deserialize(c,a[C][h],y,i)}else if(c.xmlIsMsText){if(a[o]!==undefined){l[n]=a[o]}else if(typeof a==="string"){l[n]=a}}else{const t=g||h||u;if(c.xmlIsWrapped){const t=a[h];const r=(s=t===null||t===void 0?void 0:t[g])!==null&&s!==void 0?s:[];l[n]=e.deserialize(c,r,y,i);d.push(h)}else{const r=a[t];l[n]=e.deserialize(c,r,y,i);d.push(t)}}}else{let r;let s=a;for(const e of m){if(!s)break;s=s[e]}r=s;const o=t.type.polymorphicDiscriminator;if(o&&n===o.clientName&&r==undefined){r=t.serializedName}let d;if(Array.isArray(a[n])&&p[n].serializedName===""){r=a[n];const t=e.deserialize(c,r,y,i);for(const[e,a]of Object.entries(l)){if(!Object.prototype.hasOwnProperty.call(t,e)){t[e]=a}}l=t}else if(r!==undefined||c.defaultValue!==undefined){d=e.deserialize(c,r,y,i);l[n]=d}}}const c=t.type.additionalProperties;if(c){const isAdditionalProperty=e=>{for(const t in p){const a=splitSerializeName(p[t].serializedName);if(a[0]===e){return false}}return true};for(const t in a){if(isAdditionalProperty(t)){l[t]=e.deserialize(c,a[t],r+'["'+t+'"]',i)}}}else if(a){for(const e of Object.keys(a)){if(l[e]===undefined&&!d.includes(e)&&!isSpecialXmlProperty(e,i)){l[e]=a[e]}}}return l}function deserializeDictionaryType(e,t,a,r,i){const n=t.type.value;if(!n||typeof n!=="object"){throw new Error(`"value" metadata for a Dictionary must be defined in the `+`mapper and it must of type "object" in ${r}`)}if(a){const t={};for(const s of Object.keys(a)){t[s]=e.deserialize(n,a[s],r,i)}return t}return a}function deserializeSequenceType(e,t,a,r,i){const n=t.type.element;if(!n||typeof n!=="object"){throw new Error(`element" metadata for an Array must be defined in the `+`mapper and it must of type "object" in ${r}`)}if(a){if(!Array.isArray(a)){a=[a]}const t=[];for(let s=0;s0}keys(){return Object.keys(this._rawQuery)}set(e,t){const a=t;if(e){if(a!==undefined&&a!==null){const t=Array.isArray(a)?a:a.toString();this._rawQuery[e]=t}else{delete this._rawQuery[e]}}}get(e){return e?this._rawQuery[e]:undefined}toString(){let e="";for(const t in this._rawQuery){if(e){e+="&"}const a=this._rawQuery[t];if(Array.isArray(a)){const r=[];for(const e of a){r.push(`${t}=${e}`)}e+=r.join("&")}else{e+=`${t}=${a}`}}return e}static parse(e){const t=new URLQuery;if(e){if(e.startsWith("?")){e=e.substring(1)}let a="ParameterName";let r="";let i="";for(let n=0;nisAlphaNumericCharacter(e)))}function readUntilCharacter(e,...t){return readWhile(e,(e=>t.indexOf(e)===-1))}function nextScheme(e){const t=readWhileLetterOrDigit(e);e._currentToken=URLToken.scheme(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else{e._currentState="HOST"}}function nextSchemeOrHost(e){const t=readUntilCharacter(e,":","/","?");if(!hasCurrentCharacter(e)){e._currentToken=URLToken.host(t);e._currentState="DONE"}else if(getCurrentCharacter(e)===":"){if(peekCharacters(e,3)==="://"){e._currentToken=URLToken.scheme(t);e._currentState="HOST"}else{e._currentToken=URLToken.host(t);e._currentState="PORT"}}else{e._currentToken=URLToken.host(t);if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}}function nextHost(e){if(peekCharacters(e,3)==="://"){nextCharacter(e,3)}const t=readUntilCharacter(e,":","/","?");e._currentToken=URLToken.host(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else if(getCurrentCharacter(e)===":"){e._currentState="PORT"}else if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}function nextPort(e){if(getCurrentCharacter(e)===":"){nextCharacter(e)}const t=readUntilCharacter(e,"/","?");e._currentToken=URLToken.port(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}function nextPath(e){const t=readUntilCharacter(e,"?");e._currentToken=URLToken.path(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else{e._currentState="QUERY"}}function nextQuery(e){if(getCurrentCharacter(e)==="?"){nextCharacter(e)}const t=readRemaining(e);e._currentToken=URLToken.query(t);e._currentState="DONE"}function createProxyAgent(e,t,a){const r=URLBuilder.parse(t.host).getHost();if(!r){throw new Error("Expecting a non-empty host in proxy settings.")}if(!isValidPort(t.port)){throw new Error("Expecting a valid port number in the range of [0, 65535] in proxy settings.")}const i={proxy:{host:r,port:t.port,headers:a&&a.rawHeaders()||{}}};if(t.username&&t.password){i.proxy.proxyAuth=`${t.username}:${t.password}`}else if(t.username){i.proxy.proxyAuth=`${t.username}`}const n=isUrlHttps(e);const s=isUrlHttps(t.host);const o={isHttps:n,agent:createTunnel(n,s,i)};return o}function isUrlHttps(e){const t=URLBuilder.parse(e).getScheme()||"";return t.toLowerCase()==="https"}function createTunnel(e,t,a){if(e&&t){return T.httpsOverHttps(a)}else if(e&&!t){return T.httpsOverHttp(a)}else if(!e&&t){return T.httpOverHttps(a)}else{return T.httpOverHttp(a)}}function isValidPort(e){return 0<=e&&e<=65535}const I="REDACTED";const L=["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","WWW-Authenticate"];const M=["api-version"];class Sanitizer{constructor({allowedHeaderNames:e=[],allowedQueryParameters:t=[]}={}){e=Array.isArray(e)?L.concat(e):L;t=Array.isArray(t)?M.concat(t):M;this.allowedHeaderNames=new Set(e.map((e=>e.toLowerCase())));this.allowedQueryParameters=new Set(t.map((e=>e.toLowerCase())))}sanitize(e){const t=new Set;return JSON.stringify(e,((e,a)=>{if(a instanceof Error){return Object.assign(Object.assign({},a),{name:a.name,message:a.message})}if(e==="_headersMap"){return this.sanitizeHeaders(a)}else if(e==="url"){return this.sanitizeUrl(a)}else if(e==="query"){return this.sanitizeQuery(a)}else if(e==="body"){return undefined}else if(e==="response"){return undefined}else if(e==="operationSpec"){return undefined}else if(Array.isArray(a)||isObject(a)){if(t.has(a)){return"[Circular]"}t.add(a)}return a}),2)}sanitizeHeaders(e){return this.sanitizeObject(e,this.allowedHeaderNames,((e,t)=>e[t].value))}sanitizeQuery(e){return this.sanitizeObject(e,this.allowedQueryParameters,((e,t)=>e[t]))}sanitizeObject(e,t,a){if(typeof e!=="object"||e===null){return e}const r={};for(const i of Object.keys(e)){if(t.has(i.toLowerCase())){r[i]=a(e,i)}else{r[i]=I}}return r}sanitizeUrl(e){if(typeof e!=="string"||e===null){return e}const t=URLBuilder.parse(e);const a=t.getQuery();if(!a){return e}const r=URLQuery.parse(a);for(const e of r.keys()){if(!this.allowedQueryParameters.has(e.toLowerCase())){r.set(e,I)}}t.setQuery(r.toString());return t.toString()}}const B=i.inspect.custom;const k=new Sanitizer;class RestError extends Error{constructor(e,t,a,r,i){super(e);this.name="RestError";this.code=t;this.statusCode=a;this.request=r;this.response=i;Object.setPrototypeOf(this,RestError.prototype)}[B](){return`RestError: ${this.message} \n ${k.sanitize(this)}`}}RestError.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR";RestError.PARSE_ERROR="PARSE_ERROR";const z=p.createClientLogger("core-http");function getCachedAgent(e,t){return e?t.httpsAgent:t.httpAgent}class ReportTransform extends g.Transform{constructor(e){super();this.progressCallback=e;this.loadedBytes=0}_transform(e,t,a){this.push(e);this.loadedBytes+=e.length;this.progressCallback({loadedBytes:this.loadedBytes});a(undefined)}}function isReadableStream(e){return e&&typeof e.pipe==="function"}function isStreamComplete(e,t){return new Promise((a=>{e.once("close",(()=>{t===null||t===void 0?void 0:t.abort();a()}));e.once("end",a);e.once("error",a)}))}function parseHeaders(e){const t=new HttpHeaders;e.forEach(((e,a)=>{t.set(a,e)}));return t}class NodeFetchHttpClient{constructor(){this.proxyAgentMap=new Map;this.keepAliveAgents={}}async sendRequest(e){var t;if(!e&&typeof e!=="object"){throw new Error("'httpRequest' (WebResourceLike) cannot be null or undefined and must be of type object.")}const a=new u.AbortController;let r;if(e.abortSignal){if(e.abortSignal.aborted){throw new u.AbortError("The operation was aborted.")}r=e=>{if(e.type==="abort"){a.abort()}};e.abortSignal.addEventListener("abort",r)}if(e.timeout){setTimeout((()=>{a.abort()}),e.timeout)}if(e.formData){const t=e.formData;const a=new E["default"];const appendFormValue=(e,t)=>{if(typeof t==="function"){t=t()}if(t&&Object.prototype.hasOwnProperty.call(t,"value")&&Object.prototype.hasOwnProperty.call(t,"options")){a.append(e,t.value,t.options)}else{a.append(e,t)}};for(const e of Object.keys(t)){const a=t[e];if(Array.isArray(a)){for(let t=0;t{var t;(t=e.abortSignal)===null||t===void 0?void 0:t.removeEventListener("abort",r);return})).catch((e=>{z.warning("Error when cleaning up abortListener on httpRequest",e)}))}}}getOrCreateAgent(e){var t;const a=isUrlHttps(e.url);if(e.proxySettings){const{host:r,port:i,username:n,password:s}=e.proxySettings;const o=`${r}:${i}:${n}:${s}`;const p=(t=this.proxyAgentMap.get(o))!==null&&t!==void 0?t:{};let l=getCachedAgent(a,p);if(l){return l}const d=createProxyAgent(e.url,e.proxySettings,e.headers);l=d.agent;if(d.isHttps){p.httpsAgent=d.agent}else{p.httpAgent=d.agent}this.proxyAgentMap.set(o,p);return l}else if(e.keepAlive){let t=getCachedAgent(a,this.keepAliveAgents);if(t){return t}const r={keepAlive:e.keepAlive};if(a){t=this.keepAliveAgents.httpsAgent=new N.Agent(r)}else{t=this.keepAliveAgents.httpAgent=new S.Agent(r)}return t}else{return a?N.globalAgent:S.globalAgent}}async fetch(e,t){return _["default"](e,t)}async prepareRequest(e){const t={};t.agent=this.getOrCreateAgent(e);t.compress=e.decompressResponse;return t}async processRequest(e){}}t.HttpPipelineLogLevel=void 0;(function(e){e[e["OFF"]=0]="OFF";e[e["ERROR"]=1]="ERROR";e[e["WARNING"]=2]="WARNING";e[e["INFO"]=3]="INFO"})(t.HttpPipelineLogLevel||(t.HttpPipelineLogLevel={}));function operationOptionsToRequestOptionsBase(e){const{requestOptions:t,tracingOptions:a}=e,r=n.__rest(e,["requestOptions","tracingOptions"]);let i=r;if(t){i=Object.assign(Object.assign({},i),t)}if(a){i.tracingContext=a.tracingContext;i.spanOptions=a===null||a===void 0?void 0:a.spanOptions}return i}class BaseRequestPolicy{constructor(e,t){this._nextPolicy=e;this._options=t}shouldLog(e){return this._options.shouldLog(e)}log(e,t){this._options.log(e,t)}}class RequestPolicyOptions{constructor(e){this._logger=e}shouldLog(e){return!!this._logger&&e!==t.HttpPipelineLogLevel.OFF&&e<=this._logger.minimumLogLevel}log(e,t){if(this._logger&&this.shouldLog(e)){this._logger.log(e,t)}}}const j={explicitCharkey:false,trim:false,normalize:false,normalizeTags:false,attrkey:C,explicitArray:true,ignoreAttrs:false,mergeAttrs:false,explicitRoot:true,validator:undefined,xmlns:false,explicitChildren:false,preserveChildrenOrder:false,childkey:"$$",charsAsChildren:false,includeWhiteChars:false,async:false,strict:true,attrNameProcessors:undefined,attrValueProcessors:undefined,tagNameProcessors:undefined,valueProcessors:undefined,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:true},doctype:undefined,renderOpts:{pretty:true,indent:" ",newline:"\n"},headless:false,chunkSize:1e4,emptyTag:"",cdata:false};const q=Object.assign({},j);q.explicitArray=false;const U=Object.assign({},j);U.explicitArray=false;U.renderOpts={pretty:false};function stringifyXML(e,t={}){var a;U.rootName=t.rootName;U.charkey=(a=t.xmlCharKey)!==null&&a!==void 0?a:O;const r=new x.Builder(U);return r.buildObject(e)}function parseXML(e,t={}){var a;q.explicitRoot=!!t.includeRoot;q.charkey=(a=t.xmlCharKey)!==null&&a!==void 0?a:O;const r=new x.Parser(q);return new Promise(((t,a)=>{if(!e){a(new Error("Document is empty"))}else{r.parseString(e,((e,r)=>{if(e){a(e)}else{t(r)}}))}}))}function deserializationPolicy(e,t){return{create:(a,r)=>new DeserializationPolicy(a,r,e,t)}}const H=["application/json","text/json"];const V=["application/xml","application/atom+xml"];const G={expectedContentTypes:{json:H,xml:V}};class DeserializationPolicy extends BaseRequestPolicy{constructor(e,t,a,r={}){var i;super(e,t);this.jsonContentTypes=a&&a.json||H;this.xmlContentTypes=a&&a.xml||V;this.xmlCharKey=(i=r.xmlCharKey)!==null&&i!==void 0?i:O}async sendRequest(e){return this._nextPolicy.sendRequest(e).then((e=>deserializeResponseBody(this.jsonContentTypes,this.xmlContentTypes,e,{xmlCharKey:this.xmlCharKey})))}}function getOperationResponse(e){let t;const a=e.request;const r=a.operationSpec;if(r){const i=a.operationResponseGetter;if(!i){t=r.responses[e.status]}else{t=i(r,e)}}return t}function shouldDeserializeResponse(e){const t=e.request.shouldDeserialize;let a;if(t===undefined){a=true}else if(typeof t==="boolean"){a=t}else{a=t(e)}return a}function deserializeResponseBody(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};return parse(e,t,a,o).then((e=>{if(!shouldDeserializeResponse(e)){return e}const t=e.request.operationSpec;if(!t||!t.responses){return e}const i=getOperationResponse(e);const{error:n,shouldReturnResponse:s}=handleErrorResponse(e,t,i);if(n){throw n}else if(s){return e}if(i){if(i.bodyMapper){let a=e.parsedBody;if(t.isXML&&i.bodyMapper.type.name===A.Sequence){a=typeof a==="object"?a[i.bodyMapper.xmlElementName]:[]}try{e.parsedBody=t.serializer.deserialize(i.bodyMapper,a,"operationRes.parsedBody",r)}catch(t){const a=new RestError(`Error ${t} occurred in deserializing the responseBody - ${e.bodyAsText}`,undefined,e.status,e.request,e);throw a}}else if(t.httpMethod==="HEAD"){e.parsedBody=a.status>=200&&a.status<300}if(i.headersMapper){e.parsedHeaders=t.serializer.deserialize(i.headersMapper,e.headers.toJson(),"operationRes.parsedHeaders",r)}}return e}))}function isOperationSpecEmpty(e){const t=Object.keys(e.responses);return t.length===0||t.length===1&&t[0]==="default"}function handleErrorResponse(e,t,a){var r;const i=200<=e.status&&e.status<300;const n=isOperationSpecEmpty(t)?i:!!a;if(n){if(a){if(!a.isError){return{error:null,shouldReturnResponse:false}}}else{return{error:null,shouldReturnResponse:false}}}const s=a!==null&&a!==void 0?a:t.responses.default;const o=((r=e.request.streamResponseStatusCodes)===null||r===void 0?void 0:r.has(e.status))||e.request.streamResponseBody;const p=o?`Unexpected status code: ${e.status}`:e.bodyAsText;const l=new RestError(p,undefined,e.status,e.request,e);if(!s){throw l}const d=s.bodyMapper;const c=s.headersMapper;try{if(e.parsedBody){const a=e.parsedBody;let r;if(d){let e=a;if(t.isXML&&d.type.name===A.Sequence){e=typeof a==="object"?a[d.xmlElementName]:[]}r=t.serializer.deserialize(d,e,"error.response.parsedBody")}const i=a.error||r||a;l.code=i.code;if(i.message){l.message=i.message}if(d){l.response.parsedBody=r}}if(e.headers&&c){l.response.parsedHeaders=t.serializer.deserialize(c,e.headers.toJson(),"operationRes.parsedHeaders")}}catch(t){l.message=`Error "${t.message}" occurred in deserializing the responseBody - "${e.bodyAsText}" for the default response.`}return{error:l,shouldReturnResponse:false}}function parse(e,t,a,r){var i;const errorHandler=e=>{const t=`Error "${e}" occurred while parsing the response body - ${a.bodyAsText}.`;const r=e.code||RestError.PARSE_ERROR;const i=new RestError(t,r,a.status,a.request,a);return Promise.reject(i)};const n=((i=a.request.streamResponseStatusCodes)===null||i===void 0?void 0:i.has(a.status))||a.request.streamResponseBody;if(!n&&a.bodyAsText){const i=a.bodyAsText;const n=a.headers.get("Content-Type")||"";const s=!n?[]:n.split(";").map((e=>e.toLowerCase()));if(s.length===0||s.some((t=>e.indexOf(t)!==-1))){return new Promise((e=>{a.parsedBody=JSON.parse(i);e(a)})).catch(errorHandler)}else if(s.some((e=>t.indexOf(e)!==-1))){return parseXML(i,r).then((e=>{a.parsedBody=e;return a})).catch(errorHandler)}}return Promise.resolve(a)}const $={enable:true};function keepAlivePolicy(e){return{create:(t,a)=>new KeepAlivePolicy(t,a,e||$)}}class KeepAlivePolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.keepAliveOptions=a}async sendRequest(e){e.keepAlive=this.keepAliveOptions.enable;return this._nextPolicy.sendRequest(e)}}const X=["GET","HEAD"];const W={handleRedirects:true,maxRetries:20};function redirectPolicy(e=20){return{create:(t,a)=>new RedirectPolicy(t,a,e)}}class RedirectPolicy extends BaseRequestPolicy{constructor(e,t,a=20){super(e,t);this.maxRetries=a}sendRequest(e){return this._nextPolicy.sendRequest(e).then((e=>handleRedirect(this,e,0)))}}function handleRedirect(e,t,a){const{request:r,status:i}=t;const n=t.headers.get("location");if(n&&(i===300||i===301&&X.includes(r.method)||i===302&&X.includes(r.method)||i===303&&r.method==="POST"||i===307)&&(!e.maxRetries||ahandleRedirect(e,t,a+1)))}return Promise.resolve(t)}const K=3;const Q=1e3*30;const Y=1e3*90;const J=1e3*3;function isNumber(e){return typeof e==="number"}function shouldRetry(e,t,a,r,i){if(!t(r,i)){return false}return a.retryCountnew ExponentialRetryPolicy(r,i,e,t,a)}}t.RetryMode=void 0;(function(e){e[e["Exponential"]=0]="Exponential"})(t.RetryMode||(t.RetryMode={}));const Z={maxRetries:K,retryDelayInMs:Q,maxRetryDelayInMs:Y};class ExponentialRetryPolicy extends BaseRequestPolicy{constructor(e,t,a,r,i){super(e,t);this.retryCount=isNumber(a)?a:K;this.retryInterval=isNumber(r)?r:Q;this.maxRetryInterval=isNumber(i)?i:Y}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then((t=>retry$1(this,e,t))).catch((t=>retry$1(this,e,t.response,undefined,t)))}}async function retry$1(e,t,a,r,i){function shouldPolicyRetry(e){const t=e===null||e===void 0?void 0:e.status;if(t===503&&(a===null||a===void 0?void 0:a.headers.get(P.HeaderConstants.RETRY_AFTER))){return false}if(t===undefined||t<500&&t!==408||t===501||t===505){return false}return true}r=updateRetryData({retryInterval:e.retryInterval,minRetryInterval:0,maxRetryInterval:e.maxRetryInterval},r,i);const n=t.abortSignal&&t.abortSignal.aborted;if(!n&&shouldRetry(e.retryCount,shouldPolicyRetry,r,a)){z.info(`Retrying request in ${r.retryInterval}`);try{await o.delay(r.retryInterval);const a=await e._nextPolicy.sendRequest(t.clone());return retry$1(e,t,a,r)}catch(i){return retry$1(e,t,a,r,i)}}else if(n||i||!a){const e=r.error||new RestError("Failed to send the request.",RestError.REQUEST_SEND_ERROR,a&&a.status,a&&a.request,a);throw e}else{return a}}function logPolicy(e={}){return{create:(t,a)=>new LogPolicy(t,a,e)}}class LogPolicy extends BaseRequestPolicy{constructor(e,t,{logger:a=z.info,allowedHeaderNames:r=[],allowedQueryParameters:i=[]}={}){super(e,t);this.logger=a;this.sanitizer=new Sanitizer({allowedHeaderNames:r,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){if(!this.logger.enabled)return this._nextPolicy.sendRequest(e);this.logRequest(e);return this._nextPolicy.sendRequest(e).then((e=>this.logResponse(e)))}logRequest(e){this.logger(`Request: ${this.sanitizer.sanitize(e)}`)}logResponse(e){this.logger(`Response status code: ${e.status}`);this.logger(`Headers: ${this.sanitizer.sanitize(e.headers)}`);return e}}function getPathStringFromParameter(e){return getPathStringFromParameterPath(e.parameterPath,e.mapper)}function getPathStringFromParameterPath(e,t){let a;if(typeof e==="string"){a=e}else if(Array.isArray(e)){a=e.join(".")}else{a=t.serializedName}return a}function getStreamResponseStatusCodes(e){const t=new Set;for(const a in e.responses){const r=e.responses[a];if(r.bodyMapper&&r.bodyMapper.type.name===A.Stream){t.add(Number(a))}}return t}function getDefaultUserAgentKey(){return P.HeaderConstants.USER_AGENT}function getPlatformSpecificData(){const e={key:"Node",value:process.version};const t={key:"OS",value:`(${w.arch()}-${w.type()}-${w.release()})`};return[e,t]}function getRuntimeInfo(){const e={key:"core-http",value:P.coreHttpVersion};return[e]}function getUserAgentString(e,t=" ",a="/"){return e.map((e=>{const t=e.value?`${a}${e.value}`:"";return`${e.key}${t}`})).join(t)}const ee=getDefaultUserAgentKey;function getDefaultUserAgentValue(){const e=getRuntimeInfo();const t=getPlatformSpecificData();const a=getUserAgentString(e.concat(t));return a}function userAgentPolicy(e){const t=!e||e.key===undefined||e.key===null?getDefaultUserAgentKey():e.key;const a=!e||e.value===undefined||e.value===null?getDefaultUserAgentValue():e.value;return{create:(e,r)=>new UserAgentPolicy(e,r,t,a)}}class UserAgentPolicy extends BaseRequestPolicy{constructor(e,t,a,r){super(e,t);this._nextPolicy=e;this._options=t;this.headerKey=a;this.headerValue=r}sendRequest(e){this.addUserAgentHeader(e);return this._nextPolicy.sendRequest(e)}addUserAgentHeader(e){if(!e.headers){e.headers=new HttpHeaders}if(!e.headers.get(this.headerKey)&&this.headerValue){e.headers.set(this.headerKey,this.headerValue)}}}t.QueryCollectionFormat=void 0;(function(e){e["Csv"]=",";e["Ssv"]=" ";e["Tsv"]="\t";e["Pipes"]="|";e["Multi"]="Multi"})(t.QueryCollectionFormat||(t.QueryCollectionFormat={}));const te={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function beginRefresh(e,t,a){async function tryGetAccessToken(){if(Date.now()e.getToken(t,a);r=beginRefresh(tryGetAccessToken,n.retryIntervalInMs,(o=i===null||i===void 0?void 0:i.expiresOnTimestamp)!==null&&o!==void 0?o:Date.now()).then((e=>{r=null;i=e;return i})).catch((e=>{r=null;i=null;throw e}))}return r}return async e=>{if(s.mustRefresh)return refresh(e);if(s.shouldRefresh){refresh(e)}return i}}function bearerTokenAuthenticationPolicy(e,t){const a=createTokenCycler(e,t);class BearerTokenAuthenticationPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){if(!e.url.toLowerCase().startsWith("https://")){throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.")}const{token:t}=await a({abortSignal:e.abortSignal,tracingOptions:{tracingContext:e.tracingContext}});e.headers.set(P.HeaderConstants.AUTHORIZATION,`Bearer ${t}`);return this._nextPolicy.sendRequest(e)}}return{create:(e,t)=>new BearerTokenAuthenticationPolicy(e,t)}}function disableResponseDecompressionPolicy(){return{create:(e,t)=>new DisableResponseDecompressionPolicy(e,t)}}class DisableResponseDecompressionPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){e.decompressResponse=false;return this._nextPolicy.sendRequest(e)}}function generateClientRequestIdPolicy(e="x-ms-client-request-id"){return{create:(t,a)=>new GenerateClientRequestIdPolicy(t,a,e)}}class GenerateClientRequestIdPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this._requestIdHeaderName=a}sendRequest(e){if(!e.headers.contains(this._requestIdHeaderName)){e.headers.set(this._requestIdHeaderName,e.requestId)}return this._nextPolicy.sendRequest(e)}}let ae;function getCachedDefaultHttpClient(){if(!ae){ae=new NodeFetchHttpClient}return ae}function ndJsonPolicy(){return{create:(e,t)=>new NdJsonPolicy(e,t)}}class NdJsonPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){if(typeof e.body==="string"&&e.body.startsWith("[")){const t=JSON.parse(e.body);if(Array.isArray(t)){e.body=t.map((e=>JSON.stringify(e)+"\n")).join("")}}return this._nextPolicy.sendRequest(e)}}const re=[];let ie=false;const ne=new Map;function loadEnvironmentProxyValue(){if(!process){return undefined}const e=getEnvironmentValue(P.HTTPS_PROXY);const t=getEnvironmentValue(P.ALL_PROXY);const a=getEnvironmentValue(P.HTTP_PROXY);return e||t||a}function isBypassed(e,t,a){if(t.length===0){return false}const r=URLBuilder.parse(e).getHost();if(a===null||a===void 0?void 0:a.has(r)){return a.get(r)}let i=false;for(const e of t){if(e[0]==="."){if(r.endsWith(e)){i=true}else{if(r.length===e.length-1&&r===e.slice(1)){i=true}}}else{if(r===e){i=true}}}a===null||a===void 0?void 0:a.set(r,i);return i}function loadNoProxy(){const e=getEnvironmentValue(P.NO_PROXY);ie=true;if(e){return e.split(",").map((e=>e.trim())).filter((e=>e.length))}return[]}function getDefaultProxySettings(e){if(!e){e=loadEnvironmentProxyValue();if(!e){return undefined}}const{username:t,password:a,urlWithoutAuth:r}=extractAuthFromUrl(e);const i=URLBuilder.parse(r);const n=i.getScheme()?i.getScheme()+"://":"";return{host:n+i.getHost(),port:Number.parseInt(i.getPort()||"80"),username:t,password:a}}function proxyPolicy(e,t){if(!e){e=getDefaultProxySettings()}if(!ie){re.push(...loadNoProxy())}return{create:(a,r)=>new ProxyPolicy(a,r,e,t===null||t===void 0?void 0:t.customNoProxyList)}}function extractAuthFromUrl(e){const t=e.indexOf("@");if(t===-1){return{urlWithoutAuth:e}}const a=e.indexOf("://");const r=a!==-1?a+3:0;const i=e.substring(r,t);const n=i.indexOf(":");const s=n!==-1;const o=s?i.substring(0,n):i;const p=s?i.substring(n+1):undefined;const l=e.substring(0,r)+e.substring(t+1);return{username:o,password:p,urlWithoutAuth:l}}class ProxyPolicy extends BaseRequestPolicy{constructor(e,t,a,r){super(e,t);this.proxySettings=a;this.customNoProxyList=r}sendRequest(e){var t;if(!e.proxySettings&&!isBypassed(e.url,(t=this.customNoProxyList)!==null&&t!==void 0?t:re,this.customNoProxyList?undefined:ne)){e.proxySettings=this.proxySettings}return this._nextPolicy.sendRequest(e)}}function rpRegistrationPolicy(e=30){return{create:(t,a)=>new RPRegistrationPolicy(t,a,e)}}class RPRegistrationPolicy extends BaseRequestPolicy{constructor(e,t,a=30){super(e,t);this._retryTimeout=a}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then((t=>registerIfNeeded(this,e,t)))}}function registerIfNeeded(e,t,a){if(a.status===409){const r=checkRPNotRegisteredError(a.bodyAsText);if(r){const i=extractSubscriptionUrl(t.url);return registerRP(e,i,r,t).catch((()=>false)).then((r=>{if(r){t.headers.set("x-ms-client-request-id",generateUuid());return e._nextPolicy.sendRequest(t.clone())}return a}))}}return Promise.resolve(a)}function getRequestEssentials(e,t=false){const a=e.clone();if(t){a.url=e.url}a.headers.set("x-ms-client-request-id",generateUuid());a.headers.set("Content-Type","application/json; charset=utf-8");return a}function checkRPNotRegisteredError(e){let t,a;if(e){try{a=JSON.parse(e)}catch(e){}if(a&&a.error&&a.error.message&&a.error.code&&a.error.code==="MissingSubscriptionRegistration"){const e=a.error.message.match(/.*'(.*)'/i);if(e){t=e.pop()}}}return t}function extractSubscriptionUrl(e){let t;const a=e.match(/.*\/subscriptions\/[a-f0-9-]+\//gi);if(a&&a[0]){t=a[0]}else{throw new Error(`Unable to extract subscriptionId from the given url - ${e}.`)}return t}async function registerRP(e,t,a,r){const i=`${t}providers/${a}/register?api-version=2016-02-01`;const n=`${t}providers/${a}?api-version=2016-02-01`;const s=getRequestEssentials(r);s.method="POST";s.url=i;const o=await e._nextPolicy.sendRequest(s);if(o.status!==200){throw new Error(`Autoregistration of ${a} failed. Please try registering manually.`)}return getRegistrationStatus(e,n,r)}async function getRegistrationStatus(e,t,a){const r=getRequestEssentials(a);r.url=t;r.method="GET";const i=await e._nextPolicy.sendRequest(r);const n=i.parsedBody;if(i.parsedBody&&n.registrationState&&n.registrationState==="Registered"){return true}else{await o.delay(e._retryTimeout*1e3);return getRegistrationStatus(e,t,a)}}function signingPolicy(e){return{create:(t,a)=>new SigningPolicy(t,a,e)}}class SigningPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.authenticationProvider=a}signRequest(e){return this.authenticationProvider.signRequest(e)}sendRequest(e){return this.signRequest(e).then((e=>this._nextPolicy.sendRequest(e)))}}function systemErrorRetryPolicy(e,t,a,r){return{create:(i,n)=>new SystemErrorRetryPolicy(i,n,e,t,a,r)}}class SystemErrorRetryPolicy extends BaseRequestPolicy{constructor(e,t,a,r,i,n){super(e,t);this.retryCount=isNumber(a)?a:K;this.retryInterval=isNumber(r)?r:Q;this.minRetryInterval=isNumber(i)?i:J;this.maxRetryInterval=isNumber(n)?n:Y}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).catch((t=>retry(this,e,t.response,t)))}}async function retry(e,t,a,r,i){i=updateRetryData(e,i,r);function shouldPolicyRetry(e,t){if(t&&t.code&&(t.code==="ETIMEDOUT"||t.code==="ESOCKETTIMEDOUT"||t.code==="ECONNREFUSED"||t.code==="ECONNRESET"||t.code==="ENOENT")){return true}return false}if(shouldRetry(e.retryCount,shouldPolicyRetry,i,a,r)){try{await o.delay(i.retryInterval);return e._nextPolicy.sendRequest(t.clone())}catch(r){return retry(e,t,a,r,i)}}else{if(r){return Promise.reject(i.error)}return a}}const se=3;const oe=P.HttpConstants.StatusCodes;function throttlingRetryPolicy(){return{create:(e,t)=>new ThrottlingRetryPolicy(e,t)}}const pe="The operation was aborted.";class ThrottlingRetryPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.numberOfRetries=0;this._handleResponse=a||this._defaultResponseHandler}async sendRequest(e){const t=await this._nextPolicy.sendRequest(e.clone());if(t.status!==oe.TooManyRequests&&t.status!==oe.ServiceUnavailable){return t}else{return this._handleResponse(e,t)}}async _defaultResponseHandler(e,t){var a;const r=t.headers.get(P.HeaderConstants.RETRY_AFTER);if(r){const t=ThrottlingRetryPolicy.parseRetryAfterHeader(r);if(t){this.numberOfRetries+=1;await o.delay(t,{abortSignal:e.abortSignal,abortErrorMsg:pe});if((a=e.abortSignal)===null||a===void 0?void 0:a.aborted){throw new u.AbortError(pe)}if(this.numberOfRetries{let a=undefined;const r=this;const i=t;return{create(t,n){const s=getCredentialScopes(i,r.baseUri);if(!s){throw new Error(`When using credential, the ServiceClient must contain a baseUri or a credentialScopes in ServiceClientOptions. Unable to create a bearerTokenAuthenticationPolicy`)}if(a===undefined||a===null){a=bearerTokenAuthenticationPolicy(e,s)}return a.create(t,n)}}};r=wrappedPolicyFactory()}else if(e&&typeof e.signRequest==="function"){z.info("ServiceClient: creating signing policy from provided credentials");r=signingPolicy(e)}else if(e!==undefined&&e!==null){throw new Error("The credentials argument must implement the TokenCredential interface")}z.info("ServiceClient: using default request policies");a=createDefaultRequestPolicyFactories(r,t);if(t.requestPolicyFactories){const e=t.requestPolicyFactories(a);if(e){a=e}}}this._requestPolicyFactories=a}sendRequest(e){if(e===null||e===undefined||typeof e!=="object"){throw new Error("options cannot be null or undefined and it must be of type object.")}let t;try{if(isWebResourceLike(e)){e.validateRequestProperties();t=e}else{t=new WebResource;t=t.prepare(e)}}catch(e){return Promise.reject(e)}let a=this._httpClient;if(this._requestPolicyFactories&&this._requestPolicyFactories.length>0){for(let e=this._requestPolicyFactories.length-1;e>=0;--e){a=this._requestPolicyFactories[e].create(a,this._requestPolicyOptions)}}return a.sendRequest(t)}async sendOperationRequest(e,a,r){var i;if(typeof e.options==="function"){r=e.options;e.options=undefined}const n=(i=e.options)===null||i===void 0?void 0:i.serializerOptions;const s=new WebResource;let o;try{const r=a.baseUrl||this.baseUri;if(!r){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=a.httpMethod;s.operationSpec=a;const i=URLBuilder.parse(r);if(a.path){i.appendPath(a.path)}if(a.urlParameters&&a.urlParameters.length>0){for(const t of a.urlParameters){let r=getOperationArgumentValueFromParameter(this,e,t,a.serializer);r=a.serializer.serialize(t.mapper,r,getPathStringFromParameter(t),n);if(!t.skipEncoding){r=encodeURIComponent(r)}i.replaceAll(`{${t.mapper.serializedName||getPathStringFromParameter(t)}}`,r)}}if(a.queryParameters&&a.queryParameters.length>0){for(const r of a.queryParameters){let s=getOperationArgumentValueFromParameter(this,e,r,a.serializer);if(s!==undefined&&s!==null){s=a.serializer.serialize(r.mapper,s,getPathStringFromParameter(r),n);if(r.collectionFormat!==undefined&&r.collectionFormat!==null){if(r.collectionFormat===t.QueryCollectionFormat.Multi){if(s.length===0){continue}else{for(const e in s){const t=s[e];s[e]=t===undefined||t===null?"":t.toString()}}}else if(r.collectionFormat===t.QueryCollectionFormat.Ssv||r.collectionFormat===t.QueryCollectionFormat.Tsv){s=s.join(r.collectionFormat)}}if(!r.skipEncoding){if(Array.isArray(s)){for(const e in s){if(s[e]!==undefined&&s[e]!==null){s[e]=encodeURIComponent(s[e])}}}else{s=encodeURIComponent(s)}}if(r.collectionFormat!==undefined&&r.collectionFormat!==null&&r.collectionFormat!==t.QueryCollectionFormat.Multi&&r.collectionFormat!==t.QueryCollectionFormat.Ssv&&r.collectionFormat!==t.QueryCollectionFormat.Tsv){s=s.join(r.collectionFormat)}i.setQueryParameter(r.mapper.serializedName||getPathStringFromParameter(r),s)}}}s.url=i.toString();const p=a.contentType||this.requestContentType;if(p&&a.requestBody){s.headers.set("Content-Type",p)}if(a.headerParameters){for(const t of a.headerParameters){let r=getOperationArgumentValueFromParameter(this,e,t,a.serializer);if(r!==undefined&&r!==null){r=a.serializer.serialize(t.mapper,r,getPathStringFromParameter(t),n);const e=t.mapper.headerCollectionPrefix;if(e){for(const t of Object.keys(r)){s.headers.set(e+t,r[t])}}else{s.headers.set(t.mapper.serializedName||getPathStringFromParameter(t),r)}}}}const l=e.options;if(l){if(l.customHeaders){for(const e in l.customHeaders){s.headers.set(e,l.customHeaders[e])}}if(l.abortSignal){s.abortSignal=l.abortSignal}if(l.timeout){s.timeout=l.timeout}if(l.onUploadProgress){s.onUploadProgress=l.onUploadProgress}if(l.onDownloadProgress){s.onDownloadProgress=l.onDownloadProgress}if(l.spanOptions){s.spanOptions=l.spanOptions}if(l.tracingContext){s.tracingContext=l.tracingContext}if(l.shouldDeserialize!==undefined&&l.shouldDeserialize!==null){s.shouldDeserialize=l.shouldDeserialize}}s.withCredentials=this._withCredentials;serializeRequestBody(this,s,e,a);if(s.streamResponseStatusCodes===undefined){s.streamResponseStatusCodes=getStreamResponseStatusCodes(a)}let d;let c;try{d=await this.sendRequest(s)}catch(e){c=e}if(c){if(c.response){c.details=flattenResponse(c.response,a.responses[c.statusCode]||a.responses["default"])}o=Promise.reject(c)}else{o=Promise.resolve(flattenResponse(d,a.responses[d.status]))}}catch(e){o=Promise.reject(e)}const p=r;if(p){o.then((e=>p(null,e._response.parsedBody,e._response.request,e._response))).catch((e=>p(e)))}return o}}function serializeRequestBody(e,t,a,r){var i,n,s,o,p,l;const d=(n=(i=a.options)===null||i===void 0?void 0:i.serializerOptions)!==null&&n!==void 0?n:{};const c={rootName:(s=d.rootName)!==null&&s!==void 0?s:"",includeRoot:(o=d.includeRoot)!==null&&o!==void 0?o:false,xmlCharKey:(p=d.xmlCharKey)!==null&&p!==void 0?p:O};const m=d.xmlCharKey;if(r.requestBody&&r.requestBody.mapper){t.body=getOperationArgumentValueFromParameter(e,a,r.requestBody,r.serializer);const i=r.requestBody.mapper;const{required:n,xmlName:s,xmlElementName:o,serializedName:p,xmlNamespace:d,xmlNamespacePrefix:u}=i;const h=i.type.name;try{if(t.body!==undefined&&t.body!==null||n){const e=getPathStringFromParameter(r.requestBody);t.body=r.serializer.serialize(i,t.body,e,c);const a=h===A.Stream;if(r.isXML){const e=u?`xmlns:${u}`:"xmlns";const r=getXmlValueWithNamespace(d,e,h,t.body,c);if(h===A.Sequence){t.body=stringifyXML(prepareXMLRootList(r,o||s||p,e,d),{rootName:s||p,xmlCharKey:m})}else if(!a){t.body=stringifyXML(r,{rootName:s||p,xmlCharKey:m})}}else if(h===A.String&&(((l=r.contentType)===null||l===void 0?void 0:l.match("text/plain"))||r.mediaType==="text")){return}else if(!a){t.body=JSON.stringify(t.body)}}}catch(e){throw new Error(`Error "${e.message}" occurred in serializing the payload - ${JSON.stringify(p,undefined," ")}.`)}}else if(r.formDataParameters&&r.formDataParameters.length>0){t.formData={};for(const i of r.formDataParameters){const n=getOperationArgumentValueFromParameter(e,a,i,r.serializer);if(n!==undefined&&n!==null){const e=i.mapper.serializedName||getPathStringFromParameter(i);t.formData[e]=r.serializer.serialize(i.mapper,n,getPathStringFromParameter(i),c)}}}}function getXmlValueWithNamespace(e,t,a,r,i){if(e&&!["Composite","Sequence","Dictionary"].includes(a)){const a={};a[i.xmlCharKey]=r;a[C]={[t]:e};return a}return r}function getValueOrFunctionResult(e,t){let a;if(typeof e==="string"){a=e}else{a=t();if(typeof e==="function"){a=e(a)}}return a}function createDefaultRequestPolicyFactories(e,t){const a=[];if(t.generateClientRequestIdHeader){a.push(generateClientRequestIdPolicy(t.clientRequestIdHeaderName))}if(e){a.push(e)}const r=getValueOrFunctionResult(t.userAgentHeaderName,ee);const i=getValueOrFunctionResult(t.userAgent,getDefaultUserAgentValue);if(r&&i){a.push(userAgentPolicy({key:r,value:i}))}a.push(redirectPolicy());a.push(rpRegistrationPolicy(t.rpRegistrationRetryTimeout));if(!t.noRetryPolicy){a.push(exponentialRetryPolicy());a.push(systemErrorRetryPolicy());a.push(throttlingRetryPolicy())}a.push(deserializationPolicy(t.deserializationContentTypes));if(o.isNode){a.push(proxyPolicy(t.proxySettings))}a.push(logPolicy({logger:z.info}));return a}function createPipelineFromOptions(e,t){const a=[];if(e.sendStreamingJson){a.push(ndJsonPolicy())}let r=undefined;if(e.userAgentOptions&&e.userAgentOptions.userAgentPrefix){const t=[];t.push(e.userAgentOptions.userAgentPrefix);const a=getDefaultUserAgentValue();if(t.indexOf(a)===-1){t.push(a)}r=t.join(" ")}const i=Object.assign(Object.assign({},$),e.keepAliveOptions);const n=Object.assign(Object.assign({},Z),e.retryOptions);const s=Object.assign(Object.assign({},W),e.redirectOptions);if(o.isNode){a.push(proxyPolicy(e.proxyOptions))}const p=Object.assign(Object.assign({},G),e.deserializationOptions);const l=Object.assign({},e.loggingOptions);a.push(tracingPolicy({userAgent:r}),keepAlivePolicy(i),userAgentPolicy({value:r}),generateClientRequestIdPolicy(),deserializationPolicy(p.expectedContentTypes),throttlingRetryPolicy(),systemErrorRetryPolicy(),exponentialRetryPolicy(n.maxRetries,n.retryDelayInMs,n.maxRetryDelayInMs));if(s.handleRedirects){a.push(redirectPolicy(s.maxRetries))}if(t){a.push(t)}a.push(logPolicy(l));if(o.isNode&&e.decompressResponse===false){a.push(disableResponseDecompressionPolicy())}return{httpClient:e.httpClient,requestPolicyFactories:a}}function getOperationArgumentValueFromParameter(e,t,a,r){return getOperationArgumentValueFromParameterPath(e,t,a.parameterPath,a.mapper,r)}function getOperationArgumentValueFromParameterPath(e,t,a,r,i){var n;let s;if(typeof a==="string"){a=[a]}const o=(n=t.options)===null||n===void 0?void 0:n.serializerOptions;if(Array.isArray(a)){if(a.length>0){if(r.isConstant){s=r.defaultValue}else{let i=getPropertyFromParameterPath(t,a);if(!i.propertyFound){i=getPropertyFromParameterPath(e,a)}let n=false;if(!i.propertyFound){n=r.required||a[0]==="options"&&a.length===2}s=n?r.defaultValue:i.propertyValue}const n=getPathStringFromParameterPath(a,r);i.serialize(r,s,n,o)}}else{if(r.required){s={}}for(const n in a){const p=r.type.modelProperties[n];const l=a[n];const d=getOperationArgumentValueFromParameterPath(e,t,l,p,i);const c=getPathStringFromParameterPath(l,p);i.serialize(p,d,c,o);if(d!==undefined&&d!==null){if(!s){s={}}s[n]=d}}}return s}function getPropertyFromParameterPath(e,t){const a={propertyFound:false};let r=0;for(;rObject.defineProperty(t,"_response",{value:e});if(r){const t=r.type.name;if(t==="Stream"){return addOperationResponse(Object.assign(Object.assign({},a),{blobBody:e.blobBody,readableStreamBody:e.readableStreamBody}))}const i=t==="Composite"&&r.type.modelProperties||{};const n=Object.keys(i).some((e=>i[e].serializedName===""));if(t==="Sequence"||n){const t=[...e.parsedBody||[]];for(const a of Object.keys(i)){if(i[a].serializedName){t[a]=e.parsedBody[a]}}if(a){for(const e of Object.keys(a)){t[e]=a[e]}}addOperationResponse(t);return t}if(t==="Composite"||t==="Dictionary"){return addOperationResponse(Object.assign(Object.assign({},a),e.parsedBody))}}if(r||e.request.method==="HEAD"||isPrimitiveType(e.parsedBody)){return addOperationResponse(Object.assign(Object.assign({},a),{body:e.parsedBody}))}return addOperationResponse(Object.assign(Object.assign({},a),e.parsedBody))}function getCredentialScopes(e,t){if(e===null||e===void 0?void 0:e.credentialScopes){return e.credentialScopes}if(t){return`${t}/.default`}return undefined}function createSpanFunction(e){return b.createSpanFunction(e)}const de=2*60*1e3;class ExpiringAccessTokenCache{constructor(e=de){this.cachedToken=undefined;this.tokenRefreshBufferMs=e}setCachedToken(e){this.cachedToken=e}getCachedToken(){if(this.cachedToken&&Date.now()+this.tokenRefreshBufferMs>=this.cachedToken.expiresOnTimestamp){this.cachedToken=undefined}return this.cachedToken}}class AccessTokenRefresher{constructor(e,t,a=3e4){this.credential=e;this.scopes=t;this.requiredMillisecondsBeforeNewRefresh=a;this.lastCalled=0}isReady(){return!this.lastCalled||Date.now()-this.lastCalled>this.requiredMillisecondsBeforeNewRefresh}async getToken(e){this.lastCalled=Date.now();const t=await this.credential.getToken(this.scopes,e);this.promise=undefined;return t||undefined}refresh(e){if(!this.promise){this.promise=this.getToken(e)}return this.promise}}const ce=P.HeaderConstants;const me="Basic";class BasicAuthenticationCredentials{constructor(e,t,a=me){this.authorizationScheme=me;if(e===null||e===undefined||typeof e.valueOf()!=="string"){throw new Error("userName cannot be null or undefined and must be of type string.")}if(t===null||t===undefined||typeof t.valueOf()!=="string"){throw new Error("password cannot be null or undefined and must be of type string.")}this.userName=e;this.password=t;this.authorizationScheme=a}signRequest(e){const t=`${this.userName}:${this.password}`;const a=`${this.authorizationScheme} ${encodeString(t)}`;if(!e.headers)e.headers=new HttpHeaders;e.headers.set(ce.AUTHORIZATION,a);return Promise.resolve(e)}}class ApiKeyCredentials{constructor(e){if(!e||e&&!e.inHeader&&!e.inQuery){throw new Error(`options cannot be null or undefined. Either "inHeader" or "inQuery" property of the options object needs to be provided.`)}this.inHeader=e.inHeader;this.inQuery=e.inQuery}signRequest(e){if(!e){return Promise.reject(new Error(`webResource cannot be null or undefined and must be of type "object".`))}if(this.inHeader){if(!e.headers){e.headers=new HttpHeaders}for(const t in this.inHeader){e.headers.set(t,this.inHeader[t])}}if(this.inQuery){if(!e.url){return Promise.reject(new Error(`url cannot be null in the request object.`))}if(e.url.indexOf("?")<0){e.url+="?"}for(const t in this.inQuery){if(!e.url.endsWith("?")){e.url+="&"}e.url+=`${t}=${this.inQuery[t]}`}}return Promise.resolve(e)}}class TopicCredentials extends ApiKeyCredentials{constructor(e){if(!e||e&&typeof e!=="string"){throw new Error("topicKey cannot be null or undefined and must be of type string.")}const t={inHeader:{"aeg-sas-key":e}};super(t)}}Object.defineProperty(t,"delay",{enumerable:true,get:function(){return o.delay}});Object.defineProperty(t,"isNode",{enumerable:true,get:function(){return o.isNode}});Object.defineProperty(t,"isTokenCredential",{enumerable:true,get:function(){return l.isTokenCredential}});t.AccessTokenRefresher=AccessTokenRefresher;t.ApiKeyCredentials=ApiKeyCredentials;t.BaseRequestPolicy=BaseRequestPolicy;t.BasicAuthenticationCredentials=BasicAuthenticationCredentials;t.Constants=P;t.DefaultHttpClient=NodeFetchHttpClient;t.ExpiringAccessTokenCache=ExpiringAccessTokenCache;t.HttpHeaders=HttpHeaders;t.MapperType=A;t.RequestPolicyOptions=RequestPolicyOptions;t.RestError=RestError;t.Serializer=Serializer;t.ServiceClient=ServiceClient;t.TopicCredentials=TopicCredentials;t.URLBuilder=URLBuilder;t.URLQuery=URLQuery;t.WebResource=WebResource;t.XML_ATTRKEY=C;t.XML_CHARKEY=O;t.applyMixins=applyMixins;t.bearerTokenAuthenticationPolicy=bearerTokenAuthenticationPolicy;t.createPipelineFromOptions=createPipelineFromOptions;t.createSpanFunction=createSpanFunction;t.deserializationPolicy=deserializationPolicy;t.deserializeResponseBody=deserializeResponseBody;t.disableResponseDecompressionPolicy=disableResponseDecompressionPolicy;t.encodeUri=encodeUri;t.executePromisesSequentially=executePromisesSequentially;t.exponentialRetryPolicy=exponentialRetryPolicy;t.flattenResponse=flattenResponse;t.generateClientRequestIdPolicy=generateClientRequestIdPolicy;t.generateUuid=generateUuid;t.getDefaultProxySettings=getDefaultProxySettings;t.getDefaultUserAgentValue=getDefaultUserAgentValue;t.isDuration=isDuration;t.isValidUuid=isValidUuid;t.keepAlivePolicy=keepAlivePolicy;t.logPolicy=logPolicy;t.operationOptionsToRequestOptionsBase=operationOptionsToRequestOptionsBase;t.parseXML=parseXML;t.promiseToCallback=promiseToCallback;t.promiseToServiceCallback=promiseToServiceCallback;t.proxyPolicy=proxyPolicy;t.redirectPolicy=redirectPolicy;t.serializeObject=serializeObject;t.signingPolicy=signingPolicy;t.stringifyXML=stringifyXML;t.stripRequest=stripRequest;t.stripResponse=stripResponse;t.systemErrorRetryPolicy=systemErrorRetryPolicy;t.throttlingRetryPolicy=throttlingRetryPolicy;t.tracingPolicy=tracingPolicy;t.userAgentPolicy=userAgentPolicy},6279:(e,t,a)=>{var r=a(5443);var i=a(3837);var n=a(1017);var s=a(3685);var o=a(5687);var p=a(7310).parse;var l=a(7147);var d=a(2781).Stream;var c=a(3583);var m=a(4812);var u=a(3971);e.exports=FormData;i.inherits(FormData,r);function FormData(e){if(!(this instanceof FormData)){return new FormData(e)}this._overheadLength=0;this._valueLength=0;this._valuesToMeasure=[];r.call(this);e=e||{};for(var t in e){this[t]=e[t]}}FormData.LINE_BREAK="\r\n";FormData.DEFAULT_CONTENT_TYPE="application/octet-stream";FormData.prototype.append=function(e,t,a){a=a||{};if(typeof a=="string"){a={filename:a}}var n=r.prototype.append.bind(this);if(typeof t=="number"){t=""+t}if(i.isArray(t)){this._error(new Error("Arrays are not supported."));return}var s=this._multiPartHeader(e,t,a);var o=this._multiPartFooter();n(s);n(t);n(o);this._trackLength(s,t,a)};FormData.prototype._trackLength=function(e,t,a){var r=0;if(a.knownLength!=null){r+=+a.knownLength}else if(Buffer.isBuffer(t)){r=t.length}else if(typeof t==="string"){r=Buffer.byteLength(t)}this._valueLength+=r;this._overheadLength+=Buffer.byteLength(e)+FormData.LINE_BREAK.length;if(!t||!t.path&&!(t.readable&&t.hasOwnProperty("httpVersion"))&&!(t instanceof d)){return}if(!a.knownLength){this._valuesToMeasure.push(t)}};FormData.prototype._lengthRetriever=function(e,t){if(e.hasOwnProperty("fd")){if(e.end!=undefined&&e.end!=Infinity&&e.start!=undefined){t(null,e.end+1-(e.start?e.start:0))}else{l.stat(e.path,(function(a,r){var i;if(a){t(a);return}i=r.size-(e.start?e.start:0);t(null,i)}))}}else if(e.hasOwnProperty("httpVersion")){t(null,+e.headers["content-length"])}else if(e.hasOwnProperty("httpModule")){e.on("response",(function(a){e.pause();t(null,+a.headers["content-length"])}));e.resume()}else{t("Unknown stream")}};FormData.prototype._multiPartHeader=function(e,t,a){if(typeof a.header=="string"){return a.header}var r=this._getContentDisposition(t,a);var i=this._getContentType(t,a);var n="";var s={"Content-Disposition":["form-data",'name="'+e+'"'].concat(r||[]),"Content-Type":[].concat(i||[])};if(typeof a.header=="object"){u(s,a.header)}var o;for(var p in s){if(!s.hasOwnProperty(p))continue;o=s[p];if(o==null){continue}if(!Array.isArray(o)){o=[o]}if(o.length){n+=p+": "+o.join("; ")+FormData.LINE_BREAK}}return"--"+this.getBoundary()+FormData.LINE_BREAK+n+FormData.LINE_BREAK};FormData.prototype._getContentDisposition=function(e,t){var a,r;if(typeof t.filepath==="string"){a=n.normalize(t.filepath).replace(/\\/g,"/")}else if(t.filename||e.name||e.path){a=n.basename(t.filename||e.name||e.path)}else if(e.readable&&e.hasOwnProperty("httpVersion")){a=n.basename(e.client._httpMessage.path||"")}if(a){r='filename="'+a+'"'}return r};FormData.prototype._getContentType=function(e,t){var a=t.contentType;if(!a&&e.name){a=c.lookup(e.name)}if(!a&&e.path){a=c.lookup(e.path)}if(!a&&e.readable&&e.hasOwnProperty("httpVersion")){a=e.headers["content-type"]}if(!a&&(t.filepath||t.filename)){a=c.lookup(t.filepath||t.filename)}if(!a&&typeof e=="object"){a=FormData.DEFAULT_CONTENT_TYPE}return a};FormData.prototype._multiPartFooter=function(){return function(e){var t=FormData.LINE_BREAK;var a=this._streams.length===0;if(a){t+=this._lastBoundary()}e(t)}.bind(this)};FormData.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+FormData.LINE_BREAK};FormData.prototype.getHeaders=function(e){var t;var a={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e){if(e.hasOwnProperty(t)){a[t.toLowerCase()]=e[t]}}return a};FormData.prototype.setBoundary=function(e){this._boundary=e};FormData.prototype.getBoundary=function(){if(!this._boundary){this._generateBoundary()}return this._boundary};FormData.prototype.getBuffer=function(){var e=new Buffer.alloc(0);var t=this.getBoundary();for(var a=0,r=this._streams.length;a{e.exports=function(e,t){Object.keys(t).forEach((function(a){e[a]=e[a]||t[a]}));return e}},2107:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var L=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);L(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var M=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new M(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},7094:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(3233);var i=a(2557);var n=a(1333);const s=r.createClientLogger("core-lro");const o=2e3;const p=["succeeded","canceled","failed"];function deserializeState(e){try{return JSON.parse(e).state}catch(t){throw new Error(`Unable to deserialize input state: ${e}`)}}function setStateError(e){const{state:t,stateProxy:a,isOperationError:r}=e;return e=>{if(r(e)){a.setError(t,e);a.setFailed(t)}throw e}}function appendReadableErrorMessage(e,t){let a=e;if(a.slice(-1)!=="."){a=a+"."}return a+" "+t}function simplifyError(e){let t=e.message;let a=e.code;let r=e;while(r.innererror){r=r.innererror;a=r.code;t=appendReadableErrorMessage(t,r.message)}return{code:a,message:t}}function processOperationStatus(e){const{state:t,stateProxy:a,status:r,isDone:i,processResult:n,getError:o,response:p,setErrorAsResult:l}=e;switch(r){case"succeeded":{a.setSucceeded(t);break}case"failed":{const e=o===null||o===void 0?void 0:o(p);let r="";if(e){const{code:t,message:a}=simplifyError(e);r=`. ${t}. ${a}`}const i=`The long-running operation has failed${r}`;a.setError(t,new Error(i));a.setFailed(t);s.warning(i);break}case"canceled":{a.setCanceled(t);break}}if((i===null||i===void 0?void 0:i(p,t))||i===undefined&&["succeeded","canceled"].concat(l?[]:["failed"]).includes(r)){a.setResult(t,buildResult({response:p,state:t,processResult:n}))}}function buildResult(e){const{processResult:t,response:a,state:r}=e;return t?t(a,r):a}async function initOperation(e){const{init:t,stateProxy:a,processResult:r,getOperationStatus:i,withOperationLocation:n,setErrorAsResult:o}=e;const{operationLocation:p,resourceLocation:l,metadata:d,response:c}=await t();if(p)n===null||n===void 0?void 0:n(p,false);const m={metadata:d,operationLocation:p,resourceLocation:l};s.verbose(`LRO: Operation description:`,m);const u=a.initState(m);const h=i({response:c,state:u,operationLocation:p});processOperationStatus({state:u,status:h,stateProxy:a,response:c,setErrorAsResult:o,processResult:r});return u}async function pollOperationHelper(e){const{poll:t,state:a,stateProxy:r,operationLocation:i,getOperationStatus:n,getResourceLocation:o,isOperationError:l,options:d}=e;const c=await t(i,d).catch(setStateError({state:a,stateProxy:r,isOperationError:l}));const m=n(c,a);s.verbose(`LRO: Status:\n\tPolling from: ${a.config.operationLocation}\n\tOperation status: ${m}\n\tPolling status: ${p.includes(m)?"Stopped":"Running"}`);if(m==="succeeded"){const e=o(c,a);if(e!==undefined){return{response:await t(e).catch(setStateError({state:a,stateProxy:r,isOperationError:l})),status:m}}}return{response:c,status:m}}async function pollOperation(e){const{poll:t,state:a,stateProxy:r,options:i,getOperationStatus:n,getResourceLocation:s,getOperationLocation:o,isOperationError:l,withOperationLocation:d,getPollingInterval:c,processResult:m,getError:u,updateState:h,setDelay:g,isDone:y,setErrorAsResult:v}=e;const{operationLocation:b}=a.config;if(b!==undefined){const{response:e,status:x}=await pollOperationHelper({poll:t,getOperationStatus:n,state:a,stateProxy:r,operationLocation:b,getResourceLocation:s,isOperationError:l,options:i});processOperationStatus({status:x,response:e,state:a,stateProxy:r,isDone:y,processResult:m,getError:u,setErrorAsResult:v});if(!p.includes(x)){const t=c===null||c===void 0?void 0:c(e);if(t)g(t);const r=o===null||o===void 0?void 0:o(e,a);if(r!==undefined){const e=b!==r;a.config.operationLocation=r;d===null||d===void 0?void 0:d(r,e)}else d===null||d===void 0?void 0:d(b,false)}h===null||h===void 0?void 0:h(a,e)}}function getOperationLocationPollingUrl(e){const{azureAsyncOperation:t,operationLocation:a}=e;return a!==null&&a!==void 0?a:t}function getLocationHeader(e){return e.headers["location"]}function getOperationLocationHeader(e){return e.headers["operation-location"]}function getAzureAsyncOperationHeader(e){return e.headers["azure-asyncoperation"]}function findResourceLocation(e){var t;const{location:a,requestMethod:r,requestPath:i,resourceLocationConfig:n}=e;switch(r){case"PUT":{return i}case"DELETE":{return undefined}case"PATCH":{return(t=getDefault())!==null&&t!==void 0?t:i}default:{return getDefault()}}function getDefault(){switch(n){case"azure-async-operation":{return undefined}case"original-uri":{return i}case"location":default:{return a}}}}function inferLroMode(e){const{rawResponse:t,requestMethod:a,requestPath:r,resourceLocationConfig:i}=e;const n=getOperationLocationHeader(t);const s=getAzureAsyncOperationHeader(t);const o=getOperationLocationPollingUrl({operationLocation:n,azureAsyncOperation:s});const p=getLocationHeader(t);const l=a===null||a===void 0?void 0:a.toLocaleUpperCase();if(o!==undefined){return{mode:"OperationLocation",operationLocation:o,resourceLocation:findResourceLocation({requestMethod:l,location:p,requestPath:r,resourceLocationConfig:i})}}else if(p!==undefined){return{mode:"ResourceLocation",operationLocation:p}}else if(l==="PUT"&&r){return{mode:"Body",operationLocation:r}}else{return undefined}}function transformStatus(e){const{status:t,statusCode:a}=e;if(typeof t!=="string"&&t!==undefined){throw new Error(`Polling was unsuccessful. Expected status to have a string value or no value but it has instead: ${t}. This doesn't necessarily indicate the operation has failed. Check your Azure subscription or resource status for more information.`)}switch(t===null||t===void 0?void 0:t.toLocaleLowerCase()){case undefined:return toOperationStatus(a);case"succeeded":return"succeeded";case"failed":return"failed";case"running":case"accepted":case"started":case"canceling":case"cancelling":return"running";case"canceled":case"cancelled":return"canceled";default:{s.verbose(`LRO: unrecognized operation status: ${t}`);return t}}}function getStatus(e){var t;const{status:a}=(t=e.body)!==null&&t!==void 0?t:{};return transformStatus({status:a,statusCode:e.statusCode})}function getProvisioningState(e){var t,a;const{properties:r,provisioningState:i}=(t=e.body)!==null&&t!==void 0?t:{};const n=(a=r===null||r===void 0?void 0:r.provisioningState)!==null&&a!==void 0?a:i;return transformStatus({status:n,statusCode:e.statusCode})}function toOperationStatus(e){if(e===202){return"running"}else if(e<300){return"succeeded"}else{return"failed"}}function parseRetryAfter({rawResponse:e}){const t=e.headers["retry-after"];if(t!==undefined){const e=parseInt(t);return isNaN(e)?calculatePollingIntervalFromDate(new Date(t)):e*1e3}return undefined}function getErrorFromResponse(e){const t=e.flatResponse.error;if(!t){s.warning(`The long-running operation failed but there is no error property in the response's body`);return}if(!t.code||!t.message){s.warning(`The long-running operation failed but the error property in the response's body doesn't contain code or message`);return}return t}function calculatePollingIntervalFromDate(e){const t=Math.floor((new Date).getTime());const a=e.getTime();if(t{const e=await i.sendInitialRequest();const t=inferLroMode({rawResponse:e.rawResponse,requestPath:i.requestPath,requestMethod:i.requestMethod,resourceLocationConfig:a});return Object.assign({response:e,operationLocation:t===null||t===void 0?void 0:t.operationLocation,resourceLocation:t===null||t===void 0?void 0:t.resourceLocation},(t===null||t===void 0?void 0:t.mode)?{metadata:{mode:t.mode}}:{})},stateProxy:t,processResult:r?({flatResponse:e},t)=>r(e,t):({flatResponse:e})=>e,getOperationStatus:getStatusFromInitialResponse,setErrorAsResult:n})}function getOperationLocation({rawResponse:e},t){var a;const r=(a=t.config.metadata)===null||a===void 0?void 0:a["mode"];switch(r){case"OperationLocation":{return getOperationLocationPollingUrl({operationLocation:getOperationLocationHeader(e),azureAsyncOperation:getAzureAsyncOperationHeader(e)})}case"ResourceLocation":{return getLocationHeader(e)}case"Body":default:{return undefined}}}function getOperationStatus({rawResponse:e},t){var a;const r=(a=t.config.metadata)===null||a===void 0?void 0:a["mode"];switch(r){case"OperationLocation":{return getStatus(e)}case"ResourceLocation":{return toOperationStatus(e.statusCode)}case"Body":{return getProvisioningState(e)}default:throw new Error(`Internal error: Unexpected operation mode: ${r}`)}}function getResourceLocation({flatResponse:e},t){if(typeof e==="object"){const a=e.resourceLocation;if(a!==undefined){t.config.resourceLocation=a}}return t.config.resourceLocation}function isOperationError(e){return e.name==="RestError"}async function pollHttpOperation(e){const{lro:t,stateProxy:a,options:r,processResult:i,updateState:n,setDelay:s,state:o,setErrorAsResult:p}=e;return pollOperation({state:o,stateProxy:a,setDelay:s,processResult:i?({flatResponse:e},t)=>i(e,t):({flatResponse:e})=>e,getError:getErrorFromResponse,updateState:n,getPollingInterval:parseRetryAfter,getOperationLocation:getOperationLocation,getOperationStatus:getOperationStatus,isOperationError:isOperationError,getResourceLocation:getResourceLocation,options:r,poll:async(e,a)=>t.sendPollRequest(e,a),setErrorAsResult:p})}const createStateProxy$1=()=>({initState:e=>({status:"running",config:e}),setCanceled:e=>e.status="canceled",setError:(e,t)=>e.error=t,setResult:(e,t)=>e.result=t,setRunning:e=>e.status="running",setSucceeded:e=>e.status="succeeded",setFailed:e=>e.status="failed",getError:e=>e.error,getResult:e=>e.result,isCanceled:e=>e.status==="canceled",isFailed:e=>e.status==="failed",isRunning:e=>e.status==="running",isSucceeded:e=>e.status==="succeeded"});function buildCreatePoller(e){const{getOperationLocation:t,getStatusFromInitialResponse:a,getStatusFromPollResponse:r,isOperationError:s,getResourceLocation:p,getPollingInterval:l,getError:d,resolveOnUnsuccessful:c}=e;return async({init:e,poll:m},u)=>{const{processResult:h,updateState:g,withOperationLocation:y,intervalInMs:v=o,restoreFrom:b}=u||{};const x=createStateProxy$1();const w=y?(()=>{let e=false;return(t,a)=>{if(a)y(t);else if(!e)y(t);e=true}})():undefined;const S=b?deserializeState(b):await initOperation({init:e,stateProxy:x,processResult:h,getOperationStatus:a,withOperationLocation:w,setErrorAsResult:!c});let N;const T=new i.AbortController;const E=new Map;const handleProgressEvents=async()=>E.forEach((e=>e(S)));const _="Operation was canceled";let P=v;const C={getOperationState:()=>S,getResult:()=>S.result,isDone:()=>["succeeded","failed","canceled"].includes(S.status),isStopped:()=>N===undefined,stopPolling:()=>{T.abort()},toString:()=>JSON.stringify({state:S}),onProgress:e=>{const t=Symbol();E.set(t,e);return()=>E.delete(t)},pollUntilDone:e=>N!==null&&N!==void 0?N:N=(async()=>{const{abortSignal:t}=e||{};const{signal:a}=t?new i.AbortController([t,T.signal]):T;if(!C.isDone()){await C.poll({abortSignal:a});while(!C.isDone()){await n.delay(P,{abortSignal:a});await C.poll({abortSignal:a})}}if(c){return C.getResult()}else{switch(S.status){case"succeeded":return C.getResult();case"canceled":throw new Error(_);case"failed":throw S.error;case"notStarted":case"running":throw new Error(`Polling completed without succeeding or failing`)}}})().finally((()=>{N=undefined})),async poll(e){if(c){if(C.isDone())return}else{switch(S.status){case"succeeded":return;case"canceled":throw new Error(_);case"failed":throw S.error}}await pollOperation({poll:m,state:S,stateProxy:x,getOperationLocation:t,isOperationError:s,withOperationLocation:w,getPollingInterval:l,getOperationStatus:r,getResourceLocation:p,processResult:h,getError:d,updateState:g,options:e,setDelay:e=>{P=e},setErrorAsResult:!c});await handleProgressEvents();if(!c){switch(S.status){case"canceled":throw new Error(_);case"failed":throw S.error}}}};return C}}async function createHttpPoller(e,t){const{resourceLocationConfig:a,intervalInMs:r,processResult:i,restoreFrom:n,updateState:s,withOperationLocation:o,resolveOnUnsuccessful:p=false}=t||{};return buildCreatePoller({getStatusFromInitialResponse:getStatusFromInitialResponse,getStatusFromPollResponse:getOperationStatus,isOperationError:isOperationError,getOperationLocation:getOperationLocation,getResourceLocation:getResourceLocation,getPollingInterval:parseRetryAfter,getError:getErrorFromResponse,resolveOnUnsuccessful:p})({init:async()=>{const t=await e.sendInitialRequest();const r=inferLroMode({rawResponse:t.rawResponse,requestPath:e.requestPath,requestMethod:e.requestMethod,resourceLocationConfig:a});return Object.assign({response:t,operationLocation:r===null||r===void 0?void 0:r.operationLocation,resourceLocation:r===null||r===void 0?void 0:r.resourceLocation},(r===null||r===void 0?void 0:r.mode)?{metadata:{mode:r.mode}}:{})},poll:e.sendPollRequest},{intervalInMs:r,withOperationLocation:o,restoreFrom:n,updateState:s,processResult:i?({flatResponse:e},t)=>i(e,t):({flatResponse:e})=>e})}const createStateProxy=()=>({initState:e=>({config:e,isStarted:true}),setCanceled:e=>e.isCancelled=true,setError:(e,t)=>e.error=t,setResult:(e,t)=>e.result=t,setRunning:e=>e.isStarted=true,setSucceeded:e=>e.isCompleted=true,setFailed:()=>{},getError:e=>e.error,getResult:e=>e.result,isCanceled:e=>!!e.isCancelled,isFailed:e=>!!e.error,isRunning:e=>!!e.isStarted,isSucceeded:e=>Boolean(e.isCompleted&&!e.isCancelled&&!e.error)});class GenericPollOperation{constructor(e,t,a,r,i,n,s){this.state=e;this.lro=t;this.setErrorAsResult=a;this.lroResourceLocationConfig=r;this.processResult=i;this.updateState=n;this.isDone=s}setPollerConfig(e){this.pollerConfig=e}async update(e){var t;const a=createStateProxy();if(!this.state.isStarted){this.state=Object.assign(Object.assign({},this.state),await initHttpOperation({lro:this.lro,stateProxy:a,resourceLocationConfig:this.lroResourceLocationConfig,processResult:this.processResult,setErrorAsResult:this.setErrorAsResult}))}const r=this.updateState;const i=this.isDone;if(!this.state.isCompleted&&this.state.error===undefined){await pollHttpOperation({lro:this.lro,state:this.state,stateProxy:a,processResult:this.processResult,updateState:r?(e,{rawResponse:t})=>r(e,t):undefined,isDone:i?({flatResponse:e},t)=>i(e,t):undefined,options:e,setDelay:e=>{this.pollerConfig.intervalInMs=e},setErrorAsResult:this.setErrorAsResult})}(t=e===null||e===void 0?void 0:e.fireProgress)===null||t===void 0?void 0:t.call(e,this.state);return this}async cancel(){s.error("`cancelOperation` is deprecated because it wasn't implemented");return this}toString(){return JSON.stringify({state:this.state})}}class PollerStoppedError extends Error{constructor(e){super(e);this.name="PollerStoppedError";Object.setPrototypeOf(this,PollerStoppedError.prototype)}}class PollerCancelledError extends Error{constructor(e){super(e);this.name="PollerCancelledError";Object.setPrototypeOf(this,PollerCancelledError.prototype)}}class Poller{constructor(e){this.resolveOnUnsuccessful=false;this.stopped=true;this.pollProgressCallbacks=[];this.operation=e;this.promise=new Promise(((e,t)=>{this.resolve=e;this.reject=t}));this.promise.catch((()=>{}))}async startPolling(e={}){if(this.stopped){this.stopped=false}while(!this.isStopped()&&!this.isDone()){await this.poll(e);await this.delay()}}async pollOnce(e={}){if(!this.isDone()){this.operation=await this.operation.update({abortSignal:e.abortSignal,fireProgress:this.fireProgress.bind(this)})}this.processUpdatedState()}fireProgress(e){for(const t of this.pollProgressCallbacks){t(e)}}async cancelOnce(e={}){this.operation=await this.operation.cancel(e)}poll(e={}){if(!this.pollOncePromise){this.pollOncePromise=this.pollOnce(e);const clearPollOncePromise=()=>{this.pollOncePromise=undefined};this.pollOncePromise.then(clearPollOncePromise,clearPollOncePromise).catch(this.reject)}return this.pollOncePromise}processUpdatedState(){if(this.operation.state.error){this.stopped=true;if(!this.resolveOnUnsuccessful){this.reject(this.operation.state.error);throw this.operation.state.error}}if(this.operation.state.isCancelled){this.stopped=true;if(!this.resolveOnUnsuccessful){const e=new PollerCancelledError("Operation was canceled");this.reject(e);throw e}}if(this.isDone()&&this.resolve){this.resolve(this.getResult())}}async pollUntilDone(e={}){if(this.stopped){this.startPolling(e).catch(this.reject)}this.processUpdatedState();return this.promise}onProgress(e){this.pollProgressCallbacks.push(e);return()=>{this.pollProgressCallbacks=this.pollProgressCallbacks.filter((t=>t!==e))}}isDone(){const e=this.operation.state;return Boolean(e.isCompleted||e.isCancelled||e.error)}stopPolling(){if(!this.stopped){this.stopped=true;if(this.reject){this.reject(new PollerStoppedError("This poller is already stopped"))}}}isStopped(){return this.stopped}cancelOperation(e={}){if(!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(){const e=this.operation.state;return e.result}toString(){return this.operation.toString()}}class LroEngine extends Poller{constructor(e,t){const{intervalInMs:a=o,resumeFrom:r,resolveOnUnsuccessful:i=false,isDone:n,lroResourceLocationConfig:s,processResult:p,updateState:l}=t||{};const d=r?deserializeState(r):{};const c=new GenericPollOperation(d,e,!i,s,p,l,n);super(c);this.resolveOnUnsuccessful=i;this.config={intervalInMs:a};c.setPollerConfig(this.config)}delay(){return new Promise((e=>setTimeout((()=>e()),this.config.intervalInMs)))}}t.LroEngine=LroEngine;t.Poller=Poller;t.PollerCancelledError=PollerCancelledError;t.PollerStoppedError=PollerStoppedError;t.createHttpPoller=createHttpPoller},4559:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(6429);function getPagedAsyncIterator(e){var t;const a=getItemAsyncIterator(e);return{next(){return a.next()},[Symbol.asyncIterator](){return this},byPage:(t=e===null||e===void 0?void 0:e.byPage)!==null&&t!==void 0?t:t=>{const{continuationToken:a,maxPageSize:r}=t!==null&&t!==void 0?t:{};return getPageAsyncIterator(e,{pageLink:a,maxPageSize:r})}}}function getItemAsyncIterator(e){return r.__asyncGenerator(this,arguments,(function*getItemAsyncIterator_1(){var t,a,i,n;const s=getPageAsyncIterator(e);const o=yield r.__await(s.next());if(!Array.isArray(o.value)){const{toElements:i}=e;if(i){yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(i(o.value))));try{for(var p=r.__asyncValues(s),l;l=yield r.__await(p.next()),!l.done;){const e=l.value;yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(i(e))))}}catch(e){t={error:e}}finally{try{if(l&&!l.done&&(a=p.return))yield r.__await(a.call(p))}finally{if(t)throw t.error}}}else{yield yield r.__await(o.value);yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(s)))}}else{yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(o.value)));try{for(var d=r.__asyncValues(s),c;c=yield r.__await(d.next()),!c.done;){const e=c.value;yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(e)))}}catch(e){i={error:e}}finally{try{if(c&&!c.done&&(n=d.return))yield r.__await(n.call(d))}finally{if(i)throw i.error}}}}))}function getPageAsyncIterator(e,t={}){return r.__asyncGenerator(this,arguments,(function*getPageAsyncIterator_1(){const{pageLink:a,maxPageSize:i}=t;let n=yield r.__await(e.getPage(a!==null&&a!==void 0?a:e.firstPageLink,i));if(!n){return yield r.__await(void 0)}yield yield r.__await(n.page);while(n.nextPageLink){n=yield r.__await(e.getPage(n.nextPageLink,i));if(!n){return yield r.__await(void 0)}yield yield r.__await(n.page)}}))}t.getPagedAsyncIterator=getPagedAsyncIterator},6429:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var L=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);L(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var M=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new M(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},4175:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5163);(function(e){e[e["INTERNAL"]=0]="INTERNAL";e[e["SERVER"]=1]="SERVER";e[e["CLIENT"]=2]="CLIENT";e[e["PRODUCER"]=3]="PRODUCER";e[e["CONSUMER"]=4]="CONSUMER"})(t.SpanKind||(t.SpanKind={}));function getSpan(e){return r.trace.getSpan(e)}function setSpan(e,t){return r.trace.setSpan(e,t)}function setSpanContext(e,t){return r.trace.setSpanContext(e,t)}function getSpanContext(e){return r.trace.getSpanContext(e)}function isSpanContextValid(e){return r.trace.isSpanContextValid(e)}function getTracer(e,t){return r.trace.getTracer(e||"azure/core-tracing",t)}const i=r.context;(function(e){e[e["UNSET"]=0]="UNSET";e[e["OK"]=1]="OK";e[e["ERROR"]=2]="ERROR"})(t.SpanStatusCode||(t.SpanStatusCode={}));function isTracingDisabled(){var e;if(typeof process==="undefined"){return false}const t=(e=process.env.AZURE_TRACING_DISABLED)===null||e===void 0?void 0:e.toLowerCase();if(t==="false"||t==="0"){return false}return Boolean(t)}function createSpanFunction(e){return function(a,n){const s=getTracer();const o=(n===null||n===void 0?void 0:n.tracingOptions)||{};const p=Object.assign({kind:t.SpanKind.INTERNAL},o.spanOptions);const l=e.packagePrefix?`${e.packagePrefix}.${a}`:a;let d;if(isTracingDisabled()){d=r.trace.wrapSpanContext(r.INVALID_SPAN_CONTEXT)}else{d=s.startSpan(l,p,o.tracingContext)}if(e.namespace){d.setAttribute("az.namespace",e.namespace)}let c=o.spanOptions||{};if(d.isRecording()&&e.namespace){c=Object.assign(Object.assign({},o.spanOptions),{attributes:Object.assign(Object.assign({},p.attributes),{"az.namespace":e.namespace})})}const m=Object.assign(Object.assign({},o),{spanOptions:c,tracingContext:setSpan(o.tracingContext||i.active(),d)});const u=Object.assign(Object.assign({},n),{tracingOptions:m});return{span:d,updatedOptions:u}}}const n="00";function extractSpanContextFromTraceParentHeader(e){const t=e.split("-");if(t.length!==4){return}const[a,r,i,s]=t;if(a!==n){return}const o=parseInt(s,16);const p={spanId:i,traceId:r,traceFlags:o};return p}function getTraceParentHeader(e){const t=[];if(!e.traceId){t.push("traceId")}if(!e.spanId){t.push("spanId")}if(t.length){return}const a=e.traceFlags||0;const r=a.toString(16);const i=r.length===1?`0${r}`:r;return`${n}-${e.traceId}-${e.spanId}-${i}`}t.context=i;t.createSpanFunction=createSpanFunction;t.extractSpanContextFromTraceParentHeader=extractSpanContextFromTraceParentHeader;t.getSpan=getSpan;t.getSpanContext=getSpanContext;t.getTraceParentHeader=getTraceParentHeader;t.getTracer=getTracer;t.isSpanContextValid=isSpanContextValid;t.setSpan=setSpan;t.setSpanContext=setSpanContext},1333:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(2557);var i=a(6113);function createAbortablePromise(e,t){const{cleanupBeforeAbort:a,abortSignal:i,abortErrorMsg:n}=t!==null&&t!==void 0?t:{};return new Promise(((t,s)=>{function rejectOnAbort(){s(new r.AbortError(n!==null&&n!==void 0?n:"The operation was aborted."))}function removeListeners(){i===null||i===void 0?void 0:i.removeEventListener("abort",onAbort)}function onAbort(){a===null||a===void 0?void 0:a();removeListeners();rejectOnAbort()}if(i===null||i===void 0?void 0:i.aborted){return rejectOnAbort()}try{e((e=>{removeListeners();t(e)}),(e=>{removeListeners();s(e)}))}catch(e){s(e)}i===null||i===void 0?void 0:i.addEventListener("abort",onAbort)}))}const n="The delay was aborted.";function delay(e,t){let a;const{abortSignal:r,abortErrorMsg:i}=t!==null&&t!==void 0?t:{};return createAbortablePromise((t=>{a=setTimeout(t,e)}),{cleanupBeforeAbort:()=>clearTimeout(a),abortSignal:r,abortErrorMsg:i!==null&&i!==void 0?i:n})}function getRandomIntegerInclusive(e,t){e=Math.ceil(e);t=Math.floor(t);const a=Math.floor(Math.random()*(t-e+1));return a+e}function isObject(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}function isError(e){if(isObject(e)){const t=typeof e.name==="string";const a=typeof e.message==="string";return t&&a}return false}function getErrorMessage(e){if(isError(e)){return e.message}else{let t;try{if(typeof e==="object"&&e){t=JSON.stringify(e)}else{t=String(e)}}catch(e){t="[unable to stringify input]"}return`Unknown error ${t}`}}async function computeSha256Hmac(e,t,a){const r=Buffer.from(e,"base64");return i.createHmac("sha256",r).update(t).digest(a)}async function computeSha256Hash(e,t){return i.createHash("sha256").update(e).digest(t)}function isDefined(e){return typeof e!=="undefined"&&e!==null}function isObjectWithProperties(e,t){if(!isDefined(e)||typeof e!=="object"){return false}for(const a of t){if(!objectHasProperty(e,a)){return false}}return true}function objectHasProperty(e,t){return isDefined(e)&&typeof e==="object"&&t in e}function generateUUID(){let e="";for(let t=0;t<32;t++){const a=Math.floor(Math.random()*16);if(t===12){e+="4"}else if(t===16){e+=a&3|8}else{e+=a.toString(16)}if(t===7||t===11||t===15||t===19){e+="-"}}return e}var s;let o=typeof((s=globalThis===null||globalThis===void 0?void 0:globalThis.crypto)===null||s===void 0?void 0:s.randomUUID)==="function"?globalThis.crypto.randomUUID.bind(globalThis.crypto):i.randomUUID;if(!o){o=generateUUID}function randomUUID(){return o()}var p,l,d,c;const m=typeof window!=="undefined"&&typeof window.document!=="undefined";const u=typeof self==="object"&&typeof(self===null||self===void 0?void 0:self.importScripts)==="function"&&(((p=self.constructor)===null||p===void 0?void 0:p.name)==="DedicatedWorkerGlobalScope"||((l=self.constructor)===null||l===void 0?void 0:l.name)==="ServiceWorkerGlobalScope"||((d=self.constructor)===null||d===void 0?void 0:d.name)==="SharedWorkerGlobalScope");const h=typeof process!=="undefined"&&Boolean(process.version)&&Boolean((c=process.versions)===null||c===void 0?void 0:c.node);const g=typeof Deno!=="undefined"&&typeof Deno.version!=="undefined"&&typeof Deno.version.deno!=="undefined";const y=typeof Bun!=="undefined"&&typeof Bun.version!=="undefined";const v=typeof navigator!=="undefined"&&(navigator===null||navigator===void 0?void 0:navigator.product)==="ReactNative";function uint8ArrayToString(e,t){switch(t){case"utf-8":return uint8ArrayToUtf8String(e);case"base64":return uint8ArrayToBase64(e);case"base64url":return uint8ArrayToBase64Url(e)}}function stringToUint8Array(e,t){switch(t){case"utf-8":return utf8StringToUint8Array(e);case"base64":return base64ToUint8Array(e);case"base64url":return base64UrlToUint8Array(e)}}function uint8ArrayToBase64(e){return Buffer.from(e).toString("base64")}function uint8ArrayToBase64Url(e){return Buffer.from(e).toString("base64url")}function uint8ArrayToUtf8String(e){return Buffer.from(e).toString("utf-8")}function utf8StringToUint8Array(e){return Buffer.from(e)}function base64ToUint8Array(e){return Buffer.from(e,"base64")}function base64UrlToUint8Array(e){return Buffer.from(e,"base64url")}t.computeSha256Hash=computeSha256Hash;t.computeSha256Hmac=computeSha256Hmac;t.createAbortablePromise=createAbortablePromise;t.delay=delay;t.getErrorMessage=getErrorMessage;t.getRandomIntegerInclusive=getRandomIntegerInclusive;t.isBrowser=m;t.isBun=y;t.isDefined=isDefined;t.isDeno=g;t.isError=isError;t.isNode=h;t.isObject=isObject;t.isObjectWithProperties=isObjectWithProperties;t.isReactNative=v;t.isWebWorker=u;t.objectHasProperty=objectHasProperty;t.randomUUID=randomUUID;t.stringToUint8Array=stringToUint8Array;t.uint8ArrayToString=uint8ArrayToString},3233:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(2037);var i=a(3837);function _interopDefaultLegacy(e){return e&&typeof e==="object"&&"default"in e?e:{default:e}}var n=_interopDefaultLegacy(i);function log(e,...t){process.stderr.write(`${n["default"].format(e,...t)}${r.EOL}`)}const s=typeof process!=="undefined"&&process.env&&process.env.DEBUG||undefined;let o;let p=[];let l=[];const d=[];if(s){enable(s)}const c=Object.assign((e=>createDebugger(e)),{enable:enable,enabled:enabled,disable:disable,log:log});function enable(e){o=e;p=[];l=[];const t=/\*/g;const a=e.split(",").map((e=>e.trim().replace(t,".*?")));for(const e of a){if(e.startsWith("-")){l.push(new RegExp(`^${e.substr(1)}$`))}else{p.push(new RegExp(`^${e}$`))}}for(const e of d){e.enabled=enabled(e.namespace)}}function enabled(e){if(e.endsWith("*")){return true}for(const t of l){if(t.test(e)){return false}}for(const t of p){if(t.test(e)){return true}}return false}function disable(){const e=o||"";enable("");return e}function createDebugger(e){const t=Object.assign(debug,{enabled:enabled(e),destroy:destroy,log:c.log,namespace:e,extend:extend});function debug(...a){if(!t.enabled){return}if(a.length>0){a[0]=`${e} ${a[0]}`}t.log(...a)}d.push(t);return t}function destroy(){const e=d.indexOf(this);if(e>=0){d.splice(e,1);return true}return false}function extend(e){const t=createDebugger(`${this.namespace}:${e}`);t.log=this.log;return t}var m=c;const u=new Set;const h=typeof process!=="undefined"&&process.env&&process.env.AZURE_LOG_LEVEL||undefined;let g;const y=m("azure");y.log=(...e)=>{m.log(...e)};const v=["verbose","info","warning","error"];if(h){if(isAzureLogLevel(h)){setLogLevel(h)}else{console.error(`AZURE_LOG_LEVEL set to unknown log level '${h}'; logging is not enabled. Acceptable values: ${v.join(", ")}.`)}}function setLogLevel(e){if(e&&!isAzureLogLevel(e)){throw new Error(`Unknown log level '${e}'. Acceptable values: ${v.join(",")}`)}g=e;const t=[];for(const e of u){if(shouldEnable(e)){t.push(e.namespace)}}m.enable(t.join(","))}function getLogLevel(){return g}const b={verbose:400,info:300,warning:200,error:100};function createClientLogger(e){const t=y.extend(e);patchLogMethod(y,t);return{error:createLogger(t,"error"),warning:createLogger(t,"warning"),info:createLogger(t,"info"),verbose:createLogger(t,"verbose")}}function patchLogMethod(e,t){t.log=(...t)=>{e.log(...t)}}function createLogger(e,t){const a=Object.assign(e.extend(t),{level:t});patchLogMethod(e,a);if(shouldEnable(a)){const e=m.disable();m.enable(e+","+a.namespace)}u.add(a);return a}function shouldEnable(e){return Boolean(g&&b[e.level]<=b[g])}function isAzureLogLevel(e){return v.includes(e)}t.AzureLogger=y;t.createClientLogger=createClientLogger;t.getLogLevel=getLogLevel;t.setLogLevel=setLogLevel},4100:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(4607);var i=a(679);var n=a(4175);var s=a(3233);var o=a(2557);var p=a(2037);var l=a(6113);var d=a(2781);a(4559);var c=a(7094);var m=a(2361);var u=a(7147);var h=a(3837);function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(a){if(a!=="default"){var r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:true,get:function(){return e[a]}})}}))}t["default"]=e;return Object.freeze(t)}var g=_interopNamespace(r);var y=_interopNamespace(p);var v=_interopNamespace(u);var b=_interopNamespace(h);const x={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:true,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"}}}}};const w={serializedName:"Logging",type:{name:"Composite",className:"Logging",modelProperties:{version:{serializedName:"Version",required:true,xmlName:"Version",type:{name:"String"}},deleteProperty:{serializedName:"Delete",required:true,xmlName:"Delete",type:{name:"Boolean"}},read:{serializedName:"Read",required:true,xmlName:"Read",type:{name:"Boolean"}},write:{serializedName:"Write",required:true,xmlName:"Write",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}};const S={serializedName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy",modelProperties:{enabled:{serializedName:"Enabled",required:true,xmlName:"Enabled",type:{name:"Boolean"}},days:{constraints:{InclusiveMinimum:1},serializedName:"Days",xmlName:"Days",type:{name:"Number"}}}}};const N={serializedName:"Metrics",type:{name:"Composite",className:"Metrics",modelProperties:{version:{serializedName:"Version",xmlName:"Version",type:{name:"String"}},enabled:{serializedName:"Enabled",required:true,xmlName:"Enabled",type:{name:"Boolean"}},includeAPIs:{serializedName:"IncludeAPIs",xmlName:"IncludeAPIs",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}};const T={serializedName:"CorsRule",type:{name:"Composite",className:"CorsRule",modelProperties:{allowedOrigins:{serializedName:"AllowedOrigins",required:true,xmlName:"AllowedOrigins",type:{name:"String"}},allowedMethods:{serializedName:"AllowedMethods",required:true,xmlName:"AllowedMethods",type:{name:"String"}},allowedHeaders:{serializedName:"AllowedHeaders",required:true,xmlName:"AllowedHeaders",type:{name:"String"}},exposedHeaders:{serializedName:"ExposedHeaders",required:true,xmlName:"ExposedHeaders",type:{name:"String"}},maxAgeInSeconds:{constraints:{InclusiveMinimum:0},serializedName:"MaxAgeInSeconds",required:true,xmlName:"MaxAgeInSeconds",type:{name:"Number"}}}}};const E={serializedName:"StaticWebsite",type:{name:"Composite",className:"StaticWebsite",modelProperties:{enabled:{serializedName:"Enabled",required:true,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"}}}}};const _={serializedName:"StorageError",type:{name:"Composite",className:"StorageError",modelProperties:{message:{serializedName:"Message",xmlName:"Message",type:{name:"String"}},code:{serializedName:"Code",xmlName:"Code",type:{name:"String"}}}}};const P={serializedName:"BlobServiceStatistics",xmlName:"StorageServiceStats",type:{name:"Composite",className:"BlobServiceStatistics",modelProperties:{geoReplication:{serializedName:"GeoReplication",xmlName:"GeoReplication",type:{name:"Composite",className:"GeoReplication"}}}}};const C={serializedName:"GeoReplication",type:{name:"Composite",className:"GeoReplication",modelProperties:{status:{serializedName:"Status",required:true,xmlName:"Status",type:{name:"Enum",allowedValues:["live","bootstrap","unavailable"]}},lastSyncOn:{serializedName:"LastSyncTime",required:true,xmlName:"LastSyncTime",type:{name:"DateTimeRfc1123"}}}}};const O={serializedName:"ListContainersSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListContainersSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,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:true,xmlName:"Containers",xmlIsWrapped:true,xmlElementName:"Container",type:{name:"Sequence",element:{type:{name:"Composite",className:"ContainerItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const R={serializedName:"ContainerItem",xmlName:"Container",type:{name:"Composite",className:"ContainerItem",modelProperties:{name:{serializedName:"Name",required:true,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"}}}}}}};const D={serializedName:"ContainerProperties",type:{name:"Composite",className:"ContainerProperties",modelProperties:{lastModified:{serializedName:"Last-Modified",required:true,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:true,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"}}}}};const A={serializedName:"KeyInfo",type:{name:"Composite",className:"KeyInfo",modelProperties:{startsOn:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"String"}},expiresOn:{serializedName:"Expiry",required:true,xmlName:"Expiry",type:{name:"String"}}}}};const I={serializedName:"UserDelegationKey",type:{name:"Composite",className:"UserDelegationKey",modelProperties:{signedObjectId:{serializedName:"SignedOid",required:true,xmlName:"SignedOid",type:{name:"String"}},signedTenantId:{serializedName:"SignedTid",required:true,xmlName:"SignedTid",type:{name:"String"}},signedStartsOn:{serializedName:"SignedStart",required:true,xmlName:"SignedStart",type:{name:"String"}},signedExpiresOn:{serializedName:"SignedExpiry",required:true,xmlName:"SignedExpiry",type:{name:"String"}},signedService:{serializedName:"SignedService",required:true,xmlName:"SignedService",type:{name:"String"}},signedVersion:{serializedName:"SignedVersion",required:true,xmlName:"SignedVersion",type:{name:"String"}},value:{serializedName:"Value",required:true,xmlName:"Value",type:{name:"String"}}}}};const L={serializedName:"FilterBlobSegment",xmlName:"EnumerationResults",type:{name:"Composite",className:"FilterBlobSegment",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},where:{serializedName:"Where",required:true,xmlName:"Where",type:{name:"String"}},blobs:{serializedName:"Blobs",required:true,xmlName:"Blobs",xmlIsWrapped:true,xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"FilterBlobItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const M={serializedName:"FilterBlobItem",xmlName:"Blob",type:{name:"Composite",className:"FilterBlobItem",modelProperties:{name:{serializedName:"Name",required:true,xmlName:"Name",type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",type:{name:"String"}},tags:{serializedName:"Tags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags"}}}}};const B={serializedName:"BlobTags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags",modelProperties:{blobTagSet:{serializedName:"BlobTagSet",required:true,xmlName:"TagSet",xmlIsWrapped:true,xmlElementName:"Tag",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobTag"}}}}}}};const k={serializedName:"BlobTag",xmlName:"Tag",type:{name:"Composite",className:"BlobTag",modelProperties:{key:{serializedName:"Key",required:true,xmlName:"Key",type:{name:"String"}},value:{serializedName:"Value",required:true,xmlName:"Value",type:{name:"String"}}}}};const z={serializedName:"SignedIdentifier",xmlName:"SignedIdentifier",type:{name:"Composite",className:"SignedIdentifier",modelProperties:{id:{serializedName:"Id",required:true,xmlName:"Id",type:{name:"String"}},accessPolicy:{serializedName:"AccessPolicy",xmlName:"AccessPolicy",type:{name:"Composite",className:"AccessPolicy"}}}}};const j={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"}}}}};const q={serializedName:"ListBlobsFlatSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsFlatSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",xmlIsAttribute:true,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"}}}}};const U={serializedName:"BlobFlatListSegment",xmlName:"Blobs",type:{name:"Composite",className:"BlobFlatListSegment",modelProperties:{blobItems:{serializedName:"BlobItems",required:true,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}};const H={serializedName:"BlobItemInternal",xmlName:"Blob",type:{name:"Composite",className:"BlobItemInternal",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}},deleted:{serializedName:"Deleted",required:true,xmlName:"Deleted",type:{name:"Boolean"}},snapshot:{serializedName:"Snapshot",required:true,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"}}}}};const V={serializedName:"BlobName",type:{name:"Composite",className:"BlobName",modelProperties:{encoded:{serializedName:"Encoded",xmlName:"Encoded",xmlIsAttribute:true,type:{name:"Boolean"}},content:{serializedName:"content",xmlName:"content",xmlIsMsText:true,type:{name:"String"}}}}};const G={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:true,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:true,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","Cold"]}},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"}}}}};const $={serializedName:"ListBlobsHierarchySegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsHierarchySegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",xmlIsAttribute:true,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"}}}}};const X={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:true,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}};const W={serializedName:"BlobPrefix",type:{name:"Composite",className:"BlobPrefix",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}}}}};const K={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"}}}}}}};const Q={serializedName:"BlockList",type:{name:"Composite",className:"BlockList",modelProperties:{committedBlocks:{serializedName:"CommittedBlocks",xmlName:"CommittedBlocks",xmlIsWrapped:true,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}},uncommittedBlocks:{serializedName:"UncommittedBlocks",xmlName:"UncommittedBlocks",xmlIsWrapped:true,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}}}}};const Y={serializedName:"Block",type:{name:"Composite",className:"Block",modelProperties:{name:{serializedName:"Name",required:true,xmlName:"Name",type:{name:"String"}},size:{serializedName:"Size",required:true,xmlName:"Size",type:{name:"Number"}}}}};const J={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"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const Z={serializedName:"PageRange",xmlName:"PageRange",type:{name:"Composite",className:"PageRange",modelProperties:{start:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:true,xmlName:"End",type:{name:"Number"}}}}};const ee={serializedName:"ClearRange",xmlName:"ClearRange",type:{name:"Composite",className:"ClearRange",modelProperties:{start:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:true,xmlName:"End",type:{name:"Number"}}}}};const te={serializedName:"QueryRequest",xmlName:"QueryRequest",type:{name:"Composite",className:"QueryRequest",modelProperties:{queryType:{serializedName:"QueryType",required:true,xmlName:"QueryType",type:{name:"String"}},expression:{serializedName:"Expression",required:true,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"}}}}};const ae={serializedName:"QuerySerialization",type:{name:"Composite",className:"QuerySerialization",modelProperties:{format:{serializedName:"Format",xmlName:"Format",type:{name:"Composite",className:"QueryFormat"}}}}};const re={serializedName:"QueryFormat",type:{name:"Composite",className:"QueryFormat",modelProperties:{type:{serializedName:"Type",required:true,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"}}}}};const ie={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"}}}}};const ne={serializedName:"JsonTextConfiguration",xmlName:"JsonTextConfiguration",type:{name:"Composite",className:"JsonTextConfiguration",modelProperties:{recordSeparator:{serializedName:"RecordSeparator",xmlName:"RecordSeparator",type:{name:"String"}}}}};const se={serializedName:"ArrowConfiguration",xmlName:"ArrowConfiguration",type:{name:"Composite",className:"ArrowConfiguration",modelProperties:{schema:{serializedName:"Schema",required:true,xmlName:"Schema",xmlIsWrapped:true,xmlElementName:"Field",type:{name:"Sequence",element:{type:{name:"Composite",className:"ArrowField"}}}}}}};const oe={serializedName:"ArrowField",xmlName:"Field",type:{name:"Composite",className:"ArrowField",modelProperties:{type:{serializedName:"Type",required:true,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"}}}}};const pe={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"}}}}};const le={serializedName:"Service_setPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceSetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const de={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"}}}}};const ce={serializedName:"Service_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const me={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"}}}}};const ue={serializedName:"Service_getStatisticsExceptionHeaders",type:{name:"Composite",className:"ServiceGetStatisticsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const fe={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"}}}}};const he={serializedName:"Service_listContainersSegmentExceptionHeaders",type:{name:"Composite",className:"ServiceListContainersSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ge={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"}}}}};const ye={serializedName:"Service_getUserDelegationKeyExceptionHeaders",type:{name:"Composite",className:"ServiceGetUserDelegationKeyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ve={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"}}}}};const be={serializedName:"Service_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ServiceGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const xe={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"}}}}};const we={serializedName:"Service_submitBatchExceptionHeaders",type:{name:"Composite",className:"ServiceSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Se={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"}}}}};const Ne={serializedName:"Service_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ServiceFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Te={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"}}}}};const Ee={serializedName:"Container_createExceptionHeaders",type:{name:"Composite",className:"ContainerCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const _e={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"}}}}};const Pe={serializedName:"Container_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ContainerGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ce={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"}}}}};const Oe={serializedName:"Container_deleteExceptionHeaders",type:{name:"Composite",className:"ContainerDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Re={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"}}}}};const De={serializedName:"Container_setMetadataExceptionHeaders",type:{name:"Composite",className:"ContainerSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ae={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"}}}}};const Ie={serializedName:"Container_getAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Le={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"}}}}};const Me={serializedName:"Container_setAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerSetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Be={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"}}}}};const ke={serializedName:"Container_restoreExceptionHeaders",type:{name:"Composite",className:"ContainerRestoreExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ze={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"}}}}};const je={serializedName:"Container_renameExceptionHeaders",type:{name:"Composite",className:"ContainerRenameExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const qe={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"}}}}};const Ue={serializedName:"Container_submitBatchExceptionHeaders",type:{name:"Composite",className:"ContainerSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Fe={serializedName:"Container_filterBlobsHeaders",type:{name:"Composite",className:"ContainerFilterBlobsHeaders",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"}}}}};const He={serializedName:"Container_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ContainerFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ve={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"}}}}};const Ge={serializedName:"Container_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const $e={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"}}}}};const Xe={serializedName:"Container_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const We={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"}}}}};const Ke={serializedName:"Container_renewLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Qe={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"}}}}};const Ye={serializedName:"Container_breakLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Je={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"}}}}};const Ze={serializedName:"Container_changeLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const et={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"}}}}};const tt={serializedName:"Container_listBlobFlatSegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobFlatSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const rt={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"}}}}};const it={serializedName:"Container_listBlobHierarchySegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobHierarchySegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const nt={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"]}}}}};const st={serializedName:"Container_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ot={serializedName:"Blob_downloadHeaders",type:{name:"Composite",className:"BlobDownloadHeaders",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-"},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"}}}}};const pt={serializedName:"Blob_downloadExceptionHeaders",type:{name:"Composite",className:"BlobDownloadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const dt={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"}}}}};const ct={serializedName:"Blob_getPropertiesExceptionHeaders",type:{name:"Composite",className:"BlobGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const mt={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"}}}}};const ut={serializedName:"Blob_deleteExceptionHeaders",type:{name:"Composite",className:"BlobDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ft={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"}}}}};const ht={serializedName:"Blob_undeleteExceptionHeaders",type:{name:"Composite",className:"BlobUndeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const yt={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"}}}}};const vt={serializedName:"Blob_setExpiryExceptionHeaders",type:{name:"Composite",className:"BlobSetExpiryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const bt={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"}}}}};const xt={serializedName:"Blob_setHttpHeadersExceptionHeaders",type:{name:"Composite",className:"BlobSetHttpHeadersExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const wt={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"]}}}}};const St={serializedName:"Blob_setImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobSetImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Nt={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"}}}}};const Tt={serializedName:"Blob_deleteImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobDeleteImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Et={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"}}}}};const _t={serializedName:"Blob_setLegalHoldExceptionHeaders",type:{name:"Composite",className:"BlobSetLegalHoldExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Pt={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"}}}}};const Ct={serializedName:"Blob_setMetadataExceptionHeaders",type:{name:"Composite",className:"BlobSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ot={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"}}}}};const Rt={serializedName:"Blob_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"BlobAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Dt={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"}}}}};const At={serializedName:"Blob_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"BlobReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const It={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"}}}}};const Lt={serializedName:"Blob_renewLeaseExceptionHeaders",type:{name:"Composite",className:"BlobRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Mt={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"}}}}};const Bt={serializedName:"Blob_changeLeaseExceptionHeaders",type:{name:"Composite",className:"BlobChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const kt={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"}}}}};const zt={serializedName:"Blob_breakLeaseExceptionHeaders",type:{name:"Composite",className:"BlobBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const jt={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"}}}}};const qt={serializedName:"Blob_createSnapshotExceptionHeaders",type:{name:"Composite",className:"BlobCreateSnapshotExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ut={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"}}}}};const Ft={serializedName:"Blob_startCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobStartCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ht={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:true,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"}},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"}}}}};const Vt={serializedName:"Blob_copyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Gt={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"}}}}};const $t={serializedName:"Blob_abortCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobAbortCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Xt={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"}}}}};const Wt={serializedName:"Blob_setTierExceptionHeaders",type:{name:"Composite",className:"BlobSetTierExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Kt={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"]}}}}};const Qt={serializedName:"Blob_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"BlobGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Yt={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"}}}}};const Jt={serializedName:"Blob_queryExceptionHeaders",type:{name:"Composite",className:"BlobQueryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Zt={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"}}}}};const ea={serializedName:"Blob_getTagsExceptionHeaders",type:{name:"Composite",className:"BlobGetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ta={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"}}}}};const aa={serializedName:"Blob_setTagsExceptionHeaders",type:{name:"Composite",className:"BlobSetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ra={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"}}}}};const ia={serializedName:"PageBlob_createExceptionHeaders",type:{name:"Composite",className:"PageBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const na={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"}}}}};const sa={serializedName:"PageBlob_uploadPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const oa={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"}}}}};const pa={serializedName:"PageBlob_clearPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobClearPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const la={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"}}}}};const da={serializedName:"PageBlob_uploadPagesFromURLExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ca={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"}}}}};const ma={serializedName:"PageBlob_getPageRangesExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ua={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"}}}}};const fa={serializedName:"PageBlob_getPageRangesDiffExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesDiffExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ha={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"}}}}};const ga={serializedName:"PageBlob_resizeExceptionHeaders",type:{name:"Composite",className:"PageBlobResizeExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ya={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"}}}}};const va={serializedName:"PageBlob_updateSequenceNumberExceptionHeaders",type:{name:"Composite",className:"PageBlobUpdateSequenceNumberExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ba={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"}}}}};const xa={serializedName:"PageBlob_copyIncrementalExceptionHeaders",type:{name:"Composite",className:"PageBlobCopyIncrementalExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const wa={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"}}}}};const Sa={serializedName:"AppendBlob_createExceptionHeaders",type:{name:"Composite",className:"AppendBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Na={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"}}}}};const Ta={serializedName:"AppendBlob_appendBlockExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ea={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"}}}}};const _a={serializedName:"AppendBlob_appendBlockFromUrlExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Pa={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"}}}}};const Ca={serializedName:"AppendBlob_sealExceptionHeaders",type:{name:"Composite",className:"AppendBlobSealExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Oa={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"}}}}};const Ra={serializedName:"BlockBlob_uploadExceptionHeaders",type:{name:"Composite",className:"BlockBlobUploadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Da={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"}}}}};const Aa={serializedName:"BlockBlob_putBlobFromUrlExceptionHeaders",type:{name:"Composite",className:"BlockBlobPutBlobFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ia={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"}}}}};const La={serializedName:"BlockBlob_stageBlockExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ma={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"}}}}};const Ba={serializedName:"BlockBlob_stageBlockFromURLExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ka={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"}}}}};const za={serializedName:"BlockBlob_commitBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobCommitBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ja={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"}}}}};const qa={serializedName:"BlockBlob_getBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobGetBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};var Ua=Object.freeze({__proto__:null,BlobServiceProperties:x,Logging:w,RetentionPolicy:S,Metrics:N,CorsRule:T,StaticWebsite:E,StorageError:_,BlobServiceStatistics:P,GeoReplication:C,ListContainersSegmentResponse:O,ContainerItem:R,ContainerProperties:D,KeyInfo:A,UserDelegationKey:I,FilterBlobSegment:L,FilterBlobItem:M,BlobTags:B,BlobTag:k,SignedIdentifier:z,AccessPolicy:j,ListBlobsFlatSegmentResponse:q,BlobFlatListSegment:U,BlobItemInternal:H,BlobName:V,BlobPropertiesInternal:G,ListBlobsHierarchySegmentResponse:$,BlobHierarchyListSegment:X,BlobPrefix:W,BlockLookupList:K,BlockList:Q,Block:Y,PageList:J,PageRange:Z,ClearRange:ee,QueryRequest:te,QuerySerialization:ae,QueryFormat:re,DelimitedTextConfiguration:ie,JsonTextConfiguration:ne,ArrowConfiguration:se,ArrowField:oe,ServiceSetPropertiesHeaders:pe,ServiceSetPropertiesExceptionHeaders:le,ServiceGetPropertiesHeaders:de,ServiceGetPropertiesExceptionHeaders:ce,ServiceGetStatisticsHeaders:me,ServiceGetStatisticsExceptionHeaders:ue,ServiceListContainersSegmentHeaders:fe,ServiceListContainersSegmentExceptionHeaders:he,ServiceGetUserDelegationKeyHeaders:ge,ServiceGetUserDelegationKeyExceptionHeaders:ye,ServiceGetAccountInfoHeaders:ve,ServiceGetAccountInfoExceptionHeaders:be,ServiceSubmitBatchHeaders:xe,ServiceSubmitBatchExceptionHeaders:we,ServiceFilterBlobsHeaders:Se,ServiceFilterBlobsExceptionHeaders:Ne,ContainerCreateHeaders:Te,ContainerCreateExceptionHeaders:Ee,ContainerGetPropertiesHeaders:_e,ContainerGetPropertiesExceptionHeaders:Pe,ContainerDeleteHeaders:Ce,ContainerDeleteExceptionHeaders:Oe,ContainerSetMetadataHeaders:Re,ContainerSetMetadataExceptionHeaders:De,ContainerGetAccessPolicyHeaders:Ae,ContainerGetAccessPolicyExceptionHeaders:Ie,ContainerSetAccessPolicyHeaders:Le,ContainerSetAccessPolicyExceptionHeaders:Me,ContainerRestoreHeaders:Be,ContainerRestoreExceptionHeaders:ke,ContainerRenameHeaders:ze,ContainerRenameExceptionHeaders:je,ContainerSubmitBatchHeaders:qe,ContainerSubmitBatchExceptionHeaders:Ue,ContainerFilterBlobsHeaders:Fe,ContainerFilterBlobsExceptionHeaders:He,ContainerAcquireLeaseHeaders:Ve,ContainerAcquireLeaseExceptionHeaders:Ge,ContainerReleaseLeaseHeaders:$e,ContainerReleaseLeaseExceptionHeaders:Xe,ContainerRenewLeaseHeaders:We,ContainerRenewLeaseExceptionHeaders:Ke,ContainerBreakLeaseHeaders:Qe,ContainerBreakLeaseExceptionHeaders:Ye,ContainerChangeLeaseHeaders:Je,ContainerChangeLeaseExceptionHeaders:Ze,ContainerListBlobFlatSegmentHeaders:et,ContainerListBlobFlatSegmentExceptionHeaders:tt,ContainerListBlobHierarchySegmentHeaders:rt,ContainerListBlobHierarchySegmentExceptionHeaders:it,ContainerGetAccountInfoHeaders:nt,ContainerGetAccountInfoExceptionHeaders:st,BlobDownloadHeaders:ot,BlobDownloadExceptionHeaders:pt,BlobGetPropertiesHeaders:dt,BlobGetPropertiesExceptionHeaders:ct,BlobDeleteHeaders:mt,BlobDeleteExceptionHeaders:ut,BlobUndeleteHeaders:ft,BlobUndeleteExceptionHeaders:ht,BlobSetExpiryHeaders:yt,BlobSetExpiryExceptionHeaders:vt,BlobSetHttpHeadersHeaders:bt,BlobSetHttpHeadersExceptionHeaders:xt,BlobSetImmutabilityPolicyHeaders:wt,BlobSetImmutabilityPolicyExceptionHeaders:St,BlobDeleteImmutabilityPolicyHeaders:Nt,BlobDeleteImmutabilityPolicyExceptionHeaders:Tt,BlobSetLegalHoldHeaders:Et,BlobSetLegalHoldExceptionHeaders:_t,BlobSetMetadataHeaders:Pt,BlobSetMetadataExceptionHeaders:Ct,BlobAcquireLeaseHeaders:Ot,BlobAcquireLeaseExceptionHeaders:Rt,BlobReleaseLeaseHeaders:Dt,BlobReleaseLeaseExceptionHeaders:At,BlobRenewLeaseHeaders:It,BlobRenewLeaseExceptionHeaders:Lt,BlobChangeLeaseHeaders:Mt,BlobChangeLeaseExceptionHeaders:Bt,BlobBreakLeaseHeaders:kt,BlobBreakLeaseExceptionHeaders:zt,BlobCreateSnapshotHeaders:jt,BlobCreateSnapshotExceptionHeaders:qt,BlobStartCopyFromURLHeaders:Ut,BlobStartCopyFromURLExceptionHeaders:Ft,BlobCopyFromURLHeaders:Ht,BlobCopyFromURLExceptionHeaders:Vt,BlobAbortCopyFromURLHeaders:Gt,BlobAbortCopyFromURLExceptionHeaders:$t,BlobSetTierHeaders:Xt,BlobSetTierExceptionHeaders:Wt,BlobGetAccountInfoHeaders:Kt,BlobGetAccountInfoExceptionHeaders:Qt,BlobQueryHeaders:Yt,BlobQueryExceptionHeaders:Jt,BlobGetTagsHeaders:Zt,BlobGetTagsExceptionHeaders:ea,BlobSetTagsHeaders:ta,BlobSetTagsExceptionHeaders:aa,PageBlobCreateHeaders:ra,PageBlobCreateExceptionHeaders:ia,PageBlobUploadPagesHeaders:na,PageBlobUploadPagesExceptionHeaders:sa,PageBlobClearPagesHeaders:oa,PageBlobClearPagesExceptionHeaders:pa,PageBlobUploadPagesFromURLHeaders:la,PageBlobUploadPagesFromURLExceptionHeaders:da,PageBlobGetPageRangesHeaders:ca,PageBlobGetPageRangesExceptionHeaders:ma,PageBlobGetPageRangesDiffHeaders:ua,PageBlobGetPageRangesDiffExceptionHeaders:fa,PageBlobResizeHeaders:ha,PageBlobResizeExceptionHeaders:ga,PageBlobUpdateSequenceNumberHeaders:ya,PageBlobUpdateSequenceNumberExceptionHeaders:va,PageBlobCopyIncrementalHeaders:ba,PageBlobCopyIncrementalExceptionHeaders:xa,AppendBlobCreateHeaders:wa,AppendBlobCreateExceptionHeaders:Sa,AppendBlobAppendBlockHeaders:Na,AppendBlobAppendBlockExceptionHeaders:Ta,AppendBlobAppendBlockFromUrlHeaders:Ea,AppendBlobAppendBlockFromUrlExceptionHeaders:_a,AppendBlobSealHeaders:Pa,AppendBlobSealExceptionHeaders:Ca,BlockBlobUploadHeaders:Oa,BlockBlobUploadExceptionHeaders:Ra,BlockBlobPutBlobFromUrlHeaders:Da,BlockBlobPutBlobFromUrlExceptionHeaders:Aa,BlockBlobStageBlockHeaders:Ia,BlockBlobStageBlockExceptionHeaders:La,BlockBlobStageBlockFromURLHeaders:Ma,BlockBlobStageBlockFromURLExceptionHeaders:Ba,BlockBlobCommitBlockListHeaders:ka,BlockBlobCommitBlockListExceptionHeaders:za,BlockBlobGetBlockListHeaders:ja,BlockBlobGetBlockListExceptionHeaders:qa});const Fa={parameterPath:["options","contentType"],mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Content-Type",type:{name:"String"}}};const Ha={parameterPath:"blobServiceProperties",mapper:x};const Va={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Ga={parameterPath:"url",mapper:{serializedName:"url",required:true,xmlName:"url",type:{name:"String"}},skipEncoding:true};const $a={parameterPath:"restype",mapper:{defaultValue:"service",isConstant:true,serializedName:"restype",type:{name:"String"}}};const Xa={parameterPath:"comp",mapper:{defaultValue:"properties",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Wa={parameterPath:["options","timeoutInSeconds"],mapper:{constraints:{InclusiveMinimum:0},serializedName:"timeout",xmlName:"timeout",type:{name:"Number"}}};const Ka={parameterPath:"version",mapper:{defaultValue:"2023-01-03",isConstant:true,serializedName:"x-ms-version",type:{name:"String"}}};const Qa={parameterPath:["options","requestId"],mapper:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}}};const Ya={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Ja={parameterPath:"comp",mapper:{defaultValue:"stats",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Za={parameterPath:"comp",mapper:{defaultValue:"list",isConstant:true,serializedName:"comp",type:{name:"String"}}};const er={parameterPath:["options","prefix"],mapper:{serializedName:"prefix",xmlName:"prefix",type:{name:"String"}}};const tr={parameterPath:["options","marker"],mapper:{serializedName:"marker",xmlName:"marker",type:{name:"String"}}};const ar={parameterPath:["options","maxPageSize"],mapper:{constraints:{InclusiveMinimum:1},serializedName:"maxresults",xmlName:"maxresults",type:{name:"Number"}}};const rr={parameterPath:["options","include"],mapper:{serializedName:"include",xmlName:"include",xmlElementName:"ListContainersIncludeType",type:{name:"Sequence",element:{type:{name:"Enum",allowedValues:["metadata","deleted","system"]}}}},collectionFormat:r.QueryCollectionFormat.Csv};const ir={parameterPath:"keyInfo",mapper:A};const nr={parameterPath:"comp",mapper:{defaultValue:"userdelegationkey",isConstant:true,serializedName:"comp",type:{name:"String"}}};const sr={parameterPath:"restype",mapper:{defaultValue:"account",isConstant:true,serializedName:"restype",type:{name:"String"}}};const or={parameterPath:"body",mapper:{serializedName:"body",required:true,xmlName:"body",type:{name:"Stream"}}};const pr={parameterPath:"comp",mapper:{defaultValue:"batch",isConstant:true,serializedName:"comp",type:{name:"String"}}};const lr={parameterPath:"contentLength",mapper:{serializedName:"Content-Length",required:true,xmlName:"Content-Length",type:{name:"Number"}}};const dr={parameterPath:"multipartContentType",mapper:{serializedName:"Content-Type",required:true,xmlName:"Content-Type",type:{name:"String"}}};const cr={parameterPath:"comp",mapper:{defaultValue:"blobs",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mr={parameterPath:["options","where"],mapper:{serializedName:"where",xmlName:"where",type:{name:"String"}}};const ur={parameterPath:"restype",mapper:{defaultValue:"container",isConstant:true,serializedName:"restype",type:{name:"String"}}};const fr={parameterPath:["options","metadata"],mapper:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-meta-"}};const hr={parameterPath:["options","access"],mapper:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}}};const gr={parameterPath:["options","containerEncryptionScope","defaultEncryptionScope"],mapper:{serializedName:"x-ms-default-encryption-scope",xmlName:"x-ms-default-encryption-scope",type:{name:"String"}}};const yr={parameterPath:["options","containerEncryptionScope","preventEncryptionScopeOverride"],mapper:{serializedName:"x-ms-deny-encryption-scope-override",xmlName:"x-ms-deny-encryption-scope-override",type:{name:"Boolean"}}};const vr={parameterPath:["options","leaseAccessConditions","leaseId"],mapper:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}}};const br={parameterPath:["options","modifiedAccessConditions","ifModifiedSince"],mapper:{serializedName:"If-Modified-Since",xmlName:"If-Modified-Since",type:{name:"DateTimeRfc1123"}}};const xr={parameterPath:["options","modifiedAccessConditions","ifUnmodifiedSince"],mapper:{serializedName:"If-Unmodified-Since",xmlName:"If-Unmodified-Since",type:{name:"DateTimeRfc1123"}}};const wr={parameterPath:"comp",mapper:{defaultValue:"metadata",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Sr={parameterPath:"comp",mapper:{defaultValue:"acl",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Nr={parameterPath:["options","containerAcl"],mapper:{serializedName:"containerAcl",xmlName:"SignedIdentifiers",xmlIsWrapped:true,xmlElementName:"SignedIdentifier",type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}}}};const Tr={parameterPath:"comp",mapper:{defaultValue:"undelete",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Er={parameterPath:["options","deletedContainerName"],mapper:{serializedName:"x-ms-deleted-container-name",xmlName:"x-ms-deleted-container-name",type:{name:"String"}}};const _r={parameterPath:["options","deletedContainerVersion"],mapper:{serializedName:"x-ms-deleted-container-version",xmlName:"x-ms-deleted-container-version",type:{name:"String"}}};const Pr={parameterPath:"comp",mapper:{defaultValue:"rename",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Cr={parameterPath:"sourceContainerName",mapper:{serializedName:"x-ms-source-container-name",required:true,xmlName:"x-ms-source-container-name",type:{name:"String"}}};const Or={parameterPath:["options","sourceLeaseId"],mapper:{serializedName:"x-ms-source-lease-id",xmlName:"x-ms-source-lease-id",type:{name:"String"}}};const Rr={parameterPath:"comp",mapper:{defaultValue:"lease",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Dr={parameterPath:"action",mapper:{defaultValue:"acquire",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const Ar={parameterPath:["options","duration"],mapper:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Number"}}};const Ir={parameterPath:["options","proposedLeaseId"],mapper:{serializedName:"x-ms-proposed-lease-id",xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}};const Lr={parameterPath:"action",mapper:{defaultValue:"release",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const Mr={parameterPath:"leaseId",mapper:{serializedName:"x-ms-lease-id",required:true,xmlName:"x-ms-lease-id",type:{name:"String"}}};const Br={parameterPath:"action",mapper:{defaultValue:"renew",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const kr={parameterPath:"action",mapper:{defaultValue:"break",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const zr={parameterPath:["options","breakPeriod"],mapper:{serializedName:"x-ms-lease-break-period",xmlName:"x-ms-lease-break-period",type:{name:"Number"}}};const jr={parameterPath:"action",mapper:{defaultValue:"change",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const qr={parameterPath:"proposedLeaseId",mapper:{serializedName:"x-ms-proposed-lease-id",required:true,xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}};const Ur={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:r.QueryCollectionFormat.Csv};const Fr={parameterPath:"delimiter",mapper:{serializedName:"delimiter",required:true,xmlName:"delimiter",type:{name:"String"}}};const Hr={parameterPath:["options","snapshot"],mapper:{serializedName:"snapshot",xmlName:"snapshot",type:{name:"String"}}};const Vr={parameterPath:["options","versionId"],mapper:{serializedName:"versionid",xmlName:"versionid",type:{name:"String"}}};const Gr={parameterPath:["options","range"],mapper:{serializedName:"x-ms-range",xmlName:"x-ms-range",type:{name:"String"}}};const $r={parameterPath:["options","rangeGetContentMD5"],mapper:{serializedName:"x-ms-range-get-content-md5",xmlName:"x-ms-range-get-content-md5",type:{name:"Boolean"}}};const Xr={parameterPath:["options","rangeGetContentCRC64"],mapper:{serializedName:"x-ms-range-get-content-crc64",xmlName:"x-ms-range-get-content-crc64",type:{name:"Boolean"}}};const Wr={parameterPath:["options","cpkInfo","encryptionKey"],mapper:{serializedName:"x-ms-encryption-key",xmlName:"x-ms-encryption-key",type:{name:"String"}}};const Kr={parameterPath:["options","cpkInfo","encryptionKeySha256"],mapper:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}}};const Qr={parameterPath:["options","cpkInfo","encryptionAlgorithm"],mapper:{serializedName:"x-ms-encryption-algorithm",xmlName:"x-ms-encryption-algorithm",type:{name:"String"}}};const Yr={parameterPath:["options","modifiedAccessConditions","ifMatch"],mapper:{serializedName:"If-Match",xmlName:"If-Match",type:{name:"String"}}};const Jr={parameterPath:["options","modifiedAccessConditions","ifNoneMatch"],mapper:{serializedName:"If-None-Match",xmlName:"If-None-Match",type:{name:"String"}}};const Zr={parameterPath:["options","modifiedAccessConditions","ifTags"],mapper:{serializedName:"x-ms-if-tags",xmlName:"x-ms-if-tags",type:{name:"String"}}};const ei={parameterPath:["options","deleteSnapshots"],mapper:{serializedName:"x-ms-delete-snapshots",xmlName:"x-ms-delete-snapshots",type:{name:"Enum",allowedValues:["include","only"]}}};const ti={parameterPath:["options","blobDeleteType"],mapper:{serializedName:"deletetype",xmlName:"deletetype",type:{name:"String"}}};const ai={parameterPath:"comp",mapper:{defaultValue:"expiry",isConstant:true,serializedName:"comp",type:{name:"String"}}};const ri={parameterPath:"expiryOptions",mapper:{serializedName:"x-ms-expiry-option",required:true,xmlName:"x-ms-expiry-option",type:{name:"String"}}};const ii={parameterPath:["options","expiresOn"],mapper:{serializedName:"x-ms-expiry-time",xmlName:"x-ms-expiry-time",type:{name:"String"}}};const ni={parameterPath:["options","blobHttpHeaders","blobCacheControl"],mapper:{serializedName:"x-ms-blob-cache-control",xmlName:"x-ms-blob-cache-control",type:{name:"String"}}};const si={parameterPath:["options","blobHttpHeaders","blobContentType"],mapper:{serializedName:"x-ms-blob-content-type",xmlName:"x-ms-blob-content-type",type:{name:"String"}}};const oi={parameterPath:["options","blobHttpHeaders","blobContentMD5"],mapper:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}}};const pi={parameterPath:["options","blobHttpHeaders","blobContentEncoding"],mapper:{serializedName:"x-ms-blob-content-encoding",xmlName:"x-ms-blob-content-encoding",type:{name:"String"}}};const li={parameterPath:["options","blobHttpHeaders","blobContentLanguage"],mapper:{serializedName:"x-ms-blob-content-language",xmlName:"x-ms-blob-content-language",type:{name:"String"}}};const di={parameterPath:["options","blobHttpHeaders","blobContentDisposition"],mapper:{serializedName:"x-ms-blob-content-disposition",xmlName:"x-ms-blob-content-disposition",type:{name:"String"}}};const ci={parameterPath:"comp",mapper:{defaultValue:"immutabilityPolicies",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mi={parameterPath:["options","immutabilityPolicyExpiry"],mapper:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}}};const ui={parameterPath:["options","immutabilityPolicyMode"],mapper:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}}};const fi={parameterPath:"comp",mapper:{defaultValue:"legalhold",isConstant:true,serializedName:"comp",type:{name:"String"}}};const hi={parameterPath:"legalHold",mapper:{serializedName:"x-ms-legal-hold",required:true,xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}};const gi={parameterPath:["options","encryptionScope"],mapper:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}}};const yi={parameterPath:"comp",mapper:{defaultValue:"snapshot",isConstant:true,serializedName:"comp",type:{name:"String"}}};const vi={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","Cold"]}}};const bi={parameterPath:["options","rehydratePriority"],mapper:{serializedName:"x-ms-rehydrate-priority",xmlName:"x-ms-rehydrate-priority",type:{name:"Enum",allowedValues:["High","Standard"]}}};const xi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfModifiedSince"],mapper:{serializedName:"x-ms-source-if-modified-since",xmlName:"x-ms-source-if-modified-since",type:{name:"DateTimeRfc1123"}}};const wi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfUnmodifiedSince"],mapper:{serializedName:"x-ms-source-if-unmodified-since",xmlName:"x-ms-source-if-unmodified-since",type:{name:"DateTimeRfc1123"}}};const Si={parameterPath:["options","sourceModifiedAccessConditions","sourceIfMatch"],mapper:{serializedName:"x-ms-source-if-match",xmlName:"x-ms-source-if-match",type:{name:"String"}}};const Ni={parameterPath:["options","sourceModifiedAccessConditions","sourceIfNoneMatch"],mapper:{serializedName:"x-ms-source-if-none-match",xmlName:"x-ms-source-if-none-match",type:{name:"String"}}};const Ti={parameterPath:["options","sourceModifiedAccessConditions","sourceIfTags"],mapper:{serializedName:"x-ms-source-if-tags",xmlName:"x-ms-source-if-tags",type:{name:"String"}}};const Ei={parameterPath:"copySource",mapper:{serializedName:"x-ms-copy-source",required:true,xmlName:"x-ms-copy-source",type:{name:"String"}}};const _i={parameterPath:["options","blobTagsString"],mapper:{serializedName:"x-ms-tags",xmlName:"x-ms-tags",type:{name:"String"}}};const Pi={parameterPath:["options","sealBlob"],mapper:{serializedName:"x-ms-seal-blob",xmlName:"x-ms-seal-blob",type:{name:"Boolean"}}};const Ci={parameterPath:["options","legalHold"],mapper:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}};const Oi={parameterPath:"xMsRequiresSync",mapper:{defaultValue:"true",isConstant:true,serializedName:"x-ms-requires-sync",type:{name:"String"}}};const Ri={parameterPath:["options","sourceContentMD5"],mapper:{serializedName:"x-ms-source-content-md5",xmlName:"x-ms-source-content-md5",type:{name:"ByteArray"}}};const Di={parameterPath:["options","copySourceAuthorization"],mapper:{serializedName:"x-ms-copy-source-authorization",xmlName:"x-ms-copy-source-authorization",type:{name:"String"}}};const Ai={parameterPath:["options","copySourceTags"],mapper:{serializedName:"x-ms-copy-source-tag-option",xmlName:"x-ms-copy-source-tag-option",type:{name:"Enum",allowedValues:["REPLACE","COPY"]}}};const Ii={parameterPath:"comp",mapper:{defaultValue:"copy",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Li={parameterPath:"copyActionAbortConstant",mapper:{defaultValue:"abort",isConstant:true,serializedName:"x-ms-copy-action",type:{name:"String"}}};const Mi={parameterPath:"copyId",mapper:{serializedName:"copyid",required:true,xmlName:"copyid",type:{name:"String"}}};const Bi={parameterPath:"comp",mapper:{defaultValue:"tier",isConstant:true,serializedName:"comp",type:{name:"String"}}};const ki={parameterPath:"tier",mapper:{serializedName:"x-ms-access-tier",required:true,xmlName:"x-ms-access-tier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive","Cold"]}}};const zi={parameterPath:["options","queryRequest"],mapper:te};const ji={parameterPath:"comp",mapper:{defaultValue:"query",isConstant:true,serializedName:"comp",type:{name:"String"}}};const qi={parameterPath:"comp",mapper:{defaultValue:"tags",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Ui={parameterPath:["options","tags"],mapper:B};const Fi={parameterPath:["options","transactionalContentMD5"],mapper:{serializedName:"Content-MD5",xmlName:"Content-MD5",type:{name:"ByteArray"}}};const Hi={parameterPath:["options","transactionalContentCrc64"],mapper:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}};const Vi={parameterPath:"blobType",mapper:{defaultValue:"PageBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const Gi={parameterPath:"blobContentLength",mapper:{serializedName:"x-ms-blob-content-length",required:true,xmlName:"x-ms-blob-content-length",type:{name:"Number"}}};const $i={parameterPath:["options","blobSequenceNumber"],mapper:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}}};const Xi={parameterPath:["options","contentType"],mapper:{defaultValue:"application/octet-stream",isConstant:true,serializedName:"Content-Type",type:{name:"String"}}};const Wi={parameterPath:"body",mapper:{serializedName:"body",required:true,xmlName:"body",type:{name:"Stream"}}};const Ki={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Qi={parameterPath:"comp",mapper:{defaultValue:"page",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Yi={parameterPath:"pageWrite",mapper:{defaultValue:"update",isConstant:true,serializedName:"x-ms-page-write",type:{name:"String"}}};const Ji={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThanOrEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-le",xmlName:"x-ms-if-sequence-number-le",type:{name:"Number"}}};const Zi={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThan"],mapper:{serializedName:"x-ms-if-sequence-number-lt",xmlName:"x-ms-if-sequence-number-lt",type:{name:"Number"}}};const en={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-eq",xmlName:"x-ms-if-sequence-number-eq",type:{name:"Number"}}};const tn={parameterPath:"pageWrite",mapper:{defaultValue:"clear",isConstant:true,serializedName:"x-ms-page-write",type:{name:"String"}}};const an={parameterPath:"sourceUrl",mapper:{serializedName:"x-ms-copy-source",required:true,xmlName:"x-ms-copy-source",type:{name:"String"}}};const rn={parameterPath:"sourceRange",mapper:{serializedName:"x-ms-source-range",required:true,xmlName:"x-ms-source-range",type:{name:"String"}}};const nn={parameterPath:["options","sourceContentCrc64"],mapper:{serializedName:"x-ms-source-content-crc64",xmlName:"x-ms-source-content-crc64",type:{name:"ByteArray"}}};const sn={parameterPath:"range",mapper:{serializedName:"x-ms-range",required:true,xmlName:"x-ms-range",type:{name:"String"}}};const on={parameterPath:"comp",mapper:{defaultValue:"pagelist",isConstant:true,serializedName:"comp",type:{name:"String"}}};const pn={parameterPath:["options","prevsnapshot"],mapper:{serializedName:"prevsnapshot",xmlName:"prevsnapshot",type:{name:"String"}}};const ln={parameterPath:["options","prevSnapshotUrl"],mapper:{serializedName:"x-ms-previous-snapshot-url",xmlName:"x-ms-previous-snapshot-url",type:{name:"String"}}};const dn={parameterPath:"sequenceNumberAction",mapper:{serializedName:"x-ms-sequence-number-action",required:true,xmlName:"x-ms-sequence-number-action",type:{name:"Enum",allowedValues:["max","update","increment"]}}};const cn={parameterPath:"comp",mapper:{defaultValue:"incrementalcopy",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mn={parameterPath:"blobType",mapper:{defaultValue:"AppendBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const un={parameterPath:"comp",mapper:{defaultValue:"appendblock",isConstant:true,serializedName:"comp",type:{name:"String"}}};const fn={parameterPath:["options","appendPositionAccessConditions","maxSize"],mapper:{serializedName:"x-ms-blob-condition-maxsize",xmlName:"x-ms-blob-condition-maxsize",type:{name:"Number"}}};const hn={parameterPath:["options","appendPositionAccessConditions","appendPosition"],mapper:{serializedName:"x-ms-blob-condition-appendpos",xmlName:"x-ms-blob-condition-appendpos",type:{name:"Number"}}};const gn={parameterPath:["options","sourceRange"],mapper:{serializedName:"x-ms-source-range",xmlName:"x-ms-source-range",type:{name:"String"}}};const yn={parameterPath:"comp",mapper:{defaultValue:"seal",isConstant:true,serializedName:"comp",type:{name:"String"}}};const vn={parameterPath:"blobType",mapper:{defaultValue:"BlockBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const bn={parameterPath:["options","copySourceBlobProperties"],mapper:{serializedName:"x-ms-copy-source-blob-properties",xmlName:"x-ms-copy-source-blob-properties",type:{name:"Boolean"}}};const xn={parameterPath:"comp",mapper:{defaultValue:"block",isConstant:true,serializedName:"comp",type:{name:"String"}}};const wn={parameterPath:"blockId",mapper:{serializedName:"blockid",required:true,xmlName:"blockid",type:{name:"String"}}};const Sn={parameterPath:"blocks",mapper:K};const Nn={parameterPath:"comp",mapper:{defaultValue:"blocklist",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Tn={parameterPath:"listType",mapper:{defaultValue:"committed",serializedName:"blocklisttype",required:true,xmlName:"blocklisttype",type:{name:"Enum",allowedValues:["committed","uncommitted","all"]}}};class Service{constructor(e){this.client=e}setProperties(e,t){const a={blobServiceProperties:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,_n)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Pn)}getStatistics(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Cn)}listContainersSegment(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,On)}getUserDelegationKey(e,t){const a={keyInfo:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Rn)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Dn)}submitBatch(e,t,a,r){const i={contentLength:e,multipartContentType:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,An)}filterBlobs(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,In)}}const En=new g.Serializer(Ua,true);const _n={path:"/",httpMethod:"PUT",responses:{202:{headersMapper:pe},default:{bodyMapper:_,headersMapper:le}},requestBody:Ha,queryParameters:[$a,Xa,Wa],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const Pn={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:x,headersMapper:de},default:{bodyMapper:_,headersMapper:ce}},queryParameters:[$a,Xa,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const Cn={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:P,headersMapper:me},default:{bodyMapper:_,headersMapper:ue}},queryParameters:[$a,Wa,Ja],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const On={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:O,headersMapper:fe},default:{bodyMapper:_,headersMapper:he}},queryParameters:[Wa,Za,er,tr,ar,rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const Rn={path:"/",httpMethod:"POST",responses:{200:{bodyMapper:I,headersMapper:ge},default:{bodyMapper:_,headersMapper:ye}},requestBody:ir,queryParameters:[$a,Wa,nr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const Dn={path:"/",httpMethod:"GET",responses:{200:{headersMapper:ve},default:{bodyMapper:_,headersMapper:be}},queryParameters:[Xa,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:En};const An={path:"/",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:xe},default:{bodyMapper:_,headersMapper:we}},requestBody:or,queryParameters:[Wa,pr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,lr,dr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const In={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:L,headersMapper:Se},default:{bodyMapper:_,headersMapper:Ne}},queryParameters:[Wa,tr,ar,cr,mr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};class Container{constructor(e){this.client=e}create(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Mn)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Bn)}delete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,kn)}setMetadata(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,zn)}getAccessPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,jn)}setAccessPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,qn)}restore(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Un)}rename(e,t){const a={sourceContainerName:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Fn)}submitBatch(e,t,a,r){const i={contentLength:e,multipartContentType:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Hn)}filterBlobs(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Vn)}acquireLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Gn)}releaseLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,$n)}renewLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Xn)}breakLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Wn)}changeLease(e,t,a){const r={leaseId:e,proposedLeaseId:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Kn)}listBlobFlatSegment(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Qn)}listBlobHierarchySegment(e,t){const a={delimiter:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Yn)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Jn)}}const Ln=new g.Serializer(Ua,true);const Mn={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Te},default:{bodyMapper:_,headersMapper:Ee}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,hr,gr,yr],isXML:true,serializer:Ln};const Bn={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:_e},default:{bodyMapper:_,headersMapper:Pe}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr],isXML:true,serializer:Ln};const kn={path:"/{containerName}",httpMethod:"DELETE",responses:{202:{headersMapper:Ce},default:{bodyMapper:_,headersMapper:Oe}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr],isXML:true,serializer:Ln};const zn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Re},default:{bodyMapper:_,headersMapper:De}},queryParameters:[Wa,ur,wr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br],isXML:true,serializer:Ln};const jn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}},serializedName:"SignedIdentifiers",xmlName:"SignedIdentifiers",xmlIsWrapped:true,xmlElementName:"SignedIdentifier"},headersMapper:Ae},default:{bodyMapper:_,headersMapper:Ie}},queryParameters:[Wa,ur,Sr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr],isXML:true,serializer:Ln};const qn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Le},default:{bodyMapper:_,headersMapper:Me}},requestBody:Nr,queryParameters:[Wa,ur,Sr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,hr,vr,br,xr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Ln};const Un={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Be},default:{bodyMapper:_,headersMapper:ke}},queryParameters:[Wa,ur,Tr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,Er,_r],isXML:true,serializer:Ln};const Fn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:ze},default:{bodyMapper:_,headersMapper:je}},queryParameters:[Wa,ur,Pr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,Cr,Or],isXML:true,serializer:Ln};const Hn={path:"/{containerName}",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:qe},default:{bodyMapper:_,headersMapper:Ue}},requestBody:or,queryParameters:[Wa,pr,ur],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,lr,dr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Ln};const Vn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:L,headersMapper:Fe},default:{bodyMapper:_,headersMapper:He}},queryParameters:[Wa,tr,ar,cr,mr,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Ln};const Gn={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Ve},default:{bodyMapper:_,headersMapper:Ge}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Dr,Ar,Ir],isXML:true,serializer:Ln};const $n={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:$e},default:{bodyMapper:_,headersMapper:Xe}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,Mr],isXML:true,serializer:Ln};const Xn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:We},default:{bodyMapper:_,headersMapper:Ke}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Mr,Br],isXML:true,serializer:Ln};const Wn={path:"/{containerName}",httpMethod:"PUT",responses:{202:{headersMapper:Qe},default:{bodyMapper:_,headersMapper:Ye}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,kr,zr],isXML:true,serializer:Ln};const Kn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Je},default:{bodyMapper:_,headersMapper:Ze}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Mr,jr,qr],isXML:true,serializer:Ln};const Qn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:q,headersMapper:et},default:{bodyMapper:_,headersMapper:tt}},queryParameters:[Wa,Za,er,tr,ar,ur,Ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Ln};const Yn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:$,headersMapper:rt},default:{bodyMapper:_,headersMapper:it}},queryParameters:[Wa,Za,er,tr,ar,ur,Ur,Fr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Ln};const Jn={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:nt},default:{bodyMapper:_,headersMapper:st}},queryParameters:[Xa,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:Ln};class Blob$1{constructor(e){this.client=e}download(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,es)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ts)}delete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,as)}undelete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,rs)}setExpiry(e,t){const a={expiryOptions:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,is)}setHttpHeaders(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ns)}setImmutabilityPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ss)}deleteImmutabilityPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,os)}setLegalHold(e,t){const a={legalHold:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ps)}setMetadata(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ls)}acquireLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ds)}releaseLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,cs)}renewLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ms)}changeLease(e,t,a){const r={leaseId:e,proposedLeaseId:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,us)}breakLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,fs)}createSnapshot(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,hs)}startCopyFromURL(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,gs)}copyFromURL(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ys)}abortCopyFromURL(e,t){const a={copyId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,vs)}setTier(e,t){const a={tier:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,bs)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,xs)}query(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ws)}getTags(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ss)}setTags(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ns)}}const Zn=new g.Serializer(Ua,true);const es={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ot},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ot},default:{bodyMapper:_,headersMapper:pt}},queryParameters:[Wa,Hr,Vr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,$r,Xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const ts={path:"/{containerName}/{blob}",httpMethod:"HEAD",responses:{200:{headersMapper:dt},default:{bodyMapper:_,headersMapper:ct}},queryParameters:[Wa,Hr,Vr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const as={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{202:{headersMapper:mt},default:{bodyMapper:_,headersMapper:ut}},queryParameters:[Wa,Hr,Vr,ti],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,ei],isXML:true,serializer:Zn};const rs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ft},default:{bodyMapper:_,headersMapper:ht}},queryParameters:[Wa,Tr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Zn};const is={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:yt},default:{bodyMapper:_,headersMapper:vt}},queryParameters:[Wa,ai],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,ri,ii],isXML:true,serializer:Zn};const ns={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:bt},default:{bodyMapper:_,headersMapper:xt}},queryParameters:[Xa,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,ni,si,oi,pi,li,di],isXML:true,serializer:Zn};const ss={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:wt},default:{bodyMapper:_,headersMapper:St}},queryParameters:[Wa,ci],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,xr,mi,ui],isXML:true,serializer:Zn};const os={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{200:{headersMapper:Nt},default:{bodyMapper:_,headersMapper:Tt}},queryParameters:[Wa,ci],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Zn};const ps={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Et},default:{bodyMapper:_,headersMapper:_t}},queryParameters:[Wa,fi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,hi],isXML:true,serializer:Zn};const ls={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Pt},default:{bodyMapper:_,headersMapper:Ct}},queryParameters:[Wa,wr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi],isXML:true,serializer:Zn};const ds={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ot},default:{bodyMapper:_,headersMapper:Rt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Dr,Ar,Ir,Yr,Jr,Zr],isXML:true,serializer:Zn};const cs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Dt},default:{bodyMapper:_,headersMapper:At}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,Mr,Yr,Jr,Zr],isXML:true,serializer:Zn};const ms={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:It},default:{bodyMapper:_,headersMapper:Lt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Mr,Br,Yr,Jr,Zr],isXML:true,serializer:Zn};const us={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Mt},default:{bodyMapper:_,headersMapper:Bt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Mr,jr,qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const fs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:kt},default:{bodyMapper:_,headersMapper:zt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,kr,zr,Yr,Jr,Zr],isXML:true,serializer:Zn};const hs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:jt},default:{bodyMapper:_,headersMapper:qt}},queryParameters:[Wa,yi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi],isXML:true,serializer:Zn};const gs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Ut},default:{bodyMapper:_,headersMapper:Ft}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Yr,Jr,Zr,mi,ui,vi,bi,xi,wi,Si,Ni,Ti,Ei,_i,Pi,Ci],isXML:true,serializer:Zn};const ys={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Ht},default:{bodyMapper:_,headersMapper:Vt}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Yr,Jr,Zr,mi,ui,gi,vi,xi,wi,Si,Ni,Ei,_i,Ci,Oi,Ri,Di,Ai],isXML:true,serializer:Zn};const vs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:Gt},default:{bodyMapper:_,headersMapper:$t}},queryParameters:[Wa,Ii,Mi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Li],isXML:true,serializer:Zn};const bs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Xt},202:{headersMapper:Xt},default:{bodyMapper:_,headersMapper:Wt}},queryParameters:[Wa,Hr,Vr,Bi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr,bi,ki],isXML:true,serializer:Zn};const xs={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{headersMapper:Kt},default:{bodyMapper:_,headersMapper:Qt}},queryParameters:[Xa,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:Zn};const ws={path:"/{containerName}/{blob}",httpMethod:"POST",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Yt},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Yt},default:{bodyMapper:_,headersMapper:Jt}},requestBody:zi,queryParameters:[Wa,Hr,ji],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Zn};const Ss={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:B,headersMapper:Zt},default:{bodyMapper:_,headersMapper:ea}},queryParameters:[Wa,Hr,Vr,qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr],isXML:true,serializer:Zn};const Ns={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:ta},default:{bodyMapper:_,headersMapper:aa}},requestBody:Ui,queryParameters:[Wa,Vr,qi],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,vr,Zr,Fi,Hi],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Zn};class PageBlob{constructor(e){this.client=e}create(e,t,a){const r={contentLength:e,blobContentLength:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,_s)}uploadPages(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Ps)}clearPages(e,t){const a={contentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Cs)}uploadPagesFromURL(e,t,a,r,i){const n={sourceUrl:e,sourceRange:t,contentLength:a,range:r,options:g.operationOptionsToRequestOptionsBase(i||{})};return this.client.sendOperationRequest(n,Os)}getPageRanges(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Rs)}getPageRangesDiff(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ds)}resize(e,t){const a={blobContentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,As)}updateSequenceNumber(e,t){const a={sequenceNumberAction:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Is)}copyIncremental(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Ls)}}const Ts=new g.Serializer(Ua,true);const Es=new g.Serializer(Ua,false);const _s={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ra},default:{bodyMapper:_,headersMapper:ia}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Vi,Gi,$i],isXML:true,serializer:Ts};const Ps={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:na},default:{bodyMapper:_,headersMapper:sa}},requestBody:Wi,queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,br,xr,Gr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Fi,Hi,Xi,Ki,Yi,Ji,Zi,en],mediaType:"binary",serializer:Es};const Cs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:oa},default:{bodyMapper:_,headersMapper:pa}},queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Gr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Ji,Zi,en,tn],isXML:true,serializer:Ts};const Os={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:la},default:{bodyMapper:_,headersMapper:da}},queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,xi,wi,Si,Ni,Ri,Di,Yi,Ji,Zi,en,an,rn,nn,sn],isXML:true,serializer:Ts};const Rs={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:J,headersMapper:ca},default:{bodyMapper:_,headersMapper:ma}},queryParameters:[Wa,tr,ar,Hr,on],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Yr,Jr,Zr],isXML:true,serializer:Ts};const Ds={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:J,headersMapper:ua},default:{bodyMapper:_,headersMapper:fa}},queryParameters:[Wa,tr,ar,Hr,on,pn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Yr,Jr,Zr,ln],isXML:true,serializer:Ts};const As={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ha},default:{bodyMapper:_,headersMapper:ga}},queryParameters:[Xa,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Gi],isXML:true,serializer:Ts};const Is={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ya},default:{bodyMapper:_,headersMapper:va}},queryParameters:[Xa,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,$i,dn],isXML:true,serializer:Ts};const Ls={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:ba},default:{bodyMapper:_,headersMapper:xa}},queryParameters:[Wa,cn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Yr,Jr,Zr,Ei],isXML:true,serializer:Ts};class AppendBlob{constructor(e){this.client=e}create(e,t){const a={contentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ks)}appendBlock(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,zs)}appendBlockFromUrl(e,t,a){const r={sourceUrl:e,contentLength:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,js)}seal(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,qs)}}const Ms=new g.Serializer(Ua,true);const Bs=new g.Serializer(Ua,false);const ks={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:wa},default:{bodyMapper:_,headersMapper:Sa}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,_i,Ci,mn],isXML:true,serializer:Ms};const zs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Na},default:{bodyMapper:_,headersMapper:Ta}},requestBody:Wi,queryParameters:[Wa,un],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Fi,Hi,Xi,Ki,fn,hn],mediaType:"binary",serializer:Bs};const js={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ea},default:{bodyMapper:_,headersMapper:_a}},queryParameters:[Wa,un],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,xi,wi,Si,Ni,Ri,Di,Fi,an,nn,fn,hn,gn],isXML:true,serializer:Ms};const qs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Pa},default:{bodyMapper:_,headersMapper:Ca}},queryParameters:[Wa,yn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,hn],isXML:true,serializer:Ms};class BlockBlob{constructor(e){this.client=e}upload(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Hs)}putBlobFromUrl(e,t,a){const r={contentLength:e,copySource:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Vs)}stageBlock(e,t,a,r){const i={blockId:e,contentLength:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Gs)}stageBlockFromURL(e,t,a,r){const i={blockId:e,contentLength:t,sourceUrl:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,$s)}commitBlockList(e,t){const a={blocks:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Xs)}getBlockList(e,t){const a={listType:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Ws)}}const Us=new g.Serializer(Ua,true);const Fs=new g.Serializer(Ua,false);const Hs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Oa},default:{bodyMapper:_,headersMapper:Ra}},requestBody:Wi,queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Fi,Hi,Xi,Ki,vn],mediaType:"binary",serializer:Fs};const Vs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Da},default:{bodyMapper:_,headersMapper:Aa}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,gi,vi,xi,wi,Si,Ni,Ti,Ei,_i,Ri,Di,Ai,Fi,vn,bn],isXML:true,serializer:Us};const Gs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ia},default:{bodyMapper:_,headersMapper:La}},requestBody:Wi,queryParameters:[Wa,xn,wn],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,Wr,Kr,Qr,gi,Fi,Hi,Xi,Ki],mediaType:"binary",serializer:Fs};const $s={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ma},default:{bodyMapper:_,headersMapper:Ba}},queryParameters:[Wa,xn,wn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,Wr,Kr,Qr,gi,xi,wi,Si,Ni,Ri,Di,an,nn,gn],isXML:true,serializer:Us};const Xs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ka},default:{bodyMapper:_,headersMapper:za}},requestBody:Sn,queryParameters:[Wa,Nn],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Fi,Hi],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Us};const Ws={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:Q,headersMapper:ja},default:{bodyMapper:_,headersMapper:qa}},queryParameters:[Wa,Hr,Nn,Tn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr],isXML:true,serializer:Us};const Ks=s.createClientLogger("storage-blob");const Qs="12.15.0";const Ys="2023-01-03";const Js=256*1024*1024;const Zs=4e3*1024*1024;const eo=5e4;const to=8*1024*1024;const ao=4*1024*1024;const ro=5;const io=100*1e3;const no="https://storage.azure.com/.default";const so={Parameters:{FORCE_BROWSER_NO_CACHE:"_",SIGNATURE:"sig",SNAPSHOT:"snapshot",VERSIONID:"versionid",TIMEOUT:"timeout"}};const oo={HTTP_ACCEPTED:202,HTTP_CONFLICT:409,HTTP_NOT_FOUND:404,HTTP_PRECON_FAILED:412,HTTP_RANGE_NOT_SATISFIABLE:416};const po={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"};const lo="";const co="*";const mo=1*1024*1024;const uo=256;const fo=4*mo;const ho="\r\n";const go="HTTP/1.1";const yo="AES256";const vo=`DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;`;const bo=["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"];const xo=["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"];const wo="BlobUsesCustomerSpecifiedEncryption";const So="BlobDoesNotUseCustomerSpecifiedEncryption";const No=["10000","10001","10002","10003","10004","10100","10101","10102","10103","10104","11000","11001","11002","11003","11004","11100","11101","11102","11103","11104"];function escapeURLPath(e){const t=r.URLBuilder.parse(e);let a=t.getPath();a=a||"/";a=escape(a);t.setPath(a);return t.toString()}function getProxyUriFromDevConnString(e){let t="";if(e.search("DevelopmentStorageProxyUri=")!==-1){const a=e.split(";");for(const e of a){if(e.trim().startsWith("DevelopmentStorageProxyUri=")){t=e.trim().match("DevelopmentStorageProxyUri=(.*)")[1]}}}return t}function getValueInConnString(e,t){const a=e.split(";");for(const e of a){if(e.trim().startsWith(t)){return e.trim().match(t+"=(.*)")[1]}}return""}function extractConnectionStringParts(e){let t="";if(e.startsWith("UseDevelopmentStorage=true")){t=getProxyUriFromDevConnString(e);e=vo}let a=getValueInConnString(e,"BlobEndpoint");a=a.endsWith("/")?a.slice(0,-1):a;if(e.search("DefaultEndpointsProtocol=")!==-1&&e.search("AccountKey=")!==-1){let r="";let i="";let n=Buffer.from("accountKey","base64");let s="";i=getValueInConnString(e,"AccountName");n=Buffer.from(getValueInConnString(e,"AccountKey"),"base64");if(!a){r=getValueInConnString(e,"DefaultEndpointsProtocol");const t=r.toLowerCase();if(t!=="https"&&t!=="http"){throw new Error("Invalid DefaultEndpointsProtocol in the provided Connection String. Expecting 'https' or 'http'")}s=getValueInConnString(e,"EndpointSuffix");if(!s){throw new Error("Invalid EndpointSuffix in the provided Connection String")}a=`${r}://${i}.blob.${s}`}if(!i){throw new Error("Invalid AccountName in the provided Connection String")}else if(n.length===0){throw new Error("Invalid AccountKey in the provided Connection String")}return{kind:"AccountConnString",url:a,accountName:i,accountKey:n,proxyUri:t}}else{const t=getValueInConnString(e,"SharedAccessSignature");const r=getAccountNameFromUrl(a);if(!a){throw new Error("Invalid BlobEndpoint in the provided SAS Connection String")}else if(!t){throw new Error("Invalid SharedAccessSignature in the provided SAS Connection String")}return{kind:"SASConnString",url:a,accountName:r,accountSas:t}}}function escape(e){return encodeURIComponent(e).replace(/%2F/g,"/").replace(/'/g,"%27").replace(/\+/g,"%20").replace(/%25/g,"%")}function appendToURLPath(e,t){const a=r.URLBuilder.parse(e);let i=a.getPath();i=i?i.endsWith("/")?`${i}${t}`:`${i}/${t}`:t;a.setPath(i);const n=new URL(a.toString());return n.toString()}function setURLParameter(e,t,a){const i=r.URLBuilder.parse(e);i.setQueryParameter(t,a);return i.toString()}function getURLParameter(e,t){const a=r.URLBuilder.parse(e);return a.getQueryParameterValue(t)}function setURLHost(e,t){const a=r.URLBuilder.parse(e);a.setHost(t);return a.toString()}function getURLPath(e){const t=r.URLBuilder.parse(e);return t.getPath()}function getURLScheme(e){const t=r.URLBuilder.parse(e);return t.getScheme()}function getURLPathAndQuery(e){const t=r.URLBuilder.parse(e);const a=t.getPath();if(!a){throw new RangeError("Invalid url without valid path.")}let i=t.getQuery()||"";i=i.trim();if(i!==""){i=i.startsWith("?")?i:`?${i}`}return`${a}${i}`}function getURLQueries(e){let t=r.URLBuilder.parse(e).getQuery();if(!t){return{}}t=t.trim();t=t.startsWith("?")?t.substr(1):t;let a=t.split("&");a=a.filter((e=>{const t=e.indexOf("=");const a=e.lastIndexOf("=");return t>0&&t===a&&ai){e=e.slice(0,i)}const n=e+padStart(t.toString(),a-e.length,"0");return base64encode(n)}async function delay(e,t,a){return new Promise(((r,i)=>{let n;const abortHandler=()=>{if(n!==undefined){clearTimeout(n)}i(a)};const resolveHandler=()=>{if(t!==undefined){t.removeEventListener("abort",abortHandler)}r()};n=setTimeout(resolveHandler,e);if(t!==undefined){t.addEventListener("abort",abortHandler)}}))}function padStart(e,t,a=" "){if(String.prototype.padStart){return e.padStart(t,a)}a=a||" ";if(e.length>t){return e}else{t=t-e.length;if(t>a.length){a+=a.repeat(t/a.length)}return a.slice(0,t)+e}}function iEqual(e,t){return e.toLocaleLowerCase()===t.toLocaleLowerCase()}function getAccountNameFromUrl(e){const t=r.URLBuilder.parse(e);let a;try{if(t.getHost().split(".")[1]==="blob"){a=t.getHost().split(".")[0]}else if(isIpEndpointStyle(t)){a=t.getPath().split("/")[1]}else{a=""}return a}catch(e){throw new Error("Unable to extract accountName with provided information.")}}function isIpEndpointStyle(e){if(e.getHost()===undefined){return false}const t=e.getHost()+(e.getPort()===undefined?"":":"+e.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(t)||e.getPort()!==undefined&&No.includes(e.getPort())}function toBlobTagsString(e){if(e===undefined){return undefined}const t=[];for(const a in e){if(Object.prototype.hasOwnProperty.call(e,a)){const r=e[a];t.push(`${encodeURIComponent(a)}=${encodeURIComponent(r)}`)}}return t.join("&")}function toBlobTags(e){if(e===undefined){return undefined}const t={blobTagSet:[]};for(const a in e){if(Object.prototype.hasOwnProperty.call(e,a)){const r=e[a];t.blobTagSet.push({key:a,value:r})}}return t}function toTags(e){if(e===undefined){return undefined}const t={};for(const a of e.blobTagSet){t[a.key]=a.value}return t}function toQuerySerialization(e){if(e===undefined){return undefined}switch(e.kind){case"csv":return{format:{type:"delimited",delimitedTextConfiguration:{columnSeparator:e.columnSeparator||",",fieldQuote:e.fieldQuote||"",recordSeparator:e.recordSeparator,escapeChar:e.escapeCharacter||"",headersPresent:e.hasHeaders||false}}};case"json":return{format:{type:"json",jsonTextConfiguration:{recordSeparator:e.recordSeparator}}};case"arrow":return{format:{type:"arrow",arrowConfiguration:{schema:e.schema}}};case"parquet":return{format:{type:"parquet"}};default:throw Error("Invalid BlobQueryTextConfiguration.")}}function parseObjectReplicationRecord(e){if(!e){return undefined}if("policy-id"in e){return undefined}const t=[];for(const a in e){const r=a.split("_");const i="or-";if(r[0].startsWith(i)){r[0]=r[0].substring(i.length)}const n={ruleId:r[1],replicationStatus:e[a]};const s=t.findIndex((e=>e.policyId===r[0]));if(s>-1){t[s].rules.push(n)}else{t.push({policyId:r[0],rules:[n]})}}return t}function attachCredential(e,t){e.credential=t;return e}function httpAuthorizationToString(e){return e?e.scheme+" "+e.value:undefined}function BlobNameToString(e){if(e.encoded){return decodeURIComponent(e.content)}else{return e.content}}function ConvertInternalResponseOfListBlobFlat(e){return Object.assign(Object.assign({},e),{segment:{blobItems:e.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))}})}function ConvertInternalResponseOfListBlobHierarchy(e){var t;return Object.assign(Object.assign({},e),{segment:{blobPrefixes:(t=e.segment.blobPrefixes)===null||t===void 0?void 0:t.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t})),blobItems:e.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))}})}function*ExtractPageRangeInfoItems(e){let t=[];let a=[];if(e.pageRange)t=e.pageRange;if(e.clearRange)a=e.clearRange;let r=0;let i=0;while(r=1?Math.floor(a.maxTries):To.maxTries,tryTimeoutInMs:a.tryTimeoutInMs&&a.tryTimeoutInMs>=0?a.tryTimeoutInMs:To.tryTimeoutInMs,retryDelayInMs:a.retryDelayInMs&&a.retryDelayInMs>=0?Math.min(a.retryDelayInMs,a.maxRetryDelayInMs?a.maxRetryDelayInMs:To.maxRetryDelayInMs):To.retryDelayInMs,maxRetryDelayInMs:a.maxRetryDelayInMs&&a.maxRetryDelayInMs>=0?a.maxRetryDelayInMs:To.maxRetryDelayInMs,secondaryHost:a.secondaryHost?a.secondaryHost:To.secondaryHost}}async sendRequest(e){return this.attemptSendRequest(e,false,1)}async attemptSendRequest(e,t,a){const r=e.clone();const i=t||!this.retryOptions.secondaryHost||!(e.method==="GET"||e.method==="HEAD"||e.method==="OPTIONS")||a%2===1;if(!i){r.url=setURLHost(r.url,this.retryOptions.secondaryHost)}if(this.retryOptions.tryTimeoutInMs){r.url=setURLParameter(r.url,so.Parameters.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString())}let n;try{Ks.info(`RetryPolicy: =====> Try=${a} ${i?"Primary":"Secondary"}`);n=await this._nextPolicy.sendRequest(r);if(!this.shouldRetry(i,a,n)){return n}t=t||!i&&n.status===404}catch(e){Ks.error(`RetryPolicy: Caught error, message: ${e.message}, code: ${e.code}`);if(!this.shouldRetry(i,a,n,e)){throw e}}await this.delay(i,a,e.abortSignal);return this.attemptSendRequest(e,t,++a)}shouldRetry(e,t,a,r){if(t>=this.retryOptions.maxTries){Ks.info(`RetryPolicy: Attempt(s) ${t} >= maxTries ${this.retryOptions.maxTries}, no further try.`);return false}const i=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(r){for(const e of i){if(r.name.toUpperCase().includes(e)||r.message.toUpperCase().includes(e)||r.code&&r.code.toString().toUpperCase()===e){Ks.info(`RetryPolicy: Network error ${e} found, will retry.`);return true}}}if(a||r){const t=a?a.status:r?r.statusCode:0;if(!e&&t===404){Ks.info(`RetryPolicy: Secondary access with 404, will retry.`);return true}if(t===503||t===500){Ks.info(`RetryPolicy: Will retry for status code ${t}.`);return true}}if((r===null||r===void 0?void 0:r.code)==="PARSE_ERROR"&&(r===null||r===void 0?void 0:r.message.startsWith(`Error "Error: Unclosed root tag`))){Ks.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry.");return true}return false}async delay(e,a,r){let i=0;if(e){switch(this.retryOptions.retryPolicyType){case t.StorageRetryPolicyType.EXPONENTIAL:i=Math.min((Math.pow(2,a-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;case t.StorageRetryPolicyType.FIXED:i=this.retryOptions.retryDelayInMs;break}}else{i=Math.random()*1e3}Ks.info(`RetryPolicy: Delay for ${i}ms`);return delay(i,r,Eo)}}class StorageRetryPolicyFactory{constructor(e){this.retryOptions=e}create(e,t){return new StorageRetryPolicy(e,t,this.retryOptions)}}class CredentialPolicy extends r.BaseRequestPolicy{sendRequest(e){return this._nextPolicy.sendRequest(this.signRequest(e))}signRequest(e){return e}}class AnonymousCredentialPolicy extends CredentialPolicy{constructor(e,t){super(e,t)}}class Credential{create(e,t){throw new Error("Method should be implemented in children classes.")}}class AnonymousCredential extends Credential{create(e,t){return new AnonymousCredentialPolicy(e,t)}}class TelemetryPolicy extends r.BaseRequestPolicy{constructor(e,t,a){super(e,t);this.telemetry=a}async sendRequest(e){if(r.isNode){if(!e.headers){e.headers=new r.HttpHeaders}if(!e.headers.get(po.USER_AGENT)){e.headers.set(po.USER_AGENT,this.telemetry)}}return this._nextPolicy.sendRequest(e)}}class TelemetryPolicyFactory{constructor(e){const t=[];if(r.isNode){if(e){const a=e.userAgentPrefix||"";if(a.length>0&&t.indexOf(a)===-1){t.push(a)}}const a=`azsdk-js-storageblob/${Qs}`;if(t.indexOf(a)===-1){t.push(a)}let r=`(NODE-VERSION ${process.version})`;if(y){r=`(NODE-VERSION ${process.version}; ${y.type()} ${y.release()})`}if(t.indexOf(r)===-1){t.push(r)}}this.telemetryString=t.join(" ")}create(e,t){return new TelemetryPolicy(e,t,this.telemetryString)}}const _o=new r.DefaultHttpClient;function getCachedDefaultHttpClient(){return _o}const Po={DefaultScope:"/.default",HeaderConstants:{AUTHORIZATION:"authorization"}};const Co={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function beginRefresh(e,t,a){async function tryGetAccessToken(){if(Date.now()e.getToken(t,a);r=beginRefresh(tryGetAccessToken,n.retryIntervalInMs,(o=i===null||i===void 0?void 0:i.expiresOnTimestamp)!==null&&o!==void 0?o:Date.now()).then((e=>{r=null;i=e;return i})).catch((e=>{r=null;i=null;throw e}))}return r}return async e=>{if(s.mustRefresh)return refresh(e);if(s.shouldRefresh){refresh(e)}return i}}function getChallenge(e){const t=e.headers.get("WWW-Authenticate");if(e.status===401&&t){return t}return}function parseChallenge(e){const t=e.slice("Bearer ".length);const a=`${t.trim()} `.split(" ").filter((e=>e));const r=a.map((e=>(([e,t])=>({[e]:t}))(e.trim().split("="))));return r.reduce(((e,t)=>Object.assign(Object.assign({},e),t)),{})}function storageBearerTokenChallengeAuthenticationPolicy(e,t){let a=createTokenCycler(e,t);class StorageBearerTokenChallengeAuthenticationPolicy extends r.BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(t){if(!t.url.toLowerCase().startsWith("https://")){throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.")}const i=a;const n=(await i({abortSignal:t.abortSignal,tracingOptions:{tracingContext:t.tracingContext}})).token;t.headers.set(Po.HeaderConstants.AUTHORIZATION,`Bearer ${n}`);const s=await this._nextPolicy.sendRequest(t);if((s===null||s===void 0?void 0:s.status)===401){const i=getChallenge(s);if(i){const n=parseChallenge(i);const s=n.resource_id+Po.DefaultScope;const o=r.URLBuilder.parse(n.authorization_uri);const p=o.getPath().split("/");const l=p[1];const d=createTokenCycler(e,s);const c=(await d({abortSignal:t.abortSignal,tracingOptions:{tracingContext:t.tracingContext},tenantId:l})).token;a=d;t.headers.set(Po.HeaderConstants.AUTHORIZATION,`Bearer ${c}`);return this._nextPolicy.sendRequest(t)}}return s}}return{create:(e,t)=>new StorageBearerTokenChallengeAuthenticationPolicy(e,t)}}function isPipelineLike(e){if(!e||typeof e!=="object"){return false}const t=e;return Array.isArray(t.factories)&&typeof t.options==="object"&&typeof t.toServiceClientOptions==="function"}class Pipeline{constructor(e,t={}){this.factories=e;this.options=Object.assign(Object.assign({},t),{httpClient:t.httpClient||getCachedDefaultHttpClient()})}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}}function newPipeline(e,t={}){var a;if(e===undefined){e=new AnonymousCredential}const i=new TelemetryPolicyFactory(t.userAgentOptions);const n=[r.tracingPolicy({userAgent:i.telemetryString}),r.keepAlivePolicy(t.keepAliveOptions),i,r.generateClientRequestIdPolicy(),new StorageBrowserPolicyFactory,new StorageRetryPolicyFactory(t.retryOptions),r.deserializationPolicy(undefined,{xmlCharKey:"#"}),r.logPolicy({logger:Ks.info,allowedHeaderNames:bo,allowedQueryParameters:xo})];if(r.isNode){n.push(r.proxyPolicy(t.proxyOptions));n.push(r.disableResponseDecompressionPolicy())}n.push(r.isTokenCredential(e)?attachCredential(storageBearerTokenChallengeAuthenticationPolicy(e,(a=t.audience)!==null&&a!==void 0?a:no),e):e);return new Pipeline(n,t)}class StorageSharedKeyCredentialPolicy extends CredentialPolicy{constructor(e,t,a){super(e,t);this.factory=a}signRequest(e){e.headers.set(po.X_MS_DATE,(new Date).toUTCString());if(e.body&&(typeof e.body==="string"||e.body!==undefined)&&e.body.length>0){e.headers.set(po.CONTENT_LENGTH,Buffer.byteLength(e.body))}const t=[e.method.toUpperCase(),this.getHeaderValueToSign(e,po.CONTENT_LANGUAGE),this.getHeaderValueToSign(e,po.CONTENT_ENCODING),this.getHeaderValueToSign(e,po.CONTENT_LENGTH),this.getHeaderValueToSign(e,po.CONTENT_MD5),this.getHeaderValueToSign(e,po.CONTENT_TYPE),this.getHeaderValueToSign(e,po.DATE),this.getHeaderValueToSign(e,po.IF_MODIFIED_SINCE),this.getHeaderValueToSign(e,po.IF_MATCH),this.getHeaderValueToSign(e,po.IF_NONE_MATCH),this.getHeaderValueToSign(e,po.IF_UNMODIFIED_SINCE),this.getHeaderValueToSign(e,po.RANGE)].join("\n")+"\n"+this.getCanonicalizedHeadersString(e)+this.getCanonicalizedResourceString(e);const a=this.factory.computeHMACSHA256(t);e.headers.set(po.AUTHORIZATION,`SharedKey ${this.factory.accountName}:${a}`);return e}getHeaderValueToSign(e,t){const a=e.headers.get(t);if(!a){return""}if(t===po.CONTENT_LENGTH&&a==="0"){return""}return a}getCanonicalizedHeadersString(e){let t=e.headers.headersArray().filter((e=>e.name.toLowerCase().startsWith(po.PREFIX_FOR_STORAGE)));t.sort(((e,t)=>e.name.toLowerCase().localeCompare(t.name.toLowerCase())));t=t.filter(((e,t,a)=>{if(t>0&&e.name.toLowerCase()===a[t-1].name.toLowerCase()){return false}return true}));let a="";t.forEach((e=>{a+=`${e.name.toLowerCase().trimRight()}:${e.value.trimLeft()}\n`}));return a}getCanonicalizedResourceString(e){const t=getURLPath(e.url)||"/";let a="";a+=`/${this.factory.accountName}${t}`;const r=getURLQueries(e.url);const i={};if(r){const e=[];for(const t in r){if(Object.prototype.hasOwnProperty.call(r,t)){const a=t.toLowerCase();i[a]=r[t];e.push(a)}}e.sort();for(const t of e){a+=`\n${t}:${decodeURIComponent(i[t])}`}}return a}}class StorageSharedKeyCredential extends Credential{constructor(e,t){super();this.accountName=e;this.accountKey=Buffer.from(t,"base64")}create(e,t){return new StorageSharedKeyCredentialPolicy(e,t,this)}computeHMACSHA256(e){return l.createHmac("sha256",this.accountKey).update(e,"utf8").digest("base64")}}const Oo="azure-storage-blob";const Ro="12.15.0";class StorageClientContext extends g.ServiceClient{constructor(e,t){if(e===undefined){throw new Error("'url' cannot be null")}if(!t){t={}}if(!t.userAgent){const e=g.getDefaultUserAgentValue();t.userAgent=`${Oo}/${Ro} ${e}`}super(undefined,t);this.requestContentType="application/json; charset=utf-8";this.baseUri=t.endpoint||"{url}";this.url=e;this.version=t.version||"2023-01-03"}}class StorageClient{constructor(e,t){this.url=escapeURLPath(e);this.accountName=getAccountNameFromUrl(e);this.pipeline=t;this.storageClientContext=new StorageClientContext(this.url,t.toServiceClientOptions());this.isHttps=iEqual(getURLScheme(this.url)||"","https");this.credential=new AnonymousCredential;for(const e of this.pipeline.factories){if(r.isNode&&e instanceof StorageSharedKeyCredential||e instanceof AnonymousCredential){this.credential=e}else if(r.isTokenCredential(e.credential)){this.credential=e.credential}}const a=this.storageClientContext;a.requestContentType=undefined}}const Do=n.createSpanFunction({packagePrefix:"Azure.Storage.Blob",namespace:"Microsoft.Storage"});function convertTracingToRequestOptionsBase(e){var t,a;return{spanOptions:(t=e===null||e===void 0?void 0:e.tracingOptions)===null||t===void 0?void 0:t.spanOptions,tracingContext:(a=e===null||e===void 0?void 0:e.tracingOptions)===null||a===void 0?void 0:a.tracingContext}}class BlobSASPermissions{constructor(){this.read=false;this.add=false;this.create=false;this.write=false;this.delete=false;this.deleteVersion=false;this.tag=false;this.move=false;this.execute=false;this.setImmutabilityPolicy=false;this.permanentDelete=false}static parse(e){const t=new BlobSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"x":t.deleteVersion=true;break;case"t":t.tag=true;break;case"m":t.move=true;break;case"e":t.execute=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;default:throw new RangeError(`Invalid permission: ${a}`)}}return t}static from(e){const t=new BlobSASPermissions;if(e.read){t.read=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.deleteVersion){t.deleteVersion=true}if(e.tag){t.tag=true}if(e.move){t.move=true}if(e.execute){t.execute=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.tag){e.push("t")}if(this.move){e.push("m")}if(this.execute){e.push("e")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}return e.join("")}}class ContainerSASPermissions{constructor(){this.read=false;this.add=false;this.create=false;this.write=false;this.delete=false;this.deleteVersion=false;this.list=false;this.tag=false;this.move=false;this.execute=false;this.setImmutabilityPolicy=false;this.permanentDelete=false;this.filterByTags=false}static parse(e){const t=new ContainerSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"l":t.list=true;break;case"t":t.tag=true;break;case"x":t.deleteVersion=true;break;case"m":t.move=true;break;case"e":t.execute=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;case"f":t.filterByTags=true;break;default:throw new RangeError(`Invalid permission ${a}`)}}return t}static from(e){const t=new ContainerSASPermissions;if(e.read){t.read=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.list){t.list=true}if(e.deleteVersion){t.deleteVersion=true}if(e.tag){t.tag=true}if(e.move){t.move=true}if(e.execute){t.execute=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}if(e.filterByTags){t.filterByTags=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.list){e.push("l")}if(this.tag){e.push("t")}if(this.move){e.push("m")}if(this.execute){e.push("e")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}if(this.filterByTags){e.push("f")}return e.join("")}}class UserDelegationKeyCredential{constructor(e,t){this.accountName=e;this.userDelegationKey=t;this.key=Buffer.from(t.value,"base64")}computeHMACSHA256(e){return l.createHmac("sha256",this.key).update(e,"utf8").digest("base64")}}function ipRangeToString(e){return e.end?`${e.start}-${e.end}`:e.start}t.SASProtocol=void 0;(function(e){e["Https"]="https";e["HttpsAndHttp"]="https,http"})(t.SASProtocol||(t.SASProtocol={}));class SASQueryParameters{constructor(e,t,a,r,i,n,s,o,p,l,d,c,m,u,h,g,y,v,b,x){this.version=e;this.signature=t;if(a!==undefined&&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.encryptionScope=a.encryptionScope;this.resource=a.resource;this.cacheControl=a.cacheControl;this.contentDisposition=a.contentDisposition;this.contentEncoding=a.contentEncoding;this.contentLanguage=a.contentLanguage;this.contentType=a.contentType;if(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}}else{this.services=r;this.resourceTypes=i;this.expiresOn=o;this.permissions=a;this.protocol=n;this.startsOn=s;this.ipRangeInner=p;this.encryptionScope=x;this.identifier=l;this.resource=d;this.cacheControl=c;this.contentDisposition=m;this.contentEncoding=u;this.contentLanguage=h;this.contentType=g;if(y){this.signedOid=y.signedObjectId;this.signedTenantId=y.signedTenantId;this.signedStartsOn=y.signedStartsOn;this.signedExpiresOn=y.signedExpiresOn;this.signedService=y.signedService;this.signedVersion=y.signedVersion;this.preauthorizedAgentObjectId=v;this.correlationId=b}}}get ipRange(){if(this.ipRangeInner){return{end:this.ipRangeInner.end,start:this.ipRangeInner.start}}return undefined}toString(){const e=["sv","ss","srt","spr","st","se","sip","si","ses","skoid","sktid","skt","ske","sks","skv","sr","sp","sig","rscc","rscd","rsce","rscl","rsct","saoid","scid"];const t=[];for(const 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?truncatedISO8061Date(this.startsOn,false):undefined);break;case"se":this.tryAppendQueryParameter(t,a,this.expiresOn?truncatedISO8061Date(this.expiresOn,false):undefined);break;case"sip":this.tryAppendQueryParameter(t,a,this.ipRange?ipRangeToString(this.ipRange):undefined);break;case"si":this.tryAppendQueryParameter(t,a,this.identifier);break;case"ses":this.tryAppendQueryParameter(t,a,this.encryptionScope);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?truncatedISO8061Date(this.signedStartsOn,false):undefined);break;case"ske":this.tryAppendQueryParameter(t,a,this.signedExpiresOn?truncatedISO8061Date(this.signedExpiresOn,false):undefined);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){if(!a){return}t=encodeURIComponent(t);a=encodeURIComponent(a);if(t.length>0&&a.length>0){e.push(`${t}=${a}`)}}}function generateBlobSASQueryParameters(e,t,a){const r=e.version?e.version:Ys;const i=t instanceof StorageSharedKeyCredential?t:undefined;let n;if(i===undefined&&a!==undefined){n=new UserDelegationKeyCredential(a,t)}if(i===undefined&&n===undefined){throw TypeError("Invalid sharedKeyCredential, userDelegationKey or accountName.")}if(r>="2020-12-06"){if(i!==undefined){return generateBlobSASQueryParameters20201206(e,i)}else{return generateBlobSASQueryParametersUDK20201206(e,n)}}if(r>="2018-11-09"){if(i!==undefined){return generateBlobSASQueryParameters20181109(e,i)}else{if(r>="2020-02-10"){return generateBlobSASQueryParametersUDK20200210(e,n)}else{return generateBlobSASQueryParametersUDK20181109(e,n)}}}if(r>="2015-04-05"){if(i!==undefined){return generateBlobSASQueryParameters20150405(e,i)}else{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 generateBlobSASQueryParameters20150405(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";if(e.blobName){a="b"}let r;if(e.permissions){if(e.blobName){r=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{r=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const i=[r?r:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const n=t.computeHMACSHA256(i);return new SASQueryParameters(e.version,n,r,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType)}function generateBlobSASQueryParameters20181109(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType)}function generateBlobSASQueryParameters20201206(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.encryptionScope,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,undefined,undefined,undefined,e.encryptionScope)}function generateBlobSASQueryParametersUDK20181109(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey)}function generateBlobSASQueryParametersUDK20200210(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,undefined,e.correlationId,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId)}function generateBlobSASQueryParametersUDK20201206(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,undefined,e.correlationId,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.encryptionScope,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId,e.encryptionScope)}function getCanonicalName(e,t,a){const r=[`/blob/${e}/${t}`];if(a){r.push(`/${a}`)}return r.join("")}function SASSignatureValuesSanityCheckAndAutofill(e){const t=e.version?e.version:Ys;if(e.snapshotTime&&t<"2018-11-09"){throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.")}if(e.blobName===undefined&&e.snapshotTime){throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.")}if(e.versionId&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.")}if(e.blobName===undefined&&e.versionId){throw RangeError("Must provide 'blobName' when providing 'versionId'.")}if(e.permissions&&e.permissions.setImmutabilityPolicy&&t<"2020-08-04"){throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.")}if(e.permissions&&e.permissions.deleteVersion&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.")}if(e.permissions&&e.permissions.permanentDelete&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'y' permission.")}if(e.permissions&&e.permissions.tag&&t<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.")}if(t<"2020-02-10"&&e.permissions&&(e.permissions.move||e.permissions.execute)){throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.")}if(t<"2021-04-10"&&e.permissions&&e.permissions.filterByTags){throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.")}if(t<"2020-02-10"&&(e.preauthorizedAgentObjectId||e.correlationId)){throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.")}if(e.encryptionScope&&t<"2020-12-06"){throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.")}e.version=t;return e}class BlobLeaseClient{constructor(e,t){const a=new StorageClientContext(e.url,e.pipeline.toServiceClientOptions());this._url=e.url;if(e.name===undefined){this._isContainer=true;this._containerOrBlobOperation=new Container(a)}else{this._isContainer=false;this._containerOrBlobOperation=new Blob$1(a)}if(!t){t=r.generateUuid()}this._leaseId=t}get leaseId(){return this._leaseId}get url(){return this._url}async acquireLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-acquireLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions}),proposedLeaseId:this._leaseId},convertTracingToRequestOptionsBase(d)))}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}async changeLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-changeLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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{const a=await this._containerOrBlobOperation.changeLease(this._leaseId,e,Object.assign({abortSignal:t.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions})},convertTracingToRequestOptionsBase(d)));this._leaseId=e;return a}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}async releaseLease(e={}){var t,a,r,i,s,o;const{span:p,updatedOptions:l}=Do("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)!==lo||((r=e.conditions)===null||r===void 0?void 0:r.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==lo||((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})},convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async renewLease(e={}){var t,a,r,i,s,o;const{span:p,updatedOptions:l}=Do("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)!==lo||((r=e.conditions)===null||r===void 0?void 0:r.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==lo||((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})},convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async breakLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-breakLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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{const a=Object.assign({abortSignal:t.abortSignal,breakPeriod:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions})},convertTracingToRequestOptionsBase(d));return await this._containerOrBlobOperation.breakLease(a)}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}}class RetriableReadableStream extends d.Readable{constructor(e,t,a,r,i={}){super({highWaterMark:i.highWaterMark});this.retries=0;this.sourceDataHandler=e=>{if(this.options.doInjectErrorOnce){this.options.doInjectErrorOnce=undefined;this.source.pause();this.source.removeAllListeners("data");this.source.emit("end");return}this.offset+=e.length;if(this.onProgress){this.onProgress({loadedBytes:this.offset-this.start})}if(!this.push(e)){this.source.pause()}};this.sourceErrorOrEndHandler=e=>{if(e&&e.name==="AbortError"){this.destroy(e);return}this.removeSourceEventHandlers();if(this.offset-1===this.end){this.push(null)}else if(this.offset<=this.end){if(this.retries{this.source=e;this.setSourceEventHandlers();return})).catch((e=>{this.destroy(e)}))}else{this.destroy(new Error(`Data corruption failure: received less data than required and reached maxRetires limitation. Received data offset: ${this.offset-1}, data needed offset: ${this.end}, retries: ${this.retries}, max retries: ${this.maxRetryRequests}`))}}else{this.destroy(new Error(`Data corruption failure: Received more data than original request, data needed offset is ${this.end}, received offset: ${this.offset-1}`))}};this.getter=t;this.source=e;this.start=a;this.offset=a;this.end=a+r-1;this.maxRetryRequests=i.maxRetryRequests&&i.maxRetryRequests>=0?i.maxRetryRequests:0;this.onProgress=i.onProgress;this.options=i;this.setSourceEventHandlers()}_read(){this.source.resume()}setSourceEventHandlers(){this.source.on("data",this.sourceDataHandler);this.source.on("end",this.sourceErrorOrEndHandler);this.source.on("error",this.sourceErrorOrEndHandler)}removeSourceEventHandlers(){this.source.removeListener("data",this.sourceDataHandler);this.source.removeListener("end",this.sourceErrorOrEndHandler);this.source.removeListener("error",this.sourceErrorOrEndHandler)}_destroy(e,t){this.removeSourceEventHandlers();this.source.destroy();t(e===null?undefined:e)}}class BlobDownloadResponse{constructor(e,t,a,r,i={}){this.originalResponse=e;this.blobDownloadStream=new RetriableReadableStream(this.originalResponse.readableStreamBody,t,a,r,i)}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(){return this.originalResponse.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 tagCount(){return this.originalResponse.tagCount}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 lastAccessed(){return this.originalResponse.lastAccessed}get createdOn(){return this.originalResponse.createdOn}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 versionId(){return this.originalResponse.versionId}get isCurrentVersion(){return this.originalResponse.isCurrentVersion}get encryptionKeySha256(){return this.originalResponse.encryptionKeySha256}get contentCrc64(){return this.originalResponse.contentCrc64}get objectReplicationDestinationPolicyId(){return this.originalResponse.objectReplicationDestinationPolicyId}get objectReplicationSourceProperties(){return this.originalResponse.objectReplicationSourceProperties}get isSealed(){return this.originalResponse.isSealed}get immutabilityPolicyExpiresOn(){return this.originalResponse.immutabilityPolicyExpiresOn}get immutabilityPolicyMode(){return this.originalResponse.immutabilityPolicyMode}get legalHold(){return this.originalResponse.legalHold}get contentAsBlob(){return this.originalResponse.blobBody}get readableStreamBody(){return r.isNode?this.blobDownloadStream:undefined}get _response(){return this.originalResponse._response}}const Ao=16;const Io=new Uint8Array([79,98,106,1]);const Lo="avro.codec";const Mo="avro.schema";class AvroParser{static async readFixedBytes(e,t,a={}){const r=await e.read(t,{abortSignal:a.abortSignal});if(r.length!==t){throw new Error("Hit stream end.")}return r}static async readByte(e,t={}){const a=await AvroParser.readFixedBytes(e,1,t);return a[0]}static async readZigZagLong(e,t={}){let a=0;let r=0;let i,n,s;do{i=await AvroParser.readByte(e,t);n=i&128;a|=(i&127)<Number.MAX_SAFE_INTEGER){throw new Error("Integer overflow.")}return r}return a>>1^-(a&1)}static async readLong(e,t={}){return AvroParser.readZigZagLong(e,t)}static async readInt(e,t={}){return AvroParser.readZigZagLong(e,t)}static async readNull(){return null}static async readBoolean(e,t={}){const a=await AvroParser.readByte(e,t);if(a===1){return true}else if(a===0){return false}else{throw new Error("Byte was not a boolean.")}}static async readFloat(e,t={}){const a=await AvroParser.readFixedBytes(e,4,t);const r=new DataView(a.buffer,a.byteOffset,a.byteLength);return r.getFloat32(0,true)}static async readDouble(e,t={}){const a=await AvroParser.readFixedBytes(e,8,t);const r=new DataView(a.buffer,a.byteOffset,a.byteLength);return r.getFloat64(0,true)}static async readBytes(e,t={}){const a=await AvroParser.readLong(e,t);if(a<0){throw new Error("Bytes size was negative.")}return e.read(a,{abortSignal:t.abortSignal})}static async readString(e,t={}){const a=await AvroParser.readBytes(e,t);const r=new TextDecoder;return r.decode(a)}static async readMapPair(e,t,a={}){const r=await AvroParser.readString(e,a);const i=await t(e,a);return{key:r,value:i}}static async readMap(e,t,a={}){const readPairMethod=(e,a={})=>AvroParser.readMapPair(e,t,a);const r=await AvroParser.readArray(e,readPairMethod,a);const i={};for(const e of r){i[e.key]=e.value}return i}static async readArray(e,t,a={}){const r=[];for(let i=await AvroParser.readLong(e,a);i!==0;i=await AvroParser.readLong(e,a)){if(i<0){await AvroParser.readLong(e,a);i=-i}while(i--){const i=await t(e,a);r.push(i)}}return r}}var Bo;(function(e){e["RECORD"]="record";e["ENUM"]="enum";e["ARRAY"]="array";e["MAP"]="map";e["UNION"]="union";e["FIXED"]="fixed"})(Bo||(Bo={}));var ko;(function(e){e["NULL"]="null";e["BOOLEAN"]="boolean";e["INT"]="int";e["LONG"]="long";e["FLOAT"]="float";e["DOUBLE"]="double";e["BYTES"]="bytes";e["STRING"]="string"})(ko||(ko={}));class AvroType{static fromSchema(e){if(typeof e==="string"){return AvroType.fromStringSchema(e)}else if(Array.isArray(e)){return AvroType.fromArraySchema(e)}else{return AvroType.fromObjectSchema(e)}}static fromStringSchema(e){switch(e){case ko.NULL:case ko.BOOLEAN:case ko.INT:case ko.LONG:case ko.FLOAT:case ko.DOUBLE:case ko.BYTES:case ko.STRING:return new AvroPrimitiveType(e);default:throw new Error(`Unexpected Avro type ${e}`)}}static fromArraySchema(e){return new AvroUnionType(e.map(AvroType.fromSchema))}static fromObjectSchema(e){const t=e.type;try{return AvroType.fromStringSchema(t)}catch(e){}switch(t){case Bo.RECORD:if(e.aliases){throw new Error(`aliases currently is not supported, schema: ${e}`)}if(!e.name){throw new Error(`Required attribute 'name' doesn't exist on schema: ${e}`)}const a={};if(!e.fields){throw new Error(`Required attribute 'fields' doesn't exist on schema: ${e}`)}for(const t of e.fields){a[t.name]=AvroType.fromSchema(t.type)}return new AvroRecordType(a,e.name);case Bo.ENUM:if(e.aliases){throw new Error(`aliases currently is not supported, schema: ${e}`)}if(!e.symbols){throw new Error(`Required attribute 'symbols' doesn't exist on schema: ${e}`)}return new AvroEnumType(e.symbols);case Bo.MAP:if(!e.values){throw new Error(`Required attribute 'values' doesn't exist on schema: ${e}`)}return new AvroMapType(AvroType.fromSchema(e.values));case Bo.ARRAY:case Bo.FIXED:default:throw new Error(`Unexpected Avro type ${t} in ${e}`)}}}class AvroPrimitiveType extends AvroType{constructor(e){super();this._primitive=e}read(e,t={}){switch(this._primitive){case ko.NULL:return AvroParser.readNull();case ko.BOOLEAN:return AvroParser.readBoolean(e,t);case ko.INT:return AvroParser.readInt(e,t);case ko.LONG:return AvroParser.readLong(e,t);case ko.FLOAT:return AvroParser.readFloat(e,t);case ko.DOUBLE:return AvroParser.readDouble(e,t);case ko.BYTES:return AvroParser.readBytes(e,t);case ko.STRING:return AvroParser.readString(e,t);default:throw new Error("Unknown Avro Primitive")}}}class AvroEnumType extends AvroType{constructor(e){super();this._symbols=e}async read(e,t={}){const a=await AvroParser.readInt(e,t);return this._symbols[a]}}class AvroUnionType extends AvroType{constructor(e){super();this._types=e}async read(e,t={}){const a=await AvroParser.readInt(e,t);return this._types[a].read(e,t)}}class AvroMapType extends AvroType{constructor(e){super();this._itemType=e}read(e,t={}){const readItemMethod=(e,t)=>this._itemType.read(e,t);return AvroParser.readMap(e,readItemMethod,t)}}class AvroRecordType extends AvroType{constructor(e,t){super();this._fields=e;this._name=t}async read(e,t={}){const a={};a["$schema"]=this._name;for(const r in this._fields){if(Object.prototype.hasOwnProperty.call(this._fields,r)){a[r]=await this._fields[r].read(e,t)}}return a}}function arraysEqual(e,t){if(e===t)return true;if(e==null||t==null)return false;if(e.length!==t.length)return false;for(let a=0;a0){for(let t=0;t0}parseObjects(e={}){return i.__asyncGenerator(this,arguments,(function*parseObjects_1(){if(!this._initialized){yield i.__await(this.initialize(e))}while(this.hasNext()){const t=yield i.__await(this._itemType.read(this._dataStream,{abortSignal:e.abortSignal}));this._itemsRemainingInBlock--;this._objectIndex++;if(this._itemsRemainingInBlock===0){const t=yield i.__await(AvroParser.readFixedBytes(this._dataStream,Ao,{abortSignal:e.abortSignal}));this._blockOffset=this._initialBlockOffset+this._dataStream.position;this._objectIndex=0;if(!arraysEqual(this._syncMarker,t)){throw new Error("Stream is not a valid Avro file.")}try{this._itemsRemainingInBlock=yield i.__await(AvroParser.readLong(this._dataStream,{abortSignal:e.abortSignal}))}catch(e){this._itemsRemainingInBlock=0}if(this._itemsRemainingInBlock>0){yield i.__await(AvroParser.readLong(this._dataStream,{abortSignal:e.abortSignal}))}}yield yield i.__await(t)}}))}}class AvroReadable{}const zo=new o.AbortError("Reading from the avro stream was aborted.");class AvroReadableFromStream extends AvroReadable{constructor(e){super();this._readable=e;this._position=0}toUint8Array(e){if(typeof e==="string"){return Buffer.from(e)}return e}get position(){return this._position}async read(e,t={}){var a;if((a=t.abortSignal)===null||a===void 0?void 0:a.aborted){throw zo}if(e<0){throw new Error(`size parameter should be positive: ${e}`)}if(e===0){return new Uint8Array}if(!this._readable.readable){throw new Error("Stream no longer readable.")}const r=this._readable.read(e);if(r){this._position+=r.length;return this.toUint8Array(r)}else{return new Promise(((a,r)=>{const cleanUp=()=>{this._readable.removeListener("readable",readableCallback);this._readable.removeListener("error",rejectCallback);this._readable.removeListener("end",rejectCallback);this._readable.removeListener("close",rejectCallback);if(t.abortSignal){t.abortSignal.removeEventListener("abort",abortHandler)}};const readableCallback=()=>{const t=this._readable.read(e);if(t){this._position+=t.length;cleanUp();a(this.toUint8Array(t))}};const rejectCallback=()=>{cleanUp();r()};const abortHandler=()=>{cleanUp();r(zo)};this._readable.on("readable",readableCallback);this._readable.once("error",rejectCallback);this._readable.once("end",rejectCallback);this._readable.once("close",rejectCallback);if(t.abortSignal){t.abortSignal.addEventListener("abort",abortHandler)}}))}}}class BlobQuickQueryStream extends d.Readable{constructor(e,t={}){super();this.avroPaused=true;this.source=e;this.onProgress=t.onProgress;this.onError=t.onError;this.avroReader=new AvroReader(new AvroReadableFromStream(this.source));this.avroIter=this.avroReader.parseObjects({abortSignal:t.abortSignal})}_read(){if(this.avroPaused){this.readInternal().catch((e=>{this.emit("error",e)}))}}async readInternal(){this.avroPaused=false;let e;do{e=await this.avroIter.next();if(e.done){break}const t=e.value;const a=t.$schema;if(typeof a!=="string"){throw Error("Missing schema in avro record.")}switch(a){case"com.microsoft.azure.storage.queryBlobContents.resultData":{const e=t.data;if(e instanceof Uint8Array===false){throw Error("Invalid data in avro result record.")}if(!this.push(Buffer.from(e))){this.avroPaused=true}}break;case"com.microsoft.azure.storage.queryBlobContents.progress":{const e=t.bytesScanned;if(typeof e!=="number"){throw Error("Invalid bytesScanned in avro progress record.")}if(this.onProgress){this.onProgress({loadedBytes:e})}}break;case"com.microsoft.azure.storage.queryBlobContents.end":if(this.onProgress){const e=t.totalBytes;if(typeof e!=="number"){throw Error("Invalid totalBytes in avro end record.")}this.onProgress({loadedBytes:e})}this.push(null);break;case"com.microsoft.azure.storage.queryBlobContents.error":if(this.onError){const e=t.fatal;if(typeof e!=="boolean"){throw Error("Invalid fatal in avro error record.")}const a=t.name;if(typeof a!=="string"){throw Error("Invalid name in avro error record.")}const r=t.description;if(typeof r!=="string"){throw Error("Invalid description in avro error record.")}const i=t.position;if(typeof i!=="number"){throw Error("Invalid position in avro error record.")}this.onError({position:i,name:a,isFatal:e,description:r})}break;default:throw Error(`Unknown schema ${a} in avro progress record.`)}}while(!e.done&&!this.avroPaused)}}class BlobQueryResponse{constructor(e,t={}){this.originalResponse=e;this.blobDownloadStream=new BlobQuickQueryStream(this.originalResponse.readableStreamBody,t)}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(){return undefined}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(){return undefined}get readableStreamBody(){return r.isNode?this.blobDownloadStream:undefined}get _response(){return this.originalResponse._response}}t.BlockBlobTier=void 0;(function(e){e["Hot"]="Hot";e["Cool"]="Cool";e["Cold"]="Cold";e["Archive"]="Archive"})(t.BlockBlobTier||(t.BlockBlobTier={}));t.PremiumPageBlobTier=void 0;(function(e){e["P4"]="P4";e["P6"]="P6";e["P10"]="P10";e["P15"]="P15";e["P20"]="P20";e["P30"]="P30";e["P40"]="P40";e["P50"]="P50";e["P60"]="P60";e["P70"]="P70";e["P80"]="P80"})(t.PremiumPageBlobTier||(t.PremiumPageBlobTier={}));function toAccessTier(e){if(e===undefined){return undefined}return e}function ensureCpkIfSpecified(e,t){if(e&&!t){throw new RangeError("Customer-provided encryption key must be used over HTTPS.")}if(e&&!e.encryptionAlgorithm){e.encryptionAlgorithm=yo}}t.StorageBlobAudience=void 0;(function(e){e["StorageOAuthScopes"]="https://storage.azure.com/.default";e["DiskComputeOAuthScopes"]="https://disk.compute.azure.com/.default"})(t.StorageBlobAudience||(t.StorageBlobAudience={}));function rangeResponseFromModel(e){const t=(e._response.parsedBody.pageRange||[]).map((e=>({offset:e.start,count:e.end-e.start})));const a=(e._response.parsedBody.clearRange||[]).map((e=>({offset:e.start,count:e.end-e.start})));return Object.assign(Object.assign({},e),{pageRange:t,clearRange:a,_response:Object.assign(Object.assign({},e._response),{parsedBody:{pageRange:t,clearRange:a}})})}class BlobBeginCopyFromUrlPoller extends c.Poller{constructor(e){const{blobClient:t,copySource:a,intervalInMs:r=15e3,onProgress:i,resumeFrom:n,startCopyFromURLOptions:s}=e;let o;if(n){o=JSON.parse(n).state}const p=makeBlobBeginCopyFromURLPollOperation(Object.assign(Object.assign({},o),{blobClient:t,copySource:a,startCopyFromURLOptions:s}));super(p);if(typeof i==="function"){this.onProgress(i)}this.intervalInMs=r}delay(){return r.delay(this.intervalInMs)}}const jo=async function cancel(e={}){const t=this.state;const{copyId:a}=t;if(t.isCompleted){return makeBlobBeginCopyFromURLPollOperation(t)}if(!a){t.isCancelled=true;return makeBlobBeginCopyFromURLPollOperation(t)}await t.blobClient.abortCopyFromURL(a,{abortSignal:e.abortSignal});t.isCancelled=true;return makeBlobBeginCopyFromURLPollOperation(t)};const qo=async function update(e={}){const t=this.state;const{blobClient:a,copySource:r,startCopyFromURLOptions:i}=t;if(!t.isStarted){t.isStarted=true;const e=await a.startCopyFromURL(r,i);t.copyId=e.copyId;if(e.copyStatus==="success"){t.result=e;t.isCompleted=true}}else if(!t.isCompleted){try{const a=await t.blobClient.getProperties({abortSignal:e.abortSignal});const{copyStatus:r,copyProgress:i}=a;const n=t.copyProgress;if(i){t.copyProgress=i}if(r==="pending"&&i!==n&&typeof e.fireProgress==="function"){e.fireProgress(t)}else if(r==="success"){t.result=a;t.isCompleted=true}else if(r==="failed"){t.error=new Error(`Blob copy failed with reason: "${a.copyStatusDescription||"unknown"}"`);t.isCompleted=true}}catch(e){t.error=e;t.isCompleted=true}}return makeBlobBeginCopyFromURLPollOperation(t)};const Uo=function toString(){return JSON.stringify({state:this.state},((e,t)=>{if(e==="blobClient"){return undefined}return t}))};function makeBlobBeginCopyFromURLPollOperation(e){return{state:Object.assign({},e),cancel:jo,toString:Uo,update:qo}}function rangeToString(e){if(e.offset<0){throw new RangeError(`Range.offset cannot be smaller than 0.`)}if(e.count&&e.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 e.count?`bytes=${e.offset}-${e.offset+e.count-1}`:`bytes=${e.offset}-`}var Fo;(function(e){e[e["Good"]=0]="Good";e[e["Error"]=1]="Error"})(Fo||(Fo={}));class Batch{constructor(e=5){this.actives=0;this.completed=0;this.offset=0;this.operations=[];this.state=Fo.Good;if(e<1){throw new RangeError("concurrency must be larger than 0")}this.concurrency=e;this.emitter=new m.EventEmitter}addOperation(e){this.operations.push((async()=>{try{this.actives++;await e();this.actives--;this.completed++;this.parallelExecute()}catch(e){this.emitter.emit("error",e)}}))}async do(){if(this.operations.length===0){return Promise.resolve()}this.parallelExecute();return new Promise(((e,t)=>{this.emitter.on("finish",e);this.emitter.on("error",(e=>{this.state=Fo.Error;t(e)}))}))}nextOperation(){if(this.offset=this.operations.length){this.emitter.emit("finish");return}while(this.actives=this.byteLength){this.push(null)}if(!e){e=this.readableHighWaterMark}const t=[];let a=0;while(ae-a){const r=this.byteOffsetInCurrentBuffer+e-a;t.push(this.buffers[this.bufferIndex].slice(this.byteOffsetInCurrentBuffer,r));this.pushedBytesLength+=e-a;this.byteOffsetInCurrentBuffer=r;a=e;break}else{const e=this.byteOffsetInCurrentBuffer+n;t.push(this.buffers[this.bufferIndex].slice(this.byteOffsetInCurrentBuffer,e));if(n===i){this.byteOffsetInCurrentBuffer=0;this.bufferIndex++}else{this.byteOffsetInCurrentBuffer=e}this.pushedBytesLength+=n;a+=n}}if(t.length>1){this.push(Buffer.concat(t))}else if(t.length===1){this.push(t[0])}}}const Ho=a(4300).constants.MAX_LENGTH;class PooledBuffer{constructor(e,t,a){this.buffers=[];this.capacity=e;this._size=0;const r=Math.ceil(e/Ho);for(let t=0;t0){e[0]=e[0].slice(n)}}getReadableStream(){return new BuffersStream(this.buffers,this.size)}}class BufferScheduler{constructor(e,t,a,r,i,n){this.emitter=new m.EventEmitter;this.offset=0;this.isStreamEnd=false;this.isError=false;this.executingOutgoingHandlers=0;this.numBuffers=0;this.unresolvedDataArray=[];this.unresolvedLength=0;this.incoming=[];this.outgoing=[];if(t<=0){throw new RangeError(`bufferSize must be larger than 0, current is ${t}`)}if(a<=0){throw new RangeError(`maxBuffers must be larger than 0, current is ${a}`)}if(i<=0){throw new RangeError(`concurrency must be larger than 0, current is ${i}`)}this.bufferSize=t;this.maxBuffers=a;this.readable=e;this.outgoingHandler=r;this.concurrency=i;this.encoding=n}async do(){return new Promise(((e,t)=>{this.readable.on("data",(e=>{e=typeof e==="string"?Buffer.from(e,this.encoding):e;this.appendUnresolvedData(e);if(!this.resolveData()){this.readable.pause()}}));this.readable.on("error",(e=>{this.emitter.emit("error",e)}));this.readable.on("end",(()=>{this.isStreamEnd=true;this.emitter.emit("checkEnd")}));this.emitter.on("error",(e=>{this.isError=true;this.readable.pause();t(e)}));this.emitter.on("checkEnd",(()=>{if(this.outgoing.length>0){this.triggerOutgoingHandlers();return}if(this.isStreamEnd&&this.executingOutgoingHandlers===0){if(this.unresolvedLength>0&&this.unresolvedLengtha.getReadableStream()),a.size,this.offset).then(e).catch(t)}else if(this.unresolvedLength>=this.bufferSize){return}else{e()}}}))}))}appendUnresolvedData(e){this.unresolvedDataArray.push(e);this.unresolvedLength+=e.length}shiftBufferFromUnresolvedDataArray(e){if(!e){e=new PooledBuffer(this.bufferSize,this.unresolvedDataArray,this.unresolvedLength)}else{e.fill(this.unresolvedDataArray,this.unresolvedLength)}this.unresolvedLength-=e.size;return e}resolveData(){while(this.unresolvedLength>=this.bufferSize){let e;if(this.incoming.length>0){e=this.incoming.shift();this.shiftBufferFromUnresolvedDataArray(e)}else{if(this.numBuffers=this.concurrency){return}e=this.outgoing.shift();if(e){this.triggerOutgoingHandler(e)}}while(e)}async triggerOutgoingHandler(e){const t=e.size;this.executingOutgoingHandlers++;this.offset+=t;try{await this.outgoingHandler((()=>e.getReadableStream()),t,this.offset-t)}catch(e){this.emitter.emit("error",e);return}this.executingOutgoingHandlers--;this.reuseBuffer(e);this.emitter.emit("checkEnd")}reuseBuffer(e){this.incoming.push(e);if(!this.isError&&this.resolveData()&&!this.isStreamEnd){this.readable.resume()}}}async function streamToBuffer(e,t,a,r,i){let n=0;const s=r-a;return new Promise(((r,o)=>{const p=setTimeout((()=>o(new Error(`The operation cannot be completed in timeout.`))),io);e.on("readable",(()=>{if(n>=s){clearTimeout(p);r();return}let o=e.read();if(!o){return}if(typeof o==="string"){o=Buffer.from(o,i)}const l=n+o.length>s?s-n:o.length;t.fill(o.slice(0,l),a+n,a+n+l);n+=l}));e.on("end",(()=>{clearTimeout(p);if(n{clearTimeout(p);o(e)}))}))}async function streamToBuffer2(e,t,a){let r=0;const i=t.length;return new Promise(((n,s)=>{e.on("readable",(()=>{let n=e.read();if(!n){return}if(typeof n==="string"){n=Buffer.from(n,a)}if(r+n.length>i){s(new Error(`Stream exceeds buffer size. Buffer size: ${i}`));return}t.fill(n,r,r+n.length);r+=n.length}));e.on("end",(()=>{n(r)}));e.on("error",s)}))}async function readStreamToLocalFile(e,t){return new Promise(((a,r)=>{const i=v.createWriteStream(t);e.on("error",(e=>{r(e)}));i.on("error",(e=>{r(e)}));i.on("close",a);e.pipe(i)}))}const Vo=b.promisify(v.stat);const Go=v.createReadStream;class BlobClient extends StorageClient{constructor(e,t,a,i){i=i||{};let n;let s;if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;if(a&&typeof a!=="string"){i=a}n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);({blobName:this._name,containerName:this._containerName}=this.getBlobAndContainerNamesFromUrl());this.blobContext=new Blob$1(this.storageClientContext);this._snapshot=getURLParameter(this.url,so.Parameters.SNAPSHOT);this._versionId=getURLParameter(this.url,so.Parameters.VERSIONID)}get name(){return this._name}get containerName(){return this._containerName}withSnapshot(e){return new BlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}withVersion(e){return new BlobClient(setURLParameter(this.url,so.Parameters.VERSIONID,e.length===0?undefined:e),this.pipeline)}getAppendBlobClient(){return new AppendBlobClient(this.url,this.pipeline)}getBlockBlobClient(){return new BlockBlobClient(this.url,this.pipeline)}getPageBlobClient(){return new PageBlobClient(this.url,this.pipeline)}async download(e=0,t,a={}){var i;a.conditions=a.conditions||{};a.conditions=a.conditions||{};ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);const{span:s,updatedOptions:o}=Do("BlobClient-download",a);try{const n=await this.blobContext.download(Object.assign({abortSignal:a.abortSignal,leaseAccessConditions:a.conditions,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(i=a.conditions)===null||i===void 0?void 0:i.tagConditions}),requestOptions:{onDownloadProgress:r.isNode?undefined:a.onProgress},range:e===0&&!t?undefined:rangeToString({offset:e,count:t}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey},convertTracingToRequestOptionsBase(o)));const p=Object.assign(Object.assign({},n),{_response:n._response,objectReplicationDestinationPolicyId:n.objectReplicationPolicyId,objectReplicationSourceProperties:parseObjectReplicationRecord(n.objectReplicationRules)});if(!r.isNode){return p}if(a.maxRetryRequests===undefined||a.maxRetryRequests<0){a.maxRetryRequests=ro}if(n.contentLength===undefined){throw new RangeError(`File download response doesn't contain valid content length header`)}if(!n.etag){throw new RangeError(`File download response doesn't contain valid etag header`)}return new BlobDownloadResponse(p,(async t=>{var r;const i={leaseAccessConditions:a.conditions,modifiedAccessConditions:{ifMatch:a.conditions.ifMatch||n.etag,ifModifiedSince:a.conditions.ifModifiedSince,ifNoneMatch:a.conditions.ifNoneMatch,ifUnmodifiedSince:a.conditions.ifUnmodifiedSince,ifTags:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions},range:rangeToString({count:e+n.contentLength-t,offset:t}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey};return(await this.blobContext.download(Object.assign({abortSignal:a.abortSignal},i))).readableStreamBody}),e,n.contentLength,{maxRetryRequests:a.maxRetryRequests,onProgress:a.onProgress})}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async exists(e={}){const{span:t,updatedOptions:a}=Do("BlobClient-exists",e);try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);await this.getProperties({abortSignal:e.abortSignal,customerProvidedKey:e.customerProvidedKey,conditions:e.conditions,tracingOptions:a.tracingOptions});return true}catch(e){if(e.statusCode===404){return false}else if(e.statusCode===409&&(e.details.errorCode===wo||e.details.errorCode===So)){return true}t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async getProperties(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-getProperties",e);try{e.conditions=e.conditions||{};ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);const 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},convertTracingToRequestOptionsBase(r)));return Object.assign(Object.assign({},i),{_response:i._response,objectReplicationDestinationPolicyId:i.objectReplicationPolicyId,objectReplicationSourceProperties:parseObjectReplicationRecord(i.objectReplicationRules)})}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async delete(e={}){var t;const{span:a,updatedOptions:r}=Do("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})},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async deleteIfExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("BlobClient-deleteIfExists",e);try{const e=await this.delete(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="BlobNotFound"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when deleting a blob or snapshot only if it exists."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async undelete(e={}){const{span:t,updatedOptions:a}=Do("BlobClient-undelete",e);try{return await this.blobContext.undelete(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setHTTPHeaders(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setHTTPHeaders",t);t.conditions=t.conditions||{};try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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})},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setMetadata(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setMetadata",t);t.conditions=t.conditions||{};try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setTags(e,t={}){var a;const{span:r,updatedOptions:i}=Do("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})},convertTracingToRequestOptionsBase(i)),{tags:toBlobTags(e)}))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async getTags(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-getTags",e);try{const 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})},convertTracingToRequestOptionsBase(r)));const n=Object.assign(Object.assign({},i),{_response:i._response,tags:toTags({blobTagSet:i.blobTagSet})||{}});return n}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}getBlobLeaseClient(e){return new BlobLeaseClient(this,e)}async createSnapshot(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-createSnapshot",e);e.conditions=e.conditions||{};try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);return 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},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async beginCopyFromURL(e,t={}){const a={abortCopyFromURL:(...e)=>this.abortCopyFromURL(...e),getProperties:(...e)=>this.getProperties(...e),startCopyFromURL:(...e)=>this.startCopyFromURL(...e)};const r=new BlobBeginCopyFromUrlPoller({blobClient:a,copySource:e,intervalInMs:t.intervalInMs,onProgress:t.onProgress,resumeFrom:t.resumeFrom,startCopyFromURLOptions:t});await r.poll();return r}async abortCopyFromURL(e,t={}){const{span:a,updatedOptions:r}=Do("BlobClient-abortCopyFromURL",t);try{return await this.blobContext.abortCopyFromURL(e,Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async syncCopyFromURL(e,t={}){var a,r,i;const{span:s,updatedOptions:o}=Do("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:httpAuthorizationToString(t.sourceAuthorization),tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags),immutabilityPolicyExpiry:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,encryptionScope:t.encryptionScope,copySourceTags:t.copySourceTags},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async setAccessTier(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setAccessTier",t);try{return await this.blobContext.setTier(toAccessTier(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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async downloadToBuffer(e,t,a,r={}){let i;let s=0;let o=0;let p=r;if(e instanceof Buffer){i=e;s=t||0;o=typeof a==="number"?a:0}else{s=typeof e==="number"?e:0;o=typeof t==="number"?t:0;p=a||{}}const{span:l,updatedOptions:d}=Do("BlobClient-downloadToBuffer",p);try{if(!p.blockSize){p.blockSize=0}if(p.blockSize<0){throw new RangeError("blockSize option must be >= 0")}if(p.blockSize===0){p.blockSize=ao}if(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(!p.conditions){p.conditions={}}if(!o){const e=await this.getProperties(Object.assign(Object.assign({},p),{tracingOptions:Object.assign(Object.assign({},p.tracingOptions),convertTracingToRequestOptionsBase(d))}));o=e.contentLength-s;if(o<0){throw new RangeError(`offset ${s} shouldn't be larger than blob size ${e.contentLength}`)}}if(!i){try{i=Buffer.alloc(o)}catch(e){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".\t ${e.message}`)}}if(i.length{let t=s+o;if(a+p.blockSize{if(!(this.credential instanceof StorageSharedKeyCredential)){throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential")}const a=generateBlobSASQueryParameters(Object.assign({containerName:this._containerName,blobName:this._name,snapshotTime:this._snapshot,versionId:this._versionId},e),this.credential).toString();t(appendToURLQuery(this.url,a))}))}async deleteImmutabilityPolicy(e){const{span:t,updatedOptions:a}=Do("BlobClient-deleteImmutabilityPolicy",e);try{return await this.blobContext.deleteImmutabilityPolicy(Object.assign({abortSignal:e===null||e===void 0?void 0:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setImmutabilityPolicy(e,t){const{span:a,updatedOptions:r}=Do("BlobClient-setImmutabilityPolicy",t);try{return await this.blobContext.setImmutabilityPolicy(Object.assign({abortSignal:t===null||t===void 0?void 0:t.abortSignal,immutabilityPolicyExpiry:e.expiriesOn,immutabilityPolicyMode:e.policyMode,modifiedAccessConditions:t===null||t===void 0?void 0:t.modifiedAccessCondition},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async setLegalHold(e,t){const{span:a,updatedOptions:r}=Do("BlobClient-setLegalHold",t);try{return await this.blobContext.setLegalHold(e,Object.assign({abortSignal:t===null||t===void 0?void 0:t.abortSignal},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}}class AppendBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.appendBlobContext=new AppendBlob(this.storageClientContext)}withSnapshot(e){return new AppendBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async create(e={}){var t,a,r;const{span:i,updatedOptions:s}=Do("AppendBlobClient-create",e);e.conditions=e.conditions||{};try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);return 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:(r=e.immutabilityPolicy)===null||r===void 0?void 0:r.policyMode,legalHold:e.legalHold,blobTagsString:toBlobTagsString(e.tags)},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async createIfNotExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("AppendBlobClient-createIfNotExists",e);const s={ifNoneMatch:co};try{const e=await this.create(Object.assign(Object.assign({},i),{conditions:s}));return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="BlobAlreadyExists"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a blob only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async seal(e={}){var t;const{span:a,updatedOptions:r}=Do("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})},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async appendBlock(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("AppendBlobClient-appendBlock",a);a.conditions=a.conditions||{};try{ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);return 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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),requestOptions:{onUploadProgress:a.onProgress},transactionalContentMD5:a.transactionalContentMD5,transactionalContentCrc64:a.transactionalContentCrc64,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async appendBlockFromURL(e,t,a,r={}){var i;const{span:s,updatedOptions:o}=Do("AppendBlobClient-appendBlockFromURL",r);r.conditions=r.conditions||{};r.sourceConditions=r.sourceConditions||{};try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.appendBlobContext.appendBlockFromUrl(e,0,Object.assign({abortSignal:r.abortSignal,sourceRange:rangeToString({offset:t,count:a}),sourceContentMD5:r.sourceContentMD5,sourceContentCrc64:r.sourceContentCrc64,leaseAccessConditions:r.conditions,appendPositionAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:r.sourceConditions.ifMatch,sourceIfModifiedSince:r.sourceConditions.ifModifiedSince,sourceIfNoneMatch:r.sourceConditions.ifNoneMatch,sourceIfUnmodifiedSince:r.sourceConditions.ifUnmodifiedSince},copySourceAuthorization:httpAuthorizationToString(r.sourceAuthorization),cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}}class BlockBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;if(a&&typeof a!=="string"){i=a}n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.blockBlobContext=new BlockBlob(this.storageClientContext);this._blobContext=new Blob$1(this.storageClientContext)}withSnapshot(e){return new BlockBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async query(e,t={}){var a;ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);const{span:i,updatedOptions:s}=Do("BlockBlobClient-query",t);try{if(!r.isNode){throw new Error("This operation currently is only supported in Node.js.")}ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);const n=await this._blobContext.query(Object.assign({abortSignal:t.abortSignal,queryRequest:{queryType:"SQL",expression:e,inputSerialization:toQuerySerialization(t.inputTextConfiguration),outputSerialization:toQuerySerialization(t.outputTextConfiguration)},leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),cpkInfo:t.customerProvidedKey},convertTracingToRequestOptionsBase(s)));return new BlobQueryResponse(n,{abortSignal:t.abortSignal,onProgress:t.onProgress,onError:t.onError})}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async upload(e,t,a={}){var r,i,s;a.conditions=a.conditions||{};const{span:o,updatedOptions:p}=Do("BlockBlobClient-upload",a);try{ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);return 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:(r=a.conditions)===null||r===void 0?void 0:r.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:toAccessTier(a.tier),blobTagsString:toBlobTagsString(a.tags)},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async syncUploadFromURL(e,t={}){var a,r,i,s,o;t.conditions=t.conditions||{};const{span:p,updatedOptions:l}=Do("BlockBlobClient-syncUploadFromURL",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.sourceConditions)===null||r===void 0?void 0:r.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:httpAuthorizationToString(t.sourceAuthorization),tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags),copySourceTags:t.copySourceTags}),convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async stageBlock(e,t,a,r={}){const{span:i,updatedOptions:s}=Do("BlockBlobClient-stageBlock",r);try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.blockBlobContext.stageBlock(e,a,t,Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,requestOptions:{onUploadProgress:r.onProgress},transactionalContentMD5:r.transactionalContentMD5,transactionalContentCrc64:r.transactionalContentCrc64,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async stageBlockFromURL(e,t,a=0,r,i={}){const{span:s,updatedOptions:o}=Do("BlockBlobClient-stageBlockFromURL",i);try{ensureCpkIfSpecified(i.customerProvidedKey,this.isHttps);return await this.blockBlobContext.stageBlockFromURL(e,0,t,Object.assign({abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,sourceContentMD5:i.sourceContentMD5,sourceContentCrc64:i.sourceContentCrc64,sourceRange:a===0&&!r?undefined:rangeToString({offset:a,count:r}),cpkInfo:i.customerProvidedKey,encryptionScope:i.encryptionScope,copySourceAuthorization:httpAuthorizationToString(i.sourceAuthorization)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async commitBlockList(e,t={}){var a,r,i;t.conditions=t.conditions||{};const{span:s,updatedOptions:o}=Do("BlockBlobClient-commitBlockList",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async getBlockList(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlockBlobClient-getBlockList",t);try{const n=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})},convertTracingToRequestOptionsBase(i)));if(!n.committedBlocks){n.committedBlocks=[]}if(!n.uncommittedBlocks){n.uncommittedBlocks=[]}return n}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async uploadData(e,t={}){const{span:a,updatedOptions:i}=Do("BlockBlobClient-uploadData",t);try{if(r.isNode){let t;if(e instanceof Buffer){t=e}else if(e instanceof ArrayBuffer){t=Buffer.from(e)}else{e=e;t=Buffer.from(e.buffer,e.byteOffset,e.byteLength)}return this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.byteLength,i)}else{const t=new Blob([e]);return this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.size,i)}}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadBrowserData(e,t={}){const{span:a,updatedOptions:r}=Do("BlockBlobClient-uploadBrowserData",t);try{const t=new Blob([e]);return await this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.size,r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadSeekableInternal(e,t,a={}){if(!a.blockSize){a.blockSize=0}if(a.blockSize<0||a.blockSize>Zs){throw new RangeError(`blockSize option must be >= 0 and <= ${Zs}`)}if(a.maxSingleShotSize!==0&&!a.maxSingleShotSize){a.maxSingleShotSize=Js}if(a.maxSingleShotSize<0||a.maxSingleShotSize>Js){throw new RangeError(`maxSingleShotSize option must be >= 0 and <= ${Js}`)}if(a.blockSize===0){if(t>Zs*eo){throw new RangeError(`${t} is too larger to upload to a block blob.`)}if(t>a.maxSingleShotSize){a.blockSize=Math.ceil(t/eo);if(a.blockSizeeo){throw new RangeError(`The buffer's size is too big or the BlockSize is too small;`+`the number of blocks must be <= ${eo}`)}const o=[];const p=r.generateUuid();let l=0;const d=new Batch(a.concurrency);for(let r=0;r{const i=generateBlockID(p,r);const d=a.blockSize*r;const c=r===n-1?t:d+a.blockSize;const m=c-d;o.push(i);await this.stageBlock(i,e(d,m),m,{abortSignal:a.abortSignal,conditions:a.conditions,encryptionScope:a.encryptionScope,tracingOptions:s.tracingOptions});l+=m;if(a.onProgress){a.onProgress({loadedBytes:l})}}))}await d.do();return this.commitBlockList(o,s)}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async uploadFile(e,t={}){const{span:a,updatedOptions:r}=Do("BlockBlobClient-uploadFile",t);try{const i=(await Vo(e)).size;return await this.uploadSeekableInternal(((t,a)=>()=>Go(e,{autoClose:true,end:a?t+a-1:Infinity,start:t})),i,Object.assign(Object.assign({},t),{tracingOptions:Object.assign(Object.assign({},t.tracingOptions),convertTracingToRequestOptionsBase(r))}))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadStream(e,t=to,a=5,i={}){if(!i.blobHTTPHeaders){i.blobHTTPHeaders={}}if(!i.conditions){i.conditions={}}const{span:s,updatedOptions:o}=Do("BlockBlobClient-uploadStream",i);try{let n=0;const p=r.generateUuid();let l=0;const d=[];const c=new BufferScheduler(e,t,a,(async(e,t)=>{const a=generateBlockID(p,n);d.push(a);n++;await this.stageBlock(a,e,t,{conditions:i.conditions,encryptionScope:i.encryptionScope,tracingOptions:o.tracingOptions});l+=t;if(i.onProgress){i.onProgress({loadedBytes:l})}}),Math.ceil(a/4*3));await c.do();return await this.commitBlockList(d,Object.assign(Object.assign({},i),{tracingOptions:Object.assign(Object.assign({},i.tracingOptions),convertTracingToRequestOptionsBase(o))}))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}}class PageBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.pageBlobContext=new PageBlob(this.storageClientContext)}withSnapshot(e){return new PageBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async create(e,t={}){var a,r,i;t.conditions=t.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-create",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async createIfNotExists(e,t={}){var a,r;const{span:i,updatedOptions:s}=Do("PageBlobClient-createIfNotExists",t);try{const a={ifNoneMatch:co};const r=await this.create(e,Object.assign(Object.assign({},t),{conditions:a,tracingOptions:s.tracingOptions}));return Object.assign(Object.assign({succeeded:true},r),{_response:r._response})}catch(e){if(((a=e.details)===null||a===void 0?void 0:a.errorCode)==="BlobAlreadyExists"){i.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a blob only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(r=e.response)===null||r===void 0?void 0:r.parsedHeaders),{_response:e.response})}i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async uploadPages(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-uploadPages",r);try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.pageBlobContext.uploadPages(a,e,Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),requestOptions:{onUploadProgress:r.onProgress},range:rangeToString({offset:t,count:a}),sequenceNumberAccessConditions:r.conditions,transactionalContentMD5:r.transactionalContentMD5,transactionalContentCrc64:r.transactionalContentCrc64,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async uploadPagesFromURL(e,t,a,r,i={}){var s;i.conditions=i.conditions||{};i.sourceConditions=i.sourceConditions||{};const{span:o,updatedOptions:p}=Do("PageBlobClient-uploadPagesFromURL",i);try{ensureCpkIfSpecified(i.customerProvidedKey,this.isHttps);return await this.pageBlobContext.uploadPagesFromURL(e,rangeToString({offset:t,count:r}),0,rangeToString({offset:a,count:r}),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:httpAuthorizationToString(i.sourceAuthorization)},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async clearPages(e=0,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),range:rangeToString({offset:e,count:t}),sequenceNumberAccessConditions:a.conditions,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async getPageRanges(e=0,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(s))).then(rangeResponseFromModel)}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async listPageRangesSegment(e=0,t,a,r={}){var i;const{span:s,updatedOptions:o}=Do("PageBlobClient-getPageRangesSegment",r);try{return await this.pageBlobContext.getPageRanges(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),range:rangeToString({offset:e,count:t}),marker:a,maxPageSize:r.maxPageSize},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}listPageRangeItemSegments(e=0,t,a,r={}){return i.__asyncGenerator(this,arguments,(function*listPageRangeItemSegments_1(){let n;if(!!a||a===undefined){do{n=yield i.__await(this.listPageRangesSegment(e,t,a,r));a=n.continuationToken;yield yield i.__await(yield i.__await(n))}while(a)}}))}listPageRangeItems(e=0,t,a={}){return i.__asyncGenerator(this,arguments,(function*listPageRangeItems_1(){var r,n;let s;try{for(var o=i.__asyncValues(this.listPageRangeItemSegments(e,t,s,a)),p;p=yield i.__await(o.next()),!p.done;){const e=p.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(ExtractPageRangeInfoItems(e))))}}catch(e){r={error:e}}finally{try{if(p&&!p.done&&(n=o.return))yield i.__await(n.call(o))}finally{if(r)throw r.error}}}))}listPageRanges(e=0,t,a={}){a.conditions=a.conditions||{};const r=this.listPageRangeItems(e,t,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(r={})=>this.listPageRangeItemSegments(e,t,r.continuationToken,Object.assign({maxPageSize:r.maxPageSize},a))}}async getPageRangesDiff(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-getPageRangesDiff",r);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),prevsnapshot:a,range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(o))).then(rangeResponseFromModel)}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async listPageRangesDiffSegment(e,t,a,r,i){var s;const{span:o,updatedOptions:p}=Do("PageBlobClient-getPageRangesDiffSegment",i);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:i===null||i===void 0?void 0:i.abortSignal,leaseAccessConditions:i===null||i===void 0?void 0:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i===null||i===void 0?void 0:i.conditions),{ifTags:(s=i===null||i===void 0?void 0:i.conditions)===null||s===void 0?void 0:s.tagConditions}),prevsnapshot:a,range:rangeToString({offset:e,count:t}),marker:r,maxPageSize:i===null||i===void 0?void 0:i.maxPageSize},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}listPageRangeDiffItemSegments(e,t,a,r,n){return i.__asyncGenerator(this,arguments,(function*listPageRangeDiffItemSegments_1(){let s;if(!!r||r===undefined){do{s=yield i.__await(this.listPageRangesDiffSegment(e,t,a,r,n));r=s.continuationToken;yield yield i.__await(yield i.__await(s))}while(r)}}))}listPageRangeDiffItems(e,t,a,r){return i.__asyncGenerator(this,arguments,(function*listPageRangeDiffItems_1(){var n,s;let o;try{for(var p=i.__asyncValues(this.listPageRangeDiffItemSegments(e,t,a,o,r)),l;l=yield i.__await(p.next()),!l.done;){const e=l.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(ExtractPageRangeInfoItems(e))))}}catch(e){n={error:e}}finally{try{if(l&&!l.done&&(s=p.return))yield i.__await(s.call(p))}finally{if(n)throw n.error}}}))}listPageRangesDiff(e,t,a,r={}){r.conditions=r.conditions||{};const i=this.listPageRangeDiffItems(e,t,a,Object.assign({},r));return{next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(i={})=>this.listPageRangeDiffItemSegments(e,t,a,i.continuationToken,Object.assign({maxPageSize:i.maxPageSize},r))}}async getPageRangesDiffForManagedDisks(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-GetPageRangesDiffForManagedDisks",r);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),prevSnapshotUrl:a,range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(o))).then(rangeResponseFromModel)}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async resize(e,t={}){var a;t.conditions=t.conditions||{};const{span:r,updatedOptions:i}=Do("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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async updateSequenceNumber(e,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions})},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async startCopyIncremental(e,t={}){var a;const{span:r,updatedOptions:i}=Do("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})},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}}async function getBodyAsText(e){let t=Buffer.alloc(fo);const a=await streamToBuffer2(e.readableStreamBody,t);t=t.slice(0,a);return t.toString()}function utf8ByteLength(e){return Buffer.byteLength(e)}const $o=": ";const Xo=" ";const Wo=-1;class BatchResponseParser{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}${ho}`;this.batchResponseEnding=`--${this.responseBatchBoundary}--`}async parseBatchResponse(){if(this.batchResponse._response.status!==oo.HTTP_ACCEPTED){throw new Error(`Invalid state: batch request failed with status: '${this.batchResponse._response.status}'.`)}const e=await getBodyAsText(this.batchResponse);const t=e.split(this.batchResponseEnding)[0].split(this.perResponsePrefix).slice(1);const 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.")}const i=new Array(a);let n=0;let s=0;for(let e=0;e=0&&m{if(this.keys[e]===undefined||this.keys[e]===Ko.UNLOCKED){this.keys[e]=Ko.LOCKED;t()}else{this.onUnlockEvent(e,(()=>{this.keys[e]=Ko.LOCKED;t()}))}}))}static async unlock(e){return new Promise((t=>{if(this.keys[e]===Ko.LOCKED){this.emitUnlockEvent(e)}delete this.keys[e];t()}))}static onUnlockEvent(e,t){if(this.listeners[e]===undefined){this.listeners[e]=[t]}else{this.listeners[e].push(t)}}static emitUnlockEvent(e){if(this.listeners[e]!==undefined&&this.listeners[e].length>0){const t=this.listeners[e].shift();setImmediate((()=>{t.call(this)}))}}}Mutex.keys={};Mutex.listeners={};class BlobBatch{constructor(){this.batch="batch";this.batchRequest=new InnerBatchRequest}getMultiPartContentType(){return this.batchRequest.getMultipartContentType()}getHttpRequestBody(){return this.batchRequest.getHttpRequestBody()}getSubRequests(){return this.batchRequest.getSubRequests()}async addSubRequestInternal(e,t){await Mutex.lock(this.batch);try{this.batchRequest.preAddSubRequest(e);await t();this.batchRequest.postAddSubRequest(e)}finally{await Mutex.unlock(this.batch)}}setBatchType(e){if(!this.batchType){this.batchType=e}if(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 i;let s;if(typeof e==="string"&&(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t))){i=e;s=t}else if(e instanceof BlobClient){i=e.url;s=e.credential;a=t}else{throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.")}if(!a){a={}}const{span:o,updatedOptions:p}=Do("BatchDeleteRequest-addSubRequest",a);try{this.setBatchType("delete");await this.addSubRequestInternal({url:i,credential:s},(async()=>{await new BlobClient(i,this.batchRequest.createPipeline(s)).delete(p)}))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async setBlobAccessTier(e,t,a,i){let s;let o;let p;if(typeof e==="string"&&(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t))){s=e;o=t;p=a}else if(e instanceof BlobClient){s=e.url;o=e.credential;p=t;i=a}else{throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.")}if(!i){i={}}const{span:l,updatedOptions:d}=Do("BatchSetTierRequest-addSubRequest",i);try{this.setBatchType("setAccessTier");await this.addSubRequestInternal({url:s,credential:o},(async()=>{await new BlobClient(s,this.batchRequest.createPipeline(o)).setAccessTier(p,d)}))}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}}class InnerBatchRequest{constructor(){this.operationCount=0;this.body="";const e=r.generateUuid();this.boundary=`batch_${e}`;this.subRequestPrefix=`--${this.boundary}${ho}${po.CONTENT_TYPE}: application/http${ho}${po.CONTENT_TRANSFER_ENCODING}: binary`;this.multipartContentType=`multipart/mixed; boundary=${this.boundary}`;this.batchRequestEnding=`--${this.boundary}--`;this.subRequests=new Map}createPipeline(e){const t=e instanceof AnonymousCredential;const a=3+(t?0:1);const i=new Array(a);i[0]=r.deserializationPolicy();i[1]=new BatchHeaderFilterPolicyFactory;if(!t){i[2]=r.isTokenCredential(e)?attachCredential(r.bearerTokenAuthenticationPolicy(e,no),e):e}i[a-1]=new BatchRequestAssemblePolicyFactory(this);return new Pipeline(i,{})}appendSubRequestToBody(e){this.body+=[this.subRequestPrefix,`${po.CONTENT_ID}: ${this.operationCount}`,"",`${e.method.toString()} ${getURLPathAndQuery(e.url)} ${go}${ho}`].join(ho);for(const t of e.headers.headersArray()){this.body+=`${t.name}: ${t.value}${ho}`}this.body+=ho}preAddSubRequest(e){if(this.operationCount>=uo){throw new RangeError(`Cannot exceed ${uo} sub requests in a single batch`)}const t=getURLPath(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}${ho}`}getMultipartContentType(){return this.multipartContentType}getSubRequests(){return this.subRequests}}class BatchRequestAssemblePolicy extends r.BaseRequestPolicy{constructor(e,t,a){super(t,a);this.dummyResponse={request:new r.WebResource,status:200,headers:new r.HttpHeaders};this.batchRequest=e}async sendRequest(e){await this.batchRequest.appendSubRequestToBody(e);return this.dummyResponse}}class BatchRequestAssemblePolicyFactory{constructor(e){this.batchRequest=e}create(e,t){return new BatchRequestAssemblePolicy(this.batchRequest,e,t)}}class BatchHeaderFilterPolicy extends r.BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){let t="";for(const a of e.headers.headersArray()){if(iEqual(a.name,po.X_MS_VERSION)){t=a.name}}if(t!==""){e.headers.remove(t)}return this._nextPolicy.sendRequest(e)}}class BatchHeaderFilterPolicyFactory{create(e,t){return new BatchHeaderFilterPolicy(e,t)}}class BlobBatchClient{constructor(e,t,a){let r;if(isPipelineLike(t)){r=t}else if(!t){r=newPipeline(new AnonymousCredential,a)}else{r=newPipeline(t,a)}const i=new StorageClientContext(e,r.toServiceClientOptions());const n=getURLPath(e);if(n&&n!=="/"){this.serviceOrContainerContext=new Container(i)}else{this.serviceOrContainerContext=new Service(i)}}createBatch(){return new BlobBatch}async deleteBlobs(e,t,a){const r=new BlobBatch;for(const i of e){if(typeof i==="string"){await r.deleteBlob(i,t,a)}else{await r.deleteBlob(i,t)}}return this.submitBatch(r)}async setBlobsAccessTier(e,t,a,r){const i=new BlobBatch;for(const n of e){if(typeof n==="string"){await i.setBlobAccessTier(n,t,a,r)}else{await i.setBlobAccessTier(n,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.")}const{span:a,updatedOptions:r}=Do("BlobBatchClient-submitBatch",t);try{const i=e.getHttpRequestBody();const n=await this.serviceOrContainerContext.submitBatch(utf8ByteLength(i),e.getMultiPartContentType(),i,Object.assign(Object.assign({},t),convertTracingToRequestOptionsBase(r)));const s=new BatchResponseParser(n,e.getSubRequests());const o=await s.parseBatchResponse();const p={_response:n._response,contentType:n.contentType,errorCode:n.errorCode,requestId:n.requestId,clientRequestId:n.clientRequestId,version:n.version,subResponses:o.subResponses,subResponsesSucceededCount:o.subResponsesSucceededCount,subResponsesFailedCount:o.subResponsesFailedCount};return p}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}}class ContainerClient extends StorageClient{constructor(e,t,a){let i;let n;a=a||{};if(isPipelineLike(t)){n=e;i=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){n=e;i=newPipeline(t,a)}else if(!t&&typeof t!=="string"){n=e;i=newPipeline(new AnonymousCredential,a)}else if(t&&typeof t==="string"){const s=t;const o=extractConnectionStringParts(e);if(o.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(o.accountName,o.accountKey);n=appendToURLPath(o.url,encodeURIComponent(s));if(!a.proxyOptions){a.proxyOptions=r.getDefaultProxySettings(o.proxyUri)}i=newPipeline(e,a)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(o.kind==="SASConnString"){n=appendToURLPath(o.url,encodeURIComponent(s))+"?"+o.accountSas;i=newPipeline(new AnonymousCredential,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(n,i);this._containerName=this.getContainerNameFromUrl();this.containerContext=new Container(this.storageClientContext)}get containerName(){return this._containerName}async create(e={}){const{span:t,updatedOptions:a}=Do("ContainerClient-create",e);try{return await this.containerContext.create(Object.assign(Object.assign({},e),convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async createIfNotExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("ContainerClient-createIfNotExists",e);try{const e=await this.create(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="ContainerAlreadyExists"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a container only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async exists(e={}){const{span:t,updatedOptions:a}=Do("ContainerClient-exists",e);try{await this.getProperties({abortSignal:e.abortSignal,tracingOptions:a.tracingOptions});return true}catch(e){if(e.statusCode===404){t.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when checking container existence"});return false}t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}getBlobClient(e){return new BlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getAppendBlobClient(e){return new AppendBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getBlockBlobClient(e){return new BlockBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getPageBlobClient(e){return new PageBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}async getProperties(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-getProperties",e);try{return await this.containerContext.getProperties(Object.assign(Object.assign({abortSignal:e.abortSignal},e.conditions),convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async delete(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-delete",e);try{return await this.containerContext.delete(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:e.conditions},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async deleteIfExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("ContainerClient-deleteIfExists",e);try{const e=await this.delete(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="ContainerNotFound"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when deleting a container only if it exists."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setMetadata(e,t={}){if(!t.conditions){t.conditions={}}if(t.conditions.ifUnmodifiedSince){throw new RangeError("the IfUnmodifiedSince must have their default values because they are ignored by the blob service")}const{span:a,updatedOptions:r}=Do("ContainerClient-setMetadata",t);try{return await this.containerContext.setMetadata(Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:e,modifiedAccessConditions:t.conditions},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async getAccessPolicy(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-getAccessPolicy",e);try{const r=await this.containerContext.getAccessPolicy(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions},convertTracingToRequestOptionsBase(a)));const i={_response:r._response,blobPublicAccess:r.blobPublicAccess,date:r.date,etag:r.etag,errorCode:r.errorCode,lastModified:r.lastModified,requestId:r.requestId,clientRequestId:r.clientRequestId,signedIdentifiers:[],version:r.version};for(const e of r){let t=undefined;if(e.accessPolicy){t={permissions:e.accessPolicy.permissions};if(e.accessPolicy.expiresOn){t.expiresOn=new Date(e.accessPolicy.expiresOn)}if(e.accessPolicy.startsOn){t.startsOn=new Date(e.accessPolicy.startsOn)}}i.signedIdentifiers.push({accessPolicy:t,id:e.id})}return i}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setAccessPolicy(e,t,a={}){a.conditions=a.conditions||{};const{span:r,updatedOptions:i}=Do("ContainerClient-setAccessPolicy",a);try{const n=[];for(const e of t||[]){n.push({accessPolicy:{expiresOn:e.accessPolicy.expiresOn?truncatedISO8061Date(e.accessPolicy.expiresOn):"",permissions:e.accessPolicy.permissions,startsOn:e.accessPolicy.startsOn?truncatedISO8061Date(e.accessPolicy.startsOn):""},id:e.id})}return await this.containerContext.setAccessPolicy(Object.assign({abortSignal:a.abortSignal,access:e,containerAcl:n,leaseAccessConditions:a.conditions,modifiedAccessConditions:a.conditions},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}getBlobLeaseClient(e){return new BlobLeaseClient(this,e)}async uploadBlockBlob(e,t,a,r={}){const{span:i,updatedOptions:s}=Do("ContainerClient-uploadBlockBlob",r);try{const r=this.getBlockBlobClient(e);const n=await r.upload(t,a,s);return{blockBlobClient:r,response:n}}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async deleteBlob(e,t={}){const{span:a,updatedOptions:r}=Do("ContainerClient-deleteBlob",t);try{let i=this.getBlobClient(e);if(t.versionId){i=i.withVersion(t.versionId)}return await i.delete(r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async listBlobFlatSegment(e,t={}){const{span:a,updatedOptions:r}=Do("ContainerClient-listBlobFlatSegment",t);try{const i=await this.containerContext.listBlobFlatSegment(Object.assign(Object.assign({marker:e},t),convertTracingToRequestOptionsBase(r)));const n=Object.assign(Object.assign({},i),{_response:Object.assign(Object.assign({},i._response),{parsedBody:ConvertInternalResponseOfListBlobFlat(i._response.parsedBody)}),segment:Object.assign(Object.assign({},i.segment),{blobItems:i.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name),tags:toTags(e.blobTags),objectReplicationSourceProperties:parseObjectReplicationRecord(e.objectReplicationMetadata)});return t}))})});return n}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async listBlobHierarchySegment(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("ContainerClient-listBlobHierarchySegment",a);try{const n=await this.containerContext.listBlobHierarchySegment(e,Object.assign(Object.assign({marker:t},a),convertTracingToRequestOptionsBase(s)));const o=Object.assign(Object.assign({},n),{_response:Object.assign(Object.assign({},n._response),{parsedBody:ConvertInternalResponseOfListBlobHierarchy(n._response.parsedBody)}),segment:Object.assign(Object.assign({},n.segment),{blobItems:n.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name),tags:toTags(e.blobTags),objectReplicationSourceProperties:parseObjectReplicationRecord(e.objectReplicationMetadata)});return t})),blobPrefixes:(r=n.segment.blobPrefixes)===null||r===void 0?void 0:r.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))})});return o}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}listSegments(e,t={}){return i.__asyncGenerator(this,arguments,(function*listSegments_1(){let a;if(!!e||e===undefined){do{a=yield i.__await(this.listBlobFlatSegment(e,t));e=a.continuationToken;yield yield i.__await(yield i.__await(a))}while(e)}}))}listItems(e={}){return i.__asyncGenerator(this,arguments,(function*listItems_1(){var t,a;let r;try{for(var n=i.__asyncValues(this.listSegments(r,e)),s;s=yield i.__await(n.next()),!s.done;){const e=s.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.segment.blobItems)))}}catch(e){t={error:e}}finally{try{if(s&&!s.done&&(a=n.return))yield i.__await(a.call(n))}finally{if(t)throw t.error}}}))}listBlobsFlat(e={}){const t=[];if(e.includeCopy){t.push("copy")}if(e.includeDeleted){t.push("deleted")}if(e.includeMetadata){t.push("metadata")}if(e.includeSnapshots){t.push("snapshots")}if(e.includeVersions){t.push("versions")}if(e.includeUncommitedBlobs){t.push("uncommittedblobs")}if(e.includeTags){t.push("tags")}if(e.includeDeletedWithVersions){t.push("deletedwithversions")}if(e.includeImmutabilityPolicy){t.push("immutabilitypolicy")}if(e.includeLegalHold){t.push("legalhold")}if(e.prefix===""){e.prefix=undefined}const a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{});const r=this.listItems(a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(e={})=>this.listSegments(e.continuationToken,Object.assign({maxPageSize:e.maxPageSize},a))}}listHierarchySegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*listHierarchySegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.listBlobHierarchySegment(e,t,a));t=r.continuationToken;yield yield i.__await(yield i.__await(r))}while(t)}}))}listItemsByHierarchy(e,t={}){return i.__asyncGenerator(this,arguments,(function*listItemsByHierarchy_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.listHierarchySegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;const t=e.segment;if(t.blobPrefixes){for(const e of t.blobPrefixes){yield yield i.__await(Object.assign({kind:"prefix"},e))}}for(const e of t.blobItems){yield yield i.__await(Object.assign({kind:"blob"},e))}}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}listBlobsByHierarchy(e,t={}){if(e===""){throw new RangeError("delimiter should contain one or more characters")}const a=[];if(t.includeCopy){a.push("copy")}if(t.includeDeleted){a.push("deleted")}if(t.includeMetadata){a.push("metadata")}if(t.includeSnapshots){a.push("snapshots")}if(t.includeVersions){a.push("versions")}if(t.includeUncommitedBlobs){a.push("uncommittedblobs")}if(t.includeTags){a.push("tags")}if(t.includeDeletedWithVersions){a.push("deletedwithversions")}if(t.includeImmutabilityPolicy){a.push("immutabilitypolicy")}if(t.includeLegalHold){a.push("legalhold")}if(t.prefix===""){t.prefix=undefined}const r=Object.assign(Object.assign({},t),a.length>0?{include:a}:{});const i=this.listItemsByHierarchy(e,r);return{async next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.listHierarchySegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},r))}}async findBlobsByTagsSegment(e,t,a={}){const{span:r,updatedOptions:i}=Do("ContainerClient-findBlobsByTagsSegment",a);try{const n=await this.containerContext.filterBlobs(Object.assign({abortSignal:a.abortSignal,where:e,marker:t,maxPageSize:a.maxPageSize},convertTracingToRequestOptionsBase(i)));const s=Object.assign(Object.assign({},n),{_response:n._response,blobs:n.blobs.map((e=>{var t;let a="";if(((t=e.tags)===null||t===void 0?void 0:t.blobTagSet.length)===1){a=e.tags.blobTagSet[0].value}return Object.assign(Object.assign({},e),{tags:toTags(e.tags),tagValue:a})}))});return s}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}findBlobsByTagsSegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsSegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.findBlobsByTagsSegment(e,t,a));r.blobs=r.blobs||[];t=r.continuationToken;yield yield i.__await(r)}while(t)}}))}findBlobsByTagsItems(e,t={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsItems_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.findBlobsByTagsSegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.blobs)))}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}findBlobsByTags(e,t={}){const a=Object.assign({},t);const r=this.findBlobsByTagsItems(e,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.findBlobsByTagsSegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},a))}}getContainerNameFromUrl(){let e;try{const t=r.URLBuilder.parse(this.url);if(t.getHost().split(".")[1]==="blob"){e=t.getPath().split("/")[1]}else if(isIpEndpointStyle(t)){e=t.getPath().split("/")[2]}else{e=t.getPath().split("/")[1]}e=decodeURIComponent(e);if(!e){throw new Error("Provided containerName is invalid.")}return e}catch(e){throw new Error("Unable to extract containerName with provided information.")}}generateSasUrl(e){return new Promise((t=>{if(!(this.credential instanceof StorageSharedKeyCredential)){throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential")}const a=generateBlobSASQueryParameters(Object.assign({containerName:this._containerName},e),this.credential).toString();t(appendToURLQuery(this.url,a))}))}getBlobBatchClient(){return new BlobBatchClient(this.url,this.pipeline)}}class AccountSASPermissions{constructor(){this.read=false;this.write=false;this.delete=false;this.deleteVersion=false;this.list=false;this.add=false;this.create=false;this.update=false;this.process=false;this.tag=false;this.filter=false;this.setImmutabilityPolicy=false;this.permanentDelete=false}static parse(e){const t=new AccountSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"x":t.deleteVersion=true;break;case"l":t.list=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"u":t.update=true;break;case"p":t.process=true;break;case"t":t.tag=true;break;case"f":t.filter=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;default:throw new RangeError(`Invalid permission character: ${a}`)}}return t}static from(e){const t=new AccountSASPermissions;if(e.read){t.read=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.deleteVersion){t.deleteVersion=true}if(e.filter){t.filter=true}if(e.tag){t.tag=true}if(e.list){t.list=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.update){t.update=true}if(e.process){t.process=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.filter){e.push("f")}if(this.tag){e.push("t")}if(this.list){e.push("l")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.update){e.push("u")}if(this.process){e.push("p")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}return e.join("")}}class AccountSASResourceTypes{constructor(){this.service=false;this.container=false;this.object=false}static parse(e){const t=new AccountSASResourceTypes;for(const a of e){switch(a){case"s":t.service=true;break;case"c":t.container=true;break;case"o":t.object=true;break;default:throw new RangeError(`Invalid resource type: ${a}`)}}return t}toString(){const e=[];if(this.service){e.push("s")}if(this.container){e.push("c")}if(this.object){e.push("o")}return e.join("")}}class AccountSASServices{constructor(){this.blob=false;this.file=false;this.queue=false;this.table=false}static parse(e){const t=new AccountSASServices;for(const a of e){switch(a){case"b":t.blob=true;break;case"f":t.file=true;break;case"q":t.queue=true;break;case"t":t.table=true;break;default:throw new RangeError(`Invalid service character: ${a}`)}}return t}toString(){const e=[];if(this.blob){e.push("b")}if(this.table){e.push("t")}if(this.queue){e.push("q")}if(this.file){e.push("f")}return e.join("")}}function generateAccountSASQueryParameters(e,t){const a=e.version?e.version:Ys;if(e.permissions&&e.permissions.setImmutabilityPolicy&&a<"2020-08-04"){throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.")}if(e.permissions&&e.permissions.deleteVersion&&a<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when provided 'x' permission.")}if(e.permissions&&e.permissions.permanentDelete&&a<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when provided 'y' permission.")}if(e.permissions&&e.permissions.tag&&a<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when provided 't' permission.")}if(e.permissions&&e.permissions.filter&&a<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when provided 'f' permission.")}if(e.encryptionScope&&a<"2020-12-06"){throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.")}const r=AccountSASPermissions.parse(e.permissions.toString());const i=AccountSASServices.parse(e.services).toString();const n=AccountSASResourceTypes.parse(e.resourceTypes).toString();let s;if(a>="2020-12-06"){s=[t.accountName,r,i,n,e.startsOn?truncatedISO8061Date(e.startsOn,false):"",truncatedISO8061Date(e.expiresOn,false),e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",a,e.encryptionScope?e.encryptionScope:"",""].join("\n")}else{s=[t.accountName,r,i,n,e.startsOn?truncatedISO8061Date(e.startsOn,false):"",truncatedISO8061Date(e.expiresOn,false),e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",a,""].join("\n")}const o=t.computeHMACSHA256(s);return new SASQueryParameters(a,o,r.toString(),i,n,e.protocol,e.startsOn,e.expiresOn,e.ipRange,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,e.encryptionScope)}class BlobServiceClient extends StorageClient{constructor(e,t,a){let i;if(isPipelineLike(t)){i=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){i=newPipeline(t,a)}else{i=newPipeline(new AnonymousCredential,a)}super(e,i);this.serviceContext=new Service(this.storageClientContext)}static fromConnectionString(e,t){t=t||{};const a=extractConnectionStringParts(e);if(a.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(a.accountName,a.accountKey);if(!t.proxyOptions){t.proxyOptions=r.getDefaultProxySettings(a.proxyUri)}const i=newPipeline(e,t);return new BlobServiceClient(a.url,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(a.kind==="SASConnString"){const e=newPipeline(new AnonymousCredential,t);return new BlobServiceClient(a.url+"?"+a.accountSas,e)}else{throw new Error("Connection string must be either an Account connection string or a SAS connection string")}}getContainerClient(e){return new ContainerClient(appendToURLPath(this.url,encodeURIComponent(e)),this.pipeline)}async createContainer(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-createContainer",t);try{const t=this.getContainerClient(e);const i=await t.create(r);return{containerClient:t,containerCreateResponse:i}}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async deleteContainer(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-deleteContainer",t);try{const t=this.getContainerClient(e);return await t.delete(r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async undeleteContainer(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-undeleteContainer",a);try{const n=this.getContainerClient(a.destinationContainerName||e);const s=new Container(n["storageClientContext"]);const o=await s.restore(Object.assign({deletedContainerName:e,deletedContainerVersion:t},i));return{containerClient:n,containerUndeleteResponse:o}}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async renameContainer(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("BlobServiceClient-renameContainer",a);try{const n=this.getContainerClient(t);const o=new Container(n["storageClientContext"]);const p=await o.rename(e,Object.assign(Object.assign({},s),{sourceLeaseId:(r=a.sourceCondition)===null||r===void 0?void 0:r.leaseId}));return{containerClient:n,containerRenameResponse:p}}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async getProperties(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getProperties",e);try{return await this.serviceContext.getProperties(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setProperties(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-setProperties",t);try{return await this.serviceContext.setProperties(e,Object.assign({abortSignal:t.abortSignal},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async getStatistics(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getStatistics",e);try{return await this.serviceContext.getStatistics(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async getAccountInfo(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getAccountInfo",e);try{return await this.serviceContext.getAccountInfo(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async listContainersSegment(e,t={}){const{span:a,updatedOptions:r}=Do("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}),convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async findBlobsByTagsSegment(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-findBlobsByTagsSegment",a);try{const n=await this.serviceContext.filterBlobs(Object.assign({abortSignal:a.abortSignal,where:e,marker:t,maxPageSize:a.maxPageSize},convertTracingToRequestOptionsBase(i)));const s=Object.assign(Object.assign({},n),{_response:n._response,blobs:n.blobs.map((e=>{var t;let a="";if(((t=e.tags)===null||t===void 0?void 0:t.blobTagSet.length)===1){a=e.tags.blobTagSet[0].value}return Object.assign(Object.assign({},e),{tags:toTags(e.tags),tagValue:a})}))});return s}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}findBlobsByTagsSegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsSegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.findBlobsByTagsSegment(e,t,a));r.blobs=r.blobs||[];t=r.continuationToken;yield yield i.__await(r)}while(t)}}))}findBlobsByTagsItems(e,t={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsItems_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.findBlobsByTagsSegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.blobs)))}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}findBlobsByTags(e,t={}){const a=Object.assign({},t);const r=this.findBlobsByTagsItems(e,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.findBlobsByTagsSegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},a))}}listSegments(e,t={}){return i.__asyncGenerator(this,arguments,(function*listSegments_1(){let a;if(!!e||e===undefined){do{a=yield i.__await(this.listContainersSegment(e,t));a.containerItems=a.containerItems||[];e=a.continuationToken;yield yield i.__await(yield i.__await(a))}while(e)}}))}listItems(e={}){return i.__asyncGenerator(this,arguments,(function*listItems_1(){var t,a;let r;try{for(var n=i.__asyncValues(this.listSegments(r,e)),s;s=yield i.__await(n.next()),!s.done;){const e=s.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.containerItems)))}}catch(e){t={error:e}}finally{try{if(s&&!s.done&&(a=n.return))yield i.__await(a.call(n))}finally{if(t)throw t.error}}}))}listContainers(e={}){if(e.prefix===""){e.prefix=undefined}const t=[];if(e.includeDeleted){t.push("deleted")}if(e.includeMetadata){t.push("metadata")}if(e.includeSystem){t.push("system")}const a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{});const r=this.listItems(a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(e={})=>this.listSegments(e.continuationToken,Object.assign({maxPageSize:e.maxPageSize},a))}}async getUserDelegationKey(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-getUserDelegationKey",a);try{const n=await this.serviceContext.getUserDelegationKey({startsOn:truncatedISO8061Date(e,false),expiresOn:truncatedISO8061Date(t,false)},Object.assign({abortSignal:a.abortSignal},convertTracingToRequestOptionsBase(i)));const s={signedObjectId:n.signedObjectId,signedTenantId:n.signedTenantId,signedStartsOn:new Date(n.signedStartsOn),signedExpiresOn:new Date(n.signedExpiresOn),signedService:n.signedService,signedVersion:n.signedVersion,value:n.value};const o=Object.assign({_response:n._response,requestId:n.requestId,clientRequestId:n.clientRequestId,version:n.version,date:n.date,errorCode:n.errorCode},s);return o}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}getBlobBatchClient(){return new BlobBatchClient(this.url,this.pipeline)}generateAccountSasUrl(e,t=AccountSASPermissions.parse("r"),a="sco",r={}){if(!(this.credential instanceof StorageSharedKeyCredential)){throw RangeError("Can only generate the account SAS when the client is initialized with a shared key credential")}if(e===undefined){const t=new Date;e=new Date(t.getTime()+3600*1e3)}const i=generateAccountSASQueryParameters(Object.assign({permissions:t,expiresOn:e,resourceTypes:a,services:AccountSASServices.parse("b").toString()},r),this.credential).toString();return appendToURLQuery(this.url,i)}}t.KnownEncryptionAlgorithmType=void 0;(function(e){e["AES256"]="AES256"})(t.KnownEncryptionAlgorithmType||(t.KnownEncryptionAlgorithmType={}));Object.defineProperty(t,"BaseRequestPolicy",{enumerable:true,get:function(){return r.BaseRequestPolicy}});Object.defineProperty(t,"HttpHeaders",{enumerable:true,get:function(){return r.HttpHeaders}});Object.defineProperty(t,"RequestPolicyOptions",{enumerable:true,get:function(){return r.RequestPolicyOptions}});Object.defineProperty(t,"RestError",{enumerable:true,get:function(){return r.RestError}});Object.defineProperty(t,"WebResource",{enumerable:true,get:function(){return r.WebResource}});Object.defineProperty(t,"deserializationPolicy",{enumerable:true,get:function(){return r.deserializationPolicy}});t.AccountSASPermissions=AccountSASPermissions;t.AccountSASResourceTypes=AccountSASResourceTypes;t.AccountSASServices=AccountSASServices;t.AnonymousCredential=AnonymousCredential;t.AnonymousCredentialPolicy=AnonymousCredentialPolicy;t.AppendBlobClient=AppendBlobClient;t.BlobBatch=BlobBatch;t.BlobBatchClient=BlobBatchClient;t.BlobClient=BlobClient;t.BlobLeaseClient=BlobLeaseClient;t.BlobSASPermissions=BlobSASPermissions;t.BlobServiceClient=BlobServiceClient;t.BlockBlobClient=BlockBlobClient;t.ContainerClient=ContainerClient;t.ContainerSASPermissions=ContainerSASPermissions;t.Credential=Credential;t.CredentialPolicy=CredentialPolicy;t.PageBlobClient=PageBlobClient;t.Pipeline=Pipeline;t.SASQueryParameters=SASQueryParameters;t.StorageBrowserPolicy=StorageBrowserPolicy;t.StorageBrowserPolicyFactory=StorageBrowserPolicyFactory;t.StorageOAuthScopes=no;t.StorageRetryPolicy=StorageRetryPolicy;t.StorageRetryPolicyFactory=StorageRetryPolicyFactory;t.StorageSharedKeyCredential=StorageSharedKeyCredential;t.StorageSharedKeyCredentialPolicy=StorageSharedKeyCredentialPolicy;t.generateAccountSASQueryParameters=generateAccountSASQueryParameters;t.generateBlobSASQueryParameters=generateBlobSASQueryParameters;t.isPipelineLike=isPipelineLike;t.logger=Ks;t.newPipeline=newPipeline},679:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var L=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);L(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var M=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new M(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},334:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a=/^v1\./;const r=/^ghs_/;const i=/^ghu_/;async function auth(e){const t=e.split(/\./).length===3;const n=a.test(e)||r.test(e);const s=i.test(e);const o=t?"app":n?"installation":s?"user-to-server":"oauth";return{type:"token",token:e,tokenType:o}}function withAuthorizationPrefix(e){if(e.split(/\./).length===3){return`bearer ${e}`}return`token ${e}`}async function hook(e,t,a,r){const i=t.endpoint.merge(a,r);i.headers.authorization=withAuthorizationPrefix(e);return t(i)}const n=function createTokenAuth(e){if(!e){throw new Error("[@octokit/auth-token] No token passed to createTokenAuth")}if(typeof e!=="string"){throw new Error("[@octokit/auth-token] Token passed to createTokenAuth is not a string")}e=e.replace(/^(token|bearer) +/i,"");return Object.assign(auth.bind(null,e),{hook:hook.bind(null,e)})};t.createTokenAuth=n},6762:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5030);var i=a(3682);var n=a(6234);var s=a(8467);var o=a(334);function _objectWithoutPropertiesLoose(e,t){if(e==null)return{};var a={};var r=Object.keys(e);var i,n;for(n=0;n=0)continue;a[i]=e[i]}return a}function _objectWithoutProperties(e,t){if(e==null)return{};var a=_objectWithoutPropertiesLoose(e,t);var r,i;if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);for(i=0;i=0)continue;if(!Object.prototype.propertyIsEnumerable.call(e,r))continue;a[r]=e[r]}}return a}const p="3.6.0";const l=["authStrategy"];class Octokit{constructor(e={}){const t=new i.Collection;const a={baseUrl:n.request.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:t.bind(null,"request")}),mediaType:{previews:[],format:""}};a.headers["user-agent"]=[e.userAgent,`octokit-core.js/${p} ${r.getUserAgent()}`].filter(Boolean).join(" ");if(e.baseUrl){a.baseUrl=e.baseUrl}if(e.previews){a.mediaType.previews=e.previews}if(e.timeZone){a.headers["time-zone"]=e.timeZone}this.request=n.request.defaults(a);this.graphql=s.withCustomRequest(this.request).defaults(a);this.log=Object.assign({debug:()=>{},info:()=>{},warn:console.warn.bind(console),error:console.error.bind(console)},e.log);this.hook=t;if(!e.authStrategy){if(!e.auth){this.auth=async()=>({type:"unauthenticated"})}else{const a=o.createTokenAuth(e.auth);t.wrap("request",a.hook);this.auth=a}}else{const{authStrategy:a}=e,r=_objectWithoutProperties(e,l);const i=a(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:r},e.auth));t.wrap("request",i.hook);this.auth=i}const d=this.constructor;d.plugins.forEach((t=>{Object.assign(this,t(this,e))}))}static defaults(e){const t=class extends(this){constructor(...t){const a=t[0]||{};if(typeof e==="function"){super(e(a));return}super(Object.assign({},e,a,a.userAgent&&e.userAgent?{userAgent:`${a.userAgent} ${e.userAgent}`}:null))}};return t}static plugin(...e){var t;const a=this.plugins;const r=(t=class extends(this){},t.plugins=a.concat(e.filter((e=>!a.includes(e)))),t);return r}}Octokit.VERSION=p;Octokit.plugins=[];t.Octokit=Octokit},9440:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(3287);var i=a(5030);function lowercaseKeys(e){if(!e){return{}}return Object.keys(e).reduce(((t,a)=>{t[a.toLowerCase()]=e[a];return t}),{})}function mergeDeep(e,t){const a=Object.assign({},e);Object.keys(t).forEach((i=>{if(r.isPlainObject(t[i])){if(!(i in e))Object.assign(a,{[i]:t[i]});else a[i]=mergeDeep(e[i],t[i])}else{Object.assign(a,{[i]:t[i]})}}));return a}function removeUndefinedProperties(e){for(const t in e){if(e[t]===undefined){delete e[t]}}return e}function merge(e,t,a){if(typeof t==="string"){let[e,r]=t.split(" ");a=Object.assign(r?{method:e,url:r}:{url:e},a)}else{a=Object.assign({},t)}a.headers=lowercaseKeys(a.headers);removeUndefinedProperties(a);removeUndefinedProperties(a.headers);const r=mergeDeep(e||{},a);if(e&&e.mediaType.previews.length){r.mediaType.previews=e.mediaType.previews.filter((e=>!r.mediaType.previews.includes(e))).concat(r.mediaType.previews)}r.mediaType.previews=r.mediaType.previews.map((e=>e.replace(/-preview/,"")));return r}function addQueryParameters(e,t){const a=/\?/.test(e)?"&":"?";const r=Object.keys(t);if(r.length===0){return e}return e+a+r.map((e=>{if(e==="q"){return"q="+t.q.split("+").map(encodeURIComponent).join("+")}return`${e}=${encodeURIComponent(t[e])}`})).join("&")}const n=/\{[^}]+\}/g;function removeNonChars(e){return e.replace(/^\W+|\W+$/g,"").split(/,/)}function extractUrlVariableNames(e){const t=e.match(n);if(!t){return[]}return t.map(removeNonChars).reduce(((e,t)=>e.concat(t)),[])}function omit(e,t){return Object.keys(e).filter((e=>!t.includes(e))).reduce(((t,a)=>{t[a]=e[a];return t}),{})}function encodeReserved(e){return e.split(/(%[0-9A-Fa-f]{2})/g).map((function(e){if(!/%[0-9A-Fa-f]/.test(e)){e=encodeURI(e).replace(/%5B/g,"[").replace(/%5D/g,"]")}return e})).join("")}function encodeUnreserved(e){return encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function encodeValue(e,t,a){t=e==="+"||e==="#"?encodeReserved(t):encodeUnreserved(t);if(a){return encodeUnreserved(a)+"="+t}else{return t}}function isDefined(e){return e!==undefined&&e!==null}function isKeyOperator(e){return e===";"||e==="&"||e==="?"}function getValues(e,t,a,r){var i=e[a],n=[];if(isDefined(i)&&i!==""){if(typeof i==="string"||typeof i==="number"||typeof i==="boolean"){i=i.toString();if(r&&r!=="*"){i=i.substring(0,parseInt(r,10))}n.push(encodeValue(t,i,isKeyOperator(t)?a:""))}else{if(r==="*"){if(Array.isArray(i)){i.filter(isDefined).forEach((function(e){n.push(encodeValue(t,e,isKeyOperator(t)?a:""))}))}else{Object.keys(i).forEach((function(e){if(isDefined(i[e])){n.push(encodeValue(t,i[e],e))}}))}}else{const e=[];if(Array.isArray(i)){i.filter(isDefined).forEach((function(a){e.push(encodeValue(t,a))}))}else{Object.keys(i).forEach((function(a){if(isDefined(i[a])){e.push(encodeUnreserved(a));e.push(encodeValue(t,i[a].toString()))}}))}if(isKeyOperator(t)){n.push(encodeUnreserved(a)+"="+e.join(","))}else if(e.length!==0){n.push(e.join(","))}}}}else{if(t===";"){if(isDefined(i)){n.push(encodeUnreserved(a))}}else if(i===""&&(t==="&"||t==="?")){n.push(encodeUnreserved(a)+"=")}else if(i===""){n.push("")}}return n}function parseUrl(e){return{expand:expand.bind(null,e)}}function expand(e,t){var a=["+","#",".","/",";","?","&"];return e.replace(/\{([^\{\}]+)\}|([^\{\}]+)/g,(function(e,r,i){if(r){let e="";const i=[];if(a.indexOf(r.charAt(0))!==-1){e=r.charAt(0);r=r.substr(1)}r.split(/,/g).forEach((function(a){var r=/([^:\*]*)(?::(\d+)|(\*))?/.exec(a);i.push(getValues(t,e,r[1],r[2]||r[3]))}));if(e&&e!=="+"){var n=",";if(e==="?"){n="&"}else if(e!=="#"){n=e}return(i.length!==0?e:"")+i.join(n)}else{return i.join(",")}}else{return encodeReserved(i)}}))}function parse(e){let t=e.method.toUpperCase();let a=(e.url||"/").replace(/:([a-z]\w+)/g,"{$1}");let r=Object.assign({},e.headers);let i;let n=omit(e,["method","baseUrl","url","headers","request","mediaType"]);const s=extractUrlVariableNames(a);a=parseUrl(a).expand(n);if(!/^http/.test(a)){a=e.baseUrl+a}const o=Object.keys(e).filter((e=>s.includes(e))).concat("baseUrl");const p=omit(n,o);const l=/application\/octet-stream/i.test(r.accept);if(!l){if(e.mediaType.format){r.accept=r.accept.split(/,/).map((t=>t.replace(/application\/vnd(\.\w+)(\.v3)?(\.\w+)?(\+json)?$/,`application/vnd$1$2.${e.mediaType.format}`))).join(",")}if(e.mediaType.previews.length){const t=r.accept.match(/[\w-]+(?=-preview)/g)||[];r.accept=t.concat(e.mediaType.previews).map((t=>{const a=e.mediaType.format?`.${e.mediaType.format}`:"+json";return`application/vnd.github.${t}-preview${a}`})).join(",")}}if(["GET","HEAD"].includes(t)){a=addQueryParameters(a,p)}else{if("data"in p){i=p.data}else{if(Object.keys(p).length){i=p}else{r["content-length"]=0}}}if(!r["content-type"]&&typeof i!=="undefined"){r["content-type"]="application/json; charset=utf-8"}if(["PATCH","PUT"].includes(t)&&typeof i==="undefined"){i=""}return Object.assign({method:t,url:a,headers:r},typeof i!=="undefined"?{body:i}:null,e.request?{request:e.request}:null)}function endpointWithDefaults(e,t,a){return parse(merge(e,t,a))}function withDefaults(e,t){const a=merge(e,t);const r=endpointWithDefaults.bind(null,a);return Object.assign(r,{DEFAULTS:a,defaults:withDefaults.bind(null,a),merge:merge.bind(null,a),parse:parse})}const s="6.0.12";const o=`octokit-endpoint.js/${s} ${i.getUserAgent()}`;const p={method:"GET",baseUrl:"https://api.github.com",headers:{accept:"application/vnd.github.v3+json","user-agent":o},mediaType:{format:"",previews:[]}};const l=withDefaults(null,p);t.endpoint=l},8467:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(6234);var i=a(5030);const n="4.8.0";function _buildMessageForResponseErrors(e){return`Request failed due to following response errors:\n`+e.errors.map((e=>` - ${e.message}`)).join("\n")}class GraphqlResponseError extends Error{constructor(e,t,a){super(_buildMessageForResponseErrors(a));this.request=e;this.headers=t;this.response=a;this.name="GraphqlResponseError";this.errors=a.errors;this.data=a.data;if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}}}const s=["method","baseUrl","url","headers","request","query","mediaType"];const o=["query","method","url"];const p=/\/api\/v3\/?$/;function graphql(e,t,a){if(a){if(typeof t==="string"&&"query"in a){return Promise.reject(new Error(`[@octokit/graphql] "query" cannot be used as variable name`))}for(const e in a){if(!o.includes(e))continue;return Promise.reject(new Error(`[@octokit/graphql] "${e}" cannot be used as variable name`))}}const r=typeof t==="string"?Object.assign({query:t},a):t;const i=Object.keys(r).reduce(((e,t)=>{if(s.includes(t)){e[t]=r[t];return e}if(!e.variables){e.variables={}}e.variables[t]=r[t];return e}),{});const n=r.baseUrl||e.endpoint.DEFAULTS.baseUrl;if(p.test(n)){i.url=n.replace(p,"/api/graphql")}return e(i).then((e=>{if(e.data.errors){const t={};for(const a of Object.keys(e.headers)){t[a]=e.headers[a]}throw new GraphqlResponseError(i,t,e.data)}return e.data.data}))}function withDefaults(e,t){const a=e.defaults(t);const newApi=(e,t)=>graphql(a,e,t);return Object.assign(newApi,{defaults:withDefaults.bind(null,a),endpoint:r.request.endpoint})}const l=withDefaults(r.request,{headers:{"user-agent":`octokit-graphql.js/${n} ${i.getUserAgent()}`},method:"POST",url:"/graphql"});function withCustomRequest(e){return withDefaults(e,{method:"POST",url:"/graphql"})}t.GraphqlResponseError=GraphqlResponseError;t.graphql=l;t.withCustomRequest=withCustomRequest},4193:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a="2.21.3";function ownKeys(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function _objectSpread2(e){for(var t=1;t({async next(){if(!o)return{done:true};try{const e=await i({method:n,url:o,headers:s});const t=normalizePaginatedListResponse(e);o=((t.headers.link||"").match(/<([^>]+)>;\s*rel="next"/)||[])[1];return{value:t}}catch(e){if(e.status!==409)throw e;o="";return{value:{status:200,headers:{},data:[]}}}}})}}function paginate(e,t,a,r){if(typeof a==="function"){r=a;a=undefined}return gather(e,[],iterator(e,t,a)[Symbol.asyncIterator](),r)}function gather(e,t,a,r){return a.next().then((i=>{if(i.done){return t}let n=false;function done(){n=true}t=t.concat(r?r(i.value,done):i.value.data);if(n){return t}return gather(e,t,a,r)}))}const r=Object.assign(paginate,{iterator:iterator});const i=["GET /app/hook/deliveries","GET /app/installations","GET /applications/grants","GET /authorizations","GET /enterprises/{enterprise}/actions/permissions/organizations","GET /enterprises/{enterprise}/actions/runner-groups","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/organizations","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/runners","GET /enterprises/{enterprise}/actions/runners","GET /enterprises/{enterprise}/audit-log","GET /enterprises/{enterprise}/secret-scanning/alerts","GET /enterprises/{enterprise}/settings/billing/advanced-security","GET /events","GET /gists","GET /gists/public","GET /gists/starred","GET /gists/{gist_id}/comments","GET /gists/{gist_id}/commits","GET /gists/{gist_id}/forks","GET /installation/repositories","GET /issues","GET /licenses","GET /marketplace_listing/plans","GET /marketplace_listing/plans/{plan_id}/accounts","GET /marketplace_listing/stubbed/plans","GET /marketplace_listing/stubbed/plans/{plan_id}/accounts","GET /networks/{owner}/{repo}/events","GET /notifications","GET /organizations","GET /orgs/{org}/actions/cache/usage-by-repository","GET /orgs/{org}/actions/permissions/repositories","GET /orgs/{org}/actions/runner-groups","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners","GET /orgs/{org}/actions/runners","GET /orgs/{org}/actions/secrets","GET /orgs/{org}/actions/secrets/{secret_name}/repositories","GET /orgs/{org}/audit-log","GET /orgs/{org}/blocks","GET /orgs/{org}/code-scanning/alerts","GET /orgs/{org}/codespaces","GET /orgs/{org}/credential-authorizations","GET /orgs/{org}/dependabot/secrets","GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories","GET /orgs/{org}/events","GET /orgs/{org}/external-groups","GET /orgs/{org}/failed_invitations","GET /orgs/{org}/hooks","GET /orgs/{org}/hooks/{hook_id}/deliveries","GET /orgs/{org}/installations","GET /orgs/{org}/invitations","GET /orgs/{org}/invitations/{invitation_id}/teams","GET /orgs/{org}/issues","GET /orgs/{org}/members","GET /orgs/{org}/migrations","GET /orgs/{org}/migrations/{migration_id}/repositories","GET /orgs/{org}/outside_collaborators","GET /orgs/{org}/packages","GET /orgs/{org}/packages/{package_type}/{package_name}/versions","GET /orgs/{org}/projects","GET /orgs/{org}/public_members","GET /orgs/{org}/repos","GET /orgs/{org}/secret-scanning/alerts","GET /orgs/{org}/settings/billing/advanced-security","GET /orgs/{org}/team-sync/groups","GET /orgs/{org}/teams","GET /orgs/{org}/teams/{team_slug}/discussions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions","GET /orgs/{org}/teams/{team_slug}/invitations","GET /orgs/{org}/teams/{team_slug}/members","GET /orgs/{org}/teams/{team_slug}/projects","GET /orgs/{org}/teams/{team_slug}/repos","GET /orgs/{org}/teams/{team_slug}/teams","GET /projects/columns/{column_id}/cards","GET /projects/{project_id}/collaborators","GET /projects/{project_id}/columns","GET /repos/{owner}/{repo}/actions/artifacts","GET /repos/{owner}/{repo}/actions/caches","GET /repos/{owner}/{repo}/actions/runners","GET /repos/{owner}/{repo}/actions/runs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts","GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs","GET /repos/{owner}/{repo}/actions/secrets","GET /repos/{owner}/{repo}/actions/workflows","GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs","GET /repos/{owner}/{repo}/assignees","GET /repos/{owner}/{repo}/branches","GET /repos/{owner}/{repo}/check-runs/{check_run_id}/annotations","GET /repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs","GET /repos/{owner}/{repo}/code-scanning/alerts","GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances","GET /repos/{owner}/{repo}/code-scanning/analyses","GET /repos/{owner}/{repo}/codespaces","GET /repos/{owner}/{repo}/codespaces/devcontainers","GET /repos/{owner}/{repo}/codespaces/secrets","GET /repos/{owner}/{repo}/collaborators","GET /repos/{owner}/{repo}/comments","GET /repos/{owner}/{repo}/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/commits","GET /repos/{owner}/{repo}/commits/{commit_sha}/comments","GET /repos/{owner}/{repo}/commits/{commit_sha}/pulls","GET /repos/{owner}/{repo}/commits/{ref}/check-runs","GET /repos/{owner}/{repo}/commits/{ref}/check-suites","GET /repos/{owner}/{repo}/commits/{ref}/status","GET /repos/{owner}/{repo}/commits/{ref}/statuses","GET /repos/{owner}/{repo}/contributors","GET /repos/{owner}/{repo}/dependabot/secrets","GET /repos/{owner}/{repo}/deployments","GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses","GET /repos/{owner}/{repo}/environments","GET /repos/{owner}/{repo}/events","GET /repos/{owner}/{repo}/forks","GET /repos/{owner}/{repo}/git/matching-refs/{ref}","GET /repos/{owner}/{repo}/hooks","GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries","GET /repos/{owner}/{repo}/invitations","GET /repos/{owner}/{repo}/issues","GET /repos/{owner}/{repo}/issues/comments","GET /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/issues/events","GET /repos/{owner}/{repo}/issues/{issue_number}/comments","GET /repos/{owner}/{repo}/issues/{issue_number}/events","GET /repos/{owner}/{repo}/issues/{issue_number}/labels","GET /repos/{owner}/{repo}/issues/{issue_number}/reactions","GET /repos/{owner}/{repo}/issues/{issue_number}/timeline","GET /repos/{owner}/{repo}/keys","GET /repos/{owner}/{repo}/labels","GET /repos/{owner}/{repo}/milestones","GET /repos/{owner}/{repo}/milestones/{milestone_number}/labels","GET /repos/{owner}/{repo}/notifications","GET /repos/{owner}/{repo}/pages/builds","GET /repos/{owner}/{repo}/projects","GET /repos/{owner}/{repo}/pulls","GET /repos/{owner}/{repo}/pulls/comments","GET /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/pulls/{pull_number}/comments","GET /repos/{owner}/{repo}/pulls/{pull_number}/commits","GET /repos/{owner}/{repo}/pulls/{pull_number}/files","GET /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments","GET /repos/{owner}/{repo}/releases","GET /repos/{owner}/{repo}/releases/{release_id}/assets","GET /repos/{owner}/{repo}/releases/{release_id}/reactions","GET /repos/{owner}/{repo}/secret-scanning/alerts","GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations","GET /repos/{owner}/{repo}/stargazers","GET /repos/{owner}/{repo}/subscribers","GET /repos/{owner}/{repo}/tags","GET /repos/{owner}/{repo}/teams","GET /repos/{owner}/{repo}/topics","GET /repositories","GET /repositories/{repository_id}/environments/{environment_name}/secrets","GET /search/code","GET /search/commits","GET /search/issues","GET /search/labels","GET /search/repositories","GET /search/topics","GET /search/users","GET /teams/{team_id}/discussions","GET /teams/{team_id}/discussions/{discussion_number}/comments","GET /teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /teams/{team_id}/discussions/{discussion_number}/reactions","GET /teams/{team_id}/invitations","GET /teams/{team_id}/members","GET /teams/{team_id}/projects","GET /teams/{team_id}/repos","GET /teams/{team_id}/teams","GET /user/blocks","GET /user/codespaces","GET /user/codespaces/secrets","GET /user/emails","GET /user/followers","GET /user/following","GET /user/gpg_keys","GET /user/installations","GET /user/installations/{installation_id}/repositories","GET /user/issues","GET /user/keys","GET /user/marketplace_purchases","GET /user/marketplace_purchases/stubbed","GET /user/memberships/orgs","GET /user/migrations","GET /user/migrations/{migration_id}/repositories","GET /user/orgs","GET /user/packages","GET /user/packages/{package_type}/{package_name}/versions","GET /user/public_emails","GET /user/repos","GET /user/repository_invitations","GET /user/starred","GET /user/subscriptions","GET /user/teams","GET /users","GET /users/{username}/events","GET /users/{username}/events/orgs/{org}","GET /users/{username}/events/public","GET /users/{username}/followers","GET /users/{username}/following","GET /users/{username}/gists","GET /users/{username}/gpg_keys","GET /users/{username}/keys","GET /users/{username}/orgs","GET /users/{username}/packages","GET /users/{username}/projects","GET /users/{username}/received_events","GET /users/{username}/received_events/public","GET /users/{username}/repos","GET /users/{username}/starred","GET /users/{username}/subscriptions"];function isPaginatingEndpoint(e){if(typeof e==="string"){return i.includes(e)}else{return false}}function paginateRest(e){return{paginate:Object.assign(paginate.bind(null,e),{iterator:iterator.bind(null,e)})}}paginateRest.VERSION=a;t.composePaginateRest=r;t.isPaginatingEndpoint=isPaginatingEndpoint;t.paginateRest=paginateRest;t.paginatingEndpoints=i},3044:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function ownKeys(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);if(t){r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))}a.push.apply(a,r)}return a}function _objectSpread2(e){for(var t=1;t{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var r=a(8932);var i=_interopDefault(a(1223));const n=i((e=>console.warn(e)));const s=i((e=>console.warn(e)));class RequestError extends Error{constructor(e,t,a){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="HttpError";this.status=t;let i;if("headers"in a&&typeof a.headers!=="undefined"){i=a.headers}if("response"in a){this.response=a.response;i=a.response.headers}const o=Object.assign({},a.request);if(a.request.headers.authorization){o.headers=Object.assign({},a.request.headers,{authorization:a.request.headers.authorization.replace(/ .*$/," [REDACTED]")})}o.url=o.url.replace(/\bclient_secret=\w+/g,"client_secret=[REDACTED]").replace(/\baccess_token=\w+/g,"access_token=[REDACTED]");this.request=o;Object.defineProperty(this,"code",{get(){n(new r.Deprecation("[@octokit/request-error] `error.code` is deprecated, use `error.status`."));return t}});Object.defineProperty(this,"headers",{get(){s(new r.Deprecation("[@octokit/request-error] `error.headers` is deprecated, use `error.response.headers`."));return i||{}}})}}t.RequestError=RequestError},6234:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var r=a(9440);var i=a(5030);var n=a(3287);var s=_interopDefault(a(467));var o=a(537);const p="5.6.3";function getBufferResponse(e){return e.arrayBuffer()}function fetchWrapper(e){const t=e.request&&e.request.log?e.request.log:console;if(n.isPlainObject(e.body)||Array.isArray(e.body)){e.body=JSON.stringify(e.body)}let a={};let r;let i;const p=e.request&&e.request.fetch||s;return p(e.url,Object.assign({method:e.method,body:e.body,headers:e.headers,redirect:e.redirect},e.request)).then((async n=>{i=n.url;r=n.status;for(const e of n.headers){a[e[0]]=e[1]}if("deprecation"in a){const r=a.link&&a.link.match(/<([^>]+)>; rel="deprecation"/);const i=r&&r.pop();t.warn(`[@octokit/request] "${e.method} ${e.url}" is deprecated. It is scheduled to be removed on ${a.sunset}${i?`. See ${i}`:""}`)}if(r===204||r===205){return}if(e.method==="HEAD"){if(r<400){return}throw new o.RequestError(n.statusText,r,{response:{url:i,status:r,headers:a,data:undefined},request:e})}if(r===304){throw new o.RequestError("Not modified",r,{response:{url:i,status:r,headers:a,data:await getResponseData(n)},request:e})}if(r>=400){const t=await getResponseData(n);const s=new o.RequestError(toErrorMessage(t),r,{response:{url:i,status:r,headers:a,data:t},request:e});throw s}return getResponseData(n)})).then((e=>({status:r,url:i,headers:a,data:e}))).catch((t=>{if(t instanceof o.RequestError)throw t;throw new o.RequestError(t.message,500,{request:e})}))}async function getResponseData(e){const t=e.headers.get("content-type");if(/application\/json/.test(t)){return e.json()}if(!t||/^text\/|charset=utf-8$/.test(t)){return e.text()}return getBufferResponse(e)}function toErrorMessage(e){if(typeof e==="string")return e;if("message"in e){if(Array.isArray(e.errors)){return`${e.message}: ${e.errors.map(JSON.stringify).join(", ")}`}return e.message}return`Unknown error: ${JSON.stringify(e)}`}function withDefaults(e,t){const a=e.defaults(t);const newApi=function(e,t){const r=a.merge(e,t);if(!r.request||!r.request.hook){return fetchWrapper(a.parse(r))}const request=(e,t)=>fetchWrapper(a.parse(a.merge(e,t)));Object.assign(request,{endpoint:a,defaults:withDefaults.bind(null,a)});return r.request.hook(request,r)};return Object.assign(newApi,{endpoint:a,defaults:withDefaults.bind(null,a)})}const l=withDefaults(r.endpoint,{headers:{"user-agent":`octokit-request.js/${p} ${i.getUserAgent()}`}});t.request=l},7171:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ContextAPI=void 0;const r=a(4118);const i=a(5135);const n=a(1877);const s="context";const o=new r.NoopContextManager;class ContextAPI{constructor(){}static getInstance(){if(!this._instance){this._instance=new ContextAPI}return this._instance}setGlobalContextManager(e){return(0,i.registerGlobal)(s,e,n.DiagAPI.instance())}active(){return this._getContextManager().active()}with(e,t,a,...r){return this._getContextManager().with(e,t,a,...r)}bind(e,t){return this._getContextManager().bind(e,t)}_getContextManager(){return(0,i.getGlobal)(s)||o}disable(){this._getContextManager().disable();(0,i.unregisterGlobal)(s,n.DiagAPI.instance())}}t.ContextAPI=ContextAPI},1877:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagAPI=void 0;const r=a(7978);const i=a(9639);const n=a(8077);const s=a(5135);const o="diag";class DiagAPI{constructor(){function _logProxy(e){return function(...t){const a=(0,s.getGlobal)("diag");if(!a)return;return a[e](...t)}}const e=this;const setLogger=(t,a={logLevel:n.DiagLogLevel.INFO})=>{var r,o,p;if(t===e){const t=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");e.error((r=t.stack)!==null&&r!==void 0?r:t.message);return false}if(typeof a==="number"){a={logLevel:a}}const l=(0,s.getGlobal)("diag");const d=(0,i.createLogLevelDiagLogger)((o=a.logLevel)!==null&&o!==void 0?o:n.DiagLogLevel.INFO,t);if(l&&!a.suppressOverrideMessage){const e=(p=(new Error).stack)!==null&&p!==void 0?p:"";l.warn(`Current logger will be overwritten from ${e}`);d.warn(`Current logger will overwrite one already registered from ${e}`)}return(0,s.registerGlobal)("diag",d,e,true)};e.setLogger=setLogger;e.disable=()=>{(0,s.unregisterGlobal)(o,e)};e.createComponentLogger=e=>new r.DiagComponentLogger(e);e.verbose=_logProxy("verbose");e.debug=_logProxy("debug");e.info=_logProxy("info");e.warn=_logProxy("warn");e.error=_logProxy("error")}static instance(){if(!this._instance){this._instance=new DiagAPI}return this._instance}}t.DiagAPI=DiagAPI},7696:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MetricsAPI=void 0;const r=a(2647);const i=a(5135);const n=a(1877);const s="metrics";class MetricsAPI{constructor(){}static getInstance(){if(!this._instance){this._instance=new MetricsAPI}return this._instance}setGlobalMeterProvider(e){return(0,i.registerGlobal)(s,e,n.DiagAPI.instance())}getMeterProvider(){return(0,i.getGlobal)(s)||r.NOOP_METER_PROVIDER}getMeter(e,t,a){return this.getMeterProvider().getMeter(e,t,a)}disable(){(0,i.unregisterGlobal)(s,n.DiagAPI.instance())}}t.MetricsAPI=MetricsAPI},9909:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.PropagationAPI=void 0;const r=a(5135);const i=a(2368);const n=a(865);const s=a(7682);const o=a(8136);const p=a(1877);const l="propagation";const d=new i.NoopTextMapPropagator;class PropagationAPI{constructor(){this.createBaggage=o.createBaggage;this.getBaggage=s.getBaggage;this.getActiveBaggage=s.getActiveBaggage;this.setBaggage=s.setBaggage;this.deleteBaggage=s.deleteBaggage}static getInstance(){if(!this._instance){this._instance=new PropagationAPI}return this._instance}setGlobalPropagator(e){return(0,r.registerGlobal)(l,e,p.DiagAPI.instance())}inject(e,t,a=n.defaultTextMapSetter){return this._getGlobalPropagator().inject(e,t,a)}extract(e,t,a=n.defaultTextMapGetter){return this._getGlobalPropagator().extract(e,t,a)}fields(){return this._getGlobalPropagator().fields()}disable(){(0,r.unregisterGlobal)(l,p.DiagAPI.instance())}_getGlobalPropagator(){return(0,r.getGlobal)(l)||d}}t.PropagationAPI=PropagationAPI},1539:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceAPI=void 0;const r=a(5135);const i=a(2285);const n=a(9745);const s=a(3326);const o=a(1877);const p="trace";class TraceAPI{constructor(){this._proxyTracerProvider=new i.ProxyTracerProvider;this.wrapSpanContext=n.wrapSpanContext;this.isSpanContextValid=n.isSpanContextValid;this.deleteSpan=s.deleteSpan;this.getSpan=s.getSpan;this.getActiveSpan=s.getActiveSpan;this.getSpanContext=s.getSpanContext;this.setSpan=s.setSpan;this.setSpanContext=s.setSpanContext}static getInstance(){if(!this._instance){this._instance=new TraceAPI}return this._instance}setGlobalTracerProvider(e){const t=(0,r.registerGlobal)(p,this._proxyTracerProvider,o.DiagAPI.instance());if(t){this._proxyTracerProvider.setDelegate(e)}return t}getTracerProvider(){return(0,r.getGlobal)(p)||this._proxyTracerProvider}getTracer(e,t){return this.getTracerProvider().getTracer(e,t)}disable(){(0,r.unregisterGlobal)(p,o.DiagAPI.instance());this._proxyTracerProvider=new i.ProxyTracerProvider}}t.TraceAPI=TraceAPI},7682:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.deleteBaggage=t.setBaggage=t.getActiveBaggage=t.getBaggage=void 0;const r=a(7171);const i=a(8242);const n=(0,i.createContextKey)("OpenTelemetry Baggage Key");function getBaggage(e){return e.getValue(n)||undefined}t.getBaggage=getBaggage;function getActiveBaggage(){return getBaggage(r.ContextAPI.getInstance().active())}t.getActiveBaggage=getActiveBaggage;function setBaggage(e,t){return e.setValue(n,t)}t.setBaggage=setBaggage;function deleteBaggage(e){return e.deleteValue(n)}t.deleteBaggage=deleteBaggage},4811:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.BaggageImpl=void 0;class BaggageImpl{constructor(e){this._entries=e?new Map(e):new Map}getEntry(e){const t=this._entries.get(e);if(!t){return undefined}return Object.assign({},t)}getAllEntries(){return Array.from(this._entries.entries()).map((([e,t])=>[e,t]))}setEntry(e,t){const a=new BaggageImpl(this._entries);a._entries.set(e,t);return a}removeEntry(e){const t=new BaggageImpl(this._entries);t._entries.delete(e);return t}removeEntries(...e){const t=new BaggageImpl(this._entries);for(const a of e){t._entries.delete(a)}return t}clear(){return new BaggageImpl}}t.BaggageImpl=BaggageImpl},3542:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.baggageEntryMetadataSymbol=void 0;t.baggageEntryMetadataSymbol=Symbol("BaggageEntryMetadata")},8136:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.baggageEntryMetadataFromString=t.createBaggage=void 0;const r=a(1877);const i=a(4811);const n=a(3542);const s=r.DiagAPI.instance();function createBaggage(e={}){return new i.BaggageImpl(new Map(Object.entries(e)))}t.createBaggage=createBaggage;function baggageEntryMetadataFromString(e){if(typeof e!=="string"){s.error(`Cannot create baggage metadata from unknown type: ${typeof e}`);e=""}return{__TYPE__:n.baggageEntryMetadataSymbol,toString(){return e}}}t.baggageEntryMetadataFromString=baggageEntryMetadataFromString},7393:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.context=void 0;const r=a(7171);t.context=r.ContextAPI.getInstance()},4118:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopContextManager=void 0;const r=a(8242);class NoopContextManager{active(){return r.ROOT_CONTEXT}with(e,t,a,...r){return t.call(a,...r)}bind(e,t){return t}enable(){return this}disable(){return this}}t.NoopContextManager=NoopContextManager},8242:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ROOT_CONTEXT=t.createContextKey=void 0;function createContextKey(e){return Symbol.for(e)}t.createContextKey=createContextKey;class BaseContext{constructor(e){const t=this;t._currentContext=e?new Map(e):new Map;t.getValue=e=>t._currentContext.get(e);t.setValue=(e,a)=>{const r=new BaseContext(t._currentContext);r._currentContext.set(e,a);return r};t.deleteValue=e=>{const a=new BaseContext(t._currentContext);a._currentContext.delete(e);return a}}}t.ROOT_CONTEXT=new BaseContext},9721:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.diag=void 0;const r=a(1877);t.diag=r.DiagAPI.instance()},7978:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagComponentLogger=void 0;const r=a(5135);class DiagComponentLogger{constructor(e){this._namespace=e.namespace||"DiagComponentLogger"}debug(...e){return logProxy("debug",this._namespace,e)}error(...e){return logProxy("error",this._namespace,e)}info(...e){return logProxy("info",this._namespace,e)}warn(...e){return logProxy("warn",this._namespace,e)}verbose(...e){return logProxy("verbose",this._namespace,e)}}t.DiagComponentLogger=DiagComponentLogger;function logProxy(e,t,a){const i=(0,r.getGlobal)("diag");if(!i){return}a.unshift(t);return i[e](...a)}},3041:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagConsoleLogger=void 0;const a=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}];class DiagConsoleLogger{constructor(){function _consoleFunc(e){return function(...t){if(console){let a=console[e];if(typeof a!=="function"){a=console.log}if(typeof a==="function"){return a.apply(console,t)}}}}for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createLogLevelDiagLogger=void 0;const r=a(8077);function createLogLevelDiagLogger(e,t){if(er.DiagLogLevel.ALL){e=r.DiagLogLevel.ALL}t=t||{};function _filterFunc(a,r){const i=t[a];if(typeof i==="function"&&e>=r){return i.bind(t)}return function(){}}return{error:_filterFunc("error",r.DiagLogLevel.ERROR),warn:_filterFunc("warn",r.DiagLogLevel.WARN),info:_filterFunc("info",r.DiagLogLevel.INFO),debug:_filterFunc("debug",r.DiagLogLevel.DEBUG),verbose:_filterFunc("verbose",r.DiagLogLevel.VERBOSE)}}t.createLogLevelDiagLogger=createLogLevelDiagLogger},8077:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagLogLevel=void 0;var a;(function(e){e[e["NONE"]=0]="NONE";e[e["ERROR"]=30]="ERROR";e[e["WARN"]=50]="WARN";e[e["INFO"]=60]="INFO";e[e["DEBUG"]=70]="DEBUG";e[e["VERBOSE"]=80]="VERBOSE";e[e["ALL"]=9999]="ALL"})(a=t.DiagLogLevel||(t.DiagLogLevel={}))},5163:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.trace=t.propagation=t.metrics=t.diag=t.context=t.INVALID_SPAN_CONTEXT=t.INVALID_TRACEID=t.INVALID_SPANID=t.isValidSpanId=t.isValidTraceId=t.isSpanContextValid=t.createTraceState=t.TraceFlags=t.SpanStatusCode=t.SpanKind=t.SamplingDecision=t.ProxyTracerProvider=t.ProxyTracer=t.defaultTextMapSetter=t.defaultTextMapGetter=t.ValueType=t.createNoopMeter=t.DiagLogLevel=t.DiagConsoleLogger=t.ROOT_CONTEXT=t.createContextKey=t.baggageEntryMetadataFromString=void 0;var r=a(8136);Object.defineProperty(t,"baggageEntryMetadataFromString",{enumerable:true,get:function(){return r.baggageEntryMetadataFromString}});var i=a(8242);Object.defineProperty(t,"createContextKey",{enumerable:true,get:function(){return i.createContextKey}});Object.defineProperty(t,"ROOT_CONTEXT",{enumerable:true,get:function(){return i.ROOT_CONTEXT}});var n=a(3041);Object.defineProperty(t,"DiagConsoleLogger",{enumerable:true,get:function(){return n.DiagConsoleLogger}});var s=a(8077);Object.defineProperty(t,"DiagLogLevel",{enumerable:true,get:function(){return s.DiagLogLevel}});var o=a(4837);Object.defineProperty(t,"createNoopMeter",{enumerable:true,get:function(){return o.createNoopMeter}});var p=a(9999);Object.defineProperty(t,"ValueType",{enumerable:true,get:function(){return p.ValueType}});var l=a(865);Object.defineProperty(t,"defaultTextMapGetter",{enumerable:true,get:function(){return l.defaultTextMapGetter}});Object.defineProperty(t,"defaultTextMapSetter",{enumerable:true,get:function(){return l.defaultTextMapSetter}});var d=a(3503);Object.defineProperty(t,"ProxyTracer",{enumerable:true,get:function(){return d.ProxyTracer}});var c=a(2285);Object.defineProperty(t,"ProxyTracerProvider",{enumerable:true,get:function(){return c.ProxyTracerProvider}});var m=a(3209);Object.defineProperty(t,"SamplingDecision",{enumerable:true,get:function(){return m.SamplingDecision}});var u=a(1424);Object.defineProperty(t,"SpanKind",{enumerable:true,get:function(){return u.SpanKind}});var h=a(8845);Object.defineProperty(t,"SpanStatusCode",{enumerable:true,get:function(){return h.SpanStatusCode}});var g=a(6905);Object.defineProperty(t,"TraceFlags",{enumerable:true,get:function(){return g.TraceFlags}});var y=a(2615);Object.defineProperty(t,"createTraceState",{enumerable:true,get:function(){return y.createTraceState}});var v=a(9745);Object.defineProperty(t,"isSpanContextValid",{enumerable:true,get:function(){return v.isSpanContextValid}});Object.defineProperty(t,"isValidTraceId",{enumerable:true,get:function(){return v.isValidTraceId}});Object.defineProperty(t,"isValidSpanId",{enumerable:true,get:function(){return v.isValidSpanId}});var b=a(1760);Object.defineProperty(t,"INVALID_SPANID",{enumerable:true,get:function(){return b.INVALID_SPANID}});Object.defineProperty(t,"INVALID_TRACEID",{enumerable:true,get:function(){return b.INVALID_TRACEID}});Object.defineProperty(t,"INVALID_SPAN_CONTEXT",{enumerable:true,get:function(){return b.INVALID_SPAN_CONTEXT}});const x=a(7393);Object.defineProperty(t,"context",{enumerable:true,get:function(){return x.context}});const w=a(9721);Object.defineProperty(t,"diag",{enumerable:true,get:function(){return w.diag}});const S=a(2601);Object.defineProperty(t,"metrics",{enumerable:true,get:function(){return S.metrics}});const N=a(7591);Object.defineProperty(t,"propagation",{enumerable:true,get:function(){return N.propagation}});const T=a(8989);Object.defineProperty(t,"trace",{enumerable:true,get:function(){return T.trace}});t["default"]={context:x.context,diag:w.diag,metrics:S.metrics,propagation:N.propagation,trace:T.trace}},5135:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.unregisterGlobal=t.getGlobal=t.registerGlobal=void 0;const r=a(9957);const i=a(8996);const n=a(1522);const s=i.VERSION.split(".")[0];const o=Symbol.for(`opentelemetry.js.api.${s}`);const p=r._globalThis;function registerGlobal(e,t,a,r=false){var n;const s=p[o]=(n=p[o])!==null&&n!==void 0?n:{version:i.VERSION};if(!r&&s[e]){const t=new Error(`@opentelemetry/api: Attempted duplicate registration of API: ${e}`);a.error(t.stack||t.message);return false}if(s.version!==i.VERSION){const t=new Error(`@opentelemetry/api: Registration of version v${s.version} for ${e} does not match previously registered API v${i.VERSION}`);a.error(t.stack||t.message);return false}s[e]=t;a.debug(`@opentelemetry/api: Registered a global for ${e} v${i.VERSION}.`);return true}t.registerGlobal=registerGlobal;function getGlobal(e){var t,a;const r=(t=p[o])===null||t===void 0?void 0:t.version;if(!r||!(0,n.isCompatible)(r)){return}return(a=p[o])===null||a===void 0?void 0:a[e]}t.getGlobal=getGlobal;function unregisterGlobal(e,t){t.debug(`@opentelemetry/api: Unregistering a global for ${e} v${i.VERSION}.`);const a=p[o];if(a){delete a[e]}}t.unregisterGlobal=unregisterGlobal},1522:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.isCompatible=t._makeCompatibilityCheck=void 0;const r=a(8996);const i=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;function _makeCompatibilityCheck(e){const t=new Set([e]);const a=new Set;const r=e.match(i);if(!r){return()=>false}const n={major:+r[1],minor:+r[2],patch:+r[3],prerelease:r[4]};if(n.prerelease!=null){return function isExactmatch(t){return t===e}}function _reject(e){a.add(e);return false}function _accept(e){t.add(e);return true}return function isCompatible(e){if(t.has(e)){return true}if(a.has(e)){return false}const r=e.match(i);if(!r){return _reject(e)}const s={major:+r[1],minor:+r[2],patch:+r[3],prerelease:r[4]};if(s.prerelease!=null){return _reject(e)}if(n.major!==s.major){return _reject(e)}if(n.major===0){if(n.minor===s.minor&&n.patch<=s.patch){return _accept(e)}return _reject(e)}if(n.minor<=s.minor){return _accept(e)}return _reject(e)}}t._makeCompatibilityCheck=_makeCompatibilityCheck;t.isCompatible=_makeCompatibilityCheck(r.VERSION)},2601:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.metrics=void 0;const r=a(7696);t.metrics=r.MetricsAPI.getInstance()},9999:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ValueType=void 0;var a;(function(e){e[e["INT"]=0]="INT";e[e["DOUBLE"]=1]="DOUBLE"})(a=t.ValueType||(t.ValueType={}))},4837:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createNoopMeter=t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC=t.NOOP_OBSERVABLE_GAUGE_METRIC=t.NOOP_OBSERVABLE_COUNTER_METRIC=t.NOOP_UP_DOWN_COUNTER_METRIC=t.NOOP_HISTOGRAM_METRIC=t.NOOP_COUNTER_METRIC=t.NOOP_METER=t.NoopObservableUpDownCounterMetric=t.NoopObservableGaugeMetric=t.NoopObservableCounterMetric=t.NoopObservableMetric=t.NoopHistogramMetric=t.NoopUpDownCounterMetric=t.NoopCounterMetric=t.NoopMetric=t.NoopMeter=void 0;class NoopMeter{constructor(){}createHistogram(e,a){return t.NOOP_HISTOGRAM_METRIC}createCounter(e,a){return t.NOOP_COUNTER_METRIC}createUpDownCounter(e,a){return t.NOOP_UP_DOWN_COUNTER_METRIC}createObservableGauge(e,a){return t.NOOP_OBSERVABLE_GAUGE_METRIC}createObservableCounter(e,a){return t.NOOP_OBSERVABLE_COUNTER_METRIC}createObservableUpDownCounter(e,a){return t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC}addBatchObservableCallback(e,t){}removeBatchObservableCallback(e){}}t.NoopMeter=NoopMeter;class NoopMetric{}t.NoopMetric=NoopMetric;class NoopCounterMetric extends NoopMetric{add(e,t){}}t.NoopCounterMetric=NoopCounterMetric;class NoopUpDownCounterMetric extends NoopMetric{add(e,t){}}t.NoopUpDownCounterMetric=NoopUpDownCounterMetric;class NoopHistogramMetric extends NoopMetric{record(e,t){}}t.NoopHistogramMetric=NoopHistogramMetric;class NoopObservableMetric{addCallback(e){}removeCallback(e){}}t.NoopObservableMetric=NoopObservableMetric;class NoopObservableCounterMetric extends NoopObservableMetric{}t.NoopObservableCounterMetric=NoopObservableCounterMetric;class NoopObservableGaugeMetric extends NoopObservableMetric{}t.NoopObservableGaugeMetric=NoopObservableGaugeMetric;class NoopObservableUpDownCounterMetric extends NoopObservableMetric{}t.NoopObservableUpDownCounterMetric=NoopObservableUpDownCounterMetric;t.NOOP_METER=new NoopMeter;t.NOOP_COUNTER_METRIC=new NoopCounterMetric;t.NOOP_HISTOGRAM_METRIC=new NoopHistogramMetric;t.NOOP_UP_DOWN_COUNTER_METRIC=new NoopUpDownCounterMetric;t.NOOP_OBSERVABLE_COUNTER_METRIC=new NoopObservableCounterMetric;t.NOOP_OBSERVABLE_GAUGE_METRIC=new NoopObservableGaugeMetric;t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC=new NoopObservableUpDownCounterMetric;function createNoopMeter(){return t.NOOP_METER}t.createNoopMeter=createNoopMeter},2647:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NOOP_METER_PROVIDER=t.NoopMeterProvider=void 0;const r=a(4837);class NoopMeterProvider{getMeter(e,t,a){return r.NOOP_METER}}t.NoopMeterProvider=NoopMeterProvider;t.NOOP_METER_PROVIDER=new NoopMeterProvider},9957:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__exportStar||function(e,t){for(var a in e)if(a!=="default"&&!Object.prototype.hasOwnProperty.call(t,a))r(t,e,a)};Object.defineProperty(t,"__esModule",{value:true});i(a(7200),t)},9406:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t._globalThis=void 0;t._globalThis=typeof globalThis==="object"?globalThis:global},7200:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__exportStar||function(e,t){for(var a in e)if(a!=="default"&&!Object.prototype.hasOwnProperty.call(t,a))r(t,e,a)};Object.defineProperty(t,"__esModule",{value:true});i(a(9406),t)},7591:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.propagation=void 0;const r=a(9909);t.propagation=r.PropagationAPI.getInstance()},2368:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTextMapPropagator=void 0;class NoopTextMapPropagator{inject(e,t){}extract(e,t){return e}fields(){return[]}}t.NoopTextMapPropagator=NoopTextMapPropagator},865:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.defaultTextMapSetter=t.defaultTextMapGetter=void 0;t.defaultTextMapGetter={get(e,t){if(e==null){return undefined}return e[t]},keys(e){if(e==null){return[]}return Object.keys(e)}};t.defaultTextMapSetter={set(e,t,a){if(e==null){return}e[t]=a}}},8989:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.trace=void 0;const r=a(1539);t.trace=r.TraceAPI.getInstance()},1462:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NonRecordingSpan=void 0;const r=a(1760);class NonRecordingSpan{constructor(e=r.INVALID_SPAN_CONTEXT){this._spanContext=e}spanContext(){return this._spanContext}setAttribute(e,t){return this}setAttributes(e){return this}addEvent(e,t){return this}setStatus(e){return this}updateName(e){return this}end(e){}isRecording(){return false}recordException(e,t,a){}}t.NonRecordingSpan=NonRecordingSpan},7606:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTracer=void 0;const r=a(7171);const i=a(3326);const n=a(1462);const s=a(9745);const o=r.ContextAPI.getInstance();class NoopTracer{startSpan(e,t,a=o.active()){const r=Boolean(t===null||t===void 0?void 0:t.root);if(r){return new n.NonRecordingSpan}const p=a&&(0,i.getSpanContext)(a);if(isSpanContext(p)&&(0,s.isSpanContextValid)(p)){return new n.NonRecordingSpan(p)}else{return new n.NonRecordingSpan}}startActiveSpan(e,t,a,r){let n;let s;let p;if(arguments.length<2){return}else if(arguments.length===2){p=t}else if(arguments.length===3){n=t;p=a}else{n=t;s=a;p=r}const l=s!==null&&s!==void 0?s:o.active();const d=this.startSpan(e,n,l);const c=(0,i.setSpan)(l,d);return o.with(c,p,undefined,d)}}t.NoopTracer=NoopTracer;function isSpanContext(e){return typeof e==="object"&&typeof e["spanId"]==="string"&&typeof e["traceId"]==="string"&&typeof e["traceFlags"]==="number"}},3259:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTracerProvider=void 0;const r=a(7606);class NoopTracerProvider{getTracer(e,t,a){return new r.NoopTracer}}t.NoopTracerProvider=NoopTracerProvider},3503:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ProxyTracer=void 0;const r=a(7606);const i=new r.NoopTracer;class ProxyTracer{constructor(e,t,a,r){this._provider=e;this.name=t;this.version=a;this.options=r}startSpan(e,t,a){return this._getTracer().startSpan(e,t,a)}startActiveSpan(e,t,a,r){const i=this._getTracer();return Reflect.apply(i.startActiveSpan,i,arguments)}_getTracer(){if(this._delegate){return this._delegate}const e=this._provider.getDelegateTracer(this.name,this.version,this.options);if(!e){return i}this._delegate=e;return this._delegate}}t.ProxyTracer=ProxyTracer},2285:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ProxyTracerProvider=void 0;const r=a(3503);const i=a(3259);const n=new i.NoopTracerProvider;class ProxyTracerProvider{getTracer(e,t,a){var i;return(i=this.getDelegateTracer(e,t,a))!==null&&i!==void 0?i:new r.ProxyTracer(this,e,t,a)}getDelegate(){var e;return(e=this._delegate)!==null&&e!==void 0?e:n}setDelegate(e){this._delegate=e}getDelegateTracer(e,t,a){var r;return(r=this._delegate)===null||r===void 0?void 0:r.getTracer(e,t,a)}}t.ProxyTracerProvider=ProxyTracerProvider},3209:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SamplingDecision=void 0;var a;(function(e){e[e["NOT_RECORD"]=0]="NOT_RECORD";e[e["RECORD"]=1]="RECORD";e[e["RECORD_AND_SAMPLED"]=2]="RECORD_AND_SAMPLED"})(a=t.SamplingDecision||(t.SamplingDecision={}))},3326:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getSpanContext=t.setSpanContext=t.deleteSpan=t.setSpan=t.getActiveSpan=t.getSpan=void 0;const r=a(8242);const i=a(1462);const n=a(7171);const s=(0,r.createContextKey)("OpenTelemetry Context Key SPAN");function getSpan(e){return e.getValue(s)||undefined}t.getSpan=getSpan;function getActiveSpan(){return getSpan(n.ContextAPI.getInstance().active())}t.getActiveSpan=getActiveSpan;function setSpan(e,t){return e.setValue(s,t)}t.setSpan=setSpan;function deleteSpan(e){return e.deleteValue(s)}t.deleteSpan=deleteSpan;function setSpanContext(e,t){return setSpan(e,new i.NonRecordingSpan(t))}t.setSpanContext=setSpanContext;function getSpanContext(e){var t;return(t=getSpan(e))===null||t===void 0?void 0:t.spanContext()}t.getSpanContext=getSpanContext},2110:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceStateImpl=void 0;const r=a(4864);const i=32;const n=512;const s=",";const o="=";class TraceStateImpl{constructor(e){this._internalState=new Map;if(e)this._parse(e)}set(e,t){const a=this._clone();if(a._internalState.has(e)){a._internalState.delete(e)}a._internalState.set(e,t);return a}unset(e){const t=this._clone();t._internalState.delete(e);return t}get(e){return this._internalState.get(e)}serialize(){return this._keys().reduce(((e,t)=>{e.push(t+o+this.get(t));return e}),[]).join(s)}_parse(e){if(e.length>n)return;this._internalState=e.split(s).reverse().reduce(((e,t)=>{const a=t.trim();const i=a.indexOf(o);if(i!==-1){const n=a.slice(0,i);const s=a.slice(i+1,t.length);if((0,r.validateKey)(n)&&(0,r.validateValue)(s)){e.set(n,s)}else{}}return e}),new Map);if(this._internalState.size>i){this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,i))}}_keys(){return Array.from(this._internalState.keys()).reverse()}_clone(){const e=new TraceStateImpl;e._internalState=new Map(this._internalState);return e}}t.TraceStateImpl=TraceStateImpl},4864:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.validateValue=t.validateKey=void 0;const a="[_0-9a-z-*/]";const r=`[a-z]${a}{0,255}`;const i=`[a-z0-9]${a}{0,240}@[a-z]${a}{0,13}`;const n=new RegExp(`^(?:${r}|${i})$`);const s=/^[ -~]{0,255}[!-~]$/;const o=/,|=/;function validateKey(e){return n.test(e)}t.validateKey=validateKey;function validateValue(e){return s.test(e)&&!o.test(e)}t.validateValue=validateValue},2615:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createTraceState=void 0;const r=a(2110);function createTraceState(e){return new r.TraceStateImpl(e)}t.createTraceState=createTraceState},1760:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.INVALID_SPAN_CONTEXT=t.INVALID_TRACEID=t.INVALID_SPANID=void 0;const r=a(6905);t.INVALID_SPANID="0000000000000000";t.INVALID_TRACEID="00000000000000000000000000000000";t.INVALID_SPAN_CONTEXT={traceId:t.INVALID_TRACEID,spanId:t.INVALID_SPANID,traceFlags:r.TraceFlags.NONE}},1424:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SpanKind=void 0;var a;(function(e){e[e["INTERNAL"]=0]="INTERNAL";e[e["SERVER"]=1]="SERVER";e[e["CLIENT"]=2]="CLIENT";e[e["PRODUCER"]=3]="PRODUCER";e[e["CONSUMER"]=4]="CONSUMER"})(a=t.SpanKind||(t.SpanKind={}))},9745:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.wrapSpanContext=t.isSpanContextValid=t.isValidSpanId=t.isValidTraceId=void 0;const r=a(1760);const i=a(1462);const n=/^([0-9a-f]{32})$/i;const s=/^[0-9a-f]{16}$/i;function isValidTraceId(e){return n.test(e)&&e!==r.INVALID_TRACEID}t.isValidTraceId=isValidTraceId;function isValidSpanId(e){return s.test(e)&&e!==r.INVALID_SPANID}t.isValidSpanId=isValidSpanId;function isSpanContextValid(e){return isValidTraceId(e.traceId)&&isValidSpanId(e.spanId)}t.isSpanContextValid=isSpanContextValid;function wrapSpanContext(e){return new i.NonRecordingSpan(e)}t.wrapSpanContext=wrapSpanContext},8845:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SpanStatusCode=void 0;var a;(function(e){e[e["UNSET"]=0]="UNSET";e[e["OK"]=1]="OK";e[e["ERROR"]=2]="ERROR"})(a=t.SpanStatusCode||(t.SpanStatusCode={}))},6905:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceFlags=void 0;var a;(function(e){e[e["NONE"]=0]="NONE";e[e["SAMPLED"]=1]="SAMPLED"})(a=t.TraceFlags||(t.TraceFlags={}))},8996:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.VERSION=void 0;t.VERSION="1.5.0"},4812:(e,t,a)=>{e.exports={parallel:a(8210),serial:a(445),serialOrdered:a(3578)}},1700:e=>{e.exports=abort;function abort(e){Object.keys(e.jobs).forEach(clean.bind(e));e.jobs={}}function clean(e){if(typeof this.jobs[e]=="function"){this.jobs[e]()}}},2794:(e,t,a)=>{var r=a(5295);e.exports=async;function async(e){var t=false;r((function(){t=true}));return function async_callback(a,i){if(t){e(a,i)}else{r((function nextTick_callback(){e(a,i)}))}}}},5295:e=>{e.exports=defer;function defer(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;if(t){t(e)}else{setTimeout(e,0)}}},9023:(e,t,a)=>{var r=a(2794),i=a(1700);e.exports=iterate;function iterate(e,t,a,r){var n=a["keyedList"]?a["keyedList"][a.index]:a.index;a.jobs[n]=runJob(t,n,e[n],(function(e,t){if(!(n in a.jobs)){return}delete a.jobs[n];if(e){i(a)}else{a.results[n]=t}r(e,a.results)}))}function runJob(e,t,a,i){var n;if(e.length==2){n=e(a,r(i))}else{n=e(a,t,r(i))}return n}},2474:e=>{e.exports=state;function state(e,t){var a=!Array.isArray(e),r={index:0,keyedList:a||t?Object.keys(e):null,jobs:{},results:a?{}:[],size:a?Object.keys(e).length:e.length};if(t){r.keyedList.sort(a?t:function(a,r){return t(e[a],e[r])})}return r}},7942:(e,t,a)=>{var r=a(1700),i=a(2794);e.exports=terminator;function terminator(e){if(!Object.keys(this.jobs).length){return}this.index=this.size;r(this);i(e)(null,this.results)}},8210:(e,t,a)=>{var r=a(9023),i=a(2474),n=a(7942);e.exports=parallel;function parallel(e,t,a){var s=i(e);while(s.index<(s["keyedList"]||e).length){r(e,t,s,(function(e,t){if(e){a(e,t);return}if(Object.keys(s.jobs).length===0){a(null,s.results);return}}));s.index++}return n.bind(s,a)}},445:(e,t,a)=>{var r=a(3578);e.exports=serial;function serial(e,t,a){return r(e,t,null,a)}},3578:(e,t,a)=>{var r=a(9023),i=a(2474),n=a(7942);e.exports=serialOrdered;e.exports.ascending=ascending;e.exports.descending=descending;function serialOrdered(e,t,a,s){var o=i(e,a);r(e,t,o,(function iteratorHandler(a,i){if(a){s(a,i);return}o.index++;if(o.index<(o["keyedList"]||e).length){r(e,t,o,iteratorHandler);return}s(null,o.results)}));return n.bind(o,s)}function ascending(e,t){return et?1:0}function descending(e,t){return-1*ascending(e,t)}},9417:e=>{"use strict";e.exports=balanced;function balanced(e,t,a){if(e instanceof RegExp)e=maybeMatch(e,a);if(t instanceof RegExp)t=maybeMatch(t,a);var r=range(e,t,a);return r&&{start:r[0],end:r[1],pre:a.slice(0,r[0]),body:a.slice(r[0]+e.length,r[1]),post:a.slice(r[1]+t.length)}}function maybeMatch(e,t){var a=t.match(e);return a?a[0]:null}balanced.range=range;function range(e,t,a){var r,i,n,s,o;var p=a.indexOf(e);var l=a.indexOf(t,p+1);var d=p;if(p>=0&&l>0){if(e===t){return[p,l]}r=[];n=a.length;while(d>=0&&!o){if(d==p){r.push(d);p=a.indexOf(e,d+1)}else if(r.length==1){o=[r.pop(),l]}else{i=r.pop();if(i=0?p:l}if(r.length){o=[n,s]}}return o}},3682:(e,t,a)=>{var r=a(4670);var i=a(5549);var n=a(6819);var s=Function.bind;var o=s.bind(s);function bindApi(e,t,a){var r=o(n,null).apply(null,a?[t,a]:[t]);e.api={remove:r};e.remove=r;["before","error","after","wrap"].forEach((function(r){var n=a?[t,r,a]:[t,r];e[r]=e.api[r]=o(i,null).apply(null,n)}))}function HookSingular(){var e="h";var t={registry:{}};var a=r.bind(null,t,e);bindApi(a,t,e);return a}function HookCollection(){var e={registry:{}};var t=r.bind(null,e);bindApi(t,e);return t}var p=false;function Hook(){if(!p){console.warn('[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4');p=true}return HookCollection()}Hook.Singular=HookSingular.bind();Hook.Collection=HookCollection.bind();e.exports=Hook;e.exports.Hook=Hook;e.exports.Singular=Hook.Singular;e.exports.Collection=Hook.Collection},5549:e=>{e.exports=addHook;function addHook(e,t,a,r){var i=r;if(!e.registry[a]){e.registry[a]=[]}if(t==="before"){r=function(e,t){return Promise.resolve().then(i.bind(null,t)).then(e.bind(null,t))}}if(t==="after"){r=function(e,t){var a;return Promise.resolve().then(e.bind(null,t)).then((function(e){a=e;return i(a,t)})).then((function(){return a}))}}if(t==="error"){r=function(e,t){return Promise.resolve().then(e.bind(null,t)).catch((function(e){return i(e,t)}))}}e.registry[a].push({hook:r,orig:i})}},4670:e=>{e.exports=register;function register(e,t,a,r){if(typeof a!=="function"){throw new Error("method for before hook must be a function")}if(!r){r={}}if(Array.isArray(t)){return t.reverse().reduce((function(t,a){return register.bind(null,e,a,t,r)}),a)()}return Promise.resolve().then((function(){if(!e.registry[t]){return a(r)}return e.registry[t].reduce((function(e,t){return t.hook.bind(null,e,r)}),a)()}))}},6819:e=>{e.exports=removeHook;function removeHook(e,t,a){if(!e.registry[t]){return}var r=e.registry[t].map((function(e){return e.orig})).indexOf(a);if(r===-1){return}e.registry[t].splice(r,1)}},3717:(e,t,a)=>{var r=a(6891);var i=a(9417);e.exports=expandTop;var n="\0SLASH"+Math.random()+"\0";var s="\0OPEN"+Math.random()+"\0";var o="\0CLOSE"+Math.random()+"\0";var p="\0COMMA"+Math.random()+"\0";var l="\0PERIOD"+Math.random()+"\0";function numeric(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function escapeBraces(e){return e.split("\\\\").join(n).split("\\{").join(s).split("\\}").join(o).split("\\,").join(p).split("\\.").join(l)}function unescapeBraces(e){return e.split(n).join("\\").split(s).join("{").split(o).join("}").split(p).join(",").split(l).join(".")}function parseCommaParts(e){if(!e)return[""];var t=[];var a=i("{","}",e);if(!a)return e.split(",");var r=a.pre;var n=a.body;var s=a.post;var o=r.split(",");o[o.length-1]+="{"+n+"}";var p=parseCommaParts(s);if(s.length){o[o.length-1]+=p.shift();o.push.apply(o,p)}t.push.apply(t,o);return t}function expandTop(e){if(!e)return[];if(e.substr(0,2)==="{}"){e="\\{\\}"+e.substr(2)}return expand(escapeBraces(e),true).map(unescapeBraces)}function identity(e){return e}function embrace(e){return"{"+e+"}"}function isPadded(e){return/^-?0\d/.test(e)}function lte(e,t){return e<=t}function gte(e,t){return e>=t}function expand(e,t){var a=[];var n=i("{","}",e);if(!n||/\$$/.test(n.pre))return[e];var s=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(n.body);var p=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(n.body);var l=s||p;var d=n.body.indexOf(",")>=0;if(!l&&!d){if(n.post.match(/,.*\}/)){e=n.pre+"{"+n.body+o+n.post;return expand(e)}return[e]}var c;if(l){c=n.body.split(/\.\./)}else{c=parseCommaParts(n.body);if(c.length===1){c=expand(c[0],false).map(embrace);if(c.length===1){var m=n.post.length?expand(n.post,false):[""];return m.map((function(e){return n.pre+c[0]+e}))}}}var u=n.pre;var m=n.post.length?expand(n.post,false):[""];var h;if(l){var g=numeric(c[0]);var y=numeric(c[1]);var v=Math.max(c[0].length,c[1].length);var b=c.length==3?Math.abs(numeric(c[2])):1;var x=lte;var w=y0){var _=new Array(E+1).join("0");if(N<0)T="-"+_+T.slice(1);else T=_+T}}}h.push(T)}}else{h=r(c,(function(e){return expand(e,false)}))}for(var P=0;P{var r=a(3837);var i=a(2781).Stream;var n=a(8611);e.exports=CombinedStream;function CombinedStream(){this.writable=false;this.readable=true;this.dataSize=0;this.maxDataSize=2*1024*1024;this.pauseStreams=true;this._released=false;this._streams=[];this._currentStream=null;this._insideLoop=false;this._pendingNext=false}r.inherits(CombinedStream,i);CombinedStream.create=function(e){var t=new this;e=e||{};for(var a in e){t[a]=e[a]}return t};CombinedStream.isStreamLike=function(e){return typeof e!=="function"&&typeof e!=="string"&&typeof e!=="boolean"&&typeof e!=="number"&&!Buffer.isBuffer(e)};CombinedStream.prototype.append=function(e){var t=CombinedStream.isStreamLike(e);if(t){if(!(e instanceof n)){var a=n.create(e,{maxDataSize:Infinity,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this));e=a}this._handleErrors(e);if(this.pauseStreams){e.pause()}}this._streams.push(e);return this};CombinedStream.prototype.pipe=function(e,t){i.prototype.pipe.call(this,e,t);this.resume();return e};CombinedStream.prototype._getNext=function(){this._currentStream=null;if(this._insideLoop){this._pendingNext=true;return}this._insideLoop=true;try{do{this._pendingNext=false;this._realGetNext()}while(this._pendingNext)}finally{this._insideLoop=false}};CombinedStream.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e=="undefined"){this.end();return}if(typeof e!=="function"){this._pipeNext(e);return}var t=e;t(function(e){var t=CombinedStream.isStreamLike(e);if(t){e.on("data",this._checkDataSize.bind(this));this._handleErrors(e)}this._pipeNext(e)}.bind(this))};CombinedStream.prototype._pipeNext=function(e){this._currentStream=e;var t=CombinedStream.isStreamLike(e);if(t){e.on("end",this._getNext.bind(this));e.pipe(this,{end:false});return}var a=e;this.write(a);this._getNext()};CombinedStream.prototype._handleErrors=function(e){var t=this;e.on("error",(function(e){t._emitError(e)}))};CombinedStream.prototype.write=function(e){this.emit("data",e)};CombinedStream.prototype.pause=function(){if(!this.pauseStreams){return}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function")this._currentStream.pause();this.emit("pause")};CombinedStream.prototype.resume=function(){if(!this._released){this._released=true;this.writable=true;this._getNext()}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function")this._currentStream.resume();this.emit("resume")};CombinedStream.prototype.end=function(){this._reset();this.emit("end")};CombinedStream.prototype.destroy=function(){this._reset();this.emit("close")};CombinedStream.prototype._reset=function(){this.writable=false;this._streams=[];this._currentStream=null};CombinedStream.prototype._checkDataSize=function(){this._updateDataSize();if(this.dataSize<=this.maxDataSize){return}var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))};CombinedStream.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach((function(t){if(!t.dataSize){return}e.dataSize+=t.dataSize}));if(this._currentStream&&this._currentStream.dataSize){this.dataSize+=this._currentStream.dataSize}};CombinedStream.prototype._emitError=function(e){this._reset();this.emit("error",e)}},6891:e=>{e.exports=function(e,a){var r=[];for(var i=0;i{var r=a(2781).Stream;var i=a(3837);e.exports=DelayedStream;function DelayedStream(){this.source=null;this.dataSize=0;this.maxDataSize=1024*1024;this.pauseStream=true;this._maxDataSizeExceeded=false;this._released=false;this._bufferedEvents=[]}i.inherits(DelayedStream,r);DelayedStream.create=function(e,t){var a=new this;t=t||{};for(var r in t){a[r]=t[r]}a.source=e;var i=e.emit;e.emit=function(){a._handleEmit(arguments);return i.apply(e,arguments)};e.on("error",(function(){}));if(a.pauseStream){e.pause()}return a};Object.defineProperty(DelayedStream.prototype,"readable",{configurable:true,enumerable:true,get:function(){return this.source.readable}});DelayedStream.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};DelayedStream.prototype.resume=function(){if(!this._released){this.release()}this.source.resume()};DelayedStream.prototype.pause=function(){this.source.pause()};DelayedStream.prototype.release=function(){this._released=true;this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this));this._bufferedEvents=[]};DelayedStream.prototype.pipe=function(){var e=r.prototype.pipe.apply(this,arguments);this.resume();return e};DelayedStream.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}if(e[0]==="data"){this.dataSize+=e[1].length;this._checkIfMaxDataSizeExceeded()}this._bufferedEvents.push(e)};DelayedStream.prototype._checkIfMaxDataSizeExceeded=function(){if(this._maxDataSizeExceeded){return}if(this.dataSize<=this.maxDataSize){return}this._maxDataSizeExceeded=true;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}},8932:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});class Deprecation extends Error{constructor(e){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="Deprecation"}}t.Deprecation=Deprecation},3287:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true}); +(()=>{var __webpack_modules__={3782:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.deduplicate=t.pleaseRestore=t.pleaseSave=void 0;const o=a(7799);const p=n(a(2186));const l=n(a(5438));const d="sccache";const pleaseSave=()=>s(void 0,void 0,void 0,(function*(){const e=process.env.SCCACHE_CACHE_DIR;console.log(e);if(!e){console.log(`no sccache dir found in SCCACHE_CACHE_DIR ${e}`);return}yield(0,o.saveCache)([e],d)}));t.pleaseSave=pleaseSave;const pleaseRestore=()=>s(void 0,void 0,void 0,(function*(){console.log("restore sccache files");const e=process.env.SCCACHE_CACHE_DIR;console.log(e);if(!e){console.log(`no sccache dir found in SCCACHE_CACHE_DIR ${e}`);return}yield(0,o.restoreCache)([e],d).then((t=>{if(!t){console.log(`no cache matching "${e}" to restore`)}}))}));t.pleaseRestore=pleaseRestore;const deduplicate=()=>s(void 0,void 0,void 0,(function*(){console.log("trying to deduplicate cache");const e=p.getInput("token",{required:true});const t=l.getOctokit(e);const a=yield t.rest.actions.deleteActionsCacheByKey({owner:l.context.repo.owner,repo:l.context.repo.repo,key:d}).then((()=>"successfully deleted cache")).catch((e=>{console.log(`catch: ${e}`);return"nothing to delete"}));console.log(`delete cache api response: ${a}`)}));t.deduplicate=deduplicate},7391:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});const o=n(a(2186));const p=a(7784);const l=a(5438);const d=n(a(7147));const c=n(a(6113));const m=a(3782);const u=a(1514);function setup(){return s(this,void 0,void 0,(function*(){let e=o.getInput("version");if(e.length===0){const t=o.getInput("token",{required:true});const a=(0,l.getOctokit)(t);const r=yield a.rest.repos.getLatestRelease({owner:"mozilla",repo:"sccache"});e=r.data.tag_name}o.info(`try to setup sccache version: ${e}`);const t=getFilename(e);const a=getDirname(e);const r=`https://github.com/mozilla/sccache/releases/download/${e}/${t}`;const i=`${r}.sha256`;o.info(`sccache download from url: ${r}`);const n=yield(0,p.downloadTool)(r);const s=yield(0,p.downloadTool)(i);const h=yield d.promises.readFile(n);const g=c.createHash("sha256");g.update(h);const y=g.digest("hex");const v=(yield d.promises.readFile(s)).toString().trim();if(y!==v){o.setFailed("Checksum verification failed");return}o.info(`Correct checksum: ${y}`);let b;if(getExtension()=="zip"){b=yield(0,p.extractZip)(n)}else{b=yield(0,p.extractTar)(n)}o.info(`sccache extracted to: ${b}`);const x=yield(0,p.cacheDir)(`${b}/${a}`,"sccache",e);o.info(`sccache cached to: ${x}`);o.addPath(`${x}`);o.exportVariable("SCCACHE_PATH",`${x}/sccache`);o.exportVariable("ACTIONS_CACHE_URL",process.env.ACTIONS_CACHE_URL||"");o.exportVariable("ACTIONS_RUNTIME_TOKEN",process.env.ACTIONS_RUNTIME_TOKEN||"");const w=o.getInput("local",{required:false});if(w=="true"){let e="";let t="";const a={};a.listeners={stdout:t=>{e+=t.toString()},stderr:e=>{t+=e.toString()}};yield(0,u.exec)(`${x}/sccache`,["--show-stats","--stats-format","json"],a).catch((e=>{console.log(`exec error: ${e}`);console.log(t)}));const r=JSON.parse(e);console.log(`\n${r.cache_location}`);let i=r.cache_location.split(":")[1].trim().slice(1,-1);o.exportVariable("SCCACHE_CACHE_DIR",i);yield(0,m.pleaseRestore)();o.exportVariable("RUSTC_WRAPPER",`sccache`)}}))}function getFilename(e){return`sccache-${e}-${getArch()}-${getPlatform()}.${getExtension()}`}function getDirname(e){return`sccache-${e}-${getArch()}-${getPlatform()}`}function getArch(){switch(process.arch){case"x64":return"x86_64";case"arm64":return"aarch64";default:return Error('Unsupported arch "${process.arch}"')}}function getPlatform(){switch(process.platform){case"darwin":return"apple-darwin";case"win32":return"pc-windows-msvc";case"linux":return"unknown-linux-musl";default:return Error('Unsupported platform "${process.platform}"')}}function getExtension(){switch(process.platform){case"win32":return"zip";default:return"tar.gz"}}setup().catch((e=>{o.error(e);o.setFailed(e.message)}))},7799:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.saveCache=t.restoreCache=t.isFeatureAvailable=t.ReserveCacheError=t.ValidationError=void 0;const o=n(a(2186));const p=n(a(1017));const l=n(a(1518));const d=n(a(8245));const c=a(6490);class ValidationError extends Error{constructor(e){super(e);this.name="ValidationError";Object.setPrototypeOf(this,ValidationError.prototype)}}t.ValidationError=ValidationError;class ReserveCacheError extends Error{constructor(e){super(e);this.name="ReserveCacheError";Object.setPrototypeOf(this,ReserveCacheError.prototype)}}t.ReserveCacheError=ReserveCacheError;function checkPaths(e){if(!e||e.length===0){throw new ValidationError(`Path Validation Error: At least one directory or file path is required`)}}function checkKey(e){if(e.length>512){throw new ValidationError(`Key Validation Error: ${e} cannot be larger than 512 characters.`)}const t=/^[^,]*$/;if(!t.test(e)){throw new ValidationError(`Key Validation Error: ${e} cannot contain commas.`)}}function isFeatureAvailable(){return!!process.env["ACTIONS_CACHE_URL"]}t.isFeatureAvailable=isFeatureAvailable;function restoreCache(e,t,a,r,i=false){return s(this,void 0,void 0,(function*(){checkPaths(e);a=a||[];const n=[t,...a];o.debug("Resolved Keys:");o.debug(JSON.stringify(n));if(n.length>10){throw new ValidationError(`Key Validation Error: Keys are limited to a maximum of 10.`)}for(const e of n){checkKey(e)}const s=yield l.getCompressionMethod();let m="";try{const t=yield d.getCacheEntry(n,e,{compressionMethod:s,enableCrossOsArchive:i});if(!(t===null||t===void 0?void 0:t.archiveLocation)){return undefined}if(r===null||r===void 0?void 0:r.lookupOnly){o.info("Lookup only - skipping download");return t.cacheKey}m=p.join(yield l.createTempDirectory(),l.getCacheFileName(s));o.debug(`Archive Path: ${m}`);yield d.downloadCache(t.archiveLocation,m,r);if(o.isDebug()){yield(0,c.listTar)(m,s)}const a=l.getArchiveFileSizeInBytes(m);o.info(`Cache Size: ~${Math.round(a/(1024*1024))} MB (${a} B)`);yield(0,c.extractTar)(m,s);o.info("Cache restored successfully");return t.cacheKey}catch(e){const t=e;if(t.name===ValidationError.name){throw e}else{o.warning(`Failed to restore: ${e.message}`)}}finally{try{yield l.unlinkFile(m)}catch(e){o.debug(`Failed to delete archive: ${e}`)}}return undefined}))}t.restoreCache=restoreCache;function saveCache(e,t,a,r=false){var i,n,m,u,h;return s(this,void 0,void 0,(function*(){checkPaths(e);checkKey(t);const s=yield l.getCompressionMethod();let g=-1;const y=yield l.resolvePaths(e);o.debug("Cache Paths:");o.debug(`${JSON.stringify(y)}`);if(y.length===0){throw new Error(`Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved.`)}const v=yield l.createTempDirectory();const b=p.join(v,l.getCacheFileName(s));o.debug(`Archive Path: ${b}`);try{yield(0,c.createTar)(v,y,s);if(o.isDebug()){yield(0,c.listTar)(b,s)}const p=10*1024*1024*1024;const x=l.getArchiveFileSizeInBytes(b);o.debug(`File Size: ${x}`);if(x>p&&!l.isGhes()){throw new Error(`Cache size of ~${Math.round(x/(1024*1024))} MB (${x} B) is over the 10GB limit, not saving cache.`)}o.debug("Reserving Cache");const w=yield d.reserveCache(t,e,{compressionMethod:s,enableCrossOsArchive:r,cacheSize:x});if((i=w===null||w===void 0?void 0:w.result)===null||i===void 0?void 0:i.cacheId){g=(n=w===null||w===void 0?void 0:w.result)===null||n===void 0?void 0:n.cacheId}else if((w===null||w===void 0?void 0:w.statusCode)===400){throw new Error((u=(m=w===null||w===void 0?void 0:w.error)===null||m===void 0?void 0:m.message)!==null&&u!==void 0?u:`Cache size of ~${Math.round(x/(1024*1024))} MB (${x} B) is over the data cap limit, not saving cache.`)}else{throw new ReserveCacheError(`Unable to reserve cache with key ${t}, another job may be creating this cache. More details: ${(h=w===null||w===void 0?void 0:w.error)===null||h===void 0?void 0:h.message}`)}o.debug(`Saving Cache (ID: ${g})`);yield d.saveCache(g,b,a)}catch(e){const t=e;if(t.name===ValidationError.name){throw e}else if(t.name===ReserveCacheError.name){o.info(`Failed to save: ${t.message}`)}else{o.warning(`Failed to save: ${t.message}`)}}finally{try{yield l.unlinkFile(b)}catch(e){o.debug(`Failed to delete archive: ${e}`)}}return g}))}t.saveCache=saveCache},8245:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.saveCache=t.reserveCache=t.downloadCache=t.getCacheEntry=t.getCacheVersion=void 0;const o=n(a(2186));const p=a(6255);const l=a(5526);const d=n(a(6113));const c=n(a(7147));const m=a(7310);const u=n(a(1518));const h=a(5500);const g=a(6215);const y=a(3981);const v="1.0";function getCacheApiUrl(e){const t=process.env["ACTIONS_CACHE_URL"]||"";if(!t){throw new Error("Cache Service Url not found, unable to restore cache.")}const a=`${t}_apis/artifactcache/${e}`;o.debug(`Resource Url: ${a}`);return a}function createAcceptHeader(e,t){return`${e};api-version=${t}`}function getRequestOptions(){const e={headers:{Accept:createAcceptHeader("application/json","6.0-preview.1")}};return e}function createHttpClient(){const e=process.env["ACTIONS_RUNTIME_TOKEN"]||"";const t=new l.BearerCredentialHandler(e);return new p.HttpClient("actions/cache",[t],getRequestOptions())}function getCacheVersion(e,t,a=false){const r=e;if(t){r.push(t)}if(process.platform==="win32"&&!a){r.push("windows-only")}r.push(v);return d.createHash("sha256").update(r.join("|")).digest("hex")}t.getCacheVersion=getCacheVersion;function getCacheEntry(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();const i=getCacheVersion(t,a===null||a===void 0?void 0:a.compressionMethod,a===null||a===void 0?void 0:a.enableCrossOsArchive);const n=`cache?keys=${encodeURIComponent(e.join(","))}&version=${i}`;const p=yield(0,y.retryTypedResponse)("getCacheEntry",(()=>s(this,void 0,void 0,(function*(){return r.getJson(getCacheApiUrl(n))}))));if(p.statusCode===204){if(o.isDebug()){yield printCachesListForDiagnostics(e[0],r,i)}return null}if(!(0,y.isSuccessStatusCode)(p.statusCode)){throw new Error(`Cache service responded with ${p.statusCode}`)}const l=p.result;const d=l===null||l===void 0?void 0:l.archiveLocation;if(!d){throw new Error("Cache not found.")}o.setSecret(d);o.debug(`Cache Result:`);o.debug(JSON.stringify(l));return l}))}t.getCacheEntry=getCacheEntry;function printCachesListForDiagnostics(e,t,a){return s(this,void 0,void 0,(function*(){const r=`caches?key=${encodeURIComponent(e)}`;const i=yield(0,y.retryTypedResponse)("listCache",(()=>s(this,void 0,void 0,(function*(){return t.getJson(getCacheApiUrl(r))}))));if(i.statusCode===200){const t=i.result;const r=t===null||t===void 0?void 0:t.totalCount;if(r&&r>0){o.debug(`No matching cache found for cache key '${e}', version '${a} and scope ${process.env["GITHUB_REF"]}. There exist one or more cache(s) with similar key but they have different version or scope. See more info on cache matching here: https://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows#matching-a-cache-key \nOther caches with similar key:`);for(const e of(t===null||t===void 0?void 0:t.artifactCaches)||[]){o.debug(`Cache Key: ${e===null||e===void 0?void 0:e.cacheKey}, Cache Version: ${e===null||e===void 0?void 0:e.cacheVersion}, Cache Scope: ${e===null||e===void 0?void 0:e.scope}, Cache Created: ${e===null||e===void 0?void 0:e.creationTime}`)}}}}))}function downloadCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=new m.URL(e);const i=(0,g.getDownloadOptions)(a);if(r.hostname.endsWith(".blob.core.windows.net")){if(i.useAzureSdk){yield(0,h.downloadCacheStorageSDK)(e,t,i)}else if(i.concurrentBlobDownloads){yield(0,h.downloadCacheHttpClientConcurrent)(e,t,i)}else{yield(0,h.downloadCacheHttpClient)(e,t)}}else{yield(0,h.downloadCacheHttpClient)(e,t)}}))}t.downloadCache=downloadCache;function reserveCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();const i=getCacheVersion(t,a===null||a===void 0?void 0:a.compressionMethod,a===null||a===void 0?void 0:a.enableCrossOsArchive);const n={key:e,version:i,cacheSize:a===null||a===void 0?void 0:a.cacheSize};const o=yield(0,y.retryTypedResponse)("reserveCache",(()=>s(this,void 0,void 0,(function*(){return r.postJson(getCacheApiUrl("caches"),n)}))));return o}))}t.reserveCache=reserveCache;function getContentRange(e,t){return`bytes ${e}-${t}/*`}function uploadChunk(e,t,a,r,i){return s(this,void 0,void 0,(function*(){o.debug(`Uploading chunk of size ${i-r+1} bytes at offset ${r} with content range: ${getContentRange(r,i)}`);const n={"Content-Type":"application/octet-stream","Content-Range":getContentRange(r,i)};const p=yield(0,y.retryHttpClientResponse)(`uploadChunk (start: ${r}, end: ${i})`,(()=>s(this,void 0,void 0,(function*(){return e.sendStream("PATCH",t,a(),n)}))));if(!(0,y.isSuccessStatusCode)(p.message.statusCode)){throw new Error(`Cache service responded with ${p.message.statusCode} during upload chunk.`)}}))}function uploadFile(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=u.getArchiveFileSizeInBytes(a);const n=getCacheApiUrl(`caches/${t.toString()}`);const p=c.openSync(a,"r");const l=(0,g.getUploadOptions)(r);const d=u.assertDefined("uploadConcurrency",l.uploadConcurrency);const m=u.assertDefined("uploadChunkSize",l.uploadChunkSize);const h=[...new Array(d).keys()];o.debug("Awaiting all uploads");let y=0;try{yield Promise.all(h.map((()=>s(this,void 0,void 0,(function*(){while(yc.createReadStream(a,{fd:p,start:r,end:s,autoClose:false}).on("error",(e=>{throw new Error(`Cache upload failed because file read failed with ${e.message}`)}))),r,s)}})))))}finally{c.closeSync(p)}return}))}function commitCache(e,t,a){return s(this,void 0,void 0,(function*(){const r={size:a};return yield(0,y.retryTypedResponse)("commitCache",(()=>s(this,void 0,void 0,(function*(){return e.postJson(getCacheApiUrl(`caches/${t.toString()}`),r)}))))}))}function saveCache(e,t,a){return s(this,void 0,void 0,(function*(){const r=createHttpClient();o.debug("Upload cache");yield uploadFile(r,e,t,a);o.debug("Commiting cache");const i=u.getArchiveFileSizeInBytes(t);o.info(`Cache Size: ~${Math.round(i/(1024*1024))} MB (${i} B)`);const n=yield commitCache(r,e,i);if(!(0,y.isSuccessStatusCode)(n.statusCode)){throw new Error(`Cache service responded with ${n.statusCode} during commit cache.`)}o.info("Cache saved successfully")}))}t.saveCache=saveCache},1518:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};Object.defineProperty(t,"__esModule",{value:true});t.isGhes=t.assertDefined=t.getGnuTarPathOnWindows=t.getCacheFileName=t.getCompressionMethod=t.unlinkFile=t.resolvePaths=t.getArchiveFileSizeInBytes=t.createTempDirectory=void 0;const p=n(a(2186));const l=n(a(1514));const d=n(a(8090));const c=n(a(7436));const m=n(a(7147));const u=n(a(1017));const h=n(a(5911));const g=n(a(3837));const y=a(4138);const v=a(8840);function createTempDirectory(){return s(this,void 0,void 0,(function*(){const e=process.platform==="win32";let t=process.env["RUNNER_TEMP"]||"";if(!t){let a;if(e){a=process.env["USERPROFILE"]||"C:\\"}else{if(process.platform==="darwin"){a="/Users"}else{a="/home"}}t=u.join(a,"actions","temp")}const a=u.join(t,(0,y.v4)());yield c.mkdirP(a);return a}))}t.createTempDirectory=createTempDirectory;function getArchiveFileSizeInBytes(e){return m.statSync(e).size}t.getArchiveFileSizeInBytes=getArchiveFileSizeInBytes;function resolvePaths(e){var t,a,r,i;var n;return s(this,void 0,void 0,(function*(){const s=[];const l=(n=process.env["GITHUB_WORKSPACE"])!==null&&n!==void 0?n:process.cwd();const c=yield d.create(e.join("\n"),{implicitDescendants:false});try{for(var m=true,h=o(c.globGenerator()),g;g=yield h.next(),t=g.done,!t;){i=g.value;m=false;try{const e=i;const t=u.relative(l,e).replace(new RegExp(`\\${u.sep}`,"g"),"/");p.debug(`Matched: ${t}`);if(t===""){s.push(".")}else{s.push(`${t}`)}}finally{m=true}}}catch(e){a={error:e}}finally{try{if(!m&&!t&&(r=h.return))yield r.call(h)}finally{if(a)throw a.error}}return s}))}t.resolvePaths=resolvePaths;function unlinkFile(e){return s(this,void 0,void 0,(function*(){return g.promisify(m.unlink)(e)}))}t.unlinkFile=unlinkFile;function getVersion(e,t=[]){return s(this,void 0,void 0,(function*(){let a="";t.push("--version");p.debug(`Checking ${e} ${t.join(" ")}`);try{yield l.exec(`${e}`,t,{ignoreReturnCode:true,silent:true,listeners:{stdout:e=>a+=e.toString(),stderr:e=>a+=e.toString()}})}catch(e){p.debug(e.message)}a=a.trim();p.debug(a);return a}))}function getCompressionMethod(){return s(this,void 0,void 0,(function*(){const e=yield getVersion("zstd",["--quiet"]);const t=h.clean(e);p.debug(`zstd version: ${t}`);if(e===""){return v.CompressionMethod.Gzip}else{return v.CompressionMethod.ZstdWithoutLong}}))}t.getCompressionMethod=getCompressionMethod;function getCacheFileName(e){return e===v.CompressionMethod.Gzip?v.CacheFilename.Gzip:v.CacheFilename.Zstd}t.getCacheFileName=getCacheFileName;function getGnuTarPathOnWindows(){return s(this,void 0,void 0,(function*(){if(m.existsSync(v.GnuTarPathOnWindows)){return v.GnuTarPathOnWindows}const e=yield getVersion("tar");return e.toLowerCase().includes("gnu tar")?c.which("tar"):""}))}t.getGnuTarPathOnWindows=getGnuTarPathOnWindows;function assertDefined(e,t){if(t===undefined){throw Error(`Expected ${e} but value was undefiend`)}return t}t.assertDefined=assertDefined;function isGhes(){const e=new URL(process.env["GITHUB_SERVER_URL"]||"https://github.com");return e.hostname.toUpperCase()!=="GITHUB.COM"}t.isGhes=isGhes},8840:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ManifestFilename=t.TarFilename=t.SystemTarPathOnWindows=t.GnuTarPathOnWindows=t.SocketTimeout=t.DefaultRetryDelay=t.DefaultRetryAttempts=t.ArchiveToolType=t.CompressionMethod=t.CacheFilename=void 0;var a;(function(e){e["Gzip"]="cache.tgz";e["Zstd"]="cache.tzst"})(a=t.CacheFilename||(t.CacheFilename={}));var r;(function(e){e["Gzip"]="gzip";e["ZstdWithoutLong"]="zstd-without-long";e["Zstd"]="zstd"})(r=t.CompressionMethod||(t.CompressionMethod={}));var i;(function(e){e["GNU"]="gnu";e["BSD"]="bsd"})(i=t.ArchiveToolType||(t.ArchiveToolType={}));t.DefaultRetryAttempts=2;t.DefaultRetryDelay=5e3;t.SocketTimeout=5e3;t.GnuTarPathOnWindows=`${process.env["PROGRAMFILES"]}\\Git\\usr\\bin\\tar.exe`;t.SystemTarPathOnWindows=`${process.env["SYSTEMDRIVE"]}\\Windows\\System32\\tar.exe`;t.TarFilename="cache.tar";t.ManifestFilename="manifest.txt"},5500:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.downloadCacheStorageSDK=t.downloadCacheHttpClientConcurrent=t.downloadCacheHttpClient=t.DownloadProgress=void 0;const o=n(a(2186));const p=a(6255);const l=a(4100);const d=n(a(4300));const c=n(a(7147));const m=n(a(2781));const u=n(a(3837));const h=n(a(1518));const g=a(8840);const y=a(3981);const v=a(2557);function pipeResponseToStream(e,t){return s(this,void 0,void 0,(function*(){const a=u.promisify(m.pipeline);yield a(e.message,t)}))}class DownloadProgress{constructor(e){this.contentLength=e;this.segmentIndex=0;this.segmentSize=0;this.segmentOffset=0;this.receivedBytes=0;this.displayedComplete=false;this.startTime=Date.now()}nextSegment(e){this.segmentOffset=this.segmentOffset+this.segmentSize;this.segmentIndex=this.segmentIndex+1;this.segmentSize=e;this.receivedBytes=0;o.debug(`Downloading segment at offset ${this.segmentOffset} with length ${this.segmentSize}...`)}setReceivedBytes(e){this.receivedBytes=e}getTransferredBytes(){return this.segmentOffset+this.receivedBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete){return}const e=this.segmentOffset+this.receivedBytes;const t=(100*(e/this.contentLength)).toFixed(1);const a=Date.now()-this.startTime;const r=(e/(1024*1024)/(a/1e3)).toFixed(1);o.info(`Received ${e} of ${this.contentLength} (${t}%), ${r} MBs/sec`);if(this.isDone()){this.displayedComplete=true}}onProgress(){return e=>{this.setReceivedBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){const displayCallback=()=>{this.display();if(!this.isDone()){this.timeoutHandle=setTimeout(displayCallback,e)}};this.timeoutHandle=setTimeout(displayCallback,e)}stopDisplayTimer(){if(this.timeoutHandle){clearTimeout(this.timeoutHandle);this.timeoutHandle=undefined}this.display()}}t.DownloadProgress=DownloadProgress;function downloadCacheHttpClient(e,t){return s(this,void 0,void 0,(function*(){const a=c.createWriteStream(t);const r=new p.HttpClient("actions/cache");const i=yield(0,y.retryHttpClientResponse)("downloadCache",(()=>s(this,void 0,void 0,(function*(){return r.get(e)}))));i.message.socket.setTimeout(g.SocketTimeout,(()=>{i.message.destroy();o.debug(`Aborting download, socket timed out after ${g.SocketTimeout} ms`)}));yield pipeResponseToStream(i,a);const n=i.message.headers["content-length"];if(n){const e=parseInt(n);const a=h.getArchiveFileSizeInBytes(t);if(a!==e){throw new Error(`Incomplete download. Expected file size: ${e}, actual file size: ${a}`)}}else{o.debug("Unable to validate download, no Content-Length header")}}))}t.downloadCacheHttpClient=downloadCacheHttpClient;function downloadCacheHttpClientConcurrent(e,t,a){var r;return s(this,void 0,void 0,(function*(){const i=yield c.promises.open(t,"w");const n=new p.HttpClient("actions/cache",undefined,{socketTimeout:a.timeoutInMs,keepAlive:true});try{const t=yield(0,y.retryHttpClientResponse)("downloadCacheMetadata",(()=>s(this,void 0,void 0,(function*(){return yield n.request("HEAD",e,null,{})}))));const o=t.message.headers["content-length"];if(o===undefined||o===null){throw new Error("Content-Length not found on blob response")}const p=parseInt(o);if(Number.isNaN(p)){throw new Error(`Could not interpret Content-Length: ${p}`)}const l=[];const d=4*1024*1024;for(let t=0;ts(this,void 0,void 0,(function*(){return yield downloadSegmentRetry(n,e,t,a)}))})}l.reverse();let c=0;let m=0;const u=new DownloadProgress(p);u.startDisplayTimer();const h=u.onProgress();const g=[];let v;const waitAndWrite=()=>s(this,void 0,void 0,(function*(){const e=yield Promise.race(Object.values(g));yield i.write(e.buffer,0,e.count,e.offset);c--;delete g[e.offset];m+=e.count;h({loadedBytes:m})}));while(v=l.pop()){g[v.offset]=v.promiseGetter();c++;if(c>=((r=a.downloadConcurrency)!==null&&r!==void 0?r:10)){yield waitAndWrite()}}while(c>0){yield waitAndWrite()}}finally{n.dispose();yield i.close()}}))}t.downloadCacheHttpClientConcurrent=downloadCacheHttpClientConcurrent;function downloadSegmentRetry(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=5;let n=0;while(true){try{const i=3e4;const n=yield promiseWithTimeout(i,downloadSegment(e,t,a,r));if(typeof n==="string"){throw new Error("downloadSegmentRetry failed due to timeout")}return n}catch(e){if(n>=i){throw e}n++}}}))}function downloadSegment(e,t,a,r){return s(this,void 0,void 0,(function*(){const i=yield(0,y.retryHttpClientResponse)("downloadCachePart",(()=>s(this,void 0,void 0,(function*(){return yield e.get(t,{Range:`bytes=${a}-${a+r-1}`})}))));if(!i.readBodyBuffer){throw new Error("Expected HttpClientResponse to implement readBodyBuffer")}return{offset:a,count:r,buffer:yield i.readBodyBuffer()}}))}function downloadCacheStorageSDK(e,t,a){var r;return s(this,void 0,void 0,(function*(){const i=new l.BlockBlobClient(e,undefined,{retryOptions:{tryTimeoutInMs:a.timeoutInMs}});const n=yield i.getProperties();const s=(r=n.contentLength)!==null&&r!==void 0?r:-1;if(s<0){o.debug("Unable to determine content length, downloading file with http-client...");yield downloadCacheHttpClient(e,t)}else{const e=Math.min(134217728,d.constants.MAX_LENGTH);const r=new DownloadProgress(s);const n=c.openSync(t,"w");try{r.startDisplayTimer();const t=new v.AbortController;const o=t.signal;while(!r.isDone()){const p=r.segmentOffset+r.segmentSize;const l=Math.min(e,s-p);r.nextSegment(l);const d=yield promiseWithTimeout(a.segmentTimeoutInMs||36e5,i.downloadToBuffer(p,l,{abortSignal:o,concurrency:a.downloadConcurrency,onProgress:r.onProgress()}));if(d==="timeout"){t.abort();throw new Error("Aborting cache download as the download time exceeded the timeout.")}else if(Buffer.isBuffer(d)){c.writeFileSync(n,d)}}}finally{r.stopDisplayTimer();c.closeSync(n)}}}))}t.downloadCacheStorageSDK=downloadCacheStorageSDK;const promiseWithTimeout=(e,t)=>s(void 0,void 0,void 0,(function*(){let a;const r=new Promise((t=>{a=setTimeout((()=>t("timeout")),e)}));return Promise.race([t,r]).then((e=>{clearTimeout(a);return e}))}))},3981:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.retryHttpClientResponse=t.retryTypedResponse=t.retry=t.isRetryableStatusCode=t.isServerErrorStatusCode=t.isSuccessStatusCode=void 0;const o=n(a(2186));const p=a(6255);const l=a(8840);function isSuccessStatusCode(e){if(!e){return false}return e>=200&&e<300}t.isSuccessStatusCode=isSuccessStatusCode;function isServerErrorStatusCode(e){if(!e){return true}return e>=500}t.isServerErrorStatusCode=isServerErrorStatusCode;function isRetryableStatusCode(e){if(!e){return false}const t=[p.HttpCodes.BadGateway,p.HttpCodes.ServiceUnavailable,p.HttpCodes.GatewayTimeout];return t.includes(e)}t.isRetryableStatusCode=isRetryableStatusCode;function sleep(e){return s(this,void 0,void 0,(function*(){return new Promise((t=>setTimeout(t,e)))}))}function retry(e,t,a,r=l.DefaultRetryAttempts,i=l.DefaultRetryDelay,n=undefined){return s(this,void 0,void 0,(function*(){let s="";let p=1;while(p<=r){let l=undefined;let d=undefined;let c=false;try{l=yield t()}catch(e){if(n){l=n(e)}c=true;s=e.message}if(l){d=a(l);if(!isServerErrorStatusCode(d)){return l}}if(d){c=isRetryableStatusCode(d);s=`Cache service responded with ${d}`}o.debug(`${e} - Attempt ${p} of ${r} failed with error: ${s}`);if(!c){o.debug(`${e} - Error is not retryable`);break}yield sleep(i);p++}throw Error(`${e} failed: ${s}`)}))}t.retry=retry;function retryTypedResponse(e,t,a=l.DefaultRetryAttempts,r=l.DefaultRetryDelay){return s(this,void 0,void 0,(function*(){return yield retry(e,t,(e=>e.statusCode),a,r,(e=>{if(e instanceof p.HttpClientError){return{statusCode:e.statusCode,result:null,headers:{},error:e}}else{return undefined}}))}))}t.retryTypedResponse=retryTypedResponse;function retryHttpClientResponse(e,t,a=l.DefaultRetryAttempts,r=l.DefaultRetryDelay){return s(this,void 0,void 0,(function*(){return yield retry(e,t,(e=>e.message.statusCode),a,r)}))}t.retryHttpClientResponse=retryHttpClientResponse},6490:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.createTar=t.extractTar=t.listTar=void 0;const o=a(1514);const p=n(a(7436));const l=a(7147);const d=n(a(1017));const c=n(a(1518));const m=a(8840);const u=process.platform==="win32";function getTarPath(){return s(this,void 0,void 0,(function*(){switch(process.platform){case"win32":{const e=yield c.getGnuTarPathOnWindows();const t=m.SystemTarPathOnWindows;if(e){return{path:e,type:m.ArchiveToolType.GNU}}else if((0,l.existsSync)(t)){return{path:t,type:m.ArchiveToolType.BSD}}break}case"darwin":{const e=yield p.which("gtar",false);if(e){return{path:e,type:m.ArchiveToolType.GNU}}else{return{path:yield p.which("tar",true),type:m.ArchiveToolType.BSD}}}default:break}return{path:yield p.which("tar",true),type:m.ArchiveToolType.GNU}}))}function getTarArgs(e,t,a,r=""){return s(this,void 0,void 0,(function*(){const i=[`"${e.path}"`];const n=c.getCacheFileName(t);const s="cache.tar";const o=getWorkingDirectory();const p=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(a){case"create":i.push("--posix","-cf",p?s:n.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"--exclude",p?s:n.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P","-C",o.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"--files-from",m.ManifestFilename);break;case"extract":i.push("-xf",p?s:r.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P","-C",o.replace(new RegExp(`\\${d.sep}`,"g"),"/"));break;case"list":i.push("-tf",p?s:r.replace(new RegExp(`\\${d.sep}`,"g"),"/"),"-P");break}if(e.type===m.ArchiveToolType.GNU){switch(process.platform){case"win32":i.push("--force-local");break;case"darwin":i.push("--delay-directory-restore");break}}return i}))}function getCommands(e,t,a=""){return s(this,void 0,void 0,(function*(){let r;const i=yield getTarPath();const n=yield getTarArgs(i,e,t,a);const s=t!=="create"?yield getDecompressionProgram(i,e,a):yield getCompressionProgram(i,e);const o=i.type===m.ArchiveToolType.BSD&&e!==m.CompressionMethod.Gzip&&u;if(o&&t!=="create"){r=[[...s].join(" "),[...n].join(" ")]}else{r=[[...n].join(" "),[...s].join(" ")]}if(o){return r}return[r.join(" ")]}))}function getWorkingDirectory(){var e;return(e=process.env["GITHUB_WORKSPACE"])!==null&&e!==void 0?e:process.cwd()}function getDecompressionProgram(e,t,a){return s(this,void 0,void 0,(function*(){const r=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(t){case m.CompressionMethod.Zstd:return r?["zstd -d --long=30 --force -o",m.TarFilename,a.replace(new RegExp(`\\${d.sep}`,"g"),"/")]:["--use-compress-program",u?'"zstd -d --long=30"':"unzstd --long=30"];case m.CompressionMethod.ZstdWithoutLong:return r?["zstd -d --force -o",m.TarFilename,a.replace(new RegExp(`\\${d.sep}`,"g"),"/")]:["--use-compress-program",u?'"zstd -d"':"unzstd"];default:return["-z"]}}))}function getCompressionProgram(e,t){return s(this,void 0,void 0,(function*(){const a=c.getCacheFileName(t);const r=e.type===m.ArchiveToolType.BSD&&t!==m.CompressionMethod.Gzip&&u;switch(t){case m.CompressionMethod.Zstd:return r?["zstd -T0 --long=30 --force -o",a.replace(new RegExp(`\\${d.sep}`,"g"),"/"),m.TarFilename]:["--use-compress-program",u?'"zstd -T0 --long=30"':"zstdmt --long=30"];case m.CompressionMethod.ZstdWithoutLong:return r?["zstd -T0 --force -o",a.replace(new RegExp(`\\${d.sep}`,"g"),"/"),m.TarFilename]:["--use-compress-program",u?'"zstd -T0"':"zstdmt"];default:return["-z"]}}))}function execCommands(e,t){return s(this,void 0,void 0,(function*(){for(const a of e){try{yield(0,o.exec)(a,undefined,{cwd:t,env:Object.assign(Object.assign({},process.env),{MSYS:"winsymlinks:nativestrict"})})}catch(e){throw new Error(`${a.split(" ")[0]} failed with error: ${e===null||e===void 0?void 0:e.message}`)}}}))}function listTar(e,t){return s(this,void 0,void 0,(function*(){const a=yield getCommands(t,"list",e);yield execCommands(a)}))}t.listTar=listTar;function extractTar(e,t){return s(this,void 0,void 0,(function*(){const a=getWorkingDirectory();yield p.mkdirP(a);const r=yield getCommands(t,"extract",e);yield execCommands(r)}))}t.extractTar=extractTar;function createTar(e,t,a){return s(this,void 0,void 0,(function*(){(0,l.writeFileSync)(d.join(e,m.ManifestFilename),t.join("\n"));const r=yield getCommands(a,"create");yield execCommands(r,e)}))}t.createTar=createTar},6215:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;var i=Object.getOwnPropertyDescriptor(t,a);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[a]}}}Object.defineProperty(e,r,i)}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getDownloadOptions=t.getUploadOptions=void 0;const s=n(a(2186));function getUploadOptions(e){const t={uploadConcurrency:4,uploadChunkSize:32*1024*1024};if(e){if(typeof e.uploadConcurrency==="number"){t.uploadConcurrency=e.uploadConcurrency}if(typeof e.uploadChunkSize==="number"){t.uploadChunkSize=e.uploadChunkSize}}s.debug(`Upload concurrency: ${t.uploadConcurrency}`);s.debug(`Upload chunk size: ${t.uploadChunkSize}`);return t}t.getUploadOptions=getUploadOptions;function getDownloadOptions(e){const t={useAzureSdk:false,concurrentBlobDownloads:true,downloadConcurrency:8,timeoutInMs:3e4,segmentTimeoutInMs:6e5,lookupOnly:false};if(e){if(typeof e.useAzureSdk==="boolean"){t.useAzureSdk=e.useAzureSdk}if(typeof e.concurrentBlobDownloads==="boolean"){t.concurrentBlobDownloads=e.concurrentBlobDownloads}if(typeof e.downloadConcurrency==="number"){t.downloadConcurrency=e.downloadConcurrency}if(typeof e.timeoutInMs==="number"){t.timeoutInMs=e.timeoutInMs}if(typeof e.segmentTimeoutInMs==="number"){t.segmentTimeoutInMs=e.segmentTimeoutInMs}if(typeof e.lookupOnly==="boolean"){t.lookupOnly=e.lookupOnly}}const a=process.env["SEGMENT_DOWNLOAD_TIMEOUT_MINS"];if(a&&!isNaN(Number(a))&&isFinite(Number(a))){t.segmentTimeoutInMs=Number(a)*60*1e3}s.debug(`Use Azure SDK: ${t.useAzureSdk}`);s.debug(`Download concurrency: ${t.downloadConcurrency}`);s.debug(`Request timeout (ms): ${t.timeoutInMs}`);s.debug(`Cache segment download timeout mins env var: ${process.env["SEGMENT_DOWNLOAD_TIMEOUT_MINS"]}`);s.debug(`Segment download timeout (ms): ${t.segmentTimeoutInMs}`);s.debug(`Lookup only: ${t.lookupOnly}`);return t}t.getDownloadOptions=getDownloadOptions},4138:(e,t,a)=>{var r=a(1610);var i=a(8373);var n=i;n.v1=r;n.v4=i;e.exports=n},5694:e=>{var t=[];for(var a=0;a<256;++a){t[a]=(a+256).toString(16).substr(1)}function bytesToUuid(e,a){var r=a||0;var i=t;return[i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]]].join("")}e.exports=bytesToUuid},4069:(e,t,a)=>{var r=a(6113);e.exports=function nodeRNG(){return r.randomBytes(16)}},1610:(e,t,a)=>{var r=a(4069);var i=a(5694);var n;var s;var o=0;var p=0;function v1(e,t,a){var l=t&&a||0;var d=t||[];e=e||{};var c=e.node||n;var m=e.clockseq!==undefined?e.clockseq:s;if(c==null||m==null){var u=r();if(c==null){c=n=[u[0]|1,u[1],u[2],u[3],u[4],u[5]]}if(m==null){m=s=(u[6]<<8|u[7])&16383}}var h=e.msecs!==undefined?e.msecs:(new Date).getTime();var g=e.nsecs!==undefined?e.nsecs:p+1;var y=h-o+(g-p)/1e4;if(y<0&&e.clockseq===undefined){m=m+1&16383}if((y<0||h>o)&&e.nsecs===undefined){g=0}if(g>=1e4){throw new Error("uuid.v1(): Can't create more than 10M uuids/sec")}o=h;p=g;s=m;h+=122192928e5;var v=((h&268435455)*1e4+g)%4294967296;d[l++]=v>>>24&255;d[l++]=v>>>16&255;d[l++]=v>>>8&255;d[l++]=v&255;var b=h/4294967296*1e4&268435455;d[l++]=b>>>8&255;d[l++]=b&255;d[l++]=b>>>24&15|16;d[l++]=b>>>16&255;d[l++]=m>>>8|128;d[l++]=m&255;for(var x=0;x<6;++x){d[l+x]=c[x]}return t?t:i(d)}e.exports=v1},8373:(e,t,a)=>{var r=a(4069);var i=a(5694);function v4(e,t,a){var n=t&&a||0;if(typeof e=="string"){t=e==="binary"?new Array(16):null;e=null}e=e||{};var s=e.random||(e.rng||r)();s[6]=s[6]&15|64;s[8]=s[8]&63|128;if(t){for(var o=0;o<16;++o){t[n+o]=s[o]}}return t||i(s)}e.exports=v4},7351:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.issue=t.issueCommand=void 0;const s=n(a(2037));const o=a(5278);function issueCommand(e,t,a){const r=new Command(e,t,a);process.stdout.write(r.toString()+s.EOL)}t.issueCommand=issueCommand;function issue(e,t=""){issueCommand(e,{},t)}t.issue=issue;const p="::";class Command{constructor(e,t,a){if(!e){e="missing.command"}this.command=e;this.properties=t;this.message=a}toString(){let e=p+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let t=true;for(const a in this.properties){if(this.properties.hasOwnProperty(a)){const r=this.properties[a];if(r){if(t){t=false}else{e+=","}e+=`${a}=${escapeProperty(r)}`}}}}e+=`${p}${escapeData(this.message)}`;return e}}function escapeData(e){return o.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function escapeProperty(e){return o.toCommandValue(e).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}},2186:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getIDToken=t.getState=t.saveState=t.group=t.endGroup=t.startGroup=t.info=t.notice=t.warning=t.error=t.debug=t.isDebug=t.setFailed=t.setCommandEcho=t.setOutput=t.getBooleanInput=t.getMultilineInput=t.getInput=t.addPath=t.setSecret=t.exportVariable=t.ExitCode=void 0;const o=a(7351);const p=a(717);const l=a(5278);const d=n(a(2037));const c=n(a(1017));const m=a(8041);var u;(function(e){e[e["Success"]=0]="Success";e[e["Failure"]=1]="Failure"})(u=t.ExitCode||(t.ExitCode={}));function exportVariable(e,t){const a=l.toCommandValue(t);process.env[e]=a;const r=process.env["GITHUB_ENV"]||"";if(r){return p.issueFileCommand("ENV",p.prepareKeyValueMessage(e,t))}o.issueCommand("set-env",{name:e},a)}t.exportVariable=exportVariable;function setSecret(e){o.issueCommand("add-mask",{},e)}t.setSecret=setSecret;function addPath(e){const t=process.env["GITHUB_PATH"]||"";if(t){p.issueFileCommand("PATH",e)}else{o.issueCommand("add-path",{},e)}process.env["PATH"]=`${e}${c.delimiter}${process.env["PATH"]}`}t.addPath=addPath;function getInput(e,t){const a=process.env[`INPUT_${e.replace(/ /g,"_").toUpperCase()}`]||"";if(t&&t.required&&!a){throw new Error(`Input required and not supplied: ${e}`)}if(t&&t.trimWhitespace===false){return a}return a.trim()}t.getInput=getInput;function getMultilineInput(e,t){const a=getInput(e,t).split("\n").filter((e=>e!==""));if(t&&t.trimWhitespace===false){return a}return a.map((e=>e.trim()))}t.getMultilineInput=getMultilineInput;function getBooleanInput(e,t){const a=["true","True","TRUE"];const r=["false","False","FALSE"];const i=getInput(e,t);if(a.includes(i))return true;if(r.includes(i))return false;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${e}\n`+`Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}t.getBooleanInput=getBooleanInput;function setOutput(e,t){const a=process.env["GITHUB_OUTPUT"]||"";if(a){return p.issueFileCommand("OUTPUT",p.prepareKeyValueMessage(e,t))}process.stdout.write(d.EOL);o.issueCommand("set-output",{name:e},l.toCommandValue(t))}t.setOutput=setOutput;function setCommandEcho(e){o.issue("echo",e?"on":"off")}t.setCommandEcho=setCommandEcho;function setFailed(e){process.exitCode=u.Failure;error(e)}t.setFailed=setFailed;function isDebug(){return process.env["RUNNER_DEBUG"]==="1"}t.isDebug=isDebug;function debug(e){o.issueCommand("debug",{},e)}t.debug=debug;function error(e,t={}){o.issueCommand("error",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.error=error;function warning(e,t={}){o.issueCommand("warning",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.warning=warning;function notice(e,t={}){o.issueCommand("notice",l.toCommandProperties(t),e instanceof Error?e.toString():e)}t.notice=notice;function info(e){process.stdout.write(e+d.EOL)}t.info=info;function startGroup(e){o.issue("group",e)}t.startGroup=startGroup;function endGroup(){o.issue("endgroup")}t.endGroup=endGroup;function group(e,t){return s(this,void 0,void 0,(function*(){startGroup(e);let a;try{a=yield t()}finally{endGroup()}return a}))}t.group=group;function saveState(e,t){const a=process.env["GITHUB_STATE"]||"";if(a){return p.issueFileCommand("STATE",p.prepareKeyValueMessage(e,t))}o.issueCommand("save-state",{name:e},l.toCommandValue(t))}t.saveState=saveState;function getState(e){return process.env[`STATE_${e}`]||""}t.getState=getState;function getIDToken(e){return s(this,void 0,void 0,(function*(){return yield m.OidcClient.getIDToken(e)}))}t.getIDToken=getIDToken;var h=a(1327);Object.defineProperty(t,"summary",{enumerable:true,get:function(){return h.summary}});var g=a(1327);Object.defineProperty(t,"markdownSummary",{enumerable:true,get:function(){return g.markdownSummary}});var y=a(2981);Object.defineProperty(t,"toPosixPath",{enumerable:true,get:function(){return y.toPosixPath}});Object.defineProperty(t,"toWin32Path",{enumerable:true,get:function(){return y.toWin32Path}});Object.defineProperty(t,"toPlatformPath",{enumerable:true,get:function(){return y.toPlatformPath}})},717:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.prepareKeyValueMessage=t.issueFileCommand=void 0;const s=n(a(7147));const o=n(a(2037));const p=a(5840);const l=a(5278);function issueFileCommand(e,t){const a=process.env[`GITHUB_${e}`];if(!a){throw new Error(`Unable to find environment variable for file command ${e}`)}if(!s.existsSync(a)){throw new Error(`Missing file at path: ${a}`)}s.appendFileSync(a,`${l.toCommandValue(t)}${o.EOL}`,{encoding:"utf8"})}t.issueFileCommand=issueFileCommand;function prepareKeyValueMessage(e,t){const a=`ghadelimiter_${p.v4()}`;const r=l.toCommandValue(t);if(e.includes(a)){throw new Error(`Unexpected input: name should not contain the delimiter "${a}"`)}if(r.includes(a)){throw new Error(`Unexpected input: value should not contain the delimiter "${a}"`)}return`${e}<<${a}${o.EOL}${r}${o.EOL}${a}`}t.prepareKeyValueMessage=prepareKeyValueMessage},8041:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.OidcClient=void 0;const i=a(6255);const n=a(5526);const s=a(2186);class OidcClient{static createHttpClient(e=true,t=10){const a={allowRetries:e,maxRetries:t};return new i.HttpClient("actions/oidc-client",[new n.BearerCredentialHandler(OidcClient.getRequestToken())],a)}static getRequestToken(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_TOKEN env variable")}return e}static getIDTokenUrl(){const e=process.env["ACTIONS_ID_TOKEN_REQUEST_URL"];if(!e){throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable")}return e}static getCall(e){var t;return r(this,void 0,void 0,(function*(){const a=OidcClient.createHttpClient();const r=yield a.getJson(e).catch((e=>{throw new Error(`Failed to get ID Token. \n \n Error Code : ${e.statusCode}\n \n Error Message: ${e.result.message}`)}));const i=(t=r.result)===null||t===void 0?void 0:t.value;if(!i){throw new Error("Response json body do not have ID Token field")}return i}))}static getIDToken(e){return r(this,void 0,void 0,(function*(){try{let t=OidcClient.getIDTokenUrl();if(e){const a=encodeURIComponent(e);t=`${t}&audience=${a}`}s.debug(`ID token url is ${t}`);const a=yield OidcClient.getCall(t);s.setSecret(a);return a}catch(e){throw new Error(`Error message: ${e.message}`)}}))}}t.OidcClient=OidcClient},2981:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.toPlatformPath=t.toWin32Path=t.toPosixPath=void 0;const s=n(a(1017));function toPosixPath(e){return e.replace(/[\\]/g,"/")}t.toPosixPath=toPosixPath;function toWin32Path(e){return e.replace(/[/]/g,"\\")}t.toWin32Path=toWin32Path;function toPlatformPath(e){return e.replace(/[/\\]/g,s.sep)}t.toPlatformPath=toPlatformPath},1327:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.summary=t.markdownSummary=t.SUMMARY_DOCS_URL=t.SUMMARY_ENV_VAR=void 0;const i=a(2037);const n=a(7147);const{access:s,appendFile:o,writeFile:p}=n.promises;t.SUMMARY_ENV_VAR="GITHUB_STEP_SUMMARY";t.SUMMARY_DOCS_URL="https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary";class Summary{constructor(){this._buffer=""}filePath(){return r(this,void 0,void 0,(function*(){if(this._filePath){return this._filePath}const e=process.env[t.SUMMARY_ENV_VAR];if(!e){throw new Error(`Unable to find environment variable for $${t.SUMMARY_ENV_VAR}. Check if your runtime environment supports job summaries.`)}try{yield s(e,n.constants.R_OK|n.constants.W_OK)}catch(t){throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}this._filePath=e;return this._filePath}))}wrap(e,t,a={}){const r=Object.entries(a).map((([e,t])=>` ${e}="${t}"`)).join("");if(!t){return`<${e}${r}>`}return`<${e}${r}>${t}`}write(e){return r(this,void 0,void 0,(function*(){const t=!!(e===null||e===void 0?void 0:e.overwrite);const a=yield this.filePath();const r=t?p:o;yield r(a,this._buffer,{encoding:"utf8"});return this.emptyBuffer()}))}clear(){return r(this,void 0,void 0,(function*(){return this.emptyBuffer().write({overwrite:true})}))}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){this._buffer="";return this}addRaw(e,t=false){this._buffer+=e;return t?this.addEOL():this}addEOL(){return this.addRaw(i.EOL)}addCodeBlock(e,t){const a=Object.assign({},t&&{lang:t});const r=this.wrap("pre",this.wrap("code",e),a);return this.addRaw(r).addEOL()}addList(e,t=false){const a=t?"ol":"ul";const r=e.map((e=>this.wrap("li",e))).join("");const i=this.wrap(a,r);return this.addRaw(i).addEOL()}addTable(e){const t=e.map((e=>{const t=e.map((e=>{if(typeof e==="string"){return this.wrap("td",e)}const{header:t,data:a,colspan:r,rowspan:i}=e;const n=t?"th":"td";const s=Object.assign(Object.assign({},r&&{colspan:r}),i&&{rowspan:i});return this.wrap(n,a,s)})).join("");return this.wrap("tr",t)})).join("");const a=this.wrap("table",t);return this.addRaw(a).addEOL()}addDetails(e,t){const a=this.wrap("details",this.wrap("summary",e)+t);return this.addRaw(a).addEOL()}addImage(e,t,a){const{width:r,height:i}=a||{};const n=Object.assign(Object.assign({},r&&{width:r}),i&&{height:i});const s=this.wrap("img",null,Object.assign({src:e,alt:t},n));return this.addRaw(s).addEOL()}addHeading(e,t){const a=`h${t}`;const r=["h1","h2","h3","h4","h5","h6"].includes(a)?a:"h1";const i=this.wrap(r,e);return this.addRaw(i).addEOL()}addSeparator(){const e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){const e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,t){const a=Object.assign({},t&&{cite:t});const r=this.wrap("blockquote",e,a);return this.addRaw(r).addEOL()}addLink(e,t){const a=this.wrap("a",e,{href:t});return this.addRaw(a).addEOL()}}const l=new Summary;t.markdownSummary=l;t.summary=l},5278:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.toCommandProperties=t.toCommandValue=void 0;function toCommandValue(e){if(e===null||e===undefined){return""}else if(typeof e==="string"||e instanceof String){return e}return JSON.stringify(e)}t.toCommandValue=toCommandValue;function toCommandProperties(e){if(!Object.keys(e).length){return{}}return{title:e.title,file:e.file,line:e.startLine,endLine:e.endLine,col:e.startColumn,endColumn:e.endColumn}}t.toCommandProperties=toCommandProperties},1514:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.getExecOutput=t.exec=void 0;const o=a(1576);const p=n(a(8159));function exec(e,t,a){return s(this,void 0,void 0,(function*(){const r=p.argStringToArray(e);if(r.length===0){throw new Error(`Parameter 'commandLine' cannot be null or empty.`)}const i=r[0];t=r.slice(1).concat(t||[]);const n=new p.ToolRunner(i,t,a);return n.exec()}))}t.exec=exec;function getExecOutput(e,t,a){var r,i;return s(this,void 0,void 0,(function*(){let n="";let s="";const p=new o.StringDecoder("utf8");const l=new o.StringDecoder("utf8");const d=(r=a===null||a===void 0?void 0:a.listeners)===null||r===void 0?void 0:r.stdout;const c=(i=a===null||a===void 0?void 0:a.listeners)===null||i===void 0?void 0:i.stderr;const stdErrListener=e=>{s+=l.write(e);if(c){c(e)}};const stdOutListener=e=>{n+=p.write(e);if(d){d(e)}};const m=Object.assign(Object.assign({},a===null||a===void 0?void 0:a.listeners),{stdout:stdOutListener,stderr:stdErrListener});const u=yield exec(e,t,Object.assign(Object.assign({},a),{listeners:m}));n+=p.end();s+=l.end();return{exitCode:u,stdout:n,stderr:s}}))}t.getExecOutput=getExecOutput},8159:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.argStringToArray=t.ToolRunner=void 0;const o=n(a(2037));const p=n(a(2361));const l=n(a(2081));const d=n(a(1017));const c=n(a(7436));const m=n(a(1962));const u=a(9512);const h=process.platform==="win32";class ToolRunner extends p.EventEmitter{constructor(e,t,a){super();if(!e){throw new Error("Parameter 'toolPath' cannot be null or empty.")}this.toolPath=e;this.args=t||[];this.options=a||{}}_debug(e){if(this.options.listeners&&this.options.listeners.debug){this.options.listeners.debug(e)}}_getCommandString(e,t){const a=this._getSpawnFileName();const r=this._getSpawnArgs(e);let i=t?"":"[command]";if(h){if(this._isCmdFile()){i+=a;for(const e of r){i+=` ${e}`}}else if(e.windowsVerbatimArguments){i+=`"${a}"`;for(const e of r){i+=` ${e}`}}else{i+=this._windowsQuoteCmdArg(a);for(const e of r){i+=` ${this._windowsQuoteCmdArg(e)}`}}}else{i+=a;for(const e of r){i+=` ${e}`}}return i}_processLineBuffer(e,t,a){try{let r=t+e.toString();let i=r.indexOf(o.EOL);while(i>-1){const e=r.substring(0,i);a(e);r=r.substring(i+o.EOL.length);i=r.indexOf(o.EOL)}return r}catch(e){this._debug(`error processing line. Failed with error ${e}`);return""}}_getSpawnFileName(){if(h){if(this._isCmdFile()){return process.env["COMSPEC"]||"cmd.exe"}}return this.toolPath}_getSpawnArgs(e){if(h){if(this._isCmdFile()){let t=`/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;for(const a of this.args){t+=" ";t+=e.windowsVerbatimArguments?a:this._windowsQuoteCmdArg(a)}t+='"';return[t]}}return this.args}_endsWith(e,t){return e.endsWith(t)}_isCmdFile(){const e=this.toolPath.toUpperCase();return this._endsWith(e,".CMD")||this._endsWith(e,".BAT")}_windowsQuoteCmdArg(e){if(!this._isCmdFile()){return this._uvQuoteCmdArg(e)}if(!e){return'""'}const t=[" ","\t","&","(",")","[","]","{","}","^","=",";","!","'","+",",","`","~","|","<",">",'"'];let a=false;for(const r of e){if(t.some((e=>e===r))){a=true;break}}if(!a){return e}let r='"';let i=true;for(let t=e.length;t>0;t--){r+=e[t-1];if(i&&e[t-1]==="\\"){r+="\\"}else if(e[t-1]==='"'){i=true;r+='"'}else{i=false}}r+='"';return r.split("").reverse().join("")}_uvQuoteCmdArg(e){if(!e){return'""'}if(!e.includes(" ")&&!e.includes("\t")&&!e.includes('"')){return e}if(!e.includes('"')&&!e.includes("\\")){return`"${e}"`}let t='"';let a=true;for(let r=e.length;r>0;r--){t+=e[r-1];if(a&&e[r-1]==="\\"){t+="\\"}else if(e[r-1]==='"'){a=true;t+="\\"}else{a=false}}t+='"';return t.split("").reverse().join("")}_cloneExecOptions(e){e=e||{};const t={cwd:e.cwd||process.cwd(),env:e.env||process.env,silent:e.silent||false,windowsVerbatimArguments:e.windowsVerbatimArguments||false,failOnStdErr:e.failOnStdErr||false,ignoreReturnCode:e.ignoreReturnCode||false,delay:e.delay||1e4};t.outStream=e.outStream||process.stdout;t.errStream=e.errStream||process.stderr;return t}_getSpawnOptions(e,t){e=e||{};const a={};a.cwd=e.cwd;a.env=e.env;a["windowsVerbatimArguments"]=e.windowsVerbatimArguments||this._isCmdFile();if(e.windowsVerbatimArguments){a.argv0=`"${t}"`}return a}exec(){return s(this,void 0,void 0,(function*(){if(!m.isRooted(this.toolPath)&&(this.toolPath.includes("/")||h&&this.toolPath.includes("\\"))){this.toolPath=d.resolve(process.cwd(),this.options.cwd||process.cwd(),this.toolPath)}this.toolPath=yield c.which(this.toolPath,true);return new Promise(((e,t)=>s(this,void 0,void 0,(function*(){this._debug(`exec tool: ${this.toolPath}`);this._debug("arguments:");for(const e of this.args){this._debug(` ${e}`)}const a=this._cloneExecOptions(this.options);if(!a.silent&&a.outStream){a.outStream.write(this._getCommandString(a)+o.EOL)}const r=new ExecState(a,this.toolPath);r.on("debug",(e=>{this._debug(e)}));if(this.options.cwd&&!(yield m.exists(this.options.cwd))){return t(new Error(`The cwd: ${this.options.cwd} does not exist!`))}const i=this._getSpawnFileName();const n=l.spawn(i,this._getSpawnArgs(a),this._getSpawnOptions(this.options,i));let s="";if(n.stdout){n.stdout.on("data",(e=>{if(this.options.listeners&&this.options.listeners.stdout){this.options.listeners.stdout(e)}if(!a.silent&&a.outStream){a.outStream.write(e)}s=this._processLineBuffer(e,s,(e=>{if(this.options.listeners&&this.options.listeners.stdline){this.options.listeners.stdline(e)}}))}))}let p="";if(n.stderr){n.stderr.on("data",(e=>{r.processStderr=true;if(this.options.listeners&&this.options.listeners.stderr){this.options.listeners.stderr(e)}if(!a.silent&&a.errStream&&a.outStream){const t=a.failOnStdErr?a.errStream:a.outStream;t.write(e)}p=this._processLineBuffer(e,p,(e=>{if(this.options.listeners&&this.options.listeners.errline){this.options.listeners.errline(e)}}))}))}n.on("error",(e=>{r.processError=e.message;r.processExited=true;r.processClosed=true;r.CheckComplete()}));n.on("exit",(e=>{r.processExitCode=e;r.processExited=true;this._debug(`Exit code ${e} received from tool '${this.toolPath}'`);r.CheckComplete()}));n.on("close",(e=>{r.processExitCode=e;r.processExited=true;r.processClosed=true;this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);r.CheckComplete()}));r.on("done",((a,r)=>{if(s.length>0){this.emit("stdline",s)}if(p.length>0){this.emit("errline",p)}n.removeAllListeners();if(a){t(a)}else{e(r)}}));if(this.options.input){if(!n.stdin){throw new Error("child process missing stdin")}n.stdin.end(this.options.input)}}))))}))}}t.ToolRunner=ToolRunner;function argStringToArray(e){const t=[];let a=false;let r=false;let i="";function append(e){if(r&&e!=='"'){i+="\\"}i+=e;r=false}for(let n=0;n0){t.push(i);i=""}continue}append(s)}if(i.length>0){t.push(i.trim())}return t}t.argStringToArray=argStringToArray;class ExecState extends p.EventEmitter{constructor(e,t){super();this.processClosed=false;this.processError="";this.processExitCode=0;this.processExited=false;this.processStderr=false;this.delay=1e4;this.done=false;this.timeout=null;if(!t){throw new Error("toolPath must not be empty")}this.options=e;this.toolPath=t;if(e.delay){this.delay=e.delay}}CheckComplete(){if(this.done){return}if(this.processClosed){this._setResult()}else if(this.processExited){this.timeout=u.setTimeout(ExecState.HandleTimeout,this.delay,this)}}_debug(e){this.emit("debug",e)}_setResult(){let e;if(this.processExited){if(this.processError){e=new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`)}else if(this.processExitCode!==0&&!this.options.ignoreReturnCode){e=new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`)}else if(this.processStderr&&this.options.failOnStdErr){e=new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`)}}if(this.timeout){clearTimeout(this.timeout);this.timeout=null}this.done=true;this.emit("done",e,this.processExitCode)}static HandleTimeout(e){if(e.done){return}if(!e.processClosed&&e.processExited){const t=`The STDIO streams did not close within ${e.delay/1e3} seconds of the exit event from process '${e.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;e._debug(t)}e._setResult()}}},4087:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.Context=void 0;const r=a(7147);const i=a(2037);class Context{constructor(){var e,t,a;this.payload={};if(process.env.GITHUB_EVENT_PATH){if(r.existsSync(process.env.GITHUB_EVENT_PATH)){this.payload=JSON.parse(r.readFileSync(process.env.GITHUB_EVENT_PATH,{encoding:"utf8"}))}else{const e=process.env.GITHUB_EVENT_PATH;process.stdout.write(`GITHUB_EVENT_PATH ${e} does not exist${i.EOL}`)}}this.eventName=process.env.GITHUB_EVENT_NAME;this.sha=process.env.GITHUB_SHA;this.ref=process.env.GITHUB_REF;this.workflow=process.env.GITHUB_WORKFLOW;this.action=process.env.GITHUB_ACTION;this.actor=process.env.GITHUB_ACTOR;this.job=process.env.GITHUB_JOB;this.runNumber=parseInt(process.env.GITHUB_RUN_NUMBER,10);this.runId=parseInt(process.env.GITHUB_RUN_ID,10);this.apiUrl=(e=process.env.GITHUB_API_URL)!==null&&e!==void 0?e:`https://api.github.com`;this.serverUrl=(t=process.env.GITHUB_SERVER_URL)!==null&&t!==void 0?t:`https://github.com`;this.graphqlUrl=(a=process.env.GITHUB_GRAPHQL_URL)!==null&&a!==void 0?a:`https://api.github.com/graphql`}get issue(){const e=this.payload;return Object.assign(Object.assign({},this.repo),{number:(e.issue||e.pull_request||e).number})}get repo(){if(process.env.GITHUB_REPOSITORY){const[e,t]=process.env.GITHUB_REPOSITORY.split("/");return{owner:e,repo:t}}if(this.payload.repository){return{owner:this.payload.repository.owner.login,repo:this.payload.repository.name}}throw new Error("context.repo requires a GITHUB_REPOSITORY environment variable like 'owner/repo'")}}t.Context=Context},5438:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokit=t.context=void 0;const s=n(a(4087));const o=a(3030);t.context=new s.Context;function getOctokit(e,t,...a){const r=o.GitHub.plugin(...a);return new r(o.getOctokitOptions(e,t))}t.getOctokit=getOctokit},7914:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getApiBaseUrl=t.getProxyAgent=t.getAuthString=void 0;const s=n(a(6255));function getAuthString(e,t){if(!e&&!t.auth){throw new Error("Parameter token or opts.auth is required")}else if(e&&t.auth){throw new Error("Parameters token and opts.auth may not both be specified")}return typeof t.auth==="string"?t.auth:`token ${e}`}t.getAuthString=getAuthString;function getProxyAgent(e){const t=new s.HttpClient;return t.getAgent(e)}t.getProxyAgent=getProxyAgent;function getApiBaseUrl(){return process.env["GITHUB_API_URL"]||"https://api.github.com"}t.getApiBaseUrl=getApiBaseUrl},3030:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOctokitOptions=t.GitHub=t.defaults=t.context=void 0;const s=n(a(4087));const o=n(a(7914));const p=a(6762);const l=a(3044);const d=a(4193);t.context=new s.Context;const c=o.getApiBaseUrl();t.defaults={baseUrl:c,request:{agent:o.getProxyAgent(c)}};t.GitHub=p.Octokit.plugin(l.restEndpointMethods,d.paginateRest).defaults(t.defaults);function getOctokitOptions(e,t){const a=Object.assign({},t||{});const r=o.getAuthString(e,a);if(r){a.auth=r}return a}t.getOctokitOptions=getOctokitOptions},8090:function(e,t,a){"use strict";var r=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.create=void 0;const i=a(8298);function create(e,t){return r(this,void 0,void 0,(function*(){return yield i.DefaultGlobber.create(e,t)}))}t.create=create},1026:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};Object.defineProperty(t,"__esModule",{value:true});t.getOptions=void 0;const s=n(a(2186));function getOptions(e){const t={followSymbolicLinks:true,implicitDescendants:true,omitBrokenSymbolicLinks:true};if(e){if(typeof e.followSymbolicLinks==="boolean"){t.followSymbolicLinks=e.followSymbolicLinks;s.debug(`followSymbolicLinks '${t.followSymbolicLinks}'`)}if(typeof e.implicitDescendants==="boolean"){t.implicitDescendants=e.implicitDescendants;s.debug(`implicitDescendants '${t.implicitDescendants}'`)}if(typeof e.omitBrokenSymbolicLinks==="boolean"){t.omitBrokenSymbolicLinks=e.omitBrokenSymbolicLinks;s.debug(`omitBrokenSymbolicLinks '${t.omitBrokenSymbolicLinks}'`)}}return t}t.getOptions=getOptions},8298:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof __values==="function"?__values(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};var p=this&&this.__await||function(e){return this instanceof p?(this.v=e,this):new p(e)};var l=this&&this.__asyncGenerator||function(e,t,a){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=a.apply(e,t||[]),i,n=[];return i={},verb("next"),verb("throw"),verb("return"),i[Symbol.asyncIterator]=function(){return this},i;function verb(e){if(r[e])i[e]=function(t){return new Promise((function(a,r){n.push([e,t,a,r])>1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof p?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};Object.defineProperty(t,"__esModule",{value:true});t.DefaultGlobber=void 0;const d=n(a(2186));const c=n(a(7147));const m=n(a(1026));const u=n(a(1017));const h=n(a(9005));const g=a(1063);const y=a(4536);const v=a(9117);const b=process.platform==="win32";class DefaultGlobber{constructor(e){this.patterns=[];this.searchPaths=[];this.options=m.getOptions(e)}getSearchPaths(){return this.searchPaths.slice()}glob(){var e,t;return s(this,void 0,void 0,(function*(){const a=[];try{for(var r=o(this.globGenerator()),i;i=yield r.next(),!i.done;){const e=i.value;a.push(e)}}catch(t){e={error:t}}finally{try{if(i&&!i.done&&(t=r.return))yield t.call(r)}finally{if(e)throw e.error}}return a}))}globGenerator(){return l(this,arguments,(function*globGenerator_1(){const e=m.getOptions(this.options);const t=[];for(const a of this.patterns){t.push(a);if(e.implicitDescendants&&(a.trailingSeparator||a.segments[a.segments.length-1]!=="**")){t.push(new y.Pattern(a.negate,true,a.segments.concat("**")))}}const a=[];for(const e of h.getSearchPaths(t)){d.debug(`Search path '${e}'`);try{yield p(c.promises.lstat(e))}catch(e){if(e.code==="ENOENT"){continue}throw e}a.unshift(new v.SearchState(e,1))}const r=[];while(a.length){const i=a.pop();const n=h.match(t,i.path);const s=!!n||h.partialMatch(t,i.path);if(!n&&!s){continue}const o=yield p(DefaultGlobber.stat(i,e,r));if(!o){continue}if(o.isDirectory()){if(n&g.MatchKind.Directory){yield yield p(i.path)}else if(!s){continue}const e=i.level+1;const t=(yield p(c.promises.readdir(i.path))).map((t=>new v.SearchState(u.join(i.path,t),e)));a.push(...t.reverse())}else if(n&g.MatchKind.File){yield yield p(i.path)}}}))}static create(e,t){return s(this,void 0,void 0,(function*(){const a=new DefaultGlobber(t);if(b){e=e.replace(/\r\n/g,"\n");e=e.replace(/\r/g,"\n")}const r=e.split("\n").map((e=>e.trim()));for(const e of r){if(!e||e.startsWith("#")){continue}else{a.patterns.push(new y.Pattern(e))}}a.searchPaths.push(...h.getSearchPaths(a.patterns));return a}))}static stat(e,t,a){return s(this,void 0,void 0,(function*(){let r;if(t.followSymbolicLinks){try{r=yield c.promises.stat(e.path)}catch(a){if(a.code==="ENOENT"){if(t.omitBrokenSymbolicLinks){d.debug(`Broken symlink '${e.path}'`);return undefined}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw a}}else{r=yield c.promises.lstat(e.path)}if(r.isDirectory()&&t.followSymbolicLinks){const t=yield c.promises.realpath(e.path);while(a.length>=e.level){a.pop()}if(a.some((e=>e===t))){d.debug(`Symlink cycle detected for path '${e.path}' and realpath '${t}'`);return undefined}a.push(t)}return r}))}}t.DefaultGlobber=DefaultGlobber},1063:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MatchKind=void 0;var a;(function(e){e[e["None"]=0]="None";e[e["Directory"]=1]="Directory";e[e["File"]=2]="File";e[e["All"]=3]="All"})(a=t.MatchKind||(t.MatchKind={}))},1849:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.safeTrimTrailingSeparator=t.normalizeSeparators=t.hasRoot=t.hasAbsoluteRoot=t.ensureAbsoluteRoot=t.dirname=void 0;const o=n(a(1017));const p=s(a(9491));const l=process.platform==="win32";function dirname(e){e=safeTrimTrailingSeparator(e);if(l&&/^\\\\[^\\]+(\\[^\\]+)?$/.test(e)){return e}let t=o.dirname(e);if(l&&/^\\\\[^\\]+\\[^\\]+\\$/.test(t)){t=safeTrimTrailingSeparator(t)}return t}t.dirname=dirname;function ensureAbsoluteRoot(e,t){p.default(e,`ensureAbsoluteRoot parameter 'root' must not be empty`);p.default(t,`ensureAbsoluteRoot parameter 'itemPath' must not be empty`);if(hasAbsoluteRoot(t)){return t}if(l){if(t.match(/^[A-Z]:[^\\/]|^[A-Z]:$/i)){let e=process.cwd();p.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);if(t[0].toUpperCase()===e[0].toUpperCase()){if(t.length===2){return`${t[0]}:\\${e.substr(3)}`}else{if(!e.endsWith("\\")){e+="\\"}return`${t[0]}:\\${e.substr(3)}${t.substr(2)}`}}else{return`${t[0]}:\\${t.substr(2)}`}}else if(normalizeSeparators(t).match(/^\\$|^\\[^\\]/)){const e=process.cwd();p.default(e.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${e}'`);return`${e[0]}:\\${t.substr(1)}`}}p.default(hasAbsoluteRoot(e),`ensureAbsoluteRoot parameter 'root' must have an absolute root`);if(e.endsWith("/")||l&&e.endsWith("\\")){}else{e+=o.sep}return e+t}t.ensureAbsoluteRoot=ensureAbsoluteRoot;function hasAbsoluteRoot(e){p.default(e,`hasAbsoluteRoot parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(l){return e.startsWith("\\\\")||/^[A-Z]:\\/i.test(e)}return e.startsWith("/")}t.hasAbsoluteRoot=hasAbsoluteRoot;function hasRoot(e){p.default(e,`isRooted parameter 'itemPath' must not be empty`);e=normalizeSeparators(e);if(l){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.hasRoot=hasRoot;function normalizeSeparators(e){e=e||"";if(l){e=e.replace(/\//g,"\\");const t=/^\\\\+[^\\]/.test(e);return(t?"\\":"")+e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}t.normalizeSeparators=normalizeSeparators;function safeTrimTrailingSeparator(e){if(!e){return""}e=normalizeSeparators(e);if(!e.endsWith(o.sep)){return e}if(e===o.sep){return e}if(l&&/^[A-Z]:\\$/i.test(e)){return e}return e.substr(0,e.length-1)}t.safeTrimTrailingSeparator=safeTrimTrailingSeparator},6836:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Path=void 0;const o=n(a(1017));const p=n(a(1849));const l=s(a(9491));const d=process.platform==="win32";class Path{constructor(e){this.segments=[];if(typeof e==="string"){l.default(e,`Parameter 'itemPath' must not be empty`);e=p.safeTrimTrailingSeparator(e);if(!p.hasRoot(e)){this.segments=e.split(o.sep)}else{let t=e;let a=p.dirname(t);while(a!==t){const e=o.basename(t);this.segments.unshift(e);t=a;a=p.dirname(t)}this.segments.unshift(t)}}else{l.default(e.length>0,`Parameter 'itemPath' must not be an empty array`);for(let t=0;t!e.negate));const t={};for(const a of e){const e=p?a.searchPath.toUpperCase():a.searchPath;t[e]="candidate"}const a=[];for(const r of e){const e=p?r.searchPath.toUpperCase():r.searchPath;if(t[e]==="included"){continue}let i=false;let n=e;let o=s.dirname(n);while(o!==n){if(t[o]){i=true;break}n=o;o=s.dirname(n)}if(!i){a.push(r.searchPath);t[e]="included"}}return a}t.getSearchPaths=getSearchPaths;function match(e,t){let a=o.MatchKind.None;for(const r of e){if(r.negate){a&=~r.match(t)}else{a|=r.match(t)}}return a}t.match=match;function partialMatch(e,t){return e.some((e=>!e.negate&&e.partialMatch(t)))}t.partialMatch=partialMatch},4536:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.Pattern=void 0;const o=n(a(2037));const p=n(a(1017));const l=n(a(1849));const d=s(a(9491));const c=a(3973);const m=a(1063);const u=a(6836);const h=process.platform==="win32";class Pattern{constructor(e,t=false,a,r){this.negate=false;let i;if(typeof e==="string"){i=e.trim()}else{a=a||[];d.default(a.length,`Parameter 'segments' must not empty`);const t=Pattern.getLiteral(a[0]);d.default(t&&l.hasAbsoluteRoot(t),`Parameter 'segments' first element must be a root path`);i=new u.Path(a).toString().trim();if(e){i=`!${i}`}}while(i.startsWith("!")){this.negate=!this.negate;i=i.substr(1).trim()}i=Pattern.fixupPattern(i,r);this.segments=new u.Path(i).segments;this.trailingSeparator=l.normalizeSeparators(i).endsWith(p.sep);i=l.safeTrimTrailingSeparator(i);let n=false;const s=this.segments.map((e=>Pattern.getLiteral(e))).filter((e=>!n&&!(n=e==="")));this.searchPath=new u.Path(s).toString();this.rootRegExp=new RegExp(Pattern.regExpEscape(s[0]),h?"i":"");this.isImplicitPattern=t;const o={dot:true,nobrace:true,nocase:h,nocomment:true,noext:true,nonegate:true};i=h?i.replace(/\\/g,"/"):i;this.minimatch=new c.Minimatch(i,o)}match(e){if(this.segments[this.segments.length-1]==="**"){e=l.normalizeSeparators(e);if(!e.endsWith(p.sep)&&this.isImplicitPattern===false){e=`${e}${p.sep}`}}else{e=l.safeTrimTrailingSeparator(e)}if(this.minimatch.match(e)){return this.trailingSeparator?m.MatchKind.Directory:m.MatchKind.All}return m.MatchKind.None}partialMatch(e){e=l.safeTrimTrailingSeparator(e);if(l.dirname(e)===e){return this.rootRegExp.test(e)}return this.minimatch.matchOne(e.split(h?/\\+/:/\/+/),this.minimatch.set[0],true)}static globEscape(e){return(h?e:e.replace(/\\/g,"\\\\")).replace(/(\[)(?=[^/]+\])/g,"[[]").replace(/\?/g,"[?]").replace(/\*/g,"[*]")}static fixupPattern(e,t){d.default(e,"pattern cannot be empty");const a=new u.Path(e).segments.map((e=>Pattern.getLiteral(e)));d.default(a.every(((e,t)=>(e!=="."||t===0)&&e!=="..")),`Invalid pattern '${e}'. Relative pathing '.' and '..' is not allowed.`);d.default(!l.hasRoot(e)||a[0],`Invalid pattern '${e}'. Root segment must not contain globs.`);e=l.normalizeSeparators(e);if(e==="."||e.startsWith(`.${p.sep}`)){e=Pattern.globEscape(process.cwd())+e.substr(1)}else if(e==="~"||e.startsWith(`~${p.sep}`)){t=t||o.homedir();d.default(t,"Unable to determine HOME directory");d.default(l.hasAbsoluteRoot(t),`Expected HOME directory to be a rooted path. Actual '${t}'`);e=Pattern.globEscape(t)+e.substr(1)}else if(h&&(e.match(/^[A-Z]:$/i)||e.match(/^[A-Z]:[^\\]/i))){let t=l.ensureAbsoluteRoot("C:\\dummy-root",e.substr(0,2));if(e.length>2&&!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(2)}else if(h&&(e==="\\"||e.match(/^\\[^\\]/))){let t=l.ensureAbsoluteRoot("C:\\dummy-root","\\");if(!t.endsWith("\\")){t+="\\"}e=Pattern.globEscape(t)+e.substr(1)}else{e=l.ensureAbsoluteRoot(Pattern.globEscape(process.cwd()),e)}return l.normalizeSeparators(e)}static getLiteral(e){let t="";for(let a=0;a=0){if(r.length>1){return""}if(r){t+=r;a=i;continue}}}t+=r}return t}static regExpEscape(e){return e.replace(/[[\\^$.|?*+()]/g,"\\$&")}}t.Pattern=Pattern},9117:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SearchState=void 0;class SearchState{constructor(e,t){this.path=e;this.level=t}}t.SearchState=SearchState},5526:function(e,t){"use strict";var a=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.PersonalAccessTokenCredentialHandler=t.BearerCredentialHandler=t.BasicCredentialHandler=void 0;class BasicCredentialHandler{constructor(e,t){this.username=e;this.password=t}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`${this.username}:${this.password}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.BasicCredentialHandler=BasicCredentialHandler;class BearerCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Bearer ${this.token}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.BearerCredentialHandler=BearerCredentialHandler;class PersonalAccessTokenCredentialHandler{constructor(e){this.token=e}prepareRequest(e){if(!e.headers){throw Error("The request has no headers")}e.headers["Authorization"]=`Basic ${Buffer.from(`PAT:${this.token}`).toString("base64")}`}canHandleAuthentication(){return false}handleAuthentication(){return a(this,void 0,void 0,(function*(){throw new Error("not implemented")}))}}t.PersonalAccessTokenCredentialHandler=PersonalAccessTokenCredentialHandler},6255:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.HttpClient=t.isHttps=t.HttpClientResponse=t.HttpClientError=t.getProxyUrl=t.MediaTypes=t.Headers=t.HttpCodes=void 0;const o=n(a(3685));const p=n(a(5687));const l=n(a(9835));const d=n(a(4294));var c;(function(e){e[e["OK"]=200]="OK";e[e["MultipleChoices"]=300]="MultipleChoices";e[e["MovedPermanently"]=301]="MovedPermanently";e[e["ResourceMoved"]=302]="ResourceMoved";e[e["SeeOther"]=303]="SeeOther";e[e["NotModified"]=304]="NotModified";e[e["UseProxy"]=305]="UseProxy";e[e["SwitchProxy"]=306]="SwitchProxy";e[e["TemporaryRedirect"]=307]="TemporaryRedirect";e[e["PermanentRedirect"]=308]="PermanentRedirect";e[e["BadRequest"]=400]="BadRequest";e[e["Unauthorized"]=401]="Unauthorized";e[e["PaymentRequired"]=402]="PaymentRequired";e[e["Forbidden"]=403]="Forbidden";e[e["NotFound"]=404]="NotFound";e[e["MethodNotAllowed"]=405]="MethodNotAllowed";e[e["NotAcceptable"]=406]="NotAcceptable";e[e["ProxyAuthenticationRequired"]=407]="ProxyAuthenticationRequired";e[e["RequestTimeout"]=408]="RequestTimeout";e[e["Conflict"]=409]="Conflict";e[e["Gone"]=410]="Gone";e[e["TooManyRequests"]=429]="TooManyRequests";e[e["InternalServerError"]=500]="InternalServerError";e[e["NotImplemented"]=501]="NotImplemented";e[e["BadGateway"]=502]="BadGateway";e[e["ServiceUnavailable"]=503]="ServiceUnavailable";e[e["GatewayTimeout"]=504]="GatewayTimeout"})(c=t.HttpCodes||(t.HttpCodes={}));var m;(function(e){e["Accept"]="accept";e["ContentType"]="content-type"})(m=t.Headers||(t.Headers={}));var u;(function(e){e["ApplicationJson"]="application/json"})(u=t.MediaTypes||(t.MediaTypes={}));function getProxyUrl(e){const t=l.getProxyUrl(new URL(e));return t?t.href:""}t.getProxyUrl=getProxyUrl;const h=[c.MovedPermanently,c.ResourceMoved,c.SeeOther,c.TemporaryRedirect,c.PermanentRedirect];const g=[c.BadGateway,c.ServiceUnavailable,c.GatewayTimeout];const y=["OPTIONS","GET","DELETE","HEAD"];const v=10;const b=5;class HttpClientError extends Error{constructor(e,t){super(e);this.name="HttpClientError";this.statusCode=t;Object.setPrototypeOf(this,HttpClientError.prototype)}}t.HttpClientError=HttpClientError;class HttpClientResponse{constructor(e){this.message=e}readBody(){return s(this,void 0,void 0,(function*(){return new Promise((e=>s(this,void 0,void 0,(function*(){let t=Buffer.alloc(0);this.message.on("data",(e=>{t=Buffer.concat([t,e])}));this.message.on("end",(()=>{e(t.toString())}))}))))}))}readBodyBuffer(){return s(this,void 0,void 0,(function*(){return new Promise((e=>s(this,void 0,void 0,(function*(){const t=[];this.message.on("data",(e=>{t.push(e)}));this.message.on("end",(()=>{e(Buffer.concat(t))}))}))))}))}}t.HttpClientResponse=HttpClientResponse;function isHttps(e){const t=new URL(e);return t.protocol==="https:"}t.isHttps=isHttps;class HttpClient{constructor(e,t,a){this._ignoreSslError=false;this._allowRedirects=true;this._allowRedirectDowngrade=false;this._maxRedirects=50;this._allowRetries=false;this._maxRetries=1;this._keepAlive=false;this._disposed=false;this.userAgent=e;this.handlers=t||[];this.requestOptions=a;if(a){if(a.ignoreSslError!=null){this._ignoreSslError=a.ignoreSslError}this._socketTimeout=a.socketTimeout;if(a.allowRedirects!=null){this._allowRedirects=a.allowRedirects}if(a.allowRedirectDowngrade!=null){this._allowRedirectDowngrade=a.allowRedirectDowngrade}if(a.maxRedirects!=null){this._maxRedirects=Math.max(a.maxRedirects,0)}if(a.keepAlive!=null){this._keepAlive=a.keepAlive}if(a.allowRetries!=null){this._allowRetries=a.allowRetries}if(a.maxRetries!=null){this._maxRetries=a.maxRetries}}}options(e,t){return s(this,void 0,void 0,(function*(){return this.request("OPTIONS",e,null,t||{})}))}get(e,t){return s(this,void 0,void 0,(function*(){return this.request("GET",e,null,t||{})}))}del(e,t){return s(this,void 0,void 0,(function*(){return this.request("DELETE",e,null,t||{})}))}post(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("POST",e,t,a||{})}))}patch(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("PATCH",e,t,a||{})}))}put(e,t,a){return s(this,void 0,void 0,(function*(){return this.request("PUT",e,t,a||{})}))}head(e,t){return s(this,void 0,void 0,(function*(){return this.request("HEAD",e,null,t||{})}))}sendStream(e,t,a,r){return s(this,void 0,void 0,(function*(){return this.request(e,t,a,r)}))}getJson(e,t={}){return s(this,void 0,void 0,(function*(){t[m.Accept]=this._getExistingOrDefaultHeader(t,m.Accept,u.ApplicationJson);const a=yield this.get(e,t);return this._processResponse(a,this.requestOptions)}))}postJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.post(e,r,a);return this._processResponse(i,this.requestOptions)}))}putJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.put(e,r,a);return this._processResponse(i,this.requestOptions)}))}patchJson(e,t,a={}){return s(this,void 0,void 0,(function*(){const r=JSON.stringify(t,null,2);a[m.Accept]=this._getExistingOrDefaultHeader(a,m.Accept,u.ApplicationJson);a[m.ContentType]=this._getExistingOrDefaultHeader(a,m.ContentType,u.ApplicationJson);const i=yield this.patch(e,r,a);return this._processResponse(i,this.requestOptions)}))}request(e,t,a,r){return s(this,void 0,void 0,(function*(){if(this._disposed){throw new Error("Client has already been disposed.")}const i=new URL(t);let n=this._prepareRequest(e,i,r);const s=this._allowRetries&&y.includes(e)?this._maxRetries+1:1;let o=0;let p;do{p=yield this.requestRaw(n,a);if(p&&p.message&&p.message.statusCode===c.Unauthorized){let e;for(const t of this.handlers){if(t.canHandleAuthentication(p)){e=t;break}}if(e){return e.handleAuthentication(this,n,a)}else{return p}}let t=this._maxRedirects;while(p.message.statusCode&&h.includes(p.message.statusCode)&&this._allowRedirects&&t>0){const s=p.message.headers["location"];if(!s){break}const o=new URL(s);if(i.protocol==="https:"&&i.protocol!==o.protocol&&!this._allowRedirectDowngrade){throw new Error("Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.")}yield p.readBody();if(o.hostname!==i.hostname){for(const e in r){if(e.toLowerCase()==="authorization"){delete r[e]}}}n=this._prepareRequest(e,o,r);p=yield this.requestRaw(n,a);t--}if(!p.message.statusCode||!g.includes(p.message.statusCode)){return p}o+=1;if(o{function callbackForResult(e,t){if(e){r(e)}else if(!t){r(new Error("Unknown error"))}else{a(t)}}this.requestRawWithCallback(e,t,callbackForResult)}))}))}requestRawWithCallback(e,t,a){if(typeof t==="string"){if(!e.options.headers){e.options.headers={}}e.options.headers["Content-Length"]=Buffer.byteLength(t,"utf8")}let r=false;function handleResult(e,t){if(!r){r=true;a(e,t)}}const i=e.httpModule.request(e.options,(e=>{const t=new HttpClientResponse(e);handleResult(undefined,t)}));let n;i.on("socket",(e=>{n=e}));i.setTimeout(this._socketTimeout||3*6e4,(()=>{if(n){n.end()}handleResult(new Error(`Request timeout: ${e.options.path}`))}));i.on("error",(function(e){handleResult(e)}));if(t&&typeof t==="string"){i.write(t,"utf8")}if(t&&typeof t!=="string"){t.on("close",(function(){i.end()}));t.pipe(i)}else{i.end()}}getAgent(e){const t=new URL(e);return this._getAgent(t)}_prepareRequest(e,t,a){const r={};r.parsedUrl=t;const i=r.parsedUrl.protocol==="https:";r.httpModule=i?p:o;const n=i?443:80;r.options={};r.options.host=r.parsedUrl.hostname;r.options.port=r.parsedUrl.port?parseInt(r.parsedUrl.port):n;r.options.path=(r.parsedUrl.pathname||"")+(r.parsedUrl.search||"");r.options.method=e;r.options.headers=this._mergeHeaders(a);if(this.userAgent!=null){r.options.headers["user-agent"]=this.userAgent}r.options.agent=this._getAgent(r.parsedUrl);if(this.handlers){for(const e of this.handlers){e.prepareRequest(r.options)}}return r}_mergeHeaders(e){if(this.requestOptions&&this.requestOptions.headers){return Object.assign({},lowercaseKeys(this.requestOptions.headers),lowercaseKeys(e||{}))}return lowercaseKeys(e||{})}_getExistingOrDefaultHeader(e,t,a){let r;if(this.requestOptions&&this.requestOptions.headers){r=lowercaseKeys(this.requestOptions.headers)[t]}return e[t]||r||a}_getAgent(e){let t;const a=l.getProxyUrl(e);const r=a&&a.hostname;if(this._keepAlive&&r){t=this._proxyAgent}if(this._keepAlive&&!r){t=this._agent}if(t){return t}const i=e.protocol==="https:";let n=100;if(this.requestOptions){n=this.requestOptions.maxSockets||o.globalAgent.maxSockets}if(a&&a.hostname){const e={maxSockets:n,keepAlive:this._keepAlive,proxy:Object.assign(Object.assign({},(a.username||a.password)&&{proxyAuth:`${a.username}:${a.password}`}),{host:a.hostname,port:a.port})};let r;const s=a.protocol==="https:";if(i){r=s?d.httpsOverHttps:d.httpsOverHttp}else{r=s?d.httpOverHttps:d.httpOverHttp}t=r(e);this._proxyAgent=t}if(this._keepAlive&&!t){const e={keepAlive:this._keepAlive,maxSockets:n};t=i?new p.Agent(e):new o.Agent(e);this._agent=t}if(!t){t=i?p.globalAgent:o.globalAgent}if(i&&this._ignoreSslError){t.options=Object.assign(t.options||{},{rejectUnauthorized:false})}return t}_performExponentialBackoff(e){return s(this,void 0,void 0,(function*(){e=Math.min(v,e);const t=b*Math.pow(2,e);return new Promise((e=>setTimeout((()=>e()),t)))}))}_processResponse(e,t){return s(this,void 0,void 0,(function*(){return new Promise(((a,r)=>s(this,void 0,void 0,(function*(){const i=e.message.statusCode||0;const n={statusCode:i,result:null,headers:{}};if(i===c.NotFound){a(n)}function dateTimeDeserializer(e,t){if(typeof t==="string"){const e=new Date(t);if(!isNaN(e.valueOf())){return e}}return t}let s;let o;try{o=yield e.readBody();if(o&&o.length>0){if(t&&t.deserializeDates){s=JSON.parse(o,dateTimeDeserializer)}else{s=JSON.parse(o)}n.result=s}n.headers=e.message.headers}catch(e){}if(i>299){let e;if(s&&s.message){e=s.message}else if(o&&o.length>0){e=o}else{e=`Failed request: (${i})`}const t=new HttpClientError(e,i);t.result=n.result;r(t)}else{a(n)}}))))}))}}t.HttpClient=HttpClient;const lowercaseKeys=e=>Object.keys(e).reduce(((t,a)=>(t[a.toLowerCase()]=e[a],t)),{})},9835:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.checkBypass=t.getProxyUrl=void 0;function getProxyUrl(e){const t=e.protocol==="https:";if(checkBypass(e)){return undefined}const a=(()=>{if(t){return process.env["https_proxy"]||process.env["HTTPS_PROXY"]}else{return process.env["http_proxy"]||process.env["HTTP_PROXY"]}})();if(a){try{return new URL(a)}catch(e){if(!a.startsWith("http://")&&!a.startsWith("https://"))return new URL(`http://${a}`)}}else{return undefined}}t.getProxyUrl=getProxyUrl;function checkBypass(e){if(!e.hostname){return false}const t=e.hostname;if(isLoopbackAddress(t)){return true}const a=process.env["no_proxy"]||process.env["NO_PROXY"]||"";if(!a){return false}let r;if(e.port){r=Number(e.port)}else if(e.protocol==="http:"){r=80}else if(e.protocol==="https:"){r=443}const i=[e.hostname.toUpperCase()];if(typeof r==="number"){i.push(`${i[0]}:${r}`)}for(const e of a.split(",").map((e=>e.trim().toUpperCase())).filter((e=>e))){if(e==="*"||i.some((t=>t===e||t.endsWith(`.${e}`)||e.startsWith(".")&&t.endsWith(`${e}`)))){return true}}return false}t.checkBypass=checkBypass;function isLoopbackAddress(e){const t=e.toLowerCase();return t==="localhost"||t.startsWith("127.")||t.startsWith("[::1]")||t.startsWith("[0:0:0:0:0:0:0:1]")}},1962:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o;Object.defineProperty(t,"__esModule",{value:true});t.getCmdPath=t.tryGetExecutablePath=t.isRooted=t.isDirectory=t.exists=t.READONLY=t.UV_FS_O_EXLOCK=t.IS_WINDOWS=t.unlink=t.symlink=t.stat=t.rmdir=t.rm=t.rename=t.readlink=t.readdir=t.open=t.mkdir=t.lstat=t.copyFile=t.chmod=void 0;const p=n(a(7147));const l=n(a(1017));o=p.promises,t.chmod=o.chmod,t.copyFile=o.copyFile,t.lstat=o.lstat,t.mkdir=o.mkdir,t.open=o.open,t.readdir=o.readdir,t.readlink=o.readlink,t.rename=o.rename,t.rm=o.rm,t.rmdir=o.rmdir,t.stat=o.stat,t.symlink=o.symlink,t.unlink=o.unlink;t.IS_WINDOWS=process.platform==="win32";t.UV_FS_O_EXLOCK=268435456;t.READONLY=p.constants.O_RDONLY;function exists(e){return s(this,void 0,void 0,(function*(){try{yield t.stat(e)}catch(e){if(e.code==="ENOENT"){return false}throw e}return true}))}t.exists=exists;function isDirectory(e,a=false){return s(this,void 0,void 0,(function*(){const r=a?yield t.stat(e):yield t.lstat(e);return r.isDirectory()}))}t.isDirectory=isDirectory;function isRooted(e){e=normalizeSeparators(e);if(!e){throw new Error('isRooted() parameter "p" cannot be empty')}if(t.IS_WINDOWS){return e.startsWith("\\")||/^[A-Z]:/i.test(e)}return e.startsWith("/")}t.isRooted=isRooted;function tryGetExecutablePath(e,a){return s(this,void 0,void 0,(function*(){let r=undefined;try{r=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(r&&r.isFile()){if(t.IS_WINDOWS){const t=l.extname(e).toUpperCase();if(a.some((e=>e.toUpperCase()===t))){return e}}else{if(isUnixExecutable(r)){return e}}}const i=e;for(const n of a){e=i+n;r=undefined;try{r=yield t.stat(e)}catch(t){if(t.code!=="ENOENT"){console.log(`Unexpected error attempting to determine if executable file exists '${e}': ${t}`)}}if(r&&r.isFile()){if(t.IS_WINDOWS){try{const a=l.dirname(e);const r=l.basename(e).toUpperCase();for(const i of yield t.readdir(a)){if(r===i.toUpperCase()){e=l.join(a,i);break}}}catch(t){console.log(`Unexpected error attempting to determine the actual case of the file '${e}': ${t}`)}return e}else{if(isUnixExecutable(r)){return e}}}}return""}))}t.tryGetExecutablePath=tryGetExecutablePath;function normalizeSeparators(e){e=e||"";if(t.IS_WINDOWS){e=e.replace(/\//g,"\\");return e.replace(/\\\\+/g,"\\")}return e.replace(/\/\/+/g,"/")}function isUnixExecutable(e){return(e.mode&1)>0||(e.mode&8)>0&&e.gid===process.getgid()||(e.mode&64)>0&&e.uid===process.getuid()}function getCmdPath(){var e;return(e=process.env["COMSPEC"])!==null&&e!==void 0?e:`cmd.exe`}t.getCmdPath=getCmdPath},7436:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.findInPath=t.which=t.mkdirP=t.rmRF=t.mv=t.cp=void 0;const o=a(9491);const p=n(a(1017));const l=n(a(1962));function cp(e,t,a={}){return s(this,void 0,void 0,(function*(){const{force:r,recursive:i,copySourceDirectory:n}=readCopyOptions(a);const s=(yield l.exists(t))?yield l.stat(t):null;if(s&&s.isFile()&&!r){return}const o=s&&s.isDirectory()&&n?p.join(t,p.basename(e)):t;if(!(yield l.exists(e))){throw new Error(`no such file or directory: ${e}`)}const d=yield l.stat(e);if(d.isDirectory()){if(!i){throw new Error(`Failed to copy. ${e} is a directory, but tried to copy without recursive flag.`)}else{yield cpDirRecursive(e,o,0,r)}}else{if(p.relative(e,o)===""){throw new Error(`'${o}' and '${e}' are the same file`)}yield copyFile(e,o,r)}}))}t.cp=cp;function mv(e,t,a={}){return s(this,void 0,void 0,(function*(){if(yield l.exists(t)){let r=true;if(yield l.isDirectory(t)){t=p.join(t,p.basename(e));r=yield l.exists(t)}if(r){if(a.force==null||a.force){yield rmRF(t)}else{throw new Error("Destination already exists")}}}yield mkdirP(p.dirname(t));yield l.rename(e,t)}))}t.mv=mv;function rmRF(e){return s(this,void 0,void 0,(function*(){if(l.IS_WINDOWS){if(/[*"<>|]/.test(e)){throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows')}}try{yield l.rm(e,{force:true,maxRetries:3,recursive:true,retryDelay:300})}catch(e){throw new Error(`File was unable to be removed ${e}`)}}))}t.rmRF=rmRF;function mkdirP(e){return s(this,void 0,void 0,(function*(){o.ok(e,"a path argument must be provided");yield l.mkdir(e,{recursive:true})}))}t.mkdirP=mkdirP;function which(e,t){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}if(t){const t=yield which(e,false);if(!t){if(l.IS_WINDOWS){throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`)}else{throw new Error(`Unable to locate executable file: ${e}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`)}}return t}const a=yield findInPath(e);if(a&&a.length>0){return a[0]}return""}))}t.which=which;function findInPath(e){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'tool' is required")}const t=[];if(l.IS_WINDOWS&&process.env["PATHEXT"]){for(const e of process.env["PATHEXT"].split(p.delimiter)){if(e){t.push(e)}}}if(l.isRooted(e)){const a=yield l.tryGetExecutablePath(e,t);if(a){return[a]}return[]}if(e.includes(p.sep)){return[]}const a=[];if(process.env.PATH){for(const e of process.env.PATH.split(p.delimiter)){if(e){a.push(e)}}}const r=[];for(const i of a){const a=yield l.tryGetExecutablePath(p.join(i,e),t);if(a){r.push(a)}}return r}))}t.findInPath=findInPath;function readCopyOptions(e){const t=e.force==null?true:e.force;const a=Boolean(e.recursive);const r=e.copySourceDirectory==null?true:Boolean(e.copySourceDirectory);return{force:t,recursive:a,copySourceDirectory:r}}function cpDirRecursive(e,t,a,r){return s(this,void 0,void 0,(function*(){if(a>=255)return;a++;yield mkdirP(t);const i=yield l.readdir(e);for(const n of i){const i=`${e}/${n}`;const s=`${t}/${n}`;const o=yield l.lstat(i);if(o.isDirectory()){yield cpDirRecursive(i,s,a,r)}else{yield copyFile(i,s,r)}}yield l.chmod(t,(yield l.stat(e)).mode)}))}function copyFile(e,t,a){return s(this,void 0,void 0,(function*(){if((yield l.lstat(e)).isSymbolicLink()){try{yield l.lstat(t);yield l.unlink(t)}catch(e){if(e.code==="EPERM"){yield l.chmod(t,"0666");yield l.unlink(t)}}const a=yield l.readlink(e);yield l.symlink(a,t,l.IS_WINDOWS?"junction":null)}else if(!(yield l.exists(t))||a){yield l.copyFile(e,t)}}))}},2473:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t._readLinuxVersionFile=t._getOsVersion=t._findMatch=void 0;const o=n(a(5911));const p=a(2186);const l=a(2037);const d=a(2081);const c=a(7147);function _findMatch(t,a,r,i){return s(this,void 0,void 0,(function*(){const n=l.platform();let s;let d;let c;for(const s of r){const r=s.version;p.debug(`check ${r} satisfies ${t}`);if(o.satisfies(r,t)&&(!a||s.stable===a)){c=s.files.find((t=>{p.debug(`${t.arch}===${i} && ${t.platform}===${n}`);let a=t.arch===i&&t.platform===n;if(a&&t.platform_version){const r=e.exports._getOsVersion();if(r===t.platform_version){a=true}else{a=o.satisfies(r,t.platform_version)}}return a}));if(c){p.debug(`matched ${s.version}`);d=s;break}}}if(d&&c){s=Object.assign({},d);s.files=[c]}return s}))}t._findMatch=_findMatch;function _getOsVersion(){const t=l.platform();let a="";if(t==="darwin"){a=d.execSync("sw_vers -productVersion").toString()}else if(t==="linux"){const t=e.exports._readLinuxVersionFile();if(t){const e=t.split("\n");for(const t of e){const e=t.split("=");if(e.length===2&&(e[0].trim()==="VERSION_ID"||e[0].trim()==="DISTRIB_RELEASE")){a=e[1].trim().replace(/^"/,"").replace(/"$/,"");break}}}}return a}t._getOsVersion=_getOsVersion;function _readLinuxVersionFile(){const e="/etc/lsb-release";const t="/etc/os-release";let a="";if(c.existsSync(e)){a=c.readFileSync(e).toString()}else if(c.existsSync(t)){a=c.readFileSync(t).toString()}return a}t._readLinuxVersionFile=_readLinuxVersionFile},8279:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:true});t.RetryHelper=void 0;const o=n(a(2186));class RetryHelper{constructor(e,t,a){if(e<1){throw new Error("max attempts should be greater than or equal to 1")}this.maxAttempts=e;this.minSeconds=Math.floor(t);this.maxSeconds=Math.floor(a);if(this.minSeconds>this.maxSeconds){throw new Error("min seconds should be less than or equal to max seconds")}}execute(e,t){return s(this,void 0,void 0,(function*(){let a=1;while(asetTimeout(t,e*1e3)))}))}}t.RetryHelper=RetryHelper},7784:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var n=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.hasOwnProperty.call(e,a))r(t,e,a);i(t,e);return t};var s=this&&this.__awaiter||function(e,t,a,r){function adopt(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,i){function fulfilled(e){try{step(r.next(e))}catch(e){i(e)}}function rejected(e){try{step(r["throw"](e))}catch(e){i(e)}}function step(e){e.done?a(e.value):adopt(e.value).then(fulfilled,rejected)}step((r=r.apply(e,t||[])).next())}))};var o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.evaluateVersions=t.isExplicitVersion=t.findFromManifest=t.getManifestFromRepo=t.findAllVersions=t.find=t.cacheFile=t.cacheDir=t.extractZip=t.extractXar=t.extractTar=t.extract7z=t.downloadTool=t.HTTPError=void 0;const p=n(a(2186));const l=n(a(7436));const d=n(a(7147));const c=n(a(2473));const m=n(a(2037));const u=n(a(1017));const h=n(a(6255));const g=n(a(5911));const y=n(a(2781));const v=n(a(3837));const b=a(9491);const x=o(a(7468));const w=a(1514);const S=a(8279);class HTTPError extends Error{constructor(e){super(`Unexpected HTTP response: ${e}`);this.httpStatusCode=e;Object.setPrototypeOf(this,new.target.prototype)}}t.HTTPError=HTTPError;const N=process.platform==="win32";const T=process.platform==="darwin";const E="actions/tool-cache";function downloadTool(e,t,a,r){return s(this,void 0,void 0,(function*(){t=t||u.join(_getTempDirectory(),x.default());yield l.mkdirP(u.dirname(t));p.debug(`Downloading ${e}`);p.debug(`Destination ${t}`);const i=3;const n=_getGlobal("TEST_DOWNLOAD_TOOL_RETRY_MIN_SECONDS",10);const o=_getGlobal("TEST_DOWNLOAD_TOOL_RETRY_MAX_SECONDS",20);const d=new S.RetryHelper(i,n,o);return yield d.execute((()=>s(this,void 0,void 0,(function*(){return yield downloadToolAttempt(e,t||"",a,r)}))),(e=>{if(e instanceof HTTPError&&e.httpStatusCode){if(e.httpStatusCode<500&&e.httpStatusCode!==408&&e.httpStatusCode!==429){return false}}return true}))}))}t.downloadTool=downloadTool;function downloadToolAttempt(e,t,a,r){return s(this,void 0,void 0,(function*(){if(d.existsSync(t)){throw new Error(`Destination file path ${t} already exists`)}const i=new h.HttpClient(E,[],{allowRetries:false});if(a){p.debug("set auth");if(r===undefined){r={}}r.authorization=a}const n=yield i.get(e,r);if(n.message.statusCode!==200){const t=new HTTPError(n.message.statusCode);p.debug(`Failed to download from "${e}". Code(${n.message.statusCode}) Message(${n.message.statusMessage})`);throw t}const s=v.promisify(y.pipeline);const o=_getGlobal("TEST_DOWNLOAD_TOOL_RESPONSE_MESSAGE_FACTORY",(()=>n.message));const c=o();let m=false;try{yield s(c,d.createWriteStream(t));p.debug("download complete");m=true;return t}finally{if(!m){p.debug("download failed");try{yield l.rmRF(t)}catch(e){p.debug(`Failed to delete '${t}'. ${e.message}`)}}}}))}function extract7z(e,t,a){return s(this,void 0,void 0,(function*(){b.ok(N,"extract7z() not supported on current OS");b.ok(e,'parameter "file" is required');t=yield _createExtractFolder(t);const r=process.cwd();process.chdir(t);if(a){try{const t=p.isDebug()?"-bb1":"-bb0";const i=["x",t,"-bd","-sccUTF-8",e];const n={silent:true};yield w.exec(`"${a}"`,i,n)}finally{process.chdir(r)}}else{const a=u.join(__dirname,"..","scripts","Invoke-7zdec.ps1").replace(/'/g,"''").replace(/"|\n|\r/g,"");const i=e.replace(/'/g,"''").replace(/"|\n|\r/g,"");const n=t.replace(/'/g,"''").replace(/"|\n|\r/g,"");const s=`& '${a}' -Source '${i}' -Target '${n}'`;const o=["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",s];const p={silent:true};try{const e=yield l.which("powershell",true);yield w.exec(`"${e}"`,o,p)}finally{process.chdir(r)}}return t}))}t.extract7z=extract7z;function extractTar(e,t,a="xz"){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'file' is required")}t=yield _createExtractFolder(t);p.debug("Checking tar --version");let r="";yield w.exec("tar --version",[],{ignoreReturnCode:true,silent:true,listeners:{stdout:e=>r+=e.toString(),stderr:e=>r+=e.toString()}});p.debug(r.trim());const i=r.toUpperCase().includes("GNU TAR");let n;if(a instanceof Array){n=a}else{n=[a]}if(p.isDebug()&&!a.includes("v")){n.push("-v")}let s=t;let o=e;if(N&&i){n.push("--force-local");s=t.replace(/\\/g,"/");o=e.replace(/\\/g,"/")}if(i){n.push("--warning=no-unknown-keyword");n.push("--overwrite")}n.push("-C",s,"-f",o);yield w.exec(`tar`,n);return t}))}t.extractTar=extractTar;function extractXar(e,t,a=[]){return s(this,void 0,void 0,(function*(){b.ok(T,"extractXar() not supported on current OS");b.ok(e,'parameter "file" is required');t=yield _createExtractFolder(t);let r;if(a instanceof Array){r=a}else{r=[a]}r.push("-x","-C",t,"-f",e);if(p.isDebug()){r.push("-v")}const i=yield l.which("xar",true);yield w.exec(`"${i}"`,_unique(r));return t}))}t.extractXar=extractXar;function extractZip(e,t){return s(this,void 0,void 0,(function*(){if(!e){throw new Error("parameter 'file' is required")}t=yield _createExtractFolder(t);if(N){yield extractZipWin(e,t)}else{yield extractZipNix(e,t)}return t}))}t.extractZip=extractZip;function extractZipWin(e,t){return s(this,void 0,void 0,(function*(){const a=e.replace(/'/g,"''").replace(/"|\n|\r/g,"");const r=t.replace(/'/g,"''").replace(/"|\n|\r/g,"");const i=yield l.which("pwsh",false);if(i){const e=[`$ErrorActionPreference = 'Stop' ;`,`try { Add-Type -AssemblyName System.IO.Compression.ZipFile } catch { } ;`,`try { [System.IO.Compression.ZipFile]::ExtractToDirectory('${a}', '${r}', $true) }`,`catch { if (($_.Exception.GetType().FullName -eq 'System.Management.Automation.MethodException') -or ($_.Exception.GetType().FullName -eq 'System.Management.Automation.RuntimeException') ){ Expand-Archive -LiteralPath '${a}' -DestinationPath '${r}' -Force } else { throw $_ } } ;`].join(" ");const t=["-NoLogo","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",e];p.debug(`Using pwsh at path: ${i}`);yield w.exec(`"${i}"`,t)}else{const e=[`$ErrorActionPreference = 'Stop' ;`,`try { Add-Type -AssemblyName System.IO.Compression.FileSystem } catch { } ;`,`if ((Get-Command -Name Expand-Archive -Module Microsoft.PowerShell.Archive -ErrorAction Ignore)) { Expand-Archive -LiteralPath '${a}' -DestinationPath '${r}' -Force }`,`else {[System.IO.Compression.ZipFile]::ExtractToDirectory('${a}', '${r}', $true) }`].join(" ");const t=["-NoLogo","-Sta","-NoProfile","-NonInteractive","-ExecutionPolicy","Unrestricted","-Command",e];const i=yield l.which("powershell",true);p.debug(`Using powershell at path: ${i}`);yield w.exec(`"${i}"`,t)}}))}function extractZipNix(e,t){return s(this,void 0,void 0,(function*(){const a=yield l.which("unzip",true);const r=[e];if(!p.isDebug()){r.unshift("-q")}r.unshift("-o");yield w.exec(`"${a}"`,r,{cwd:t})}))}function cacheDir(e,t,a,r){return s(this,void 0,void 0,(function*(){a=g.clean(a)||a;r=r||m.arch();p.debug(`Caching tool ${t} ${a} ${r}`);p.debug(`source dir: ${e}`);if(!d.statSync(e).isDirectory()){throw new Error("sourceDir is not a directory")}const i=yield _createToolPath(t,a,r);for(const t of d.readdirSync(e)){const a=u.join(e,t);yield l.cp(a,i,{recursive:true})}_completeToolPath(t,a,r);return i}))}t.cacheDir=cacheDir;function cacheFile(e,t,a,r,i){return s(this,void 0,void 0,(function*(){r=g.clean(r)||r;i=i||m.arch();p.debug(`Caching tool ${a} ${r} ${i}`);p.debug(`source file: ${e}`);if(!d.statSync(e).isFile()){throw new Error("sourceFile is not a file")}const n=yield _createToolPath(a,r,i);const s=u.join(n,t);p.debug(`destination file ${s}`);yield l.cp(e,s);_completeToolPath(a,r,i);return n}))}t.cacheFile=cacheFile;function find(e,t,a){if(!e){throw new Error("toolName parameter is required")}if(!t){throw new Error("versionSpec parameter is required")}a=a||m.arch();if(!isExplicitVersion(t)){const r=findAllVersions(e,a);const i=evaluateVersions(r,t);t=i}let r="";if(t){t=g.clean(t)||"";const i=u.join(_getCacheDirectory(),e,t,a);p.debug(`checking cache: ${i}`);if(d.existsSync(i)&&d.existsSync(`${i}.complete`)){p.debug(`Found tool in cache ${e} ${t} ${a}`);r=i}else{p.debug("not found")}}return r}t.find=find;function findAllVersions(e,t){const a=[];t=t||m.arch();const r=u.join(_getCacheDirectory(),e);if(d.existsSync(r)){const e=d.readdirSync(r);for(const i of e){if(isExplicitVersion(i)){const e=u.join(r,i,t||"");if(d.existsSync(e)&&d.existsSync(`${e}.complete`)){a.push(i)}}}}return a}t.findAllVersions=findAllVersions;function getManifestFromRepo(e,t,a,r="master"){return s(this,void 0,void 0,(function*(){let i=[];const n=`https://api.github.com/repos/${e}/${t}/git/trees/${r}`;const s=new h.HttpClient("tool-cache");const o={};if(a){p.debug("set auth");o.authorization=a}const l=yield s.getJson(n,o);if(!l.result){return i}let d="";for(const e of l.result.tree){if(e.path==="versions-manifest.json"){d=e.url;break}}o["accept"]="application/vnd.github.VERSION.raw";let c=yield(yield s.get(d,o)).readBody();if(c){c=c.replace(/^\uFEFF/,"");try{i=JSON.parse(c)}catch(e){p.debug("Invalid json")}}return i}))}t.getManifestFromRepo=getManifestFromRepo;function findFromManifest(e,t,a,r=m.arch()){return s(this,void 0,void 0,(function*(){const i=yield c._findMatch(e,t,a,r);return i}))}t.findFromManifest=findFromManifest;function _createExtractFolder(e){return s(this,void 0,void 0,(function*(){if(!e){e=u.join(_getTempDirectory(),x.default())}yield l.mkdirP(e);return e}))}function _createToolPath(e,t,a){return s(this,void 0,void 0,(function*(){const r=u.join(_getCacheDirectory(),e,g.clean(t)||t,a||"");p.debug(`destination ${r}`);const i=`${r}.complete`;yield l.rmRF(r);yield l.rmRF(i);yield l.mkdirP(r);return r}))}function _completeToolPath(e,t,a){const r=u.join(_getCacheDirectory(),e,g.clean(t)||t,a||"");const i=`${r}.complete`;d.writeFileSync(i,"");p.debug("finished caching tool")}function isExplicitVersion(e){const t=g.clean(e)||"";p.debug(`isExplicit: ${t}`);const a=g.valid(t)!=null;p.debug(`explicit? ${a}`);return a}t.isExplicitVersion=isExplicitVersion;function evaluateVersions(e,t){let a="";p.debug(`evaluating ${e.length} versions`);e=e.sort(((e,t)=>{if(g.gt(e,t)){return 1}return-1}));for(let r=e.length-1;r>=0;r--){const i=e[r];const n=g.satisfies(i,t);if(n){a=i;break}}if(a){p.debug(`matched: ${a}`)}else{p.debug("match not found")}return a}t.evaluateVersions=evaluateVersions;function _getCacheDirectory(){const e=process.env["RUNNER_TOOL_CACHE"]||"";b.ok(e,"Expected RUNNER_TOOL_CACHE to be defined");return e}function _getTempDirectory(){const e=process.env["RUNNER_TEMP"]||"";b.ok(e,"Expected RUNNER_TEMP to be defined");return e}function _getGlobal(e,t){const a=global[e];return a!==undefined?a:t}function _unique(e){return Array.from(new Set(e))}},7701:e=>{var t=[];for(var a=0;a<256;++a){t[a]=(a+256).toString(16).substr(1)}function bytesToUuid(e,a){var r=a||0;var i=t;return[i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]]].join("")}e.exports=bytesToUuid},7269:(e,t,a)=>{var r=a(6113);e.exports=function nodeRNG(){return r.randomBytes(16)}},7468:(e,t,a)=>{var r=a(7269);var i=a(7701);function v4(e,t,a){var n=t&&a||0;if(typeof e=="string"){t=e==="binary"?new Array(16):null;e=null}e=e||{};var s=e.random||(e.rng||r)();s[6]=s[6]&15|64;s[8]=s[8]&63|128;if(t){for(var o=0;o<16;++o){t[n+o]=s[o]}}return t||i(s)}e.exports=v4},2557:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a=new WeakMap;const r=new WeakMap;class AbortSignal{constructor(){this.onabort=null;a.set(this,[]);r.set(this,false)}get aborted(){if(!r.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}return r.get(this)}static get none(){return new AbortSignal}addEventListener(e,t){if(!a.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}const r=a.get(this);r.push(t)}removeEventListener(e,t){if(!a.has(this)){throw new TypeError("Expected `this` to be an instance of AbortSignal.")}const r=a.get(this);const i=r.indexOf(t);if(i>-1){r.splice(i,1)}}dispatchEvent(e){throw new Error("This is a stub dispatchEvent implementation that should not be used. It only exists for type-checking purposes.")}}function abortSignal(e){if(e.aborted){return}if(e.onabort){e.onabort.call(e)}const t=a.get(e);if(t){t.slice().forEach((t=>{t.call(e,{type:"abort"})}))}r.set(e,true)}class AbortError extends Error{constructor(e){super(e);this.name="AbortError"}}class AbortController{constructor(e){this._signal=new AbortSignal;if(!e){return}if(!Array.isArray(e)){e=arguments}for(const t of e){if(t.aborted){this.abort()}else{t.addEventListener("abort",(()=>{this.abort()}))}}}get signal(){return this._signal}abort(){abortSignal(this._signal)}static timeout(e){const t=new AbortSignal;const a=setTimeout(abortSignal,e,t);if(typeof a.unref==="function"){a.unref()}return t}}t.AbortController=AbortController;t.AbortError=AbortError;t.AbortSignal=AbortSignal},9645:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(1333);class AzureKeyCredential{get key(){return this._key}constructor(e){if(!e){throw new Error("key must be a non-empty string")}this._key=e}update(e){this._key=e}}class AzureNamedKeyCredential{get key(){return this._key}get name(){return this._name}constructor(e,t){if(!e||!t){throw new TypeError("name and key must be non-empty strings")}this._name=e;this._key=t}update(e,t){if(!e||!t){throw new TypeError("newName and newKey must be non-empty strings")}this._name=e;this._key=t}}function isNamedKeyCredential(e){return r.isObjectWithProperties(e,["name","key"])&&typeof e.key==="string"&&typeof e.name==="string"}class AzureSASCredential{get signature(){return this._signature}constructor(e){if(!e){throw new Error("shared access signature must be a non-empty string")}this._signature=e}update(e){if(!e){throw new Error("shared access signature must be a non-empty string")}this._signature=e}}function isSASCredential(e){return r.isObjectWithProperties(e,["signature"])&&typeof e.signature==="string"}function isTokenCredential(e){const t=e;return t&&typeof t.getToken==="function"&&(t.signRequest===undefined||t.getToken.length>0)}t.AzureKeyCredential=AzureKeyCredential;t.AzureNamedKeyCredential=AzureNamedKeyCredential;t.AzureSASCredential=AzureSASCredential;t.isNamedKeyCredential=isNamedKeyCredential;t.isSASCredential=isSASCredential;t.isTokenCredential=isTokenCredential},4607:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5840);var i=a(3837);var n=a(2107);var s=a(6189);var o=a(1333);var p=a(3233);var l=a(9645);var d=a(2037);var c=a(3685);var m=a(5687);var u=a(2557);var h=a(4294);var g=a(2781);var y=a(6279);var v=a(467);var b=a(4175);function _interopDefaultLegacy(e){return e&&typeof e==="object"&&"default"in e?e:{default:e}}function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(a){if(a!=="default"){var r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:true,get:function(){return e[a]}})}}))}t["default"]=e;return Object.freeze(t)}var x=_interopNamespace(s);var w=_interopNamespace(d);var S=_interopNamespace(c);var N=_interopNamespace(m);var T=_interopNamespace(h);var E=_interopDefaultLegacy(y);var _=_interopDefaultLegacy(v);function getHeaderKey(e){return e.toLowerCase()}function isHttpHeadersLike(e){if(e&&typeof e==="object"){const t=e;if(typeof t.rawHeaders==="function"&&typeof t.clone==="function"&&typeof t.get==="function"&&typeof t.set==="function"&&typeof t.contains==="function"&&typeof t.remove==="function"&&typeof t.headersArray==="function"&&typeof t.headerValues==="function"&&typeof t.headerNames==="function"&&typeof t.toJson==="function"){return true}}return false}class HttpHeaders{constructor(e){this._headersMap={};if(e){for(const t in e){this.set(t,e[t])}}}set(e,t){this._headersMap[getHeaderKey(e)]={name:e,value:t.toString()}}get(e){const t=this._headersMap[getHeaderKey(e)];return!t?undefined:t.value}contains(e){return!!this._headersMap[getHeaderKey(e)]}remove(e){const t=this.contains(e);delete this._headersMap[getHeaderKey(e)];return t}rawHeaders(){return this.toJson({preserveCase:true})}headersArray(){const e=[];for(const t in this._headersMap){e.push(this._headersMap[t])}return e}headerNames(){const e=[];const t=this.headersArray();for(let a=0;a{a=a.then(e)}));return a}function promiseToCallback(e){if(typeof e.then!=="function"){throw new Error("The provided input is not a Promise.")}return t=>{e.then((e=>t(undefined,e))).catch((e=>{t(e)}))}}function promiseToServiceCallback(e){if(typeof e.then!=="function"){throw new Error("The provided input is not a Promise.")}return t=>{e.then((e=>process.nextTick(t,undefined,e.parsedBody,e.request,e))).catch((e=>{process.nextTick(t,e)}))}}function prepareXMLRootList(e,t,a,r){if(!Array.isArray(e)){e=[e]}if(!a||!r){return{[t]:e}}const i={[t]:e};i[C]={[a]:r};return i}function applyMixins(e,t){const a=e;t.forEach((e=>{Object.getOwnPropertyNames(e.prototype).forEach((t=>{a.prototype[t]=e.prototype[t]}))}))}const D=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function isDuration(e){return D.test(e)}function replaceAll(e,t,a){return!e||!t?e:e.split(t).join(a||"")}function isPrimitiveType(e){return typeof e!=="object"&&typeof e!=="function"||e===null}function getEnvironmentValue(e){if(process.env[e]){return process.env[e]}else if(process.env[e.toLowerCase()]){return process.env[e.toLowerCase()]}return undefined}function isObject(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}class Serializer{constructor(e={},t){this.modelMappers=e;this.isXML=t}validateConstraints(e,t,a){const failValidation=(e,r)=>{throw new Error(`"${a}" with value "${t}" should satisfy the constraint "${e}": ${r}.`)};if(e.constraints&&t!=undefined){const a=t;const{ExclusiveMaximum:r,ExclusiveMinimum:i,InclusiveMaximum:n,InclusiveMinimum:s,MaxItems:o,MaxLength:p,MinItems:l,MinLength:d,MultipleOf:c,Pattern:m,UniqueItems:u}=e.constraints;if(r!=undefined&&a>=r){failValidation("ExclusiveMaximum",r)}if(i!=undefined&&a<=i){failValidation("ExclusiveMinimum",i)}if(n!=undefined&&a>n){failValidation("InclusiveMaximum",n)}if(s!=undefined&&ao){failValidation("MaxItems",o)}if(p!=undefined&&h.length>p){failValidation("MaxLength",p)}if(l!=undefined&&h.lengtha.indexOf(e)!==t))){failValidation("UniqueItems",u)}}}serialize(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};let p={};const l=e.type.name;if(!a){a=e.serializedName}if(l.match(/^Sequence$/i)!==null){p=[]}if(e.isConstant){t=e.defaultValue}const{required:d,nullable:c}=e;if(d&&c&&t===undefined){throw new Error(`${a} cannot be undefined.`)}if(d&&!c&&t==undefined){throw new Error(`${a} cannot be null or undefined.`)}if(!d&&c===false&&t===null){throw new Error(`${a} cannot be null.`)}if(t==undefined){p=t}else{if(l.match(/^any$/i)!==null){p=t}else if(l.match(/^(Number|String|Boolean|Object|Stream|Uuid)$/i)!==null){p=serializeBasicTypes(l,a,t)}else if(l.match(/^Enum$/i)!==null){const r=e;p=serializeEnumType(a,r.type.allowedValues,t)}else if(l.match(/^(Date|DateTime|TimeSpan|DateTimeRfc1123|UnixTime)$/i)!==null){p=serializeDateTypes(l,t,a)}else if(l.match(/^ByteArray$/i)!==null){p=serializeByteArrayType(a,t)}else if(l.match(/^Base64Url$/i)!==null){p=serializeBase64UrlType(a,t)}else if(l.match(/^Sequence$/i)!==null){p=serializeSequenceType(this,e,t,a,Boolean(this.isXML),o)}else if(l.match(/^Dictionary$/i)!==null){p=serializeDictionaryType(this,e,t,a,Boolean(this.isXML),o)}else if(l.match(/^Composite$/i)!==null){p=serializeCompositeType(this,e,t,a,Boolean(this.isXML),o)}}return p}deserialize(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};if(t==undefined){if(this.isXML&&e.type.name==="Sequence"&&!e.xmlIsWrapped){t=[]}if(e.defaultValue!==undefined){t=e.defaultValue}return t}let p;const l=e.type.name;if(!a){a=e.serializedName}if(l.match(/^Composite$/i)!==null){p=deserializeCompositeType(this,e,t,a,o)}else{if(this.isXML){const e=o.xmlCharKey;const a=t;if(a[C]!=undefined&&a[e]!=undefined){t=a[e]}}if(l.match(/^Number$/i)!==null){p=parseFloat(t);if(isNaN(p)){p=t}}else if(l.match(/^Boolean$/i)!==null){if(t==="true"){p=true}else if(t==="false"){p=false}else{p=t}}else if(l.match(/^(String|Enum|Object|Stream|Uuid|TimeSpan|any)$/i)!==null){p=t}else if(l.match(/^(Date|DateTime|DateTimeRfc1123)$/i)!==null){p=new Date(t)}else if(l.match(/^UnixTime$/i)!==null){p=unixTimeToDate(t)}else if(l.match(/^ByteArray$/i)!==null){p=decodeString(t)}else if(l.match(/^Base64Url$/i)!==null){p=base64UrlToByteArray(t)}else if(l.match(/^Sequence$/i)!==null){p=deserializeSequenceType(this,e,t,a,o)}else if(l.match(/^Dictionary$/i)!==null){p=deserializeDictionaryType(this,e,t,a,o)}}if(e.isConstant){p=e.defaultValue}return p}}function trimEnd(e,t){let a=e.length;while(a-1>=0&&e[a-1]===t){--a}return e.substr(0,a)}function bufferToBase64Url(e){if(!e){return undefined}if(!(e instanceof Uint8Array)){throw new Error(`Please provide an input of type Uint8Array for converting to Base64Url.`)}const t=encodeByteArray(e);return trimEnd(t,"=").replace(/\+/g,"-").replace(/\//g,"_")}function base64UrlToByteArray(e){if(!e){return undefined}if(e&&typeof e.valueOf()!=="string"){throw new Error("Please provide an input of type string for converting to Uint8Array")}e=e.replace(/-/g,"+").replace(/_/g,"/");return decodeString(e)}function splitSerializeName(e){const t=[];let a="";if(e){const r=e.split(".");for(const e of r){if(e.charAt(e.length-1)==="\\"){a+=e.substr(0,e.length-1)+"."}else{a+=e;t.push(a);a=""}}}return t}function dateToUnixTime(e){if(!e){return undefined}if(typeof e.valueOf()==="string"){e=new Date(e)}return Math.floor(e.getTime()/1e3)}function unixTimeToDate(e){if(!e){return undefined}return new Date(e*1e3)}function serializeBasicTypes(e,t,a){if(a!==null&&a!==undefined){if(e.match(/^Number$/i)!==null){if(typeof a!=="number"){throw new Error(`${t} with value ${a} must be of type number.`)}}else if(e.match(/^String$/i)!==null){if(typeof a.valueOf()!=="string"){throw new Error(`${t} with value "${a}" must be of type string.`)}}else if(e.match(/^Uuid$/i)!==null){if(!(typeof a.valueOf()==="string"&&isValidUuid(a))){throw new Error(`${t} with value "${a}" must be of type string and a valid uuid.`)}}else if(e.match(/^Boolean$/i)!==null){if(typeof a!=="boolean"){throw new Error(`${t} with value ${a} must be of type boolean.`)}}else if(e.match(/^Stream$/i)!==null){const e=typeof a;if(e!=="string"&&e!=="function"&&!(a instanceof ArrayBuffer)&&!ArrayBuffer.isView(a)&&!((typeof Blob==="function"||typeof Blob==="object")&&a instanceof Blob)){throw new Error(`${t} must be a string, Blob, ArrayBuffer, ArrayBufferView, or a function returning NodeJS.ReadableStream.`)}}}return a}function serializeEnumType(e,t,a){if(!t){throw new Error(`Please provide a set of allowedValues to validate ${e} as an Enum Type.`)}const r=t.some((e=>{if(typeof e.valueOf()==="string"){return e.toLowerCase()===a.toLowerCase()}return e===a}));if(!r){throw new Error(`${a} is not a valid value for ${e}. The valid values are: ${JSON.stringify(t)}.`)}return a}function serializeByteArrayType(e,t){let a="";if(t!=undefined){if(!(t instanceof Uint8Array)){throw new Error(`${e} must be of type Uint8Array.`)}a=encodeByteArray(t)}return a}function serializeBase64UrlType(e,t){let a="";if(t!=undefined){if(!(t instanceof Uint8Array)){throw new Error(`${e} must be of type Uint8Array.`)}a=bufferToBase64Url(t)||""}return a}function serializeDateTypes(e,t,a){if(t!=undefined){if(e.match(/^Date$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in ISO8601 format.`)}t=t instanceof Date?t.toISOString().substring(0,10):new Date(t).toISOString().substring(0,10)}else if(e.match(/^DateTime$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in ISO8601 format.`)}t=t instanceof Date?t.toISOString():new Date(t).toISOString()}else if(e.match(/^DateTimeRfc1123$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in RFC-1123 format.`)}t=t instanceof Date?t.toUTCString():new Date(t).toUTCString()}else if(e.match(/^UnixTime$/i)!==null){if(!(t instanceof Date||typeof t.valueOf()==="string"&&!isNaN(Date.parse(t)))){throw new Error(`${a} must be an instanceof Date or a string in RFC-1123/ISO8601 format `+`for it to be serialized in UnixTime/Epoch format.`)}t=dateToUnixTime(t)}else if(e.match(/^TimeSpan$/i)!==null){if(!isDuration(t)){throw new Error(`${a} must be a string in ISO 8601 format. Instead was "${t}".`)}}}return t}function serializeSequenceType(e,t,a,r,i,n){if(!Array.isArray(a)){throw new Error(`${r} must be of type Array.`)}const s=t.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 ${r}.`)}const o=[];for(let t=0;te!==i));if(o){s[i]=e.serialize(p,a[i],r+'["'+i+'"]',n)}}}return s}return a}function getXmlObjectValue(e,t,a,r){if(!a||!e.xmlNamespace){return t}const i=e.xmlNamespacePrefix?`xmlns:${e.xmlNamespacePrefix}`:"xmlns";const n={[i]:e.xmlNamespace};if(["Composite"].includes(e.type.name)){if(t[C]){return t}else{const e=Object.assign({},t);e[C]=n;return e}}const s={};s[r.xmlCharKey]=t;s[C]=n;return s}function isSpecialXmlProperty(e,t){return[C,t.xmlCharKey].includes(e)}function deserializeCompositeType(e,t,a,r,i){var n,s;const o=(n=i.xmlCharKey)!==null&&n!==void 0?n:O;if(getPolymorphicDiscriminatorRecursively(e,t)){t=getPolymorphicMapper(e,t,a,"serializedName")}const p=resolveModelProperties(e,t,r);let l={};const d=[];for(const n of Object.keys(p)){const c=p[n];const m=splitSerializeName(p[n].serializedName);d.push(m[0]);const{serializedName:u,xmlName:h,xmlElementName:g}=c;let y=r;if(u!==""&&u!==undefined){y=r+"."+u}const v=c.headerCollectionPrefix;if(v){const t={};for(const r of Object.keys(a)){if(r.startsWith(v)){t[r.substring(v.length)]=e.deserialize(c.type.value,a[r],y,i)}d.push(r)}l[n]=t}else if(e.isXML){if(c.xmlIsAttribute&&a[C]){l[n]=e.deserialize(c,a[C][h],y,i)}else if(c.xmlIsMsText){if(a[o]!==undefined){l[n]=a[o]}else if(typeof a==="string"){l[n]=a}}else{const t=g||h||u;if(c.xmlIsWrapped){const t=a[h];const r=(s=t===null||t===void 0?void 0:t[g])!==null&&s!==void 0?s:[];l[n]=e.deserialize(c,r,y,i);d.push(h)}else{const r=a[t];l[n]=e.deserialize(c,r,y,i);d.push(t)}}}else{let r;let s=a;for(const e of m){if(!s)break;s=s[e]}r=s;const o=t.type.polymorphicDiscriminator;if(o&&n===o.clientName&&r==undefined){r=t.serializedName}let d;if(Array.isArray(a[n])&&p[n].serializedName===""){r=a[n];const t=e.deserialize(c,r,y,i);for(const[e,a]of Object.entries(l)){if(!Object.prototype.hasOwnProperty.call(t,e)){t[e]=a}}l=t}else if(r!==undefined||c.defaultValue!==undefined){d=e.deserialize(c,r,y,i);l[n]=d}}}const c=t.type.additionalProperties;if(c){const isAdditionalProperty=e=>{for(const t in p){const a=splitSerializeName(p[t].serializedName);if(a[0]===e){return false}}return true};for(const t in a){if(isAdditionalProperty(t)){l[t]=e.deserialize(c,a[t],r+'["'+t+'"]',i)}}}else if(a){for(const e of Object.keys(a)){if(l[e]===undefined&&!d.includes(e)&&!isSpecialXmlProperty(e,i)){l[e]=a[e]}}}return l}function deserializeDictionaryType(e,t,a,r,i){const n=t.type.value;if(!n||typeof n!=="object"){throw new Error(`"value" metadata for a Dictionary must be defined in the `+`mapper and it must of type "object" in ${r}`)}if(a){const t={};for(const s of Object.keys(a)){t[s]=e.deserialize(n,a[s],r,i)}return t}return a}function deserializeSequenceType(e,t,a,r,i){const n=t.type.element;if(!n||typeof n!=="object"){throw new Error(`element" metadata for an Array must be defined in the `+`mapper and it must of type "object" in ${r}`)}if(a){if(!Array.isArray(a)){a=[a]}const t=[];for(let s=0;s0}keys(){return Object.keys(this._rawQuery)}set(e,t){const a=t;if(e){if(a!==undefined&&a!==null){const t=Array.isArray(a)?a:a.toString();this._rawQuery[e]=t}else{delete this._rawQuery[e]}}}get(e){return e?this._rawQuery[e]:undefined}toString(){let e="";for(const t in this._rawQuery){if(e){e+="&"}const a=this._rawQuery[t];if(Array.isArray(a)){const r=[];for(const e of a){r.push(`${t}=${e}`)}e+=r.join("&")}else{e+=`${t}=${a}`}}return e}static parse(e){const t=new URLQuery;if(e){if(e.startsWith("?")){e=e.substring(1)}let a="ParameterName";let r="";let i="";for(let n=0;nisAlphaNumericCharacter(e)))}function readUntilCharacter(e,...t){return readWhile(e,(e=>t.indexOf(e)===-1))}function nextScheme(e){const t=readWhileLetterOrDigit(e);e._currentToken=URLToken.scheme(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else{e._currentState="HOST"}}function nextSchemeOrHost(e){const t=readUntilCharacter(e,":","/","?");if(!hasCurrentCharacter(e)){e._currentToken=URLToken.host(t);e._currentState="DONE"}else if(getCurrentCharacter(e)===":"){if(peekCharacters(e,3)==="://"){e._currentToken=URLToken.scheme(t);e._currentState="HOST"}else{e._currentToken=URLToken.host(t);e._currentState="PORT"}}else{e._currentToken=URLToken.host(t);if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}}function nextHost(e){if(peekCharacters(e,3)==="://"){nextCharacter(e,3)}const t=readUntilCharacter(e,":","/","?");e._currentToken=URLToken.host(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else if(getCurrentCharacter(e)===":"){e._currentState="PORT"}else if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}function nextPort(e){if(getCurrentCharacter(e)===":"){nextCharacter(e)}const t=readUntilCharacter(e,"/","?");e._currentToken=URLToken.port(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else if(getCurrentCharacter(e)==="/"){e._currentState="PATH"}else{e._currentState="QUERY"}}function nextPath(e){const t=readUntilCharacter(e,"?");e._currentToken=URLToken.path(t);if(!hasCurrentCharacter(e)){e._currentState="DONE"}else{e._currentState="QUERY"}}function nextQuery(e){if(getCurrentCharacter(e)==="?"){nextCharacter(e)}const t=readRemaining(e);e._currentToken=URLToken.query(t);e._currentState="DONE"}function createProxyAgent(e,t,a){const r=URLBuilder.parse(t.host).getHost();if(!r){throw new Error("Expecting a non-empty host in proxy settings.")}if(!isValidPort(t.port)){throw new Error("Expecting a valid port number in the range of [0, 65535] in proxy settings.")}const i={proxy:{host:r,port:t.port,headers:a&&a.rawHeaders()||{}}};if(t.username&&t.password){i.proxy.proxyAuth=`${t.username}:${t.password}`}else if(t.username){i.proxy.proxyAuth=`${t.username}`}const n=isUrlHttps(e);const s=isUrlHttps(t.host);const o={isHttps:n,agent:createTunnel(n,s,i)};return o}function isUrlHttps(e){const t=URLBuilder.parse(e).getScheme()||"";return t.toLowerCase()==="https"}function createTunnel(e,t,a){if(e&&t){return T.httpsOverHttps(a)}else if(e&&!t){return T.httpsOverHttp(a)}else if(!e&&t){return T.httpOverHttps(a)}else{return T.httpOverHttp(a)}}function isValidPort(e){return 0<=e&&e<=65535}const I="REDACTED";const L=["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","WWW-Authenticate"];const M=["api-version"];class Sanitizer{constructor({allowedHeaderNames:e=[],allowedQueryParameters:t=[]}={}){e=Array.isArray(e)?L.concat(e):L;t=Array.isArray(t)?M.concat(t):M;this.allowedHeaderNames=new Set(e.map((e=>e.toLowerCase())));this.allowedQueryParameters=new Set(t.map((e=>e.toLowerCase())))}sanitize(e){const t=new Set;return JSON.stringify(e,((e,a)=>{if(a instanceof Error){return Object.assign(Object.assign({},a),{name:a.name,message:a.message})}if(e==="_headersMap"){return this.sanitizeHeaders(a)}else if(e==="url"){return this.sanitizeUrl(a)}else if(e==="query"){return this.sanitizeQuery(a)}else if(e==="body"){return undefined}else if(e==="response"){return undefined}else if(e==="operationSpec"){return undefined}else if(Array.isArray(a)||isObject(a)){if(t.has(a)){return"[Circular]"}t.add(a)}return a}),2)}sanitizeHeaders(e){return this.sanitizeObject(e,this.allowedHeaderNames,((e,t)=>e[t].value))}sanitizeQuery(e){return this.sanitizeObject(e,this.allowedQueryParameters,((e,t)=>e[t]))}sanitizeObject(e,t,a){if(typeof e!=="object"||e===null){return e}const r={};for(const i of Object.keys(e)){if(t.has(i.toLowerCase())){r[i]=a(e,i)}else{r[i]=I}}return r}sanitizeUrl(e){if(typeof e!=="string"||e===null){return e}const t=URLBuilder.parse(e);const a=t.getQuery();if(!a){return e}const r=URLQuery.parse(a);for(const e of r.keys()){if(!this.allowedQueryParameters.has(e.toLowerCase())){r.set(e,I)}}t.setQuery(r.toString());return t.toString()}}const B=i.inspect.custom;const k=new Sanitizer;class RestError extends Error{constructor(e,t,a,r,i){super(e);this.name="RestError";this.code=t;this.statusCode=a;this.request=r;this.response=i;Object.setPrototypeOf(this,RestError.prototype)}[B](){return`RestError: ${this.message} \n ${k.sanitize(this)}`}}RestError.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR";RestError.PARSE_ERROR="PARSE_ERROR";const z=p.createClientLogger("core-http");function getCachedAgent(e,t){return e?t.httpsAgent:t.httpAgent}class ReportTransform extends g.Transform{constructor(e){super();this.progressCallback=e;this.loadedBytes=0}_transform(e,t,a){this.push(e);this.loadedBytes+=e.length;this.progressCallback({loadedBytes:this.loadedBytes});a(undefined)}}function isReadableStream(e){return e&&typeof e.pipe==="function"}function isStreamComplete(e,t){return new Promise((a=>{e.once("close",(()=>{t===null||t===void 0?void 0:t.abort();a()}));e.once("end",a);e.once("error",a)}))}function parseHeaders(e){const t=new HttpHeaders;e.forEach(((e,a)=>{t.set(a,e)}));return t}class NodeFetchHttpClient{constructor(){this.proxyAgentMap=new Map;this.keepAliveAgents={}}async sendRequest(e){var t;if(!e&&typeof e!=="object"){throw new Error("'httpRequest' (WebResourceLike) cannot be null or undefined and must be of type object.")}const a=new u.AbortController;let r;if(e.abortSignal){if(e.abortSignal.aborted){throw new u.AbortError("The operation was aborted.")}r=e=>{if(e.type==="abort"){a.abort()}};e.abortSignal.addEventListener("abort",r)}if(e.timeout){setTimeout((()=>{a.abort()}),e.timeout)}if(e.formData){const t=e.formData;const a=new E["default"];const appendFormValue=(e,t)=>{if(typeof t==="function"){t=t()}if(t&&Object.prototype.hasOwnProperty.call(t,"value")&&Object.prototype.hasOwnProperty.call(t,"options")){a.append(e,t.value,t.options)}else{a.append(e,t)}};for(const e of Object.keys(t)){const a=t[e];if(Array.isArray(a)){for(let t=0;t{var t;(t=e.abortSignal)===null||t===void 0?void 0:t.removeEventListener("abort",r);return})).catch((e=>{z.warning("Error when cleaning up abortListener on httpRequest",e)}))}}}getOrCreateAgent(e){var t;const a=isUrlHttps(e.url);if(e.proxySettings){const{host:r,port:i,username:n,password:s}=e.proxySettings;const o=`${r}:${i}:${n}:${s}`;const p=(t=this.proxyAgentMap.get(o))!==null&&t!==void 0?t:{};let l=getCachedAgent(a,p);if(l){return l}const d=createProxyAgent(e.url,e.proxySettings,e.headers);l=d.agent;if(d.isHttps){p.httpsAgent=d.agent}else{p.httpAgent=d.agent}this.proxyAgentMap.set(o,p);return l}else if(e.keepAlive){let t=getCachedAgent(a,this.keepAliveAgents);if(t){return t}const r={keepAlive:e.keepAlive};if(a){t=this.keepAliveAgents.httpsAgent=new N.Agent(r)}else{t=this.keepAliveAgents.httpAgent=new S.Agent(r)}return t}else{return a?N.globalAgent:S.globalAgent}}async fetch(e,t){return _["default"](e,t)}async prepareRequest(e){const t={};t.agent=this.getOrCreateAgent(e);t.compress=e.decompressResponse;return t}async processRequest(e){}}t.HttpPipelineLogLevel=void 0;(function(e){e[e["OFF"]=0]="OFF";e[e["ERROR"]=1]="ERROR";e[e["WARNING"]=2]="WARNING";e[e["INFO"]=3]="INFO"})(t.HttpPipelineLogLevel||(t.HttpPipelineLogLevel={}));function operationOptionsToRequestOptionsBase(e){const{requestOptions:t,tracingOptions:a}=e,r=n.__rest(e,["requestOptions","tracingOptions"]);let i=r;if(t){i=Object.assign(Object.assign({},i),t)}if(a){i.tracingContext=a.tracingContext;i.spanOptions=a===null||a===void 0?void 0:a.spanOptions}return i}class BaseRequestPolicy{constructor(e,t){this._nextPolicy=e;this._options=t}shouldLog(e){return this._options.shouldLog(e)}log(e,t){this._options.log(e,t)}}class RequestPolicyOptions{constructor(e){this._logger=e}shouldLog(e){return!!this._logger&&e!==t.HttpPipelineLogLevel.OFF&&e<=this._logger.minimumLogLevel}log(e,t){if(this._logger&&this.shouldLog(e)){this._logger.log(e,t)}}}const j={explicitCharkey:false,trim:false,normalize:false,normalizeTags:false,attrkey:C,explicitArray:true,ignoreAttrs:false,mergeAttrs:false,explicitRoot:true,validator:undefined,xmlns:false,explicitChildren:false,preserveChildrenOrder:false,childkey:"$$",charsAsChildren:false,includeWhiteChars:false,async:false,strict:true,attrNameProcessors:undefined,attrValueProcessors:undefined,tagNameProcessors:undefined,valueProcessors:undefined,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:true},doctype:undefined,renderOpts:{pretty:true,indent:" ",newline:"\n"},headless:false,chunkSize:1e4,emptyTag:"",cdata:false};const q=Object.assign({},j);q.explicitArray=false;const U=Object.assign({},j);U.explicitArray=false;U.renderOpts={pretty:false};function stringifyXML(e,t={}){var a;U.rootName=t.rootName;U.charkey=(a=t.xmlCharKey)!==null&&a!==void 0?a:O;const r=new x.Builder(U);return r.buildObject(e)}function parseXML(e,t={}){var a;q.explicitRoot=!!t.includeRoot;q.charkey=(a=t.xmlCharKey)!==null&&a!==void 0?a:O;const r=new x.Parser(q);return new Promise(((t,a)=>{if(!e){a(new Error("Document is empty"))}else{r.parseString(e,((e,r)=>{if(e){a(e)}else{t(r)}}))}}))}function deserializationPolicy(e,t){return{create:(a,r)=>new DeserializationPolicy(a,r,e,t)}}const H=["application/json","text/json"];const V=["application/xml","application/atom+xml"];const G={expectedContentTypes:{json:H,xml:V}};class DeserializationPolicy extends BaseRequestPolicy{constructor(e,t,a,r={}){var i;super(e,t);this.jsonContentTypes=a&&a.json||H;this.xmlContentTypes=a&&a.xml||V;this.xmlCharKey=(i=r.xmlCharKey)!==null&&i!==void 0?i:O}async sendRequest(e){return this._nextPolicy.sendRequest(e).then((e=>deserializeResponseBody(this.jsonContentTypes,this.xmlContentTypes,e,{xmlCharKey:this.xmlCharKey})))}}function getOperationResponse(e){let t;const a=e.request;const r=a.operationSpec;if(r){const i=a.operationResponseGetter;if(!i){t=r.responses[e.status]}else{t=i(r,e)}}return t}function shouldDeserializeResponse(e){const t=e.request.shouldDeserialize;let a;if(t===undefined){a=true}else if(typeof t==="boolean"){a=t}else{a=t(e)}return a}function deserializeResponseBody(e,t,a,r={}){var i,n,s;const o={rootName:(i=r.rootName)!==null&&i!==void 0?i:"",includeRoot:(n=r.includeRoot)!==null&&n!==void 0?n:false,xmlCharKey:(s=r.xmlCharKey)!==null&&s!==void 0?s:O};return parse(e,t,a,o).then((e=>{if(!shouldDeserializeResponse(e)){return e}const t=e.request.operationSpec;if(!t||!t.responses){return e}const i=getOperationResponse(e);const{error:n,shouldReturnResponse:s}=handleErrorResponse(e,t,i);if(n){throw n}else if(s){return e}if(i){if(i.bodyMapper){let a=e.parsedBody;if(t.isXML&&i.bodyMapper.type.name===A.Sequence){a=typeof a==="object"?a[i.bodyMapper.xmlElementName]:[]}try{e.parsedBody=t.serializer.deserialize(i.bodyMapper,a,"operationRes.parsedBody",r)}catch(t){const a=new RestError(`Error ${t} occurred in deserializing the responseBody - ${e.bodyAsText}`,undefined,e.status,e.request,e);throw a}}else if(t.httpMethod==="HEAD"){e.parsedBody=a.status>=200&&a.status<300}if(i.headersMapper){e.parsedHeaders=t.serializer.deserialize(i.headersMapper,e.headers.toJson(),"operationRes.parsedHeaders",r)}}return e}))}function isOperationSpecEmpty(e){const t=Object.keys(e.responses);return t.length===0||t.length===1&&t[0]==="default"}function handleErrorResponse(e,t,a){var r;const i=200<=e.status&&e.status<300;const n=isOperationSpecEmpty(t)?i:!!a;if(n){if(a){if(!a.isError){return{error:null,shouldReturnResponse:false}}}else{return{error:null,shouldReturnResponse:false}}}const s=a!==null&&a!==void 0?a:t.responses.default;const o=((r=e.request.streamResponseStatusCodes)===null||r===void 0?void 0:r.has(e.status))||e.request.streamResponseBody;const p=o?`Unexpected status code: ${e.status}`:e.bodyAsText;const l=new RestError(p,undefined,e.status,e.request,e);if(!s){throw l}const d=s.bodyMapper;const c=s.headersMapper;try{if(e.parsedBody){const a=e.parsedBody;let r;if(d){let e=a;if(t.isXML&&d.type.name===A.Sequence){e=typeof a==="object"?a[d.xmlElementName]:[]}r=t.serializer.deserialize(d,e,"error.response.parsedBody")}const i=a.error||r||a;l.code=i.code;if(i.message){l.message=i.message}if(d){l.response.parsedBody=r}}if(e.headers&&c){l.response.parsedHeaders=t.serializer.deserialize(c,e.headers.toJson(),"operationRes.parsedHeaders")}}catch(t){l.message=`Error "${t.message}" occurred in deserializing the responseBody - "${e.bodyAsText}" for the default response.`}return{error:l,shouldReturnResponse:false}}function parse(e,t,a,r){var i;const errorHandler=e=>{const t=`Error "${e}" occurred while parsing the response body - ${a.bodyAsText}.`;const r=e.code||RestError.PARSE_ERROR;const i=new RestError(t,r,a.status,a.request,a);return Promise.reject(i)};const n=((i=a.request.streamResponseStatusCodes)===null||i===void 0?void 0:i.has(a.status))||a.request.streamResponseBody;if(!n&&a.bodyAsText){const i=a.bodyAsText;const n=a.headers.get("Content-Type")||"";const s=!n?[]:n.split(";").map((e=>e.toLowerCase()));if(s.length===0||s.some((t=>e.indexOf(t)!==-1))){return new Promise((e=>{a.parsedBody=JSON.parse(i);e(a)})).catch(errorHandler)}else if(s.some((e=>t.indexOf(e)!==-1))){return parseXML(i,r).then((e=>{a.parsedBody=e;return a})).catch(errorHandler)}}return Promise.resolve(a)}const $={enable:true};function keepAlivePolicy(e){return{create:(t,a)=>new KeepAlivePolicy(t,a,e||$)}}class KeepAlivePolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.keepAliveOptions=a}async sendRequest(e){e.keepAlive=this.keepAliveOptions.enable;return this._nextPolicy.sendRequest(e)}}const X=["GET","HEAD"];const W={handleRedirects:true,maxRetries:20};function redirectPolicy(e=20){return{create:(t,a)=>new RedirectPolicy(t,a,e)}}class RedirectPolicy extends BaseRequestPolicy{constructor(e,t,a=20){super(e,t);this.maxRetries=a}sendRequest(e){return this._nextPolicy.sendRequest(e).then((e=>handleRedirect(this,e,0)))}}function handleRedirect(e,t,a){const{request:r,status:i}=t;const n=t.headers.get("location");if(n&&(i===300||i===301&&X.includes(r.method)||i===302&&X.includes(r.method)||i===303&&r.method==="POST"||i===307)&&(!e.maxRetries||ahandleRedirect(e,t,a+1)))}return Promise.resolve(t)}const K=3;const Q=1e3*30;const Y=1e3*90;const J=1e3*3;function isNumber(e){return typeof e==="number"}function shouldRetry(e,t,a,r,i){if(!t(r,i)){return false}return a.retryCountnew ExponentialRetryPolicy(r,i,e,t,a)}}t.RetryMode=void 0;(function(e){e[e["Exponential"]=0]="Exponential"})(t.RetryMode||(t.RetryMode={}));const Z={maxRetries:K,retryDelayInMs:Q,maxRetryDelayInMs:Y};class ExponentialRetryPolicy extends BaseRequestPolicy{constructor(e,t,a,r,i){super(e,t);this.retryCount=isNumber(a)?a:K;this.retryInterval=isNumber(r)?r:Q;this.maxRetryInterval=isNumber(i)?i:Y}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then((t=>retry$1(this,e,t))).catch((t=>retry$1(this,e,t.response,undefined,t)))}}async function retry$1(e,t,a,r,i){function shouldPolicyRetry(e){const t=e===null||e===void 0?void 0:e.status;if(t===503&&(a===null||a===void 0?void 0:a.headers.get(P.HeaderConstants.RETRY_AFTER))){return false}if(t===undefined||t<500&&t!==408||t===501||t===505){return false}return true}r=updateRetryData({retryInterval:e.retryInterval,minRetryInterval:0,maxRetryInterval:e.maxRetryInterval},r,i);const n=t.abortSignal&&t.abortSignal.aborted;if(!n&&shouldRetry(e.retryCount,shouldPolicyRetry,r,a)){z.info(`Retrying request in ${r.retryInterval}`);try{await o.delay(r.retryInterval);const a=await e._nextPolicy.sendRequest(t.clone());return retry$1(e,t,a,r)}catch(i){return retry$1(e,t,a,r,i)}}else if(n||i||!a){const e=r.error||new RestError("Failed to send the request.",RestError.REQUEST_SEND_ERROR,a&&a.status,a&&a.request,a);throw e}else{return a}}function logPolicy(e={}){return{create:(t,a)=>new LogPolicy(t,a,e)}}class LogPolicy extends BaseRequestPolicy{constructor(e,t,{logger:a=z.info,allowedHeaderNames:r=[],allowedQueryParameters:i=[]}={}){super(e,t);this.logger=a;this.sanitizer=new Sanitizer({allowedHeaderNames:r,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){if(!this.logger.enabled)return this._nextPolicy.sendRequest(e);this.logRequest(e);return this._nextPolicy.sendRequest(e).then((e=>this.logResponse(e)))}logRequest(e){this.logger(`Request: ${this.sanitizer.sanitize(e)}`)}logResponse(e){this.logger(`Response status code: ${e.status}`);this.logger(`Headers: ${this.sanitizer.sanitize(e.headers)}`);return e}}function getPathStringFromParameter(e){return getPathStringFromParameterPath(e.parameterPath,e.mapper)}function getPathStringFromParameterPath(e,t){let a;if(typeof e==="string"){a=e}else if(Array.isArray(e)){a=e.join(".")}else{a=t.serializedName}return a}function getStreamResponseStatusCodes(e){const t=new Set;for(const a in e.responses){const r=e.responses[a];if(r.bodyMapper&&r.bodyMapper.type.name===A.Stream){t.add(Number(a))}}return t}function getDefaultUserAgentKey(){return P.HeaderConstants.USER_AGENT}function getPlatformSpecificData(){const e={key:"Node",value:process.version};const t={key:"OS",value:`(${w.arch()}-${w.type()}-${w.release()})`};return[e,t]}function getRuntimeInfo(){const e={key:"core-http",value:P.coreHttpVersion};return[e]}function getUserAgentString(e,t=" ",a="/"){return e.map((e=>{const t=e.value?`${a}${e.value}`:"";return`${e.key}${t}`})).join(t)}const ee=getDefaultUserAgentKey;function getDefaultUserAgentValue(){const e=getRuntimeInfo();const t=getPlatformSpecificData();const a=getUserAgentString(e.concat(t));return a}function userAgentPolicy(e){const t=!e||e.key===undefined||e.key===null?getDefaultUserAgentKey():e.key;const a=!e||e.value===undefined||e.value===null?getDefaultUserAgentValue():e.value;return{create:(e,r)=>new UserAgentPolicy(e,r,t,a)}}class UserAgentPolicy extends BaseRequestPolicy{constructor(e,t,a,r){super(e,t);this._nextPolicy=e;this._options=t;this.headerKey=a;this.headerValue=r}sendRequest(e){this.addUserAgentHeader(e);return this._nextPolicy.sendRequest(e)}addUserAgentHeader(e){if(!e.headers){e.headers=new HttpHeaders}if(!e.headers.get(this.headerKey)&&this.headerValue){e.headers.set(this.headerKey,this.headerValue)}}}t.QueryCollectionFormat=void 0;(function(e){e["Csv"]=",";e["Ssv"]=" ";e["Tsv"]="\t";e["Pipes"]="|";e["Multi"]="Multi"})(t.QueryCollectionFormat||(t.QueryCollectionFormat={}));const te={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function beginRefresh(e,t,a){async function tryGetAccessToken(){if(Date.now()e.getToken(t,a);r=beginRefresh(tryGetAccessToken,n.retryIntervalInMs,(o=i===null||i===void 0?void 0:i.expiresOnTimestamp)!==null&&o!==void 0?o:Date.now()).then((e=>{r=null;i=e;return i})).catch((e=>{r=null;i=null;throw e}))}return r}return async e=>{if(s.mustRefresh)return refresh(e);if(s.shouldRefresh){refresh(e)}return i}}function bearerTokenAuthenticationPolicy(e,t){const a=createTokenCycler(e,t);class BearerTokenAuthenticationPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){if(!e.url.toLowerCase().startsWith("https://")){throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.")}const{token:t}=await a({abortSignal:e.abortSignal,tracingOptions:{tracingContext:e.tracingContext}});e.headers.set(P.HeaderConstants.AUTHORIZATION,`Bearer ${t}`);return this._nextPolicy.sendRequest(e)}}return{create:(e,t)=>new BearerTokenAuthenticationPolicy(e,t)}}function disableResponseDecompressionPolicy(){return{create:(e,t)=>new DisableResponseDecompressionPolicy(e,t)}}class DisableResponseDecompressionPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){e.decompressResponse=false;return this._nextPolicy.sendRequest(e)}}function generateClientRequestIdPolicy(e="x-ms-client-request-id"){return{create:(t,a)=>new GenerateClientRequestIdPolicy(t,a,e)}}class GenerateClientRequestIdPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this._requestIdHeaderName=a}sendRequest(e){if(!e.headers.contains(this._requestIdHeaderName)){e.headers.set(this._requestIdHeaderName,e.requestId)}return this._nextPolicy.sendRequest(e)}}let ae;function getCachedDefaultHttpClient(){if(!ae){ae=new NodeFetchHttpClient}return ae}function ndJsonPolicy(){return{create:(e,t)=>new NdJsonPolicy(e,t)}}class NdJsonPolicy extends BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){if(typeof e.body==="string"&&e.body.startsWith("[")){const t=JSON.parse(e.body);if(Array.isArray(t)){e.body=t.map((e=>JSON.stringify(e)+"\n")).join("")}}return this._nextPolicy.sendRequest(e)}}const re=[];let ie=false;const ne=new Map;function loadEnvironmentProxyValue(){if(!process){return undefined}const e=getEnvironmentValue(P.HTTPS_PROXY);const t=getEnvironmentValue(P.ALL_PROXY);const a=getEnvironmentValue(P.HTTP_PROXY);return e||t||a}function isBypassed(e,t,a){if(t.length===0){return false}const r=URLBuilder.parse(e).getHost();if(a===null||a===void 0?void 0:a.has(r)){return a.get(r)}let i=false;for(const e of t){if(e[0]==="."){if(r.endsWith(e)){i=true}else{if(r.length===e.length-1&&r===e.slice(1)){i=true}}}else{if(r===e){i=true}}}a===null||a===void 0?void 0:a.set(r,i);return i}function loadNoProxy(){const e=getEnvironmentValue(P.NO_PROXY);ie=true;if(e){return e.split(",").map((e=>e.trim())).filter((e=>e.length))}return[]}function getDefaultProxySettings(e){if(!e){e=loadEnvironmentProxyValue();if(!e){return undefined}}const{username:t,password:a,urlWithoutAuth:r}=extractAuthFromUrl(e);const i=URLBuilder.parse(r);const n=i.getScheme()?i.getScheme()+"://":"";return{host:n+i.getHost(),port:Number.parseInt(i.getPort()||"80"),username:t,password:a}}function proxyPolicy(e,t){if(!e){e=getDefaultProxySettings()}if(!ie){re.push(...loadNoProxy())}return{create:(a,r)=>new ProxyPolicy(a,r,e,t===null||t===void 0?void 0:t.customNoProxyList)}}function extractAuthFromUrl(e){const t=e.indexOf("@");if(t===-1){return{urlWithoutAuth:e}}const a=e.indexOf("://");const r=a!==-1?a+3:0;const i=e.substring(r,t);const n=i.indexOf(":");const s=n!==-1;const o=s?i.substring(0,n):i;const p=s?i.substring(n+1):undefined;const l=e.substring(0,r)+e.substring(t+1);return{username:o,password:p,urlWithoutAuth:l}}class ProxyPolicy extends BaseRequestPolicy{constructor(e,t,a,r){super(e,t);this.proxySettings=a;this.customNoProxyList=r}sendRequest(e){var t;if(!e.proxySettings&&!isBypassed(e.url,(t=this.customNoProxyList)!==null&&t!==void 0?t:re,this.customNoProxyList?undefined:ne)){e.proxySettings=this.proxySettings}return this._nextPolicy.sendRequest(e)}}function rpRegistrationPolicy(e=30){return{create:(t,a)=>new RPRegistrationPolicy(t,a,e)}}class RPRegistrationPolicy extends BaseRequestPolicy{constructor(e,t,a=30){super(e,t);this._retryTimeout=a}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).then((t=>registerIfNeeded(this,e,t)))}}function registerIfNeeded(e,t,a){if(a.status===409){const r=checkRPNotRegisteredError(a.bodyAsText);if(r){const i=extractSubscriptionUrl(t.url);return registerRP(e,i,r,t).catch((()=>false)).then((r=>{if(r){t.headers.set("x-ms-client-request-id",generateUuid());return e._nextPolicy.sendRequest(t.clone())}return a}))}}return Promise.resolve(a)}function getRequestEssentials(e,t=false){const a=e.clone();if(t){a.url=e.url}a.headers.set("x-ms-client-request-id",generateUuid());a.headers.set("Content-Type","application/json; charset=utf-8");return a}function checkRPNotRegisteredError(e){let t,a;if(e){try{a=JSON.parse(e)}catch(e){}if(a&&a.error&&a.error.message&&a.error.code&&a.error.code==="MissingSubscriptionRegistration"){const e=a.error.message.match(/.*'(.*)'/i);if(e){t=e.pop()}}}return t}function extractSubscriptionUrl(e){let t;const a=e.match(/.*\/subscriptions\/[a-f0-9-]+\//gi);if(a&&a[0]){t=a[0]}else{throw new Error(`Unable to extract subscriptionId from the given url - ${e}.`)}return t}async function registerRP(e,t,a,r){const i=`${t}providers/${a}/register?api-version=2016-02-01`;const n=`${t}providers/${a}?api-version=2016-02-01`;const s=getRequestEssentials(r);s.method="POST";s.url=i;const o=await e._nextPolicy.sendRequest(s);if(o.status!==200){throw new Error(`Autoregistration of ${a} failed. Please try registering manually.`)}return getRegistrationStatus(e,n,r)}async function getRegistrationStatus(e,t,a){const r=getRequestEssentials(a);r.url=t;r.method="GET";const i=await e._nextPolicy.sendRequest(r);const n=i.parsedBody;if(i.parsedBody&&n.registrationState&&n.registrationState==="Registered"){return true}else{await o.delay(e._retryTimeout*1e3);return getRegistrationStatus(e,t,a)}}function signingPolicy(e){return{create:(t,a)=>new SigningPolicy(t,a,e)}}class SigningPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.authenticationProvider=a}signRequest(e){return this.authenticationProvider.signRequest(e)}sendRequest(e){return this.signRequest(e).then((e=>this._nextPolicy.sendRequest(e)))}}function systemErrorRetryPolicy(e,t,a,r){return{create:(i,n)=>new SystemErrorRetryPolicy(i,n,e,t,a,r)}}class SystemErrorRetryPolicy extends BaseRequestPolicy{constructor(e,t,a,r,i,n){super(e,t);this.retryCount=isNumber(a)?a:K;this.retryInterval=isNumber(r)?r:Q;this.minRetryInterval=isNumber(i)?i:J;this.maxRetryInterval=isNumber(n)?n:Y}sendRequest(e){return this._nextPolicy.sendRequest(e.clone()).catch((t=>retry(this,e,t.response,t)))}}async function retry(e,t,a,r,i){i=updateRetryData(e,i,r);function shouldPolicyRetry(e,t){if(t&&t.code&&(t.code==="ETIMEDOUT"||t.code==="ESOCKETTIMEDOUT"||t.code==="ECONNREFUSED"||t.code==="ECONNRESET"||t.code==="ENOENT")){return true}return false}if(shouldRetry(e.retryCount,shouldPolicyRetry,i,a,r)){try{await o.delay(i.retryInterval);return e._nextPolicy.sendRequest(t.clone())}catch(r){return retry(e,t,a,r,i)}}else{if(r){return Promise.reject(i.error)}return a}}const se=3;const oe=P.HttpConstants.StatusCodes;function throttlingRetryPolicy(){return{create:(e,t)=>new ThrottlingRetryPolicy(e,t)}}const pe="The operation was aborted.";class ThrottlingRetryPolicy extends BaseRequestPolicy{constructor(e,t,a){super(e,t);this.numberOfRetries=0;this._handleResponse=a||this._defaultResponseHandler}async sendRequest(e){const t=await this._nextPolicy.sendRequest(e.clone());if(t.status!==oe.TooManyRequests&&t.status!==oe.ServiceUnavailable){return t}else{return this._handleResponse(e,t)}}async _defaultResponseHandler(e,t){var a;const r=t.headers.get(P.HeaderConstants.RETRY_AFTER);if(r){const t=ThrottlingRetryPolicy.parseRetryAfterHeader(r);if(t){this.numberOfRetries+=1;await o.delay(t,{abortSignal:e.abortSignal,abortErrorMsg:pe});if((a=e.abortSignal)===null||a===void 0?void 0:a.aborted){throw new u.AbortError(pe)}if(this.numberOfRetries{let a=undefined;const r=this;const i=t;return{create(t,n){const s=getCredentialScopes(i,r.baseUri);if(!s){throw new Error(`When using credential, the ServiceClient must contain a baseUri or a credentialScopes in ServiceClientOptions. Unable to create a bearerTokenAuthenticationPolicy`)}if(a===undefined||a===null){a=bearerTokenAuthenticationPolicy(e,s)}return a.create(t,n)}}};r=wrappedPolicyFactory()}else if(e&&typeof e.signRequest==="function"){z.info("ServiceClient: creating signing policy from provided credentials");r=signingPolicy(e)}else if(e!==undefined&&e!==null){throw new Error("The credentials argument must implement the TokenCredential interface")}z.info("ServiceClient: using default request policies");a=createDefaultRequestPolicyFactories(r,t);if(t.requestPolicyFactories){const e=t.requestPolicyFactories(a);if(e){a=e}}}this._requestPolicyFactories=a}sendRequest(e){if(e===null||e===undefined||typeof e!=="object"){throw new Error("options cannot be null or undefined and it must be of type object.")}let t;try{if(isWebResourceLike(e)){e.validateRequestProperties();t=e}else{t=new WebResource;t=t.prepare(e)}}catch(e){return Promise.reject(e)}let a=this._httpClient;if(this._requestPolicyFactories&&this._requestPolicyFactories.length>0){for(let e=this._requestPolicyFactories.length-1;e>=0;--e){a=this._requestPolicyFactories[e].create(a,this._requestPolicyOptions)}}return a.sendRequest(t)}async sendOperationRequest(e,a,r){var i;if(typeof e.options==="function"){r=e.options;e.options=undefined}const n=(i=e.options)===null||i===void 0?void 0:i.serializerOptions;const s=new WebResource;let o;try{const r=a.baseUrl||this.baseUri;if(!r){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=a.httpMethod;s.operationSpec=a;const i=URLBuilder.parse(r);if(a.path){i.appendPath(a.path)}if(a.urlParameters&&a.urlParameters.length>0){for(const t of a.urlParameters){let r=getOperationArgumentValueFromParameter(this,e,t,a.serializer);r=a.serializer.serialize(t.mapper,r,getPathStringFromParameter(t),n);if(!t.skipEncoding){r=encodeURIComponent(r)}i.replaceAll(`{${t.mapper.serializedName||getPathStringFromParameter(t)}}`,r)}}if(a.queryParameters&&a.queryParameters.length>0){for(const r of a.queryParameters){let s=getOperationArgumentValueFromParameter(this,e,r,a.serializer);if(s!==undefined&&s!==null){s=a.serializer.serialize(r.mapper,s,getPathStringFromParameter(r),n);if(r.collectionFormat!==undefined&&r.collectionFormat!==null){if(r.collectionFormat===t.QueryCollectionFormat.Multi){if(s.length===0){continue}else{for(const e in s){const t=s[e];s[e]=t===undefined||t===null?"":t.toString()}}}else if(r.collectionFormat===t.QueryCollectionFormat.Ssv||r.collectionFormat===t.QueryCollectionFormat.Tsv){s=s.join(r.collectionFormat)}}if(!r.skipEncoding){if(Array.isArray(s)){for(const e in s){if(s[e]!==undefined&&s[e]!==null){s[e]=encodeURIComponent(s[e])}}}else{s=encodeURIComponent(s)}}if(r.collectionFormat!==undefined&&r.collectionFormat!==null&&r.collectionFormat!==t.QueryCollectionFormat.Multi&&r.collectionFormat!==t.QueryCollectionFormat.Ssv&&r.collectionFormat!==t.QueryCollectionFormat.Tsv){s=s.join(r.collectionFormat)}i.setQueryParameter(r.mapper.serializedName||getPathStringFromParameter(r),s)}}}s.url=i.toString();const p=a.contentType||this.requestContentType;if(p&&a.requestBody){s.headers.set("Content-Type",p)}if(a.headerParameters){for(const t of a.headerParameters){let r=getOperationArgumentValueFromParameter(this,e,t,a.serializer);if(r!==undefined&&r!==null){r=a.serializer.serialize(t.mapper,r,getPathStringFromParameter(t),n);const e=t.mapper.headerCollectionPrefix;if(e){for(const t of Object.keys(r)){s.headers.set(e+t,r[t])}}else{s.headers.set(t.mapper.serializedName||getPathStringFromParameter(t),r)}}}}const l=e.options;if(l){if(l.customHeaders){for(const e in l.customHeaders){s.headers.set(e,l.customHeaders[e])}}if(l.abortSignal){s.abortSignal=l.abortSignal}if(l.timeout){s.timeout=l.timeout}if(l.onUploadProgress){s.onUploadProgress=l.onUploadProgress}if(l.onDownloadProgress){s.onDownloadProgress=l.onDownloadProgress}if(l.spanOptions){s.spanOptions=l.spanOptions}if(l.tracingContext){s.tracingContext=l.tracingContext}if(l.shouldDeserialize!==undefined&&l.shouldDeserialize!==null){s.shouldDeserialize=l.shouldDeserialize}}s.withCredentials=this._withCredentials;serializeRequestBody(this,s,e,a);if(s.streamResponseStatusCodes===undefined){s.streamResponseStatusCodes=getStreamResponseStatusCodes(a)}let d;let c;try{d=await this.sendRequest(s)}catch(e){c=e}if(c){if(c.response){c.details=flattenResponse(c.response,a.responses[c.statusCode]||a.responses["default"])}o=Promise.reject(c)}else{o=Promise.resolve(flattenResponse(d,a.responses[d.status]))}}catch(e){o=Promise.reject(e)}const p=r;if(p){o.then((e=>p(null,e._response.parsedBody,e._response.request,e._response))).catch((e=>p(e)))}return o}}function serializeRequestBody(e,t,a,r){var i,n,s,o,p,l;const d=(n=(i=a.options)===null||i===void 0?void 0:i.serializerOptions)!==null&&n!==void 0?n:{};const c={rootName:(s=d.rootName)!==null&&s!==void 0?s:"",includeRoot:(o=d.includeRoot)!==null&&o!==void 0?o:false,xmlCharKey:(p=d.xmlCharKey)!==null&&p!==void 0?p:O};const m=d.xmlCharKey;if(r.requestBody&&r.requestBody.mapper){t.body=getOperationArgumentValueFromParameter(e,a,r.requestBody,r.serializer);const i=r.requestBody.mapper;const{required:n,xmlName:s,xmlElementName:o,serializedName:p,xmlNamespace:d,xmlNamespacePrefix:u}=i;const h=i.type.name;try{if(t.body!==undefined&&t.body!==null||n){const e=getPathStringFromParameter(r.requestBody);t.body=r.serializer.serialize(i,t.body,e,c);const a=h===A.Stream;if(r.isXML){const e=u?`xmlns:${u}`:"xmlns";const r=getXmlValueWithNamespace(d,e,h,t.body,c);if(h===A.Sequence){t.body=stringifyXML(prepareXMLRootList(r,o||s||p,e,d),{rootName:s||p,xmlCharKey:m})}else if(!a){t.body=stringifyXML(r,{rootName:s||p,xmlCharKey:m})}}else if(h===A.String&&(((l=r.contentType)===null||l===void 0?void 0:l.match("text/plain"))||r.mediaType==="text")){return}else if(!a){t.body=JSON.stringify(t.body)}}}catch(e){throw new Error(`Error "${e.message}" occurred in serializing the payload - ${JSON.stringify(p,undefined," ")}.`)}}else if(r.formDataParameters&&r.formDataParameters.length>0){t.formData={};for(const i of r.formDataParameters){const n=getOperationArgumentValueFromParameter(e,a,i,r.serializer);if(n!==undefined&&n!==null){const e=i.mapper.serializedName||getPathStringFromParameter(i);t.formData[e]=r.serializer.serialize(i.mapper,n,getPathStringFromParameter(i),c)}}}}function getXmlValueWithNamespace(e,t,a,r,i){if(e&&!["Composite","Sequence","Dictionary"].includes(a)){const a={};a[i.xmlCharKey]=r;a[C]={[t]:e};return a}return r}function getValueOrFunctionResult(e,t){let a;if(typeof e==="string"){a=e}else{a=t();if(typeof e==="function"){a=e(a)}}return a}function createDefaultRequestPolicyFactories(e,t){const a=[];if(t.generateClientRequestIdHeader){a.push(generateClientRequestIdPolicy(t.clientRequestIdHeaderName))}if(e){a.push(e)}const r=getValueOrFunctionResult(t.userAgentHeaderName,ee);const i=getValueOrFunctionResult(t.userAgent,getDefaultUserAgentValue);if(r&&i){a.push(userAgentPolicy({key:r,value:i}))}a.push(redirectPolicy());a.push(rpRegistrationPolicy(t.rpRegistrationRetryTimeout));if(!t.noRetryPolicy){a.push(exponentialRetryPolicy());a.push(systemErrorRetryPolicy());a.push(throttlingRetryPolicy())}a.push(deserializationPolicy(t.deserializationContentTypes));if(o.isNode){a.push(proxyPolicy(t.proxySettings))}a.push(logPolicy({logger:z.info}));return a}function createPipelineFromOptions(e,t){const a=[];if(e.sendStreamingJson){a.push(ndJsonPolicy())}let r=undefined;if(e.userAgentOptions&&e.userAgentOptions.userAgentPrefix){const t=[];t.push(e.userAgentOptions.userAgentPrefix);const a=getDefaultUserAgentValue();if(t.indexOf(a)===-1){t.push(a)}r=t.join(" ")}const i=Object.assign(Object.assign({},$),e.keepAliveOptions);const n=Object.assign(Object.assign({},Z),e.retryOptions);const s=Object.assign(Object.assign({},W),e.redirectOptions);if(o.isNode){a.push(proxyPolicy(e.proxyOptions))}const p=Object.assign(Object.assign({},G),e.deserializationOptions);const l=Object.assign({},e.loggingOptions);a.push(tracingPolicy({userAgent:r}),keepAlivePolicy(i),userAgentPolicy({value:r}),generateClientRequestIdPolicy(),deserializationPolicy(p.expectedContentTypes),throttlingRetryPolicy(),systemErrorRetryPolicy(),exponentialRetryPolicy(n.maxRetries,n.retryDelayInMs,n.maxRetryDelayInMs));if(s.handleRedirects){a.push(redirectPolicy(s.maxRetries))}if(t){a.push(t)}a.push(logPolicy(l));if(o.isNode&&e.decompressResponse===false){a.push(disableResponseDecompressionPolicy())}return{httpClient:e.httpClient,requestPolicyFactories:a}}function getOperationArgumentValueFromParameter(e,t,a,r){return getOperationArgumentValueFromParameterPath(e,t,a.parameterPath,a.mapper,r)}function getOperationArgumentValueFromParameterPath(e,t,a,r,i){var n;let s;if(typeof a==="string"){a=[a]}const o=(n=t.options)===null||n===void 0?void 0:n.serializerOptions;if(Array.isArray(a)){if(a.length>0){if(r.isConstant){s=r.defaultValue}else{let i=getPropertyFromParameterPath(t,a);if(!i.propertyFound){i=getPropertyFromParameterPath(e,a)}let n=false;if(!i.propertyFound){n=r.required||a[0]==="options"&&a.length===2}s=n?r.defaultValue:i.propertyValue}const n=getPathStringFromParameterPath(a,r);i.serialize(r,s,n,o)}}else{if(r.required){s={}}for(const n in a){const p=r.type.modelProperties[n];const l=a[n];const d=getOperationArgumentValueFromParameterPath(e,t,l,p,i);const c=getPathStringFromParameterPath(l,p);i.serialize(p,d,c,o);if(d!==undefined&&d!==null){if(!s){s={}}s[n]=d}}}return s}function getPropertyFromParameterPath(e,t){const a={propertyFound:false};let r=0;for(;rObject.defineProperty(t,"_response",{value:e});if(r){const t=r.type.name;if(t==="Stream"){return addOperationResponse(Object.assign(Object.assign({},a),{blobBody:e.blobBody,readableStreamBody:e.readableStreamBody}))}const i=t==="Composite"&&r.type.modelProperties||{};const n=Object.keys(i).some((e=>i[e].serializedName===""));if(t==="Sequence"||n){const t=[...e.parsedBody||[]];for(const a of Object.keys(i)){if(i[a].serializedName){t[a]=e.parsedBody[a]}}if(a){for(const e of Object.keys(a)){t[e]=a[e]}}addOperationResponse(t);return t}if(t==="Composite"||t==="Dictionary"){return addOperationResponse(Object.assign(Object.assign({},a),e.parsedBody))}}if(r||e.request.method==="HEAD"||isPrimitiveType(e.parsedBody)){return addOperationResponse(Object.assign(Object.assign({},a),{body:e.parsedBody}))}return addOperationResponse(Object.assign(Object.assign({},a),e.parsedBody))}function getCredentialScopes(e,t){if(e===null||e===void 0?void 0:e.credentialScopes){return e.credentialScopes}if(t){return`${t}/.default`}return undefined}function createSpanFunction(e){return b.createSpanFunction(e)}const de=2*60*1e3;class ExpiringAccessTokenCache{constructor(e=de){this.cachedToken=undefined;this.tokenRefreshBufferMs=e}setCachedToken(e){this.cachedToken=e}getCachedToken(){if(this.cachedToken&&Date.now()+this.tokenRefreshBufferMs>=this.cachedToken.expiresOnTimestamp){this.cachedToken=undefined}return this.cachedToken}}class AccessTokenRefresher{constructor(e,t,a=3e4){this.credential=e;this.scopes=t;this.requiredMillisecondsBeforeNewRefresh=a;this.lastCalled=0}isReady(){return!this.lastCalled||Date.now()-this.lastCalled>this.requiredMillisecondsBeforeNewRefresh}async getToken(e){this.lastCalled=Date.now();const t=await this.credential.getToken(this.scopes,e);this.promise=undefined;return t||undefined}refresh(e){if(!this.promise){this.promise=this.getToken(e)}return this.promise}}const ce=P.HeaderConstants;const me="Basic";class BasicAuthenticationCredentials{constructor(e,t,a=me){this.authorizationScheme=me;if(e===null||e===undefined||typeof e.valueOf()!=="string"){throw new Error("userName cannot be null or undefined and must be of type string.")}if(t===null||t===undefined||typeof t.valueOf()!=="string"){throw new Error("password cannot be null or undefined and must be of type string.")}this.userName=e;this.password=t;this.authorizationScheme=a}signRequest(e){const t=`${this.userName}:${this.password}`;const a=`${this.authorizationScheme} ${encodeString(t)}`;if(!e.headers)e.headers=new HttpHeaders;e.headers.set(ce.AUTHORIZATION,a);return Promise.resolve(e)}}class ApiKeyCredentials{constructor(e){if(!e||e&&!e.inHeader&&!e.inQuery){throw new Error(`options cannot be null or undefined. Either "inHeader" or "inQuery" property of the options object needs to be provided.`)}this.inHeader=e.inHeader;this.inQuery=e.inQuery}signRequest(e){if(!e){return Promise.reject(new Error(`webResource cannot be null or undefined and must be of type "object".`))}if(this.inHeader){if(!e.headers){e.headers=new HttpHeaders}for(const t in this.inHeader){e.headers.set(t,this.inHeader[t])}}if(this.inQuery){if(!e.url){return Promise.reject(new Error(`url cannot be null in the request object.`))}if(e.url.indexOf("?")<0){e.url+="?"}for(const t in this.inQuery){if(!e.url.endsWith("?")){e.url+="&"}e.url+=`${t}=${this.inQuery[t]}`}}return Promise.resolve(e)}}class TopicCredentials extends ApiKeyCredentials{constructor(e){if(!e||e&&typeof e!=="string"){throw new Error("topicKey cannot be null or undefined and must be of type string.")}const t={inHeader:{"aeg-sas-key":e}};super(t)}}Object.defineProperty(t,"delay",{enumerable:true,get:function(){return o.delay}});Object.defineProperty(t,"isNode",{enumerable:true,get:function(){return o.isNode}});Object.defineProperty(t,"isTokenCredential",{enumerable:true,get:function(){return l.isTokenCredential}});t.AccessTokenRefresher=AccessTokenRefresher;t.ApiKeyCredentials=ApiKeyCredentials;t.BaseRequestPolicy=BaseRequestPolicy;t.BasicAuthenticationCredentials=BasicAuthenticationCredentials;t.Constants=P;t.DefaultHttpClient=NodeFetchHttpClient;t.ExpiringAccessTokenCache=ExpiringAccessTokenCache;t.HttpHeaders=HttpHeaders;t.MapperType=A;t.RequestPolicyOptions=RequestPolicyOptions;t.RestError=RestError;t.Serializer=Serializer;t.ServiceClient=ServiceClient;t.TopicCredentials=TopicCredentials;t.URLBuilder=URLBuilder;t.URLQuery=URLQuery;t.WebResource=WebResource;t.XML_ATTRKEY=C;t.XML_CHARKEY=O;t.applyMixins=applyMixins;t.bearerTokenAuthenticationPolicy=bearerTokenAuthenticationPolicy;t.createPipelineFromOptions=createPipelineFromOptions;t.createSpanFunction=createSpanFunction;t.deserializationPolicy=deserializationPolicy;t.deserializeResponseBody=deserializeResponseBody;t.disableResponseDecompressionPolicy=disableResponseDecompressionPolicy;t.encodeUri=encodeUri;t.executePromisesSequentially=executePromisesSequentially;t.exponentialRetryPolicy=exponentialRetryPolicy;t.flattenResponse=flattenResponse;t.generateClientRequestIdPolicy=generateClientRequestIdPolicy;t.generateUuid=generateUuid;t.getDefaultProxySettings=getDefaultProxySettings;t.getDefaultUserAgentValue=getDefaultUserAgentValue;t.isDuration=isDuration;t.isValidUuid=isValidUuid;t.keepAlivePolicy=keepAlivePolicy;t.logPolicy=logPolicy;t.operationOptionsToRequestOptionsBase=operationOptionsToRequestOptionsBase;t.parseXML=parseXML;t.promiseToCallback=promiseToCallback;t.promiseToServiceCallback=promiseToServiceCallback;t.proxyPolicy=proxyPolicy;t.redirectPolicy=redirectPolicy;t.serializeObject=serializeObject;t.signingPolicy=signingPolicy;t.stringifyXML=stringifyXML;t.stripRequest=stripRequest;t.stripResponse=stripResponse;t.systemErrorRetryPolicy=systemErrorRetryPolicy;t.throttlingRetryPolicy=throttlingRetryPolicy;t.tracingPolicy=tracingPolicy;t.userAgentPolicy=userAgentPolicy},6279:(e,t,a)=>{var r=a(5443);var i=a(3837);var n=a(1017);var s=a(3685);var o=a(5687);var p=a(7310).parse;var l=a(7147);var d=a(2781).Stream;var c=a(3583);var m=a(4812);var u=a(3971);e.exports=FormData;i.inherits(FormData,r);function FormData(e){if(!(this instanceof FormData)){return new FormData(e)}this._overheadLength=0;this._valueLength=0;this._valuesToMeasure=[];r.call(this);e=e||{};for(var t in e){this[t]=e[t]}}FormData.LINE_BREAK="\r\n";FormData.DEFAULT_CONTENT_TYPE="application/octet-stream";FormData.prototype.append=function(e,t,a){a=a||{};if(typeof a=="string"){a={filename:a}}var n=r.prototype.append.bind(this);if(typeof t=="number"){t=""+t}if(i.isArray(t)){this._error(new Error("Arrays are not supported."));return}var s=this._multiPartHeader(e,t,a);var o=this._multiPartFooter();n(s);n(t);n(o);this._trackLength(s,t,a)};FormData.prototype._trackLength=function(e,t,a){var r=0;if(a.knownLength!=null){r+=+a.knownLength}else if(Buffer.isBuffer(t)){r=t.length}else if(typeof t==="string"){r=Buffer.byteLength(t)}this._valueLength+=r;this._overheadLength+=Buffer.byteLength(e)+FormData.LINE_BREAK.length;if(!t||!t.path&&!(t.readable&&t.hasOwnProperty("httpVersion"))&&!(t instanceof d)){return}if(!a.knownLength){this._valuesToMeasure.push(t)}};FormData.prototype._lengthRetriever=function(e,t){if(e.hasOwnProperty("fd")){if(e.end!=undefined&&e.end!=Infinity&&e.start!=undefined){t(null,e.end+1-(e.start?e.start:0))}else{l.stat(e.path,(function(a,r){var i;if(a){t(a);return}i=r.size-(e.start?e.start:0);t(null,i)}))}}else if(e.hasOwnProperty("httpVersion")){t(null,+e.headers["content-length"])}else if(e.hasOwnProperty("httpModule")){e.on("response",(function(a){e.pause();t(null,+a.headers["content-length"])}));e.resume()}else{t("Unknown stream")}};FormData.prototype._multiPartHeader=function(e,t,a){if(typeof a.header=="string"){return a.header}var r=this._getContentDisposition(t,a);var i=this._getContentType(t,a);var n="";var s={"Content-Disposition":["form-data",'name="'+e+'"'].concat(r||[]),"Content-Type":[].concat(i||[])};if(typeof a.header=="object"){u(s,a.header)}var o;for(var p in s){if(!s.hasOwnProperty(p))continue;o=s[p];if(o==null){continue}if(!Array.isArray(o)){o=[o]}if(o.length){n+=p+": "+o.join("; ")+FormData.LINE_BREAK}}return"--"+this.getBoundary()+FormData.LINE_BREAK+n+FormData.LINE_BREAK};FormData.prototype._getContentDisposition=function(e,t){var a,r;if(typeof t.filepath==="string"){a=n.normalize(t.filepath).replace(/\\/g,"/")}else if(t.filename||e.name||e.path){a=n.basename(t.filename||e.name||e.path)}else if(e.readable&&e.hasOwnProperty("httpVersion")){a=n.basename(e.client._httpMessage.path||"")}if(a){r='filename="'+a+'"'}return r};FormData.prototype._getContentType=function(e,t){var a=t.contentType;if(!a&&e.name){a=c.lookup(e.name)}if(!a&&e.path){a=c.lookup(e.path)}if(!a&&e.readable&&e.hasOwnProperty("httpVersion")){a=e.headers["content-type"]}if(!a&&(t.filepath||t.filename)){a=c.lookup(t.filepath||t.filename)}if(!a&&typeof e=="object"){a=FormData.DEFAULT_CONTENT_TYPE}return a};FormData.prototype._multiPartFooter=function(){return function(e){var t=FormData.LINE_BREAK;var a=this._streams.length===0;if(a){t+=this._lastBoundary()}e(t)}.bind(this)};FormData.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+FormData.LINE_BREAK};FormData.prototype.getHeaders=function(e){var t;var a={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e){if(e.hasOwnProperty(t)){a[t.toLowerCase()]=e[t]}}return a};FormData.prototype.setBoundary=function(e){this._boundary=e};FormData.prototype.getBoundary=function(){if(!this._boundary){this._generateBoundary()}return this._boundary};FormData.prototype.getBuffer=function(){var e=new Buffer.alloc(0);var t=this.getBoundary();for(var a=0,r=this._streams.length;a{e.exports=function(e,t){Object.keys(t).forEach((function(a){e[a]=e[a]||t[a]}));return e}},2107:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var L=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);L(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var M=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new M(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},7094:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(3233);var i=a(2557);var n=a(1333);const s=r.createClientLogger("core-lro");const o=2e3;const p=["succeeded","canceled","failed"];function deserializeState(e){try{return JSON.parse(e).state}catch(t){throw new Error(`Unable to deserialize input state: ${e}`)}}function setStateError(e){const{state:t,stateProxy:a,isOperationError:r}=e;return e=>{if(r(e)){a.setError(t,e);a.setFailed(t)}throw e}}function appendReadableErrorMessage(e,t){let a=e;if(a.slice(-1)!=="."){a=a+"."}return a+" "+t}function simplifyError(e){let t=e.message;let a=e.code;let r=e;while(r.innererror){r=r.innererror;a=r.code;t=appendReadableErrorMessage(t,r.message)}return{code:a,message:t}}function processOperationStatus(e){const{state:t,stateProxy:a,status:r,isDone:i,processResult:n,getError:o,response:p,setErrorAsResult:l}=e;switch(r){case"succeeded":{a.setSucceeded(t);break}case"failed":{const e=o===null||o===void 0?void 0:o(p);let r="";if(e){const{code:t,message:a}=simplifyError(e);r=`. ${t}. ${a}`}const i=`The long-running operation has failed${r}`;a.setError(t,new Error(i));a.setFailed(t);s.warning(i);break}case"canceled":{a.setCanceled(t);break}}if((i===null||i===void 0?void 0:i(p,t))||i===undefined&&["succeeded","canceled"].concat(l?[]:["failed"]).includes(r)){a.setResult(t,buildResult({response:p,state:t,processResult:n}))}}function buildResult(e){const{processResult:t,response:a,state:r}=e;return t?t(a,r):a}async function initOperation(e){const{init:t,stateProxy:a,processResult:r,getOperationStatus:i,withOperationLocation:n,setErrorAsResult:o}=e;const{operationLocation:p,resourceLocation:l,metadata:d,response:c}=await t();if(p)n===null||n===void 0?void 0:n(p,false);const m={metadata:d,operationLocation:p,resourceLocation:l};s.verbose(`LRO: Operation description:`,m);const u=a.initState(m);const h=i({response:c,state:u,operationLocation:p});processOperationStatus({state:u,status:h,stateProxy:a,response:c,setErrorAsResult:o,processResult:r});return u}async function pollOperationHelper(e){const{poll:t,state:a,stateProxy:r,operationLocation:i,getOperationStatus:n,getResourceLocation:o,isOperationError:l,options:d}=e;const c=await t(i,d).catch(setStateError({state:a,stateProxy:r,isOperationError:l}));const m=n(c,a);s.verbose(`LRO: Status:\n\tPolling from: ${a.config.operationLocation}\n\tOperation status: ${m}\n\tPolling status: ${p.includes(m)?"Stopped":"Running"}`);if(m==="succeeded"){const e=o(c,a);if(e!==undefined){return{response:await t(e).catch(setStateError({state:a,stateProxy:r,isOperationError:l})),status:m}}}return{response:c,status:m}}async function pollOperation(e){const{poll:t,state:a,stateProxy:r,options:i,getOperationStatus:n,getResourceLocation:s,getOperationLocation:o,isOperationError:l,withOperationLocation:d,getPollingInterval:c,processResult:m,getError:u,updateState:h,setDelay:g,isDone:y,setErrorAsResult:v}=e;const{operationLocation:b}=a.config;if(b!==undefined){const{response:e,status:x}=await pollOperationHelper({poll:t,getOperationStatus:n,state:a,stateProxy:r,operationLocation:b,getResourceLocation:s,isOperationError:l,options:i});processOperationStatus({status:x,response:e,state:a,stateProxy:r,isDone:y,processResult:m,getError:u,setErrorAsResult:v});if(!p.includes(x)){const t=c===null||c===void 0?void 0:c(e);if(t)g(t);const r=o===null||o===void 0?void 0:o(e,a);if(r!==undefined){const e=b!==r;a.config.operationLocation=r;d===null||d===void 0?void 0:d(r,e)}else d===null||d===void 0?void 0:d(b,false)}h===null||h===void 0?void 0:h(a,e)}}function getOperationLocationPollingUrl(e){const{azureAsyncOperation:t,operationLocation:a}=e;return a!==null&&a!==void 0?a:t}function getLocationHeader(e){return e.headers["location"]}function getOperationLocationHeader(e){return e.headers["operation-location"]}function getAzureAsyncOperationHeader(e){return e.headers["azure-asyncoperation"]}function findResourceLocation(e){var t;const{location:a,requestMethod:r,requestPath:i,resourceLocationConfig:n}=e;switch(r){case"PUT":{return i}case"DELETE":{return undefined}case"PATCH":{return(t=getDefault())!==null&&t!==void 0?t:i}default:{return getDefault()}}function getDefault(){switch(n){case"azure-async-operation":{return undefined}case"original-uri":{return i}case"location":default:{return a}}}}function inferLroMode(e){const{rawResponse:t,requestMethod:a,requestPath:r,resourceLocationConfig:i}=e;const n=getOperationLocationHeader(t);const s=getAzureAsyncOperationHeader(t);const o=getOperationLocationPollingUrl({operationLocation:n,azureAsyncOperation:s});const p=getLocationHeader(t);const l=a===null||a===void 0?void 0:a.toLocaleUpperCase();if(o!==undefined){return{mode:"OperationLocation",operationLocation:o,resourceLocation:findResourceLocation({requestMethod:l,location:p,requestPath:r,resourceLocationConfig:i})}}else if(p!==undefined){return{mode:"ResourceLocation",operationLocation:p}}else if(l==="PUT"&&r){return{mode:"Body",operationLocation:r}}else{return undefined}}function transformStatus(e){const{status:t,statusCode:a}=e;if(typeof t!=="string"&&t!==undefined){throw new Error(`Polling was unsuccessful. Expected status to have a string value or no value but it has instead: ${t}. This doesn't necessarily indicate the operation has failed. Check your Azure subscription or resource status for more information.`)}switch(t===null||t===void 0?void 0:t.toLocaleLowerCase()){case undefined:return toOperationStatus(a);case"succeeded":return"succeeded";case"failed":return"failed";case"running":case"accepted":case"started":case"canceling":case"cancelling":return"running";case"canceled":case"cancelled":return"canceled";default:{s.verbose(`LRO: unrecognized operation status: ${t}`);return t}}}function getStatus(e){var t;const{status:a}=(t=e.body)!==null&&t!==void 0?t:{};return transformStatus({status:a,statusCode:e.statusCode})}function getProvisioningState(e){var t,a;const{properties:r,provisioningState:i}=(t=e.body)!==null&&t!==void 0?t:{};const n=(a=r===null||r===void 0?void 0:r.provisioningState)!==null&&a!==void 0?a:i;return transformStatus({status:n,statusCode:e.statusCode})}function toOperationStatus(e){if(e===202){return"running"}else if(e<300){return"succeeded"}else{return"failed"}}function parseRetryAfter({rawResponse:e}){const t=e.headers["retry-after"];if(t!==undefined){const e=parseInt(t);return isNaN(e)?calculatePollingIntervalFromDate(new Date(t)):e*1e3}return undefined}function getErrorFromResponse(e){const t=e.flatResponse.error;if(!t){s.warning(`The long-running operation failed but there is no error property in the response's body`);return}if(!t.code||!t.message){s.warning(`The long-running operation failed but the error property in the response's body doesn't contain code or message`);return}return t}function calculatePollingIntervalFromDate(e){const t=Math.floor((new Date).getTime());const a=e.getTime();if(t{const e=await i.sendInitialRequest();const t=inferLroMode({rawResponse:e.rawResponse,requestPath:i.requestPath,requestMethod:i.requestMethod,resourceLocationConfig:a});return Object.assign({response:e,operationLocation:t===null||t===void 0?void 0:t.operationLocation,resourceLocation:t===null||t===void 0?void 0:t.resourceLocation},(t===null||t===void 0?void 0:t.mode)?{metadata:{mode:t.mode}}:{})},stateProxy:t,processResult:r?({flatResponse:e},t)=>r(e,t):({flatResponse:e})=>e,getOperationStatus:getStatusFromInitialResponse,setErrorAsResult:n})}function getOperationLocation({rawResponse:e},t){var a;const r=(a=t.config.metadata)===null||a===void 0?void 0:a["mode"];switch(r){case"OperationLocation":{return getOperationLocationPollingUrl({operationLocation:getOperationLocationHeader(e),azureAsyncOperation:getAzureAsyncOperationHeader(e)})}case"ResourceLocation":{return getLocationHeader(e)}case"Body":default:{return undefined}}}function getOperationStatus({rawResponse:e},t){var a;const r=(a=t.config.metadata)===null||a===void 0?void 0:a["mode"];switch(r){case"OperationLocation":{return getStatus(e)}case"ResourceLocation":{return toOperationStatus(e.statusCode)}case"Body":{return getProvisioningState(e)}default:throw new Error(`Internal error: Unexpected operation mode: ${r}`)}}function getResourceLocation({flatResponse:e},t){if(typeof e==="object"){const a=e.resourceLocation;if(a!==undefined){t.config.resourceLocation=a}}return t.config.resourceLocation}function isOperationError(e){return e.name==="RestError"}async function pollHttpOperation(e){const{lro:t,stateProxy:a,options:r,processResult:i,updateState:n,setDelay:s,state:o,setErrorAsResult:p}=e;return pollOperation({state:o,stateProxy:a,setDelay:s,processResult:i?({flatResponse:e},t)=>i(e,t):({flatResponse:e})=>e,getError:getErrorFromResponse,updateState:n,getPollingInterval:parseRetryAfter,getOperationLocation:getOperationLocation,getOperationStatus:getOperationStatus,isOperationError:isOperationError,getResourceLocation:getResourceLocation,options:r,poll:async(e,a)=>t.sendPollRequest(e,a),setErrorAsResult:p})}const createStateProxy$1=()=>({initState:e=>({status:"running",config:e}),setCanceled:e=>e.status="canceled",setError:(e,t)=>e.error=t,setResult:(e,t)=>e.result=t,setRunning:e=>e.status="running",setSucceeded:e=>e.status="succeeded",setFailed:e=>e.status="failed",getError:e=>e.error,getResult:e=>e.result,isCanceled:e=>e.status==="canceled",isFailed:e=>e.status==="failed",isRunning:e=>e.status==="running",isSucceeded:e=>e.status==="succeeded"});function buildCreatePoller(e){const{getOperationLocation:t,getStatusFromInitialResponse:a,getStatusFromPollResponse:r,isOperationError:s,getResourceLocation:p,getPollingInterval:l,getError:d,resolveOnUnsuccessful:c}=e;return async({init:e,poll:m},u)=>{const{processResult:h,updateState:g,withOperationLocation:y,intervalInMs:v=o,restoreFrom:b}=u||{};const x=createStateProxy$1();const w=y?(()=>{let e=false;return(t,a)=>{if(a)y(t);else if(!e)y(t);e=true}})():undefined;const S=b?deserializeState(b):await initOperation({init:e,stateProxy:x,processResult:h,getOperationStatus:a,withOperationLocation:w,setErrorAsResult:!c});let N;const T=new i.AbortController;const E=new Map;const handleProgressEvents=async()=>E.forEach((e=>e(S)));const _="Operation was canceled";let P=v;const C={getOperationState:()=>S,getResult:()=>S.result,isDone:()=>["succeeded","failed","canceled"].includes(S.status),isStopped:()=>N===undefined,stopPolling:()=>{T.abort()},toString:()=>JSON.stringify({state:S}),onProgress:e=>{const t=Symbol();E.set(t,e);return()=>E.delete(t)},pollUntilDone:e=>N!==null&&N!==void 0?N:N=(async()=>{const{abortSignal:t}=e||{};const{signal:a}=t?new i.AbortController([t,T.signal]):T;if(!C.isDone()){await C.poll({abortSignal:a});while(!C.isDone()){await n.delay(P,{abortSignal:a});await C.poll({abortSignal:a})}}if(c){return C.getResult()}else{switch(S.status){case"succeeded":return C.getResult();case"canceled":throw new Error(_);case"failed":throw S.error;case"notStarted":case"running":throw new Error(`Polling completed without succeeding or failing`)}}})().finally((()=>{N=undefined})),async poll(e){if(c){if(C.isDone())return}else{switch(S.status){case"succeeded":return;case"canceled":throw new Error(_);case"failed":throw S.error}}await pollOperation({poll:m,state:S,stateProxy:x,getOperationLocation:t,isOperationError:s,withOperationLocation:w,getPollingInterval:l,getOperationStatus:r,getResourceLocation:p,processResult:h,getError:d,updateState:g,options:e,setDelay:e=>{P=e},setErrorAsResult:!c});await handleProgressEvents();if(!c){switch(S.status){case"canceled":throw new Error(_);case"failed":throw S.error}}}};return C}}async function createHttpPoller(e,t){const{resourceLocationConfig:a,intervalInMs:r,processResult:i,restoreFrom:n,updateState:s,withOperationLocation:o,resolveOnUnsuccessful:p=false}=t||{};return buildCreatePoller({getStatusFromInitialResponse:getStatusFromInitialResponse,getStatusFromPollResponse:getOperationStatus,isOperationError:isOperationError,getOperationLocation:getOperationLocation,getResourceLocation:getResourceLocation,getPollingInterval:parseRetryAfter,getError:getErrorFromResponse,resolveOnUnsuccessful:p})({init:async()=>{const t=await e.sendInitialRequest();const r=inferLroMode({rawResponse:t.rawResponse,requestPath:e.requestPath,requestMethod:e.requestMethod,resourceLocationConfig:a});return Object.assign({response:t,operationLocation:r===null||r===void 0?void 0:r.operationLocation,resourceLocation:r===null||r===void 0?void 0:r.resourceLocation},(r===null||r===void 0?void 0:r.mode)?{metadata:{mode:r.mode}}:{})},poll:e.sendPollRequest},{intervalInMs:r,withOperationLocation:o,restoreFrom:n,updateState:s,processResult:i?({flatResponse:e},t)=>i(e,t):({flatResponse:e})=>e})}const createStateProxy=()=>({initState:e=>({config:e,isStarted:true}),setCanceled:e=>e.isCancelled=true,setError:(e,t)=>e.error=t,setResult:(e,t)=>e.result=t,setRunning:e=>e.isStarted=true,setSucceeded:e=>e.isCompleted=true,setFailed:()=>{},getError:e=>e.error,getResult:e=>e.result,isCanceled:e=>!!e.isCancelled,isFailed:e=>!!e.error,isRunning:e=>!!e.isStarted,isSucceeded:e=>Boolean(e.isCompleted&&!e.isCancelled&&!e.error)});class GenericPollOperation{constructor(e,t,a,r,i,n,s){this.state=e;this.lro=t;this.setErrorAsResult=a;this.lroResourceLocationConfig=r;this.processResult=i;this.updateState=n;this.isDone=s}setPollerConfig(e){this.pollerConfig=e}async update(e){var t;const a=createStateProxy();if(!this.state.isStarted){this.state=Object.assign(Object.assign({},this.state),await initHttpOperation({lro:this.lro,stateProxy:a,resourceLocationConfig:this.lroResourceLocationConfig,processResult:this.processResult,setErrorAsResult:this.setErrorAsResult}))}const r=this.updateState;const i=this.isDone;if(!this.state.isCompleted&&this.state.error===undefined){await pollHttpOperation({lro:this.lro,state:this.state,stateProxy:a,processResult:this.processResult,updateState:r?(e,{rawResponse:t})=>r(e,t):undefined,isDone:i?({flatResponse:e},t)=>i(e,t):undefined,options:e,setDelay:e=>{this.pollerConfig.intervalInMs=e},setErrorAsResult:this.setErrorAsResult})}(t=e===null||e===void 0?void 0:e.fireProgress)===null||t===void 0?void 0:t.call(e,this.state);return this}async cancel(){s.error("`cancelOperation` is deprecated because it wasn't implemented");return this}toString(){return JSON.stringify({state:this.state})}}class PollerStoppedError extends Error{constructor(e){super(e);this.name="PollerStoppedError";Object.setPrototypeOf(this,PollerStoppedError.prototype)}}class PollerCancelledError extends Error{constructor(e){super(e);this.name="PollerCancelledError";Object.setPrototypeOf(this,PollerCancelledError.prototype)}}class Poller{constructor(e){this.resolveOnUnsuccessful=false;this.stopped=true;this.pollProgressCallbacks=[];this.operation=e;this.promise=new Promise(((e,t)=>{this.resolve=e;this.reject=t}));this.promise.catch((()=>{}))}async startPolling(e={}){if(this.stopped){this.stopped=false}while(!this.isStopped()&&!this.isDone()){await this.poll(e);await this.delay()}}async pollOnce(e={}){if(!this.isDone()){this.operation=await this.operation.update({abortSignal:e.abortSignal,fireProgress:this.fireProgress.bind(this)})}this.processUpdatedState()}fireProgress(e){for(const t of this.pollProgressCallbacks){t(e)}}async cancelOnce(e={}){this.operation=await this.operation.cancel(e)}poll(e={}){if(!this.pollOncePromise){this.pollOncePromise=this.pollOnce(e);const clearPollOncePromise=()=>{this.pollOncePromise=undefined};this.pollOncePromise.then(clearPollOncePromise,clearPollOncePromise).catch(this.reject)}return this.pollOncePromise}processUpdatedState(){if(this.operation.state.error){this.stopped=true;if(!this.resolveOnUnsuccessful){this.reject(this.operation.state.error);throw this.operation.state.error}}if(this.operation.state.isCancelled){this.stopped=true;if(!this.resolveOnUnsuccessful){const e=new PollerCancelledError("Operation was canceled");this.reject(e);throw e}}if(this.isDone()&&this.resolve){this.resolve(this.getResult())}}async pollUntilDone(e={}){if(this.stopped){this.startPolling(e).catch(this.reject)}this.processUpdatedState();return this.promise}onProgress(e){this.pollProgressCallbacks.push(e);return()=>{this.pollProgressCallbacks=this.pollProgressCallbacks.filter((t=>t!==e))}}isDone(){const e=this.operation.state;return Boolean(e.isCompleted||e.isCancelled||e.error)}stopPolling(){if(!this.stopped){this.stopped=true;if(this.reject){this.reject(new PollerStoppedError("This poller is already stopped"))}}}isStopped(){return this.stopped}cancelOperation(e={}){if(!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(){const e=this.operation.state;return e.result}toString(){return this.operation.toString()}}class LroEngine extends Poller{constructor(e,t){const{intervalInMs:a=o,resumeFrom:r,resolveOnUnsuccessful:i=false,isDone:n,lroResourceLocationConfig:s,processResult:p,updateState:l}=t||{};const d=r?deserializeState(r):{};const c=new GenericPollOperation(d,e,!i,s,p,l,n);super(c);this.resolveOnUnsuccessful=i;this.config={intervalInMs:a};c.setPollerConfig(this.config)}delay(){return new Promise((e=>setTimeout((()=>e()),this.config.intervalInMs)))}}t.LroEngine=LroEngine;t.Poller=Poller;t.PollerCancelledError=PollerCancelledError;t.PollerStoppedError=PollerStoppedError;t.createHttpPoller=createHttpPoller},4559:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(6429);function getPagedAsyncIterator(e){var t;const a=getItemAsyncIterator(e);return{next(){return a.next()},[Symbol.asyncIterator](){return this},byPage:(t=e===null||e===void 0?void 0:e.byPage)!==null&&t!==void 0?t:t=>{const{continuationToken:a,maxPageSize:r}=t!==null&&t!==void 0?t:{};return getPageAsyncIterator(e,{pageLink:a,maxPageSize:r})}}}function getItemAsyncIterator(e){return r.__asyncGenerator(this,arguments,(function*getItemAsyncIterator_1(){var t,a,i,n;const s=getPageAsyncIterator(e);const o=yield r.__await(s.next());if(!Array.isArray(o.value)){const{toElements:i}=e;if(i){yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(i(o.value))));try{for(var p=r.__asyncValues(s),l;l=yield r.__await(p.next()),!l.done;){const e=l.value;yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(i(e))))}}catch(e){t={error:e}}finally{try{if(l&&!l.done&&(a=p.return))yield r.__await(a.call(p))}finally{if(t)throw t.error}}}else{yield yield r.__await(o.value);yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(s)))}}else{yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(o.value)));try{for(var d=r.__asyncValues(s),c;c=yield r.__await(d.next()),!c.done;){const e=c.value;yield r.__await(yield*r.__asyncDelegator(r.__asyncValues(e)))}}catch(e){i={error:e}}finally{try{if(c&&!c.done&&(n=d.return))yield r.__await(n.call(d))}finally{if(i)throw i.error}}}}))}function getPageAsyncIterator(e,t={}){return r.__asyncGenerator(this,arguments,(function*getPageAsyncIterator_1(){const{pageLink:a,maxPageSize:i}=t;let n=yield r.__await(e.getPage(a!==null&&a!==void 0?a:e.firstPageLink,i));if(!n){return yield r.__await(void 0)}yield yield r.__await(n.page);while(n.nextPageLink){n=yield r.__await(e.getPage(n.nextPageLink,i));if(!n){return yield r.__await(void 0)}yield yield r.__await(n.page)}}))}t.getPagedAsyncIterator=getPagedAsyncIterator},6429:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var L=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);L(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var M=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new M(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},4175:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5163);(function(e){e[e["INTERNAL"]=0]="INTERNAL";e[e["SERVER"]=1]="SERVER";e[e["CLIENT"]=2]="CLIENT";e[e["PRODUCER"]=3]="PRODUCER";e[e["CONSUMER"]=4]="CONSUMER"})(t.SpanKind||(t.SpanKind={}));function getSpan(e){return r.trace.getSpan(e)}function setSpan(e,t){return r.trace.setSpan(e,t)}function setSpanContext(e,t){return r.trace.setSpanContext(e,t)}function getSpanContext(e){return r.trace.getSpanContext(e)}function isSpanContextValid(e){return r.trace.isSpanContextValid(e)}function getTracer(e,t){return r.trace.getTracer(e||"azure/core-tracing",t)}const i=r.context;(function(e){e[e["UNSET"]=0]="UNSET";e[e["OK"]=1]="OK";e[e["ERROR"]=2]="ERROR"})(t.SpanStatusCode||(t.SpanStatusCode={}));function isTracingDisabled(){var e;if(typeof process==="undefined"){return false}const t=(e=process.env.AZURE_TRACING_DISABLED)===null||e===void 0?void 0:e.toLowerCase();if(t==="false"||t==="0"){return false}return Boolean(t)}function createSpanFunction(e){return function(a,n){const s=getTracer();const o=(n===null||n===void 0?void 0:n.tracingOptions)||{};const p=Object.assign({kind:t.SpanKind.INTERNAL},o.spanOptions);const l=e.packagePrefix?`${e.packagePrefix}.${a}`:a;let d;if(isTracingDisabled()){d=r.trace.wrapSpanContext(r.INVALID_SPAN_CONTEXT)}else{d=s.startSpan(l,p,o.tracingContext)}if(e.namespace){d.setAttribute("az.namespace",e.namespace)}let c=o.spanOptions||{};if(d.isRecording()&&e.namespace){c=Object.assign(Object.assign({},o.spanOptions),{attributes:Object.assign(Object.assign({},p.attributes),{"az.namespace":e.namespace})})}const m=Object.assign(Object.assign({},o),{spanOptions:c,tracingContext:setSpan(o.tracingContext||i.active(),d)});const u=Object.assign(Object.assign({},n),{tracingOptions:m});return{span:d,updatedOptions:u}}}const n="00";function extractSpanContextFromTraceParentHeader(e){const t=e.split("-");if(t.length!==4){return}const[a,r,i,s]=t;if(a!==n){return}const o=parseInt(s,16);const p={spanId:i,traceId:r,traceFlags:o};return p}function getTraceParentHeader(e){const t=[];if(!e.traceId){t.push("traceId")}if(!e.spanId){t.push("spanId")}if(t.length){return}const a=e.traceFlags||0;const r=a.toString(16);const i=r.length===1?`0${r}`:r;return`${n}-${e.traceId}-${e.spanId}-${i}`}t.context=i;t.createSpanFunction=createSpanFunction;t.extractSpanContextFromTraceParentHeader=extractSpanContextFromTraceParentHeader;t.getSpan=getSpan;t.getSpanContext=getSpanContext;t.getTraceParentHeader=getTraceParentHeader;t.getTracer=getTracer;t.isSpanContextValid=isSpanContextValid;t.setSpan=setSpan;t.setSpanContext=setSpanContext},1333:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(2557);var i=a(6113);function createAbortablePromise(e,t){const{cleanupBeforeAbort:a,abortSignal:i,abortErrorMsg:n}=t!==null&&t!==void 0?t:{};return new Promise(((t,s)=>{function rejectOnAbort(){s(new r.AbortError(n!==null&&n!==void 0?n:"The operation was aborted."))}function removeListeners(){i===null||i===void 0?void 0:i.removeEventListener("abort",onAbort)}function onAbort(){a===null||a===void 0?void 0:a();removeListeners();rejectOnAbort()}if(i===null||i===void 0?void 0:i.aborted){return rejectOnAbort()}try{e((e=>{removeListeners();t(e)}),(e=>{removeListeners();s(e)}))}catch(e){s(e)}i===null||i===void 0?void 0:i.addEventListener("abort",onAbort)}))}const n="The delay was aborted.";function delay(e,t){let a;const{abortSignal:r,abortErrorMsg:i}=t!==null&&t!==void 0?t:{};return createAbortablePromise((t=>{a=setTimeout(t,e)}),{cleanupBeforeAbort:()=>clearTimeout(a),abortSignal:r,abortErrorMsg:i!==null&&i!==void 0?i:n})}function getRandomIntegerInclusive(e,t){e=Math.ceil(e);t=Math.floor(t);const a=Math.floor(Math.random()*(t-e+1));return a+e}function isObject(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}function isError(e){if(isObject(e)){const t=typeof e.name==="string";const a=typeof e.message==="string";return t&&a}return false}function getErrorMessage(e){if(isError(e)){return e.message}else{let t;try{if(typeof e==="object"&&e){t=JSON.stringify(e)}else{t=String(e)}}catch(e){t="[unable to stringify input]"}return`Unknown error ${t}`}}async function computeSha256Hmac(e,t,a){const r=Buffer.from(e,"base64");return i.createHmac("sha256",r).update(t).digest(a)}async function computeSha256Hash(e,t){return i.createHash("sha256").update(e).digest(t)}function isDefined(e){return typeof e!=="undefined"&&e!==null}function isObjectWithProperties(e,t){if(!isDefined(e)||typeof e!=="object"){return false}for(const a of t){if(!objectHasProperty(e,a)){return false}}return true}function objectHasProperty(e,t){return isDefined(e)&&typeof e==="object"&&t in e}function generateUUID(){let e="";for(let t=0;t<32;t++){const a=Math.floor(Math.random()*16);if(t===12){e+="4"}else if(t===16){e+=a&3|8}else{e+=a.toString(16)}if(t===7||t===11||t===15||t===19){e+="-"}}return e}var s;let o=typeof((s=globalThis===null||globalThis===void 0?void 0:globalThis.crypto)===null||s===void 0?void 0:s.randomUUID)==="function"?globalThis.crypto.randomUUID.bind(globalThis.crypto):i.randomUUID;if(!o){o=generateUUID}function randomUUID(){return o()}var p,l,d,c;const m=typeof window!=="undefined"&&typeof window.document!=="undefined";const u=typeof self==="object"&&typeof(self===null||self===void 0?void 0:self.importScripts)==="function"&&(((p=self.constructor)===null||p===void 0?void 0:p.name)==="DedicatedWorkerGlobalScope"||((l=self.constructor)===null||l===void 0?void 0:l.name)==="ServiceWorkerGlobalScope"||((d=self.constructor)===null||d===void 0?void 0:d.name)==="SharedWorkerGlobalScope");const h=typeof process!=="undefined"&&Boolean(process.version)&&Boolean((c=process.versions)===null||c===void 0?void 0:c.node);const g=typeof Deno!=="undefined"&&typeof Deno.version!=="undefined"&&typeof Deno.version.deno!=="undefined";const y=typeof Bun!=="undefined"&&typeof Bun.version!=="undefined";const v=typeof navigator!=="undefined"&&(navigator===null||navigator===void 0?void 0:navigator.product)==="ReactNative";function uint8ArrayToString(e,t){switch(t){case"utf-8":return uint8ArrayToUtf8String(e);case"base64":return uint8ArrayToBase64(e);case"base64url":return uint8ArrayToBase64Url(e)}}function stringToUint8Array(e,t){switch(t){case"utf-8":return utf8StringToUint8Array(e);case"base64":return base64ToUint8Array(e);case"base64url":return base64UrlToUint8Array(e)}}function uint8ArrayToBase64(e){return Buffer.from(e).toString("base64")}function uint8ArrayToBase64Url(e){return Buffer.from(e).toString("base64url")}function uint8ArrayToUtf8String(e){return Buffer.from(e).toString("utf-8")}function utf8StringToUint8Array(e){return Buffer.from(e)}function base64ToUint8Array(e){return Buffer.from(e,"base64")}function base64UrlToUint8Array(e){return Buffer.from(e,"base64url")}t.computeSha256Hash=computeSha256Hash;t.computeSha256Hmac=computeSha256Hmac;t.createAbortablePromise=createAbortablePromise;t.delay=delay;t.getErrorMessage=getErrorMessage;t.getRandomIntegerInclusive=getRandomIntegerInclusive;t.isBrowser=m;t.isBun=y;t.isDefined=isDefined;t.isDeno=g;t.isError=isError;t.isNode=h;t.isObject=isObject;t.isObjectWithProperties=isObjectWithProperties;t.isReactNative=v;t.isWebWorker=u;t.objectHasProperty=objectHasProperty;t.randomUUID=randomUUID;t.stringToUint8Array=stringToUint8Array;t.uint8ArrayToString=uint8ArrayToString},3233:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(2037);var i=a(3837);function _interopDefaultLegacy(e){return e&&typeof e==="object"&&"default"in e?e:{default:e}}var n=_interopDefaultLegacy(i);function log(e,...t){process.stderr.write(`${n["default"].format(e,...t)}${r.EOL}`)}const s=typeof process!=="undefined"&&process.env&&process.env.DEBUG||undefined;let o;let p=[];let l=[];const d=[];if(s){enable(s)}const c=Object.assign((e=>createDebugger(e)),{enable:enable,enabled:enabled,disable:disable,log:log});function enable(e){o=e;p=[];l=[];const t=/\*/g;const a=e.split(",").map((e=>e.trim().replace(t,".*?")));for(const e of a){if(e.startsWith("-")){l.push(new RegExp(`^${e.substr(1)}$`))}else{p.push(new RegExp(`^${e}$`))}}for(const e of d){e.enabled=enabled(e.namespace)}}function enabled(e){if(e.endsWith("*")){return true}for(const t of l){if(t.test(e)){return false}}for(const t of p){if(t.test(e)){return true}}return false}function disable(){const e=o||"";enable("");return e}function createDebugger(e){const t=Object.assign(debug,{enabled:enabled(e),destroy:destroy,log:c.log,namespace:e,extend:extend});function debug(...a){if(!t.enabled){return}if(a.length>0){a[0]=`${e} ${a[0]}`}t.log(...a)}d.push(t);return t}function destroy(){const e=d.indexOf(this);if(e>=0){d.splice(e,1);return true}return false}function extend(e){const t=createDebugger(`${this.namespace}:${e}`);t.log=this.log;return t}var m=c;const u=new Set;const h=typeof process!=="undefined"&&process.env&&process.env.AZURE_LOG_LEVEL||undefined;let g;const y=m("azure");y.log=(...e)=>{m.log(...e)};const v=["verbose","info","warning","error"];if(h){if(isAzureLogLevel(h)){setLogLevel(h)}else{console.error(`AZURE_LOG_LEVEL set to unknown log level '${h}'; logging is not enabled. Acceptable values: ${v.join(", ")}.`)}}function setLogLevel(e){if(e&&!isAzureLogLevel(e)){throw new Error(`Unknown log level '${e}'. Acceptable values: ${v.join(",")}`)}g=e;const t=[];for(const e of u){if(shouldEnable(e)){t.push(e.namespace)}}m.enable(t.join(","))}function getLogLevel(){return g}const b={verbose:400,info:300,warning:200,error:100};function createClientLogger(e){const t=y.extend(e);patchLogMethod(y,t);return{error:createLogger(t,"error"),warning:createLogger(t,"warning"),info:createLogger(t,"info"),verbose:createLogger(t,"verbose")}}function patchLogMethod(e,t){t.log=(...t)=>{e.log(...t)}}function createLogger(e,t){const a=Object.assign(e.extend(t),{level:t});patchLogMethod(e,a);if(shouldEnable(a)){const e=m.disable();m.enable(e+","+a.namespace)}u.add(a);return a}function shouldEnable(e){return Boolean(g&&b[e.level]<=b[g])}function isAzureLogLevel(e){return v.includes(e)}t.AzureLogger=y;t.createClientLogger=createClientLogger;t.getLogLevel=getLogLevel;t.setLogLevel=setLogLevel},4100:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(4607);var i=a(679);var n=a(4175);var s=a(3233);var o=a(2557);var p=a(2037);var l=a(6113);var d=a(2781);a(4559);var c=a(7094);var m=a(2361);var u=a(7147);var h=a(3837);function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(a){if(a!=="default"){var r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:true,get:function(){return e[a]}})}}))}t["default"]=e;return Object.freeze(t)}var g=_interopNamespace(r);var y=_interopNamespace(p);var v=_interopNamespace(u);var b=_interopNamespace(h);const x={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:true,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"}}}}};const w={serializedName:"Logging",type:{name:"Composite",className:"Logging",modelProperties:{version:{serializedName:"Version",required:true,xmlName:"Version",type:{name:"String"}},deleteProperty:{serializedName:"Delete",required:true,xmlName:"Delete",type:{name:"Boolean"}},read:{serializedName:"Read",required:true,xmlName:"Read",type:{name:"Boolean"}},write:{serializedName:"Write",required:true,xmlName:"Write",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}};const S={serializedName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy",modelProperties:{enabled:{serializedName:"Enabled",required:true,xmlName:"Enabled",type:{name:"Boolean"}},days:{constraints:{InclusiveMinimum:1},serializedName:"Days",xmlName:"Days",type:{name:"Number"}}}}};const N={serializedName:"Metrics",type:{name:"Composite",className:"Metrics",modelProperties:{version:{serializedName:"Version",xmlName:"Version",type:{name:"String"}},enabled:{serializedName:"Enabled",required:true,xmlName:"Enabled",type:{name:"Boolean"}},includeAPIs:{serializedName:"IncludeAPIs",xmlName:"IncludeAPIs",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}};const T={serializedName:"CorsRule",type:{name:"Composite",className:"CorsRule",modelProperties:{allowedOrigins:{serializedName:"AllowedOrigins",required:true,xmlName:"AllowedOrigins",type:{name:"String"}},allowedMethods:{serializedName:"AllowedMethods",required:true,xmlName:"AllowedMethods",type:{name:"String"}},allowedHeaders:{serializedName:"AllowedHeaders",required:true,xmlName:"AllowedHeaders",type:{name:"String"}},exposedHeaders:{serializedName:"ExposedHeaders",required:true,xmlName:"ExposedHeaders",type:{name:"String"}},maxAgeInSeconds:{constraints:{InclusiveMinimum:0},serializedName:"MaxAgeInSeconds",required:true,xmlName:"MaxAgeInSeconds",type:{name:"Number"}}}}};const E={serializedName:"StaticWebsite",type:{name:"Composite",className:"StaticWebsite",modelProperties:{enabled:{serializedName:"Enabled",required:true,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"}}}}};const _={serializedName:"StorageError",type:{name:"Composite",className:"StorageError",modelProperties:{message:{serializedName:"Message",xmlName:"Message",type:{name:"String"}},code:{serializedName:"Code",xmlName:"Code",type:{name:"String"}}}}};const P={serializedName:"BlobServiceStatistics",xmlName:"StorageServiceStats",type:{name:"Composite",className:"BlobServiceStatistics",modelProperties:{geoReplication:{serializedName:"GeoReplication",xmlName:"GeoReplication",type:{name:"Composite",className:"GeoReplication"}}}}};const C={serializedName:"GeoReplication",type:{name:"Composite",className:"GeoReplication",modelProperties:{status:{serializedName:"Status",required:true,xmlName:"Status",type:{name:"Enum",allowedValues:["live","bootstrap","unavailable"]}},lastSyncOn:{serializedName:"LastSyncTime",required:true,xmlName:"LastSyncTime",type:{name:"DateTimeRfc1123"}}}}};const O={serializedName:"ListContainersSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListContainersSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,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:true,xmlName:"Containers",xmlIsWrapped:true,xmlElementName:"Container",type:{name:"Sequence",element:{type:{name:"Composite",className:"ContainerItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const R={serializedName:"ContainerItem",xmlName:"Container",type:{name:"Composite",className:"ContainerItem",modelProperties:{name:{serializedName:"Name",required:true,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"}}}}}}};const D={serializedName:"ContainerProperties",type:{name:"Composite",className:"ContainerProperties",modelProperties:{lastModified:{serializedName:"Last-Modified",required:true,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:true,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"}}}}};const A={serializedName:"KeyInfo",type:{name:"Composite",className:"KeyInfo",modelProperties:{startsOn:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"String"}},expiresOn:{serializedName:"Expiry",required:true,xmlName:"Expiry",type:{name:"String"}}}}};const I={serializedName:"UserDelegationKey",type:{name:"Composite",className:"UserDelegationKey",modelProperties:{signedObjectId:{serializedName:"SignedOid",required:true,xmlName:"SignedOid",type:{name:"String"}},signedTenantId:{serializedName:"SignedTid",required:true,xmlName:"SignedTid",type:{name:"String"}},signedStartsOn:{serializedName:"SignedStart",required:true,xmlName:"SignedStart",type:{name:"String"}},signedExpiresOn:{serializedName:"SignedExpiry",required:true,xmlName:"SignedExpiry",type:{name:"String"}},signedService:{serializedName:"SignedService",required:true,xmlName:"SignedService",type:{name:"String"}},signedVersion:{serializedName:"SignedVersion",required:true,xmlName:"SignedVersion",type:{name:"String"}},value:{serializedName:"Value",required:true,xmlName:"Value",type:{name:"String"}}}}};const L={serializedName:"FilterBlobSegment",xmlName:"EnumerationResults",type:{name:"Composite",className:"FilterBlobSegment",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},where:{serializedName:"Where",required:true,xmlName:"Where",type:{name:"String"}},blobs:{serializedName:"Blobs",required:true,xmlName:"Blobs",xmlIsWrapped:true,xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"FilterBlobItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const M={serializedName:"FilterBlobItem",xmlName:"Blob",type:{name:"Composite",className:"FilterBlobItem",modelProperties:{name:{serializedName:"Name",required:true,xmlName:"Name",type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",type:{name:"String"}},tags:{serializedName:"Tags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags"}}}}};const B={serializedName:"BlobTags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags",modelProperties:{blobTagSet:{serializedName:"BlobTagSet",required:true,xmlName:"TagSet",xmlIsWrapped:true,xmlElementName:"Tag",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobTag"}}}}}}};const k={serializedName:"BlobTag",xmlName:"Tag",type:{name:"Composite",className:"BlobTag",modelProperties:{key:{serializedName:"Key",required:true,xmlName:"Key",type:{name:"String"}},value:{serializedName:"Value",required:true,xmlName:"Value",type:{name:"String"}}}}};const z={serializedName:"SignedIdentifier",xmlName:"SignedIdentifier",type:{name:"Composite",className:"SignedIdentifier",modelProperties:{id:{serializedName:"Id",required:true,xmlName:"Id",type:{name:"String"}},accessPolicy:{serializedName:"AccessPolicy",xmlName:"AccessPolicy",type:{name:"Composite",className:"AccessPolicy"}}}}};const j={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"}}}}};const q={serializedName:"ListBlobsFlatSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsFlatSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",xmlIsAttribute:true,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"}}}}};const U={serializedName:"BlobFlatListSegment",xmlName:"Blobs",type:{name:"Composite",className:"BlobFlatListSegment",modelProperties:{blobItems:{serializedName:"BlobItems",required:true,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}};const H={serializedName:"BlobItemInternal",xmlName:"Blob",type:{name:"Composite",className:"BlobItemInternal",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}},deleted:{serializedName:"Deleted",required:true,xmlName:"Deleted",type:{name:"Boolean"}},snapshot:{serializedName:"Snapshot",required:true,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"}}}}};const V={serializedName:"BlobName",type:{name:"Composite",className:"BlobName",modelProperties:{encoded:{serializedName:"Encoded",xmlName:"Encoded",xmlIsAttribute:true,type:{name:"Boolean"}},content:{serializedName:"content",xmlName:"content",xmlIsMsText:true,type:{name:"String"}}}}};const G={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:true,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:true,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","Cold"]}},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"}}}}};const $={serializedName:"ListBlobsHierarchySegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsHierarchySegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:true,xmlName:"ServiceEndpoint",xmlIsAttribute:true,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:true,xmlName:"ContainerName",xmlIsAttribute:true,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"}}}}};const X={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:true,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}};const W={serializedName:"BlobPrefix",type:{name:"Composite",className:"BlobPrefix",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}}}}};const K={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"}}}}}}};const Q={serializedName:"BlockList",type:{name:"Composite",className:"BlockList",modelProperties:{committedBlocks:{serializedName:"CommittedBlocks",xmlName:"CommittedBlocks",xmlIsWrapped:true,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}},uncommittedBlocks:{serializedName:"UncommittedBlocks",xmlName:"UncommittedBlocks",xmlIsWrapped:true,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}}}}};const Y={serializedName:"Block",type:{name:"Composite",className:"Block",modelProperties:{name:{serializedName:"Name",required:true,xmlName:"Name",type:{name:"String"}},size:{serializedName:"Size",required:true,xmlName:"Size",type:{name:"Number"}}}}};const J={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"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}};const Z={serializedName:"PageRange",xmlName:"PageRange",type:{name:"Composite",className:"PageRange",modelProperties:{start:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:true,xmlName:"End",type:{name:"Number"}}}}};const ee={serializedName:"ClearRange",xmlName:"ClearRange",type:{name:"Composite",className:"ClearRange",modelProperties:{start:{serializedName:"Start",required:true,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:true,xmlName:"End",type:{name:"Number"}}}}};const te={serializedName:"QueryRequest",xmlName:"QueryRequest",type:{name:"Composite",className:"QueryRequest",modelProperties:{queryType:{serializedName:"QueryType",required:true,xmlName:"QueryType",type:{name:"String"}},expression:{serializedName:"Expression",required:true,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"}}}}};const ae={serializedName:"QuerySerialization",type:{name:"Composite",className:"QuerySerialization",modelProperties:{format:{serializedName:"Format",xmlName:"Format",type:{name:"Composite",className:"QueryFormat"}}}}};const re={serializedName:"QueryFormat",type:{name:"Composite",className:"QueryFormat",modelProperties:{type:{serializedName:"Type",required:true,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"}}}}};const ie={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"}}}}};const ne={serializedName:"JsonTextConfiguration",xmlName:"JsonTextConfiguration",type:{name:"Composite",className:"JsonTextConfiguration",modelProperties:{recordSeparator:{serializedName:"RecordSeparator",xmlName:"RecordSeparator",type:{name:"String"}}}}};const se={serializedName:"ArrowConfiguration",xmlName:"ArrowConfiguration",type:{name:"Composite",className:"ArrowConfiguration",modelProperties:{schema:{serializedName:"Schema",required:true,xmlName:"Schema",xmlIsWrapped:true,xmlElementName:"Field",type:{name:"Sequence",element:{type:{name:"Composite",className:"ArrowField"}}}}}}};const oe={serializedName:"ArrowField",xmlName:"Field",type:{name:"Composite",className:"ArrowField",modelProperties:{type:{serializedName:"Type",required:true,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"}}}}};const pe={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"}}}}};const le={serializedName:"Service_setPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceSetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const de={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"}}}}};const ce={serializedName:"Service_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const me={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"}}}}};const ue={serializedName:"Service_getStatisticsExceptionHeaders",type:{name:"Composite",className:"ServiceGetStatisticsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const fe={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"}}}}};const he={serializedName:"Service_listContainersSegmentExceptionHeaders",type:{name:"Composite",className:"ServiceListContainersSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ge={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"}}}}};const ye={serializedName:"Service_getUserDelegationKeyExceptionHeaders",type:{name:"Composite",className:"ServiceGetUserDelegationKeyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ve={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"}}}}};const be={serializedName:"Service_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ServiceGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const xe={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"}}}}};const we={serializedName:"Service_submitBatchExceptionHeaders",type:{name:"Composite",className:"ServiceSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Se={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"}}}}};const Ne={serializedName:"Service_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ServiceFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Te={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"}}}}};const Ee={serializedName:"Container_createExceptionHeaders",type:{name:"Composite",className:"ContainerCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const _e={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"}}}}};const Pe={serializedName:"Container_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ContainerGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ce={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"}}}}};const Oe={serializedName:"Container_deleteExceptionHeaders",type:{name:"Composite",className:"ContainerDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Re={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"}}}}};const De={serializedName:"Container_setMetadataExceptionHeaders",type:{name:"Composite",className:"ContainerSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ae={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"}}}}};const Ie={serializedName:"Container_getAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Le={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"}}}}};const Me={serializedName:"Container_setAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerSetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Be={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"}}}}};const ke={serializedName:"Container_restoreExceptionHeaders",type:{name:"Composite",className:"ContainerRestoreExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ze={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"}}}}};const je={serializedName:"Container_renameExceptionHeaders",type:{name:"Composite",className:"ContainerRenameExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const qe={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"}}}}};const Ue={serializedName:"Container_submitBatchExceptionHeaders",type:{name:"Composite",className:"ContainerSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Fe={serializedName:"Container_filterBlobsHeaders",type:{name:"Composite",className:"ContainerFilterBlobsHeaders",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"}}}}};const He={serializedName:"Container_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ContainerFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ve={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"}}}}};const Ge={serializedName:"Container_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const $e={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"}}}}};const Xe={serializedName:"Container_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const We={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"}}}}};const Ke={serializedName:"Container_renewLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Qe={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"}}}}};const Ye={serializedName:"Container_breakLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Je={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"}}}}};const Ze={serializedName:"Container_changeLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const et={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"}}}}};const tt={serializedName:"Container_listBlobFlatSegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobFlatSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const rt={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"}}}}};const it={serializedName:"Container_listBlobHierarchySegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobHierarchySegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const nt={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"]}}}}};const st={serializedName:"Container_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ot={serializedName:"Blob_downloadHeaders",type:{name:"Composite",className:"BlobDownloadHeaders",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-"},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"}}}}};const pt={serializedName:"Blob_downloadExceptionHeaders",type:{name:"Composite",className:"BlobDownloadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const dt={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"}}}}};const ct={serializedName:"Blob_getPropertiesExceptionHeaders",type:{name:"Composite",className:"BlobGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const mt={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"}}}}};const ut={serializedName:"Blob_deleteExceptionHeaders",type:{name:"Composite",className:"BlobDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ft={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"}}}}};const ht={serializedName:"Blob_undeleteExceptionHeaders",type:{name:"Composite",className:"BlobUndeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const yt={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"}}}}};const vt={serializedName:"Blob_setExpiryExceptionHeaders",type:{name:"Composite",className:"BlobSetExpiryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const bt={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"}}}}};const xt={serializedName:"Blob_setHttpHeadersExceptionHeaders",type:{name:"Composite",className:"BlobSetHttpHeadersExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const wt={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"]}}}}};const St={serializedName:"Blob_setImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobSetImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Nt={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"}}}}};const Tt={serializedName:"Blob_deleteImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobDeleteImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Et={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"}}}}};const _t={serializedName:"Blob_setLegalHoldExceptionHeaders",type:{name:"Composite",className:"BlobSetLegalHoldExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Pt={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"}}}}};const Ct={serializedName:"Blob_setMetadataExceptionHeaders",type:{name:"Composite",className:"BlobSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ot={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"}}}}};const Rt={serializedName:"Blob_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"BlobAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Dt={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"}}}}};const At={serializedName:"Blob_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"BlobReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const It={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"}}}}};const Lt={serializedName:"Blob_renewLeaseExceptionHeaders",type:{name:"Composite",className:"BlobRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Mt={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"}}}}};const Bt={serializedName:"Blob_changeLeaseExceptionHeaders",type:{name:"Composite",className:"BlobChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const kt={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"}}}}};const zt={serializedName:"Blob_breakLeaseExceptionHeaders",type:{name:"Composite",className:"BlobBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const jt={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"}}}}};const qt={serializedName:"Blob_createSnapshotExceptionHeaders",type:{name:"Composite",className:"BlobCreateSnapshotExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ut={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"}}}}};const Ft={serializedName:"Blob_startCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobStartCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ht={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:true,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"}},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"}}}}};const Vt={serializedName:"Blob_copyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Gt={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"}}}}};const $t={serializedName:"Blob_abortCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobAbortCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Xt={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"}}}}};const Wt={serializedName:"Blob_setTierExceptionHeaders",type:{name:"Composite",className:"BlobSetTierExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Kt={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"]}}}}};const Qt={serializedName:"Blob_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"BlobGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Yt={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"}}}}};const Jt={serializedName:"Blob_queryExceptionHeaders",type:{name:"Composite",className:"BlobQueryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Zt={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"}}}}};const ea={serializedName:"Blob_getTagsExceptionHeaders",type:{name:"Composite",className:"BlobGetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ta={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"}}}}};const aa={serializedName:"Blob_setTagsExceptionHeaders",type:{name:"Composite",className:"BlobSetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ra={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"}}}}};const ia={serializedName:"PageBlob_createExceptionHeaders",type:{name:"Composite",className:"PageBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const na={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"}}}}};const sa={serializedName:"PageBlob_uploadPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const oa={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"}}}}};const pa={serializedName:"PageBlob_clearPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobClearPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const la={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"}}}}};const da={serializedName:"PageBlob_uploadPagesFromURLExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ca={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"}}}}};const ma={serializedName:"PageBlob_getPageRangesExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ua={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"}}}}};const fa={serializedName:"PageBlob_getPageRangesDiffExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesDiffExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ha={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"}}}}};const ga={serializedName:"PageBlob_resizeExceptionHeaders",type:{name:"Composite",className:"PageBlobResizeExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ya={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"}}}}};const va={serializedName:"PageBlob_updateSequenceNumberExceptionHeaders",type:{name:"Composite",className:"PageBlobUpdateSequenceNumberExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ba={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"}}}}};const xa={serializedName:"PageBlob_copyIncrementalExceptionHeaders",type:{name:"Composite",className:"PageBlobCopyIncrementalExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const wa={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"}}}}};const Sa={serializedName:"AppendBlob_createExceptionHeaders",type:{name:"Composite",className:"AppendBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Na={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"}}}}};const Ta={serializedName:"AppendBlob_appendBlockExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ea={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"}}}}};const _a={serializedName:"AppendBlob_appendBlockFromUrlExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Pa={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"}}}}};const Ca={serializedName:"AppendBlob_sealExceptionHeaders",type:{name:"Composite",className:"AppendBlobSealExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Oa={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"}}}}};const Ra={serializedName:"BlockBlob_uploadExceptionHeaders",type:{name:"Composite",className:"BlockBlobUploadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Da={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"}}}}};const Aa={serializedName:"BlockBlob_putBlobFromUrlExceptionHeaders",type:{name:"Composite",className:"BlockBlobPutBlobFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ia={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"}}}}};const La={serializedName:"BlockBlob_stageBlockExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const Ma={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"}}}}};const Ba={serializedName:"BlockBlob_stageBlockFromURLExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ka={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"}}}}};const za={serializedName:"BlockBlob_commitBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobCommitBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};const ja={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"}}}}};const qa={serializedName:"BlockBlob_getBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobGetBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}};var Ua=Object.freeze({__proto__:null,BlobServiceProperties:x,Logging:w,RetentionPolicy:S,Metrics:N,CorsRule:T,StaticWebsite:E,StorageError:_,BlobServiceStatistics:P,GeoReplication:C,ListContainersSegmentResponse:O,ContainerItem:R,ContainerProperties:D,KeyInfo:A,UserDelegationKey:I,FilterBlobSegment:L,FilterBlobItem:M,BlobTags:B,BlobTag:k,SignedIdentifier:z,AccessPolicy:j,ListBlobsFlatSegmentResponse:q,BlobFlatListSegment:U,BlobItemInternal:H,BlobName:V,BlobPropertiesInternal:G,ListBlobsHierarchySegmentResponse:$,BlobHierarchyListSegment:X,BlobPrefix:W,BlockLookupList:K,BlockList:Q,Block:Y,PageList:J,PageRange:Z,ClearRange:ee,QueryRequest:te,QuerySerialization:ae,QueryFormat:re,DelimitedTextConfiguration:ie,JsonTextConfiguration:ne,ArrowConfiguration:se,ArrowField:oe,ServiceSetPropertiesHeaders:pe,ServiceSetPropertiesExceptionHeaders:le,ServiceGetPropertiesHeaders:de,ServiceGetPropertiesExceptionHeaders:ce,ServiceGetStatisticsHeaders:me,ServiceGetStatisticsExceptionHeaders:ue,ServiceListContainersSegmentHeaders:fe,ServiceListContainersSegmentExceptionHeaders:he,ServiceGetUserDelegationKeyHeaders:ge,ServiceGetUserDelegationKeyExceptionHeaders:ye,ServiceGetAccountInfoHeaders:ve,ServiceGetAccountInfoExceptionHeaders:be,ServiceSubmitBatchHeaders:xe,ServiceSubmitBatchExceptionHeaders:we,ServiceFilterBlobsHeaders:Se,ServiceFilterBlobsExceptionHeaders:Ne,ContainerCreateHeaders:Te,ContainerCreateExceptionHeaders:Ee,ContainerGetPropertiesHeaders:_e,ContainerGetPropertiesExceptionHeaders:Pe,ContainerDeleteHeaders:Ce,ContainerDeleteExceptionHeaders:Oe,ContainerSetMetadataHeaders:Re,ContainerSetMetadataExceptionHeaders:De,ContainerGetAccessPolicyHeaders:Ae,ContainerGetAccessPolicyExceptionHeaders:Ie,ContainerSetAccessPolicyHeaders:Le,ContainerSetAccessPolicyExceptionHeaders:Me,ContainerRestoreHeaders:Be,ContainerRestoreExceptionHeaders:ke,ContainerRenameHeaders:ze,ContainerRenameExceptionHeaders:je,ContainerSubmitBatchHeaders:qe,ContainerSubmitBatchExceptionHeaders:Ue,ContainerFilterBlobsHeaders:Fe,ContainerFilterBlobsExceptionHeaders:He,ContainerAcquireLeaseHeaders:Ve,ContainerAcquireLeaseExceptionHeaders:Ge,ContainerReleaseLeaseHeaders:$e,ContainerReleaseLeaseExceptionHeaders:Xe,ContainerRenewLeaseHeaders:We,ContainerRenewLeaseExceptionHeaders:Ke,ContainerBreakLeaseHeaders:Qe,ContainerBreakLeaseExceptionHeaders:Ye,ContainerChangeLeaseHeaders:Je,ContainerChangeLeaseExceptionHeaders:Ze,ContainerListBlobFlatSegmentHeaders:et,ContainerListBlobFlatSegmentExceptionHeaders:tt,ContainerListBlobHierarchySegmentHeaders:rt,ContainerListBlobHierarchySegmentExceptionHeaders:it,ContainerGetAccountInfoHeaders:nt,ContainerGetAccountInfoExceptionHeaders:st,BlobDownloadHeaders:ot,BlobDownloadExceptionHeaders:pt,BlobGetPropertiesHeaders:dt,BlobGetPropertiesExceptionHeaders:ct,BlobDeleteHeaders:mt,BlobDeleteExceptionHeaders:ut,BlobUndeleteHeaders:ft,BlobUndeleteExceptionHeaders:ht,BlobSetExpiryHeaders:yt,BlobSetExpiryExceptionHeaders:vt,BlobSetHttpHeadersHeaders:bt,BlobSetHttpHeadersExceptionHeaders:xt,BlobSetImmutabilityPolicyHeaders:wt,BlobSetImmutabilityPolicyExceptionHeaders:St,BlobDeleteImmutabilityPolicyHeaders:Nt,BlobDeleteImmutabilityPolicyExceptionHeaders:Tt,BlobSetLegalHoldHeaders:Et,BlobSetLegalHoldExceptionHeaders:_t,BlobSetMetadataHeaders:Pt,BlobSetMetadataExceptionHeaders:Ct,BlobAcquireLeaseHeaders:Ot,BlobAcquireLeaseExceptionHeaders:Rt,BlobReleaseLeaseHeaders:Dt,BlobReleaseLeaseExceptionHeaders:At,BlobRenewLeaseHeaders:It,BlobRenewLeaseExceptionHeaders:Lt,BlobChangeLeaseHeaders:Mt,BlobChangeLeaseExceptionHeaders:Bt,BlobBreakLeaseHeaders:kt,BlobBreakLeaseExceptionHeaders:zt,BlobCreateSnapshotHeaders:jt,BlobCreateSnapshotExceptionHeaders:qt,BlobStartCopyFromURLHeaders:Ut,BlobStartCopyFromURLExceptionHeaders:Ft,BlobCopyFromURLHeaders:Ht,BlobCopyFromURLExceptionHeaders:Vt,BlobAbortCopyFromURLHeaders:Gt,BlobAbortCopyFromURLExceptionHeaders:$t,BlobSetTierHeaders:Xt,BlobSetTierExceptionHeaders:Wt,BlobGetAccountInfoHeaders:Kt,BlobGetAccountInfoExceptionHeaders:Qt,BlobQueryHeaders:Yt,BlobQueryExceptionHeaders:Jt,BlobGetTagsHeaders:Zt,BlobGetTagsExceptionHeaders:ea,BlobSetTagsHeaders:ta,BlobSetTagsExceptionHeaders:aa,PageBlobCreateHeaders:ra,PageBlobCreateExceptionHeaders:ia,PageBlobUploadPagesHeaders:na,PageBlobUploadPagesExceptionHeaders:sa,PageBlobClearPagesHeaders:oa,PageBlobClearPagesExceptionHeaders:pa,PageBlobUploadPagesFromURLHeaders:la,PageBlobUploadPagesFromURLExceptionHeaders:da,PageBlobGetPageRangesHeaders:ca,PageBlobGetPageRangesExceptionHeaders:ma,PageBlobGetPageRangesDiffHeaders:ua,PageBlobGetPageRangesDiffExceptionHeaders:fa,PageBlobResizeHeaders:ha,PageBlobResizeExceptionHeaders:ga,PageBlobUpdateSequenceNumberHeaders:ya,PageBlobUpdateSequenceNumberExceptionHeaders:va,PageBlobCopyIncrementalHeaders:ba,PageBlobCopyIncrementalExceptionHeaders:xa,AppendBlobCreateHeaders:wa,AppendBlobCreateExceptionHeaders:Sa,AppendBlobAppendBlockHeaders:Na,AppendBlobAppendBlockExceptionHeaders:Ta,AppendBlobAppendBlockFromUrlHeaders:Ea,AppendBlobAppendBlockFromUrlExceptionHeaders:_a,AppendBlobSealHeaders:Pa,AppendBlobSealExceptionHeaders:Ca,BlockBlobUploadHeaders:Oa,BlockBlobUploadExceptionHeaders:Ra,BlockBlobPutBlobFromUrlHeaders:Da,BlockBlobPutBlobFromUrlExceptionHeaders:Aa,BlockBlobStageBlockHeaders:Ia,BlockBlobStageBlockExceptionHeaders:La,BlockBlobStageBlockFromURLHeaders:Ma,BlockBlobStageBlockFromURLExceptionHeaders:Ba,BlockBlobCommitBlockListHeaders:ka,BlockBlobCommitBlockListExceptionHeaders:za,BlockBlobGetBlockListHeaders:ja,BlockBlobGetBlockListExceptionHeaders:qa});const Fa={parameterPath:["options","contentType"],mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Content-Type",type:{name:"String"}}};const Ha={parameterPath:"blobServiceProperties",mapper:x};const Va={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Ga={parameterPath:"url",mapper:{serializedName:"url",required:true,xmlName:"url",type:{name:"String"}},skipEncoding:true};const $a={parameterPath:"restype",mapper:{defaultValue:"service",isConstant:true,serializedName:"restype",type:{name:"String"}}};const Xa={parameterPath:"comp",mapper:{defaultValue:"properties",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Wa={parameterPath:["options","timeoutInSeconds"],mapper:{constraints:{InclusiveMinimum:0},serializedName:"timeout",xmlName:"timeout",type:{name:"Number"}}};const Ka={parameterPath:"version",mapper:{defaultValue:"2023-01-03",isConstant:true,serializedName:"x-ms-version",type:{name:"String"}}};const Qa={parameterPath:["options","requestId"],mapper:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}}};const Ya={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Ja={parameterPath:"comp",mapper:{defaultValue:"stats",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Za={parameterPath:"comp",mapper:{defaultValue:"list",isConstant:true,serializedName:"comp",type:{name:"String"}}};const er={parameterPath:["options","prefix"],mapper:{serializedName:"prefix",xmlName:"prefix",type:{name:"String"}}};const tr={parameterPath:["options","marker"],mapper:{serializedName:"marker",xmlName:"marker",type:{name:"String"}}};const ar={parameterPath:["options","maxPageSize"],mapper:{constraints:{InclusiveMinimum:1},serializedName:"maxresults",xmlName:"maxresults",type:{name:"Number"}}};const rr={parameterPath:["options","include"],mapper:{serializedName:"include",xmlName:"include",xmlElementName:"ListContainersIncludeType",type:{name:"Sequence",element:{type:{name:"Enum",allowedValues:["metadata","deleted","system"]}}}},collectionFormat:r.QueryCollectionFormat.Csv};const ir={parameterPath:"keyInfo",mapper:A};const nr={parameterPath:"comp",mapper:{defaultValue:"userdelegationkey",isConstant:true,serializedName:"comp",type:{name:"String"}}};const sr={parameterPath:"restype",mapper:{defaultValue:"account",isConstant:true,serializedName:"restype",type:{name:"String"}}};const or={parameterPath:"body",mapper:{serializedName:"body",required:true,xmlName:"body",type:{name:"Stream"}}};const pr={parameterPath:"comp",mapper:{defaultValue:"batch",isConstant:true,serializedName:"comp",type:{name:"String"}}};const lr={parameterPath:"contentLength",mapper:{serializedName:"Content-Length",required:true,xmlName:"Content-Length",type:{name:"Number"}}};const dr={parameterPath:"multipartContentType",mapper:{serializedName:"Content-Type",required:true,xmlName:"Content-Type",type:{name:"String"}}};const cr={parameterPath:"comp",mapper:{defaultValue:"blobs",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mr={parameterPath:["options","where"],mapper:{serializedName:"where",xmlName:"where",type:{name:"String"}}};const ur={parameterPath:"restype",mapper:{defaultValue:"container",isConstant:true,serializedName:"restype",type:{name:"String"}}};const fr={parameterPath:["options","metadata"],mapper:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}},headerCollectionPrefix:"x-ms-meta-"}};const hr={parameterPath:["options","access"],mapper:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}}};const gr={parameterPath:["options","containerEncryptionScope","defaultEncryptionScope"],mapper:{serializedName:"x-ms-default-encryption-scope",xmlName:"x-ms-default-encryption-scope",type:{name:"String"}}};const yr={parameterPath:["options","containerEncryptionScope","preventEncryptionScopeOverride"],mapper:{serializedName:"x-ms-deny-encryption-scope-override",xmlName:"x-ms-deny-encryption-scope-override",type:{name:"Boolean"}}};const vr={parameterPath:["options","leaseAccessConditions","leaseId"],mapper:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}}};const br={parameterPath:["options","modifiedAccessConditions","ifModifiedSince"],mapper:{serializedName:"If-Modified-Since",xmlName:"If-Modified-Since",type:{name:"DateTimeRfc1123"}}};const xr={parameterPath:["options","modifiedAccessConditions","ifUnmodifiedSince"],mapper:{serializedName:"If-Unmodified-Since",xmlName:"If-Unmodified-Since",type:{name:"DateTimeRfc1123"}}};const wr={parameterPath:"comp",mapper:{defaultValue:"metadata",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Sr={parameterPath:"comp",mapper:{defaultValue:"acl",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Nr={parameterPath:["options","containerAcl"],mapper:{serializedName:"containerAcl",xmlName:"SignedIdentifiers",xmlIsWrapped:true,xmlElementName:"SignedIdentifier",type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}}}};const Tr={parameterPath:"comp",mapper:{defaultValue:"undelete",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Er={parameterPath:["options","deletedContainerName"],mapper:{serializedName:"x-ms-deleted-container-name",xmlName:"x-ms-deleted-container-name",type:{name:"String"}}};const _r={parameterPath:["options","deletedContainerVersion"],mapper:{serializedName:"x-ms-deleted-container-version",xmlName:"x-ms-deleted-container-version",type:{name:"String"}}};const Pr={parameterPath:"comp",mapper:{defaultValue:"rename",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Cr={parameterPath:"sourceContainerName",mapper:{serializedName:"x-ms-source-container-name",required:true,xmlName:"x-ms-source-container-name",type:{name:"String"}}};const Or={parameterPath:["options","sourceLeaseId"],mapper:{serializedName:"x-ms-source-lease-id",xmlName:"x-ms-source-lease-id",type:{name:"String"}}};const Rr={parameterPath:"comp",mapper:{defaultValue:"lease",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Dr={parameterPath:"action",mapper:{defaultValue:"acquire",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const Ar={parameterPath:["options","duration"],mapper:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Number"}}};const Ir={parameterPath:["options","proposedLeaseId"],mapper:{serializedName:"x-ms-proposed-lease-id",xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}};const Lr={parameterPath:"action",mapper:{defaultValue:"release",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const Mr={parameterPath:"leaseId",mapper:{serializedName:"x-ms-lease-id",required:true,xmlName:"x-ms-lease-id",type:{name:"String"}}};const Br={parameterPath:"action",mapper:{defaultValue:"renew",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const kr={parameterPath:"action",mapper:{defaultValue:"break",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const zr={parameterPath:["options","breakPeriod"],mapper:{serializedName:"x-ms-lease-break-period",xmlName:"x-ms-lease-break-period",type:{name:"Number"}}};const jr={parameterPath:"action",mapper:{defaultValue:"change",isConstant:true,serializedName:"x-ms-lease-action",type:{name:"String"}}};const qr={parameterPath:"proposedLeaseId",mapper:{serializedName:"x-ms-proposed-lease-id",required:true,xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}};const Ur={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:r.QueryCollectionFormat.Csv};const Fr={parameterPath:"delimiter",mapper:{serializedName:"delimiter",required:true,xmlName:"delimiter",type:{name:"String"}}};const Hr={parameterPath:["options","snapshot"],mapper:{serializedName:"snapshot",xmlName:"snapshot",type:{name:"String"}}};const Vr={parameterPath:["options","versionId"],mapper:{serializedName:"versionid",xmlName:"versionid",type:{name:"String"}}};const Gr={parameterPath:["options","range"],mapper:{serializedName:"x-ms-range",xmlName:"x-ms-range",type:{name:"String"}}};const $r={parameterPath:["options","rangeGetContentMD5"],mapper:{serializedName:"x-ms-range-get-content-md5",xmlName:"x-ms-range-get-content-md5",type:{name:"Boolean"}}};const Xr={parameterPath:["options","rangeGetContentCRC64"],mapper:{serializedName:"x-ms-range-get-content-crc64",xmlName:"x-ms-range-get-content-crc64",type:{name:"Boolean"}}};const Wr={parameterPath:["options","cpkInfo","encryptionKey"],mapper:{serializedName:"x-ms-encryption-key",xmlName:"x-ms-encryption-key",type:{name:"String"}}};const Kr={parameterPath:["options","cpkInfo","encryptionKeySha256"],mapper:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}}};const Qr={parameterPath:["options","cpkInfo","encryptionAlgorithm"],mapper:{serializedName:"x-ms-encryption-algorithm",xmlName:"x-ms-encryption-algorithm",type:{name:"String"}}};const Yr={parameterPath:["options","modifiedAccessConditions","ifMatch"],mapper:{serializedName:"If-Match",xmlName:"If-Match",type:{name:"String"}}};const Jr={parameterPath:["options","modifiedAccessConditions","ifNoneMatch"],mapper:{serializedName:"If-None-Match",xmlName:"If-None-Match",type:{name:"String"}}};const Zr={parameterPath:["options","modifiedAccessConditions","ifTags"],mapper:{serializedName:"x-ms-if-tags",xmlName:"x-ms-if-tags",type:{name:"String"}}};const ei={parameterPath:["options","deleteSnapshots"],mapper:{serializedName:"x-ms-delete-snapshots",xmlName:"x-ms-delete-snapshots",type:{name:"Enum",allowedValues:["include","only"]}}};const ti={parameterPath:["options","blobDeleteType"],mapper:{serializedName:"deletetype",xmlName:"deletetype",type:{name:"String"}}};const ai={parameterPath:"comp",mapper:{defaultValue:"expiry",isConstant:true,serializedName:"comp",type:{name:"String"}}};const ri={parameterPath:"expiryOptions",mapper:{serializedName:"x-ms-expiry-option",required:true,xmlName:"x-ms-expiry-option",type:{name:"String"}}};const ii={parameterPath:["options","expiresOn"],mapper:{serializedName:"x-ms-expiry-time",xmlName:"x-ms-expiry-time",type:{name:"String"}}};const ni={parameterPath:["options","blobHttpHeaders","blobCacheControl"],mapper:{serializedName:"x-ms-blob-cache-control",xmlName:"x-ms-blob-cache-control",type:{name:"String"}}};const si={parameterPath:["options","blobHttpHeaders","blobContentType"],mapper:{serializedName:"x-ms-blob-content-type",xmlName:"x-ms-blob-content-type",type:{name:"String"}}};const oi={parameterPath:["options","blobHttpHeaders","blobContentMD5"],mapper:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}}};const pi={parameterPath:["options","blobHttpHeaders","blobContentEncoding"],mapper:{serializedName:"x-ms-blob-content-encoding",xmlName:"x-ms-blob-content-encoding",type:{name:"String"}}};const li={parameterPath:["options","blobHttpHeaders","blobContentLanguage"],mapper:{serializedName:"x-ms-blob-content-language",xmlName:"x-ms-blob-content-language",type:{name:"String"}}};const di={parameterPath:["options","blobHttpHeaders","blobContentDisposition"],mapper:{serializedName:"x-ms-blob-content-disposition",xmlName:"x-ms-blob-content-disposition",type:{name:"String"}}};const ci={parameterPath:"comp",mapper:{defaultValue:"immutabilityPolicies",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mi={parameterPath:["options","immutabilityPolicyExpiry"],mapper:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}}};const ui={parameterPath:["options","immutabilityPolicyMode"],mapper:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}}};const fi={parameterPath:"comp",mapper:{defaultValue:"legalhold",isConstant:true,serializedName:"comp",type:{name:"String"}}};const hi={parameterPath:"legalHold",mapper:{serializedName:"x-ms-legal-hold",required:true,xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}};const gi={parameterPath:["options","encryptionScope"],mapper:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}}};const yi={parameterPath:"comp",mapper:{defaultValue:"snapshot",isConstant:true,serializedName:"comp",type:{name:"String"}}};const vi={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","Cold"]}}};const bi={parameterPath:["options","rehydratePriority"],mapper:{serializedName:"x-ms-rehydrate-priority",xmlName:"x-ms-rehydrate-priority",type:{name:"Enum",allowedValues:["High","Standard"]}}};const xi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfModifiedSince"],mapper:{serializedName:"x-ms-source-if-modified-since",xmlName:"x-ms-source-if-modified-since",type:{name:"DateTimeRfc1123"}}};const wi={parameterPath:["options","sourceModifiedAccessConditions","sourceIfUnmodifiedSince"],mapper:{serializedName:"x-ms-source-if-unmodified-since",xmlName:"x-ms-source-if-unmodified-since",type:{name:"DateTimeRfc1123"}}};const Si={parameterPath:["options","sourceModifiedAccessConditions","sourceIfMatch"],mapper:{serializedName:"x-ms-source-if-match",xmlName:"x-ms-source-if-match",type:{name:"String"}}};const Ni={parameterPath:["options","sourceModifiedAccessConditions","sourceIfNoneMatch"],mapper:{serializedName:"x-ms-source-if-none-match",xmlName:"x-ms-source-if-none-match",type:{name:"String"}}};const Ti={parameterPath:["options","sourceModifiedAccessConditions","sourceIfTags"],mapper:{serializedName:"x-ms-source-if-tags",xmlName:"x-ms-source-if-tags",type:{name:"String"}}};const Ei={parameterPath:"copySource",mapper:{serializedName:"x-ms-copy-source",required:true,xmlName:"x-ms-copy-source",type:{name:"String"}}};const _i={parameterPath:["options","blobTagsString"],mapper:{serializedName:"x-ms-tags",xmlName:"x-ms-tags",type:{name:"String"}}};const Pi={parameterPath:["options","sealBlob"],mapper:{serializedName:"x-ms-seal-blob",xmlName:"x-ms-seal-blob",type:{name:"Boolean"}}};const Ci={parameterPath:["options","legalHold"],mapper:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}};const Oi={parameterPath:"xMsRequiresSync",mapper:{defaultValue:"true",isConstant:true,serializedName:"x-ms-requires-sync",type:{name:"String"}}};const Ri={parameterPath:["options","sourceContentMD5"],mapper:{serializedName:"x-ms-source-content-md5",xmlName:"x-ms-source-content-md5",type:{name:"ByteArray"}}};const Di={parameterPath:["options","copySourceAuthorization"],mapper:{serializedName:"x-ms-copy-source-authorization",xmlName:"x-ms-copy-source-authorization",type:{name:"String"}}};const Ai={parameterPath:["options","copySourceTags"],mapper:{serializedName:"x-ms-copy-source-tag-option",xmlName:"x-ms-copy-source-tag-option",type:{name:"Enum",allowedValues:["REPLACE","COPY"]}}};const Ii={parameterPath:"comp",mapper:{defaultValue:"copy",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Li={parameterPath:"copyActionAbortConstant",mapper:{defaultValue:"abort",isConstant:true,serializedName:"x-ms-copy-action",type:{name:"String"}}};const Mi={parameterPath:"copyId",mapper:{serializedName:"copyid",required:true,xmlName:"copyid",type:{name:"String"}}};const Bi={parameterPath:"comp",mapper:{defaultValue:"tier",isConstant:true,serializedName:"comp",type:{name:"String"}}};const ki={parameterPath:"tier",mapper:{serializedName:"x-ms-access-tier",required:true,xmlName:"x-ms-access-tier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive","Cold"]}}};const zi={parameterPath:["options","queryRequest"],mapper:te};const ji={parameterPath:"comp",mapper:{defaultValue:"query",isConstant:true,serializedName:"comp",type:{name:"String"}}};const qi={parameterPath:"comp",mapper:{defaultValue:"tags",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Ui={parameterPath:["options","tags"],mapper:B};const Fi={parameterPath:["options","transactionalContentMD5"],mapper:{serializedName:"Content-MD5",xmlName:"Content-MD5",type:{name:"ByteArray"}}};const Hi={parameterPath:["options","transactionalContentCrc64"],mapper:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}};const Vi={parameterPath:"blobType",mapper:{defaultValue:"PageBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const Gi={parameterPath:"blobContentLength",mapper:{serializedName:"x-ms-blob-content-length",required:true,xmlName:"x-ms-blob-content-length",type:{name:"Number"}}};const $i={parameterPath:["options","blobSequenceNumber"],mapper:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}}};const Xi={parameterPath:["options","contentType"],mapper:{defaultValue:"application/octet-stream",isConstant:true,serializedName:"Content-Type",type:{name:"String"}}};const Wi={parameterPath:"body",mapper:{serializedName:"body",required:true,xmlName:"body",type:{name:"Stream"}}};const Ki={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:true,serializedName:"Accept",type:{name:"String"}}};const Qi={parameterPath:"comp",mapper:{defaultValue:"page",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Yi={parameterPath:"pageWrite",mapper:{defaultValue:"update",isConstant:true,serializedName:"x-ms-page-write",type:{name:"String"}}};const Ji={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThanOrEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-le",xmlName:"x-ms-if-sequence-number-le",type:{name:"Number"}}};const Zi={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThan"],mapper:{serializedName:"x-ms-if-sequence-number-lt",xmlName:"x-ms-if-sequence-number-lt",type:{name:"Number"}}};const en={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-eq",xmlName:"x-ms-if-sequence-number-eq",type:{name:"Number"}}};const tn={parameterPath:"pageWrite",mapper:{defaultValue:"clear",isConstant:true,serializedName:"x-ms-page-write",type:{name:"String"}}};const an={parameterPath:"sourceUrl",mapper:{serializedName:"x-ms-copy-source",required:true,xmlName:"x-ms-copy-source",type:{name:"String"}}};const rn={parameterPath:"sourceRange",mapper:{serializedName:"x-ms-source-range",required:true,xmlName:"x-ms-source-range",type:{name:"String"}}};const nn={parameterPath:["options","sourceContentCrc64"],mapper:{serializedName:"x-ms-source-content-crc64",xmlName:"x-ms-source-content-crc64",type:{name:"ByteArray"}}};const sn={parameterPath:"range",mapper:{serializedName:"x-ms-range",required:true,xmlName:"x-ms-range",type:{name:"String"}}};const on={parameterPath:"comp",mapper:{defaultValue:"pagelist",isConstant:true,serializedName:"comp",type:{name:"String"}}};const pn={parameterPath:["options","prevsnapshot"],mapper:{serializedName:"prevsnapshot",xmlName:"prevsnapshot",type:{name:"String"}}};const ln={parameterPath:["options","prevSnapshotUrl"],mapper:{serializedName:"x-ms-previous-snapshot-url",xmlName:"x-ms-previous-snapshot-url",type:{name:"String"}}};const dn={parameterPath:"sequenceNumberAction",mapper:{serializedName:"x-ms-sequence-number-action",required:true,xmlName:"x-ms-sequence-number-action",type:{name:"Enum",allowedValues:["max","update","increment"]}}};const cn={parameterPath:"comp",mapper:{defaultValue:"incrementalcopy",isConstant:true,serializedName:"comp",type:{name:"String"}}};const mn={parameterPath:"blobType",mapper:{defaultValue:"AppendBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const un={parameterPath:"comp",mapper:{defaultValue:"appendblock",isConstant:true,serializedName:"comp",type:{name:"String"}}};const fn={parameterPath:["options","appendPositionAccessConditions","maxSize"],mapper:{serializedName:"x-ms-blob-condition-maxsize",xmlName:"x-ms-blob-condition-maxsize",type:{name:"Number"}}};const hn={parameterPath:["options","appendPositionAccessConditions","appendPosition"],mapper:{serializedName:"x-ms-blob-condition-appendpos",xmlName:"x-ms-blob-condition-appendpos",type:{name:"Number"}}};const gn={parameterPath:["options","sourceRange"],mapper:{serializedName:"x-ms-source-range",xmlName:"x-ms-source-range",type:{name:"String"}}};const yn={parameterPath:"comp",mapper:{defaultValue:"seal",isConstant:true,serializedName:"comp",type:{name:"String"}}};const vn={parameterPath:"blobType",mapper:{defaultValue:"BlockBlob",isConstant:true,serializedName:"x-ms-blob-type",type:{name:"String"}}};const bn={parameterPath:["options","copySourceBlobProperties"],mapper:{serializedName:"x-ms-copy-source-blob-properties",xmlName:"x-ms-copy-source-blob-properties",type:{name:"Boolean"}}};const xn={parameterPath:"comp",mapper:{defaultValue:"block",isConstant:true,serializedName:"comp",type:{name:"String"}}};const wn={parameterPath:"blockId",mapper:{serializedName:"blockid",required:true,xmlName:"blockid",type:{name:"String"}}};const Sn={parameterPath:"blocks",mapper:K};const Nn={parameterPath:"comp",mapper:{defaultValue:"blocklist",isConstant:true,serializedName:"comp",type:{name:"String"}}};const Tn={parameterPath:"listType",mapper:{defaultValue:"committed",serializedName:"blocklisttype",required:true,xmlName:"blocklisttype",type:{name:"Enum",allowedValues:["committed","uncommitted","all"]}}};class Service{constructor(e){this.client=e}setProperties(e,t){const a={blobServiceProperties:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,_n)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Pn)}getStatistics(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Cn)}listContainersSegment(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,On)}getUserDelegationKey(e,t){const a={keyInfo:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Rn)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Dn)}submitBatch(e,t,a,r){const i={contentLength:e,multipartContentType:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,An)}filterBlobs(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,In)}}const En=new g.Serializer(Ua,true);const _n={path:"/",httpMethod:"PUT",responses:{202:{headersMapper:pe},default:{bodyMapper:_,headersMapper:le}},requestBody:Ha,queryParameters:[$a,Xa,Wa],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const Pn={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:x,headersMapper:de},default:{bodyMapper:_,headersMapper:ce}},queryParameters:[$a,Xa,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const Cn={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:P,headersMapper:me},default:{bodyMapper:_,headersMapper:ue}},queryParameters:[$a,Wa,Ja],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const On={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:O,headersMapper:fe},default:{bodyMapper:_,headersMapper:he}},queryParameters:[Wa,Za,er,tr,ar,rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};const Rn={path:"/",httpMethod:"POST",responses:{200:{bodyMapper:I,headersMapper:ge},default:{bodyMapper:_,headersMapper:ye}},requestBody:ir,queryParameters:[$a,Wa,nr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const Dn={path:"/",httpMethod:"GET",responses:{200:{headersMapper:ve},default:{bodyMapper:_,headersMapper:be}},queryParameters:[Xa,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:En};const An={path:"/",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:xe},default:{bodyMapper:_,headersMapper:we}},requestBody:or,queryParameters:[Wa,pr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,lr,dr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:En};const In={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:L,headersMapper:Se},default:{bodyMapper:_,headersMapper:Ne}},queryParameters:[Wa,tr,ar,cr,mr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:En};class Container{constructor(e){this.client=e}create(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Mn)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Bn)}delete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,kn)}setMetadata(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,zn)}getAccessPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,jn)}setAccessPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,qn)}restore(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Un)}rename(e,t){const a={sourceContainerName:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Fn)}submitBatch(e,t,a,r){const i={contentLength:e,multipartContentType:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Hn)}filterBlobs(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Vn)}acquireLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Gn)}releaseLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,$n)}renewLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Xn)}breakLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Wn)}changeLease(e,t,a){const r={leaseId:e,proposedLeaseId:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Kn)}listBlobFlatSegment(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Qn)}listBlobHierarchySegment(e,t){const a={delimiter:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Yn)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Jn)}}const Ln=new g.Serializer(Ua,true);const Mn={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Te},default:{bodyMapper:_,headersMapper:Ee}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,hr,gr,yr],isXML:true,serializer:Ln};const Bn={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:_e},default:{bodyMapper:_,headersMapper:Pe}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr],isXML:true,serializer:Ln};const kn={path:"/{containerName}",httpMethod:"DELETE",responses:{202:{headersMapper:Ce},default:{bodyMapper:_,headersMapper:Oe}},queryParameters:[Wa,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr],isXML:true,serializer:Ln};const zn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Re},default:{bodyMapper:_,headersMapper:De}},queryParameters:[Wa,ur,wr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br],isXML:true,serializer:Ln};const jn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}},serializedName:"SignedIdentifiers",xmlName:"SignedIdentifiers",xmlIsWrapped:true,xmlElementName:"SignedIdentifier"},headersMapper:Ae},default:{bodyMapper:_,headersMapper:Ie}},queryParameters:[Wa,ur,Sr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr],isXML:true,serializer:Ln};const qn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Le},default:{bodyMapper:_,headersMapper:Me}},requestBody:Nr,queryParameters:[Wa,ur,Sr],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,hr,vr,br,xr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Ln};const Un={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Be},default:{bodyMapper:_,headersMapper:ke}},queryParameters:[Wa,ur,Tr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,Er,_r],isXML:true,serializer:Ln};const Fn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:ze},default:{bodyMapper:_,headersMapper:je}},queryParameters:[Wa,ur,Pr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,Cr,Or],isXML:true,serializer:Ln};const Hn={path:"/{containerName}",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:qe},default:{bodyMapper:_,headersMapper:Ue}},requestBody:or,queryParameters:[Wa,pr,ur],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,lr,dr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Ln};const Vn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:L,headersMapper:Fe},default:{bodyMapper:_,headersMapper:He}},queryParameters:[Wa,tr,ar,cr,mr,ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Ln};const Gn={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:Ve},default:{bodyMapper:_,headersMapper:Ge}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Dr,Ar,Ir],isXML:true,serializer:Ln};const $n={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:$e},default:{bodyMapper:_,headersMapper:Xe}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,Mr],isXML:true,serializer:Ln};const Xn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:We},default:{bodyMapper:_,headersMapper:Ke}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Mr,Br],isXML:true,serializer:Ln};const Wn={path:"/{containerName}",httpMethod:"PUT",responses:{202:{headersMapper:Qe},default:{bodyMapper:_,headersMapper:Ye}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,kr,zr],isXML:true,serializer:Ln};const Kn={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Je},default:{bodyMapper:_,headersMapper:Ze}},queryParameters:[Wa,ur,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Mr,jr,qr],isXML:true,serializer:Ln};const Qn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:q,headersMapper:et},default:{bodyMapper:_,headersMapper:tt}},queryParameters:[Wa,Za,er,tr,ar,ur,Ur],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Ln};const Yn={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:$,headersMapper:rt},default:{bodyMapper:_,headersMapper:it}},queryParameters:[Wa,Za,er,tr,ar,ur,Ur,Fr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Ln};const Jn={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:nt},default:{bodyMapper:_,headersMapper:st}},queryParameters:[Xa,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:Ln};class Blob$1{constructor(e){this.client=e}download(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,es)}getProperties(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ts)}delete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,as)}undelete(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,rs)}setExpiry(e,t){const a={expiryOptions:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,is)}setHttpHeaders(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ns)}setImmutabilityPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ss)}deleteImmutabilityPolicy(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,os)}setLegalHold(e,t){const a={legalHold:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ps)}setMetadata(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ls)}acquireLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ds)}releaseLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,cs)}renewLease(e,t){const a={leaseId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ms)}changeLease(e,t,a){const r={leaseId:e,proposedLeaseId:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,us)}breakLease(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,fs)}createSnapshot(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,hs)}startCopyFromURL(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,gs)}copyFromURL(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ys)}abortCopyFromURL(e,t){const a={copyId:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,vs)}setTier(e,t){const a={tier:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,bs)}getAccountInfo(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,xs)}query(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,ws)}getTags(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ss)}setTags(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ns)}}const Zn=new g.Serializer(Ua,true);const es={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ot},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ot},default:{bodyMapper:_,headersMapper:pt}},queryParameters:[Wa,Hr,Vr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,$r,Xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const ts={path:"/{containerName}/{blob}",httpMethod:"HEAD",responses:{200:{headersMapper:dt},default:{bodyMapper:_,headersMapper:ct}},queryParameters:[Wa,Hr,Vr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const as={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{202:{headersMapper:mt},default:{bodyMapper:_,headersMapper:ut}},queryParameters:[Wa,Hr,Vr,ti],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,ei],isXML:true,serializer:Zn};const rs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ft},default:{bodyMapper:_,headersMapper:ht}},queryParameters:[Wa,Tr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Zn};const is={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:yt},default:{bodyMapper:_,headersMapper:vt}},queryParameters:[Wa,ai],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,ri,ii],isXML:true,serializer:Zn};const ns={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:bt},default:{bodyMapper:_,headersMapper:xt}},queryParameters:[Xa,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,ni,si,oi,pi,li,di],isXML:true,serializer:Zn};const ss={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:wt},default:{bodyMapper:_,headersMapper:St}},queryParameters:[Wa,ci],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,xr,mi,ui],isXML:true,serializer:Zn};const os={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{200:{headersMapper:Nt},default:{bodyMapper:_,headersMapper:Tt}},queryParameters:[Wa,ci],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya],isXML:true,serializer:Zn};const ps={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Et},default:{bodyMapper:_,headersMapper:_t}},queryParameters:[Wa,fi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,hi],isXML:true,serializer:Zn};const ls={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Pt},default:{bodyMapper:_,headersMapper:Ct}},queryParameters:[Wa,wr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi],isXML:true,serializer:Zn};const ds={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ot},default:{bodyMapper:_,headersMapper:Rt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Dr,Ar,Ir,Yr,Jr,Zr],isXML:true,serializer:Zn};const cs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Dt},default:{bodyMapper:_,headersMapper:At}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Lr,Mr,Yr,Jr,Zr],isXML:true,serializer:Zn};const ms={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:It},default:{bodyMapper:_,headersMapper:Lt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Mr,Br,Yr,Jr,Zr],isXML:true,serializer:Zn};const us={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Mt},default:{bodyMapper:_,headersMapper:Bt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Mr,jr,qr,Yr,Jr,Zr],isXML:true,serializer:Zn};const fs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:kt},default:{bodyMapper:_,headersMapper:zt}},queryParameters:[Wa,Rr],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,kr,zr,Yr,Jr,Zr],isXML:true,serializer:Zn};const hs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:jt},default:{bodyMapper:_,headersMapper:qt}},queryParameters:[Wa,yi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi],isXML:true,serializer:Zn};const gs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Ut},default:{bodyMapper:_,headersMapper:Ft}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Yr,Jr,Zr,mi,ui,vi,bi,xi,wi,Si,Ni,Ti,Ei,_i,Pi,Ci],isXML:true,serializer:Zn};const ys={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Ht},default:{bodyMapper:_,headersMapper:Vt}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,fr,vr,br,xr,Yr,Jr,Zr,mi,ui,gi,vi,xi,wi,Si,Ni,Ei,_i,Ci,Oi,Ri,Di,Ai],isXML:true,serializer:Zn};const vs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:Gt},default:{bodyMapper:_,headersMapper:$t}},queryParameters:[Wa,Ii,Mi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Li],isXML:true,serializer:Zn};const bs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Xt},202:{headersMapper:Xt},default:{bodyMapper:_,headersMapper:Wt}},queryParameters:[Wa,Hr,Vr,Bi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr,bi,ki],isXML:true,serializer:Zn};const xs={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{headersMapper:Kt},default:{bodyMapper:_,headersMapper:Qt}},queryParameters:[Xa,sr],urlParameters:[Ga],headerParameters:[Ka,Ya],isXML:true,serializer:Zn};const ws={path:"/{containerName}/{blob}",httpMethod:"POST",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Yt},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Yt},default:{bodyMapper:_,headersMapper:Jt}},requestBody:zi,queryParameters:[Wa,Hr,ji],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Zn};const Ss={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:B,headersMapper:Zt},default:{bodyMapper:_,headersMapper:ea}},queryParameters:[Wa,Hr,Vr,qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr],isXML:true,serializer:Zn};const Ns={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:ta},default:{bodyMapper:_,headersMapper:aa}},requestBody:Ui,queryParameters:[Wa,Vr,qi],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,vr,Zr,Fi,Hi],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Zn};class PageBlob{constructor(e){this.client=e}create(e,t,a){const r={contentLength:e,blobContentLength:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,_s)}uploadPages(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Ps)}clearPages(e,t){const a={contentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Cs)}uploadPagesFromURL(e,t,a,r,i){const n={sourceUrl:e,sourceRange:t,contentLength:a,range:r,options:g.operationOptionsToRequestOptionsBase(i||{})};return this.client.sendOperationRequest(n,Os)}getPageRanges(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Rs)}getPageRangesDiff(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,Ds)}resize(e,t){const a={blobContentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,As)}updateSequenceNumber(e,t){const a={sequenceNumberAction:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Is)}copyIncremental(e,t){const a={copySource:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Ls)}}const Ts=new g.Serializer(Ua,true);const Es=new g.Serializer(Ua,false);const _s={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ra},default:{bodyMapper:_,headersMapper:ia}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Vi,Gi,$i],isXML:true,serializer:Ts};const Ps={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:na},default:{bodyMapper:_,headersMapper:sa}},requestBody:Wi,queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,br,xr,Gr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Fi,Hi,Xi,Ki,Yi,Ji,Zi,en],mediaType:"binary",serializer:Es};const Cs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:oa},default:{bodyMapper:_,headersMapper:pa}},queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Gr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Ji,Zi,en,tn],isXML:true,serializer:Ts};const Os={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:la},default:{bodyMapper:_,headersMapper:da}},queryParameters:[Wa,Qi],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,xi,wi,Si,Ni,Ri,Di,Yi,Ji,Zi,en,an,rn,nn,sn],isXML:true,serializer:Ts};const Rs={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:J,headersMapper:ca},default:{bodyMapper:_,headersMapper:ma}},queryParameters:[Wa,tr,ar,Hr,on],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Yr,Jr,Zr],isXML:true,serializer:Ts};const Ds={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:J,headersMapper:ua},default:{bodyMapper:_,headersMapper:fa}},queryParameters:[Wa,tr,ar,Hr,on,pn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Gr,Yr,Jr,Zr,ln],isXML:true,serializer:Ts};const As={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ha},default:{bodyMapper:_,headersMapper:ga}},queryParameters:[Xa,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Gi],isXML:true,serializer:Ts};const Is={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ya},default:{bodyMapper:_,headersMapper:va}},queryParameters:[Xa,Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,Zr,$i,dn],isXML:true,serializer:Ts};const Ls={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:ba},default:{bodyMapper:_,headersMapper:xa}},queryParameters:[Wa,cn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,br,xr,Yr,Jr,Zr,Ei],isXML:true,serializer:Ts};class AppendBlob{constructor(e){this.client=e}create(e,t){const a={contentLength:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,ks)}appendBlock(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,zs)}appendBlockFromUrl(e,t,a){const r={sourceUrl:e,contentLength:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,js)}seal(e){const t={options:g.operationOptionsToRequestOptionsBase(e||{})};return this.client.sendOperationRequest(t,qs)}}const Ms=new g.Serializer(Ua,true);const Bs=new g.Serializer(Ua,false);const ks={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:wa},default:{bodyMapper:_,headersMapper:Sa}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,_i,Ci,mn],isXML:true,serializer:Ms};const zs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Na},default:{bodyMapper:_,headersMapper:Ta}},requestBody:Wi,queryParameters:[Wa,un],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,Fi,Hi,Xi,Ki,fn,hn],mediaType:"binary",serializer:Bs};const js={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ea},default:{bodyMapper:_,headersMapper:_a}},queryParameters:[Wa,un],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,gi,xi,wi,Si,Ni,Ri,Di,Fi,an,nn,fn,hn,gn],isXML:true,serializer:Ms};const qs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Pa},default:{bodyMapper:_,headersMapper:Ca}},queryParameters:[Wa,yn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,br,xr,Yr,Jr,hn],isXML:true,serializer:Ms};class BlockBlob{constructor(e){this.client=e}upload(e,t,a){const r={contentLength:e,body:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Hs)}putBlobFromUrl(e,t,a){const r={contentLength:e,copySource:t,options:g.operationOptionsToRequestOptionsBase(a||{})};return this.client.sendOperationRequest(r,Vs)}stageBlock(e,t,a,r){const i={blockId:e,contentLength:t,body:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,Gs)}stageBlockFromURL(e,t,a,r){const i={blockId:e,contentLength:t,sourceUrl:a,options:g.operationOptionsToRequestOptionsBase(r||{})};return this.client.sendOperationRequest(i,$s)}commitBlockList(e,t){const a={blocks:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Xs)}getBlockList(e,t){const a={listType:e,options:g.operationOptionsToRequestOptionsBase(t||{})};return this.client.sendOperationRequest(a,Ws)}}const Us=new g.Serializer(Ua,true);const Fs=new g.Serializer(Ua,false);const Hs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Oa},default:{bodyMapper:_,headersMapper:Ra}},requestBody:Wi,queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Fi,Hi,Xi,Ki,vn],mediaType:"binary",serializer:Fs};const Vs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Da},default:{bodyMapper:_,headersMapper:Aa}},queryParameters:[Wa],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,gi,vi,xi,wi,Si,Ni,Ti,Ei,_i,Ri,Di,Ai,Fi,vn,bn],isXML:true,serializer:Us};const Gs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ia},default:{bodyMapper:_,headersMapper:La}},requestBody:Wi,queryParameters:[Wa,xn,wn],urlParameters:[Ga],headerParameters:[Ka,Qa,lr,vr,Wr,Kr,Qr,gi,Fi,Hi,Xi,Ki],mediaType:"binary",serializer:Fs};const $s={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ma},default:{bodyMapper:_,headersMapper:Ba}},queryParameters:[Wa,xn,wn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,lr,vr,Wr,Kr,Qr,gi,xi,wi,Si,Ni,Ri,Di,an,nn,gn],isXML:true,serializer:Us};const Xs={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ka},default:{bodyMapper:_,headersMapper:za}},requestBody:Sn,queryParameters:[Wa,Nn],urlParameters:[Ga],headerParameters:[Fa,Va,Ka,Qa,fr,vr,br,xr,Wr,Kr,Qr,Yr,Jr,Zr,ni,si,oi,pi,li,di,mi,ui,gi,vi,_i,Ci,Fi,Hi],isXML:true,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Us};const Ws={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:Q,headersMapper:ja},default:{bodyMapper:_,headersMapper:qa}},queryParameters:[Wa,Hr,Nn,Tn],urlParameters:[Ga],headerParameters:[Ka,Qa,Ya,vr,Zr],isXML:true,serializer:Us};const Ks=s.createClientLogger("storage-blob");const Qs="12.15.0";const Ys="2023-01-03";const Js=256*1024*1024;const Zs=4e3*1024*1024;const eo=5e4;const to=8*1024*1024;const ao=4*1024*1024;const ro=5;const io=100*1e3;const no="https://storage.azure.com/.default";const so={Parameters:{FORCE_BROWSER_NO_CACHE:"_",SIGNATURE:"sig",SNAPSHOT:"snapshot",VERSIONID:"versionid",TIMEOUT:"timeout"}};const oo={HTTP_ACCEPTED:202,HTTP_CONFLICT:409,HTTP_NOT_FOUND:404,HTTP_PRECON_FAILED:412,HTTP_RANGE_NOT_SATISFIABLE:416};const po={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"};const lo="";const co="*";const mo=1*1024*1024;const uo=256;const fo=4*mo;const ho="\r\n";const go="HTTP/1.1";const yo="AES256";const vo=`DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;`;const bo=["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"];const xo=["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"];const wo="BlobUsesCustomerSpecifiedEncryption";const So="BlobDoesNotUseCustomerSpecifiedEncryption";const No=["10000","10001","10002","10003","10004","10100","10101","10102","10103","10104","11000","11001","11002","11003","11004","11100","11101","11102","11103","11104"];function escapeURLPath(e){const t=r.URLBuilder.parse(e);let a=t.getPath();a=a||"/";a=escape(a);t.setPath(a);return t.toString()}function getProxyUriFromDevConnString(e){let t="";if(e.search("DevelopmentStorageProxyUri=")!==-1){const a=e.split(";");for(const e of a){if(e.trim().startsWith("DevelopmentStorageProxyUri=")){t=e.trim().match("DevelopmentStorageProxyUri=(.*)")[1]}}}return t}function getValueInConnString(e,t){const a=e.split(";");for(const e of a){if(e.trim().startsWith(t)){return e.trim().match(t+"=(.*)")[1]}}return""}function extractConnectionStringParts(e){let t="";if(e.startsWith("UseDevelopmentStorage=true")){t=getProxyUriFromDevConnString(e);e=vo}let a=getValueInConnString(e,"BlobEndpoint");a=a.endsWith("/")?a.slice(0,-1):a;if(e.search("DefaultEndpointsProtocol=")!==-1&&e.search("AccountKey=")!==-1){let r="";let i="";let n=Buffer.from("accountKey","base64");let s="";i=getValueInConnString(e,"AccountName");n=Buffer.from(getValueInConnString(e,"AccountKey"),"base64");if(!a){r=getValueInConnString(e,"DefaultEndpointsProtocol");const t=r.toLowerCase();if(t!=="https"&&t!=="http"){throw new Error("Invalid DefaultEndpointsProtocol in the provided Connection String. Expecting 'https' or 'http'")}s=getValueInConnString(e,"EndpointSuffix");if(!s){throw new Error("Invalid EndpointSuffix in the provided Connection String")}a=`${r}://${i}.blob.${s}`}if(!i){throw new Error("Invalid AccountName in the provided Connection String")}else if(n.length===0){throw new Error("Invalid AccountKey in the provided Connection String")}return{kind:"AccountConnString",url:a,accountName:i,accountKey:n,proxyUri:t}}else{const t=getValueInConnString(e,"SharedAccessSignature");const r=getAccountNameFromUrl(a);if(!a){throw new Error("Invalid BlobEndpoint in the provided SAS Connection String")}else if(!t){throw new Error("Invalid SharedAccessSignature in the provided SAS Connection String")}return{kind:"SASConnString",url:a,accountName:r,accountSas:t}}}function escape(e){return encodeURIComponent(e).replace(/%2F/g,"/").replace(/'/g,"%27").replace(/\+/g,"%20").replace(/%25/g,"%")}function appendToURLPath(e,t){const a=r.URLBuilder.parse(e);let i=a.getPath();i=i?i.endsWith("/")?`${i}${t}`:`${i}/${t}`:t;a.setPath(i);const n=new URL(a.toString());return n.toString()}function setURLParameter(e,t,a){const i=r.URLBuilder.parse(e);i.setQueryParameter(t,a);return i.toString()}function getURLParameter(e,t){const a=r.URLBuilder.parse(e);return a.getQueryParameterValue(t)}function setURLHost(e,t){const a=r.URLBuilder.parse(e);a.setHost(t);return a.toString()}function getURLPath(e){const t=r.URLBuilder.parse(e);return t.getPath()}function getURLScheme(e){const t=r.URLBuilder.parse(e);return t.getScheme()}function getURLPathAndQuery(e){const t=r.URLBuilder.parse(e);const a=t.getPath();if(!a){throw new RangeError("Invalid url without valid path.")}let i=t.getQuery()||"";i=i.trim();if(i!==""){i=i.startsWith("?")?i:`?${i}`}return`${a}${i}`}function getURLQueries(e){let t=r.URLBuilder.parse(e).getQuery();if(!t){return{}}t=t.trim();t=t.startsWith("?")?t.substr(1):t;let a=t.split("&");a=a.filter((e=>{const t=e.indexOf("=");const a=e.lastIndexOf("=");return t>0&&t===a&&ai){e=e.slice(0,i)}const n=e+padStart(t.toString(),a-e.length,"0");return base64encode(n)}async function delay(e,t,a){return new Promise(((r,i)=>{let n;const abortHandler=()=>{if(n!==undefined){clearTimeout(n)}i(a)};const resolveHandler=()=>{if(t!==undefined){t.removeEventListener("abort",abortHandler)}r()};n=setTimeout(resolveHandler,e);if(t!==undefined){t.addEventListener("abort",abortHandler)}}))}function padStart(e,t,a=" "){if(String.prototype.padStart){return e.padStart(t,a)}a=a||" ";if(e.length>t){return e}else{t=t-e.length;if(t>a.length){a+=a.repeat(t/a.length)}return a.slice(0,t)+e}}function iEqual(e,t){return e.toLocaleLowerCase()===t.toLocaleLowerCase()}function getAccountNameFromUrl(e){const t=r.URLBuilder.parse(e);let a;try{if(t.getHost().split(".")[1]==="blob"){a=t.getHost().split(".")[0]}else if(isIpEndpointStyle(t)){a=t.getPath().split("/")[1]}else{a=""}return a}catch(e){throw new Error("Unable to extract accountName with provided information.")}}function isIpEndpointStyle(e){if(e.getHost()===undefined){return false}const t=e.getHost()+(e.getPort()===undefined?"":":"+e.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(t)||e.getPort()!==undefined&&No.includes(e.getPort())}function toBlobTagsString(e){if(e===undefined){return undefined}const t=[];for(const a in e){if(Object.prototype.hasOwnProperty.call(e,a)){const r=e[a];t.push(`${encodeURIComponent(a)}=${encodeURIComponent(r)}`)}}return t.join("&")}function toBlobTags(e){if(e===undefined){return undefined}const t={blobTagSet:[]};for(const a in e){if(Object.prototype.hasOwnProperty.call(e,a)){const r=e[a];t.blobTagSet.push({key:a,value:r})}}return t}function toTags(e){if(e===undefined){return undefined}const t={};for(const a of e.blobTagSet){t[a.key]=a.value}return t}function toQuerySerialization(e){if(e===undefined){return undefined}switch(e.kind){case"csv":return{format:{type:"delimited",delimitedTextConfiguration:{columnSeparator:e.columnSeparator||",",fieldQuote:e.fieldQuote||"",recordSeparator:e.recordSeparator,escapeChar:e.escapeCharacter||"",headersPresent:e.hasHeaders||false}}};case"json":return{format:{type:"json",jsonTextConfiguration:{recordSeparator:e.recordSeparator}}};case"arrow":return{format:{type:"arrow",arrowConfiguration:{schema:e.schema}}};case"parquet":return{format:{type:"parquet"}};default:throw Error("Invalid BlobQueryTextConfiguration.")}}function parseObjectReplicationRecord(e){if(!e){return undefined}if("policy-id"in e){return undefined}const t=[];for(const a in e){const r=a.split("_");const i="or-";if(r[0].startsWith(i)){r[0]=r[0].substring(i.length)}const n={ruleId:r[1],replicationStatus:e[a]};const s=t.findIndex((e=>e.policyId===r[0]));if(s>-1){t[s].rules.push(n)}else{t.push({policyId:r[0],rules:[n]})}}return t}function attachCredential(e,t){e.credential=t;return e}function httpAuthorizationToString(e){return e?e.scheme+" "+e.value:undefined}function BlobNameToString(e){if(e.encoded){return decodeURIComponent(e.content)}else{return e.content}}function ConvertInternalResponseOfListBlobFlat(e){return Object.assign(Object.assign({},e),{segment:{blobItems:e.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))}})}function ConvertInternalResponseOfListBlobHierarchy(e){var t;return Object.assign(Object.assign({},e),{segment:{blobPrefixes:(t=e.segment.blobPrefixes)===null||t===void 0?void 0:t.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t})),blobItems:e.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))}})}function*ExtractPageRangeInfoItems(e){let t=[];let a=[];if(e.pageRange)t=e.pageRange;if(e.clearRange)a=e.clearRange;let r=0;let i=0;while(r=1?Math.floor(a.maxTries):To.maxTries,tryTimeoutInMs:a.tryTimeoutInMs&&a.tryTimeoutInMs>=0?a.tryTimeoutInMs:To.tryTimeoutInMs,retryDelayInMs:a.retryDelayInMs&&a.retryDelayInMs>=0?Math.min(a.retryDelayInMs,a.maxRetryDelayInMs?a.maxRetryDelayInMs:To.maxRetryDelayInMs):To.retryDelayInMs,maxRetryDelayInMs:a.maxRetryDelayInMs&&a.maxRetryDelayInMs>=0?a.maxRetryDelayInMs:To.maxRetryDelayInMs,secondaryHost:a.secondaryHost?a.secondaryHost:To.secondaryHost}}async sendRequest(e){return this.attemptSendRequest(e,false,1)}async attemptSendRequest(e,t,a){const r=e.clone();const i=t||!this.retryOptions.secondaryHost||!(e.method==="GET"||e.method==="HEAD"||e.method==="OPTIONS")||a%2===1;if(!i){r.url=setURLHost(r.url,this.retryOptions.secondaryHost)}if(this.retryOptions.tryTimeoutInMs){r.url=setURLParameter(r.url,so.Parameters.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString())}let n;try{Ks.info(`RetryPolicy: =====> Try=${a} ${i?"Primary":"Secondary"}`);n=await this._nextPolicy.sendRequest(r);if(!this.shouldRetry(i,a,n)){return n}t=t||!i&&n.status===404}catch(e){Ks.error(`RetryPolicy: Caught error, message: ${e.message}, code: ${e.code}`);if(!this.shouldRetry(i,a,n,e)){throw e}}await this.delay(i,a,e.abortSignal);return this.attemptSendRequest(e,t,++a)}shouldRetry(e,t,a,r){if(t>=this.retryOptions.maxTries){Ks.info(`RetryPolicy: Attempt(s) ${t} >= maxTries ${this.retryOptions.maxTries}, no further try.`);return false}const i=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(r){for(const e of i){if(r.name.toUpperCase().includes(e)||r.message.toUpperCase().includes(e)||r.code&&r.code.toString().toUpperCase()===e){Ks.info(`RetryPolicy: Network error ${e} found, will retry.`);return true}}}if(a||r){const t=a?a.status:r?r.statusCode:0;if(!e&&t===404){Ks.info(`RetryPolicy: Secondary access with 404, will retry.`);return true}if(t===503||t===500){Ks.info(`RetryPolicy: Will retry for status code ${t}.`);return true}}if((r===null||r===void 0?void 0:r.code)==="PARSE_ERROR"&&(r===null||r===void 0?void 0:r.message.startsWith(`Error "Error: Unclosed root tag`))){Ks.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry.");return true}return false}async delay(e,a,r){let i=0;if(e){switch(this.retryOptions.retryPolicyType){case t.StorageRetryPolicyType.EXPONENTIAL:i=Math.min((Math.pow(2,a-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;case t.StorageRetryPolicyType.FIXED:i=this.retryOptions.retryDelayInMs;break}}else{i=Math.random()*1e3}Ks.info(`RetryPolicy: Delay for ${i}ms`);return delay(i,r,Eo)}}class StorageRetryPolicyFactory{constructor(e){this.retryOptions=e}create(e,t){return new StorageRetryPolicy(e,t,this.retryOptions)}}class CredentialPolicy extends r.BaseRequestPolicy{sendRequest(e){return this._nextPolicy.sendRequest(this.signRequest(e))}signRequest(e){return e}}class AnonymousCredentialPolicy extends CredentialPolicy{constructor(e,t){super(e,t)}}class Credential{create(e,t){throw new Error("Method should be implemented in children classes.")}}class AnonymousCredential extends Credential{create(e,t){return new AnonymousCredentialPolicy(e,t)}}class TelemetryPolicy extends r.BaseRequestPolicy{constructor(e,t,a){super(e,t);this.telemetry=a}async sendRequest(e){if(r.isNode){if(!e.headers){e.headers=new r.HttpHeaders}if(!e.headers.get(po.USER_AGENT)){e.headers.set(po.USER_AGENT,this.telemetry)}}return this._nextPolicy.sendRequest(e)}}class TelemetryPolicyFactory{constructor(e){const t=[];if(r.isNode){if(e){const a=e.userAgentPrefix||"";if(a.length>0&&t.indexOf(a)===-1){t.push(a)}}const a=`azsdk-js-storageblob/${Qs}`;if(t.indexOf(a)===-1){t.push(a)}let r=`(NODE-VERSION ${process.version})`;if(y){r=`(NODE-VERSION ${process.version}; ${y.type()} ${y.release()})`}if(t.indexOf(r)===-1){t.push(r)}}this.telemetryString=t.join(" ")}create(e,t){return new TelemetryPolicy(e,t,this.telemetryString)}}const _o=new r.DefaultHttpClient;function getCachedDefaultHttpClient(){return _o}const Po={DefaultScope:"/.default",HeaderConstants:{AUTHORIZATION:"authorization"}};const Co={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function beginRefresh(e,t,a){async function tryGetAccessToken(){if(Date.now()e.getToken(t,a);r=beginRefresh(tryGetAccessToken,n.retryIntervalInMs,(o=i===null||i===void 0?void 0:i.expiresOnTimestamp)!==null&&o!==void 0?o:Date.now()).then((e=>{r=null;i=e;return i})).catch((e=>{r=null;i=null;throw e}))}return r}return async e=>{if(s.mustRefresh)return refresh(e);if(s.shouldRefresh){refresh(e)}return i}}function getChallenge(e){const t=e.headers.get("WWW-Authenticate");if(e.status===401&&t){return t}return}function parseChallenge(e){const t=e.slice("Bearer ".length);const a=`${t.trim()} `.split(" ").filter((e=>e));const r=a.map((e=>(([e,t])=>({[e]:t}))(e.trim().split("="))));return r.reduce(((e,t)=>Object.assign(Object.assign({},e),t)),{})}function storageBearerTokenChallengeAuthenticationPolicy(e,t){let a=createTokenCycler(e,t);class StorageBearerTokenChallengeAuthenticationPolicy extends r.BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(t){if(!t.url.toLowerCase().startsWith("https://")){throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.")}const i=a;const n=(await i({abortSignal:t.abortSignal,tracingOptions:{tracingContext:t.tracingContext}})).token;t.headers.set(Po.HeaderConstants.AUTHORIZATION,`Bearer ${n}`);const s=await this._nextPolicy.sendRequest(t);if((s===null||s===void 0?void 0:s.status)===401){const i=getChallenge(s);if(i){const n=parseChallenge(i);const s=n.resource_id+Po.DefaultScope;const o=r.URLBuilder.parse(n.authorization_uri);const p=o.getPath().split("/");const l=p[1];const d=createTokenCycler(e,s);const c=(await d({abortSignal:t.abortSignal,tracingOptions:{tracingContext:t.tracingContext},tenantId:l})).token;a=d;t.headers.set(Po.HeaderConstants.AUTHORIZATION,`Bearer ${c}`);return this._nextPolicy.sendRequest(t)}}return s}}return{create:(e,t)=>new StorageBearerTokenChallengeAuthenticationPolicy(e,t)}}function isPipelineLike(e){if(!e||typeof e!=="object"){return false}const t=e;return Array.isArray(t.factories)&&typeof t.options==="object"&&typeof t.toServiceClientOptions==="function"}class Pipeline{constructor(e,t={}){this.factories=e;this.options=Object.assign(Object.assign({},t),{httpClient:t.httpClient||getCachedDefaultHttpClient()})}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}}function newPipeline(e,t={}){var a;if(e===undefined){e=new AnonymousCredential}const i=new TelemetryPolicyFactory(t.userAgentOptions);const n=[r.tracingPolicy({userAgent:i.telemetryString}),r.keepAlivePolicy(t.keepAliveOptions),i,r.generateClientRequestIdPolicy(),new StorageBrowserPolicyFactory,new StorageRetryPolicyFactory(t.retryOptions),r.deserializationPolicy(undefined,{xmlCharKey:"#"}),r.logPolicy({logger:Ks.info,allowedHeaderNames:bo,allowedQueryParameters:xo})];if(r.isNode){n.push(r.proxyPolicy(t.proxyOptions));n.push(r.disableResponseDecompressionPolicy())}n.push(r.isTokenCredential(e)?attachCredential(storageBearerTokenChallengeAuthenticationPolicy(e,(a=t.audience)!==null&&a!==void 0?a:no),e):e);return new Pipeline(n,t)}class StorageSharedKeyCredentialPolicy extends CredentialPolicy{constructor(e,t,a){super(e,t);this.factory=a}signRequest(e){e.headers.set(po.X_MS_DATE,(new Date).toUTCString());if(e.body&&(typeof e.body==="string"||e.body!==undefined)&&e.body.length>0){e.headers.set(po.CONTENT_LENGTH,Buffer.byteLength(e.body))}const t=[e.method.toUpperCase(),this.getHeaderValueToSign(e,po.CONTENT_LANGUAGE),this.getHeaderValueToSign(e,po.CONTENT_ENCODING),this.getHeaderValueToSign(e,po.CONTENT_LENGTH),this.getHeaderValueToSign(e,po.CONTENT_MD5),this.getHeaderValueToSign(e,po.CONTENT_TYPE),this.getHeaderValueToSign(e,po.DATE),this.getHeaderValueToSign(e,po.IF_MODIFIED_SINCE),this.getHeaderValueToSign(e,po.IF_MATCH),this.getHeaderValueToSign(e,po.IF_NONE_MATCH),this.getHeaderValueToSign(e,po.IF_UNMODIFIED_SINCE),this.getHeaderValueToSign(e,po.RANGE)].join("\n")+"\n"+this.getCanonicalizedHeadersString(e)+this.getCanonicalizedResourceString(e);const a=this.factory.computeHMACSHA256(t);e.headers.set(po.AUTHORIZATION,`SharedKey ${this.factory.accountName}:${a}`);return e}getHeaderValueToSign(e,t){const a=e.headers.get(t);if(!a){return""}if(t===po.CONTENT_LENGTH&&a==="0"){return""}return a}getCanonicalizedHeadersString(e){let t=e.headers.headersArray().filter((e=>e.name.toLowerCase().startsWith(po.PREFIX_FOR_STORAGE)));t.sort(((e,t)=>e.name.toLowerCase().localeCompare(t.name.toLowerCase())));t=t.filter(((e,t,a)=>{if(t>0&&e.name.toLowerCase()===a[t-1].name.toLowerCase()){return false}return true}));let a="";t.forEach((e=>{a+=`${e.name.toLowerCase().trimRight()}:${e.value.trimLeft()}\n`}));return a}getCanonicalizedResourceString(e){const t=getURLPath(e.url)||"/";let a="";a+=`/${this.factory.accountName}${t}`;const r=getURLQueries(e.url);const i={};if(r){const e=[];for(const t in r){if(Object.prototype.hasOwnProperty.call(r,t)){const a=t.toLowerCase();i[a]=r[t];e.push(a)}}e.sort();for(const t of e){a+=`\n${t}:${decodeURIComponent(i[t])}`}}return a}}class StorageSharedKeyCredential extends Credential{constructor(e,t){super();this.accountName=e;this.accountKey=Buffer.from(t,"base64")}create(e,t){return new StorageSharedKeyCredentialPolicy(e,t,this)}computeHMACSHA256(e){return l.createHmac("sha256",this.accountKey).update(e,"utf8").digest("base64")}}const Oo="azure-storage-blob";const Ro="12.15.0";class StorageClientContext extends g.ServiceClient{constructor(e,t){if(e===undefined){throw new Error("'url' cannot be null")}if(!t){t={}}if(!t.userAgent){const e=g.getDefaultUserAgentValue();t.userAgent=`${Oo}/${Ro} ${e}`}super(undefined,t);this.requestContentType="application/json; charset=utf-8";this.baseUri=t.endpoint||"{url}";this.url=e;this.version=t.version||"2023-01-03"}}class StorageClient{constructor(e,t){this.url=escapeURLPath(e);this.accountName=getAccountNameFromUrl(e);this.pipeline=t;this.storageClientContext=new StorageClientContext(this.url,t.toServiceClientOptions());this.isHttps=iEqual(getURLScheme(this.url)||"","https");this.credential=new AnonymousCredential;for(const e of this.pipeline.factories){if(r.isNode&&e instanceof StorageSharedKeyCredential||e instanceof AnonymousCredential){this.credential=e}else if(r.isTokenCredential(e.credential)){this.credential=e.credential}}const a=this.storageClientContext;a.requestContentType=undefined}}const Do=n.createSpanFunction({packagePrefix:"Azure.Storage.Blob",namespace:"Microsoft.Storage"});function convertTracingToRequestOptionsBase(e){var t,a;return{spanOptions:(t=e===null||e===void 0?void 0:e.tracingOptions)===null||t===void 0?void 0:t.spanOptions,tracingContext:(a=e===null||e===void 0?void 0:e.tracingOptions)===null||a===void 0?void 0:a.tracingContext}}class BlobSASPermissions{constructor(){this.read=false;this.add=false;this.create=false;this.write=false;this.delete=false;this.deleteVersion=false;this.tag=false;this.move=false;this.execute=false;this.setImmutabilityPolicy=false;this.permanentDelete=false}static parse(e){const t=new BlobSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"x":t.deleteVersion=true;break;case"t":t.tag=true;break;case"m":t.move=true;break;case"e":t.execute=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;default:throw new RangeError(`Invalid permission: ${a}`)}}return t}static from(e){const t=new BlobSASPermissions;if(e.read){t.read=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.deleteVersion){t.deleteVersion=true}if(e.tag){t.tag=true}if(e.move){t.move=true}if(e.execute){t.execute=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.tag){e.push("t")}if(this.move){e.push("m")}if(this.execute){e.push("e")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}return e.join("")}}class ContainerSASPermissions{constructor(){this.read=false;this.add=false;this.create=false;this.write=false;this.delete=false;this.deleteVersion=false;this.list=false;this.tag=false;this.move=false;this.execute=false;this.setImmutabilityPolicy=false;this.permanentDelete=false;this.filterByTags=false}static parse(e){const t=new ContainerSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"l":t.list=true;break;case"t":t.tag=true;break;case"x":t.deleteVersion=true;break;case"m":t.move=true;break;case"e":t.execute=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;case"f":t.filterByTags=true;break;default:throw new RangeError(`Invalid permission ${a}`)}}return t}static from(e){const t=new ContainerSASPermissions;if(e.read){t.read=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.list){t.list=true}if(e.deleteVersion){t.deleteVersion=true}if(e.tag){t.tag=true}if(e.move){t.move=true}if(e.execute){t.execute=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}if(e.filterByTags){t.filterByTags=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.list){e.push("l")}if(this.tag){e.push("t")}if(this.move){e.push("m")}if(this.execute){e.push("e")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}if(this.filterByTags){e.push("f")}return e.join("")}}class UserDelegationKeyCredential{constructor(e,t){this.accountName=e;this.userDelegationKey=t;this.key=Buffer.from(t.value,"base64")}computeHMACSHA256(e){return l.createHmac("sha256",this.key).update(e,"utf8").digest("base64")}}function ipRangeToString(e){return e.end?`${e.start}-${e.end}`:e.start}t.SASProtocol=void 0;(function(e){e["Https"]="https";e["HttpsAndHttp"]="https,http"})(t.SASProtocol||(t.SASProtocol={}));class SASQueryParameters{constructor(e,t,a,r,i,n,s,o,p,l,d,c,m,u,h,g,y,v,b,x){this.version=e;this.signature=t;if(a!==undefined&&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.encryptionScope=a.encryptionScope;this.resource=a.resource;this.cacheControl=a.cacheControl;this.contentDisposition=a.contentDisposition;this.contentEncoding=a.contentEncoding;this.contentLanguage=a.contentLanguage;this.contentType=a.contentType;if(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}}else{this.services=r;this.resourceTypes=i;this.expiresOn=o;this.permissions=a;this.protocol=n;this.startsOn=s;this.ipRangeInner=p;this.encryptionScope=x;this.identifier=l;this.resource=d;this.cacheControl=c;this.contentDisposition=m;this.contentEncoding=u;this.contentLanguage=h;this.contentType=g;if(y){this.signedOid=y.signedObjectId;this.signedTenantId=y.signedTenantId;this.signedStartsOn=y.signedStartsOn;this.signedExpiresOn=y.signedExpiresOn;this.signedService=y.signedService;this.signedVersion=y.signedVersion;this.preauthorizedAgentObjectId=v;this.correlationId=b}}}get ipRange(){if(this.ipRangeInner){return{end:this.ipRangeInner.end,start:this.ipRangeInner.start}}return undefined}toString(){const e=["sv","ss","srt","spr","st","se","sip","si","ses","skoid","sktid","skt","ske","sks","skv","sr","sp","sig","rscc","rscd","rsce","rscl","rsct","saoid","scid"];const t=[];for(const 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?truncatedISO8061Date(this.startsOn,false):undefined);break;case"se":this.tryAppendQueryParameter(t,a,this.expiresOn?truncatedISO8061Date(this.expiresOn,false):undefined);break;case"sip":this.tryAppendQueryParameter(t,a,this.ipRange?ipRangeToString(this.ipRange):undefined);break;case"si":this.tryAppendQueryParameter(t,a,this.identifier);break;case"ses":this.tryAppendQueryParameter(t,a,this.encryptionScope);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?truncatedISO8061Date(this.signedStartsOn,false):undefined);break;case"ske":this.tryAppendQueryParameter(t,a,this.signedExpiresOn?truncatedISO8061Date(this.signedExpiresOn,false):undefined);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){if(!a){return}t=encodeURIComponent(t);a=encodeURIComponent(a);if(t.length>0&&a.length>0){e.push(`${t}=${a}`)}}}function generateBlobSASQueryParameters(e,t,a){const r=e.version?e.version:Ys;const i=t instanceof StorageSharedKeyCredential?t:undefined;let n;if(i===undefined&&a!==undefined){n=new UserDelegationKeyCredential(a,t)}if(i===undefined&&n===undefined){throw TypeError("Invalid sharedKeyCredential, userDelegationKey or accountName.")}if(r>="2020-12-06"){if(i!==undefined){return generateBlobSASQueryParameters20201206(e,i)}else{return generateBlobSASQueryParametersUDK20201206(e,n)}}if(r>="2018-11-09"){if(i!==undefined){return generateBlobSASQueryParameters20181109(e,i)}else{if(r>="2020-02-10"){return generateBlobSASQueryParametersUDK20200210(e,n)}else{return generateBlobSASQueryParametersUDK20181109(e,n)}}}if(r>="2015-04-05"){if(i!==undefined){return generateBlobSASQueryParameters20150405(e,i)}else{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 generateBlobSASQueryParameters20150405(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";if(e.blobName){a="b"}let r;if(e.permissions){if(e.blobName){r=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{r=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const i=[r?r:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const n=t.computeHMACSHA256(i);return new SASQueryParameters(e.version,n,r,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType)}function generateBlobSASQueryParameters20181109(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType)}function generateBlobSASQueryParameters20201206(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.identifier&&!(e.permissions&&e.expiresOn)){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.encryptionScope,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,undefined,undefined,undefined,e.encryptionScope)}function generateBlobSASQueryParametersUDK20181109(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey)}function generateBlobSASQueryParametersUDK20200210(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,undefined,e.correlationId,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId)}function generateBlobSASQueryParametersUDK20201206(e,t){e=SASSignatureValuesSanityCheckAndAutofill(e);if(!e.permissions||!e.expiresOn){throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.")}let a="c";let r=e.snapshotTime;if(e.blobName){a="b";if(e.snapshotTime){a="bs"}else if(e.versionId){a="bv";r=e.versionId}}let i;if(e.permissions){if(e.blobName){i=BlobSASPermissions.parse(e.permissions.toString()).toString()}else{i=ContainerSASPermissions.parse(e.permissions.toString()).toString()}}const n=[i?i:"",e.startsOn?truncatedISO8061Date(e.startsOn,false):"",e.expiresOn?truncatedISO8061Date(e.expiresOn,false):"",getCanonicalName(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?truncatedISO8061Date(t.userDelegationKey.signedStartsOn,false):"",t.userDelegationKey.signedExpiresOn?truncatedISO8061Date(t.userDelegationKey.signedExpiresOn,false):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,undefined,e.correlationId,e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",e.version,a,r,e.encryptionScope,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n");const s=t.computeHMACSHA256(n);return new SASQueryParameters(e.version,s,i,undefined,undefined,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,a,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId,e.encryptionScope)}function getCanonicalName(e,t,a){const r=[`/blob/${e}/${t}`];if(a){r.push(`/${a}`)}return r.join("")}function SASSignatureValuesSanityCheckAndAutofill(e){const t=e.version?e.version:Ys;if(e.snapshotTime&&t<"2018-11-09"){throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.")}if(e.blobName===undefined&&e.snapshotTime){throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.")}if(e.versionId&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.")}if(e.blobName===undefined&&e.versionId){throw RangeError("Must provide 'blobName' when providing 'versionId'.")}if(e.permissions&&e.permissions.setImmutabilityPolicy&&t<"2020-08-04"){throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.")}if(e.permissions&&e.permissions.deleteVersion&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.")}if(e.permissions&&e.permissions.permanentDelete&&t<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when providing 'y' permission.")}if(e.permissions&&e.permissions.tag&&t<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.")}if(t<"2020-02-10"&&e.permissions&&(e.permissions.move||e.permissions.execute)){throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.")}if(t<"2021-04-10"&&e.permissions&&e.permissions.filterByTags){throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.")}if(t<"2020-02-10"&&(e.preauthorizedAgentObjectId||e.correlationId)){throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.")}if(e.encryptionScope&&t<"2020-12-06"){throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.")}e.version=t;return e}class BlobLeaseClient{constructor(e,t){const a=new StorageClientContext(e.url,e.pipeline.toServiceClientOptions());this._url=e.url;if(e.name===undefined){this._isContainer=true;this._containerOrBlobOperation=new Container(a)}else{this._isContainer=false;this._containerOrBlobOperation=new Blob$1(a)}if(!t){t=r.generateUuid()}this._leaseId=t}get leaseId(){return this._leaseId}get url(){return this._url}async acquireLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-acquireLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions}),proposedLeaseId:this._leaseId},convertTracingToRequestOptionsBase(d)))}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}async changeLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-changeLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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{const a=await this._containerOrBlobOperation.changeLease(this._leaseId,e,Object.assign({abortSignal:t.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions})},convertTracingToRequestOptionsBase(d)));this._leaseId=e;return a}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}async releaseLease(e={}){var t,a,r,i,s,o;const{span:p,updatedOptions:l}=Do("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)!==lo||((r=e.conditions)===null||r===void 0?void 0:r.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==lo||((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})},convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async renewLease(e={}){var t,a,r,i,s,o;const{span:p,updatedOptions:l}=Do("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)!==lo||((r=e.conditions)===null||r===void 0?void 0:r.ifNoneMatch)&&((i=e.conditions)===null||i===void 0?void 0:i.ifNoneMatch)!==lo||((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})},convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async breakLease(e,t={}){var a,r,i,s,o,p;const{span:l,updatedOptions:d}=Do("BlobLeaseClient-breakLease",t);if(this._isContainer&&(((a=t.conditions)===null||a===void 0?void 0:a.ifMatch)&&((r=t.conditions)===null||r===void 0?void 0:r.ifMatch)!==lo||((i=t.conditions)===null||i===void 0?void 0:i.ifNoneMatch)&&((s=t.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==lo||((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{const a=Object.assign({abortSignal:t.abortSignal,breakPeriod:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(p=t.conditions)===null||p===void 0?void 0:p.tagConditions})},convertTracingToRequestOptionsBase(d));return await this._containerOrBlobOperation.breakLease(a)}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}}class RetriableReadableStream extends d.Readable{constructor(e,t,a,r,i={}){super({highWaterMark:i.highWaterMark});this.retries=0;this.sourceDataHandler=e=>{if(this.options.doInjectErrorOnce){this.options.doInjectErrorOnce=undefined;this.source.pause();this.source.removeAllListeners("data");this.source.emit("end");return}this.offset+=e.length;if(this.onProgress){this.onProgress({loadedBytes:this.offset-this.start})}if(!this.push(e)){this.source.pause()}};this.sourceErrorOrEndHandler=e=>{if(e&&e.name==="AbortError"){this.destroy(e);return}this.removeSourceEventHandlers();if(this.offset-1===this.end){this.push(null)}else if(this.offset<=this.end){if(this.retries{this.source=e;this.setSourceEventHandlers();return})).catch((e=>{this.destroy(e)}))}else{this.destroy(new Error(`Data corruption failure: received less data than required and reached maxRetires limitation. Received data offset: ${this.offset-1}, data needed offset: ${this.end}, retries: ${this.retries}, max retries: ${this.maxRetryRequests}`))}}else{this.destroy(new Error(`Data corruption failure: Received more data than original request, data needed offset is ${this.end}, received offset: ${this.offset-1}`))}};this.getter=t;this.source=e;this.start=a;this.offset=a;this.end=a+r-1;this.maxRetryRequests=i.maxRetryRequests&&i.maxRetryRequests>=0?i.maxRetryRequests:0;this.onProgress=i.onProgress;this.options=i;this.setSourceEventHandlers()}_read(){this.source.resume()}setSourceEventHandlers(){this.source.on("data",this.sourceDataHandler);this.source.on("end",this.sourceErrorOrEndHandler);this.source.on("error",this.sourceErrorOrEndHandler)}removeSourceEventHandlers(){this.source.removeListener("data",this.sourceDataHandler);this.source.removeListener("end",this.sourceErrorOrEndHandler);this.source.removeListener("error",this.sourceErrorOrEndHandler)}_destroy(e,t){this.removeSourceEventHandlers();this.source.destroy();t(e===null?undefined:e)}}class BlobDownloadResponse{constructor(e,t,a,r,i={}){this.originalResponse=e;this.blobDownloadStream=new RetriableReadableStream(this.originalResponse.readableStreamBody,t,a,r,i)}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(){return this.originalResponse.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 tagCount(){return this.originalResponse.tagCount}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 lastAccessed(){return this.originalResponse.lastAccessed}get createdOn(){return this.originalResponse.createdOn}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 versionId(){return this.originalResponse.versionId}get isCurrentVersion(){return this.originalResponse.isCurrentVersion}get encryptionKeySha256(){return this.originalResponse.encryptionKeySha256}get contentCrc64(){return this.originalResponse.contentCrc64}get objectReplicationDestinationPolicyId(){return this.originalResponse.objectReplicationDestinationPolicyId}get objectReplicationSourceProperties(){return this.originalResponse.objectReplicationSourceProperties}get isSealed(){return this.originalResponse.isSealed}get immutabilityPolicyExpiresOn(){return this.originalResponse.immutabilityPolicyExpiresOn}get immutabilityPolicyMode(){return this.originalResponse.immutabilityPolicyMode}get legalHold(){return this.originalResponse.legalHold}get contentAsBlob(){return this.originalResponse.blobBody}get readableStreamBody(){return r.isNode?this.blobDownloadStream:undefined}get _response(){return this.originalResponse._response}}const Ao=16;const Io=new Uint8Array([79,98,106,1]);const Lo="avro.codec";const Mo="avro.schema";class AvroParser{static async readFixedBytes(e,t,a={}){const r=await e.read(t,{abortSignal:a.abortSignal});if(r.length!==t){throw new Error("Hit stream end.")}return r}static async readByte(e,t={}){const a=await AvroParser.readFixedBytes(e,1,t);return a[0]}static async readZigZagLong(e,t={}){let a=0;let r=0;let i,n,s;do{i=await AvroParser.readByte(e,t);n=i&128;a|=(i&127)<Number.MAX_SAFE_INTEGER){throw new Error("Integer overflow.")}return r}return a>>1^-(a&1)}static async readLong(e,t={}){return AvroParser.readZigZagLong(e,t)}static async readInt(e,t={}){return AvroParser.readZigZagLong(e,t)}static async readNull(){return null}static async readBoolean(e,t={}){const a=await AvroParser.readByte(e,t);if(a===1){return true}else if(a===0){return false}else{throw new Error("Byte was not a boolean.")}}static async readFloat(e,t={}){const a=await AvroParser.readFixedBytes(e,4,t);const r=new DataView(a.buffer,a.byteOffset,a.byteLength);return r.getFloat32(0,true)}static async readDouble(e,t={}){const a=await AvroParser.readFixedBytes(e,8,t);const r=new DataView(a.buffer,a.byteOffset,a.byteLength);return r.getFloat64(0,true)}static async readBytes(e,t={}){const a=await AvroParser.readLong(e,t);if(a<0){throw new Error("Bytes size was negative.")}return e.read(a,{abortSignal:t.abortSignal})}static async readString(e,t={}){const a=await AvroParser.readBytes(e,t);const r=new TextDecoder;return r.decode(a)}static async readMapPair(e,t,a={}){const r=await AvroParser.readString(e,a);const i=await t(e,a);return{key:r,value:i}}static async readMap(e,t,a={}){const readPairMethod=(e,a={})=>AvroParser.readMapPair(e,t,a);const r=await AvroParser.readArray(e,readPairMethod,a);const i={};for(const e of r){i[e.key]=e.value}return i}static async readArray(e,t,a={}){const r=[];for(let i=await AvroParser.readLong(e,a);i!==0;i=await AvroParser.readLong(e,a)){if(i<0){await AvroParser.readLong(e,a);i=-i}while(i--){const i=await t(e,a);r.push(i)}}return r}}var Bo;(function(e){e["RECORD"]="record";e["ENUM"]="enum";e["ARRAY"]="array";e["MAP"]="map";e["UNION"]="union";e["FIXED"]="fixed"})(Bo||(Bo={}));var ko;(function(e){e["NULL"]="null";e["BOOLEAN"]="boolean";e["INT"]="int";e["LONG"]="long";e["FLOAT"]="float";e["DOUBLE"]="double";e["BYTES"]="bytes";e["STRING"]="string"})(ko||(ko={}));class AvroType{static fromSchema(e){if(typeof e==="string"){return AvroType.fromStringSchema(e)}else if(Array.isArray(e)){return AvroType.fromArraySchema(e)}else{return AvroType.fromObjectSchema(e)}}static fromStringSchema(e){switch(e){case ko.NULL:case ko.BOOLEAN:case ko.INT:case ko.LONG:case ko.FLOAT:case ko.DOUBLE:case ko.BYTES:case ko.STRING:return new AvroPrimitiveType(e);default:throw new Error(`Unexpected Avro type ${e}`)}}static fromArraySchema(e){return new AvroUnionType(e.map(AvroType.fromSchema))}static fromObjectSchema(e){const t=e.type;try{return AvroType.fromStringSchema(t)}catch(e){}switch(t){case Bo.RECORD:if(e.aliases){throw new Error(`aliases currently is not supported, schema: ${e}`)}if(!e.name){throw new Error(`Required attribute 'name' doesn't exist on schema: ${e}`)}const a={};if(!e.fields){throw new Error(`Required attribute 'fields' doesn't exist on schema: ${e}`)}for(const t of e.fields){a[t.name]=AvroType.fromSchema(t.type)}return new AvroRecordType(a,e.name);case Bo.ENUM:if(e.aliases){throw new Error(`aliases currently is not supported, schema: ${e}`)}if(!e.symbols){throw new Error(`Required attribute 'symbols' doesn't exist on schema: ${e}`)}return new AvroEnumType(e.symbols);case Bo.MAP:if(!e.values){throw new Error(`Required attribute 'values' doesn't exist on schema: ${e}`)}return new AvroMapType(AvroType.fromSchema(e.values));case Bo.ARRAY:case Bo.FIXED:default:throw new Error(`Unexpected Avro type ${t} in ${e}`)}}}class AvroPrimitiveType extends AvroType{constructor(e){super();this._primitive=e}read(e,t={}){switch(this._primitive){case ko.NULL:return AvroParser.readNull();case ko.BOOLEAN:return AvroParser.readBoolean(e,t);case ko.INT:return AvroParser.readInt(e,t);case ko.LONG:return AvroParser.readLong(e,t);case ko.FLOAT:return AvroParser.readFloat(e,t);case ko.DOUBLE:return AvroParser.readDouble(e,t);case ko.BYTES:return AvroParser.readBytes(e,t);case ko.STRING:return AvroParser.readString(e,t);default:throw new Error("Unknown Avro Primitive")}}}class AvroEnumType extends AvroType{constructor(e){super();this._symbols=e}async read(e,t={}){const a=await AvroParser.readInt(e,t);return this._symbols[a]}}class AvroUnionType extends AvroType{constructor(e){super();this._types=e}async read(e,t={}){const a=await AvroParser.readInt(e,t);return this._types[a].read(e,t)}}class AvroMapType extends AvroType{constructor(e){super();this._itemType=e}read(e,t={}){const readItemMethod=(e,t)=>this._itemType.read(e,t);return AvroParser.readMap(e,readItemMethod,t)}}class AvroRecordType extends AvroType{constructor(e,t){super();this._fields=e;this._name=t}async read(e,t={}){const a={};a["$schema"]=this._name;for(const r in this._fields){if(Object.prototype.hasOwnProperty.call(this._fields,r)){a[r]=await this._fields[r].read(e,t)}}return a}}function arraysEqual(e,t){if(e===t)return true;if(e==null||t==null)return false;if(e.length!==t.length)return false;for(let a=0;a0){for(let t=0;t0}parseObjects(e={}){return i.__asyncGenerator(this,arguments,(function*parseObjects_1(){if(!this._initialized){yield i.__await(this.initialize(e))}while(this.hasNext()){const t=yield i.__await(this._itemType.read(this._dataStream,{abortSignal:e.abortSignal}));this._itemsRemainingInBlock--;this._objectIndex++;if(this._itemsRemainingInBlock===0){const t=yield i.__await(AvroParser.readFixedBytes(this._dataStream,Ao,{abortSignal:e.abortSignal}));this._blockOffset=this._initialBlockOffset+this._dataStream.position;this._objectIndex=0;if(!arraysEqual(this._syncMarker,t)){throw new Error("Stream is not a valid Avro file.")}try{this._itemsRemainingInBlock=yield i.__await(AvroParser.readLong(this._dataStream,{abortSignal:e.abortSignal}))}catch(e){this._itemsRemainingInBlock=0}if(this._itemsRemainingInBlock>0){yield i.__await(AvroParser.readLong(this._dataStream,{abortSignal:e.abortSignal}))}}yield yield i.__await(t)}}))}}class AvroReadable{}const zo=new o.AbortError("Reading from the avro stream was aborted.");class AvroReadableFromStream extends AvroReadable{constructor(e){super();this._readable=e;this._position=0}toUint8Array(e){if(typeof e==="string"){return Buffer.from(e)}return e}get position(){return this._position}async read(e,t={}){var a;if((a=t.abortSignal)===null||a===void 0?void 0:a.aborted){throw zo}if(e<0){throw new Error(`size parameter should be positive: ${e}`)}if(e===0){return new Uint8Array}if(!this._readable.readable){throw new Error("Stream no longer readable.")}const r=this._readable.read(e);if(r){this._position+=r.length;return this.toUint8Array(r)}else{return new Promise(((a,r)=>{const cleanUp=()=>{this._readable.removeListener("readable",readableCallback);this._readable.removeListener("error",rejectCallback);this._readable.removeListener("end",rejectCallback);this._readable.removeListener("close",rejectCallback);if(t.abortSignal){t.abortSignal.removeEventListener("abort",abortHandler)}};const readableCallback=()=>{const t=this._readable.read(e);if(t){this._position+=t.length;cleanUp();a(this.toUint8Array(t))}};const rejectCallback=()=>{cleanUp();r()};const abortHandler=()=>{cleanUp();r(zo)};this._readable.on("readable",readableCallback);this._readable.once("error",rejectCallback);this._readable.once("end",rejectCallback);this._readable.once("close",rejectCallback);if(t.abortSignal){t.abortSignal.addEventListener("abort",abortHandler)}}))}}}class BlobQuickQueryStream extends d.Readable{constructor(e,t={}){super();this.avroPaused=true;this.source=e;this.onProgress=t.onProgress;this.onError=t.onError;this.avroReader=new AvroReader(new AvroReadableFromStream(this.source));this.avroIter=this.avroReader.parseObjects({abortSignal:t.abortSignal})}_read(){if(this.avroPaused){this.readInternal().catch((e=>{this.emit("error",e)}))}}async readInternal(){this.avroPaused=false;let e;do{e=await this.avroIter.next();if(e.done){break}const t=e.value;const a=t.$schema;if(typeof a!=="string"){throw Error("Missing schema in avro record.")}switch(a){case"com.microsoft.azure.storage.queryBlobContents.resultData":{const e=t.data;if(e instanceof Uint8Array===false){throw Error("Invalid data in avro result record.")}if(!this.push(Buffer.from(e))){this.avroPaused=true}}break;case"com.microsoft.azure.storage.queryBlobContents.progress":{const e=t.bytesScanned;if(typeof e!=="number"){throw Error("Invalid bytesScanned in avro progress record.")}if(this.onProgress){this.onProgress({loadedBytes:e})}}break;case"com.microsoft.azure.storage.queryBlobContents.end":if(this.onProgress){const e=t.totalBytes;if(typeof e!=="number"){throw Error("Invalid totalBytes in avro end record.")}this.onProgress({loadedBytes:e})}this.push(null);break;case"com.microsoft.azure.storage.queryBlobContents.error":if(this.onError){const e=t.fatal;if(typeof e!=="boolean"){throw Error("Invalid fatal in avro error record.")}const a=t.name;if(typeof a!=="string"){throw Error("Invalid name in avro error record.")}const r=t.description;if(typeof r!=="string"){throw Error("Invalid description in avro error record.")}const i=t.position;if(typeof i!=="number"){throw Error("Invalid position in avro error record.")}this.onError({position:i,name:a,isFatal:e,description:r})}break;default:throw Error(`Unknown schema ${a} in avro progress record.`)}}while(!e.done&&!this.avroPaused)}}class BlobQueryResponse{constructor(e,t={}){this.originalResponse=e;this.blobDownloadStream=new BlobQuickQueryStream(this.originalResponse.readableStreamBody,t)}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(){return undefined}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(){return undefined}get readableStreamBody(){return r.isNode?this.blobDownloadStream:undefined}get _response(){return this.originalResponse._response}}t.BlockBlobTier=void 0;(function(e){e["Hot"]="Hot";e["Cool"]="Cool";e["Cold"]="Cold";e["Archive"]="Archive"})(t.BlockBlobTier||(t.BlockBlobTier={}));t.PremiumPageBlobTier=void 0;(function(e){e["P4"]="P4";e["P6"]="P6";e["P10"]="P10";e["P15"]="P15";e["P20"]="P20";e["P30"]="P30";e["P40"]="P40";e["P50"]="P50";e["P60"]="P60";e["P70"]="P70";e["P80"]="P80"})(t.PremiumPageBlobTier||(t.PremiumPageBlobTier={}));function toAccessTier(e){if(e===undefined){return undefined}return e}function ensureCpkIfSpecified(e,t){if(e&&!t){throw new RangeError("Customer-provided encryption key must be used over HTTPS.")}if(e&&!e.encryptionAlgorithm){e.encryptionAlgorithm=yo}}t.StorageBlobAudience=void 0;(function(e){e["StorageOAuthScopes"]="https://storage.azure.com/.default";e["DiskComputeOAuthScopes"]="https://disk.compute.azure.com/.default"})(t.StorageBlobAudience||(t.StorageBlobAudience={}));function rangeResponseFromModel(e){const t=(e._response.parsedBody.pageRange||[]).map((e=>({offset:e.start,count:e.end-e.start})));const a=(e._response.parsedBody.clearRange||[]).map((e=>({offset:e.start,count:e.end-e.start})));return Object.assign(Object.assign({},e),{pageRange:t,clearRange:a,_response:Object.assign(Object.assign({},e._response),{parsedBody:{pageRange:t,clearRange:a}})})}class BlobBeginCopyFromUrlPoller extends c.Poller{constructor(e){const{blobClient:t,copySource:a,intervalInMs:r=15e3,onProgress:i,resumeFrom:n,startCopyFromURLOptions:s}=e;let o;if(n){o=JSON.parse(n).state}const p=makeBlobBeginCopyFromURLPollOperation(Object.assign(Object.assign({},o),{blobClient:t,copySource:a,startCopyFromURLOptions:s}));super(p);if(typeof i==="function"){this.onProgress(i)}this.intervalInMs=r}delay(){return r.delay(this.intervalInMs)}}const jo=async function cancel(e={}){const t=this.state;const{copyId:a}=t;if(t.isCompleted){return makeBlobBeginCopyFromURLPollOperation(t)}if(!a){t.isCancelled=true;return makeBlobBeginCopyFromURLPollOperation(t)}await t.blobClient.abortCopyFromURL(a,{abortSignal:e.abortSignal});t.isCancelled=true;return makeBlobBeginCopyFromURLPollOperation(t)};const qo=async function update(e={}){const t=this.state;const{blobClient:a,copySource:r,startCopyFromURLOptions:i}=t;if(!t.isStarted){t.isStarted=true;const e=await a.startCopyFromURL(r,i);t.copyId=e.copyId;if(e.copyStatus==="success"){t.result=e;t.isCompleted=true}}else if(!t.isCompleted){try{const a=await t.blobClient.getProperties({abortSignal:e.abortSignal});const{copyStatus:r,copyProgress:i}=a;const n=t.copyProgress;if(i){t.copyProgress=i}if(r==="pending"&&i!==n&&typeof e.fireProgress==="function"){e.fireProgress(t)}else if(r==="success"){t.result=a;t.isCompleted=true}else if(r==="failed"){t.error=new Error(`Blob copy failed with reason: "${a.copyStatusDescription||"unknown"}"`);t.isCompleted=true}}catch(e){t.error=e;t.isCompleted=true}}return makeBlobBeginCopyFromURLPollOperation(t)};const Uo=function toString(){return JSON.stringify({state:this.state},((e,t)=>{if(e==="blobClient"){return undefined}return t}))};function makeBlobBeginCopyFromURLPollOperation(e){return{state:Object.assign({},e),cancel:jo,toString:Uo,update:qo}}function rangeToString(e){if(e.offset<0){throw new RangeError(`Range.offset cannot be smaller than 0.`)}if(e.count&&e.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 e.count?`bytes=${e.offset}-${e.offset+e.count-1}`:`bytes=${e.offset}-`}var Fo;(function(e){e[e["Good"]=0]="Good";e[e["Error"]=1]="Error"})(Fo||(Fo={}));class Batch{constructor(e=5){this.actives=0;this.completed=0;this.offset=0;this.operations=[];this.state=Fo.Good;if(e<1){throw new RangeError("concurrency must be larger than 0")}this.concurrency=e;this.emitter=new m.EventEmitter}addOperation(e){this.operations.push((async()=>{try{this.actives++;await e();this.actives--;this.completed++;this.parallelExecute()}catch(e){this.emitter.emit("error",e)}}))}async do(){if(this.operations.length===0){return Promise.resolve()}this.parallelExecute();return new Promise(((e,t)=>{this.emitter.on("finish",e);this.emitter.on("error",(e=>{this.state=Fo.Error;t(e)}))}))}nextOperation(){if(this.offset=this.operations.length){this.emitter.emit("finish");return}while(this.actives=this.byteLength){this.push(null)}if(!e){e=this.readableHighWaterMark}const t=[];let a=0;while(ae-a){const r=this.byteOffsetInCurrentBuffer+e-a;t.push(this.buffers[this.bufferIndex].slice(this.byteOffsetInCurrentBuffer,r));this.pushedBytesLength+=e-a;this.byteOffsetInCurrentBuffer=r;a=e;break}else{const e=this.byteOffsetInCurrentBuffer+n;t.push(this.buffers[this.bufferIndex].slice(this.byteOffsetInCurrentBuffer,e));if(n===i){this.byteOffsetInCurrentBuffer=0;this.bufferIndex++}else{this.byteOffsetInCurrentBuffer=e}this.pushedBytesLength+=n;a+=n}}if(t.length>1){this.push(Buffer.concat(t))}else if(t.length===1){this.push(t[0])}}}const Ho=a(4300).constants.MAX_LENGTH;class PooledBuffer{constructor(e,t,a){this.buffers=[];this.capacity=e;this._size=0;const r=Math.ceil(e/Ho);for(let t=0;t0){e[0]=e[0].slice(n)}}getReadableStream(){return new BuffersStream(this.buffers,this.size)}}class BufferScheduler{constructor(e,t,a,r,i,n){this.emitter=new m.EventEmitter;this.offset=0;this.isStreamEnd=false;this.isError=false;this.executingOutgoingHandlers=0;this.numBuffers=0;this.unresolvedDataArray=[];this.unresolvedLength=0;this.incoming=[];this.outgoing=[];if(t<=0){throw new RangeError(`bufferSize must be larger than 0, current is ${t}`)}if(a<=0){throw new RangeError(`maxBuffers must be larger than 0, current is ${a}`)}if(i<=0){throw new RangeError(`concurrency must be larger than 0, current is ${i}`)}this.bufferSize=t;this.maxBuffers=a;this.readable=e;this.outgoingHandler=r;this.concurrency=i;this.encoding=n}async do(){return new Promise(((e,t)=>{this.readable.on("data",(e=>{e=typeof e==="string"?Buffer.from(e,this.encoding):e;this.appendUnresolvedData(e);if(!this.resolveData()){this.readable.pause()}}));this.readable.on("error",(e=>{this.emitter.emit("error",e)}));this.readable.on("end",(()=>{this.isStreamEnd=true;this.emitter.emit("checkEnd")}));this.emitter.on("error",(e=>{this.isError=true;this.readable.pause();t(e)}));this.emitter.on("checkEnd",(()=>{if(this.outgoing.length>0){this.triggerOutgoingHandlers();return}if(this.isStreamEnd&&this.executingOutgoingHandlers===0){if(this.unresolvedLength>0&&this.unresolvedLengtha.getReadableStream()),a.size,this.offset).then(e).catch(t)}else if(this.unresolvedLength>=this.bufferSize){return}else{e()}}}))}))}appendUnresolvedData(e){this.unresolvedDataArray.push(e);this.unresolvedLength+=e.length}shiftBufferFromUnresolvedDataArray(e){if(!e){e=new PooledBuffer(this.bufferSize,this.unresolvedDataArray,this.unresolvedLength)}else{e.fill(this.unresolvedDataArray,this.unresolvedLength)}this.unresolvedLength-=e.size;return e}resolveData(){while(this.unresolvedLength>=this.bufferSize){let e;if(this.incoming.length>0){e=this.incoming.shift();this.shiftBufferFromUnresolvedDataArray(e)}else{if(this.numBuffers=this.concurrency){return}e=this.outgoing.shift();if(e){this.triggerOutgoingHandler(e)}}while(e)}async triggerOutgoingHandler(e){const t=e.size;this.executingOutgoingHandlers++;this.offset+=t;try{await this.outgoingHandler((()=>e.getReadableStream()),t,this.offset-t)}catch(e){this.emitter.emit("error",e);return}this.executingOutgoingHandlers--;this.reuseBuffer(e);this.emitter.emit("checkEnd")}reuseBuffer(e){this.incoming.push(e);if(!this.isError&&this.resolveData()&&!this.isStreamEnd){this.readable.resume()}}}async function streamToBuffer(e,t,a,r,i){let n=0;const s=r-a;return new Promise(((r,o)=>{const p=setTimeout((()=>o(new Error(`The operation cannot be completed in timeout.`))),io);e.on("readable",(()=>{if(n>=s){clearTimeout(p);r();return}let o=e.read();if(!o){return}if(typeof o==="string"){o=Buffer.from(o,i)}const l=n+o.length>s?s-n:o.length;t.fill(o.slice(0,l),a+n,a+n+l);n+=l}));e.on("end",(()=>{clearTimeout(p);if(n{clearTimeout(p);o(e)}))}))}async function streamToBuffer2(e,t,a){let r=0;const i=t.length;return new Promise(((n,s)=>{e.on("readable",(()=>{let n=e.read();if(!n){return}if(typeof n==="string"){n=Buffer.from(n,a)}if(r+n.length>i){s(new Error(`Stream exceeds buffer size. Buffer size: ${i}`));return}t.fill(n,r,r+n.length);r+=n.length}));e.on("end",(()=>{n(r)}));e.on("error",s)}))}async function readStreamToLocalFile(e,t){return new Promise(((a,r)=>{const i=v.createWriteStream(t);e.on("error",(e=>{r(e)}));i.on("error",(e=>{r(e)}));i.on("close",a);e.pipe(i)}))}const Vo=b.promisify(v.stat);const Go=v.createReadStream;class BlobClient extends StorageClient{constructor(e,t,a,i){i=i||{};let n;let s;if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;if(a&&typeof a!=="string"){i=a}n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);({blobName:this._name,containerName:this._containerName}=this.getBlobAndContainerNamesFromUrl());this.blobContext=new Blob$1(this.storageClientContext);this._snapshot=getURLParameter(this.url,so.Parameters.SNAPSHOT);this._versionId=getURLParameter(this.url,so.Parameters.VERSIONID)}get name(){return this._name}get containerName(){return this._containerName}withSnapshot(e){return new BlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}withVersion(e){return new BlobClient(setURLParameter(this.url,so.Parameters.VERSIONID,e.length===0?undefined:e),this.pipeline)}getAppendBlobClient(){return new AppendBlobClient(this.url,this.pipeline)}getBlockBlobClient(){return new BlockBlobClient(this.url,this.pipeline)}getPageBlobClient(){return new PageBlobClient(this.url,this.pipeline)}async download(e=0,t,a={}){var i;a.conditions=a.conditions||{};a.conditions=a.conditions||{};ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);const{span:s,updatedOptions:o}=Do("BlobClient-download",a);try{const n=await this.blobContext.download(Object.assign({abortSignal:a.abortSignal,leaseAccessConditions:a.conditions,modifiedAccessConditions:Object.assign(Object.assign({},a.conditions),{ifTags:(i=a.conditions)===null||i===void 0?void 0:i.tagConditions}),requestOptions:{onDownloadProgress:r.isNode?undefined:a.onProgress},range:e===0&&!t?undefined:rangeToString({offset:e,count:t}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey},convertTracingToRequestOptionsBase(o)));const p=Object.assign(Object.assign({},n),{_response:n._response,objectReplicationDestinationPolicyId:n.objectReplicationPolicyId,objectReplicationSourceProperties:parseObjectReplicationRecord(n.objectReplicationRules)});if(!r.isNode){return p}if(a.maxRetryRequests===undefined||a.maxRetryRequests<0){a.maxRetryRequests=ro}if(n.contentLength===undefined){throw new RangeError(`File download response doesn't contain valid content length header`)}if(!n.etag){throw new RangeError(`File download response doesn't contain valid etag header`)}return new BlobDownloadResponse(p,(async t=>{var r;const i={leaseAccessConditions:a.conditions,modifiedAccessConditions:{ifMatch:a.conditions.ifMatch||n.etag,ifModifiedSince:a.conditions.ifModifiedSince,ifNoneMatch:a.conditions.ifNoneMatch,ifUnmodifiedSince:a.conditions.ifUnmodifiedSince,ifTags:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions},range:rangeToString({count:e+n.contentLength-t,offset:t}),rangeGetContentMD5:a.rangeGetContentMD5,rangeGetContentCRC64:a.rangeGetContentCrc64,snapshot:a.snapshot,cpkInfo:a.customerProvidedKey};return(await this.blobContext.download(Object.assign({abortSignal:a.abortSignal},i))).readableStreamBody}),e,n.contentLength,{maxRetryRequests:a.maxRetryRequests,onProgress:a.onProgress})}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async exists(e={}){const{span:t,updatedOptions:a}=Do("BlobClient-exists",e);try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);await this.getProperties({abortSignal:e.abortSignal,customerProvidedKey:e.customerProvidedKey,conditions:e.conditions,tracingOptions:a.tracingOptions});return true}catch(e){if(e.statusCode===404){return false}else if(e.statusCode===409&&(e.details.errorCode===wo||e.details.errorCode===So)){return true}t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async getProperties(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-getProperties",e);try{e.conditions=e.conditions||{};ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);const 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},convertTracingToRequestOptionsBase(r)));return Object.assign(Object.assign({},i),{_response:i._response,objectReplicationDestinationPolicyId:i.objectReplicationPolicyId,objectReplicationSourceProperties:parseObjectReplicationRecord(i.objectReplicationRules)})}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async delete(e={}){var t;const{span:a,updatedOptions:r}=Do("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})},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async deleteIfExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("BlobClient-deleteIfExists",e);try{const e=await this.delete(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="BlobNotFound"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when deleting a blob or snapshot only if it exists."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async undelete(e={}){const{span:t,updatedOptions:a}=Do("BlobClient-undelete",e);try{return await this.blobContext.undelete(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setHTTPHeaders(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setHTTPHeaders",t);t.conditions=t.conditions||{};try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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})},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setMetadata(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setMetadata",t);t.conditions=t.conditions||{};try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setTags(e,t={}){var a;const{span:r,updatedOptions:i}=Do("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})},convertTracingToRequestOptionsBase(i)),{tags:toBlobTags(e)}))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async getTags(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-getTags",e);try{const 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})},convertTracingToRequestOptionsBase(r)));const n=Object.assign(Object.assign({},i),{_response:i._response,tags:toTags({blobTagSet:i.blobTagSet})||{}});return n}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}getBlobLeaseClient(e){return new BlobLeaseClient(this,e)}async createSnapshot(e={}){var t;const{span:a,updatedOptions:r}=Do("BlobClient-createSnapshot",e);e.conditions=e.conditions||{};try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);return 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},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async beginCopyFromURL(e,t={}){const a={abortCopyFromURL:(...e)=>this.abortCopyFromURL(...e),getProperties:(...e)=>this.getProperties(...e),startCopyFromURL:(...e)=>this.startCopyFromURL(...e)};const r=new BlobBeginCopyFromUrlPoller({blobClient:a,copySource:e,intervalInMs:t.intervalInMs,onProgress:t.onProgress,resumeFrom:t.resumeFrom,startCopyFromURLOptions:t});await r.poll();return r}async abortCopyFromURL(e,t={}){const{span:a,updatedOptions:r}=Do("BlobClient-abortCopyFromURL",t);try{return await this.blobContext.abortCopyFromURL(e,Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async syncCopyFromURL(e,t={}){var a,r,i;const{span:s,updatedOptions:o}=Do("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:httpAuthorizationToString(t.sourceAuthorization),tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags),immutabilityPolicyExpiry:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,encryptionScope:t.encryptionScope,copySourceTags:t.copySourceTags},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async setAccessTier(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlobClient-setAccessTier",t);try{return await this.blobContext.setTier(toAccessTier(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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async downloadToBuffer(e,t,a,r={}){let i;let s=0;let o=0;let p=r;if(e instanceof Buffer){i=e;s=t||0;o=typeof a==="number"?a:0}else{s=typeof e==="number"?e:0;o=typeof t==="number"?t:0;p=a||{}}const{span:l,updatedOptions:d}=Do("BlobClient-downloadToBuffer",p);try{if(!p.blockSize){p.blockSize=0}if(p.blockSize<0){throw new RangeError("blockSize option must be >= 0")}if(p.blockSize===0){p.blockSize=ao}if(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(!p.conditions){p.conditions={}}if(!o){const e=await this.getProperties(Object.assign(Object.assign({},p),{tracingOptions:Object.assign(Object.assign({},p.tracingOptions),convertTracingToRequestOptionsBase(d))}));o=e.contentLength-s;if(o<0){throw new RangeError(`offset ${s} shouldn't be larger than blob size ${e.contentLength}`)}}if(!i){try{i=Buffer.alloc(o)}catch(e){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".\t ${e.message}`)}}if(i.length{let t=s+o;if(a+p.blockSize{if(!(this.credential instanceof StorageSharedKeyCredential)){throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential")}const a=generateBlobSASQueryParameters(Object.assign({containerName:this._containerName,blobName:this._name,snapshotTime:this._snapshot,versionId:this._versionId},e),this.credential).toString();t(appendToURLQuery(this.url,a))}))}async deleteImmutabilityPolicy(e){const{span:t,updatedOptions:a}=Do("BlobClient-deleteImmutabilityPolicy",e);try{return await this.blobContext.deleteImmutabilityPolicy(Object.assign({abortSignal:e===null||e===void 0?void 0:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setImmutabilityPolicy(e,t){const{span:a,updatedOptions:r}=Do("BlobClient-setImmutabilityPolicy",t);try{return await this.blobContext.setImmutabilityPolicy(Object.assign({abortSignal:t===null||t===void 0?void 0:t.abortSignal,immutabilityPolicyExpiry:e.expiriesOn,immutabilityPolicyMode:e.policyMode,modifiedAccessConditions:t===null||t===void 0?void 0:t.modifiedAccessCondition},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async setLegalHold(e,t){const{span:a,updatedOptions:r}=Do("BlobClient-setLegalHold",t);try{return await this.blobContext.setLegalHold(e,Object.assign({abortSignal:t===null||t===void 0?void 0:t.abortSignal},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}}class AppendBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.appendBlobContext=new AppendBlob(this.storageClientContext)}withSnapshot(e){return new AppendBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async create(e={}){var t,a,r;const{span:i,updatedOptions:s}=Do("AppendBlobClient-create",e);e.conditions=e.conditions||{};try{ensureCpkIfSpecified(e.customerProvidedKey,this.isHttps);return 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:(r=e.immutabilityPolicy)===null||r===void 0?void 0:r.policyMode,legalHold:e.legalHold,blobTagsString:toBlobTagsString(e.tags)},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async createIfNotExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("AppendBlobClient-createIfNotExists",e);const s={ifNoneMatch:co};try{const e=await this.create(Object.assign(Object.assign({},i),{conditions:s}));return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="BlobAlreadyExists"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a blob only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async seal(e={}){var t;const{span:a,updatedOptions:r}=Do("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})},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async appendBlock(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("AppendBlobClient-appendBlock",a);a.conditions=a.conditions||{};try{ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);return 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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),requestOptions:{onUploadProgress:a.onProgress},transactionalContentMD5:a.transactionalContentMD5,transactionalContentCrc64:a.transactionalContentCrc64,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async appendBlockFromURL(e,t,a,r={}){var i;const{span:s,updatedOptions:o}=Do("AppendBlobClient-appendBlockFromURL",r);r.conditions=r.conditions||{};r.sourceConditions=r.sourceConditions||{};try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.appendBlobContext.appendBlockFromUrl(e,0,Object.assign({abortSignal:r.abortSignal,sourceRange:rangeToString({offset:t,count:a}),sourceContentMD5:r.sourceContentMD5,sourceContentCrc64:r.sourceContentCrc64,leaseAccessConditions:r.conditions,appendPositionAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:r.sourceConditions.ifMatch,sourceIfModifiedSince:r.sourceConditions.ifModifiedSince,sourceIfNoneMatch:r.sourceConditions.ifNoneMatch,sourceIfUnmodifiedSince:r.sourceConditions.ifUnmodifiedSince},copySourceAuthorization:httpAuthorizationToString(r.sourceAuthorization),cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}}class BlockBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;if(a&&typeof a!=="string"){i=a}n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.blockBlobContext=new BlockBlob(this.storageClientContext);this._blobContext=new Blob$1(this.storageClientContext)}withSnapshot(e){return new BlockBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async query(e,t={}){var a;ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);const{span:i,updatedOptions:s}=Do("BlockBlobClient-query",t);try{if(!r.isNode){throw new Error("This operation currently is only supported in Node.js.")}ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);const n=await this._blobContext.query(Object.assign({abortSignal:t.abortSignal,queryRequest:{queryType:"SQL",expression:e,inputSerialization:toQuerySerialization(t.inputTextConfiguration),outputSerialization:toQuerySerialization(t.outputTextConfiguration)},leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:(a=t.conditions)===null||a===void 0?void 0:a.tagConditions}),cpkInfo:t.customerProvidedKey},convertTracingToRequestOptionsBase(s)));return new BlobQueryResponse(n,{abortSignal:t.abortSignal,onProgress:t.onProgress,onError:t.onError})}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async upload(e,t,a={}){var r,i,s;a.conditions=a.conditions||{};const{span:o,updatedOptions:p}=Do("BlockBlobClient-upload",a);try{ensureCpkIfSpecified(a.customerProvidedKey,this.isHttps);return 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:(r=a.conditions)===null||r===void 0?void 0:r.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:toAccessTier(a.tier),blobTagsString:toBlobTagsString(a.tags)},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async syncUploadFromURL(e,t={}){var a,r,i,s,o;t.conditions=t.conditions||{};const{span:p,updatedOptions:l}=Do("BlockBlobClient-syncUploadFromURL",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.sourceConditions)===null||r===void 0?void 0:r.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:httpAuthorizationToString(t.sourceAuthorization),tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags),copySourceTags:t.copySourceTags}),convertTracingToRequestOptionsBase(l)))}catch(e){p.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{p.end()}}async stageBlock(e,t,a,r={}){const{span:i,updatedOptions:s}=Do("BlockBlobClient-stageBlock",r);try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.blockBlobContext.stageBlock(e,a,t,Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,requestOptions:{onUploadProgress:r.onProgress},transactionalContentMD5:r.transactionalContentMD5,transactionalContentCrc64:r.transactionalContentCrc64,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async stageBlockFromURL(e,t,a=0,r,i={}){const{span:s,updatedOptions:o}=Do("BlockBlobClient-stageBlockFromURL",i);try{ensureCpkIfSpecified(i.customerProvidedKey,this.isHttps);return await this.blockBlobContext.stageBlockFromURL(e,0,t,Object.assign({abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,sourceContentMD5:i.sourceContentMD5,sourceContentCrc64:i.sourceContentCrc64,sourceRange:a===0&&!r?undefined:rangeToString({offset:a,count:r}),cpkInfo:i.customerProvidedKey,encryptionScope:i.encryptionScope,copySourceAuthorization:httpAuthorizationToString(i.sourceAuthorization)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async commitBlockList(e,t={}){var a,r,i;t.conditions=t.conditions||{};const{span:s,updatedOptions:o}=Do("BlockBlobClient-commitBlockList",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async getBlockList(e,t={}){var a;const{span:r,updatedOptions:i}=Do("BlockBlobClient-getBlockList",t);try{const n=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})},convertTracingToRequestOptionsBase(i)));if(!n.committedBlocks){n.committedBlocks=[]}if(!n.uncommittedBlocks){n.uncommittedBlocks=[]}return n}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async uploadData(e,t={}){const{span:a,updatedOptions:i}=Do("BlockBlobClient-uploadData",t);try{if(r.isNode){let t;if(e instanceof Buffer){t=e}else if(e instanceof ArrayBuffer){t=Buffer.from(e)}else{e=e;t=Buffer.from(e.buffer,e.byteOffset,e.byteLength)}return this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.byteLength,i)}else{const t=new Blob([e]);return this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.size,i)}}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadBrowserData(e,t={}){const{span:a,updatedOptions:r}=Do("BlockBlobClient-uploadBrowserData",t);try{const t=new Blob([e]);return await this.uploadSeekableInternal(((e,a)=>t.slice(e,e+a)),t.size,r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadSeekableInternal(e,t,a={}){if(!a.blockSize){a.blockSize=0}if(a.blockSize<0||a.blockSize>Zs){throw new RangeError(`blockSize option must be >= 0 and <= ${Zs}`)}if(a.maxSingleShotSize!==0&&!a.maxSingleShotSize){a.maxSingleShotSize=Js}if(a.maxSingleShotSize<0||a.maxSingleShotSize>Js){throw new RangeError(`maxSingleShotSize option must be >= 0 and <= ${Js}`)}if(a.blockSize===0){if(t>Zs*eo){throw new RangeError(`${t} is too larger to upload to a block blob.`)}if(t>a.maxSingleShotSize){a.blockSize=Math.ceil(t/eo);if(a.blockSizeeo){throw new RangeError(`The buffer's size is too big or the BlockSize is too small;`+`the number of blocks must be <= ${eo}`)}const o=[];const p=r.generateUuid();let l=0;const d=new Batch(a.concurrency);for(let r=0;r{const i=generateBlockID(p,r);const d=a.blockSize*r;const c=r===n-1?t:d+a.blockSize;const m=c-d;o.push(i);await this.stageBlock(i,e(d,m),m,{abortSignal:a.abortSignal,conditions:a.conditions,encryptionScope:a.encryptionScope,tracingOptions:s.tracingOptions});l+=m;if(a.onProgress){a.onProgress({loadedBytes:l})}}))}await d.do();return this.commitBlockList(o,s)}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async uploadFile(e,t={}){const{span:a,updatedOptions:r}=Do("BlockBlobClient-uploadFile",t);try{const i=(await Vo(e)).size;return await this.uploadSeekableInternal(((t,a)=>()=>Go(e,{autoClose:true,end:a?t+a-1:Infinity,start:t})),i,Object.assign(Object.assign({},t),{tracingOptions:Object.assign(Object.assign({},t.tracingOptions),convertTracingToRequestOptionsBase(r))}))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async uploadStream(e,t=to,a=5,i={}){if(!i.blobHTTPHeaders){i.blobHTTPHeaders={}}if(!i.conditions){i.conditions={}}const{span:s,updatedOptions:o}=Do("BlockBlobClient-uploadStream",i);try{let n=0;const p=r.generateUuid();let l=0;const d=[];const c=new BufferScheduler(e,t,a,(async(e,t)=>{const a=generateBlockID(p,n);d.push(a);n++;await this.stageBlock(a,e,t,{conditions:i.conditions,encryptionScope:i.encryptionScope,tracingOptions:o.tracingOptions});l+=t;if(i.onProgress){i.onProgress({loadedBytes:l})}}),Math.ceil(a/4*3));await c.do();return await this.commitBlockList(d,Object.assign(Object.assign({},i),{tracingOptions:Object.assign(Object.assign({},i.tracingOptions),convertTracingToRequestOptionsBase(o))}))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}}class PageBlobClient extends BlobClient{constructor(e,t,a,i){let n;let s;i=i||{};if(isPipelineLike(t)){s=e;n=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){s=e;i=a;n=newPipeline(t,i)}else if(!t&&typeof t!=="string"){s=e;n=newPipeline(new AnonymousCredential,i)}else if(t&&typeof t==="string"&&a&&typeof a==="string"){const o=t;const p=a;const l=extractConnectionStringParts(e);if(l.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(l.accountName,l.accountKey);s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p));if(!i.proxyOptions){i.proxyOptions=r.getDefaultProxySettings(l.proxyUri)}n=newPipeline(e,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(l.kind==="SASConnString"){s=appendToURLPath(appendToURLPath(l.url,encodeURIComponent(o)),encodeURIComponent(p))+"?"+l.accountSas;n=newPipeline(new AnonymousCredential,i)}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,n);this.pageBlobContext=new PageBlob(this.storageClientContext)}withSnapshot(e){return new PageBlobClient(setURLParameter(this.url,so.Parameters.SNAPSHOT,e.length===0?undefined:e),this.pipeline)}async create(e,t={}){var a,r,i;t.conditions=t.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-create",t);try{ensureCpkIfSpecified(t.customerProvidedKey,this.isHttps);return 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:(r=t.immutabilityPolicy)===null||r===void 0?void 0:r.expiriesOn,immutabilityPolicyMode:(i=t.immutabilityPolicy)===null||i===void 0?void 0:i.policyMode,legalHold:t.legalHold,tier:toAccessTier(t.tier),blobTagsString:toBlobTagsString(t.tags)},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async createIfNotExists(e,t={}){var a,r;const{span:i,updatedOptions:s}=Do("PageBlobClient-createIfNotExists",t);try{const a={ifNoneMatch:co};const r=await this.create(e,Object.assign(Object.assign({},t),{conditions:a,tracingOptions:s.tracingOptions}));return Object.assign(Object.assign({succeeded:true},r),{_response:r._response})}catch(e){if(((a=e.details)===null||a===void 0?void 0:a.errorCode)==="BlobAlreadyExists"){i.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a blob only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(r=e.response)===null||r===void 0?void 0:r.parsedHeaders),{_response:e.response})}i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async uploadPages(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-uploadPages",r);try{ensureCpkIfSpecified(r.customerProvidedKey,this.isHttps);return await this.pageBlobContext.uploadPages(a,e,Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),requestOptions:{onUploadProgress:r.onProgress},range:rangeToString({offset:t,count:a}),sequenceNumberAccessConditions:r.conditions,transactionalContentMD5:r.transactionalContentMD5,transactionalContentCrc64:r.transactionalContentCrc64,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async uploadPagesFromURL(e,t,a,r,i={}){var s;i.conditions=i.conditions||{};i.sourceConditions=i.sourceConditions||{};const{span:o,updatedOptions:p}=Do("PageBlobClient-uploadPagesFromURL",i);try{ensureCpkIfSpecified(i.customerProvidedKey,this.isHttps);return await this.pageBlobContext.uploadPagesFromURL(e,rangeToString({offset:t,count:r}),0,rangeToString({offset:a,count:r}),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:httpAuthorizationToString(i.sourceAuthorization)},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async clearPages(e=0,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),range:rangeToString({offset:e,count:t}),sequenceNumberAccessConditions:a.conditions,cpkInfo:a.customerProvidedKey,encryptionScope:a.encryptionScope},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async getPageRanges(e=0,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions}),range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(s))).then(rangeResponseFromModel)}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async listPageRangesSegment(e=0,t,a,r={}){var i;const{span:s,updatedOptions:o}=Do("PageBlobClient-getPageRangesSegment",r);try{return await this.pageBlobContext.getPageRanges(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),range:rangeToString({offset:e,count:t}),marker:a,maxPageSize:r.maxPageSize},convertTracingToRequestOptionsBase(o)))}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}listPageRangeItemSegments(e=0,t,a,r={}){return i.__asyncGenerator(this,arguments,(function*listPageRangeItemSegments_1(){let n;if(!!a||a===undefined){do{n=yield i.__await(this.listPageRangesSegment(e,t,a,r));a=n.continuationToken;yield yield i.__await(yield i.__await(n))}while(a)}}))}listPageRangeItems(e=0,t,a={}){return i.__asyncGenerator(this,arguments,(function*listPageRangeItems_1(){var r,n;let s;try{for(var o=i.__asyncValues(this.listPageRangeItemSegments(e,t,s,a)),p;p=yield i.__await(o.next()),!p.done;){const e=p.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(ExtractPageRangeInfoItems(e))))}}catch(e){r={error:e}}finally{try{if(p&&!p.done&&(n=o.return))yield i.__await(n.call(o))}finally{if(r)throw r.error}}}))}listPageRanges(e=0,t,a={}){a.conditions=a.conditions||{};const r=this.listPageRangeItems(e,t,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(r={})=>this.listPageRangeItemSegments(e,t,r.continuationToken,Object.assign({maxPageSize:r.maxPageSize},a))}}async getPageRangesDiff(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-getPageRangesDiff",r);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),prevsnapshot:a,range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(o))).then(rangeResponseFromModel)}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async listPageRangesDiffSegment(e,t,a,r,i){var s;const{span:o,updatedOptions:p}=Do("PageBlobClient-getPageRangesDiffSegment",i);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:i===null||i===void 0?void 0:i.abortSignal,leaseAccessConditions:i===null||i===void 0?void 0:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i===null||i===void 0?void 0:i.conditions),{ifTags:(s=i===null||i===void 0?void 0:i.conditions)===null||s===void 0?void 0:s.tagConditions}),prevsnapshot:a,range:rangeToString({offset:e,count:t}),marker:r,maxPageSize:i===null||i===void 0?void 0:i.maxPageSize},convertTracingToRequestOptionsBase(p)))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}listPageRangeDiffItemSegments(e,t,a,r,n){return i.__asyncGenerator(this,arguments,(function*listPageRangeDiffItemSegments_1(){let s;if(!!r||r===undefined){do{s=yield i.__await(this.listPageRangesDiffSegment(e,t,a,r,n));r=s.continuationToken;yield yield i.__await(yield i.__await(s))}while(r)}}))}listPageRangeDiffItems(e,t,a,r){return i.__asyncGenerator(this,arguments,(function*listPageRangeDiffItems_1(){var n,s;let o;try{for(var p=i.__asyncValues(this.listPageRangeDiffItemSegments(e,t,a,o,r)),l;l=yield i.__await(p.next()),!l.done;){const e=l.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(ExtractPageRangeInfoItems(e))))}}catch(e){n={error:e}}finally{try{if(l&&!l.done&&(s=p.return))yield i.__await(s.call(p))}finally{if(n)throw n.error}}}))}listPageRangesDiff(e,t,a,r={}){r.conditions=r.conditions||{};const i=this.listPageRangeDiffItems(e,t,a,Object.assign({},r));return{next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(i={})=>this.listPageRangeDiffItemSegments(e,t,a,i.continuationToken,Object.assign({maxPageSize:i.maxPageSize},r))}}async getPageRangesDiffForManagedDisks(e,t,a,r={}){var i;r.conditions=r.conditions||{};const{span:s,updatedOptions:o}=Do("PageBlobClient-GetPageRangesDiffForManagedDisks",r);try{return await this.pageBlobContext.getPageRangesDiff(Object.assign({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(i=r.conditions)===null||i===void 0?void 0:i.tagConditions}),prevSnapshotUrl:a,range:rangeToString({offset:e,count:t})},convertTracingToRequestOptionsBase(o))).then(rangeResponseFromModel)}catch(e){s.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{s.end()}}async resize(e,t={}){var a;t.conditions=t.conditions||{};const{span:r,updatedOptions:i}=Do("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},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async updateSequenceNumber(e,t,a={}){var r;a.conditions=a.conditions||{};const{span:i,updatedOptions:s}=Do("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:(r=a.conditions)===null||r===void 0?void 0:r.tagConditions})},convertTracingToRequestOptionsBase(s)))}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async startCopyIncremental(e,t={}){var a;const{span:r,updatedOptions:i}=Do("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})},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}}async function getBodyAsText(e){let t=Buffer.alloc(fo);const a=await streamToBuffer2(e.readableStreamBody,t);t=t.slice(0,a);return t.toString()}function utf8ByteLength(e){return Buffer.byteLength(e)}const $o=": ";const Xo=" ";const Wo=-1;class BatchResponseParser{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}${ho}`;this.batchResponseEnding=`--${this.responseBatchBoundary}--`}async parseBatchResponse(){if(this.batchResponse._response.status!==oo.HTTP_ACCEPTED){throw new Error(`Invalid state: batch request failed with status: '${this.batchResponse._response.status}'.`)}const e=await getBodyAsText(this.batchResponse);const t=e.split(this.batchResponseEnding)[0].split(this.perResponsePrefix).slice(1);const 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.")}const i=new Array(a);let n=0;let s=0;for(let e=0;e=0&&m{if(this.keys[e]===undefined||this.keys[e]===Ko.UNLOCKED){this.keys[e]=Ko.LOCKED;t()}else{this.onUnlockEvent(e,(()=>{this.keys[e]=Ko.LOCKED;t()}))}}))}static async unlock(e){return new Promise((t=>{if(this.keys[e]===Ko.LOCKED){this.emitUnlockEvent(e)}delete this.keys[e];t()}))}static onUnlockEvent(e,t){if(this.listeners[e]===undefined){this.listeners[e]=[t]}else{this.listeners[e].push(t)}}static emitUnlockEvent(e){if(this.listeners[e]!==undefined&&this.listeners[e].length>0){const t=this.listeners[e].shift();setImmediate((()=>{t.call(this)}))}}}Mutex.keys={};Mutex.listeners={};class BlobBatch{constructor(){this.batch="batch";this.batchRequest=new InnerBatchRequest}getMultiPartContentType(){return this.batchRequest.getMultipartContentType()}getHttpRequestBody(){return this.batchRequest.getHttpRequestBody()}getSubRequests(){return this.batchRequest.getSubRequests()}async addSubRequestInternal(e,t){await Mutex.lock(this.batch);try{this.batchRequest.preAddSubRequest(e);await t();this.batchRequest.postAddSubRequest(e)}finally{await Mutex.unlock(this.batch)}}setBatchType(e){if(!this.batchType){this.batchType=e}if(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 i;let s;if(typeof e==="string"&&(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t))){i=e;s=t}else if(e instanceof BlobClient){i=e.url;s=e.credential;a=t}else{throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.")}if(!a){a={}}const{span:o,updatedOptions:p}=Do("BatchDeleteRequest-addSubRequest",a);try{this.setBatchType("delete");await this.addSubRequestInternal({url:i,credential:s},(async()=>{await new BlobClient(i,this.batchRequest.createPipeline(s)).delete(p)}))}catch(e){o.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{o.end()}}async setBlobAccessTier(e,t,a,i){let s;let o;let p;if(typeof e==="string"&&(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t))){s=e;o=t;p=a}else if(e instanceof BlobClient){s=e.url;o=e.credential;p=t;i=a}else{throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.")}if(!i){i={}}const{span:l,updatedOptions:d}=Do("BatchSetTierRequest-addSubRequest",i);try{this.setBatchType("setAccessTier");await this.addSubRequestInternal({url:s,credential:o},(async()=>{await new BlobClient(s,this.batchRequest.createPipeline(o)).setAccessTier(p,d)}))}catch(e){l.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{l.end()}}}class InnerBatchRequest{constructor(){this.operationCount=0;this.body="";const e=r.generateUuid();this.boundary=`batch_${e}`;this.subRequestPrefix=`--${this.boundary}${ho}${po.CONTENT_TYPE}: application/http${ho}${po.CONTENT_TRANSFER_ENCODING}: binary`;this.multipartContentType=`multipart/mixed; boundary=${this.boundary}`;this.batchRequestEnding=`--${this.boundary}--`;this.subRequests=new Map}createPipeline(e){const t=e instanceof AnonymousCredential;const a=3+(t?0:1);const i=new Array(a);i[0]=r.deserializationPolicy();i[1]=new BatchHeaderFilterPolicyFactory;if(!t){i[2]=r.isTokenCredential(e)?attachCredential(r.bearerTokenAuthenticationPolicy(e,no),e):e}i[a-1]=new BatchRequestAssemblePolicyFactory(this);return new Pipeline(i,{})}appendSubRequestToBody(e){this.body+=[this.subRequestPrefix,`${po.CONTENT_ID}: ${this.operationCount}`,"",`${e.method.toString()} ${getURLPathAndQuery(e.url)} ${go}${ho}`].join(ho);for(const t of e.headers.headersArray()){this.body+=`${t.name}: ${t.value}${ho}`}this.body+=ho}preAddSubRequest(e){if(this.operationCount>=uo){throw new RangeError(`Cannot exceed ${uo} sub requests in a single batch`)}const t=getURLPath(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}${ho}`}getMultipartContentType(){return this.multipartContentType}getSubRequests(){return this.subRequests}}class BatchRequestAssemblePolicy extends r.BaseRequestPolicy{constructor(e,t,a){super(t,a);this.dummyResponse={request:new r.WebResource,status:200,headers:new r.HttpHeaders};this.batchRequest=e}async sendRequest(e){await this.batchRequest.appendSubRequestToBody(e);return this.dummyResponse}}class BatchRequestAssemblePolicyFactory{constructor(e){this.batchRequest=e}create(e,t){return new BatchRequestAssemblePolicy(this.batchRequest,e,t)}}class BatchHeaderFilterPolicy extends r.BaseRequestPolicy{constructor(e,t){super(e,t)}async sendRequest(e){let t="";for(const a of e.headers.headersArray()){if(iEqual(a.name,po.X_MS_VERSION)){t=a.name}}if(t!==""){e.headers.remove(t)}return this._nextPolicy.sendRequest(e)}}class BatchHeaderFilterPolicyFactory{create(e,t){return new BatchHeaderFilterPolicy(e,t)}}class BlobBatchClient{constructor(e,t,a){let r;if(isPipelineLike(t)){r=t}else if(!t){r=newPipeline(new AnonymousCredential,a)}else{r=newPipeline(t,a)}const i=new StorageClientContext(e,r.toServiceClientOptions());const n=getURLPath(e);if(n&&n!=="/"){this.serviceOrContainerContext=new Container(i)}else{this.serviceOrContainerContext=new Service(i)}}createBatch(){return new BlobBatch}async deleteBlobs(e,t,a){const r=new BlobBatch;for(const i of e){if(typeof i==="string"){await r.deleteBlob(i,t,a)}else{await r.deleteBlob(i,t)}}return this.submitBatch(r)}async setBlobsAccessTier(e,t,a,r){const i=new BlobBatch;for(const n of e){if(typeof n==="string"){await i.setBlobAccessTier(n,t,a,r)}else{await i.setBlobAccessTier(n,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.")}const{span:a,updatedOptions:r}=Do("BlobBatchClient-submitBatch",t);try{const i=e.getHttpRequestBody();const n=await this.serviceOrContainerContext.submitBatch(utf8ByteLength(i),e.getMultiPartContentType(),i,Object.assign(Object.assign({},t),convertTracingToRequestOptionsBase(r)));const s=new BatchResponseParser(n,e.getSubRequests());const o=await s.parseBatchResponse();const p={_response:n._response,contentType:n.contentType,errorCode:n.errorCode,requestId:n.requestId,clientRequestId:n.clientRequestId,version:n.version,subResponses:o.subResponses,subResponsesSucceededCount:o.subResponsesSucceededCount,subResponsesFailedCount:o.subResponsesFailedCount};return p}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}}class ContainerClient extends StorageClient{constructor(e,t,a){let i;let n;a=a||{};if(isPipelineLike(t)){n=e;i=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){n=e;i=newPipeline(t,a)}else if(!t&&typeof t!=="string"){n=e;i=newPipeline(new AnonymousCredential,a)}else if(t&&typeof t==="string"){const s=t;const o=extractConnectionStringParts(e);if(o.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(o.accountName,o.accountKey);n=appendToURLPath(o.url,encodeURIComponent(s));if(!a.proxyOptions){a.proxyOptions=r.getDefaultProxySettings(o.proxyUri)}i=newPipeline(e,a)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(o.kind==="SASConnString"){n=appendToURLPath(o.url,encodeURIComponent(s))+"?"+o.accountSas;i=newPipeline(new AnonymousCredential,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(n,i);this._containerName=this.getContainerNameFromUrl();this.containerContext=new Container(this.storageClientContext)}get containerName(){return this._containerName}async create(e={}){const{span:t,updatedOptions:a}=Do("ContainerClient-create",e);try{return await this.containerContext.create(Object.assign(Object.assign({},e),convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async createIfNotExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("ContainerClient-createIfNotExists",e);try{const e=await this.create(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="ContainerAlreadyExists"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when creating a container only if it does not already exist."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async exists(e={}){const{span:t,updatedOptions:a}=Do("ContainerClient-exists",e);try{await this.getProperties({abortSignal:e.abortSignal,tracingOptions:a.tracingOptions});return true}catch(e){if(e.statusCode===404){t.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when checking container existence"});return false}t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}getBlobClient(e){return new BlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getAppendBlobClient(e){return new AppendBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getBlockBlobClient(e){return new BlockBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}getPageBlobClient(e){return new PageBlobClient(appendToURLPath(this.url,EscapePath(e)),this.pipeline)}async getProperties(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-getProperties",e);try{return await this.containerContext.getProperties(Object.assign(Object.assign({abortSignal:e.abortSignal},e.conditions),convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async delete(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-delete",e);try{return await this.containerContext.delete(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:e.conditions},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async deleteIfExists(e={}){var t,a;const{span:r,updatedOptions:i}=Do("ContainerClient-deleteIfExists",e);try{const e=await this.delete(i);return Object.assign(Object.assign({succeeded:true},e),{_response:e._response})}catch(e){if(((t=e.details)===null||t===void 0?void 0:t.errorCode)==="ContainerNotFound"){r.setStatus({code:n.SpanStatusCode.ERROR,message:"Expected exception when deleting a container only if it exists."});return Object.assign(Object.assign({succeeded:false},(a=e.response)===null||a===void 0?void 0:a.parsedHeaders),{_response:e.response})}r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async setMetadata(e,t={}){if(!t.conditions){t.conditions={}}if(t.conditions.ifUnmodifiedSince){throw new RangeError("the IfUnmodifiedSince must have their default values because they are ignored by the blob service")}const{span:a,updatedOptions:r}=Do("ContainerClient-setMetadata",t);try{return await this.containerContext.setMetadata(Object.assign({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:e,modifiedAccessConditions:t.conditions},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async getAccessPolicy(e={}){if(!e.conditions){e.conditions={}}const{span:t,updatedOptions:a}=Do("ContainerClient-getAccessPolicy",e);try{const r=await this.containerContext.getAccessPolicy(Object.assign({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions},convertTracingToRequestOptionsBase(a)));const i={_response:r._response,blobPublicAccess:r.blobPublicAccess,date:r.date,etag:r.etag,errorCode:r.errorCode,lastModified:r.lastModified,requestId:r.requestId,clientRequestId:r.clientRequestId,signedIdentifiers:[],version:r.version};for(const e of r){let t=undefined;if(e.accessPolicy){t={permissions:e.accessPolicy.permissions};if(e.accessPolicy.expiresOn){t.expiresOn=new Date(e.accessPolicy.expiresOn)}if(e.accessPolicy.startsOn){t.startsOn=new Date(e.accessPolicy.startsOn)}}i.signedIdentifiers.push({accessPolicy:t,id:e.id})}return i}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setAccessPolicy(e,t,a={}){a.conditions=a.conditions||{};const{span:r,updatedOptions:i}=Do("ContainerClient-setAccessPolicy",a);try{const n=[];for(const e of t||[]){n.push({accessPolicy:{expiresOn:e.accessPolicy.expiresOn?truncatedISO8061Date(e.accessPolicy.expiresOn):"",permissions:e.accessPolicy.permissions,startsOn:e.accessPolicy.startsOn?truncatedISO8061Date(e.accessPolicy.startsOn):""},id:e.id})}return await this.containerContext.setAccessPolicy(Object.assign({abortSignal:a.abortSignal,access:e,containerAcl:n,leaseAccessConditions:a.conditions,modifiedAccessConditions:a.conditions},convertTracingToRequestOptionsBase(i)))}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}getBlobLeaseClient(e){return new BlobLeaseClient(this,e)}async uploadBlockBlob(e,t,a,r={}){const{span:i,updatedOptions:s}=Do("ContainerClient-uploadBlockBlob",r);try{const r=this.getBlockBlobClient(e);const n=await r.upload(t,a,s);return{blockBlobClient:r,response:n}}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async deleteBlob(e,t={}){const{span:a,updatedOptions:r}=Do("ContainerClient-deleteBlob",t);try{let i=this.getBlobClient(e);if(t.versionId){i=i.withVersion(t.versionId)}return await i.delete(r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async listBlobFlatSegment(e,t={}){const{span:a,updatedOptions:r}=Do("ContainerClient-listBlobFlatSegment",t);try{const i=await this.containerContext.listBlobFlatSegment(Object.assign(Object.assign({marker:e},t),convertTracingToRequestOptionsBase(r)));const n=Object.assign(Object.assign({},i),{_response:Object.assign(Object.assign({},i._response),{parsedBody:ConvertInternalResponseOfListBlobFlat(i._response.parsedBody)}),segment:Object.assign(Object.assign({},i.segment),{blobItems:i.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name),tags:toTags(e.blobTags),objectReplicationSourceProperties:parseObjectReplicationRecord(e.objectReplicationMetadata)});return t}))})});return n}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async listBlobHierarchySegment(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("ContainerClient-listBlobHierarchySegment",a);try{const n=await this.containerContext.listBlobHierarchySegment(e,Object.assign(Object.assign({marker:t},a),convertTracingToRequestOptionsBase(s)));const o=Object.assign(Object.assign({},n),{_response:Object.assign(Object.assign({},n._response),{parsedBody:ConvertInternalResponseOfListBlobHierarchy(n._response.parsedBody)}),segment:Object.assign(Object.assign({},n.segment),{blobItems:n.segment.blobItems.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name),tags:toTags(e.blobTags),objectReplicationSourceProperties:parseObjectReplicationRecord(e.objectReplicationMetadata)});return t})),blobPrefixes:(r=n.segment.blobPrefixes)===null||r===void 0?void 0:r.map((e=>{const t=Object.assign(Object.assign({},e),{name:BlobNameToString(e.name)});return t}))})});return o}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}listSegments(e,t={}){return i.__asyncGenerator(this,arguments,(function*listSegments_1(){let a;if(!!e||e===undefined){do{a=yield i.__await(this.listBlobFlatSegment(e,t));e=a.continuationToken;yield yield i.__await(yield i.__await(a))}while(e)}}))}listItems(e={}){return i.__asyncGenerator(this,arguments,(function*listItems_1(){var t,a;let r;try{for(var n=i.__asyncValues(this.listSegments(r,e)),s;s=yield i.__await(n.next()),!s.done;){const e=s.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.segment.blobItems)))}}catch(e){t={error:e}}finally{try{if(s&&!s.done&&(a=n.return))yield i.__await(a.call(n))}finally{if(t)throw t.error}}}))}listBlobsFlat(e={}){const t=[];if(e.includeCopy){t.push("copy")}if(e.includeDeleted){t.push("deleted")}if(e.includeMetadata){t.push("metadata")}if(e.includeSnapshots){t.push("snapshots")}if(e.includeVersions){t.push("versions")}if(e.includeUncommitedBlobs){t.push("uncommittedblobs")}if(e.includeTags){t.push("tags")}if(e.includeDeletedWithVersions){t.push("deletedwithversions")}if(e.includeImmutabilityPolicy){t.push("immutabilitypolicy")}if(e.includeLegalHold){t.push("legalhold")}if(e.prefix===""){e.prefix=undefined}const a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{});const r=this.listItems(a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(e={})=>this.listSegments(e.continuationToken,Object.assign({maxPageSize:e.maxPageSize},a))}}listHierarchySegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*listHierarchySegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.listBlobHierarchySegment(e,t,a));t=r.continuationToken;yield yield i.__await(yield i.__await(r))}while(t)}}))}listItemsByHierarchy(e,t={}){return i.__asyncGenerator(this,arguments,(function*listItemsByHierarchy_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.listHierarchySegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;const t=e.segment;if(t.blobPrefixes){for(const e of t.blobPrefixes){yield yield i.__await(Object.assign({kind:"prefix"},e))}}for(const e of t.blobItems){yield yield i.__await(Object.assign({kind:"blob"},e))}}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}listBlobsByHierarchy(e,t={}){if(e===""){throw new RangeError("delimiter should contain one or more characters")}const a=[];if(t.includeCopy){a.push("copy")}if(t.includeDeleted){a.push("deleted")}if(t.includeMetadata){a.push("metadata")}if(t.includeSnapshots){a.push("snapshots")}if(t.includeVersions){a.push("versions")}if(t.includeUncommitedBlobs){a.push("uncommittedblobs")}if(t.includeTags){a.push("tags")}if(t.includeDeletedWithVersions){a.push("deletedwithversions")}if(t.includeImmutabilityPolicy){a.push("immutabilitypolicy")}if(t.includeLegalHold){a.push("legalhold")}if(t.prefix===""){t.prefix=undefined}const r=Object.assign(Object.assign({},t),a.length>0?{include:a}:{});const i=this.listItemsByHierarchy(e,r);return{async next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.listHierarchySegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},r))}}async findBlobsByTagsSegment(e,t,a={}){const{span:r,updatedOptions:i}=Do("ContainerClient-findBlobsByTagsSegment",a);try{const n=await this.containerContext.filterBlobs(Object.assign({abortSignal:a.abortSignal,where:e,marker:t,maxPageSize:a.maxPageSize},convertTracingToRequestOptionsBase(i)));const s=Object.assign(Object.assign({},n),{_response:n._response,blobs:n.blobs.map((e=>{var t;let a="";if(((t=e.tags)===null||t===void 0?void 0:t.blobTagSet.length)===1){a=e.tags.blobTagSet[0].value}return Object.assign(Object.assign({},e),{tags:toTags(e.tags),tagValue:a})}))});return s}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}findBlobsByTagsSegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsSegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.findBlobsByTagsSegment(e,t,a));r.blobs=r.blobs||[];t=r.continuationToken;yield yield i.__await(r)}while(t)}}))}findBlobsByTagsItems(e,t={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsItems_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.findBlobsByTagsSegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.blobs)))}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}findBlobsByTags(e,t={}){const a=Object.assign({},t);const r=this.findBlobsByTagsItems(e,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.findBlobsByTagsSegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},a))}}getContainerNameFromUrl(){let e;try{const t=r.URLBuilder.parse(this.url);if(t.getHost().split(".")[1]==="blob"){e=t.getPath().split("/")[1]}else if(isIpEndpointStyle(t)){e=t.getPath().split("/")[2]}else{e=t.getPath().split("/")[1]}e=decodeURIComponent(e);if(!e){throw new Error("Provided containerName is invalid.")}return e}catch(e){throw new Error("Unable to extract containerName with provided information.")}}generateSasUrl(e){return new Promise((t=>{if(!(this.credential instanceof StorageSharedKeyCredential)){throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential")}const a=generateBlobSASQueryParameters(Object.assign({containerName:this._containerName},e),this.credential).toString();t(appendToURLQuery(this.url,a))}))}getBlobBatchClient(){return new BlobBatchClient(this.url,this.pipeline)}}class AccountSASPermissions{constructor(){this.read=false;this.write=false;this.delete=false;this.deleteVersion=false;this.list=false;this.add=false;this.create=false;this.update=false;this.process=false;this.tag=false;this.filter=false;this.setImmutabilityPolicy=false;this.permanentDelete=false}static parse(e){const t=new AccountSASPermissions;for(const a of e){switch(a){case"r":t.read=true;break;case"w":t.write=true;break;case"d":t.delete=true;break;case"x":t.deleteVersion=true;break;case"l":t.list=true;break;case"a":t.add=true;break;case"c":t.create=true;break;case"u":t.update=true;break;case"p":t.process=true;break;case"t":t.tag=true;break;case"f":t.filter=true;break;case"i":t.setImmutabilityPolicy=true;break;case"y":t.permanentDelete=true;break;default:throw new RangeError(`Invalid permission character: ${a}`)}}return t}static from(e){const t=new AccountSASPermissions;if(e.read){t.read=true}if(e.write){t.write=true}if(e.delete){t.delete=true}if(e.deleteVersion){t.deleteVersion=true}if(e.filter){t.filter=true}if(e.tag){t.tag=true}if(e.list){t.list=true}if(e.add){t.add=true}if(e.create){t.create=true}if(e.update){t.update=true}if(e.process){t.process=true}if(e.setImmutabilityPolicy){t.setImmutabilityPolicy=true}if(e.permanentDelete){t.permanentDelete=true}return t}toString(){const e=[];if(this.read){e.push("r")}if(this.write){e.push("w")}if(this.delete){e.push("d")}if(this.deleteVersion){e.push("x")}if(this.filter){e.push("f")}if(this.tag){e.push("t")}if(this.list){e.push("l")}if(this.add){e.push("a")}if(this.create){e.push("c")}if(this.update){e.push("u")}if(this.process){e.push("p")}if(this.setImmutabilityPolicy){e.push("i")}if(this.permanentDelete){e.push("y")}return e.join("")}}class AccountSASResourceTypes{constructor(){this.service=false;this.container=false;this.object=false}static parse(e){const t=new AccountSASResourceTypes;for(const a of e){switch(a){case"s":t.service=true;break;case"c":t.container=true;break;case"o":t.object=true;break;default:throw new RangeError(`Invalid resource type: ${a}`)}}return t}toString(){const e=[];if(this.service){e.push("s")}if(this.container){e.push("c")}if(this.object){e.push("o")}return e.join("")}}class AccountSASServices{constructor(){this.blob=false;this.file=false;this.queue=false;this.table=false}static parse(e){const t=new AccountSASServices;for(const a of e){switch(a){case"b":t.blob=true;break;case"f":t.file=true;break;case"q":t.queue=true;break;case"t":t.table=true;break;default:throw new RangeError(`Invalid service character: ${a}`)}}return t}toString(){const e=[];if(this.blob){e.push("b")}if(this.table){e.push("t")}if(this.queue){e.push("q")}if(this.file){e.push("f")}return e.join("")}}function generateAccountSASQueryParameters(e,t){const a=e.version?e.version:Ys;if(e.permissions&&e.permissions.setImmutabilityPolicy&&a<"2020-08-04"){throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.")}if(e.permissions&&e.permissions.deleteVersion&&a<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when provided 'x' permission.")}if(e.permissions&&e.permissions.permanentDelete&&a<"2019-10-10"){throw RangeError("'version' must be >= '2019-10-10' when provided 'y' permission.")}if(e.permissions&&e.permissions.tag&&a<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when provided 't' permission.")}if(e.permissions&&e.permissions.filter&&a<"2019-12-12"){throw RangeError("'version' must be >= '2019-12-12' when provided 'f' permission.")}if(e.encryptionScope&&a<"2020-12-06"){throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.")}const r=AccountSASPermissions.parse(e.permissions.toString());const i=AccountSASServices.parse(e.services).toString();const n=AccountSASResourceTypes.parse(e.resourceTypes).toString();let s;if(a>="2020-12-06"){s=[t.accountName,r,i,n,e.startsOn?truncatedISO8061Date(e.startsOn,false):"",truncatedISO8061Date(e.expiresOn,false),e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",a,e.encryptionScope?e.encryptionScope:"",""].join("\n")}else{s=[t.accountName,r,i,n,e.startsOn?truncatedISO8061Date(e.startsOn,false):"",truncatedISO8061Date(e.expiresOn,false),e.ipRange?ipRangeToString(e.ipRange):"",e.protocol?e.protocol:"",a,""].join("\n")}const o=t.computeHMACSHA256(s);return new SASQueryParameters(a,o,r.toString(),i,n,e.protocol,e.startsOn,e.expiresOn,e.ipRange,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,undefined,e.encryptionScope)}class BlobServiceClient extends StorageClient{constructor(e,t,a){let i;if(isPipelineLike(t)){i=t}else if(r.isNode&&t instanceof StorageSharedKeyCredential||t instanceof AnonymousCredential||r.isTokenCredential(t)){i=newPipeline(t,a)}else{i=newPipeline(new AnonymousCredential,a)}super(e,i);this.serviceContext=new Service(this.storageClientContext)}static fromConnectionString(e,t){t=t||{};const a=extractConnectionStringParts(e);if(a.kind==="AccountConnString"){if(r.isNode){const e=new StorageSharedKeyCredential(a.accountName,a.accountKey);if(!t.proxyOptions){t.proxyOptions=r.getDefaultProxySettings(a.proxyUri)}const i=newPipeline(e,t);return new BlobServiceClient(a.url,i)}else{throw new Error("Account connection string is only supported in Node.js environment")}}else if(a.kind==="SASConnString"){const e=newPipeline(new AnonymousCredential,t);return new BlobServiceClient(a.url+"?"+a.accountSas,e)}else{throw new Error("Connection string must be either an Account connection string or a SAS connection string")}}getContainerClient(e){return new ContainerClient(appendToURLPath(this.url,encodeURIComponent(e)),this.pipeline)}async createContainer(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-createContainer",t);try{const t=this.getContainerClient(e);const i=await t.create(r);return{containerClient:t,containerCreateResponse:i}}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async deleteContainer(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-deleteContainer",t);try{const t=this.getContainerClient(e);return await t.delete(r)}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async undeleteContainer(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-undeleteContainer",a);try{const n=this.getContainerClient(a.destinationContainerName||e);const s=new Container(n["storageClientContext"]);const o=await s.restore(Object.assign({deletedContainerName:e,deletedContainerVersion:t},i));return{containerClient:n,containerUndeleteResponse:o}}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}async renameContainer(e,t,a={}){var r;const{span:i,updatedOptions:s}=Do("BlobServiceClient-renameContainer",a);try{const n=this.getContainerClient(t);const o=new Container(n["storageClientContext"]);const p=await o.rename(e,Object.assign(Object.assign({},s),{sourceLeaseId:(r=a.sourceCondition)===null||r===void 0?void 0:r.leaseId}));return{containerClient:n,containerRenameResponse:p}}catch(e){i.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{i.end()}}async getProperties(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getProperties",e);try{return await this.serviceContext.getProperties(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async setProperties(e,t={}){const{span:a,updatedOptions:r}=Do("BlobServiceClient-setProperties",t);try{return await this.serviceContext.setProperties(e,Object.assign({abortSignal:t.abortSignal},convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async getStatistics(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getStatistics",e);try{return await this.serviceContext.getStatistics(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async getAccountInfo(e={}){const{span:t,updatedOptions:a}=Do("BlobServiceClient-getAccountInfo",e);try{return await this.serviceContext.getAccountInfo(Object.assign({abortSignal:e.abortSignal},convertTracingToRequestOptionsBase(a)))}catch(e){t.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{t.end()}}async listContainersSegment(e,t={}){const{span:a,updatedOptions:r}=Do("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}),convertTracingToRequestOptionsBase(r)))}catch(e){a.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{a.end()}}async findBlobsByTagsSegment(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-findBlobsByTagsSegment",a);try{const n=await this.serviceContext.filterBlobs(Object.assign({abortSignal:a.abortSignal,where:e,marker:t,maxPageSize:a.maxPageSize},convertTracingToRequestOptionsBase(i)));const s=Object.assign(Object.assign({},n),{_response:n._response,blobs:n.blobs.map((e=>{var t;let a="";if(((t=e.tags)===null||t===void 0?void 0:t.blobTagSet.length)===1){a=e.tags.blobTagSet[0].value}return Object.assign(Object.assign({},e),{tags:toTags(e.tags),tagValue:a})}))});return s}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}findBlobsByTagsSegments(e,t,a={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsSegments_1(){let r;if(!!t||t===undefined){do{r=yield i.__await(this.findBlobsByTagsSegment(e,t,a));r.blobs=r.blobs||[];t=r.continuationToken;yield yield i.__await(r)}while(t)}}))}findBlobsByTagsItems(e,t={}){return i.__asyncGenerator(this,arguments,(function*findBlobsByTagsItems_1(){var a,r;let n;try{for(var s=i.__asyncValues(this.findBlobsByTagsSegments(e,n,t)),o;o=yield i.__await(s.next()),!o.done;){const e=o.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.blobs)))}}catch(e){a={error:e}}finally{try{if(o&&!o.done&&(r=s.return))yield i.__await(r.call(s))}finally{if(a)throw a.error}}}))}findBlobsByTags(e,t={}){const a=Object.assign({},t);const r=this.findBlobsByTagsItems(e,a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(t={})=>this.findBlobsByTagsSegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},a))}}listSegments(e,t={}){return i.__asyncGenerator(this,arguments,(function*listSegments_1(){let a;if(!!e||e===undefined){do{a=yield i.__await(this.listContainersSegment(e,t));a.containerItems=a.containerItems||[];e=a.continuationToken;yield yield i.__await(yield i.__await(a))}while(e)}}))}listItems(e={}){return i.__asyncGenerator(this,arguments,(function*listItems_1(){var t,a;let r;try{for(var n=i.__asyncValues(this.listSegments(r,e)),s;s=yield i.__await(n.next()),!s.done;){const e=s.value;yield i.__await(yield*i.__asyncDelegator(i.__asyncValues(e.containerItems)))}}catch(e){t={error:e}}finally{try{if(s&&!s.done&&(a=n.return))yield i.__await(a.call(n))}finally{if(t)throw t.error}}}))}listContainers(e={}){if(e.prefix===""){e.prefix=undefined}const t=[];if(e.includeDeleted){t.push("deleted")}if(e.includeMetadata){t.push("metadata")}if(e.includeSystem){t.push("system")}const a=Object.assign(Object.assign({},e),t.length>0?{include:t}:{});const r=this.listItems(a);return{next(){return r.next()},[Symbol.asyncIterator](){return this},byPage:(e={})=>this.listSegments(e.continuationToken,Object.assign({maxPageSize:e.maxPageSize},a))}}async getUserDelegationKey(e,t,a={}){const{span:r,updatedOptions:i}=Do("BlobServiceClient-getUserDelegationKey",a);try{const n=await this.serviceContext.getUserDelegationKey({startsOn:truncatedISO8061Date(e,false),expiresOn:truncatedISO8061Date(t,false)},Object.assign({abortSignal:a.abortSignal},convertTracingToRequestOptionsBase(i)));const s={signedObjectId:n.signedObjectId,signedTenantId:n.signedTenantId,signedStartsOn:new Date(n.signedStartsOn),signedExpiresOn:new Date(n.signedExpiresOn),signedService:n.signedService,signedVersion:n.signedVersion,value:n.value};const o=Object.assign({_response:n._response,requestId:n.requestId,clientRequestId:n.clientRequestId,version:n.version,date:n.date,errorCode:n.errorCode},s);return o}catch(e){r.setStatus({code:n.SpanStatusCode.ERROR,message:e.message});throw e}finally{r.end()}}getBlobBatchClient(){return new BlobBatchClient(this.url,this.pipeline)}generateAccountSasUrl(e,t=AccountSASPermissions.parse("r"),a="sco",r={}){if(!(this.credential instanceof StorageSharedKeyCredential)){throw RangeError("Can only generate the account SAS when the client is initialized with a shared key credential")}if(e===undefined){const t=new Date;e=new Date(t.getTime()+3600*1e3)}const i=generateAccountSASQueryParameters(Object.assign({permissions:t,expiresOn:e,resourceTypes:a,services:AccountSASServices.parse("b").toString()},r),this.credential).toString();return appendToURLQuery(this.url,i)}}t.KnownEncryptionAlgorithmType=void 0;(function(e){e["AES256"]="AES256"})(t.KnownEncryptionAlgorithmType||(t.KnownEncryptionAlgorithmType={}));Object.defineProperty(t,"BaseRequestPolicy",{enumerable:true,get:function(){return r.BaseRequestPolicy}});Object.defineProperty(t,"HttpHeaders",{enumerable:true,get:function(){return r.HttpHeaders}});Object.defineProperty(t,"RequestPolicyOptions",{enumerable:true,get:function(){return r.RequestPolicyOptions}});Object.defineProperty(t,"RestError",{enumerable:true,get:function(){return r.RestError}});Object.defineProperty(t,"WebResource",{enumerable:true,get:function(){return r.WebResource}});Object.defineProperty(t,"deserializationPolicy",{enumerable:true,get:function(){return r.deserializationPolicy}});t.AccountSASPermissions=AccountSASPermissions;t.AccountSASResourceTypes=AccountSASResourceTypes;t.AccountSASServices=AccountSASServices;t.AnonymousCredential=AnonymousCredential;t.AnonymousCredentialPolicy=AnonymousCredentialPolicy;t.AppendBlobClient=AppendBlobClient;t.BlobBatch=BlobBatch;t.BlobBatchClient=BlobBatchClient;t.BlobClient=BlobClient;t.BlobLeaseClient=BlobLeaseClient;t.BlobSASPermissions=BlobSASPermissions;t.BlobServiceClient=BlobServiceClient;t.BlockBlobClient=BlockBlobClient;t.ContainerClient=ContainerClient;t.ContainerSASPermissions=ContainerSASPermissions;t.Credential=Credential;t.CredentialPolicy=CredentialPolicy;t.PageBlobClient=PageBlobClient;t.Pipeline=Pipeline;t.SASQueryParameters=SASQueryParameters;t.StorageBrowserPolicy=StorageBrowserPolicy;t.StorageBrowserPolicyFactory=StorageBrowserPolicyFactory;t.StorageOAuthScopes=no;t.StorageRetryPolicy=StorageRetryPolicy;t.StorageRetryPolicyFactory=StorageRetryPolicyFactory;t.StorageSharedKeyCredential=StorageSharedKeyCredential;t.StorageSharedKeyCredentialPolicy=StorageSharedKeyCredentialPolicy;t.generateAccountSASQueryParameters=generateAccountSASQueryParameters;t.generateBlobSASQueryParameters=generateBlobSASQueryParameters;t.isPipelineLike=isPipelineLike;t.logger=Ks;t.newPipeline=newPipeline},679:e=>{var t;var a;var r;var i;var n;var s;var o;var p;var l;var d;var c;var m;var u;var h;var g;var y;var v;var b;var x;var w;var S;var N;var T;var E;var _;var P;var C;var O;var R;var D;var A;(function(t){var a=typeof global==="object"?global:typeof self==="object"?self:typeof this==="object"?this:{};if(typeof define==="function"&&define.amd){define("tslib",["exports"],(function(e){t(createExporter(a,createExporter(e)))}))}else if(true&&typeof e.exports==="object"){t(createExporter(a,createExporter(e.exports)))}else{t(createExporter(a))}function createExporter(e,t){if(e!==a){if(typeof Object.create==="function"){Object.defineProperty(e,"__esModule",{value:true})}else{e.__esModule=true}}return function(a,r){return e[a]=t?t(a,r):r}}})((function(e){var I=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a))e[a]=t[a]};t=function(e,t){if(typeof t!=="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");I(e,t);function __(){this.constructor=e}e.prototype=t===null?Object.create(t):(__.prototype=t.prototype,new __)};a=Object.assign||function(e){for(var t,a=1,r=arguments.length;a=0;o--)if(s=e[o])n=(i<3?s(n):i>3?s(t,a,n):s(t,a))||n;return i>3&&n&&Object.defineProperty(t,a,n),n};n=function(e,t){return function(a,r){t(a,r,e)}};s=function(e,t,a,r,i,n){function accept(e){if(e!==void 0&&typeof e!=="function")throw new TypeError("Function expected");return e}var s=r.kind,o=s==="getter"?"get":s==="setter"?"set":"value";var p=!t&&e?r["static"]?e:e.prototype:null;var l=t||(p?Object.getOwnPropertyDescriptor(p,r.name):{});var d,c=false;for(var m=a.length-1;m>=0;m--){var u={};for(var h in r)u[h]=h==="access"?{}:r[h];for(var h in r.access)u.access[h]=r.access[h];u.addInitializer=function(e){if(c)throw new TypeError("Cannot add initializers after decoration has completed");n.push(accept(e||null))};var g=(0,a[m])(s==="accessor"?{get:l.get,set:l.set}:l[o],u);if(s==="accessor"){if(g===void 0)continue;if(g===null||typeof g!=="object")throw new TypeError("Object expected");if(d=accept(g.get))l.get=d;if(d=accept(g.set))l.set=d;if(d=accept(g.init))i.unshift(d)}else if(d=accept(g)){if(s==="field")i.unshift(d);else l[o]=d}}if(p)Object.defineProperty(p,r.name,l);c=true};o=function(e,t,a){var r=arguments.length>2;for(var i=0;i0&&n[n.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!n||o[1]>n[0]&&o[1]=e.length)e=void 0;return{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};g=function(e,t){var a=typeof Symbol==="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],s;try{while((t===void 0||t-- >0)&&!(i=r.next()).done)n.push(i.value)}catch(e){s={error:e}}finally{try{if(i&&!i.done&&(a=r["return"]))a.call(r)}finally{if(s)throw s.error}}return n};y=function(){for(var e=[],t=0;t1||resume(e,t)}))}}function resume(e,t){try{step(r[e](t))}catch(e){settle(n[0][3],e)}}function step(e){e.value instanceof x?Promise.resolve(e.value.v).then(fulfill,reject):settle(n[0][2],e)}function fulfill(e){resume("next",e)}function reject(e){resume("throw",e)}function settle(e,t){if(e(t),n.shift(),n.length)resume(n[0][0],n[0][1])}};S=function(e){var t,a;return t={},verb("next"),verb("throw",(function(e){throw e})),verb("return"),t[Symbol.iterator]=function(){return this},t;function verb(r,i){t[r]=e[r]?function(t){return(a=!a)?{value:x(e[r](t)),done:false}:i?i(t):t}:i}};N=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],a;return t?t.call(e):(e=typeof h==="function"?h(e):e[Symbol.iterator](),a={},verb("next"),verb("throw"),verb("return"),a[Symbol.asyncIterator]=function(){return this},a);function verb(t){a[t]=e[t]&&function(a){return new Promise((function(r,i){a=e[t](a),settle(r,i,a.done,a.value)}))}}function settle(e,t,a,r){Promise.resolve(r).then((function(t){e({value:t,done:a})}),t)}};T=function(e,t){if(Object.defineProperty){Object.defineProperty(e,"raw",{value:t})}else{e.raw=t}return e};var L=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t};E=function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var a in e)if(a!=="default"&&Object.prototype.hasOwnProperty.call(e,a))R(t,e,a);L(t,e);return t};_=function(e){return e&&e.__esModule?e:{default:e}};P=function(e,t,a,r){if(a==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?r:a==="a"?r.call(e):r?r.value:t.get(e)};C=function(e,t,a,r,i){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?i.call(e,a):i?i.value=a:t.set(e,a),a};O=function(e,t){if(t===null||typeof t!=="object"&&typeof t!=="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e==="function"?t===e:e.has(t)};D=function(e,t,a){if(t!==null&&t!==void 0){if(typeof t!=="object"&&typeof t!=="function")throw new TypeError("Object expected.");var r;if(a){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose]}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose]}if(typeof r!=="function")throw new TypeError("Object not disposable.");e.stack.push({value:t,dispose:r,async:a})}else if(a){e.stack.push({async:true})}return t};var M=typeof SuppressedError==="function"?SuppressedError:function(e,t,a){var r=new Error(a);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};A=function(e){function fail(t){e.error=e.hasError?new M(t,e.error,"An error was suppressed during disposal."):t;e.hasError=true}function next(){while(e.stack.length){var t=e.stack.pop();try{var a=t.dispose&&t.dispose.call(t.value);if(t.async)return Promise.resolve(a).then(next,(function(e){fail(e);return next()}))}catch(e){fail(e)}}if(e.hasError)throw e.error}return next()};e("__extends",t);e("__assign",a);e("__rest",r);e("__decorate",i);e("__param",n);e("__esDecorate",s);e("__runInitializers",o);e("__propKey",p);e("__setFunctionName",l);e("__metadata",d);e("__awaiter",c);e("__generator",m);e("__exportStar",u);e("__createBinding",R);e("__values",h);e("__read",g);e("__spread",y);e("__spreadArrays",v);e("__spreadArray",b);e("__await",x);e("__asyncGenerator",w);e("__asyncDelegator",S);e("__asyncValues",N);e("__makeTemplateObject",T);e("__importStar",E);e("__importDefault",_);e("__classPrivateFieldGet",P);e("__classPrivateFieldSet",C);e("__classPrivateFieldIn",O);e("__addDisposableResource",D);e("__disposeResources",A)}))},334:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a=/^v1\./;const r=/^ghs_/;const i=/^ghu_/;async function auth(e){const t=e.split(/\./).length===3;const n=a.test(e)||r.test(e);const s=i.test(e);const o=t?"app":n?"installation":s?"user-to-server":"oauth";return{type:"token",token:e,tokenType:o}}function withAuthorizationPrefix(e){if(e.split(/\./).length===3){return`bearer ${e}`}return`token ${e}`}async function hook(e,t,a,r){const i=t.endpoint.merge(a,r);i.headers.authorization=withAuthorizationPrefix(e);return t(i)}const n=function createTokenAuth(e){if(!e){throw new Error("[@octokit/auth-token] No token passed to createTokenAuth")}if(typeof e!=="string"){throw new Error("[@octokit/auth-token] Token passed to createTokenAuth is not a string")}e=e.replace(/^(token|bearer) +/i,"");return Object.assign(auth.bind(null,e),{hook:hook.bind(null,e)})};t.createTokenAuth=n},6762:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(5030);var i=a(3682);var n=a(6234);var s=a(8467);var o=a(334);function _objectWithoutPropertiesLoose(e,t){if(e==null)return{};var a={};var r=Object.keys(e);var i,n;for(n=0;n=0)continue;a[i]=e[i]}return a}function _objectWithoutProperties(e,t){if(e==null)return{};var a=_objectWithoutPropertiesLoose(e,t);var r,i;if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);for(i=0;i=0)continue;if(!Object.prototype.propertyIsEnumerable.call(e,r))continue;a[r]=e[r]}}return a}const p="3.6.0";const l=["authStrategy"];class Octokit{constructor(e={}){const t=new i.Collection;const a={baseUrl:n.request.endpoint.DEFAULTS.baseUrl,headers:{},request:Object.assign({},e.request,{hook:t.bind(null,"request")}),mediaType:{previews:[],format:""}};a.headers["user-agent"]=[e.userAgent,`octokit-core.js/${p} ${r.getUserAgent()}`].filter(Boolean).join(" ");if(e.baseUrl){a.baseUrl=e.baseUrl}if(e.previews){a.mediaType.previews=e.previews}if(e.timeZone){a.headers["time-zone"]=e.timeZone}this.request=n.request.defaults(a);this.graphql=s.withCustomRequest(this.request).defaults(a);this.log=Object.assign({debug:()=>{},info:()=>{},warn:console.warn.bind(console),error:console.error.bind(console)},e.log);this.hook=t;if(!e.authStrategy){if(!e.auth){this.auth=async()=>({type:"unauthenticated"})}else{const a=o.createTokenAuth(e.auth);t.wrap("request",a.hook);this.auth=a}}else{const{authStrategy:a}=e,r=_objectWithoutProperties(e,l);const i=a(Object.assign({request:this.request,log:this.log,octokit:this,octokitOptions:r},e.auth));t.wrap("request",i.hook);this.auth=i}const d=this.constructor;d.plugins.forEach((t=>{Object.assign(this,t(this,e))}))}static defaults(e){const t=class extends(this){constructor(...t){const a=t[0]||{};if(typeof e==="function"){super(e(a));return}super(Object.assign({},e,a,a.userAgent&&e.userAgent?{userAgent:`${a.userAgent} ${e.userAgent}`}:null))}};return t}static plugin(...e){var t;const a=this.plugins;const r=(t=class extends(this){},t.plugins=a.concat(e.filter((e=>!a.includes(e)))),t);return r}}Octokit.VERSION=p;Octokit.plugins=[];t.Octokit=Octokit},9440:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(3287);var i=a(5030);function lowercaseKeys(e){if(!e){return{}}return Object.keys(e).reduce(((t,a)=>{t[a.toLowerCase()]=e[a];return t}),{})}function mergeDeep(e,t){const a=Object.assign({},e);Object.keys(t).forEach((i=>{if(r.isPlainObject(t[i])){if(!(i in e))Object.assign(a,{[i]:t[i]});else a[i]=mergeDeep(e[i],t[i])}else{Object.assign(a,{[i]:t[i]})}}));return a}function removeUndefinedProperties(e){for(const t in e){if(e[t]===undefined){delete e[t]}}return e}function merge(e,t,a){if(typeof t==="string"){let[e,r]=t.split(" ");a=Object.assign(r?{method:e,url:r}:{url:e},a)}else{a=Object.assign({},t)}a.headers=lowercaseKeys(a.headers);removeUndefinedProperties(a);removeUndefinedProperties(a.headers);const r=mergeDeep(e||{},a);if(e&&e.mediaType.previews.length){r.mediaType.previews=e.mediaType.previews.filter((e=>!r.mediaType.previews.includes(e))).concat(r.mediaType.previews)}r.mediaType.previews=r.mediaType.previews.map((e=>e.replace(/-preview/,"")));return r}function addQueryParameters(e,t){const a=/\?/.test(e)?"&":"?";const r=Object.keys(t);if(r.length===0){return e}return e+a+r.map((e=>{if(e==="q"){return"q="+t.q.split("+").map(encodeURIComponent).join("+")}return`${e}=${encodeURIComponent(t[e])}`})).join("&")}const n=/\{[^}]+\}/g;function removeNonChars(e){return e.replace(/^\W+|\W+$/g,"").split(/,/)}function extractUrlVariableNames(e){const t=e.match(n);if(!t){return[]}return t.map(removeNonChars).reduce(((e,t)=>e.concat(t)),[])}function omit(e,t){return Object.keys(e).filter((e=>!t.includes(e))).reduce(((t,a)=>{t[a]=e[a];return t}),{})}function encodeReserved(e){return e.split(/(%[0-9A-Fa-f]{2})/g).map((function(e){if(!/%[0-9A-Fa-f]/.test(e)){e=encodeURI(e).replace(/%5B/g,"[").replace(/%5D/g,"]")}return e})).join("")}function encodeUnreserved(e){return encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function encodeValue(e,t,a){t=e==="+"||e==="#"?encodeReserved(t):encodeUnreserved(t);if(a){return encodeUnreserved(a)+"="+t}else{return t}}function isDefined(e){return e!==undefined&&e!==null}function isKeyOperator(e){return e===";"||e==="&"||e==="?"}function getValues(e,t,a,r){var i=e[a],n=[];if(isDefined(i)&&i!==""){if(typeof i==="string"||typeof i==="number"||typeof i==="boolean"){i=i.toString();if(r&&r!=="*"){i=i.substring(0,parseInt(r,10))}n.push(encodeValue(t,i,isKeyOperator(t)?a:""))}else{if(r==="*"){if(Array.isArray(i)){i.filter(isDefined).forEach((function(e){n.push(encodeValue(t,e,isKeyOperator(t)?a:""))}))}else{Object.keys(i).forEach((function(e){if(isDefined(i[e])){n.push(encodeValue(t,i[e],e))}}))}}else{const e=[];if(Array.isArray(i)){i.filter(isDefined).forEach((function(a){e.push(encodeValue(t,a))}))}else{Object.keys(i).forEach((function(a){if(isDefined(i[a])){e.push(encodeUnreserved(a));e.push(encodeValue(t,i[a].toString()))}}))}if(isKeyOperator(t)){n.push(encodeUnreserved(a)+"="+e.join(","))}else if(e.length!==0){n.push(e.join(","))}}}}else{if(t===";"){if(isDefined(i)){n.push(encodeUnreserved(a))}}else if(i===""&&(t==="&"||t==="?")){n.push(encodeUnreserved(a)+"=")}else if(i===""){n.push("")}}return n}function parseUrl(e){return{expand:expand.bind(null,e)}}function expand(e,t){var a=["+","#",".","/",";","?","&"];return e.replace(/\{([^\{\}]+)\}|([^\{\}]+)/g,(function(e,r,i){if(r){let e="";const i=[];if(a.indexOf(r.charAt(0))!==-1){e=r.charAt(0);r=r.substr(1)}r.split(/,/g).forEach((function(a){var r=/([^:\*]*)(?::(\d+)|(\*))?/.exec(a);i.push(getValues(t,e,r[1],r[2]||r[3]))}));if(e&&e!=="+"){var n=",";if(e==="?"){n="&"}else if(e!=="#"){n=e}return(i.length!==0?e:"")+i.join(n)}else{return i.join(",")}}else{return encodeReserved(i)}}))}function parse(e){let t=e.method.toUpperCase();let a=(e.url||"/").replace(/:([a-z]\w+)/g,"{$1}");let r=Object.assign({},e.headers);let i;let n=omit(e,["method","baseUrl","url","headers","request","mediaType"]);const s=extractUrlVariableNames(a);a=parseUrl(a).expand(n);if(!/^http/.test(a)){a=e.baseUrl+a}const o=Object.keys(e).filter((e=>s.includes(e))).concat("baseUrl");const p=omit(n,o);const l=/application\/octet-stream/i.test(r.accept);if(!l){if(e.mediaType.format){r.accept=r.accept.split(/,/).map((t=>t.replace(/application\/vnd(\.\w+)(\.v3)?(\.\w+)?(\+json)?$/,`application/vnd$1$2.${e.mediaType.format}`))).join(",")}if(e.mediaType.previews.length){const t=r.accept.match(/[\w-]+(?=-preview)/g)||[];r.accept=t.concat(e.mediaType.previews).map((t=>{const a=e.mediaType.format?`.${e.mediaType.format}`:"+json";return`application/vnd.github.${t}-preview${a}`})).join(",")}}if(["GET","HEAD"].includes(t)){a=addQueryParameters(a,p)}else{if("data"in p){i=p.data}else{if(Object.keys(p).length){i=p}else{r["content-length"]=0}}}if(!r["content-type"]&&typeof i!=="undefined"){r["content-type"]="application/json; charset=utf-8"}if(["PATCH","PUT"].includes(t)&&typeof i==="undefined"){i=""}return Object.assign({method:t,url:a,headers:r},typeof i!=="undefined"?{body:i}:null,e.request?{request:e.request}:null)}function endpointWithDefaults(e,t,a){return parse(merge(e,t,a))}function withDefaults(e,t){const a=merge(e,t);const r=endpointWithDefaults.bind(null,a);return Object.assign(r,{DEFAULTS:a,defaults:withDefaults.bind(null,a),merge:merge.bind(null,a),parse:parse})}const s="6.0.12";const o=`octokit-endpoint.js/${s} ${i.getUserAgent()}`;const p={method:"GET",baseUrl:"https://api.github.com",headers:{accept:"application/vnd.github.v3+json","user-agent":o},mediaType:{format:"",previews:[]}};const l=withDefaults(null,p);t.endpoint=l},8467:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var r=a(6234);var i=a(5030);const n="4.8.0";function _buildMessageForResponseErrors(e){return`Request failed due to following response errors:\n`+e.errors.map((e=>` - ${e.message}`)).join("\n")}class GraphqlResponseError extends Error{constructor(e,t,a){super(_buildMessageForResponseErrors(a));this.request=e;this.headers=t;this.response=a;this.name="GraphqlResponseError";this.errors=a.errors;this.data=a.data;if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}}}const s=["method","baseUrl","url","headers","request","query","mediaType"];const o=["query","method","url"];const p=/\/api\/v3\/?$/;function graphql(e,t,a){if(a){if(typeof t==="string"&&"query"in a){return Promise.reject(new Error(`[@octokit/graphql] "query" cannot be used as variable name`))}for(const e in a){if(!o.includes(e))continue;return Promise.reject(new Error(`[@octokit/graphql] "${e}" cannot be used as variable name`))}}const r=typeof t==="string"?Object.assign({query:t},a):t;const i=Object.keys(r).reduce(((e,t)=>{if(s.includes(t)){e[t]=r[t];return e}if(!e.variables){e.variables={}}e.variables[t]=r[t];return e}),{});const n=r.baseUrl||e.endpoint.DEFAULTS.baseUrl;if(p.test(n)){i.url=n.replace(p,"/api/graphql")}return e(i).then((e=>{if(e.data.errors){const t={};for(const a of Object.keys(e.headers)){t[a]=e.headers[a]}throw new GraphqlResponseError(i,t,e.data)}return e.data.data}))}function withDefaults(e,t){const a=e.defaults(t);const newApi=(e,t)=>graphql(a,e,t);return Object.assign(newApi,{defaults:withDefaults.bind(null,a),endpoint:r.request.endpoint})}const l=withDefaults(r.request,{headers:{"user-agent":`octokit-graphql.js/${n} ${i.getUserAgent()}`},method:"POST",url:"/graphql"});function withCustomRequest(e){return withDefaults(e,{method:"POST",url:"/graphql"})}t.GraphqlResponseError=GraphqlResponseError;t.graphql=l;t.withCustomRequest=withCustomRequest},4193:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});const a="2.21.3";function ownKeys(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function _objectSpread2(e){for(var t=1;t({async next(){if(!o)return{done:true};try{const e=await i({method:n,url:o,headers:s});const t=normalizePaginatedListResponse(e);o=((t.headers.link||"").match(/<([^>]+)>;\s*rel="next"/)||[])[1];return{value:t}}catch(e){if(e.status!==409)throw e;o="";return{value:{status:200,headers:{},data:[]}}}}})}}function paginate(e,t,a,r){if(typeof a==="function"){r=a;a=undefined}return gather(e,[],iterator(e,t,a)[Symbol.asyncIterator](),r)}function gather(e,t,a,r){return a.next().then((i=>{if(i.done){return t}let n=false;function done(){n=true}t=t.concat(r?r(i.value,done):i.value.data);if(n){return t}return gather(e,t,a,r)}))}const r=Object.assign(paginate,{iterator:iterator});const i=["GET /app/hook/deliveries","GET /app/installations","GET /applications/grants","GET /authorizations","GET /enterprises/{enterprise}/actions/permissions/organizations","GET /enterprises/{enterprise}/actions/runner-groups","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/organizations","GET /enterprises/{enterprise}/actions/runner-groups/{runner_group_id}/runners","GET /enterprises/{enterprise}/actions/runners","GET /enterprises/{enterprise}/audit-log","GET /enterprises/{enterprise}/secret-scanning/alerts","GET /enterprises/{enterprise}/settings/billing/advanced-security","GET /events","GET /gists","GET /gists/public","GET /gists/starred","GET /gists/{gist_id}/comments","GET /gists/{gist_id}/commits","GET /gists/{gist_id}/forks","GET /installation/repositories","GET /issues","GET /licenses","GET /marketplace_listing/plans","GET /marketplace_listing/plans/{plan_id}/accounts","GET /marketplace_listing/stubbed/plans","GET /marketplace_listing/stubbed/plans/{plan_id}/accounts","GET /networks/{owner}/{repo}/events","GET /notifications","GET /organizations","GET /orgs/{org}/actions/cache/usage-by-repository","GET /orgs/{org}/actions/permissions/repositories","GET /orgs/{org}/actions/runner-groups","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories","GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners","GET /orgs/{org}/actions/runners","GET /orgs/{org}/actions/secrets","GET /orgs/{org}/actions/secrets/{secret_name}/repositories","GET /orgs/{org}/audit-log","GET /orgs/{org}/blocks","GET /orgs/{org}/code-scanning/alerts","GET /orgs/{org}/codespaces","GET /orgs/{org}/credential-authorizations","GET /orgs/{org}/dependabot/secrets","GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories","GET /orgs/{org}/events","GET /orgs/{org}/external-groups","GET /orgs/{org}/failed_invitations","GET /orgs/{org}/hooks","GET /orgs/{org}/hooks/{hook_id}/deliveries","GET /orgs/{org}/installations","GET /orgs/{org}/invitations","GET /orgs/{org}/invitations/{invitation_id}/teams","GET /orgs/{org}/issues","GET /orgs/{org}/members","GET /orgs/{org}/migrations","GET /orgs/{org}/migrations/{migration_id}/repositories","GET /orgs/{org}/outside_collaborators","GET /orgs/{org}/packages","GET /orgs/{org}/packages/{package_type}/{package_name}/versions","GET /orgs/{org}/projects","GET /orgs/{org}/public_members","GET /orgs/{org}/repos","GET /orgs/{org}/secret-scanning/alerts","GET /orgs/{org}/settings/billing/advanced-security","GET /orgs/{org}/team-sync/groups","GET /orgs/{org}/teams","GET /orgs/{org}/teams/{team_slug}/discussions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions","GET /orgs/{org}/teams/{team_slug}/invitations","GET /orgs/{org}/teams/{team_slug}/members","GET /orgs/{org}/teams/{team_slug}/projects","GET /orgs/{org}/teams/{team_slug}/repos","GET /orgs/{org}/teams/{team_slug}/teams","GET /projects/columns/{column_id}/cards","GET /projects/{project_id}/collaborators","GET /projects/{project_id}/columns","GET /repos/{owner}/{repo}/actions/artifacts","GET /repos/{owner}/{repo}/actions/caches","GET /repos/{owner}/{repo}/actions/runners","GET /repos/{owner}/{repo}/actions/runs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/artifacts","GET /repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs","GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs","GET /repos/{owner}/{repo}/actions/secrets","GET /repos/{owner}/{repo}/actions/workflows","GET /repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs","GET /repos/{owner}/{repo}/assignees","GET /repos/{owner}/{repo}/branches","GET /repos/{owner}/{repo}/check-runs/{check_run_id}/annotations","GET /repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs","GET /repos/{owner}/{repo}/code-scanning/alerts","GET /repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances","GET /repos/{owner}/{repo}/code-scanning/analyses","GET /repos/{owner}/{repo}/codespaces","GET /repos/{owner}/{repo}/codespaces/devcontainers","GET /repos/{owner}/{repo}/codespaces/secrets","GET /repos/{owner}/{repo}/collaborators","GET /repos/{owner}/{repo}/comments","GET /repos/{owner}/{repo}/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/commits","GET /repos/{owner}/{repo}/commits/{commit_sha}/comments","GET /repos/{owner}/{repo}/commits/{commit_sha}/pulls","GET /repos/{owner}/{repo}/commits/{ref}/check-runs","GET /repos/{owner}/{repo}/commits/{ref}/check-suites","GET /repos/{owner}/{repo}/commits/{ref}/status","GET /repos/{owner}/{repo}/commits/{ref}/statuses","GET /repos/{owner}/{repo}/contributors","GET /repos/{owner}/{repo}/dependabot/secrets","GET /repos/{owner}/{repo}/deployments","GET /repos/{owner}/{repo}/deployments/{deployment_id}/statuses","GET /repos/{owner}/{repo}/environments","GET /repos/{owner}/{repo}/events","GET /repos/{owner}/{repo}/forks","GET /repos/{owner}/{repo}/git/matching-refs/{ref}","GET /repos/{owner}/{repo}/hooks","GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries","GET /repos/{owner}/{repo}/invitations","GET /repos/{owner}/{repo}/issues","GET /repos/{owner}/{repo}/issues/comments","GET /repos/{owner}/{repo}/issues/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/issues/events","GET /repos/{owner}/{repo}/issues/{issue_number}/comments","GET /repos/{owner}/{repo}/issues/{issue_number}/events","GET /repos/{owner}/{repo}/issues/{issue_number}/labels","GET /repos/{owner}/{repo}/issues/{issue_number}/reactions","GET /repos/{owner}/{repo}/issues/{issue_number}/timeline","GET /repos/{owner}/{repo}/keys","GET /repos/{owner}/{repo}/labels","GET /repos/{owner}/{repo}/milestones","GET /repos/{owner}/{repo}/milestones/{milestone_number}/labels","GET /repos/{owner}/{repo}/notifications","GET /repos/{owner}/{repo}/pages/builds","GET /repos/{owner}/{repo}/projects","GET /repos/{owner}/{repo}/pulls","GET /repos/{owner}/{repo}/pulls/comments","GET /repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions","GET /repos/{owner}/{repo}/pulls/{pull_number}/comments","GET /repos/{owner}/{repo}/pulls/{pull_number}/commits","GET /repos/{owner}/{repo}/pulls/{pull_number}/files","GET /repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews","GET /repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments","GET /repos/{owner}/{repo}/releases","GET /repos/{owner}/{repo}/releases/{release_id}/assets","GET /repos/{owner}/{repo}/releases/{release_id}/reactions","GET /repos/{owner}/{repo}/secret-scanning/alerts","GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations","GET /repos/{owner}/{repo}/stargazers","GET /repos/{owner}/{repo}/subscribers","GET /repos/{owner}/{repo}/tags","GET /repos/{owner}/{repo}/teams","GET /repos/{owner}/{repo}/topics","GET /repositories","GET /repositories/{repository_id}/environments/{environment_name}/secrets","GET /search/code","GET /search/commits","GET /search/issues","GET /search/labels","GET /search/repositories","GET /search/topics","GET /search/users","GET /teams/{team_id}/discussions","GET /teams/{team_id}/discussions/{discussion_number}/comments","GET /teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions","GET /teams/{team_id}/discussions/{discussion_number}/reactions","GET /teams/{team_id}/invitations","GET /teams/{team_id}/members","GET /teams/{team_id}/projects","GET /teams/{team_id}/repos","GET /teams/{team_id}/teams","GET /user/blocks","GET /user/codespaces","GET /user/codespaces/secrets","GET /user/emails","GET /user/followers","GET /user/following","GET /user/gpg_keys","GET /user/installations","GET /user/installations/{installation_id}/repositories","GET /user/issues","GET /user/keys","GET /user/marketplace_purchases","GET /user/marketplace_purchases/stubbed","GET /user/memberships/orgs","GET /user/migrations","GET /user/migrations/{migration_id}/repositories","GET /user/orgs","GET /user/packages","GET /user/packages/{package_type}/{package_name}/versions","GET /user/public_emails","GET /user/repos","GET /user/repository_invitations","GET /user/starred","GET /user/subscriptions","GET /user/teams","GET /users","GET /users/{username}/events","GET /users/{username}/events/orgs/{org}","GET /users/{username}/events/public","GET /users/{username}/followers","GET /users/{username}/following","GET /users/{username}/gists","GET /users/{username}/gpg_keys","GET /users/{username}/keys","GET /users/{username}/orgs","GET /users/{username}/packages","GET /users/{username}/projects","GET /users/{username}/received_events","GET /users/{username}/received_events/public","GET /users/{username}/repos","GET /users/{username}/starred","GET /users/{username}/subscriptions"];function isPaginatingEndpoint(e){if(typeof e==="string"){return i.includes(e)}else{return false}}function paginateRest(e){return{paginate:Object.assign(paginate.bind(null,e),{iterator:iterator.bind(null,e)})}}paginateRest.VERSION=a;t.composePaginateRest=r;t.isPaginatingEndpoint=isPaginatingEndpoint;t.paginateRest=paginateRest;t.paginatingEndpoints=i},3044:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function ownKeys(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);if(t){r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))}a.push.apply(a,r)}return a}function _objectSpread2(e){for(var t=1;t{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var r=a(8932);var i=_interopDefault(a(1223));const n=i((e=>console.warn(e)));const s=i((e=>console.warn(e)));class RequestError extends Error{constructor(e,t,a){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="HttpError";this.status=t;let i;if("headers"in a&&typeof a.headers!=="undefined"){i=a.headers}if("response"in a){this.response=a.response;i=a.response.headers}const o=Object.assign({},a.request);if(a.request.headers.authorization){o.headers=Object.assign({},a.request.headers,{authorization:a.request.headers.authorization.replace(/ .*$/," [REDACTED]")})}o.url=o.url.replace(/\bclient_secret=\w+/g,"client_secret=[REDACTED]").replace(/\baccess_token=\w+/g,"access_token=[REDACTED]");this.request=o;Object.defineProperty(this,"code",{get(){n(new r.Deprecation("[@octokit/request-error] `error.code` is deprecated, use `error.status`."));return t}});Object.defineProperty(this,"headers",{get(){s(new r.Deprecation("[@octokit/request-error] `error.headers` is deprecated, use `error.response.headers`."));return i||{}}})}}t.RequestError=RequestError},6234:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});function _interopDefault(e){return e&&typeof e==="object"&&"default"in e?e["default"]:e}var r=a(9440);var i=a(5030);var n=a(3287);var s=_interopDefault(a(467));var o=a(537);const p="5.6.3";function getBufferResponse(e){return e.arrayBuffer()}function fetchWrapper(e){const t=e.request&&e.request.log?e.request.log:console;if(n.isPlainObject(e.body)||Array.isArray(e.body)){e.body=JSON.stringify(e.body)}let a={};let r;let i;const p=e.request&&e.request.fetch||s;return p(e.url,Object.assign({method:e.method,body:e.body,headers:e.headers,redirect:e.redirect},e.request)).then((async n=>{i=n.url;r=n.status;for(const e of n.headers){a[e[0]]=e[1]}if("deprecation"in a){const r=a.link&&a.link.match(/<([^>]+)>; rel="deprecation"/);const i=r&&r.pop();t.warn(`[@octokit/request] "${e.method} ${e.url}" is deprecated. It is scheduled to be removed on ${a.sunset}${i?`. See ${i}`:""}`)}if(r===204||r===205){return}if(e.method==="HEAD"){if(r<400){return}throw new o.RequestError(n.statusText,r,{response:{url:i,status:r,headers:a,data:undefined},request:e})}if(r===304){throw new o.RequestError("Not modified",r,{response:{url:i,status:r,headers:a,data:await getResponseData(n)},request:e})}if(r>=400){const t=await getResponseData(n);const s=new o.RequestError(toErrorMessage(t),r,{response:{url:i,status:r,headers:a,data:t},request:e});throw s}return getResponseData(n)})).then((e=>({status:r,url:i,headers:a,data:e}))).catch((t=>{if(t instanceof o.RequestError)throw t;throw new o.RequestError(t.message,500,{request:e})}))}async function getResponseData(e){const t=e.headers.get("content-type");if(/application\/json/.test(t)){return e.json()}if(!t||/^text\/|charset=utf-8$/.test(t)){return e.text()}return getBufferResponse(e)}function toErrorMessage(e){if(typeof e==="string")return e;if("message"in e){if(Array.isArray(e.errors)){return`${e.message}: ${e.errors.map(JSON.stringify).join(", ")}`}return e.message}return`Unknown error: ${JSON.stringify(e)}`}function withDefaults(e,t){const a=e.defaults(t);const newApi=function(e,t){const r=a.merge(e,t);if(!r.request||!r.request.hook){return fetchWrapper(a.parse(r))}const request=(e,t)=>fetchWrapper(a.parse(a.merge(e,t)));Object.assign(request,{endpoint:a,defaults:withDefaults.bind(null,a)});return r.request.hook(request,r)};return Object.assign(newApi,{endpoint:a,defaults:withDefaults.bind(null,a)})}const l=withDefaults(r.endpoint,{headers:{"user-agent":`octokit-request.js/${p} ${i.getUserAgent()}`}});t.request=l},7171:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ContextAPI=void 0;const r=a(4118);const i=a(5135);const n=a(1877);const s="context";const o=new r.NoopContextManager;class ContextAPI{constructor(){}static getInstance(){if(!this._instance){this._instance=new ContextAPI}return this._instance}setGlobalContextManager(e){return(0,i.registerGlobal)(s,e,n.DiagAPI.instance())}active(){return this._getContextManager().active()}with(e,t,a,...r){return this._getContextManager().with(e,t,a,...r)}bind(e,t){return this._getContextManager().bind(e,t)}_getContextManager(){return(0,i.getGlobal)(s)||o}disable(){this._getContextManager().disable();(0,i.unregisterGlobal)(s,n.DiagAPI.instance())}}t.ContextAPI=ContextAPI},1877:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagAPI=void 0;const r=a(7978);const i=a(9639);const n=a(8077);const s=a(5135);const o="diag";class DiagAPI{constructor(){function _logProxy(e){return function(...t){const a=(0,s.getGlobal)("diag");if(!a)return;return a[e](...t)}}const e=this;const setLogger=(t,a={logLevel:n.DiagLogLevel.INFO})=>{var r,o,p;if(t===e){const t=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");e.error((r=t.stack)!==null&&r!==void 0?r:t.message);return false}if(typeof a==="number"){a={logLevel:a}}const l=(0,s.getGlobal)("diag");const d=(0,i.createLogLevelDiagLogger)((o=a.logLevel)!==null&&o!==void 0?o:n.DiagLogLevel.INFO,t);if(l&&!a.suppressOverrideMessage){const e=(p=(new Error).stack)!==null&&p!==void 0?p:"";l.warn(`Current logger will be overwritten from ${e}`);d.warn(`Current logger will overwrite one already registered from ${e}`)}return(0,s.registerGlobal)("diag",d,e,true)};e.setLogger=setLogger;e.disable=()=>{(0,s.unregisterGlobal)(o,e)};e.createComponentLogger=e=>new r.DiagComponentLogger(e);e.verbose=_logProxy("verbose");e.debug=_logProxy("debug");e.info=_logProxy("info");e.warn=_logProxy("warn");e.error=_logProxy("error")}static instance(){if(!this._instance){this._instance=new DiagAPI}return this._instance}}t.DiagAPI=DiagAPI},7696:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.MetricsAPI=void 0;const r=a(2647);const i=a(5135);const n=a(1877);const s="metrics";class MetricsAPI{constructor(){}static getInstance(){if(!this._instance){this._instance=new MetricsAPI}return this._instance}setGlobalMeterProvider(e){return(0,i.registerGlobal)(s,e,n.DiagAPI.instance())}getMeterProvider(){return(0,i.getGlobal)(s)||r.NOOP_METER_PROVIDER}getMeter(e,t,a){return this.getMeterProvider().getMeter(e,t,a)}disable(){(0,i.unregisterGlobal)(s,n.DiagAPI.instance())}}t.MetricsAPI=MetricsAPI},9909:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.PropagationAPI=void 0;const r=a(5135);const i=a(2368);const n=a(865);const s=a(7682);const o=a(8136);const p=a(1877);const l="propagation";const d=new i.NoopTextMapPropagator;class PropagationAPI{constructor(){this.createBaggage=o.createBaggage;this.getBaggage=s.getBaggage;this.getActiveBaggage=s.getActiveBaggage;this.setBaggage=s.setBaggage;this.deleteBaggage=s.deleteBaggage}static getInstance(){if(!this._instance){this._instance=new PropagationAPI}return this._instance}setGlobalPropagator(e){return(0,r.registerGlobal)(l,e,p.DiagAPI.instance())}inject(e,t,a=n.defaultTextMapSetter){return this._getGlobalPropagator().inject(e,t,a)}extract(e,t,a=n.defaultTextMapGetter){return this._getGlobalPropagator().extract(e,t,a)}fields(){return this._getGlobalPropagator().fields()}disable(){(0,r.unregisterGlobal)(l,p.DiagAPI.instance())}_getGlobalPropagator(){return(0,r.getGlobal)(l)||d}}t.PropagationAPI=PropagationAPI},1539:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceAPI=void 0;const r=a(5135);const i=a(2285);const n=a(9745);const s=a(3326);const o=a(1877);const p="trace";class TraceAPI{constructor(){this._proxyTracerProvider=new i.ProxyTracerProvider;this.wrapSpanContext=n.wrapSpanContext;this.isSpanContextValid=n.isSpanContextValid;this.deleteSpan=s.deleteSpan;this.getSpan=s.getSpan;this.getActiveSpan=s.getActiveSpan;this.getSpanContext=s.getSpanContext;this.setSpan=s.setSpan;this.setSpanContext=s.setSpanContext}static getInstance(){if(!this._instance){this._instance=new TraceAPI}return this._instance}setGlobalTracerProvider(e){const t=(0,r.registerGlobal)(p,this._proxyTracerProvider,o.DiagAPI.instance());if(t){this._proxyTracerProvider.setDelegate(e)}return t}getTracerProvider(){return(0,r.getGlobal)(p)||this._proxyTracerProvider}getTracer(e,t){return this.getTracerProvider().getTracer(e,t)}disable(){(0,r.unregisterGlobal)(p,o.DiagAPI.instance());this._proxyTracerProvider=new i.ProxyTracerProvider}}t.TraceAPI=TraceAPI},7682:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.deleteBaggage=t.setBaggage=t.getActiveBaggage=t.getBaggage=void 0;const r=a(7171);const i=a(8242);const n=(0,i.createContextKey)("OpenTelemetry Baggage Key");function getBaggage(e){return e.getValue(n)||undefined}t.getBaggage=getBaggage;function getActiveBaggage(){return getBaggage(r.ContextAPI.getInstance().active())}t.getActiveBaggage=getActiveBaggage;function setBaggage(e,t){return e.setValue(n,t)}t.setBaggage=setBaggage;function deleteBaggage(e){return e.deleteValue(n)}t.deleteBaggage=deleteBaggage},4811:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.BaggageImpl=void 0;class BaggageImpl{constructor(e){this._entries=e?new Map(e):new Map}getEntry(e){const t=this._entries.get(e);if(!t){return undefined}return Object.assign({},t)}getAllEntries(){return Array.from(this._entries.entries()).map((([e,t])=>[e,t]))}setEntry(e,t){const a=new BaggageImpl(this._entries);a._entries.set(e,t);return a}removeEntry(e){const t=new BaggageImpl(this._entries);t._entries.delete(e);return t}removeEntries(...e){const t=new BaggageImpl(this._entries);for(const a of e){t._entries.delete(a)}return t}clear(){return new BaggageImpl}}t.BaggageImpl=BaggageImpl},3542:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.baggageEntryMetadataSymbol=void 0;t.baggageEntryMetadataSymbol=Symbol("BaggageEntryMetadata")},8136:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.baggageEntryMetadataFromString=t.createBaggage=void 0;const r=a(1877);const i=a(4811);const n=a(3542);const s=r.DiagAPI.instance();function createBaggage(e={}){return new i.BaggageImpl(new Map(Object.entries(e)))}t.createBaggage=createBaggage;function baggageEntryMetadataFromString(e){if(typeof e!=="string"){s.error(`Cannot create baggage metadata from unknown type: ${typeof e}`);e=""}return{__TYPE__:n.baggageEntryMetadataSymbol,toString(){return e}}}t.baggageEntryMetadataFromString=baggageEntryMetadataFromString},7393:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.context=void 0;const r=a(7171);t.context=r.ContextAPI.getInstance()},4118:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopContextManager=void 0;const r=a(8242);class NoopContextManager{active(){return r.ROOT_CONTEXT}with(e,t,a,...r){return t.call(a,...r)}bind(e,t){return t}enable(){return this}disable(){return this}}t.NoopContextManager=NoopContextManager},8242:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ROOT_CONTEXT=t.createContextKey=void 0;function createContextKey(e){return Symbol.for(e)}t.createContextKey=createContextKey;class BaseContext{constructor(e){const t=this;t._currentContext=e?new Map(e):new Map;t.getValue=e=>t._currentContext.get(e);t.setValue=(e,a)=>{const r=new BaseContext(t._currentContext);r._currentContext.set(e,a);return r};t.deleteValue=e=>{const a=new BaseContext(t._currentContext);a._currentContext.delete(e);return a}}}t.ROOT_CONTEXT=new BaseContext},9721:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.diag=void 0;const r=a(1877);t.diag=r.DiagAPI.instance()},7978:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagComponentLogger=void 0;const r=a(5135);class DiagComponentLogger{constructor(e){this._namespace=e.namespace||"DiagComponentLogger"}debug(...e){return logProxy("debug",this._namespace,e)}error(...e){return logProxy("error",this._namespace,e)}info(...e){return logProxy("info",this._namespace,e)}warn(...e){return logProxy("warn",this._namespace,e)}verbose(...e){return logProxy("verbose",this._namespace,e)}}t.DiagComponentLogger=DiagComponentLogger;function logProxy(e,t,a){const i=(0,r.getGlobal)("diag");if(!i){return}a.unshift(t);return i[e](...a)}},3041:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagConsoleLogger=void 0;const a=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}];class DiagConsoleLogger{constructor(){function _consoleFunc(e){return function(...t){if(console){let a=console[e];if(typeof a!=="function"){a=console.log}if(typeof a==="function"){return a.apply(console,t)}}}}for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createLogLevelDiagLogger=void 0;const r=a(8077);function createLogLevelDiagLogger(e,t){if(er.DiagLogLevel.ALL){e=r.DiagLogLevel.ALL}t=t||{};function _filterFunc(a,r){const i=t[a];if(typeof i==="function"&&e>=r){return i.bind(t)}return function(){}}return{error:_filterFunc("error",r.DiagLogLevel.ERROR),warn:_filterFunc("warn",r.DiagLogLevel.WARN),info:_filterFunc("info",r.DiagLogLevel.INFO),debug:_filterFunc("debug",r.DiagLogLevel.DEBUG),verbose:_filterFunc("verbose",r.DiagLogLevel.VERBOSE)}}t.createLogLevelDiagLogger=createLogLevelDiagLogger},8077:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.DiagLogLevel=void 0;var a;(function(e){e[e["NONE"]=0]="NONE";e[e["ERROR"]=30]="ERROR";e[e["WARN"]=50]="WARN";e[e["INFO"]=60]="INFO";e[e["DEBUG"]=70]="DEBUG";e[e["VERBOSE"]=80]="VERBOSE";e[e["ALL"]=9999]="ALL"})(a=t.DiagLogLevel||(t.DiagLogLevel={}))},5163:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.trace=t.propagation=t.metrics=t.diag=t.context=t.INVALID_SPAN_CONTEXT=t.INVALID_TRACEID=t.INVALID_SPANID=t.isValidSpanId=t.isValidTraceId=t.isSpanContextValid=t.createTraceState=t.TraceFlags=t.SpanStatusCode=t.SpanKind=t.SamplingDecision=t.ProxyTracerProvider=t.ProxyTracer=t.defaultTextMapSetter=t.defaultTextMapGetter=t.ValueType=t.createNoopMeter=t.DiagLogLevel=t.DiagConsoleLogger=t.ROOT_CONTEXT=t.createContextKey=t.baggageEntryMetadataFromString=void 0;var r=a(8136);Object.defineProperty(t,"baggageEntryMetadataFromString",{enumerable:true,get:function(){return r.baggageEntryMetadataFromString}});var i=a(8242);Object.defineProperty(t,"createContextKey",{enumerable:true,get:function(){return i.createContextKey}});Object.defineProperty(t,"ROOT_CONTEXT",{enumerable:true,get:function(){return i.ROOT_CONTEXT}});var n=a(3041);Object.defineProperty(t,"DiagConsoleLogger",{enumerable:true,get:function(){return n.DiagConsoleLogger}});var s=a(8077);Object.defineProperty(t,"DiagLogLevel",{enumerable:true,get:function(){return s.DiagLogLevel}});var o=a(4837);Object.defineProperty(t,"createNoopMeter",{enumerable:true,get:function(){return o.createNoopMeter}});var p=a(9999);Object.defineProperty(t,"ValueType",{enumerable:true,get:function(){return p.ValueType}});var l=a(865);Object.defineProperty(t,"defaultTextMapGetter",{enumerable:true,get:function(){return l.defaultTextMapGetter}});Object.defineProperty(t,"defaultTextMapSetter",{enumerable:true,get:function(){return l.defaultTextMapSetter}});var d=a(3503);Object.defineProperty(t,"ProxyTracer",{enumerable:true,get:function(){return d.ProxyTracer}});var c=a(2285);Object.defineProperty(t,"ProxyTracerProvider",{enumerable:true,get:function(){return c.ProxyTracerProvider}});var m=a(3209);Object.defineProperty(t,"SamplingDecision",{enumerable:true,get:function(){return m.SamplingDecision}});var u=a(1424);Object.defineProperty(t,"SpanKind",{enumerable:true,get:function(){return u.SpanKind}});var h=a(8845);Object.defineProperty(t,"SpanStatusCode",{enumerable:true,get:function(){return h.SpanStatusCode}});var g=a(6905);Object.defineProperty(t,"TraceFlags",{enumerable:true,get:function(){return g.TraceFlags}});var y=a(2615);Object.defineProperty(t,"createTraceState",{enumerable:true,get:function(){return y.createTraceState}});var v=a(9745);Object.defineProperty(t,"isSpanContextValid",{enumerable:true,get:function(){return v.isSpanContextValid}});Object.defineProperty(t,"isValidTraceId",{enumerable:true,get:function(){return v.isValidTraceId}});Object.defineProperty(t,"isValidSpanId",{enumerable:true,get:function(){return v.isValidSpanId}});var b=a(1760);Object.defineProperty(t,"INVALID_SPANID",{enumerable:true,get:function(){return b.INVALID_SPANID}});Object.defineProperty(t,"INVALID_TRACEID",{enumerable:true,get:function(){return b.INVALID_TRACEID}});Object.defineProperty(t,"INVALID_SPAN_CONTEXT",{enumerable:true,get:function(){return b.INVALID_SPAN_CONTEXT}});const x=a(7393);Object.defineProperty(t,"context",{enumerable:true,get:function(){return x.context}});const w=a(9721);Object.defineProperty(t,"diag",{enumerable:true,get:function(){return w.diag}});const S=a(2601);Object.defineProperty(t,"metrics",{enumerable:true,get:function(){return S.metrics}});const N=a(7591);Object.defineProperty(t,"propagation",{enumerable:true,get:function(){return N.propagation}});const T=a(8989);Object.defineProperty(t,"trace",{enumerable:true,get:function(){return T.trace}});t["default"]={context:x.context,diag:w.diag,metrics:S.metrics,propagation:N.propagation,trace:T.trace}},5135:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.unregisterGlobal=t.getGlobal=t.registerGlobal=void 0;const r=a(9957);const i=a(8996);const n=a(1522);const s=i.VERSION.split(".")[0];const o=Symbol.for(`opentelemetry.js.api.${s}`);const p=r._globalThis;function registerGlobal(e,t,a,r=false){var n;const s=p[o]=(n=p[o])!==null&&n!==void 0?n:{version:i.VERSION};if(!r&&s[e]){const t=new Error(`@opentelemetry/api: Attempted duplicate registration of API: ${e}`);a.error(t.stack||t.message);return false}if(s.version!==i.VERSION){const t=new Error(`@opentelemetry/api: Registration of version v${s.version} for ${e} does not match previously registered API v${i.VERSION}`);a.error(t.stack||t.message);return false}s[e]=t;a.debug(`@opentelemetry/api: Registered a global for ${e} v${i.VERSION}.`);return true}t.registerGlobal=registerGlobal;function getGlobal(e){var t,a;const r=(t=p[o])===null||t===void 0?void 0:t.version;if(!r||!(0,n.isCompatible)(r)){return}return(a=p[o])===null||a===void 0?void 0:a[e]}t.getGlobal=getGlobal;function unregisterGlobal(e,t){t.debug(`@opentelemetry/api: Unregistering a global for ${e} v${i.VERSION}.`);const a=p[o];if(a){delete a[e]}}t.unregisterGlobal=unregisterGlobal},1522:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.isCompatible=t._makeCompatibilityCheck=void 0;const r=a(8996);const i=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;function _makeCompatibilityCheck(e){const t=new Set([e]);const a=new Set;const r=e.match(i);if(!r){return()=>false}const n={major:+r[1],minor:+r[2],patch:+r[3],prerelease:r[4]};if(n.prerelease!=null){return function isExactmatch(t){return t===e}}function _reject(e){a.add(e);return false}function _accept(e){t.add(e);return true}return function isCompatible(e){if(t.has(e)){return true}if(a.has(e)){return false}const r=e.match(i);if(!r){return _reject(e)}const s={major:+r[1],minor:+r[2],patch:+r[3],prerelease:r[4]};if(s.prerelease!=null){return _reject(e)}if(n.major!==s.major){return _reject(e)}if(n.major===0){if(n.minor===s.minor&&n.patch<=s.patch){return _accept(e)}return _reject(e)}if(n.minor<=s.minor){return _accept(e)}return _reject(e)}}t._makeCompatibilityCheck=_makeCompatibilityCheck;t.isCompatible=_makeCompatibilityCheck(r.VERSION)},2601:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.metrics=void 0;const r=a(7696);t.metrics=r.MetricsAPI.getInstance()},9999:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ValueType=void 0;var a;(function(e){e[e["INT"]=0]="INT";e[e["DOUBLE"]=1]="DOUBLE"})(a=t.ValueType||(t.ValueType={}))},4837:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createNoopMeter=t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC=t.NOOP_OBSERVABLE_GAUGE_METRIC=t.NOOP_OBSERVABLE_COUNTER_METRIC=t.NOOP_UP_DOWN_COUNTER_METRIC=t.NOOP_HISTOGRAM_METRIC=t.NOOP_COUNTER_METRIC=t.NOOP_METER=t.NoopObservableUpDownCounterMetric=t.NoopObservableGaugeMetric=t.NoopObservableCounterMetric=t.NoopObservableMetric=t.NoopHistogramMetric=t.NoopUpDownCounterMetric=t.NoopCounterMetric=t.NoopMetric=t.NoopMeter=void 0;class NoopMeter{constructor(){}createHistogram(e,a){return t.NOOP_HISTOGRAM_METRIC}createCounter(e,a){return t.NOOP_COUNTER_METRIC}createUpDownCounter(e,a){return t.NOOP_UP_DOWN_COUNTER_METRIC}createObservableGauge(e,a){return t.NOOP_OBSERVABLE_GAUGE_METRIC}createObservableCounter(e,a){return t.NOOP_OBSERVABLE_COUNTER_METRIC}createObservableUpDownCounter(e,a){return t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC}addBatchObservableCallback(e,t){}removeBatchObservableCallback(e){}}t.NoopMeter=NoopMeter;class NoopMetric{}t.NoopMetric=NoopMetric;class NoopCounterMetric extends NoopMetric{add(e,t){}}t.NoopCounterMetric=NoopCounterMetric;class NoopUpDownCounterMetric extends NoopMetric{add(e,t){}}t.NoopUpDownCounterMetric=NoopUpDownCounterMetric;class NoopHistogramMetric extends NoopMetric{record(e,t){}}t.NoopHistogramMetric=NoopHistogramMetric;class NoopObservableMetric{addCallback(e){}removeCallback(e){}}t.NoopObservableMetric=NoopObservableMetric;class NoopObservableCounterMetric extends NoopObservableMetric{}t.NoopObservableCounterMetric=NoopObservableCounterMetric;class NoopObservableGaugeMetric extends NoopObservableMetric{}t.NoopObservableGaugeMetric=NoopObservableGaugeMetric;class NoopObservableUpDownCounterMetric extends NoopObservableMetric{}t.NoopObservableUpDownCounterMetric=NoopObservableUpDownCounterMetric;t.NOOP_METER=new NoopMeter;t.NOOP_COUNTER_METRIC=new NoopCounterMetric;t.NOOP_HISTOGRAM_METRIC=new NoopHistogramMetric;t.NOOP_UP_DOWN_COUNTER_METRIC=new NoopUpDownCounterMetric;t.NOOP_OBSERVABLE_COUNTER_METRIC=new NoopObservableCounterMetric;t.NOOP_OBSERVABLE_GAUGE_METRIC=new NoopObservableGaugeMetric;t.NOOP_OBSERVABLE_UP_DOWN_COUNTER_METRIC=new NoopObservableUpDownCounterMetric;function createNoopMeter(){return t.NOOP_METER}t.createNoopMeter=createNoopMeter},2647:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NOOP_METER_PROVIDER=t.NoopMeterProvider=void 0;const r=a(4837);class NoopMeterProvider{getMeter(e,t,a){return r.NOOP_METER}}t.NoopMeterProvider=NoopMeterProvider;t.NOOP_METER_PROVIDER=new NoopMeterProvider},9957:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__exportStar||function(e,t){for(var a in e)if(a!=="default"&&!Object.prototype.hasOwnProperty.call(t,a))r(t,e,a)};Object.defineProperty(t,"__esModule",{value:true});i(a(7200),t)},9406:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t._globalThis=void 0;t._globalThis=typeof globalThis==="object"?globalThis:global},7200:function(e,t,a){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,a,r){if(r===undefined)r=a;Object.defineProperty(e,r,{enumerable:true,get:function(){return t[a]}})}:function(e,t,a,r){if(r===undefined)r=a;e[r]=t[a]});var i=this&&this.__exportStar||function(e,t){for(var a in e)if(a!=="default"&&!Object.prototype.hasOwnProperty.call(t,a))r(t,e,a)};Object.defineProperty(t,"__esModule",{value:true});i(a(9406),t)},7591:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.propagation=void 0;const r=a(9909);t.propagation=r.PropagationAPI.getInstance()},2368:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTextMapPropagator=void 0;class NoopTextMapPropagator{inject(e,t){}extract(e,t){return e}fields(){return[]}}t.NoopTextMapPropagator=NoopTextMapPropagator},865:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.defaultTextMapSetter=t.defaultTextMapGetter=void 0;t.defaultTextMapGetter={get(e,t){if(e==null){return undefined}return e[t]},keys(e){if(e==null){return[]}return Object.keys(e)}};t.defaultTextMapSetter={set(e,t,a){if(e==null){return}e[t]=a}}},8989:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.trace=void 0;const r=a(1539);t.trace=r.TraceAPI.getInstance()},1462:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NonRecordingSpan=void 0;const r=a(1760);class NonRecordingSpan{constructor(e=r.INVALID_SPAN_CONTEXT){this._spanContext=e}spanContext(){return this._spanContext}setAttribute(e,t){return this}setAttributes(e){return this}addEvent(e,t){return this}setStatus(e){return this}updateName(e){return this}end(e){}isRecording(){return false}recordException(e,t,a){}}t.NonRecordingSpan=NonRecordingSpan},7606:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTracer=void 0;const r=a(7171);const i=a(3326);const n=a(1462);const s=a(9745);const o=r.ContextAPI.getInstance();class NoopTracer{startSpan(e,t,a=o.active()){const r=Boolean(t===null||t===void 0?void 0:t.root);if(r){return new n.NonRecordingSpan}const p=a&&(0,i.getSpanContext)(a);if(isSpanContext(p)&&(0,s.isSpanContextValid)(p)){return new n.NonRecordingSpan(p)}else{return new n.NonRecordingSpan}}startActiveSpan(e,t,a,r){let n;let s;let p;if(arguments.length<2){return}else if(arguments.length===2){p=t}else if(arguments.length===3){n=t;p=a}else{n=t;s=a;p=r}const l=s!==null&&s!==void 0?s:o.active();const d=this.startSpan(e,n,l);const c=(0,i.setSpan)(l,d);return o.with(c,p,undefined,d)}}t.NoopTracer=NoopTracer;function isSpanContext(e){return typeof e==="object"&&typeof e["spanId"]==="string"&&typeof e["traceId"]==="string"&&typeof e["traceFlags"]==="number"}},3259:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.NoopTracerProvider=void 0;const r=a(7606);class NoopTracerProvider{getTracer(e,t,a){return new r.NoopTracer}}t.NoopTracerProvider=NoopTracerProvider},3503:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ProxyTracer=void 0;const r=a(7606);const i=new r.NoopTracer;class ProxyTracer{constructor(e,t,a,r){this._provider=e;this.name=t;this.version=a;this.options=r}startSpan(e,t,a){return this._getTracer().startSpan(e,t,a)}startActiveSpan(e,t,a,r){const i=this._getTracer();return Reflect.apply(i.startActiveSpan,i,arguments)}_getTracer(){if(this._delegate){return this._delegate}const e=this._provider.getDelegateTracer(this.name,this.version,this.options);if(!e){return i}this._delegate=e;return this._delegate}}t.ProxyTracer=ProxyTracer},2285:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.ProxyTracerProvider=void 0;const r=a(3503);const i=a(3259);const n=new i.NoopTracerProvider;class ProxyTracerProvider{getTracer(e,t,a){var i;return(i=this.getDelegateTracer(e,t,a))!==null&&i!==void 0?i:new r.ProxyTracer(this,e,t,a)}getDelegate(){var e;return(e=this._delegate)!==null&&e!==void 0?e:n}setDelegate(e){this._delegate=e}getDelegateTracer(e,t,a){var r;return(r=this._delegate)===null||r===void 0?void 0:r.getTracer(e,t,a)}}t.ProxyTracerProvider=ProxyTracerProvider},3209:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SamplingDecision=void 0;var a;(function(e){e[e["NOT_RECORD"]=0]="NOT_RECORD";e[e["RECORD"]=1]="RECORD";e[e["RECORD_AND_SAMPLED"]=2]="RECORD_AND_SAMPLED"})(a=t.SamplingDecision||(t.SamplingDecision={}))},3326:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getSpanContext=t.setSpanContext=t.deleteSpan=t.setSpan=t.getActiveSpan=t.getSpan=void 0;const r=a(8242);const i=a(1462);const n=a(7171);const s=(0,r.createContextKey)("OpenTelemetry Context Key SPAN");function getSpan(e){return e.getValue(s)||undefined}t.getSpan=getSpan;function getActiveSpan(){return getSpan(n.ContextAPI.getInstance().active())}t.getActiveSpan=getActiveSpan;function setSpan(e,t){return e.setValue(s,t)}t.setSpan=setSpan;function deleteSpan(e){return e.deleteValue(s)}t.deleteSpan=deleteSpan;function setSpanContext(e,t){return setSpan(e,new i.NonRecordingSpan(t))}t.setSpanContext=setSpanContext;function getSpanContext(e){var t;return(t=getSpan(e))===null||t===void 0?void 0:t.spanContext()}t.getSpanContext=getSpanContext},2110:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceStateImpl=void 0;const r=a(4864);const i=32;const n=512;const s=",";const o="=";class TraceStateImpl{constructor(e){this._internalState=new Map;if(e)this._parse(e)}set(e,t){const a=this._clone();if(a._internalState.has(e)){a._internalState.delete(e)}a._internalState.set(e,t);return a}unset(e){const t=this._clone();t._internalState.delete(e);return t}get(e){return this._internalState.get(e)}serialize(){return this._keys().reduce(((e,t)=>{e.push(t+o+this.get(t));return e}),[]).join(s)}_parse(e){if(e.length>n)return;this._internalState=e.split(s).reverse().reduce(((e,t)=>{const a=t.trim();const i=a.indexOf(o);if(i!==-1){const n=a.slice(0,i);const s=a.slice(i+1,t.length);if((0,r.validateKey)(n)&&(0,r.validateValue)(s)){e.set(n,s)}else{}}return e}),new Map);if(this._internalState.size>i){this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,i))}}_keys(){return Array.from(this._internalState.keys()).reverse()}_clone(){const e=new TraceStateImpl;e._internalState=new Map(this._internalState);return e}}t.TraceStateImpl=TraceStateImpl},4864:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.validateValue=t.validateKey=void 0;const a="[_0-9a-z-*/]";const r=`[a-z]${a}{0,255}`;const i=`[a-z0-9]${a}{0,240}@[a-z]${a}{0,13}`;const n=new RegExp(`^(?:${r}|${i})$`);const s=/^[ -~]{0,255}[!-~]$/;const o=/,|=/;function validateKey(e){return n.test(e)}t.validateKey=validateKey;function validateValue(e){return s.test(e)&&!o.test(e)}t.validateValue=validateValue},2615:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createTraceState=void 0;const r=a(2110);function createTraceState(e){return new r.TraceStateImpl(e)}t.createTraceState=createTraceState},1760:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.INVALID_SPAN_CONTEXT=t.INVALID_TRACEID=t.INVALID_SPANID=void 0;const r=a(6905);t.INVALID_SPANID="0000000000000000";t.INVALID_TRACEID="00000000000000000000000000000000";t.INVALID_SPAN_CONTEXT={traceId:t.INVALID_TRACEID,spanId:t.INVALID_SPANID,traceFlags:r.TraceFlags.NONE}},1424:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SpanKind=void 0;var a;(function(e){e[e["INTERNAL"]=0]="INTERNAL";e[e["SERVER"]=1]="SERVER";e[e["CLIENT"]=2]="CLIENT";e[e["PRODUCER"]=3]="PRODUCER";e[e["CONSUMER"]=4]="CONSUMER"})(a=t.SpanKind||(t.SpanKind={}))},9745:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.wrapSpanContext=t.isSpanContextValid=t.isValidSpanId=t.isValidTraceId=void 0;const r=a(1760);const i=a(1462);const n=/^([0-9a-f]{32})$/i;const s=/^[0-9a-f]{16}$/i;function isValidTraceId(e){return n.test(e)&&e!==r.INVALID_TRACEID}t.isValidTraceId=isValidTraceId;function isValidSpanId(e){return s.test(e)&&e!==r.INVALID_SPANID}t.isValidSpanId=isValidSpanId;function isSpanContextValid(e){return isValidTraceId(e.traceId)&&isValidSpanId(e.spanId)}t.isSpanContextValid=isSpanContextValid;function wrapSpanContext(e){return new i.NonRecordingSpan(e)}t.wrapSpanContext=wrapSpanContext},8845:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.SpanStatusCode=void 0;var a;(function(e){e[e["UNSET"]=0]="UNSET";e[e["OK"]=1]="OK";e[e["ERROR"]=2]="ERROR"})(a=t.SpanStatusCode||(t.SpanStatusCode={}))},6905:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.TraceFlags=void 0;var a;(function(e){e[e["NONE"]=0]="NONE";e[e["SAMPLED"]=1]="SAMPLED"})(a=t.TraceFlags||(t.TraceFlags={}))},8996:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.VERSION=void 0;t.VERSION="1.5.0"},4812:(e,t,a)=>{e.exports={parallel:a(8210),serial:a(445),serialOrdered:a(3578)}},1700:e=>{e.exports=abort;function abort(e){Object.keys(e.jobs).forEach(clean.bind(e));e.jobs={}}function clean(e){if(typeof this.jobs[e]=="function"){this.jobs[e]()}}},2794:(e,t,a)=>{var r=a(5295);e.exports=async;function async(e){var t=false;r((function(){t=true}));return function async_callback(a,i){if(t){e(a,i)}else{r((function nextTick_callback(){e(a,i)}))}}}},5295:e=>{e.exports=defer;function defer(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;if(t){t(e)}else{setTimeout(e,0)}}},9023:(e,t,a)=>{var r=a(2794),i=a(1700);e.exports=iterate;function iterate(e,t,a,r){var n=a["keyedList"]?a["keyedList"][a.index]:a.index;a.jobs[n]=runJob(t,n,e[n],(function(e,t){if(!(n in a.jobs)){return}delete a.jobs[n];if(e){i(a)}else{a.results[n]=t}r(e,a.results)}))}function runJob(e,t,a,i){var n;if(e.length==2){n=e(a,r(i))}else{n=e(a,t,r(i))}return n}},2474:e=>{e.exports=state;function state(e,t){var a=!Array.isArray(e),r={index:0,keyedList:a||t?Object.keys(e):null,jobs:{},results:a?{}:[],size:a?Object.keys(e).length:e.length};if(t){r.keyedList.sort(a?t:function(a,r){return t(e[a],e[r])})}return r}},7942:(e,t,a)=>{var r=a(1700),i=a(2794);e.exports=terminator;function terminator(e){if(!Object.keys(this.jobs).length){return}this.index=this.size;r(this);i(e)(null,this.results)}},8210:(e,t,a)=>{var r=a(9023),i=a(2474),n=a(7942);e.exports=parallel;function parallel(e,t,a){var s=i(e);while(s.index<(s["keyedList"]||e).length){r(e,t,s,(function(e,t){if(e){a(e,t);return}if(Object.keys(s.jobs).length===0){a(null,s.results);return}}));s.index++}return n.bind(s,a)}},445:(e,t,a)=>{var r=a(3578);e.exports=serial;function serial(e,t,a){return r(e,t,null,a)}},3578:(e,t,a)=>{var r=a(9023),i=a(2474),n=a(7942);e.exports=serialOrdered;e.exports.ascending=ascending;e.exports.descending=descending;function serialOrdered(e,t,a,s){var o=i(e,a);r(e,t,o,(function iteratorHandler(a,i){if(a){s(a,i);return}o.index++;if(o.index<(o["keyedList"]||e).length){r(e,t,o,iteratorHandler);return}s(null,o.results)}));return n.bind(o,s)}function ascending(e,t){return et?1:0}function descending(e,t){return-1*ascending(e,t)}},9417:e=>{"use strict";e.exports=balanced;function balanced(e,t,a){if(e instanceof RegExp)e=maybeMatch(e,a);if(t instanceof RegExp)t=maybeMatch(t,a);var r=range(e,t,a);return r&&{start:r[0],end:r[1],pre:a.slice(0,r[0]),body:a.slice(r[0]+e.length,r[1]),post:a.slice(r[1]+t.length)}}function maybeMatch(e,t){var a=t.match(e);return a?a[0]:null}balanced.range=range;function range(e,t,a){var r,i,n,s,o;var p=a.indexOf(e);var l=a.indexOf(t,p+1);var d=p;if(p>=0&&l>0){if(e===t){return[p,l]}r=[];n=a.length;while(d>=0&&!o){if(d==p){r.push(d);p=a.indexOf(e,d+1)}else if(r.length==1){o=[r.pop(),l]}else{i=r.pop();if(i=0?p:l}if(r.length){o=[n,s]}}return o}},3682:(e,t,a)=>{var r=a(4670);var i=a(5549);var n=a(6819);var s=Function.bind;var o=s.bind(s);function bindApi(e,t,a){var r=o(n,null).apply(null,a?[t,a]:[t]);e.api={remove:r};e.remove=r;["before","error","after","wrap"].forEach((function(r){var n=a?[t,r,a]:[t,r];e[r]=e.api[r]=o(i,null).apply(null,n)}))}function HookSingular(){var e="h";var t={registry:{}};var a=r.bind(null,t,e);bindApi(a,t,e);return a}function HookCollection(){var e={registry:{}};var t=r.bind(null,e);bindApi(t,e);return t}var p=false;function Hook(){if(!p){console.warn('[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4');p=true}return HookCollection()}Hook.Singular=HookSingular.bind();Hook.Collection=HookCollection.bind();e.exports=Hook;e.exports.Hook=Hook;e.exports.Singular=Hook.Singular;e.exports.Collection=Hook.Collection},5549:e=>{e.exports=addHook;function addHook(e,t,a,r){var i=r;if(!e.registry[a]){e.registry[a]=[]}if(t==="before"){r=function(e,t){return Promise.resolve().then(i.bind(null,t)).then(e.bind(null,t))}}if(t==="after"){r=function(e,t){var a;return Promise.resolve().then(e.bind(null,t)).then((function(e){a=e;return i(a,t)})).then((function(){return a}))}}if(t==="error"){r=function(e,t){return Promise.resolve().then(e.bind(null,t)).catch((function(e){return i(e,t)}))}}e.registry[a].push({hook:r,orig:i})}},4670:e=>{e.exports=register;function register(e,t,a,r){if(typeof a!=="function"){throw new Error("method for before hook must be a function")}if(!r){r={}}if(Array.isArray(t)){return t.reverse().reduce((function(t,a){return register.bind(null,e,a,t,r)}),a)()}return Promise.resolve().then((function(){if(!e.registry[t]){return a(r)}return e.registry[t].reduce((function(e,t){return t.hook.bind(null,e,r)}),a)()}))}},6819:e=>{e.exports=removeHook;function removeHook(e,t,a){if(!e.registry[t]){return}var r=e.registry[t].map((function(e){return e.orig})).indexOf(a);if(r===-1){return}e.registry[t].splice(r,1)}},3717:(e,t,a)=>{var r=a(6891);var i=a(9417);e.exports=expandTop;var n="\0SLASH"+Math.random()+"\0";var s="\0OPEN"+Math.random()+"\0";var o="\0CLOSE"+Math.random()+"\0";var p="\0COMMA"+Math.random()+"\0";var l="\0PERIOD"+Math.random()+"\0";function numeric(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function escapeBraces(e){return e.split("\\\\").join(n).split("\\{").join(s).split("\\}").join(o).split("\\,").join(p).split("\\.").join(l)}function unescapeBraces(e){return e.split(n).join("\\").split(s).join("{").split(o).join("}").split(p).join(",").split(l).join(".")}function parseCommaParts(e){if(!e)return[""];var t=[];var a=i("{","}",e);if(!a)return e.split(",");var r=a.pre;var n=a.body;var s=a.post;var o=r.split(",");o[o.length-1]+="{"+n+"}";var p=parseCommaParts(s);if(s.length){o[o.length-1]+=p.shift();o.push.apply(o,p)}t.push.apply(t,o);return t}function expandTop(e){if(!e)return[];if(e.substr(0,2)==="{}"){e="\\{\\}"+e.substr(2)}return expand(escapeBraces(e),true).map(unescapeBraces)}function identity(e){return e}function embrace(e){return"{"+e+"}"}function isPadded(e){return/^-?0\d/.test(e)}function lte(e,t){return e<=t}function gte(e,t){return e>=t}function expand(e,t){var a=[];var n=i("{","}",e);if(!n||/\$$/.test(n.pre))return[e];var s=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(n.body);var p=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(n.body);var l=s||p;var d=n.body.indexOf(",")>=0;if(!l&&!d){if(n.post.match(/,.*\}/)){e=n.pre+"{"+n.body+o+n.post;return expand(e)}return[e]}var c;if(l){c=n.body.split(/\.\./)}else{c=parseCommaParts(n.body);if(c.length===1){c=expand(c[0],false).map(embrace);if(c.length===1){var m=n.post.length?expand(n.post,false):[""];return m.map((function(e){return n.pre+c[0]+e}))}}}var u=n.pre;var m=n.post.length?expand(n.post,false):[""];var h;if(l){var g=numeric(c[0]);var y=numeric(c[1]);var v=Math.max(c[0].length,c[1].length);var b=c.length==3?Math.abs(numeric(c[2])):1;var x=lte;var w=y0){var _=new Array(E+1).join("0");if(N<0)T="-"+_+T.slice(1);else T=_+T}}}h.push(T)}}else{h=r(c,(function(e){return expand(e,false)}))}for(var P=0;P{var r=a(3837);var i=a(2781).Stream;var n=a(8611);e.exports=CombinedStream;function CombinedStream(){this.writable=false;this.readable=true;this.dataSize=0;this.maxDataSize=2*1024*1024;this.pauseStreams=true;this._released=false;this._streams=[];this._currentStream=null;this._insideLoop=false;this._pendingNext=false}r.inherits(CombinedStream,i);CombinedStream.create=function(e){var t=new this;e=e||{};for(var a in e){t[a]=e[a]}return t};CombinedStream.isStreamLike=function(e){return typeof e!=="function"&&typeof e!=="string"&&typeof e!=="boolean"&&typeof e!=="number"&&!Buffer.isBuffer(e)};CombinedStream.prototype.append=function(e){var t=CombinedStream.isStreamLike(e);if(t){if(!(e instanceof n)){var a=n.create(e,{maxDataSize:Infinity,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this));e=a}this._handleErrors(e);if(this.pauseStreams){e.pause()}}this._streams.push(e);return this};CombinedStream.prototype.pipe=function(e,t){i.prototype.pipe.call(this,e,t);this.resume();return e};CombinedStream.prototype._getNext=function(){this._currentStream=null;if(this._insideLoop){this._pendingNext=true;return}this._insideLoop=true;try{do{this._pendingNext=false;this._realGetNext()}while(this._pendingNext)}finally{this._insideLoop=false}};CombinedStream.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e=="undefined"){this.end();return}if(typeof e!=="function"){this._pipeNext(e);return}var t=e;t(function(e){var t=CombinedStream.isStreamLike(e);if(t){e.on("data",this._checkDataSize.bind(this));this._handleErrors(e)}this._pipeNext(e)}.bind(this))};CombinedStream.prototype._pipeNext=function(e){this._currentStream=e;var t=CombinedStream.isStreamLike(e);if(t){e.on("end",this._getNext.bind(this));e.pipe(this,{end:false});return}var a=e;this.write(a);this._getNext()};CombinedStream.prototype._handleErrors=function(e){var t=this;e.on("error",(function(e){t._emitError(e)}))};CombinedStream.prototype.write=function(e){this.emit("data",e)};CombinedStream.prototype.pause=function(){if(!this.pauseStreams){return}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function")this._currentStream.pause();this.emit("pause")};CombinedStream.prototype.resume=function(){if(!this._released){this._released=true;this.writable=true;this._getNext()}if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function")this._currentStream.resume();this.emit("resume")};CombinedStream.prototype.end=function(){this._reset();this.emit("end")};CombinedStream.prototype.destroy=function(){this._reset();this.emit("close")};CombinedStream.prototype._reset=function(){this.writable=false;this._streams=[];this._currentStream=null};CombinedStream.prototype._checkDataSize=function(){this._updateDataSize();if(this.dataSize<=this.maxDataSize){return}var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))};CombinedStream.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach((function(t){if(!t.dataSize){return}e.dataSize+=t.dataSize}));if(this._currentStream&&this._currentStream.dataSize){this.dataSize+=this._currentStream.dataSize}};CombinedStream.prototype._emitError=function(e){this._reset();this.emit("error",e)}},6891:e=>{e.exports=function(e,a){var r=[];for(var i=0;i{var r=a(2781).Stream;var i=a(3837);e.exports=DelayedStream;function DelayedStream(){this.source=null;this.dataSize=0;this.maxDataSize=1024*1024;this.pauseStream=true;this._maxDataSizeExceeded=false;this._released=false;this._bufferedEvents=[]}i.inherits(DelayedStream,r);DelayedStream.create=function(e,t){var a=new this;t=t||{};for(var r in t){a[r]=t[r]}a.source=e;var i=e.emit;e.emit=function(){a._handleEmit(arguments);return i.apply(e,arguments)};e.on("error",(function(){}));if(a.pauseStream){e.pause()}return a};Object.defineProperty(DelayedStream.prototype,"readable",{configurable:true,enumerable:true,get:function(){return this.source.readable}});DelayedStream.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};DelayedStream.prototype.resume=function(){if(!this._released){this.release()}this.source.resume()};DelayedStream.prototype.pause=function(){this.source.pause()};DelayedStream.prototype.release=function(){this._released=true;this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this));this._bufferedEvents=[]};DelayedStream.prototype.pipe=function(){var e=r.prototype.pipe.apply(this,arguments);this.resume();return e};DelayedStream.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}if(e[0]==="data"){this.dataSize+=e[1].length;this._checkIfMaxDataSizeExceeded()}this._bufferedEvents.push(e)};DelayedStream.prototype._checkIfMaxDataSizeExceeded=function(){if(this._maxDataSizeExceeded){return}if(this.dataSize<=this.maxDataSize){return}this._maxDataSizeExceeded=true;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}},8932:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});class Deprecation extends Error{constructor(e){super(e);if(Error.captureStackTrace){Error.captureStackTrace(this,this.constructor)}this.name="Deprecation"}}t.Deprecation=Deprecation},3287:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true}); /*! * is-plain-object * diff --git a/src/cache.ts b/src/cache.ts index d85025e..98ea882 100644 --- a/src/cache.ts +++ b/src/cache.ts @@ -22,7 +22,9 @@ export const pleaseRestore = async () => { return; } await restoreCache([path], key).then(r => { - console.log(`successfully restored cache: ${JSON.stringify(r)}`); + if (!r) { + console.log(`no cache matching "${path}" to restore`); + } }); }; diff --git a/src/post_run.ts b/src/post_run.ts index 9aaf7ab..648ec8b 100644 --- a/src/post_run.ts +++ b/src/post_run.ts @@ -4,8 +4,12 @@ import {show_stats} from './show_stats'; const postRun = async () => { await show_stats(); - await deduplicate(); - await pleaseSave(); + + const is_local = core.getInput('local', {required: false}); + if (is_local == 'true') { + await deduplicate(); + await pleaseSave(); + } }; postRun().catch(err => { diff --git a/src/setup.ts b/src/setup.ts index cc779e1..5f848b8 100644 --- a/src/setup.ts +++ b/src/setup.ts @@ -99,37 +99,39 @@ async function setup() { process.env.ACTIONS_RUNTIME_TOKEN || '' ); - // TODO: get this the right way - let myOutput = ''; - let myError = ''; - - const options: ExecOptions = {}; - options.listeners = { - stdout: (data: Buffer) => { - myOutput += data.toString(); - }, - stderr: (data: Buffer) => { - myError += data.toString(); - } - }; - - await exec( - `${sccacheHome}/sccache`, - ['--show-stats', '--stats-format', 'json'], - options - ).catch(e => { - console.log(`exec error: ${e}`); - console.log(myError); - }); - const json = JSON.parse(myOutput); - console.log(`\n${json.cache_location}`); - let cache_path = json.cache_location.split(':')[1].trim().slice(1, -1); - - core.exportVariable('SCCACHE_CACHE_DIR', cache_path); - - await pleaseRestore(); - - core.exportVariable('RUSTC_WRAPPER', `sccache`); + const is_local = core.getInput('local', {required: false}); + + if (is_local == 'true') { + let myOutput = ''; + let myError = ''; + + const options: ExecOptions = {}; + options.listeners = { + stdout: (data: Buffer) => { + myOutput += data.toString(); + }, + stderr: (data: Buffer) => { + myError += data.toString(); + } + }; + + await exec( + `${sccacheHome}/sccache`, + ['--show-stats', '--stats-format', 'json'], + options + ).catch(e => { + console.log(`exec error: ${e}`); + console.log(myError); + }); + const json = JSON.parse(myOutput); + console.log(`\n${json.cache_location}`); + let cache_path = json.cache_location.split(':')[1].trim().slice(1, -1); + + core.exportVariable('SCCACHE_CACHE_DIR', cache_path); + + await pleaseRestore(); + core.exportVariable('RUSTC_WRAPPER', `sccache`); + } } function getFilename(version: string): Error | string {