import{E as a,Pd as v,Qf as d,Sc as C,Uc as o,Wc as c,Xc as f,ad as S,ea as u,rb as l}from"./chunk-SKPDQO4E.js";var m=class extends f{http;sessionService;configurationService;interactionService;constructor(e,r,t,i){super(e,r,t,i),this.http=e,this.sessionService=r,this.configurationService=t,this.interactionService=i}listCameras(e){return this.requestPost(`/${this.sessionService.currentOrganizationId}/camera/list`,e,"CameraListResponse",o.User,c.User)}upsertCamera(e){return this.requestPost(`/${this.sessionService.currentOrganizationId}/camera/upsert`,e,null,o.User,c.User)}deleteCamera(e){return this.requestDeleteEmptyResponse(`/${this.sessionService.currentOrganizationId}/camera/${e}`,o.User)}getCameraSnapshot(e,r){return this.requestPost(`/${this.sessionService.currentOrganizationId}/report/accesssnapshot/${e}/${r}`,{},"CameraSnapshotResponse",o.User,c.User,!1)}getCamera(e){return this.requestGet(`/${this.sessionService.currentOrganizationId}/camera/${e}`,"CameraBasic",o.User,c.User)}};var I=function(n,e,r,t){var i=arguments.length,s=i<3?e:t===null?t=Object.getOwnPropertyDescriptor(e,r):t,p;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")s=Reflect.decorate(n,e,r,t);else for(var h=n.length-1;h>=0;h--)(p=n[h])&&(s=(i<3?p(s):i>3?p(e,r,s):p(e,r))||s);return i>3&&s&&Object.defineProperty(e,r,s),s},g=class extends C{http;configurationService;interactionService;sessionService;apiCamera;constructor(e,r,t,i){super(t,i),this.http=e,this.configurationService=r,this.interactionService=t,this.sessionService=i,this.apiCamera=new m(this.http,this.sessionService,this.configurationService,this.interactionService)}listCameras(e){return this.apiCamera.listCameras(e).pipe(a(r=>this.handleError(r,[])))}upsertCamera(e){return this.apiCamera.upsertCamera(e).pipe(a(r=>this.handleError(r,[])))}deleteCamera(e){return this.apiCamera.deleteCamera(e).pipe(a(r=>this.handleError(r,[])))}getCameraSnapshot(e,r){return this.apiCamera.getCameraSnapshot(e,r).pipe(a(t=>this.handleError(t,[{code:500,message:null},{code:410,message:null},{code:411,message:null}])))}getCamera(e){return this.apiCamera.getCamera(e).pipe(a(r=>this.handleError(r,[])))}static ctorParameters=()=>[{type:l},{type:S},{type:d},{type:v}]};g=I([u({providedIn:"root"})],g);export{g as a};
