/*
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","../../geometry","../../Graphic","../../core/JSONSupport","../../core/maybe","../../core/accessorSupport/decorators/property","../../core/arrayUtils","../../core/has","../../core/accessorSupport/ensureType","../../core/accessorSupport/decorators/reader","../../core/accessorSupport/decorators/subclass","../../core/accessorSupport/decorators/writer","../../geometry/support/typeUtils"],(function(e,r,t,o,p,a,s,u,i,c,y,n,l,d){"use strict";let _=function(r){function t(e){var t;return(t=r.call(this,e)||this).displayFieldName=null,t.feature=null,t.foundFieldName=null,t.layerId=null,t.layerName=null,t.value=void 0,t}e._inheritsLoose(t,r);var p=t.prototype;return p.readFeature=function(e,r){const t={attributes:{}};return r.attributes&&(t.attributes=r.attributes),r.geometry&&(t.geometry=r.geometry),o.fromJSON(t)},p.writeFeature=function(e,r){if(!e)return;const{attributes:t,geometry:o}=e;t&&(r.attributes={...t}),a.isSome(o)&&(r.geometry=o.toJSON(),r.geometryType=d.typeKebabDictionary.toJSON(o.type))},t}(p.JSONSupport);r.__decorate([s.property({type:String,json:{write:!0}})],_.prototype,"displayFieldName",void 0),r.__decorate([s.property({type:o})],_.prototype,"feature",void 0),r.__decorate([y.reader("feature",["attributes","geometry"])],_.prototype,"readFeature",null),r.__decorate([l.writer("feature")],_.prototype,"writeFeature",null),r.__decorate([s.property({type:String,json:{write:!0}})],_.prototype,"foundFieldName",void 0),r.__decorate([s.property({type:Number,json:{write:!0}})],_.prototype,"layerId",void 0),r.__decorate([s.property({type:String,json:{write:!0}})],_.prototype,"layerName",void 0),r.__decorate([s.property({json:{write:!0}})],_.prototype,"value",void 0),_=r.__decorate([n.subclass("esri.rest.support.FindResult")],_);return _}));
