/*
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
See https://js.arcgis.com/4.24/esri/copyright.txt for details.
*/
define(["../../chunks/_rollupPluginBabelHelpers","../../chunks/tslib.es6","../../core/JSONSupport","../../core/accessorSupport/decorators/property","../../core/arrayUtils","../../core/has","../../core/accessorSupport/ensureType","../../core/accessorSupport/decorators/subclass","./VoxelDimension"],(function(e,s,i,r,o,t,n,u,p){"use strict";let c=function(s){function i(){var e;return(e=s.apply(this,arguments)||this).id=0,e.dimensions=null,e}e._inheritsLoose(i,s);var r=i.prototype;return r.getZDimension=function(){if(!this.dimensions)return-1;if(!Array.isArray(this.dimensions))return-1;if(4!==this.dimensions.length)return-1;for(let e=2;e<4;++e)if(this.dimensions[e].size>0)return e;return-1},r.isVolumeValid=function(){return!!this.dimensions&&(!!Array.isArray(this.dimensions)&&(4===this.dimensions.length&&(!(this.dimensions[0].size<1||this.dimensions[1].size<1)&&-1!==this.getZDimension())))},i}(i.JSONSupport);s.__decorate([r.property({type:Number,json:{write:{enabled:!0,isRequired:!0}}})],c.prototype,"id",void 0),s.__decorate([r.property({type:[p],json:{write:{enabled:!0,isRequired:!0}}})],c.prototype,"dimensions",void 0),c=s.__decorate([u.subclass("esri.layers.support.VoxelVolume")],c);return c}));
