import {a}from'./chunk-DCUKY2F4.js';import {b}from'./chunk-OLJXVUYE.js';import {PrivateNoneLocationSelection}from'@scandit/web-datacapture-core';var S=class{constructor(){this.codeDuplicateFilter=b.BarcodeCapture.BarcodeCaptureSettings.codeDuplicateFilter;this.locationSelection=null;this.enabledCompositeTypes=[];this.scanIntention="manual";this.properties={};this.symbologies={};this._arucoDictionary=null;}get enabledSymbologies(){return Object.keys(this.symbologies).filter(o=>{var e;return (e=this.symbologies[o])==null?void 0:e.isEnabled})}get compositeTypeDescriptions(){return b.CompositeTypeDescriptions.reduce((o,e)=>(o[e.types[0]]=e,o),{})}settingsForSymbology(o){if(!this.symbologies[o]){let e=b.SymbologySettings[o];e._symbology=o,this.symbologies[o]=e;}return this.symbologies[o]}setProperty(o,e){this.properties[o]=e;}getProperty(o){return this.properties[o]}enableSymbologies(o){for(let e of o)this.enableSymbology(e,true);}enableSymbology(o,e){this.settingsForSymbology(o).isEnabled=e,o==="aruco"&&(this._arucoDictionary=a.fromPreset("5X5_50"));}enableSymbologiesForCompositeTypes(o){for(let e of o)this.enableSymbologies(this.compositeTypeDescriptions[e].symbologies);}setArucoDictionary(o){this._arucoDictionary=o;}toJSONObject(){var e,i,r,n,s;let o={};return {codeDuplicateFilter:this.codeDuplicateFilter,enabledCompositeTypes:[...this.enabledCompositeTypes],locationSelection:(i=(e=this.locationSelection)==null?void 0:e.toJSONObject())!=null?i:PrivateNoneLocationSelection,properties:{...this.properties},symbologies:Object.keys(this.symbologies).reduce((c,l)=>{var a;let y=(a=this.symbologies[l])==null?void 0:a.toJSONObject();return y&&(c[l]=y),c},o),scanIntention:(r=this.scanIntention)!=null?r:null,arucoDictionary:(s=(n=this._arucoDictionary)==null?void 0:n.toJSONObject())!=null?s:null}}};export{S as a};