Lighting.js
1.97 KB
// All material copyright ESRI, All Rights Reserved, unless otherwise specified.
// See https://js.arcgis.com/4.6/esri/copyright.txt for details.
//>>built
define("require exports ../core/tsSupport/declareExtendsHelper ../core/tsSupport/decorateHelper ../core/JSONSupport ../core/accessorSupport/decorators".split(" "),function(l,m,g,c,h,b){return function(f){function a(d){d=f.call(this,d)||this;d.date=null;d.directShadowsEnabled=!1;d.displayUTCOffset=null;return d}g(a,f);e=a;a.prototype.readDate=function(d,a){return null!=a.datetime&&new Date(a.datetime)||null};a.prototype.writeDate=function(a,k,b){k[b]=a.getTime()};a.prototype.readDirectShadowsEnabled=
function(a,b){return!!b.directShadows};a.prototype.writedirectShadowsEnabled=function(a,b,c){a&&(b[c]=a)};a.prototype.writeDisplayUTCOffset=function(a,b){null!=a&&(b.displayUTCOffset=a)};a.prototype.clone=function(){return new e({date:null!=this.date?new Date(this.date.getTime()):null,directShadowsEnabled:this.directShadowsEnabled,displayUTCOffset:null!=this.displayUTCOffset?this.displayUTCOffset:null})};a.sanitizeJSON=function(a){var b={datetime:a.datetime};void 0!==a.directShadows&&(b.directShadows=
!!a.directShadows);void 0!==a.displayUTCOffset&&(b.displayUTCOffset=a.displayUTCOffset);return b};c([b.property({type:Date,json:{type:Number,write:{target:"datetime"}}})],a.prototype,"date",void 0);c([b.reader("date",["datetime"])],a.prototype,"readDate",null);c([b.writer("date")],a.prototype,"writeDate",null);c([b.property({type:Boolean,json:{write:{target:"directShadows"}}})],a.prototype,"directShadowsEnabled",void 0);c([b.reader("directShadowsEnabled",["directShadows"])],a.prototype,"readDirectShadowsEnabled",
null);c([b.writer("directShadowsEnabled")],a.prototype,"writedirectShadowsEnabled",null);c([b.property({type:Number,json:{write:!0}})],a.prototype,"displayUTCOffset",void 0);c([b.writer("displayUTCOffset")],a.prototype,"writeDisplayUTCOffset",null);return a=e=c([b.subclass("esri.webscene.Lighting")],a);var e}(b.declared(h))});