@aurigma/ng-design-atoms-api-client 2.80.12 → 2.82.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/aurigma-ng-design-atoms-api-client.metadata.json +1 -1
- package/bundles/aurigma-ng-design-atoms-api-client.umd.js +298 -195
- package/bundles/aurigma-ng-design-atoms-api-client.umd.js.map +1 -1
- package/bundles/aurigma-ng-design-atoms-api-client.umd.min.js +1 -1
- package/bundles/aurigma-ng-design-atoms-api-client.umd.min.js.map +1 -1
- package/esm2015/aurigma-ng-design-atoms-api-client.js +1 -1
- package/esm2015/lib/design-atoms-api-client.js +91 -1
- package/esm2015/lib/design-atoms-api.module.js +1 -1
- package/esm2015/public-api.js +1 -1
- package/fesm2015/aurigma-ng-design-atoms-api-client.js +90 -0
- package/fesm2015/aurigma-ng-design-atoms-api-client.js.map +1 -1
- package/lib/design-atoms-api-client.d.ts +46 -0
- package/package.json +1 -1
|
@@ -12,5 +12,5 @@
|
|
|
12
12
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
13
13
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
14
14
|
PERFORMANCE OF THIS SOFTWARE.
|
|
15
|
-
***************************************************************************** */var a=function(e,r){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,r){e.__proto__=r}||function(e,r){for(var t in r)Object.prototype.hasOwnProperty.call(r,t)&&(e[t]=r[t])})(e,r)};function p(e,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function t(){this.constructor=e}a(e,r),e.prototype=null===r?Object.create(r):(t.prototype=r.prototype,new t)}function s(e,r,t,n){return new(t||(t=Promise))((function(o,a){function p(e){try{i(n.next(e))}catch(e){a(e)}}function s(e){try{i(n.throw(e))}catch(e){a(e)}}function i(e){var r;e.done?o(e.value):(r=e.value,r instanceof t?r:new t((function(e){e(r)}))).then(p,s)}i((n=n.apply(e,r||[])).next())}))}function i(e,r){var t,n,o,a,p={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(a){return function(s){return function(a){if(t)throw new TypeError("Generator is already executing.");for(;p;)try{if(t=1,n&&(o=2&a[0]?n.return:a[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,a[1])).done)return o;switch(n=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return p.label++,{value:a[1],done:!1};case 5:p.label++,n=a[1],a=[0];continue;case 7:a=p.ops.pop(),p.trys.pop();continue;default:if(!(o=p.trys,(o=o.length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){p=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){p.label=a[1];break}if(6===a[0]&&p.label<o[1]){p.label=o[1],o=a;break}if(o&&p.label<o[2]){p.label=o[2],p.ops.push(a);break}o[2]&&p.ops.pop(),p.trys.pop();continue}a=r.call(e,p)}catch(e){a=[6,e],n=0}finally{t=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,s])}}}Object.create;function u(e){var r="function"==typeof Symbol&&Symbol.iterator,t=r&&e[r],n=0;if(t)return t.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(r?"Object is not iterable.":"Symbol.iterator is not defined.")}Object.create;var c=new r.InjectionToken("API_BASE_URL"),l=function(){function e(){this.apiUrl="http://localhost:54220",this.apiKey="ApiKey",this.authorizationToken=null}return e.prototype.getAuthorizationToken=function(){return s(this,void 0,void 0,(function(){return i(this,(function(e){return[2,this.authorizationToken]}))}))},e.prototype.setAuthorizationToken=function(e){this.authorizationToken=e},e}(),f=function(){function e(e){this.configuration=e}return e.prototype.transformOptions=function(e){return s(this,void 0,void 0,(function(){var r;return i(this,(function(t){switch(t.label){case 0:return[4,this.configuration.getAuthorizationToken()];case 1:return r=t.sent(),e.headers=null!=r?e.headers.append("authorization","Bearer "+r):e.headers.append("X-API-Key",this.configuration.apiKey),[2,e]}}))}))},e.prototype.getBaseUrl=function(e){return this.configuration.apiUrl.endsWith("/")?this.configuration.apiUrl.slice(0,-1):this.configuration.apiUrl},e.prototype.transformResult=function(e,r,t){return t(r)},e}(),d=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.headInfo=function(){var e=this,r=this.baseUrl+"/api/atoms/v1/info";r=r.replace(/[?&]$/,"");var a={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(a)).pipe(t.mergeMap((function(t){return e.http.request("head",r,t)}))).pipe(t.mergeMap((function(t){return e.transformResult(r,t,(function(r){return e.processHeadInfo(r)}))}))).pipe(t.catchError((function(t){if(!(t instanceof o.HttpResponseBase))return n.throwError(t);try{return e.transformResult(r,t,(function(r){return e.processHeadInfo(r)}))}catch(e){return n.throwError(e)}})))},r.prototype.processHeadInfo=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}return 200===p?_(s).pipe(t.mergeMap((function(e){return n.of(null)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.getInfo=function(){var e=this,r=this.baseUrl+"/api/atoms/v1/info";r=r.replace(/[?&]$/,"");var a={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(a)).pipe(t.mergeMap((function(t){return e.http.request("get",r,t)}))).pipe(t.mergeMap((function(t){return e.transformResult(r,t,(function(r){return e.processGetInfo(r)}))}))).pipe(t.catchError((function(t){if(!(t instanceof o.HttpResponseBase))return n.throwError(t);try{return e.transformResult(r,t,(function(r){return e.processGetInfo(r)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetInfo=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);d.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new d(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:d,providedIn:"root"}),d.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],d.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var m=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.cssFonts=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/cssfonts";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"text/css"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processCssFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processCssFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCssFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.fonts=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/fonts/{psName}";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");if(p=p.replace("{tenantId}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'psName' must be defined.");p=(p=p.replace("{psName}",encodeURIComponent(""+r))).replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getColorPreview=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetColorPreview";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetColorPreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetColorPreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetColorPreview=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getColorPreviews=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetColorPreviews";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetColorPreviews(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetColorPreviews(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetColorPreviews=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getCssFont=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetCssFont?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=p.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(p+="fontKey="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetCssFont(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetCssFont(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetCssFont=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getFallbackFonts=function(e){var r=this,a=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetFallbackFonts";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");a=(a=a.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var p={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(p)).pipe(t.mergeMap((function(e){return r.http.request("get",a,e)}))).pipe(t.mergeMap((function(e){return r.transformResult(a,e,(function(e){return r.processGetFallbackFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return r.transformResult(a,e,(function(e){return r.processGetFallbackFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetFallbackFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getImageSize=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetImageSize";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetImageSize(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetImageSize(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetImageSize=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getShapeBounds=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetShapeBounds";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetShapeBounds(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetShapeBounds(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetShapeBounds=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getWatermarkItems=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetWatermarkItems";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetWatermarkItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetWatermarkItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetWatermarkItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.img=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y,R,b,w,I,M){var U=this,C=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/img?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");C=C.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(C+="f="+encodeURIComponent(""+r)+"&"),null!=a&&(C+="w="+encodeURIComponent(""+a)+"&"),null!=p&&(C+="h="+encodeURIComponent(""+p)+"&"),null!=s&&(C+="cmyk="+encodeURIComponent(""+s)+"&"),null!=i&&(C+="rgb="+encodeURIComponent(""+i)+"&"),null!=u&&(C+="grayscale="+encodeURIComponent(""+u)+"&"),null!=c&&(C+="target="+encodeURIComponent(""+c)+"&"),null!=l&&(C+="sq="+encodeURIComponent(""+l)+"&"),null!=f&&(C+="effect="+encodeURIComponent(""+f)+"&"),null!=d&&(C+="kp="+encodeURIComponent(""+d)+"&"),null!=m&&(C+="color="+encodeURIComponent(""+m)+"&"),null!=h&&(C+="obm="+encodeURIComponent(""+h)+"&"),null!=v&&(C+="oo="+encodeURIComponent(""+v)+"&"),null!=g&&(C+="alphaMask="+encodeURIComponent(""+g)+"&"),null!=y&&(C+="page="+encodeURIComponent(""+y)+"&"),null!=R&&(C+="colorizeColor="+encodeURIComponent(""+R)+"&"),null!=b&&(C+="rw="+encodeURIComponent(""+b)+"&"),null!=w&&(C+="rh="+encodeURIComponent(""+w)+"&"),null!=I&&(C+="dt="+encodeURIComponent(""+I)+"&"),null!=M&&(C+="da="+encodeURIComponent(""+M)+"&"),C=C.replace(/[?&]$/,"");var H={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(H)).pipe(t.mergeMap((function(e){return U.http.request("get",C,e)}))).pipe(t.mergeMap((function(e){return U.transformResult(C,e,(function(e){return U.processImg(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return U.transformResult(C,e,(function(e){return U.processImg(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processImg=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getLicense=function(e){var r=this,a=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/license";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");a=(a=a.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var p={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(p)).pipe(t.mergeMap((function(e){return r.http.request("get",a,e)}))).pipe(t.mergeMap((function(e){return r.transformResult(a,e,(function(e){return r.processGetLicense(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return r.transformResult(a,e,(function(e){return r.processGetLicense(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetLicense=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.pth=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/pth?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=p.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(p+="f="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processPth(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processPth(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processPth=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.resource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/resource?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=p.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(p+="image="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.svg=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y,R,b,w,I,M){var U=this,C=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/svg?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");C=C.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(C+="f="+encodeURIComponent(""+r)+"&"),null!=a&&(C+="w="+encodeURIComponent(""+a)+"&"),null!=p&&(C+="h="+encodeURIComponent(""+p)+"&"),null!=s&&(C+="cmyk="+encodeURIComponent(""+s)+"&"),null!=i&&(C+="rgb="+encodeURIComponent(""+i)+"&"),null!=u&&(C+="grayscale="+encodeURIComponent(""+u)+"&"),null!=c&&(C+="target="+encodeURIComponent(""+c)+"&"),null!=l&&(C+="sq="+encodeURIComponent(""+l)+"&"),null!=f&&(C+="effect="+encodeURIComponent(""+f)+"&"),null!=d&&(C+="kp="+encodeURIComponent(""+d)+"&"),null!=m&&(C+="color="+encodeURIComponent(""+m)+"&"),null!=h&&(C+="obm="+encodeURIComponent(""+h)+"&"),null!=v&&(C+="oo="+encodeURIComponent(""+v)+"&"),null!=g&&(C+="alphaMask="+encodeURIComponent(""+g)+"&"),null!=y&&(C+="page="+encodeURIComponent(""+y)+"&"),null!=R&&(C+="colorizeColor="+encodeURIComponent(""+R)+"&"),null!=b&&(C+="rw="+encodeURIComponent(""+b)+"&"),null!=w&&(C+="rh="+encodeURIComponent(""+w)+"&"),null!=I&&(C+="dt="+encodeURIComponent(""+I)+"&"),null!=M&&(C+="da="+encodeURIComponent(""+M)+"&"),C=C.replace(/[?&]$/,"");var H={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(H)).pipe(t.mergeMap((function(e){return U.http.request("get",C,e)}))).pipe(t.mergeMap((function(e){return U.transformResult(C,e,(function(e){return U.processSvg(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return U.transformResult(C,e,(function(e){return U.processSvg(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSvg=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.txt=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/txt?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=p.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(p+="f="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processTxt(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processTxt(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processTxt=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateArchedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateArchedTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateArchedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateArchedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateArchedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateAutoScaledTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateAutoScaledTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateAutoScaledTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateAutoScaledTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateAutoScaledTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateBarcodeItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateBarcodeItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateBarcodeItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateBarcodeItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateBarcodeItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateBoundedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateBoundedTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateBoundedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateBoundedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateBoundedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateByColorData=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateByColorData";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateByColorData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateByColorData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateByColorData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateByMultiCallRequest=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateByMultiCallRequest";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateByMultiCallRequest(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateByMultiCallRequest(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateByMultiCallRequest=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateCurvedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateCurvedTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateCurvedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateCurvedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateCurvedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateImageItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateImageItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateImageItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateImageItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateImageItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updatePathBoundedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdatePathBoundedTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdatePathBoundedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdatePathBoundedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdatePathBoundedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updatePlainTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdatePlainTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdatePlainTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdatePlainTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdatePlainTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateShapeItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateShapeItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateShapeItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateShapeItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateShapeItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);m.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new m(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:m,providedIn:"root"}),m.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],m.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var h=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.renderImagePreview=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/images/render-preview?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderImagePreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderImagePreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreview=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewFromFile=function(e,r,a,p,s,i,u,c,l,f){var d=this,m=this.baseUrl+"/api/atoms/v1/images/render-preview/from-file?";if(null!=e&&(m+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(m+="tenantId="+encodeURIComponent(""+r)+"&"),m=m.replace(/[?&]$/,"");var h=new FormData;null!=a&&h.append("sourceFile",a.data,a.fileName?a.fileName:"sourceFile"),null!=p&&h.append("mockupOwnerId",p.toString()),null!=s&&h.append("mockupId",s.toString()),null!=i&&h.append("width",i.toString()),null!=u&&h.append("height",u.toString()),null!=c&&h.append("fileFormat",c.toString()),null!=l&&h.append("fitMode",l.toString()),null!=f&&h.append("pageIndex",f.toString());var v={body:h,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(v)).pipe(t.mergeMap((function(e){return d.http.request("post",m,e)}))).pipe(t.mergeMap((function(e){return d.transformResult(m,e,(function(e){return d.processRenderImagePreviewFromFile(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return d.transformResult(m,e,(function(e){return d.processRenderImagePreviewFromFile(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewFromFile=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewFromFileToResource=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y){var R=this,b=this.baseUrl+"/api/atoms/v1/images/render-preview/from-file/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(b+="tenantId="+encodeURIComponent(""+e)+"&"),b=b.replace(/[?&]$/,"");var w=new FormData;null!=r&&w.append("resourceOwnerId",r.toString()),null!=a&&w.append("resourceNamespace",a.toString()),null!=p&&w.append("resourceName",p.toString()),null!=s&&w.append("resourceSourceId",s.toString()),null!=i&&w.append("resourceType",i.toString()),null!=u&&w.append("anonymousAccess",u.toString()),null!=c&&w.append("overwriteExistingResource",c.toString()),null!=l&&w.append("sourceFile",l.data,l.fileName?l.fileName:"sourceFile"),null!=f&&w.append("mockupOwnerId",f.toString()),null!=d&&w.append("mockupId",d.toString()),null!=m&&w.append("width",m.toString()),null!=h&&w.append("height",h.toString()),null!=v&&w.append("fileFormat",v.toString()),null!=g&&w.append("fitMode",g.toString()),null!=y&&w.append("pageIndex",y.toString());var I={body:w,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(I)).pipe(t.mergeMap((function(e){return R.http.request("post",b,e)}))).pipe(t.mergeMap((function(e){return R.transformResult(b,e,(function(e){return R.processRenderImagePreviewFromFileToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return R.transformResult(b,e,(function(e){return R.processRenderImagePreviewFromFileToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewFromFileToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewFromUrl=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/images/render-preview/from-url?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderImagePreviewFromUrl(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderImagePreviewFromUrl(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewFromUrl=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewFromUrlToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/images/render-preview/from-url/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processRenderImagePreviewFromUrlToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processRenderImagePreviewFromUrlToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewFromUrlToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/images/render-preview/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processRenderImagePreviewToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processRenderImagePreviewToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);h.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new h(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:h,providedIn:"root"}),h.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],h.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var v=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.renderMockupPreview=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/mockups-2d/render-preview?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderMockupPreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderMockupPreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderMockupPreview=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);v.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new v(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:v,providedIn:"root"}),v.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],v.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var g=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.getAttributes=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/mockups-3d/{id}/attributes?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="ownerId="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetAttributes(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetAttributes(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetAttributes=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getContentAsProtobuf=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/mockups-3d/{id}/content/as-protobuf?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="ownerId="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetContentAsProtobuf(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetContentAsProtobuf(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetContentAsProtobuf=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getGeometryFile=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/mockups-3d/{id}/geometry/file?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="ownerId="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetGeometryFile(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetGeometryFile(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetGeometryFile=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);g.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new g(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:g,providedIn:"root"}),g.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],g.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var y=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.findPaletteColor=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/palettes/find-color?";if(null!=e&&(s+="paletteUID="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processFindPaletteColor(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processFindPaletteColor(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFindPaletteColor=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getPaletteModel=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/palettes/model?";if(null!=e&&(s+="id="+encodeURIComponent(""+e)+"&"),null!=r&&(s+="uid="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetPaletteModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetPaletteModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetPaletteModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);y.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new y(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:y,providedIn:"root"}),y.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],y.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var R=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.patchDesignProduct=function(e,r,a,p,s,i,u,c,l){var f=this,d=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(d=d.replace("{id}",encodeURIComponent(""+e)),null!=r&&(d+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(d+="tenantId="+encodeURIComponent(""+a)+"&"),d=d.replace(/[?&]$/,"");var m=new FormData;null!=p&&m.append("patchType",p.toString()),null!=s&&m.append("replaceImageItemFileInfo.itemName",s.toString()),null!=i&&m.append("replaceImageItemFileInfo.sourceFile",i.data,i.fileName?i.fileName:"replaceImageItemFileInfo.sourceFile"),null!=u&&m.append("replacePlaceholderItemContentInfo.placeholderItemName",u.toString()),null!=c&&m.append("replacePlaceholderItemContentInfo.newContentType",c.toString()),null!=l&&m.append("replacePlaceholderItemContentInfo.sourceFile",l.data,l.fileName?l.fileName:"replacePlaceholderItemContentInfo.sourceFile");var h={body:m,observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(h)).pipe(t.mergeMap((function(e){return f.http.request("patch",d,e)}))).pipe(t.mergeMap((function(e){return f.transformResult(d,e,(function(e){return f.processPatchDesignProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return f.transformResult(d,e,(function(e){return f.processPatchDesignProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processPatchDesignProduct=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceContainers=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainers(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainers(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceContainers=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignSurfaceContainer=function(e,r,a,p,s,i){var u=this,c=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(c=c.replace("{id}",encodeURIComponent(""+e)),null!=r&&(c+="index="+encodeURIComponent(""+r)+"&"),null!=a&&(c+="surfaceId="+encodeURIComponent(""+a)+"&"),null!=p&&(c+="privateStorageOwner="+encodeURIComponent(""+p)+"&"),null===s)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==s&&(c+="tenantId="+encodeURIComponent(""+s)+"&"),c=c.replace(/[?&]$/,"");var l={body:JSON.stringify(i),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(l)).pipe(t.mergeMap((function(e){return u.http.request("post",c,e)}))).pipe(t.mergeMap((function(e){return u.transformResult(c,e,(function(e){return u.processAddDesignSurfaceContainer(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return u.transformResult(c,e,(function(e){return u.processAddDesignSurfaceContainer(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignSurfaceContainer=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceContainer=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(i=i.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainer(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainer(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceContainer=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceContainer=function(e,r,a,p,s,i){var u=this,c=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(c=c.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(c=c.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(c+="surfaceId="+encodeURIComponent(""+a)+"&"),null!=p&&(c+="privateStorageOwner="+encodeURIComponent(""+p)+"&"),null===s)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==s&&(c+="tenantId="+encodeURIComponent(""+s)+"&"),c=c.replace(/[?&]$/,"");var l={body:JSON.stringify(i),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(l)).pipe(t.mergeMap((function(e){return u.http.request("put",c,e)}))).pipe(t.mergeMap((function(e){return u.transformResult(c,e,(function(e){return u.processUpdateDesignSurfaceContainer(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return u.transformResult(c,e,(function(e){return u.processUpdateDesignSurfaceContainer(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceContainer=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteDesignSurfaceContainer=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(i=i.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("delete",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurfaceContainer(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurfaceContainer(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteDesignSurfaceContainer=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceContainerModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(i=i.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainerModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainerModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceContainerModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceContainerModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(u=u.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processUpdateDesignSurfaceContainerModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processUpdateDesignSurfaceContainerModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceContainerModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignSurfaceContainerModel=function(e,r,a,p,s,i,u,c){var l=this,f=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(f=f.replace("{id}",encodeURIComponent(""+e)),null!=r&&(f+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(f+="index="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'top' cannot be null.");if(void 0!==p&&(f+="top="+encodeURIComponent(""+p)+"&"),null===s)throw new Error("The parameter 'left' cannot be null.");if(void 0!==s&&(f+="left="+encodeURIComponent(""+s)+"&"),null!=i&&(f+="privateStorageOwner="+encodeURIComponent(""+i)+"&"),null===u)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==u&&(f+="tenantId="+encodeURIComponent(""+u)+"&"),f=f.replace(/[?&]$/,"");var d={body:JSON.stringify(c),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(d)).pipe(t.mergeMap((function(e){return l.http.request("post",f,e)}))).pipe(t.mergeMap((function(e){return l.transformResult(f,e,(function(e){return l.processAddDesignSurfaceContainerModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return l.transformResult(f,e,(function(e){return l.processAddDesignSurfaceContainerModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignSurfaceContainerModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceItems=function(e,r,a,p,s,i){var u=this,c=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(c=c.replace("{id}",encodeURIComponent(""+e)),null!=r&&(c+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(c+="containerId="+encodeURIComponent(""+a)+"&"),null!=p&&(c+="parentItemId="+encodeURIComponent(""+p)+"&"),null!=s&&(c+="privateStorageOwner="+encodeURIComponent(""+s)+"&"),null===i)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==i&&(c+="tenantId="+encodeURIComponent(""+i)+"&"),c=c.replace(/[?&]$/,"");var l={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(l)).pipe(t.mergeMap((function(e){return u.http.request("get",c,e)}))).pipe(t.mergeMap((function(e){return u.transformResult(c,e,(function(e){return u.processGetDesignSurfaceItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return u.transformResult(c,e,(function(e){return u.processGetDesignSurfaceItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteDesignSurfaceItem=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items/{itemId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'itemId' must be defined.");if(i=i.replace("{itemId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("delete",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurfaceItem(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurfaceItem(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteDesignSurfaceItem=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceItemModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items/{itemId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'itemId' must be defined.");if(i=i.replace("{itemId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceItemModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceItemModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceItemModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceItemModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items/{itemId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'itemId' must be defined.");if(u=u.replace("{itemId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processUpdateDesignSurfaceItemModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processUpdateDesignSurfaceItemModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceItemModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignSurfaceItemModel=function(e,r,a,p,s,i,u,c){var l=this,f=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(f=f.replace("{id}",encodeURIComponent(""+e)),null!=r&&(f+="containerId="+encodeURIComponent(""+r)+"&"),null!=a&&(f+="index="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'top' cannot be null.");if(void 0!==p&&(f+="top="+encodeURIComponent(""+p)+"&"),null===s)throw new Error("The parameter 'left' cannot be null.");if(void 0!==s&&(f+="left="+encodeURIComponent(""+s)+"&"),null!=i&&(f+="privateStorageOwner="+encodeURIComponent(""+i)+"&"),null===u)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==u&&(f+="tenantId="+encodeURIComponent(""+u)+"&"),f=f.replace(/[?&]$/,"");var d={body:JSON.stringify(c),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(d)).pipe(t.mergeMap((function(e){return l.http.request("post",f,e)}))).pipe(t.mergeMap((function(e){return l.transformResult(f,e,(function(e){return l.processAddDesignSurfaceItemModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return l.transformResult(f,e,(function(e){return l.processAddDesignSurfaceItemModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignSurfaceItemModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignProductModel=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetDesignProductModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetDesignProductModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignProductModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignProductModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processUpdateDesignProductModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processUpdateDesignProductModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignProductModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignPrintAreas=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignPrintAreas(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignPrintAreas(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignPrintAreas=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignPrintArea=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("post",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processAddDesignPrintArea(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processAddDesignPrintArea(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignPrintArea=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignPrintArea=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/{printAreaId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'printAreaId' must be defined.");if(u=u.replace("{printAreaId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processUpdateDesignPrintArea(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processUpdateDesignPrintArea(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignPrintArea=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteDesignPrintArea=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/{printAreaId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'printAreaId' must be defined.");if(i=i.replace("{printAreaId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("delete",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processDeleteDesignPrintArea(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processDeleteDesignPrintArea(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteDesignPrintArea=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignPrintAreaModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/{printAreaId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'printAreaId' must be defined.");if(i=i.replace("{printAreaId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignPrintAreaModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignPrintAreaModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignPrintAreaModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignPrintAreaModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/{printAreaId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'printAreaId' must be defined.");if(u=u.replace("{printAreaId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processUpdateDesignPrintAreaModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processUpdateDesignPrintAreaModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignPrintAreaModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignPrintAreaModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null!=r&&(u+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("post",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processAddDesignPrintAreaModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processAddDesignPrintAreaModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignPrintAreaModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaces=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetDesignSurfaces(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetDesignSurfaces(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaces=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteDesignSurface=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("delete",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurface(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurface(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteDesignSurface=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceDownMockup=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-down?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceDownMockup(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceDownMockup(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceDownMockup=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceDownMockup=function(e,r,a,p,s,i,u,c,l){var f=this,d=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-down?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(d=d.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(d=d.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(d+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(d+="tenantId="+encodeURIComponent(""+p)+"&"),d=d.replace(/[?&]$/,"");var m=new FormData;if(null==s)throw new Error("The parameter 'position_top' cannot be null.");if(m.append("position.top",s.toString()),null==i)throw new Error("The parameter 'position_left' cannot be null.");m.append("position.left",i.toString()),null!=u&&m.append("dpiX",u.toString()),null!=c&&m.append("dpiY",c.toString()),null!=l&&m.append("sourceFile",l.data,l.fileName?l.fileName:"sourceFile");var h={body:m,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(h)).pipe(t.mergeMap((function(e){return f.http.request("patch",d,e)}))).pipe(t.mergeMap((function(e){return f.transformResult(d,e,(function(e){return f.processUpdateDesignSurfaceDownMockup(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return f.transformResult(d,e,(function(e){return f.processUpdateDesignSurfaceDownMockup(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceDownMockup=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceDownMockupContent=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-down/file?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceDownMockupContent(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceDownMockupContent(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceDownMockupContent=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceUpMockup=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-up?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceUpMockup(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceUpMockup(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceUpMockup=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceUpMockup=function(e,r,a,p,s,i,u,c,l){var f=this,d=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-up?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(d=d.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(d=d.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(d+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(d+="tenantId="+encodeURIComponent(""+p)+"&"),d=d.replace(/[?&]$/,"");var m=new FormData;if(null==s)throw new Error("The parameter 'position_top' cannot be null.");if(m.append("position.top",s.toString()),null==i)throw new Error("The parameter 'position_left' cannot be null.");m.append("position.left",i.toString()),null!=u&&m.append("dpiX",u.toString()),null!=c&&m.append("dpiY",c.toString()),null!=l&&m.append("sourceFile",l.data,l.fileName?l.fileName:"sourceFile");var h={body:m,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(h)).pipe(t.mergeMap((function(e){return f.http.request("patch",d,e)}))).pipe(t.mergeMap((function(e){return f.transformResult(d,e,(function(e){return f.processUpdateDesignSurfaceUpMockup(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return f.transformResult(d,e,(function(e){return f.processUpdateDesignSurfaceUpMockup(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceUpMockup=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceUpMockupContent=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-up/file?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceUpMockupContent(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceUpMockupContent(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceUpMockupContent=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.replaceDesignSurfaceModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(u=u.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processReplaceDesignSurfaceModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processReplaceDesignSurfaceModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processReplaceDesignSurfaceModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignSurfaceModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null!=r&&(u+="index="+encodeURIComponent(""+r)+"&"),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("post",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processAddDesignSurfaceModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processAddDesignSurfaceModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignSurfaceModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);R.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new R(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:R,providedIn:"root"}),R.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],R.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var b=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.applyItemEffects=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/apply-effects?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processApplyItemEffects(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processApplyItemEffects(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processApplyItemEffects=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createEllipseItem=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/ellipse?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processCreateEllipseItem(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processCreateEllipseItem(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateEllipseItem=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.extractItemImage=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/extract-image?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processExtractItemImage(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processExtractItemImage(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processExtractItemImage=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.extractItemImageToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/extract-image/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processExtractItemImageToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processExtractItemImageToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processExtractItemImageToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.flattenItems=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/flatten?";if(null!=e&&(s+="paletteUID="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processFlattenItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processFlattenItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFlattenItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createItemFromFile=function(e,r,a,p,s,i){var u=this,c=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-file?";if(null!=e&&(c+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(c+="tenantId="+encodeURIComponent(""+r)+"&"),c=c.replace(/[?&]$/,"");var l=new FormData;null!=a&&l.append("sourceFile",a.data,a.fileName?a.fileName:"sourceFile"),null!=p&&l.append("paletteUID",p.toString()),null!=s&&l.append("pageIndex",s.toString()),null!=i&&l.append("preserveOriginalFile",i.toString());var f={body:l,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(f)).pipe(t.mergeMap((function(e){return u.http.request("post",c,e)}))).pipe(t.mergeMap((function(e){return u.transformResult(c,e,(function(e){return u.processCreateItemFromFile(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return u.transformResult(c,e,(function(e){return u.processCreateItemFromFile(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateItemFromFile=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.batchCreateItemsFromFile=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-file/batch-create?";if(null!=e&&(u+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(u+="tenantId="+encodeURIComponent(""+r)+"&"),u=u.replace(/[?&]$/,"");var c=new FormData;null!=a&&a.forEach((function(e){return c.append("sourceFiles",e.data,e.fileName?e.fileName:"sourceFiles")})),null!=p&&c.append("paletteUID",p.toString()),null!=s&&c.append("preserveOriginalFile",s.toString());var l={body:c,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(l)).pipe(t.mergeMap((function(e){return i.http.request("post",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processBatchCreateItemsFromFile(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processBatchCreateItemsFromFile(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processBatchCreateItemsFromFile=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createItemFromStorage=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-storage?";if(null!=e&&(s+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processCreateItemFromStorage(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processCreateItemFromStorage(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateItemFromStorage=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.batchCreateItemsFromStorage=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-storage/batch-create?";if(null!=e&&(s+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processBatchCreateItemsFromStorage(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processBatchCreateItemsFromStorage(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processBatchCreateItemsFromStorage=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createItemFromUrl=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-url?";if(null!=e&&(s+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processCreateItemFromUrl(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processCreateItemFromUrl(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateItemFromUrl=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.batchCreateItemsFromUrl=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-url/batch-create?";if(null!=e&&(s+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processBatchCreateItemsFromUrl(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processBatchCreateItemsFromUrl(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processBatchCreateItemsFromUrl=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createRectangleItem=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/rectangle?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processCreateRectangleItem(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processCreateRectangleItem(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateRectangleItem=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);b.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new b(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:b,providedIn:"root"}),b.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],b.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var w=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.createDesign=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs?";if(null!=e&&(s+="privateStorageOwner="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processCreateDesign(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processCreateDesign(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateDesign=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 201===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.applyItemsData=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/apply-items-data?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("post",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processApplyItemsData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processApplyItemsData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processApplyItemsData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.extractBackground=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/background?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="surfaceIndex="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processExtractBackground(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processExtractBackground(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processExtractBackground=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.setEditorMockups=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/editor-mockups?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processSetEditorMockups(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processSetEditorMockups(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSetEditorMockups=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignParameters=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/parameters?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetDesignParameters(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetDesignParameters(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignParameters=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadDataSchema=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/schema?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadDataSchema(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadDataSchema(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadDataSchema=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadToggleSet=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/toggle-set?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadToggleSet(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadToggleSet(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadToggleSet=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getVariables=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/variables?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetVariables(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetVariables(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetVariables=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.setVariables=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/variables?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processSetVariables(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processSetVariables(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSetVariables=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadVdpData=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/vdp-data?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadVdpData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadVdpData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadVdpData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.saveVdpData=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/vdp-data?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processSaveVdpData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processSaveVdpData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSaveVdpData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteVdpData=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/vdp-data?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("delete",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processDeleteVdpData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processDeleteVdpData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteVdpData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.convertColors=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/convert-colors?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processConvertColors(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processConvertColors(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processConvertColors=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadProductFromResource=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/from-resource/model?";if(null!=e&&(s+="id="+encodeURIComponent(""+e)+"&"),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadProductFromResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadProductFromResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadProductFromResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderProduct=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/render-proof?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderProduct=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}if(200===p||206===p){var d=e.headers?e.headers.get("content-disposition"):void 0,m=d?/filename="?([^"]*?)"?(;|$)/g.exec(d):void 0,h=m&&m.length>1?m[1]:void 0;return n.of({fileName:h,data:s,status:p,headers:i})}return 401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.renderDesignPreview=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/render-preview?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderDesignPreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderDesignPreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderDesignPreview=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}if(200===p||206===p){var d=e.headers?e.headers.get("content-disposition"):void 0,m=d?/filename="?([^"]*?)"?(;|$)/g.exec(d):void 0,h=m&&m.length>1?m[1]:void 0;return n.of({fileName:h,data:s,status:p,headers:i})}return 401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.renderDesignPreviewToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/render-preview/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processRenderDesignPreviewToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processRenderDesignPreviewToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderDesignPreviewToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderDesignProof=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/render-proof?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderDesignProof(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderDesignProof(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderDesignProof=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderDesignProofToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/render-proof/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processRenderDesignProofToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processRenderDesignProofToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderDesignProofToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadProduct=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadProduct=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.saveProduct=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processSaveProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processSaveProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSaveProduct=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.patchProduct=function(e,r,a,p,s,i,u,c,l){var f=this,d=this.baseUrl+"/api/atoms/v1/designs/{id}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(d=d.replace("{id}",encodeURIComponent(""+e)),null!=r&&(d+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(d+="tenantId="+encodeURIComponent(""+a)+"&"),d=d.replace(/[?&]$/,"");var m=new FormData;null!=p&&m.append("patchType",p.toString()),null!=s&&m.append("replaceImageItemFileInfo.itemName",s.toString()),null!=i&&m.append("replaceImageItemFileInfo.sourceFile",i.data,i.fileName?i.fileName:"replaceImageItemFileInfo.sourceFile"),null!=u&&m.append("replacePlaceholderItemContentInfo.placeholderItemName",u.toString()),null!=c&&m.append("replacePlaceholderItemContentInfo.newContentType",c.toString()),null!=l&&m.append("replacePlaceholderItemContentInfo.sourceFile",l.data,l.fileName?l.fileName:"replacePlaceholderItemContentInfo.sourceFile");var h={body:m,observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(h)).pipe(t.mergeMap((function(e){return f.http.request("patch",d,e)}))).pipe(t.mergeMap((function(e){return f.transformResult(d,e,(function(e){return f.processPatchProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return f.transformResult(d,e,(function(e){return f.processPatchProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processPatchProduct=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createItem=function(e,r,a,p,s,i,u){var c=this,l=this.baseUrl+"/api/atoms/v1/designs/model/items?";if(null!=e&&(l+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(l+="tenantId="+encodeURIComponent(""+r)+"&"),l=l.replace(/[?&]$/,"");var f=new FormData;null!=a&&f.append("sourceType",a.toString()),null!=p&&f.append("sourceId",p.toString()),null!=s&&f.append("sourceOwnerId",s.toString()),null!=i&&f.append("url",i.toString()),null!=u&&f.append("sourceFile",u.data,u.fileName?u.fileName:"sourceFile");var d={body:f,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(d)).pipe(t.mergeMap((function(e){return c.http.request("post",l,e)}))).pipe(t.mergeMap((function(e){return c.transformResult(l,e,(function(e){return c.processCreateItem(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return c.transformResult(l,e,(function(e){return c.processCreateItem(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateItem=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.extractItemImage=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/model/items/extract-image?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processExtractItemImage(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processExtractItemImage(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processExtractItemImage=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}if(200===p||206===p){var d=e.headers?e.headers.get("content-disposition"):void 0,m=d?/filename="?([^"]*?)"?(;|$)/g.exec(d):void 0,h=m&&m.length>1?m[1]:void 0;return n.of({fileName:h,data:s,status:p,headers:i})}return 401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.flattenItems=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/model/items/flatten?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processFlattenItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processFlattenItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFlattenItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createPrivateDesignFromDesign=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/private-designs/from-design?";if(null!=e&&(i+="designId="+encodeURIComponent(""+e)+"&"),null!=r&&(i+="privateDesignId="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("post",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processCreatePrivateDesignFromDesign(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processCreatePrivateDesignFromDesign(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreatePrivateDesignFromDesign=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}return 201===p?_(s).pipe(t.mergeMap((function(e){return n.of(null)}))):401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.createPrivateDesignFromResource=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/private-designs/from-resource?";if(null!=e&&(i+="resourceId="+encodeURIComponent(""+e)+"&"),null!=r&&(i+="privateDesignId="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("post",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processCreatePrivateDesignFromResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processCreatePrivateDesignFromResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreatePrivateDesignFromResource=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}return 201===p?_(s).pipe(t.mergeMap((function(e){return n.of(null)}))):401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r}(f);w.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new w(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:w,providedIn:"root"}),w.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],w.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var I,M,U,C,H,E,S,T,x,O,j,P,N,A,B,F,J,D,k,q,$,z,G=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.cssFonts=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/cssfonts?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"text/css"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processCssFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processCssFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCssFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.fonts=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/fonts/{psName}?";if(null==e)throw new Error("The parameter 'psName' must be defined.");if(p=p.replace("{psName}",encodeURIComponent(""+e)),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getColorPreview=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetColorPreview?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetColorPreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetColorPreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetColorPreview=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getColorPreviews=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetColorPreviews?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetColorPreviews(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetColorPreviews(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetColorPreviews=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getCssFont=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetCssFont?";if(null!=e&&(p+="fontKey="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetCssFont(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetCssFont(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetCssFont=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getFallbackFonts=function(e){var r=this,a=this.baseUrl+"/api/atoms/v1/ccviewer/GetFallbackFonts?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(a+="tenantId="+encodeURIComponent(""+e)+"&"),a=a.replace(/[?&]$/,"");var p={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(p)).pipe(t.mergeMap((function(e){return r.http.request("get",a,e)}))).pipe(t.mergeMap((function(e){return r.transformResult(a,e,(function(e){return r.processGetFallbackFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return r.transformResult(a,e,(function(e){return r.processGetFallbackFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetFallbackFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getImageSize=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetImageSize?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetImageSize(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetImageSize(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetImageSize=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getShapeBounds=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetShapeBounds?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetShapeBounds(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetShapeBounds(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetShapeBounds=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getWatermarkItems=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetWatermarkItems?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetWatermarkItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetWatermarkItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetWatermarkItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.img=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y,R,b,w,I,M){var U=this,C=this.baseUrl+"/api/atoms/v1/ccviewer/img?";if(null!=e&&(C+="f="+encodeURIComponent(""+e)+"&"),null!=r&&(C+="w="+encodeURIComponent(""+r)+"&"),null!=a&&(C+="h="+encodeURIComponent(""+a)+"&"),null!=p&&(C+="cmyk="+encodeURIComponent(""+p)+"&"),null!=s&&(C+="rgb="+encodeURIComponent(""+s)+"&"),null!=i&&(C+="grayscale="+encodeURIComponent(""+i)+"&"),null!=u&&(C+="target="+encodeURIComponent(""+u)+"&"),null!=c&&(C+="sq="+encodeURIComponent(""+c)+"&"),null!=l&&(C+="effect="+encodeURIComponent(""+l)+"&"),null!=f&&(C+="kp="+encodeURIComponent(""+f)+"&"),null!=d&&(C+="color="+encodeURIComponent(""+d)+"&"),null!=m&&(C+="obm="+encodeURIComponent(""+m)+"&"),null!=h&&(C+="oo="+encodeURIComponent(""+h)+"&"),null!=v&&(C+="alphaMask="+encodeURIComponent(""+v)+"&"),null!=g&&(C+="page="+encodeURIComponent(""+g)+"&"),null!=y&&(C+="colorizeColor="+encodeURIComponent(""+y)+"&"),null!=R&&(C+="rw="+encodeURIComponent(""+R)+"&"),null!=b&&(C+="rh="+encodeURIComponent(""+b)+"&"),null!=w&&(C+="dt="+encodeURIComponent(""+w)+"&"),null!=I&&(C+="da="+encodeURIComponent(""+I)+"&"),null===M)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==M&&(C+="tenantId="+encodeURIComponent(""+M)+"&"),C=C.replace(/[?&]$/,"");var H={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(H)).pipe(t.mergeMap((function(e){return U.http.request("get",C,e)}))).pipe(t.mergeMap((function(e){return U.transformResult(C,e,(function(e){return U.processImg(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return U.transformResult(C,e,(function(e){return U.processImg(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processImg=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getLicense=function(e){var r=this,a=this.baseUrl+"/api/atoms/v1/ccviewer/license?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(a+="tenantId="+encodeURIComponent(""+e)+"&"),a=a.replace(/[?&]$/,"");var p={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(p)).pipe(t.mergeMap((function(e){return r.http.request("get",a,e)}))).pipe(t.mergeMap((function(e){return r.transformResult(a,e,(function(e){return r.processGetLicense(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return r.transformResult(a,e,(function(e){return r.processGetLicense(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetLicense=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.pth=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/pth?";if(null!=e&&(p+="f="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processPth(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processPth(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processPth=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.resource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/resource?";if(null!=e&&(p+="image="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.svg=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y,R,b,w,I,M){var U=this,C=this.baseUrl+"/api/atoms/v1/ccviewer/svg?";if(null!=e&&(C+="f="+encodeURIComponent(""+e)+"&"),null!=r&&(C+="w="+encodeURIComponent(""+r)+"&"),null!=a&&(C+="h="+encodeURIComponent(""+a)+"&"),null!=p&&(C+="cmyk="+encodeURIComponent(""+p)+"&"),null!=s&&(C+="rgb="+encodeURIComponent(""+s)+"&"),null!=i&&(C+="grayscale="+encodeURIComponent(""+i)+"&"),null!=u&&(C+="target="+encodeURIComponent(""+u)+"&"),null!=c&&(C+="sq="+encodeURIComponent(""+c)+"&"),null!=l&&(C+="effect="+encodeURIComponent(""+l)+"&"),null!=f&&(C+="kp="+encodeURIComponent(""+f)+"&"),null!=d&&(C+="color="+encodeURIComponent(""+d)+"&"),null!=m&&(C+="obm="+encodeURIComponent(""+m)+"&"),null!=h&&(C+="oo="+encodeURIComponent(""+h)+"&"),null!=v&&(C+="alphaMask="+encodeURIComponent(""+v)+"&"),null!=g&&(C+="page="+encodeURIComponent(""+g)+"&"),null!=y&&(C+="colorizeColor="+encodeURIComponent(""+y)+"&"),null!=R&&(C+="rw="+encodeURIComponent(""+R)+"&"),null!=b&&(C+="rh="+encodeURIComponent(""+b)+"&"),null!=w&&(C+="dt="+encodeURIComponent(""+w)+"&"),null!=I&&(C+="da="+encodeURIComponent(""+I)+"&"),null===M)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==M&&(C+="tenantId="+encodeURIComponent(""+M)+"&"),C=C.replace(/[?&]$/,"");var H={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(H)).pipe(t.mergeMap((function(e){return U.http.request("get",C,e)}))).pipe(t.mergeMap((function(e){return U.transformResult(C,e,(function(e){return U.processSvg(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return U.transformResult(C,e,(function(e){return U.processSvg(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSvg=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.txt=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/txt?";if(null!=e&&(p+="f="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processTxt(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processTxt(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processTxt=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateArchedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateArchedTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateArchedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateArchedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateArchedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateAutoScaledTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateAutoScaledTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateAutoScaledTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateAutoScaledTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateAutoScaledTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateBarcodeItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateBarcodeItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateBarcodeItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateBarcodeItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateBarcodeItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateBoundedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateBoundedTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateBoundedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateBoundedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateBoundedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateByColorData=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateByColorData?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateByColorData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateByColorData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateByColorData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateByMultiCallRequest=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateByMultiCallRequest?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateByMultiCallRequest(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateByMultiCallRequest(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateByMultiCallRequest=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateCurvedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateCurvedTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateCurvedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateCurvedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateCurvedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateImageItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateImageItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateImageItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateImageItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateImageItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updatePathBoundedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdatePathBoundedTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdatePathBoundedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdatePathBoundedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdatePathBoundedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updatePlainTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdatePlainTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdatePlainTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdatePlainTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdatePlainTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateShapeItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateShapeItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateShapeItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateShapeItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateShapeItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);G.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new G(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:G,providedIn:"root"}),G.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],G.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]},(I=e.ArtworkShapeType||(e.ArtworkShapeType={})).Rectangle="rectangle",I.Ellipse="ellipse",(M=e.ColorlessContainerDisplayType||(e.ColorlessContainerDisplayType={})).Color="Color",M.Texture="Texture",(U=e.ColorlessContainerDitherType||(e.ColorlessContainerDitherType={})).None="None",U.Diffusion="Diffusion",U.Pattern="Pattern",U.Noise="Noise",(C=e.ColorlessContainerFormat||(e.ColorlessContainerFormat={})).OneBit="OneBit",C.Grayscale="Grayscale",C.Vector="Vector",(H=e.ConflictType||(e.ConflictType={})).NameConflict="NameConflict",H.FolderOverwriteConflict="FolderOverwriteConflict",H.IdConflict="IdConflict",H.GeneralConflict="GeneralConflict",(E=e.ContainerColorSpace||(e.ContainerColorSpace={})).Rgb="Rgb",E.Cmyk="Cmyk",E.Grayscale="Grayscale",E.Lab="Lab",E.Spot="Spot",(S=e.ContainerPrintingMode||(e.ContainerPrintingMode={})).FullColor="FullColor",S.LimitedColor="LimitedColor",S.Colorless="Colorless",(T=e.DesignElementType||(e.DesignElementType={})).Product="Product",T.Design="Design",T.Surface="Surface",T.Container="Container",T.PrintArea="PrintArea",T.Item="Item",(x=e.ImageExtractionFormat||(e.ImageExtractionFormat={})).AsIs="AsIs",x.Jpeg="Jpeg",x.Png="Png",(O=e.ImagePreviewFitMode||(e.ImagePreviewFitMode={})).Fit="Fit",O.Shrink="Shrink",O.Resize="Resize",O.Fill="Fill",(j=e.ImagePreviewFormat||(e.ImagePreviewFormat={})).Jpeg="Jpeg",j.Png="Png",(P=e.ItemBorderStyle||(e.ItemBorderStyle={})).Solid="Solid",P.Dashed="Dashed",(N=e.ItemSourceType||(e.ItemSourceType={})).File="File",N.ImageStorage="ImageStorage",N.PrivateImageStorage="PrivateImageStorage",N.Url="Url",(A=e.ItemType||(e.ItemType={})).Image="Image",A.Shape="Shape",A.Clipart="Clipart",A.Group="Group",(B=e.MockupPreviewFitMode||(e.MockupPreviewFitMode={})).Fit="Fit",B.Shrink="Shrink",B.Resize="Resize",B.Fill="Fill",(F=e.MockupPreviewFormat||(e.MockupPreviewFormat={})).Jpeg="Jpeg",F.Png="Png",(e.PlaceholderItemContentType||(e.PlaceholderItemContentType={})).Image="Image",(J=e.ProductPatchType||(e.ProductPatchType={})).Undefined="Undefined",J.ReplaceImageItemFile="ReplaceImageItemFile",J.ReplacePlaceholderItemContent="ReplacePlaceholderItemContent",(D=e.ProductPreviewFormat||(e.ProductPreviewFormat={})).Jpeg="Jpeg",D.Png="Png",(k=e.ProductProofFormat||(e.ProductProofFormat={})).Jpeg="Jpeg",k.Png="Png",k.Tiff="Tiff",k.Pdf="Pdf",(q=e.ProductProofInterpolationMode||(e.ProductProofInterpolationMode={})).High="High",q.Medium="Medium",q.Low="Low",q.NearestNeighbour="NearestNeighbour",q.Linear="Linear",q.Cubic="Cubic",q.Supersampling="Supersampling",q.Lanczos="Lanczos",q.Anisotropic4="Anisotropic4",q.Anisotropic9="Anisotropic9",q.Lanczos3="Lanczos3",($=e.TextAlignment||(e.TextAlignment={})).Left="Left",$.Center="Center",$.Right="Right",$.All="All",$.LastLeft="LastLeft",$.LastRight="LastRight",$.LastCenter="LastCenter",(z=e.TextVerticalAlignment||(e.TextVerticalAlignment={})).Top="Top",z.Center="Center",z.Bottom="Bottom";var L=function(e){function r(r,t,n,o,a){var p=e.call(this)||this;return p.isApiException=!0,p.message=r,p.status=t,p.response=n,p.headers=o,p.result=a,p}return p(r,e),r.isApiException=function(e){return!0===e.isApiException},r}(Error);function V(e,r,t,o,a){return n.throwError(new L(e,r,t,o,a))}function _(e){return new n.Observable((function(r){if(e){var t=new FileReader;t.onload=function(e){r.next(e.target.result),r.complete()},t.readAsText(e)}else r.next(""),r.complete()}))}function W(e,r,t){void 0===t&&(t="ApiKey");var n=new l;return n.apiKey=t,n.apiUrl=r,n.setAuthorizationToken(e),n}var K=function(){function e(){}return e.forRoot=function(r,t,n){return void 0===n&&(n="ApiKey"),{ngModule:e,providers:[{provide:c,useValue:t},{provide:l,useFactory:W.bind(this,r,t,n)}]}},e}();K.decorators=[{type:r.NgModule,args:[{declarations:[],imports:[],exports:[]}]}],e.API_BASE_URL=c,e.ApiClientBase=f,e.ApiClientConfiguration=l,e.ApiException=L,e.BuildInfoApiClient=d,e.CreateApiClientConfiguration=W,e.DesignAtomsApiModule=K,e.DesignAtomsCompatibilityApiClient=m,e.DesignAtomsImagesApiClient=h,e.DesignAtomsMockups2dApiClient=v,e.DesignAtomsMockups3dApiClient=g,e.DesignAtomsPalettesApiClient=y,e.DesignAtomsPrintProductApiClient=R,e.DesignAtomsPrintProductItemsApiClient=b,e.DesignAtomsServiceApiClient=w,e.DesignAtomsViewerApiClient=G,Object.defineProperty(e,"__esModule",{value:!0})}));
|
|
15
|
+
***************************************************************************** */var a=function(e,r){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,r){e.__proto__=r}||function(e,r){for(var t in r)Object.prototype.hasOwnProperty.call(r,t)&&(e[t]=r[t])})(e,r)};function p(e,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function t(){this.constructor=e}a(e,r),e.prototype=null===r?Object.create(r):(t.prototype=r.prototype,new t)}function s(e,r,t,n){return new(t||(t=Promise))((function(o,a){function p(e){try{i(n.next(e))}catch(e){a(e)}}function s(e){try{i(n.throw(e))}catch(e){a(e)}}function i(e){var r;e.done?o(e.value):(r=e.value,r instanceof t?r:new t((function(e){e(r)}))).then(p,s)}i((n=n.apply(e,r||[])).next())}))}function i(e,r){var t,n,o,a,p={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(a){return function(s){return function(a){if(t)throw new TypeError("Generator is already executing.");for(;p;)try{if(t=1,n&&(o=2&a[0]?n.return:a[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,a[1])).done)return o;switch(n=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return p.label++,{value:a[1],done:!1};case 5:p.label++,n=a[1],a=[0];continue;case 7:a=p.ops.pop(),p.trys.pop();continue;default:if(!(o=p.trys,(o=o.length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){p=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){p.label=a[1];break}if(6===a[0]&&p.label<o[1]){p.label=o[1],o=a;break}if(o&&p.label<o[2]){p.label=o[2],p.ops.push(a);break}o[2]&&p.ops.pop(),p.trys.pop();continue}a=r.call(e,p)}catch(e){a=[6,e],n=0}finally{t=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,s])}}}Object.create;function u(e){var r="function"==typeof Symbol&&Symbol.iterator,t=r&&e[r],n=0;if(t)return t.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(r?"Object is not iterable.":"Symbol.iterator is not defined.")}Object.create;var c=new r.InjectionToken("API_BASE_URL"),l=function(){function e(){this.apiUrl="http://localhost:54220",this.apiKey="ApiKey",this.authorizationToken=null}return e.prototype.getAuthorizationToken=function(){return s(this,void 0,void 0,(function(){return i(this,(function(e){return[2,this.authorizationToken]}))}))},e.prototype.setAuthorizationToken=function(e){this.authorizationToken=e},e}(),f=function(){function e(e){this.configuration=e}return e.prototype.transformOptions=function(e){return s(this,void 0,void 0,(function(){var r;return i(this,(function(t){switch(t.label){case 0:return[4,this.configuration.getAuthorizationToken()];case 1:return r=t.sent(),e.headers=null!=r?e.headers.append("authorization","Bearer "+r):e.headers.append("X-API-Key",this.configuration.apiKey),[2,e]}}))}))},e.prototype.getBaseUrl=function(e){return this.configuration.apiUrl.endsWith("/")?this.configuration.apiUrl.slice(0,-1):this.configuration.apiUrl},e.prototype.transformResult=function(e,r,t){return t(r)},e}(),d=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.headInfo=function(){var e=this,r=this.baseUrl+"/api/atoms/v1/info";r=r.replace(/[?&]$/,"");var a={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(a)).pipe(t.mergeMap((function(t){return e.http.request("head",r,t)}))).pipe(t.mergeMap((function(t){return e.transformResult(r,t,(function(r){return e.processHeadInfo(r)}))}))).pipe(t.catchError((function(t){if(!(t instanceof o.HttpResponseBase))return n.throwError(t);try{return e.transformResult(r,t,(function(r){return e.processHeadInfo(r)}))}catch(e){return n.throwError(e)}})))},r.prototype.processHeadInfo=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}return 200===p?_(s).pipe(t.mergeMap((function(e){return n.of(null)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.getInfo=function(){var e=this,r=this.baseUrl+"/api/atoms/v1/info";r=r.replace(/[?&]$/,"");var a={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(a)).pipe(t.mergeMap((function(t){return e.http.request("get",r,t)}))).pipe(t.mergeMap((function(t){return e.transformResult(r,t,(function(r){return e.processGetInfo(r)}))}))).pipe(t.catchError((function(t){if(!(t instanceof o.HttpResponseBase))return n.throwError(t);try{return e.transformResult(r,t,(function(r){return e.processGetInfo(r)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetInfo=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);d.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new d(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:d,providedIn:"root"}),d.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],d.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var m=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.cssFonts=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/cssfonts";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"text/css"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processCssFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processCssFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCssFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.fonts=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/fonts/{psName}";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");if(p=p.replace("{tenantId}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'psName' must be defined.");p=(p=p.replace("{psName}",encodeURIComponent(""+r))).replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getColorPreview=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetColorPreview";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetColorPreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetColorPreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetColorPreview=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getColorPreviews=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetColorPreviews";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetColorPreviews(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetColorPreviews(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetColorPreviews=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getCssFont=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetCssFont?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=p.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(p+="fontKey="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetCssFont(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetCssFont(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetCssFont=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getFallbackFonts=function(e){var r=this,a=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetFallbackFonts";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");a=(a=a.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var p={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(p)).pipe(t.mergeMap((function(e){return r.http.request("get",a,e)}))).pipe(t.mergeMap((function(e){return r.transformResult(a,e,(function(e){return r.processGetFallbackFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return r.transformResult(a,e,(function(e){return r.processGetFallbackFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetFallbackFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getImageSize=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetImageSize";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetImageSize(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetImageSize(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetImageSize=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getShapeBounds=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetShapeBounds";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetShapeBounds(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetShapeBounds(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetShapeBounds=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getWatermarkItems=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/GetWatermarkItems";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetWatermarkItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetWatermarkItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetWatermarkItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.img=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y,R,b,w,I,M){var U=this,C=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/img?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");C=C.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(C+="f="+encodeURIComponent(""+r)+"&"),null!=a&&(C+="w="+encodeURIComponent(""+a)+"&"),null!=p&&(C+="h="+encodeURIComponent(""+p)+"&"),null!=s&&(C+="cmyk="+encodeURIComponent(""+s)+"&"),null!=i&&(C+="rgb="+encodeURIComponent(""+i)+"&"),null!=u&&(C+="grayscale="+encodeURIComponent(""+u)+"&"),null!=c&&(C+="target="+encodeURIComponent(""+c)+"&"),null!=l&&(C+="sq="+encodeURIComponent(""+l)+"&"),null!=f&&(C+="effect="+encodeURIComponent(""+f)+"&"),null!=d&&(C+="kp="+encodeURIComponent(""+d)+"&"),null!=m&&(C+="color="+encodeURIComponent(""+m)+"&"),null!=h&&(C+="obm="+encodeURIComponent(""+h)+"&"),null!=v&&(C+="oo="+encodeURIComponent(""+v)+"&"),null!=g&&(C+="alphaMask="+encodeURIComponent(""+g)+"&"),null!=y&&(C+="page="+encodeURIComponent(""+y)+"&"),null!=R&&(C+="colorizeColor="+encodeURIComponent(""+R)+"&"),null!=b&&(C+="rw="+encodeURIComponent(""+b)+"&"),null!=w&&(C+="rh="+encodeURIComponent(""+w)+"&"),null!=I&&(C+="dt="+encodeURIComponent(""+I)+"&"),null!=M&&(C+="da="+encodeURIComponent(""+M)+"&"),C=C.replace(/[?&]$/,"");var H={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(H)).pipe(t.mergeMap((function(e){return U.http.request("get",C,e)}))).pipe(t.mergeMap((function(e){return U.transformResult(C,e,(function(e){return U.processImg(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return U.transformResult(C,e,(function(e){return U.processImg(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processImg=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getLicense=function(e){var r=this,a=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/license";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");a=(a=a.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var p={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(p)).pipe(t.mergeMap((function(e){return r.http.request("get",a,e)}))).pipe(t.mergeMap((function(e){return r.transformResult(a,e,(function(e){return r.processGetLicense(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return r.transformResult(a,e,(function(e){return r.processGetLicense(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetLicense=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.pth=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/pth?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=p.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(p+="f="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processPth(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processPth(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processPth=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.resource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/resource?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=p.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(p+="image="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.svg=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y,R,b,w,I,M){var U=this,C=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/svg?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");C=C.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(C+="f="+encodeURIComponent(""+r)+"&"),null!=a&&(C+="w="+encodeURIComponent(""+a)+"&"),null!=p&&(C+="h="+encodeURIComponent(""+p)+"&"),null!=s&&(C+="cmyk="+encodeURIComponent(""+s)+"&"),null!=i&&(C+="rgb="+encodeURIComponent(""+i)+"&"),null!=u&&(C+="grayscale="+encodeURIComponent(""+u)+"&"),null!=c&&(C+="target="+encodeURIComponent(""+c)+"&"),null!=l&&(C+="sq="+encodeURIComponent(""+l)+"&"),null!=f&&(C+="effect="+encodeURIComponent(""+f)+"&"),null!=d&&(C+="kp="+encodeURIComponent(""+d)+"&"),null!=m&&(C+="color="+encodeURIComponent(""+m)+"&"),null!=h&&(C+="obm="+encodeURIComponent(""+h)+"&"),null!=v&&(C+="oo="+encodeURIComponent(""+v)+"&"),null!=g&&(C+="alphaMask="+encodeURIComponent(""+g)+"&"),null!=y&&(C+="page="+encodeURIComponent(""+y)+"&"),null!=R&&(C+="colorizeColor="+encodeURIComponent(""+R)+"&"),null!=b&&(C+="rw="+encodeURIComponent(""+b)+"&"),null!=w&&(C+="rh="+encodeURIComponent(""+w)+"&"),null!=I&&(C+="dt="+encodeURIComponent(""+I)+"&"),null!=M&&(C+="da="+encodeURIComponent(""+M)+"&"),C=C.replace(/[?&]$/,"");var H={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(H)).pipe(t.mergeMap((function(e){return U.http.request("get",C,e)}))).pipe(t.mergeMap((function(e){return U.transformResult(C,e,(function(e){return U.processSvg(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return U.transformResult(C,e,(function(e){return U.processSvg(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSvg=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.txt=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/txt?";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=p.replace("{tenantId}",encodeURIComponent(""+e)),null!=r&&(p+="f="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processTxt(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processTxt(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processTxt=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateArchedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateArchedTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateArchedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateArchedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateArchedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateAutoScaledTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateAutoScaledTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateAutoScaledTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateAutoScaledTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateAutoScaledTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateBarcodeItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateBarcodeItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateBarcodeItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateBarcodeItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateBarcodeItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateBoundedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateBoundedTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateBoundedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateBoundedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateBoundedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateByColorData=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateByColorData";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateByColorData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateByColorData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateByColorData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateByMultiCallRequest=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateByMultiCallRequest";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateByMultiCallRequest(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateByMultiCallRequest(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateByMultiCallRequest=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateCurvedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateCurvedTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateCurvedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateCurvedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateCurvedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateImageItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateImageItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateImageItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateImageItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateImageItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updatePathBoundedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdatePathBoundedTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdatePathBoundedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdatePathBoundedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdatePathBoundedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updatePlainTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdatePlainTextItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdatePlainTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdatePlainTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdatePlainTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateShapeItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/tenants/{tenantId}/api/ccviewer/UpdateShapeItemHandler";if(null==e)throw new Error("The parameter 'tenantId' must be defined.");p=(p=p.replace("{tenantId}",encodeURIComponent(""+e))).replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateShapeItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateShapeItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateShapeItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);m.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new m(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:m,providedIn:"root"}),m.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],m.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var h=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.renderImagePreview=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/images/render-preview?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderImagePreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderImagePreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreview=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewFromFile=function(e,r,a,p,s,i,u,c,l,f){var d=this,m=this.baseUrl+"/api/atoms/v1/images/render-preview/from-file?";if(null!=e&&(m+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(m+="tenantId="+encodeURIComponent(""+r)+"&"),m=m.replace(/[?&]$/,"");var h=new FormData;null!=a&&h.append("sourceFile",a.data,a.fileName?a.fileName:"sourceFile"),null!=p&&h.append("mockupOwnerId",p.toString()),null!=s&&h.append("mockupId",s.toString()),null!=i&&h.append("width",i.toString()),null!=u&&h.append("height",u.toString()),null!=c&&h.append("fileFormat",c.toString()),null!=l&&h.append("fitMode",l.toString()),null!=f&&h.append("pageIndex",f.toString());var v={body:h,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(v)).pipe(t.mergeMap((function(e){return d.http.request("post",m,e)}))).pipe(t.mergeMap((function(e){return d.transformResult(m,e,(function(e){return d.processRenderImagePreviewFromFile(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return d.transformResult(m,e,(function(e){return d.processRenderImagePreviewFromFile(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewFromFile=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewFromFileToResource=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y){var R=this,b=this.baseUrl+"/api/atoms/v1/images/render-preview/from-file/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(b+="tenantId="+encodeURIComponent(""+e)+"&"),b=b.replace(/[?&]$/,"");var w=new FormData;null!=r&&w.append("resourceOwnerId",r.toString()),null!=a&&w.append("resourceNamespace",a.toString()),null!=p&&w.append("resourceName",p.toString()),null!=s&&w.append("resourceSourceId",s.toString()),null!=i&&w.append("resourceType",i.toString()),null!=u&&w.append("anonymousAccess",u.toString()),null!=c&&w.append("overwriteExistingResource",c.toString()),null!=l&&w.append("sourceFile",l.data,l.fileName?l.fileName:"sourceFile"),null!=f&&w.append("mockupOwnerId",f.toString()),null!=d&&w.append("mockupId",d.toString()),null!=m&&w.append("width",m.toString()),null!=h&&w.append("height",h.toString()),null!=v&&w.append("fileFormat",v.toString()),null!=g&&w.append("fitMode",g.toString()),null!=y&&w.append("pageIndex",y.toString());var I={body:w,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(I)).pipe(t.mergeMap((function(e){return R.http.request("post",b,e)}))).pipe(t.mergeMap((function(e){return R.transformResult(b,e,(function(e){return R.processRenderImagePreviewFromFileToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return R.transformResult(b,e,(function(e){return R.processRenderImagePreviewFromFileToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewFromFileToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewFromUrl=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/images/render-preview/from-url?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderImagePreviewFromUrl(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderImagePreviewFromUrl(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewFromUrl=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewFromUrlToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/images/render-preview/from-url/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processRenderImagePreviewFromUrlToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processRenderImagePreviewFromUrlToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewFromUrlToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderImagePreviewToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/images/render-preview/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processRenderImagePreviewToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processRenderImagePreviewToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderImagePreviewToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);h.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new h(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:h,providedIn:"root"}),h.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],h.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var v=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.renderMockupPreview=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/mockups-2d/render-preview?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderMockupPreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderMockupPreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderMockupPreview=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);v.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new v(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:v,providedIn:"root"}),v.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],v.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var g=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.getAttributes=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/mockups-3d/{id}/attributes?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="ownerId="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetAttributes(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetAttributes(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetAttributes=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getContentAsProtobuf=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/mockups-3d/{id}/content/as-protobuf?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="ownerId="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetContentAsProtobuf(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetContentAsProtobuf(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetContentAsProtobuf=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getGeometryFile=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/mockups-3d/{id}/geometry/file?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="ownerId="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetGeometryFile(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetGeometryFile(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetGeometryFile=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);g.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new g(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:g,providedIn:"root"}),g.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],g.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var y=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.findPaletteColor=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/palettes/find-color?";if(null!=e&&(s+="paletteUID="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processFindPaletteColor(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processFindPaletteColor(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFindPaletteColor=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getPaletteModel=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/palettes/model?";if(null!=e&&(s+="id="+encodeURIComponent(""+e)+"&"),null!=r&&(s+="uid="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetPaletteModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetPaletteModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetPaletteModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);y.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new y(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:y,providedIn:"root"}),y.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],y.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var R=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.patchDesignProduct=function(e,r,a,p,s,i,u,c,l){var f=this,d=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(d=d.replace("{id}",encodeURIComponent(""+e)),null!=r&&(d+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(d+="tenantId="+encodeURIComponent(""+a)+"&"),d=d.replace(/[?&]$/,"");var m=new FormData;null!=p&&m.append("patchType",p.toString()),null!=s&&m.append("replaceImageItemFileInfo.itemName",s.toString()),null!=i&&m.append("replaceImageItemFileInfo.sourceFile",i.data,i.fileName?i.fileName:"replaceImageItemFileInfo.sourceFile"),null!=u&&m.append("replacePlaceholderItemContentInfo.placeholderItemName",u.toString()),null!=c&&m.append("replacePlaceholderItemContentInfo.newContentType",c.toString()),null!=l&&m.append("replacePlaceholderItemContentInfo.sourceFile",l.data,l.fileName?l.fileName:"replacePlaceholderItemContentInfo.sourceFile");var h={body:m,observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(h)).pipe(t.mergeMap((function(e){return f.http.request("patch",d,e)}))).pipe(t.mergeMap((function(e){return f.transformResult(d,e,(function(e){return f.processPatchDesignProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return f.transformResult(d,e,(function(e){return f.processPatchDesignProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processPatchDesignProduct=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceContainers=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainers(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainers(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceContainers=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignSurfaceContainer=function(e,r,a,p,s,i){var u=this,c=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(c=c.replace("{id}",encodeURIComponent(""+e)),null!=r&&(c+="index="+encodeURIComponent(""+r)+"&"),null!=a&&(c+="surfaceId="+encodeURIComponent(""+a)+"&"),null!=p&&(c+="privateStorageOwner="+encodeURIComponent(""+p)+"&"),null===s)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==s&&(c+="tenantId="+encodeURIComponent(""+s)+"&"),c=c.replace(/[?&]$/,"");var l={body:JSON.stringify(i),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(l)).pipe(t.mergeMap((function(e){return u.http.request("post",c,e)}))).pipe(t.mergeMap((function(e){return u.transformResult(c,e,(function(e){return u.processAddDesignSurfaceContainer(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return u.transformResult(c,e,(function(e){return u.processAddDesignSurfaceContainer(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignSurfaceContainer=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceContainer=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(i=i.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainer(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainer(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceContainer=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceContainer=function(e,r,a,p,s,i){var u=this,c=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(c=c.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(c=c.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(c+="surfaceId="+encodeURIComponent(""+a)+"&"),null!=p&&(c+="privateStorageOwner="+encodeURIComponent(""+p)+"&"),null===s)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==s&&(c+="tenantId="+encodeURIComponent(""+s)+"&"),c=c.replace(/[?&]$/,"");var l={body:JSON.stringify(i),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(l)).pipe(t.mergeMap((function(e){return u.http.request("put",c,e)}))).pipe(t.mergeMap((function(e){return u.transformResult(c,e,(function(e){return u.processUpdateDesignSurfaceContainer(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return u.transformResult(c,e,(function(e){return u.processUpdateDesignSurfaceContainer(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceContainer=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteDesignSurfaceContainer=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(i=i.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("delete",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurfaceContainer(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurfaceContainer(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteDesignSurfaceContainer=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceContainerModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(i=i.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainerModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceContainerModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceContainerModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceContainerModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/{containerId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'containerId' must be defined.");if(u=u.replace("{containerId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processUpdateDesignSurfaceContainerModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processUpdateDesignSurfaceContainerModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceContainerModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignSurfaceContainerModel=function(e,r,a,p,s,i,u,c){var l=this,f=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/containers/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(f=f.replace("{id}",encodeURIComponent(""+e)),null!=r&&(f+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(f+="index="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'top' cannot be null.");if(void 0!==p&&(f+="top="+encodeURIComponent(""+p)+"&"),null===s)throw new Error("The parameter 'left' cannot be null.");if(void 0!==s&&(f+="left="+encodeURIComponent(""+s)+"&"),null!=i&&(f+="privateStorageOwner="+encodeURIComponent(""+i)+"&"),null===u)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==u&&(f+="tenantId="+encodeURIComponent(""+u)+"&"),f=f.replace(/[?&]$/,"");var d={body:JSON.stringify(c),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(d)).pipe(t.mergeMap((function(e){return l.http.request("post",f,e)}))).pipe(t.mergeMap((function(e){return l.transformResult(f,e,(function(e){return l.processAddDesignSurfaceContainerModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return l.transformResult(f,e,(function(e){return l.processAddDesignSurfaceContainerModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignSurfaceContainerModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceItems=function(e,r,a,p,s,i){var u=this,c=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(c=c.replace("{id}",encodeURIComponent(""+e)),null!=r&&(c+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(c+="containerId="+encodeURIComponent(""+a)+"&"),null!=p&&(c+="parentItemId="+encodeURIComponent(""+p)+"&"),null!=s&&(c+="privateStorageOwner="+encodeURIComponent(""+s)+"&"),null===i)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==i&&(c+="tenantId="+encodeURIComponent(""+i)+"&"),c=c.replace(/[?&]$/,"");var l={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(l)).pipe(t.mergeMap((function(e){return u.http.request("get",c,e)}))).pipe(t.mergeMap((function(e){return u.transformResult(c,e,(function(e){return u.processGetDesignSurfaceItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return u.transformResult(c,e,(function(e){return u.processGetDesignSurfaceItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteDesignSurfaceItem=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items/{itemId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'itemId' must be defined.");if(i=i.replace("{itemId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("delete",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurfaceItem(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurfaceItem(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteDesignSurfaceItem=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceItemModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items/{itemId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'itemId' must be defined.");if(i=i.replace("{itemId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceItemModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceItemModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceItemModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceItemModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items/{itemId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'itemId' must be defined.");if(u=u.replace("{itemId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processUpdateDesignSurfaceItemModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processUpdateDesignSurfaceItemModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceItemModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignSurfaceItemModel=function(e,r,a,p,s,i,u,c){var l=this,f=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/items/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(f=f.replace("{id}",encodeURIComponent(""+e)),null!=r&&(f+="containerId="+encodeURIComponent(""+r)+"&"),null!=a&&(f+="index="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'top' cannot be null.");if(void 0!==p&&(f+="top="+encodeURIComponent(""+p)+"&"),null===s)throw new Error("The parameter 'left' cannot be null.");if(void 0!==s&&(f+="left="+encodeURIComponent(""+s)+"&"),null!=i&&(f+="privateStorageOwner="+encodeURIComponent(""+i)+"&"),null===u)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==u&&(f+="tenantId="+encodeURIComponent(""+u)+"&"),f=f.replace(/[?&]$/,"");var d={body:JSON.stringify(c),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(d)).pipe(t.mergeMap((function(e){return l.http.request("post",f,e)}))).pipe(t.mergeMap((function(e){return l.transformResult(f,e,(function(e){return l.processAddDesignSurfaceItemModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return l.transformResult(f,e,(function(e){return l.processAddDesignSurfaceItemModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignSurfaceItemModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignProductModel=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetDesignProductModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetDesignProductModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignProductModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignProductModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processUpdateDesignProductModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processUpdateDesignProductModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignProductModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignPrintAreas=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignPrintAreas(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignPrintAreas(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignPrintAreas=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignPrintArea=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("post",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processAddDesignPrintArea(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processAddDesignPrintArea(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignPrintArea=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignPrintArea=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/{printAreaId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'printAreaId' must be defined.");if(u=u.replace("{printAreaId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processUpdateDesignPrintArea(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processUpdateDesignPrintArea(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignPrintArea=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteDesignPrintArea=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/{printAreaId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'printAreaId' must be defined.");if(i=i.replace("{printAreaId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("delete",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processDeleteDesignPrintArea(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processDeleteDesignPrintArea(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteDesignPrintArea=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignPrintAreaModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/{printAreaId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'printAreaId' must be defined.");if(i=i.replace("{printAreaId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignPrintAreaModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignPrintAreaModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignPrintAreaModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignPrintAreaModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/{printAreaId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'printAreaId' must be defined.");if(u=u.replace("{printAreaId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processUpdateDesignPrintAreaModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processUpdateDesignPrintAreaModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignPrintAreaModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignPrintAreaModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/print-areas/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null!=r&&(u+="surfaceId="+encodeURIComponent(""+r)+"&"),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("post",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processAddDesignPrintAreaModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processAddDesignPrintAreaModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignPrintAreaModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaces=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetDesignSurfaces(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetDesignSurfaces(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaces=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteDesignSurface=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("delete",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurface(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processDeleteDesignSurface(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteDesignSurface=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceDownMockup=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-down?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceDownMockup(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceDownMockup(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceDownMockup=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceDownMockup=function(e,r,a,p,s,i,u,c,l){var f=this,d=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-down?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(d=d.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(d=d.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(d+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(d+="tenantId="+encodeURIComponent(""+p)+"&"),d=d.replace(/[?&]$/,"");var m=new FormData;if(null==s)throw new Error("The parameter 'position_top' cannot be null.");if(m.append("position.top",s.toString()),null==i)throw new Error("The parameter 'position_left' cannot be null.");m.append("position.left",i.toString()),null!=u&&m.append("dpiX",u.toString()),null!=c&&m.append("dpiY",c.toString()),null!=l&&m.append("sourceFile",l.data,l.fileName?l.fileName:"sourceFile");var h={body:m,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(h)).pipe(t.mergeMap((function(e){return f.http.request("patch",d,e)}))).pipe(t.mergeMap((function(e){return f.transformResult(d,e,(function(e){return f.processUpdateDesignSurfaceDownMockup(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return f.transformResult(d,e,(function(e){return f.processUpdateDesignSurfaceDownMockup(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceDownMockup=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceDownMockupContent=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-down/file?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceDownMockupContent(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceDownMockupContent(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceDownMockupContent=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceUpMockup=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-up?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceUpMockup(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceUpMockup(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceUpMockup=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateDesignSurfaceUpMockup=function(e,r,a,p,s,i,u,c,l){var f=this,d=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-up?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(d=d.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(d=d.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(d+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(d+="tenantId="+encodeURIComponent(""+p)+"&"),d=d.replace(/[?&]$/,"");var m=new FormData;if(null==s)throw new Error("The parameter 'position_top' cannot be null.");if(m.append("position.top",s.toString()),null==i)throw new Error("The parameter 'position_left' cannot be null.");m.append("position.left",i.toString()),null!=u&&m.append("dpiX",u.toString()),null!=c&&m.append("dpiY",c.toString()),null!=l&&m.append("sourceFile",l.data,l.fileName?l.fileName:"sourceFile");var h={body:m,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(h)).pipe(t.mergeMap((function(e){return f.http.request("patch",d,e)}))).pipe(t.mergeMap((function(e){return f.transformResult(d,e,(function(e){return f.processUpdateDesignSurfaceUpMockup(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return f.transformResult(d,e,(function(e){return f.processUpdateDesignSurfaceUpMockup(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateDesignSurfaceUpMockup=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceUpMockupContent=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/mockup-up/file?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceUpMockupContent(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceUpMockupContent(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceUpMockupContent=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignSurfaceModel=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(i=i.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processGetDesignSurfaceModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignSurfaceModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.replaceDesignSurfaceModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/{surfaceId}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null==r)throw new Error("The parameter 'surfaceId' must be defined.");if(u=u.replace("{surfaceId}",encodeURIComponent(""+r)),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("put",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processReplaceDesignSurfaceModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processReplaceDesignSurfaceModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processReplaceDesignSurfaceModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.addDesignSurfaceModel=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/{id}/print-product/surfaces/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(u=u.replace("{id}",encodeURIComponent(""+e)),null!=r&&(u+="index="+encodeURIComponent(""+r)+"&"),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("post",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processAddDesignSurfaceModel(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processAddDesignSurfaceModel(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processAddDesignSurfaceModel=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createDesignProduct=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/print-product?";if(null!=e&&(u+="name="+encodeURIComponent(""+e)+"&"),null!=r&&(u+="path="+encodeURIComponent(""+r)+"&"),null!=a&&(u+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(u+="tenantId="+encodeURIComponent(""+p)+"&"),u=u.replace(/[?&]$/,"");var c={body:JSON.stringify(s),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(c)).pipe(t.mergeMap((function(e){return i.http.request("post",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processCreateDesignProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processCreateDesignProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateDesignProduct=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 201===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);R.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new R(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:R,providedIn:"root"}),R.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],R.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var b=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.applyItemEffects=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/apply-effects?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processApplyItemEffects(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processApplyItemEffects(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processApplyItemEffects=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createEllipseItem=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/ellipse?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processCreateEllipseItem(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processCreateEllipseItem(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateEllipseItem=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.extractItemImage=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/extract-image?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processExtractItemImage(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processExtractItemImage(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processExtractItemImage=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.extractItemImageToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/extract-image/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processExtractItemImageToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processExtractItemImageToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processExtractItemImageToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.flattenItems=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/flatten?";if(null!=e&&(s+="paletteUID="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processFlattenItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processFlattenItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFlattenItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createItemFromFile=function(e,r,a,p,s,i){var u=this,c=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-file?";if(null!=e&&(c+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(c+="tenantId="+encodeURIComponent(""+r)+"&"),c=c.replace(/[?&]$/,"");var l=new FormData;null!=a&&l.append("sourceFile",a.data,a.fileName?a.fileName:"sourceFile"),null!=p&&l.append("paletteUID",p.toString()),null!=s&&l.append("pageIndex",s.toString()),null!=i&&l.append("preserveOriginalFile",i.toString());var f={body:l,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(f)).pipe(t.mergeMap((function(e){return u.http.request("post",c,e)}))).pipe(t.mergeMap((function(e){return u.transformResult(c,e,(function(e){return u.processCreateItemFromFile(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return u.transformResult(c,e,(function(e){return u.processCreateItemFromFile(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateItemFromFile=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.batchCreateItemsFromFile=function(e,r,a,p,s){var i=this,u=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-file/batch-create?";if(null!=e&&(u+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(u+="tenantId="+encodeURIComponent(""+r)+"&"),u=u.replace(/[?&]$/,"");var c=new FormData;null!=a&&a.forEach((function(e){return c.append("sourceFiles",e.data,e.fileName?e.fileName:"sourceFiles")})),null!=p&&c.append("paletteUID",p.toString()),null!=s&&c.append("preserveOriginalFile",s.toString());var l={body:c,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(l)).pipe(t.mergeMap((function(e){return i.http.request("post",u,e)}))).pipe(t.mergeMap((function(e){return i.transformResult(u,e,(function(e){return i.processBatchCreateItemsFromFile(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return i.transformResult(u,e,(function(e){return i.processBatchCreateItemsFromFile(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processBatchCreateItemsFromFile=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createItemFromStorage=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-storage?";if(null!=e&&(s+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processCreateItemFromStorage(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processCreateItemFromStorage(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateItemFromStorage=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.batchCreateItemsFromStorage=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-storage/batch-create?";if(null!=e&&(s+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processBatchCreateItemsFromStorage(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processBatchCreateItemsFromStorage(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processBatchCreateItemsFromStorage=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createItemFromUrl=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-url?";if(null!=e&&(s+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processCreateItemFromUrl(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processCreateItemFromUrl(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateItemFromUrl=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.batchCreateItemsFromUrl=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/items/from-url/batch-create?";if(null!=e&&(s+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processBatchCreateItemsFromUrl(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processBatchCreateItemsFromUrl(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processBatchCreateItemsFromUrl=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createRectangleItem=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/items/rectangle?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processCreateRectangleItem(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processCreateRectangleItem(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateRectangleItem=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);b.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new b(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:b,providedIn:"root"}),b.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],b.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var w=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.createDesign=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs?";if(null!=e&&(s+="privateStorageOwner="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processCreateDesign(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processCreateDesign(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateDesign=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 201===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.applyItemsData=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/apply-items-data?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("post",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processApplyItemsData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processApplyItemsData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processApplyItemsData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.extractBackground=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/background?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="surfaceIndex="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("get",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processExtractBackground(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processExtractBackground(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processExtractBackground=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.setEditorMockups=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/editor-mockups?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processSetEditorMockups(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processSetEditorMockups(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSetEditorMockups=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 204===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getDesignParameters=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/parameters?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetDesignParameters(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetDesignParameters(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetDesignParameters=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadDataSchema=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/schema?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadDataSchema(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadDataSchema(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadDataSchema=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadToggleSet=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/toggle-set?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadToggleSet(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadToggleSet(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadToggleSet=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getVariables=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/variables?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processGetVariables(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processGetVariables(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetVariables=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.setVariables=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/variables?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processSetVariables(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processSetVariables(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSetVariables=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadVdpData=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/vdp-data?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadVdpData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadVdpData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadVdpData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.saveVdpData=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/vdp-data?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processSaveVdpData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processSaveVdpData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSaveVdpData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.deleteVdpData=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/vdp-data?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("delete",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processDeleteVdpData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processDeleteVdpData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processDeleteVdpData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.convertColors=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/print-product/convert-colors?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processConvertColors(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processConvertColors(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processConvertColors=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadProductFromResource=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/from-resource/model?";if(null!=e&&(s+="id="+encodeURIComponent(""+e)+"&"),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadProductFromResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadProductFromResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadProductFromResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderProduct=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/print-product/render-proof?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderProduct=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}if(200===p||206===p){var d=e.headers?e.headers.get("content-disposition"):void 0,m=d?/filename="?([^"]*?)"?(;|$)/g.exec(d):void 0,h=m&&m.length>1?m[1]:void 0;return n.of({fileName:h,data:s,status:p,headers:i})}return 401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.renderDesignPreview=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/render-preview?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderDesignPreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderDesignPreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderDesignPreview=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}if(200===p||206===p){var d=e.headers?e.headers.get("content-disposition"):void 0,m=d?/filename="?([^"]*?)"?(;|$)/g.exec(d):void 0,h=m&&m.length>1?m[1]:void 0;return n.of({fileName:h,data:s,status:p,headers:i})}return 401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.renderDesignPreviewToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/render-preview/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processRenderDesignPreviewToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processRenderDesignPreviewToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderDesignPreviewToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderDesignProof=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/render-proof?";if(null!=e&&(s+="attachment="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(s+="tenantId="+encodeURIComponent(""+r)+"&"),s=s.replace(/[?&]$/,"");var i={body:JSON.stringify(a),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("post",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processRenderDesignProof(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processRenderDesignProof(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderDesignProof=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.renderDesignProofToResource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/render-proof/to-resource?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processRenderDesignProofToResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processRenderDesignProofToResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processRenderDesignProofToResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):409===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Conflict",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.loadProduct=function(e,r,a){var p=this,s=this.baseUrl+"/api/atoms/v1/designs/{id}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(s=s.replace("{id}",encodeURIComponent(""+e)),null!=r&&(s+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(s+="tenantId="+encodeURIComponent(""+a)+"&"),s=s.replace(/[?&]$/,"");var i={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(i)).pipe(t.mergeMap((function(e){return p.http.request("get",s,e)}))).pipe(t.mergeMap((function(e){return p.transformResult(s,e,(function(e){return p.processLoadProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return p.transformResult(s,e,(function(e){return p.processLoadProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processLoadProduct=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.saveProduct=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/designs/{id}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(i=i.replace("{id}",encodeURIComponent(""+e)),null!=r&&(i+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(i+="tenantId="+encodeURIComponent(""+a)+"&"),i=i.replace(/[?&]$/,"");var u={body:JSON.stringify(p),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json"})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("put",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processSaveProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processSaveProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSaveProduct=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.patchProduct=function(e,r,a,p,s,i,u,c,l){var f=this,d=this.baseUrl+"/api/atoms/v1/designs/{id}/model?";if(null==e)throw new Error("The parameter 'id' must be defined.");if(d=d.replace("{id}",encodeURIComponent(""+e)),null!=r&&(d+="privateStorageOwner="+encodeURIComponent(""+r)+"&"),null===a)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==a&&(d+="tenantId="+encodeURIComponent(""+a)+"&"),d=d.replace(/[?&]$/,"");var m=new FormData;null!=p&&m.append("patchType",p.toString()),null!=s&&m.append("replaceImageItemFileInfo.itemName",s.toString()),null!=i&&m.append("replaceImageItemFileInfo.sourceFile",i.data,i.fileName?i.fileName:"replaceImageItemFileInfo.sourceFile"),null!=u&&m.append("replacePlaceholderItemContentInfo.placeholderItemName",u.toString()),null!=c&&m.append("replacePlaceholderItemContentInfo.newContentType",c.toString()),null!=l&&m.append("replacePlaceholderItemContentInfo.sourceFile",l.data,l.fileName?l.fileName:"replacePlaceholderItemContentInfo.sourceFile");var h={body:m,observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(h)).pipe(t.mergeMap((function(e){return f.http.request("patch",d,e)}))).pipe(t.mergeMap((function(e){return f.transformResult(d,e,(function(e){return f.processPatchProduct(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return f.transformResult(d,e,(function(e){return f.processPatchProduct(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processPatchProduct=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){return n.of(null)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createItem=function(e,r,a,p,s,i,u){var c=this,l=this.baseUrl+"/api/atoms/v1/designs/model/items?";if(null!=e&&(l+="itemType="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(l+="tenantId="+encodeURIComponent(""+r)+"&"),l=l.replace(/[?&]$/,"");var f=new FormData;null!=a&&f.append("sourceType",a.toString()),null!=p&&f.append("sourceId",p.toString()),null!=s&&f.append("sourceOwnerId",s.toString()),null!=i&&f.append("url",i.toString()),null!=u&&f.append("sourceFile",u.data,u.fileName?u.fileName:"sourceFile");var d={body:f,observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(d)).pipe(t.mergeMap((function(e){return c.http.request("post",l,e)}))).pipe(t.mergeMap((function(e){return c.transformResult(l,e,(function(e){return c.processCreateItem(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return c.transformResult(l,e,(function(e){return c.processCreateItem(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreateItem=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.extractItemImage=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/model/items/extract-image?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processExtractItemImage(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processExtractItemImage(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processExtractItemImage=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}if(200===p||206===p){var d=e.headers?e.headers.get("content-disposition"):void 0,m=d?/filename="?([^"]*?)"?(;|$)/g.exec(d):void 0,h=m&&m.length>1?m[1]:void 0;return n.of({fileName:h,data:s,status:p,headers:i})}return 401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.flattenItems=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/designs/model/items/flatten?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processFlattenItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processFlattenItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFlattenItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):403===s?_(i).pipe(t.mergeMap((function(e){return V("Forbidden",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.createPrivateDesignFromDesign=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/private-designs/from-design?";if(null!=e&&(i+="designId="+encodeURIComponent(""+e)+"&"),null!=r&&(i+="privateDesignId="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("post",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processCreatePrivateDesignFromDesign(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processCreatePrivateDesignFromDesign(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreatePrivateDesignFromDesign=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}return 201===p?_(s).pipe(t.mergeMap((function(e){return n.of(null)}))):401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r.prototype.createPrivateDesignFromResource=function(e,r,a,p){var s=this,i=this.baseUrl+"/api/atoms/v1/private-designs/from-resource?";if(null!=e&&(i+="resourceId="+encodeURIComponent(""+e)+"&"),null!=r&&(i+="privateDesignId="+encodeURIComponent(""+r)+"&"),null!=a&&(i+="privateStorageOwner="+encodeURIComponent(""+a)+"&"),null===p)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==p&&(i+="tenantId="+encodeURIComponent(""+p)+"&"),i=i.replace(/[?&]$/,"");var u={observe:"response",responseType:"blob",headers:new o.HttpHeaders({})};return n.from(this.transformOptions(u)).pipe(t.mergeMap((function(e){return s.http.request("post",i,e)}))).pipe(t.mergeMap((function(e){return s.transformResult(i,e,(function(e){return s.processCreatePrivateDesignFromResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return s.transformResult(i,e,(function(e){return s.processCreatePrivateDesignFromResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCreatePrivateDesignFromResource=function(e){var r,a,p=e.status,s=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,i={};if(e.headers)try{for(var c=u(e.headers.keys()),l=c.next();!l.done;l=c.next()){var f=l.value;i[f]=e.headers.get(f)}}catch(e){r={error:e}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(r)throw r.error}}return 201===p?_(s).pipe(t.mergeMap((function(e){return n.of(null)}))):401===p?_(s).pipe(t.mergeMap((function(e){return V("Unauthorized",p,e,i)}))):403===p?_(s).pipe(t.mergeMap((function(e){return V("Forbidden",p,e,i)}))):200!==p&&204!==p?_(s).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",p,e,i)}))):n.of(null)},r}(f);w.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new w(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:w,providedIn:"root"}),w.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],w.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]};var I,M,U,C,H,E,S,T,x,O,j,P,N,A,B,F,J,D,k,q,$,z,G=function(e){function r(r,t,n){var o=e.call(this,r)||this;return o.jsonParseReviver=void 0,o.http=t,o.baseUrl=null!=n?n:o.getBaseUrl(""),o}return p(r,e),r.prototype.cssFonts=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/cssfonts?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"text/css"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processCssFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processCssFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processCssFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.fonts=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/fonts/{psName}?";if(null==e)throw new Error("The parameter 'psName' must be defined.");if(p=p.replace("{psName}",encodeURIComponent(""+e)),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getColorPreview=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetColorPreview?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetColorPreview(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetColorPreview(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetColorPreview=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getColorPreviews=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetColorPreviews?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetColorPreviews(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetColorPreviews(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetColorPreviews=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):400===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Bad Request",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getCssFont=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetCssFont?";if(null!=e&&(p+="fontKey="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetCssFont(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetCssFont(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetCssFont=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getFallbackFonts=function(e){var r=this,a=this.baseUrl+"/api/atoms/v1/ccviewer/GetFallbackFonts?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(a+="tenantId="+encodeURIComponent(""+e)+"&"),a=a.replace(/[?&]$/,"");var p={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(p)).pipe(t.mergeMap((function(e){return r.http.request("get",a,e)}))).pipe(t.mergeMap((function(e){return r.transformResult(a,e,(function(e){return r.processGetFallbackFonts(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return r.transformResult(a,e,(function(e){return r.processGetFallbackFonts(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetFallbackFonts=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getImageSize=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetImageSize?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetImageSize(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetImageSize(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetImageSize=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getShapeBounds=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetShapeBounds?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetShapeBounds(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetShapeBounds(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetShapeBounds=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getWatermarkItems=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/GetWatermarkItems?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processGetWatermarkItems(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processGetWatermarkItems(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetWatermarkItems=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.img=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y,R,b,w,I,M){var U=this,C=this.baseUrl+"/api/atoms/v1/ccviewer/img?";if(null!=e&&(C+="f="+encodeURIComponent(""+e)+"&"),null!=r&&(C+="w="+encodeURIComponent(""+r)+"&"),null!=a&&(C+="h="+encodeURIComponent(""+a)+"&"),null!=p&&(C+="cmyk="+encodeURIComponent(""+p)+"&"),null!=s&&(C+="rgb="+encodeURIComponent(""+s)+"&"),null!=i&&(C+="grayscale="+encodeURIComponent(""+i)+"&"),null!=u&&(C+="target="+encodeURIComponent(""+u)+"&"),null!=c&&(C+="sq="+encodeURIComponent(""+c)+"&"),null!=l&&(C+="effect="+encodeURIComponent(""+l)+"&"),null!=f&&(C+="kp="+encodeURIComponent(""+f)+"&"),null!=d&&(C+="color="+encodeURIComponent(""+d)+"&"),null!=m&&(C+="obm="+encodeURIComponent(""+m)+"&"),null!=h&&(C+="oo="+encodeURIComponent(""+h)+"&"),null!=v&&(C+="alphaMask="+encodeURIComponent(""+v)+"&"),null!=g&&(C+="page="+encodeURIComponent(""+g)+"&"),null!=y&&(C+="colorizeColor="+encodeURIComponent(""+y)+"&"),null!=R&&(C+="rw="+encodeURIComponent(""+R)+"&"),null!=b&&(C+="rh="+encodeURIComponent(""+b)+"&"),null!=w&&(C+="dt="+encodeURIComponent(""+w)+"&"),null!=I&&(C+="da="+encodeURIComponent(""+I)+"&"),null===M)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==M&&(C+="tenantId="+encodeURIComponent(""+M)+"&"),C=C.replace(/[?&]$/,"");var H={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(H)).pipe(t.mergeMap((function(e){return U.http.request("get",C,e)}))).pipe(t.mergeMap((function(e){return U.transformResult(C,e,(function(e){return U.processImg(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return U.transformResult(C,e,(function(e){return U.processImg(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processImg=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.getLicense=function(e){var r=this,a=this.baseUrl+"/api/atoms/v1/ccviewer/license?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(a+="tenantId="+encodeURIComponent(""+e)+"&"),a=a.replace(/[?&]$/,"");var p={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/json"})};return n.from(this.transformOptions(p)).pipe(t.mergeMap((function(e){return r.http.request("get",a,e)}))).pipe(t.mergeMap((function(e){return r.transformResult(a,e,(function(e){return r.processGetLicense(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return r.transformResult(a,e,(function(e){return r.processGetLicense(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processGetLicense=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.pth=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/pth?";if(null!=e&&(p+="f="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processPth(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processPth(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processPth=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.resource=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/resource?";if(null!=e&&(p+="image="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processResource(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processResource(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processResource=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.svg=function(e,r,a,p,s,i,u,c,l,f,d,m,h,v,g,y,R,b,w,I,M){var U=this,C=this.baseUrl+"/api/atoms/v1/ccviewer/svg?";if(null!=e&&(C+="f="+encodeURIComponent(""+e)+"&"),null!=r&&(C+="w="+encodeURIComponent(""+r)+"&"),null!=a&&(C+="h="+encodeURIComponent(""+a)+"&"),null!=p&&(C+="cmyk="+encodeURIComponent(""+p)+"&"),null!=s&&(C+="rgb="+encodeURIComponent(""+s)+"&"),null!=i&&(C+="grayscale="+encodeURIComponent(""+i)+"&"),null!=u&&(C+="target="+encodeURIComponent(""+u)+"&"),null!=c&&(C+="sq="+encodeURIComponent(""+c)+"&"),null!=l&&(C+="effect="+encodeURIComponent(""+l)+"&"),null!=f&&(C+="kp="+encodeURIComponent(""+f)+"&"),null!=d&&(C+="color="+encodeURIComponent(""+d)+"&"),null!=m&&(C+="obm="+encodeURIComponent(""+m)+"&"),null!=h&&(C+="oo="+encodeURIComponent(""+h)+"&"),null!=v&&(C+="alphaMask="+encodeURIComponent(""+v)+"&"),null!=g&&(C+="page="+encodeURIComponent(""+g)+"&"),null!=y&&(C+="colorizeColor="+encodeURIComponent(""+y)+"&"),null!=R&&(C+="rw="+encodeURIComponent(""+R)+"&"),null!=b&&(C+="rh="+encodeURIComponent(""+b)+"&"),null!=w&&(C+="dt="+encodeURIComponent(""+w)+"&"),null!=I&&(C+="da="+encodeURIComponent(""+I)+"&"),null===M)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==M&&(C+="tenantId="+encodeURIComponent(""+M)+"&"),C=C.replace(/[?&]$/,"");var H={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(H)).pipe(t.mergeMap((function(e){return U.http.request("get",C,e)}))).pipe(t.mergeMap((function(e){return U.transformResult(C,e,(function(e){return U.processSvg(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return U.transformResult(C,e,(function(e){return U.processSvg(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processSvg=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.txt=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/txt?";if(null!=e&&(p+="f="+encodeURIComponent(""+e)+"&"),null===r)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==r&&(p+="tenantId="+encodeURIComponent(""+r)+"&"),p=p.replace(/[?&]$/,"");var s={observe:"response",responseType:"blob",headers:new o.HttpHeaders({Accept:"application/octet-stream"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("get",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processTxt(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processTxt(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processTxt=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}if(200===s||206===s){var m=e.headers?e.headers.get("content-disposition"):void 0,h=m?/filename="?([^"]*?)"?(;|$)/g.exec(m):void 0,v=h&&h.length>1?h[1]:void 0;return n.of({fileName:v,data:i,status:s,headers:c})}return 304===s?_(i).pipe(t.mergeMap((function(e){return V("Not Modified",s,e,c)}))):404===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),V("Not Found",s,e,c,r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateArchedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateArchedTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateArchedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateArchedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateArchedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateAutoScaledTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateAutoScaledTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateAutoScaledTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateAutoScaledTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateAutoScaledTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateBarcodeItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateBarcodeItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateBarcodeItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateBarcodeItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateBarcodeItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateBoundedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateBoundedTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateBoundedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateBoundedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateBoundedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateByColorData=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateByColorData?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateByColorData(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateByColorData(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateByColorData=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateByMultiCallRequest=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateByMultiCallRequest?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateByMultiCallRequest(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateByMultiCallRequest(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateByMultiCallRequest=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateCurvedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateCurvedTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateCurvedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateCurvedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateCurvedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateImageItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateImageItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateImageItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateImageItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateImageItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updatePathBoundedTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdatePathBoundedTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdatePathBoundedTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdatePathBoundedTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdatePathBoundedTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updatePlainTextItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdatePlainTextItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdatePlainTextItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdatePlainTextItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdatePlainTextItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r.prototype.updateShapeItemHandler=function(e,r){var a=this,p=this.baseUrl+"/api/atoms/v1/ccviewer/UpdateShapeItemHandler?";if(null===e)throw new Error("The parameter 'tenantId' cannot be null.");void 0!==e&&(p+="tenantId="+encodeURIComponent(""+e)+"&"),p=p.replace(/[?&]$/,"");var s={body:JSON.stringify(r),observe:"response",responseType:"blob",headers:new o.HttpHeaders({"Content-Type":"application/json",Accept:"application/json"})};return n.from(this.transformOptions(s)).pipe(t.mergeMap((function(e){return a.http.request("post",p,e)}))).pipe(t.mergeMap((function(e){return a.transformResult(p,e,(function(e){return a.processUpdateShapeItemHandler(e)}))}))).pipe(t.catchError((function(e){if(!(e instanceof o.HttpResponseBase))return n.throwError(e);try{return a.transformResult(p,e,(function(e){return a.processUpdateShapeItemHandler(e)}))}catch(e){return n.throwError(e)}})))},r.prototype.processUpdateShapeItemHandler=function(e){var r,a,p=this,s=e.status,i=e instanceof o.HttpResponse?e.body:e.error instanceof Blob?e.error:void 0,c={};if(e.headers)try{for(var l=u(e.headers.keys()),f=l.next();!f.done;f=l.next()){var d=f.value;c[d]=e.headers.get(d)}}catch(e){r={error:e}}finally{try{f&&!f.done&&(a=l.return)&&a.call(l)}finally{if(r)throw r.error}}return 200===s?_(i).pipe(t.mergeMap((function(e){var r;return r=""===e?null:JSON.parse(e,p.jsonParseReviver),n.of(r)}))):401===s?_(i).pipe(t.mergeMap((function(e){return V("Unauthorized",s,e,c)}))):200!==s&&204!==s?_(i).pipe(t.mergeMap((function(e){return V("An unexpected server error occurred.",s,e,c)}))):n.of(null)},r}(f);G.ɵprov=r.ɵɵdefineInjectable({factory:function(){return new G(r.ɵɵinject(l),r.ɵɵinject(o.HttpClient),r.ɵɵinject(c,8))},token:G,providedIn:"root"}),G.decorators=[{type:r.Injectable,args:[{providedIn:"root"}]}],G.ctorParameters=function(){return[{type:l,decorators:[{type:r.Inject,args:[l]}]},{type:o.HttpClient,decorators:[{type:r.Inject,args:[o.HttpClient]}]},{type:String,decorators:[{type:r.Optional},{type:r.Inject,args:[c]}]}]},(I=e.ArtworkShapeType||(e.ArtworkShapeType={})).Rectangle="rectangle",I.Ellipse="ellipse",(M=e.ColorlessContainerDisplayType||(e.ColorlessContainerDisplayType={})).Color="Color",M.Texture="Texture",(U=e.ColorlessContainerDitherType||(e.ColorlessContainerDitherType={})).None="None",U.Diffusion="Diffusion",U.Pattern="Pattern",U.Noise="Noise",(C=e.ColorlessContainerFormat||(e.ColorlessContainerFormat={})).OneBit="OneBit",C.Grayscale="Grayscale",C.Vector="Vector",(H=e.ConflictType||(e.ConflictType={})).NameConflict="NameConflict",H.FolderOverwriteConflict="FolderOverwriteConflict",H.IdConflict="IdConflict",H.GeneralConflict="GeneralConflict",(E=e.ContainerColorSpace||(e.ContainerColorSpace={})).Rgb="Rgb",E.Cmyk="Cmyk",E.Grayscale="Grayscale",E.Lab="Lab",E.Spot="Spot",(S=e.ContainerPrintingMode||(e.ContainerPrintingMode={})).FullColor="FullColor",S.LimitedColor="LimitedColor",S.Colorless="Colorless",(T=e.DesignElementType||(e.DesignElementType={})).Product="Product",T.Design="Design",T.Surface="Surface",T.Container="Container",T.PrintArea="PrintArea",T.Item="Item",(x=e.ImageExtractionFormat||(e.ImageExtractionFormat={})).AsIs="AsIs",x.Jpeg="Jpeg",x.Png="Png",(O=e.ImagePreviewFitMode||(e.ImagePreviewFitMode={})).Fit="Fit",O.Shrink="Shrink",O.Resize="Resize",O.Fill="Fill",(j=e.ImagePreviewFormat||(e.ImagePreviewFormat={})).Jpeg="Jpeg",j.Png="Png",(P=e.ItemBorderStyle||(e.ItemBorderStyle={})).Solid="Solid",P.Dashed="Dashed",(N=e.ItemSourceType||(e.ItemSourceType={})).File="File",N.ImageStorage="ImageStorage",N.PrivateImageStorage="PrivateImageStorage",N.Url="Url",(A=e.ItemType||(e.ItemType={})).Image="Image",A.Shape="Shape",A.Clipart="Clipart",A.Group="Group",(B=e.MockupPreviewFitMode||(e.MockupPreviewFitMode={})).Fit="Fit",B.Shrink="Shrink",B.Resize="Resize",B.Fill="Fill",(F=e.MockupPreviewFormat||(e.MockupPreviewFormat={})).Jpeg="Jpeg",F.Png="Png",(e.PlaceholderItemContentType||(e.PlaceholderItemContentType={})).Image="Image",(J=e.ProductPatchType||(e.ProductPatchType={})).Undefined="Undefined",J.ReplaceImageItemFile="ReplaceImageItemFile",J.ReplacePlaceholderItemContent="ReplacePlaceholderItemContent",(D=e.ProductPreviewFormat||(e.ProductPreviewFormat={})).Jpeg="Jpeg",D.Png="Png",(k=e.ProductProofFormat||(e.ProductProofFormat={})).Jpeg="Jpeg",k.Png="Png",k.Tiff="Tiff",k.Pdf="Pdf",(q=e.ProductProofInterpolationMode||(e.ProductProofInterpolationMode={})).High="High",q.Medium="Medium",q.Low="Low",q.NearestNeighbour="NearestNeighbour",q.Linear="Linear",q.Cubic="Cubic",q.Supersampling="Supersampling",q.Lanczos="Lanczos",q.Anisotropic4="Anisotropic4",q.Anisotropic9="Anisotropic9",q.Lanczos3="Lanczos3",($=e.TextAlignment||(e.TextAlignment={})).Left="Left",$.Center="Center",$.Right="Right",$.All="All",$.LastLeft="LastLeft",$.LastRight="LastRight",$.LastCenter="LastCenter",(z=e.TextVerticalAlignment||(e.TextVerticalAlignment={})).Top="Top",z.Center="Center",z.Bottom="Bottom";var L=function(e){function r(r,t,n,o,a){var p=e.call(this)||this;return p.isApiException=!0,p.message=r,p.status=t,p.response=n,p.headers=o,p.result=a,p}return p(r,e),r.isApiException=function(e){return!0===e.isApiException},r}(Error);function V(e,r,t,o,a){return n.throwError(new L(e,r,t,o,a))}function _(e){return new n.Observable((function(r){if(e){var t=new FileReader;t.onload=function(e){r.next(e.target.result),r.complete()},t.readAsText(e)}else r.next(""),r.complete()}))}function W(e,r,t){void 0===t&&(t="ApiKey");var n=new l;return n.apiKey=t,n.apiUrl=r,n.setAuthorizationToken(e),n}var K=function(){function e(){}return e.forRoot=function(r,t,n){return void 0===n&&(n="ApiKey"),{ngModule:e,providers:[{provide:c,useValue:t},{provide:l,useFactory:W.bind(this,r,t,n)}]}},e}();K.decorators=[{type:r.NgModule,args:[{declarations:[],imports:[],exports:[]}]}],e.API_BASE_URL=c,e.ApiClientBase=f,e.ApiClientConfiguration=l,e.ApiException=L,e.BuildInfoApiClient=d,e.CreateApiClientConfiguration=W,e.DesignAtomsApiModule=K,e.DesignAtomsCompatibilityApiClient=m,e.DesignAtomsImagesApiClient=h,e.DesignAtomsMockups2dApiClient=v,e.DesignAtomsMockups3dApiClient=g,e.DesignAtomsPalettesApiClient=y,e.DesignAtomsPrintProductApiClient=R,e.DesignAtomsPrintProductItemsApiClient=b,e.DesignAtomsServiceApiClient=w,e.DesignAtomsViewerApiClient=G,Object.defineProperty(e,"__esModule",{value:!0})}));
|
|
16
16
|
//# sourceMappingURL=aurigma-ng-design-atoms-api-client.umd.min.js.map
|