cedar-model-typescript-library 1.0.5 → 1.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.esm.js +1 -1
- package/index.esm.js.map +1 -1
- package/index.js +1 -1
- package/index.js.map +1 -1
- package/index.umd.js +1 -1
- package/index.umd.js.map +1 -1
- package/org/metadatacenter/io/reader/yaml/YamlAbstractArtifactReader.d.ts +0 -11
- package/org/metadatacenter/io/reader/yaml/YamlAbstractArtifactReader.d.ts.map +1 -1
- package/org/metadatacenter/io/reader/yaml/YamlTemplateElementReader.d.ts.map +1 -1
- package/org/metadatacenter/io/reader/yaml/YamlTemplateFieldReader.d.ts.map +1 -1
- package/org/metadatacenter/io/reader/yaml/YamlTemplateInstanceReader.d.ts.map +1 -1
- package/org/metadatacenter/io/reader/yaml/YamlTemplateReader.d.ts.map +1 -1
- package/org/metadatacenter/io/writer/yaml/YamlAbstractArtifactWriter.d.ts +4 -5
- package/org/metadatacenter/io/writer/yaml/YamlAbstractArtifactWriter.d.ts.map +1 -1
- package/org/metadatacenter/io/writer/yaml/YamlTemplateInstanceWriter.d.ts.map +1 -1
- package/org/metadatacenter/model/cedar/constants/CedarModel.d.ts +0 -5
- package/org/metadatacenter/model/cedar/constants/CedarModel.d.ts.map +1 -1
- package/org/metadatacenter/model/cedar/constants/YamlKeys.d.ts +0 -5
- package/org/metadatacenter/model/cedar/constants/YamlKeys.d.ts.map +1 -1
- package/package.json +1 -1
package/index.esm.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var e={5846(e,t,r){t.JsonReaderBehavior=t.C=void 0;const n=r(7639);t.C={STRICT:"strict",FEBRUARY_2024:"february-2024"};class a extends n.ReaderWriterBehavior{value;constructor(e,t){super(t),this.value=e}getValue(){return this.value}static STRICT=new a(t.C.STRICT,!1);static FEBRUARY_2024=new a(t.C.FEBRUARY_2024,!0)}t.JsonReaderBehavior=a},2022(e,t,r){t.JsonWriterBehavior=t.C=void 0;const n=r(7639);t.C={STRICT:"strict",FEBRUARY_2024:"february-2024"};class a extends n.ReaderWriterBehavior{value;_outputPages;_usePropertiesAtLanguage;_includeSkosNotationForLinksAndControlled;constructor(e,t,r,n,a){super(a),this.value=e,this._outputPages=t,this._usePropertiesAtLanguage=r,this._includeSkosNotationForLinksAndControlled=n}getValue(){return this.value}static STRICT=new a(t.C.STRICT,!1,!0,!0,!1);static FEBRUARY_2024=new a(t.C.FEBRUARY_2024,!0,!1,!1,!0);outputPages(){return this._outputPages}usePropertiesAtLanguage(){return this._usePropertiesAtLanguage}includeSkosNotationForLinksAndControlled(){return this._includeSkosNotationForLinksAndControlled}}t.JsonWriterBehavior=a},7639(e,t){t.ReaderWriterBehavior=void 0,t.ReaderWriterBehavior=class{_useWarningForKnownIssues;constructor(e){this._useWarningForKnownIssues=e}useWarningForKnownIssues(){return this._useWarningForKnownIssues}}},1395(e,t,r){t.YamlReaderBehavior=t.L=void 0;const n=r(7639);t.L={STRICT:"strict"};class a extends n.ReaderWriterBehavior{value;constructor(e,t){super(t),this.value=e}getValue(){return this.value}static STRICT=new a(t.L.STRICT,!1)}t.YamlReaderBehavior=a},9411(e,t,r){t.YamlWriterBehavior=t.D=void 0;const n=r(7639);t.D={STRICT:"strict"};class a extends n.ReaderWriterBehavior{value;constructor(e,t){super(t),this.value=e}getValue(){return this.value}static STRICT=new a(t.D.STRICT,!1)}t.YamlWriterBehavior=a},6568(e,t,r){t.CedarBuilders=void 0;const n=r(766),a=r(1762),i=r(4925),s=r(7889),o=r(1259),l=r(345),c=r(2875),d=r(8084),u=r(3675),m=r(9497),p=r(1667),h=r(2052),f=r(4675),T=r(9916),y=r(3138),E=r(2703),C=r(9521),g=r(5795),I=r(7674),A=r(9105),b=r(1513),R=r(7328),S=r(2376),_=r(3914),v=r(7162),N=r(3474),w=r(9062),L=r(6610);t.CedarBuilders=class{static templateBuilder(){return new n.TemplateBuilder}static templateElementBuilder(){return new a.TemplateElementBuilder}static templateInstanceBuilder(){return new i.TemplateInstanceBuilder}static textFieldBuilder(){return s.TextFieldBuilderImpl.create()}static textAreaBuilder(){return o.TextAreaBuilderImpl.create()}static temporalFieldBuilder(){return l.TemporalFieldBuilderImpl.create()}static phoneNumberFieldBuilder(){return d.PhoneNumberFieldBuilderImpl.create()}static numericFieldBuilder(){return u.NumericFieldBuilderImpl.create()}static emailFieldBuilder(){return p.EmailFieldBuilderImpl.create()}static attributeValueFieldBuilder(){return h.AttributeValueFieldBuilderImpl.create()}static youtubeFieldBuilder(){return I.StaticYoutubeFieldBuilderImpl.create()}static sectionBreakFieldBuilder(){return g.StaticSectionBreakFieldBuilderImpl.create()}static richTextFieldBuilder(){return C.StaticRichTextFieldBuilderImpl.create()}static pageBreakFieldBuilder(){return E.StaticPageBreakFieldBuilderImpl.create()}static imageFieldBuilder(){return y.StaticImageFieldBuilderImpl.create()}static linkFieldBuilder(){return m.LinkFieldBuilderImpl.create()}static extRorFieldBuilder(){return R.ExtRorFieldBuilderImpl.create()}static extOrcidFieldBuilder(){return S.ExtOrcidFieldBuilderImpl.create()}static extPfasFieldBuilder(){return _.ExtPfasFieldBuilderImpl.create()}static extPubmedFieldBuilder(){return v.ExtPubmedFieldBuilderImpl.create()}static extRridFieldBuilder(){return N.ExtRridFieldBuilderImpl.create()}static extNihGrantIdFieldBuilder(){return w.ExtNihGrantIdFieldBuilderImpl.create()}static extDoiFieldBuilder(){return L.ExtDoiFieldBuilderImpl.create()}static singleChoiceListFieldBuilder(){return A.SingleChoiceListFieldBuilderImpl.create()}static multipleChoiceListFieldBuilder(){return b.MultipleChoiceListFieldBuilderImpl.create()}static radioFieldBuilder(){return c.RadioFieldBuilderImpl.create()}static checkboxFieldBuilder(){return f.CheckboxFieldBuilderImpl.create()}static controlledTermFieldBuilder(){return T.ControlledTermFieldBuilderImpl.create()}}},1998(e,t,r){t.CedarReaders=void 0;const n=r(2103),a=r(8639);t.CedarReaders=class{static json(){return n.CedarJsonReaders}static yaml(){return a.CedarYamlReaders}}},8748(e,t,r){t.ReaderUtil=void 0;const n=r(9517),a=r(8802);t.ReaderUtil=class{static getString(e,t){return Object.hasOwn(e,t)?e[t]:null}static getStringOrEmpty(e,t){return Object.hasOwn(e,t)?e[t]:""}static getBoolean(e,t){return!!Object.hasOwn(e,t)&&e[t]}static getBooleanOrNullOrUndefined(e,t){return Object.hasOwn(e,t)?null===e[t]?null:e[t]:void 0}static getBooleanOrNull(e,t){return Object.hasOwn(e,t)?null===e[t]?null:e[t]:null}static getNumber(e,t){return Object.hasOwn(e,t)?e[t]:null}static getNumericDefault(e,t){if(!Object.hasOwn(e,t)||null===e[t]||void 0===e[t])return null;const r=e[t];if("number"==typeof r){if(Number.isFinite(r))return r;throw new Error(`Numeric default at "${t}" must be finite.`)}if("string"==typeof r){const e=r.trim();if(""===e)return null;if(!/^[+-]?(?:\d+(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+)?$/.test(e))throw new Error(`Numeric default at "${t}" is not a valid number: "${r}".`);const n=Number(e);if(Number.isFinite(n))return n;throw new Error(`Numeric default at "${t}" must be finite.`)}throw new Error(`Numeric default at "${t}" must be a number or numeric string.`)}static getNumberOrZero(e,t){return Object.hasOwn(e,t)?e[t]:0}static getNumberOrNull(e,t){return Object.hasOwn(e,t)?e[t]:null}static getNode(e,t){return Object.hasOwn(e,t)?e[t]:n.JsonNode.getEmpty()}static getNodeOrNull(e,t){return Object.hasOwn(e,t)?e[t]:null}static getStringList(e,t){return Object.hasOwn(e,t)&&Array.isArray(e[t])?e[t]:[]}static getFilteredStringList(e,t){return Object.hasOwn(e,t)&&Array.isArray(e[t])?e[t].filter(e=>""!==e.trim()):[]}static getStringMap(e,t){if(Object.hasOwn(e,t)&&"object"==typeof e[t]&&!Array.isArray(e[t])&&null!==e[t]){const r=e[t],n=Object.entries(r),a=new Map;for(const[e,t]of n)a.set(e,t);return a}return new Map}static deepClone(e){return this.deepUnfreeze(e)}static deepUnfreeze(e){if(null===e||"object"!=typeof e&&"function"!=typeof e)return e;const t=Array.isArray(e)?e.slice():{...e};return Object.getOwnPropertyNames(t).forEach(e=>{t[e]=this.deepUnfreeze(t[e])}),t}static deepFreeze(e){return Object.freeze(e),Object.getOwnPropertyNames(e).forEach(t=>{const r=e[t];null===r||"object"!=typeof r&&"function"!=typeof r||Object.isFrozen(r)||this.deepFreeze(r)}),e}static getNodeList(e,t){return Object.hasOwn(e,t)&&Array.isArray(e[t])?e[t]:n.JsonNode.getEmptyList()}static getURI(e,t){return new a.Iri(this.getStringOrEmpty(e,t))}static deleteNodeKey(e,t){Object.hasOwn(e,t)&&delete e[t]}}},2103(e,t,r){t.CedarJsonReaders=void 0;const n=r(2763),a=r(8748),i=r(2733),s=r(5291),o=r(7909),l=r(5846),c=r(9232),d=r(4381);class u{behavior;constructor(e){this.behavior=e}static getStrict(){return new u(l.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new u(l.JsonReaderBehavior.FEBRUARY_2024)}static detectArtifactType(e){let t;if(t="string"==typeof e?JSON.parse(e):e,t&&t["@type"]){const e=a.ReaderUtil.getString(t,i.JsonSchema.atType);return n.CedarArtifactType.forValue(e)}return n.CedarArtifactType.NULL}getReaderForArtifactType(e){switch(e){case n.CedarArtifactType.TEMPLATE:return s.JsonTemplateReader.getStrict();case n.CedarArtifactType.TEMPLATE_ELEMENT:return o.JsonTemplateElementReader.getStrict();case n.CedarArtifactType.TEMPLATE_FIELD:case n.CedarArtifactType.STATIC_TEMPLATE_FIELD:return d.JsonTemplateFieldReader.getStrict();case n.CedarArtifactType.TEMPLATE_INSTANCE:return c.JsonTemplateInstanceReader.getStrict();default:throw new Error(`No JSON reader available for CedarArtifactType: ${e}`)}}getTemplateReader(){return s.JsonTemplateReader.getForBehavior(this.behavior)}getTemplateElementReader(){return o.JsonTemplateElementReader.getForBehavior(this.behavior)}getTemplateFieldReader(){return d.JsonTemplateFieldReader.getForBehavior(this.behavior)}getTemplateInstanceReader(){return c.JsonTemplateInstanceReader.getForBehavior(this.behavior)}}t.CedarJsonReaders=u},7993(e,t,r){t.JsonAbstractArtifactReader=void 0;const n=r(8534),a=r(8748),i=r(2733),s=r(2234),o=r(9857),l=r(2763),c=r(5226),d=r(936),u=r(2787),m=r(3549);class p{static refuseEmptyIdentifier(e,t=i.JsonSchema.atId){const r=a.ReaderUtil.getString(e,t);if(null!==r&&""===r.trim())throw new Error(`An empty string is not a URI at "${t}"; write null or leave the key out where there is no value.`)}behavior;knownArtifactType=l.CedarArtifactType.NULL;constructor(e){this.behavior=e}readNonReportableAttributes(e,t){p.refuseEmptyIdentifier(t),e.at_id=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.atId)),e.schema_name=a.ReaderUtil.getString(t,i.JsonSchema.schemaName),e.schema_description=a.ReaderUtil.getString(t,i.JsonSchema.schemaDescription),e.pav_createdBy=s.CedarUser.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavCreatedBy)),e.pav_createdOn=o.IsoDate.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavCreatedOn)),e.oslc_modifiedBy=s.CedarUser.forValue(a.ReaderUtil.getString(t,i.JsonSchema.oslcModifiedBy)),e.pav_lastUpdatedOn=o.IsoDate.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavLastUpdatedOn))}readAnnotations(e,t){const r=new c.Annotations,n=a.ReaderUtil.getNodeOrNull(t,d.CedarModel.annotations);null!==n&&Object.keys(n).forEach(e=>{const t=a.ReaderUtil.getNode(n,e),s=a.ReaderUtil.getString(t,i.JsonSchema.atId);if(null!==s)r.add(new u.AnnotationAtId(e,s));else{const n=a.ReaderUtil.getString(t,i.JsonSchema.atValue);null!==n&&r.add(new m.AnnotationAtValue(e,n))}}),r.getSize()>0&&(e.annotations=r)}}t.JsonAbstractArtifactReader=p},3326(e,t,r){t.JsonAbstractInstanceArtifactReader=void 0;const n=r(8534),a=r(8748),i=r(2733),s=r(7993);class o extends s.JsonAbstractArtifactReader{constructor(e){super(e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.schema_isBasedOn=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.schemaIsBasedOn)),e.pav_derivedFrom=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavDerivedFrom))}}t.JsonAbstractInstanceArtifactReader=o},978(e,t,r){t.JsonAbstractSchemaArtifactReader=void 0;const n=r(8534),a=r(8748),i=r(2733),s=r(5747),o=r(8557),l=r(1027),c=r(3910),d=r(7993);class u extends d.JsonAbstractArtifactReader{constructor(e){super(e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.title=a.ReaderUtil.getString(t,s.TemplateProperty.title),e.description=a.ReaderUtil.getString(t,s.TemplateProperty.description),e.schema_schemaVersion=o.SchemaVersion.forValue(a.ReaderUtil.getString(t,i.JsonSchema.schemaVersion)),e.pav_version=l.PavVersion.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavVersion)),e.bibo_status=c.BiboStatus.forJsonValue(a.ReaderUtil.getString(t,i.JsonSchema.biboStatus)),e.pav_derivedFrom=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavDerivedFrom)),e.pav_previousVersion=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavPreviousVersion)),e.schema_identifier=a.ReaderUtil.getString(t,i.JsonSchema.schemaIdentifier)}}t.JsonAbstractSchemaArtifactReader=u},8518(e,t){t.JsonArtifactReaderResult=void 0,t.JsonArtifactReaderResult=class{_artifact;_parsingResult;_artifactSourceObject;constructor(e,t,r){this._artifact=e,this._parsingResult=t,this._artifactSourceObject=r}get artifact(){return this._artifact}get parsingResult(){return this._parsingResult}get artifactSourceObject(){return this._artifactSourceObject}}},5510(e,t,r){t.JsonContainerArtifactReader=void 0;const n=r(978),a=r(1492),i=r(455),s=r(2763),o=r(8748),l=r(2733),c=r(936),d=r(9034),u=r(2888),m=r(9760),p=r(3056),h=r(5793),f=r(2475),T=r(6968),y=r(3812),E=r(3608),C=r(3239),g=r(7752),I=r(8220);class A extends n.JsonAbstractSchemaArtifactReader{fieldReader;constructor(e){super(e),this.fieldReader=I.JsonTemplateFieldReaderInternal.getForBehavior(e)}readAndStoreCandidateChildInfo(e,t,r,n,a){const p=s.CedarArtifactType.forValue(o.ReaderUtil.getString(e,l.JsonSchema.atType));if(p!==s.CedarArtifactType.NULL){const r=new i.ChildDeploymentInfo(t);r.atType=p;const a=o.ReaderUtil.getNode(e,c.CedarModel.ui);return r.uiInputType=d.UiInputType.forValue(o.ReaderUtil.getString(a,c.CedarModel.inputType)),r.hidden=o.ReaderUtil.getBoolean(a,c.CedarModel.Ui.hidden),n.add(r),r}return this.reportBlueprintDifference(r,new u.ComparisonError("jtr09",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,a.add(t,l.JsonSchema.atType))),null}readReportableAttributes(e,t,r,n){p.JsonObjectComparator.comparePrimitive(r,this.knownArtifactType.getValue(),o.ReaderUtil.getString(t,l.JsonSchema.atType),n.add(l.JsonSchema.atType));const a=o.ReaderUtil.getNode(t,l.JsonSchema.atContext),i=T.JsonContainerArtifactContent.CONTEXT_VERBATIM;p.JsonObjectComparator.compareBothWays(r,i,a,n.add(l.JsonSchema.atContext),this.behavior,[l.JsonSchema.atLanguage]),p.JsonObjectComparator.comparePrimitive(r,h.JavascriptType.OBJECT.getValue(),o.ReaderUtil.getString(t,c.CedarModel.type),n.add(c.CedarModel.type)),p.JsonObjectComparator.comparePrimitive(r,f.ArtifactSchema.CURRENT.getValue(),o.ReaderUtil.getString(t,c.CedarModel.schema),n.add(c.CedarModel.schema)),e.language=g.Language.forValue(o.ReaderUtil.getString(a,l.JsonSchema.atLanguage))}parseChildren(e,t,r,n,a){for(const c of e.children){let e=o.ReaderUtil.getNode(t,c.name),d=a.add(l.JsonSchema.properties,c.name);if(c.isMultiInAnyWay()&&(e=o.ReaderUtil.getNode(e,l.JsonSchema.items),d=d.add(l.JsonSchema.items)),c.atType===s.CedarArtifactType.STATIC_TEMPLATE_FIELD){const t=this.fieldReader.readFromObjectInternal(e,c,d),a=t.field.createDeploymentBuilder(c.name).withLabel(c.label).withDescription(c.description).withHidden(c.hidden).build();r.addChild(t.field,a),n.merge(t.parsingResult)}else if(c.atType===s.CedarArtifactType.TEMPLATE_FIELD){const t=this.fieldReader.readFromObjectInternal(e,c,d),a=t.field.createDeploymentBuilder(c.name),s=c;a.withIri(s.iri).withHidden(s.hidden).withContinuePreviousLine(s.continuePreviousLine).withValueRecommendationEnabled(s.valueRecommendationEnabled).withLabel(c.label).withDescription(c.description).withRecommendedValue(s.recommendedValue).withRequiredValue(s.requiredValue),a instanceof E.ChildDeploymentInfoBuilder&&c instanceof i.ChildDeploymentInfo?a.withMultiInstance(c.multiInstance).withMinItems(c.minItems).withMaxItems(c.maxItems):a instanceof C.ChildDeploymentInfoAlwaysMultipleBuilder&&a.withMinItems(s.minItems).withMaxItems(s.maxItems);const o=a.build();r.addChild(t.field,o),n.merge(t.parsingResult)}else if(c.atType===s.CedarArtifactType.TEMPLATE_ELEMENT){const t=this.getElementReader().readFromObject(e,d);r.addChild(t.element,c),n.merge(t.parsingResult)}}}validatePropertiesVsOrder(e,t,r,n){for(const a of e.children)t.includes(a.name)||this.reportBlueprintDifference(r,new u.ComparisonError("jtr08",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,n.add(c.CedarModel.ui,c.CedarModel.order),a.name,null))}finalizeChildInfo(e,t,r,n){const i=new a.ContainerArtifactChildrenInfo;for(const a of e){const e=t.get(a);null!=e?i.add(e):this.reportBlueprintDifference(r,new u.ComparisonError("jtr07",m.ComparisonErrorType.UNEXPECTED_KEY_IN_REAL_OBJECT,n.add(c.CedarModel.ui,c.CedarModel.order),null,a))}return i}getCandidateChildrenInfo(e,t,r,n){const i=new a.ContainerArtifactChildrenInfo;return Object.keys(e).forEach(a=>{if(!t.has(a)){const t=o.ReaderUtil.getNode(e,a);if("object"==typeof t&&null!==t){let e=t;const s=o.ReaderUtil.getString(t,l.JsonSchema.type);if("object"==s)this.readAndStoreCandidateChildInfo(e,a,r,i,n.add(l.JsonSchema.properties,a));else if("array"==s){e=o.ReaderUtil.getNode(t,l.JsonSchema.items);const s=this.readAndStoreCandidateChildInfo(e,a,r,i,n.add(l.JsonSchema.properties,a,l.JsonSchema.items));null!==s&&(s.multiInstance=!0,s.minItems=o.ReaderUtil.getNumber(t,c.CedarModel.minItems),s.maxItems=o.ReaderUtil.getNumber(t,c.CedarModel.maxItems))}}}}),i}generateAndValidateRequiredMap(e,t,r,n){const a=e.reduce((e,t)=>(e.set(t,!0),e),new Map);for(const e of t)a.has(e)||this.reportBlueprintDifference(r,new u.ComparisonError("jtr01",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,n.add(l.JsonSchema.required),e));return a}checkRequiredBothWays(e,t,r,n,a,i){const s=e.getChildrenNamesForRequired();for(const e of s)t.has(e)||this.reportBlueprintDifference(a,new u.ComparisonError("jtr02",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,i.add(l.JsonSchema.required),e));for(const t of r)n.has(t)||e.has(t)||this.reportBlueprintDifference(a,new u.ComparisonError("jtr03",m.ComparisonErrorType.UNEXPECTED_KEY_IN_REAL_OBJECT,i.add(l.JsonSchema.required),t))}extractUIPreferredLabelsAndDescriptions(e,t,r,n){const a=o.ReaderUtil.getStringMap(e,c.CedarModel.propertyLabels);if(null!==a)for(const e of t.children)a.has(e.name)&&(e.label=a.get(e.name)??null);const i=o.ReaderUtil.getStringMap(e,c.CedarModel.propertyDescriptions);if(null!==i)for(const e of t.children)i.has(e.name)&&(e.description=i.get(e.name)??null)}reportBlueprintDifference(e,t){this.behavior.useWarningForKnownIssues()&&p.JsonObjectComparator.isKnownProductionVariation(t.errorPath)?e.addBlueprintComparisonWarning(t):e.addBlueprintComparisonError(t)}extractIRIMappings(e,t,r,n){const a=o.ReaderUtil.getNode(e,l.JsonSchema.atContext),i=o.ReaderUtil.getNode(a,l.JsonSchema.properties);for(const e of t.children)if(this.includeInIRIMapping(e)){const t=o.ReaderUtil.getNode(i,e.name),a=o.ReaderUtil.getStringList(t,l.JsonSchema.enum);null===a||1!=a.length?this.reportBlueprintDifference(r,new u.ComparisonError("jtr06",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,n.add(l.JsonSchema.properties,l.JsonSchema.atContext,l.JsonSchema.properties,e.name,l.JsonSchema.enum,0))):e instanceof y.AbstractDynamicChildDeploymentInfo&&(e.iri=a[0])}}readInstanceTypeSpecification(e,t,r){const n=o.ReaderUtil.getNode(t,l.JsonSchema.properties);if(null!==n){const t=o.ReaderUtil.getNode(n,l.JsonSchema.atType);if(null!==t){const r=o.ReaderUtil.getNodeList(t,l.JsonSchema.oneOf);null!==r&&r.forEach(t=>{const r=o.ReaderUtil.getStringList(t,l.JsonSchema.enum);null!=r&&r.length>0&&(e.instanceTypeSpecification=r[0])})}}}}t.JsonContainerArtifactReader=A},7909(e,t,r){t.JsonTemplateElementReader=void 0;const n=r(936),a=r(2733),i=r(2763),s=r(5747),o=r(8748),l=r(3056),c=r(4036),d=r(3188),u=r(5846),m=r(9932),p=r(4948),h=r(7661),f=r(5510),T=r(1501);class y extends f.JsonContainerArtifactReader{knownArtifactType=i.CedarArtifactType.TEMPLATE_ELEMENT;constructor(e){super(e)}static getStrict(){return new y(u.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new y(u.JsonReaderBehavior.FEBRUARY_2024)}static getForBehavior(e){return new y(e)}getElementReader(){return this}includeInIRIMapping(e){return e.atType!==i.CedarArtifactType.STATIC_TEMPLATE_FIELD}readFromString(e){let t;try{t=JSON.parse(e)}catch{t={}}return this.readFromObject(t,new d.JsonPath)}readFromObject(e,t=new d.JsonPath){const r=new c.JsonArtifactParsingResult,n=h.TemplateElement.buildEmptyWithNullValues();return this.readNonReportableAttributes(n,e),this.readReportableAttributes(n,e,r,t),this.readAnnotations(n,e),this.readInstanceTypeSpecification(n,e,r),this.readAndValidateChildrenInfo(n,e,r,t),new p.JsonTemplateElementReaderResult(n,r,e)}readNonReportableAttributes(e,t){e.skos_prefLabel=o.ReaderUtil.getString(t,n.CedarModel.skosPrefLabel),e.skos_altLabel=o.ReaderUtil.getFilteredStringList(t,n.CedarModel.skosAltLabel),super.readNonReportableAttributes(e,t)}readAndValidateChildrenInfo(e,t,r,i){const s=o.ReaderUtil.getStringList(t,a.JsonSchema.required),l=o.ReaderUtil.getNode(t,a.JsonSchema.properties),c=this.generateAndValidateRequiredMap(s,T.JsonTemplateElementContent.REQUIRED_PARTIAL,r,i),d=this.getCandidateChildrenInfo(l,T.JsonTemplateElementContent.PROPERTIES_PARTIAL_KEY_MAP,r,i);this.checkRequiredBothWays(d,c,s,T.JsonTemplateElementContent.REQUIRED_PARTIAL_KEY_MAP,r,i);const u=o.ReaderUtil.getNode(t,n.CedarModel.ui);this.extractUIPreferredLabelsAndDescriptions(u,d,r,i),this.extractIRIMappings(l,d,r,i);const m=o.ReaderUtil.getStringList(u,n.CedarModel.order),p=this.finalizeChildInfo(m,d,r,i);this.validatePropertiesVsOrder(d,m,r,i),this.validateProperties(p,l,e,r,i),this.parseChildren(p,l,e,r,i)}validateProperties(e,t,r,n,i){const c=o.ReaderUtil.deepClone(T.JsonTemplateElementContent.PROPERTIES_PARTIAL);e.hasAttributeValue()&&(c[a.JsonSchema.atContext][s.TemplateProperty.additionalProperties]=m.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE);const d=c[a.JsonSchema.atContext],u=o.ReaderUtil.getNodeList(d,a.JsonSchema.required);null!=u&&0==u.length&&o.ReaderUtil.deleteNodeKey(d,a.JsonSchema.required),T.JsonTemplateElementContent.acceptEitherIdTyping(c,t),l.JsonObjectComparator.compareToLeft(n,c,t,i.add(a.JsonSchema.properties),this.behavior)}}t.JsonTemplateElementReader=y},4948(e,t,r){t.JsonTemplateElementReaderResult=void 0;const n=r(8518);class a extends n.JsonArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get element(){return this._artifact}get elementSourceObject(){return this._artifactSourceObject}}t.JsonTemplateElementReaderResult=a},4381(e,t,r){t.JsonTemplateFieldReader=void 0;const n=r(9517),a=r(4036),i=r(3188),s=r(8748),o=r(2733),l=r(5747),c=r(3056),d=r(2763),u=r(5793),m=r(936),p=r(2475),h=r(9932),f=r(9241),T=r(5933),y=r(6511),E=r(9148),C=r(6291),g=r(8596),I=r(7095),A=r(9251),b=r(9315),R=r(2691),S=r(1769),_=r(9683),v=r(1468),N=r(9053),w=r(9034),L=r(19),F=r(2419),O=r(9366),V=r(4869),B=r(8728),D=r(5846),M=r(6396),U=r(855),J=r(978),Y=r(455),x=r(7752),P=r(8244),k=r(4956),W=r(6854),K=r(3028),j=r(7004),G=r(1886),X=r(8583);class $ extends J.JsonAbstractSchemaArtifactReader{constructor(e){super(e)}static getStrict(){return new $(D.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new $(D.JsonReaderBehavior.FEBRUARY_2024)}static getForBehavior(e){return new $(e)}static dynamicTypeReaderMap=new Map([[V.CedarFieldType.TEXT,new f.JsonFieldReaderTextField],[V.CedarFieldType.TEXTAREA,new _.JsonFieldReaderTextArea],[V.CedarFieldType.CONTROLLED_TERM,new B.JsonFieldReaderControlledTerm],[V.CedarFieldType.LINK,new I.JsonFieldReaderLink],[V.CedarFieldType.EXT_ROR,new P.JsonFieldReaderExtRor],[V.CedarFieldType.EXT_ORCID,new k.JsonFieldReaderExtOrcid],[V.CedarFieldType.EXT_PFAS,new W.JsonFieldReaderExtPfas],[V.CedarFieldType.EXT_PUBMED,new K.JsonFieldReaderExtPubmed],[V.CedarFieldType.EXT_RRID,new j.JsonFieldReaderExtRrid],[V.CedarFieldType.EXT_NIH_GRANT_ID,new G.JsonFieldReaderExtNihGrantId],[V.CedarFieldType.EXT_DOI,new X.JsonFieldReaderExtDoi],[V.CedarFieldType.TEMPORAL,new b.JsonFieldReaderTemporal],[V.CedarFieldType.EMAIL,new R.JsonFieldReaderEmail],[V.CedarFieldType.NUMERIC,new S.JsonFieldReaderNumeric],[V.CedarFieldType.PHONE_NUMBER,new v.JsonFieldReaderPhoneNumber],[V.CedarFieldType.RADIO,new N.JsonFieldReaderRadio],[V.CedarFieldType.CHECKBOX,new L.JsonFieldReaderCheckbox],[V.CedarFieldType.SINGLE_SELECT_LIST,new F.JsonFieldReaderList],[V.CedarFieldType.MULTIPLE_SELECT_LIST,new F.JsonFieldReaderList],[V.CedarFieldType.ATTRIBUTE_VALUE,new O.JsonFieldReaderAttributeValue],[V.CedarFieldType.STATIC_PAGE_BREAK,new T.JsonFieldReaderPageBreak],[V.CedarFieldType.STATIC_SECTION_BREAK,new y.JsonFieldReaderSectionBreak],[V.CedarFieldType.STATIC_IMAGE,new E.JsonFieldReaderImage],[V.CedarFieldType.STATIC_RICH_TEXT,new C.JsonFieldReaderRichText],[V.CedarFieldType.STATIC_YOUTUBE,new g.JsonFieldReaderYoutube]]);readFromString(e){let t;try{t=JSON.parse(e)}catch{t={}}return this.readFromObject(t)}readFromObject(e){const t=Y.ChildDeploymentInfo.standalone(),r=new i.JsonPath;return this.readFromObjectInternal(e,t,r)}readFromObjectInternal(e,t,r){const n=new a.JsonArtifactParsingResult,i=$.readFieldSpecificAttributes(e,t,n,r);return this.readNonReportableAttributes(i,e),this.readReportableAttributes(i,e,n,r),this.readAnnotations(i,e),new M.JsonTemplateFieldReaderResult(i,n,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.skos_prefLabel=s.ReaderUtil.getString(t,m.CedarModel.skosPrefLabel),e.skos_altLabel=s.ReaderUtil.getFilteredStringList(t,m.CedarModel.skosAltLabel)}readReportableAttributes(e,t,r,a){const i=s.ReaderUtil.getNode(t,o.JsonSchema.atContext);let f=n.JsonNode.getEmpty();e.cedarArtifactType==d.CedarArtifactType.TEMPLATE_FIELD?f=h.JsonTemplateFieldContentDynamic.CONTEXT_VERBATIM:e.cedarArtifactType==d.CedarArtifactType.STATIC_TEMPLATE_FIELD&&(f=A.JsonTemplateFieldContentStatic.CONTEXT_VERBATIM),c.JsonObjectComparator.compareBothWays(r,f,i,a.add(o.JsonSchema.atContext),this.behavior,[o.JsonSchema.atLanguage]),e.cedarFieldType===V.CedarFieldType.ATTRIBUTE_VALUE?c.JsonObjectComparator.comparePrimitive(r,u.JavascriptType.STRING.getValue(),s.ReaderUtil.getString(t,m.CedarModel.type),a.add(m.CedarModel.type)):c.JsonObjectComparator.comparePrimitive(r,u.JavascriptType.OBJECT.getValue(),s.ReaderUtil.getString(t,m.CedarModel.type),a.add(m.CedarModel.type)),c.JsonObjectComparator.comparePrimitive(r,!1,s.ReaderUtil.getBoolean(t,l.TemplateProperty.additionalProperties),a.add(l.TemplateProperty.additionalProperties)),c.JsonObjectComparator.comparePrimitive(r,p.ArtifactSchema.CURRENT.getValue(),s.ReaderUtil.getString(t,m.CedarModel.schema),a.add(m.CedarModel.schema)),e.language=x.Language.forValue(s.ReaderUtil.getString(i,o.JsonSchema.atLanguage))}static readFieldSpecificAttributes(e,t,r,n){const a=d.CedarArtifactType.forValue(s.ReaderUtil.getString(e,o.JsonSchema.atType)),i=s.ReaderUtil.getNode(e,m.CedarModel.ui),l=s.ReaderUtil.getString(i,m.CedarModel.inputType),c=w.UiInputType.forValue(l),u=this.getCedarFieldType(e,c);if(u===V.CedarFieldType.NULL)throw new Error(`Unknown uiInputType type: "${l}"`);if((a==d.CedarArtifactType.TEMPLATE_FIELD||a==d.CedarArtifactType.STATIC_TEMPLATE_FIELD)&&null!=c){const a=this.dynamicTypeReaderMap.get(u);if(!a)throw new Error(`\n No reader defined for dynamic input type "${u.getValue()}"`);return a.read(e,t,r,n)}return U.UnknownTemplateField.build()}static fieldHasValueConstraint(e){const t=s.ReaderUtil.getNode(e,m.CedarModel.valueConstraints);return s.ReaderUtil.getNodeList(t,m.CedarModel.ontologies).length>0||(s.ReaderUtil.getNodeList(t,m.CedarModel.branches).length>0||(s.ReaderUtil.getNodeList(t,m.CedarModel.classes).length>0||s.ReaderUtil.getNodeList(t,m.CedarModel.valueSets).length>0))}static getCedarFieldType(e,t){let r=V.CedarFieldType.forUiInputType(t);return r!==V.CedarFieldType.TEXT&&r!==V.CedarFieldType.CONTROLLED_TERM||(r=this.fieldHasValueConstraint(e)?V.CedarFieldType.CONTROLLED_TERM:V.CedarFieldType.TEXT),r}}t.JsonTemplateFieldReader=$},8220(e,t,r){t.JsonTemplateFieldReaderInternal=void 0;const n=r(3188),a=r(4381),i=r(455);class s extends a.JsonTemplateFieldReader{constructor(e){super(e)}static getForBehavior(e){return new s(e)}readFromObjectInternal(e,t,r){return t=t||i.ChildDeploymentInfo.standalone(),r=r||new n.JsonPath,super.readFromObjectInternal(e,t,r)}}t.JsonTemplateFieldReaderInternal=s},6396(e,t,r){t.JsonTemplateFieldReaderResult=void 0;const n=r(8518);class a extends n.JsonArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get field(){return this._artifact}get fieldSourceObject(){return this._artifactSourceObject}}t.JsonTemplateFieldReaderResult=a},4385(e,t,r){t.JsonTemplateFieldTypeSpecificReader=void 0;const n=r(855),a=r(8748),i=r(936);t.JsonTemplateFieldTypeSpecificReader=class{read(e,t,r,a){return n.UnknownTemplateField.build()}readRequiredAndHidden(e,t){const r=a.ReaderUtil.getNode(e,i.CedarModel.valueConstraints);null!=r&&(t.requiredValue=a.ReaderUtil.getBoolean(r,i.CedarModel.requiredValue),t.recommendedValue=a.ReaderUtil.getBoolean(r,i.CedarModel.ValueConstraints.recommendedValue));const n=a.ReaderUtil.getNode(e,i.CedarModel.ui);n&&(t.hidden=a.ReaderUtil.getBoolean(n,i.CedarModel.Ui.hidden),t.continuePreviousLine=a.ReaderUtil.getBoolean(n,i.CedarModel.Ui.continuePreviousLine),t.valueRecommendationEnabled=a.ReaderUtil.getBoolean(n,i.CedarModel.Ui.valueRecommendationEnabled))}}},9232(e,t,r){t.JsonTemplateInstanceReader=void 0;const n=r(2763),a=r(4036),i=r(2888),s=r(9760),o=r(3188),l=r(5846),c=r(3326),d=r(2272),u=r(6537),m=r(8748),p=r(2733),h=r(7723),f=r(5222),T=r(7571),y=r(7548),E=r(8193),C=r(4877),g=r(4465),I=r(3644),A=r(9327),b=r(936),R=r(350),S=r(4033);class _ extends c.JsonAbstractInstanceArtifactReader{knownArtifactType=n.CedarArtifactType.TEMPLATE_INSTANCE;knownKeys={[p.JsonSchema.atId]:!0,[p.JsonSchema.oslcModifiedBy]:!0,[p.JsonSchema.pavLastUpdatedOn]:!0,[p.JsonSchema.pavCreatedBy]:!0,[p.JsonSchema.pavCreatedOn]:!0,[p.JsonSchema.schemaDescription]:!0,[p.JsonSchema.schemaName]:!0,[p.JsonSchema.schemaIsBasedOn]:!0,[p.JsonSchema.atContext]:!0,[b.CedarModel.annotations]:!0};constructor(e){super(e)}static getStrict(){return new _(l.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new _(l.JsonReaderBehavior.FEBRUARY_2024)}static getForBehavior(e){return new _(e)}readFromString(e){let t;try{t=JSON.parse(e)}catch{t={}}return this.readFromObject(t,new o.JsonPath)}readFromObject(e,t){const r=new a.JsonArtifactParsingResult,n=d.TemplateInstance.buildEmptyWithNullValues();this.readNonReportableAttributes(n,e);const i=t??new o.JsonPath;return this.readInstanceData(e,n,i,r),_.reportEnvelope(e,i,r),new u.JsonTemplateInstanceReaderResult(n,r,e)}static ENVELOPE_KEYS=[p.JsonSchema.atContext,p.JsonSchema.atId,p.JsonSchema.schemaIsBasedOn,p.JsonSchema.pavCreatedOn,p.JsonSchema.pavCreatedBy,p.JsonSchema.oslcModifiedBy,p.JsonSchema.pavLastUpdatedOn];static reportEnvelope(e,t,r){for(const n of _.ENVELOPE_KEYS){if(!Object.hasOwn(e,n)){r.addBlueprintComparisonWarning(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,t.add(n),n));continue}const a=m.ReaderUtil.getNode(e,n);(null==a||n===p.JsonSchema.atContext&&0===Object.keys(a).length)&&r.addBlueprintComparisonWarning(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,t.add(n),n,null))}}readInstanceData(e,t,r,n){t.dataContainer=this.readInstanceContainer(e,r,n),this.readAnnotations(t,e)}readInstanceContainer(e,t,r){return this.parseContainer(e,t,r)}isKnownKey(e){return Object.hasOwn(this.knownKeys,e)}parseContainer(e,t,r){const n=new h.InstanceDataContainer;Object.keys(e).forEach(a=>{if(!this.isKnownKey(a)){const i=m.ReaderUtil.getNode(e,a);if(Array.isArray(i)){const e=[];n.setValue(a,e),i.forEach((n,i)=>{e[i]=this.parseNode(n,t.add(a,i),r)})}else n.setValue(a,this.parseNode(i,t.add(a),r))}});for(const e of S.AttributeValueNamePolicy.findConflicts(n).filter(e=>0===e.path.length))r.addBlueprintComparisonError(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.VALUE_MISMATCH,t.add(...e.path,e.groupName,e.name),"a unique, non-reserved attribute-value name",e.name));this.packAttributeValues(n);const a=Object.hasOwn(e,p.JsonSchema.atContext)?m.ReaderUtil.getNode(e,p.JsonSchema.atContext):null;if(null!=a){const e=a;Object.keys(n.values).forEach(t=>{const r=m.ReaderUtil.getString(e,t);null!==r&&n.setIri(t,r)}),Object.keys(n.values).forEach(t=>{const r=n.values[t];r instanceof A.InstanceDataAttributeValueField&&Object.keys(r.values).forEach(t=>{const r=m.ReaderUtil.getString(e,t);null!==r&&n.setIri(t,r)})}),Object.keys(e).forEach(t=>{if(Object.hasOwn(R.JsonTemplateInstanceContent.CONTEXT_VERBATIM,t))return;const r=m.ReaderUtil.getString(e,t);null!==r&&n.setIri(t,r)})}if(Object.hasOwn(e,p.JsonSchema.atId)){const a=m.ReaderUtil.getString(e,p.JsonSchema.atId);null!==a&&(""===a.trim()&&(this.behavior.useWarningForKnownIssues()||_.refuseEmptyIdentifier(e),r.addBlueprintComparisonWarning(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.VALUE_MISMATCH,t.add(p.JsonSchema.atId),"an absolute IRI or null while the occurrence awaits server assignment",a))),n.id=a)}return n}static VALUE_ATOM_KEYS=new Set([p.JsonSchema.atValue,p.JsonSchema.atId,p.JsonSchema.rdfsLabel,p.JsonSchema.atType,b.CedarModel.skosNotation]);static isValueNode(e){if(null==e)return!1;if("string"==typeof e)return!0;if(Object.hasOwn(e,p.JsonSchema.atValue))return!0;if(Object.hasOwn(e,p.JsonSchema.atContext))return!1;const t=Object.keys(e);return t.length>0&&t.every(e=>_.VALUE_ATOM_KEYS.has(e))}static readValueNode(e){return null==e?new g.InstanceDataEmptyNode:"string"==typeof e?new I.InstanceDataAttributeValueFieldName(e):_.isValueNode(e)?_.parseDataAtom(e):new g.InstanceDataEmptyNode}parseNode(e,t,r){if(null==e)return new g.InstanceDataEmptyNode;if("string"==typeof e)return new I.InstanceDataAttributeValueFieldName(e);if(_.isValueNode(e)){const n=_.parseDataAtom(e);return _.reportNullIri(n,t,r),n}return 0===Object.keys(e).length?new g.InstanceDataEmptyNode:this.parseContainer(e,t,r)}static reportNullIri(e,t,r){(e instanceof T.InstanceDataLinkAtom||e instanceof E.InstanceDataControlledAtom)&&null===e.id&&r.addBlueprintComparisonError(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,t.add(p.JsonSchema.atId),"an IRI",null))}static parseDataAtom(e){if(Object.hasOwn(e,p.JsonSchema.atValue)){const t=m.ReaderUtil.getString(e,p.JsonSchema.atValue),r=m.ReaderUtil.getString(e,p.JsonSchema.atType);return null===r?new f.InstanceDataStringAtom(t):new C.InstanceDataTypedAtom(t,r)}if(Object.hasOwn(e,p.JsonSchema.atId)){_.refuseEmptyIdentifier(e);const t=m.ReaderUtil.getString(e,p.JsonSchema.atId),r=m.ReaderUtil.getString(e,p.JsonSchema.rdfsLabel);return null===r?T.InstanceDataLinkAtom.fromParsedNode(t):E.InstanceDataControlledAtom.fromParsedNode(t,r)}return new y.InstanceDataEmptyAtom(e)}packAttributeValues(e){const t=e.values,r=[];Object.keys(t).forEach(e=>{const n=t[e];if(Array.isArray(n)){let a=!1;if(n.forEach((e,t)=>{e instanceof I.InstanceDataAttributeValueFieldName||(a=!0)}),n.length>0&&!a){const a=new A.InstanceDataAttributeValueField(e);r.push(a),n.forEach((e,r)=>{const n=e.name;if(null!==n&&Object.hasOwn(t,n)){const e=t[n];a.addValue(n,e)}})}}}),r.forEach((e,r)=>{const n=e.name;null!==n&&(t[n]=e,Object.keys(e.values).forEach(e=>{Object.hasOwn(t,e)&&delete t[e]}))}),e.values=t}}t.JsonTemplateInstanceReader=_},6537(e,t,r){t.JsonTemplateInstanceReaderResult=void 0;const n=r(8518);class a extends n.JsonArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get instance(){return this._artifact}get instanceSourceObject(){return this._artifactSourceObject}}t.JsonTemplateInstanceReaderResult=a},5291(e,t,r){t.JsonTemplateReader=void 0;const n=r(936),a=r(2733),i=r(2763),s=r(5747),o=r(8748),l=r(6551),c=r(3056),d=r(4036),u=r(7954),m=r(3188),p=r(5846),h=r(9932),f=r(7909),T=r(5510),y=r(3281);class E extends T.JsonContainerArtifactReader{elementReader;knownArtifactType=i.CedarArtifactType.TEMPLATE;constructor(e){super(e),this.elementReader=f.JsonTemplateElementReader.getForBehavior(e)}static getStrict(){return new E(p.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new E(p.JsonReaderBehavior.FEBRUARY_2024)}static getForBehavior(e){return new E(e)}getElementReader(){return this.elementReader}includeInIRIMapping(e){return e.atType!==i.CedarArtifactType.STATIC_TEMPLATE_FIELD}readFromString(e){let t;try{t=JSON.parse(e)}catch{t={}}return this.readFromObject(t)}readFromObject(e,t=new m.JsonPath){const r=new d.JsonArtifactParsingResult,n=y.Template.buildEmptyWithNullValues();return this.readNonReportableAttributes(n,e),this.readReportableAttributes(n,e,r,t),this.readAnnotations(n,e),this.readInstanceTypeSpecification(n,e,r),this.readAndValidateChildrenInfo(n,e,r,t),new u.JsonTemplateReaderResult(n,r,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t);const r=o.ReaderUtil.getNode(t,n.CedarModel.ui);null!==r&&(e.header=o.ReaderUtil.getString(r,n.CedarModel.header),e.footer=o.ReaderUtil.getString(r,n.CedarModel.footer))}readAndValidateChildrenInfo(e,t,r,i){const s=o.ReaderUtil.getStringList(t,a.JsonSchema.required),c=o.ReaderUtil.getNode(t,a.JsonSchema.properties),d=this.generateAndValidateRequiredMap(s,l.JsonTemplateContent.REQUIRED_PARTIAL,r,i),u=this.getCandidateChildrenInfo(c,l.JsonTemplateContent.PROPERTIES_PARTIAL_KEY_MAP,r,i);this.checkRequiredBothWays(u,d,s,l.JsonTemplateContent.REQUIRED_PARTIAL_KEY_MAP,r,i);const m=o.ReaderUtil.getNode(t,n.CedarModel.ui);this.extractUIPreferredLabelsAndDescriptions(m,u,r,i),this.extractIRIMappings(c,u,r,i);const p=o.ReaderUtil.getStringList(m,n.CedarModel.order),h=this.finalizeChildInfo(p,u,r,i);this.validatePropertiesVsOrder(u,p,r,i),this.validateProperties(h,c,e,r,i),this.parseChildren(h,c,e,r,i)}validateProperties(e,t,r,n,i){let d=l.JsonTemplateContent.PROPERTIES_PARTIAL;e.hasAttributeValue()&&(d=o.ReaderUtil.deepClone(l.JsonTemplateContent.PROPERTIES_PARTIAL),d[a.JsonSchema.atContext][s.TemplateProperty.additionalProperties]=h.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE),c.JsonObjectComparator.compareToLeft(n,d,t,i.add(a.JsonSchema.properties),this.behavior)}}t.JsonTemplateReader=E},7954(e,t,r){t.JsonTemplateReaderResult=void 0;const n=r(8518);class a extends n.JsonArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get template(){return this._artifact}get templateSourceObject(){return this._artifactSourceObject}}t.JsonTemplateReaderResult=a},8639(e,t,r){t.CedarYamlReaders=void 0;const n=r(2763),a=r(1395),i=r(5677),s=r(8239),o=r(2999),l=r(9946);class c{behavior;isCompact;constructor(e,t=!1){this.behavior=e,this.isCompact=t}static getStrict(){return new c(a.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new c(a.YamlReaderBehavior.STRICT,!0)}getTemplateReader(){return i.YamlTemplateReader.getForBehavior(this.behavior,this.isCompact)}getTemplateElementReader(){return s.YamlTemplateElementReader.getForBehavior(this.behavior,this.isCompact)}getTemplateFieldReader(){return o.YamlTemplateFieldReader.getForBehavior(this.behavior,this.isCompact)}getTemplateInstanceReader(){return l.YamlTemplateInstanceReader.getForBehavior(this.behavior)}getReaderForArtifactType(e){switch(e){case n.CedarArtifactType.TEMPLATE:return i.YamlTemplateReader.getForBehavior(this.behavior,this.isCompact);case n.CedarArtifactType.TEMPLATE_ELEMENT:return s.YamlTemplateElementReader.getForBehavior(this.behavior,this.isCompact);case n.CedarArtifactType.TEMPLATE_FIELD:case n.CedarArtifactType.STATIC_TEMPLATE_FIELD:return o.YamlTemplateFieldReader.getForBehavior(this.behavior,this.isCompact);case n.CedarArtifactType.TEMPLATE_INSTANCE:return l.YamlTemplateInstanceReader.getForBehavior(this.behavior);default:throw new Error(`No YAML reader available for CedarArtifactType: ${e}`)}}}t.CedarYamlReaders=c},6575(e,t,r){t.YamlAbstractArtifactReader=void 0;const n=r(8534),a=r(2234),i=r(9857),s=r(8557),o=r(1027),l=r(3910),c=r(2763),d=r(5226),u=r(2787),m=r(3549),p=r(8748),h=r(2099),f=r(7752);class T{behavior;knownArtifactType=c.CedarArtifactType.NULL;isCompact;constructor(e,t=!1){this.behavior=e,this.isCompact=t}artifactTypeWord(){return this.knownArtifactType===c.CedarArtifactType.TEMPLATE?"template":this.knownArtifactType===c.CedarArtifactType.TEMPLATE_ELEMENT?"element":"field"}readNonReportableAttributes(e,t){if(T.refuseEmptyIdentifier(t),e.at_id=n.CedarArtifactId.forValue(p.ReaderUtil.getString(t,h.YamlKeys.id)),e.schema_name=p.ReaderUtil.getString(t,h.YamlKeys.name),e.schema_description=p.ReaderUtil.getString(t,h.YamlKeys.description),null!==e.schema_name){const t=this.artifactTypeWord();e.title=`${e.schema_name} ${t} schema`,e.description=`${e.schema_name} ${t} schema generated by the CEDAR Artifact Library`}e.pav_createdBy=a.CedarUser.forValue(p.ReaderUtil.getString(t,h.YamlKeys.createdBy)),e.pav_createdOn=i.IsoDate.forValue(p.ReaderUtil.getString(t,h.YamlKeys.createdOn)),e.oslc_modifiedBy=a.CedarUser.forValue(p.ReaderUtil.getString(t,h.YamlKeys.modifiedBy)),e.pav_lastUpdatedOn=i.IsoDate.forValue(p.ReaderUtil.getString(t,h.YamlKeys.modifiedOn));const r=p.ReaderUtil.getString(t,h.YamlKeys.modelVersion);if(null===r&&!this.isCompact)throw new Error(`No ${h.YamlKeys.modelVersion} present. A document without one is the compact form, which a reader has to be asked for.`);e.schema_schemaVersion=s.SchemaVersion.forValue(r),e.pav_version=o.PavVersion.forValue(p.ReaderUtil.getString(t,h.YamlKeys.version)),e.bibo_status=l.BiboStatus.forYamlValue(p.ReaderUtil.getString(t,h.YamlKeys.status)),e.pav_derivedFrom=n.CedarArtifactId.forValue(p.ReaderUtil.getString(t,h.YamlKeys.derivedFrom)),e.pav_previousVersion=n.CedarArtifactId.forValue(p.ReaderUtil.getString(t,h.YamlKeys.previousVersion)),e.schema_identifier=p.ReaderUtil.getString(t,h.YamlKeys.identifier),e.language=f.Language.forValue(p.ReaderUtil.getString(t,h.YamlKeys.language))}static refuseEmptyIdentifier(e,t=h.YamlKeys.id){const r=p.ReaderUtil.getString(e,t);if(null!==r&&""===r.trim())throw new Error(`An empty string is not a URI at "${t}"; write null or leave the key out where there is no value.`)}refuseIdentifierAtDocumentRoot(e){const t=null===p.ReaderUtil.getString(e,h.YamlKeys.modelVersion);if(this.isCompact&&t&&null!==p.ReaderUtil.getString(e,h.YamlKeys.id))throw new Error(`A compact document describes an artifact being authored, so it cannot carry an ${h.YamlKeys.id}. Use the full form to represent a stored artifact.`)}readAnnotations(e,t,r,n){const a=new d.Annotations,i=p.ReaderUtil.getNode(t,h.YamlKeys.annotations);Object.keys(i).forEach(e=>{const t=p.ReaderUtil.getNode(i,e),r=p.ReaderUtil.getString(t,h.YamlKeys.id),n=p.ReaderUtil.getString(t,h.YamlKeys.value);null!==e&&(null!==r?a.add(new u.AnnotationAtId(e,r)):null!==n&&a.add(new m.AnnotationAtValue(e,n)))}),a.getSize()>0&&(e.annotations=a)}}t.YamlAbstractArtifactReader=T},6532(e,t){t.YamlArtifactReaderResult=void 0,t.YamlArtifactReaderResult=class{_artifact;_parsingResult;_artifactSourceObject;constructor(e,t,r){this._artifact=e,this._parsingResult=t,this._artifactSourceObject=r}get artifact(){return this._artifact}get parsingResult(){return this._parsingResult}get artifactSourceObject(){return this._artifactSourceObject}}},9300(e,t,r){t.YamlContainerArtifactReader=void 0;const n=r(6575),a=r(2999),i=r(455),s=r(2763),o=r(8748),l=r(2099),c=r(699),d=r(9499),u=r(4869),m=r(3608);class p extends n.YamlAbstractArtifactReader{fieldReader;constructor(e,t=!1){super(e,t),this.fieldReader=a.YamlTemplateFieldReader.getForBehavior(e,t)}readAndValidateChildrenInfo(e,t,r,n){o.ReaderUtil.getNodeList(t,l.YamlKeys.children).forEach(t=>{const r=o.ReaderUtil.getString(t,l.YamlKeys.type),a=o.ReaderUtil.getString(t,l.YamlKeys.key),p=d.YamlArtifactType.forValue(r);if(null===a)throw new Error(`A child without a ${l.YamlKeys.key} at ${n.add(l.YamlKeys.children).toString()}`);{const d=new i.ChildDeploymentInfo(a);d.atType=s.CedarArtifactType.forYamlArtifactType(p);const h=o.ReaderUtil.getNode(t,l.YamlKeys.configuration);if(d.label=o.ReaderUtil.getString(h,l.YamlKeys.overrideLabel),d.description=o.ReaderUtil.getString(h,l.YamlKeys.overrideDescription),d.multiInstance=o.ReaderUtil.getBoolean(h,l.YamlKeys.multiple),d.multiInstance&&(d.minItems=o.ReaderUtil.getNumber(h,l.YamlKeys.minItems),d.maxItems=o.ReaderUtil.getNumber(h,l.YamlKeys.maxItems)),d.requiredValue=o.ReaderUtil.getBoolean(h,l.YamlKeys.required),d.recommendedValue=o.ReaderUtil.getBoolean(h,l.YamlKeys.recommended),d.hidden=o.ReaderUtil.getBoolean(h,l.YamlKeys.hidden),d.continuePreviousLine=o.ReaderUtil.getBoolean(h,l.YamlKeys.continuePreviousLine),d.valueRecommendationEnabled=o.ReaderUtil.getBoolean(h,l.YamlKeys.valueRecommendation),d.iri=o.ReaderUtil.getString(h,l.YamlKeys.propertyIri),p.isField()){const r=u.CedarFieldType.forYamlArtifactType(p);d.uiInputType=r.getUiInputType();const i=this.fieldReader.readFromObject(t,d,n.add(l.YamlKeys.children,a));(0,c.isSizedStaticField)(i.field)&&(i.field.width=o.ReaderUtil.getNumber(h,l.YamlKeys.width),i.field.height=o.ReaderUtil.getNumber(h,l.YamlKeys.height));const f=i.field.createDeploymentBuilder(d.name).withLabel(d.label).withDescription(d.description);if(d.atType===s.CedarArtifactType.TEMPLATE_FIELD){const e=f;e.withIri(d.iri).withHidden(d.hidden).withContinuePreviousLine(d.continuePreviousLine).withRecommendedValue(d.recommendedValue).withRequiredValue(d.requiredValue).withValueRecommendationEnabled(d.valueRecommendationEnabled),e instanceof m.ChildDeploymentInfoBuilder&&e.withMultiInstance(d.multiInstance).withMinItems(d.minItems).withMaxItems(d.maxItems)}const T=f.build();e.addChild(i.field,T)}else{if(!p.isElement())throw new Error(`Unknown child type "${r}" at ${n.add(l.YamlKeys.children,a).toString()}`);{const r=this.getElementReader().readFromObject(t,d,n.add(l.YamlKeys.children,a));e.addChild(r.element,d)}}}})}}t.YamlContainerArtifactReader=p},8239(e,t,r){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.YamlTemplateElementReader=void 0;const a=r(2763),i=r(3188),s=r(1395),o=r(7661),l=r(455),c=n(r(3198)),d=r(9300),u=r(4646),m=r(1591),p=r(8748),h=r(2099);class f extends d.YamlContainerArtifactReader{knownArtifactType=a.CedarArtifactType.TEMPLATE_ELEMENT;constructor(e,t=!1){super(e,t)}static getStrict(){return new f(s.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new f(s.YamlReaderBehavior.STRICT,!0)}static getForBehavior(e,t=!1){return new f(e,t)}getElementReader(){return this}readFromString(e){let t;try{t=c.default.parse(e)}catch{t={}}return this.refuseIdentifierAtDocumentRoot(t),this.readFromObject(t,l.ChildDeploymentInfo.empty(),new i.JsonPath)}readFromObject(e,t,r){const n=new m.YamlArtifactParsingResult,a=o.TemplateElement.buildEmptyWithNullValues();return this.readNonReportableAttributes(a,e),this.readAnnotations(a,e,n,r),super.readAndValidateChildrenInfo(a,e,n,r),new u.YamlTemplateElementReaderResult(a,n,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.instanceTypeSpecification=p.ReaderUtil.getString(t,h.YamlKeys.instanceType),e.skos_prefLabel=p.ReaderUtil.getString(t,h.YamlKeys.prefLabel),e.skos_altLabel=p.ReaderUtil.getFilteredStringList(t,h.YamlKeys.altLabels)}}t.YamlTemplateElementReader=f},4646(e,t){t.YamlTemplateElementReaderResult=void 0,t.YamlTemplateElementReaderResult=class{_element;_parsingResult;_elementSourceObject;constructor(e,t,r){this._element=e,this._parsingResult=t,this._elementSourceObject=r}get element(){return this._element}get parsingResult(){return this._parsingResult}get elementSourceObject(){return this._elementSourceObject}}},2999(e,t,r){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.YamlTemplateFieldReader=void 0;const a=r(3188),i=r(8748),s=r(2763),o=r(3054),l=r(1790),c=r(455),d=r(6575),u=r(1395),m=n(r(3198)),p=r(2099),h=r(9499),f=r(1268),T=r(3168),y=r(384),E=r(1872),C=r(529),g=r(4568),I=r(8568),A=r(3980),b=r(7941),R=r(1404),S=r(7089),_=r(4329),v=r(7268),N=r(2709),w=r(7124),L=r(4284),F=r(9299),O=r(1591),V=r(6651),B=r(7123),D=r(5075),M=r(7709),U=r(6089),J=r(8543),Y=r(5907);class x extends d.YamlAbstractArtifactReader{knownArtifactType=s.CedarArtifactType.TEMPLATE_FIELD;constructor(e,t=!1){super(e,t)}static getStrict(){return new x(u.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new x(u.YamlReaderBehavior.STRICT,!0)}static getForBehavior(e,t=!1){return new x(e,t)}static readerMap=new Map([[h.YamlArtifactType.TEXTFIELD,new f.YamlFieldReaderTextField],[h.YamlArtifactType.TEXTAREA,new T.YamlFieldReaderTextArea],[h.YamlArtifactType.CONTROLLED_TERM,new F.YamlFieldReaderControlledTerm],[h.YamlArtifactType.LINK,new I.YamlFieldReaderLink],[h.YamlArtifactType.EXT_ROR,new V.YamlFieldReaderExtRor],[h.YamlArtifactType.EXT_ORCID,new B.YamlFieldReaderExtOrcid],[h.YamlArtifactType.EXT_PFAS,new D.YamlFieldReaderExtPfas],[h.YamlArtifactType.EXT_PUBMED,new M.YamlFieldReaderExtPubmed],[h.YamlArtifactType.EXT_RRID,new U.YamlFieldReaderExtRrid],[h.YamlArtifactType.EXT_NIH_GRANT_ID,new J.YamlFieldReaderExtNihGrantId],[h.YamlArtifactType.EXT_DOI,new Y.YamlFieldReaderExtDoi],[h.YamlArtifactType.TEMPORAL,new y.YamlFieldReaderTemporal],[h.YamlArtifactType.EMAIL,new o.YamlFieldReaderEmail],[h.YamlArtifactType.NUMERIC,new E.YamlFieldReaderNumeric],[h.YamlArtifactType.PHONE_NUMBER,new _.YamlFieldReaderPhoneNumber],[h.YamlArtifactType.RADIO,new L.YamlFieldReaderRadio],[h.YamlArtifactType.CHECKBOX,new v.YamlFieldReaderCheckbox],[h.YamlArtifactType.SINGLE_SELECT_LIST,new N.YamlFieldReaderSingleSelectList],[h.YamlArtifactType.MULTI_SELECT_LIST,new w.YamlFieldReaderMultiSelectList],[h.YamlArtifactType.ATTRIBUTE_VALUE,new C.YamlFieldReaderAttributeValue],[h.YamlArtifactType.PAGE_BREAK,new g.YamlFieldReaderPageBreak],[h.YamlArtifactType.SECTION_BREAK,new A.YamlFieldReaderSectionBreak],[h.YamlArtifactType.IMAGE,new b.YamlFieldReaderImage],[h.YamlArtifactType.RICH_TEXT,new R.YamlFieldReaderRichText],[h.YamlArtifactType.YOUTUBE,new S.YamlFieldReaderYoutube]]);readFromString(e){let t;try{t=m.default.parse(e)}catch{t={}}return this.refuseIdentifierAtDocumentRoot(t),this.readFromObject(t,c.ChildDeploymentInfo.empty(),new a.JsonPath)}readFromObject(e,t,r){const n=new O.YamlArtifactParsingResult,a=x.readFieldSpecificAttributes(e,t,n,r);return this.readNonReportableAttributes(a,e),this.readAnnotations(a,e,n,r),new l.YamlTemplateFieldReaderResult(a,n,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.skos_prefLabel=i.ReaderUtil.getString(t,p.YamlKeys.prefLabel),e.skos_altLabel=i.ReaderUtil.getFilteredStringList(t,p.YamlKeys.altLabels)}static readFieldSpecificAttributes(e,t,r,n){const a=h.YamlArtifactType.forValue(i.ReaderUtil.getString(e,p.YamlKeys.type));if(a.isField()){const i=this.readerMap.get(a);if(!i)throw new Error(`No reader defined for dynamic input type "${a.getValue()}"`);const o=i.read(e,t,r,n);let l=s.CedarArtifactType.NULL;return a.isStaticField()?l=s.CedarArtifactType.STATIC_TEMPLATE_FIELD:a.isDynamicField()&&(l=s.CedarArtifactType.TEMPLATE_FIELD),o.cedarArtifactType=l,o}throw new Error(`Unknown field type "${i.ReaderUtil.getString(e,p.YamlKeys.type)}" at ${n.toString()}`)}}t.YamlTemplateFieldReader=x},1790(e,t){t.YamlTemplateFieldReaderResult=void 0,t.YamlTemplateFieldReaderResult=class{_field;_parsingResult;_fieldSourceObject;constructor(e,t,r){this._field=e,this._parsingResult=t,this._fieldSourceObject=r}get field(){return this._field}get parsingResult(){return this._parsingResult}get fieldSourceObject(){return this._fieldSourceObject}}},5675(e,t,r){t.YamlTemplateFieldTypeSpecificReader=void 0;const n=r(855),a=r(8748),i=r(2099),s=r(4081);t.YamlTemplateFieldTypeSpecificReader=class{read(e,t,r,a){return n.UnknownTemplateField.build()}static readAndStoreListValueConstraints(e,t){t.valueConstraints.defaultValue=a.ReaderUtil.getString(e,i.YamlKeys.default);const r=a.ReaderUtil.getNodeList(e,i.YamlKeys.values);null!==r&&r.forEach(e=>{const r=a.ReaderUtil.getString(e,i.YamlKeys.label),n=a.ReaderUtil.getBoolean(e,i.YamlKeys.selected);if(null!=r){const e=new s.ListOption(r,n);t.valueConstraints.literals.push(e)}})}}},9946(e,t,r){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.YamlTemplateInstanceReader=void 0;const a=n(r(3198)),i=r(8534),s=r(1395),o=r(6575),l=r(2234),c=r(9857),d=r(1591),u=r(2099),m=r(8748),p=r(2272),h=r(147),f=r(7723),T=r(5222),y=r(4877),E=r(7571),C=r(8193),g=r(4465),I=r(9327),A=r(4033),b=r(2888),R=r(6109),S=r(3188);class _ extends o.YamlAbstractArtifactReader{constructor(e,t=!1){super(e,t)}static getStrict(){return new _(s.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new _(s.YamlReaderBehavior.STRICT,!0)}static getForBehavior(e,t=!1){return new _(e,t)}readFromString(e){let t;try{t=a.default.parse(e)}catch{t={}}return this.refuseIdentifierAtDocumentRoot(t),this.readFromObject(t)}readFromObject(e){const t=new d.YamlArtifactParsingResult,r=p.TemplateInstance.buildEmptyWithNullValues(),n=e??{};r.schema_name=m.ReaderUtil.getString(n,u.YamlKeys.name),r.schema_description=m.ReaderUtil.getString(n,u.YamlKeys.description),_.refuseEmptyIdentifier(n),r.at_id=i.CedarArtifactId.forValue(m.ReaderUtil.getString(n,u.YamlKeys.id)),r.schema_isBasedOn=i.CedarArtifactId.forValue(m.ReaderUtil.getString(n,u.YamlKeys.isBasedOn)),r.pav_derivedFrom=i.CedarArtifactId.forValue(m.ReaderUtil.getString(n,u.YamlKeys.derivedFrom)),r.pav_createdBy=l.CedarUser.forValue(m.ReaderUtil.getString(n,u.YamlKeys.createdBy)),r.pav_createdOn=c.IsoDate.forValue(m.ReaderUtil.getString(n,u.YamlKeys.createdOn)),r.oslc_modifiedBy=l.CedarUser.forValue(m.ReaderUtil.getString(n,u.YamlKeys.modifiedBy)),r.pav_lastUpdatedOn=c.IsoDate.forValue(m.ReaderUtil.getString(n,u.YamlKeys.modifiedOn)),this.readAnnotations(r,n,t,new S.JsonPath),r.dataContainer=this.parseContainer(n);for(const e of A.AttributeValueNamePolicy.findConflicts(r.dataContainer))t.addBlueprintComparisonError(new b.ComparisonError("YamlTemplateInstanceReader",R.YamlComparisonErrorType.VALUE_MISMATCH,new S.JsonPath(...e.path,e.groupName,e.name),"a unique, non-reserved attribute-value name",e.name));return new h.YamlTemplateInstanceReaderResult(r,t,n)}static RESERVED_KEYS=new Set([u.YamlKeys.type,u.YamlKeys.name,u.YamlKeys.description,u.YamlKeys.id,u.YamlKeys.isBasedOn,u.YamlKeys.derivedFrom,u.YamlKeys.children,u.YamlKeys.annotations,u.YamlKeys.createdOn,u.YamlKeys.createdBy,u.YamlKeys.modifiedOn,u.YamlKeys.modifiedBy]);parseContainer(e){const t=new f.InstanceDataContainer,r=m.ReaderUtil.getNode(e,u.YamlKeys.children);null!==r&&Object.keys(r).forEach(e=>{const n=m.ReaderUtil.getNode(r,e)??r[e];if(Array.isArray(n)){const r=[];t.setValue(e,r),n.forEach((e,t)=>{r[t]=this.parseNode(e)})}else t.setValue(e,this.parseNode(n))}),Object.keys(e).forEach(r=>{if(_.RESERVED_KEYS.has(r))return;const n=e[r];if(null===n||"object"!=typeof n||Array.isArray(n))return;const a=new I.InstanceDataAttributeValueField(r);Object.keys(n).forEach(e=>{const t=n[e];a.addValue(e,new T.InstanceDataStringAtom(this.parseAttributeValue(t)))}),t.setValue(r,a)}),_.refuseEmptyIdentifier(e);const n=m.ReaderUtil.getString(e,u.YamlKeys.id);return null!==n&&(t.id=n),t}parseAttributeValue(e){if("string"==typeof e)return e;if(null!==e&&"object"==typeof e&&!Array.isArray(e)){const t=e[u.YamlKeys.value];return"string"==typeof t?t:null}return null}parseNode(e){if(null==e)return new g.InstanceDataEmptyNode;if("string"==typeof e)return new T.InstanceDataStringAtom(e);if(Object.hasOwn(e,u.YamlKeys.children)||"element-instance"===m.ReaderUtil.getString(e,u.YamlKeys.type))return this.parseContainer(e);if(Object.hasOwn(e,u.YamlKeys.value)){const t=m.ReaderUtil.getString(e,u.YamlKeys.value),r=m.ReaderUtil.getString(e,u.YamlKeys.datatype);return null===r?new T.InstanceDataStringAtom(t):new y.InstanceDataTypedAtom(t,r)}if(Object.hasOwn(e,u.YamlKeys.id)){_.refuseEmptyIdentifier(e);const t=m.ReaderUtil.getString(e,u.YamlKeys.id),r=m.ReaderUtil.getString(e,u.YamlKeys.label);return null===r?E.InstanceDataLinkAtom.fromParsedNode(t):C.InstanceDataControlledAtom.fromParsedNode(t,r)}return new g.InstanceDataEmptyNode}}t.YamlTemplateInstanceReader=_},147(e,t,r){t.YamlTemplateInstanceReaderResult=void 0;const n=r(6532);class a extends n.YamlArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get instance(){return this._artifact}get instanceSourceObject(){return this._artifactSourceObject}}t.YamlTemplateInstanceReaderResult=a},5677(e,t,r){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.YamlTemplateReader=void 0;const a=r(2763),i=r(8748),s=r(7868),o=r(3188),l=r(1395),c=r(8239),d=r(3281),u=n(r(3198)),m=r(9300),p=r(2099),h=r(1591);class f extends m.YamlContainerArtifactReader{elementReader;knownArtifactType=a.CedarArtifactType.TEMPLATE;constructor(e,t=!1){super(e,t),this.elementReader=c.YamlTemplateElementReader.getForBehavior(e,t)}static getStrict(){return new f(l.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new f(l.YamlReaderBehavior.STRICT,!0)}static getForBehavior(e,t=!1){return new f(e,t)}getElementReader(){return this.elementReader}readFromString(e){let t;try{t=u.default.parse(e)}catch{t={}}return this.refuseIdentifierAtDocumentRoot(t),this.readFromObject(t)}readFromObject(e,t=new o.JsonPath){const r=new h.YamlArtifactParsingResult,n=d.Template.buildEmptyWithNullValues();return this.readNonReportableAttributes(n,e),this.readAnnotations(n,e,r,t),this.readInstanceTypeSpecification(n,e,r),this.readAndValidateChildrenInfo(n,e,r,t),new s.YamlTemplateReaderResult(n,r,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.header=i.ReaderUtil.getString(t,p.YamlKeys.header),e.footer=i.ReaderUtil.getString(t,p.YamlKeys.footer)}readInstanceTypeSpecification(e,t,r){e.instanceTypeSpecification=i.ReaderUtil.getString(t,p.YamlKeys.instanceType)}}t.YamlTemplateReader=f},7868(e,t){t.YamlTemplateReaderResult=void 0,t.YamlTemplateReaderResult=class{_template;_parsingResult;_templateSourceObject;constructor(e,t,r){this._template=e,this._parsingResult=t,this._templateSourceObject=r}get template(){return this._template}get parsingResult(){return this._parsingResult}get templateSourceObject(){return this._templateSourceObject}}},1888(e,t,r){t.RoundTrip=void 0;const n=r(6396),a=r(2748),i=r(4036),s=r(3056),o=r(455),l=r(3188),c=r(7954),d=r(7519),u=r(4948),m=r(6645),p=r(2022);t.RoundTrip=class{static compare(e,t){if(e instanceof n.JsonTemplateFieldReaderResult&&t instanceof a.JsonTemplateFieldWriterInternal)return this.compareField(e,t);if(e instanceof u.JsonTemplateElementReaderResult&&t instanceof m.JsonTemplateElementWriter)return this.compareElement(e,t);if(e instanceof c.JsonTemplateReaderResult&&t instanceof d.JsonTemplateWriter)return this.compareTemplate(e,t);if("string"==typeof e&&"string"==typeof t)return this.compareString(e,t);throw new Error("Invalid argument types for compare method")}static compareField(e,t){const r=new i.JsonArtifactParsingResult;return s.JsonObjectComparator.compareBothWays(r,e.fieldSourceObject,t.getAsJsonNode(e.field,o.ChildDeploymentInfo.empty()),new l.JsonPath,t.getBehavior()),r}static compareElement(e,t){const r=new i.JsonArtifactParsingResult;return s.JsonObjectComparator.compareBothWays(r,e.elementSourceObject,t.getAsJsonNode(e.element),new l.JsonPath,t.getBehavior()),r}static compareTemplate(e,t){const r=new i.JsonArtifactParsingResult;return s.JsonObjectComparator.compareBothWays(r,e.templateSourceObject,t.getAsJsonNode(e.template),new l.JsonPath,t.getBehavior()),r}static compareString(e,t){const r=JSON.parse(e),n=JSON.parse(t),a=new i.JsonArtifactParsingResult;return s.JsonObjectComparator.compareBothWays(a,r,n,new l.JsonPath,p.JsonWriterBehavior.STRICT),a}}},2112(e,t){t.AbstractArtifactWriter=void 0,t.AbstractArtifactWriter=class{constructor(){}}},8810(e,t,r){t.CedarWriters=void 0;const n=r(9607),a=r(5359);t.CedarWriters=class{static json(){return n.CedarJsonWriters}static yaml(){return a.CedarYamlWriters}}},5692(e,t,r){t.WriterUtil=void 0;const n=r(8878),a=r(455);t.WriterUtil=class{static getMultiMinMax(e,t){let r=null,i=null,s=!1;if(e.isMultiInstanceByDefinition())t instanceof n.ChildDeploymentInfoAlwaysMultiple&&(s=!0,r=t.minItems,i=t.maxItems);else if(e.isSingleInstanceByDefinition())s=!1;else if(t instanceof a.ChildDeploymentInfo){const e=t;s=e.multiInstance,s&&(r=e.minItems,i=e.maxItems)}return{isMultiInstance:s,minItems:r,maxItems:i}}}},9607(e,t,r){t.CedarJsonWriters=void 0;const n=r(2022),a=r(4872),i=r(7519),s=r(4869),o=r(7501),l=r(3691),c=r(4841),d=r(5459),u=r(8970),m=r(2347),p=r(41),h=r(6029),f=r(6766),T=r(9309),y=r(8663),E=r(7335),C=r(275),g=r(6876),I=r(9031),A=r(9129),b=r(1442),R=r(8280),S=r(8354),_=r(5996),v=r(2418),N=r(9222),w=r(9184),L=r(7054),F=r(2395),O=r(2813),V=r(6645),B=r(2981),D=r(7432),M=r(8014),U=r(3281),J=r(7661),Y=r(6320),x=r(7584),P=r(8096),k=r(6122),W=r(3312),K=r(4780),j=r(5250),G=r(7412);class X{behavior;jsonDynamicFieldWriters;jsonStaticFieldWriters;jsonValueConstraintsWriters;jsonAtomicWriter;jsonAnnotationsWriter;jsonTemplateWriter;jsonTemplateElementWriter;jsonTemplateInstanceWriter;constructor(e){this.behavior=e,this.jsonAtomicWriter=new a.JsonAtomicWriter(e),this.jsonAnnotationsWriter=new B.JsonAnnotationsWriter(e),this.jsonTemplateWriter=i.JsonTemplateWriter.getFor(e,this),this.jsonTemplateElementWriter=V.JsonTemplateElementWriter.getFor(e,this),this.jsonTemplateInstanceWriter=Y.JsonTemplateInstanceWriter.getFor(e,this),this.jsonDynamicFieldWriters=new Map([[s.CedarFieldType.TEXT,new o.JsonFieldWriterTextField(e,this)],[s.CedarFieldType.TEXTAREA,new C.JsonFieldWriterTextArea(e,this)],[s.CedarFieldType.CONTROLLED_TERM,new R.JsonFieldWriterControlledTerm(e,this)],[s.CedarFieldType.PHONE_NUMBER,new g.JsonFieldWriterPhoneNumber(e,this)],[s.CedarFieldType.EMAIL,new I.JsonFieldWriterEmail(e,this)],[s.CedarFieldType.LINK,new l.JsonFieldWriterLink(e,this)],[s.CedarFieldType.EXT_ROR,new x.JsonFieldWriterExtRor(e,this)],[s.CedarFieldType.EXT_ORCID,new P.JsonFieldWriterExtOrcid(e,this)],[s.CedarFieldType.EXT_PFAS,new k.JsonFieldWriterExtPfas(e,this)],[s.CedarFieldType.EXT_PUBMED,new W.JsonFieldWriterExtPubmed(e,this)],[s.CedarFieldType.EXT_RRID,new K.JsonFieldWriterExtRrid(e,this)],[s.CedarFieldType.EXT_NIH_GRANT_ID,new j.JsonFieldWriterExtNihGrantId(e,this)],[s.CedarFieldType.EXT_DOI,new G.JsonFieldWriterExtDoi(e,this)],[s.CedarFieldType.NUMERIC,new c.JsonFieldWriterNumeric(e,this)],[s.CedarFieldType.TEMPORAL,new d.JsonFieldWriterTemporal(e,this)],[s.CedarFieldType.RADIO,new T.JsonFieldWriterRadio(e,this)],[s.CedarFieldType.CHECKBOX,new y.JsonFieldWriterCheckbox(e,this)],[s.CedarFieldType.SINGLE_SELECT_LIST,new E.JsonFieldWriterList(e,this)],[s.CedarFieldType.MULTIPLE_SELECT_LIST,new E.JsonFieldWriterList(e,this)],[s.CedarFieldType.ATTRIBUTE_VALUE,new b.JsonFieldWriterAttributeValue(e,this)]]),this.jsonStaticFieldWriters=new Map([[s.CedarFieldType.STATIC_PAGE_BREAK,new m.JsonFieldWriterStaticPageBreak(e,this)],[s.CedarFieldType.STATIC_SECTION_BREAK,new p.JsonFieldWriterStaticSectionsBreak(e,this)],[s.CedarFieldType.STATIC_IMAGE,new u.JsonFieldWriterStaticImage(e,this)],[s.CedarFieldType.STATIC_RICH_TEXT,new h.JsonFieldWriterStaticRichText(e,this)],[s.CedarFieldType.STATIC_YOUTUBE,new f.JsonFieldWriterStaticYoutube(e,this)]]),this.jsonValueConstraintsWriters=new Map([[S.ControlledTermOntology.className,new _.JsonValueConstraintsOntologyWriter(e,this)],[v.ControlledTermClass.className,new N.JsonValueConstraintsClassWriter(e,this)],[w.ControlledTermBranch.className,new L.JsonValueConstraintsBranchWriter(e,this)],[F.ControlledTermValueSet.className,new O.JsonValueConstraintsValueSetWriter(e,this)],[D.ControlledTermAction.className,new M.JsonValueConstraintsActionWriter(e,this)]])}static getStrict(){return new X(n.JsonWriterBehavior.STRICT)}static getFebruary2024(){return new X(n.JsonWriterBehavior.FEBRUARY_2024)}static getFor(e){return new X(e)}getTemplateWriter(){return this.jsonTemplateWriter}getTemplateElementWriter(){return this.jsonTemplateElementWriter}getTemplateInstanceWriter(){return this.jsonTemplateInstanceWriter}getAtomicWriter(){return this.jsonAtomicWriter}getFieldWriterForType(e){let t;if(t=e.isStaticField?this.jsonStaticFieldWriters.get(e):this.jsonDynamicFieldWriters.get(e),t)return t;throw new Error(`No JSON writer found for field type: ${e.getValue()}`)}getWriterForValueConstraint(e){const t=e.className,r=this.jsonValueConstraintsWriters.get(t);if(r)return r;throw new Error(`No JSON writer found for class type: ${t}`)}getFieldWriterForField(e){return this.getFieldWriterForType(e.cedarFieldType)}getAnnotationsWriter(){return this.jsonAnnotationsWriter}getWriterForArtifact(e){if(e instanceof U.Template)return i.JsonTemplateWriter.getFor(this.behavior,this);if(e instanceof J.TemplateElement)return V.JsonTemplateElementWriter.getFor(this.behavior,this);if(e instanceof A.TemplateField)return this.getFieldWriterForType(e.cedarFieldType);throw new Error(`No JSON reader available for CedarArtifact: ${e}`)}}t.CedarJsonWriters=X},3161(e,t,r){t.JsonAbstractArtifactWriter=void 0;const n=r(2112),a=r(9517),i=r(2733),s=r(3910),o=r(1027),l=r(936),c=r(8534);class d extends n.AbstractArtifactWriter{behavior;writers;atomicWriter;annotationsWriter;constructor(e,t){super(),this.behavior=e,this.writers=t,this.atomicWriter=t.getAtomicWriter(),this.annotationsWriter=t.getAnnotationsWriter()}getBehavior(){return this.behavior}macroSchemaNameAndDescription(e){return{[i.JsonSchema.schemaName]:e.schema_name,[i.JsonSchema.schemaDescription]:e.schema_description}}macroProvenance(e,t){return{[i.JsonSchema.pavCreatedOn]:t.write(e.pav_createdOn),[i.JsonSchema.pavCreatedBy]:t.write(e.pav_createdBy),[i.JsonSchema.pavLastUpdatedOn]:t.write(e.pav_lastUpdatedOn),[i.JsonSchema.oslcModifiedBy]:t.write(e.oslc_modifiedBy)}}macroStatusAndVersion(e,t){const r=a.JsonNode.getEmpty();return e.pav_version!==o.PavVersion.NULL&&(r[i.JsonSchema.pavVersion]=t.write(e.pav_version)),e.bibo_status!==s.BiboStatus.NULL&&(r[i.JsonSchema.biboStatus]=t.write(e.bibo_status)),r}macroSkos(e){const t=a.JsonNode.getEmpty();return null!==e.skos_prefLabel&&(t[l.CedarModel.skosPrefLabel]=e.skos_prefLabel),null!==e.skos_altLabel&&e.skos_altLabel.length>0&&(t[l.CedarModel.skosAltLabel]=e.skos_altLabel),t}macroDerivedFrom(e){const t=a.JsonNode.getEmpty();return e.pav_derivedFrom!==c.CedarArtifactId.NULL&&(t[i.JsonSchema.pavDerivedFrom]=this.atomicWriter.write(e.pav_derivedFrom)),t}macroIsBasedOn(e){const t=a.JsonNode.getEmpty();return e.schema_isBasedOn!==c.CedarArtifactId.NULL&&(t[i.JsonSchema.schemaIsBasedOn]=this.atomicWriter.write(e.schema_isBasedOn)),t}macroPreviousVersion(e){const t=a.JsonNode.getEmpty();return e.pav_previousVersion!==c.CedarArtifactId.NULL&&(t[i.JsonSchema.pavPreviousVersion]=this.atomicWriter.write(e.pav_previousVersion)),t}macroSchemaIdentifier(e){const t=a.JsonNode.getEmpty();return null!==e.schema_identifier&&(t[i.JsonSchema.schemaIdentifier]=e.schema_identifier),t}macroAnnotations(e){return this.annotationsWriter.write(e.annotations)}}t.JsonAbstractArtifactWriter=d},8872(e,t,r){t.JsonAbstractContainerArtifactWriter=void 0;const n=r(3161),a=r(6968),i=r(9517),s=r(9129),o=r(2733),l=r(936),c=r(5692),d=r(8748);class u extends n.JsonAbstractArtifactWriter{macroContext(e){return a.JsonContainerArtifactContent.CONTEXT_VERBATIM}getChildMapAsJson(e){const t=i.JsonNode.getEmpty();return e.getChildrenInfo().getChildrenNames().forEach(r=>{const n=e.getChild(r);if(null!=n){let a=i.JsonNode.getEmpty();const d=e.getChildrenInfo().get(r);if(null!==d&&(a=n instanceof s.TemplateField?this.writers.getFieldWriterForType(n.cedarFieldType).getAsJsonNode(n,d):this.writers.getTemplateElementWriter().getAsJsonNode(n)),null!==d){const{isMultiInstance:e,minItems:s,maxItems:u}=c.WriterUtil.getMultiMinMax(n,d);let m=s,p=u;if(e){null===m&&(m=0),null!==p&&p<m&&(p=m);const e=i.JsonNode.getEmpty();e[l.CedarModel.minItems]=m,null!==p&&(e[l.CedarModel.maxItems]=p),a={[o.JsonSchema.type]:"array",...e,[o.JsonSchema.items]:a}}t[r]=a}}}),t}expandInstanceTypeSpecification(e,t){if(null!==e.instanceTypeSpecification){const r=d.ReaderUtil.getNode(t,o.JsonSchema.atType);d.ReaderUtil.getNodeList(r,o.JsonSchema.oneOf).forEach(t=>{const r=d.ReaderUtil.getString(t,o.JsonSchema.type);"string"==r?t[o.JsonSchema.enum]=[e.instanceTypeSpecification]:"array"==r&&(d.ReaderUtil.getNode(t,o.JsonSchema.items)[o.JsonSchema.enum]=[e.instanceTypeSpecification])})}}}t.JsonAbstractContainerArtifactWriter=u},2981(e,t,r){t.JsonAnnotationsWriter=void 0;const n=r(9517),a=r(936),i=r(2787),s=r(2733),o=r(3549);t.JsonAnnotationsWriter=class{behavior;constructor(e){this.behavior=e}write(e){const t=n.JsonNode.getEmpty();if(null!==e&&e.getSize()>0){const r=n.JsonNode.getEmpty();e.getAnnotationNames().forEach(t=>{const n=e.get(t);n instanceof i.AnnotationAtId?r[t]={[s.JsonSchema.atId]:n.getAtId()}:n instanceof o.AnnotationAtValue&&(r[t]={[s.JsonSchema.atValue]:n.getAtValue()})}),t[a.CedarModel.annotations]=r}return t}}},4872(e,t,r){t.JsonAtomicWriter=void 0;const n=r(8534),a=r(2763),i=r(5793),s=r(9857),o=r(2234),l=r(3910),c=r(1027),d=r(2475),u=r(8557),m=r(3447),p=r(8588),h=r(7974),f=r(3764),T=r(9034),y=r(3746),E=r(9932),C=r(8802),g=r(4531),I=r(7752);t.JsonAtomicWriter=class{behavior;constructor(e){this.behavior=e}write(e){if(null==e)return null;if(e instanceof n.CedarArtifactId)return this.writeCedarArtifactId(e);if(e instanceof a.CedarArtifactType)return this.writeCedarArtifactType(e);if(e instanceof i.JavascriptType)return this.writeJavascriptType(e);if(e instanceof s.IsoDate)return this.writeCedarDate(e);if(e instanceof o.CedarUser)return this.writeCedarUser(e);if(e instanceof l.BiboStatus)return this.writeBiboStatusJson(e);if(e instanceof c.PavVersion)return this.writePavVersion(e);if(e instanceof d.ArtifactSchema)return this.writeCedarSchema(e);if(e instanceof u.SchemaVersion)return this.writeSchemaVersion(e);if(e instanceof m.NumberType)return this.writeNumberType(e);if(e instanceof p.TemporalType)return this.writeTemporalType(e);if(e instanceof h.TemporalGranularity)return this.writeTemporalGranularity(e);if(e instanceof f.TimeFormat)return this.writeTimeFormat(e);if(e instanceof T.UiInputType)return this.writeUiInputType(e);if(e instanceof y.AdditionalProperties)return this.writeAdditionalProperties(e);if(e instanceof C.Iri)return this.writeURI(e);if(e instanceof g.BioportalTermType)return this.writeBioportalTermTypeJson(e);if(e instanceof I.Language)return this.writeLanguage(e);throw new Error("Unsupported type")}writeCedarArtifactId(e){return e.getValue()}writeCedarArtifactType(e){return e.getValue()}writeJavascriptType(e){return e.getValue()}writeCedarDate(e){return e.getValue()}writeCedarUser(e){return e.getValue()}writeBiboStatusJson(e){return e.getJsonValue()}writePavVersion(e){return e.getValue()}writeCedarSchema(e){return e.getValue()}writeSchemaVersion(e){return null!==e.getValue()?e.getValue():u.SchemaVersion.CURRENT.getValue()}writeNumberType(e){return e.getValue()}writeTemporalType(e){return e.getValue()}writeTemporalGranularity(e){return e.getValue()}writeTimeFormat(e){return e.getValue()}writeUiInputType(e){return e.getValue()}writeAdditionalProperties(e){return e!==y.AdditionalProperties.FALSE&&(e===y.AdditionalProperties.ALLOW_ATTRIBUTE_VALUE?E.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_OUTSIDE:null)}writeURI(e){return e.getValue()}writeBioportalTermTypeJson(e){return e.getJsonValue()}writeLanguage(e){return e.getValue()}}},6645(e,t,r){t.JsonTemplateElementWriter=void 0;const n=r(8748),a=r(2733),i=r(936),s=r(2763),o=r(5793),l=r(5747),c=r(2475),d=r(9932),u=r(1501),m=r(8872),p=r(7752);class h extends m.JsonAbstractContainerArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new h(e,t)}buildProperties(e){const t=n.ReaderUtil.deepClone(u.JsonTemplateElementContent.PROPERTIES_PARTIAL);e.language!==p.Language.NULL&&(t[a.JsonSchema.atContext][a.JsonSchema.atLanguage]=this.atomicWriter.write(e.language));const r=e.getChildrenInfo().getIRIMap();t[a.JsonSchema.atContext][a.JsonSchema.properties]={...t[a.JsonSchema.atContext][a.JsonSchema.properties],...r};const i=Object.keys(r);i.length>0?t[a.JsonSchema.atContext][a.JsonSchema.required]=[...t[a.JsonSchema.atContext][a.JsonSchema.required],...i]:n.ReaderUtil.deleteNodeKey(t[a.JsonSchema.atContext],a.JsonSchema.required),e.getChildrenInfo().hasAttributeValue()&&(t[a.JsonSchema.atContext][l.TemplateProperty.additionalProperties]=d.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE);const s={...t,...this.getChildMapAsJson(e)};return this.expandInstanceTypeSpecification(e,s),s}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=this.buildProperties(e),r={[i.CedarModel.order]:e.getChildrenInfo().getChildrenNames(),[i.CedarModel.propertyLabels]:e.getChildrenInfo().getPropertyLabelMap(e),[i.CedarModel.propertyDescriptions]:e.getChildrenInfo().getPropertyDescriptionMap(e)};return{[a.JsonSchema.atId]:this.atomicWriter.write(e.at_id),[a.JsonSchema.atType]:this.atomicWriter.write(s.CedarArtifactType.TEMPLATE_ELEMENT),[a.JsonSchema.atContext]:this.macroContext(e),[i.CedarModel.type]:this.atomicWriter.write(o.JavascriptType.OBJECT),[l.TemplateProperty.title]:e.title,[l.TemplateProperty.description]:e.description,[i.CedarModel.ui]:r,[a.JsonSchema.properties]:t,[a.JsonSchema.required]:[...u.JsonTemplateElementContent.REQUIRED_PARTIAL,...e.getChildrenInfo().getChildrenNamesForRequired()],...this.macroAnnotations(e),...this.macroSchemaNameAndDescription(e),...this.macroProvenance(e,this.atomicWriter),...this.macroSkos(e),...this.macroStatusAndVersion(e,this.atomicWriter),...this.macroDerivedFrom(e),...this.macroPreviousVersion(e),[a.JsonSchema.schemaVersion]:this.atomicWriter.write(e.schema_schemaVersion),[l.TemplateProperty.additionalProperties]:this.atomicWriter.write(e.getAdditionalProperties()),...this.macroSchemaIdentifier(e),[i.CedarModel.schema]:this.atomicWriter.write(c.ArtifactSchema.CURRENT)}}}t.JsonTemplateElementWriter=h},2748(e,t,r){t.JsonTemplateFieldWriterInternal=void 0;const n=r(9517),a=r(936),i=r(2733),s=r(9932),o=r(5793),l=r(5747),c=r(2475),d=r(3161),u=r(3746),m=r(455),p=r(3812),h=r(7752),f=r(8748);class T extends d.JsonAbstractArtifactWriter{constructor(e,t){super(e,t)}expandPropertiesNode(e){e[i.JsonSchema.properties]=s.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_LITERAL,this.behavior.usePropertiesAtLanguage()||(e[i.JsonSchema.properties]=s.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE)}expandRequiredNode(e){e[i.JsonSchema.required]=[i.JsonSchema.atValue]}expandUINode(e,t,r){r instanceof p.AbstractDynamicChildDeploymentInfo&&(r.hidden&&(e[a.CedarModel.Ui.hidden]=r.hidden),r.continuePreviousLine&&(e[a.CedarModel.Ui.continuePreviousLine]=r.continuePreviousLine),r.valueRecommendationEnabled&&t.supportsValueRecommendation()&&(e[a.CedarModel.Ui.valueRecommendationEnabled]=r.valueRecommendationEnabled))}buildUIObject(e,t){const r={[a.CedarModel.inputType]:this.atomicWriter.write(e.cedarFieldType.getUiInputType())},n={[a.CedarModel.ui]:r};return this.expandUINode(r,e,t),n}expandTypeNode(e,t){}expandValueConstraintsNode(e,t,r){r instanceof p.AbstractDynamicChildDeploymentInfo&&(e[a.CedarModel.requiredValue]=r.requiredValue),r instanceof p.AbstractDynamicChildDeploymentInfo&&r.recommendedValue&&(e[a.CedarModel.ValueConstraints.recommendedValue]=r.recommendedValue)}buildValueConstraintsObject(e,t){const r=n.JsonNode.getEmpty(),i={[a.CedarModel.valueConstraints]:r};return this.expandValueConstraintsNode(r,e,t),i}expandLiterals(e,t){const r=n.JsonNode.getEmptyList();e.valueConstraints.literals.forEach(e=>{const t=n.JsonNode.getEmpty();t[a.CedarModel.label]=e.label,e.selectedByDefault&&(t[a.CedarModel.selectedByDefault]=e.selectedByDefault),r.push(t)}),r.length>0&&(t[a.CedarModel.literals]=r)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e,m.ChildDeploymentInfo.empty()),null,t)}getAsJsonNode(e,t=m.ChildDeploymentInfo.empty()){const r=n.JsonNode.getEmpty();this.expandPropertiesNode(r);const s=n.JsonNode.getEmpty();this.expandRequiredNode(s);const d=this.buildUIObject(e,t),p=this.buildValueConstraintsObject(e,t),h={[a.CedarModel.type]:this.atomicWriter.write(o.JavascriptType.OBJECT)};return this.expandTypeNode(h,e),{[i.JsonSchema.atId]:this.atomicWriter.write(e.at_id),[i.JsonSchema.atType]:this.atomicWriter.write(e.cedarArtifactType),[i.JsonSchema.atContext]:this.macroContext(e),...h,[l.TemplateProperty.title]:e.title,[l.TemplateProperty.description]:e.description,...d,...p,...r,...s,...this.macroAnnotations(e),...this.macroSchemaNameAndDescription(e),...this.macroProvenance(e,this.atomicWriter),...this.macroSkos(e),...this.macroStatusAndVersion(e,this.atomicWriter),...this.macroDerivedFrom(e),...this.macroPreviousVersion(e),[i.JsonSchema.schemaVersion]:this.atomicWriter.write(e.schema_schemaVersion),[l.TemplateProperty.additionalProperties]:this.atomicWriter.write(u.AdditionalProperties.FALSE),...this.macroSchemaIdentifier(e),[a.CedarModel.schema]:this.atomicWriter.write(c.ArtifactSchema.CURRENT)}}macroContext(e){const t=f.ReaderUtil.deepClone(s.JsonTemplateFieldContentDynamic.CONTEXT_VERBATIM);return e.language!==h.Language.NULL&&(t[i.JsonSchema.atLanguage]=this.atomicWriter.write(e.language)),t}}t.JsonTemplateFieldWriterInternal=T},6320(e,t,r){t.JsonTemplateInstanceWriter=void 0;const n=r(8748),a=r(2733),i=r(9517),s=r(3161),o=r(350),l=r(7723),c=r(5222),d=r(4877),u=r(9327),m=r(3644),p=r(8193),h=r(7571),f=r(7548),T=r(4465),y=r(4033);class E extends s.JsonAbstractArtifactWriter{constructor(e,t){super(e,t)}macroContext(e){return o.JsonTemplateInstanceContent.CONTEXT_VERBATIM}static getFor(e,t){return new E(e,t)}buildContext(e){const t=n.ReaderUtil.deepClone(o.JsonTemplateInstanceContent.CONTEXT_VERBATIM);return Object.keys(e.dataContainer.iris).forEach(r=>{t[r]=e.dataContainer.iris[r]}),{...t}}getDataTree(e){const t=i.JsonNode.getEmpty();return this.serializeDataLevelInto(e.dataContainer,t,!0),t}serializeDataLevelInto(e,t,r=!1){r||(t[a.JsonSchema.atId]=""===e.id?null:e.id),Object.keys(e.values).forEach(r=>{const n=e.values[r];if(Array.isArray(n)){const e=i.JsonNode.getEmptyList();t[r]=e,n.forEach((t,r)=>{if(t instanceof m.InstanceDataAttributeValueFieldName){const r=t.name;return void(r.trim().length>0&&e.push(r))}const n=this.serializeCommonType(t);null!==n&&e.push(n)})}else{const e=this.serializeCommonType(n);if(null!==e&&(t[r]=e),n instanceof u.InstanceDataAttributeValueField){const e=[];Object.keys(n.values).forEach(t=>{e.push(t)}),t[r]=e}}}),this.serializeAttributeValueFields(e,t);const n=i.JsonNode.getEmpty();Object.keys(e.iris).forEach(t=>{n[t]=e.iris[t]}),t[a.JsonSchema.atContext]=n}static writeValueNode(e){return e instanceof c.InstanceDataStringAtom?{[a.JsonSchema.atValue]:e.value}:e instanceof d.InstanceDataTypedAtom?{[a.JsonSchema.atValue]:e.value,[a.JsonSchema.atType]:e.type}:e instanceof p.InstanceDataControlledAtom?{[a.JsonSchema.atId]:e.id,[a.JsonSchema.rdfsLabel]:e.label}:e instanceof h.InstanceDataLinkAtom?{[a.JsonSchema.atId]:e.id}:e instanceof f.InstanceDataEmptyAtom||e instanceof T.InstanceDataEmptyNode?i.JsonNode.getEmpty():null}serializeCommonType(e){if(e instanceof l.InstanceDataContainer){const t=i.JsonNode.getEmpty();return this.serializeDataLevelInto(e,t),t}return E.writeValueNode(e)}serializeAtomString(e){return{[a.JsonSchema.atValue]:e.value}}serializeAttributeValueFields(e,t){Object.keys(e.values).forEach(r=>{const n=e.values[r];n instanceof u.InstanceDataAttributeValueField&&Object.keys(n.values).forEach(e=>{const r=n.values[e];r instanceof c.InstanceDataStringAtom&&(t[e]=this.serializeAtomString(r))})})}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){y.AttributeValueNamePolicy.assertValid(e.dataContainer);const t=this.buildContext(e);return{[a.JsonSchema.atId]:this.atomicWriter.write(e.at_id),...this.macroSchemaNameAndDescription(e),...this.getDataTree(e),...this.macroAnnotations(e),[a.JsonSchema.atContext]:t,...this.macroIsBasedOn(e),...this.macroProvenance(e,this.atomicWriter),...this.macroDerivedFrom(e)}}}t.JsonTemplateInstanceWriter=E},7519(e,t,r){t.JsonTemplateWriter=void 0;const n=r(8748),a=r(6551),i=r(2733),s=r(936),o=r(2763),l=r(5793),c=r(5747),d=r(2475),u=r(9932),m=r(8872),p=r(7752);class h extends m.JsonAbstractContainerArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new h(e,t)}buildProperties(e){const t=n.ReaderUtil.deepClone(a.JsonTemplateContent.PROPERTIES_PARTIAL);e.language!==p.Language.NULL&&(t[i.JsonSchema.atContext][i.JsonSchema.atLanguage]=this.atomicWriter.write(e.language));const r=e.getChildrenInfo().getIRIMap();t[i.JsonSchema.atContext][i.JsonSchema.properties]={...t[i.JsonSchema.atContext][i.JsonSchema.properties],...r};const s=Object.keys(r);t[i.JsonSchema.atContext][i.JsonSchema.required]=[...t[i.JsonSchema.atContext][i.JsonSchema.required],...s],e.getChildrenInfo().hasAttributeValue()&&(t[i.JsonSchema.atContext][c.TemplateProperty.additionalProperties]=u.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE);const o={...t,...this.getChildMapAsJson(e)};return this.expandInstanceTypeSpecification(e,o),o}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=this.buildProperties(e),r={[s.CedarModel.order]:e.getChildrenInfo().getChildrenNames(),[s.CedarModel.propertyLabels]:e.getChildrenInfo().getPropertyLabelMap(e),[s.CedarModel.propertyDescriptions]:e.getChildrenInfo().getPropertyDescriptionMap(e)};return this.behavior.outputPages()&&(r[s.CedarModel.pages]=[]),null!==e.header&&(r[s.CedarModel.header]=e.header),null!==e.footer&&(r[s.CedarModel.footer]=e.footer),{[i.JsonSchema.atId]:this.atomicWriter.write(e.at_id),[i.JsonSchema.atType]:this.atomicWriter.write(o.CedarArtifactType.TEMPLATE),[i.JsonSchema.atContext]:this.macroContext(e),[s.CedarModel.type]:this.atomicWriter.write(l.JavascriptType.OBJECT),[c.TemplateProperty.title]:e.title,[c.TemplateProperty.description]:e.description,[s.CedarModel.ui]:r,[i.JsonSchema.properties]:t,[i.JsonSchema.required]:[...a.JsonTemplateContent.REQUIRED_PARTIAL,...e.getChildrenInfo().getChildrenNamesForRequired()],[c.TemplateProperty.additionalProperties]:this.atomicWriter.write(e.getAdditionalProperties()),...this.macroAnnotations(e),...this.macroSchemaNameAndDescription(e),...this.macroProvenance(e,this.atomicWriter),...this.macroStatusAndVersion(e,this.atomicWriter),...this.macroDerivedFrom(e),...this.macroPreviousVersion(e),[i.JsonSchema.schemaVersion]:this.atomicWriter.write(e.schema_schemaVersion),...this.macroSchemaIdentifier(e),[s.CedarModel.schema]:this.atomicWriter.write(d.ArtifactSchema.CURRENT)}}}t.JsonTemplateWriter=h},5359(e,t,r){t.CedarYamlWriters=void 0;const n=r(4869),a=r(1933),i=r(8354),s=r(2418),o=r(9184),l=r(2395),c=r(7432),d=r(6116),u=r(2342),m=r(2287),p=r(836),h=r(7436),f=r(7594),T=r(1784),y=r(6082),E=r(4935),C=r(6314),g=r(1903),I=r(5251),A=r(1521),b=r(1038),R=r(3292),S=r(9821),_=r(4500),v=r(3080),N=r(8136),w=r(9535),L=r(1181),F=r(765),O=r(3671),V=r(9532),B=r(4647),D=r(9411),M=r(9326),U=r(491),J=r(4355),Y=r(5587),x=r(6557),P=r(4077),k=r(3711),W=r(6967);class K{behavior;yamlDynamicFieldWriters;yamlStaticFieldWriters;yamlValueConstraintsWriters;yamlAtomicWriter;yamlAnnotationsWriter;yamlTemplateWriter;yamlTemplateElementWriter;yamlTemplateInstanceWriter;constructor(e){this.behavior=e,this.yamlAtomicWriter=new u.YamlAtomicWriter(e),this.yamlAnnotationsWriter=new m.YamlAnnotationsWriter(e),this.yamlTemplateWriter=a.YamlTemplateWriter.getFor(e,this),this.yamlTemplateElementWriter=I.YamlTemplateElementWriter.getFor(e,this),this.yamlTemplateInstanceWriter=M.YamlTemplateInstanceWriter.getFor(e,this),this.yamlDynamicFieldWriters=new Map([[n.CedarFieldType.TEXT,new d.YamlFieldWriterTextField(e,this)],[n.CedarFieldType.TEXTAREA,new p.YamlFieldWriterTextArea(e,this)],[n.CedarFieldType.CONTROLLED_TERM,new w.YamlFieldWriterControlledTerm(e,this)],[n.CedarFieldType.PHONE_NUMBER,new S.YamlFieldWriterPhoneNumber(e,this)],[n.CedarFieldType.EMAIL,new b.YamlFieldWriterEmail(e,this)],[n.CedarFieldType.LINK,new T.YamlFieldWriterLink(e,this)],[n.CedarFieldType.EXT_ROR,new U.YamlFieldWriterExtRor(e,this)],[n.CedarFieldType.EXT_ORCID,new J.YamlFieldWriterExtOrcid(e,this)],[n.CedarFieldType.EXT_PFAS,new Y.YamlFieldWriterExtPfas(e,this)],[n.CedarFieldType.EXT_PUBMED,new x.YamlFieldWriterExtPubmed(e,this)],[n.CedarFieldType.EXT_RRID,new P.YamlFieldWriterExtRrid(e,this)],[n.CedarFieldType.EXT_NIH_GRANT_ID,new k.YamlFieldWriterExtNihGrantId(e,this)],[n.CedarFieldType.EXT_DOI,new W.YamlFieldWriterExtDoi(e,this)],[n.CedarFieldType.NUMERIC,new R.YamlFieldWriterNumeric(e,this)],[n.CedarFieldType.TEMPORAL,new h.YamlFieldWriterTemporal(e,this)],[n.CedarFieldType.RADIO,new N.YamlFieldWriterRadio(e,this)],[n.CedarFieldType.CHECKBOX,new _.YamlFieldWriterCheckbox(e,this)],[n.CedarFieldType.SINGLE_SELECT_LIST,new v.YamlFieldWriterList(e,this)],[n.CedarFieldType.MULTIPLE_SELECT_LIST,new v.YamlFieldWriterList(e,this)],[n.CedarFieldType.ATTRIBUTE_VALUE,new A.YamlFieldWriterAttributeValue(e,this)]]),this.yamlStaticFieldWriters=new Map([[n.CedarFieldType.STATIC_PAGE_BREAK,new f.YamlFieldWriterStaticPageBreak(e,this)],[n.CedarFieldType.STATIC_SECTION_BREAK,new y.YAMLFieldWriterStaticSectionsBreak(e,this)],[n.CedarFieldType.STATIC_IMAGE,new E.YamlFieldWriterStaticImage(e,this)],[n.CedarFieldType.STATIC_RICH_TEXT,new C.YamlFieldWriterStaticRichText(e,this)],[n.CedarFieldType.STATIC_YOUTUBE,new g.YamlFieldWriterStaticYoutube(e,this)]]),this.yamlValueConstraintsWriters=new Map([[i.ControlledTermOntology.className,new L.YamlValueConstraintsOntologyWriter(e,this)],[s.ControlledTermClass.className,new F.YamlValueConstraintsClassWriter(e,this)],[o.ControlledTermBranch.className,new O.YamlValueConstraintsBranchWriter(e,this)],[l.ControlledTermValueSet.className,new V.YamlValueConstraintsValueSetWriter(e,this)],[c.ControlledTermAction.className,new B.YamlValueConstraintsActionWriter(e,this)]])}static getStrict(){return new K(D.YamlWriterBehavior.STRICT)}static getFor(e){return new K(e)}getFieldWriterForType(e){let t;if(t=e.isStaticField?this.yamlStaticFieldWriters.get(e):this.yamlDynamicFieldWriters.get(e),t)return t;throw new Error(`No YAML writer found for field type: ${e.getValue()}`)}getFieldWriterForField(e){return this.getFieldWriterForType(e.cedarFieldType)}getAtomicWriter(){return this.yamlAtomicWriter}getAnnotationsWriter(){return this.yamlAnnotationsWriter}getTemplateWriter(){return this.yamlTemplateWriter}getTemplateElementWriter(){return this.yamlTemplateElementWriter}getTemplateInstanceWriter(){return this.yamlTemplateInstanceWriter}getWriterForValueConstraint(e){const t=e.className,r=this.yamlValueConstraintsWriters.get(t);if(r)return r;throw new Error(`No YAML writer found for class type: ${t}`)}}t.CedarYamlWriters=K},6574(e,t,r){var n,a=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),s=this&&this.__importStar||(n=function(e){return n=Object.getOwnPropertyNames||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[t.length]=r);return t},n(e)},function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r=n(e),s=0;s<r.length;s++)"default"!==r[s]&&a(t,e,r[s]);return i(t,e),t});Object.defineProperty(t,"__esModule",{value:!0}),t.SimpleYamlSerializer=void 0;const o=s(r(3198)),l=r(1100),c={blockQuote:"literal",doubleQuotedMinMultiLineLength:1e9,lineWidth:0,minContentWidth:0,defaultStringType:"QUOTE_DOUBLE",defaultKeyType:"PLAIN",doubleQuotedAsJSON:!0};t.SimpleYamlSerializer=class{static serialize(e){const t=new o.default.Document(e);return(0,o.visit)(t,{Scalar(e,t,r){if("key"===e&&"string"==typeof t.value&&(0,l.plainScalarNeedsQuoting)(t.value))t.type=o.Scalar.QUOTE_DOUBLE;else if("value"===e&&"string"==typeof t.value){const e=r.at(-1);(0,o.isPair)(e)&&(0,o.isScalar)(e.key)&&"string"==typeof e.key.value&&(0,l.mayWriteYamlValuePlain)(e.key.value,t.value)&&(t.type=o.Scalar.PLAIN)}}}),t.toString(c).trim()+"\n"}}},211(e,t,r){t.YamlAbstractArtifactWriter=void 0;const n=r(2112),a=r(8333),i=r(9517),s=r(2099),o=r(3910),l=r(1027),c=r(9129),d=r(8534),u=r(2234),m=r(9857),p=r(7661),h=r(9499),f=r(3281),T=r(6731),y=r(8972),E=r(7752),C=r(8557),g=r(2272);class I extends n.AbstractArtifactWriter{behavior;writers;atomicWriter;annotationsWriter;constructor(e,t){super(),this.behavior=e,this.writers=t,this.atomicWriter=t.getAtomicWriter(),this.annotationsWriter=t.getAnnotationsWriter()}macroNameAndDescription(e){const t=i.JsonNode.getEmpty();return e instanceof a.AbstractSchemaArtifact&&e.language!==E.Language.NULL&&(t[s.YamlKeys.language]=this.atomicWriter.write(e.language)),t[s.YamlKeys.name]=e.schema_name,null!==e.schema_description&&""!==e.schema_description&&(t[s.YamlKeys.description]=e.schema_description),t}macroStatusAndVersion(e,t){const r=i.JsonNode.getEmpty();return t||(e.bibo_status!==o.BiboStatus.NULL&&(r[s.YamlKeys.status]=this.atomicWriter.write(e.bibo_status)),e.pav_version!==l.PavVersion.NULL&&(r[s.YamlKeys.version]=this.atomicWriter.write(e.pav_version)),r[s.YamlKeys.modelVersion]=this.atomicWriter.write(C.SchemaVersion.CURRENT)),r}macroInstanceType(e){const t=i.JsonNode.getEmpty();return null!==e.instanceTypeSpecification&&(t[s.YamlKeys.instanceType]=e.instanceTypeSpecification),t}macroSkos(e){const t=i.JsonNode.getEmpty();return null!==e.skos_prefLabel&&(t[s.YamlKeys.prefLabel]=e.skos_prefLabel),null!==e.skos_altLabel&&e.skos_altLabel.length>0&&(t[s.YamlKeys.altLabels]=e.skos_altLabel),t}macroValueRecommendation(e){const t=i.JsonNode.getEmpty();return(e instanceof T.ControlledTermFieldImpl||e instanceof y.TextFieldImpl)&&e.valueRecommendationEnabled&&(t[s.YamlKeys.valueRecommendation]=e.valueRecommendationEnabled),t}macroProvenance(e,t){const r=i.JsonNode.getEmpty();return t||(e.pav_createdOn!==m.IsoDate.NULL&&(r[s.YamlKeys.createdOn]=this.atomicWriter.write(e.pav_createdOn)),e.pav_createdBy!==u.CedarUser.NULL&&(r[s.YamlKeys.createdBy]=this.atomicWriter.write(e.pav_createdBy)),e.pav_lastUpdatedOn!==m.IsoDate.NULL&&(r[s.YamlKeys.modifiedOn]=this.atomicWriter.write(e.pav_lastUpdatedOn)),e.oslc_modifiedBy!==u.CedarUser.NULL&&(r[s.YamlKeys.modifiedBy]=this.atomicWriter.write(e.oslc_modifiedBy))),r}macroSchemaIdentifier(e){const t=i.JsonNode.getEmpty();return null!==e.schema_identifier&&(t[s.YamlKeys.identifier]=e.schema_identifier),t}macroType(e){const t=i.JsonNode.getEmpty();return t[s.YamlKeys.type]=this.getYamlType(e),t}macroId(e,t=!1,r=!0){const n=i.JsonNode.getEmpty();return e.at_id===d.CedarArtifactId.NULL||t||(n[s.YamlKeys.id]=this.atomicWriter.write(e.at_id)),n}macroDerivedFrom(e,t){const r=i.JsonNode.getEmpty();return t||e.pav_derivedFrom!==d.CedarArtifactId.NULL&&(r[s.YamlKeys.derivedFrom]=this.atomicWriter.write(e.pav_derivedFrom)),r}macroIsBasedOn(e){const t=i.JsonNode.getEmpty();return e.schema_isBasedOn!==d.CedarArtifactId.NULL&&(t[s.YamlKeys.isBasedOn]=this.atomicWriter.write(e.schema_isBasedOn)),t}macroPreviousVersion(e,t){const r=i.JsonNode.getEmpty();return t||e.pav_previousVersion!==d.CedarArtifactId.NULL&&(r[s.YamlKeys.previousVersion]=this.atomicWriter.write(e.pav_previousVersion)),r}macroAnnotations(e){return this.annotationsWriter.write(e.annotations)}getYamlType(e){return e instanceof f.Template?h.YamlArtifactType.TEMPLATE.getValue():e instanceof p.TemplateElement?h.YamlArtifactType.ELEMENT.getValue():e instanceof c.TemplateField?e.cedarFieldType.getYamlType().getValue():e instanceof g.TemplateInstance?h.YamlArtifactType.TEMPLATE_INSTANCE.getValue():void 0}}t.YamlAbstractArtifactWriter=I},5386(e,t,r){t.YamlAbstractContainerArtifactWriter=void 0;const n=r(9517),a=r(9129),i=r(211),s=r(2099),o=r(3812),l=r(5692),c=r(699);class d extends i.YamlAbstractArtifactWriter{getChildListAsJSON(e,t){const r=n.JsonNode.getEmptyList();return e.getChildrenInfo().getChildrenNames().forEach(i=>{const o=e.getChild(i);if(null!=o){let l=n.JsonNode.getEmpty();const c=e.getChildrenInfo().get(i);if(null!==c){l[s.YamlKeys.key]=i,l=o instanceof a.TemplateField?{...l,...this.writers.getFieldWriterForType(o.cedarFieldType).getYamlAsJsonNode(o,c,t,!1)}:{...l,...this.writers.getTemplateElementWriter().getYamlAsJsonNode(o,t,!1)};const e=this.getDeploymentInfo(o,c,t);n.JsonNode.hasEntries(e)&&(l[s.YamlKeys.configuration]=e),r.push(l)}}}),r}getDeploymentInfo(e,t,r){const i=n.JsonNode.getEmpty();t instanceof o.AbstractDynamicChildDeploymentInfo&&(t.requiredValue&&(i[s.YamlKeys.required]=!0),t.hidden&&(i[s.YamlKeys.hidden]=!0),t.recommendedValue&&(i[s.YamlKeys.recommended]=!0),null!==t.iri&&(r||(i[s.YamlKeys.propertyIri]=t.iri))),null!==t.label&&t.label!==e?.schema_name&&(i[s.YamlKeys.overrideLabel]=t.label),null!==t.description&&t.description!==e?.schema_description&&(i[s.YamlKeys.overrideDescription]=t.description),t instanceof o.AbstractDynamicChildDeploymentInfo&&(t.continuePreviousLine&&(i[s.YamlKeys.continuePreviousLine]=!0),t.valueRecommendationEnabled&&e instanceof a.TemplateField&&e.supportsValueRecommendation()&&(i[s.YamlKeys.valueRecommendation]=!0));const{isMultiInstance:d,minItems:u,maxItems:m}=l.WriterUtil.getMultiMinMax(e,t);let p=u,h=m;return d&&(null===p&&(p=0),null!==h&&h<p&&(h=p),e?.isMultiInstanceByDefinition()||e?.isSingleInstanceByDefinition()||(i[s.YamlKeys.multiple]=!0,i[s.YamlKeys.minItems]=p,null!==h&&(i[s.YamlKeys.maxItems]=h))),(0,c.isSizedStaticField)(e)&&(null!==e.width&&(i[s.YamlKeys.width]=e.width),null!==e.height&&(i[s.YamlKeys.height]=e.height)),i}}t.YamlAbstractContainerArtifactWriter=d},2287(e,t,r){t.YamlAnnotationsWriter=void 0;const n=r(9517),a=r(2787),i=r(3549),s=r(2099);t.YamlAnnotationsWriter=class{behavior;constructor(e){this.behavior=e}write(e){const t=n.JsonNode.getEmpty(),r=n.JsonNode.getEmpty();return null!==e&&e.getSize()>0&&(e.getAnnotationNames().forEach(t=>{const n=e.get(t);if(n instanceof a.AnnotationAtId){const e={[s.YamlKeys.id]:n.getAtId()};r[t]=e}else if(n instanceof i.AnnotationAtValue){const e={[s.YamlKeys.value]:n.getAtValue()};r[t]=e}}),t[s.YamlKeys.annotations]=r),t}}},2342(e,t,r){t.YamlAtomicWriter=void 0;const n=r(2022),a=r(4872),i=r(4531),s=r(3910);class o extends a.JsonAtomicWriter{constructor(e){super(n.JsonWriterBehavior.STRICT)}writeCedarArtifactType(e){return e.getYamlValue()}write(e){return null==e?null:e instanceof s.BiboStatus?this.writeBiboStatusYaml(e):e instanceof i.BioportalTermType?this.writeBioportalTermTypeYaml(e):super.write(e)}writeBiboStatusYaml(e){return e.getYamlValue()}writeBioportalTermTypeYaml(e){return e.getYamlValue()}}t.YamlAtomicWriter=o},1100(e,t,r){t.plainScalarNeedsQuoting=m,t.mayWriteYamlValuePlain=function(e,t){return(T.get(e)?.has(t)??(("version"===e||"modelVersion"===e)&&f.test(t)))&&!m(t)};const n=r(8349),a=r(4531),i=r(3910),s=r(3447),o=r(7974),l=r(8588),c=r(3764),d=r(9499),u=[/^(y|Y|n|N|yes|Yes|YES|no|No|NO|on|On|ON|off|Off|OFF|true|True|TRUE|false|False|FALSE)$/,/^(null|Null|NULL|~|<<|=)$/,/^[-+]?[0-9][0-9_]*$/,/^[-+]?0[xX][0-9a-fA-F_]+$/,/^[-+]?0[bB][01_]+$/,/^[-+]?0[oO]?[0-7_]+$/,/^[-+]?[0-9_]*\.?[0-9_]+([eE][-+]?[0-9]+)?$/,/^[-+]?\.(inf|Inf|INF|nan|NaN|NAN)$/,/^[-+]?[0-9][0-9_]*(:[0-5]?[0-9])+(\.[0-9_]*)?$/];function m(e){return u.some(t=>t.test(e))||function(e){for(const t of e){const e=t.codePointAt(0)??0;if(9===e||13===e||e<=31&&10!==e||e>=127&&e<=160||5760===e||e>=8192&&e<=8202||8232===e||8233===e||8239===e||8287===e||12288===e||65279===e)return!0}return e.startsWith(" ")||e.endsWith(" ")||e.includes(" \n")||0===e.length}(e)}const p=new Set([...Object.values(d.YamlArtifactTypeValues),"element-instance",n.YamlValues.Controlled.class,a.BioportalTermTypeYamlValues.VALUE,n.YamlValues.Controlled.ontology,n.YamlValues.Controlled.branch,n.YamlValues.Controlled.valueSet]),h=new Set(["xsd:string","xsd:anyUri",...Object.values(l.TemporalTypeValues),...Object.values(s.NumberTypeValues),n.YamlValues.iri]),f=/^\d+\.\d+\.\d+$/,T=new Map([["type",p],["status",new Set(Object.values(i.BiboStatusYamlValues))],["datatype",h],["action",new Set(["move","delete"])],["granularity",new Set(Object.values(o.TemporalGranularityValues))],["termType",new Set(Object.values(a.BioportalTermTypeYamlValues))],["inputTimeFormat",new Set(Object.values(c.TimeFormatValues))]]);new Set([...T.keys(),"version","modelVersion"])},5251(e,t,r){t.YamlTemplateElementWriter=void 0;const n=r(6574),a=r(2099),i=r(5386);class s extends i.YamlAbstractContainerArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new s(e,t)}getYamlAsJsonNode(e,t=!1,r=!0){const n={...this.macroType(e),...this.macroNameAndDescription(e),...this.macroSchemaIdentifier(e),...this.macroId(e,t,r),...this.macroStatusAndVersion(e,t),...this.macroInstanceType(e),...this.macroPreviousVersion(e,t),...this.macroDerivedFrom(e,t),...this.macroProvenance(e,t),...this.macroSkos(e),...this.macroAnnotations(e)},i=this.getChildListAsJSON(e,t);return i.length>0&&(n[a.YamlKeys.children]=i),n}getAsYamlString(e,t=!1){return n.SimpleYamlSerializer.serialize(this.getYamlAsJsonNode(e,t))}}t.YamlTemplateElementWriter=s},5430(e,t,r){t.YamlTemplateFieldWriterInternal=void 0;const n=r(9517),a=r(936),i=r(455),s=r(2099),o=r(211),l=r(6574);class c extends o.YamlAbstractArtifactWriter{constructor(e,t){super(e,t)}getAsYamlString(e,t=!1){return l.SimpleYamlSerializer.serialize(this.getYamlAsJsonNode(e,i.ChildDeploymentInfo.empty(),t))}getYamlAsJsonNode(e,t=i.ChildDeploymentInfo.empty(),r=!1,n=!0){const a=this.buildUIObject(e,t),s=this.buildValueConstraintsObject(e,t);return{...this.macroType(e),...this.macroNameAndDescription(e),...this.macroSchemaIdentifier(e),...this.macroId(e,r,n),...this.macroStatusAndVersion(e,r),...this.macroSkos(e),...a,...s,...this.macroValueRecommendation(e),...this.macroPreviousVersion(e,r),...this.macroDerivedFrom(e,r),...this.macroProvenance(e,r),...this.macroAnnotations(e)}}expandUINodeForYAML(e){return n.JsonNode.getEmpty()}expandValueConstraintsNodeForYAML(e,t,r){}buildValueConstraintsObject(e,t){const r=n.JsonNode.getEmpty();return this.expandValueConstraintsNodeForYAML(r,e,t),r}expandLiterals(e,t){const r=n.JsonNode.getEmptyList();e.valueConstraints.literals.forEach(e=>{const t=n.JsonNode.getEmpty();t[a.CedarModel.label]=e.label,e.selectedByDefault&&(t[s.YamlKeys.selected]=e.selectedByDefault),r.push(t)}),r.length>0&&(t[s.YamlKeys.values]=r)}buildUIObject(e,t){return this.expandUINodeForYAML(e)}}t.YamlTemplateFieldWriterInternal=c},9326(e,t,r){t.YamlTemplateInstanceWriter=void 0;const n=r(9517),a=r(6574),i=r(211),s=r(7723),o=r(9327),l=r(5222),c=r(7571),d=r(4877),u=r(8193),m=r(2099),p=r(4033),h=r(3644);class f extends i.YamlAbstractArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new f(e,t)}getYamlAsJsonNode(e,t=!1){return p.AttributeValueNamePolicy.assertValid(e.dataContainer),{...this.macroType(e),...this.macroNameAndDescription(e),...this.macroId(e,t,!0),...this.macroIsBasedOn(e),...this.macroDerivedFrom(e,t),...this.macroProvenance(e,t),...this.getDataTree(e,t),...this.macroAnnotations(e)}}getAsYamlString(e,t=!1){return a.SimpleYamlSerializer.serialize(this.getYamlAsJsonNode(e,t))}getDataTree(e,t){const r=n.JsonNode.getEmpty();return this.serializeDataLevelInto(e.dataContainer,r,t,!0),r}serializeDataLevelInto(e,t,r,a=!1){const i=n.JsonNode.getEmpty(),o=this.getUnpackedAttributeValueGroups(e),l=new Set(Array.from(o.values()).flat());Object.keys(e.values).forEach(t=>{if(o.has(t)||l.has(t))return;const a=e.values[t];if(Array.isArray(a)){const e=n.JsonNode.getEmptyList();a.forEach((t,a)=>{const i=this.serializeCommonType(t,r);if(null!==i&&n.JsonNode.hasEntries(i))e.push(i);else if(t instanceof s.InstanceDataContainer){const r={[m.YamlKeys.type]:"element-instance"};this.hasId(t.id)&&(r[m.YamlKeys.id]=t.id),e.push(r)}}),e.length>0&&(i[t]=e)}else{const e=this.serializeCommonType(a,r);null!==e&&n.JsonNode.hasEntries(e)&&(i[t]=e)}}),n.JsonNode.hasEntries(i)&&(!this.hasId(e.id)||r&&a||(t[m.YamlKeys.id]=e.id),t[m.YamlKeys.children]=i),this.serializeAttributeValueFields(e,t,o)}serializeAttributeValueFields(e,t,r){Object.keys(e.values).forEach(r=>{const a=e.values[r];if(a instanceof o.InstanceDataAttributeValueField){const e=n.JsonNode.getEmpty();let i=!1;Object.keys(a.values).forEach(t=>{const r=a.values[t];if(r instanceof l.InstanceDataStringAtom){const n=this.serializeAtomString(r);null!==n&&(e[t]=n,i=!0)}}),i&&(t[r]=e)}});for(const[a,i]of r){const r=n.JsonNode.getEmpty();for(const t of i){const n=e.values[t];if(n instanceof l.InstanceDataStringAtom){const e=this.serializeAtomString(n);null!==e&&(r[t]=e)}}n.JsonNode.hasEntries(r)&&(t[a]=r)}}getUnpackedAttributeValueGroups(e){const t=new Map;for(const[r,n]of Object.entries(e.values)){if(!Array.isArray(n))continue;const e=n.filter(e=>e instanceof h.InstanceDataAttributeValueFieldName).map(e=>e.name).filter(e=>e.trim().length>0);e.length>0&&t.set(r,e)}return t}serializeCommonType(e,t){if(e instanceof l.InstanceDataStringAtom)return this.serializeAtomString(e);if(e instanceof d.InstanceDataTypedAtom)return null===e.value?null:{[m.YamlKeys.datatype]:e.type,[m.YamlKeys.value]:e.value};if(e instanceof u.InstanceDataControlledAtom){const t=n.JsonNode.getEmpty();return this.hasId(e.id)&&(t[m.YamlKeys.id]=e.id),null!==e.label&&(t[m.YamlKeys.label]=e.label),n.JsonNode.hasEntries(t)?t:null}if(e instanceof c.InstanceDataLinkAtom)return this.serializeAtomLink(e);if(e instanceof s.InstanceDataContainer){const r=n.JsonNode.getEmpty();return this.serializeDataLevelInto(e,r,t),r}return null}serializeAtomString(e){return null===e.value?null:{[m.YamlKeys.value]:e.value}}serializeAtomLink(e){return this.hasId(e.id)?{[m.YamlKeys.id]:e.id}:null}hasId(e){return null!==e&&""!==e}}t.YamlTemplateInstanceWriter=f},1933(e,t,r){t.YamlTemplateWriter=void 0;const n=r(9517),a=r(6574),i=r(2099),s=r(5386);class o extends s.YamlAbstractContainerArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new o(e,t)}getYamlAsJsonNode(e,t=!1){const r=n.JsonNode.getEmpty();null!==e.header&&(r[i.YamlKeys.header]=e.header),null!==e.footer&&(r[i.YamlKeys.footer]=e.footer);const a={...this.macroType(e),...this.macroNameAndDescription(e),...this.macroSchemaIdentifier(e),...this.macroId(e,t,!0),...this.macroStatusAndVersion(e,t),...this.macroInstanceType(e),...r,...this.macroPreviousVersion(e,t),...this.macroDerivedFrom(e,t),...this.macroProvenance(e,t),...this.macroAnnotations(e)},s=this.getChildListAsJSON(e,t);return s.length>0&&(a[i.YamlKeys.children]=s),a}getAsYamlString(e,t=!1){return a.SimpleYamlSerializer.serialize(this.getYamlAsJsonNode(e,t))}}t.YamlTemplateWriter=o},1641(e,t,r){t.AbstractArtifactBuilder=void 0;const n=r(9857),a=r(2234),i=r(1027),s=r(3910),o=r(8534),l=r(8557);t.AbstractArtifactBuilder=class{at_id=o.CedarArtifactId.NULL;title=null;description=null;schema_schemaVersion=l.SchemaVersion.CURRENT;pav_createdOn=n.IsoDate.NULL;pav_createdBy=a.CedarUser.NULL;pav_lastUpdatedOn=n.IsoDate.NULL;oslc_modifiedBy=a.CedarUser.NULL;pav_version=i.PavVersion.DEFAULT;bibo_status=s.BiboStatus.DRAFT;schema_name=null;schema_description=null;schema_identifier=null;pav_derivedFrom=o.CedarArtifactId.NULL;withAtId(e){return e instanceof o.CedarArtifactId?this.at_id=e:this.at_id=o.CedarArtifactId.forValue(e),this}withTitle(e){return this.title=e,this}withDescription(e){return this.description=e,this}withSchemaVersion(e){return this.schema_schemaVersion=e,this}withCreatedOn(e){return e instanceof n.IsoDate?this.pav_createdOn=e:this.pav_createdOn=n.IsoDate.forValue(e),this}withCreatedBy(e){return e instanceof a.CedarUser?this.pav_createdBy=e:this.pav_createdBy=a.CedarUser.forValue(e),this}withLastUpdatedOn(e){return e instanceof n.IsoDate?this.pav_lastUpdatedOn=e:this.pav_lastUpdatedOn=n.IsoDate.forValue(e),this}withModifiedBy(e){return e instanceof a.CedarUser?this.oslc_modifiedBy=e:this.oslc_modifiedBy=a.CedarUser.forValue(e),this}withVersion(e){return e instanceof i.PavVersion?this.pav_version=e:this.pav_version=i.PavVersion.forValue(e),this}withStatus(e){return e instanceof s.BiboStatus?this.bibo_status=e:this.bibo_status=s.BiboStatus.forJsonValue(e),this}withSchemaName(e){return this.schema_name=e,this}withSchemaDescription(e){return this.schema_description=e,this}withDerivedFrom(e){return this.pav_derivedFrom=e,this}withSchemaIdentifier(e){return this.schema_identifier=e,this}buildInternal(e){e.at_id=this.at_id,e.title=this.title,e.description=this.description,e.schema_schemaVersion=this.schema_schemaVersion,e.pav_createdOn=this.pav_createdOn,e.pav_createdBy=this.pav_createdBy,e.pav_lastUpdatedOn=this.pav_lastUpdatedOn,e.oslc_modifiedBy=this.oslc_modifiedBy,e.pav_version=this.pav_version,e.bibo_status=this.bibo_status,e.schema_name=this.schema_name,e.schema_description=this.schema_description,e.schema_identifier=this.schema_identifier,e.pav_derivedFrom=this.pav_derivedFrom}}},2674(e,t,r){t.AbstractArtifact=void 0;const n=r(9857),a=r(2234),i=r(8534),s=r(2763);t.AbstractArtifact=class{at_id=i.CedarArtifactId.NULL;pav_createdOn=n.IsoDate.NULL;pav_createdBy=a.CedarUser.NULL;pav_lastUpdatedOn=n.IsoDate.NULL;oslc_modifiedBy=a.CedarUser.NULL;pav_derivedFrom=i.CedarArtifactId.NULL;schema_name=null;schema_description=null;cedarArtifactType=s.CedarArtifactType.NULL;annotations=null}},5451(e,t,r){t.AbstractContainerArtifact=void 0;const n=r(8333),a=r(1492),i=r(3746),s=r(2763);class o extends n.AbstractSchemaArtifact{childrenInfo=new a.ContainerArtifactChildrenInfo;childMap=new Map;instanceTypeSpecification=null;addChild(e,t){this.childrenInfo.add(t),this.childMap.set(t.name,e)}getChildrenInfo(){return this.childrenInfo}getAdditionalProperties(){return this.childrenInfo.hasAttributeValue()?i.AdditionalProperties.ALLOW_ATTRIBUTE_VALUE:i.AdditionalProperties.FALSE}getChild(e){return this.childMap.get(e)??null}getElement(e){const t=this.getChild(e);return null!==t&&t.cedarArtifactType===s.CedarArtifactType.TEMPLATE_ELEMENT?t:null}getField(e){const t=this.getChild(e);return null!==t&&t.cedarArtifactType===s.CedarArtifactType.TEMPLATE_FIELD?t:null}getChildInfo(e){return this.childrenInfo.get(e)}}t.AbstractContainerArtifact=o},5697(e,t,r){t.AbstractInstanceArtifact=void 0;const n=r(8534),a=r(2674);class i extends a.AbstractArtifact{schema_isBasedOn=n.CedarArtifactId.NULL}t.AbstractInstanceArtifact=i},8333(e,t,r){t.AbstractSchemaArtifact=void 0;const n=r(1027),a=r(3910),i=r(8534),s=r(8557),o=r(2674),l=r(7752);class c extends o.AbstractArtifact{title=null;description=null;schema_schemaVersion=s.SchemaVersion.NULL;pav_version=n.PavVersion.NULL;bibo_status=a.BiboStatus.NULL;schema_identifier=null;pav_previousVersion=i.CedarArtifactId.NULL;language=l.Language.NULL}t.AbstractSchemaArtifact=c},2787(e,t){t.AnnotationAtId=void 0,t.AnnotationAtId=class{name;id;constructor(e,t){this.name=e,this.id=t}getName(){return this.name}getAtId(){return this.id}}},3549(e,t){t.AnnotationAtValue=void 0,t.AnnotationAtValue=class{name;value;constructor(e,t){this.name=e,this.value=t}getName(){return this.name}getAtValue(){return this.value}}},5226(e,t){t.Annotations=void 0,t.Annotations=class{annotations=new Map;add(e){this.annotations.set(e.getName(),e)}getSize(){return this.annotations.size}getAnnotationNames(){return Array.from(this.annotations.keys())}get(e){return this.annotations.has(e)?this.annotations.get(e):null}}},936(e,t){t.CedarModel=void 0,t.CedarModel=class{static ui="_ui";static schema="$schema";static order="order";static inputType="inputType";static type="type";static items="items";static valueConstraints="_valueConstraints";static requiredValue="requiredValue";static defaultValue="defaultValue";static minItems="minItems";static maxItems="maxItems";static minLength="minLength";static maxLength="maxLength";static numberType="numberType";static temporalType="temporalType";static temporalGranularity="temporalGranularity";static timezoneEnabled="timezoneEnabled";static inputTimeFormat="inputTimeFormat";static unitOfMeasure="unitOfMeasure";static minValue="minValue";static maxValue="maxValue";static decimalPlace="decimalPlace";static content="_content";static size="_size";static width="width";static height="height";static regex="regex";static pages="pages";static header="header";static footer="footer";static ontologies="ontologies";static valueSets="valueSets";static classes="classes";static branches="branches";static actions="actions";static multipleChoice="multipleChoice";static literals="literals";static label="label";static selectedByDefault="selectedByDefault";static propertyDescriptions="propertyDescriptions";static propertyLabels="propertyLabels";static skosPrefLabel="skos:prefLabel";static skosAltLabel="skos:altLabel";static skosNotation="skos:notation";static format="format";static enum="enum";static annotations="_annotations";static propertyIriPrefix="https://schema.metadatacenter.org/properties/";static ValueConstraints=class{static acronym="acronym";static name="name";static uri="uri";static numTerms="numTerms";static label="label";static source="source";static type="type";static termType="termType";static prefLabel="prefLabel";static maxDepth="maxDepth";static vsCollection="vsCollection";static termUri="termUri";static sourceUri="sourceUri";static iri="iri";static sourceSystem="sourceSystem";static version="version";static versionId="id";static versionEffectiveDate="effectiveDate";static versionDeclaredVersion="declaredVersion";static action="action";static to="to";static recommendedValue="recommendedValue"};static Ui=class{static hidden="hidden";static continuePreviousLine="continuePreviousLine";static valueRecommendationEnabled="valueRecommendationEnabled"};static nullEnabled="nullEnabled";static trueLabel="true";static falseLabel="false";static nullLabel="null";static labels="labels"}},2733(e,t){t.JsonSchema=void 0,t.JsonSchema=class{static properties="properties";static required="required";static atContext="@context";static atId="@id";static atType="@type";static atValue="@value";static atLanguage="@language";static schemaIsBasedOn="schema:isBasedOn";static schemaName="schema:name";static schemaDescription="schema:description";static schemaVersion="schema:schemaVersion";static schemaIdentifier="schema:identifier";static pavDerivedFrom="pav:derivedFrom";static pavPreviousVersion="pav:previousVersion";static pavCreatedOn="pav:createdOn";static pavCreatedBy="pav:createdBy";static pavLastUpdatedOn="pav:lastUpdatedOn";static oslcModifiedBy="oslc:modifiedBy";static pavVersion="pav:version";static biboStatus="bibo:status";static rdfsLabel="rdfs:label";static termUri="termUri";static enum="enum";static oneOf="oneOf";static type="type";static items="items"}},4216(e,t){t.NonStandardDatatype=void 0,t.NonStandardDatatype=class{static IRI="iri"}},5747(e,t){t.TemplateProperty=void 0,t.TemplateProperty=class{static title="title";static description="description";static additionalProperties="additionalProperties"}},2099(e,t){t.YamlKeys=void 0,t.YamlKeys=class{static id="id";static type="type";static name="name";static description="description";static modelVersion="modelVersion";static status="status";static version="version";static language="language";static label="label";static prefLabel="prefLabel";static altLabels="altLabels";static datatype="datatype";static valueRecommendation="valueRecommendation";static required="required";static recommended="recommended";static hidden="hidden";static continuePreviousLine="continuePreviousLine";static propertyIri="propertyIri";static overrideLabel="overrideLabel";static overrideDescription="overrideDescription";static default="default";static minLength="minLength";static maxLength="maxLength";static regex="regex";static identifier="identifier";static derivedFrom="derivedFrom";static previousVersion="previousVersion";static createdOn="createdOn";static createdBy="createdBy";static modifiedOn="modifiedOn";static modifiedBy="modifiedBy";static isBasedOn="isBasedOn";static instanceType="instanceType";static annotations="annotations";static value="value";static granularity="granularity";static inputTimeZone="inputTimeZone";static inputTimeFormat="inputTimeFormat";static header="header";static footer="footer";static children="children";static multiple="multiple";static minItems="minItems";static maxItems="maxItems";static content="content";static height="height";static width="width";static key="key";static minValue="minValue";static maxValue="maxValue";static decimalPlaces="decimalPlaces";static unit="unit";static multipleChoice="multipleChoice";static values="values";static selected="selected";static actions="actions";static action="action";static configuration="configuration";static Controlled=class{static sourceSystem="sourceSystem";static sourceAcronym="sourceAcronym";static sourceName="sourceName";static sourceIri="sourceIri";static termIri="termIri";static termType="termType";static termLabel="termLabel";static termDisplayLabel="termDisplayLabel";static termBaseIri="termBaseIri";static termBaseLabel="termBaseLabel";static termMaxDepth="termMaxDepth";static termCount="termCount";static versionId="id";static versionEffectiveDate="effectiveDate";static versionDeclaredVersion="declaredVersion";static to="to"};static nullEnabled="nullEnabled";static labels="labels";static trueLabel="true";static falseLabel="false";static nullLabel="null"}},8349(e,t){t.YamlValues=void 0,t.YamlValues=class{static id="id";static value="value";static iri="iri";static string="string";static Controlled=class{static class="class";static ontology="ontology";static valueSet="valueSet";static branch="branch"}}},513(e,t,r){t.AbstractChildDeploymentInfo=void 0;const n=r(2763),a=r(9034);t.AbstractChildDeploymentInfo=class{_name;_atType=n.CedarArtifactType.NULL;_uiInputType=a.UiInputType.NULL;_label=null;_description=null;_hidden=!1;constructor(e){this._name=e}get name(){return this._name}hasParent(){return""!==this._name}get atType(){return this._atType}set atType(e){this._atType=e}get uiInputType(){return this._uiInputType}set uiInputType(e){this._uiInputType=e}get label(){return this._label}set label(e){this._label=e}get description(){return this._description}set description(e){this._description=e}get hidden(){return this._hidden}set hidden(e){this._hidden=e}}},6910(e,t,r){t.AbstractChildDeploymentInfoBuilder=void 0;const n=r(2763),a=r(9034),i=r(9129);t.AbstractChildDeploymentInfoBuilder=class{child=null;name="";atType=n.CedarArtifactType.NULL;uiInputType=a.UiInputType.NULL;label=null;description=null;hidden=!1;constructor(e,t){this.child=e,this.name=t}withLabel(e){return this.label=e,this}withDescription(e){return this.description=e,this}withHidden(e){return this.hidden=e,this}setCommonData(e){e.label=this.label,e.description=this.description,e.hidden=this.hidden,e.atType=this.atType,e.uiInputType=this.uiInputType,null!=this.child&&(e.atType=this.child.cedarArtifactType,this.child instanceof i.TemplateField&&(e.uiInputType=this.child.cedarFieldType.getUiInputType()))}}},3812(e,t,r){t.AbstractDynamicChildDeploymentInfo=void 0;const n=r(513);class a extends n.AbstractChildDeploymentInfo{_iri=null;_requiredValue=!1;_recommendedValue=!1;_continuePreviousLine=!1;_valueRecommendationEnabled=!1;constructor(e){super(e)}get iri(){return this._iri}set iri(e){this._iri=e}get requiredValue(){return this._requiredValue}set requiredValue(e){this._requiredValue=e}get recommendedValue(){return this._recommendedValue}set recommendedValue(e){this._recommendedValue=e}get continuePreviousLine(){return this._continuePreviousLine}set continuePreviousLine(e){this._continuePreviousLine=e}get valueRecommendationEnabled(){return this._valueRecommendationEnabled}set valueRecommendationEnabled(e){this._valueRecommendationEnabled=e}get minItems(){return null}get maxItems(){return null}}t.AbstractDynamicChildDeploymentInfo=a},4809(e,t,r){t.AbstractDynamicChildDeploymentInfoBuilder=void 0;const n=r(455),a=r(6910);class i extends a.AbstractChildDeploymentInfoBuilder{iri=null;requiredValue=!1;recommendedValue=!1;continuePreviousLine=!1;valueRecommendationEnabled=!1;constructor(e,t){super(e,t)}withIri(e){return this.iri=e,this}withRequiredValue(e){return this.requiredValue=e,this}withRecommendedValue(e){return this.recommendedValue=e,this}withContinuePreviousLine(e){return this.continuePreviousLine=e,this}withValueRecommendationEnabled(e){return this.valueRecommendationEnabled=e,this}build(){const e=new n.ChildDeploymentInfo(this.name);return this.setCommonData(e),e}setCommonData(e){super.setCommonData(e),e.iri=this.iri,e.requiredValue=this.requiredValue,e.recommendedValue=this.recommendedValue,e.continuePreviousLine=this.continuePreviousLine,e.valueRecommendationEnabled=this.valueRecommendationEnabled}}t.AbstractDynamicChildDeploymentInfoBuilder=i},455(e,t,r){t.ChildDeploymentInfo=void 0;const n=r(3812);class a extends n.AbstractDynamicChildDeploymentInfo{_multiInstance=!1;_minItems=null;_maxItems=null;_standalone=!1;static empty(){return new a("")}static standalone(){const e=new a("");return e._standalone=!0,e}constructor(e){super(e)}get multiInstance(){return this._multiInstance}set multiInstance(e){this._multiInstance=e}get minItems(){return this._minItems}set minItems(e){this._minItems=e}get maxItems(){return this._maxItems}set maxItems(e){this._maxItems=e}isMultiInAnyWay(){return this._multiInstance}isStandalone(){return this._standalone}}t.ChildDeploymentInfo=a},8878(e,t,r){t.ChildDeploymentInfoAlwaysMultiple=void 0;const n=r(9034),a=r(3812);class i extends a.AbstractDynamicChildDeploymentInfo{_declaredMinItems=null;_declaredMaxItems=null;static empty(){return new i("")}constructor(e){super(e)}isMultiInAnyWay(){return!0}set declaredMinItems(e){this._declaredMinItems=e}set declaredMaxItems(e){this._declaredMaxItems=e}get minItems(){return null!==this._declaredMinItems?this._declaredMinItems:this.uiInputType===n.UiInputType.ATTRIBUTE_VALUE?0:this.requiredValue?1:0}get maxItems(){return this._declaredMaxItems}}t.ChildDeploymentInfoAlwaysMultiple=i},3239(e,t,r){t.ChildDeploymentInfoAlwaysMultipleBuilder=void 0;const n=r(8878),a=r(4809);class i extends a.AbstractDynamicChildDeploymentInfoBuilder{declaredMinItems=null;declaredMaxItems=null;constructor(e,t){super(e,t)}withMinItems(e){return this.declaredMinItems=e,this}withMaxItems(e){return this.declaredMaxItems=e,this}build(){const e=new n.ChildDeploymentInfoAlwaysMultiple(this.name);return this.setCommonData(e),e.declaredMinItems=this.declaredMinItems,e.declaredMaxItems=this.declaredMaxItems,e}}t.ChildDeploymentInfoAlwaysMultipleBuilder=i},2266(e,t,r){t.ChildDeploymentInfoAlwaysSingle=void 0;const n=r(3812);class a extends n.AbstractDynamicChildDeploymentInfo{static empty(){return new a("")}constructor(e){super(e)}isMultiInAnyWay(){return!1}}t.ChildDeploymentInfoAlwaysSingle=a},587(e,t,r){t.ChildDeploymentInfoAlwaysSingleBuilder=void 0;const n=r(2266),a=r(4809);class i extends a.AbstractDynamicChildDeploymentInfoBuilder{constructor(e,t){super(e,t)}build(){const e=new n.ChildDeploymentInfoAlwaysSingle(this.name);return this.setCommonData(e),e}}t.ChildDeploymentInfoAlwaysSingleBuilder=i},3608(e,t,r){t.ChildDeploymentInfoBuilder=void 0;const n=r(455),a=r(4809);class i extends a.AbstractDynamicChildDeploymentInfoBuilder{multiInstance=!1;minItems=null;maxItems=null;constructor(e,t){super(e,t)}withMultiInstance(e){return this.multiInstance=e,this}withMinItems(e){return this.minItems=e,this}withMaxItems(e){return this.maxItems=e,this}build(){const e=new n.ChildDeploymentInfo(this.name);return this.setCommonData(e),e.multiInstance=this.multiInstance,e.minItems=this.minItems,e.maxItems=this.maxItems,e}}t.ChildDeploymentInfoBuilder=i},3581(e,t,r){t.ChildDeploymentInfoStatic=void 0;const n=r(513);class a extends n.AbstractChildDeploymentInfo{static empty(){return new a("")}constructor(e){super(e)}isMultiInAnyWay(){return!1}}t.ChildDeploymentInfoStatic=a},8290(e,t,r){t.ChildDeploymentInfoStaticBuilder=void 0;const n=r(6910),a=r(3581);class i extends n.AbstractChildDeploymentInfoBuilder{constructor(e,t){super(e,t)}build(){const e=new a.ChildDeploymentInfoStatic(this.name);return super.setCommonData(e),e}}t.ChildDeploymentInfoStaticBuilder=i},1492(e,t,r){t.ContainerArtifactChildrenInfo=void 0;const n=r(2763),a=r(2733),i=r(9034),s=r(3812);t.ContainerArtifactChildrenInfo=class{childNameList=[];childMap=new Map;add(e){this.childNameList.push(e.name),this.childMap.set(e.name,e)}get children(){return this.childNameList.map(e=>this.childMap.get(e))}has(e){return this.childMap.has(e)}get(e){return this.childMap.get(e)??null}getChildrenNames(){return Array.from(this.childMap.keys())}getChildrenNamesForRequiredInProperties(){const e=[];for(const[t,r]of this.childMap.entries())r.atType!==n.CedarArtifactType.STATIC_TEMPLATE_FIELD&&r.uiInputType!==i.UiInputType.ATTRIBUTE_VALUE&&e.push(t);return e}getChildrenNamesForRequired(){const e=[];for(const[t,r]of this.childMap.entries())r.atType!==n.CedarArtifactType.STATIC_TEMPLATE_FIELD&&r.uiInputType!==i.UiInputType.ATTRIBUTE_VALUE&&e.push(t);return e}getOnlyElementNamesForPropertiesContextRequired(){const e=[];for(const[t,r]of this.childMap.entries())r.atType===n.CedarArtifactType.TEMPLATE_ELEMENT&&e.push(t);return e}getPropertyLabelMap(e){const t={};return this.childNameList.forEach(e=>{const r=this.getChildInfo(e);null!==r.label&&(t[r.name]=r.label)}),t}getPropertyDescriptionMap(e){const t={};return this.childNameList.forEach(e=>{const r=this.getChildInfo(e);null!==r.description&&(t[r.name]=r.description)}),t}getChildIriMap(){const e={};return this.childNameList.forEach(t=>{const r=this.getChildInfo(t);r.atType!==n.CedarArtifactType.STATIC_TEMPLATE_FIELD&&r.uiInputType!==i.UiInputType.ATTRIBUTE_VALUE&&r instanceof s.AbstractDynamicChildDeploymentInfo&&null!==r.iri&&(e[r.name]=r.iri)}),e}getIRIMap(){const e={},t=this.getChildIriMap();return Object.keys(t).forEach(r=>{e[r]={[a.JsonSchema.enum]:[t[r]]}}),e}hasAttributeValue(){for(const e of this.childMap.values())if(e.uiInputType===i.UiInputType.ATTRIBUTE_VALUE)return!0;return!1}getChildInfo(e){return this.childMap.get(e)}}},7661(e,t,r){t.TemplateElement=void 0;const n=r(3910),a=r(8557),i=r(1027),s=r(5451),o=r(2763),l=r(3608);class c extends s.AbstractContainerArtifact{skos_altLabel=null;skos_prefLabel=null;constructor(){super(),this.cedarArtifactType=o.CedarArtifactType.TEMPLATE_ELEMENT}static buildEmptyWithNullValues(){return new c}static buildEmptyWithDefaultValues(){const e=new c;return e.schema_schemaVersion=a.SchemaVersion.CURRENT,e.bibo_status=n.BiboStatus.DRAFT,e.pav_version=i.PavVersion.DEFAULT,e}isMultiInstanceByDefinition(){return!1}isSingleInstanceByDefinition(){return!1}createDeploymentBuilder(e){return new l.ChildDeploymentInfoBuilder(this,e)}}t.TemplateElement=c},1762(e,t,r){t.TemplateElementBuilder=void 0;const n=r(1641),a=r(7661);class i extends n.AbstractArtifactBuilder{children=[];instanceTypeSpecification=null;withInstanceTypeSpecification(e){return this.instanceTypeSpecification=e,this}addChild(e,t){return this.children.push([e,t]),this}build(){const e=a.TemplateElement.buildEmptyWithNullValues();return super.buildInternal(e),e.instanceTypeSpecification=this.instanceTypeSpecification,this.children.forEach(([t,r])=>{e.addChild(t,r)}),e}}t.TemplateElementBuilder=i},7282(e,t){t.ChoiceOptionEntity=void 0,t.ChoiceOptionEntity=class{label;selectedByDefault;constructor(e,t){this.label=e,this.selectedByDefault=t}}},3557(e,t,r){t.JsonValueConstraintsWriter=void 0;const n=r(3161);class a extends n.JsonAbstractArtifactWriter{}t.JsonValueConstraintsWriter=a},9129(e,t,r){t.TemplateField=void 0;const n=r(4328),a=r(4869),i=r(8333);class s extends i.AbstractSchemaArtifact{skos_altLabel=null;skos_prefLabel=null;valueConstraints=new n.ValueConstraints;cedarFieldType=a.CedarFieldType.NULL;isMultiInstanceByDefinition(){return!1}isSingleInstanceByDefinition(){return!1}supportsValueRecommendation(){return!1}}t.TemplateField=s},3350(e,t,r){t.TemplateFieldBuilder=void 0;const n=r(1641);class a extends n.AbstractArtifactBuilder{skos_altLabel=null;skos_prefLabel=null;withAlternateLabels(e){return this.skos_altLabel=e,this}addAlternateLabel(e){return null===this.skos_altLabel&&(this.skos_altLabel=[]),this.skos_altLabel.push(e),this}withPreferredLabel(e){return this.skos_prefLabel=e,this}buildInternal(e){super.buildInternal(e),e.skos_altLabel=this.skos_altLabel,e.skos_prefLabel=this.skos_prefLabel}}t.TemplateFieldBuilder=a},855(e,t,r){t.UnknownTemplateField=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(3608);class o extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.NULL,this.cedarArtifactType=i.CedarArtifactType.NULL}static build(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoBuilder(this,e)}}t.UnknownTemplateField=o},4328(e,t){t.ValueConstraints=void 0,t.ValueConstraints=class{constructor(){}}},2500(e,t,r){t.YamlValueConstraintsWriter=void 0;const n=r(211);class a extends n.YamlAbstractArtifactWriter{}t.YamlValueConstraintsWriter=a},2052(e,t,r){t.AttributeValueFieldBuilderImpl=void 0;const n=r(3350),a=r(9571);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.AttributeValueFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.AttributeValueFieldBuilderImpl=i},9571(e,t,r){t.AttributeValueFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3239);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.ATTRIBUTE_VALUE,this.valueConstraints=new s.ValueConstraints,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}isMultiInstanceByDefinition(){return!0}createDeploymentBuilder(e){return new o.ChildDeploymentInfoAlwaysMultipleBuilder(this,e)}}t.AttributeValueFieldImpl=l},9366(e,t,r){t.JsonFieldReaderAttributeValue=void 0;const n=r(4385),a=r(9571);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.AttributeValueFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderAttributeValue=i},1442(e,t,r){t.JsonFieldWriterAttributeValue=void 0;const n=r(2748),a=r(9517),i=r(936),s=r(5793);class o extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){}expandRequiredNode(e){}expandTypeNode(e,t){e[i.CedarModel.type]=this.atomicWriter.write(s.JavascriptType.STRING)}buildValueConstraintsObject(e){return a.JsonNode.getEmpty()}}t.JsonFieldWriterAttributeValue=o},529(e,t,r){t.YamlFieldReaderAttributeValue=void 0;const n=r(5675),a=r(9571);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.AttributeValueFieldImpl.buildEmpty()}}t.YamlFieldReaderAttributeValue=i},1521(e,t,r){t.YamlFieldWriterAttributeValue=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterAttributeValue=a},4675(e,t,r){t.CheckboxFieldBuilderImpl=void 0;const n=r(3350),a=r(9915),i=r(9282);class s extends n.TemplateFieldBuilder{literals=[];constructor(){super()}static create(){return new s}addCheckboxOption(e,t=!1){return this.literals.push(new a.CheckboxOption(e,t)),this}build(){const e=i.CheckboxFieldImpl.buildEmpty();return super.buildInternal(e),e.valueConstraints.literals=this.literals,e}}t.CheckboxFieldBuilderImpl=s},9282(e,t,r){t.CheckboxFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(1489),o=r(3239);class l extends n.TemplateField{valueConstraints;constructor(){super(),this.cedarFieldType=a.CedarFieldType.CHECKBOX,this.valueConstraints=new s.ValueConstraintsCheckboxField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}isMultiInstanceByDefinition(){return!0}createDeploymentBuilder(e){return new o.ChildDeploymentInfoAlwaysMultipleBuilder(this,e)}}t.CheckboxFieldImpl=l},9915(e,t,r){t.CheckboxOption=void 0;const n=r(7282);class a extends n.ChoiceOptionEntity{constructor(e,t){super(e,t)}}t.CheckboxOption=a},19(e,t,r){t.JsonFieldReaderCheckbox=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(9915),o=r(9282);class l extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const l=o.CheckboxFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const c=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=c){const e=n.ReaderUtil.getNodeList(c,a.CedarModel.literals);null!==e&&e.forEach(e=>{const t=n.ReaderUtil.getString(e,a.CedarModel.label),r=n.ReaderUtil.getBoolean(e,a.CedarModel.selectedByDefault);if(null!=t){const e=new s.CheckboxOption(t,r);l.valueConstraints.literals.push(e)}})}return l}}t.JsonFieldReaderCheckbox=l},8663(e,t,r){t.JsonFieldWriterCheckbox=void 0;const n=r(936),a=r(2748);class i extends a.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){this.expandLiterals(t,e),super.expandValueConstraintsNode(e,t,r),e[n.CedarModel.multipleChoice]=!0}}t.JsonFieldWriterCheckbox=i},1489(e,t,r){t.ValueConstraintsCheckboxField=void 0;const n=r(4328);class a extends n.ValueConstraints{literals=[];constructor(){super()}}t.ValueConstraintsCheckboxField=a},7268(e,t,r){t.YamlFieldReaderCheckbox=void 0;const n=r(8748),a=r(9915),i=r(5675),s=r(2099),o=r(9282);class l extends i.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const l=o.CheckboxFieldImpl.buildEmpty(),c=n.ReaderUtil.getNodeList(e,s.YamlKeys.values);return null!==c&&c.forEach(e=>{const t=n.ReaderUtil.getString(e,s.YamlKeys.label),r=n.ReaderUtil.getBoolean(e,s.YamlKeys.selected);if(null!=t){const e=new a.CheckboxOption(t,r);l.valueConstraints.literals.push(e)}}),l}}t.YamlFieldReaderCheckbox=l},4500(e,t,r){t.YamlFieldWriterCheckbox=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){this.expandLiterals(t,e)}}t.YamlFieldWriterCheckbox=a},9916(e,t,r){t.ControlledTermFieldBuilderImpl=void 0;const n=r(5376),a=r(3350),i=r(6731);class s extends a.TemplateFieldBuilder{valueConstraints=new n.ValueConstraintsControlledTermField;constructor(){super()}static create(){return new s}withDefaultValue(e){return this.valueConstraints.defaultValue=e,this}addOntology(e){return this.valueConstraints.ontologies.push(e),this}addValueSet(e){return this.valueConstraints.valueSets.push(e),this}addClass(e){return this.valueConstraints.classes.push(e),this}addBranch(e){return this.valueConstraints.branches.push(e),this}addAction(e){return this.valueConstraints.actions.push(e),this}build(){const e=i.ControlledTermFieldImpl.buildEmpty();return super.buildInternal(e),e.valueConstraints=this.valueConstraints,e}}t.ControlledTermFieldBuilderImpl=s},6731(e,t,r){t.ControlledTermFieldImpl=void 0;const n=r(9129),a=r(5376),i=r(4869),s=r(2763),o=r(3608);class l extends n.TemplateField{valueConstraints;valueRecommendationEnabled=!1;constructor(){super(),this.cedarFieldType=i.CedarFieldType.CONTROLLED_TERM,this.valueConstraints=new a.ValueConstraintsControlledTermField,this.cedarArtifactType=s.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}supportsValueRecommendation(){return!0}}t.ControlledTermFieldImpl=l},8728(e,t,r){t.JsonFieldReaderControlledTerm=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(8354),o=r(2418),l=r(9184),c=r(2395),d=r(7295),u=r(2733),m=r(7432),p=r(4531),h=r(6731),f=r(5753);class T extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const s=h.ControlledTermFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const o=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);return null!=o&&(s.valueConstraints.ontologies=this.getOntologies(n.ReaderUtil.getNodeList(o,a.CedarModel.ontologies)),s.valueConstraints.classes=this.getClasses(n.ReaderUtil.getNodeList(o,a.CedarModel.classes)),s.valueConstraints.branches=this.getBranches(n.ReaderUtil.getNodeList(o,a.CedarModel.branches)),s.valueConstraints.valueSets=this.getValueSets(n.ReaderUtil.getNodeList(o,a.CedarModel.valueSets)),s.valueConstraints.defaultValue=this.getDefaultValue(n.ReaderUtil.getNodeOrNull(o,a.CedarModel.defaultValue)),s.valueConstraints.actions=this.getActions(n.ReaderUtil.getNodeList(o,a.CedarModel.actions))),s}getOntologies(e){const t=[];return e.forEach(e=>{const r=new s.ControlledTermOntology(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.acronym),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.name),n.ReaderUtil.getNumberOrNull(e,a.CedarModel.ValueConstraints.numTerms),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.uri),...T.readSourceAndVersion(e));t.push(r)}),t}getClasses(e){const t=[];return e.forEach(e=>{const r=new o.ControlledTermClass(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.label),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.source),p.BioportalTermType.forJsonValue(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.type)),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.prefLabel),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.uri),...T.readSourceAndVersion(e));t.push(r)}),t}getBranches(e){const t=[];return e.forEach(e=>{const r=new l.ControlledTermBranch(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.source),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.acronym),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.name),n.ReaderUtil.getNumberOrZero(e,a.CedarModel.ValueConstraints.maxDepth),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.uri),...T.readSourceAndVersion(e));t.push(r)}),t}getValueSets(e){const t=[];return e.forEach(e=>{const r=new c.ControlledTermValueSet(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.vsCollection),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.name),n.ReaderUtil.getNumberOrNull(e,a.CedarModel.ValueConstraints.numTerms),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.uri),...T.readSourceAndVersion(e));t.push(r)}),t}getActions(e){const t=[];return e.forEach(e=>{const r=new m.ControlledTermAction(n.ReaderUtil.getNumber(e,a.CedarModel.ValueConstraints.to),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.action),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.termUri),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.sourceUri),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.source),p.BioportalTermType.forJsonValue(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.type)));t.push(r)}),t}static readSourceAndVersion(e){const t=n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.iri),r=n.ReaderUtil.getNodeOrNull(e,a.CedarModel.ValueConstraints.version),i=null===r?null:new f.ControlledTermVersion(n.ReaderUtil.getStringOrEmpty(r,a.CedarModel.ValueConstraints.versionId),n.ReaderUtil.getString(r,a.CedarModel.ValueConstraints.versionEffectiveDate),n.ReaderUtil.getString(r,a.CedarModel.ValueConstraints.versionDeclaredVersion));return[t.isEmpty()?null:t,n.ReaderUtil.getString(e,a.CedarModel.ValueConstraints.sourceSystem),i]}getDefaultValue(e){if(null==e)return null;const t=n.ReaderUtil.getURI(e,u.JsonSchema.termUri),r=n.ReaderUtil.getString(e,u.JsonSchema.rdfsLabel);return t.isEmpty()&&null===r?null:new d.ControlledTermDefaultValue(t,r??"")}}t.JsonFieldReaderControlledTerm=T},8280(e,t,r){t.JsonFieldWriterControlledTerm=void 0;const n=r(9517),a=r(936),i=r(2748),s=r(2733),o=r(9932);class l extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[s.JsonSchema.properties]=o.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[s.JsonSchema.properties]=o.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}expandValueConstraintsNode(e,t,r){const i=n.JsonNode.getEmptyList();t.valueConstraints.ontologies.forEach(e=>{i.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),e[a.CedarModel.ontologies]=i;const o=n.JsonNode.getEmptyList();t.valueConstraints.valueSets.forEach(e=>{o.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),e[a.CedarModel.valueSets]=o;const l=n.JsonNode.getEmptyList();t.valueConstraints.classes.forEach(e=>{l.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),e[a.CedarModel.classes]=l;const c=n.JsonNode.getEmptyList();t.valueConstraints.branches.forEach(e=>{c.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),e[a.CedarModel.branches]=c;const d=n.JsonNode.getEmptyList();if(t.valueConstraints.actions.forEach(e=>{d.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),d.length>0&&(e[a.CedarModel.actions]=d),null!=t.valueConstraints.defaultValue){const r=n.JsonNode.getEmpty();r[s.JsonSchema.rdfsLabel]=t.valueConstraints.defaultValue.rdfsLabel,r[s.JsonSchema.termUri]=this.atomicWriter.write(t.valueConstraints.defaultValue.termUri),e[a.CedarModel.defaultValue]=r}super.expandValueConstraintsNode(e,t,r)}}t.JsonFieldWriterControlledTerm=l},5376(e,t,r){t.ValueConstraintsControlledTermField=void 0;const n=r(4328);class a extends n.ValueConstraints{defaultValue=null;ontologies=[];valueSets=[];classes=[];branches=[];actions=[];constructor(){super()}}t.ValueConstraintsControlledTermField=a},9299(e,t,r){t.YamlFieldReaderControlledTerm=void 0;const n=r(8748),a=r(7295),i=r(4531),s=r(5675),o=r(2099),l=r(8349),c=r(5491),d=r(3091),u=r(2957),m=r(1556),p=r(7733),h=r(6731),f=r(8802),T=r(5753);class y extends s.YamlTemplateFieldTypeSpecificReader{read(e,t,r,s){const f=h.ControlledTermFieldImpl.buildEmpty();n.ReaderUtil.getNodeList(e,o.YamlKeys.values).forEach(e=>{const t=n.ReaderUtil.getString(e,o.YamlKeys.type);if(t===l.YamlValues.Controlled.ontology){const t=(new c.ControlledTermOntologyBuilder).withAcronym(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withName(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceName)).withUri(this.deriveOntologyUri(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym))).withNumTerms(n.ReaderUtil.getNumberOrNull(e,o.YamlKeys.Controlled.termCount));this.readSourceAndVersion(e,t),f.valueConstraints.ontologies.push(t.build())}else if(t===l.YamlValues.Controlled.class){const t=n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.termLabel),r=n.ReaderUtil.getString(e,o.YamlKeys.Controlled.termDisplayLabel),a=(new d.ControlledTermClassBuilder).withUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.termIri)).withSource(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withLabel(r??t).withPrefLabel(t).withType(i.BioportalTermType.forYamlValue(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.termType)));this.readSourceAndVersion(e,a),f.valueConstraints.classes.push(a.build())}else if(t===l.YamlValues.Controlled.branch){const t=(new u.ControlledTermBranchBuilder).withUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.termBaseIri)).withSource(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceName)).withName(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.termBaseLabel)).withAcronym(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withMaxDepth(n.ReaderUtil.getNumberOrZero(e,o.YamlKeys.Controlled.termMaxDepth));this.readSourceAndVersion(e,t),f.valueConstraints.branches.push(t.build())}else if(t===l.YamlValues.Controlled.valueSet){const t=(new m.ControlledTermValueSetBuilder).withUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.termBaseIri)).withNumTerms(n.ReaderUtil.getNumberOrNull(e,o.YamlKeys.Controlled.termCount)).withVsCollection(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withName(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.termBaseLabel));this.readSourceAndVersion(e,t),f.valueConstraints.valueSets.push(t.build())}});const T=n.ReaderUtil.getNodeOrNull(e,o.YamlKeys.default);if(null!==T){const e=n.ReaderUtil.getURI(T,o.YamlKeys.value),t=n.ReaderUtil.getStringOrEmpty(T,o.YamlKeys.label);f.valueConstraints.defaultValue=new a.ControlledTermDefaultValue(e,t)}return n.ReaderUtil.getNodeList(e,o.YamlKeys.actions).forEach(e=>{const t=(new p.ControlledTermActionBuilder).withAction(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.action)).withSource(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withType(i.BioportalTermType.forYamlValue(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.type))).withTermUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.termIri)).withTo(n.ReaderUtil.getNumber(e,o.YamlKeys.Controlled.to)).withSourceUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.sourceIri));f.valueConstraints.actions.push(t.build())}),f}deriveOntologyUri(e){return new f.Iri(`https://data.bioontology.org/ontologies/${e}`)}readSourceAndVersion(e,t){const r=n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.sourceIri);r.isEmpty()||t.withIri(r),t.withSourceSystem(n.ReaderUtil.getString(e,o.YamlKeys.Controlled.sourceSystem));const a=n.ReaderUtil.getNodeOrNull(e,o.YamlKeys.version);null!==a&&t.withVersion(new T.ControlledTermVersion(n.ReaderUtil.getStringOrEmpty(a,o.YamlKeys.Controlled.versionId),n.ReaderUtil.getString(a,o.YamlKeys.Controlled.versionEffectiveDate),n.ReaderUtil.getString(a,o.YamlKeys.Controlled.versionDeclaredVersion)))}}t.YamlFieldReaderControlledTerm=y},9535(e,t,r){t.YamlFieldWriterControlledTerm=void 0;const n=r(9517),a=r(5430),i=r(2099),s=r(4216);class o extends a.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandUINodeForYAML(e){return{[i.YamlKeys.datatype]:s.NonStandardDatatype.IRI}}expandValueConstraintsNodeForYAML(e,t,r){if(null!=t.valueConstraints.defaultValue){const r={[i.YamlKeys.value]:this.atomicWriter.write(t.valueConstraints.defaultValue.termUri),[i.YamlKeys.label]:t.valueConstraints.defaultValue.rdfsLabel};e[i.YamlKeys.default]=r}const a=n.JsonNode.getEmptyList();t.valueConstraints.ontologies.forEach(e=>{a.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),t.valueConstraints.classes.forEach(e=>{a.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),t.valueConstraints.branches.forEach(e=>{a.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),t.valueConstraints.valueSets.forEach(e=>{a.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),a.length>0&&(e[i.YamlKeys.values]=a);const s=n.JsonNode.getEmptyList();t.valueConstraints.actions.forEach(e=>{s.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),s.length>0&&(e[i.YamlKeys.actions]=s)}}t.YamlFieldWriterControlledTerm=o},1524(e,t,r){t.AbstractJsonControlledTermValueConstraintWriter=void 0;const n=r(9517),a=r(3557),i=r(936);class s extends a.JsonValueConstraintsWriter{writeSourceAndVersion(e,t){null===t.iri||t.iri.isEmpty()||(e[i.CedarModel.ValueConstraints.iri]=this.atomicWriter.write(t.iri)),null!==t.sourceSystem&&(e[i.CedarModel.ValueConstraints.sourceSystem]=t.sourceSystem);const r=t.version;if(null!==r){const t=n.JsonNode.getEmpty();t[i.CedarModel.ValueConstraints.versionId]=r.id,null!==r.effectiveDate&&(t[i.CedarModel.ValueConstraints.versionEffectiveDate]=r.effectiveDate),null!==r.declaredVersion&&(t[i.CedarModel.ValueConstraints.versionDeclaredVersion]=r.declaredVersion),e[i.CedarModel.ValueConstraints.version]=t}}}t.AbstractJsonControlledTermValueConstraintWriter=s},4339(e,t,r){t.AbstractYamlControlledTermValueConstraintWriter=void 0;const n=r(9517),a=r(2500),i=r(2099);class s extends a.YamlValueConstraintsWriter{writeSourceSystem(e,t){null!==t.sourceSystem&&(e[i.YamlKeys.Controlled.sourceSystem]=t.sourceSystem)}writeSourceIri(e,t){null===t.iri||t.iri.isEmpty()||(e[i.YamlKeys.Controlled.sourceIri]=this.atomicWriter.write(t.iri))}writeVersion(e,t){const r=t.version;if(null===r)return;const a=n.JsonNode.getEmpty();a[i.YamlKeys.Controlled.versionId]=r.id,null!==r.effectiveDate&&(a[i.YamlKeys.Controlled.versionEffectiveDate]=r.effectiveDate),null!==r.declaredVersion&&(a[i.YamlKeys.Controlled.versionDeclaredVersion]=r.declaredVersion),e[i.YamlKeys.version]=a}}t.AbstractYamlControlledTermValueConstraintWriter=s},2369(e,t,r){t.ControlledTermAbstractValueConstraint=void 0;const n=r(4328);class a extends n.ValueConstraints{className="ControlledTermAbstractValueConstraint";_iri;_sourceSystem;_version;constructor(e=null,t=null,r=null){super(),this._iri=e,this._sourceSystem=t,this._version=r}get iri(){return this._iri}get sourceSystem(){return this._sourceSystem}get version(){return this._version}}t.ControlledTermAbstractValueConstraint=a},7295(e,t){t.ControlledTermDefaultValue=void 0,t.ControlledTermDefaultValue=class{_termUri;_rdfsLabel;constructor(e,t){this._termUri=e,this._rdfsLabel=t}get termUri(){return this._termUri}get rdfsLabel(){return this._rdfsLabel}isControlledDefaultValue(){return!1}}},2480(e,t,r){t.ControlledTermDefaultValueBuilder=void 0;const n=r(8802),a=r(7295),i=r(3539);t.ControlledTermDefaultValueBuilder=class{termUri=n.Iri.empty();rdfsLabel="";withTermUri(e){return this.termUri=e,this}withRdfsLabel(e){return this.rdfsLabel=e,this}build(){return i.ValueConstraintRequirements.requireIri(this.termUri,"a term URI","A controlled-term default value"),i.ValueConstraintRequirements.requireText(this.rdfsLabel,"a label","A controlled-term default value"),new a.ControlledTermDefaultValue(this.termUri,this.rdfsLabel)}}},5753(e,t){t.ControlledTermVersion=void 0,t.ControlledTermVersion=class{_id;_effectiveDate;_declaredVersion;constructor(e,t=null,r=null){this._id=e,this._effectiveDate=t,this._declaredVersion=r}get id(){return this._id}get effectiveDate(){return this._effectiveDate}get declaredVersion(){return this._declaredVersion}}},3539(e,t){t.ValueConstraintRequirements=void 0,t.ValueConstraintRequirements=class{static requireText(e,t,r){if(null==e||""===e)throw new Error(`${r} requires ${t}.`)}static requireIri(e,t,r){if(null==e||e.isEmpty())throw new Error(`${r} requires ${t}. A constraint that points at nothing cannot be resolved.`)}static requireTermType(e,t){if(null==e||null===e.getJsonValue())throw new Error(`${t} requires a term type.`)}}},7432(e,t,r){t.ControlledTermAction=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermAction";className="ControlledTermAction";_to=null;_action;_termUri;_sourceUri;_source;_type;constructor(e,t,r,n,a,i){super(),this._to=e,this._action=t,this._termUri=r,this._sourceUri=n,this._source=a,this._type=i}get to(){return this._to}get action(){return this._action}get termUri(){return this._termUri}get sourceUri(){return this._sourceUri}get source(){return this._source}get type(){return this._type}}t.ControlledTermAction=a},7733(e,t,r){t.ControlledTermActionBuilder=void 0;const n=r(8802),a=r(7432),i=r(3539),s=r(4531);t.ControlledTermActionBuilder=class{_to=null;_action="";_termUri=n.Iri.empty();_sourceUri=n.Iri.empty();_source="";_type=s.BioportalTermType.NULL;withTo(e){return this._to=e,this}withAction(e){return this._action=e,this}withTermUri(e){return this._termUri=e,this}withSourceUri(e){return this._sourceUri=e,this}withSource(e){return this._source=e,this}withType(e){return this._type=e,this}build(){return i.ValueConstraintRequirements.requireText(this._action,"an action","A controlled-term action"),i.ValueConstraintRequirements.requireIri(this._termUri,"a term URI","A controlled-term action"),i.ValueConstraintRequirements.requireIri(this._sourceUri,"a source URI","A controlled-term action"),i.ValueConstraintRequirements.requireText(this._source,"a source","A controlled-term action"),i.ValueConstraintRequirements.requireTermType(this._type,"A controlled-term action"),new a.ControlledTermAction(this._to,this._action,this._termUri,this._sourceUri,this._source,this._type)}}},8014(e,t,r){t.JsonValueConstraintsActionWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return null!==e.to&&(t[a.CedarModel.ValueConstraints.to]=e.to),t[a.CedarModel.ValueConstraints.action]=e.action,t[a.CedarModel.ValueConstraints.termUri]=this.atomicWriter.write(e.termUri),t[a.CedarModel.ValueConstraints.sourceUri]=this.atomicWriter.write(e.sourceUri),t[a.CedarModel.ValueConstraints.source]=e.source,t[a.CedarModel.ValueConstraints.type]=this.atomicWriter.write(e.type),t}}t.JsonValueConstraintsActionWriter=s},4647(e,t,r){t.YamlValueConstraintsActionWriter=void 0;const n=r(9517),a=r(4339),i=r(2099);class s extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.action]=e.action,null!==e.to&&(t[i.YamlKeys.Controlled.to]=e.to),t[i.YamlKeys.Controlled.termIri]=this.atomicWriter.write(e.termUri),t[i.YamlKeys.Controlled.sourceIri]=this.atomicWriter.write(e.sourceUri),t[i.YamlKeys.Controlled.sourceAcronym]=e.source,t[i.YamlKeys.type]=this.atomicWriter.write(e.type),t}}t.YamlValueConstraintsActionWriter=s},9184(e,t,r){t.ControlledTermBranch=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermBranch";className="ControlledTermBranch";_source;_acronym;_name;_uri;_maxDepth=0;constructor(e,t,r,n,a,i=null,s=null,o=null){super(i,s,o),this._source=e,this._acronym=t,this._uri=a,this._name=r,this._maxDepth=n}get source(){return this._source}get acronym(){return this._acronym}get name(){return this._name}get uri(){return this._uri}get maxDepth(){return this._maxDepth}}t.ControlledTermBranch=a},2957(e,t,r){t.ControlledTermBranchBuilder=void 0;const n=r(8802),a=r(9184),i=r(3539);t.ControlledTermBranchBuilder=class{_source="";_acronym="";_name="";_uri=n.Iri.empty();_maxDepth=0;_iri=null;_sourceSystem=null;_version=null;withSource(e){return this._source=e,this}withAcronym(e){return this._acronym=e,this}withName(e){return this._name=e,this}withUri(e){return this._uri=e,this}withMaxDepth(e){return this._maxDepth=e,this}withIri(e){return this._iri=e,this}withSourceSystem(e){return this._sourceSystem=e,this}withVersion(e){return this._version=e,this}build(){return i.ValueConstraintRequirements.requireIri(this._uri,"a URI","A branch constraint"),i.ValueConstraintRequirements.requireText(this._source,"a source","A branch constraint"),i.ValueConstraintRequirements.requireText(this._acronym,"an acronym","A branch constraint"),i.ValueConstraintRequirements.requireText(this._name,"a name","A branch constraint"),new a.ControlledTermBranch(this._source,this._acronym,this._name,this._maxDepth,this._uri,this._iri,this._sourceSystem,this._version)}}},7054(e,t,r){t.JsonValueConstraintsBranchWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[a.CedarModel.ValueConstraints.uri]=this.atomicWriter.write(e.uri),t[a.CedarModel.ValueConstraints.source]=e.source,t[a.CedarModel.ValueConstraints.acronym]=e.acronym,t[a.CedarModel.ValueConstraints.name]=e.name,t[a.CedarModel.ValueConstraints.maxDepth]=e.maxDepth,this.writeSourceAndVersion(t,e),t}}t.JsonValueConstraintsBranchWriter=s},3671(e,t,r){t.YamlValueConstraintsBranchWriter=void 0;const n=r(9517),a=r(4339),i=r(2099),s=r(8349);class o extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.type]=s.YamlValues.Controlled.branch,this.writeSourceSystem(t,e),t[i.YamlKeys.Controlled.sourceAcronym]=e.acronym,t[i.YamlKeys.Controlled.sourceName]=e.source,this.writeSourceIri(t,e),t[i.YamlKeys.Controlled.termBaseIri]=this.atomicWriter.write(e.uri),t[i.YamlKeys.Controlled.termBaseLabel]=e.name,t[i.YamlKeys.Controlled.termMaxDepth]=e.maxDepth,this.writeVersion(t,e),t}}t.YamlValueConstraintsBranchWriter=o},2418(e,t,r){t.ControlledTermClass=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermClass";className="ControlledTermClass";_label;_source;_type;_prefLabel;_uri;constructor(e,t,r,n,a,i=null,s=null,o=null){super(i,s,o),this._label=e,this._source=t,this._type=r,this._prefLabel=n,this._uri=a}get label(){return this._label}get source(){return this._source}get type(){return this._type}get prefLabel(){return this._prefLabel}get uri(){return this._uri}}t.ControlledTermClass=a},3091(e,t,r){t.ControlledTermClassBuilder=void 0;const n=r(8802),a=r(2418),i=r(3539),s=r(4531);t.ControlledTermClassBuilder=class{_label="";_source="";_type=s.BioportalTermType.NULL;_prefLabel="";_uri=n.Iri.empty();_iri=null;_sourceSystem=null;_version=null;withLabel(e){return this._label=e,this}withSource(e){return this._source=e,this}withType(e){return this._type=e,this}withPrefLabel(e){return this._prefLabel=e,this}withUri(e){return this._uri=e,this}withIri(e){return this._iri=e,this}withSourceSystem(e){return this._sourceSystem=e,this}withVersion(e){return this._version=e,this}build(){return i.ValueConstraintRequirements.requireIri(this._uri,"a URI","A class constraint"),i.ValueConstraintRequirements.requireText(this._label,"a label","A class constraint"),i.ValueConstraintRequirements.requireText(this._prefLabel,"a preferred label","A class constraint"),i.ValueConstraintRequirements.requireText(this._source,"a source","A class constraint"),i.ValueConstraintRequirements.requireTermType(this._type,"A class constraint"),new a.ControlledTermClass(this._label,this._source,this._type,this._prefLabel,this._uri,this._iri,this._sourceSystem,this._version)}}},9222(e,t,r){t.JsonValueConstraintsClassWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[a.CedarModel.ValueConstraints.uri]=this.atomicWriter.write(e.uri),t[a.CedarModel.ValueConstraints.source]=e.source,t[a.CedarModel.ValueConstraints.label]=e.label,t[a.CedarModel.ValueConstraints.prefLabel]=e.prefLabel,t[a.CedarModel.ValueConstraints.type]=this.atomicWriter.write(e.type),this.writeSourceAndVersion(t,e),t}}t.JsonValueConstraintsClassWriter=s},765(e,t,r){t.YamlValueConstraintsClassWriter=void 0;const n=r(9517),a=r(4339),i=r(2099),s=r(8349);class o extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.type]=s.YamlValues.Controlled.class,this.writeSourceSystem(t,e),t[i.YamlKeys.Controlled.sourceAcronym]=e.source,this.writeSourceIri(t,e),t[i.YamlKeys.Controlled.termIri]=this.atomicWriter.write(e.uri),t[i.YamlKeys.Controlled.termType]=this.atomicWriter.write(e.type),t[i.YamlKeys.Controlled.termLabel]=e.prefLabel,e.label!==e.prefLabel&&(t[i.YamlKeys.Controlled.termDisplayLabel]=e.label),this.writeVersion(t,e),t}}t.YamlValueConstraintsClassWriter=o},8354(e,t,r){t.ControlledTermOntology=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermOntology";className="ControlledTermOntology";_acronym;_name;_uri;_numTerms=0;constructor(e,t,r,n,a=null,i=null,s=null){super(a,i,s),this._acronym=e,this._name=t,this._uri=n,this._numTerms=r}get acronym(){return this._acronym}get name(){return this._name}get uri(){return this._uri}get numTerms(){return this._numTerms}}t.ControlledTermOntology=a},5491(e,t,r){t.ControlledTermOntologyBuilder=void 0;const n=r(8802),a=r(8354),i=r(3539);t.ControlledTermOntologyBuilder=class{acronym="";name="";numTerms=null;uri=n.Iri.empty();iri=null;sourceSystem=null;version=null;withAcronym(e){return this.acronym=e,this}withName(e){return this.name=e,this}withNumTerms(e){return this.numTerms=e,this}withUri(e){return this.uri=e,this}withIri(e){return this.iri=e,this}withSourceSystem(e){return this.sourceSystem=e,this}withVersion(e){return this.version=e,this}build(){return i.ValueConstraintRequirements.requireIri(this.uri,"a URI","An ontology constraint"),i.ValueConstraintRequirements.requireText(this.acronym,"an acronym","An ontology constraint"),i.ValueConstraintRequirements.requireText(this.name,"a name","An ontology constraint"),new a.ControlledTermOntology(this.acronym,this.name,this.numTerms,this.uri,this.iri,this.sourceSystem,this.version)}}},5996(e,t,r){t.JsonValueConstraintsOntologyWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[a.CedarModel.ValueConstraints.uri]=this.atomicWriter.write(e.uri),t[a.CedarModel.ValueConstraints.acronym]=e.acronym,t[a.CedarModel.ValueConstraints.name]=e.name,null!==e.numTerms&&(t[a.CedarModel.ValueConstraints.numTerms]=e.numTerms),this.writeSourceAndVersion(t,e),t}}t.JsonValueConstraintsOntologyWriter=s},1181(e,t,r){t.YamlValueConstraintsOntologyWriter=void 0;const n=r(9517),a=r(4339),i=r(2099),s=r(8349);class o extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.type]=s.YamlValues.Controlled.ontology,this.writeSourceSystem(t,e),t[i.YamlKeys.Controlled.sourceAcronym]=e.acronym,t[i.YamlKeys.Controlled.sourceName]=e.name,this.writeSourceIri(t,e),null!==e.numTerms&&(t[i.YamlKeys.Controlled.termCount]=e.numTerms),this.writeVersion(t,e),t}}t.YamlValueConstraintsOntologyWriter=o},2395(e,t,r){t.ControlledTermValueSet=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermValueSet";className="ControlledTermValueSet";_vsCollection;_name;_uri;_numTerms=0;constructor(e,t,r,n,a=null,i=null,s=null){super(a,i,s),this._vsCollection=e,this._name=t,this._uri=n,this._numTerms=r}get vsCollection(){return this._vsCollection}get name(){return this._name}get uri(){return this._uri}get numTerms(){return this._numTerms}}t.ControlledTermValueSet=a},1556(e,t,r){t.ControlledTermValueSetBuilder=void 0;const n=r(8802),a=r(2395),i=r(3539);t.ControlledTermValueSetBuilder=class{_vsCollection="";_name="";_uri=n.Iri.empty();_numTerms=null;_iri=null;_sourceSystem=null;_version=null;withVsCollection(e){return this._vsCollection=e,this}withName(e){return this._name=e,this}withUri(e){return this._uri=e,this}withNumTerms(e){return this._numTerms=e,this}withIri(e){return this._iri=e,this}withSourceSystem(e){return this._sourceSystem=e,this}withVersion(e){return this._version=e,this}build(){return i.ValueConstraintRequirements.requireIri(this._uri,"a URI","A value-set constraint"),i.ValueConstraintRequirements.requireText(this._vsCollection,"a value-set collection","A value-set constraint"),i.ValueConstraintRequirements.requireText(this._name,"a name","A value-set constraint"),new a.ControlledTermValueSet(this._vsCollection,this._name,this._numTerms,this._uri,this._iri,this._sourceSystem,this._version)}}},2813(e,t,r){t.JsonValueConstraintsValueSetWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[a.CedarModel.ValueConstraints.uri]=this.atomicWriter.write(e.uri),t[a.CedarModel.ValueConstraints.vsCollection]=e.vsCollection,t[a.CedarModel.ValueConstraints.name]=e.name,null!==e.numTerms&&(t[a.CedarModel.ValueConstraints.numTerms]=e.numTerms),this.writeSourceAndVersion(t,e),t}}t.JsonValueConstraintsValueSetWriter=s},9532(e,t,r){t.YamlValueConstraintsValueSetWriter=void 0;const n=r(9517),a=r(4339),i=r(2099),s=r(8349);class o extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.type]=s.YamlValues.Controlled.valueSet,this.writeSourceSystem(t,e),t[i.YamlKeys.Controlled.sourceAcronym]=e.vsCollection,this.writeSourceIri(t,e),t[i.YamlKeys.Controlled.termBaseIri]=this.atomicWriter.write(e.uri),t[i.YamlKeys.Controlled.termBaseLabel]=e.name,null!==e.numTerms&&(t[i.YamlKeys.Controlled.termCount]=e.numTerms),this.writeVersion(t,e),t}}t.YamlValueConstraintsValueSetWriter=o},1667(e,t,r){t.EmailFieldBuilderImpl=void 0;const n=r(3350),a=r(4450);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.EmailFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.EmailFieldBuilderImpl=i},4450(e,t,r){t.EmailFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EMAIL,this.valueConstraints=new s.ValueConstraints,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.EmailFieldImpl=l},2691(e,t,r){t.JsonFieldReaderEmail=void 0;const n=r(4385),a=r(4450);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.EmailFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderEmail=i},9031(e,t,r){t.JsonFieldWriterEmail=void 0;const n=r(2748);class a extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.JsonFieldWriterEmail=a},3054(e,t,r){t.YamlFieldReaderEmail=void 0;const n=r(5675),a=r(4450);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.EmailFieldImpl.buildEmpty()}}t.YamlFieldReaderEmail=i},1038(e,t,r){t.YamlFieldWriterEmail=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterEmail=a},6610(e,t,r){t.ExtDoiFieldBuilderImpl=void 0;const n=r(3350),a=r(997);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtDoiFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtDoiFieldBuilderImpl=i},997(e,t,r){t.ExtDoiFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_DOI,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtDoiFieldImpl=l},8583(e,t,r){t.JsonFieldReaderExtDoi=void 0;const n=r(4385),a=r(997);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtDoiFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtDoi=i},7412(e,t,r){t.JsonFieldWriterExtDoi=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtDoi=s},5907(e,t,r){t.YamlFieldReaderExtDoi=void 0;const n=r(5675),a=r(997);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtDoiFieldImpl.buildEmpty()}}t.YamlFieldReaderExtDoi=i},6967(e,t,r){t.YamlFieldWriterExtDoi=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtDoi=a},9062(e,t,r){t.ExtNihGrantIdFieldBuilderImpl=void 0;const n=r(3350),a=r(7313);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtNihGrantIdFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtNihGrantIdFieldBuilderImpl=i},7313(e,t,r){t.ExtNihGrantIdFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_NIH_GRANT_ID,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtNihGrantIdFieldImpl=l},1886(e,t,r){t.JsonFieldReaderExtNihGrantId=void 0;const n=r(4385),a=r(7313);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtNihGrantIdFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtNihGrantId=i},5250(e,t,r){t.JsonFieldWriterExtNihGrantId=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtNihGrantId=s},8543(e,t,r){t.YamlFieldReaderExtNihGrantId=void 0;const n=r(5675),a=r(7313);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtNihGrantIdFieldImpl.buildEmpty()}}t.YamlFieldReaderExtNihGrantId=i},3711(e,t,r){t.YamlFieldWriterExtNihGrantId=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtNihGrantId=a},2376(e,t,r){t.ExtOrcidFieldBuilderImpl=void 0;const n=r(3350),a=r(5967);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtOrcidFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtOrcidFieldBuilderImpl=i},5967(e,t,r){t.ExtOrcidFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_ORCID,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtOrcidFieldImpl=l},4956(e,t,r){t.JsonFieldReaderExtOrcid=void 0;const n=r(4385),a=r(5967);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtOrcidFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtOrcid=i},8096(e,t,r){t.JsonFieldWriterExtOrcid=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtOrcid=s},7123(e,t,r){t.YamlFieldReaderExtOrcid=void 0;const n=r(5675),a=r(5967);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtOrcidFieldImpl.buildEmpty()}}t.YamlFieldReaderExtOrcid=i},4355(e,t,r){t.YamlFieldWriterExtOrcid=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtOrcid=a},3914(e,t,r){t.ExtPfasFieldBuilderImpl=void 0;const n=r(3350),a=r(6637);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtPfasFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtPfasFieldBuilderImpl=i},6637(e,t,r){t.ExtPfasFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_PFAS,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtPfasFieldImpl=l},6854(e,t,r){t.JsonFieldReaderExtPfas=void 0;const n=r(4385),a=r(6637);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtPfasFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtPfas=i},6122(e,t,r){t.JsonFieldWriterExtPfas=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtPfas=s},5075(e,t,r){t.YamlFieldReaderExtPfas=void 0;const n=r(5675),a=r(6637);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtPfasFieldImpl.buildEmpty()}}t.YamlFieldReaderExtPfas=i},5587(e,t,r){t.YamlFieldWriterExtPfas=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtPfas=a},7162(e,t,r){t.ExtPubmedFieldBuilderImpl=void 0;const n=r(3350),a=r(2685);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtPubmedFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtPubmedFieldBuilderImpl=i},2685(e,t,r){t.ExtPubmedFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_PUBMED,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtPubmedFieldImpl=l},3028(e,t,r){t.JsonFieldReaderExtPubmed=void 0;const n=r(4385),a=r(2685);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtPubmedFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtPubmed=i},3312(e,t,r){t.JsonFieldWriterExtPubmed=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtPubmed=s},7709(e,t,r){t.YamlFieldReaderExtPubmed=void 0;const n=r(5675),a=r(2685);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtPubmedFieldImpl.buildEmpty()}}t.YamlFieldReaderExtPubmed=i},6557(e,t,r){t.YamlFieldWriterExtPubmed=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtPubmed=a},7328(e,t,r){t.ExtRorFieldBuilderImpl=void 0;const n=r(3350),a=r(4007);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtRorFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtRorFieldBuilderImpl=i},4007(e,t,r){t.ExtRorFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_ROR,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtRorFieldImpl=l},8244(e,t,r){t.JsonFieldReaderExtRor=void 0;const n=r(4385),a=r(4007);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtRorFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtRor=i},7584(e,t,r){t.JsonFieldWriterExtRor=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtRor=s},6651(e,t,r){t.YamlFieldReaderExtRor=void 0;const n=r(5675),a=r(4007);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtRorFieldImpl.buildEmpty()}}t.YamlFieldReaderExtRor=i},491(e,t,r){t.YamlFieldWriterExtRor=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtRor=a},3474(e,t,r){t.ExtRridFieldBuilderImpl=void 0;const n=r(3350),a=r(789);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtRridFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtRridFieldBuilderImpl=i},789(e,t,r){t.ExtRridFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_RRID,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtRridFieldImpl=l},7004(e,t,r){t.JsonFieldReaderExtRrid=void 0;const n=r(4385),a=r(789);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtRridFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtRrid=i},4780(e,t,r){t.JsonFieldWriterExtRrid=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtRrid=s},6089(e,t,r){t.YamlFieldReaderExtRrid=void 0;const n=r(5675),a=r(789);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtRridFieldImpl.buildEmpty()}}t.YamlFieldReaderExtRrid=i},4077(e,t,r){t.YamlFieldWriterExtRrid=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtRrid=a},7095(e,t,r){t.JsonFieldReaderLink=void 0;const n=r(4385),a=r(4084);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.LinkFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderLink=i},3691(e,t,r){t.JsonFieldWriterLink=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterLink=s},9497(e,t,r){t.LinkFieldBuilderImpl=void 0;const n=r(3350),a=r(4084);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.LinkFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.LinkFieldBuilderImpl=i},4084(e,t,r){t.LinkFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.LINK,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.LinkFieldImpl=l},8568(e,t,r){t.YamlFieldReaderLink=void 0;const n=r(5675),a=r(4084);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.LinkFieldImpl.buildEmpty()}}t.YamlFieldReaderLink=i},1784(e,t,r){t.YamlFieldWriterLink=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterLink=a},1513(e,t,r){t.MultipleChoiceListFieldBuilderImpl=void 0;const n=r(9513);class a extends n.ListFieldBuilderImpl{constructor(){super(),this.multipleChoice=!0}static create(){return new a}build(){return super.build()}}t.MultipleChoiceListFieldBuilderImpl=a},4932(e,t,r){t.MultipleChoiceListFieldImpl=void 0;const n=r(5316),a=r(4869),i=r(3239);class s extends n.ListFieldImpl{constructor(){super(),this.multipleChoice=!0,this.cedarFieldType=a.CedarFieldType.MULTIPLE_SELECT_LIST}static buildEmpty(){return new s}isMultiInstanceByDefinition(){return!0}createDeploymentBuilder(e){return new i.ChildDeploymentInfoAlwaysMultipleBuilder(this,e)}}t.MultipleChoiceListFieldImpl=s},7124(e,t,r){t.YamlFieldReaderMultiSelectList=void 0;const n=r(5675),a=r(4932);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const s=a.MultipleChoiceListFieldImpl.buildEmpty();return n.YamlTemplateFieldTypeSpecificReader.readAndStoreListValueConstraints(e,s),s}}t.YamlFieldReaderMultiSelectList=i},9105(e,t,r){t.SingleChoiceListFieldBuilderImpl=void 0;const n=r(9513);class a extends n.ListFieldBuilderImpl{constructor(){super(),this.multipleChoice=!1}static create(){return new a}build(){return super.build()}}t.SingleChoiceListFieldBuilderImpl=a},1676(e,t,r){t.SingleChoiceListFieldImpl=void 0;const n=r(5316),a=r(3608),i=r(4869);class s extends n.ListFieldImpl{constructor(){super(),this.multipleChoice=!1,this.cedarFieldType=i.CedarFieldType.SINGLE_SELECT_LIST}static buildEmpty(){return new s}createDeploymentBuilder(e){return new a.ChildDeploymentInfoBuilder(this,e)}}t.SingleChoiceListFieldImpl=s},2709(e,t,r){t.YamlFieldReaderSingleSelectList=void 0;const n=r(5675),a=r(1676);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const s=a.SingleChoiceListFieldImpl.buildEmpty();return n.YamlTemplateFieldTypeSpecificReader.readAndStoreListValueConstraints(e,s),s}}t.YamlFieldReaderSingleSelectList=i},2419(e,t,r){t.JsonFieldReaderList=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(4081),o=r(4932),l=r(1676);class c extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){let c=l.SingleChoiceListFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const d=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=d){n.ReaderUtil.getBoolean(d,a.CedarModel.multipleChoice)&&(c=o.MultipleChoiceListFieldImpl.buildEmpty()),c.valueConstraints.defaultValue=n.ReaderUtil.getString(d,a.CedarModel.defaultValue);const e=n.ReaderUtil.getNodeList(d,a.CedarModel.literals);null!==e&&e.forEach(e=>{const t=n.ReaderUtil.getString(e,a.CedarModel.label),r=n.ReaderUtil.getBoolean(e,a.CedarModel.selectedByDefault);if(null!=t){const e=new s.ListOption(t,r);c.valueConstraints.literals.push(e)}})}return c}}t.JsonFieldReaderList=c},7335(e,t,r){t.JsonFieldWriterList=void 0;const n=r(936),a=r(2748);class i extends a.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){null!==t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[n.CedarModel.defaultValue]=t.valueConstraints.defaultValue),this.expandLiterals(t,e),super.expandValueConstraintsNode(e,t,r),e[n.CedarModel.multipleChoice]=t.multipleChoice}}t.JsonFieldWriterList=i},9513(e,t,r){t.ListFieldBuilderImpl=void 0;const n=r(4081),a=r(3350),i=r(4932),s=r(1676);class o extends a.TemplateFieldBuilder{multipleChoice=!1;literals=[];constructor(){super()}addListOption(e,t=!1){return this.literals.push(new n.ListOption(e,t)),this}build(){let e;if(e=this.multipleChoice?i.MultipleChoiceListFieldImpl.buildEmpty():s.SingleChoiceListFieldImpl.buildEmpty(),super.buildInternal(e),!this.multipleChoice){let e=-1;for(let t=this.literals.length-1;t>=0;t--)if(this.literals[t].selectedByDefault){e=t;break}-1!==e&&this.literals.forEach((t,r)=>{t.selectedByDefault=r===e})}return e.valueConstraints.literals=this.literals,e}}t.ListFieldBuilderImpl=o},5316(e,t,r){t.ListFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(1623);class o extends n.TemplateField{valueConstraints;multipleChoice;constructor(){super(),this.cedarFieldType=a.CedarFieldType.NULL,this.valueConstraints=new s.ValueConstraintsListField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.multipleChoice=!1}}t.ListFieldImpl=o},4081(e,t,r){t.ListOption=void 0;const n=r(7282);class a extends n.ChoiceOptionEntity{constructor(e,t){super(e,t)}}t.ListOption=a},1623(e,t,r){t.ValueConstraintsListField=void 0;const n=r(4328);class a extends n.ValueConstraints{defaultValue=null;literals=[];constructor(){super()}}t.ValueConstraintsListField=a},3080(e,t,r){t.YamlFieldWriterList=void 0;const n=r(5430),a=r(9499),i=r(2099);class s extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){null!==t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[i.YamlKeys.default]=t.valueConstraints.defaultValue),this.expandLiterals(t,e)}getYamlType(e){return e.multipleChoice?a.YamlArtifactType.MULTI_SELECT_LIST.getValue():a.YamlArtifactType.SINGLE_SELECT_LIST.getValue()}}t.YamlFieldWriterList=s},1769(e,t,r){t.JsonFieldReaderNumeric=void 0;const n=r(8748),a=r(936),i=r(3447),s=r(4385),o=r(4074),l=r(6444);class c extends s.JsonTemplateFieldTypeSpecificReader{read(e,t,r,s){const c=o.NumericFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const d=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=d){const e=n.ReaderUtil.getString(d,a.CedarModel.numberType);null!==e&&(c.valueConstraints.numberType=i.NumberType.forValue(e)),c.valueConstraints.minValue=n.ReaderUtil.getNumber(d,a.CedarModel.minValue),c.valueConstraints.maxValue=n.ReaderUtil.getNumber(d,a.CedarModel.maxValue),c.valueConstraints.decimalPlaces=n.ReaderUtil.getNumber(d,a.CedarModel.decimalPlace),c.valueConstraints.unitOfMeasure=n.ReaderUtil.getString(d,a.CedarModel.unitOfMeasure),c.valueConstraints.defaultValue=n.ReaderUtil.getNumericDefault(d,a.CedarModel.defaultValue),l.NumericDefaultValueValidator.assertValid(c.valueConstraints.numberType,c.valueConstraints.defaultValue,c.valueConstraints.minValue,c.valueConstraints.maxValue)}return c}}t.JsonFieldReaderNumeric=c},4841(e,t,r){t.JsonFieldWriterNumeric=void 0;const n=r(9932),a=r(2733),i=r(2748),s=r(936),o=r(6444);class l extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_LITERAL}expandRequiredNode(e){e[a.JsonSchema.required]=[a.JsonSchema.atValue,a.JsonSchema.atType]}expandValueConstraintsNode(e,t,r){o.NumericDefaultValueValidator.assertValid(t.valueConstraints.numberType,t.valueConstraints.defaultValue,t.valueConstraints.minValue,t.valueConstraints.maxValue),e[s.CedarModel.numberType]=this.atomicWriter.write(t.valueConstraints.numberType),null!=t.valueConstraints.minValue&&(e[s.CedarModel.minValue]=t.valueConstraints.minValue),null!=t.valueConstraints.maxValue&&(e[s.CedarModel.maxValue]=t.valueConstraints.maxValue),null!=t.valueConstraints.decimalPlaces&&(e[s.CedarModel.decimalPlace]=t.valueConstraints.decimalPlaces),null!=t.valueConstraints.unitOfMeasure&&(e[s.CedarModel.unitOfMeasure]=t.valueConstraints.unitOfMeasure),null!=t.valueConstraints.defaultValue&&(e[s.CedarModel.defaultValue]=String(t.valueConstraints.defaultValue)),super.expandValueConstraintsNode(e,t,r)}}t.JsonFieldWriterNumeric=l},6444(e,t,r){t.NumericDefaultValueValidator=void 0;const n=r(3447);t.NumericDefaultValueValidator=class{static assertValid(e,t,r=null,a=null){if(null===t)return;if(!Number.isFinite(t))throw new Error("Numeric default must be finite.");const i=e.getValue();if(null===i)throw new Error("Numeric default requires a numeric datatype.");const s={[n.NumberTypeValues.BYTE]:[-128,127],[n.NumberTypeValues.SHORT]:[-32768,32767],[n.NumberTypeValues.INT]:[-2147483648,2147483647],[n.NumberTypeValues.LONG]:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER]}[i];if(void 0!==s){if(!Number.isSafeInteger(t))throw new Error(`Numeric default ${t} must be a safely representable integer for ${i}.`);if(t<s[0]||t>s[1])throw new Error(`Numeric default ${t} is outside the ${i} range.`)}if(i===n.NumberTypeValues.FLOAT){const e=Math.abs(t);if(e>34028234663852886e22||0!==e&&e<1401298464324817e-60)throw new Error(`Numeric default ${t} is outside the ${i} range.`)}if(null!==r&&t<r)throw new Error(`Numeric default ${t} is below minValue ${r}.`);if(null!==a&&t>a)throw new Error(`Numeric default ${t} is above maxValue ${a}.`)}}},3675(e,t,r){t.NumericFieldBuilderImpl=void 0;const n=r(3350),a=r(3447),i=r(4074),s=r(6444);class o extends n.TemplateFieldBuilder{numberType=a.NumberType.DECIMAL;minValue=null;maxValue=null;decimalPlaces=null;unitOfMeasure=null;defaultValue=null;constructor(){super()}static create(){return new o}withNumberType(e){return this.numberType=e,this}withMinValue(e){return this.minValue=e,this}withMaxValue(e){return this.maxValue=e,this}withDecimalPlaces(e){return this.decimalPlaces=e,this}withUnitOfMeasure(e){return this.unitOfMeasure=e,this}withDefaultValue(e){return this.defaultValue=e,this}build(){s.NumericDefaultValueValidator.assertValid(this.numberType,this.defaultValue,this.minValue,this.maxValue);const e=i.NumericFieldImpl.buildEmpty();return super.buildInternal(e),e.valueConstraints.numberType=this.numberType,e.valueConstraints.minValue=this.minValue,e.valueConstraints.maxValue=this.maxValue,e.valueConstraints.decimalPlaces=this.decimalPlaces,e.valueConstraints.unitOfMeasure=this.unitOfMeasure,e.valueConstraints.defaultValue=this.defaultValue,e}}t.NumericFieldBuilderImpl=o},4074(e,t,r){t.NumericFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(1211),o=r(3608);class l extends n.TemplateField{valueConstraints;constructor(){super(),this.cedarFieldType=a.CedarFieldType.NUMERIC,this.valueConstraints=new s.ValueConstraintsNumericField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.NumericFieldImpl=l},1211(e,t,r){t.ValueConstraintsNumericField=void 0;const n=r(4328),a=r(3447);class i extends n.ValueConstraints{numberType=a.NumberType.DECIMAL;minValue=null;maxValue=null;decimalPlaces=null;unitOfMeasure=null;defaultValue=null;constructor(){super()}}t.ValueConstraintsNumericField=i},1872(e,t,r){t.YamlFieldReaderNumeric=void 0;const n=r(8748),a=r(3447),i=r(5675),s=r(2099),o=r(4074),l=r(6444);class c extends i.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const c=o.NumericFieldImpl.buildEmpty(),d=n.ReaderUtil.getString(e,s.YamlKeys.datatype);return null!==d&&(c.valueConstraints.numberType=a.NumberType.forValue(d)),c.valueConstraints.minValue=n.ReaderUtil.getNumber(e,s.YamlKeys.minValue),c.valueConstraints.maxValue=n.ReaderUtil.getNumber(e,s.YamlKeys.maxValue),c.valueConstraints.decimalPlaces=n.ReaderUtil.getNumber(e,s.YamlKeys.decimalPlaces),c.valueConstraints.unitOfMeasure=n.ReaderUtil.getString(e,s.YamlKeys.unit),c.valueConstraints.defaultValue=n.ReaderUtil.getNumericDefault(e,s.YamlKeys.default),l.NumericDefaultValueValidator.assertValid(c.valueConstraints.numberType,c.valueConstraints.defaultValue,c.valueConstraints.minValue,c.valueConstraints.maxValue),c}}t.YamlFieldReaderNumeric=c},3292(e,t,r){t.YamlFieldWriterNumeric=void 0;const n=r(5430),a=r(2099),i=r(6444);class s extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){i.NumericDefaultValueValidator.assertValid(t.valueConstraints.numberType,t.valueConstraints.defaultValue,t.valueConstraints.minValue,t.valueConstraints.maxValue),e[a.YamlKeys.datatype]=this.atomicWriter.write(t.valueConstraints.numberType),null!=t.valueConstraints.minValue&&(e[a.YamlKeys.minValue]=t.valueConstraints.minValue),null!=t.valueConstraints.maxValue&&(e[a.YamlKeys.maxValue]=t.valueConstraints.maxValue),null!=t.valueConstraints.decimalPlaces&&(e[a.YamlKeys.decimalPlaces]=t.valueConstraints.decimalPlaces),null!=t.valueConstraints.unitOfMeasure&&(e[a.YamlKeys.unit]=t.valueConstraints.unitOfMeasure),null!=t.valueConstraints.defaultValue&&(e[a.YamlKeys.default]=t.valueConstraints.defaultValue)}}t.YamlFieldWriterNumeric=s},1468(e,t,r){t.JsonFieldReaderPhoneNumber=void 0;const n=r(4385),a=r(7459);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.PhoneNumberFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderPhoneNumber=i},6876(e,t,r){t.JsonFieldWriterPhoneNumber=void 0;const n=r(2748);class a extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.JsonFieldWriterPhoneNumber=a},8084(e,t,r){t.PhoneNumberFieldBuilderImpl=void 0;const n=r(3350),a=r(7459);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.PhoneNumberFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.PhoneNumberFieldBuilderImpl=i},7459(e,t,r){t.PhoneNumberFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.PHONE_NUMBER,this.valueConstraints=new s.ValueConstraints,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.PhoneNumberFieldImpl=l},4329(e,t,r){t.YamlFieldReaderPhoneNumber=void 0;const n=r(5675),a=r(7459);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.PhoneNumberFieldImpl.buildEmpty()}}t.YamlFieldReaderPhoneNumber=i},9821(e,t,r){t.YamlFieldWriterPhoneNumber=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterPhoneNumber=a},9053(e,t,r){t.JsonFieldReaderRadio=void 0;const n=r(8748),a=r(936),i=r(3315),s=r(4385),o=r(8618);class l extends s.JsonTemplateFieldTypeSpecificReader{read(e,t,r,s){const l=o.RadioFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const c=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=c){const e=n.ReaderUtil.getNodeList(c,a.CedarModel.literals);null!==e&&e.forEach(e=>{const t=n.ReaderUtil.getString(e,a.CedarModel.label),r=n.ReaderUtil.getBoolean(e,a.CedarModel.selectedByDefault);if(null!=t){const e=new i.RadioOption(t,r);l.valueConstraints.literals.push(e)}})}return l}}t.JsonFieldReaderRadio=l},9309(e,t,r){t.JsonFieldWriterRadio=void 0;const n=r(936),a=r(2748);class i extends a.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){this.expandLiterals(t,e),super.expandValueConstraintsNode(e,t,r),e[n.CedarModel.multipleChoice]=!1}}t.JsonFieldWriterRadio=i},2875(e,t,r){t.RadioFieldBuilderImpl=void 0;const n=r(3350),a=r(3315),i=r(8618);class s extends n.TemplateFieldBuilder{literals=[];constructor(){super()}static create(){return new s}addRadioOption(e,t=!1){return this.literals.push(new a.RadioOption(e,t)),this}build(){const e=i.RadioFieldImpl.buildEmpty();super.buildInternal(e);let t=-1;for(let e=this.literals.length-1;e>=0;e--)if(this.literals[e].selectedByDefault){t=e;break}return-1!==t&&this.literals.forEach((e,r)=>{e.selectedByDefault=r===t}),e.valueConstraints.literals=this.literals,e}}t.RadioFieldBuilderImpl=s},8618(e,t,r){t.RadioFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(9931),o=r(587);class l extends n.TemplateField{valueConstraints;constructor(){super(),this.cedarFieldType=a.CedarFieldType.RADIO,this.valueConstraints=new s.ValueConstraintsRadioField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}isSingleInstanceByDefinition(){return!0}createDeploymentBuilder(e){return new o.ChildDeploymentInfoAlwaysSingleBuilder(this,e)}}t.RadioFieldImpl=l},3315(e,t,r){t.RadioOption=void 0;const n=r(7282);class a extends n.ChoiceOptionEntity{constructor(e,t){super(e,t)}}t.RadioOption=a},9931(e,t,r){t.ValueConstraintsRadioField=void 0;const n=r(4328);class a extends n.ValueConstraints{literals=[];constructor(){super()}}t.ValueConstraintsRadioField=a},4284(e,t,r){t.YamlFieldReaderRadio=void 0;const n=r(8748),a=r(3315),i=r(5675),s=r(2099),o=r(8618);class l extends i.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const l=o.RadioFieldImpl.buildEmpty(),c=n.ReaderUtil.getNodeList(e,s.YamlKeys.values);return null!==c&&c.forEach(e=>{const t=n.ReaderUtil.getString(e,s.YamlKeys.label),r=n.ReaderUtil.getBoolean(e,s.YamlKeys.selected);if(null!=t){const e=new a.RadioOption(t,r);l.valueConstraints.literals.push(e)}}),l}}t.YamlFieldReaderRadio=l},8136(e,t,r){t.YamlFieldWriterRadio=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){this.expandLiterals(t,e)}}t.YamlFieldWriterRadio=a},9315(e,t,r){t.JsonFieldReaderTemporal=void 0;const n=r(8748),a=r(936),i=r(8588),s=r(3764),o=r(7974),l=r(4385),c=r(964),d=r(6342);class u extends l.JsonTemplateFieldTypeSpecificReader{read(e,t,r,l){const u=c.TemporalFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const m=n.ReaderUtil.getNode(e,a.CedarModel.ui);null!=m&&(u.temporalGranularity=o.TemporalGranularity.forValue(n.ReaderUtil.getString(m,a.CedarModel.temporalGranularity)),u.inputTimeFormat=s.TimeFormat.forValue(n.ReaderUtil.getString(m,a.CedarModel.inputTimeFormat)),u.timezoneEnabled=n.ReaderUtil.getBoolean(m,a.CedarModel.timezoneEnabled));const p=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=p){const e=n.ReaderUtil.getString(p,a.CedarModel.temporalType);null!==e&&(u.valueConstraints.temporalType=i.TemporalType.forValue(e)),u.valueConstraints.defaultValue=n.ReaderUtil.getString(p,a.CedarModel.defaultValue),d.TemporalDefaultValueValidator.assertValid(u.valueConstraints.temporalType,u.temporalGranularity,u.valueConstraints.defaultValue)}return u}}t.JsonFieldReaderTemporal=u},5459(e,t,r){t.JsonFieldWriterTemporal=void 0;const n=r(936),a=r(3764),i=r(7974),s=r(2748),o=r(2733),l=r(6342);class c extends s.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandUINode(e,t,r){super.expandUINode(e,t,r),t.temporalGranularity!==i.TemporalGranularity.NULL&&(e[n.CedarModel.temporalGranularity]=this.atomicWriter.write(t.temporalGranularity)),i.TemporalGranularity.hasTime(t.temporalGranularity)&&(t.inputTimeFormat!==a.TimeFormat.NULL&&(e[n.CedarModel.inputTimeFormat]=this.atomicWriter.write(t.inputTimeFormat)),e[n.CedarModel.timezoneEnabled]=t.timezoneEnabled)}expandValueConstraintsNode(e,t,r){l.TemporalDefaultValueValidator.assertValid(t.valueConstraints.temporalType,t.temporalGranularity,t.valueConstraints.defaultValue),e[n.CedarModel.temporalType]=this.atomicWriter.write(t.valueConstraints.temporalType),null!=t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[n.CedarModel.defaultValue]=t.valueConstraints.defaultValue),super.expandValueConstraintsNode(e,t,r)}expandRequiredNode(e){e[o.JsonSchema.required]=[o.JsonSchema.atValue,o.JsonSchema.atType]}}t.JsonFieldWriterTemporal=c},6342(e,t,r){t.TemporalDefaultValueValidator=void 0;const n=r(7974),a=r(8588);t.TemporalDefaultValueValidator=class{static zone="(?:Z|[+-](?:(?:0\\d|1[0-3]):[0-5]\\d|14:00))?";static hour="(?:[01]\\d|2[0-3])";static minute="[0-5]\\d";static second="[0-5]\\d";static assertValid(e,t,r){if(null===r||""===r)return;const n=e.getValue();if(null===n)throw new Error("Temporal default requires a temporal datatype.");if(!this.isCompatibleGranularity(e,t))throw new Error(`Temporal datatype ${n} is not compatible with ${t.getValue()} granularity.`);const i=this.datePattern(t,n===a.TemporalType.DATE.getValue()),s=this.timePattern(t);let o;if(o=n===a.TemporalType.DATE.getValue()?i:n===a.TemporalType.TIME.getValue()?s:this.dateTimePattern(t),!o.test(r)||!this.hasValidCalendarDate(r))throw new Error(`Temporal default "${r}" is not valid for ${n}`+(null===t.getValue()?".":` at ${t.getValue()} granularity.`))}static isCompatibleGranularity(e,t){return t===n.TemporalGranularity.NULL||(e===a.TemporalType.DATE?[n.TemporalGranularity.YEAR,n.TemporalGranularity.MONTH,n.TemporalGranularity.DAY].includes(t):e===a.TemporalType.TIME?n.TemporalGranularity.valuesWithTimes().includes(t):[n.TemporalGranularity.DAY,...n.TemporalGranularity.valuesWithTimes()].includes(t))}static datePattern(e,t){return e===n.TemporalGranularity.YEAR?/^\d{4}$/:e===n.TemporalGranularity.MONTH?/^\d{4}-(?:0[1-9]|1[0-2])$/:e!==n.TemporalGranularity.DAY&&t?/^\d{4}(?:-(?:0[1-9]|1[0-2])(?:-(?:0[1-9]|[12]\d|3[01]))?)?$/:/^\d{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[12]\d|3[01])$/}static timePattern(e){const t=this.zone,r=this.hour,a=this.minute,i=this.second;return e===n.TemporalGranularity.HOUR?new RegExp(`^${r}${t}$`):e===n.TemporalGranularity.MINUTE?new RegExp(`^${r}:${a}${t}$`):e===n.TemporalGranularity.SECOND?new RegExp(`^${r}:${a}:${i}${t}$`):e===n.TemporalGranularity.DECIMAL_SECOND?new RegExp(`^${r}:${a}:${i}\\.\\d+${t}$`):new RegExp(`^${r}(?::${a}(?::${i}(?:\\.\\d+)?)?)?${t}$`)}static dateTimePattern(e){const t="\\d{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[12]\\d|3[01])";return e===n.TemporalGranularity.HOUR||e===n.TemporalGranularity.MINUTE||e===n.TemporalGranularity.SECOND||e===n.TemporalGranularity.DECIMAL_SECOND?new RegExp(`^${t}T${this.timePatternSource(e)}$`):e===n.TemporalGranularity.YEAR||e===n.TemporalGranularity.MONTH?/a^/:e===n.TemporalGranularity.DAY?new RegExp(`^${t}$`):new RegExp(`^${t}(?:T${this.timePatternSource(n.TemporalGranularity.NULL)})?$`)}static timePatternSource(e){return this.timePattern(e).source.replace(/^\^|\$$/g,"")}static hasValidCalendarDate(e){const t=/^(\d{4})-(\d{2})-(\d{2})/.exec(e);if(null===t)return!0;const r=Number(t[1]),n=Number(t[2]);return Number(t[3])<=[31,r%4!=0||r%100==0&&r%400!=0?28:29,31,30,31,30,31,31,30,31,30,31][n-1]}}},345(e,t,r){t.TemporalFieldBuilderImpl=void 0;const n=r(3350),a=r(3764),i=r(7974),s=r(8588),o=r(964),l=r(6342);class c extends n.TemplateFieldBuilder{timezoneEnabled=!1;inputTimeFormat=a.TimeFormat.NULL;temporalGranularity=i.TemporalGranularity.NULL;temporalType=s.TemporalType.DATETIME;defaultValue=null;constructor(){super()}static create(){return new c}withTimezoneEnabled(e){return this.timezoneEnabled=e,this}withInputTimeFormat(e){return this.inputTimeFormat=e,this}withTemporalGranularity(e){return this.temporalGranularity=e,this}withTemporalType(e){return this.temporalType=e,this}withDefaultValue(e){return this.defaultValue=e,this}build(){l.TemporalDefaultValueValidator.assertValid(this.temporalType,this.temporalGranularity,this.defaultValue);const e=o.TemporalFieldImpl.buildEmpty();return super.buildInternal(e),e.timezoneEnabled=this.timezoneEnabled,e.inputTimeFormat=this.inputTimeFormat,e.temporalGranularity=this.temporalGranularity,e.valueConstraints.temporalType=this.temporalType,e.valueConstraints.defaultValue=this.defaultValue,e}}t.TemporalFieldBuilderImpl=c},964(e,t,r){t.TemporalFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(3567),o=r(3764),l=r(7974),c=r(3608);class d extends n.TemplateField{valueConstraints;timezoneEnabled=!1;inputTimeFormat=o.TimeFormat.NULL;temporalGranularity=l.TemporalGranularity.NULL;constructor(){super(),this.cedarFieldType=a.CedarFieldType.TEMPORAL,this.valueConstraints=new s.ValueConstraintsTemporalField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new d}createDeploymentBuilder(e){return new c.ChildDeploymentInfoBuilder(this,e)}}t.TemporalFieldImpl=d},3567(e,t,r){t.ValueConstraintsTemporalField=void 0;const n=r(4328),a=r(8588);class i extends n.ValueConstraints{temporalType=a.TemporalType.DATETIME;defaultValue=null;constructor(){super()}}t.ValueConstraintsTemporalField=i},384(e,t,r){t.YamlFieldReaderTemporal=void 0;const n=r(8748),a=r(8588),i=r(3764),s=r(7974),o=r(5675),l=r(2099),c=r(964),d=r(6342);class u extends o.YamlTemplateFieldTypeSpecificReader{read(e,t,r,o){const u=c.TemporalFieldImpl.buildEmpty();u.temporalGranularity=s.TemporalGranularity.forValue(n.ReaderUtil.getString(e,l.YamlKeys.granularity)),u.inputTimeFormat=i.TimeFormat.forValue(n.ReaderUtil.getString(e,l.YamlKeys.inputTimeFormat)),u.timezoneEnabled=n.ReaderUtil.getBoolean(e,l.YamlKeys.inputTimeZone);const m=n.ReaderUtil.getString(e,l.YamlKeys.datatype);return null!==m&&(u.valueConstraints.temporalType=a.TemporalType.forValue(m)),u.valueConstraints.defaultValue=n.ReaderUtil.getString(e,l.YamlKeys.default),d.TemporalDefaultValueValidator.assertValid(u.valueConstraints.temporalType,u.temporalGranularity,u.valueConstraints.defaultValue),u}}t.YamlFieldReaderTemporal=u},7436(e,t,r){t.YamlFieldWriterTemporal=void 0;const n=r(3764),a=r(7974),i=r(5430),s=r(2099),o=r(6342);class l extends i.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){o.TemporalDefaultValueValidator.assertValid(t.valueConstraints.temporalType,t.temporalGranularity,t.valueConstraints.defaultValue),e[s.YamlKeys.datatype]=this.atomicWriter.write(t.valueConstraints.temporalType),t.temporalGranularity!==a.TemporalGranularity.NULL?(e[s.YamlKeys.granularity]=this.atomicWriter.write(t.temporalGranularity),null!=t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[s.YamlKeys.default]=t.valueConstraints.defaultValue),t.temporalGranularity!==a.TemporalGranularity.YEAR&&t.temporalGranularity!==a.TemporalGranularity.MONTH&&t.temporalGranularity!==a.TemporalGranularity.DAY&&(t.inputTimeFormat!==n.TimeFormat.NULL&&(e[s.YamlKeys.inputTimeFormat]=this.atomicWriter.write(t.inputTimeFormat)),t.timezoneEnabled&&(e[s.YamlKeys.inputTimeZone]=t.timezoneEnabled))):null!=t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[s.YamlKeys.default]=t.valueConstraints.defaultValue)}}t.YamlFieldWriterTemporal=l},9683(e,t,r){t.JsonFieldReaderTextArea=void 0;const n=r(4385),a=r(5450),i=r(8748),s=r(936);class o extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const o=a.TextAreaImpl.buildEmpty();this.readRequiredAndHidden(e,t);const l=i.ReaderUtil.getNode(e,s.CedarModel.valueConstraints);return null!=l&&(o.valueConstraints.defaultValue=i.ReaderUtil.getString(l,s.CedarModel.defaultValue)),o}}t.JsonFieldReaderTextArea=o},275(e,t,r){t.JsonFieldWriterTextArea=void 0;const n=r(2748),a=r(936);class i extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){null!==t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[a.CedarModel.defaultValue]=t.valueConstraints.defaultValue),super.expandValueConstraintsNode(e,t,r)}}t.JsonFieldWriterTextArea=i},1259(e,t,r){t.TextAreaBuilderImpl=void 0;const n=r(3350),a=r(5450);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.TextAreaImpl.buildEmpty();return super.buildInternal(e),e}}t.TextAreaBuilderImpl=i},5450(e,t,r){t.TextAreaImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(3608),o=r(5923);class l extends n.TemplateField{valueConstraints;constructor(){super(),this.cedarFieldType=a.CedarFieldType.TEXTAREA,this.valueConstraints=new o.ValueConstraintsTextArea,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new s.ChildDeploymentInfoBuilder(this,e)}}t.TextAreaImpl=l},5923(e,t,r){t.ValueConstraintsTextArea=void 0;const n=r(4328);class a extends n.ValueConstraints{defaultValue=null;constructor(){super()}}t.ValueConstraintsTextArea=a},3168(e,t,r){t.YamlFieldReaderTextArea=void 0;const n=r(5675),a=r(5450);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.TextAreaImpl.buildEmpty()}}t.YamlFieldReaderTextArea=i},836(e,t,r){t.YamlFieldWriterTextArea=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterTextArea=a},9241(e,t,r){t.JsonFieldReaderTextField=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(8972);class o extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.TextFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const l=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);return null!=l&&(o.valueConstraints.defaultValue=n.ReaderUtil.getString(l,a.CedarModel.defaultValue),o.valueConstraints.minLength=n.ReaderUtil.getNumber(l,a.CedarModel.minLength),o.valueConstraints.maxLength=n.ReaderUtil.getNumber(l,a.CedarModel.maxLength),o.valueConstraints.regex=n.ReaderUtil.getString(l,a.CedarModel.regex)),o}}t.JsonFieldReaderTextField=o},7501(e,t,r){t.JsonFieldWriterTextField=void 0;const n=r(936),a=r(2748);class i extends a.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){null!==t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[n.CedarModel.defaultValue]=t.valueConstraints.defaultValue),null!==t.valueConstraints.minLength&&(e[n.CedarModel.minLength]=t.valueConstraints.minLength),null!==t.valueConstraints.maxLength&&(e[n.CedarModel.maxLength]=t.valueConstraints.maxLength),super.expandValueConstraintsNode(e,t,r),null!==t.valueConstraints.regex&&(e[n.CedarModel.regex]=t.valueConstraints.regex)}}t.JsonFieldWriterTextField=i},7889(e,t,r){t.TextFieldBuilderImpl=void 0;const n=r(3350),a=r(8972);class i extends n.TemplateFieldBuilder{defaultValue=null;minLength=null;maxLength=null;regex=null;constructor(){super()}static create(){return new i}withDefaultValue(e){return this.defaultValue=e,this}withMinLength(e){return this.minLength=e,this}withMaxLength(e){return this.maxLength=e,this}withRegex(e){return this.regex=e,this}build(){const e=a.TextFieldImpl.buildEmpty();return super.buildInternal(e),e.valueConstraints.defaultValue=this.defaultValue,e.valueConstraints.minLength=this.minLength,e.valueConstraints.maxLength=this.maxLength,e.valueConstraints.regex=this.regex,e}}t.TextFieldBuilderImpl=i},8972(e,t,r){t.TextFieldImpl=void 0;const n=r(9129),a=r(9711),i=r(4869),s=r(2763),o=r(3608);class l extends n.TemplateField{valueConstraints;valueRecommendationEnabled=!1;constructor(){super(),this.cedarFieldType=i.CedarFieldType.TEXT,this.valueConstraints=new a.ValueConstraintsTextField,this.cedarArtifactType=s.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}supportsValueRecommendation(){return!0}}t.TextFieldImpl=l},9711(e,t,r){t.ValueConstraintsTextField=void 0;const n=r(4328);class a extends n.ValueConstraints{defaultValue=null;minLength=null;maxLength=null;regex=null;constructor(){super()}}t.ValueConstraintsTextField=a},1268(e,t,r){t.YamlFieldReaderTextField=void 0;const n=r(8748),a=r(5675),i=r(2099),s=r(8972);class o extends a.YamlTemplateFieldTypeSpecificReader{read(e,t,r,a){const o=s.TextFieldImpl.buildEmpty();return o.valueConstraints.defaultValue=n.ReaderUtil.getString(e,i.YamlKeys.default),o.valueConstraints.minLength=n.ReaderUtil.getNumber(e,i.YamlKeys.minLength),o.valueConstraints.maxLength=n.ReaderUtil.getNumber(e,i.YamlKeys.maxLength),o.valueConstraints.regex=n.ReaderUtil.getString(e,i.YamlKeys.regex),o}}t.YamlFieldReaderTextField=o},6116(e,t,r){t.YamlFieldWriterTextField=void 0;const n=r(5430),a=r(2099);class i extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){null!=t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[a.YamlKeys.default]=t.valueConstraints.defaultValue),null!=t.valueConstraints.minLength&&(e[a.YamlKeys.minLength]=t.valueConstraints.minLength),null!=t.valueConstraints.maxLength&&(e[a.YamlKeys.maxLength]=t.valueConstraints.maxLength),null!=t.valueConstraints.regex&&(e[a.YamlKeys.regex]=t.valueConstraints.regex)}}t.YamlFieldWriterTextField=i},8053(e,t,r){t.JsonStaticFieldWriter=void 0;const n=r(2748),a=r(2733),i=r(9251),s=r(936),o=r(5793),l=r(5747),c=r(3746),d=r(2475);class u extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandUiNode(e,t){}buildUIObject(e){const t={[s.CedarModel.inputType]:this.atomicWriter.write(e.cedarFieldType.getUiInputType())};return this.expandUiNode(t,e),s.CedarModel.content in t||(t[s.CedarModel.content]=null),{[s.CedarModel.ui]:t}}getAsJsonNode(e){const t=this.buildUIObject(e);return{[a.JsonSchema.atId]:this.atomicWriter.write(e.at_id),[a.JsonSchema.atType]:this.atomicWriter.write(e.cedarArtifactType),[a.JsonSchema.atContext]:this.macroContext(e),[s.CedarModel.type]:this.atomicWriter.write(o.JavascriptType.OBJECT),[l.TemplateProperty.title]:e.title,[l.TemplateProperty.description]:e.description,...t,...this.macroSchemaNameAndDescription(e),...this.macroProvenance(e,this.atomicWriter),...this.macroSkos(e),[a.JsonSchema.schemaVersion]:this.atomicWriter.write(e.schema_schemaVersion),[l.TemplateProperty.additionalProperties]:this.atomicWriter.write(c.AdditionalProperties.FALSE),...this.macroStatusAndVersion(e,this.atomicWriter),[s.CedarModel.schema]:this.atomicWriter.write(d.ArtifactSchema.CURRENT)}}macroContext(e){return i.JsonTemplateFieldContentStatic.CONTEXT_VERBATIM}}t.JsonStaticFieldWriter=u},699(e,t){t.isSizedStaticField=function(e){return null!==e&&"width"in e&&"height"in e}},934(e,t,r){t.YamlStaticFieldWriter=void 0;const n=r(9517),a=r(5430),i=r(455);class s extends a.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandUINodeForYAML(e){return super.expandUINodeForYAML(e)}expandSizeForYAML(e){return n.JsonNode.getEmpty()}buildUIObject(e){return this.expandUINodeForYAML(e)}getYamlAsJsonNode(e,t=i.ChildDeploymentInfo.empty(),r=!1,a=!0){return{...this.macroType(e),...this.macroNameAndDescription(e),...this.macroSchemaIdentifier(e),...this.macroId(e,r,a),...this.macroStatusAndVersion(e,r),...this.macroSkos(e),...this.expandUINodeForYAML(e),...t.hasParent()?n.JsonNode.getEmpty():this.expandSizeForYAML(e),...this.macroProvenance(e,r),...this.macroDerivedFrom(e,r),...this.macroPreviousVersion(e,r),...this.macroAnnotations(e)}}}t.YamlStaticFieldWriter=s},9148(e,t,r){t.JsonFieldReaderImage=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(5573);class o extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.StaticImageFieldImpl.buildEmpty(),l=n.ReaderUtil.getNode(e,a.CedarModel.ui);o.content=n.ReaderUtil.getString(l,a.CedarModel.content);const c=n.ReaderUtil.getNode(l,a.CedarModel.size);return o.width=n.ReaderUtil.getNumber(c,a.CedarModel.width),o.height=n.ReaderUtil.getNumber(c,a.CedarModel.height),o}}t.JsonFieldReaderImage=o},8970(e,t,r){t.JsonFieldWriterStaticImage=void 0;const n=r(9517),a=r(936),i=r(8053);class s extends i.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){if(null!==t.content&&(e[a.CedarModel.content]=t.content),null!==t.width||null!==t.height){const r=n.JsonNode.getEmpty();null!==t.width&&(r[a.CedarModel.width]=t.width),null!==t.height&&(r[a.CedarModel.height]=t.height),e[a.CedarModel.size]=r}}}t.JsonFieldWriterStaticImage=s},3138(e,t,r){t.StaticImageFieldBuilderImpl=void 0;const n=r(3350),a=r(5573);class i extends n.TemplateFieldBuilder{content=null;width=null;height=null;constructor(){super()}static create(){return new i}withContent(e){return this.content=e,this}withWidth(e){return this.width=e,this}withHeight(e){return this.height=e,this}build(){const e=a.StaticImageFieldImpl.buildEmpty();return super.buildInternal(e),e.content=this.content,e.width=this.width,e.height=this.height,e}}t.StaticImageFieldBuilderImpl=i},5573(e,t,r){t.StaticImageFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{content=null;width=null;height=null;constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_IMAGE,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticImageFieldImpl=o},7941(e,t,r){t.YamlFieldReaderImage=void 0;const n=r(8748),a=r(2099),i=r(5675),s=r(5573);class o extends i.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.StaticImageFieldImpl.buildEmpty();return o.content=n.ReaderUtil.getString(e,a.YamlKeys.content),o.width=n.ReaderUtil.getNumber(e,a.YamlKeys.width),o.height=n.ReaderUtil.getNumber(e,a.YamlKeys.height),o}}t.YamlFieldReaderImage=o},4935(e,t,r){t.YamlFieldWriterStaticImage=void 0;const n=r(9517),a=r(934),i=r(2099);class s extends a.YamlStaticFieldWriter{constructor(e,t){super(e,t)}expandUINodeForYAML(e){const t=n.JsonNode.getEmpty();return null!==e.content&&(t[i.YamlKeys.content]=e.content),t}expandSizeForYAML(e){const t=n.JsonNode.getEmpty();return null!==e.width&&(t[i.YamlKeys.width]=e.width),null!==e.height&&(t[i.YamlKeys.height]=e.height),t}}t.YamlFieldWriterStaticImage=s},5933(e,t,r){t.JsonFieldReaderPageBreak=void 0;const n=r(4385),a=r(9046);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.StaticPageBreakFieldImpl.buildEmpty()}}t.JsonFieldReaderPageBreak=i},2347(e,t,r){t.JsonFieldWriterStaticPageBreak=void 0;const n=r(8053);class a extends n.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){}}t.JsonFieldWriterStaticPageBreak=a},2703(e,t,r){t.StaticPageBreakFieldBuilderImpl=void 0;const n=r(3350),a=r(9046);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.StaticPageBreakFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.StaticPageBreakFieldBuilderImpl=i},9046(e,t,r){t.StaticPageBreakFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_PAGE_BREAK,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticPageBreakFieldImpl=o},4568(e,t,r){t.YamlFieldReaderPageBreak=void 0;const n=r(5675),a=r(9046);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.StaticPageBreakFieldImpl.buildEmpty()}}t.YamlFieldReaderPageBreak=i},7594(e,t,r){t.YamlFieldWriterStaticPageBreak=void 0;const n=r(934);class a extends n.YamlStaticFieldWriter{constructor(e,t){super(e,t)}}t.YamlFieldWriterStaticPageBreak=a},6291(e,t,r){t.JsonFieldReaderRichText=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(5548);class o extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.StaticRichTextFieldImpl.buildEmpty(),l=n.ReaderUtil.getNode(e,a.CedarModel.ui);return o.content=n.ReaderUtil.getString(l,a.CedarModel.content),o}}t.JsonFieldReaderRichText=o},6029(e,t,r){t.JsonFieldWriterStaticRichText=void 0;const n=r(936),a=r(8053);class i extends a.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){null!==t.content&&(e[n.CedarModel.content]=t.content)}}t.JsonFieldWriterStaticRichText=i},9521(e,t,r){t.StaticRichTextFieldBuilderImpl=void 0;const n=r(3350),a=r(5548);class i extends n.TemplateFieldBuilder{content=null;constructor(){super()}static create(){return new i}withContent(e){return this.content=e,this}build(){const e=a.StaticRichTextFieldImpl.buildEmpty();return super.buildInternal(e),e.content=this.content,e}}t.StaticRichTextFieldBuilderImpl=i},5548(e,t,r){t.StaticRichTextFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{content=null;constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_RICH_TEXT,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticRichTextFieldImpl=o},1404(e,t,r){t.YamlFieldReaderRichText=void 0;const n=r(8748),a=r(5675),i=r(2099),s=r(5548);class o extends a.YamlTemplateFieldTypeSpecificReader{read(e,t,r,a){const o=s.StaticRichTextFieldImpl.buildEmpty();return o.content=n.ReaderUtil.getString(e,i.YamlKeys.content),o}}t.YamlFieldReaderRichText=o},6314(e,t,r){t.YamlFieldWriterStaticRichText=void 0;const n=r(9517),a=r(934),i=r(2099);class s extends a.YamlStaticFieldWriter{constructor(e,t){super(e,t)}expandUINodeForYAML(e){return null!==e.content?{[i.YamlKeys.content]:e.content}:n.JsonNode.getEmpty()}}t.YamlFieldWriterStaticRichText=s},6511(e,t,r){t.JsonFieldReaderSectionBreak=void 0;const n=r(4385),a=r(2546);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.StaticSectionBreakFieldImpl.buildEmpty()}}t.JsonFieldReaderSectionBreak=i},41(e,t,r){t.JsonFieldWriterStaticSectionsBreak=void 0;const n=r(8053);class a extends n.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){}}t.JsonFieldWriterStaticSectionsBreak=a},5795(e,t,r){t.StaticSectionBreakFieldBuilderImpl=void 0;const n=r(3350),a=r(2546);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.StaticSectionBreakFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.StaticSectionBreakFieldBuilderImpl=i},2546(e,t,r){t.StaticSectionBreakFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_SECTION_BREAK,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticSectionBreakFieldImpl=o},3980(e,t,r){t.YamlFieldReaderSectionBreak=void 0;const n=r(5675),a=r(2546);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.StaticSectionBreakFieldImpl.buildEmpty()}}t.YamlFieldReaderSectionBreak=i},6082(e,t,r){t.YAMLFieldWriterStaticSectionsBreak=void 0;const n=r(934);class a extends n.YamlStaticFieldWriter{constructor(e,t){super(e,t)}}t.YAMLFieldWriterStaticSectionsBreak=a},8596(e,t,r){t.JsonFieldReaderYoutube=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(477);class o extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.StaticYoutubeFieldImpl.buildEmpty(),l=n.ReaderUtil.getNode(e,a.CedarModel.ui);o.videoId=n.ReaderUtil.getString(l,a.CedarModel.content);const c=n.ReaderUtil.getNode(l,a.CedarModel.size);return o.width=n.ReaderUtil.getNumber(c,a.CedarModel.width),o.height=n.ReaderUtil.getNumber(c,a.CedarModel.height),o}}t.JsonFieldReaderYoutube=o},6766(e,t,r){t.JsonFieldWriterStaticYoutube=void 0;const n=r(9517),a=r(936),i=r(8053);class s extends i.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){if(null!==t.videoId&&(e[a.CedarModel.content]=t.videoId),null!==t.width||null!==t.height){const r=n.JsonNode.getEmpty();null!==t.width&&(r[a.CedarModel.width]=t.width),null!==t.height&&(r[a.CedarModel.height]=t.height),e[a.CedarModel.size]=r}}}t.JsonFieldWriterStaticYoutube=s},7674(e,t,r){t.StaticYoutubeFieldBuilderImpl=void 0;const n=r(3350),a=r(477);class i extends n.TemplateFieldBuilder{videoId=null;width=null;height=null;constructor(){super()}static create(){return new i}withVideoId(e){return this.videoId=e,this}withWidth(e){return this.width=e,this}withHeight(e){return this.height=e,this}build(){const e=a.StaticYoutubeFieldImpl.buildEmpty();return super.buildInternal(e),e.videoId=this.videoId,e.width=this.width,e.height=this.height,e}}t.StaticYoutubeFieldBuilderImpl=i},477(e,t,r){t.StaticYoutubeFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{videoId=null;width=null;height=null;constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_YOUTUBE,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticYoutubeFieldImpl=o},7089(e,t,r){t.YamlFieldReaderYoutube=void 0;const n=r(8748),a=r(5675),i=r(2099),s=r(477);class o extends a.YamlTemplateFieldTypeSpecificReader{read(e,t,r,a){const o=s.StaticYoutubeFieldImpl.buildEmpty();return o.videoId=n.ReaderUtil.getString(e,i.YamlKeys.content),o.width=n.ReaderUtil.getNumber(e,i.YamlKeys.width),o.height=n.ReaderUtil.getNumber(e,i.YamlKeys.height),o}}t.YamlFieldReaderYoutube=o},1903(e,t,r){t.YamlFieldWriterStaticYoutube=void 0;const n=r(9517),a=r(934),i=r(2099);class s extends a.YamlStaticFieldWriter{constructor(e,t){super(e,t)}expandUINodeForYAML(e){const t=n.JsonNode.getEmpty();return null!==e.videoId&&(t[i.YamlKeys.content]=e.videoId),t}expandSizeForYAML(e){const t=n.JsonNode.getEmpty();return null!==e.width&&(t[i.YamlKeys.width]=e.width),null!==e.height&&(t[i.YamlKeys.height]=e.height),t}}t.YamlFieldWriterStaticYoutube=s},4033(e,t,r){t.AttributeValueNamePolicy=void 0;const n=r(936),a=r(2733),i=r(9327),s=r(3644),o=r(7723);class l{static RESERVED_NAMES=new Set([a.JsonSchema.atContext,a.JsonSchema.atId,a.JsonSchema.atType,a.JsonSchema.atValue,a.JsonSchema.atLanguage,a.JsonSchema.schemaIsBasedOn,a.JsonSchema.schemaName,a.JsonSchema.schemaDescription,a.JsonSchema.pavDerivedFrom,a.JsonSchema.pavCreatedOn,a.JsonSchema.pavCreatedBy,a.JsonSchema.pavLastUpdatedOn,a.JsonSchema.oslcModifiedBy,a.JsonSchema.rdfsLabel,n.CedarModel.skosPrefLabel,n.CedarModel.skosAltLabel,n.CedarModel.skosNotation,n.CedarModel.annotations]);constructor(){}static isReserved(e){return e.startsWith("@")||l.RESERVED_NAMES.has(e)}static findConflicts(e){const t=[];return l.scanContainer(e,[],t),t}static assertValid(e){const t=l.findConflicts(e)[0];if(void 0===t)return;const r=[...t.path,t.groupName,t.name].join("/"),n="reserved"===t.kind?"is reserved for instance metadata":"sibling"===t.kind?"collides with another child in the same object":`is also used by attribute-value field "${t.conflictingGroupName}"`;throw new Error(`Attribute-value name "${t.name}" at /${r} ${n}`)}static scanContainer(e,t,r){const n=l.attributeValueGroups(e),a=new Set(n.map(e=>e.name)),i=new Set(n.filter(e=>e.unpacked).flatMap(e=>e.attributeNames)),s=new Set(Object.keys(e.values).filter(e=>!a.has(e)&&!i.has(e))),o=new Map;for(const e of n){const n=new Set;for(const i of e.attributeNames){if(0===i.length)continue;l.isReserved(i)&&r.push({kind:"reserved",name:i,groupName:e.name,path:t}),(s.has(i)||a.has(i))&&r.push({kind:"sibling",name:i,groupName:e.name,path:t}),n.has(i)?r.push({kind:"duplicate",name:i,groupName:e.name,path:t,conflictingGroupName:e.name}):n.add(i);const c=o.get(i);void 0!==c&&c!==e.name?r.push({kind:"duplicate",name:i,groupName:e.name,path:t,conflictingGroupName:c}):o.set(i,e.name)}}for(const[n,s]of Object.entries(e.values))a.has(n)||i.has(n)||l.scanValue(s,[...t,n],r)}static scanValue(e,t,r){e instanceof o.InstanceDataContainer?l.scanContainer(e,t,r):Array.isArray(e)&&e.forEach((e,n)=>l.scanValue(e,[...t,n],r))}static attributeValueGroups(e){const t=[];for(const[r,n]of Object.entries(e.values))if(n instanceof i.InstanceDataAttributeValueField)t.push({name:r,attributeNames:Object.keys(n.values),unpacked:!1});else if(Array.isArray(n)){const e=n.filter(e=>e instanceof s.InstanceDataAttributeValueFieldName).map(e=>e.name);e.length>0&&t.push({name:r,attributeNames:e,unpacked:!0})}return t}}t.AttributeValueNamePolicy=l},9327(e,t){t.InstanceDataAttributeValueField=void 0,t.InstanceDataAttributeValueField=class{_name;_values={};_iris;constructor(e){this._name=e,this._values={},this._iris={}}addValue(e,t){this._values[e]=t}get name(){return this._name}get values(){return this._values}setIri(e,t){this._iris[e]=t}get iris(){return this._iris}}},3644(e,t){t.InstanceDataAttributeValueFieldName=void 0,t.InstanceDataAttributeValueFieldName=class{_name;constructor(e){this._name=e}get name(){return this._name}}},7723(e,t){t.InstanceDataContainer=void 0,t.InstanceDataContainer=class{_id=null;_values;_iris;constructor(){this._values={},this._iris={}}setValue(e,t){this._values[e]=t}hasValue(e){return Object.hasOwn(this._values,e)}removeValue(e){delete this._values[e],delete this._iris[e]}get values(){return this._values}set values(e){this._values=e}setIri(e,t){this._iris[e]=t}hasIri(e){return Object.hasOwn(this._iris,e)}removeIri(e){delete this._iris[e]}get iris(){return this._iris}set id(e){this._id=e}get id(){return this._id}}},8193(e,t,r){t.InstanceDataControlledAtom=void 0;const n=r(7571);class a{_id;_label;constructor(e,t,r){if(r!==n.PARSED_NODE&&((0,n.assertIri)(e,"InstanceDataControlledAtom"),null==t||""===t))throw new Error("InstanceDataControlledAtom requires a label. An IRI on its own is a link, not a controlled term.");this._id=e,this._label=t}static fromParsedNode(e,t){return new a(e,t,n.PARSED_NODE)}get id(){return this._id}get label(){return this._label}}t.InstanceDataControlledAtom=a},7548(e,t){t.InstanceDataEmptyAtom=void 0,t.InstanceDataEmptyAtom=class{_discarded;constructor(e=null){this._discarded=e}get discarded(){return this._discarded}hasDiscardedContent(){return null!==this._discarded&&Object.keys(this._discarded).length>0}}},4465(e,t){t.InstanceDataEmptyNode=void 0,t.InstanceDataEmptyNode=class{}},7571(e,t){function r(e,t){if(null==e||""===e)throw new Error(`${t} requires an IRI. An IRI-valued field with nothing in it is an empty node, not a null IRI.`)}t.InstanceDataLinkAtom=t.PARSED_NODE=void 0,t.assertIri=r,t.PARSED_NODE=Symbol("parsed node");class n{_id;constructor(e,n){n!==t.PARSED_NODE&&r(e,"InstanceDataLinkAtom"),this._id=e}static fromParsedNode(e){return new n(e,t.PARSED_NODE)}get id(){return this._id}}t.InstanceDataLinkAtom=n},5222(e,t){t.InstanceDataStringAtom=void 0,t.InstanceDataStringAtom=class{_value;constructor(e){this._value=e}get value(){return this._value}}},4877(e,t){t.InstanceDataTypedAtom=void 0,t.InstanceDataTypedAtom=class{_value;_type;constructor(e,t){if(null==t||""===t)throw new Error("InstanceDataTypedAtom requires a type. A literal with no declared type is an InstanceDataStringAtom.");this._value=e,this._type=t}get value(){return this._value}get type(){return this._type}}},9961(e,t,r){t.InstanceInflater=void 0;const n=r(7723),a=r(4465),i=r(2763),s=r(4869),o=r(7661),l=r(9129);class c{constructor(){}static inflate(e,t){return c.inflateContainer(e.dataContainer,t),e}static inflateContainer(e,t){const r=t.getChildrenInfo(),d=r.getChildIriMap();Object.keys(d).forEach(t=>e.setIri(t,d[t]));const u={};r.getChildrenNames().forEach(r=>{const d=t.getChild(r);let m=e.values[r];if(void 0===m){if(t.getChildInfo(r)?.atType===i.CedarArtifactType.STATIC_TEMPLATE_FIELD)return;m=d instanceof l.TemplateField&&d.cedarFieldType===s.CedarFieldType.ATTRIBUTE_VALUE?[]:new a.InstanceDataEmptyNode}d instanceof o.TemplateElement&&(m instanceof n.InstanceDataContainer?c.inflateContainer(m,d):Array.isArray(m)&&m.forEach(e=>{e instanceof n.InstanceDataContainer&&c.inflateContainer(e,d)})),u[r]=m}),Object.keys(e.values).forEach(t=>{Object.hasOwn(u,t)||(u[t]=e.values[t])}),e.values=u}}t.InstanceInflater=c},8410(e,t,r){t.InstanceValidator=void 0;const n=r(7723),a=r(7548),i=r(4465),s=r(5222),o=r(4877),l=r(7571),c=r(8193),d=r(3812),u=r(7661),m=r(964),p=r(4074),h=r(4036),f=r(2888),T=r(9760),y=r(3188),E=r(2733),C=r(9034),g=r(9327),I=r(3644),A=r(4033),b=r(2763),R="InstanceValidator";class S{constructor(){}static validate(e,t){const r=new h.JsonArtifactParsingResult;return S.validateContainer(e.dataContainer,t,new y.JsonPath,r),r}static validateContainer(e,t,r,n){const a=t.getChildrenInfo();for(const t of A.AttributeValueNamePolicy.findConflicts(e).filter(e=>0===e.path.length))n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,r.add(t.groupName,t.name),"a unique, non-reserved attribute-value name",t.name));for(const[t,i]of S.attributeValueGroups(e))for(const e of i){const i=a.get(e);null!==i&&i.atType!==b.CedarArtifactType.STATIC_TEMPLATE_FIELD&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,r.add(t,e),"a name different from every serializable template child",e))}for(const t of a.getChildrenNamesForRequiredInProperties())Object.hasOwn(e.values,t)||n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,r.add(t),t));for(const i of a.getChildrenNames()){const s=a.get(i);if(s?.uiInputType===C.UiInputType.ATTRIBUTE_VALUE)continue;const o=e.values[i];void 0!==o&&S.validateChild(i,o,s,t.getChild(i),r.add(i),n)}}static attributeValueGroups(e){const t=[];for(const[r,n]of Object.entries(e.values))if(n instanceof g.InstanceDataAttributeValueField)t.push([r,Object.keys(n.values)]);else if(Array.isArray(n)){const e=n.filter(e=>e instanceof I.InstanceDataAttributeValueFieldName).map(e=>e.name??"").filter(e=>e.length>0);e.length>0&&t.push([r,e])}return t}static validateChild(e,t,r,n,a,i){const s=r?.isMultiInAnyWay()??!1,o=Array.isArray(t)?t:null,l=null!==o;if(s===l)return null!==o?(S.validateCardinality(o,r,a,i),void o.forEach((e,t)=>S.validateItem(e,n,a.add(t),i))):void S.validateItem(t,n,a,i);i.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,a,s?"a list of values":"a single value",l?"a list of values":"a single value"))}static validateCardinality(e,t,r,n){if(!(t instanceof d.AbstractDynamicChildDeploymentInfo))return;const{minItems:a,maxItems:i}=t;null!==a&&e.length<a&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.MISSING_INDEX_IN_REAL_OBJECT,r,a,e.length)),null!==i&&e.length>i&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.UNEXPECTED_INDEX_IN_REAL_OBJECT,r,i,e.length))}static validateItem(e,t,r,a){if(t instanceof u.TemplateElement)return void(e instanceof n.InstanceDataContainer?S.validateContainer(e,t,r,a):S.isEmpty(e)?S.validateContainer(new n.InstanceDataContainer,t,r,a):a.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,r,"an element","a field value")));S.validateIri(e,r,a);const i=S.declaredValueType(t);null!==i&&S.validateTypedValue(e,i,r,a)}static validateIri(e,t,r){(e instanceof l.InstanceDataLinkAtom||e instanceof c.InstanceDataControlledAtom)&&null===e.id&&r.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,t.add(E.JsonSchema.atId),"an IRI",null))}static declaredValueType(e){return e instanceof m.TemporalFieldImpl?e.valueConstraints.temporalType.getValue():e instanceof p.NumericFieldImpl?e.valueConstraints.numberType.getValue():null}static validateTypedValue(e,t,r,n){S.isEmpty(e)||(e instanceof o.InstanceDataTypedAtom?null!==e.value&&e.type!==t&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,r.add(E.JsonSchema.atType),t,e.type??void 0)):e instanceof s.InstanceDataStringAtom&&null!==e.value&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,r.add(E.JsonSchema.atType),t)))}static isEmpty(e){return e instanceof a.InstanceDataEmptyAtom||e instanceof i.InstanceDataEmptyNode||(e instanceof s.InstanceDataStringAtom||e instanceof o.InstanceDataTypedAtom)&&null===e.value}}t.InstanceValidator=S},2272(e,t,r){t.TemplateInstance=void 0;const n=r(2763),a=r(5697),i=r(7723);class s extends a.AbstractInstanceArtifact{dataContainer;constructor(){super(),this.cedarArtifactType=n.CedarArtifactType.TEMPLATE_INSTANCE,this.dataContainer=new i.InstanceDataContainer}static buildEmptyWithNullValues(){return new s}}t.TemplateInstance=s},4925(e,t,r){t.TemplateInstanceBuilder=void 0;const n=r(1641),a=r(2272),i=r(7723),s=r(8534);class o extends n.AbstractArtifactBuilder{schema_isBasedOn=s.CedarArtifactId.NULL;dataContainer=new i.InstanceDataContainer;withSchemaIsBasedOn(e){return e instanceof s.CedarArtifactId?this.schema_isBasedOn=e:this.schema_isBasedOn=s.CedarArtifactId.forValue(e),this}withDataValue(e,t){return this.dataContainer.setValue(e,t),this}withDataIri(e,t){return this.dataContainer.setIri(e,t),this}withDataId(e){return this.dataContainer.id=e,this}withDataContainer(e){return this.dataContainer=e,this}build(){const e=a.TemplateInstance.buildEmptyWithNullValues();return e.at_id=this.at_id,e.pav_createdOn=this.pav_createdOn,e.pav_createdBy=this.pav_createdBy,e.pav_lastUpdatedOn=this.pav_lastUpdatedOn,e.oslc_modifiedBy=this.oslc_modifiedBy,e.pav_derivedFrom=this.pav_derivedFrom,e.schema_name=this.schema_name,e.schema_description=this.schema_description,e.schema_isBasedOn=this.schema_isBasedOn,e.dataContainer=this.dataContainer,e}}t.TemplateInstanceBuilder=o},3281(e,t,r){t.Template=void 0;const n=r(3910),a=r(8557),i=r(1027),s=r(5451),o=r(2763);class l extends s.AbstractContainerArtifact{header=null;footer=null;constructor(){super(),this.cedarArtifactType=o.CedarArtifactType.TEMPLATE}static buildEmptyWithNullValues(){return new l}static buildEmptyWithDefaultValues(){const e=new l;return e.schema_schemaVersion=a.SchemaVersion.CURRENT,e.bibo_status=n.BiboStatus.DRAFT,e.pav_version=i.PavVersion.DEFAULT,e}isMultiInstanceByDefinition(){return!1}isSingleInstanceByDefinition(){return!1}createDeploymentBuilder(e){throw new Error("Method not supported.")}}t.Template=l},766(e,t,r){t.TemplateBuilder=void 0;const n=r(3281),a=r(1641);class i extends a.AbstractArtifactBuilder{header=null;footer=null;instanceTypeSpecification=null;children=[];withHeader(e){return this.header=e,this}withFooter(e){return this.footer=e,this}withInstanceTypeSpecification(e){return this.instanceTypeSpecification=e,this}addChild(e,t){return this.children.push([e,t]),this}build(){const e=n.Template.buildEmptyWithNullValues();return super.buildInternal(e),e.header=this.header,e.footer=this.footer,e.instanceTypeSpecification=this.instanceTypeSpecification,this.children.forEach(([t,r])=>{e.addChild(t,r)}),e}}t.TemplateBuilder=i},9517(e,t){t.JsonNode=void 0,t.JsonNode=class{static getEmpty(){return{}}static getEmptyList(){return[]}static hasEntries(e){return Object.keys(e).length>0}}},4531(e,t){t.BioportalTermType=t.BioportalTermTypeYamlValues=t.P=void 0,t.P={ONTOLOGY_CLASS:"OntologyClass",VALUE:"Value"},t.BioportalTermTypeYamlValues={ONTOLOGY_CLASS:"class",VALUE:"value"};class r{jsonValue;yamlValue;constructor(e,t){this.jsonValue=e,this.yamlValue=t}getJsonValue(){return this.jsonValue}getYamlValue(){return this.yamlValue}static ONTOLOGY_CLASS=new r(t.P.ONTOLOGY_CLASS,t.BioportalTermTypeYamlValues.ONTOLOGY_CLASS);static VALUE=new r(t.P.VALUE,t.BioportalTermTypeYamlValues.VALUE);static NULL=new r(null,null);static values(){return[r.ONTOLOGY_CLASS,r.VALUE]}static forJsonValue(e){for(const t of r.values())if(t.getJsonValue()===e)return t;return this.NULL}static forYamlValue(e){for(const t of r.values())if(t.getYamlValue()===e)return t;return this.NULL}}t.BioportalTermType=r},8534(e,t){t.CedarArtifactId=void 0;class r{value;constructor(e){this.value=e}getValue(){return this.value}static NULL=new r(null);static forValue(e){return null===e||""===e?r.NULL:new r(e)}}t.CedarArtifactId=r},2763(e,t){t.CedarArtifactType=t.df=t.KW=void 0,t.KW={TEMPLATE:"https://schema.metadatacenter.org/core/Template",TEMPLATE_ELEMENT:"https://schema.metadatacenter.org/core/TemplateElement",TEMPLATE_FIELD:"https://schema.metadatacenter.org/core/TemplateField",STATIC_TEMPLATE_FIELD:"https://schema.metadatacenter.org/core/StaticTemplateField",TEMPLATE_INSTANCE:"TemplateInstance"},t.df={TEMPLATE:"template",TEMPLATE_ELEMENT:"templateElement",TEMPLATE_FIELD:"templateField",STATIC_TEMPLATE_FIELD:"staticTemplateField",TEMPLATE_INSTANCE:"instance"};class r{value;yamlValue;constructor(e,t){this.value=e,this.yamlValue=t}getValue(){return this.value}getYamlValue(){return this.yamlValue}static TEMPLATE=new r(t.KW.TEMPLATE,t.df.TEMPLATE);static TEMPLATE_ELEMENT=new r(t.KW.TEMPLATE_ELEMENT,t.df.TEMPLATE_ELEMENT);static TEMPLATE_FIELD=new r(t.KW.TEMPLATE_FIELD,t.df.TEMPLATE_FIELD);static STATIC_TEMPLATE_FIELD=new r(t.KW.STATIC_TEMPLATE_FIELD,t.df.STATIC_TEMPLATE_FIELD);static TEMPLATE_INSTANCE=new r(t.KW.TEMPLATE_INSTANCE,t.df.TEMPLATE_INSTANCE);static NULL=new r(null,null);static values(){return[r.TEMPLATE,r.TEMPLATE_ELEMENT,r.TEMPLATE_FIELD,r.STATIC_TEMPLATE_FIELD,r.TEMPLATE_INSTANCE]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}static forYamlArtifactType(e){return e.isTemplate()?r.TEMPLATE:e.isElement()?r.TEMPLATE_ELEMENT:e.isDynamicField()?r.TEMPLATE_FIELD:e.isStaticField()?r.STATIC_TEMPLATE_FIELD:e.isTemplateInstance()?r.TEMPLATE_INSTANCE:r.NULL}}t.CedarArtifactType=r},8421(e,t){t.CedarFieldCategory=t.I=void 0,t.I={STATIC:"STATIC-field",DYNAMIC:"DYNAMIC-field",NONE:"NONE"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static values(){return[r.STATIC,r.DYNAMIC,r.NONE]}static STATIC=new r(t.I.STATIC);static DYNAMIC=new r(t.I.DYNAMIC);static NONE=new r(t.I.NONE);static NULL=new r(null)}t.CedarFieldCategory=r},4869(e,t,r){t.CedarFieldType=t.K=void 0;const n=r(9034),a=r(9499);t.K={TEXTFIELD:"DYNAMIC-textfield",TEXTAREA:"DYNAMIC-textarea",CONTROLLED_TERM:"DYNAMIC-controlled-term",LINK:"DYNAMIC-link",EXT_ROR:"DYNAMIC-ext-ror",EXT_ORCID:"DYNAMIC-ext-orcid",EXT_PFAS:"DYNAMIC-ext-pfas",EXT_PUBMED:"DYNAMIC-ext-pubmed",EXT_RRID:"DYNAMIC-ext-rrid",EXT_NIH_GRANT_ID:"DYNAMIC-ext-nih-grant-id",EXT_DOI:"DYNAMIC-ext-doi",TEMPORAL:"DYNAMIC-temporal",EMAIL:"DYNAMIC-email",NUMERIC:"DYNAMIC-numeric",PHONE_NUMBER:"DYNAMIC-phone-number",RADIO:"DYNAMIC-radio",CHECKBOX:"DYNAMIC-checkbox",SINGLE_SELECT_LIST:"DYNAMIC-single-select-list",MULTIPLE_SELECT_LIST:"DYNAMIC-multiple-select-list",ATTRIBUTE_VALUE:"DYNAMIC-attribute-value",STATIC_PAGE_BREAK:"STATIC-page-break",STATIC_SECTION_BREAK:"STATIC-section-break",STATIC_IMAGE:"STATIC-image",STATIC_RICH_TEXT:"STATIC-rich_text",STATIC_YOUTUBE:"STATIC-youtube"};class i{value;_uiInputType;_yamlType;staticField;constructor(e,t,r,n){this.value=e,this._uiInputType=t,this._yamlType=r,this.staticField=n}getValue(){return this.value}getUiInputType(){return this._uiInputType}getYamlType(){return this._yamlType}get isStaticField(){return this.staticField}static values(){return[i.TEXT,i.TEXTAREA,i.CONTROLLED_TERM,i.LINK,i.EXT_ROR,i.EXT_ORCID,i.EXT_PFAS,i.EXT_PUBMED,i.EXT_RRID,i.EXT_NIH_GRANT_ID,i.EXT_DOI,i.TEMPORAL,i.EMAIL,i.NUMERIC,i.PHONE_NUMBER,i.RADIO,i.CHECKBOX,i.SINGLE_SELECT_LIST,i.MULTIPLE_SELECT_LIST,i.ATTRIBUTE_VALUE,i.STATIC_PAGE_BREAK,i.STATIC_SECTION_BREAK,i.STATIC_IMAGE,i.STATIC_RICH_TEXT,i.STATIC_YOUTUBE]}static TEXT=new i(t.K.TEXTFIELD,n.UiInputType.TEXTFIELD,a.YamlArtifactType.TEXTFIELD,!1);static TEXTAREA=new i(t.K.TEXTAREA,n.UiInputType.TEXTAREA,a.YamlArtifactType.TEXTAREA,!1);static CONTROLLED_TERM=new i(t.K.CONTROLLED_TERM,n.UiInputType.TEXTFIELD,a.YamlArtifactType.CONTROLLED_TERM,!1);static LINK=new i(t.K.LINK,n.UiInputType.LINK,a.YamlArtifactType.LINK,!1);static EXT_ROR=new i(t.K.EXT_ROR,n.UiInputType.EXT_ROR,a.YamlArtifactType.EXT_ROR,!1);static EXT_ORCID=new i(t.K.EXT_ORCID,n.UiInputType.EXT_ORCID,a.YamlArtifactType.EXT_ORCID,!1);static EXT_PFAS=new i(t.K.EXT_PFAS,n.UiInputType.EXT_PFAS,a.YamlArtifactType.EXT_PFAS,!1);static EXT_PUBMED=new i(t.K.EXT_PUBMED,n.UiInputType.EXT_PUBMED,a.YamlArtifactType.EXT_PUBMED,!1);static EXT_RRID=new i(t.K.EXT_RRID,n.UiInputType.EXT_RRID,a.YamlArtifactType.EXT_RRID,!1);static EXT_NIH_GRANT_ID=new i(t.K.EXT_NIH_GRANT_ID,n.UiInputType.EXT_NIH_GRANT_ID,a.YamlArtifactType.EXT_NIH_GRANT_ID,!1);static EXT_DOI=new i(t.K.EXT_DOI,n.UiInputType.EXT_DOI,a.YamlArtifactType.EXT_DOI,!1);static TEMPORAL=new i(t.K.TEMPORAL,n.UiInputType.TEMPORAL,a.YamlArtifactType.TEMPORAL,!1);static EMAIL=new i(t.K.EMAIL,n.UiInputType.EMAIL,a.YamlArtifactType.EMAIL,!1);static NUMERIC=new i(t.K.NUMERIC,n.UiInputType.NUMERIC,a.YamlArtifactType.NUMERIC,!1);static PHONE_NUMBER=new i(t.K.PHONE_NUMBER,n.UiInputType.PHONE_NUMBER,a.YamlArtifactType.PHONE_NUMBER,!1);static RADIO=new i(t.K.RADIO,n.UiInputType.RADIO,a.YamlArtifactType.RADIO,!1);static CHECKBOX=new i(t.K.CHECKBOX,n.UiInputType.CHECKBOX,a.YamlArtifactType.CHECKBOX,!1);static SINGLE_SELECT_LIST=new i(t.K.SINGLE_SELECT_LIST,n.UiInputType.LIST,a.YamlArtifactType.SINGLE_SELECT_LIST,!1);static MULTIPLE_SELECT_LIST=new i(t.K.MULTIPLE_SELECT_LIST,n.UiInputType.LIST,a.YamlArtifactType.MULTI_SELECT_LIST,!1);static ATTRIBUTE_VALUE=new i(t.K.ATTRIBUTE_VALUE,n.UiInputType.ATTRIBUTE_VALUE,a.YamlArtifactType.ATTRIBUTE_VALUE,!1);static STATIC_PAGE_BREAK=new i(t.K.STATIC_PAGE_BREAK,n.UiInputType.PAGE_BREAK,a.YamlArtifactType.PAGE_BREAK,!0);static STATIC_SECTION_BREAK=new i(t.K.STATIC_SECTION_BREAK,n.UiInputType.SECTION_BREAK,a.YamlArtifactType.SECTION_BREAK,!0);static STATIC_IMAGE=new i(t.K.STATIC_IMAGE,n.UiInputType.IMAGE,a.YamlArtifactType.IMAGE,!0);static STATIC_RICH_TEXT=new i(t.K.STATIC_RICH_TEXT,n.UiInputType.RICH_TEXT,a.YamlArtifactType.RICH_TEXT,!0);static STATIC_YOUTUBE=new i(t.K.STATIC_YOUTUBE,n.UiInputType.YOUTUBE,a.YamlArtifactType.YOUTUBE,!0);static NULL=new i(null,n.UiInputType.NULL,a.YamlArtifactType.NULL,!0);static forUiInputType(e){for(const t of i.values())if(t.getUiInputType()===e)return t;return this.NULL}static forYamlArtifactType(e){for(const t of i.values())if(t.getYamlType()===e)return t;return this.NULL}}t.CedarFieldType=i},2234(e,t){t.CedarUser=void 0;class r{value;constructor(e){this.value=e}getValue(){return this.value}static NULL=new r(null);static forValue(e){return null===e?r.NULL:new r(e)}}t.CedarUser=r},3746(e,t){t.AdditionalProperties=t.P=void 0,t.P={FALSE:"false",ALLOW_ATTRIBUTE_VALUE:"allow-attribute-value"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static FALSE=new r(t.P.FALSE);static ALLOW_ATTRIBUTE_VALUE=new r(t.P.ALLOW_ATTRIBUTE_VALUE);static NULL=new r(null);static values(){return[r.FALSE,r.ALLOW_ATTRIBUTE_VALUE]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.AdditionalProperties=r},2475(e,t){t.ArtifactSchema=t.T=void 0,t.T={CURRENT:"http://json-schema.org/draft-04/schema#"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static CURRENT=new r(t.T.CURRENT);static NULL=new r(null);static forValue(e){return new r(null===e?t.T.CURRENT:e)}}t.ArtifactSchema=r},3910(e,t){t.BiboStatus=t.BiboStatusYamlValues=t.l=void 0,t.l={DRAFT:"bibo:draft",PUBLISHED:"bibo:published"},t.BiboStatusYamlValues={DRAFT:"draft",PUBLISHED:"published"};class r{jsonValue;yamlValue;constructor(e,t){this.jsonValue=e,this.yamlValue=t}getJsonValue(){return this.jsonValue}getYamlValue(){return this.yamlValue}static DRAFT=new r(t.l.DRAFT,t.BiboStatusYamlValues.DRAFT);static PUBLISHED=new r(t.l.PUBLISHED,t.BiboStatusYamlValues.PUBLISHED);static NULL=new r(null,null);static values(){return[r.DRAFT,r.PUBLISHED]}static forJsonValue(e){for(const t of r.values())if(t.getJsonValue()===e)return t;return this.NULL}static forYamlValue(e){for(const t of r.values())if(t.getYamlValue()===e)return t;return this.NULL}}t.BiboStatus=r},8802(e,t){t.Iri=void 0;class r{value;constructor(e){this.value=e}getValue(){return this.value}static empty(){return new r("")}isEmpty(){return""===this.value}}t.Iri=r},9857(e,t){t.IsoDate=void 0;class r{date;timezoneOffset;constructor(e,t){this.date=e,this.timezoneOffset=t}static NULL=new r(null,null);getValue(){if(null!=this.date){if("Z"===this.timezoneOffset)return this.date.toISOString().replace(/\.\d{3}Z$/,"Z");const e=this.timezoneOffset.match(/([+-])(\d{2}):(\d{2})/);if(e){const t="+"===e[1]?1:-1,r=parseInt(e[2],10)*t,n=parseInt(e[3],10)*t,a=this.date.getTime(),i=new Date(a+60*(60*r+n)*1e3),s=i.getUTCFullYear(),o=i.getUTCMonth()+1,l=i.getUTCDate(),c=i.getUTCHours(),d=i.getUTCMinutes(),u=i.getUTCSeconds();return`${s}-${o.toString().padStart(2,"0")}-${l.toString().padStart(2,"0")}T${c.toString().padStart(2,"0")}:${d.toString().padStart(2,"0")}:${u.toString().padStart(2,"0")}${this.timezoneOffset}`}return null}return null}static forValue(e){if(!e)return r.NULL;e=e.replace(/([+-]\d{2})(\d{2})$/,"$1:$2");const t=e.match(/Z|([+-])([01]\d):?([0-5]\d)$/)?.[0]??"Z",n=new Date("Z"!==t||e.endsWith("Z")?e:`${e}Z`);return new r(n,t)}static now(){const e=new Date,t=this.getCurrentGMTOffset();return new r(e,t)}static getCurrentGMTOffset(){const e=(new Date).getTimezoneOffset(),t=Math.abs(e),r=t%60;return`${e>0?"-":"+"}${Math.floor(t/60).toString().padStart(2,"0")}:${r.toString().padStart(2,"0")}`}}t.IsoDate=r},5793(e,t){t.JavascriptType=t.W=void 0,t.W={ARRAY:"array",OBJECT:"object",STRING:"string"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static ARRAY=new r(t.W.ARRAY);static OBJECT=new r(t.W.OBJECT);static STRING=new r(t.W.STRING);static NULL=new r(null);static values(){return[r.ARRAY,r.OBJECT,r.STRING]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.JavascriptType=r},7752(e,t){t.Language=void 0;class r{value;constructor(e){this.value=e}getValue(){return this.value}static NULL=new r(null);static forValue(e){return null===e||""===e?r.NULL:new r(e)}}t.Language=r},3447(e,t){t.NumberType=t.NumberTypeValues=void 0,t.NumberTypeValues={DECIMAL:"xsd:decimal",INT:"xsd:int",LONG:"xsd:long",BYTE:"xsd:byte",SHORT:"xsd:short",FLOAT:"xsd:float",DOUBLE:"xsd:double"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static DECIMAL=new r(t.NumberTypeValues.DECIMAL);static INT=new r(t.NumberTypeValues.INT);static LONG=new r(t.NumberTypeValues.LONG);static BYTE=new r(t.NumberTypeValues.BYTE);static SHORT=new r(t.NumberTypeValues.SHORT);static FLOAT=new r(t.NumberTypeValues.FLOAT);static DOUBLE=new r(t.NumberTypeValues.DOUBLE);static NULL=new r(null);static values(){return[r.DECIMAL,r.INT,r.LONG,r.BYTE,r.SHORT,r.FLOAT,r.DOUBLE]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.NumberType=r},1027(e,t,r){t.PavVersion=t.o=void 0;const n=r(4506);t.o={DEFAULT:"0.0.1"};class a extends n.SemVer{static DEFAULT=new a(t.o.DEFAULT);static NULL=new a(null);getDefaultValue(){return t.o.DEFAULT}static values(){return[a.DEFAULT,a.NULL]}static forValue(e){for(const t of a.values())if(t.getValue()===e)return t;return new a(e)}}t.PavVersion=a},6389(e,t,r){t.PropertyIri=void 0;const n=r(936);t.PropertyIri=class{static get namespace(){return n.CedarModel.propertyIriPrefix}}},8557(e,t,r){t.SchemaVersion=t.y=void 0;const n=r(4506);t.y={CURRENT:"1.6.0"};class a extends n.SemVer{static CURRENT=new a(t.y.CURRENT);static NULL=new a(null);getDefaultValue(){return t.y.CURRENT}static values(){return[a.CURRENT]}static forValue(e){for(const t of a.values())if(t.getValue()===e)return t;return new a(e)}}t.SchemaVersion=a},4506(e,t){t.SemVer=void 0,t.SemVer=class{value;constructor(e){this.value=this.validateVersion(e)}getValue(){return this.value}validateVersion(e){return null===e||/^\d+\.\d+\.\d+$/.test(e)?e:this.getDefaultValue()}}},7974(e,t){t.TemporalGranularity=t.TemporalGranularityValues=void 0,t.TemporalGranularityValues={YEAR:"year",MONTH:"month",DAY:"day",HOUR:"hour",MINUTE:"minute",SECOND:"second",DECIMAL_SECOND:"decimalSecond"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static YEAR=new r(t.TemporalGranularityValues.YEAR);static MONTH=new r(t.TemporalGranularityValues.MONTH);static DAY=new r(t.TemporalGranularityValues.DAY);static HOUR=new r(t.TemporalGranularityValues.HOUR);static MINUTE=new r(t.TemporalGranularityValues.MINUTE);static SECOND=new r(t.TemporalGranularityValues.SECOND);static DECIMAL_SECOND=new r(t.TemporalGranularityValues.DECIMAL_SECOND);static NULL=new r(null);static values(){return[r.YEAR,r.MONTH,r.DAY,r.HOUR,r.MINUTE,r.SECOND,r.DECIMAL_SECOND]}static valuesWithTimes(){return[r.HOUR,r.MINUTE,r.SECOND,r.DECIMAL_SECOND]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}static hasTime(e){return this.valuesWithTimes().includes(e)}}t.TemporalGranularity=r},8588(e,t){t.TemporalType=t.TemporalTypeValues=void 0,t.TemporalTypeValues={DATE:"xsd:date",TIME:"xsd:time",DATETIME:"xsd:dateTime"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static DATE=new r(t.TemporalTypeValues.DATE);static TIME=new r(t.TemporalTypeValues.TIME);static DATETIME=new r(t.TemporalTypeValues.DATETIME);static NULL=new r(null);static values(){return[r.DATE,r.TIME,r.DATETIME]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.TemporalType=r},3764(e,t){t.TimeFormat=t.TimeFormatValues=void 0,t.TimeFormatValues={H24:"24h",H12:"12h"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static H24=new r(t.TimeFormatValues.H24);static H12=new r(t.TimeFormatValues.H12);static NULL=new r(null);static values(){return[r.H24,r.H12]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.TimeFormat=r},9034(e,t){t.UiInputType=t.F=void 0,t.F={TEXTFIELD:"textfield",TEXTAREA:"textarea",LINK:"link",EXT_ROR:"ext-ror",EXT_ORCID:"ext-orcid",EXT_PFAS:"ext-pfas",EXT_PUBMED:"ext-pubmed",EXT_RRID:"ext-rrid",EXT_NIH_GRANT_ID:"ext-nih-grant-id",EXT_DOI:"ext-doi",TEMPORAL:"temporal",EMAIL:"email",NUMERIC:"numeric",PHONE_NUMBER:"phone-number",LIST:"list",CHECKBOX:"checkbox",RADIO:"radio",ATTRIBUTE_VALUE:"attribute-value",PAGE_BREAK:"page-break",SECTION_BREAK:"section-break",IMAGE:"image",RICH_TEXT:"richtext",YOUTUBE:"youtube"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static TEXTFIELD=new r(t.F.TEXTFIELD);static TEXTAREA=new r(t.F.TEXTAREA);static LINK=new r(t.F.LINK);static EXT_ROR=new r(t.F.EXT_ROR);static EXT_ORCID=new r(t.F.EXT_ORCID);static EXT_PFAS=new r(t.F.EXT_PFAS);static EXT_PUBMED=new r(t.F.EXT_PUBMED);static EXT_RRID=new r(t.F.EXT_RRID);static EXT_NIH_GRANT_ID=new r(t.F.EXT_NIH_GRANT_ID);static EXT_DOI=new r(t.F.EXT_DOI);static TEMPORAL=new r(t.F.TEMPORAL);static EMAIL=new r(t.F.EMAIL);static NUMERIC=new r(t.F.NUMERIC);static PHONE_NUMBER=new r(t.F.PHONE_NUMBER);static LIST=new r(t.F.LIST);static CHECKBOX=new r(t.F.CHECKBOX);static RADIO=new r(t.F.RADIO);static ATTRIBUTE_VALUE=new r(t.F.ATTRIBUTE_VALUE);static PAGE_BREAK=new r(t.F.PAGE_BREAK);static SECTION_BREAK=new r(t.F.SECTION_BREAK);static IMAGE=new r(t.F.IMAGE);static RICH_TEXT=new r(t.F.RICH_TEXT);static YOUTUBE=new r(t.F.YOUTUBE);static NULL=new r(null);static values(){return[r.TEXTFIELD,r.TEXTAREA,r.LINK,r.EXT_ROR,r.EXT_ORCID,r.EXT_PFAS,r.EXT_PUBMED,r.EXT_RRID,r.EXT_NIH_GRANT_ID,r.EXT_DOI,r.TEMPORAL,r.EMAIL,r.NUMERIC,r.PHONE_NUMBER,r.LIST,r.CHECKBOX,r.RADIO,r.ATTRIBUTE_VALUE,r.PAGE_BREAK,r.SECTION_BREAK,r.IMAGE,r.RICH_TEXT,r.YOUTUBE,r.NULL]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.UiInputType=r},9499(e,t,r){t.YamlArtifactType=t.YamlArtifactTypeValues=void 0;const n=r(8421);t.YamlArtifactTypeValues={TEMPLATE:"template",ELEMENT:"element",TEXTFIELD:"text-field",CONTROLLED_TERM:"controlled-term-field",TEXTAREA:"text-area-field",LINK:"link-field",EXT_ROR:"ext-ror-field",EXT_ORCID:"ext-orcid-field",EXT_PFAS:"ext-pfas-field",EXT_PUBMED:"ext-pubmed-field",EXT_RRID:"ext-rrid-field",EXT_NIH_GRANT_ID:"ext-nih-grant-id-field",EXT_DOI:"ext-doi-field",TEMPORAL:"temporal-field",EMAIL:"email-field",NUMERIC:"numeric-field",PHONE_NUMBER:"phone-number-field",SINGLE_SELECT_LIST:"single-select-list-field",MULTI_SELECT_LIST:"multi-select-list-field",CHECKBOX:"checkbox-field",RADIO:"radio-field",ATTRIBUTE_VALUE:"attribute-value-field",PAGE_BREAK:"static-page-break",SECTION_BREAK:"static-section-break",IMAGE:"static-image",RICH_TEXT:"static-rich-text",YOUTUBE:"static-youtube-video",TEMPLATE_INSTANCE:"instance"};class a{value;category;constructor(e,t){this.value=e,this.category=t}getValue(){return this.value}static TEMPLATE=new a(t.YamlArtifactTypeValues.TEMPLATE,n.CedarFieldCategory.NONE);static ELEMENT=new a(t.YamlArtifactTypeValues.ELEMENT,n.CedarFieldCategory.NONE);static TEXTFIELD=new a(t.YamlArtifactTypeValues.TEXTFIELD,n.CedarFieldCategory.DYNAMIC);static CONTROLLED_TERM=new a(t.YamlArtifactTypeValues.CONTROLLED_TERM,n.CedarFieldCategory.DYNAMIC);static TEXTAREA=new a(t.YamlArtifactTypeValues.TEXTAREA,n.CedarFieldCategory.DYNAMIC);static LINK=new a(t.YamlArtifactTypeValues.LINK,n.CedarFieldCategory.DYNAMIC);static EXT_ROR=new a(t.YamlArtifactTypeValues.EXT_ROR,n.CedarFieldCategory.DYNAMIC);static EXT_ORCID=new a(t.YamlArtifactTypeValues.EXT_ORCID,n.CedarFieldCategory.DYNAMIC);static EXT_PFAS=new a(t.YamlArtifactTypeValues.EXT_PFAS,n.CedarFieldCategory.DYNAMIC);static EXT_PUBMED=new a(t.YamlArtifactTypeValues.EXT_PUBMED,n.CedarFieldCategory.DYNAMIC);static EXT_RRID=new a(t.YamlArtifactTypeValues.EXT_RRID,n.CedarFieldCategory.DYNAMIC);static EXT_NIH_GRANT_ID=new a(t.YamlArtifactTypeValues.EXT_NIH_GRANT_ID,n.CedarFieldCategory.DYNAMIC);static EXT_DOI=new a(t.YamlArtifactTypeValues.EXT_DOI,n.CedarFieldCategory.DYNAMIC);static TEMPORAL=new a(t.YamlArtifactTypeValues.TEMPORAL,n.CedarFieldCategory.DYNAMIC);static EMAIL=new a(t.YamlArtifactTypeValues.EMAIL,n.CedarFieldCategory.DYNAMIC);static NUMERIC=new a(t.YamlArtifactTypeValues.NUMERIC,n.CedarFieldCategory.DYNAMIC);static PHONE_NUMBER=new a(t.YamlArtifactTypeValues.PHONE_NUMBER,n.CedarFieldCategory.DYNAMIC);static SINGLE_SELECT_LIST=new a(t.YamlArtifactTypeValues.SINGLE_SELECT_LIST,n.CedarFieldCategory.DYNAMIC);static MULTI_SELECT_LIST=new a(t.YamlArtifactTypeValues.MULTI_SELECT_LIST,n.CedarFieldCategory.DYNAMIC);static CHECKBOX=new a(t.YamlArtifactTypeValues.CHECKBOX,n.CedarFieldCategory.DYNAMIC);static RADIO=new a(t.YamlArtifactTypeValues.RADIO,n.CedarFieldCategory.DYNAMIC);static ATTRIBUTE_VALUE=new a(t.YamlArtifactTypeValues.ATTRIBUTE_VALUE,n.CedarFieldCategory.DYNAMIC);static PAGE_BREAK=new a(t.YamlArtifactTypeValues.PAGE_BREAK,n.CedarFieldCategory.STATIC);static SECTION_BREAK=new a(t.YamlArtifactTypeValues.SECTION_BREAK,n.CedarFieldCategory.STATIC);static IMAGE=new a(t.YamlArtifactTypeValues.IMAGE,n.CedarFieldCategory.STATIC);static RICH_TEXT=new a(t.YamlArtifactTypeValues.RICH_TEXT,n.CedarFieldCategory.STATIC);static YOUTUBE=new a(t.YamlArtifactTypeValues.YOUTUBE,n.CedarFieldCategory.STATIC);static TEMPLATE_INSTANCE=new a(t.YamlArtifactTypeValues.TEMPLATE_INSTANCE,n.CedarFieldCategory.NONE);static NULL=new a(null,n.CedarFieldCategory.NULL);static values(){return[a.TEMPLATE,a.ELEMENT,a.TEXTFIELD,a.CONTROLLED_TERM,a.TEXTAREA,a.LINK,a.EXT_ROR,a.EXT_ORCID,a.EXT_PFAS,a.EXT_PUBMED,a.EXT_RRID,a.EXT_NIH_GRANT_ID,a.EXT_DOI,a.TEMPORAL,a.EMAIL,a.NUMERIC,a.PHONE_NUMBER,a.SINGLE_SELECT_LIST,a.MULTI_SELECT_LIST,a.CHECKBOX,a.RADIO,a.ATTRIBUTE_VALUE,a.PAGE_BREAK,a.SECTION_BREAK,a.IMAGE,a.RICH_TEXT,a.YOUTUBE,a.TEMPLATE_INSTANCE,a.NULL]}static forValue(e){for(const t of a.values())if(t.getValue()===e)return t;return this.NULL}isTemplate(){return this.value===t.YamlArtifactTypeValues.TEMPLATE}isElement(){return this.value===t.YamlArtifactTypeValues.ELEMENT}isField(){return this.isDynamicField()||this.isStaticField()}isStaticField(){return this.category===n.CedarFieldCategory.STATIC}isDynamicField(){return this.category===n.CedarFieldCategory.DYNAMIC}isTemplateInstance(){return this.value===t.YamlArtifactTypeValues.TEMPLATE_INSTANCE}}t.YamlArtifactType=a},2888(e,t){t.ComparisonError=void 0,t.ComparisonError=class{errorLocation;errorType;errorPath;expectedValue;encounteredValue;stackTopLines;constructor(e,t,r,n,a){this.errorLocation=e,this.errorType=t,this.errorPath=r,this.expectedValue=n,this.encounteredValue=a}}},9760(e,t){t.ComparisonErrorType=t.e=void 0,t.e={MISSING_KEY_IN_REAL_OBJECT:"missingKeyInRealObject",UNEXPECTED_KEY_IN_REAL_OBJECT:"unexpectedKeyInRealObject",VALUE_MISMATCH:"valueMismatch",MISSING_INDEX_IN_REAL_OBJECT:"missingIndexInRealObject",UNEXPECTED_INDEX_IN_REAL_OBJECT:"unexpectedIndexInRealObject",MISSING_VALUE_IN_REAL_OBJECT:"missingValueInRealObject",UNEXPECTED_VALUE_IN_REAL_OBJECT:"unexpectedValueInRealObject"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static MISSING_KEY_IN_REAL_OBJECT=new r(t.e.MISSING_KEY_IN_REAL_OBJECT);static UNEXPECTED_KEY_IN_REAL_OBJECT=new r(t.e.UNEXPECTED_KEY_IN_REAL_OBJECT);static VALUE_MISMATCH=new r(t.e.VALUE_MISMATCH);static MISSING_INDEX_IN_REAL_OBJECT=new r(t.e.MISSING_INDEX_IN_REAL_OBJECT);static UNEXPECTED_INDEX_IN_REAL_OBJECT=new r(t.e.UNEXPECTED_INDEX_IN_REAL_OBJECT);static MISSING_VALUE_IN_REAL_OBJECT=new r(t.e.MISSING_VALUE_IN_REAL_OBJECT);static UNEXPECTED_VALUE_IN_REAL_OBJECT=new r(t.e.UNEXPECTED_VALUE_IN_REAL_OBJECT);static NULL=new r(null);static values(){return[r.MISSING_KEY_IN_REAL_OBJECT,r.UNEXPECTED_KEY_IN_REAL_OBJECT,r.VALUE_MISMATCH,r.MISSING_INDEX_IN_REAL_OBJECT,r.UNEXPECTED_INDEX_IN_REAL_OBJECT,r.MISSING_VALUE_IN_REAL_OBJECT,r.UNEXPECTED_VALUE_IN_REAL_OBJECT]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}toJSON(){return this.value}}t.ComparisonErrorType=r},4325(e,t){t.ComparisonResult=void 0,t.ComparisonResult=class{comparisonErrors=[];comparisonWarnings=[];addComparisonError(e){this.comparisonErrors.push(e)}getComparisonErrors(){return this.comparisonErrors}getComparisonErrorCount(){return this.comparisonErrors.length}addComparisonWarning(e){this.comparisonWarnings.push(e)}getComparisonWarnings(){return this.comparisonWarnings}getComparisonWarningCount(){return this.comparisonWarnings.length}areEqual(){return 0===this.comparisonErrors.length&&0===this.comparisonWarnings.length}merge(e){this.comparisonErrors.push(...e.comparisonErrors),this.comparisonWarnings.push(...e.comparisonWarnings)}}},4036(e,t){t.JsonArtifactParsingResult=void 0,t.JsonArtifactParsingResult=class{blueprintComparisonErrors=[];blueprintComparisonWarnings=[];addBlueprintComparisonError(e){this.blueprintComparisonErrors.push(e)}getBlueprintComparisonErrors(){return this.blueprintComparisonErrors}getBlueprintComparisonErrorCount(){return this.blueprintComparisonErrors.length}addBlueprintComparisonWarning(e){this.blueprintComparisonWarnings.push(e)}getBlueprintComparisonWarnings(){return this.blueprintComparisonWarnings}getBlueprintComparisonWarningCount(){return this.blueprintComparisonWarnings.length}wasSuccessful(){return 0===this.blueprintComparisonErrors.length}adheresToBlueprint(){return 0===this.blueprintComparisonErrors.length&&0===this.blueprintComparisonWarnings.length}merge(e){this.blueprintComparisonErrors.push(...e.blueprintComparisonErrors),this.blueprintComparisonWarnings.push(...e.blueprintComparisonWarnings)}}},3056(e,t,r){t.JsonObjectComparator=void 0;const n=r(2888),a=r(3188),i=r(9760),s=r(5747),o=r(2733),l=r(936);class c{static compareBothWays(e,t,r,s,d,u=[]){!function t(r,s,m){const p=r.getLastComponent()==o.JsonSchema.required;if(Array.isArray(s)&&Array.isArray(m))if(p){const t=new Set(s),a=new Set(m);s.forEach((t,s)=>{const o=r.add(s);a.has(t)||e.addBlueprintComparisonError(new n.ComparisonError("oca01",i.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,o,t))}),m.forEach((a,s)=>{const o=r.add(s);t.has(a)||e.addBlueprintComparisonError(new n.ComparisonError("oca02",i.ComparisonErrorType.UNEXPECTED_VALUE_IN_REAL_OBJECT,o,void 0,a))})}else{const a=Math.max(s.length,m.length);for(let o=0;o<a;o++){const a=r.add(o);o in s?o in m?"object"==typeof s[o]&&null!==s[o]&&"object"==typeof m[o]&&null!==m[o]?t(a,s[o],m[o]):s[o]!==m[o]&&e.addBlueprintComparisonError(new n.ComparisonError("ocl03",i.ComparisonErrorType.VALUE_MISMATCH,a,s[o],m[o])):e.addBlueprintComparisonError(new n.ComparisonError("ocl02",i.ComparisonErrorType.MISSING_INDEX_IN_REAL_OBJECT,a,s[o])):e.addBlueprintComparisonError(new n.ComparisonError("ocl01",i.ComparisonErrorType.UNEXPECTED_INDEX_IN_REAL_OBJECT,a,void 0,m[o]))}}else new Set([...Object.keys(s),...Object.keys(m)]).forEach(p=>{const h=r.add(p);if(p in s)if(p in m){if("object"==typeof s[p]&&null!==s[p]&&"object"==typeof m[p]&&null!==m[p])t(h,s[p],m[p]);else if(s[p]!==m[p]){const t=new n.ComparisonError("oco03",i.ComparisonErrorType.VALUE_MISMATCH,h,s[p],m[p]);d.useWarningForKnownIssues()&&c.isKnownProductionVariation(h)?e.addBlueprintComparisonWarning(t):e.addBlueprintComparisonError(t)}}else d.useWarningForKnownIssues()&&(h.endsIn(l.CedarModel.literals,a.JsonPath.ANY,l.CedarModel.selectedByDefault)||h.endsIn(l.CedarModel.ui,l.CedarModel.pages)||c.isKnownProductionVariation(h))?e.addBlueprintComparisonWarning(new n.ComparisonError("wco02",i.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,h)):e.addBlueprintComparisonError(new n.ComparisonError("oco02",i.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,h));else d.useWarningForKnownIssues()&&(h.endsIn(o.JsonSchema.properties,o.JsonSchema.atLanguage)||c.isKnownProductionVariation(h))?e.addBlueprintComparisonWarning(new n.ComparisonError("wco01",i.ComparisonErrorType.UNEXPECTED_KEY_IN_REAL_OBJECT,h)):u.includes(p)||e.addBlueprintComparisonError(new n.ComparisonError("oco01",i.ComparisonErrorType.UNEXPECTED_KEY_IN_REAL_OBJECT,h))})}(s,t,r)}static isKnownProductionVariation(e){return e.endsIn(o.JsonSchema.atContext,s.TemplateProperty.additionalProperties)||e.endsIn(o.JsonSchema.atContext,o.JsonSchema.properties,a.JsonPath.ANY,l.CedarModel.enum,a.JsonPath.ANY)||e.endsIn(o.JsonSchema.atContext,o.JsonSchema.required,a.JsonPath.ANY)||e.endsIn(o.JsonSchema.atContext,a.JsonPath.ANY)||e.endsIn(l.CedarModel.ui,l.CedarModel.propertyDescriptions,a.JsonPath.ANY)||e.endsIn(l.CedarModel.ui,l.CedarModel.propertyDescriptions)||e.endsIn(l.CedarModel.ui,l.CedarModel.propertyLabels)||e.endsIn(o.JsonSchema.properties,a.JsonPath.ANY,l.CedarModel.enum,a.JsonPath.ANY)||e.endsIn(o.JsonSchema.required)}static reportToLeft(e,t,r){t.useWarningForKnownIssues()&&c.isKnownProductionVariation(r.errorPath)?e.addBlueprintComparisonWarning(r):e.addBlueprintComparisonError(r)}static compareToLeft(e,t,r,a,s){!function t(r,a,l){const d=r.getLastComponent()==o.JsonSchema.required;if(Array.isArray(a)&&Array.isArray(l))if(d){const t=new Set(l);a.forEach((a,o)=>{const l=r.add(o);t.has(a)||c.reportToLeft(e,s,new n.ComparisonError("ola01",i.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,l,a))})}else a.forEach((o,d)=>{const u=r.add(d);d in l?"object"==typeof o&&null!==o&&"object"==typeof l[d]&&null!==l[d]?t(u,o,l[d]):o!==l[d]&&c.reportToLeft(e,s,new n.ComparisonError("oll02",i.ComparisonErrorType.VALUE_MISMATCH,u,o,l[d])):c.reportToLeft(e,s,new n.ComparisonError("oll01",i.ComparisonErrorType.MISSING_INDEX_IN_REAL_OBJECT,u,a[d]))});else Object.keys(a).forEach(o=>{const d=r.add(o);o in l?"object"==typeof a[o]&&null!==a[o]&&"object"==typeof l[o]&&null!==l[o]?t(d,a[o],l[o]):a[o]!==l[o]&&c.reportToLeft(e,s,new n.ComparisonError("olo02",i.ComparisonErrorType.VALUE_MISMATCH,d,a[o],l[o])):c.reportToLeft(e,s,new n.ComparisonError("olo01",i.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,d))})}(a,t,r)}static comparePrimitive(e,t,r,a){return t!==r&&e.addBlueprintComparisonError(new n.ComparisonError("opp1",i.ComparisonErrorType.VALUE_MISMATCH,a,t,r)),e}}t.JsonObjectComparator=c},1591(e,t){t.YamlArtifactParsingResult=void 0,t.YamlArtifactParsingResult=class{blueprintComparisonErrors=[];blueprintComparisonWarnings=[];addBlueprintComparisonError(e){this.blueprintComparisonErrors.push(e)}getBlueprintComparisonErrors(){return this.blueprintComparisonErrors}getBlueprintComparisonErrorCount(){return this.blueprintComparisonErrors.length}addBlueprintComparisonWarning(e){this.blueprintComparisonWarnings.push(e)}getBlueprintComparisonWarnings(){return this.blueprintComparisonWarnings}getBlueprintComparisonWarningCount(){return this.blueprintComparisonWarnings.length}wasSuccessful(){return 0===this.blueprintComparisonErrors.length}adheresToBlueprint(){return 0===this.blueprintComparisonErrors.length&&0===this.blueprintComparisonWarnings.length}merge(e){this.blueprintComparisonErrors.push(...e.blueprintComparisonErrors),this.blueprintComparisonWarnings.push(...e.blueprintComparisonWarnings)}}},6109(e,t){t.YamlComparisonErrorType=t.H=void 0,t.H={MISSING_KEY_IN_RIGHT_OBJECT:"missingKeyInRightObject",UNEXPECTED_KEY_IN_RIGHT_OBJECT:"unexpectedKeyInRightObject",VALUE_MISMATCH:"valueMismatch",MISSING_INDEX_IN_RIGHT_OBJECT:"missingIndexInRightObject",UNEXPECTED_INDEX_IN_RIGHT_OBJECT:"unexpectedIndexInRightObject",MISSING_VALUE_IN_RIGHT_OBJECT:"missingValueInRightObject",UNEXPECTED_VALUE_IN_RIGHT_OBJECT:"unexpectedValueInRightObject"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static MISSING_KEY_IN_RIGHT_OBJECT=new r(t.H.MISSING_KEY_IN_RIGHT_OBJECT);static UNEXPECTED_KEY_IN_RIGHT_OBJECT=new r(t.H.UNEXPECTED_KEY_IN_RIGHT_OBJECT);static VALUE_MISMATCH=new r(t.H.VALUE_MISMATCH);static MISSING_INDEX_IN_RIGHT_OBJECT=new r(t.H.MISSING_INDEX_IN_RIGHT_OBJECT);static UNEXPECTED_INDEX_IN_RIGHT_OBJECT=new r(t.H.UNEXPECTED_INDEX_IN_RIGHT_OBJECT);static MISSING_VALUE_IN_RIGHT_OBJECT=new r(t.H.MISSING_VALUE_IN_RIGHT_OBJECT);static UNEXPECTED_VALUE_IN_RIGHT_OBJECT=new r(t.H.UNEXPECTED_VALUE_IN_RIGHT_OBJECT);static NULL=new r(null);static values(){return[r.MISSING_KEY_IN_RIGHT_OBJECT,r.UNEXPECTED_KEY_IN_RIGHT_OBJECT,r.VALUE_MISMATCH,r.MISSING_INDEX_IN_RIGHT_OBJECT,r.UNEXPECTED_INDEX_IN_RIGHT_OBJECT,r.MISSING_VALUE_IN_RIGHT_OBJECT,r.UNEXPECTED_VALUE_IN_RIGHT_OBJECT]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}toJSON(){return this.value}}t.YamlComparisonErrorType=r},1885(e,t,r){t.YamlObjectComparator=void 0;const n=r(2888),a=r(3188),i=r(6109),s=r(4325);t.YamlObjectComparator=class{static compare(e,t){const r=new s.ComparisonResult;return this.compareBothWays(r,e,t,new a.JsonPath),r}static compareBothWays(e,t,r,a){!function t(r,a,s){if(Array.isArray(a)&&Array.isArray(s)){const o=Math.max(a.length,s.length);for(let l=0;l<o;l++){const o=r.add(l);l in a?l in s?"object"==typeof a[l]&&null!==a[l]&&"object"==typeof s[l]&&null!==s[l]?t(o,a[l],s[l]):a[l]!==s[l]&&e.addComparisonError(new n.ComparisonError("ocl03",i.YamlComparisonErrorType.VALUE_MISMATCH,o,a[l],s[l])):e.addComparisonError(new n.ComparisonError("ocl02",i.YamlComparisonErrorType.MISSING_INDEX_IN_RIGHT_OBJECT,o,a[l])):e.addComparisonError(new n.ComparisonError("ocl01",i.YamlComparisonErrorType.UNEXPECTED_INDEX_IN_RIGHT_OBJECT,o,void 0,s[l]))}}else new Set([...Object.keys(a),...Object.keys(s)]).forEach(o=>{const l=r.add(o);o in a?o in s?"object"==typeof a[o]&&null!==a[o]&&"object"==typeof s[o]&&null!==s[o]?t(l,a[o],s[o]):a[o]!==s[o]&&e.addComparisonError(new n.ComparisonError("oco03",i.YamlComparisonErrorType.VALUE_MISMATCH,l,a[o],s[o])):e.addComparisonError(new n.ComparisonError("oco02",i.YamlComparisonErrorType.MISSING_KEY_IN_RIGHT_OBJECT,l)):e.addComparisonError(new n.ComparisonError("oco01",i.YamlComparisonErrorType.UNEXPECTED_KEY_IN_RIGHT_OBJECT,l))})}(a,t,r)}}},3188(e,t){t.JsonPath=void 0;class r{path;static ANY="*";constructor(...e){this.path=e}equal(e){return this.path.length===e.path.length&&this.path.every((t,r)=>t===e.path[r])}add(...e){return new r(...this.path,...e)}join(e){return new r(...this.path,...e.path)}toString(){let e="";return this.path.forEach(t=>{e+="number"==typeof t?`/[${t}]`:`/${t}`}),e+"/"}toJSON(){return this.toString()}getLastComponent(){return 0===this.path.length?null:this.path[this.path.length-1]}endsIn(...e){for(let t=1;t<=e.length;t++){if(t>this.path.length)return!1;const n=e[e.length-t];if(this.path[this.path.length-t]!==n&&n!=r.ANY)return!1}return!0}getLastNComponents(e){if(e<=0||0===this.path.length)return new r;const t=Math.max(this.path.length-e,0),n=this.path.slice(t);return new r(...n)}}t.JsonPath=r},6968(e,t,r){t.JsonContainerArtifactContent=void 0;const n=r(8748);class a{static CONTEXT_VERBATIM={xsd:"http://www.w3.org/2001/XMLSchema#",pav:"http://purl.org/pav/",bibo:"http://purl.org/ontology/bibo/",oslc:"http://open-services.net/ns/core#",schema:"http://schema.org/","schema:name":{"@type":"xsd:string"},"schema:description":{"@type":"xsd:string"},"pav:createdOn":{"@type":"xsd:dateTime"},"pav:createdBy":{"@type":"@id"},"pav:lastUpdatedOn":{"@type":"xsd:dateTime"},"oslc:modifiedBy":{"@type":"@id"}};static CONTEXT_VERBATIM_NO_BIBO;static{this.CONTEXT_VERBATIM_NO_BIBO=n.ReaderUtil.deepClone(this.CONTEXT_VERBATIM),n.ReaderUtil.deleteNodeKey(this.CONTEXT_VERBATIM_NO_BIBO,"bibo"),n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM_NO_BIBO),n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM)}}t.JsonContainerArtifactContent=a},6551(e,t,r){t.JsonTemplateContent=void 0;const n=r(8748);class a{static REQUIRED_PARTIAL=["@context","@id","schema:isBasedOn","schema:name","schema:description","pav:createdOn","pav:createdBy","pav:lastUpdatedOn","oslc:modifiedBy"];static PROPERTIES_PARTIAL={"@context":{type:"object",properties:{rdfs:{type:"string",format:"uri",enum:["http://www.w3.org/2000/01/rdf-schema#"]},xsd:{type:"string",format:"uri",enum:["http://www.w3.org/2001/XMLSchema#"]},pav:{type:"string",format:"uri",enum:["http://purl.org/pav/"]},schema:{type:"string",format:"uri",enum:["http://schema.org/"]},oslc:{type:"string",format:"uri",enum:["http://open-services.net/ns/core#"]},skos:{type:"string",format:"uri",enum:["http://www.w3.org/2004/02/skos/core#"]},"rdfs:label":{type:"object",properties:{"@type":{type:"string",enum:["xsd:string"]}}},"schema:isBasedOn":{type:"object",properties:{"@type":{type:"string",enum:["@id"]}}},"schema:name":{type:"object",properties:{"@type":{type:"string",enum:["xsd:string"]}}},"schema:description":{type:"object",properties:{"@type":{type:"string",enum:["xsd:string"]}}},"pav:derivedFrom":{type:"object",properties:{"@type":{type:"string",enum:["@id"]}}},"pav:createdOn":{type:"object",properties:{"@type":{type:"string",enum:["xsd:dateTime"]}}},"pav:createdBy":{type:"object",properties:{"@type":{type:"string",enum:["@id"]}}},"pav:lastUpdatedOn":{type:"object",properties:{"@type":{type:"string",enum:["xsd:dateTime"]}}},"oslc:modifiedBy":{type:"object",properties:{"@type":{type:"string",enum:["@id"]}}},"skos:notation":{type:"object",properties:{"@type":{type:"string",enum:["xsd:string"]}}}},required:["xsd","pav","schema","oslc","schema:isBasedOn","schema:name","schema:description","pav:createdOn","pav:createdBy","pav:lastUpdatedOn","oslc:modifiedBy"],additionalProperties:!1},"@id":{type:["string","null"],format:"uri"},"@type":{oneOf:[{type:"string",format:"uri"},{type:"array",minItems:1,items:{type:"string",format:"uri"},uniqueItems:!0}]},"schema:isBasedOn":{type:"string",format:"uri"},"schema:name":{type:"string",minLength:1},"schema:description":{type:"string"},"pav:derivedFrom":{type:"string",format:"uri"},"pav:createdOn":{type:["string","null"],format:"date-time"},"pav:createdBy":{type:["string","null"],format:"uri"},"pav:lastUpdatedOn":{type:["string","null"],format:"date-time"},"oslc:modifiedBy":{type:["string","null"],format:"uri"}};static REQUIRED_PARTIAL_KEY_MAP;static PROPERTIES_PARTIAL_KEY_LIST=[];static PROPERTIES_PARTIAL_KEY_MAP=new Map;static CONTEXT_VERBATIM_NO_BIBO;static{Object.keys(a.PROPERTIES_PARTIAL).forEach(e=>{this.PROPERTIES_PARTIAL_KEY_LIST.push(e),this.PROPERTIES_PARTIAL_KEY_MAP.set(e,!0)}),this.REQUIRED_PARTIAL_KEY_MAP=this.REQUIRED_PARTIAL.reduce((e,t)=>(e.set(t,!0),e),new Map),n.ReaderUtil.deepFreeze(this.REQUIRED_PARTIAL),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL),n.ReaderUtil.deepFreeze(this.REQUIRED_PARTIAL_KEY_MAP),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL_KEY_LIST),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL_KEY_MAP)}}t.JsonTemplateContent=a},1501(e,t,r){t.JsonTemplateElementContent=void 0;const n=r(8748);class a{static REQUIRED_PARTIAL=["@context","@id"];static PROPERTIES_PARTIAL={"@context":{type:"object",properties:{},required:[],additionalProperties:!1},"@id":{type:["string","null"],format:"uri"},"@type":{oneOf:[{type:"string",format:"uri"},{type:"array",minItems:1,items:{type:"string",format:"uri"},uniqueItems:!0}]}};static LEGACY_ID_TYPING={type:"string",format:"uri"};static acceptEitherIdTyping(e,t){const r=n.ReaderUtil.getNode(t,"@id");null!==r&&JSON.stringify(r)===JSON.stringify(a.LEGACY_ID_TYPING)&&(e["@id"]=n.ReaderUtil.deepClone(a.LEGACY_ID_TYPING))}static REQUIRED_PARTIAL_KEY_MAP;static PROPERTIES_PARTIAL_KEY_MAP=new Map;static CONTEXT_VERBATIM_NO_BIBO;static{Object.keys(a.PROPERTIES_PARTIAL).forEach(e=>{this.PROPERTIES_PARTIAL_KEY_MAP.set(e,!0)}),this.REQUIRED_PARTIAL_KEY_MAP=this.REQUIRED_PARTIAL.reduce((e,t)=>(e.set(t,!0),e),new Map),n.ReaderUtil.deepFreeze(this.REQUIRED_PARTIAL),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL),n.ReaderUtil.deepFreeze(this.REQUIRED_PARTIAL_KEY_MAP),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL_KEY_MAP)}}t.JsonTemplateElementContent=a},9932(e,t,r){t.JsonTemplateFieldContentDynamic=void 0;const n=r(8748),a=r(2733),i=r(936);class s{static CONTEXT_VERBATIM={xsd:"http://www.w3.org/2001/XMLSchema#",pav:"http://purl.org/pav/",bibo:"http://purl.org/ontology/bibo/",oslc:"http://open-services.net/ns/core#",schema:"http://schema.org/",skos:"http://www.w3.org/2004/02/skos/core#","schema:name":{"@type":"xsd:string"},"schema:description":{"@type":"xsd:string"},"skos:prefLabel":{"@type":"xsd:string"},"skos:altLabel":{"@type":"xsd:string"},"pav:createdOn":{"@type":"xsd:dateTime"},"pav:createdBy":{"@type":"@id"},"pav:lastUpdatedOn":{"@type":"xsd:dateTime"},"oslc:modifiedBy":{"@type":"@id"}};static PROPERTIES_VERBATIM_LITERAL={"@type":{type:"string",format:"uri"},"rdfs:label":{type:["string","null"]},"@value":{type:["string","null"]},"@language":{type:["string","null"],minLength:1}};static PROPERTIES_VERBATIM_IRI={"@type":{type:"string",format:"uri"},"@id":{type:"string",format:"uri"},"rdfs:label":{type:["string","null"]},"skos:notation":{type:["string","null"]}};static ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_OUTSIDE={type:"object",properties:{"@value":{type:["string","null"]},"@type":{type:"string",format:"uri"}},required:["@value"],additionalProperties:!1};static ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE={type:"string",format:"uri"};static PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE;static PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION;static CONTEXT_VERBATIM_NO_BIBO;static{n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM),n.ReaderUtil.deepFreeze(this.PROPERTIES_VERBATIM_LITERAL),this.PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE=n.ReaderUtil.deepClone(this.PROPERTIES_VERBATIM_LITERAL),n.ReaderUtil.deleteNodeKey(this.PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE,a.JsonSchema.atLanguage),n.ReaderUtil.deepFreeze(this.PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE),this.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION=n.ReaderUtil.deepClone(this.PROPERTIES_VERBATIM_IRI),n.ReaderUtil.deleteNodeKey(this.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION,i.CedarModel.skosNotation),n.ReaderUtil.deepFreeze(this.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION),this.CONTEXT_VERBATIM_NO_BIBO=n.ReaderUtil.deepClone(this.CONTEXT_VERBATIM),n.ReaderUtil.deleteNodeKey(this.CONTEXT_VERBATIM_NO_BIBO,"bibo"),n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM_NO_BIBO),n.ReaderUtil.deepFreeze(this.PROPERTIES_VERBATIM_IRI),n.ReaderUtil.deepFreeze(this.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_OUTSIDE),n.ReaderUtil.deepFreeze(this.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE)}}t.JsonTemplateFieldContentDynamic=s},9251(e,t,r){t.JsonTemplateFieldContentStatic=void 0;const n=r(8748);class a{static CONTEXT_VERBATIM={schema:"http://schema.org/",pav:"http://purl.org/pav/",bibo:"http://purl.org/ontology/bibo/",oslc:"http://open-services.net/ns/core#"};static CONTEXT_VERBATIM_NO_BIBO;static{n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM),this.CONTEXT_VERBATIM_NO_BIBO=n.ReaderUtil.deepClone(this.CONTEXT_VERBATIM),n.ReaderUtil.deleteNodeKey(this.CONTEXT_VERBATIM_NO_BIBO,"bibo"),n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM_NO_BIBO)}}t.JsonTemplateFieldContentStatic=a},350(e,t,r){t.JsonTemplateInstanceContent=void 0;const n=r(8748);class a{static CONTEXT_VERBATIM={rdfs:"http://www.w3.org/2000/01/rdf-schema#",xsd:"http://www.w3.org/2001/XMLSchema#",pav:"http://purl.org/pav/",schema:"http://schema.org/",oslc:"http://open-services.net/ns/core#",skos:"http://www.w3.org/2004/02/skos/core#","rdfs:label":{"@type":"xsd:string"},"schema:isBasedOn":{"@type":"@id"},"schema:name":{"@type":"xsd:string"},"schema:description":{"@type":"xsd:string"},"pav:derivedFrom":{"@type":"@id"},"pav:createdOn":{"@type":"xsd:dateTime"},"pav:createdBy":{"@type":"@id"},"pav:lastUpdatedOn":{"@type":"xsd:dateTime"},"oslc:modifiedBy":{"@type":"@id"},"skos:notation":{"@type":"xsd:string"}};static{n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM)}}t.JsonTemplateInstanceContent=a},3198(e,t,r){r.d(t,{Alias:()=>x,CST:()=>n,Composer:()=>er,Document:()=>_t,Lexer:()=>Nr,LineCounter:()=>wr,Pair:()=>Ce,Parser:()=>Ur,Scalar:()=>W,Schema:()=>St,YAMLError:()=>Nt,YAMLMap:()=>Se,YAMLParseError:()=>wt,YAMLSeq:()=>ve,YAMLWarning:()=>Lt,default:()=>Wr,isAlias:()=>m,isCollection:()=>E,isDocument:()=>p,isMap:()=>h,isNode:()=>C,isPair:()=>f,isScalar:()=>T,isSeq:()=>y,parse:()=>Pr,parseAllDocuments:()=>Yr,parseDocument:()=>xr,stringify:()=>kr,visit:()=>R,visitAsync:()=>_}),r.r(t);var n={};r.r(n),r.d(n,{BOM:()=>hr,DOCUMENT:()=>fr,FLOW_END:()=>Tr,SCALAR:()=>yr,createScalarToken:()=>rr,isCollection:()=>Er,isScalar:()=>Cr,prettyToken:()=>gr,resolveAsScalar:()=>tr,setScalarValue:()=>nr,stringify:()=>sr,tokenType:()=>Ir,visit:()=>mr});var a={};r.r(a),r.d(a,{Alias:()=>x,CST:()=>n,Composer:()=>er,Document:()=>_t,Lexer:()=>Nr,LineCounter:()=>wr,Pair:()=>Ce,Parser:()=>Ur,Scalar:()=>W,Schema:()=>St,YAMLError:()=>Nt,YAMLMap:()=>Se,YAMLParseError:()=>wt,YAMLSeq:()=>ve,YAMLWarning:()=>Lt,isAlias:()=>m,isCollection:()=>E,isDocument:()=>p,isMap:()=>h,isNode:()=>C,isPair:()=>f,isScalar:()=>T,isSeq:()=>y,parse:()=>Pr,parseAllDocuments:()=>Yr,parseDocument:()=>xr,stringify:()=>kr,visit:()=>R,visitAsync:()=>_});const i=Symbol.for("yaml.alias"),s=Symbol.for("yaml.document"),o=Symbol.for("yaml.map"),l=Symbol.for("yaml.pair"),c=Symbol.for("yaml.scalar"),d=Symbol.for("yaml.seq"),u=Symbol.for("yaml.node.type"),m=e=>!!e&&"object"==typeof e&&e[u]===i,p=e=>!!e&&"object"==typeof e&&e[u]===s,h=e=>!!e&&"object"==typeof e&&e[u]===o,f=e=>!!e&&"object"==typeof e&&e[u]===l,T=e=>!!e&&"object"==typeof e&&e[u]===c,y=e=>!!e&&"object"==typeof e&&e[u]===d;function E(e){if(e&&"object"==typeof e)switch(e[u]){case o:case d:return!0}return!1}function C(e){if(e&&"object"==typeof e)switch(e[u]){case i:case o:case c:case d:return!0}return!1}const g=e=>(T(e)||E(e))&&!!e.anchor,I=Symbol("break visit"),A=Symbol("skip children"),b=Symbol("remove node");function R(e,t){const r=N(t);p(e)?S(null,e.contents,r,Object.freeze([e]))===b&&(e.contents=null):S(null,e,r,Object.freeze([]))}function S(e,t,r,n){const a=w(e,t,r,n);if(C(a)||f(a))return L(e,n,a),S(e,a,r,n);if("symbol"!=typeof a)if(E(t)){n=Object.freeze(n.concat(t));for(let e=0;e<t.items.length;++e){const a=S(e,t.items[e],r,n);if("number"==typeof a)e=a-1;else{if(a===I)return I;a===b&&(t.items.splice(e,1),e-=1)}}}else if(f(t)){n=Object.freeze(n.concat(t));const e=S("key",t.key,r,n);if(e===I)return I;e===b&&(t.key=null);const a=S("value",t.value,r,n);if(a===I)return I;a===b&&(t.value=null)}return a}async function _(e,t){const r=N(t);p(e)?await v(null,e.contents,r,Object.freeze([e]))===b&&(e.contents=null):await v(null,e,r,Object.freeze([]))}async function v(e,t,r,n){const a=await w(e,t,r,n);if(C(a)||f(a))return L(e,n,a),v(e,a,r,n);if("symbol"!=typeof a)if(E(t)){n=Object.freeze(n.concat(t));for(let e=0;e<t.items.length;++e){const a=await v(e,t.items[e],r,n);if("number"==typeof a)e=a-1;else{if(a===I)return I;a===b&&(t.items.splice(e,1),e-=1)}}}else if(f(t)){n=Object.freeze(n.concat(t));const e=await v("key",t.key,r,n);if(e===I)return I;e===b&&(t.key=null);const a=await v("value",t.value,r,n);if(a===I)return I;a===b&&(t.value=null)}return a}function N(e){return"object"==typeof e&&(e.Collection||e.Node||e.Value)?Object.assign({Alias:e.Node,Map:e.Node,Scalar:e.Node,Seq:e.Node},e.Value&&{Map:e.Value,Scalar:e.Value,Seq:e.Value},e.Collection&&{Map:e.Collection,Seq:e.Collection},e):e}function w(e,t,r,n){return"function"==typeof r?r(e,t,n):h(t)?r.Map?.(e,t,n):y(t)?r.Seq?.(e,t,n):f(t)?r.Pair?.(e,t,n):T(t)?r.Scalar?.(e,t,n):m(t)?r.Alias?.(e,t,n):void 0}function L(e,t,r){const n=t[t.length-1];if(E(n))n.items[e]=r;else if(f(n))"key"===e?n.key=r:n.value=r;else{if(!p(n)){const e=m(n)?"alias":"scalar";throw new Error(`Cannot replace node with ${e} parent`)}n.contents=r}}R.BREAK=I,R.SKIP=A,R.REMOVE=b,_.BREAK=I,_.SKIP=A,_.REMOVE=b;const F={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},O=e=>e.replace(/[!,[\]{}]/g,e=>F[e]);class V{constructor(e,t){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},V.defaultYaml,e),this.tags=Object.assign({},V.defaultTags,t)}clone(){const e=new V(this.yaml,this.tags);return e.docStart=this.docStart,e}atDocument(){const e=new V(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:V.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},V.defaultTags)}return e}add(e,t){this.atNextDocument&&(this.yaml={explicit:V.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},V.defaultTags),this.atNextDocument=!1);const r=e.trim().split(/[ \t]+/),n=r.shift();switch(n){case"%TAG":{if(2!==r.length&&(t(0,"%TAG directive should contain exactly two parts"),r.length<2))return!1;const[e,n]=r;return this.tags[e]=n,!0}case"%YAML":{if(this.yaml.explicit=!0,1!==r.length)return t(0,"%YAML directive should contain exactly one part"),!1;const[e]=r;return"1.1"===e||"1.2"===e?(this.yaml.version=e,!0):(t(6,`Unsupported YAML version ${e}`,/^\d+\.\d+$/.test(e)),!1)}default:return t(0,`Unknown directive ${n}`,!0),!1}}tagName(e,t){if("!"===e)return"!";if("!"!==e[0])return t(`Not a valid tag: ${e}`),null;if("<"===e[1]){const r=e.slice(2,-1);return"!"===r||"!!"===r?(t(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(">"!==e[e.length-1]&&t("Verbatim tags must end with a >"),r)}const[,r,n]=e.match(/^(.*!)([^!]*)$/s);n||t(`The ${e} tag has no suffix`);const a=this.tags[r];if(a)try{return a+decodeURIComponent(n)}catch(e){return t(String(e)),null}return"!"===r?e:(t(`Could not resolve tag: ${e}`),null)}tagString(e){for(const[t,r]of Object.entries(this.tags))if(e.startsWith(r))return t+O(e.substring(r.length));return"!"===e[0]?e:`!<${e}>`}toString(e){const t=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],r=Object.entries(this.tags);let n;if(e&&r.length>0&&C(e.contents)){const t={};R(e.contents,(e,r)=>{C(r)&&r.tag&&(t[r.tag]=!0)}),n=Object.keys(t)}else n=[];for(const[a,i]of r)"!!"===a&&"tag:yaml.org,2002:"===i||e&&!n.some(e=>e.startsWith(i))||t.push(`%TAG ${a} ${i}`);return t.join("\n")}}function B(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){const t=JSON.stringify(e);throw new Error(`Anchor must not contain whitespace or control characters: ${t}`)}return!0}function D(e){const t=new Set;return R(e,{Value(e,r){r.anchor&&t.add(r.anchor)}}),t}function M(e,t){for(let r=1;;++r){const n=`${e}${r}`;if(!t.has(n))return n}}function U(e,t,r,n){if(n&&"object"==typeof n)if(Array.isArray(n))for(let t=0,r=n.length;t<r;++t){const r=n[t],a=U(e,n,String(t),r);void 0===a?delete n[t]:a!==r&&(n[t]=a)}else if(n instanceof Map)for(const t of Array.from(n.keys())){const r=n.get(t),a=U(e,n,t,r);void 0===a?n.delete(t):a!==r&&n.set(t,a)}else if(n instanceof Set)for(const t of Array.from(n)){const r=U(e,n,t,t);void 0===r?n.delete(t):r!==t&&(n.delete(t),n.add(r))}else for(const[t,r]of Object.entries(n)){const a=U(e,n,t,r);void 0===a?delete n[t]:a!==r&&(n[t]=a)}return e.call(t,r,n)}function J(e,t,r){if(Array.isArray(e))return e.map((e,t)=>J(e,String(t),r));if(e&&"function"==typeof e.toJSON){if(!r||!g(e))return e.toJSON(t,r);const n={aliasCount:0,count:1,res:void 0};r.anchors.set(e,n),r.onCreate=e=>{n.res=e,delete r.onCreate};const a=e.toJSON(t,r);return r.onCreate&&r.onCreate(a),a}return"bigint"!=typeof e||r?.keep?e:Number(e)}V.defaultYaml={explicit:!1,version:"1.2"},V.defaultTags={"!!":"tag:yaml.org,2002:"};class Y{constructor(e){Object.defineProperty(this,u,{value:e})}clone(){const e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:t,maxAliasCount:r,onAnchor:n,reviver:a}={}){if(!p(e))throw new TypeError("A document argument is required");const i={anchors:new Map,doc:e,keep:!0,mapAsMap:!0===t,mapKeyWarned:!1,maxAliasCount:"number"==typeof r?r:100},s=J(this,"",i);if("function"==typeof n)for(const{count:e,res:t}of i.anchors.values())n(t,e);return"function"==typeof a?U(a,{"":s},"",s):s}}class x extends Y{constructor(e){super(i),this.source=e,Object.defineProperty(this,"tag",{set(){throw new Error("Alias nodes cannot have tags")}})}resolve(e,t){if(0===t?.maxAliasCount)throw new ReferenceError("Alias resolution is disabled");let r,n;t?.aliasResolveCache?r=t.aliasResolveCache:(r=[],R(e,{Node:(e,t)=>{(m(t)||g(t))&&r.push(t)}}),t&&(t.aliasResolveCache=r));for(const e of r){if(e===this)break;e.anchor===this.source&&(n=e)}return n}toJSON(e,t){if(!t)return{source:this.source};const{anchors:r,doc:n,maxAliasCount:a}=t,i=this.resolve(n,t);if(!i){const e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new ReferenceError(e)}let s=r.get(i);if(s||(J(i,null,t),s=r.get(i)),void 0===s?.res)throw new ReferenceError("This should not happen: Alias anchor was not resolved?");if(a>=0&&(s.count+=1,0===s.aliasCount&&(s.aliasCount=P(n,i,r)),s.count*s.aliasCount>a))throw new ReferenceError("Excessive alias count indicates a resource exhaustion attack");return s.res}toString(e,t,r){const n=`*${this.source}`;if(e){if(B(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){const e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new Error(e)}if(e.implicitKey)return`${n} `}return n}}function P(e,t,r){if(m(t)){const n=t.resolve(e),a=r&&n&&r.get(n);return a?a.count*a.aliasCount:0}if(E(t)){let n=0;for(const a of t.items){const t=P(e,a,r);t>n&&(n=t)}return n}if(f(t)){const n=P(e,t.key,r),a=P(e,t.value,r);return Math.max(n,a)}return 1}const k=e=>!e||"function"!=typeof e&&"object"!=typeof e;class W extends Y{constructor(e){super(c),this.value=e}toJSON(e,t){return t?.keep?this.value:J(this.value,e,t)}toString(){return String(this.value)}}function K(e,t,r){if(p(e)&&(e=e.contents),C(e))return e;if(f(e)){const t=r.schema[o].createNode?.(r.schema,null,r);return t.items.push(e),t}(e instanceof String||e instanceof Number||e instanceof Boolean||"undefined"!=typeof BigInt&&e instanceof BigInt)&&(e=e.valueOf());const{aliasDuplicateObjects:n,onAnchor:a,onTagObj:i,schema:s,sourceObjects:l}=r;let c;if(n&&e&&"object"==typeof e){if(c=l.get(e),c)return c.anchor??(c.anchor=a(e)),new x(c.anchor);c={anchor:null,node:null},l.set(e,c)}t?.startsWith("!!")&&(t="tag:yaml.org,2002:"+t.slice(2));let u=function(e,t,r){if(t){const e=r.filter(e=>e.tag===t),n=e.find(e=>!e.format)??e[0];if(!n)throw new Error(`Tag ${t} not found`);return n}return r.find(t=>t.identify?.(e)&&!t.format)}(e,t,s.tags);if(!u){if(e&&"function"==typeof e.toJSON&&(e=e.toJSON()),!e||"object"!=typeof e){const t=new W(e);return c&&(c.node=t),t}u=e instanceof Map?s[o]:Symbol.iterator in Object(e)?s[d]:s[o]}i&&(i(u),delete r.onTagObj);const m=u?.createNode?u.createNode(r.schema,e,r):"function"==typeof u?.nodeClass?.from?u.nodeClass.from(r.schema,e,r):new W(e);return t?m.tag=t:u.default||(m.tag=u.tag),c&&(c.node=m),m}function j(e,t,r){let n=r;for(let e=t.length-1;e>=0;--e){const r=t[e];if("number"==typeof r&&Number.isInteger(r)&&r>=0){const e=[];e[r]=n,n=e}else n=new Map([[r,n]])}return K(n,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw new Error("This should not happen, please report a bug.")},schema:e,sourceObjects:new Map})}W.BLOCK_FOLDED="BLOCK_FOLDED",W.BLOCK_LITERAL="BLOCK_LITERAL",W.PLAIN="PLAIN",W.QUOTE_DOUBLE="QUOTE_DOUBLE",W.QUOTE_SINGLE="QUOTE_SINGLE";const G=e=>null==e||"object"==typeof e&&!!e[Symbol.iterator]().next().done;class X extends Y{constructor(e,t){super(e),Object.defineProperty(this,"schema",{value:t,configurable:!0,enumerable:!1,writable:!0})}clone(e){const t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(t.schema=e),t.items=t.items.map(t=>C(t)||f(t)?t.clone(e):t),this.range&&(t.range=this.range.slice()),t}addIn(e,t){if(G(e))this.add(t);else{const[r,...n]=e,a=this.get(r,!0);if(E(a))a.addIn(n,t);else{if(void 0!==a||!this.schema)throw new Error(`Expected YAML collection at ${r}. Remaining path: ${n}`);this.set(r,j(this.schema,n,t))}}}deleteIn(e){const[t,...r]=e;if(0===r.length)return this.delete(t);const n=this.get(t,!0);if(E(n))return n.deleteIn(r);throw new Error(`Expected YAML collection at ${t}. Remaining path: ${r}`)}getIn(e,t){const[r,...n]=e,a=this.get(r,!0);return 0===n.length?!t&&T(a)?a.value:a:E(a)?a.getIn(n,t):void 0}hasAllNullValues(e){return this.items.every(t=>{if(!f(t))return!1;const r=t.value;return null==r||e&&T(r)&&null==r.value&&!r.commentBefore&&!r.comment&&!r.tag})}hasIn(e){const[t,...r]=e;if(0===r.length)return this.has(t);const n=this.get(t,!0);return!!E(n)&&n.hasIn(r)}setIn(e,t){const[r,...n]=e;if(0===n.length)this.set(r,t);else{const e=this.get(r,!0);if(E(e))e.setIn(n,t);else{if(void 0!==e||!this.schema)throw new Error(`Expected YAML collection at ${r}. Remaining path: ${n}`);this.set(r,j(this.schema,n,t))}}}}const $=e=>e.replace(/^(?!$)(?: $)?/gm,"#");function q(e,t){return/^\n+$/.test(e)?e.substring(1):t?e.replace(/^(?! *$)/gm,t):e}const H=(e,t,r)=>e.endsWith("\n")?q(r,t):r.includes("\n")?"\n"+q(r,t):(e.endsWith(" ")?"":" ")+r,z="block",Q="quoted";function Z(e,t,r="flow",{indentAtStart:n,lineWidth:a=80,minContentWidth:i=20,onFold:s,onOverflow:o}={}){if(!a||a<0)return e;a<i&&(i=0);const l=Math.max(1+i,1+a-t.length);if(e.length<=l)return e;const c=[],d={};let u,m,p=a-t.length;"number"==typeof n&&(n>a-Math.max(2,i)?c.push(0):p=a-n);let h=!1,f=-1,T=-1,y=-1;r===z&&(f=ee(e,f,t.length),-1!==f&&(p=f+l));for(let n;n=e[f+=1];){if(r===Q&&"\\"===n){switch(T=f,e[f+1]){case"x":f+=3;break;case"u":f+=5;break;case"U":f+=9;break;default:f+=1}y=f}if("\n"===n)r===z&&(f=ee(e,f,t.length)),p=f+t.length+l,u=void 0;else{if(" "===n&&m&&" "!==m&&"\n"!==m&&"\t"!==m){const t=e[f+1];t&&" "!==t&&"\n"!==t&&"\t"!==t&&(u=f)}if(f>=p)if(u)c.push(u),p=u+l,u=void 0;else if(r===Q){for(;" "===m||"\t"===m;)m=n,n=e[f+=1],h=!0;const t=f>y+1?f-2:T-1;if(d[t])return e;c.push(t),d[t]=!0,p=t+l,u=void 0}else h=!0}m=n}if(h&&o&&o(),0===c.length)return e;s&&s();let E=e.slice(0,c[0]);for(let n=0;n<c.length;++n){const a=c[n],i=c[n+1]||e.length;0===a?E=`\n${t}${e.slice(0,i)}`:(r===Q&&d[a]&&(E+=`${e[a]}\\`),E+=`\n${t}${e.slice(a+1,i)}`)}return E}function ee(e,t,r){let n=t,a=t+1,i=e[a];for(;" "===i||"\t"===i;)if(t<a+r)i=e[++t];else{do{i=e[++t]}while(i&&"\n"!==i);n=t,a=t+1,i=e[a]}return n}const te=(e,t)=>({indentAtStart:t?e.indent.length:e.indentAtStart,lineWidth:e.options.lineWidth,minContentWidth:e.options.minContentWidth}),re=e=>/^(%|---|\.\.\.)/m.test(e);function ne(e,t){const r=JSON.stringify(e);if(t.options.doubleQuotedAsJSON)return r;const{implicitKey:n}=t,a=t.options.doubleQuotedMinMultiLineLength,i=t.indent||(re(e)?" ":"");let s="",o=0;for(let e=0,t=r[e];t;t=r[++e])if(" "===t&&"\\"===r[e+1]&&"n"===r[e+2]&&(s+=r.slice(o,e)+"\\ ",e+=1,o=e,t="\\"),"\\"===t)switch(r[e+1]){case"u":{s+=r.slice(o,e);const t=r.substr(e+2,4);switch(t){case"0000":s+="\\0";break;case"0007":s+="\\a";break;case"000b":s+="\\v";break;case"001b":s+="\\e";break;case"0085":s+="\\N";break;case"00a0":s+="\\_";break;case"2028":s+="\\L";break;case"2029":s+="\\P";break;default:"00"===t.substr(0,2)?s+="\\x"+t.substr(2):s+=r.substr(e,6)}e+=5,o=e+1}break;case"n":if(n||'"'===r[e+2]||r.length<a)e+=1;else{for(s+=r.slice(o,e)+"\n\n";"\\"===r[e+2]&&"n"===r[e+3]&&'"'!==r[e+4];)s+="\n",e+=2;s+=i," "===r[e+2]&&(s+="\\"),e+=1,o=e+1}break;default:e+=1}return s=o?s+r.slice(o):r,n?s:Z(s,i,"quoted",te(t,!1))}function ae(e,t){if(!1===t.options.singleQuote||t.implicitKey&&e.includes("\n")||/[ \t]\n|\n[ \t]/.test(e))return ne(e,t);const r=t.indent||(re(e)?" ":""),n="'"+e.replace(/'/g,"''").replace(/\n+/g,`$&\n${r}`)+"'";return t.implicitKey?n:Z(n,r,"flow",te(t,!1))}function ie(e,t){const{singleQuote:r}=t.options;let n;if(!1===r)n=ne;else{const t=e.includes('"'),a=e.includes("'");n=t&&!a?ae:a&&!t?ne:r?ae:ne}return n(e,t)}let se;try{se=new RegExp("(^|(?<!\n))\n+(?!\n|$)","g")}catch{se=/\n+(?!\n|$)/g}function oe({comment:e,type:t,value:r},n,a,i){const{blockQuote:s,commentString:o,lineWidth:l}=n.options;if(!s||/\n[\t ]+$/.test(r))return ie(r,n);const c=n.indent||(n.forceBlockIndent||re(r)?" ":""),d="literal"===s||"folded"!==s&&t!==W.BLOCK_FOLDED&&(t===W.BLOCK_LITERAL||!function(e,t,r){if(!t||t<0)return!1;const n=t-r,a=e.length;if(a<=n)return!1;for(let t=0,r=0;t<a;++t)if("\n"===e[t]){if(t-r>n)return!0;if(r=t+1,a-r<=n)return!1}return!0}(r,l,c.length));if(!r)return d?"|\n":">\n";let u,m;for(m=r.length;m>0;--m){const e=r[m-1];if("\n"!==e&&"\t"!==e&&" "!==e)break}let p=r.substring(m);const h=p.indexOf("\n");-1===h?u="-":r===p||h!==p.length-1?(u="+",i&&i()):u="",p&&(r=r.slice(0,-p.length),"\n"===p[p.length-1]&&(p=p.slice(0,-1)),p=p.replace(se,`$&${c}`));let f,T=!1,y=-1;for(f=0;f<r.length;++f){const e=r[f];if(" "===e)T=!0;else{if("\n"!==e)break;y=f}}let E=r.substring(0,y<f?y+1:f);E&&(r=r.substring(E.length),E=E.replace(/\n+/g,`$&${c}`));let C=(T?c?"2":"1":"")+u;if(e&&(C+=" "+o(e.replace(/ ?[\r\n]+/g," ")),a&&a()),!d){const e=r.replace(/\n+/g,"\n$&").replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${c}`);let a=!1;const i=te(n,!0);"folded"!==s&&t!==W.BLOCK_FOLDED&&(i.onOverflow=()=>{a=!0});const o=Z(`${E}${e}${p}`,c,"block",i);if(!a)return`>${C}\n${c}${o}`}return`|${C}\n${c}${E}${r=r.replace(/\n+/g,`$&${c}`)}${p}`}function le(e,t,r,n){const{implicitKey:a,inFlow:i}=t,s="string"==typeof e.value?e:Object.assign({},e,{value:String(e.value)});let{type:o}=e;o!==W.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(s.value)&&(o=W.QUOTE_DOUBLE);const l=e=>{switch(e){case W.BLOCK_FOLDED:case W.BLOCK_LITERAL:return a||i?ie(s.value,t):oe(s,t,r,n);case W.QUOTE_DOUBLE:return ne(s.value,t);case W.QUOTE_SINGLE:return ae(s.value,t);case W.PLAIN:return function(e,t,r,n){const{type:a,value:i}=e,{actualString:s,implicitKey:o,indent:l,indentStep:c,inFlow:d}=t;if(o&&i.includes("\n")||d&&/[[\]{},]/.test(i))return ie(i,t);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(i))return o||d||!i.includes("\n")?ie(i,t):oe(e,t,r,n);if(!o&&!d&&a!==W.PLAIN&&i.includes("\n"))return oe(e,t,r,n);if(re(i)){if(""===l)return t.forceBlockIndent=!0,oe(e,t,r,n);if(o&&l===c)return ie(i,t)}const u=i.replace(/\n+/g,`$&\n${l}`);if(s){const e=e=>e.default&&"tag:yaml.org,2002:str"!==e.tag&&e.test?.test(u),{compat:r,tags:n}=t.doc.schema;if(n.some(e)||r?.some(e))return ie(i,t)}return o?u:Z(u,l,"flow",te(t,!1))}(s,t,r,n);default:return null}};let c=l(o);if(null===c){const{defaultKeyType:e,defaultStringType:r}=t.options,n=a&&e||r;if(c=l(n),null===c)throw new Error(`Unsupported default string type ${n}`)}return c}function ce(e,t){const r=Object.assign({blockQuote:!0,commentString:$,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:"true",verifyAliasOrder:!0},e.schema.toStringOptions,t);let n;switch(r.collectionStyle){case"block":n=!1;break;case"flow":n=!0;break;default:n=null}return{anchors:new Set,doc:e,flowCollectionPadding:r.flowCollectionPadding?" ":"",indent:"",indentStep:"number"==typeof r.indent?" ".repeat(r.indent):" ",inFlow:n,options:r}}function de(e,t,r,n){if(f(e))return e.toString(t,r,n);if(m(e)){if(t.doc.directives)return e.toString(t);if(t.resolvedAliases?.has(e))throw new TypeError("Cannot stringify circular structure without alias nodes");t.resolvedAliases?t.resolvedAliases.add(e):t.resolvedAliases=new Set([e]),e=e.resolve(t.doc)}let a;const i=C(e)?e:t.doc.createNode(e,{onTagObj:e=>a=e});a??(a=function(e,t){if(t.tag){const r=e.filter(e=>e.tag===t.tag);if(r.length>0)return r.find(e=>e.format===t.format)??r[0]}let r,n;if(T(t)){n=t.value;let a=e.filter(e=>e.identify?.(n));if(a.length>1){const e=a.filter(e=>e.test);e.length>0&&(a=e)}r=a.find(e=>e.format===t.format)??a.find(e=>!e.format)}else n=t,r=e.find(e=>e.nodeClass&&n instanceof e.nodeClass);if(!r)throw new Error(`Tag not resolved for ${n?.constructor?.name??(null===n?"null":typeof n)} value`);return r}(t.doc.schema.tags,i));const s=function(e,t,{anchors:r,doc:n}){if(!n.directives)return"";const a=[],i=(T(e)||E(e))&&e.anchor;i&&B(i)&&(r.add(i),a.push(`&${i}`));const s=e.tag??(t.default?null:t.tag);return s&&a.push(n.directives.tagString(s)),a.join(" ")}(i,a,t);s.length>0&&(t.indentAtStart=(t.indentAtStart??0)+s.length+1);const o="function"==typeof a.stringify?a.stringify(i,t,r,n):T(i)?le(i,t,r,n):i.toString(t,r,n);return s?T(i)||"{"===o[0]||"["===o[0]?`${s} ${o}`:`${s}\n${t.indent}${o}`:o}function ue(e,t){"debug"!==e&&"warn"!==e||console.warn(t)}const me="<<",pe={identify:e=>e===me||"symbol"==typeof e&&e.description===me,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new W(Symbol(me)),{addToJSMap:he}),stringify:()=>me};function he(e,t,r){const n=Te(e,r);if(y(n))for(const r of n.items)fe(e,t,r);else if(Array.isArray(n))for(const r of n)fe(e,t,r);else fe(e,t,n)}function fe(e,t,r){const n=Te(e,r);if(!h(n))throw new Error("Merge sources must be maps or map aliases");const a=n.toJSON(null,e,Map);for(const[e,r]of a)t instanceof Map?t.has(e)||t.set(e,r):t instanceof Set?t.add(e):Object.prototype.hasOwnProperty.call(t,e)||Object.defineProperty(t,e,{value:r,writable:!0,enumerable:!0,configurable:!0});return t}function Te(e,t){return e&&m(t)?t.resolve(e.doc,e):t}function ye(e,t,{key:r,value:n}){if(C(r)&&r.addToJSMap)r.addToJSMap(e,t,n);else if(((e,t)=>(pe.identify(t)||T(t)&&(!t.type||t.type===W.PLAIN)&&pe.identify(t.value))&&e?.doc.schema.tags.some(e=>e.tag===pe.tag&&e.default))(e,r))he(e,t,n);else{const a=J(r,"",e);if(t instanceof Map)t.set(a,J(n,a,e));else if(t instanceof Set)t.add(a);else{const i=function(e,t,r){if(null===t)return"";if("object"!=typeof t)return String(t);if(C(e)&&r?.doc){const t=ce(r.doc,{});t.anchors=new Set;for(const e of r.anchors.keys())t.anchors.add(e.anchor);t.inFlow=!0,t.inStringifyKey=!0;const n=e.toString(t);if(!r.mapKeyWarned){let e=JSON.stringify(n);e.length>40&&(e=e.substring(0,36)+'..."'),ue(r.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${e}. Set mapAsMap: true to use object keys.`),r.mapKeyWarned=!0}return n}return JSON.stringify(t)}(r,a,e),s=J(n,i,e);i in t?Object.defineProperty(t,i,{value:s,writable:!0,enumerable:!0,configurable:!0}):t[i]=s}}return t}function Ee(e,t,r){const n=K(e,void 0,r),a=K(t,void 0,r);return new Ce(n,a)}class Ce{constructor(e,t=null){Object.defineProperty(this,u,{value:l}),this.key=e,this.value=t}clone(e){let{key:t,value:r}=this;return C(t)&&(t=t.clone(e)),C(r)&&(r=r.clone(e)),new Ce(t,r)}toJSON(e,t){return ye(t,t?.mapAsMap?new Map:{},this)}toString(e,t,r){return e?.doc?function({key:e,value:t},r,n,a){const{allNullValues:i,doc:s,indent:o,indentStep:l,options:{commentString:c,indentSeq:d,simpleKeys:u}}=r;let m=C(e)&&e.comment||null;if(u){if(m)throw new Error("With simple keys, key nodes cannot have comments");if(E(e)||!C(e)&&"object"==typeof e)throw new Error("With simple keys, collection cannot be used as a key value")}let p=!u&&(!e||m&&null==t&&!r.inFlow||E(e)||(T(e)?e.type===W.BLOCK_FOLDED||e.type===W.BLOCK_LITERAL:"object"==typeof e));r=Object.assign({},r,{allNullValues:!1,implicitKey:!p&&(u||!i),indent:o+l});let h,f,g,I=!1,A=!1,b=de(e,r,()=>I=!0,()=>A=!0);if(!p&&!r.inFlow&&b.length>1024){if(u)throw new Error("With simple keys, single line scalar must not span more than 1024 characters");p=!0}if(r.inFlow){if(i||null==t)return I&&n&&n(),""===b?"?":p?`? ${b}`:b}else if(i&&!u||null==t&&p)return b=`? ${b}`,m&&!I?b+=H(b,r.indent,c(m)):A&&a&&a(),b;I&&(m=null),p?(m&&(b+=H(b,r.indent,c(m))),b=`? ${b}\n${o}:`):(b=`${b}:`,m&&(b+=H(b,r.indent,c(m)))),C(t)?(h=!!t.spaceBefore,f=t.commentBefore,g=t.comment):(h=!1,f=null,g=null,t&&"object"==typeof t&&(t=s.createNode(t))),r.implicitKey=!1,p||m||!T(t)||(r.indentAtStart=b.length+1),A=!1,d||!(l.length>=2)||r.inFlow||p||!y(t)||t.flow||t.tag||t.anchor||(r.indent=r.indent.substring(2));let R=!1;const S=de(t,r,()=>R=!0,()=>A=!0);let _=" ";if(m||h||f)_=h?"\n":"",f&&(_+=`\n${q(c(f),r.indent)}`),""!==S||r.inFlow?_+=`\n${r.indent}`:"\n"===_&&g&&(_="\n\n");else if(!p&&E(t)){const e=S[0],n=S.indexOf("\n"),a=-1!==n,i=r.inFlow??t.flow??0===t.items.length;if(a||!i){let t=!1;if(a&&("&"===e||"!"===e)){let r=S.indexOf(" ");"&"===e&&-1!==r&&r<n&&"!"===S[r+1]&&(r=S.indexOf(" ",r+1)),(-1===r||n<r)&&(t=!0)}t||(_=`\n${r.indent}`)}}else""!==S&&"\n"!==S[0]||(_="");return b+=_+S,r.inFlow?R&&n&&n():g&&!R?b+=H(b,r.indent,c(g)):A&&a&&a(),b}(this,e,t,r):JSON.stringify(this)}}function ge(e,t,r){return(t.inFlow??e.flow?Ae:Ie)(e,t,r)}function Ie({comment:e,items:t},r,{blockItemPrefix:n,flowChars:a,itemIndent:i,onChompKeep:s,onComment:o}){const{indent:l,options:{commentString:c}}=r,d=Object.assign({},r,{indent:i,type:null});let u=!1;const m=[];for(let e=0;e<t.length;++e){const a=t[e];let s=null;if(C(a))!u&&a.spaceBefore&&m.push(""),be(r,m,a.commentBefore,u),a.comment&&(s=a.comment);else if(f(a)){const e=C(a.key)?a.key:null;e&&(!u&&e.spaceBefore&&m.push(""),be(r,m,e.commentBefore,u))}u=!1;let o=de(a,d,()=>s=null,()=>u=!0);s&&(o+=H(o,i,c(s))),u&&s&&(u=!1),m.push(n+o)}let p;if(0===m.length)p=a.start+a.end;else{p=m[0];for(let e=1;e<m.length;++e){const t=m[e];p+=t?`\n${l}${t}`:"\n"}}return e?(p+="\n"+q(c(e),l),o&&o()):u&&s&&s(),p}function Ae({items:e},t,{flowChars:r,itemIndent:n}){const{indent:a,indentStep:i,flowCollectionPadding:s,options:{commentString:o}}=t;n+=i;const l=Object.assign({},t,{indent:n,inFlow:!0,type:null});let c=!1,d=0;const u=[];for(let r=0;r<e.length;++r){const a=e[r];let i=null;if(C(a))a.spaceBefore&&u.push(""),be(t,u,a.commentBefore,!1),a.comment&&(i=a.comment);else if(f(a)){const e=C(a.key)?a.key:null;e&&(e.spaceBefore&&u.push(""),be(t,u,e.commentBefore,!1),e.comment&&(c=!0));const r=C(a.value)?a.value:null;r?(r.comment&&(i=r.comment),r.commentBefore&&(c=!0)):null==a.value&&e?.comment&&(i=e.comment)}i&&(c=!0);let s=de(a,l,()=>i=null);c||(c=u.length>d||s.includes("\n")),r<e.length-1?s+=",":t.options.trailingComma&&(t.options.lineWidth>0&&(c||(c=u.reduce((e,t)=>e+t.length+2,2)+(s.length+2)>t.options.lineWidth)),c&&(s+=",")),i&&(s+=H(s,n,o(i))),u.push(s),d=u.length}const{start:m,end:p}=r;if(0===u.length)return m+p;if(!c){const e=u.reduce((e,t)=>e+t.length+2,2);c=t.options.lineWidth>0&&e>t.options.lineWidth}if(c){let e=m;for(const t of u)e+=t?`\n${i}${a}${t}`:"\n";return`${e}\n${a}${p}`}return`${m}${s}${u.join(" ")}${s}${p}`}function be({indent:e,options:{commentString:t}},r,n,a){if(n&&a&&(n=n.replace(/^\n+/,"")),n){const a=q(t(n),e);r.push(a.trimStart())}}function Re(e,t){const r=T(t)?t.value:t;for(const n of e)if(f(n)){if(n.key===t||n.key===r)return n;if(T(n.key)&&n.key.value===r)return n}}class Se extends X{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(o,e),this.items=[]}static from(e,t,r){const{keepUndefined:n,replacer:a}=r,i=new this(e),s=(e,s)=>{if("function"==typeof a)s=a.call(t,e,s);else if(Array.isArray(a)&&!a.includes(e))return;(void 0!==s||n)&&i.items.push(Ee(e,s,r))};if(t instanceof Map)for(const[e,r]of t)s(e,r);else if(t&&"object"==typeof t)for(const e of Object.keys(t))s(e,t[e]);return"function"==typeof e.sortMapEntries&&i.items.sort(e.sortMapEntries),i}add(e,t){let r;r=f(e)?e:e&&"object"==typeof e&&"key"in e?new Ce(e.key,e.value):new Ce(e,e?.value);const n=Re(this.items,r.key),a=this.schema?.sortMapEntries;if(n){if(!t)throw new Error(`Key ${r.key} already set`);T(n.value)&&k(r.value)?n.value.value=r.value:n.value=r.value}else if(a){const e=this.items.findIndex(e=>a(r,e)<0);-1===e?this.items.push(r):this.items.splice(e,0,r)}else this.items.push(r)}delete(e){const t=Re(this.items,e);return!!t&&this.items.splice(this.items.indexOf(t),1).length>0}get(e,t){const r=Re(this.items,e),n=r?.value;return(!t&&T(n)?n.value:n)??void 0}has(e){return!!Re(this.items,e)}set(e,t){this.add(new Ce(e,t),!0)}toJSON(e,t,r){const n=r?new r:t?.mapAsMap?new Map:{};t?.onCreate&&t.onCreate(n);for(const e of this.items)ye(t,n,e);return n}toString(e,t,r){if(!e)return JSON.stringify(this);for(const e of this.items)if(!f(e))throw new Error(`Map items must all be pairs; found ${JSON.stringify(e)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),ge(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:r,onComment:t})}}const _e={collection:"map",default:!0,nodeClass:Se,tag:"tag:yaml.org,2002:map",resolve:(e,t)=>(h(e)||t("Expected a mapping for this tag"),e),createNode:(e,t,r)=>Se.from(e,t,r)};class ve extends X{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(d,e),this.items=[]}add(e){this.items.push(e)}delete(e){const t=Ne(e);return"number"==typeof t&&this.items.splice(t,1).length>0}get(e,t){const r=Ne(e);if("number"!=typeof r)return;const n=this.items[r];return!t&&T(n)?n.value:n}has(e){const t=Ne(e);return"number"==typeof t&&t<this.items.length}set(e,t){const r=Ne(e);if("number"!=typeof r)throw new Error(`Expected a valid index, not ${e}.`);const n=this.items[r];T(n)&&k(t)?n.value=t:this.items[r]=t}toJSON(e,t){const r=[];t?.onCreate&&t.onCreate(r);let n=0;for(const e of this.items)r.push(J(e,String(n++),t));return r}toString(e,t,r){return e?ge(this,e,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:(e.indent||"")+" ",onChompKeep:r,onComment:t}):JSON.stringify(this)}static from(e,t,r){const{replacer:n}=r,a=new this(e);if(t&&Symbol.iterator in Object(t)){let e=0;for(let i of t){if("function"==typeof n){const r=t instanceof Set?i:String(e++);i=n.call(t,r,i)}a.items.push(K(i,void 0,r))}}return a}}function Ne(e){let t=T(e)?e.value:e;return t&&"string"==typeof t&&(t=Number(t)),"number"==typeof t&&Number.isInteger(t)&&t>=0?t:null}const we={collection:"seq",default:!0,nodeClass:ve,tag:"tag:yaml.org,2002:seq",resolve:(e,t)=>(y(e)||t("Expected a sequence for this tag"),e),createNode:(e,t,r)=>ve.from(e,t,r)},Le={identify:e=>"string"==typeof e,default:!0,tag:"tag:yaml.org,2002:str",resolve:e=>e,stringify:(e,t,r,n)=>le(e,t=Object.assign({actualString:!0},t),r,n)},Fe={identify:e=>null==e,createNode:()=>new W(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new W(null),stringify:({source:e},t)=>"string"==typeof e&&Fe.test.test(e)?e:t.options.nullStr},Oe={identify:e=>"boolean"==typeof e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:e=>new W("t"===e[0]||"T"===e[0]),stringify:({source:e,value:t},r)=>e&&Oe.test.test(e)&&t===("t"===e[0]||"T"===e[0])?e:t?r.options.trueStr:r.options.falseStr};function Ve({format:e,minFractionDigits:t,tag:r,value:n}){if("bigint"==typeof n)return String(n);const a="number"==typeof n?n:Number(n);if(!isFinite(a))return isNaN(a)?".nan":a<0?"-.inf":".inf";let i=Object.is(n,-0)?"-0":JSON.stringify(n);if(!e&&t&&(!r||"tag:yaml.org,2002:float"===r)&&/^-?\d/.test(i)&&!i.includes("e")){let e=i.indexOf(".");e<0&&(e=i.length,i+=".");let r=t-(i.length-e-1);for(;r-- >0;)i+="0"}return i}const Be={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>"nan"===e.slice(-3).toLowerCase()?NaN:"-"===e[0]?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:Ve},De={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e),stringify(e){const t=Number(e.value);return isFinite(t)?t.toExponential():Ve(e)}},Me={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(e){const t=new W(parseFloat(e)),r=e.indexOf(".");return-1!==r&&"0"===e[e.length-1]&&(t.minFractionDigits=e.length-r-1),t},stringify:Ve},Ue=e=>"bigint"==typeof e||Number.isInteger(e),Je=(e,t,r,{intAsBigInt:n})=>n?BigInt(e):parseInt(e.substring(t),r);function Ye(e,t,r){const{value:n}=e;return Ue(n)&&n>=0?r+n.toString(t):Ve(e)}const xe={identify:e=>Ue(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:(e,t,r)=>Je(e,2,8,r),stringify:e=>Ye(e,8,"0o")},Pe={identify:Ue,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:(e,t,r)=>Je(e,0,10,r),stringify:Ve},ke={identify:e=>Ue(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:(e,t,r)=>Je(e,2,16,r),stringify:e=>Ye(e,16,"0x")},We=[_e,we,Le,Fe,Oe,xe,Pe,ke,Be,De,Me];function Ke(e){return"bigint"==typeof e||Number.isInteger(e)}const je=({value:e})=>JSON.stringify(e),Ge=[_e,we].concat([{identify:e=>"string"==typeof e,default:!0,tag:"tag:yaml.org,2002:str",resolve:e=>e,stringify:je},{identify:e=>null==e,createNode:()=>new W(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:je},{identify:e=>"boolean"==typeof e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^true$|^false$/,resolve:e=>"true"===e,stringify:je},{identify:Ke,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(e,t,{intAsBigInt:r})=>r?BigInt(e):parseInt(e,10),stringify:({value:e})=>Ke(e)?e.toString():JSON.stringify(e)},{identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:e=>parseFloat(e),stringify:je}],{default:!0,tag:"",test:/^/,resolve:(e,t)=>(t(`Unresolved plain scalar ${JSON.stringify(e)}`),e)}),Xe={identify:e=>e instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve(e,t){if("function"==typeof atob){const t=atob(e.replace(/[\n\r]/g,"")),r=new Uint8Array(t.length);for(let e=0;e<t.length;++e)r[e]=t.charCodeAt(e);return r}return t("This environment does not support reading binary tags; either Buffer or atob is required"),e},stringify({comment:e,type:t,value:r},n,a,i){if(!r)return"";const s=r;let o;if("function"!=typeof btoa)throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required");{let e="";for(let t=0;t<s.length;++t)e+=String.fromCharCode(s[t]);o=btoa(e)}if(t??(t=W.BLOCK_LITERAL),t!==W.QUOTE_DOUBLE){const e=Math.max(n.options.lineWidth-n.indent.length,n.options.minContentWidth),r=Math.ceil(o.length/e),a=new Array(r);for(let t=0,n=0;t<r;++t,n+=e)a[t]=o.substr(n,e);o=a.join(t===W.BLOCK_LITERAL?"\n":" ")}return le({comment:e,type:t,value:o},n,a,i)}};function $e(e,t){if(y(e))for(let r=0;r<e.items.length;++r){let n=e.items[r];if(!f(n)){if(h(n)){n.items.length>1&&t("Each pair must have its own sequence indicator");const e=n.items[0]||new Ce(new W(null));if(n.commentBefore&&(e.key.commentBefore=e.key.commentBefore?`${n.commentBefore}\n${e.key.commentBefore}`:n.commentBefore),n.comment){const t=e.value??e.key;t.comment=t.comment?`${n.comment}\n${t.comment}`:n.comment}n=e}e.items[r]=f(n)?n:new Ce(n)}}else t("Expected a sequence for this tag");return e}function qe(e,t,r){const{replacer:n}=r,a=new ve(e);a.tag="tag:yaml.org,2002:pairs";let i=0;if(t&&Symbol.iterator in Object(t))for(let e of t){let s,o;if("function"==typeof n&&(e=n.call(t,String(i++),e)),Array.isArray(e)){if(2!==e.length)throw new TypeError(`Expected [key, value] tuple: ${e}`);s=e[0],o=e[1]}else if(e&&e instanceof Object){const t=Object.keys(e);if(1!==t.length)throw new TypeError(`Expected tuple with one key, not ${t.length} keys`);s=t[0],o=e[s]}else s=e;a.items.push(Ee(s,o,r))}return a}const He={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:$e,createNode:qe};class ze extends ve{constructor(){super(),this.add=Se.prototype.add.bind(this),this.delete=Se.prototype.delete.bind(this),this.get=Se.prototype.get.bind(this),this.has=Se.prototype.has.bind(this),this.set=Se.prototype.set.bind(this),this.tag=ze.tag}toJSON(e,t){if(!t)return super.toJSON(e);const r=new Map;t?.onCreate&&t.onCreate(r);for(const e of this.items){let n,a;if(f(e)?(n=J(e.key,"",t),a=J(e.value,n,t)):n=J(e,"",t),r.has(n))throw new Error("Ordered maps must not include duplicate keys");r.set(n,a)}return r}static from(e,t,r){const n=qe(e,t,r),a=new this;return a.items=n.items,a}}ze.tag="tag:yaml.org,2002:omap";const Qe={collection:"seq",identify:e=>e instanceof Map,nodeClass:ze,default:!1,tag:"tag:yaml.org,2002:omap",resolve(e,t){const r=$e(e,t),n=[];for(const{key:e}of r.items)T(e)&&(n.includes(e.value)?t(`Ordered maps must not include duplicate keys: ${e.value}`):n.push(e.value));return Object.assign(new ze,r)},createNode:(e,t,r)=>ze.from(e,t,r)};function Ze({value:e,source:t},r){return t&&(e?et:tt).test.test(t)?t:e?r.options.trueStr:r.options.falseStr}const et={identify:e=>!0===e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new W(!0),stringify:Ze},tt={identify:e=>!1===e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new W(!1),stringify:Ze},rt={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>"nan"===e.slice(-3).toLowerCase()?NaN:"-"===e[0]?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:Ve},nt={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e.replace(/_/g,"")),stringify(e){const t=Number(e.value);return isFinite(t)?t.toExponential():Ve(e)}},at={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(e){const t=new W(parseFloat(e.replace(/_/g,""))),r=e.indexOf(".");if(-1!==r){const n=e.substring(r+1).replace(/_/g,"");"0"===n[n.length-1]&&(t.minFractionDigits=n.length)}return t},stringify:Ve},it=e=>"bigint"==typeof e||Number.isInteger(e);function st(e,t,r,{intAsBigInt:n}){const a=e[0];if("-"!==a&&"+"!==a||(t+=1),e=e.substring(t).replace(/_/g,""),n){switch(r){case 2:e=`0b${e}`;break;case 8:e=`0o${e}`;break;case 16:e=`0x${e}`}const t=BigInt(e);return"-"===a?BigInt(-1)*t:t}const i=parseInt(e,r);return"-"===a?-1*i:i}function ot(e,t,r){const{value:n}=e;if(it(n)){const e=n.toString(t);return n<0?"-"+r+e.substr(1):r+e}return Ve(e)}const lt={identify:it,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(e,t,r)=>st(e,2,2,r),stringify:e=>ot(e,2,"0b")},ct={identify:it,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(e,t,r)=>st(e,1,8,r),stringify:e=>ot(e,8,"0")},dt={identify:it,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(e,t,r)=>st(e,0,10,r),stringify:Ve},ut={identify:it,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(e,t,r)=>st(e,2,16,r),stringify:e=>ot(e,16,"0x")};class mt extends Se{constructor(e){super(e),this.tag=mt.tag}add(e){let t;t=f(e)?e:e&&"object"==typeof e&&"key"in e&&"value"in e&&null===e.value?new Ce(e.key,null):new Ce(e,null),Re(this.items,t.key)||this.items.push(t)}get(e,t){const r=Re(this.items,e);return!t&&f(r)?T(r.key)?r.key.value:r.key:r}set(e,t){if("boolean"!=typeof t)throw new Error("Expected boolean value for set(key, value) in a YAML set, not "+typeof t);const r=Re(this.items,e);r&&!t?this.items.splice(this.items.indexOf(r),1):!r&&t&&this.items.push(new Ce(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,r){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,r);throw new Error("Set items must all have null values")}static from(e,t,r){const{replacer:n}=r,a=new this(e);if(t&&Symbol.iterator in Object(t))for(let e of t)"function"==typeof n&&(e=n.call(t,e,e)),a.items.push(Ee(e,null,r));return a}}mt.tag="tag:yaml.org,2002:set";const pt={collection:"map",identify:e=>e instanceof Set,nodeClass:mt,default:!1,tag:"tag:yaml.org,2002:set",createNode:(e,t,r)=>mt.from(e,t,r),resolve(e,t){if(h(e)){if(e.hasAllNullValues(!0))return Object.assign(new mt,e);t("Set items must all have null values")}else t("Expected a mapping for this tag");return e}};function ht(e,t){const r=e[0],n="-"===r||"+"===r?e.substring(1):e,a=e=>t?BigInt(e):Number(e),i=n.replace(/_/g,"").split(":").reduce((e,t)=>e*a(60)+a(t),a(0));return"-"===r?a(-1)*i:i}function ft(e){let{value:t}=e,r=e=>e;if("bigint"==typeof t)r=e=>BigInt(e);else if(isNaN(t)||!isFinite(t))return Ve(e);let n="";t<0&&(n="-",t*=r(-1));const a=r(60),i=[t%a];return t<60?i.unshift(0):(t=(t-i[0])/a,i.unshift(t%a),t>=60&&(t=(t-i[0])/a,i.unshift(t))),n+i.map(e=>String(e).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}const Tt={identify:e=>"bigint"==typeof e||Number.isInteger(e),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(e,t,{intAsBigInt:r})=>ht(e,r),stringify:ft},yt={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:e=>ht(e,!1),stringify:ft},Et={identify:e=>e instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve(e){const t=e.match(Et.test);if(!t)throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd");const[,r,n,a,i,s,o]=t.map(Number),l=t[7]?Number((t[7]+"00").substr(1,3)):0;let c=Date.UTC(r,n-1,a,i||0,s||0,o||0,l);const d=t[8];if(d&&"Z"!==d){let e=ht(d,!1);Math.abs(e)<30&&(e*=60),c-=6e4*e}return new Date(c)},stringify:({value:e})=>e?.toISOString().replace(/(T00:00:00)?\.000Z$/,"")??""},Ct=[_e,we,Le,Fe,et,tt,lt,ct,dt,ut,rt,nt,at,Xe,pe,Qe,He,pt,Tt,yt,Et],gt=new Map([["core",We],["failsafe",[_e,we,Le]],["json",Ge],["yaml11",Ct],["yaml-1.1",Ct]]),It={binary:Xe,bool:Oe,float:Me,floatExp:De,floatNaN:Be,floatTime:yt,int:Pe,intHex:ke,intOct:xe,intTime:Tt,map:_e,merge:pe,null:Fe,omap:Qe,pairs:He,seq:we,set:pt,timestamp:Et},At={"tag:yaml.org,2002:binary":Xe,"tag:yaml.org,2002:merge":pe,"tag:yaml.org,2002:omap":Qe,"tag:yaml.org,2002:pairs":He,"tag:yaml.org,2002:set":pt,"tag:yaml.org,2002:timestamp":Et};function bt(e,t,r){const n=gt.get(t);if(n&&!e)return r&&!n.includes(pe)?n.concat(pe):n.slice();let a=n;if(!a){if(!Array.isArray(e)){const e=Array.from(gt.keys()).filter(e=>"yaml11"!==e).map(e=>JSON.stringify(e)).join(", ");throw new Error(`Unknown schema "${t}"; use one of ${e} or define customTags array`)}a=[]}if(Array.isArray(e))for(const t of e)a=a.concat(t);else"function"==typeof e&&(a=e(a.slice()));return r&&(a=a.concat(pe)),a.reduce((e,t)=>{const r="string"==typeof t?It[t]:t;if(!r){const e=JSON.stringify(t),r=Object.keys(It).map(e=>JSON.stringify(e)).join(", ");throw new Error(`Unknown custom tag ${e}; use one of ${r}`)}return e.includes(r)||e.push(r),e},[])}const Rt=(e,t)=>e.key<t.key?-1:e.key>t.key?1:0;class St{constructor({compat:e,customTags:t,merge:r,resolveKnownTags:n,schema:a,sortMapEntries:i,toStringDefaults:s}){this.compat=Array.isArray(e)?bt(e,"compat"):e?bt(null,e):null,this.name="string"==typeof a&&a||"core",this.knownTags=n?At:{},this.tags=bt(t,this.name,r),this.toStringOptions=s??null,Object.defineProperty(this,o,{value:_e}),Object.defineProperty(this,c,{value:Le}),Object.defineProperty(this,d,{value:we}),this.sortMapEntries="function"==typeof i?i:!0===i?Rt:null}clone(){const e=Object.create(St.prototype,Object.getOwnPropertyDescriptors(this));return e.tags=this.tags.slice(),e}}class _t{constructor(e,t,r){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,u,{value:s});let n=null;"function"==typeof t||Array.isArray(t)?n=t:void 0===r&&t&&(r=t,t=void 0);const a=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},r);this.options=a;let{version:i}=a;r?._directives?(this.directives=r._directives.atDocument(),this.directives.yaml.explicit&&(i=this.directives.yaml.version)):this.directives=new V({version:i}),this.setSchema(i,r),this.contents=void 0===e?null:this.createNode(e,n,r)}clone(){const e=Object.create(_t.prototype,{[u]:{value:s}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=C(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){vt(this.contents)&&this.contents.add(e)}addIn(e,t){vt(this.contents)&&this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){const r=D(this);e.anchor=!t||r.has(t)?M(t||"a",r):t}return new x(e.anchor)}createNode(e,t,r){let n;if("function"==typeof t)e=t.call({"":e},"",e),n=t;else if(Array.isArray(t)){const e=e=>"number"==typeof e||e instanceof String||e instanceof Number,r=t.filter(e).map(String);r.length>0&&(t=t.concat(r)),n=t}else void 0===r&&t&&(r=t,t=void 0);const{aliasDuplicateObjects:a,anchorPrefix:i,flow:s,keepUndefined:o,onTagObj:l,tag:c}=r??{},{onAnchor:d,setAnchors:u,sourceObjects:m}=function(e,t){const r=[],n=new Map;let a=null;return{onAnchor:n=>{r.push(n),a??(a=D(e));const i=M(t,a);return a.add(i),i},setAnchors:()=>{for(const e of r){const t=n.get(e);if("object"!=typeof t||!t.anchor||!T(t.node)&&!E(t.node)){const t=new Error("Failed to resolve repeated object (this should not happen)");throw t.source=e,t}t.node.anchor=t.anchor}},sourceObjects:n}}(this,i||"a"),p=K(e,c,{aliasDuplicateObjects:a??!0,keepUndefined:o??!1,onAnchor:d,onTagObj:l,replacer:n,schema:this.schema,sourceObjects:m});return s&&E(p)&&(p.flow=!0),u(),p}createPair(e,t,r={}){const n=this.createNode(e,null,r),a=this.createNode(t,null,r);return new Ce(n,a)}delete(e){return!!vt(this.contents)&&this.contents.delete(e)}deleteIn(e){return G(e)?null!=this.contents&&(this.contents=null,!0):!!vt(this.contents)&&this.contents.deleteIn(e)}get(e,t){return E(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){return G(e)?!t&&T(this.contents)?this.contents.value:this.contents:E(this.contents)?this.contents.getIn(e,t):void 0}has(e){return!!E(this.contents)&&this.contents.has(e)}hasIn(e){return G(e)?void 0!==this.contents:!!E(this.contents)&&this.contents.hasIn(e)}set(e,t){null==this.contents?this.contents=j(this.schema,[e],t):vt(this.contents)&&this.contents.set(e,t)}setIn(e,t){G(e)?this.contents=t:null==this.contents?this.contents=j(this.schema,Array.from(e),t):vt(this.contents)&&this.contents.setIn(e,t)}setSchema(e,t={}){let r;switch("number"==typeof e&&(e=String(e)),e){case"1.1":this.directives?this.directives.yaml.version="1.1":this.directives=new V({version:"1.1"}),r={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":this.directives?this.directives.yaml.version=e:this.directives=new V({version:e}),r={resolveKnownTags:!0,schema:"core"};break;case null:this.directives&&delete this.directives,r=null;break;default:{const t=JSON.stringify(e);throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${t}`)}}if(t.schema instanceof Object)this.schema=t.schema;else{if(!r)throw new Error("With a null YAML version, the { schema: Schema } option is required");this.schema=new St(Object.assign(r,t))}}toJS({json:e,jsonArg:t,mapAsMap:r,maxAliasCount:n,onAnchor:a,reviver:i}={}){const s={anchors:new Map,doc:this,keep:!e,mapAsMap:!0===r,mapKeyWarned:!1,maxAliasCount:"number"==typeof n?n:100},o=J(this.contents,t??"",s);if("function"==typeof a)for(const{count:e,res:t}of s.anchors.values())a(t,e);return"function"==typeof i?U(i,{"":o},"",o):o}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw new Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){const t=JSON.stringify(e.indent);throw new Error(`"indent" option must be a positive integer, not ${t}`)}return function(e,t){const r=[];let n=!0===t.directives;if(!1!==t.directives&&e.directives){const t=e.directives.toString(e);t?(r.push(t),n=!0):e.directives.docStart&&(n=!0)}n&&r.push("---");const a=ce(e,t),{commentString:i}=a.options;if(e.commentBefore){1!==r.length&&r.unshift("");const t=i(e.commentBefore);r.unshift(q(t,""))}let s=!1,o=null;if(e.contents){if(C(e.contents)){if(e.contents.spaceBefore&&n&&r.push(""),e.contents.commentBefore){const t=i(e.contents.commentBefore);r.push(q(t,""))}a.forceBlockIndent=!!e.comment,o=e.contents.comment}const t=o?void 0:()=>s=!0;let l=de(e.contents,a,()=>o=null,t);o&&(l+=H(l,"",i(o))),"|"!==l[0]&&">"!==l[0]||"---"!==r[r.length-1]?r.push(l):r[r.length-1]=`--- ${l}`}else r.push(de(e.contents,a));if(e.directives?.docEnd)if(e.comment){const t=i(e.comment);t.includes("\n")?(r.push("..."),r.push(q(t,""))):r.push(`... ${t}`)}else r.push("...");else{let t=e.comment;t&&s&&(t=t.replace(/^\n+/,"")),t&&(s&&!o||""===r[r.length-1]||r.push(""),r.push(q(i(t),"")))}return r.join("\n")+"\n"}(this,e)}}function vt(e){if(E(e))return!0;throw new Error("Expected a YAML collection as document contents")}class Nt extends Error{constructor(e,t,r,n){super(),this.name=e,this.code=r,this.message=n,this.pos=t}}class wt extends Nt{constructor(e,t,r){super("YAMLParseError",e,t,r)}}class Lt extends Nt{constructor(e,t,r){super("YAMLWarning",e,t,r)}}const Ft=(e,t)=>r=>{if(-1===r.pos[0])return;r.linePos=r.pos.map(e=>t.linePos(e));const{line:n,col:a}=r.linePos[0];r.message+=` at line ${n}, column ${a}`;let i=a-1,s=e.substring(t.lineStarts[n-1],t.lineStarts[n]).replace(/[\n\r]+$/,"");if(i>=60&&s.length>80){const e=Math.min(i-39,s.length-79);s="…"+s.substring(e),i-=e-1}if(s.length>80&&(s=s.substring(0,79)+"…"),n>1&&/^ *$/.test(s.substring(0,i))){let r=e.substring(t.lineStarts[n-2],t.lineStarts[n-1]);r.length>80&&(r=r.substring(0,79)+"…\n"),s=r+s}if(/[^ ]/.test(s)){let e=1;const t=r.linePos[1];t?.line===n&&t.col>a&&(e=Math.max(1,Math.min(t.col-a,80-i)));const o=" ".repeat(i)+"^".repeat(e);r.message+=`:\n\n${s}\n${o}\n`}};function Ot(e,{flow:t,indicator:r,next:n,offset:a,onError:i,parentIndent:s,startOnNewline:o}){let l=!1,c=o,d=o,u="",m="",p=!1,h=!1,f=null,T=null,y=null,E=null,C=null,g=null,I=null;for(const a of e)switch(h&&("space"!==a.type&&"newline"!==a.type&&"comma"!==a.type&&i(a.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),h=!1),f&&(c&&"comment"!==a.type&&"newline"!==a.type&&i(f,"TAB_AS_INDENT","Tabs are not allowed as indentation"),f=null),a.type){case"space":t||"doc-start"===r&&"flow-collection"===n?.type||!a.source.includes("\t")||(f=a),d=!0;break;case"comment":{d||i(a,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const e=a.source.substring(1)||" ";u?u+=m+e:u=e,m="",c=!1;break}case"newline":c?u?u+=a.source:g&&"seq-item-ind"===r||(l=!0):m+=a.source,c=!0,p=!0,(T||y)&&(E=a),d=!0;break;case"anchor":T&&i(a,"MULTIPLE_ANCHORS","A node can have at most one anchor"),a.source.endsWith(":")&&i(a.offset+a.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0),T=a,I??(I=a.offset),c=!1,d=!1,h=!0;break;case"tag":y&&i(a,"MULTIPLE_TAGS","A node can have at most one tag"),y=a,I??(I=a.offset),c=!1,d=!1,h=!0;break;case r:(T||y)&&i(a,"BAD_PROP_ORDER",`Anchors and tags must be after the ${a.source} indicator`),g&&i(a,"UNEXPECTED_TOKEN",`Unexpected ${a.source} in ${t??"collection"}`),g=a,c="seq-item-ind"===r||"explicit-key-ind"===r,d=!1;break;case"comma":if(t){C&&i(a,"UNEXPECTED_TOKEN",`Unexpected , in ${t}`),C=a,c=!1,d=!1;break}default:i(a,"UNEXPECTED_TOKEN",`Unexpected ${a.type} token`),c=!1,d=!1}const A=e[e.length-1],b=A?A.offset+A.source.length:a;return h&&n&&"space"!==n.type&&"newline"!==n.type&&"comma"!==n.type&&("scalar"!==n.type||""!==n.source)&&i(n.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),f&&(c&&f.indent<=s||"block-map"===n?.type||"block-seq"===n?.type)&&i(f,"TAB_AS_INDENT","Tabs are not allowed as indentation"),{comma:C,found:g,spaceBefore:l,comment:u,hasNewline:p,anchor:T,tag:y,newlineAfterProp:E,end:b,start:I??b}}function Vt(e){if(!e)return null;switch(e.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(e.source.includes("\n"))return!0;if(e.end)for(const t of e.end)if("newline"===t.type)return!0;return!1;case"flow-collection":for(const t of e.items){for(const e of t.start)if("newline"===e.type)return!0;if(t.sep)for(const e of t.sep)if("newline"===e.type)return!0;if(Vt(t.key)||Vt(t.value))return!0}return!1;default:return!0}}function Bt(e,t,r){if("flow-collection"===t?.type){const n=t.end[0];n.indent!==e||"]"!==n.source&&"}"!==n.source||!Vt(t)||r(n,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}function Dt(e,t,r){const{uniqueKeys:n}=e.options;if(!1===n)return!1;const a="function"==typeof n?n:(e,t)=>e===t||T(e)&&T(t)&&e.value===t.value;return t.some(e=>a(e.key,r))}const Mt="All mapping items must start at the same column";function Ut(e,t,r,n){let a="";if(e){let i=!1,s="";for(const o of e){const{source:e,type:l}=o;switch(l){case"space":i=!0;break;case"comment":{r&&!i&&n(o,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const t=e.substring(1)||" ";a?a+=s+t:a=t,s="";break}case"newline":a&&(s+=e),i=!0;break;default:n(o,"UNEXPECTED_TOKEN",`Unexpected ${l} at node end`)}t+=e.length}}return{comment:a,offset:t}}const Jt="Block collections are not allowed within flow collections",Yt=e=>e&&("block-map"===e.type||"block-seq"===e.type);function xt(e,t,r,n,a,i){const s="block-map"===r.type?function({composeNode:e,composeEmptyNode:t},r,n,a,i){const s=new(i?.nodeClass??Se)(r.schema);r.atRoot&&(r.atRoot=!1);let o=n.offset,l=null;for(const i of n.items){const{start:c,key:d,sep:u,value:m}=i,p=Ot(c,{indicator:"explicit-key-ind",next:d??u?.[0],offset:o,onError:a,parentIndent:n.indent,startOnNewline:!0}),h=!p.found;if(h){if(d&&("block-seq"===d.type?a(o,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key"):"indent"in d&&d.indent!==n.indent&&a(o,"BAD_INDENT",Mt)),!p.anchor&&!p.tag&&!u){l=p.end,p.comment&&(s.comment?s.comment+="\n"+p.comment:s.comment=p.comment);continue}(p.newlineAfterProp||Vt(d))&&a(d??c[c.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else p.found?.indent!==n.indent&&a(o,"BAD_INDENT",Mt);r.atKey=!0;const f=p.end,T=d?e(r,d,p,a):t(r,f,c,null,p,a);r.schema.compat&&Bt(n.indent,d,a),r.atKey=!1,Dt(r,s.items,T)&&a(f,"DUPLICATE_KEY","Map keys must be unique");const y=Ot(u??[],{indicator:"map-value-ind",next:m,offset:T.range[2],onError:a,parentIndent:n.indent,startOnNewline:!d||"block-scalar"===d.type});if(o=y.end,y.found){h&&("block-map"!==m?.type||y.hasNewline||a(o,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings"),r.options.strict&&p.start<y.found.offset-1024&&a(T.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));const l=m?e(r,m,y,a):t(r,o,u,null,y,a);r.schema.compat&&Bt(n.indent,m,a),o=l.range[2];const c=new Ce(T,l);r.options.keepSourceTokens&&(c.srcToken=i),s.items.push(c)}else{h&&a(T.range,"MISSING_CHAR","Implicit map keys need to be followed by map values"),y.comment&&(T.comment?T.comment+="\n"+y.comment:T.comment=y.comment);const e=new Ce(T);r.options.keepSourceTokens&&(e.srcToken=i),s.items.push(e)}}return l&&l<o&&a(l,"IMPOSSIBLE","Map comment with trailing content"),s.range=[n.offset,o,l??o],s}(e,t,r,n,i):"block-seq"===r.type?function({composeNode:e,composeEmptyNode:t},r,n,a,i){const s=new(i?.nodeClass??ve)(r.schema);r.atRoot&&(r.atRoot=!1),r.atKey&&(r.atKey=!1);let o=n.offset,l=null;for(const{start:i,value:c}of n.items){const d=Ot(i,{indicator:"seq-item-ind",next:c,offset:o,onError:a,parentIndent:n.indent,startOnNewline:!0});if(!d.found){if(!(d.anchor||d.tag||c)){l=d.end,d.comment&&(s.comment=d.comment);continue}"block-seq"===c?.type?a(d.end,"BAD_INDENT","All sequence items must start at the same column"):a(o,"MISSING_CHAR","Sequence item without - indicator")}const u=c?e(r,c,d,a):t(r,d.end,i,null,d,a);r.schema.compat&&Bt(n.indent,c,a),o=u.range[2],s.items.push(u)}return s.range=[n.offset,o,l??o],s}(e,t,r,n,i):function({composeNode:e,composeEmptyNode:t},r,n,a,i){const s="{"===n.start.source,o=s?"flow map":"flow sequence",l=new(i?.nodeClass??(s?Se:ve))(r.schema);l.flow=!0;const c=r.atRoot;c&&(r.atRoot=!1),r.atKey&&(r.atKey=!1);let d=n.offset+n.start.source.length;for(let i=0;i<n.items.length;++i){const c=n.items[i],{start:u,key:m,sep:p,value:h}=c,T=Ot(u,{flow:o,indicator:"explicit-key-ind",next:m??p?.[0],offset:d,onError:a,parentIndent:n.indent,startOnNewline:!1});if(!T.found){if(!(T.anchor||T.tag||p||h)){0===i&&T.comma?a(T.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${o}`):i<n.items.length-1&&a(T.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${o}`),T.comment&&(l.comment?l.comment+="\n"+T.comment:l.comment=T.comment),d=T.end;continue}!s&&r.options.strict&&Vt(m)&&a(m,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(0===i)T.comma&&a(T.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${o}`);else if(T.comma||a(T.start,"MISSING_CHAR",`Missing , between ${o} items`),T.comment){let e="";e:for(const t of u)switch(t.type){case"comma":case"space":break;case"comment":e=t.source.substring(1);break e;default:break e}if(e){let t=l.items[l.items.length-1];f(t)&&(t=t.value??t.key),t.comment?t.comment+="\n"+e:t.comment=e,T.comment=T.comment.substring(e.length+1)}}if(s||p||T.found){r.atKey=!0;const i=T.end,f=m?e(r,m,T,a):t(r,i,u,null,T,a);Yt(m)&&a(f.range,"BLOCK_IN_FLOW",Jt),r.atKey=!1;const y=Ot(p??[],{flow:o,indicator:"map-value-ind",next:h,offset:f.range[2],onError:a,parentIndent:n.indent,startOnNewline:!1});if(y.found){if(!s&&!T.found&&r.options.strict){if(p)for(const e of p){if(e===y.found)break;if("newline"===e.type){a(e,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}T.start<y.found.offset-1024&&a(y.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else h&&("source"in h&&":"===h.source?.[0]?a(h,"MISSING_CHAR",`Missing space after : in ${o}`):a(y.start,"MISSING_CHAR",`Missing , or : between ${o} items`));const E=h?e(r,h,y,a):y.found?t(r,y.end,p,null,y,a):null;E?Yt(h)&&a(E.range,"BLOCK_IN_FLOW",Jt):y.comment&&(f.comment?f.comment+="\n"+y.comment:f.comment=y.comment);const C=new Ce(f,E);if(r.options.keepSourceTokens&&(C.srcToken=c),s){const e=l;Dt(r,e.items,f)&&a(i,"DUPLICATE_KEY","Map keys must be unique"),e.items.push(C)}else{const e=new Se(r.schema);e.flow=!0,e.items.push(C);const t=(E??f).range;e.range=[f.range[0],t[1],t[2]],l.items.push(e)}d=E?E.range[2]:y.end}else{const n=h?e(r,h,T,a):t(r,T.end,p,null,T,a);l.items.push(n),d=n.range[2],Yt(h)&&a(n.range,"BLOCK_IN_FLOW",Jt)}}const u=s?"}":"]",[m,...p]=n.end;let h=d;if(m?.source===u)h=m.offset+m.source.length;else{const e=o[0].toUpperCase()+o.substring(1);a(d,c?"MISSING_CHAR":"BAD_INDENT",c?`${e} must end with a ${u}`:`${e} in block collection must be sufficiently indented and end with a ${u}`),m&&1!==m.source.length&&p.unshift(m)}if(p.length>0){const e=Ut(p,h,r.options.strict,a);e.comment&&(l.comment?l.comment+="\n"+e.comment:l.comment=e.comment),l.range=[n.offset,h,e.offset]}else l.range=[n.offset,h,h];return l}(e,t,r,n,i),o=s.constructor;return"!"===a||a===o.tagName?(s.tag=o.tagName,s):(a&&(s.tag=a),s)}function Pt(e,t,r){const n=t.offset,a=function({offset:e,props:t},r,n){if("block-scalar-header"!==t[0].type)return n(t[0],"IMPOSSIBLE","Block scalar header not found"),null;const{source:a}=t[0],i=a[0];let s=0,o="",l=-1;for(let t=1;t<a.length;++t){const r=a[t];if(o||"-"!==r&&"+"!==r){const n=Number(r);!s&&n?s=n:-1===l&&(l=e+t)}else o=r}-1!==l&&n(l,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${a}`);let c=!1,d="",u=a.length;for(let e=1;e<t.length;++e){const a=t[e];switch(a.type){case"space":c=!0;case"newline":u+=a.source.length;break;case"comment":r&&!c&&n(a,"MISSING_CHAR","Comments must be separated from other tokens by white space characters"),u+=a.source.length,d=a.source.substring(1);break;case"error":n(a,"UNEXPECTED_TOKEN",a.message),u+=a.source.length;break;default:{n(a,"UNEXPECTED_TOKEN",`Unexpected token in block scalar header: ${a.type}`);const e=a.source;e&&"string"==typeof e&&(u+=e.length)}}}return{mode:i,indent:s,chomp:o,comment:d,length:u}}(t,e.options.strict,r);if(!a)return{value:"",type:null,comment:"",range:[n,n,n]};const i=">"===a.mode?W.BLOCK_FOLDED:W.BLOCK_LITERAL,s=t.source?function(e){const t=e.split(/\n( *)/),r=t[0],n=r.match(/^( *)/),a=[n?.[1]?[n[1],r.slice(n[1].length)]:["",r]];for(let e=1;e<t.length;e+=2)a.push([t[e],t[e+1]]);return a}(t.source):[];let o=s.length;for(let e=s.length-1;e>=0;--e){const t=s[e][1];if(""!==t&&"\r"!==t)break;o=e}if(0===o){const e="+"===a.chomp&&s.length>0?"\n".repeat(Math.max(1,s.length-1)):"";let r=n+a.length;return t.source&&(r+=t.source.length),{value:e,type:i,comment:a.comment,range:[n,r,r]}}let l=t.indent+a.indent,c=t.offset+a.length,d=0;for(let t=0;t<o;++t){const[n,i]=s[t];if(""!==i&&"\r"!==i){if(n.length<l){const e="Block scalars with more-indented leading empty lines must use an explicit indentation indicator";r(c+n.length,"MISSING_CHAR",e)}0===a.indent&&(l=n.length),d=t,0!==l||e.atRoot||r(c,"BAD_INDENT","Block scalar values in collections must be indented");break}0===a.indent&&n.length>l&&(l=n.length),c+=n.length+i.length+1}for(let e=s.length-1;e>=o;--e)s[e][0].length>l&&(o=e+1);let u="",m="",p=!1;for(let e=0;e<d;++e)u+=s[e][0].slice(l)+"\n";for(let e=d;e<o;++e){let[t,n]=s[e];c+=t.length+n.length+1;const o="\r"===n[n.length-1];if(o&&(n=n.slice(0,-1)),n&&t.length<l){const e="Block scalar lines must not be less indented than their "+(a.indent?"explicit indentation indicator":"first line");r(c-n.length-(o?2:1),"BAD_INDENT",e),t=""}i===W.BLOCK_LITERAL?(u+=m+t.slice(l)+n,m="\n"):t.length>l||"\t"===n[0]?(" "===m?m="\n":p||"\n"!==m||(m="\n\n"),u+=m+t.slice(l)+n,m="\n",p=!0):""===n?"\n"===m?u+="\n":m="\n":(u+=m+n,m=" ",p=!1)}switch(a.chomp){case"-":break;case"+":for(let e=o;e<s.length;++e)u+="\n"+s[e][0].slice(l);"\n"!==u[u.length-1]&&(u+="\n");break;default:u+="\n"}const h=n+a.length+t.source.length;return{value:u,type:i,comment:a.comment,range:[n,h,h]}}function kt(e,t,r){const{offset:n,type:a,source:i,end:s}=e;let o,l;const c=(e,t,a)=>r(n+e,t,a);switch(a){case"scalar":o=W.PLAIN,l=function(e,t){let r="";switch(e[0]){case"\t":r="a tab character";break;case",":r="flow indicator character ,";break;case"%":r="directive indicator character %";break;case"|":case">":r=`block scalar indicator ${e[0]}`;break;case"@":case"`":r=`reserved character ${e[0]}`}return r&&t(0,"BAD_SCALAR_START",`Plain value cannot start with ${r}`),Wt(e)}(i,c);break;case"single-quoted-scalar":o=W.QUOTE_SINGLE,l=function(e,t){return"'"===e[e.length-1]&&1!==e.length||t(e.length,"MISSING_CHAR","Missing closing 'quote"),Wt(e.slice(1,-1)).replace(/''/g,"'")}(i,c);break;case"double-quoted-scalar":o=W.QUOTE_DOUBLE,l=function(e,t){let r="";for(let n=1;n<e.length-1;++n){const a=e[n];if("\r"!==a||"\n"!==e[n+1])if("\n"===a){const{fold:t,offset:a}=Kt(e,n);r+=t,n=a}else if("\\"===a){let a=e[++n];const i=jt[a];if(i)r+=i;else if("\n"===a)for(a=e[n+1];" "===a||"\t"===a;)a=e[1+ ++n];else if("\r"===a&&"\n"===e[n+1])for(a=e[1+ ++n];" "===a||"\t"===a;)a=e[1+ ++n];else if("x"===a||"u"===a||"U"===a){const i="x"===a?2:"u"===a?4:8;r+=Gt(e,n+1,i,t),n+=i}else{const a=e.substr(n-1,2);t(n-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${a}`),r+=a}}else if(" "===a||"\t"===a){const t=n;let i=e[n+1];for(;" "===i||"\t"===i;)i=e[1+ ++n];"\n"===i||"\r"===i&&"\n"===e[n+2]||(r+=n>t?e.slice(t,n+1):a)}else r+=a}return'"'===e[e.length-1]&&1!==e.length||t(e.length,"MISSING_CHAR",'Missing closing "quote'),r}(i,c);break;default:return r(e,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${a}`),{value:"",type:null,comment:"",range:[n,n+i.length,n+i.length]}}const d=n+i.length,u=Ut(s,d,t,r);return{value:l,type:o,comment:u.comment,range:[n,d,u.offset]}}function Wt(e){let t,r;try{t=new RegExp("(.*?)(?<![ \t])[ \t]*\r?\n","sy"),r=new RegExp("[ \t]*(.*?)(?:(?<![ \t])[ \t]*)?\r?\n","sy")}catch{t=/(.*?)[ \t]*\r?\n/sy,r=/[ \t]*(.*?)[ \t]*\r?\n/sy}let n=t.exec(e);if(!n)return e;let a=n[1],i=" ",s=t.lastIndex;for(r.lastIndex=s;n=r.exec(e);)""===n[1]?"\n"===i?a+=i:i="\n":(a+=i+n[1],i=" "),s=r.lastIndex;const o=/[ \t]*(.*)/sy;return o.lastIndex=s,n=o.exec(e),a+i+(n?.[1]??"")}function Kt(e,t){let r="",n=e[t+1];for(;!(" "!==n&&"\t"!==n&&"\n"!==n&&"\r"!==n||"\r"===n&&"\n"!==e[t+2]);)"\n"===n&&(r+="\n"),n=e[(t+=1)+1];return r||(r=" "),{fold:r,offset:t}}const jt={0:"\0",a:"",b:"\b",e:"",f:"\f",n:"\n",r:"\r",t:"\t",v:"\v",N:"
",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\","\t":"\t"};function Gt(e,t,r,n){const a=e.substr(t,r),i=a.length===r&&/^[0-9a-fA-F]+$/.test(a)?parseInt(a,16):NaN;try{return String.fromCodePoint(i)}catch{const a=e.substr(t-2,r+2);return n(t-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${a}`),a}}function Xt(e,t,r,n){const{value:a,type:i,comment:s,range:o}="block-scalar"===t.type?Pt(e,t,n):kt(t,e.options.strict,n),l=r?e.directives.tagName(r.source,e=>n(r,"TAG_RESOLVE_FAILED",e)):null;let d,u;d=e.options.stringKeys&&e.atKey?e.schema[c]:l?function(e,t,r,n,a){if("!"===r)return e[c];const i=[];for(const t of e.tags)if(!t.collection&&t.tag===r){if(!t.default||!t.test)return t;i.push(t)}for(const e of i)if(e.test?.test(t))return e;const s=e.knownTags[r];return s&&!s.collection?(e.tags.push(Object.assign({},s,{default:!1,test:void 0})),s):(a(n,"TAG_RESOLVE_FAILED",`Unresolved tag: ${r}`,"tag:yaml.org,2002:str"!==r),e[c])}(e.schema,a,l,r,n):"scalar"===t.type?function({atKey:e,directives:t,schema:r},n,a,i){const s=r.tags.find(t=>(!0===t.default||e&&"key"===t.default)&&t.test?.test(n))||r[c];if(r.compat){const e=r.compat.find(e=>e.default&&e.test?.test(n))??r[c];s.tag!==e.tag&&i(a,"TAG_RESOLVE_FAILED",`Value may be parsed as either ${t.tagString(s.tag)} or ${t.tagString(e.tag)}`,!0)}return s}(e,a,t,n):e.schema[c];try{const i=d.resolve(a,e=>n(r??t,"TAG_RESOLVE_FAILED",e),e.options);u=T(i)?i:new W(i)}catch(e){const i=e instanceof Error?e.message:String(e);n(r??t,"TAG_RESOLVE_FAILED",i),u=new W(a)}return u.range=o,u.source=a,i&&(u.type=i),l&&(u.tag=l),d.format&&(u.format=d.format),s&&(u.comment=s),u}function $t(e,t,r){if(t){r??(r=t.length);for(let n=r-1;n>=0;--n){let r=t[n];switch(r.type){case"space":case"comment":case"newline":e-=r.source.length;continue}for(r=t[++n];"space"===r?.type;)e+=r.source.length,r=t[++n];break}}return e}const qt={composeNode:Ht,composeEmptyNode:zt};function Ht(e,t,r,n){const a=e.atKey,{spaceBefore:i,comment:s,anchor:o,tag:l}=r;let c,d=!0;switch(t.type){case"alias":c=function({options:e},{offset:t,source:r,end:n},a){const i=new x(r.substring(1));""===i.source&&a(t,"BAD_ALIAS","Alias cannot be an empty string"),i.source.endsWith(":")&&a(t+r.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);const s=t+r.length,o=Ut(n,s,e.strict,a);return i.range=[t,s,o.offset],o.comment&&(i.comment=o.comment),i}(e,t,n),(o||l)&&n(t,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":c=Xt(e,t,l,n),o&&(c.anchor=o.source.substring(1));break;case"block-map":case"block-seq":case"flow-collection":try{c=function(e,t,r,n,a){const i=n.tag,s=i?t.directives.tagName(i.source,e=>a(i,"TAG_RESOLVE_FAILED",e)):null;if("block-seq"===r.type){const{anchor:e,newlineAfterProp:t}=n,r=e&&i?e.offset>i.offset?e:i:e??i;r&&(!t||t.offset<r.offset)&&a(r,"MISSING_CHAR","Missing newline after block sequence props")}const o="block-map"===r.type?"map":"block-seq"===r.type?"seq":"{"===r.start.source?"map":"seq";if(!i||!s||"!"===s||s===Se.tagName&&"map"===o||s===ve.tagName&&"seq"===o)return xt(e,t,r,a,s);let l=t.schema.tags.find(e=>e.tag===s&&e.collection===o);if(!l){const n=t.schema.knownTags[s];if(n?.collection!==o)return n?a(i,"BAD_COLLECTION_TYPE",`${n.tag} used for ${o} collection, but expects ${n.collection??"scalar"}`,!0):a(i,"TAG_RESOLVE_FAILED",`Unresolved tag: ${s}`,!0),xt(e,t,r,a,s);t.schema.tags.push(Object.assign({},n,{default:!1})),l=n}const c=xt(e,t,r,a,s,l),d=l.resolve?.(c,e=>a(i,"TAG_RESOLVE_FAILED",e),t.options)??c,u=C(d)?d:new W(d);return u.range=c.range,u.tag=s,l?.format&&(u.format=l.format),u}(qt,e,t,r,n),o&&(c.anchor=o.source.substring(1))}catch(e){n(t,"RESOURCE_EXHAUSTION",e instanceof Error?e.message:String(e))}break;default:n(t,"UNEXPECTED_TOKEN","error"===t.type?t.message:`Unsupported token (type: ${t.type})`),d=!1}return c??(c=zt(e,t.offset,void 0,null,r,n)),o&&""===c.anchor&&n(o,"BAD_ALIAS","Anchor cannot be an empty string"),a&&e.options.stringKeys&&(!T(c)||"string"!=typeof c.value||c.tag&&"tag:yaml.org,2002:str"!==c.tag)&&n(l??t,"NON_STRING_KEY","With stringKeys, all keys must be strings"),i&&(c.spaceBefore=!0),s&&("scalar"===t.type&&""===t.source?c.comment=s:c.commentBefore=s),e.options.keepSourceTokens&&d&&(c.srcToken=t),c}function zt(e,t,r,n,{spaceBefore:a,comment:i,anchor:s,tag:o,end:l},c){const d=Xt(e,{type:"scalar",offset:$t(t,r,n),indent:-1,source:""},o,c);return s&&(d.anchor=s.source.substring(1),""===d.anchor&&c(s,"BAD_ALIAS","Anchor cannot be an empty string")),a&&(d.spaceBefore=!0),i&&(d.comment=i,d.range[2]=l),d}function Qt(e){if("number"==typeof e)return[e,e+1];if(Array.isArray(e))return 2===e.length?e:[e[0],e[1]];const{offset:t,source:r}=e;return[t,t+("string"==typeof r?r.length:1)]}function Zt(e){let t="",r=!1,n=!1;for(let a=0;a<e.length;++a){const i=e[a];switch(i[0]){case"#":t+=(""===t?"":n?"\n\n":"\n")+(i.substring(1)||" "),r=!0,n=!1;break;case"%":"#"!==e[a+1]?.[0]&&(a+=1),r=!1;break;default:r||(n=!0),r=!1}}return{comment:t,afterEmptyLine:n}}class er{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(e,t,r,n)=>{const a=Qt(e);n?this.warnings.push(new Lt(a,t,r)):this.errors.push(new wt(a,t,r))},this.directives=new V({version:e.version||"1.2"}),this.options=e}decorate(e,t){const{comment:r,afterEmptyLine:n}=Zt(this.prelude);if(r){const a=e.contents;if(t)e.comment=e.comment?`${e.comment}\n${r}`:r;else if(n||e.directives.docStart||!a)e.commentBefore=r;else if(E(a)&&!a.flow&&a.items.length>0){let e=a.items[0];f(e)&&(e=e.key);const t=e.commentBefore;e.commentBefore=t?`${r}\n${t}`:r}else{const e=a.commentBefore;a.commentBefore=e?`${r}\n${e}`:r}}if(t){for(let t=0;t<this.errors.length;++t)e.errors.push(this.errors[t]);for(let t=0;t<this.warnings.length;++t)e.warnings.push(this.warnings[t])}else e.errors=this.errors,e.warnings=this.warnings;this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:Zt(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,t=!1,r=-1){for(const t of e)yield*this.next(t);yield*this.end(t,r)}*next(e){switch(e.type){case"directive":this.directives.add(e.source,(t,r,n)=>{const a=Qt(e);a[0]+=t,this.onError(a,"BAD_DIRECTIVE",r,n)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{const t=function(e,t,{offset:r,start:n,value:a,end:i},s){const o=Object.assign({_directives:t},e),l=new _t(void 0,o),c={atKey:!1,atRoot:!0,directives:l.directives,options:l.options,schema:l.schema},d=Ot(n,{indicator:"doc-start",next:a??i?.[0],offset:r,onError:s,parentIndent:0,startOnNewline:!0});d.found&&(l.directives.docStart=!0,!a||"block-map"!==a.type&&"block-seq"!==a.type||d.hasNewline||s(d.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")),l.contents=a?Ht(c,a,d,s):zt(c,d.end,n,null,d,s);const u=l.contents.range[2],m=Ut(i,u,!1,s);return m.comment&&(l.comment=m.comment),l.range=[r,u,m.offset],l}(this.options,this.directives,e,this.onError);this.atDirectives&&!t.directives.docStart&&this.onError(e,"MISSING_CHAR","Missing directives-end/doc-start indicator line"),this.decorate(t,!1),this.doc&&(yield this.doc),this.doc=t,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push(e.source);break;case"error":{const t=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,r=new wt(Qt(e),"UNEXPECTED_TOKEN",t);this.atDirectives||!this.doc?this.errors.push(r):this.doc.errors.push(r);break}case"doc-end":{if(!this.doc){const t="Unexpected doc-end without preceding document";this.errors.push(new wt(Qt(e),"UNEXPECTED_TOKEN",t));break}this.doc.directives.docEnd=!0;const t=Ut(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),t.comment){const e=this.doc.comment;this.doc.comment=e?`${e}\n${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.push(new wt(Qt(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,t=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){const e=Object.assign({_directives:this.directives},this.options),r=new _t(void 0,e);this.atDirectives&&this.onError(t,"MISSING_CHAR","Missing directives-end indicator line"),r.range=[0,t,t],this.decorate(r,!1),yield r}}}function tr(e,t=!0,r){if(e){const n=(e,t,n)=>{const a="number"==typeof e?e:Array.isArray(e)?e[0]:e.offset;if(!r)throw new wt([a,a+1],t,n);r(a,t,n)};switch(e.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return kt(e,t,n);case"block-scalar":return Pt({options:{strict:t}},e,n)}}return null}function rr(e,t){const{implicitKey:r=!1,indent:n,inFlow:a=!1,offset:i=-1,type:s="PLAIN"}=t,o=le({type:s,value:e},{implicitKey:r,indent:n>0?" ".repeat(n):"",inFlow:a,options:{blockQuote:!0,lineWidth:-1}}),l=t.end??[{type:"newline",offset:-1,indent:n,source:"\n"}];switch(o[0]){case"|":case">":{const e=o.indexOf("\n"),t=o.substring(0,e),r=o.substring(e+1)+"\n",a=[{type:"block-scalar-header",offset:i,indent:n,source:t}];return ar(a,l)||a.push({type:"newline",offset:-1,indent:n,source:"\n"}),{type:"block-scalar",offset:i,indent:n,props:a,source:r}}case'"':return{type:"double-quoted-scalar",offset:i,indent:n,source:o,end:l};case"'":return{type:"single-quoted-scalar",offset:i,indent:n,source:o,end:l};default:return{type:"scalar",offset:i,indent:n,source:o,end:l}}}function nr(e,t,r={}){let{afterKey:n=!1,implicitKey:a=!1,inFlow:i=!1,type:s}=r,o="indent"in e?e.indent:null;if(n&&"number"==typeof o&&(o+=2),!s)switch(e.type){case"single-quoted-scalar":s="QUOTE_SINGLE";break;case"double-quoted-scalar":s="QUOTE_DOUBLE";break;case"block-scalar":{const t=e.props[0];if("block-scalar-header"!==t.type)throw new Error("Invalid block scalar header");s=">"===t.source[0]?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:s="PLAIN"}const l=le({type:s,value:t},{implicitKey:a||null===o,indent:null!==o&&o>0?" ".repeat(o):"",inFlow:i,options:{blockQuote:!0,lineWidth:-1}});switch(l[0]){case"|":case">":!function(e,t){const r=t.indexOf("\n"),n=t.substring(0,r),a=t.substring(r+1)+"\n";if("block-scalar"===e.type){const t=e.props[0];if("block-scalar-header"!==t.type)throw new Error("Invalid block scalar header");t.source=n,e.source=a}else{const{offset:t}=e,r="indent"in e?e.indent:-1,i=[{type:"block-scalar-header",offset:t,indent:r,source:n}];ar(i,"end"in e?e.end:void 0)||i.push({type:"newline",offset:-1,indent:r,source:"\n"});for(const t of Object.keys(e))"type"!==t&&"offset"!==t&&delete e[t];Object.assign(e,{type:"block-scalar",indent:r,props:i,source:a})}}(e,l);break;case'"':ir(e,l,"double-quoted-scalar");break;case"'":ir(e,l,"single-quoted-scalar");break;default:ir(e,l,"scalar")}}function ar(e,t){if(t)for(const r of t)switch(r.type){case"space":case"comment":e.push(r);break;case"newline":return e.push(r),!0}return!1}function ir(e,t,r){switch(e.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":e.type=r,e.source=t;break;case"block-scalar":{const n=e.props.slice(1);let a=t.length;"block-scalar-header"===e.props[0].type&&(a-=e.props[0].source.length);for(const e of n)e.offset+=a;delete e.props,Object.assign(e,{type:r,source:t,end:n});break}case"block-map":case"block-seq":{const n={type:"newline",offset:e.offset+t.length,indent:e.indent,source:"\n"};delete e.items,Object.assign(e,{type:r,source:t,end:[n]});break}default:{const n="indent"in e?e.indent:-1,a="end"in e&&Array.isArray(e.end)?e.end.filter(e=>"space"===e.type||"comment"===e.type||"newline"===e.type):[];for(const t of Object.keys(e))"type"!==t&&"offset"!==t&&delete e[t];Object.assign(e,{type:r,indent:n,source:t,end:a})}}}const sr=e=>"type"in e?or(e):lr(e);function or(e){switch(e.type){case"block-scalar":{let t="";for(const r of e.props)t+=or(r);return t+e.source}case"block-map":case"block-seq":{let t="";for(const r of e.items)t+=lr(r);return t}case"flow-collection":{let t=e.start.source;for(const r of e.items)t+=lr(r);for(const r of e.end)t+=r.source;return t}case"document":{let t=lr(e);if(e.end)for(const r of e.end)t+=r.source;return t}default:{let t=e.source;if("end"in e&&e.end)for(const r of e.end)t+=r.source;return t}}}function lr({start:e,key:t,sep:r,value:n}){let a="";for(const t of e)a+=t.source;if(t&&(a+=or(t)),r)for(const e of r)a+=e.source;return n&&(a+=or(n)),a}const cr=Symbol("break visit"),dr=Symbol("skip children"),ur=Symbol("remove item");function mr(e,t){"type"in e&&"document"===e.type&&(e={start:e.start,value:e.value}),pr(Object.freeze([]),e,t)}function pr(e,t,r){let n=r(t,e);if("symbol"==typeof n)return n;for(const a of["key","value"]){const i=t[a];if(i&&"items"in i){for(let t=0;t<i.items.length;++t){const n=pr(Object.freeze(e.concat([[a,t]])),i.items[t],r);if("number"==typeof n)t=n-1;else{if(n===cr)return cr;n===ur&&(i.items.splice(t,1),t-=1)}}"function"==typeof n&&"key"===a&&(n=n(t,e))}}return"function"==typeof n?n(t,e):n}mr.BREAK=cr,mr.SKIP=dr,mr.REMOVE=ur,mr.itemAtPath=(e,t)=>{let r=e;for(const[e,n]of t){const t=r?.[e];if(!t||!("items"in t))return;r=t.items[n]}return r},mr.parentCollection=(e,t)=>{const r=mr.itemAtPath(e,t.slice(0,-1)),n=t[t.length-1][0],a=r?.[n];if(a&&"items"in a)return a;throw new Error("Parent collection not found")};const hr="\ufeff",fr="",Tr="",yr="",Er=e=>!!e&&"items"in e,Cr=e=>!!e&&("scalar"===e.type||"single-quoted-scalar"===e.type||"double-quoted-scalar"===e.type||"block-scalar"===e.type);function gr(e){switch(e){case hr:return"<BOM>";case fr:return"<DOC>";case Tr:return"<FLOW_END>";case yr:return"<SCALAR>";default:return JSON.stringify(e)}}function Ir(e){switch(e){case hr:return"byte-order-mark";case fr:return"doc-mode";case Tr:return"flow-error-end";case yr:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case"\n":case"\r\n":return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(e[0]){case" ":case"\t":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}function Ar(e){switch(e){case void 0:case" ":case"\n":case"\r":case"\t":return!0;default:return!1}}const br=new Set("0123456789ABCDEFabcdef"),Rr=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),Sr=new Set(",[]{}"),_r=new Set(" ,[]{}\n\r\t"),vr=e=>!e||_r.has(e);class Nr{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,t=!1){if(e){if("string"!=typeof e)throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!t;let r=this.next??"stream";for(;r&&(t||this.hasChars(1));)r=yield*this.parseNext(r)}atLineEnd(){let e=this.pos,t=this.buffer[e];for(;" "===t||"\t"===t;)t=this.buffer[++e];return!t||"#"===t||"\n"===t||"\r"===t&&"\n"===this.buffer[e+1]}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let t=this.buffer[e];if(this.indentNext>0){let r=0;for(;" "===t;)t=this.buffer[++r+e];if("\r"===t){const t=this.buffer[r+e+1];if("\n"===t||!t&&!this.atEnd)return e+r+1}return"\n"===t||r>=this.indentNext||!t&&!this.atEnd?e+r:-1}if("-"===t||"."===t){const t=this.buffer.substr(e,3);if(("---"===t||"..."===t)&&Ar(this.buffer[e+3]))return-1}return e}getLine(){let e=this.lineEndPos;return("number"!=typeof e||-1!==e&&e<this.pos)&&(e=this.buffer.indexOf("\n",this.pos),this.lineEndPos=e),-1===e?this.atEnd?this.buffer.substring(this.pos):null:("\r"===this.buffer[e-1]&&(e-=1),this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(null===e)return this.setNext("stream");if(e[0]===hr&&(yield*this.pushCount(1),e=e.substring(1)),"%"===e[0]){let t=e.length,r=e.indexOf("#");for(;-1!==r;){const n=e[r-1];if(" "===n||"\t"===n){t=r-1;break}r=e.indexOf("#",r+1)}for(;;){const r=e[t-1];if(" "!==r&&"\t"!==r)break;t-=1}const n=(yield*this.pushCount(t))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-n),this.pushNewline(),"stream"}if(this.atLineEnd()){const t=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-t),yield*this.pushNewline(),"stream"}return yield fr,yield*this.parseLineStart()}*parseLineStart(){const e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext("line-start");if("-"===e||"."===e){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");const e=this.peek(3);if(("---"===e||"..."===e)&&Ar(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,"---"===e?"doc":"stream"}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!Ar(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){const[e,t]=this.peek(2);if(!t&&!this.atEnd)return this.setNext("block-start");if(("-"===e||"?"===e||":"===e)&&Ar(t)){const e=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=e,"block-start"}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);const e=this.getLine();if(null===e)return this.setNext("doc");let t=yield*this.pushIndicators();switch(e[t]){case"#":yield*this.pushCount(e.length-t);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(vr),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return t+=(yield*this.parseBlockScalarHeader()),t+=(yield*this.pushSpaces(!0)),yield*this.pushCount(e.length-t),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,t,r=-1;do{e=yield*this.pushNewline(),e>0?(t=yield*this.pushSpaces(!1),this.indentValue=r=t):t=0,t+=(yield*this.pushSpaces(!0))}while(e+t>0);const n=this.getLine();if(null===n)return this.setNext("flow");if((-1!==r&&r<this.indentNext&&"#"!==n[0]||0===r&&(n.startsWith("---")||n.startsWith("..."))&&Ar(n[3]))&&(r!==this.indentNext-1||1!==this.flowLevel||"]"!==n[0]&&"}"!==n[0]))return this.flowLevel=0,yield Tr,yield*this.parseLineStart();let a=0;for(;","===n[a];)a+=(yield*this.pushCount(1)),a+=(yield*this.pushSpaces(!0)),this.flowKey=!1;switch(a+=(yield*this.pushIndicators()),n[a]){case void 0:return"flow";case"#":return yield*this.pushCount(n.length-a),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(vr),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{const e=this.charAt(1);if(this.flowKey||Ar(e)||","===e)return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){const e=this.charAt(0);let t=this.buffer.indexOf(e,this.pos+1);if("'"===e)for(;-1!==t&&"'"===this.buffer[t+1];)t=this.buffer.indexOf("'",t+2);else for(;-1!==t;){let e=0;for(;"\\"===this.buffer[t-1-e];)e+=1;if(e%2==0)break;t=this.buffer.indexOf('"',t+1)}const r=this.buffer.substring(0,t);let n=r.indexOf("\n",this.pos);if(-1!==n){for(;-1!==n;){const e=this.continueScalar(n+1);if(-1===e)break;n=r.indexOf("\n",e)}-1!==n&&(t=n-("\r"===r[n-1]?2:1))}if(-1===t){if(!this.atEnd)return this.setNext("quoted-scalar");t=this.buffer.length}return yield*this.pushToIndex(t+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let e=this.pos;for(;;){const t=this.buffer[++e];if("+"===t)this.blockScalarKeep=!0;else if(t>"0"&&t<="9")this.blockScalarIndent=Number(t)-1;else if("-"!==t)break}return yield*this.pushUntil(e=>Ar(e)||"#"===e)}*parseBlockScalar(){let e,t=this.pos-1,r=0;e:for(let n=this.pos;e=this.buffer[n];++n)switch(e){case" ":r+=1;break;case"\n":t=n,r=0;break;case"\r":{const e=this.buffer[n+1];if(!e&&!this.atEnd)return this.setNext("block-scalar");if("\n"===e)break}default:break e}if(!e&&!this.atEnd)return this.setNext("block-scalar");if(r>=this.indentNext){-1===this.blockScalarIndent?this.indentNext=r:this.indentNext=this.blockScalarIndent+(0===this.indentNext?1:this.indentNext);do{const e=this.continueScalar(t+1);if(-1===e)break;t=this.buffer.indexOf("\n",e)}while(-1!==t);if(-1===t){if(!this.atEnd)return this.setNext("block-scalar");t=this.buffer.length}}let n=t+1;for(e=this.buffer[n];" "===e;)e=this.buffer[++n];if("\t"===e){for(;"\t"===e||" "===e||"\r"===e||"\n"===e;)e=this.buffer[++n];t=n-1}else if(!this.blockScalarKeep)for(;;){let e=t-1,n=this.buffer[e];"\r"===n&&(n=this.buffer[--e]);const a=e;for(;" "===n;)n=this.buffer[--e];if(!("\n"===n&&e>=this.pos&&e+1+r>a))break;t=e}return yield yr,yield*this.pushToIndex(t+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){const e=this.flowLevel>0;let t,r=this.pos-1,n=this.pos-1;for(;t=this.buffer[++n];)if(":"===t){const t=this.buffer[n+1];if(Ar(t)||e&&Sr.has(t))break;r=n}else if(Ar(t)){let a=this.buffer[n+1];if("\r"===t&&("\n"===a?(n+=1,t="\n",a=this.buffer[n+1]):r=n),"#"===a||e&&Sr.has(a))break;if("\n"===t){const e=this.continueScalar(n+1);if(-1===e)break;n=Math.max(n,e-2)}}else{if(e&&Sr.has(t))break;r=n}return t||this.atEnd?(yield yr,yield*this.pushToIndex(r+1,!0),e?"flow":"doc"):this.setNext("plain-scalar")}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,t){const r=this.buffer.slice(this.pos,e);return r?(yield r,this.pos+=r.length,r.length):(t&&(yield""),0)}*pushIndicators(){let e=0;e:for(;;){switch(this.charAt(0)){case"!":e+=(yield*this.pushTag()),e+=(yield*this.pushSpaces(!0));continue e;case"&":e+=(yield*this.pushUntil(vr)),e+=(yield*this.pushSpaces(!0));continue e;case"-":case"?":case":":{const t=this.flowLevel>0,r=this.charAt(1);if(Ar(r)||t&&Sr.has(r)){t?this.flowKey&&(this.flowKey=!1):this.indentNext=this.indentValue+1,e+=(yield*this.pushCount(1)),e+=(yield*this.pushSpaces(!0));continue e}}}break e}return e}*pushTag(){if("<"===this.charAt(1)){let e=this.pos+2,t=this.buffer[e];for(;!Ar(t)&&">"!==t;)t=this.buffer[++e];return yield*this.pushToIndex(">"===t?e+1:e,!1)}{let e=this.pos+1,t=this.buffer[e];for(;t;)if(Rr.has(t))t=this.buffer[++e];else{if("%"!==t||!br.has(this.buffer[e+1])||!br.has(this.buffer[e+2]))break;t=this.buffer[e+=3]}return yield*this.pushToIndex(e,!1)}}*pushNewline(){const e=this.buffer[this.pos];return"\n"===e?yield*this.pushCount(1):"\r"===e&&"\n"===this.charAt(1)?yield*this.pushCount(2):0}*pushSpaces(e){let t,r=this.pos-1;do{t=this.buffer[++r]}while(" "===t||e&&"\t"===t);const n=r-this.pos;return n>0&&(yield this.buffer.substr(this.pos,n),this.pos=r),n}*pushUntil(e){let t=this.pos,r=this.buffer[t];for(;!e(r);)r=this.buffer[++t];return yield*this.pushToIndex(t,!1)}}class wr{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let t=0,r=this.lineStarts.length;for(;t<r;){const n=t+r>>1;this.lineStarts[n]<e?t=n+1:r=n}return this.lineStarts[t]===e?{line:t+1,col:1}:0===t?{line:0,col:e}:{line:t,col:e-this.lineStarts[t-1]+1}}}}function Lr(e,t){for(let r=0;r<e.length;++r)if(e[r].type===t)return!0;return!1}function Fr(e){for(let t=0;t<e.length;++t)switch(e[t].type){case"space":case"comment":case"newline":break;default:return t}return-1}function Or(e){switch(e?.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function Vr(e){switch(e.type){case"document":return e.start;case"block-map":{const t=e.items[e.items.length-1];return t.sep??t.start}case"block-seq":return e.items[e.items.length-1].start;default:return[]}}function Br(e){if(0===e.length)return[];let t=e.length;e:for(;--t>=0;)switch(e[t].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break e}for(;"space"===e[++t]?.type;);return e.splice(t,e.length)}function Dr(e,t){if(t.length<1e5)Array.prototype.push.apply(e,t);else for(let r=0;r<t.length;++r)e.push(t[r])}function Mr(e){if("flow-seq-start"===e.start.type)for(const t of e.items)!t.sep||t.value||Lr(t.start,"explicit-key-ind")||Lr(t.sep,"map-value-ind")||(t.key&&(t.value=t.key),delete t.key,Or(t.value)?t.value.end?Dr(t.value.end,t.sep):t.value.end=t.sep:Dr(t.start,t.sep),delete t.sep)}class Ur{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new Nr,this.onNewLine=e}*parse(e,t=!1){this.onNewLine&&0===this.offset&&this.onNewLine(0);for(const r of this.lexer.lex(e,t))yield*this.next(r);t||(yield*this.end())}*next(e){if(this.source=e,this.atScalar)return this.atScalar=!1,yield*this.step(),void(this.offset+=e.length);const t=Ir(e);if(t)if("scalar"===t)this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=t,yield*this.step(),t){case"newline":this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case"space":this.atNewLine&&" "===e[0]&&(this.indent+=e.length);break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":this.atNewLine&&(this.indent+=e.length);break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=e.length}else{const t=`Not a YAML token: ${e}`;yield*this.pop({type:"error",offset:this.offset,message:t,source:e}),this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){const e=this.peek(1);if("doc-end"!==this.type||"doc-end"===e?.type){if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}else{for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source})}}peek(e){return this.stack[this.stack.length-e]}*pop(e){const t=e??this.stack.pop();if(t)if(0===this.stack.length)yield t;else{const e=this.peek(1);switch("block-scalar"===t.type?t.indent="indent"in e?e.indent:0:"flow-collection"===t.type&&"document"===e.type&&(t.indent=0),"flow-collection"===t.type&&Mr(t),e.type){case"document":e.value=t;break;case"block-scalar":e.props.push(t);break;case"block-map":{const r=e.items[e.items.length-1];if(r.value)return e.items.push({start:[],key:t,sep:[]}),void(this.onKeyLine=!0);if(!r.sep)return Object.assign(r,{key:t,sep:[]}),void(this.onKeyLine=!r.explicitKey);r.value=t;break}case"block-seq":{const r=e.items[e.items.length-1];r.value?e.items.push({start:[],value:t}):r.value=t;break}case"flow-collection":{const r=e.items[e.items.length-1];return void(!r||r.value?e.items.push({start:[],key:t,sep:[]}):r.sep?r.value=t:Object.assign(r,{key:t,sep:[]}))}default:yield*this.pop(),yield*this.pop(t)}if(!("document"!==e.type&&"block-map"!==e.type&&"block-seq"!==e.type||"block-map"!==t.type&&"block-seq"!==t.type)){const r=t.items[t.items.length-1];r&&!r.sep&&!r.value&&r.start.length>0&&-1===Fr(r.start)&&(0===t.indent||r.start.every(e=>"comment"!==e.type||e.indent<t.indent))&&("document"===e.type?e.end=r.start:e.items.push({start:r.start}),t.items.splice(-1,1))}}else{const e="Tried to pop an empty stack";yield{type:"error",offset:this.offset,source:"",message:e}}}*stream(){switch(this.type){case"directive-line":return void(yield{type:"directive",offset:this.offset,source:this.source});case"byte-order-mark":case"space":case"comment":case"newline":return void(yield this.sourceToken);case"doc-mode":case"doc-start":{const e={type:"document",offset:this.offset,start:[]};return"doc-start"===this.type&&e.start.push(this.sourceToken),void this.stack.push(e)}}yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document(e){if(e.value)return yield*this.lineEnd(e);switch(this.type){case"doc-start":return void(-1!==Fr(e.start)?(yield*this.pop(),yield*this.step()):e.start.push(this.sourceToken));case"anchor":case"tag":case"space":case"comment":case"newline":return void e.start.push(this.sourceToken)}const t=this.startBlockValue(e);t?this.stack.push(t):yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar(e){if("map-value-ind"===this.type){const t=Br(Vr(this.peek(2)));let r;e.end?(r=e.end,r.push(this.sourceToken),delete e.end):r=[this.sourceToken];const n={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:t,key:e,sep:r}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=n}else yield*this.lineEnd(e)}*blockScalar(e){switch(this.type){case"space":case"comment":case"newline":return void e.props.push(this.sourceToken);case"scalar":if(e.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let e=this.source.indexOf("\n")+1;for(;0!==e;)this.onNewLine(this.offset+e),e=this.source.indexOf("\n",e)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){const t=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,t.value){const r="end"in t.value?t.value.end:void 0,n=Array.isArray(r)?r[r.length-1]:void 0;"comment"===n?.type?r?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case"space":case"comment":if(t.value)e.items.push({start:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else{if(this.atIndentedComment(t.start,e.indent)){const r=e.items[e.items.length-2],n=r?.value?.end;if(Array.isArray(n))return Dr(n,t.start),n.push(this.sourceToken),void e.items.pop()}t.start.push(this.sourceToken)}return}if(this.indent>=e.indent){const r=!this.onKeyLine&&this.indent===e.indent,n=r&&(t.sep||t.explicitKey)&&"seq-item-ind"!==this.type;let a=[];if(n&&t.sep&&!t.value){const r=[];for(let n=0;n<t.sep.length;++n){const a=t.sep[n];switch(a.type){case"newline":r.push(n);break;case"space":break;case"comment":a.indent>e.indent&&(r.length=0);break;default:r.length=0}}r.length>=2&&(a=t.sep.splice(r[1]))}switch(this.type){case"anchor":case"tag":return void(n||t.value?(a.push(this.sourceToken),e.items.push({start:a}),this.onKeyLine=!0):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken));case"explicit-key-ind":return t.sep||t.explicitKey?n||t.value?(a.push(this.sourceToken),e.items.push({start:a,explicitKey:!0})):this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}):(t.start.push(this.sourceToken),t.explicitKey=!0),void(this.onKeyLine=!0);case"map-value-ind":if(t.explicitKey)if(t.sep)if(t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Lr(t.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:a,key:null,sep:[this.sourceToken]}]});else if(Or(t.key)&&!Lr(t.sep,"newline")){const e=Br(t.start),r=t.key,n=t.sep;n.push(this.sourceToken),delete t.key,delete t.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:e,key:r,sep:n}]})}else a.length>0?t.sep=t.sep.concat(a,this.sourceToken):t.sep.push(this.sourceToken);else if(Lr(t.start,"newline"))Object.assign(t,{key:null,sep:[this.sourceToken]});else{const e=Br(t.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:e,key:null,sep:[this.sourceToken]}]})}else t.sep?t.value||n?e.items.push({start:a,key:null,sep:[this.sourceToken]}):Lr(t.sep,"map-value-ind")?this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});return void(this.onKeyLine=!0);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const r=this.flowScalar(this.type);return void(n||t.value?(e.items.push({start:a,key:r,sep:[]}),this.onKeyLine=!0):t.sep?this.stack.push(r):(Object.assign(t,{key:r,sep:[]}),this.onKeyLine=!0))}default:{const n=this.startBlockValue(e);if(n){if("block-seq"===n.type){if(!t.explicitKey&&t.sep&&!Lr(t.sep,"newline"))return void(yield*this.pop({type:"error",offset:this.offset,message:"Unexpected block-seq-ind on same line with key",source:this.source}))}else r&&e.items.push({start:a});return void this.stack.push(n)}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){const t=e.items[e.items.length-1];switch(this.type){case"newline":if(t.value){const r="end"in t.value?t.value.end:void 0,n=Array.isArray(r)?r[r.length-1]:void 0;"comment"===n?.type?r?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.start.push(this.sourceToken);return;case"space":case"comment":if(t.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(t.start,e.indent)){const r=e.items[e.items.length-2],n=r?.value?.end;if(Array.isArray(n))return Dr(n,t.start),n.push(this.sourceToken),void e.items.pop()}t.start.push(this.sourceToken)}return;case"anchor":case"tag":if(t.value||this.indent<=e.indent)break;return void t.start.push(this.sourceToken);case"seq-item-ind":if(this.indent!==e.indent)break;return void(t.value||Lr(t.start,"seq-item-ind")?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken))}if(this.indent>e.indent){const t=this.startBlockValue(e);if(t)return void this.stack.push(t)}yield*this.pop(),yield*this.step()}*flowCollection(e){const t=e.items[e.items.length-1];if("flow-error-end"===this.type){let e;do{yield*this.pop(),e=this.peek(1)}while("flow-collection"===e?.type)}else if(0===e.end.length){switch(this.type){case"comma":case"explicit-key-ind":return void(!t||t.sep?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken));case"map-value-ind":return void(!t||t.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]}));case"space":case"comment":case"newline":case"anchor":case"tag":return void(!t||t.value?e.items.push({start:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken));case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const r=this.flowScalar(this.type);return void(!t||t.value?e.items.push({start:[],key:r,sep:[]}):t.sep?this.stack.push(r):Object.assign(t,{key:r,sep:[]}))}case"flow-map-end":case"flow-seq-end":return void e.end.push(this.sourceToken)}const r=this.startBlockValue(e);r?this.stack.push(r):(yield*this.pop(),yield*this.step())}else{const t=this.peek(2);if("block-map"===t.type&&("map-value-ind"===this.type&&t.indent===e.indent||"newline"===this.type&&!t.items[t.items.length-1].sep))yield*this.pop(),yield*this.step();else if("map-value-ind"===this.type&&"flow-collection"!==t.type){const r=Br(Vr(t));Mr(e);const n=e.end.splice(1,e.end.length);n.push(this.sourceToken);const a={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:r,key:e,sep:n}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=a}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let e=this.source.indexOf("\n")+1;for(;0!==e;)this.onNewLine(this.offset+e),e=this.source.indexOf("\n",e)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;const t=Br(Vr(e));return t.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;const t=Br(Vr(e));return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,t){return"comment"===this.type&&!(this.indent<=t)&&e.every(e=>"newline"===e.type||"space"===e.type)}*documentEnd(e){"doc-mode"!==this.type&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],"newline"===this.type&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],"newline"===this.type&&(yield*this.pop())}}}function Jr(e){const t=!1!==e.prettyErrors;return{lineCounter:e.lineCounter||t&&new wr||null,prettyErrors:t}}function Yr(e,t={}){const{lineCounter:r,prettyErrors:n}=Jr(t),a=new Ur(r?.addNewLine),i=new er(t),s=Array.from(i.compose(a.parse(e)));if(n&&r)for(const t of s)t.errors.forEach(Ft(e,r)),t.warnings.forEach(Ft(e,r));return s.length>0?s:Object.assign([],{empty:!0},i.streamInfo())}function xr(e,t={}){const{lineCounter:r,prettyErrors:n}=Jr(t),a=new Ur(r?.addNewLine),i=new er(t);let s=null;for(const t of i.compose(a.parse(e),!0,e.length))if(s){if("silent"!==s.options.logLevel){s.errors.push(new wt(t.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}}else s=t;return n&&r&&(s.errors.forEach(Ft(e,r)),s.warnings.forEach(Ft(e,r))),s}function Pr(e,t,r){let n;"function"==typeof t?n=t:void 0===r&&t&&"object"==typeof t&&(r=t);const a=xr(e,r);if(!a)return null;if(a.warnings.forEach(e=>ue(a.options.logLevel,e)),a.errors.length>0){if("silent"!==a.options.logLevel)throw a.errors[0];a.errors=[]}return a.toJS(Object.assign({reviver:n},r))}function kr(e,t,r){let n=null;if("function"==typeof t||Array.isArray(t)?n=t:void 0===r&&t&&(r=t),"string"==typeof r&&(r=r.length),"number"==typeof r){const e=Math.round(r);r=e<1?void 0:e>8?{indent:8}:{indent:e}}if(void 0===e){const{keepUndefined:e}=r??t??{};if(!e)return}return p(e)&&!n?e.toString(r):new _t(e,n,r).toString(r)}const Wr=a}};const t={};function r(n){const a=t[n];if(void 0!==a)return a.exports;const i=t[n]={exports:{}};return e[n].call(i.exports,i,i.exports,r),i.exports}r.d=(e,t)=>{if(Array.isArray(t))for(var n=0;n<t.length;){var a=t[n++],i=t[n++];r.o(e,a)?0===i&&n++:0===i?Object.defineProperty(e,a,{enumerable:!0,value:t[n++]}):Object.defineProperty(e,a,{enumerable:!0,get:i})}else for(var a in t)r.o(t,a)&&!r.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};let n={};(()=>{let e=n;Object.defineProperty(e,"__esModule",{value:!0}),e.ControlledTermDefaultValueBuilder=e.TemplateInstanceBuilder=e.InstanceDataControlledAtom=e.InstanceDataLinkAtom=e.InstanceDataTypedAtom=e.InstanceDataStringAtom=e.InstanceDataEmptyAtom=e.InstanceDataEmptyNode=e.AttributeValueNamePolicy=e.InstanceDataAttributeValueFieldName=e.InstanceDataAttributeValueField=e.InstanceDataContainer=e.TemplateInstance=e.TemplateBuilder=e.Template=e.TemplateElementBuilder=e.TemplateElement=e.TemplateField=e.AbstractArtifact=e.AbstractInstanceArtifact=e.CedarFieldType=e.AbstractContainerArtifact=e.AbstractSchemaArtifact=e.YamlTemplateWriter=e.JsonTemplateWriter=e.YamlTemplateElementWriter=e.JsonTemplateElementWriter=e.JsonTemplateInstanceReader=e.InstanceValidator=e.InstanceInflater=e.YamlTemplateInstanceReader=e.YamlTemplateReader=e.JsonTemplateReader=e.YamlTemplateElementReader=e.JsonTemplateElementReader=e.YamlTemplateFieldReader=e.JsonTemplateFieldReader=e.JsonAbstractArtifactWriter=e.JsonAbstractArtifactReader=e.JsonAbstractInstanceArtifactReader=e.JsonAbstractSchemaArtifactReader=e.CedarYamlWriters=e.CedarYamlReaders=e.CedarJsonWriters=e.CedarJsonReaders=e.CedarReaders=e.CedarWriters=e.CedarBuilders=e.YamlTemplateFieldWriter=e.JsonTemplateFieldWriter=void 0,e.YamlTemplateInstanceReaderResult=e.JsonTemplateInstanceReaderResult=e.YamlTemplateReaderResult=e.JsonTemplateReaderResult=e.YamlTemplateElementReaderResult=e.JsonTemplateElementReaderResult=e.YamlTemplateFieldReaderResult=e.JsonTemplateFieldReaderResult=e.ComparisonErrorType=e.Language=e.PavVersion=e.CedarUser=e.CedarArtifactType=e.CedarFieldCategory=e.YamlValues=e.JsonTemplateInstanceWriter=e.JsonTemplateInstanceContent=e.PropertyIri=e.RoundTrip=e.ComparisonError=e.CedarArtifactId=e.BioportalTermType=e.BiboStatus=e.Iri=e.NumberType=e.TemporalType=e.TimeFormat=e.TemporalGranularity=e.JsonPath=e.SchemaVersion=e.IsoDate=e.JsonNode=e.ChildDeploymentInfoStaticBuilder=e.ChildDeploymentInfoStatic=e.ChildDeploymentInfoAlwaysMultipleBuilder=e.ChildDeploymentInfoAlwaysMultiple=e.ChildDeploymentInfoAlwaysSingleBuilder=e.ChildDeploymentInfoAlwaysSingle=e.ChildDeploymentInfoBuilder=e.ChildDeploymentInfo=e.AbstractDynamicChildDeploymentInfoBuilder=e.AbstractDynamicChildDeploymentInfo=e.AbstractChildDeploymentInfoBuilder=e.AbstractChildDeploymentInfo=e.ControlledTermVersion=e.ControlledTermActionBuilder=e.ControlledTermValueSetBuilder=e.ControlledTermOntologyBuilder=e.ControlledTermClassBuilder=e.ControlledTermBranchBuilder=void 0,e.YamlObjectComparator=e.JsonObjectComparator=e.ComparisonResult=e.YamlArtifactParsingResult=e.JsonArtifactParsingResult=e.YamlArtifactReaderResult=e.JsonArtifactReaderResult=void 0;const t=r(8810);Object.defineProperty(e,"CedarWriters",{enumerable:!0,get:function(){return t.CedarWriters}});const a=r(6568);Object.defineProperty(e,"CedarBuilders",{enumerable:!0,get:function(){return a.CedarBuilders}});const i=r(4381);Object.defineProperty(e,"JsonTemplateFieldReader",{enumerable:!0,get:function(){return i.JsonTemplateFieldReader}});const s=r(7909);Object.defineProperty(e,"JsonTemplateElementReader",{enumerable:!0,get:function(){return s.JsonTemplateElementReader}});const o=r(5291);Object.defineProperty(e,"JsonTemplateReader",{enumerable:!0,get:function(){return o.JsonTemplateReader}});const l=r(2748);Object.defineProperty(e,"JsonTemplateFieldWriter",{enumerable:!0,get:function(){return l.JsonTemplateFieldWriterInternal}});const c=r(5430);Object.defineProperty(e,"YamlTemplateFieldWriter",{enumerable:!0,get:function(){return c.YamlTemplateFieldWriterInternal}});const d=r(6645);Object.defineProperty(e,"JsonTemplateElementWriter",{enumerable:!0,get:function(){return d.JsonTemplateElementWriter}});const u=r(7519);Object.defineProperty(e,"JsonTemplateWriter",{enumerable:!0,get:function(){return u.JsonTemplateWriter}});const m=r(5251);Object.defineProperty(e,"YamlTemplateElementWriter",{enumerable:!0,get:function(){return m.YamlTemplateElementWriter}});const p=r(1933);Object.defineProperty(e,"YamlTemplateWriter",{enumerable:!0,get:function(){return p.YamlTemplateWriter}});const h=r(9129);Object.defineProperty(e,"TemplateField",{enumerable:!0,get:function(){return h.TemplateField}});const f=r(7661);Object.defineProperty(e,"TemplateElement",{enumerable:!0,get:function(){return f.TemplateElement}});const T=r(1762);Object.defineProperty(e,"TemplateElementBuilder",{enumerable:!0,get:function(){return T.TemplateElementBuilder}});const y=r(3281);Object.defineProperty(e,"Template",{enumerable:!0,get:function(){return y.Template}});const E=r(766);Object.defineProperty(e,"TemplateBuilder",{enumerable:!0,get:function(){return E.TemplateBuilder}});const C=r(4925);Object.defineProperty(e,"TemplateInstanceBuilder",{enumerable:!0,get:function(){return C.TemplateInstanceBuilder}});const g=r(9517);Object.defineProperty(e,"JsonNode",{enumerable:!0,get:function(){return g.JsonNode}});const I=r(9857);Object.defineProperty(e,"IsoDate",{enumerable:!0,get:function(){return I.IsoDate}});const A=r(8557);Object.defineProperty(e,"SchemaVersion",{enumerable:!0,get:function(){return A.SchemaVersion}});const b=r(3188);Object.defineProperty(e,"JsonPath",{enumerable:!0,get:function(){return b.JsonPath}});const R=r(7974);Object.defineProperty(e,"TemporalGranularity",{enumerable:!0,get:function(){return R.TemporalGranularity}});const S=r(3764);Object.defineProperty(e,"TimeFormat",{enumerable:!0,get:function(){return S.TimeFormat}});const _=r(8588);Object.defineProperty(e,"TemporalType",{enumerable:!0,get:function(){return _.TemporalType}});const v=r(3447);Object.defineProperty(e,"NumberType",{enumerable:!0,get:function(){return v.NumberType}});const N=r(8802);Object.defineProperty(e,"Iri",{enumerable:!0,get:function(){return N.Iri}});const w=r(2957);Object.defineProperty(e,"ControlledTermBranchBuilder",{enumerable:!0,get:function(){return w.ControlledTermBranchBuilder}});const L=r(3091);Object.defineProperty(e,"ControlledTermClassBuilder",{enumerable:!0,get:function(){return L.ControlledTermClassBuilder}});const F=r(5491);Object.defineProperty(e,"ControlledTermOntologyBuilder",{enumerable:!0,get:function(){return F.ControlledTermOntologyBuilder}});const O=r(1556);Object.defineProperty(e,"ControlledTermValueSetBuilder",{enumerable:!0,get:function(){return O.ControlledTermValueSetBuilder}});const V=r(2480);Object.defineProperty(e,"ControlledTermDefaultValueBuilder",{enumerable:!0,get:function(){return V.ControlledTermDefaultValueBuilder}});const B=r(5753);Object.defineProperty(e,"ControlledTermVersion",{enumerable:!0,get:function(){return B.ControlledTermVersion}});const D=r(3910);Object.defineProperty(e,"BiboStatus",{enumerable:!0,get:function(){return D.BiboStatus}});const M=r(455);Object.defineProperty(e,"ChildDeploymentInfo",{enumerable:!0,get:function(){return M.ChildDeploymentInfo}});const U=r(3608);Object.defineProperty(e,"ChildDeploymentInfoBuilder",{enumerable:!0,get:function(){return U.ChildDeploymentInfoBuilder}});const J=r(8534);Object.defineProperty(e,"CedarArtifactId",{enumerable:!0,get:function(){return J.CedarArtifactId}});const Y=r(2888);Object.defineProperty(e,"ComparisonError",{enumerable:!0,get:function(){return Y.ComparisonError}});const x=r(1888);Object.defineProperty(e,"RoundTrip",{enumerable:!0,get:function(){return x.RoundTrip}});const P=r(6389);Object.defineProperty(e,"PropertyIri",{enumerable:!0,get:function(){return P.PropertyIri}});const k=r(6320);Object.defineProperty(e,"JsonTemplateInstanceWriter",{enumerable:!0,get:function(){return k.JsonTemplateInstanceWriter}});const W=r(350);Object.defineProperty(e,"JsonTemplateInstanceContent",{enumerable:!0,get:function(){return W.JsonTemplateInstanceContent}});const K=r(7733);Object.defineProperty(e,"ControlledTermActionBuilder",{enumerable:!0,get:function(){return K.ControlledTermActionBuilder}});const j=r(8349);Object.defineProperty(e,"YamlValues",{enumerable:!0,get:function(){return j.YamlValues}});const G=r(4531);Object.defineProperty(e,"BioportalTermType",{enumerable:!0,get:function(){return G.BioportalTermType}});const X=r(8421);Object.defineProperty(e,"CedarFieldCategory",{enumerable:!0,get:function(){return X.CedarFieldCategory}});const $=r(2999);Object.defineProperty(e,"YamlTemplateFieldReader",{enumerable:!0,get:function(){return $.YamlTemplateFieldReader}});const q=r(8239);Object.defineProperty(e,"YamlTemplateElementReader",{enumerable:!0,get:function(){return q.YamlTemplateElementReader}});const H=r(5677);Object.defineProperty(e,"YamlTemplateReader",{enumerable:!0,get:function(){return H.YamlTemplateReader}});const z=r(9946);Object.defineProperty(e,"YamlTemplateInstanceReader",{enumerable:!0,get:function(){return z.YamlTemplateInstanceReader}});const Q=r(9961);Object.defineProperty(e,"InstanceInflater",{enumerable:!0,get:function(){return Q.InstanceInflater}});const Z=r(8410);Object.defineProperty(e,"InstanceValidator",{enumerable:!0,get:function(){return Z.InstanceValidator}});const ee=r(2763);Object.defineProperty(e,"CedarArtifactType",{enumerable:!0,get:function(){return ee.CedarArtifactType}});const te=r(978);Object.defineProperty(e,"JsonAbstractSchemaArtifactReader",{enumerable:!0,get:function(){return te.JsonAbstractSchemaArtifactReader}});const re=r(1998);Object.defineProperty(e,"CedarReaders",{enumerable:!0,get:function(){return re.CedarReaders}});const ne=r(8333);Object.defineProperty(e,"AbstractSchemaArtifact",{enumerable:!0,get:function(){return ne.AbstractSchemaArtifact}});const ae=r(5451);Object.defineProperty(e,"AbstractContainerArtifact",{enumerable:!0,get:function(){return ae.AbstractContainerArtifact}});const ie=r(4869);Object.defineProperty(e,"CedarFieldType",{enumerable:!0,get:function(){return ie.CedarFieldType}});const se=r(3161);Object.defineProperty(e,"JsonAbstractArtifactWriter",{enumerable:!0,get:function(){return se.JsonAbstractArtifactWriter}});const oe=r(9760);Object.defineProperty(e,"ComparisonErrorType",{enumerable:!0,get:function(){return oe.ComparisonErrorType}});const le=r(9607);Object.defineProperty(e,"CedarJsonWriters",{enumerable:!0,get:function(){return le.CedarJsonWriters}});const ce=r(2103);Object.defineProperty(e,"CedarJsonReaders",{enumerable:!0,get:function(){return ce.CedarJsonReaders}});const de=r(5359);Object.defineProperty(e,"CedarYamlWriters",{enumerable:!0,get:function(){return de.CedarYamlWriters}});const ue=r(8639);Object.defineProperty(e,"CedarYamlReaders",{enumerable:!0,get:function(){return ue.CedarYamlReaders}});const me=r(5697);Object.defineProperty(e,"AbstractInstanceArtifact",{enumerable:!0,get:function(){return me.AbstractInstanceArtifact}});const pe=r(2674);Object.defineProperty(e,"AbstractArtifact",{enumerable:!0,get:function(){return pe.AbstractArtifact}});const he=r(2272);Object.defineProperty(e,"TemplateInstance",{enumerable:!0,get:function(){return he.TemplateInstance}});const fe=r(7723);Object.defineProperty(e,"InstanceDataContainer",{enumerable:!0,get:function(){return fe.InstanceDataContainer}});const Te=r(9327);Object.defineProperty(e,"InstanceDataAttributeValueField",{enumerable:!0,get:function(){return Te.InstanceDataAttributeValueField}});const ye=r(3644);Object.defineProperty(e,"InstanceDataAttributeValueFieldName",{enumerable:!0,get:function(){return ye.InstanceDataAttributeValueFieldName}});const Ee=r(4033);Object.defineProperty(e,"AttributeValueNamePolicy",{enumerable:!0,get:function(){return Ee.AttributeValueNamePolicy}});const Ce=r(4465);Object.defineProperty(e,"InstanceDataEmptyNode",{enumerable:!0,get:function(){return Ce.InstanceDataEmptyNode}});const ge=r(7548);Object.defineProperty(e,"InstanceDataEmptyAtom",{enumerable:!0,get:function(){return ge.InstanceDataEmptyAtom}});const Ie=r(5222);Object.defineProperty(e,"InstanceDataStringAtom",{enumerable:!0,get:function(){return Ie.InstanceDataStringAtom}});const Ae=r(4877);Object.defineProperty(e,"InstanceDataTypedAtom",{enumerable:!0,get:function(){return Ae.InstanceDataTypedAtom}});const be=r(7571);Object.defineProperty(e,"InstanceDataLinkAtom",{enumerable:!0,get:function(){return be.InstanceDataLinkAtom}});const Re=r(8193);Object.defineProperty(e,"InstanceDataControlledAtom",{enumerable:!0,get:function(){return Re.InstanceDataControlledAtom}});const Se=r(9232);Object.defineProperty(e,"JsonTemplateInstanceReader",{enumerable:!0,get:function(){return Se.JsonTemplateInstanceReader}});const _e=r(3326);Object.defineProperty(e,"JsonAbstractInstanceArtifactReader",{enumerable:!0,get:function(){return _e.JsonAbstractInstanceArtifactReader}});const ve=r(7993);Object.defineProperty(e,"JsonAbstractArtifactReader",{enumerable:!0,get:function(){return ve.JsonAbstractArtifactReader}});const Ne=r(7954);Object.defineProperty(e,"JsonTemplateReaderResult",{enumerable:!0,get:function(){return Ne.JsonTemplateReaderResult}});const we=r(2234);Object.defineProperty(e,"CedarUser",{enumerable:!0,get:function(){return we.CedarUser}});const Le=r(8518);Object.defineProperty(e,"JsonArtifactReaderResult",{enumerable:!0,get:function(){return Le.JsonArtifactReaderResult}});const Fe=r(4948);Object.defineProperty(e,"JsonTemplateElementReaderResult",{enumerable:!0,get:function(){return Fe.JsonTemplateElementReaderResult}});const Oe=r(6396);Object.defineProperty(e,"JsonTemplateFieldReaderResult",{enumerable:!0,get:function(){return Oe.JsonTemplateFieldReaderResult}});const Ve=r(6537);Object.defineProperty(e,"JsonTemplateInstanceReaderResult",{enumerable:!0,get:function(){return Ve.JsonTemplateInstanceReaderResult}});const Be=r(1027);Object.defineProperty(e,"PavVersion",{enumerable:!0,get:function(){return Be.PavVersion}});const De=r(3581);Object.defineProperty(e,"ChildDeploymentInfoStatic",{enumerable:!0,get:function(){return De.ChildDeploymentInfoStatic}});const Me=r(8290);Object.defineProperty(e,"ChildDeploymentInfoStaticBuilder",{enumerable:!0,get:function(){return Me.ChildDeploymentInfoStaticBuilder}});const Ue=r(2266);Object.defineProperty(e,"ChildDeploymentInfoAlwaysSingle",{enumerable:!0,get:function(){return Ue.ChildDeploymentInfoAlwaysSingle}});const Je=r(587);Object.defineProperty(e,"ChildDeploymentInfoAlwaysSingleBuilder",{enumerable:!0,get:function(){return Je.ChildDeploymentInfoAlwaysSingleBuilder}});const Ye=r(8878);Object.defineProperty(e,"ChildDeploymentInfoAlwaysMultiple",{enumerable:!0,get:function(){return Ye.ChildDeploymentInfoAlwaysMultiple}});const xe=r(3239);Object.defineProperty(e,"ChildDeploymentInfoAlwaysMultipleBuilder",{enumerable:!0,get:function(){return xe.ChildDeploymentInfoAlwaysMultipleBuilder}});const Pe=r(513);Object.defineProperty(e,"AbstractChildDeploymentInfo",{enumerable:!0,get:function(){return Pe.AbstractChildDeploymentInfo}});const ke=r(6910);Object.defineProperty(e,"AbstractChildDeploymentInfoBuilder",{enumerable:!0,get:function(){return ke.AbstractChildDeploymentInfoBuilder}});const We=r(4809);Object.defineProperty(e,"AbstractDynamicChildDeploymentInfoBuilder",{enumerable:!0,get:function(){return We.AbstractDynamicChildDeploymentInfoBuilder}});const Ke=r(3812);Object.defineProperty(e,"AbstractDynamicChildDeploymentInfo",{enumerable:!0,get:function(){return Ke.AbstractDynamicChildDeploymentInfo}});const je=r(4036);Object.defineProperty(e,"JsonArtifactParsingResult",{enumerable:!0,get:function(){return je.JsonArtifactParsingResult}});const Ge=r(1591);Object.defineProperty(e,"YamlArtifactParsingResult",{enumerable:!0,get:function(){return Ge.YamlArtifactParsingResult}});const Xe=r(4325);Object.defineProperty(e,"ComparisonResult",{enumerable:!0,get:function(){return Xe.ComparisonResult}});const $e=r(1885);Object.defineProperty(e,"YamlObjectComparator",{enumerable:!0,get:function(){return $e.YamlObjectComparator}});const qe=r(3056);Object.defineProperty(e,"JsonObjectComparator",{enumerable:!0,get:function(){return qe.JsonObjectComparator}});const He=r(7868);Object.defineProperty(e,"YamlTemplateReaderResult",{enumerable:!0,get:function(){return He.YamlTemplateReaderResult}});const ze=r(1790);Object.defineProperty(e,"YamlTemplateFieldReaderResult",{enumerable:!0,get:function(){return ze.YamlTemplateFieldReaderResult}});const Qe=r(4646);Object.defineProperty(e,"YamlTemplateElementReaderResult",{enumerable:!0,get:function(){return Qe.YamlTemplateElementReaderResult}});const Ze=r(6532);Object.defineProperty(e,"YamlArtifactReaderResult",{enumerable:!0,get:function(){return Ze.YamlArtifactReaderResult}});const et=r(147);Object.defineProperty(e,"YamlTemplateInstanceReaderResult",{enumerable:!0,get:function(){return et.YamlTemplateInstanceReaderResult}});const tt=r(7752);Object.defineProperty(e,"Language",{enumerable:!0,get:function(){return tt.Language}})})();const a=n.AbstractArtifact,i=n.AbstractChildDeploymentInfo,s=n.AbstractChildDeploymentInfoBuilder,o=n.AbstractContainerArtifact,l=n.AbstractDynamicChildDeploymentInfo,c=n.AbstractDynamicChildDeploymentInfoBuilder,d=n.AbstractInstanceArtifact,u=n.AbstractSchemaArtifact,m=n.AttributeValueNamePolicy,p=n.BiboStatus,h=n.BioportalTermType,f=n.CedarArtifactId,T=n.CedarArtifactType,y=n.CedarBuilders,E=n.CedarFieldCategory,C=n.CedarFieldType,g=n.CedarJsonReaders,I=n.CedarJsonWriters,A=n.CedarReaders,b=n.CedarUser,R=n.CedarWriters,S=n.CedarYamlReaders,_=n.CedarYamlWriters,v=n.ChildDeploymentInfo,N=n.ChildDeploymentInfoAlwaysMultiple,w=n.ChildDeploymentInfoAlwaysMultipleBuilder,L=n.ChildDeploymentInfoAlwaysSingle,F=n.ChildDeploymentInfoAlwaysSingleBuilder,O=n.ChildDeploymentInfoBuilder,V=n.ChildDeploymentInfoStatic,B=n.ChildDeploymentInfoStaticBuilder,D=n.ComparisonError,M=n.ComparisonErrorType,U=n.ComparisonResult,J=n.ControlledTermActionBuilder,Y=n.ControlledTermBranchBuilder,x=n.ControlledTermClassBuilder,P=n.ControlledTermDefaultValueBuilder,k=n.ControlledTermOntologyBuilder,W=n.ControlledTermValueSetBuilder,K=n.ControlledTermVersion,j=n.InstanceDataAttributeValueField,G=n.InstanceDataAttributeValueFieldName,X=n.InstanceDataContainer,$=n.InstanceDataControlledAtom,q=n.InstanceDataEmptyAtom,H=n.InstanceDataEmptyNode,z=n.InstanceDataLinkAtom,Q=n.InstanceDataStringAtom,Z=n.InstanceDataTypedAtom,ee=n.InstanceInflater,te=n.InstanceValidator,re=n.Iri,ne=n.IsoDate,ae=n.JsonAbstractArtifactReader,ie=n.JsonAbstractArtifactWriter,se=n.JsonAbstractInstanceArtifactReader,oe=n.JsonAbstractSchemaArtifactReader,le=n.JsonArtifactParsingResult,ce=n.JsonArtifactReaderResult,de=n.JsonNode,ue=n.JsonObjectComparator,me=n.JsonPath,pe=n.JsonTemplateElementReader,he=n.JsonTemplateElementReaderResult,fe=n.JsonTemplateElementWriter,Te=n.JsonTemplateFieldReader,ye=n.JsonTemplateFieldReaderResult,Ee=n.JsonTemplateFieldWriter,Ce=n.JsonTemplateInstanceContent,ge=n.JsonTemplateInstanceReader,Ie=n.JsonTemplateInstanceReaderResult,Ae=n.JsonTemplateInstanceWriter,be=n.JsonTemplateReader,Re=n.JsonTemplateReaderResult,Se=n.JsonTemplateWriter,_e=n.Language,ve=n.NumberType,Ne=n.PavVersion,we=n.PropertyIri,Le=n.RoundTrip,Fe=n.SchemaVersion,Oe=n.Template,Ve=n.TemplateBuilder,Be=n.TemplateElement,De=n.TemplateElementBuilder,Me=n.TemplateField,Ue=n.TemplateInstance,Je=n.TemplateInstanceBuilder,Ye=n.TemporalGranularity,xe=n.TemporalType,Pe=n.TimeFormat,ke=n.YamlArtifactParsingResult,We=n.YamlArtifactReaderResult,Ke=n.YamlObjectComparator,je=n.YamlTemplateElementReader,Ge=n.YamlTemplateElementReaderResult,Xe=n.YamlTemplateElementWriter,$e=n.YamlTemplateFieldReader,qe=n.YamlTemplateFieldReaderResult,He=n.YamlTemplateFieldWriter,ze=n.YamlTemplateInstanceReader,Qe=n.YamlTemplateInstanceReaderResult,Ze=n.YamlTemplateReader,et=n.YamlTemplateReaderResult,tt=n.YamlTemplateWriter,rt=n.YamlValues,nt=n.__esModule;export{a as AbstractArtifact,i as AbstractChildDeploymentInfo,s as AbstractChildDeploymentInfoBuilder,o as AbstractContainerArtifact,l as AbstractDynamicChildDeploymentInfo,c as AbstractDynamicChildDeploymentInfoBuilder,d as AbstractInstanceArtifact,u as AbstractSchemaArtifact,m as AttributeValueNamePolicy,p as BiboStatus,h as BioportalTermType,f as CedarArtifactId,T as CedarArtifactType,y as CedarBuilders,E as CedarFieldCategory,C as CedarFieldType,g as CedarJsonReaders,I as CedarJsonWriters,A as CedarReaders,b as CedarUser,R as CedarWriters,S as CedarYamlReaders,_ as CedarYamlWriters,v as ChildDeploymentInfo,N as ChildDeploymentInfoAlwaysMultiple,w as ChildDeploymentInfoAlwaysMultipleBuilder,L as ChildDeploymentInfoAlwaysSingle,F as ChildDeploymentInfoAlwaysSingleBuilder,O as ChildDeploymentInfoBuilder,V as ChildDeploymentInfoStatic,B as ChildDeploymentInfoStaticBuilder,D as ComparisonError,M as ComparisonErrorType,U as ComparisonResult,J as ControlledTermActionBuilder,Y as ControlledTermBranchBuilder,x as ControlledTermClassBuilder,P as ControlledTermDefaultValueBuilder,k as ControlledTermOntologyBuilder,W as ControlledTermValueSetBuilder,K as ControlledTermVersion,j as InstanceDataAttributeValueField,G as InstanceDataAttributeValueFieldName,X as InstanceDataContainer,$ as InstanceDataControlledAtom,q as InstanceDataEmptyAtom,H as InstanceDataEmptyNode,z as InstanceDataLinkAtom,Q as InstanceDataStringAtom,Z as InstanceDataTypedAtom,ee as InstanceInflater,te as InstanceValidator,re as Iri,ne as IsoDate,ae as JsonAbstractArtifactReader,ie as JsonAbstractArtifactWriter,se as JsonAbstractInstanceArtifactReader,oe as JsonAbstractSchemaArtifactReader,le as JsonArtifactParsingResult,ce as JsonArtifactReaderResult,de as JsonNode,ue as JsonObjectComparator,me as JsonPath,pe as JsonTemplateElementReader,he as JsonTemplateElementReaderResult,fe as JsonTemplateElementWriter,Te as JsonTemplateFieldReader,ye as JsonTemplateFieldReaderResult,Ee as JsonTemplateFieldWriter,Ce as JsonTemplateInstanceContent,ge as JsonTemplateInstanceReader,Ie as JsonTemplateInstanceReaderResult,Ae as JsonTemplateInstanceWriter,be as JsonTemplateReader,Re as JsonTemplateReaderResult,Se as JsonTemplateWriter,_e as Language,ve as NumberType,Ne as PavVersion,we as PropertyIri,Le as RoundTrip,Fe as SchemaVersion,Oe as Template,Ve as TemplateBuilder,Be as TemplateElement,De as TemplateElementBuilder,Me as TemplateField,Ue as TemplateInstance,Je as TemplateInstanceBuilder,Ye as TemporalGranularity,xe as TemporalType,Pe as TimeFormat,ke as YamlArtifactParsingResult,We as YamlArtifactReaderResult,Ke as YamlObjectComparator,je as YamlTemplateElementReader,Ge as YamlTemplateElementReaderResult,Xe as YamlTemplateElementWriter,$e as YamlTemplateFieldReader,qe as YamlTemplateFieldReaderResult,He as YamlTemplateFieldWriter,ze as YamlTemplateInstanceReader,Qe as YamlTemplateInstanceReaderResult,Ze as YamlTemplateReader,et as YamlTemplateReaderResult,tt as YamlTemplateWriter,rt as YamlValues,nt as __esModule,n as default};
|
|
1
|
+
var e={5846(e,t,r){t.JsonReaderBehavior=t.C=void 0;const n=r(7639);t.C={STRICT:"strict",FEBRUARY_2024:"february-2024"};class a extends n.ReaderWriterBehavior{value;constructor(e,t){super(t),this.value=e}getValue(){return this.value}static STRICT=new a(t.C.STRICT,!1);static FEBRUARY_2024=new a(t.C.FEBRUARY_2024,!0)}t.JsonReaderBehavior=a},2022(e,t,r){t.JsonWriterBehavior=t.C=void 0;const n=r(7639);t.C={STRICT:"strict",FEBRUARY_2024:"february-2024"};class a extends n.ReaderWriterBehavior{value;_outputPages;_usePropertiesAtLanguage;_includeSkosNotationForLinksAndControlled;constructor(e,t,r,n,a){super(a),this.value=e,this._outputPages=t,this._usePropertiesAtLanguage=r,this._includeSkosNotationForLinksAndControlled=n}getValue(){return this.value}static STRICT=new a(t.C.STRICT,!1,!0,!0,!1);static FEBRUARY_2024=new a(t.C.FEBRUARY_2024,!0,!1,!1,!0);outputPages(){return this._outputPages}usePropertiesAtLanguage(){return this._usePropertiesAtLanguage}includeSkosNotationForLinksAndControlled(){return this._includeSkosNotationForLinksAndControlled}}t.JsonWriterBehavior=a},7639(e,t){t.ReaderWriterBehavior=void 0,t.ReaderWriterBehavior=class{_useWarningForKnownIssues;constructor(e){this._useWarningForKnownIssues=e}useWarningForKnownIssues(){return this._useWarningForKnownIssues}}},1395(e,t,r){t.YamlReaderBehavior=t.L=void 0;const n=r(7639);t.L={STRICT:"strict"};class a extends n.ReaderWriterBehavior{value;constructor(e,t){super(t),this.value=e}getValue(){return this.value}static STRICT=new a(t.L.STRICT,!1)}t.YamlReaderBehavior=a},9411(e,t,r){t.YamlWriterBehavior=t.D=void 0;const n=r(7639);t.D={STRICT:"strict"};class a extends n.ReaderWriterBehavior{value;constructor(e,t){super(t),this.value=e}getValue(){return this.value}static STRICT=new a(t.D.STRICT,!1)}t.YamlWriterBehavior=a},6568(e,t,r){t.CedarBuilders=void 0;const n=r(766),a=r(1762),i=r(4925),s=r(7889),o=r(1259),l=r(345),c=r(2875),d=r(8084),u=r(3675),m=r(9497),p=r(1667),h=r(2052),f=r(4675),T=r(9916),y=r(3138),E=r(2703),C=r(9521),g=r(5795),I=r(7674),A=r(9105),b=r(1513),R=r(7328),S=r(2376),_=r(3914),v=r(7162),N=r(3474),w=r(9062),L=r(6610);t.CedarBuilders=class{static templateBuilder(){return new n.TemplateBuilder}static templateElementBuilder(){return new a.TemplateElementBuilder}static templateInstanceBuilder(){return new i.TemplateInstanceBuilder}static textFieldBuilder(){return s.TextFieldBuilderImpl.create()}static textAreaBuilder(){return o.TextAreaBuilderImpl.create()}static temporalFieldBuilder(){return l.TemporalFieldBuilderImpl.create()}static phoneNumberFieldBuilder(){return d.PhoneNumberFieldBuilderImpl.create()}static numericFieldBuilder(){return u.NumericFieldBuilderImpl.create()}static emailFieldBuilder(){return p.EmailFieldBuilderImpl.create()}static attributeValueFieldBuilder(){return h.AttributeValueFieldBuilderImpl.create()}static youtubeFieldBuilder(){return I.StaticYoutubeFieldBuilderImpl.create()}static sectionBreakFieldBuilder(){return g.StaticSectionBreakFieldBuilderImpl.create()}static richTextFieldBuilder(){return C.StaticRichTextFieldBuilderImpl.create()}static pageBreakFieldBuilder(){return E.StaticPageBreakFieldBuilderImpl.create()}static imageFieldBuilder(){return y.StaticImageFieldBuilderImpl.create()}static linkFieldBuilder(){return m.LinkFieldBuilderImpl.create()}static extRorFieldBuilder(){return R.ExtRorFieldBuilderImpl.create()}static extOrcidFieldBuilder(){return S.ExtOrcidFieldBuilderImpl.create()}static extPfasFieldBuilder(){return _.ExtPfasFieldBuilderImpl.create()}static extPubmedFieldBuilder(){return v.ExtPubmedFieldBuilderImpl.create()}static extRridFieldBuilder(){return N.ExtRridFieldBuilderImpl.create()}static extNihGrantIdFieldBuilder(){return w.ExtNihGrantIdFieldBuilderImpl.create()}static extDoiFieldBuilder(){return L.ExtDoiFieldBuilderImpl.create()}static singleChoiceListFieldBuilder(){return A.SingleChoiceListFieldBuilderImpl.create()}static multipleChoiceListFieldBuilder(){return b.MultipleChoiceListFieldBuilderImpl.create()}static radioFieldBuilder(){return c.RadioFieldBuilderImpl.create()}static checkboxFieldBuilder(){return f.CheckboxFieldBuilderImpl.create()}static controlledTermFieldBuilder(){return T.ControlledTermFieldBuilderImpl.create()}}},1998(e,t,r){t.CedarReaders=void 0;const n=r(2103),a=r(8639);t.CedarReaders=class{static json(){return n.CedarJsonReaders}static yaml(){return a.CedarYamlReaders}}},8748(e,t,r){t.ReaderUtil=void 0;const n=r(9517),a=r(8802);t.ReaderUtil=class{static getString(e,t){return Object.hasOwn(e,t)?e[t]:null}static getStringOrEmpty(e,t){return Object.hasOwn(e,t)?e[t]:""}static getBoolean(e,t){return!!Object.hasOwn(e,t)&&e[t]}static getBooleanOrNullOrUndefined(e,t){return Object.hasOwn(e,t)?null===e[t]?null:e[t]:void 0}static getBooleanOrNull(e,t){return Object.hasOwn(e,t)?null===e[t]?null:e[t]:null}static getNumber(e,t){return Object.hasOwn(e,t)?e[t]:null}static getNumericDefault(e,t){if(!Object.hasOwn(e,t)||null===e[t]||void 0===e[t])return null;const r=e[t];if("number"==typeof r){if(Number.isFinite(r))return r;throw new Error(`Numeric default at "${t}" must be finite.`)}if("string"==typeof r){const e=r.trim();if(""===e)return null;if(!/^[+-]?(?:\d+(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+)?$/.test(e))throw new Error(`Numeric default at "${t}" is not a valid number: "${r}".`);const n=Number(e);if(Number.isFinite(n))return n;throw new Error(`Numeric default at "${t}" must be finite.`)}throw new Error(`Numeric default at "${t}" must be a number or numeric string.`)}static getNumberOrZero(e,t){return Object.hasOwn(e,t)?e[t]:0}static getNumberOrNull(e,t){return Object.hasOwn(e,t)?e[t]:null}static getNode(e,t){return Object.hasOwn(e,t)?e[t]:n.JsonNode.getEmpty()}static getNodeOrNull(e,t){return Object.hasOwn(e,t)?e[t]:null}static getStringList(e,t){return Object.hasOwn(e,t)&&Array.isArray(e[t])?e[t]:[]}static getFilteredStringList(e,t){return Object.hasOwn(e,t)&&Array.isArray(e[t])?e[t].filter(e=>""!==e.trim()):[]}static getStringMap(e,t){if(Object.hasOwn(e,t)&&"object"==typeof e[t]&&!Array.isArray(e[t])&&null!==e[t]){const r=e[t],n=Object.entries(r),a=new Map;for(const[e,t]of n)a.set(e,t);return a}return new Map}static deepClone(e){return this.deepUnfreeze(e)}static deepUnfreeze(e){if(null===e||"object"!=typeof e&&"function"!=typeof e)return e;const t=Array.isArray(e)?e.slice():{...e};return Object.getOwnPropertyNames(t).forEach(e=>{t[e]=this.deepUnfreeze(t[e])}),t}static deepFreeze(e){return Object.freeze(e),Object.getOwnPropertyNames(e).forEach(t=>{const r=e[t];null===r||"object"!=typeof r&&"function"!=typeof r||Object.isFrozen(r)||this.deepFreeze(r)}),e}static getNodeList(e,t){return Object.hasOwn(e,t)&&Array.isArray(e[t])?e[t]:n.JsonNode.getEmptyList()}static getURI(e,t){return new a.Iri(this.getStringOrEmpty(e,t))}static deleteNodeKey(e,t){Object.hasOwn(e,t)&&delete e[t]}}},2103(e,t,r){t.CedarJsonReaders=void 0;const n=r(2763),a=r(8748),i=r(2733),s=r(5291),o=r(7909),l=r(5846),c=r(9232),d=r(4381);class u{behavior;constructor(e){this.behavior=e}static getStrict(){return new u(l.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new u(l.JsonReaderBehavior.FEBRUARY_2024)}static detectArtifactType(e){let t;if(t="string"==typeof e?JSON.parse(e):e,t&&t["@type"]){const e=a.ReaderUtil.getString(t,i.JsonSchema.atType);return n.CedarArtifactType.forValue(e)}return n.CedarArtifactType.NULL}getReaderForArtifactType(e){switch(e){case n.CedarArtifactType.TEMPLATE:return s.JsonTemplateReader.getStrict();case n.CedarArtifactType.TEMPLATE_ELEMENT:return o.JsonTemplateElementReader.getStrict();case n.CedarArtifactType.TEMPLATE_FIELD:case n.CedarArtifactType.STATIC_TEMPLATE_FIELD:return d.JsonTemplateFieldReader.getStrict();case n.CedarArtifactType.TEMPLATE_INSTANCE:return c.JsonTemplateInstanceReader.getStrict();default:throw new Error(`No JSON reader available for CedarArtifactType: ${e}`)}}getTemplateReader(){return s.JsonTemplateReader.getForBehavior(this.behavior)}getTemplateElementReader(){return o.JsonTemplateElementReader.getForBehavior(this.behavior)}getTemplateFieldReader(){return d.JsonTemplateFieldReader.getForBehavior(this.behavior)}getTemplateInstanceReader(){return c.JsonTemplateInstanceReader.getForBehavior(this.behavior)}}t.CedarJsonReaders=u},7993(e,t,r){t.JsonAbstractArtifactReader=void 0;const n=r(8534),a=r(8748),i=r(2733),s=r(2234),o=r(9857),l=r(2763),c=r(5226),d=r(936),u=r(2787),m=r(3549);class p{static refuseEmptyIdentifier(e,t=i.JsonSchema.atId){const r=a.ReaderUtil.getString(e,t);if(null!==r&&""===r.trim())throw new Error(`An empty string is not a URI at "${t}"; write null or leave the key out where there is no value.`)}behavior;knownArtifactType=l.CedarArtifactType.NULL;constructor(e){this.behavior=e}readNonReportableAttributes(e,t){p.refuseEmptyIdentifier(t),e.at_id=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.atId)),e.schema_name=a.ReaderUtil.getString(t,i.JsonSchema.schemaName),e.schema_description=a.ReaderUtil.getString(t,i.JsonSchema.schemaDescription),e.pav_createdBy=s.CedarUser.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavCreatedBy)),e.pav_createdOn=o.IsoDate.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavCreatedOn)),e.oslc_modifiedBy=s.CedarUser.forValue(a.ReaderUtil.getString(t,i.JsonSchema.oslcModifiedBy)),e.pav_lastUpdatedOn=o.IsoDate.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavLastUpdatedOn))}readAnnotations(e,t){const r=new c.Annotations,n=a.ReaderUtil.getNodeOrNull(t,d.CedarModel.annotations);null!==n&&Object.keys(n).forEach(e=>{const t=a.ReaderUtil.getNode(n,e),s=a.ReaderUtil.getString(t,i.JsonSchema.atId);if(null!==s)r.add(new u.AnnotationAtId(e,s));else{const n=a.ReaderUtil.getString(t,i.JsonSchema.atValue);null!==n&&r.add(new m.AnnotationAtValue(e,n))}}),r.getSize()>0&&(e.annotations=r)}}t.JsonAbstractArtifactReader=p},3326(e,t,r){t.JsonAbstractInstanceArtifactReader=void 0;const n=r(8534),a=r(8748),i=r(2733),s=r(7993);class o extends s.JsonAbstractArtifactReader{constructor(e){super(e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.schema_isBasedOn=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.schemaIsBasedOn)),e.pav_derivedFrom=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavDerivedFrom))}}t.JsonAbstractInstanceArtifactReader=o},978(e,t,r){t.JsonAbstractSchemaArtifactReader=void 0;const n=r(8534),a=r(8748),i=r(2733),s=r(5747),o=r(8557),l=r(1027),c=r(3910),d=r(7993);class u extends d.JsonAbstractArtifactReader{constructor(e){super(e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.title=a.ReaderUtil.getString(t,s.TemplateProperty.title),e.description=a.ReaderUtil.getString(t,s.TemplateProperty.description),e.schema_schemaVersion=o.SchemaVersion.forValue(a.ReaderUtil.getString(t,i.JsonSchema.schemaVersion)),e.pav_version=l.PavVersion.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavVersion)),e.bibo_status=c.BiboStatus.forJsonValue(a.ReaderUtil.getString(t,i.JsonSchema.biboStatus)),e.pav_derivedFrom=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavDerivedFrom)),e.pav_previousVersion=n.CedarArtifactId.forValue(a.ReaderUtil.getString(t,i.JsonSchema.pavPreviousVersion)),e.schema_identifier=a.ReaderUtil.getString(t,i.JsonSchema.schemaIdentifier)}}t.JsonAbstractSchemaArtifactReader=u},8518(e,t){t.JsonArtifactReaderResult=void 0,t.JsonArtifactReaderResult=class{_artifact;_parsingResult;_artifactSourceObject;constructor(e,t,r){this._artifact=e,this._parsingResult=t,this._artifactSourceObject=r}get artifact(){return this._artifact}get parsingResult(){return this._parsingResult}get artifactSourceObject(){return this._artifactSourceObject}}},5510(e,t,r){t.JsonContainerArtifactReader=void 0;const n=r(978),a=r(1492),i=r(455),s=r(2763),o=r(8748),l=r(2733),c=r(936),d=r(9034),u=r(2888),m=r(9760),p=r(3056),h=r(5793),f=r(2475),T=r(6968),y=r(3812),E=r(3608),C=r(3239),g=r(7752),I=r(8220);class A extends n.JsonAbstractSchemaArtifactReader{fieldReader;constructor(e){super(e),this.fieldReader=I.JsonTemplateFieldReaderInternal.getForBehavior(e)}readAndStoreCandidateChildInfo(e,t,r,n,a){const p=s.CedarArtifactType.forValue(o.ReaderUtil.getString(e,l.JsonSchema.atType));if(p!==s.CedarArtifactType.NULL){const r=new i.ChildDeploymentInfo(t);r.atType=p;const a=o.ReaderUtil.getNode(e,c.CedarModel.ui);return r.uiInputType=d.UiInputType.forValue(o.ReaderUtil.getString(a,c.CedarModel.inputType)),r.hidden=o.ReaderUtil.getBoolean(a,c.CedarModel.Ui.hidden),n.add(r),r}return this.reportBlueprintDifference(r,new u.ComparisonError("jtr09",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,a.add(t,l.JsonSchema.atType))),null}readReportableAttributes(e,t,r,n){p.JsonObjectComparator.comparePrimitive(r,this.knownArtifactType.getValue(),o.ReaderUtil.getString(t,l.JsonSchema.atType),n.add(l.JsonSchema.atType));const a=o.ReaderUtil.getNode(t,l.JsonSchema.atContext),i=T.JsonContainerArtifactContent.CONTEXT_VERBATIM;p.JsonObjectComparator.compareBothWays(r,i,a,n.add(l.JsonSchema.atContext),this.behavior,[l.JsonSchema.atLanguage]),p.JsonObjectComparator.comparePrimitive(r,h.JavascriptType.OBJECT.getValue(),o.ReaderUtil.getString(t,c.CedarModel.type),n.add(c.CedarModel.type)),p.JsonObjectComparator.comparePrimitive(r,f.ArtifactSchema.CURRENT.getValue(),o.ReaderUtil.getString(t,c.CedarModel.schema),n.add(c.CedarModel.schema)),e.language=g.Language.forValue(o.ReaderUtil.getString(a,l.JsonSchema.atLanguage))}parseChildren(e,t,r,n,a){for(const c of e.children){let e=o.ReaderUtil.getNode(t,c.name),d=a.add(l.JsonSchema.properties,c.name);if(c.isMultiInAnyWay()&&(e=o.ReaderUtil.getNode(e,l.JsonSchema.items),d=d.add(l.JsonSchema.items)),c.atType===s.CedarArtifactType.STATIC_TEMPLATE_FIELD){const t=this.fieldReader.readFromObjectInternal(e,c,d),a=t.field.createDeploymentBuilder(c.name).withLabel(c.label).withDescription(c.description).withHidden(c.hidden).build();r.addChild(t.field,a),n.merge(t.parsingResult)}else if(c.atType===s.CedarArtifactType.TEMPLATE_FIELD){const t=this.fieldReader.readFromObjectInternal(e,c,d),a=t.field.createDeploymentBuilder(c.name),s=c;a.withIri(s.iri).withHidden(s.hidden).withContinuePreviousLine(s.continuePreviousLine).withValueRecommendationEnabled(s.valueRecommendationEnabled).withLabel(c.label).withDescription(c.description).withRecommendedValue(s.recommendedValue).withRequiredValue(s.requiredValue),a instanceof E.ChildDeploymentInfoBuilder&&c instanceof i.ChildDeploymentInfo?a.withMultiInstance(c.multiInstance).withMinItems(c.minItems).withMaxItems(c.maxItems):a instanceof C.ChildDeploymentInfoAlwaysMultipleBuilder&&a.withMinItems(s.minItems).withMaxItems(s.maxItems);const o=a.build();r.addChild(t.field,o),n.merge(t.parsingResult)}else if(c.atType===s.CedarArtifactType.TEMPLATE_ELEMENT){const t=this.getElementReader().readFromObject(e,d);r.addChild(t.element,c),n.merge(t.parsingResult)}}}validatePropertiesVsOrder(e,t,r,n){for(const a of e.children)t.includes(a.name)||this.reportBlueprintDifference(r,new u.ComparisonError("jtr08",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,n.add(c.CedarModel.ui,c.CedarModel.order),a.name,null))}finalizeChildInfo(e,t,r,n){const i=new a.ContainerArtifactChildrenInfo;for(const a of e){const e=t.get(a);null!=e?i.add(e):this.reportBlueprintDifference(r,new u.ComparisonError("jtr07",m.ComparisonErrorType.UNEXPECTED_KEY_IN_REAL_OBJECT,n.add(c.CedarModel.ui,c.CedarModel.order),null,a))}return i}getCandidateChildrenInfo(e,t,r,n){const i=new a.ContainerArtifactChildrenInfo;return Object.keys(e).forEach(a=>{if(!t.has(a)){const t=o.ReaderUtil.getNode(e,a);if("object"==typeof t&&null!==t){let e=t;const s=o.ReaderUtil.getString(t,l.JsonSchema.type);if("object"==s)this.readAndStoreCandidateChildInfo(e,a,r,i,n.add(l.JsonSchema.properties,a));else if("array"==s){e=o.ReaderUtil.getNode(t,l.JsonSchema.items);const s=this.readAndStoreCandidateChildInfo(e,a,r,i,n.add(l.JsonSchema.properties,a,l.JsonSchema.items));null!==s&&(s.multiInstance=!0,s.minItems=o.ReaderUtil.getNumber(t,c.CedarModel.minItems),s.maxItems=o.ReaderUtil.getNumber(t,c.CedarModel.maxItems))}}}}),i}generateAndValidateRequiredMap(e,t,r,n){const a=e.reduce((e,t)=>(e.set(t,!0),e),new Map);for(const e of t)a.has(e)||this.reportBlueprintDifference(r,new u.ComparisonError("jtr01",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,n.add(l.JsonSchema.required),e));return a}checkRequiredBothWays(e,t,r,n,a,i){const s=e.getChildrenNamesForRequired();for(const e of s)t.has(e)||this.reportBlueprintDifference(a,new u.ComparisonError("jtr02",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,i.add(l.JsonSchema.required),e));for(const t of r)n.has(t)||e.has(t)||this.reportBlueprintDifference(a,new u.ComparisonError("jtr03",m.ComparisonErrorType.UNEXPECTED_KEY_IN_REAL_OBJECT,i.add(l.JsonSchema.required),t))}extractUIPreferredLabelsAndDescriptions(e,t,r,n){const a=o.ReaderUtil.getStringMap(e,c.CedarModel.propertyLabels);if(null!==a)for(const e of t.children)a.has(e.name)&&(e.label=a.get(e.name)??null);const i=o.ReaderUtil.getStringMap(e,c.CedarModel.propertyDescriptions);if(null!==i)for(const e of t.children)i.has(e.name)&&(e.description=i.get(e.name)??null)}reportBlueprintDifference(e,t){this.behavior.useWarningForKnownIssues()&&p.JsonObjectComparator.isKnownProductionVariation(t.errorPath)?e.addBlueprintComparisonWarning(t):e.addBlueprintComparisonError(t)}extractIRIMappings(e,t,r,n){const a=o.ReaderUtil.getNode(e,l.JsonSchema.atContext),i=o.ReaderUtil.getNode(a,l.JsonSchema.properties);for(const e of t.children)if(this.includeInIRIMapping(e)){const t=o.ReaderUtil.getNode(i,e.name),a=o.ReaderUtil.getStringList(t,l.JsonSchema.enum);null===a||1!=a.length?this.reportBlueprintDifference(r,new u.ComparisonError("jtr06",m.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,n.add(l.JsonSchema.properties,l.JsonSchema.atContext,l.JsonSchema.properties,e.name,l.JsonSchema.enum,0))):e instanceof y.AbstractDynamicChildDeploymentInfo&&(e.iri=a[0])}}readInstanceTypeSpecification(e,t,r){const n=o.ReaderUtil.getNode(t,l.JsonSchema.properties);if(null!==n){const t=o.ReaderUtil.getNode(n,l.JsonSchema.atType);if(null!==t){const r=o.ReaderUtil.getNodeList(t,l.JsonSchema.oneOf);null!==r&&r.forEach(t=>{const r=o.ReaderUtil.getStringList(t,l.JsonSchema.enum);null!=r&&r.length>0&&(e.instanceTypeSpecification=r[0])})}}}}t.JsonContainerArtifactReader=A},7909(e,t,r){t.JsonTemplateElementReader=void 0;const n=r(936),a=r(2733),i=r(2763),s=r(5747),o=r(8748),l=r(3056),c=r(4036),d=r(3188),u=r(5846),m=r(9932),p=r(4948),h=r(7661),f=r(5510),T=r(1501);class y extends f.JsonContainerArtifactReader{knownArtifactType=i.CedarArtifactType.TEMPLATE_ELEMENT;constructor(e){super(e)}static getStrict(){return new y(u.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new y(u.JsonReaderBehavior.FEBRUARY_2024)}static getForBehavior(e){return new y(e)}getElementReader(){return this}includeInIRIMapping(e){return e.atType!==i.CedarArtifactType.STATIC_TEMPLATE_FIELD}readFromString(e){let t;try{t=JSON.parse(e)}catch{t={}}return this.readFromObject(t,new d.JsonPath)}readFromObject(e,t=new d.JsonPath){const r=new c.JsonArtifactParsingResult,n=h.TemplateElement.buildEmptyWithNullValues();return this.readNonReportableAttributes(n,e),this.readReportableAttributes(n,e,r,t),this.readAnnotations(n,e),this.readInstanceTypeSpecification(n,e,r),this.readAndValidateChildrenInfo(n,e,r,t),new p.JsonTemplateElementReaderResult(n,r,e)}readNonReportableAttributes(e,t){e.skos_prefLabel=o.ReaderUtil.getString(t,n.CedarModel.skosPrefLabel),e.skos_altLabel=o.ReaderUtil.getFilteredStringList(t,n.CedarModel.skosAltLabel),super.readNonReportableAttributes(e,t)}readAndValidateChildrenInfo(e,t,r,i){const s=o.ReaderUtil.getStringList(t,a.JsonSchema.required),l=o.ReaderUtil.getNode(t,a.JsonSchema.properties),c=this.generateAndValidateRequiredMap(s,T.JsonTemplateElementContent.REQUIRED_PARTIAL,r,i),d=this.getCandidateChildrenInfo(l,T.JsonTemplateElementContent.PROPERTIES_PARTIAL_KEY_MAP,r,i);this.checkRequiredBothWays(d,c,s,T.JsonTemplateElementContent.REQUIRED_PARTIAL_KEY_MAP,r,i);const u=o.ReaderUtil.getNode(t,n.CedarModel.ui);this.extractUIPreferredLabelsAndDescriptions(u,d,r,i),this.extractIRIMappings(l,d,r,i);const m=o.ReaderUtil.getStringList(u,n.CedarModel.order),p=this.finalizeChildInfo(m,d,r,i);this.validatePropertiesVsOrder(d,m,r,i),this.validateProperties(p,l,e,r,i),this.parseChildren(p,l,e,r,i)}validateProperties(e,t,r,n,i){const c=o.ReaderUtil.deepClone(T.JsonTemplateElementContent.PROPERTIES_PARTIAL);e.hasAttributeValue()&&(c[a.JsonSchema.atContext][s.TemplateProperty.additionalProperties]=m.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE);const d=c[a.JsonSchema.atContext],u=o.ReaderUtil.getNodeList(d,a.JsonSchema.required);null!=u&&0==u.length&&o.ReaderUtil.deleteNodeKey(d,a.JsonSchema.required),T.JsonTemplateElementContent.acceptEitherIdTyping(c,t),l.JsonObjectComparator.compareToLeft(n,c,t,i.add(a.JsonSchema.properties),this.behavior)}}t.JsonTemplateElementReader=y},4948(e,t,r){t.JsonTemplateElementReaderResult=void 0;const n=r(8518);class a extends n.JsonArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get element(){return this._artifact}get elementSourceObject(){return this._artifactSourceObject}}t.JsonTemplateElementReaderResult=a},4381(e,t,r){t.JsonTemplateFieldReader=void 0;const n=r(9517),a=r(4036),i=r(3188),s=r(8748),o=r(2733),l=r(5747),c=r(3056),d=r(2763),u=r(5793),m=r(936),p=r(2475),h=r(9932),f=r(9241),T=r(5933),y=r(6511),E=r(9148),C=r(6291),g=r(8596),I=r(7095),A=r(9251),b=r(9315),R=r(2691),S=r(1769),_=r(9683),v=r(1468),N=r(9053),w=r(9034),L=r(19),F=r(2419),O=r(9366),V=r(4869),B=r(8728),D=r(5846),M=r(6396),U=r(855),J=r(978),Y=r(455),x=r(7752),P=r(8244),k=r(4956),W=r(6854),K=r(3028),j=r(7004),G=r(1886),X=r(8583);class $ extends J.JsonAbstractSchemaArtifactReader{constructor(e){super(e)}static getStrict(){return new $(D.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new $(D.JsonReaderBehavior.FEBRUARY_2024)}static getForBehavior(e){return new $(e)}static dynamicTypeReaderMap=new Map([[V.CedarFieldType.TEXT,new f.JsonFieldReaderTextField],[V.CedarFieldType.TEXTAREA,new _.JsonFieldReaderTextArea],[V.CedarFieldType.CONTROLLED_TERM,new B.JsonFieldReaderControlledTerm],[V.CedarFieldType.LINK,new I.JsonFieldReaderLink],[V.CedarFieldType.EXT_ROR,new P.JsonFieldReaderExtRor],[V.CedarFieldType.EXT_ORCID,new k.JsonFieldReaderExtOrcid],[V.CedarFieldType.EXT_PFAS,new W.JsonFieldReaderExtPfas],[V.CedarFieldType.EXT_PUBMED,new K.JsonFieldReaderExtPubmed],[V.CedarFieldType.EXT_RRID,new j.JsonFieldReaderExtRrid],[V.CedarFieldType.EXT_NIH_GRANT_ID,new G.JsonFieldReaderExtNihGrantId],[V.CedarFieldType.EXT_DOI,new X.JsonFieldReaderExtDoi],[V.CedarFieldType.TEMPORAL,new b.JsonFieldReaderTemporal],[V.CedarFieldType.EMAIL,new R.JsonFieldReaderEmail],[V.CedarFieldType.NUMERIC,new S.JsonFieldReaderNumeric],[V.CedarFieldType.PHONE_NUMBER,new v.JsonFieldReaderPhoneNumber],[V.CedarFieldType.RADIO,new N.JsonFieldReaderRadio],[V.CedarFieldType.CHECKBOX,new L.JsonFieldReaderCheckbox],[V.CedarFieldType.SINGLE_SELECT_LIST,new F.JsonFieldReaderList],[V.CedarFieldType.MULTIPLE_SELECT_LIST,new F.JsonFieldReaderList],[V.CedarFieldType.ATTRIBUTE_VALUE,new O.JsonFieldReaderAttributeValue],[V.CedarFieldType.STATIC_PAGE_BREAK,new T.JsonFieldReaderPageBreak],[V.CedarFieldType.STATIC_SECTION_BREAK,new y.JsonFieldReaderSectionBreak],[V.CedarFieldType.STATIC_IMAGE,new E.JsonFieldReaderImage],[V.CedarFieldType.STATIC_RICH_TEXT,new C.JsonFieldReaderRichText],[V.CedarFieldType.STATIC_YOUTUBE,new g.JsonFieldReaderYoutube]]);readFromString(e){let t;try{t=JSON.parse(e)}catch{t={}}return this.readFromObject(t)}readFromObject(e){const t=Y.ChildDeploymentInfo.standalone(),r=new i.JsonPath;return this.readFromObjectInternal(e,t,r)}readFromObjectInternal(e,t,r){const n=new a.JsonArtifactParsingResult,i=$.readFieldSpecificAttributes(e,t,n,r);return this.readNonReportableAttributes(i,e),this.readReportableAttributes(i,e,n,r),this.readAnnotations(i,e),new M.JsonTemplateFieldReaderResult(i,n,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.skos_prefLabel=s.ReaderUtil.getString(t,m.CedarModel.skosPrefLabel),e.skos_altLabel=s.ReaderUtil.getFilteredStringList(t,m.CedarModel.skosAltLabel)}readReportableAttributes(e,t,r,a){const i=s.ReaderUtil.getNode(t,o.JsonSchema.atContext);let f=n.JsonNode.getEmpty();e.cedarArtifactType==d.CedarArtifactType.TEMPLATE_FIELD?f=h.JsonTemplateFieldContentDynamic.CONTEXT_VERBATIM:e.cedarArtifactType==d.CedarArtifactType.STATIC_TEMPLATE_FIELD&&(f=A.JsonTemplateFieldContentStatic.CONTEXT_VERBATIM),c.JsonObjectComparator.compareBothWays(r,f,i,a.add(o.JsonSchema.atContext),this.behavior,[o.JsonSchema.atLanguage]),e.cedarFieldType===V.CedarFieldType.ATTRIBUTE_VALUE?c.JsonObjectComparator.comparePrimitive(r,u.JavascriptType.STRING.getValue(),s.ReaderUtil.getString(t,m.CedarModel.type),a.add(m.CedarModel.type)):c.JsonObjectComparator.comparePrimitive(r,u.JavascriptType.OBJECT.getValue(),s.ReaderUtil.getString(t,m.CedarModel.type),a.add(m.CedarModel.type)),c.JsonObjectComparator.comparePrimitive(r,!1,s.ReaderUtil.getBoolean(t,l.TemplateProperty.additionalProperties),a.add(l.TemplateProperty.additionalProperties)),c.JsonObjectComparator.comparePrimitive(r,p.ArtifactSchema.CURRENT.getValue(),s.ReaderUtil.getString(t,m.CedarModel.schema),a.add(m.CedarModel.schema)),e.language=x.Language.forValue(s.ReaderUtil.getString(i,o.JsonSchema.atLanguage))}static readFieldSpecificAttributes(e,t,r,n){const a=d.CedarArtifactType.forValue(s.ReaderUtil.getString(e,o.JsonSchema.atType)),i=s.ReaderUtil.getNode(e,m.CedarModel.ui),l=s.ReaderUtil.getString(i,m.CedarModel.inputType),c=w.UiInputType.forValue(l),u=this.getCedarFieldType(e,c);if(u===V.CedarFieldType.NULL)throw new Error(`Unknown uiInputType type: "${l}"`);if((a==d.CedarArtifactType.TEMPLATE_FIELD||a==d.CedarArtifactType.STATIC_TEMPLATE_FIELD)&&null!=c){const a=this.dynamicTypeReaderMap.get(u);if(!a)throw new Error(`\n No reader defined for dynamic input type "${u.getValue()}"`);return a.read(e,t,r,n)}return U.UnknownTemplateField.build()}static fieldHasValueConstraint(e){const t=s.ReaderUtil.getNode(e,m.CedarModel.valueConstraints);return s.ReaderUtil.getNodeList(t,m.CedarModel.ontologies).length>0||(s.ReaderUtil.getNodeList(t,m.CedarModel.branches).length>0||(s.ReaderUtil.getNodeList(t,m.CedarModel.classes).length>0||s.ReaderUtil.getNodeList(t,m.CedarModel.valueSets).length>0))}static getCedarFieldType(e,t){let r=V.CedarFieldType.forUiInputType(t);return r!==V.CedarFieldType.TEXT&&r!==V.CedarFieldType.CONTROLLED_TERM||(r=this.fieldHasValueConstraint(e)?V.CedarFieldType.CONTROLLED_TERM:V.CedarFieldType.TEXT),r}}t.JsonTemplateFieldReader=$},8220(e,t,r){t.JsonTemplateFieldReaderInternal=void 0;const n=r(3188),a=r(4381),i=r(455);class s extends a.JsonTemplateFieldReader{constructor(e){super(e)}static getForBehavior(e){return new s(e)}readFromObjectInternal(e,t,r){return t=t||i.ChildDeploymentInfo.standalone(),r=r||new n.JsonPath,super.readFromObjectInternal(e,t,r)}}t.JsonTemplateFieldReaderInternal=s},6396(e,t,r){t.JsonTemplateFieldReaderResult=void 0;const n=r(8518);class a extends n.JsonArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get field(){return this._artifact}get fieldSourceObject(){return this._artifactSourceObject}}t.JsonTemplateFieldReaderResult=a},4385(e,t,r){t.JsonTemplateFieldTypeSpecificReader=void 0;const n=r(855),a=r(8748),i=r(936);t.JsonTemplateFieldTypeSpecificReader=class{read(e,t,r,a){return n.UnknownTemplateField.build()}readRequiredAndHidden(e,t){const r=a.ReaderUtil.getNode(e,i.CedarModel.valueConstraints);null!=r&&(t.requiredValue=a.ReaderUtil.getBoolean(r,i.CedarModel.requiredValue),t.recommendedValue=a.ReaderUtil.getBoolean(r,i.CedarModel.ValueConstraints.recommendedValue));const n=a.ReaderUtil.getNode(e,i.CedarModel.ui);n&&(t.hidden=a.ReaderUtil.getBoolean(n,i.CedarModel.Ui.hidden),t.continuePreviousLine=a.ReaderUtil.getBoolean(n,i.CedarModel.Ui.continuePreviousLine),t.valueRecommendationEnabled=a.ReaderUtil.getBoolean(n,i.CedarModel.Ui.valueRecommendationEnabled))}}},9232(e,t,r){t.JsonTemplateInstanceReader=void 0;const n=r(2763),a=r(4036),i=r(2888),s=r(9760),o=r(3188),l=r(5846),c=r(3326),d=r(2272),u=r(6537),m=r(8748),p=r(2733),h=r(7723),f=r(5222),T=r(7571),y=r(7548),E=r(8193),C=r(4877),g=r(4465),I=r(3644),A=r(9327),b=r(936),R=r(350),S=r(4033);class _ extends c.JsonAbstractInstanceArtifactReader{knownArtifactType=n.CedarArtifactType.TEMPLATE_INSTANCE;knownKeys={[p.JsonSchema.atId]:!0,[p.JsonSchema.oslcModifiedBy]:!0,[p.JsonSchema.pavLastUpdatedOn]:!0,[p.JsonSchema.pavCreatedBy]:!0,[p.JsonSchema.pavCreatedOn]:!0,[p.JsonSchema.schemaDescription]:!0,[p.JsonSchema.schemaName]:!0,[p.JsonSchema.schemaIsBasedOn]:!0,[p.JsonSchema.atContext]:!0,[b.CedarModel.annotations]:!0};constructor(e){super(e)}static getStrict(){return new _(l.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new _(l.JsonReaderBehavior.FEBRUARY_2024)}static getForBehavior(e){return new _(e)}readFromString(e){let t;try{t=JSON.parse(e)}catch{t={}}return this.readFromObject(t,new o.JsonPath)}readFromObject(e,t){const r=new a.JsonArtifactParsingResult,n=d.TemplateInstance.buildEmptyWithNullValues();this.readNonReportableAttributes(n,e);const i=t??new o.JsonPath;return this.readInstanceData(e,n,i,r),_.reportEnvelope(e,i,r),new u.JsonTemplateInstanceReaderResult(n,r,e)}static ENVELOPE_KEYS=[p.JsonSchema.atContext,p.JsonSchema.atId,p.JsonSchema.schemaIsBasedOn,p.JsonSchema.pavCreatedOn,p.JsonSchema.pavCreatedBy,p.JsonSchema.oslcModifiedBy,p.JsonSchema.pavLastUpdatedOn];static reportEnvelope(e,t,r){for(const n of _.ENVELOPE_KEYS){if(!Object.hasOwn(e,n)){r.addBlueprintComparisonWarning(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,t.add(n),n));continue}const a=m.ReaderUtil.getNode(e,n);(null==a||n===p.JsonSchema.atContext&&0===Object.keys(a).length)&&r.addBlueprintComparisonWarning(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,t.add(n),n,null))}}readInstanceData(e,t,r,n){t.dataContainer=this.readInstanceContainer(e,r,n),this.readAnnotations(t,e)}readInstanceContainer(e,t,r){return this.parseContainer(e,t,r)}isKnownKey(e){return Object.hasOwn(this.knownKeys,e)}parseContainer(e,t,r){const n=new h.InstanceDataContainer;Object.keys(e).forEach(a=>{if(!this.isKnownKey(a)){const i=m.ReaderUtil.getNode(e,a);if(Array.isArray(i)){const e=[];n.setValue(a,e),i.forEach((n,i)=>{e[i]=this.parseNode(n,t.add(a,i),r)})}else n.setValue(a,this.parseNode(i,t.add(a),r))}});for(const e of S.AttributeValueNamePolicy.findConflicts(n).filter(e=>0===e.path.length))r.addBlueprintComparisonError(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.VALUE_MISMATCH,t.add(...e.path,e.groupName,e.name),"a unique, non-reserved attribute-value name",e.name));this.packAttributeValues(n);const a=Object.hasOwn(e,p.JsonSchema.atContext)?m.ReaderUtil.getNode(e,p.JsonSchema.atContext):null;if(null!=a){const e=a;Object.keys(n.values).forEach(t=>{const r=m.ReaderUtil.getString(e,t);null!==r&&n.setIri(t,r)}),Object.keys(n.values).forEach(t=>{const r=n.values[t];r instanceof A.InstanceDataAttributeValueField&&Object.keys(r.values).forEach(t=>{const r=m.ReaderUtil.getString(e,t);null!==r&&n.setIri(t,r)})}),Object.keys(e).forEach(t=>{if(Object.hasOwn(R.JsonTemplateInstanceContent.CONTEXT_VERBATIM,t))return;const r=m.ReaderUtil.getString(e,t);null!==r&&n.setIri(t,r)})}if(Object.hasOwn(e,p.JsonSchema.atId)){const a=m.ReaderUtil.getString(e,p.JsonSchema.atId);null!==a&&(""===a.trim()&&(this.behavior.useWarningForKnownIssues()||_.refuseEmptyIdentifier(e),r.addBlueprintComparisonWarning(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.VALUE_MISMATCH,t.add(p.JsonSchema.atId),"an absolute IRI or null while the occurrence awaits server assignment",a))),n.id=a)}return n}static VALUE_ATOM_KEYS=new Set([p.JsonSchema.atValue,p.JsonSchema.atId,p.JsonSchema.rdfsLabel,p.JsonSchema.atType,b.CedarModel.skosNotation]);static isValueNode(e){if(null==e)return!1;if("string"==typeof e)return!0;if(Object.hasOwn(e,p.JsonSchema.atValue))return!0;if(Object.hasOwn(e,p.JsonSchema.atContext))return!1;const t=Object.keys(e);return t.length>0&&t.every(e=>_.VALUE_ATOM_KEYS.has(e))}static readValueNode(e){return null==e?new g.InstanceDataEmptyNode:"string"==typeof e?new I.InstanceDataAttributeValueFieldName(e):_.isValueNode(e)?_.parseDataAtom(e):new g.InstanceDataEmptyNode}parseNode(e,t,r){if(null==e)return new g.InstanceDataEmptyNode;if("string"==typeof e)return new I.InstanceDataAttributeValueFieldName(e);if(_.isValueNode(e)){const n=_.parseDataAtom(e);return _.reportNullIri(n,t,r),n}return 0===Object.keys(e).length?new g.InstanceDataEmptyNode:this.parseContainer(e,t,r)}static reportNullIri(e,t,r){(e instanceof T.InstanceDataLinkAtom||e instanceof E.InstanceDataControlledAtom)&&null===e.id&&r.addBlueprintComparisonError(new i.ComparisonError("JsonTemplateInstanceReader",s.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,t.add(p.JsonSchema.atId),"an IRI",null))}static parseDataAtom(e){if(Object.hasOwn(e,p.JsonSchema.atValue)){const t=m.ReaderUtil.getString(e,p.JsonSchema.atValue),r=m.ReaderUtil.getString(e,p.JsonSchema.atType);return null===r?new f.InstanceDataStringAtom(t):new C.InstanceDataTypedAtom(t,r)}if(Object.hasOwn(e,p.JsonSchema.atId)){_.refuseEmptyIdentifier(e);const t=m.ReaderUtil.getString(e,p.JsonSchema.atId),r=m.ReaderUtil.getString(e,p.JsonSchema.rdfsLabel);return null===r?T.InstanceDataLinkAtom.fromParsedNode(t):E.InstanceDataControlledAtom.fromParsedNode(t,r)}return new y.InstanceDataEmptyAtom(e)}packAttributeValues(e){const t=e.values,r=[];Object.keys(t).forEach(e=>{const n=t[e];if(Array.isArray(n)){let a=!1;if(n.forEach((e,t)=>{e instanceof I.InstanceDataAttributeValueFieldName||(a=!0)}),n.length>0&&!a){const a=new A.InstanceDataAttributeValueField(e);r.push(a),n.forEach((e,r)=>{const n=e.name;if(null!==n&&Object.hasOwn(t,n)){const e=t[n];a.addValue(n,e)}})}}}),r.forEach((e,r)=>{const n=e.name;null!==n&&(t[n]=e,Object.keys(e.values).forEach(e=>{Object.hasOwn(t,e)&&delete t[e]}))}),e.values=t}}t.JsonTemplateInstanceReader=_},6537(e,t,r){t.JsonTemplateInstanceReaderResult=void 0;const n=r(8518);class a extends n.JsonArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get instance(){return this._artifact}get instanceSourceObject(){return this._artifactSourceObject}}t.JsonTemplateInstanceReaderResult=a},5291(e,t,r){t.JsonTemplateReader=void 0;const n=r(936),a=r(2733),i=r(2763),s=r(5747),o=r(8748),l=r(6551),c=r(3056),d=r(4036),u=r(7954),m=r(3188),p=r(5846),h=r(9932),f=r(7909),T=r(5510),y=r(3281);class E extends T.JsonContainerArtifactReader{elementReader;knownArtifactType=i.CedarArtifactType.TEMPLATE;constructor(e){super(e),this.elementReader=f.JsonTemplateElementReader.getForBehavior(e)}static getStrict(){return new E(p.JsonReaderBehavior.STRICT)}static getFebruary2024(){return new E(p.JsonReaderBehavior.FEBRUARY_2024)}static getForBehavior(e){return new E(e)}getElementReader(){return this.elementReader}includeInIRIMapping(e){return e.atType!==i.CedarArtifactType.STATIC_TEMPLATE_FIELD}readFromString(e){let t;try{t=JSON.parse(e)}catch{t={}}return this.readFromObject(t)}readFromObject(e,t=new m.JsonPath){const r=new d.JsonArtifactParsingResult,n=y.Template.buildEmptyWithNullValues();return this.readNonReportableAttributes(n,e),this.readReportableAttributes(n,e,r,t),this.readAnnotations(n,e),this.readInstanceTypeSpecification(n,e,r),this.readAndValidateChildrenInfo(n,e,r,t),new u.JsonTemplateReaderResult(n,r,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t);const r=o.ReaderUtil.getNode(t,n.CedarModel.ui);null!==r&&(e.header=o.ReaderUtil.getString(r,n.CedarModel.header),e.footer=o.ReaderUtil.getString(r,n.CedarModel.footer))}readAndValidateChildrenInfo(e,t,r,i){const s=o.ReaderUtil.getStringList(t,a.JsonSchema.required),c=o.ReaderUtil.getNode(t,a.JsonSchema.properties),d=this.generateAndValidateRequiredMap(s,l.JsonTemplateContent.REQUIRED_PARTIAL,r,i),u=this.getCandidateChildrenInfo(c,l.JsonTemplateContent.PROPERTIES_PARTIAL_KEY_MAP,r,i);this.checkRequiredBothWays(u,d,s,l.JsonTemplateContent.REQUIRED_PARTIAL_KEY_MAP,r,i);const m=o.ReaderUtil.getNode(t,n.CedarModel.ui);this.extractUIPreferredLabelsAndDescriptions(m,u,r,i),this.extractIRIMappings(c,u,r,i);const p=o.ReaderUtil.getStringList(m,n.CedarModel.order),h=this.finalizeChildInfo(p,u,r,i);this.validatePropertiesVsOrder(u,p,r,i),this.validateProperties(h,c,e,r,i),this.parseChildren(h,c,e,r,i)}validateProperties(e,t,r,n,i){let d=l.JsonTemplateContent.PROPERTIES_PARTIAL;e.hasAttributeValue()&&(d=o.ReaderUtil.deepClone(l.JsonTemplateContent.PROPERTIES_PARTIAL),d[a.JsonSchema.atContext][s.TemplateProperty.additionalProperties]=h.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE),c.JsonObjectComparator.compareToLeft(n,d,t,i.add(a.JsonSchema.properties),this.behavior)}}t.JsonTemplateReader=E},7954(e,t,r){t.JsonTemplateReaderResult=void 0;const n=r(8518);class a extends n.JsonArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get template(){return this._artifact}get templateSourceObject(){return this._artifactSourceObject}}t.JsonTemplateReaderResult=a},8639(e,t,r){t.CedarYamlReaders=void 0;const n=r(2763),a=r(1395),i=r(5677),s=r(8239),o=r(2999),l=r(9946);class c{behavior;isCompact;constructor(e,t=!1){this.behavior=e,this.isCompact=t}static getStrict(){return new c(a.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new c(a.YamlReaderBehavior.STRICT,!0)}getTemplateReader(){return i.YamlTemplateReader.getForBehavior(this.behavior,this.isCompact)}getTemplateElementReader(){return s.YamlTemplateElementReader.getForBehavior(this.behavior,this.isCompact)}getTemplateFieldReader(){return o.YamlTemplateFieldReader.getForBehavior(this.behavior,this.isCompact)}getTemplateInstanceReader(){return l.YamlTemplateInstanceReader.getForBehavior(this.behavior)}getReaderForArtifactType(e){switch(e){case n.CedarArtifactType.TEMPLATE:return i.YamlTemplateReader.getForBehavior(this.behavior,this.isCompact);case n.CedarArtifactType.TEMPLATE_ELEMENT:return s.YamlTemplateElementReader.getForBehavior(this.behavior,this.isCompact);case n.CedarArtifactType.TEMPLATE_FIELD:case n.CedarArtifactType.STATIC_TEMPLATE_FIELD:return o.YamlTemplateFieldReader.getForBehavior(this.behavior,this.isCompact);case n.CedarArtifactType.TEMPLATE_INSTANCE:return l.YamlTemplateInstanceReader.getForBehavior(this.behavior);default:throw new Error(`No YAML reader available for CedarArtifactType: ${e}`)}}}t.CedarYamlReaders=c},6575(e,t,r){t.YamlAbstractArtifactReader=void 0;const n=r(8534),a=r(2234),i=r(9857),s=r(8557),o=r(1027),l=r(3910),c=r(2763),d=r(5226),u=r(2787),m=r(3549),p=r(8748),h=r(2099),f=r(7752);class T{behavior;knownArtifactType=c.CedarArtifactType.NULL;isCompact;constructor(e,t=!1){this.behavior=e,this.isCompact=t}artifactTypeWord(){return this.knownArtifactType===c.CedarArtifactType.TEMPLATE?"template":this.knownArtifactType===c.CedarArtifactType.TEMPLATE_ELEMENT?"element":"field"}readNonReportableAttributes(e,t){if(T.refuseEmptyIdentifier(t),e.at_id=n.CedarArtifactId.forValue(p.ReaderUtil.getString(t,h.YamlKeys.id)),e.schema_name=p.ReaderUtil.getString(t,h.YamlKeys.name),e.schema_description=p.ReaderUtil.getString(t,h.YamlKeys.description),null!==e.schema_name){const t=this.artifactTypeWord();e.title=`${e.schema_name} ${t} schema`,e.description=`${e.schema_name} ${t} schema generated by the CEDAR Artifact Library`}e.pav_createdBy=a.CedarUser.forValue(p.ReaderUtil.getString(t,h.YamlKeys.createdBy)),e.pav_createdOn=i.IsoDate.forValue(p.ReaderUtil.getString(t,h.YamlKeys.createdOn)),e.oslc_modifiedBy=a.CedarUser.forValue(p.ReaderUtil.getString(t,h.YamlKeys.modifiedBy)),e.pav_lastUpdatedOn=i.IsoDate.forValue(p.ReaderUtil.getString(t,h.YamlKeys.modifiedOn));const r=p.ReaderUtil.getString(t,h.YamlKeys.modelVersion);if(null===r&&!this.isCompact)throw new Error(`No ${h.YamlKeys.modelVersion} present. A document without one is the compact form, which a reader has to be asked for.`);e.schema_schemaVersion=s.SchemaVersion.forValue(r),e.pav_version=o.PavVersion.forValue(p.ReaderUtil.getString(t,h.YamlKeys.version)),e.bibo_status=l.BiboStatus.forYamlValue(p.ReaderUtil.getString(t,h.YamlKeys.status)),e.pav_derivedFrom=n.CedarArtifactId.forValue(p.ReaderUtil.getString(t,h.YamlKeys.derivedFrom)),e.pav_previousVersion=n.CedarArtifactId.forValue(p.ReaderUtil.getString(t,h.YamlKeys.previousVersion)),e.schema_identifier=p.ReaderUtil.getString(t,h.YamlKeys.identifier),e.language=f.Language.forValue(p.ReaderUtil.getString(t,h.YamlKeys.language))}static refuseEmptyIdentifier(e,t=h.YamlKeys.id){const r=p.ReaderUtil.getString(e,t);if(null!==r&&""===r.trim())throw new Error(`An empty string is not a URI at "${t}"; write null or leave the key out where there is no value.`)}readAnnotations(e,t,r,n){const a=new d.Annotations,i=p.ReaderUtil.getNode(t,h.YamlKeys.annotations);Object.keys(i).forEach(e=>{const t=p.ReaderUtil.getNode(i,e),r=p.ReaderUtil.getString(t,h.YamlKeys.id),n=p.ReaderUtil.getString(t,h.YamlKeys.value);null!==e&&(null!==r?a.add(new u.AnnotationAtId(e,r)):null!==n&&a.add(new m.AnnotationAtValue(e,n)))}),a.getSize()>0&&(e.annotations=a)}}t.YamlAbstractArtifactReader=T},6532(e,t){t.YamlArtifactReaderResult=void 0,t.YamlArtifactReaderResult=class{_artifact;_parsingResult;_artifactSourceObject;constructor(e,t,r){this._artifact=e,this._parsingResult=t,this._artifactSourceObject=r}get artifact(){return this._artifact}get parsingResult(){return this._parsingResult}get artifactSourceObject(){return this._artifactSourceObject}}},9300(e,t,r){t.YamlContainerArtifactReader=void 0;const n=r(6575),a=r(2999),i=r(455),s=r(2763),o=r(8748),l=r(2099),c=r(699),d=r(9499),u=r(4869),m=r(3608);class p extends n.YamlAbstractArtifactReader{fieldReader;constructor(e,t=!1){super(e,t),this.fieldReader=a.YamlTemplateFieldReader.getForBehavior(e,t)}readAndValidateChildrenInfo(e,t,r,n){o.ReaderUtil.getNodeList(t,l.YamlKeys.children).forEach(t=>{const r=o.ReaderUtil.getString(t,l.YamlKeys.type),a=o.ReaderUtil.getString(t,l.YamlKeys.key),p=d.YamlArtifactType.forValue(r);if(null===a)throw new Error(`A child without a ${l.YamlKeys.key} at ${n.add(l.YamlKeys.children).toString()}`);{const d=new i.ChildDeploymentInfo(a);d.atType=s.CedarArtifactType.forYamlArtifactType(p);const h=o.ReaderUtil.getNode(t,l.YamlKeys.configuration);if(d.label=o.ReaderUtil.getString(h,l.YamlKeys.overrideLabel),d.description=o.ReaderUtil.getString(h,l.YamlKeys.overrideDescription),d.multiInstance=o.ReaderUtil.getBoolean(h,l.YamlKeys.multiple),d.multiInstance&&(d.minItems=o.ReaderUtil.getNumber(h,l.YamlKeys.minItems),d.maxItems=o.ReaderUtil.getNumber(h,l.YamlKeys.maxItems)),d.requiredValue=o.ReaderUtil.getBoolean(h,l.YamlKeys.required),d.recommendedValue=o.ReaderUtil.getBoolean(h,l.YamlKeys.recommended),d.hidden=o.ReaderUtil.getBoolean(h,l.YamlKeys.hidden),d.continuePreviousLine=o.ReaderUtil.getBoolean(h,l.YamlKeys.continuePreviousLine),d.valueRecommendationEnabled=o.ReaderUtil.getBoolean(h,l.YamlKeys.valueRecommendation),d.iri=o.ReaderUtil.getString(h,l.YamlKeys.propertyIri),p.isField()){const r=u.CedarFieldType.forYamlArtifactType(p);d.uiInputType=r.getUiInputType();const i=this.fieldReader.readFromObject(t,d,n.add(l.YamlKeys.children,a));(0,c.isSizedStaticField)(i.field)&&(i.field.width=o.ReaderUtil.getNumber(h,l.YamlKeys.width),i.field.height=o.ReaderUtil.getNumber(h,l.YamlKeys.height));const f=i.field.createDeploymentBuilder(d.name).withLabel(d.label).withDescription(d.description);if(d.atType===s.CedarArtifactType.TEMPLATE_FIELD){const e=f;e.withIri(d.iri).withHidden(d.hidden).withContinuePreviousLine(d.continuePreviousLine).withRecommendedValue(d.recommendedValue).withRequiredValue(d.requiredValue).withValueRecommendationEnabled(d.valueRecommendationEnabled),e instanceof m.ChildDeploymentInfoBuilder&&e.withMultiInstance(d.multiInstance).withMinItems(d.minItems).withMaxItems(d.maxItems)}const T=f.build();e.addChild(i.field,T)}else{if(!p.isElement())throw new Error(`Unknown child type "${r}" at ${n.add(l.YamlKeys.children,a).toString()}`);{const r=this.getElementReader().readFromObject(t,d,n.add(l.YamlKeys.children,a));e.addChild(r.element,d)}}}})}}t.YamlContainerArtifactReader=p},8239(e,t,r){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.YamlTemplateElementReader=void 0;const a=r(2763),i=r(3188),s=r(1395),o=r(7661),l=r(455),c=n(r(3198)),d=r(9300),u=r(4646),m=r(1591),p=r(8748),h=r(2099);class f extends d.YamlContainerArtifactReader{knownArtifactType=a.CedarArtifactType.TEMPLATE_ELEMENT;constructor(e,t=!1){super(e,t)}static getStrict(){return new f(s.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new f(s.YamlReaderBehavior.STRICT,!0)}static getForBehavior(e,t=!1){return new f(e,t)}getElementReader(){return this}readFromString(e){let t;try{t=c.default.parse(e)}catch{t={}}return this.readFromObject(t,l.ChildDeploymentInfo.empty(),new i.JsonPath)}readFromObject(e,t,r){const n=new m.YamlArtifactParsingResult,a=o.TemplateElement.buildEmptyWithNullValues();return this.readNonReportableAttributes(a,e),this.readAnnotations(a,e,n,r),super.readAndValidateChildrenInfo(a,e,n,r),new u.YamlTemplateElementReaderResult(a,n,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.instanceTypeSpecification=p.ReaderUtil.getString(t,h.YamlKeys.instanceType),e.skos_prefLabel=p.ReaderUtil.getString(t,h.YamlKeys.prefLabel),e.skos_altLabel=p.ReaderUtil.getFilteredStringList(t,h.YamlKeys.altLabels)}}t.YamlTemplateElementReader=f},4646(e,t){t.YamlTemplateElementReaderResult=void 0,t.YamlTemplateElementReaderResult=class{_element;_parsingResult;_elementSourceObject;constructor(e,t,r){this._element=e,this._parsingResult=t,this._elementSourceObject=r}get element(){return this._element}get parsingResult(){return this._parsingResult}get elementSourceObject(){return this._elementSourceObject}}},2999(e,t,r){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.YamlTemplateFieldReader=void 0;const a=r(3188),i=r(8748),s=r(2763),o=r(3054),l=r(1790),c=r(455),d=r(6575),u=r(1395),m=n(r(3198)),p=r(2099),h=r(9499),f=r(1268),T=r(3168),y=r(384),E=r(1872),C=r(529),g=r(4568),I=r(8568),A=r(3980),b=r(7941),R=r(1404),S=r(7089),_=r(4329),v=r(7268),N=r(2709),w=r(7124),L=r(4284),F=r(9299),O=r(1591),V=r(6651),B=r(7123),D=r(5075),M=r(7709),U=r(6089),J=r(8543),Y=r(5907);class x extends d.YamlAbstractArtifactReader{knownArtifactType=s.CedarArtifactType.TEMPLATE_FIELD;constructor(e,t=!1){super(e,t)}static getStrict(){return new x(u.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new x(u.YamlReaderBehavior.STRICT,!0)}static getForBehavior(e,t=!1){return new x(e,t)}static readerMap=new Map([[h.YamlArtifactType.TEXTFIELD,new f.YamlFieldReaderTextField],[h.YamlArtifactType.TEXTAREA,new T.YamlFieldReaderTextArea],[h.YamlArtifactType.CONTROLLED_TERM,new F.YamlFieldReaderControlledTerm],[h.YamlArtifactType.LINK,new I.YamlFieldReaderLink],[h.YamlArtifactType.EXT_ROR,new V.YamlFieldReaderExtRor],[h.YamlArtifactType.EXT_ORCID,new B.YamlFieldReaderExtOrcid],[h.YamlArtifactType.EXT_PFAS,new D.YamlFieldReaderExtPfas],[h.YamlArtifactType.EXT_PUBMED,new M.YamlFieldReaderExtPubmed],[h.YamlArtifactType.EXT_RRID,new U.YamlFieldReaderExtRrid],[h.YamlArtifactType.EXT_NIH_GRANT_ID,new J.YamlFieldReaderExtNihGrantId],[h.YamlArtifactType.EXT_DOI,new Y.YamlFieldReaderExtDoi],[h.YamlArtifactType.TEMPORAL,new y.YamlFieldReaderTemporal],[h.YamlArtifactType.EMAIL,new o.YamlFieldReaderEmail],[h.YamlArtifactType.NUMERIC,new E.YamlFieldReaderNumeric],[h.YamlArtifactType.PHONE_NUMBER,new _.YamlFieldReaderPhoneNumber],[h.YamlArtifactType.RADIO,new L.YamlFieldReaderRadio],[h.YamlArtifactType.CHECKBOX,new v.YamlFieldReaderCheckbox],[h.YamlArtifactType.SINGLE_SELECT_LIST,new N.YamlFieldReaderSingleSelectList],[h.YamlArtifactType.MULTI_SELECT_LIST,new w.YamlFieldReaderMultiSelectList],[h.YamlArtifactType.ATTRIBUTE_VALUE,new C.YamlFieldReaderAttributeValue],[h.YamlArtifactType.PAGE_BREAK,new g.YamlFieldReaderPageBreak],[h.YamlArtifactType.SECTION_BREAK,new A.YamlFieldReaderSectionBreak],[h.YamlArtifactType.IMAGE,new b.YamlFieldReaderImage],[h.YamlArtifactType.RICH_TEXT,new R.YamlFieldReaderRichText],[h.YamlArtifactType.YOUTUBE,new S.YamlFieldReaderYoutube]]);readFromString(e){let t;try{t=m.default.parse(e)}catch{t={}}return this.readFromObject(t,c.ChildDeploymentInfo.empty(),new a.JsonPath)}readFromObject(e,t,r){const n=new O.YamlArtifactParsingResult,a=x.readFieldSpecificAttributes(e,t,n,r);return this.readNonReportableAttributes(a,e),this.readAnnotations(a,e,n,r),new l.YamlTemplateFieldReaderResult(a,n,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.skos_prefLabel=i.ReaderUtil.getString(t,p.YamlKeys.prefLabel),e.skos_altLabel=i.ReaderUtil.getFilteredStringList(t,p.YamlKeys.altLabels)}static readFieldSpecificAttributes(e,t,r,n){const a=h.YamlArtifactType.forValue(i.ReaderUtil.getString(e,p.YamlKeys.type));if(a.isField()){const i=this.readerMap.get(a);if(!i)throw new Error(`No reader defined for dynamic input type "${a.getValue()}"`);const o=i.read(e,t,r,n);let l=s.CedarArtifactType.NULL;return a.isStaticField()?l=s.CedarArtifactType.STATIC_TEMPLATE_FIELD:a.isDynamicField()&&(l=s.CedarArtifactType.TEMPLATE_FIELD),o.cedarArtifactType=l,o}throw new Error(`Unknown field type "${i.ReaderUtil.getString(e,p.YamlKeys.type)}" at ${n.toString()}`)}}t.YamlTemplateFieldReader=x},1790(e,t){t.YamlTemplateFieldReaderResult=void 0,t.YamlTemplateFieldReaderResult=class{_field;_parsingResult;_fieldSourceObject;constructor(e,t,r){this._field=e,this._parsingResult=t,this._fieldSourceObject=r}get field(){return this._field}get parsingResult(){return this._parsingResult}get fieldSourceObject(){return this._fieldSourceObject}}},5675(e,t,r){t.YamlTemplateFieldTypeSpecificReader=void 0;const n=r(855),a=r(8748),i=r(2099),s=r(4081);t.YamlTemplateFieldTypeSpecificReader=class{read(e,t,r,a){return n.UnknownTemplateField.build()}static readAndStoreListValueConstraints(e,t){t.valueConstraints.defaultValue=a.ReaderUtil.getString(e,i.YamlKeys.default);const r=a.ReaderUtil.getNodeList(e,i.YamlKeys.values);null!==r&&r.forEach(e=>{const r=a.ReaderUtil.getString(e,i.YamlKeys.label),n=a.ReaderUtil.getBoolean(e,i.YamlKeys.selected);if(null!=r){const e=new s.ListOption(r,n);t.valueConstraints.literals.push(e)}})}}},9946(e,t,r){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.YamlTemplateInstanceReader=void 0;const a=n(r(3198)),i=r(8534),s=r(1395),o=r(6575),l=r(2234),c=r(9857),d=r(1591),u=r(2099),m=r(8748),p=r(2272),h=r(147),f=r(7723),T=r(5222),y=r(4877),E=r(7571),C=r(8193),g=r(4465),I=r(9327),A=r(4033),b=r(2888),R=r(6109),S=r(3188);class _ extends o.YamlAbstractArtifactReader{constructor(e,t=!1){super(e,t)}static getStrict(){return new _(s.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new _(s.YamlReaderBehavior.STRICT,!0)}static getForBehavior(e,t=!1){return new _(e,t)}readFromString(e){let t;try{t=a.default.parse(e)}catch{t={}}return this.readFromObject(t)}readFromObject(e){const t=new d.YamlArtifactParsingResult,r=p.TemplateInstance.buildEmptyWithNullValues(),n=e??{};r.schema_name=m.ReaderUtil.getString(n,u.YamlKeys.name),r.schema_description=m.ReaderUtil.getString(n,u.YamlKeys.description),_.refuseEmptyIdentifier(n),r.at_id=i.CedarArtifactId.forValue(m.ReaderUtil.getString(n,u.YamlKeys.id)),r.schema_isBasedOn=i.CedarArtifactId.forValue(m.ReaderUtil.getString(n,u.YamlKeys.isBasedOn)),r.pav_derivedFrom=i.CedarArtifactId.forValue(m.ReaderUtil.getString(n,u.YamlKeys.derivedFrom)),r.pav_createdBy=l.CedarUser.forValue(m.ReaderUtil.getString(n,u.YamlKeys.createdBy)),r.pav_createdOn=c.IsoDate.forValue(m.ReaderUtil.getString(n,u.YamlKeys.createdOn)),r.oslc_modifiedBy=l.CedarUser.forValue(m.ReaderUtil.getString(n,u.YamlKeys.modifiedBy)),r.pav_lastUpdatedOn=c.IsoDate.forValue(m.ReaderUtil.getString(n,u.YamlKeys.modifiedOn)),this.readAnnotations(r,n,t,new S.JsonPath),r.dataContainer=this.parseContainer(n);for(const e of A.AttributeValueNamePolicy.findConflicts(r.dataContainer))t.addBlueprintComparisonError(new b.ComparisonError("YamlTemplateInstanceReader",R.YamlComparisonErrorType.VALUE_MISMATCH,new S.JsonPath(...e.path,e.groupName,e.name),"a unique, non-reserved attribute-value name",e.name));return new h.YamlTemplateInstanceReaderResult(r,t,n)}static RESERVED_KEYS=new Set([u.YamlKeys.type,u.YamlKeys.name,u.YamlKeys.description,u.YamlKeys.id,u.YamlKeys.isBasedOn,u.YamlKeys.derivedFrom,u.YamlKeys.children,u.YamlKeys.annotations,u.YamlKeys.createdOn,u.YamlKeys.createdBy,u.YamlKeys.modifiedOn,u.YamlKeys.modifiedBy]);parseContainer(e){const t=new f.InstanceDataContainer,r=m.ReaderUtil.getNode(e,u.YamlKeys.children);null!==r&&Object.keys(r).forEach(e=>{const n=m.ReaderUtil.getNode(r,e)??r[e];if(Array.isArray(n)){const r=[];t.setValue(e,r),n.forEach((e,t)=>{r[t]=this.parseNode(e)})}else t.setValue(e,this.parseNode(n))}),Object.keys(e).forEach(r=>{if(_.RESERVED_KEYS.has(r))return;const n=e[r];if(null===n||"object"!=typeof n||Array.isArray(n))return;const a=new I.InstanceDataAttributeValueField(r);Object.keys(n).forEach(e=>{const t=n[e];a.addValue(e,new T.InstanceDataStringAtom(this.parseAttributeValue(t)))}),t.setValue(r,a)}),_.refuseEmptyIdentifier(e);const n=m.ReaderUtil.getString(e,u.YamlKeys.id);return null!==n&&(t.id=n),t}parseAttributeValue(e){if("string"==typeof e)return e;if(null!==e&&"object"==typeof e&&!Array.isArray(e)){const t=e[u.YamlKeys.value];return"string"==typeof t?t:null}return null}parseNode(e){if(null==e)return new g.InstanceDataEmptyNode;if("string"==typeof e)return new T.InstanceDataStringAtom(e);if(Object.hasOwn(e,u.YamlKeys.children)||"element-instance"===m.ReaderUtil.getString(e,u.YamlKeys.type))return this.parseContainer(e);if(Object.hasOwn(e,u.YamlKeys.value)){const t=m.ReaderUtil.getString(e,u.YamlKeys.value),r=m.ReaderUtil.getString(e,u.YamlKeys.datatype);return null===r?new T.InstanceDataStringAtom(t):new y.InstanceDataTypedAtom(t,r)}if(Object.hasOwn(e,u.YamlKeys.id)){_.refuseEmptyIdentifier(e);const t=m.ReaderUtil.getString(e,u.YamlKeys.id),r=m.ReaderUtil.getString(e,u.YamlKeys.label);return null===r?E.InstanceDataLinkAtom.fromParsedNode(t):C.InstanceDataControlledAtom.fromParsedNode(t,r)}return new g.InstanceDataEmptyNode}}t.YamlTemplateInstanceReader=_},147(e,t,r){t.YamlTemplateInstanceReaderResult=void 0;const n=r(6532);class a extends n.YamlArtifactReaderResult{constructor(e,t,r){super(e,t,r)}get instance(){return this._artifact}get instanceSourceObject(){return this._artifactSourceObject}}t.YamlTemplateInstanceReaderResult=a},5677(e,t,r){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.YamlTemplateReader=void 0;const a=r(2763),i=r(8748),s=r(7868),o=r(3188),l=r(1395),c=r(8239),d=r(3281),u=n(r(3198)),m=r(9300),p=r(2099),h=r(1591);class f extends m.YamlContainerArtifactReader{elementReader;knownArtifactType=a.CedarArtifactType.TEMPLATE;constructor(e,t=!1){super(e,t),this.elementReader=c.YamlTemplateElementReader.getForBehavior(e,t)}static getStrict(){return new f(l.YamlReaderBehavior.STRICT)}static getStrictForCompact(){return new f(l.YamlReaderBehavior.STRICT,!0)}static getForBehavior(e,t=!1){return new f(e,t)}getElementReader(){return this.elementReader}readFromString(e){let t;try{t=u.default.parse(e)}catch{t={}}return this.readFromObject(t)}readFromObject(e,t=new o.JsonPath){const r=new h.YamlArtifactParsingResult,n=d.Template.buildEmptyWithNullValues();return this.readNonReportableAttributes(n,e),this.readAnnotations(n,e,r,t),this.readInstanceTypeSpecification(n,e,r),this.readAndValidateChildrenInfo(n,e,r,t),new s.YamlTemplateReaderResult(n,r,e)}readNonReportableAttributes(e,t){super.readNonReportableAttributes(e,t),e.header=i.ReaderUtil.getString(t,p.YamlKeys.header),e.footer=i.ReaderUtil.getString(t,p.YamlKeys.footer)}readInstanceTypeSpecification(e,t,r){e.instanceTypeSpecification=i.ReaderUtil.getString(t,p.YamlKeys.instanceType)}}t.YamlTemplateReader=f},7868(e,t){t.YamlTemplateReaderResult=void 0,t.YamlTemplateReaderResult=class{_template;_parsingResult;_templateSourceObject;constructor(e,t,r){this._template=e,this._parsingResult=t,this._templateSourceObject=r}get template(){return this._template}get parsingResult(){return this._parsingResult}get templateSourceObject(){return this._templateSourceObject}}},1888(e,t,r){t.RoundTrip=void 0;const n=r(6396),a=r(2748),i=r(4036),s=r(3056),o=r(455),l=r(3188),c=r(7954),d=r(7519),u=r(4948),m=r(6645),p=r(2022);t.RoundTrip=class{static compare(e,t){if(e instanceof n.JsonTemplateFieldReaderResult&&t instanceof a.JsonTemplateFieldWriterInternal)return this.compareField(e,t);if(e instanceof u.JsonTemplateElementReaderResult&&t instanceof m.JsonTemplateElementWriter)return this.compareElement(e,t);if(e instanceof c.JsonTemplateReaderResult&&t instanceof d.JsonTemplateWriter)return this.compareTemplate(e,t);if("string"==typeof e&&"string"==typeof t)return this.compareString(e,t);throw new Error("Invalid argument types for compare method")}static compareField(e,t){const r=new i.JsonArtifactParsingResult;return s.JsonObjectComparator.compareBothWays(r,e.fieldSourceObject,t.getAsJsonNode(e.field,o.ChildDeploymentInfo.empty()),new l.JsonPath,t.getBehavior()),r}static compareElement(e,t){const r=new i.JsonArtifactParsingResult;return s.JsonObjectComparator.compareBothWays(r,e.elementSourceObject,t.getAsJsonNode(e.element),new l.JsonPath,t.getBehavior()),r}static compareTemplate(e,t){const r=new i.JsonArtifactParsingResult;return s.JsonObjectComparator.compareBothWays(r,e.templateSourceObject,t.getAsJsonNode(e.template),new l.JsonPath,t.getBehavior()),r}static compareString(e,t){const r=JSON.parse(e),n=JSON.parse(t),a=new i.JsonArtifactParsingResult;return s.JsonObjectComparator.compareBothWays(a,r,n,new l.JsonPath,p.JsonWriterBehavior.STRICT),a}}},2112(e,t){t.AbstractArtifactWriter=void 0,t.AbstractArtifactWriter=class{constructor(){}}},8810(e,t,r){t.CedarWriters=void 0;const n=r(9607),a=r(5359);t.CedarWriters=class{static json(){return n.CedarJsonWriters}static yaml(){return a.CedarYamlWriters}}},5692(e,t,r){t.WriterUtil=void 0;const n=r(8878),a=r(455);t.WriterUtil=class{static getMultiMinMax(e,t){let r=null,i=null,s=!1;if(e.isMultiInstanceByDefinition())t instanceof n.ChildDeploymentInfoAlwaysMultiple&&(s=!0,r=t.minItems,i=t.maxItems);else if(e.isSingleInstanceByDefinition())s=!1;else if(t instanceof a.ChildDeploymentInfo){const e=t;s=e.multiInstance,s&&(r=e.minItems,i=e.maxItems)}return{isMultiInstance:s,minItems:r,maxItems:i}}}},9607(e,t,r){t.CedarJsonWriters=void 0;const n=r(2022),a=r(4872),i=r(7519),s=r(4869),o=r(7501),l=r(3691),c=r(4841),d=r(5459),u=r(8970),m=r(2347),p=r(41),h=r(6029),f=r(6766),T=r(9309),y=r(8663),E=r(7335),C=r(275),g=r(6876),I=r(9031),A=r(9129),b=r(1442),R=r(8280),S=r(8354),_=r(5996),v=r(2418),N=r(9222),w=r(9184),L=r(7054),F=r(2395),O=r(2813),V=r(6645),B=r(2981),D=r(7432),M=r(8014),U=r(3281),J=r(7661),Y=r(6320),x=r(7584),P=r(8096),k=r(6122),W=r(3312),K=r(4780),j=r(5250),G=r(7412);class X{behavior;jsonDynamicFieldWriters;jsonStaticFieldWriters;jsonValueConstraintsWriters;jsonAtomicWriter;jsonAnnotationsWriter;jsonTemplateWriter;jsonTemplateElementWriter;jsonTemplateInstanceWriter;constructor(e){this.behavior=e,this.jsonAtomicWriter=new a.JsonAtomicWriter(e),this.jsonAnnotationsWriter=new B.JsonAnnotationsWriter(e),this.jsonTemplateWriter=i.JsonTemplateWriter.getFor(e,this),this.jsonTemplateElementWriter=V.JsonTemplateElementWriter.getFor(e,this),this.jsonTemplateInstanceWriter=Y.JsonTemplateInstanceWriter.getFor(e,this),this.jsonDynamicFieldWriters=new Map([[s.CedarFieldType.TEXT,new o.JsonFieldWriterTextField(e,this)],[s.CedarFieldType.TEXTAREA,new C.JsonFieldWriterTextArea(e,this)],[s.CedarFieldType.CONTROLLED_TERM,new R.JsonFieldWriterControlledTerm(e,this)],[s.CedarFieldType.PHONE_NUMBER,new g.JsonFieldWriterPhoneNumber(e,this)],[s.CedarFieldType.EMAIL,new I.JsonFieldWriterEmail(e,this)],[s.CedarFieldType.LINK,new l.JsonFieldWriterLink(e,this)],[s.CedarFieldType.EXT_ROR,new x.JsonFieldWriterExtRor(e,this)],[s.CedarFieldType.EXT_ORCID,new P.JsonFieldWriterExtOrcid(e,this)],[s.CedarFieldType.EXT_PFAS,new k.JsonFieldWriterExtPfas(e,this)],[s.CedarFieldType.EXT_PUBMED,new W.JsonFieldWriterExtPubmed(e,this)],[s.CedarFieldType.EXT_RRID,new K.JsonFieldWriterExtRrid(e,this)],[s.CedarFieldType.EXT_NIH_GRANT_ID,new j.JsonFieldWriterExtNihGrantId(e,this)],[s.CedarFieldType.EXT_DOI,new G.JsonFieldWriterExtDoi(e,this)],[s.CedarFieldType.NUMERIC,new c.JsonFieldWriterNumeric(e,this)],[s.CedarFieldType.TEMPORAL,new d.JsonFieldWriterTemporal(e,this)],[s.CedarFieldType.RADIO,new T.JsonFieldWriterRadio(e,this)],[s.CedarFieldType.CHECKBOX,new y.JsonFieldWriterCheckbox(e,this)],[s.CedarFieldType.SINGLE_SELECT_LIST,new E.JsonFieldWriterList(e,this)],[s.CedarFieldType.MULTIPLE_SELECT_LIST,new E.JsonFieldWriterList(e,this)],[s.CedarFieldType.ATTRIBUTE_VALUE,new b.JsonFieldWriterAttributeValue(e,this)]]),this.jsonStaticFieldWriters=new Map([[s.CedarFieldType.STATIC_PAGE_BREAK,new m.JsonFieldWriterStaticPageBreak(e,this)],[s.CedarFieldType.STATIC_SECTION_BREAK,new p.JsonFieldWriterStaticSectionsBreak(e,this)],[s.CedarFieldType.STATIC_IMAGE,new u.JsonFieldWriterStaticImage(e,this)],[s.CedarFieldType.STATIC_RICH_TEXT,new h.JsonFieldWriterStaticRichText(e,this)],[s.CedarFieldType.STATIC_YOUTUBE,new f.JsonFieldWriterStaticYoutube(e,this)]]),this.jsonValueConstraintsWriters=new Map([[S.ControlledTermOntology.className,new _.JsonValueConstraintsOntologyWriter(e,this)],[v.ControlledTermClass.className,new N.JsonValueConstraintsClassWriter(e,this)],[w.ControlledTermBranch.className,new L.JsonValueConstraintsBranchWriter(e,this)],[F.ControlledTermValueSet.className,new O.JsonValueConstraintsValueSetWriter(e,this)],[D.ControlledTermAction.className,new M.JsonValueConstraintsActionWriter(e,this)]])}static getStrict(){return new X(n.JsonWriterBehavior.STRICT)}static getFebruary2024(){return new X(n.JsonWriterBehavior.FEBRUARY_2024)}static getFor(e){return new X(e)}getTemplateWriter(){return this.jsonTemplateWriter}getTemplateElementWriter(){return this.jsonTemplateElementWriter}getTemplateInstanceWriter(){return this.jsonTemplateInstanceWriter}getAtomicWriter(){return this.jsonAtomicWriter}getFieldWriterForType(e){let t;if(t=e.isStaticField?this.jsonStaticFieldWriters.get(e):this.jsonDynamicFieldWriters.get(e),t)return t;throw new Error(`No JSON writer found for field type: ${e.getValue()}`)}getWriterForValueConstraint(e){const t=e.className,r=this.jsonValueConstraintsWriters.get(t);if(r)return r;throw new Error(`No JSON writer found for class type: ${t}`)}getFieldWriterForField(e){return this.getFieldWriterForType(e.cedarFieldType)}getAnnotationsWriter(){return this.jsonAnnotationsWriter}getWriterForArtifact(e){if(e instanceof U.Template)return i.JsonTemplateWriter.getFor(this.behavior,this);if(e instanceof J.TemplateElement)return V.JsonTemplateElementWriter.getFor(this.behavior,this);if(e instanceof A.TemplateField)return this.getFieldWriterForType(e.cedarFieldType);throw new Error(`No JSON reader available for CedarArtifact: ${e}`)}}t.CedarJsonWriters=X},3161(e,t,r){t.JsonAbstractArtifactWriter=void 0;const n=r(2112),a=r(9517),i=r(2733),s=r(3910),o=r(1027),l=r(936),c=r(8534);class d extends n.AbstractArtifactWriter{behavior;writers;atomicWriter;annotationsWriter;constructor(e,t){super(),this.behavior=e,this.writers=t,this.atomicWriter=t.getAtomicWriter(),this.annotationsWriter=t.getAnnotationsWriter()}getBehavior(){return this.behavior}macroSchemaNameAndDescription(e){return{[i.JsonSchema.schemaName]:e.schema_name,[i.JsonSchema.schemaDescription]:e.schema_description}}macroProvenance(e,t){return{[i.JsonSchema.pavCreatedOn]:t.write(e.pav_createdOn),[i.JsonSchema.pavCreatedBy]:t.write(e.pav_createdBy),[i.JsonSchema.pavLastUpdatedOn]:t.write(e.pav_lastUpdatedOn),[i.JsonSchema.oslcModifiedBy]:t.write(e.oslc_modifiedBy)}}macroStatusAndVersion(e,t){const r=a.JsonNode.getEmpty();return e.pav_version!==o.PavVersion.NULL&&(r[i.JsonSchema.pavVersion]=t.write(e.pav_version)),e.bibo_status!==s.BiboStatus.NULL&&(r[i.JsonSchema.biboStatus]=t.write(e.bibo_status)),r}macroSkos(e){const t=a.JsonNode.getEmpty();return null!==e.skos_prefLabel&&(t[l.CedarModel.skosPrefLabel]=e.skos_prefLabel),null!==e.skos_altLabel&&e.skos_altLabel.length>0&&(t[l.CedarModel.skosAltLabel]=e.skos_altLabel),t}macroDerivedFrom(e){const t=a.JsonNode.getEmpty();return e.pav_derivedFrom!==c.CedarArtifactId.NULL&&(t[i.JsonSchema.pavDerivedFrom]=this.atomicWriter.write(e.pav_derivedFrom)),t}macroIsBasedOn(e){const t=a.JsonNode.getEmpty();return e.schema_isBasedOn!==c.CedarArtifactId.NULL&&(t[i.JsonSchema.schemaIsBasedOn]=this.atomicWriter.write(e.schema_isBasedOn)),t}macroPreviousVersion(e){const t=a.JsonNode.getEmpty();return e.pav_previousVersion!==c.CedarArtifactId.NULL&&(t[i.JsonSchema.pavPreviousVersion]=this.atomicWriter.write(e.pav_previousVersion)),t}macroSchemaIdentifier(e){const t=a.JsonNode.getEmpty();return null!==e.schema_identifier&&(t[i.JsonSchema.schemaIdentifier]=e.schema_identifier),t}macroAnnotations(e){return this.annotationsWriter.write(e.annotations)}}t.JsonAbstractArtifactWriter=d},8872(e,t,r){t.JsonAbstractContainerArtifactWriter=void 0;const n=r(3161),a=r(6968),i=r(9517),s=r(9129),o=r(2733),l=r(936),c=r(5692),d=r(8748);class u extends n.JsonAbstractArtifactWriter{macroContext(e){return a.JsonContainerArtifactContent.CONTEXT_VERBATIM}getChildMapAsJson(e){const t=i.JsonNode.getEmpty();return e.getChildrenInfo().getChildrenNames().forEach(r=>{const n=e.getChild(r);if(null!=n){let a=i.JsonNode.getEmpty();const d=e.getChildrenInfo().get(r);if(null!==d&&(a=n instanceof s.TemplateField?this.writers.getFieldWriterForType(n.cedarFieldType).getAsJsonNode(n,d):this.writers.getTemplateElementWriter().getAsJsonNode(n)),null!==d){const{isMultiInstance:e,minItems:s,maxItems:u}=c.WriterUtil.getMultiMinMax(n,d);let m=s,p=u;if(e){null===m&&(m=0),null!==p&&p<m&&(p=m);const e=i.JsonNode.getEmpty();e[l.CedarModel.minItems]=m,null!==p&&(e[l.CedarModel.maxItems]=p),a={[o.JsonSchema.type]:"array",...e,[o.JsonSchema.items]:a}}t[r]=a}}}),t}expandInstanceTypeSpecification(e,t){if(null!==e.instanceTypeSpecification){const r=d.ReaderUtil.getNode(t,o.JsonSchema.atType);d.ReaderUtil.getNodeList(r,o.JsonSchema.oneOf).forEach(t=>{const r=d.ReaderUtil.getString(t,o.JsonSchema.type);"string"==r?t[o.JsonSchema.enum]=[e.instanceTypeSpecification]:"array"==r&&(d.ReaderUtil.getNode(t,o.JsonSchema.items)[o.JsonSchema.enum]=[e.instanceTypeSpecification])})}}}t.JsonAbstractContainerArtifactWriter=u},2981(e,t,r){t.JsonAnnotationsWriter=void 0;const n=r(9517),a=r(936),i=r(2787),s=r(2733),o=r(3549);t.JsonAnnotationsWriter=class{behavior;constructor(e){this.behavior=e}write(e){const t=n.JsonNode.getEmpty();if(null!==e&&e.getSize()>0){const r=n.JsonNode.getEmpty();e.getAnnotationNames().forEach(t=>{const n=e.get(t);n instanceof i.AnnotationAtId?r[t]={[s.JsonSchema.atId]:n.getAtId()}:n instanceof o.AnnotationAtValue&&(r[t]={[s.JsonSchema.atValue]:n.getAtValue()})}),t[a.CedarModel.annotations]=r}return t}}},4872(e,t,r){t.JsonAtomicWriter=void 0;const n=r(8534),a=r(2763),i=r(5793),s=r(9857),o=r(2234),l=r(3910),c=r(1027),d=r(2475),u=r(8557),m=r(3447),p=r(8588),h=r(7974),f=r(3764),T=r(9034),y=r(3746),E=r(9932),C=r(8802),g=r(4531),I=r(7752);t.JsonAtomicWriter=class{behavior;constructor(e){this.behavior=e}write(e){if(null==e)return null;if(e instanceof n.CedarArtifactId)return this.writeCedarArtifactId(e);if(e instanceof a.CedarArtifactType)return this.writeCedarArtifactType(e);if(e instanceof i.JavascriptType)return this.writeJavascriptType(e);if(e instanceof s.IsoDate)return this.writeCedarDate(e);if(e instanceof o.CedarUser)return this.writeCedarUser(e);if(e instanceof l.BiboStatus)return this.writeBiboStatusJson(e);if(e instanceof c.PavVersion)return this.writePavVersion(e);if(e instanceof d.ArtifactSchema)return this.writeCedarSchema(e);if(e instanceof u.SchemaVersion)return this.writeSchemaVersion(e);if(e instanceof m.NumberType)return this.writeNumberType(e);if(e instanceof p.TemporalType)return this.writeTemporalType(e);if(e instanceof h.TemporalGranularity)return this.writeTemporalGranularity(e);if(e instanceof f.TimeFormat)return this.writeTimeFormat(e);if(e instanceof T.UiInputType)return this.writeUiInputType(e);if(e instanceof y.AdditionalProperties)return this.writeAdditionalProperties(e);if(e instanceof C.Iri)return this.writeURI(e);if(e instanceof g.BioportalTermType)return this.writeBioportalTermTypeJson(e);if(e instanceof I.Language)return this.writeLanguage(e);throw new Error("Unsupported type")}writeCedarArtifactId(e){return e.getValue()}writeCedarArtifactType(e){return e.getValue()}writeJavascriptType(e){return e.getValue()}writeCedarDate(e){return e.getValue()}writeCedarUser(e){return e.getValue()}writeBiboStatusJson(e){return e.getJsonValue()}writePavVersion(e){return e.getValue()}writeCedarSchema(e){return e.getValue()}writeSchemaVersion(e){return null!==e.getValue()?e.getValue():u.SchemaVersion.CURRENT.getValue()}writeNumberType(e){return e.getValue()}writeTemporalType(e){return e.getValue()}writeTemporalGranularity(e){return e.getValue()}writeTimeFormat(e){return e.getValue()}writeUiInputType(e){return e.getValue()}writeAdditionalProperties(e){return e!==y.AdditionalProperties.FALSE&&(e===y.AdditionalProperties.ALLOW_ATTRIBUTE_VALUE?E.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_OUTSIDE:null)}writeURI(e){return e.getValue()}writeBioportalTermTypeJson(e){return e.getJsonValue()}writeLanguage(e){return e.getValue()}}},6645(e,t,r){t.JsonTemplateElementWriter=void 0;const n=r(8748),a=r(2733),i=r(936),s=r(2763),o=r(5793),l=r(5747),c=r(2475),d=r(9932),u=r(1501),m=r(8872),p=r(7752);class h extends m.JsonAbstractContainerArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new h(e,t)}buildProperties(e){const t=n.ReaderUtil.deepClone(u.JsonTemplateElementContent.PROPERTIES_PARTIAL);e.language!==p.Language.NULL&&(t[a.JsonSchema.atContext][a.JsonSchema.atLanguage]=this.atomicWriter.write(e.language));const r=e.getChildrenInfo().getIRIMap();t[a.JsonSchema.atContext][a.JsonSchema.properties]={...t[a.JsonSchema.atContext][a.JsonSchema.properties],...r};const i=Object.keys(r);i.length>0?t[a.JsonSchema.atContext][a.JsonSchema.required]=[...t[a.JsonSchema.atContext][a.JsonSchema.required],...i]:n.ReaderUtil.deleteNodeKey(t[a.JsonSchema.atContext],a.JsonSchema.required),e.getChildrenInfo().hasAttributeValue()&&(t[a.JsonSchema.atContext][l.TemplateProperty.additionalProperties]=d.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE);const s={...t,...this.getChildMapAsJson(e)};return this.expandInstanceTypeSpecification(e,s),s}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=this.buildProperties(e),r={[i.CedarModel.order]:e.getChildrenInfo().getChildrenNames(),[i.CedarModel.propertyLabels]:e.getChildrenInfo().getPropertyLabelMap(e),[i.CedarModel.propertyDescriptions]:e.getChildrenInfo().getPropertyDescriptionMap(e)};return{[a.JsonSchema.atId]:this.atomicWriter.write(e.at_id),[a.JsonSchema.atType]:this.atomicWriter.write(s.CedarArtifactType.TEMPLATE_ELEMENT),[a.JsonSchema.atContext]:this.macroContext(e),[i.CedarModel.type]:this.atomicWriter.write(o.JavascriptType.OBJECT),[l.TemplateProperty.title]:e.title,[l.TemplateProperty.description]:e.description,[i.CedarModel.ui]:r,[a.JsonSchema.properties]:t,[a.JsonSchema.required]:[...u.JsonTemplateElementContent.REQUIRED_PARTIAL,...e.getChildrenInfo().getChildrenNamesForRequired()],...this.macroAnnotations(e),...this.macroSchemaNameAndDescription(e),...this.macroProvenance(e,this.atomicWriter),...this.macroSkos(e),...this.macroStatusAndVersion(e,this.atomicWriter),...this.macroDerivedFrom(e),...this.macroPreviousVersion(e),[a.JsonSchema.schemaVersion]:this.atomicWriter.write(e.schema_schemaVersion),[l.TemplateProperty.additionalProperties]:this.atomicWriter.write(e.getAdditionalProperties()),...this.macroSchemaIdentifier(e),[i.CedarModel.schema]:this.atomicWriter.write(c.ArtifactSchema.CURRENT)}}}t.JsonTemplateElementWriter=h},2748(e,t,r){t.JsonTemplateFieldWriterInternal=void 0;const n=r(9517),a=r(936),i=r(2733),s=r(9932),o=r(5793),l=r(5747),c=r(2475),d=r(3161),u=r(3746),m=r(455),p=r(3812),h=r(7752),f=r(8748);class T extends d.JsonAbstractArtifactWriter{constructor(e,t){super(e,t)}expandPropertiesNode(e){e[i.JsonSchema.properties]=s.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_LITERAL,this.behavior.usePropertiesAtLanguage()||(e[i.JsonSchema.properties]=s.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE)}expandRequiredNode(e){e[i.JsonSchema.required]=[i.JsonSchema.atValue]}expandUINode(e,t,r){r instanceof p.AbstractDynamicChildDeploymentInfo&&(r.hidden&&(e[a.CedarModel.Ui.hidden]=r.hidden),r.continuePreviousLine&&(e[a.CedarModel.Ui.continuePreviousLine]=r.continuePreviousLine),r.valueRecommendationEnabled&&t.supportsValueRecommendation()&&(e[a.CedarModel.Ui.valueRecommendationEnabled]=r.valueRecommendationEnabled))}buildUIObject(e,t){const r={[a.CedarModel.inputType]:this.atomicWriter.write(e.cedarFieldType.getUiInputType())},n={[a.CedarModel.ui]:r};return this.expandUINode(r,e,t),n}expandTypeNode(e,t){}expandValueConstraintsNode(e,t,r){r instanceof p.AbstractDynamicChildDeploymentInfo&&(e[a.CedarModel.requiredValue]=r.requiredValue),r instanceof p.AbstractDynamicChildDeploymentInfo&&r.recommendedValue&&(e[a.CedarModel.ValueConstraints.recommendedValue]=r.recommendedValue)}buildValueConstraintsObject(e,t){const r=n.JsonNode.getEmpty(),i={[a.CedarModel.valueConstraints]:r};return this.expandValueConstraintsNode(r,e,t),i}expandLiterals(e,t){const r=n.JsonNode.getEmptyList();e.valueConstraints.literals.forEach(e=>{const t=n.JsonNode.getEmpty();t[a.CedarModel.label]=e.label,e.selectedByDefault&&(t[a.CedarModel.selectedByDefault]=e.selectedByDefault),r.push(t)}),r.length>0&&(t[a.CedarModel.literals]=r)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e,m.ChildDeploymentInfo.empty()),null,t)}getAsJsonNode(e,t=m.ChildDeploymentInfo.empty()){const r=n.JsonNode.getEmpty();this.expandPropertiesNode(r);const s=n.JsonNode.getEmpty();this.expandRequiredNode(s);const d=this.buildUIObject(e,t),p=this.buildValueConstraintsObject(e,t),h={[a.CedarModel.type]:this.atomicWriter.write(o.JavascriptType.OBJECT)};return this.expandTypeNode(h,e),{[i.JsonSchema.atId]:this.atomicWriter.write(e.at_id),[i.JsonSchema.atType]:this.atomicWriter.write(e.cedarArtifactType),[i.JsonSchema.atContext]:this.macroContext(e),...h,[l.TemplateProperty.title]:e.title,[l.TemplateProperty.description]:e.description,...d,...p,...r,...s,...this.macroAnnotations(e),...this.macroSchemaNameAndDescription(e),...this.macroProvenance(e,this.atomicWriter),...this.macroSkos(e),...this.macroStatusAndVersion(e,this.atomicWriter),...this.macroDerivedFrom(e),...this.macroPreviousVersion(e),[i.JsonSchema.schemaVersion]:this.atomicWriter.write(e.schema_schemaVersion),[l.TemplateProperty.additionalProperties]:this.atomicWriter.write(u.AdditionalProperties.FALSE),...this.macroSchemaIdentifier(e),[a.CedarModel.schema]:this.atomicWriter.write(c.ArtifactSchema.CURRENT)}}macroContext(e){const t=f.ReaderUtil.deepClone(s.JsonTemplateFieldContentDynamic.CONTEXT_VERBATIM);return e.language!==h.Language.NULL&&(t[i.JsonSchema.atLanguage]=this.atomicWriter.write(e.language)),t}}t.JsonTemplateFieldWriterInternal=T},6320(e,t,r){t.JsonTemplateInstanceWriter=void 0;const n=r(8748),a=r(2733),i=r(9517),s=r(3161),o=r(350),l=r(7723),c=r(5222),d=r(4877),u=r(9327),m=r(3644),p=r(8193),h=r(7571),f=r(7548),T=r(4465),y=r(4033);class E extends s.JsonAbstractArtifactWriter{constructor(e,t){super(e,t)}macroContext(e){return o.JsonTemplateInstanceContent.CONTEXT_VERBATIM}static getFor(e,t){return new E(e,t)}buildContext(e){const t=n.ReaderUtil.deepClone(o.JsonTemplateInstanceContent.CONTEXT_VERBATIM);return Object.keys(e.dataContainer.iris).forEach(r=>{t[r]=e.dataContainer.iris[r]}),{...t}}getDataTree(e){const t=i.JsonNode.getEmpty();return this.serializeDataLevelInto(e.dataContainer,t,!0),t}serializeDataLevelInto(e,t,r=!1){r||(t[a.JsonSchema.atId]=""===e.id?null:e.id),Object.keys(e.values).forEach(r=>{const n=e.values[r];if(Array.isArray(n)){const e=i.JsonNode.getEmptyList();t[r]=e,n.forEach((t,r)=>{if(t instanceof m.InstanceDataAttributeValueFieldName){const r=t.name;return void(r.trim().length>0&&e.push(r))}const n=this.serializeCommonType(t);null!==n&&e.push(n)})}else{const e=this.serializeCommonType(n);if(null!==e&&(t[r]=e),n instanceof u.InstanceDataAttributeValueField){const e=[];Object.keys(n.values).forEach(t=>{e.push(t)}),t[r]=e}}}),this.serializeAttributeValueFields(e,t);const n=i.JsonNode.getEmpty();Object.keys(e.iris).forEach(t=>{n[t]=e.iris[t]}),t[a.JsonSchema.atContext]=n}static writeValueNode(e){return e instanceof c.InstanceDataStringAtom?{[a.JsonSchema.atValue]:e.value}:e instanceof d.InstanceDataTypedAtom?{[a.JsonSchema.atValue]:e.value,[a.JsonSchema.atType]:e.type}:e instanceof p.InstanceDataControlledAtom?{[a.JsonSchema.atId]:e.id,[a.JsonSchema.rdfsLabel]:e.label}:e instanceof h.InstanceDataLinkAtom?{[a.JsonSchema.atId]:e.id}:e instanceof f.InstanceDataEmptyAtom||e instanceof T.InstanceDataEmptyNode?i.JsonNode.getEmpty():null}serializeCommonType(e){if(e instanceof l.InstanceDataContainer){const t=i.JsonNode.getEmpty();return this.serializeDataLevelInto(e,t),t}return E.writeValueNode(e)}serializeAtomString(e){return{[a.JsonSchema.atValue]:e.value}}serializeAttributeValueFields(e,t){Object.keys(e.values).forEach(r=>{const n=e.values[r];n instanceof u.InstanceDataAttributeValueField&&Object.keys(n.values).forEach(e=>{const r=n.values[e];r instanceof c.InstanceDataStringAtom&&(t[e]=this.serializeAtomString(r))})})}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){y.AttributeValueNamePolicy.assertValid(e.dataContainer);const t=this.buildContext(e);return{[a.JsonSchema.atId]:this.atomicWriter.write(e.at_id),...this.macroSchemaNameAndDescription(e),...this.getDataTree(e),...this.macroAnnotations(e),[a.JsonSchema.atContext]:t,...this.macroIsBasedOn(e),...this.macroProvenance(e,this.atomicWriter),...this.macroDerivedFrom(e)}}}t.JsonTemplateInstanceWriter=E},7519(e,t,r){t.JsonTemplateWriter=void 0;const n=r(8748),a=r(6551),i=r(2733),s=r(936),o=r(2763),l=r(5793),c=r(5747),d=r(2475),u=r(9932),m=r(8872),p=r(7752);class h extends m.JsonAbstractContainerArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new h(e,t)}buildProperties(e){const t=n.ReaderUtil.deepClone(a.JsonTemplateContent.PROPERTIES_PARTIAL);e.language!==p.Language.NULL&&(t[i.JsonSchema.atContext][i.JsonSchema.atLanguage]=this.atomicWriter.write(e.language));const r=e.getChildrenInfo().getIRIMap();t[i.JsonSchema.atContext][i.JsonSchema.properties]={...t[i.JsonSchema.atContext][i.JsonSchema.properties],...r};const s=Object.keys(r);t[i.JsonSchema.atContext][i.JsonSchema.required]=[...t[i.JsonSchema.atContext][i.JsonSchema.required],...s],e.getChildrenInfo().hasAttributeValue()&&(t[i.JsonSchema.atContext][c.TemplateProperty.additionalProperties]=u.JsonTemplateFieldContentDynamic.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE);const o={...t,...this.getChildMapAsJson(e)};return this.expandInstanceTypeSpecification(e,o),o}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=this.buildProperties(e),r={[s.CedarModel.order]:e.getChildrenInfo().getChildrenNames(),[s.CedarModel.propertyLabels]:e.getChildrenInfo().getPropertyLabelMap(e),[s.CedarModel.propertyDescriptions]:e.getChildrenInfo().getPropertyDescriptionMap(e)};return this.behavior.outputPages()&&(r[s.CedarModel.pages]=[]),null!==e.header&&(r[s.CedarModel.header]=e.header),null!==e.footer&&(r[s.CedarModel.footer]=e.footer),{[i.JsonSchema.atId]:this.atomicWriter.write(e.at_id),[i.JsonSchema.atType]:this.atomicWriter.write(o.CedarArtifactType.TEMPLATE),[i.JsonSchema.atContext]:this.macroContext(e),[s.CedarModel.type]:this.atomicWriter.write(l.JavascriptType.OBJECT),[c.TemplateProperty.title]:e.title,[c.TemplateProperty.description]:e.description,[s.CedarModel.ui]:r,[i.JsonSchema.properties]:t,[i.JsonSchema.required]:[...a.JsonTemplateContent.REQUIRED_PARTIAL,...e.getChildrenInfo().getChildrenNamesForRequired()],[c.TemplateProperty.additionalProperties]:this.atomicWriter.write(e.getAdditionalProperties()),...this.macroAnnotations(e),...this.macroSchemaNameAndDescription(e),...this.macroProvenance(e,this.atomicWriter),...this.macroStatusAndVersion(e,this.atomicWriter),...this.macroDerivedFrom(e),...this.macroPreviousVersion(e),[i.JsonSchema.schemaVersion]:this.atomicWriter.write(e.schema_schemaVersion),...this.macroSchemaIdentifier(e),[s.CedarModel.schema]:this.atomicWriter.write(d.ArtifactSchema.CURRENT)}}}t.JsonTemplateWriter=h},5359(e,t,r){t.CedarYamlWriters=void 0;const n=r(4869),a=r(1933),i=r(8354),s=r(2418),o=r(9184),l=r(2395),c=r(7432),d=r(6116),u=r(2342),m=r(2287),p=r(836),h=r(7436),f=r(7594),T=r(1784),y=r(6082),E=r(4935),C=r(6314),g=r(1903),I=r(5251),A=r(1521),b=r(1038),R=r(3292),S=r(9821),_=r(4500),v=r(3080),N=r(8136),w=r(9535),L=r(1181),F=r(765),O=r(3671),V=r(9532),B=r(4647),D=r(9411),M=r(9326),U=r(491),J=r(4355),Y=r(5587),x=r(6557),P=r(4077),k=r(3711),W=r(6967);class K{behavior;yamlDynamicFieldWriters;yamlStaticFieldWriters;yamlValueConstraintsWriters;yamlAtomicWriter;yamlAnnotationsWriter;yamlTemplateWriter;yamlTemplateElementWriter;yamlTemplateInstanceWriter;constructor(e){this.behavior=e,this.yamlAtomicWriter=new u.YamlAtomicWriter(e),this.yamlAnnotationsWriter=new m.YamlAnnotationsWriter(e),this.yamlTemplateWriter=a.YamlTemplateWriter.getFor(e,this),this.yamlTemplateElementWriter=I.YamlTemplateElementWriter.getFor(e,this),this.yamlTemplateInstanceWriter=M.YamlTemplateInstanceWriter.getFor(e,this),this.yamlDynamicFieldWriters=new Map([[n.CedarFieldType.TEXT,new d.YamlFieldWriterTextField(e,this)],[n.CedarFieldType.TEXTAREA,new p.YamlFieldWriterTextArea(e,this)],[n.CedarFieldType.CONTROLLED_TERM,new w.YamlFieldWriterControlledTerm(e,this)],[n.CedarFieldType.PHONE_NUMBER,new S.YamlFieldWriterPhoneNumber(e,this)],[n.CedarFieldType.EMAIL,new b.YamlFieldWriterEmail(e,this)],[n.CedarFieldType.LINK,new T.YamlFieldWriterLink(e,this)],[n.CedarFieldType.EXT_ROR,new U.YamlFieldWriterExtRor(e,this)],[n.CedarFieldType.EXT_ORCID,new J.YamlFieldWriterExtOrcid(e,this)],[n.CedarFieldType.EXT_PFAS,new Y.YamlFieldWriterExtPfas(e,this)],[n.CedarFieldType.EXT_PUBMED,new x.YamlFieldWriterExtPubmed(e,this)],[n.CedarFieldType.EXT_RRID,new P.YamlFieldWriterExtRrid(e,this)],[n.CedarFieldType.EXT_NIH_GRANT_ID,new k.YamlFieldWriterExtNihGrantId(e,this)],[n.CedarFieldType.EXT_DOI,new W.YamlFieldWriterExtDoi(e,this)],[n.CedarFieldType.NUMERIC,new R.YamlFieldWriterNumeric(e,this)],[n.CedarFieldType.TEMPORAL,new h.YamlFieldWriterTemporal(e,this)],[n.CedarFieldType.RADIO,new N.YamlFieldWriterRadio(e,this)],[n.CedarFieldType.CHECKBOX,new _.YamlFieldWriterCheckbox(e,this)],[n.CedarFieldType.SINGLE_SELECT_LIST,new v.YamlFieldWriterList(e,this)],[n.CedarFieldType.MULTIPLE_SELECT_LIST,new v.YamlFieldWriterList(e,this)],[n.CedarFieldType.ATTRIBUTE_VALUE,new A.YamlFieldWriterAttributeValue(e,this)]]),this.yamlStaticFieldWriters=new Map([[n.CedarFieldType.STATIC_PAGE_BREAK,new f.YamlFieldWriterStaticPageBreak(e,this)],[n.CedarFieldType.STATIC_SECTION_BREAK,new y.YAMLFieldWriterStaticSectionsBreak(e,this)],[n.CedarFieldType.STATIC_IMAGE,new E.YamlFieldWriterStaticImage(e,this)],[n.CedarFieldType.STATIC_RICH_TEXT,new C.YamlFieldWriterStaticRichText(e,this)],[n.CedarFieldType.STATIC_YOUTUBE,new g.YamlFieldWriterStaticYoutube(e,this)]]),this.yamlValueConstraintsWriters=new Map([[i.ControlledTermOntology.className,new L.YamlValueConstraintsOntologyWriter(e,this)],[s.ControlledTermClass.className,new F.YamlValueConstraintsClassWriter(e,this)],[o.ControlledTermBranch.className,new O.YamlValueConstraintsBranchWriter(e,this)],[l.ControlledTermValueSet.className,new V.YamlValueConstraintsValueSetWriter(e,this)],[c.ControlledTermAction.className,new B.YamlValueConstraintsActionWriter(e,this)]])}static getStrict(){return new K(D.YamlWriterBehavior.STRICT)}static getFor(e){return new K(e)}getFieldWriterForType(e){let t;if(t=e.isStaticField?this.yamlStaticFieldWriters.get(e):this.yamlDynamicFieldWriters.get(e),t)return t;throw new Error(`No YAML writer found for field type: ${e.getValue()}`)}getFieldWriterForField(e){return this.getFieldWriterForType(e.cedarFieldType)}getAtomicWriter(){return this.yamlAtomicWriter}getAnnotationsWriter(){return this.yamlAnnotationsWriter}getTemplateWriter(){return this.yamlTemplateWriter}getTemplateElementWriter(){return this.yamlTemplateElementWriter}getTemplateInstanceWriter(){return this.yamlTemplateInstanceWriter}getWriterForValueConstraint(e){const t=e.className,r=this.yamlValueConstraintsWriters.get(t);if(r)return r;throw new Error(`No YAML writer found for class type: ${t}`)}}t.CedarYamlWriters=K},6574(e,t,r){var n,a=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),s=this&&this.__importStar||(n=function(e){return n=Object.getOwnPropertyNames||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[t.length]=r);return t},n(e)},function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r=n(e),s=0;s<r.length;s++)"default"!==r[s]&&a(t,e,r[s]);return i(t,e),t});Object.defineProperty(t,"__esModule",{value:!0}),t.SimpleYamlSerializer=void 0;const o=s(r(3198)),l=r(1100),c={blockQuote:"literal",doubleQuotedMinMultiLineLength:1e9,lineWidth:0,minContentWidth:0,defaultStringType:"QUOTE_DOUBLE",defaultKeyType:"PLAIN",doubleQuotedAsJSON:!0};t.SimpleYamlSerializer=class{static serialize(e){const t=new o.default.Document(e);return(0,o.visit)(t,{Scalar(e,t,r){if("key"===e&&"string"==typeof t.value&&(0,l.plainScalarNeedsQuoting)(t.value))t.type=o.Scalar.QUOTE_DOUBLE;else if("value"===e&&"string"==typeof t.value){const e=r.at(-1);(0,o.isPair)(e)&&(0,o.isScalar)(e.key)&&"string"==typeof e.key.value&&(0,l.mayWriteYamlValuePlain)(e.key.value,t.value)&&(t.type=o.Scalar.PLAIN)}}}),t.toString(c).trim()+"\n"}}},211(e,t,r){t.YamlAbstractArtifactWriter=void 0;const n=r(2112),a=r(8333),i=r(9517),s=r(2099),o=r(3910),l=r(1027),c=r(9129),d=r(8534),u=r(2234),m=r(9857),p=r(7661),h=r(9499),f=r(3281),T=r(6731),y=r(8972),E=r(7752),C=r(8557),g=r(2272);class I extends n.AbstractArtifactWriter{behavior;writers;atomicWriter;annotationsWriter;constructor(e,t){super(),this.behavior=e,this.writers=t,this.atomicWriter=t.getAtomicWriter(),this.annotationsWriter=t.getAnnotationsWriter()}macroNameAndDescription(e){const t=i.JsonNode.getEmpty();return e instanceof a.AbstractSchemaArtifact&&e.language!==E.Language.NULL&&(t[s.YamlKeys.language]=this.atomicWriter.write(e.language)),t[s.YamlKeys.name]=e.schema_name,null!==e.schema_description&&""!==e.schema_description&&(t[s.YamlKeys.description]=e.schema_description),t}macroStatusAndVersion(e,t){const r=i.JsonNode.getEmpty();return t||(e.bibo_status!==o.BiboStatus.NULL&&(r[s.YamlKeys.status]=this.atomicWriter.write(e.bibo_status)),e.pav_version!==l.PavVersion.NULL&&(r[s.YamlKeys.version]=this.atomicWriter.write(e.pav_version)),r[s.YamlKeys.modelVersion]=this.atomicWriter.write(C.SchemaVersion.CURRENT)),r}macroInstanceType(e){const t=i.JsonNode.getEmpty();return null!==e.instanceTypeSpecification&&(t[s.YamlKeys.instanceType]=e.instanceTypeSpecification),t}macroSkos(e){const t=i.JsonNode.getEmpty();return null!==e.skos_prefLabel&&(t[s.YamlKeys.prefLabel]=e.skos_prefLabel),null!==e.skos_altLabel&&e.skos_altLabel.length>0&&(t[s.YamlKeys.altLabels]=e.skos_altLabel),t}macroValueRecommendation(e){const t=i.JsonNode.getEmpty();return(e instanceof T.ControlledTermFieldImpl||e instanceof y.TextFieldImpl)&&e.valueRecommendationEnabled&&(t[s.YamlKeys.valueRecommendation]=e.valueRecommendationEnabled),t}macroProvenance(e,t){const r=i.JsonNode.getEmpty();return t||(e.pav_createdOn!==m.IsoDate.NULL&&(r[s.YamlKeys.createdOn]=this.atomicWriter.write(e.pav_createdOn)),e.pav_createdBy!==u.CedarUser.NULL&&(r[s.YamlKeys.createdBy]=this.atomicWriter.write(e.pav_createdBy)),e.pav_lastUpdatedOn!==m.IsoDate.NULL&&(r[s.YamlKeys.modifiedOn]=this.atomicWriter.write(e.pav_lastUpdatedOn)),e.oslc_modifiedBy!==u.CedarUser.NULL&&(r[s.YamlKeys.modifiedBy]=this.atomicWriter.write(e.oslc_modifiedBy))),r}macroSchemaIdentifier(e){const t=i.JsonNode.getEmpty();return null!==e.schema_identifier&&(t[s.YamlKeys.identifier]=e.schema_identifier),t}macroType(e){const t=i.JsonNode.getEmpty();return t[s.YamlKeys.type]=this.getYamlType(e),t}macroId(e,t=!1,r=!0){const n=i.JsonNode.getEmpty();return e.at_id!==d.CedarArtifactId.NULL&&(n[s.YamlKeys.id]=this.atomicWriter.write(e.at_id)),n}macroDerivedFrom(e,t){const r=i.JsonNode.getEmpty();return t||e.pav_derivedFrom!==d.CedarArtifactId.NULL&&(r[s.YamlKeys.derivedFrom]=this.atomicWriter.write(e.pav_derivedFrom)),r}macroIsBasedOn(e){const t=i.JsonNode.getEmpty();return e.schema_isBasedOn!==d.CedarArtifactId.NULL&&(t[s.YamlKeys.isBasedOn]=this.atomicWriter.write(e.schema_isBasedOn)),t}macroPreviousVersion(e,t){const r=i.JsonNode.getEmpty();return t||e.pav_previousVersion!==d.CedarArtifactId.NULL&&(r[s.YamlKeys.previousVersion]=this.atomicWriter.write(e.pav_previousVersion)),r}macroAnnotations(e){return this.annotationsWriter.write(e.annotations)}getYamlType(e){return e instanceof f.Template?h.YamlArtifactType.TEMPLATE.getValue():e instanceof p.TemplateElement?h.YamlArtifactType.ELEMENT.getValue():e instanceof c.TemplateField?e.cedarFieldType.getYamlType().getValue():e instanceof g.TemplateInstance?h.YamlArtifactType.TEMPLATE_INSTANCE.getValue():void 0}}t.YamlAbstractArtifactWriter=I},5386(e,t,r){t.YamlAbstractContainerArtifactWriter=void 0;const n=r(9517),a=r(9129),i=r(211),s=r(2099),o=r(3812),l=r(5692),c=r(699);class d extends i.YamlAbstractArtifactWriter{getChildListAsJSON(e,t){const r=n.JsonNode.getEmptyList();return e.getChildrenInfo().getChildrenNames().forEach(i=>{const o=e.getChild(i);if(null!=o){let l=n.JsonNode.getEmpty();const c=e.getChildrenInfo().get(i);if(null!==c){l[s.YamlKeys.key]=i,l=o instanceof a.TemplateField?{...l,...this.writers.getFieldWriterForType(o.cedarFieldType).getYamlAsJsonNode(o,c,t,!1)}:{...l,...this.writers.getTemplateElementWriter().getYamlAsJsonNode(o,t,!1)};const e=this.getDeploymentInfo(o,c,t);n.JsonNode.hasEntries(e)&&(l[s.YamlKeys.configuration]=e),r.push(l)}}}),r}getDeploymentInfo(e,t,r){const i=n.JsonNode.getEmpty();t instanceof o.AbstractDynamicChildDeploymentInfo&&(t.requiredValue&&(i[s.YamlKeys.required]=!0),t.hidden&&(i[s.YamlKeys.hidden]=!0),t.recommendedValue&&(i[s.YamlKeys.recommended]=!0),null!==t.iri&&(r||(i[s.YamlKeys.propertyIri]=t.iri))),null!==t.label&&t.label!==e?.schema_name&&(i[s.YamlKeys.overrideLabel]=t.label),null!==t.description&&t.description!==e?.schema_description&&(i[s.YamlKeys.overrideDescription]=t.description),t instanceof o.AbstractDynamicChildDeploymentInfo&&(t.continuePreviousLine&&(i[s.YamlKeys.continuePreviousLine]=!0),t.valueRecommendationEnabled&&e instanceof a.TemplateField&&e.supportsValueRecommendation()&&(i[s.YamlKeys.valueRecommendation]=!0));const{isMultiInstance:d,minItems:u,maxItems:m}=l.WriterUtil.getMultiMinMax(e,t);let p=u,h=m;return d&&(null===p&&(p=0),null!==h&&h<p&&(h=p),e?.isMultiInstanceByDefinition()||e?.isSingleInstanceByDefinition()||(i[s.YamlKeys.multiple]=!0,i[s.YamlKeys.minItems]=p,null!==h&&(i[s.YamlKeys.maxItems]=h))),(0,c.isSizedStaticField)(e)&&(null!==e.width&&(i[s.YamlKeys.width]=e.width),null!==e.height&&(i[s.YamlKeys.height]=e.height)),i}}t.YamlAbstractContainerArtifactWriter=d},2287(e,t,r){t.YamlAnnotationsWriter=void 0;const n=r(9517),a=r(2787),i=r(3549),s=r(2099);t.YamlAnnotationsWriter=class{behavior;constructor(e){this.behavior=e}write(e){const t=n.JsonNode.getEmpty(),r=n.JsonNode.getEmpty();return null!==e&&e.getSize()>0&&(e.getAnnotationNames().forEach(t=>{const n=e.get(t);if(n instanceof a.AnnotationAtId){const e={[s.YamlKeys.id]:n.getAtId()};r[t]=e}else if(n instanceof i.AnnotationAtValue){const e={[s.YamlKeys.value]:n.getAtValue()};r[t]=e}}),t[s.YamlKeys.annotations]=r),t}}},2342(e,t,r){t.YamlAtomicWriter=void 0;const n=r(2022),a=r(4872),i=r(4531),s=r(3910);class o extends a.JsonAtomicWriter{constructor(e){super(n.JsonWriterBehavior.STRICT)}writeCedarArtifactType(e){return e.getYamlValue()}write(e){return null==e?null:e instanceof s.BiboStatus?this.writeBiboStatusYaml(e):e instanceof i.BioportalTermType?this.writeBioportalTermTypeYaml(e):super.write(e)}writeBiboStatusYaml(e){return e.getYamlValue()}writeBioportalTermTypeYaml(e){return e.getYamlValue()}}t.YamlAtomicWriter=o},1100(e,t,r){t.plainScalarNeedsQuoting=m,t.mayWriteYamlValuePlain=function(e,t){return(T.get(e)?.has(t)??(("version"===e||"modelVersion"===e)&&f.test(t)))&&!m(t)};const n=r(8349),a=r(4531),i=r(3910),s=r(3447),o=r(7974),l=r(8588),c=r(3764),d=r(9499),u=[/^(y|Y|n|N|yes|Yes|YES|no|No|NO|on|On|ON|off|Off|OFF|true|True|TRUE|false|False|FALSE)$/,/^(null|Null|NULL|~|<<|=)$/,/^[-+]?[0-9][0-9_]*$/,/^[-+]?0[xX][0-9a-fA-F_]+$/,/^[-+]?0[bB][01_]+$/,/^[-+]?0[oO]?[0-7_]+$/,/^[-+]?[0-9_]*\.?[0-9_]+([eE][-+]?[0-9]+)?$/,/^[-+]?\.(inf|Inf|INF|nan|NaN|NAN)$/,/^[-+]?[0-9][0-9_]*(:[0-5]?[0-9])+(\.[0-9_]*)?$/];function m(e){return u.some(t=>t.test(e))||function(e){for(const t of e){const e=t.codePointAt(0)??0;if(9===e||13===e||e<=31&&10!==e||e>=127&&e<=160||5760===e||e>=8192&&e<=8202||8232===e||8233===e||8239===e||8287===e||12288===e||65279===e)return!0}return e.startsWith(" ")||e.endsWith(" ")||e.includes(" \n")||0===e.length}(e)}const p=new Set([...Object.values(d.YamlArtifactTypeValues),"element-instance",n.YamlValues.Controlled.class,a.BioportalTermTypeYamlValues.VALUE,n.YamlValues.Controlled.ontology,n.YamlValues.Controlled.branch,n.YamlValues.Controlled.valueSet]),h=new Set(["xsd:string","xsd:anyUri",...Object.values(l.TemporalTypeValues),...Object.values(s.NumberTypeValues),n.YamlValues.iri]),f=/^\d+\.\d+\.\d+$/,T=new Map([["type",p],["status",new Set(Object.values(i.BiboStatusYamlValues))],["datatype",h],["action",new Set(["move","delete"])],["granularity",new Set(Object.values(o.TemporalGranularityValues))],["termType",new Set(Object.values(a.BioportalTermTypeYamlValues))],["inputTimeFormat",new Set(Object.values(c.TimeFormatValues))]]);new Set([...T.keys(),"version","modelVersion"])},5251(e,t,r){t.YamlTemplateElementWriter=void 0;const n=r(6574),a=r(2099),i=r(5386);class s extends i.YamlAbstractContainerArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new s(e,t)}getYamlAsJsonNode(e,t=!1,r=!0){const n={...this.macroType(e),...this.macroNameAndDescription(e),...this.macroSchemaIdentifier(e),...this.macroId(e,t,r),...this.macroStatusAndVersion(e,t),...this.macroInstanceType(e),...this.macroPreviousVersion(e,t),...this.macroDerivedFrom(e,t),...this.macroProvenance(e,t),...this.macroSkos(e),...this.macroAnnotations(e)},i=this.getChildListAsJSON(e,t);return i.length>0&&(n[a.YamlKeys.children]=i),n}getAsYamlString(e,t=!1){return n.SimpleYamlSerializer.serialize(this.getYamlAsJsonNode(e,t))}}t.YamlTemplateElementWriter=s},5430(e,t,r){t.YamlTemplateFieldWriterInternal=void 0;const n=r(9517),a=r(936),i=r(455),s=r(2099),o=r(211),l=r(6574);class c extends o.YamlAbstractArtifactWriter{constructor(e,t){super(e,t)}getAsYamlString(e,t=!1){return l.SimpleYamlSerializer.serialize(this.getYamlAsJsonNode(e,i.ChildDeploymentInfo.empty(),t))}getYamlAsJsonNode(e,t=i.ChildDeploymentInfo.empty(),r=!1,n=!0){const a=this.buildUIObject(e,t),s=this.buildValueConstraintsObject(e,t);return{...this.macroType(e),...this.macroNameAndDescription(e),...this.macroSchemaIdentifier(e),...this.macroId(e,r,n),...this.macroStatusAndVersion(e,r),...this.macroSkos(e),...a,...s,...this.macroValueRecommendation(e),...this.macroPreviousVersion(e,r),...this.macroDerivedFrom(e,r),...this.macroProvenance(e,r),...this.macroAnnotations(e)}}expandUINodeForYAML(e){return n.JsonNode.getEmpty()}expandValueConstraintsNodeForYAML(e,t,r){}buildValueConstraintsObject(e,t){const r=n.JsonNode.getEmpty();return this.expandValueConstraintsNodeForYAML(r,e,t),r}expandLiterals(e,t){const r=n.JsonNode.getEmptyList();e.valueConstraints.literals.forEach(e=>{const t=n.JsonNode.getEmpty();t[a.CedarModel.label]=e.label,e.selectedByDefault&&(t[s.YamlKeys.selected]=e.selectedByDefault),r.push(t)}),r.length>0&&(t[s.YamlKeys.values]=r)}buildUIObject(e,t){return this.expandUINodeForYAML(e)}}t.YamlTemplateFieldWriterInternal=c},9326(e,t,r){t.YamlTemplateInstanceWriter=void 0;const n=r(9517),a=r(6574),i=r(211),s=r(7723),o=r(9327),l=r(5222),c=r(7571),d=r(4877),u=r(8193),m=r(2099),p=r(4033),h=r(3644);class f extends i.YamlAbstractArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new f(e,t)}getYamlAsJsonNode(e,t=!1){return p.AttributeValueNamePolicy.assertValid(e.dataContainer),{...this.macroType(e),...this.macroNameAndDescription(e),...this.macroId(e,t,!0),...this.macroIsBasedOn(e),...this.macroDerivedFrom(e,t),...this.macroProvenance(e,t),...this.getDataTree(e,t),...this.macroAnnotations(e)}}getAsYamlString(e,t=!1){return a.SimpleYamlSerializer.serialize(this.getYamlAsJsonNode(e,t))}getDataTree(e,t){const r=n.JsonNode.getEmpty();return this.serializeDataLevelInto(e.dataContainer,r,t),r}serializeDataLevelInto(e,t,r){const a=n.JsonNode.getEmpty(),i=this.getUnpackedAttributeValueGroups(e),o=new Set(Array.from(i.values()).flat());Object.keys(e.values).forEach(t=>{if(i.has(t)||o.has(t))return;const l=e.values[t];if(Array.isArray(l)){const e=n.JsonNode.getEmptyList();l.forEach((t,a)=>{const i=this.serializeCommonType(t,r);if(null!==i&&n.JsonNode.hasEntries(i))e.push(i);else if(t instanceof s.InstanceDataContainer){const r={[m.YamlKeys.type]:"element-instance"};this.hasId(t.id)&&(r[m.YamlKeys.id]=t.id),e.push(r)}}),e.length>0&&(a[t]=e)}else{const e=this.serializeCommonType(l,r);null!==e&&n.JsonNode.hasEntries(e)&&(a[t]=e)}}),n.JsonNode.hasEntries(a)&&(this.hasId(e.id)&&(t[m.YamlKeys.id]=e.id),t[m.YamlKeys.children]=a),this.serializeAttributeValueFields(e,t,i)}serializeAttributeValueFields(e,t,r){Object.keys(e.values).forEach(r=>{const a=e.values[r];if(a instanceof o.InstanceDataAttributeValueField){const e=n.JsonNode.getEmpty();let i=!1;Object.keys(a.values).forEach(t=>{const r=a.values[t];if(r instanceof l.InstanceDataStringAtom){const n=this.serializeAtomString(r);null!==n&&(e[t]=n,i=!0)}}),i&&(t[r]=e)}});for(const[a,i]of r){const r=n.JsonNode.getEmpty();for(const t of i){const n=e.values[t];if(n instanceof l.InstanceDataStringAtom){const e=this.serializeAtomString(n);null!==e&&(r[t]=e)}}n.JsonNode.hasEntries(r)&&(t[a]=r)}}getUnpackedAttributeValueGroups(e){const t=new Map;for(const[r,n]of Object.entries(e.values)){if(!Array.isArray(n))continue;const e=n.filter(e=>e instanceof h.InstanceDataAttributeValueFieldName).map(e=>e.name).filter(e=>e.trim().length>0);e.length>0&&t.set(r,e)}return t}serializeCommonType(e,t){if(e instanceof l.InstanceDataStringAtom)return this.serializeAtomString(e);if(e instanceof d.InstanceDataTypedAtom)return null===e.value?null:{[m.YamlKeys.datatype]:e.type,[m.YamlKeys.value]:e.value};if(e instanceof u.InstanceDataControlledAtom){const t=n.JsonNode.getEmpty();return this.hasId(e.id)&&(t[m.YamlKeys.id]=e.id),null!==e.label&&(t[m.YamlKeys.label]=e.label),n.JsonNode.hasEntries(t)?t:null}if(e instanceof c.InstanceDataLinkAtom)return this.serializeAtomLink(e);if(e instanceof s.InstanceDataContainer){const r=n.JsonNode.getEmpty();return this.serializeDataLevelInto(e,r,t),r}return null}serializeAtomString(e){return null===e.value?null:{[m.YamlKeys.value]:e.value}}serializeAtomLink(e){return this.hasId(e.id)?{[m.YamlKeys.id]:e.id}:null}hasId(e){return null!==e&&""!==e}}t.YamlTemplateInstanceWriter=f},1933(e,t,r){t.YamlTemplateWriter=void 0;const n=r(9517),a=r(6574),i=r(2099),s=r(5386);class o extends s.YamlAbstractContainerArtifactWriter{constructor(e,t){super(e,t)}static getFor(e,t){return new o(e,t)}getYamlAsJsonNode(e,t=!1){const r=n.JsonNode.getEmpty();null!==e.header&&(r[i.YamlKeys.header]=e.header),null!==e.footer&&(r[i.YamlKeys.footer]=e.footer);const a={...this.macroType(e),...this.macroNameAndDescription(e),...this.macroSchemaIdentifier(e),...this.macroId(e,t,!0),...this.macroStatusAndVersion(e,t),...this.macroInstanceType(e),...r,...this.macroPreviousVersion(e,t),...this.macroDerivedFrom(e,t),...this.macroProvenance(e,t),...this.macroAnnotations(e)},s=this.getChildListAsJSON(e,t);return s.length>0&&(a[i.YamlKeys.children]=s),a}getAsYamlString(e,t=!1){return a.SimpleYamlSerializer.serialize(this.getYamlAsJsonNode(e,t))}}t.YamlTemplateWriter=o},1641(e,t,r){t.AbstractArtifactBuilder=void 0;const n=r(9857),a=r(2234),i=r(1027),s=r(3910),o=r(8534),l=r(8557);t.AbstractArtifactBuilder=class{at_id=o.CedarArtifactId.NULL;title=null;description=null;schema_schemaVersion=l.SchemaVersion.CURRENT;pav_createdOn=n.IsoDate.NULL;pav_createdBy=a.CedarUser.NULL;pav_lastUpdatedOn=n.IsoDate.NULL;oslc_modifiedBy=a.CedarUser.NULL;pav_version=i.PavVersion.DEFAULT;bibo_status=s.BiboStatus.DRAFT;schema_name=null;schema_description=null;schema_identifier=null;pav_derivedFrom=o.CedarArtifactId.NULL;withAtId(e){return e instanceof o.CedarArtifactId?this.at_id=e:this.at_id=o.CedarArtifactId.forValue(e),this}withTitle(e){return this.title=e,this}withDescription(e){return this.description=e,this}withSchemaVersion(e){return this.schema_schemaVersion=e,this}withCreatedOn(e){return e instanceof n.IsoDate?this.pav_createdOn=e:this.pav_createdOn=n.IsoDate.forValue(e),this}withCreatedBy(e){return e instanceof a.CedarUser?this.pav_createdBy=e:this.pav_createdBy=a.CedarUser.forValue(e),this}withLastUpdatedOn(e){return e instanceof n.IsoDate?this.pav_lastUpdatedOn=e:this.pav_lastUpdatedOn=n.IsoDate.forValue(e),this}withModifiedBy(e){return e instanceof a.CedarUser?this.oslc_modifiedBy=e:this.oslc_modifiedBy=a.CedarUser.forValue(e),this}withVersion(e){return e instanceof i.PavVersion?this.pav_version=e:this.pav_version=i.PavVersion.forValue(e),this}withStatus(e){return e instanceof s.BiboStatus?this.bibo_status=e:this.bibo_status=s.BiboStatus.forJsonValue(e),this}withSchemaName(e){return this.schema_name=e,this}withSchemaDescription(e){return this.schema_description=e,this}withDerivedFrom(e){return this.pav_derivedFrom=e,this}withSchemaIdentifier(e){return this.schema_identifier=e,this}buildInternal(e){e.at_id=this.at_id,e.title=this.title,e.description=this.description,e.schema_schemaVersion=this.schema_schemaVersion,e.pav_createdOn=this.pav_createdOn,e.pav_createdBy=this.pav_createdBy,e.pav_lastUpdatedOn=this.pav_lastUpdatedOn,e.oslc_modifiedBy=this.oslc_modifiedBy,e.pav_version=this.pav_version,e.bibo_status=this.bibo_status,e.schema_name=this.schema_name,e.schema_description=this.schema_description,e.schema_identifier=this.schema_identifier,e.pav_derivedFrom=this.pav_derivedFrom}}},2674(e,t,r){t.AbstractArtifact=void 0;const n=r(9857),a=r(2234),i=r(8534),s=r(2763);t.AbstractArtifact=class{at_id=i.CedarArtifactId.NULL;pav_createdOn=n.IsoDate.NULL;pav_createdBy=a.CedarUser.NULL;pav_lastUpdatedOn=n.IsoDate.NULL;oslc_modifiedBy=a.CedarUser.NULL;pav_derivedFrom=i.CedarArtifactId.NULL;schema_name=null;schema_description=null;cedarArtifactType=s.CedarArtifactType.NULL;annotations=null}},5451(e,t,r){t.AbstractContainerArtifact=void 0;const n=r(8333),a=r(1492),i=r(3746),s=r(2763);class o extends n.AbstractSchemaArtifact{childrenInfo=new a.ContainerArtifactChildrenInfo;childMap=new Map;instanceTypeSpecification=null;addChild(e,t){this.childrenInfo.add(t),this.childMap.set(t.name,e)}getChildrenInfo(){return this.childrenInfo}getAdditionalProperties(){return this.childrenInfo.hasAttributeValue()?i.AdditionalProperties.ALLOW_ATTRIBUTE_VALUE:i.AdditionalProperties.FALSE}getChild(e){return this.childMap.get(e)??null}getElement(e){const t=this.getChild(e);return null!==t&&t.cedarArtifactType===s.CedarArtifactType.TEMPLATE_ELEMENT?t:null}getField(e){const t=this.getChild(e);return null!==t&&t.cedarArtifactType===s.CedarArtifactType.TEMPLATE_FIELD?t:null}getChildInfo(e){return this.childrenInfo.get(e)}}t.AbstractContainerArtifact=o},5697(e,t,r){t.AbstractInstanceArtifact=void 0;const n=r(8534),a=r(2674);class i extends a.AbstractArtifact{schema_isBasedOn=n.CedarArtifactId.NULL}t.AbstractInstanceArtifact=i},8333(e,t,r){t.AbstractSchemaArtifact=void 0;const n=r(1027),a=r(3910),i=r(8534),s=r(8557),o=r(2674),l=r(7752);class c extends o.AbstractArtifact{title=null;description=null;schema_schemaVersion=s.SchemaVersion.NULL;pav_version=n.PavVersion.NULL;bibo_status=a.BiboStatus.NULL;schema_identifier=null;pav_previousVersion=i.CedarArtifactId.NULL;language=l.Language.NULL}t.AbstractSchemaArtifact=c},2787(e,t){t.AnnotationAtId=void 0,t.AnnotationAtId=class{name;id;constructor(e,t){this.name=e,this.id=t}getName(){return this.name}getAtId(){return this.id}}},3549(e,t){t.AnnotationAtValue=void 0,t.AnnotationAtValue=class{name;value;constructor(e,t){this.name=e,this.value=t}getName(){return this.name}getAtValue(){return this.value}}},5226(e,t){t.Annotations=void 0,t.Annotations=class{annotations=new Map;add(e){this.annotations.set(e.getName(),e)}getSize(){return this.annotations.size}getAnnotationNames(){return Array.from(this.annotations.keys())}get(e){return this.annotations.has(e)?this.annotations.get(e):null}}},936(e,t){t.CedarModel=void 0,t.CedarModel=class{static ui="_ui";static schema="$schema";static order="order";static inputType="inputType";static type="type";static items="items";static valueConstraints="_valueConstraints";static requiredValue="requiredValue";static defaultValue="defaultValue";static minItems="minItems";static maxItems="maxItems";static minLength="minLength";static maxLength="maxLength";static numberType="numberType";static temporalType="temporalType";static temporalGranularity="temporalGranularity";static timezoneEnabled="timezoneEnabled";static inputTimeFormat="inputTimeFormat";static unitOfMeasure="unitOfMeasure";static minValue="minValue";static maxValue="maxValue";static decimalPlace="decimalPlace";static content="_content";static size="_size";static width="width";static height="height";static regex="regex";static pages="pages";static header="header";static footer="footer";static ontologies="ontologies";static valueSets="valueSets";static classes="classes";static branches="branches";static actions="actions";static multipleChoice="multipleChoice";static literals="literals";static label="label";static selectedByDefault="selectedByDefault";static propertyDescriptions="propertyDescriptions";static propertyLabels="propertyLabels";static skosPrefLabel="skos:prefLabel";static skosAltLabel="skos:altLabel";static skosNotation="skos:notation";static format="format";static enum="enum";static annotations="_annotations";static propertyIriPrefix="https://schema.metadatacenter.org/properties/";static ValueConstraints=class{static acronym="acronym";static name="name";static uri="uri";static numTerms="numTerms";static label="label";static source="source";static type="type";static termType="termType";static prefLabel="prefLabel";static maxDepth="maxDepth";static vsCollection="vsCollection";static termUri="termUri";static sourceUri="sourceUri";static iri="iri";static sourceSystem="sourceSystem";static version="version";static versionId="id";static versionEffectiveDate="effectiveDate";static versionDeclaredVersion="declaredVersion";static action="action";static to="to";static recommendedValue="recommendedValue"};static Ui=class{static hidden="hidden";static continuePreviousLine="continuePreviousLine";static valueRecommendationEnabled="valueRecommendationEnabled"}}},2733(e,t){t.JsonSchema=void 0,t.JsonSchema=class{static properties="properties";static required="required";static atContext="@context";static atId="@id";static atType="@type";static atValue="@value";static atLanguage="@language";static schemaIsBasedOn="schema:isBasedOn";static schemaName="schema:name";static schemaDescription="schema:description";static schemaVersion="schema:schemaVersion";static schemaIdentifier="schema:identifier";static pavDerivedFrom="pav:derivedFrom";static pavPreviousVersion="pav:previousVersion";static pavCreatedOn="pav:createdOn";static pavCreatedBy="pav:createdBy";static pavLastUpdatedOn="pav:lastUpdatedOn";static oslcModifiedBy="oslc:modifiedBy";static pavVersion="pav:version";static biboStatus="bibo:status";static rdfsLabel="rdfs:label";static termUri="termUri";static enum="enum";static oneOf="oneOf";static type="type";static items="items"}},4216(e,t){t.NonStandardDatatype=void 0,t.NonStandardDatatype=class{static IRI="iri"}},5747(e,t){t.TemplateProperty=void 0,t.TemplateProperty=class{static title="title";static description="description";static additionalProperties="additionalProperties"}},2099(e,t){t.YamlKeys=void 0,t.YamlKeys=class{static id="id";static type="type";static name="name";static description="description";static modelVersion="modelVersion";static status="status";static version="version";static language="language";static label="label";static prefLabel="prefLabel";static altLabels="altLabels";static datatype="datatype";static valueRecommendation="valueRecommendation";static required="required";static recommended="recommended";static hidden="hidden";static continuePreviousLine="continuePreviousLine";static propertyIri="propertyIri";static overrideLabel="overrideLabel";static overrideDescription="overrideDescription";static default="default";static minLength="minLength";static maxLength="maxLength";static regex="regex";static identifier="identifier";static derivedFrom="derivedFrom";static previousVersion="previousVersion";static createdOn="createdOn";static createdBy="createdBy";static modifiedOn="modifiedOn";static modifiedBy="modifiedBy";static isBasedOn="isBasedOn";static instanceType="instanceType";static annotations="annotations";static value="value";static granularity="granularity";static inputTimeZone="inputTimeZone";static inputTimeFormat="inputTimeFormat";static header="header";static footer="footer";static children="children";static multiple="multiple";static minItems="minItems";static maxItems="maxItems";static content="content";static height="height";static width="width";static key="key";static minValue="minValue";static maxValue="maxValue";static decimalPlaces="decimalPlaces";static unit="unit";static multipleChoice="multipleChoice";static values="values";static selected="selected";static actions="actions";static action="action";static configuration="configuration";static Controlled=class{static sourceSystem="sourceSystem";static sourceAcronym="sourceAcronym";static sourceName="sourceName";static sourceIri="sourceIri";static termIri="termIri";static termType="termType";static termLabel="termLabel";static termDisplayLabel="termDisplayLabel";static termBaseIri="termBaseIri";static termBaseLabel="termBaseLabel";static termMaxDepth="termMaxDepth";static termCount="termCount";static versionId="id";static versionEffectiveDate="effectiveDate";static versionDeclaredVersion="declaredVersion";static to="to"}}},8349(e,t){t.YamlValues=void 0,t.YamlValues=class{static id="id";static value="value";static iri="iri";static string="string";static Controlled=class{static class="class";static ontology="ontology";static valueSet="valueSet";static branch="branch"}}},513(e,t,r){t.AbstractChildDeploymentInfo=void 0;const n=r(2763),a=r(9034);t.AbstractChildDeploymentInfo=class{_name;_atType=n.CedarArtifactType.NULL;_uiInputType=a.UiInputType.NULL;_label=null;_description=null;_hidden=!1;constructor(e){this._name=e}get name(){return this._name}hasParent(){return""!==this._name}get atType(){return this._atType}set atType(e){this._atType=e}get uiInputType(){return this._uiInputType}set uiInputType(e){this._uiInputType=e}get label(){return this._label}set label(e){this._label=e}get description(){return this._description}set description(e){this._description=e}get hidden(){return this._hidden}set hidden(e){this._hidden=e}}},6910(e,t,r){t.AbstractChildDeploymentInfoBuilder=void 0;const n=r(2763),a=r(9034),i=r(9129);t.AbstractChildDeploymentInfoBuilder=class{child=null;name="";atType=n.CedarArtifactType.NULL;uiInputType=a.UiInputType.NULL;label=null;description=null;hidden=!1;constructor(e,t){this.child=e,this.name=t}withLabel(e){return this.label=e,this}withDescription(e){return this.description=e,this}withHidden(e){return this.hidden=e,this}setCommonData(e){e.label=this.label,e.description=this.description,e.hidden=this.hidden,e.atType=this.atType,e.uiInputType=this.uiInputType,null!=this.child&&(e.atType=this.child.cedarArtifactType,this.child instanceof i.TemplateField&&(e.uiInputType=this.child.cedarFieldType.getUiInputType()))}}},3812(e,t,r){t.AbstractDynamicChildDeploymentInfo=void 0;const n=r(513);class a extends n.AbstractChildDeploymentInfo{_iri=null;_requiredValue=!1;_recommendedValue=!1;_continuePreviousLine=!1;_valueRecommendationEnabled=!1;constructor(e){super(e)}get iri(){return this._iri}set iri(e){this._iri=e}get requiredValue(){return this._requiredValue}set requiredValue(e){this._requiredValue=e}get recommendedValue(){return this._recommendedValue}set recommendedValue(e){this._recommendedValue=e}get continuePreviousLine(){return this._continuePreviousLine}set continuePreviousLine(e){this._continuePreviousLine=e}get valueRecommendationEnabled(){return this._valueRecommendationEnabled}set valueRecommendationEnabled(e){this._valueRecommendationEnabled=e}get minItems(){return null}get maxItems(){return null}}t.AbstractDynamicChildDeploymentInfo=a},4809(e,t,r){t.AbstractDynamicChildDeploymentInfoBuilder=void 0;const n=r(455),a=r(6910);class i extends a.AbstractChildDeploymentInfoBuilder{iri=null;requiredValue=!1;recommendedValue=!1;continuePreviousLine=!1;valueRecommendationEnabled=!1;constructor(e,t){super(e,t)}withIri(e){return this.iri=e,this}withRequiredValue(e){return this.requiredValue=e,this}withRecommendedValue(e){return this.recommendedValue=e,this}withContinuePreviousLine(e){return this.continuePreviousLine=e,this}withValueRecommendationEnabled(e){return this.valueRecommendationEnabled=e,this}build(){const e=new n.ChildDeploymentInfo(this.name);return this.setCommonData(e),e}setCommonData(e){super.setCommonData(e),e.iri=this.iri,e.requiredValue=this.requiredValue,e.recommendedValue=this.recommendedValue,e.continuePreviousLine=this.continuePreviousLine,e.valueRecommendationEnabled=this.valueRecommendationEnabled}}t.AbstractDynamicChildDeploymentInfoBuilder=i},455(e,t,r){t.ChildDeploymentInfo=void 0;const n=r(3812);class a extends n.AbstractDynamicChildDeploymentInfo{_multiInstance=!1;_minItems=null;_maxItems=null;_standalone=!1;static empty(){return new a("")}static standalone(){const e=new a("");return e._standalone=!0,e}constructor(e){super(e)}get multiInstance(){return this._multiInstance}set multiInstance(e){this._multiInstance=e}get minItems(){return this._minItems}set minItems(e){this._minItems=e}get maxItems(){return this._maxItems}set maxItems(e){this._maxItems=e}isMultiInAnyWay(){return this._multiInstance}isStandalone(){return this._standalone}}t.ChildDeploymentInfo=a},8878(e,t,r){t.ChildDeploymentInfoAlwaysMultiple=void 0;const n=r(9034),a=r(3812);class i extends a.AbstractDynamicChildDeploymentInfo{_declaredMinItems=null;_declaredMaxItems=null;static empty(){return new i("")}constructor(e){super(e)}isMultiInAnyWay(){return!0}set declaredMinItems(e){this._declaredMinItems=e}set declaredMaxItems(e){this._declaredMaxItems=e}get minItems(){return null!==this._declaredMinItems?this._declaredMinItems:this.uiInputType===n.UiInputType.ATTRIBUTE_VALUE?0:this.requiredValue?1:0}get maxItems(){return this._declaredMaxItems}}t.ChildDeploymentInfoAlwaysMultiple=i},3239(e,t,r){t.ChildDeploymentInfoAlwaysMultipleBuilder=void 0;const n=r(8878),a=r(4809);class i extends a.AbstractDynamicChildDeploymentInfoBuilder{declaredMinItems=null;declaredMaxItems=null;constructor(e,t){super(e,t)}withMinItems(e){return this.declaredMinItems=e,this}withMaxItems(e){return this.declaredMaxItems=e,this}build(){const e=new n.ChildDeploymentInfoAlwaysMultiple(this.name);return this.setCommonData(e),e.declaredMinItems=this.declaredMinItems,e.declaredMaxItems=this.declaredMaxItems,e}}t.ChildDeploymentInfoAlwaysMultipleBuilder=i},2266(e,t,r){t.ChildDeploymentInfoAlwaysSingle=void 0;const n=r(3812);class a extends n.AbstractDynamicChildDeploymentInfo{static empty(){return new a("")}constructor(e){super(e)}isMultiInAnyWay(){return!1}}t.ChildDeploymentInfoAlwaysSingle=a},587(e,t,r){t.ChildDeploymentInfoAlwaysSingleBuilder=void 0;const n=r(2266),a=r(4809);class i extends a.AbstractDynamicChildDeploymentInfoBuilder{constructor(e,t){super(e,t)}build(){const e=new n.ChildDeploymentInfoAlwaysSingle(this.name);return this.setCommonData(e),e}}t.ChildDeploymentInfoAlwaysSingleBuilder=i},3608(e,t,r){t.ChildDeploymentInfoBuilder=void 0;const n=r(455),a=r(4809);class i extends a.AbstractDynamicChildDeploymentInfoBuilder{multiInstance=!1;minItems=null;maxItems=null;constructor(e,t){super(e,t)}withMultiInstance(e){return this.multiInstance=e,this}withMinItems(e){return this.minItems=e,this}withMaxItems(e){return this.maxItems=e,this}build(){const e=new n.ChildDeploymentInfo(this.name);return this.setCommonData(e),e.multiInstance=this.multiInstance,e.minItems=this.minItems,e.maxItems=this.maxItems,e}}t.ChildDeploymentInfoBuilder=i},3581(e,t,r){t.ChildDeploymentInfoStatic=void 0;const n=r(513);class a extends n.AbstractChildDeploymentInfo{static empty(){return new a("")}constructor(e){super(e)}isMultiInAnyWay(){return!1}}t.ChildDeploymentInfoStatic=a},8290(e,t,r){t.ChildDeploymentInfoStaticBuilder=void 0;const n=r(6910),a=r(3581);class i extends n.AbstractChildDeploymentInfoBuilder{constructor(e,t){super(e,t)}build(){const e=new a.ChildDeploymentInfoStatic(this.name);return super.setCommonData(e),e}}t.ChildDeploymentInfoStaticBuilder=i},1492(e,t,r){t.ContainerArtifactChildrenInfo=void 0;const n=r(2763),a=r(2733),i=r(9034),s=r(3812);t.ContainerArtifactChildrenInfo=class{childNameList=[];childMap=new Map;add(e){this.childNameList.push(e.name),this.childMap.set(e.name,e)}get children(){return this.childNameList.map(e=>this.childMap.get(e))}has(e){return this.childMap.has(e)}get(e){return this.childMap.get(e)??null}getChildrenNames(){return Array.from(this.childMap.keys())}getChildrenNamesForRequiredInProperties(){const e=[];for(const[t,r]of this.childMap.entries())r.atType!==n.CedarArtifactType.STATIC_TEMPLATE_FIELD&&r.uiInputType!==i.UiInputType.ATTRIBUTE_VALUE&&e.push(t);return e}getChildrenNamesForRequired(){const e=[];for(const[t,r]of this.childMap.entries())r.atType!==n.CedarArtifactType.STATIC_TEMPLATE_FIELD&&r.uiInputType!==i.UiInputType.ATTRIBUTE_VALUE&&e.push(t);return e}getOnlyElementNamesForPropertiesContextRequired(){const e=[];for(const[t,r]of this.childMap.entries())r.atType===n.CedarArtifactType.TEMPLATE_ELEMENT&&e.push(t);return e}getPropertyLabelMap(e){const t={};return this.childNameList.forEach(e=>{const r=this.getChildInfo(e);null!==r.label&&(t[r.name]=r.label)}),t}getPropertyDescriptionMap(e){const t={};return this.childNameList.forEach(e=>{const r=this.getChildInfo(e);null!==r.description&&(t[r.name]=r.description)}),t}getChildIriMap(){const e={};return this.childNameList.forEach(t=>{const r=this.getChildInfo(t);r.atType!==n.CedarArtifactType.STATIC_TEMPLATE_FIELD&&r.uiInputType!==i.UiInputType.ATTRIBUTE_VALUE&&r instanceof s.AbstractDynamicChildDeploymentInfo&&null!==r.iri&&(e[r.name]=r.iri)}),e}getIRIMap(){const e={},t=this.getChildIriMap();return Object.keys(t).forEach(r=>{e[r]={[a.JsonSchema.enum]:[t[r]]}}),e}hasAttributeValue(){for(const e of this.childMap.values())if(e.uiInputType===i.UiInputType.ATTRIBUTE_VALUE)return!0;return!1}getChildInfo(e){return this.childMap.get(e)}}},7661(e,t,r){t.TemplateElement=void 0;const n=r(3910),a=r(8557),i=r(1027),s=r(5451),o=r(2763),l=r(3608);class c extends s.AbstractContainerArtifact{skos_altLabel=null;skos_prefLabel=null;constructor(){super(),this.cedarArtifactType=o.CedarArtifactType.TEMPLATE_ELEMENT}static buildEmptyWithNullValues(){return new c}static buildEmptyWithDefaultValues(){const e=new c;return e.schema_schemaVersion=a.SchemaVersion.CURRENT,e.bibo_status=n.BiboStatus.DRAFT,e.pav_version=i.PavVersion.DEFAULT,e}isMultiInstanceByDefinition(){return!1}isSingleInstanceByDefinition(){return!1}createDeploymentBuilder(e){return new l.ChildDeploymentInfoBuilder(this,e)}}t.TemplateElement=c},1762(e,t,r){t.TemplateElementBuilder=void 0;const n=r(1641),a=r(7661);class i extends n.AbstractArtifactBuilder{children=[];instanceTypeSpecification=null;withInstanceTypeSpecification(e){return this.instanceTypeSpecification=e,this}addChild(e,t){return this.children.push([e,t]),this}build(){const e=a.TemplateElement.buildEmptyWithNullValues();return super.buildInternal(e),e.instanceTypeSpecification=this.instanceTypeSpecification,this.children.forEach(([t,r])=>{e.addChild(t,r)}),e}}t.TemplateElementBuilder=i},7282(e,t){t.ChoiceOptionEntity=void 0,t.ChoiceOptionEntity=class{label;selectedByDefault;constructor(e,t){this.label=e,this.selectedByDefault=t}}},3557(e,t,r){t.JsonValueConstraintsWriter=void 0;const n=r(3161);class a extends n.JsonAbstractArtifactWriter{}t.JsonValueConstraintsWriter=a},9129(e,t,r){t.TemplateField=void 0;const n=r(4328),a=r(4869),i=r(8333);class s extends i.AbstractSchemaArtifact{skos_altLabel=null;skos_prefLabel=null;valueConstraints=new n.ValueConstraints;cedarFieldType=a.CedarFieldType.NULL;isMultiInstanceByDefinition(){return!1}isSingleInstanceByDefinition(){return!1}supportsValueRecommendation(){return!1}}t.TemplateField=s},3350(e,t,r){t.TemplateFieldBuilder=void 0;const n=r(1641);class a extends n.AbstractArtifactBuilder{skos_altLabel=null;skos_prefLabel=null;withAlternateLabels(e){return this.skos_altLabel=e,this}addAlternateLabel(e){return null===this.skos_altLabel&&(this.skos_altLabel=[]),this.skos_altLabel.push(e),this}withPreferredLabel(e){return this.skos_prefLabel=e,this}buildInternal(e){super.buildInternal(e),e.skos_altLabel=this.skos_altLabel,e.skos_prefLabel=this.skos_prefLabel}}t.TemplateFieldBuilder=a},855(e,t,r){t.UnknownTemplateField=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(3608);class o extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.NULL,this.cedarArtifactType=i.CedarArtifactType.NULL}static build(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoBuilder(this,e)}}t.UnknownTemplateField=o},4328(e,t){t.ValueConstraints=void 0,t.ValueConstraints=class{constructor(){}}},2500(e,t,r){t.YamlValueConstraintsWriter=void 0;const n=r(211);class a extends n.YamlAbstractArtifactWriter{}t.YamlValueConstraintsWriter=a},2052(e,t,r){t.AttributeValueFieldBuilderImpl=void 0;const n=r(3350),a=r(9571);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.AttributeValueFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.AttributeValueFieldBuilderImpl=i},9571(e,t,r){t.AttributeValueFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3239);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.ATTRIBUTE_VALUE,this.valueConstraints=new s.ValueConstraints,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}isMultiInstanceByDefinition(){return!0}createDeploymentBuilder(e){return new o.ChildDeploymentInfoAlwaysMultipleBuilder(this,e)}}t.AttributeValueFieldImpl=l},9366(e,t,r){t.JsonFieldReaderAttributeValue=void 0;const n=r(4385),a=r(9571);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.AttributeValueFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderAttributeValue=i},1442(e,t,r){t.JsonFieldWriterAttributeValue=void 0;const n=r(2748),a=r(9517),i=r(936),s=r(5793);class o extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){}expandRequiredNode(e){}expandTypeNode(e,t){e[i.CedarModel.type]=this.atomicWriter.write(s.JavascriptType.STRING)}buildValueConstraintsObject(e){return a.JsonNode.getEmpty()}}t.JsonFieldWriterAttributeValue=o},529(e,t,r){t.YamlFieldReaderAttributeValue=void 0;const n=r(5675),a=r(9571);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.AttributeValueFieldImpl.buildEmpty()}}t.YamlFieldReaderAttributeValue=i},1521(e,t,r){t.YamlFieldWriterAttributeValue=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterAttributeValue=a},4675(e,t,r){t.CheckboxFieldBuilderImpl=void 0;const n=r(3350),a=r(9915),i=r(9282);class s extends n.TemplateFieldBuilder{literals=[];constructor(){super()}static create(){return new s}addCheckboxOption(e,t=!1){return this.literals.push(new a.CheckboxOption(e,t)),this}build(){const e=i.CheckboxFieldImpl.buildEmpty();return super.buildInternal(e),e.valueConstraints.literals=this.literals,e}}t.CheckboxFieldBuilderImpl=s},9282(e,t,r){t.CheckboxFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(1489),o=r(3239);class l extends n.TemplateField{valueConstraints;constructor(){super(),this.cedarFieldType=a.CedarFieldType.CHECKBOX,this.valueConstraints=new s.ValueConstraintsCheckboxField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}isMultiInstanceByDefinition(){return!0}createDeploymentBuilder(e){return new o.ChildDeploymentInfoAlwaysMultipleBuilder(this,e)}}t.CheckboxFieldImpl=l},9915(e,t,r){t.CheckboxOption=void 0;const n=r(7282);class a extends n.ChoiceOptionEntity{constructor(e,t){super(e,t)}}t.CheckboxOption=a},19(e,t,r){t.JsonFieldReaderCheckbox=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(9915),o=r(9282);class l extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const l=o.CheckboxFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const c=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=c){const e=n.ReaderUtil.getNodeList(c,a.CedarModel.literals);null!==e&&e.forEach(e=>{const t=n.ReaderUtil.getString(e,a.CedarModel.label),r=n.ReaderUtil.getBoolean(e,a.CedarModel.selectedByDefault);if(null!=t){const e=new s.CheckboxOption(t,r);l.valueConstraints.literals.push(e)}})}return l}}t.JsonFieldReaderCheckbox=l},8663(e,t,r){t.JsonFieldWriterCheckbox=void 0;const n=r(936),a=r(2748);class i extends a.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){this.expandLiterals(t,e),super.expandValueConstraintsNode(e,t,r),e[n.CedarModel.multipleChoice]=!0}}t.JsonFieldWriterCheckbox=i},1489(e,t,r){t.ValueConstraintsCheckboxField=void 0;const n=r(4328);class a extends n.ValueConstraints{literals=[];constructor(){super()}}t.ValueConstraintsCheckboxField=a},7268(e,t,r){t.YamlFieldReaderCheckbox=void 0;const n=r(8748),a=r(9915),i=r(5675),s=r(2099),o=r(9282);class l extends i.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const l=o.CheckboxFieldImpl.buildEmpty(),c=n.ReaderUtil.getNodeList(e,s.YamlKeys.values);return null!==c&&c.forEach(e=>{const t=n.ReaderUtil.getString(e,s.YamlKeys.label),r=n.ReaderUtil.getBoolean(e,s.YamlKeys.selected);if(null!=t){const e=new a.CheckboxOption(t,r);l.valueConstraints.literals.push(e)}}),l}}t.YamlFieldReaderCheckbox=l},4500(e,t,r){t.YamlFieldWriterCheckbox=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){this.expandLiterals(t,e)}}t.YamlFieldWriterCheckbox=a},9916(e,t,r){t.ControlledTermFieldBuilderImpl=void 0;const n=r(5376),a=r(3350),i=r(6731);class s extends a.TemplateFieldBuilder{valueConstraints=new n.ValueConstraintsControlledTermField;constructor(){super()}static create(){return new s}withDefaultValue(e){return this.valueConstraints.defaultValue=e,this}addOntology(e){return this.valueConstraints.ontologies.push(e),this}addValueSet(e){return this.valueConstraints.valueSets.push(e),this}addClass(e){return this.valueConstraints.classes.push(e),this}addBranch(e){return this.valueConstraints.branches.push(e),this}addAction(e){return this.valueConstraints.actions.push(e),this}build(){const e=i.ControlledTermFieldImpl.buildEmpty();return super.buildInternal(e),e.valueConstraints=this.valueConstraints,e}}t.ControlledTermFieldBuilderImpl=s},6731(e,t,r){t.ControlledTermFieldImpl=void 0;const n=r(9129),a=r(5376),i=r(4869),s=r(2763),o=r(3608);class l extends n.TemplateField{valueConstraints;valueRecommendationEnabled=!1;constructor(){super(),this.cedarFieldType=i.CedarFieldType.CONTROLLED_TERM,this.valueConstraints=new a.ValueConstraintsControlledTermField,this.cedarArtifactType=s.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}supportsValueRecommendation(){return!0}}t.ControlledTermFieldImpl=l},8728(e,t,r){t.JsonFieldReaderControlledTerm=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(8354),o=r(2418),l=r(9184),c=r(2395),d=r(7295),u=r(2733),m=r(7432),p=r(4531),h=r(6731),f=r(5753);class T extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const s=h.ControlledTermFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const o=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);return null!=o&&(s.valueConstraints.ontologies=this.getOntologies(n.ReaderUtil.getNodeList(o,a.CedarModel.ontologies)),s.valueConstraints.classes=this.getClasses(n.ReaderUtil.getNodeList(o,a.CedarModel.classes)),s.valueConstraints.branches=this.getBranches(n.ReaderUtil.getNodeList(o,a.CedarModel.branches)),s.valueConstraints.valueSets=this.getValueSets(n.ReaderUtil.getNodeList(o,a.CedarModel.valueSets)),s.valueConstraints.defaultValue=this.getDefaultValue(n.ReaderUtil.getNodeOrNull(o,a.CedarModel.defaultValue)),s.valueConstraints.actions=this.getActions(n.ReaderUtil.getNodeList(o,a.CedarModel.actions))),s}getOntologies(e){const t=[];return e.forEach(e=>{const r=new s.ControlledTermOntology(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.acronym),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.name),n.ReaderUtil.getNumberOrNull(e,a.CedarModel.ValueConstraints.numTerms),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.uri),...T.readSourceAndVersion(e));t.push(r)}),t}getClasses(e){const t=[];return e.forEach(e=>{const r=new o.ControlledTermClass(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.label),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.source),p.BioportalTermType.forJsonValue(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.type)),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.prefLabel),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.uri),...T.readSourceAndVersion(e));t.push(r)}),t}getBranches(e){const t=[];return e.forEach(e=>{const r=new l.ControlledTermBranch(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.source),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.acronym),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.name),n.ReaderUtil.getNumberOrZero(e,a.CedarModel.ValueConstraints.maxDepth),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.uri),...T.readSourceAndVersion(e));t.push(r)}),t}getValueSets(e){const t=[];return e.forEach(e=>{const r=new c.ControlledTermValueSet(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.vsCollection),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.name),n.ReaderUtil.getNumberOrNull(e,a.CedarModel.ValueConstraints.numTerms),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.uri),...T.readSourceAndVersion(e));t.push(r)}),t}getActions(e){const t=[];return e.forEach(e=>{const r=new m.ControlledTermAction(n.ReaderUtil.getNumber(e,a.CedarModel.ValueConstraints.to),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.action),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.termUri),n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.sourceUri),n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.source),p.BioportalTermType.forJsonValue(n.ReaderUtil.getStringOrEmpty(e,a.CedarModel.ValueConstraints.type)));t.push(r)}),t}static readSourceAndVersion(e){const t=n.ReaderUtil.getURI(e,a.CedarModel.ValueConstraints.iri),r=n.ReaderUtil.getNodeOrNull(e,a.CedarModel.ValueConstraints.version),i=null===r?null:new f.ControlledTermVersion(n.ReaderUtil.getStringOrEmpty(r,a.CedarModel.ValueConstraints.versionId),n.ReaderUtil.getString(r,a.CedarModel.ValueConstraints.versionEffectiveDate),n.ReaderUtil.getString(r,a.CedarModel.ValueConstraints.versionDeclaredVersion));return[t.isEmpty()?null:t,n.ReaderUtil.getString(e,a.CedarModel.ValueConstraints.sourceSystem),i]}getDefaultValue(e){if(null==e)return null;const t=n.ReaderUtil.getURI(e,u.JsonSchema.termUri),r=n.ReaderUtil.getString(e,u.JsonSchema.rdfsLabel);return t.isEmpty()&&null===r?null:new d.ControlledTermDefaultValue(t,r??"")}}t.JsonFieldReaderControlledTerm=T},8280(e,t,r){t.JsonFieldWriterControlledTerm=void 0;const n=r(9517),a=r(936),i=r(2748),s=r(2733),o=r(9932);class l extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[s.JsonSchema.properties]=o.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[s.JsonSchema.properties]=o.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}expandValueConstraintsNode(e,t,r){const i=n.JsonNode.getEmptyList();t.valueConstraints.ontologies.forEach(e=>{i.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),e[a.CedarModel.ontologies]=i;const o=n.JsonNode.getEmptyList();t.valueConstraints.valueSets.forEach(e=>{o.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),e[a.CedarModel.valueSets]=o;const l=n.JsonNode.getEmptyList();t.valueConstraints.classes.forEach(e=>{l.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),e[a.CedarModel.classes]=l;const c=n.JsonNode.getEmptyList();t.valueConstraints.branches.forEach(e=>{c.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),e[a.CedarModel.branches]=c;const d=n.JsonNode.getEmptyList();if(t.valueConstraints.actions.forEach(e=>{d.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),d.length>0&&(e[a.CedarModel.actions]=d),null!=t.valueConstraints.defaultValue){const r=n.JsonNode.getEmpty();r[s.JsonSchema.rdfsLabel]=t.valueConstraints.defaultValue.rdfsLabel,r[s.JsonSchema.termUri]=this.atomicWriter.write(t.valueConstraints.defaultValue.termUri),e[a.CedarModel.defaultValue]=r}super.expandValueConstraintsNode(e,t,r)}}t.JsonFieldWriterControlledTerm=l},5376(e,t,r){t.ValueConstraintsControlledTermField=void 0;const n=r(4328);class a extends n.ValueConstraints{defaultValue=null;ontologies=[];valueSets=[];classes=[];branches=[];actions=[];constructor(){super()}}t.ValueConstraintsControlledTermField=a},9299(e,t,r){t.YamlFieldReaderControlledTerm=void 0;const n=r(8748),a=r(7295),i=r(4531),s=r(5675),o=r(2099),l=r(8349),c=r(5491),d=r(3091),u=r(2957),m=r(1556),p=r(7733),h=r(6731),f=r(8802),T=r(5753);class y extends s.YamlTemplateFieldTypeSpecificReader{read(e,t,r,s){const f=h.ControlledTermFieldImpl.buildEmpty();n.ReaderUtil.getNodeList(e,o.YamlKeys.values).forEach(e=>{const t=n.ReaderUtil.getString(e,o.YamlKeys.type);if(t===l.YamlValues.Controlled.ontology){const t=(new c.ControlledTermOntologyBuilder).withAcronym(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withName(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceName)).withUri(this.deriveOntologyUri(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym))).withNumTerms(n.ReaderUtil.getNumberOrNull(e,o.YamlKeys.Controlled.termCount));this.readSourceAndVersion(e,t),f.valueConstraints.ontologies.push(t.build())}else if(t===l.YamlValues.Controlled.class){const t=n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.termLabel),r=n.ReaderUtil.getString(e,o.YamlKeys.Controlled.termDisplayLabel),a=(new d.ControlledTermClassBuilder).withUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.termIri)).withSource(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withLabel(r??t).withPrefLabel(t).withType(i.BioportalTermType.forYamlValue(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.termType)));this.readSourceAndVersion(e,a),f.valueConstraints.classes.push(a.build())}else if(t===l.YamlValues.Controlled.branch){const t=(new u.ControlledTermBranchBuilder).withUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.termBaseIri)).withSource(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceName)).withName(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.termBaseLabel)).withAcronym(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withMaxDepth(n.ReaderUtil.getNumberOrZero(e,o.YamlKeys.Controlled.termMaxDepth));this.readSourceAndVersion(e,t),f.valueConstraints.branches.push(t.build())}else if(t===l.YamlValues.Controlled.valueSet){const t=(new m.ControlledTermValueSetBuilder).withUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.termBaseIri)).withNumTerms(n.ReaderUtil.getNumberOrNull(e,o.YamlKeys.Controlled.termCount)).withVsCollection(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withName(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.termBaseLabel));this.readSourceAndVersion(e,t),f.valueConstraints.valueSets.push(t.build())}});const T=n.ReaderUtil.getNodeOrNull(e,o.YamlKeys.default);if(null!==T){const e=n.ReaderUtil.getURI(T,o.YamlKeys.value),t=n.ReaderUtil.getStringOrEmpty(T,o.YamlKeys.label);f.valueConstraints.defaultValue=new a.ControlledTermDefaultValue(e,t)}return n.ReaderUtil.getNodeList(e,o.YamlKeys.actions).forEach(e=>{const t=(new p.ControlledTermActionBuilder).withAction(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.action)).withSource(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.Controlled.sourceAcronym)).withType(i.BioportalTermType.forYamlValue(n.ReaderUtil.getStringOrEmpty(e,o.YamlKeys.type))).withTermUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.termIri)).withTo(n.ReaderUtil.getNumber(e,o.YamlKeys.Controlled.to)).withSourceUri(n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.sourceIri));f.valueConstraints.actions.push(t.build())}),f}deriveOntologyUri(e){return new f.Iri(`https://data.bioontology.org/ontologies/${e}`)}readSourceAndVersion(e,t){const r=n.ReaderUtil.getURI(e,o.YamlKeys.Controlled.sourceIri);r.isEmpty()||t.withIri(r),t.withSourceSystem(n.ReaderUtil.getString(e,o.YamlKeys.Controlled.sourceSystem));const a=n.ReaderUtil.getNodeOrNull(e,o.YamlKeys.version);null!==a&&t.withVersion(new T.ControlledTermVersion(n.ReaderUtil.getStringOrEmpty(a,o.YamlKeys.Controlled.versionId),n.ReaderUtil.getString(a,o.YamlKeys.Controlled.versionEffectiveDate),n.ReaderUtil.getString(a,o.YamlKeys.Controlled.versionDeclaredVersion)))}}t.YamlFieldReaderControlledTerm=y},9535(e,t,r){t.YamlFieldWriterControlledTerm=void 0;const n=r(9517),a=r(5430),i=r(2099),s=r(4216);class o extends a.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandUINodeForYAML(e){return{[i.YamlKeys.datatype]:s.NonStandardDatatype.IRI}}expandValueConstraintsNodeForYAML(e,t,r){if(null!=t.valueConstraints.defaultValue){const r={[i.YamlKeys.value]:this.atomicWriter.write(t.valueConstraints.defaultValue.termUri),[i.YamlKeys.label]:t.valueConstraints.defaultValue.rdfsLabel};e[i.YamlKeys.default]=r}const a=n.JsonNode.getEmptyList();t.valueConstraints.ontologies.forEach(e=>{a.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),t.valueConstraints.classes.forEach(e=>{a.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),t.valueConstraints.branches.forEach(e=>{a.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),t.valueConstraints.valueSets.forEach(e=>{a.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),a.length>0&&(e[i.YamlKeys.values]=a);const s=n.JsonNode.getEmptyList();t.valueConstraints.actions.forEach(e=>{s.push(this.writers.getWriterForValueConstraint(e).getAsJsonNode(e))}),s.length>0&&(e[i.YamlKeys.actions]=s)}}t.YamlFieldWriterControlledTerm=o},1524(e,t,r){t.AbstractJsonControlledTermValueConstraintWriter=void 0;const n=r(9517),a=r(3557),i=r(936);class s extends a.JsonValueConstraintsWriter{writeSourceAndVersion(e,t){null===t.iri||t.iri.isEmpty()||(e[i.CedarModel.ValueConstraints.iri]=this.atomicWriter.write(t.iri)),null!==t.sourceSystem&&(e[i.CedarModel.ValueConstraints.sourceSystem]=t.sourceSystem);const r=t.version;if(null!==r){const t=n.JsonNode.getEmpty();t[i.CedarModel.ValueConstraints.versionId]=r.id,null!==r.effectiveDate&&(t[i.CedarModel.ValueConstraints.versionEffectiveDate]=r.effectiveDate),null!==r.declaredVersion&&(t[i.CedarModel.ValueConstraints.versionDeclaredVersion]=r.declaredVersion),e[i.CedarModel.ValueConstraints.version]=t}}}t.AbstractJsonControlledTermValueConstraintWriter=s},4339(e,t,r){t.AbstractYamlControlledTermValueConstraintWriter=void 0;const n=r(9517),a=r(2500),i=r(2099);class s extends a.YamlValueConstraintsWriter{writeSourceSystem(e,t){null!==t.sourceSystem&&(e[i.YamlKeys.Controlled.sourceSystem]=t.sourceSystem)}writeSourceIri(e,t){null===t.iri||t.iri.isEmpty()||(e[i.YamlKeys.Controlled.sourceIri]=this.atomicWriter.write(t.iri))}writeVersion(e,t){const r=t.version;if(null===r)return;const a=n.JsonNode.getEmpty();a[i.YamlKeys.Controlled.versionId]=r.id,null!==r.effectiveDate&&(a[i.YamlKeys.Controlled.versionEffectiveDate]=r.effectiveDate),null!==r.declaredVersion&&(a[i.YamlKeys.Controlled.versionDeclaredVersion]=r.declaredVersion),e[i.YamlKeys.version]=a}}t.AbstractYamlControlledTermValueConstraintWriter=s},2369(e,t,r){t.ControlledTermAbstractValueConstraint=void 0;const n=r(4328);class a extends n.ValueConstraints{className="ControlledTermAbstractValueConstraint";_iri;_sourceSystem;_version;constructor(e=null,t=null,r=null){super(),this._iri=e,this._sourceSystem=t,this._version=r}get iri(){return this._iri}get sourceSystem(){return this._sourceSystem}get version(){return this._version}}t.ControlledTermAbstractValueConstraint=a},7295(e,t){t.ControlledTermDefaultValue=void 0,t.ControlledTermDefaultValue=class{_termUri;_rdfsLabel;constructor(e,t){this._termUri=e,this._rdfsLabel=t}get termUri(){return this._termUri}get rdfsLabel(){return this._rdfsLabel}isControlledDefaultValue(){return!1}}},2480(e,t,r){t.ControlledTermDefaultValueBuilder=void 0;const n=r(8802),a=r(7295),i=r(3539);t.ControlledTermDefaultValueBuilder=class{termUri=n.Iri.empty();rdfsLabel="";withTermUri(e){return this.termUri=e,this}withRdfsLabel(e){return this.rdfsLabel=e,this}build(){return i.ValueConstraintRequirements.requireIri(this.termUri,"a term URI","A controlled-term default value"),i.ValueConstraintRequirements.requireText(this.rdfsLabel,"a label","A controlled-term default value"),new a.ControlledTermDefaultValue(this.termUri,this.rdfsLabel)}}},5753(e,t){t.ControlledTermVersion=void 0,t.ControlledTermVersion=class{_id;_effectiveDate;_declaredVersion;constructor(e,t=null,r=null){this._id=e,this._effectiveDate=t,this._declaredVersion=r}get id(){return this._id}get effectiveDate(){return this._effectiveDate}get declaredVersion(){return this._declaredVersion}}},3539(e,t){t.ValueConstraintRequirements=void 0,t.ValueConstraintRequirements=class{static requireText(e,t,r){if(null==e||""===e)throw new Error(`${r} requires ${t}.`)}static requireIri(e,t,r){if(null==e||e.isEmpty())throw new Error(`${r} requires ${t}. A constraint that points at nothing cannot be resolved.`)}static requireTermType(e,t){if(null==e||null===e.getJsonValue())throw new Error(`${t} requires a term type.`)}}},7432(e,t,r){t.ControlledTermAction=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermAction";className="ControlledTermAction";_to=null;_action;_termUri;_sourceUri;_source;_type;constructor(e,t,r,n,a,i){super(),this._to=e,this._action=t,this._termUri=r,this._sourceUri=n,this._source=a,this._type=i}get to(){return this._to}get action(){return this._action}get termUri(){return this._termUri}get sourceUri(){return this._sourceUri}get source(){return this._source}get type(){return this._type}}t.ControlledTermAction=a},7733(e,t,r){t.ControlledTermActionBuilder=void 0;const n=r(8802),a=r(7432),i=r(3539),s=r(4531);t.ControlledTermActionBuilder=class{_to=null;_action="";_termUri=n.Iri.empty();_sourceUri=n.Iri.empty();_source="";_type=s.BioportalTermType.NULL;withTo(e){return this._to=e,this}withAction(e){return this._action=e,this}withTermUri(e){return this._termUri=e,this}withSourceUri(e){return this._sourceUri=e,this}withSource(e){return this._source=e,this}withType(e){return this._type=e,this}build(){return i.ValueConstraintRequirements.requireText(this._action,"an action","A controlled-term action"),i.ValueConstraintRequirements.requireIri(this._termUri,"a term URI","A controlled-term action"),i.ValueConstraintRequirements.requireIri(this._sourceUri,"a source URI","A controlled-term action"),i.ValueConstraintRequirements.requireText(this._source,"a source","A controlled-term action"),i.ValueConstraintRequirements.requireTermType(this._type,"A controlled-term action"),new a.ControlledTermAction(this._to,this._action,this._termUri,this._sourceUri,this._source,this._type)}}},8014(e,t,r){t.JsonValueConstraintsActionWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return null!==e.to&&(t[a.CedarModel.ValueConstraints.to]=e.to),t[a.CedarModel.ValueConstraints.action]=e.action,t[a.CedarModel.ValueConstraints.termUri]=this.atomicWriter.write(e.termUri),t[a.CedarModel.ValueConstraints.sourceUri]=this.atomicWriter.write(e.sourceUri),t[a.CedarModel.ValueConstraints.source]=e.source,t[a.CedarModel.ValueConstraints.type]=this.atomicWriter.write(e.type),t}}t.JsonValueConstraintsActionWriter=s},4647(e,t,r){t.YamlValueConstraintsActionWriter=void 0;const n=r(9517),a=r(4339),i=r(2099);class s extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.action]=e.action,null!==e.to&&(t[i.YamlKeys.Controlled.to]=e.to),t[i.YamlKeys.Controlled.termIri]=this.atomicWriter.write(e.termUri),t[i.YamlKeys.Controlled.sourceIri]=this.atomicWriter.write(e.sourceUri),t[i.YamlKeys.Controlled.sourceAcronym]=e.source,t[i.YamlKeys.type]=this.atomicWriter.write(e.type),t}}t.YamlValueConstraintsActionWriter=s},9184(e,t,r){t.ControlledTermBranch=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermBranch";className="ControlledTermBranch";_source;_acronym;_name;_uri;_maxDepth=0;constructor(e,t,r,n,a,i=null,s=null,o=null){super(i,s,o),this._source=e,this._acronym=t,this._uri=a,this._name=r,this._maxDepth=n}get source(){return this._source}get acronym(){return this._acronym}get name(){return this._name}get uri(){return this._uri}get maxDepth(){return this._maxDepth}}t.ControlledTermBranch=a},2957(e,t,r){t.ControlledTermBranchBuilder=void 0;const n=r(8802),a=r(9184),i=r(3539);t.ControlledTermBranchBuilder=class{_source="";_acronym="";_name="";_uri=n.Iri.empty();_maxDepth=0;_iri=null;_sourceSystem=null;_version=null;withSource(e){return this._source=e,this}withAcronym(e){return this._acronym=e,this}withName(e){return this._name=e,this}withUri(e){return this._uri=e,this}withMaxDepth(e){return this._maxDepth=e,this}withIri(e){return this._iri=e,this}withSourceSystem(e){return this._sourceSystem=e,this}withVersion(e){return this._version=e,this}build(){return i.ValueConstraintRequirements.requireIri(this._uri,"a URI","A branch constraint"),i.ValueConstraintRequirements.requireText(this._source,"a source","A branch constraint"),i.ValueConstraintRequirements.requireText(this._acronym,"an acronym","A branch constraint"),i.ValueConstraintRequirements.requireText(this._name,"a name","A branch constraint"),new a.ControlledTermBranch(this._source,this._acronym,this._name,this._maxDepth,this._uri,this._iri,this._sourceSystem,this._version)}}},7054(e,t,r){t.JsonValueConstraintsBranchWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[a.CedarModel.ValueConstraints.uri]=this.atomicWriter.write(e.uri),t[a.CedarModel.ValueConstraints.source]=e.source,t[a.CedarModel.ValueConstraints.acronym]=e.acronym,t[a.CedarModel.ValueConstraints.name]=e.name,t[a.CedarModel.ValueConstraints.maxDepth]=e.maxDepth,this.writeSourceAndVersion(t,e),t}}t.JsonValueConstraintsBranchWriter=s},3671(e,t,r){t.YamlValueConstraintsBranchWriter=void 0;const n=r(9517),a=r(4339),i=r(2099),s=r(8349);class o extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.type]=s.YamlValues.Controlled.branch,this.writeSourceSystem(t,e),t[i.YamlKeys.Controlled.sourceAcronym]=e.acronym,t[i.YamlKeys.Controlled.sourceName]=e.source,this.writeSourceIri(t,e),t[i.YamlKeys.Controlled.termBaseIri]=this.atomicWriter.write(e.uri),t[i.YamlKeys.Controlled.termBaseLabel]=e.name,t[i.YamlKeys.Controlled.termMaxDepth]=e.maxDepth,this.writeVersion(t,e),t}}t.YamlValueConstraintsBranchWriter=o},2418(e,t,r){t.ControlledTermClass=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermClass";className="ControlledTermClass";_label;_source;_type;_prefLabel;_uri;constructor(e,t,r,n,a,i=null,s=null,o=null){super(i,s,o),this._label=e,this._source=t,this._type=r,this._prefLabel=n,this._uri=a}get label(){return this._label}get source(){return this._source}get type(){return this._type}get prefLabel(){return this._prefLabel}get uri(){return this._uri}}t.ControlledTermClass=a},3091(e,t,r){t.ControlledTermClassBuilder=void 0;const n=r(8802),a=r(2418),i=r(3539),s=r(4531);t.ControlledTermClassBuilder=class{_label="";_source="";_type=s.BioportalTermType.NULL;_prefLabel="";_uri=n.Iri.empty();_iri=null;_sourceSystem=null;_version=null;withLabel(e){return this._label=e,this}withSource(e){return this._source=e,this}withType(e){return this._type=e,this}withPrefLabel(e){return this._prefLabel=e,this}withUri(e){return this._uri=e,this}withIri(e){return this._iri=e,this}withSourceSystem(e){return this._sourceSystem=e,this}withVersion(e){return this._version=e,this}build(){return i.ValueConstraintRequirements.requireIri(this._uri,"a URI","A class constraint"),i.ValueConstraintRequirements.requireText(this._label,"a label","A class constraint"),i.ValueConstraintRequirements.requireText(this._prefLabel,"a preferred label","A class constraint"),i.ValueConstraintRequirements.requireText(this._source,"a source","A class constraint"),i.ValueConstraintRequirements.requireTermType(this._type,"A class constraint"),new a.ControlledTermClass(this._label,this._source,this._type,this._prefLabel,this._uri,this._iri,this._sourceSystem,this._version)}}},9222(e,t,r){t.JsonValueConstraintsClassWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[a.CedarModel.ValueConstraints.uri]=this.atomicWriter.write(e.uri),t[a.CedarModel.ValueConstraints.source]=e.source,t[a.CedarModel.ValueConstraints.label]=e.label,t[a.CedarModel.ValueConstraints.prefLabel]=e.prefLabel,t[a.CedarModel.ValueConstraints.type]=this.atomicWriter.write(e.type),this.writeSourceAndVersion(t,e),t}}t.JsonValueConstraintsClassWriter=s},765(e,t,r){t.YamlValueConstraintsClassWriter=void 0;const n=r(9517),a=r(4339),i=r(2099),s=r(8349);class o extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.type]=s.YamlValues.Controlled.class,this.writeSourceSystem(t,e),t[i.YamlKeys.Controlled.sourceAcronym]=e.source,this.writeSourceIri(t,e),t[i.YamlKeys.Controlled.termIri]=this.atomicWriter.write(e.uri),t[i.YamlKeys.Controlled.termType]=this.atomicWriter.write(e.type),t[i.YamlKeys.Controlled.termLabel]=e.prefLabel,e.label!==e.prefLabel&&(t[i.YamlKeys.Controlled.termDisplayLabel]=e.label),this.writeVersion(t,e),t}}t.YamlValueConstraintsClassWriter=o},8354(e,t,r){t.ControlledTermOntology=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermOntology";className="ControlledTermOntology";_acronym;_name;_uri;_numTerms=0;constructor(e,t,r,n,a=null,i=null,s=null){super(a,i,s),this._acronym=e,this._name=t,this._uri=n,this._numTerms=r}get acronym(){return this._acronym}get name(){return this._name}get uri(){return this._uri}get numTerms(){return this._numTerms}}t.ControlledTermOntology=a},5491(e,t,r){t.ControlledTermOntologyBuilder=void 0;const n=r(8802),a=r(8354),i=r(3539);t.ControlledTermOntologyBuilder=class{acronym="";name="";numTerms=null;uri=n.Iri.empty();iri=null;sourceSystem=null;version=null;withAcronym(e){return this.acronym=e,this}withName(e){return this.name=e,this}withNumTerms(e){return this.numTerms=e,this}withUri(e){return this.uri=e,this}withIri(e){return this.iri=e,this}withSourceSystem(e){return this.sourceSystem=e,this}withVersion(e){return this.version=e,this}build(){return i.ValueConstraintRequirements.requireIri(this.uri,"a URI","An ontology constraint"),i.ValueConstraintRequirements.requireText(this.acronym,"an acronym","An ontology constraint"),i.ValueConstraintRequirements.requireText(this.name,"a name","An ontology constraint"),new a.ControlledTermOntology(this.acronym,this.name,this.numTerms,this.uri,this.iri,this.sourceSystem,this.version)}}},5996(e,t,r){t.JsonValueConstraintsOntologyWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[a.CedarModel.ValueConstraints.uri]=this.atomicWriter.write(e.uri),t[a.CedarModel.ValueConstraints.acronym]=e.acronym,t[a.CedarModel.ValueConstraints.name]=e.name,null!==e.numTerms&&(t[a.CedarModel.ValueConstraints.numTerms]=e.numTerms),this.writeSourceAndVersion(t,e),t}}t.JsonValueConstraintsOntologyWriter=s},1181(e,t,r){t.YamlValueConstraintsOntologyWriter=void 0;const n=r(9517),a=r(4339),i=r(2099),s=r(8349);class o extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.type]=s.YamlValues.Controlled.ontology,this.writeSourceSystem(t,e),t[i.YamlKeys.Controlled.sourceAcronym]=e.acronym,t[i.YamlKeys.Controlled.sourceName]=e.name,this.writeSourceIri(t,e),null!==e.numTerms&&(t[i.YamlKeys.Controlled.termCount]=e.numTerms),this.writeVersion(t,e),t}}t.YamlValueConstraintsOntologyWriter=o},2395(e,t,r){t.ControlledTermValueSet=void 0;const n=r(2369);class a extends n.ControlledTermAbstractValueConstraint{static className="ControlledTermValueSet";className="ControlledTermValueSet";_vsCollection;_name;_uri;_numTerms=0;constructor(e,t,r,n,a=null,i=null,s=null){super(a,i,s),this._vsCollection=e,this._name=t,this._uri=n,this._numTerms=r}get vsCollection(){return this._vsCollection}get name(){return this._name}get uri(){return this._uri}get numTerms(){return this._numTerms}}t.ControlledTermValueSet=a},1556(e,t,r){t.ControlledTermValueSetBuilder=void 0;const n=r(8802),a=r(2395),i=r(3539);t.ControlledTermValueSetBuilder=class{_vsCollection="";_name="";_uri=n.Iri.empty();_numTerms=null;_iri=null;_sourceSystem=null;_version=null;withVsCollection(e){return this._vsCollection=e,this}withName(e){return this._name=e,this}withUri(e){return this._uri=e,this}withNumTerms(e){return this._numTerms=e,this}withIri(e){return this._iri=e,this}withSourceSystem(e){return this._sourceSystem=e,this}withVersion(e){return this._version=e,this}build(){return i.ValueConstraintRequirements.requireIri(this._uri,"a URI","A value-set constraint"),i.ValueConstraintRequirements.requireText(this._vsCollection,"a value-set collection","A value-set constraint"),i.ValueConstraintRequirements.requireText(this._name,"a name","A value-set constraint"),new a.ControlledTermValueSet(this._vsCollection,this._name,this._numTerms,this._uri,this._iri,this._sourceSystem,this._version)}}},2813(e,t,r){t.JsonValueConstraintsValueSetWriter=void 0;const n=r(9517),a=r(936),i=r(1524);class s extends i.AbstractJsonControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonString(e,t=2){return JSON.stringify(this.getAsJsonNode(e),null,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[a.CedarModel.ValueConstraints.uri]=this.atomicWriter.write(e.uri),t[a.CedarModel.ValueConstraints.vsCollection]=e.vsCollection,t[a.CedarModel.ValueConstraints.name]=e.name,null!==e.numTerms&&(t[a.CedarModel.ValueConstraints.numTerms]=e.numTerms),this.writeSourceAndVersion(t,e),t}}t.JsonValueConstraintsValueSetWriter=s},9532(e,t,r){t.YamlValueConstraintsValueSetWriter=void 0;const n=r(9517),a=r(4339),i=r(2099),s=r(8349);class o extends a.AbstractYamlControlledTermValueConstraintWriter{constructor(e,t){super(e,t)}getAsJsonNode(e){const t=n.JsonNode.getEmpty();return t[i.YamlKeys.type]=s.YamlValues.Controlled.valueSet,this.writeSourceSystem(t,e),t[i.YamlKeys.Controlled.sourceAcronym]=e.vsCollection,this.writeSourceIri(t,e),t[i.YamlKeys.Controlled.termBaseIri]=this.atomicWriter.write(e.uri),t[i.YamlKeys.Controlled.termBaseLabel]=e.name,null!==e.numTerms&&(t[i.YamlKeys.Controlled.termCount]=e.numTerms),this.writeVersion(t,e),t}}t.YamlValueConstraintsValueSetWriter=o},1667(e,t,r){t.EmailFieldBuilderImpl=void 0;const n=r(3350),a=r(4450);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.EmailFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.EmailFieldBuilderImpl=i},4450(e,t,r){t.EmailFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EMAIL,this.valueConstraints=new s.ValueConstraints,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.EmailFieldImpl=l},2691(e,t,r){t.JsonFieldReaderEmail=void 0;const n=r(4385),a=r(4450);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.EmailFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderEmail=i},9031(e,t,r){t.JsonFieldWriterEmail=void 0;const n=r(2748);class a extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.JsonFieldWriterEmail=a},3054(e,t,r){t.YamlFieldReaderEmail=void 0;const n=r(5675),a=r(4450);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.EmailFieldImpl.buildEmpty()}}t.YamlFieldReaderEmail=i},1038(e,t,r){t.YamlFieldWriterEmail=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterEmail=a},6610(e,t,r){t.ExtDoiFieldBuilderImpl=void 0;const n=r(3350),a=r(997);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtDoiFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtDoiFieldBuilderImpl=i},997(e,t,r){t.ExtDoiFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_DOI,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtDoiFieldImpl=l},8583(e,t,r){t.JsonFieldReaderExtDoi=void 0;const n=r(4385),a=r(997);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtDoiFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtDoi=i},7412(e,t,r){t.JsonFieldWriterExtDoi=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtDoi=s},5907(e,t,r){t.YamlFieldReaderExtDoi=void 0;const n=r(5675),a=r(997);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtDoiFieldImpl.buildEmpty()}}t.YamlFieldReaderExtDoi=i},6967(e,t,r){t.YamlFieldWriterExtDoi=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtDoi=a},9062(e,t,r){t.ExtNihGrantIdFieldBuilderImpl=void 0;const n=r(3350),a=r(7313);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtNihGrantIdFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtNihGrantIdFieldBuilderImpl=i},7313(e,t,r){t.ExtNihGrantIdFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_NIH_GRANT_ID,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtNihGrantIdFieldImpl=l},1886(e,t,r){t.JsonFieldReaderExtNihGrantId=void 0;const n=r(4385),a=r(7313);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtNihGrantIdFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtNihGrantId=i},5250(e,t,r){t.JsonFieldWriterExtNihGrantId=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtNihGrantId=s},8543(e,t,r){t.YamlFieldReaderExtNihGrantId=void 0;const n=r(5675),a=r(7313);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtNihGrantIdFieldImpl.buildEmpty()}}t.YamlFieldReaderExtNihGrantId=i},3711(e,t,r){t.YamlFieldWriterExtNihGrantId=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtNihGrantId=a},2376(e,t,r){t.ExtOrcidFieldBuilderImpl=void 0;const n=r(3350),a=r(5967);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtOrcidFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtOrcidFieldBuilderImpl=i},5967(e,t,r){t.ExtOrcidFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_ORCID,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtOrcidFieldImpl=l},4956(e,t,r){t.JsonFieldReaderExtOrcid=void 0;const n=r(4385),a=r(5967);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtOrcidFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtOrcid=i},8096(e,t,r){t.JsonFieldWriterExtOrcid=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtOrcid=s},7123(e,t,r){t.YamlFieldReaderExtOrcid=void 0;const n=r(5675),a=r(5967);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtOrcidFieldImpl.buildEmpty()}}t.YamlFieldReaderExtOrcid=i},4355(e,t,r){t.YamlFieldWriterExtOrcid=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtOrcid=a},3914(e,t,r){t.ExtPfasFieldBuilderImpl=void 0;const n=r(3350),a=r(6637);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtPfasFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtPfasFieldBuilderImpl=i},6637(e,t,r){t.ExtPfasFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_PFAS,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtPfasFieldImpl=l},6854(e,t,r){t.JsonFieldReaderExtPfas=void 0;const n=r(4385),a=r(6637);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtPfasFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtPfas=i},6122(e,t,r){t.JsonFieldWriterExtPfas=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtPfas=s},5075(e,t,r){t.YamlFieldReaderExtPfas=void 0;const n=r(5675),a=r(6637);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtPfasFieldImpl.buildEmpty()}}t.YamlFieldReaderExtPfas=i},5587(e,t,r){t.YamlFieldWriterExtPfas=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtPfas=a},7162(e,t,r){t.ExtPubmedFieldBuilderImpl=void 0;const n=r(3350),a=r(2685);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtPubmedFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtPubmedFieldBuilderImpl=i},2685(e,t,r){t.ExtPubmedFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_PUBMED,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtPubmedFieldImpl=l},3028(e,t,r){t.JsonFieldReaderExtPubmed=void 0;const n=r(4385),a=r(2685);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtPubmedFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtPubmed=i},3312(e,t,r){t.JsonFieldWriterExtPubmed=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtPubmed=s},7709(e,t,r){t.YamlFieldReaderExtPubmed=void 0;const n=r(5675),a=r(2685);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtPubmedFieldImpl.buildEmpty()}}t.YamlFieldReaderExtPubmed=i},6557(e,t,r){t.YamlFieldWriterExtPubmed=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtPubmed=a},7328(e,t,r){t.ExtRorFieldBuilderImpl=void 0;const n=r(3350),a=r(4007);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtRorFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtRorFieldBuilderImpl=i},4007(e,t,r){t.ExtRorFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_ROR,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtRorFieldImpl=l},8244(e,t,r){t.JsonFieldReaderExtRor=void 0;const n=r(4385),a=r(4007);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtRorFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtRor=i},7584(e,t,r){t.JsonFieldWriterExtRor=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtRor=s},6651(e,t,r){t.YamlFieldReaderExtRor=void 0;const n=r(5675),a=r(4007);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtRorFieldImpl.buildEmpty()}}t.YamlFieldReaderExtRor=i},491(e,t,r){t.YamlFieldWriterExtRor=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtRor=a},3474(e,t,r){t.ExtRridFieldBuilderImpl=void 0;const n=r(3350),a=r(789);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.ExtRridFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.ExtRridFieldBuilderImpl=i},789(e,t,r){t.ExtRridFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.EXT_RRID,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.ExtRridFieldImpl=l},7004(e,t,r){t.JsonFieldReaderExtRrid=void 0;const n=r(4385),a=r(789);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.ExtRridFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderExtRrid=i},4780(e,t,r){t.JsonFieldWriterExtRrid=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterExtRrid=s},6089(e,t,r){t.YamlFieldReaderExtRrid=void 0;const n=r(5675),a=r(789);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.ExtRridFieldImpl.buildEmpty()}}t.YamlFieldReaderExtRrid=i},4077(e,t,r){t.YamlFieldWriterExtRrid=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterExtRrid=a},7095(e,t,r){t.JsonFieldReaderLink=void 0;const n=r(4385),a=r(4084);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.LinkFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderLink=i},3691(e,t,r){t.JsonFieldWriterLink=void 0;const n=r(9932),a=r(2733),i=r(2748);class s extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){this.behavior.includeSkosNotationForLinksAndControlled()?e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI:e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION}expandRequiredNode(e){}}t.JsonFieldWriterLink=s},9497(e,t,r){t.LinkFieldBuilderImpl=void 0;const n=r(3350),a=r(4084);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.LinkFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.LinkFieldBuilderImpl=i},4084(e,t,r){t.LinkFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.LINK,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.valueConstraints=new s.ValueConstraints}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.LinkFieldImpl=l},8568(e,t,r){t.YamlFieldReaderLink=void 0;const n=r(5675),a=r(4084);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.LinkFieldImpl.buildEmpty()}}t.YamlFieldReaderLink=i},1784(e,t,r){t.YamlFieldWriterLink=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterLink=a},1513(e,t,r){t.MultipleChoiceListFieldBuilderImpl=void 0;const n=r(9513);class a extends n.ListFieldBuilderImpl{constructor(){super(),this.multipleChoice=!0}static create(){return new a}build(){return super.build()}}t.MultipleChoiceListFieldBuilderImpl=a},4932(e,t,r){t.MultipleChoiceListFieldImpl=void 0;const n=r(5316),a=r(4869),i=r(3239);class s extends n.ListFieldImpl{constructor(){super(),this.multipleChoice=!0,this.cedarFieldType=a.CedarFieldType.MULTIPLE_SELECT_LIST}static buildEmpty(){return new s}isMultiInstanceByDefinition(){return!0}createDeploymentBuilder(e){return new i.ChildDeploymentInfoAlwaysMultipleBuilder(this,e)}}t.MultipleChoiceListFieldImpl=s},7124(e,t,r){t.YamlFieldReaderMultiSelectList=void 0;const n=r(5675),a=r(4932);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const s=a.MultipleChoiceListFieldImpl.buildEmpty();return n.YamlTemplateFieldTypeSpecificReader.readAndStoreListValueConstraints(e,s),s}}t.YamlFieldReaderMultiSelectList=i},9105(e,t,r){t.SingleChoiceListFieldBuilderImpl=void 0;const n=r(9513);class a extends n.ListFieldBuilderImpl{constructor(){super(),this.multipleChoice=!1}static create(){return new a}build(){return super.build()}}t.SingleChoiceListFieldBuilderImpl=a},1676(e,t,r){t.SingleChoiceListFieldImpl=void 0;const n=r(5316),a=r(3608),i=r(4869);class s extends n.ListFieldImpl{constructor(){super(),this.multipleChoice=!1,this.cedarFieldType=i.CedarFieldType.SINGLE_SELECT_LIST}static buildEmpty(){return new s}createDeploymentBuilder(e){return new a.ChildDeploymentInfoBuilder(this,e)}}t.SingleChoiceListFieldImpl=s},2709(e,t,r){t.YamlFieldReaderSingleSelectList=void 0;const n=r(5675),a=r(1676);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const s=a.SingleChoiceListFieldImpl.buildEmpty();return n.YamlTemplateFieldTypeSpecificReader.readAndStoreListValueConstraints(e,s),s}}t.YamlFieldReaderSingleSelectList=i},2419(e,t,r){t.JsonFieldReaderList=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(4081),o=r(4932),l=r(1676);class c extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){let c=l.SingleChoiceListFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const d=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=d){n.ReaderUtil.getBoolean(d,a.CedarModel.multipleChoice)&&(c=o.MultipleChoiceListFieldImpl.buildEmpty()),c.valueConstraints.defaultValue=n.ReaderUtil.getString(d,a.CedarModel.defaultValue);const e=n.ReaderUtil.getNodeList(d,a.CedarModel.literals);null!==e&&e.forEach(e=>{const t=n.ReaderUtil.getString(e,a.CedarModel.label),r=n.ReaderUtil.getBoolean(e,a.CedarModel.selectedByDefault);if(null!=t){const e=new s.ListOption(t,r);c.valueConstraints.literals.push(e)}})}return c}}t.JsonFieldReaderList=c},7335(e,t,r){t.JsonFieldWriterList=void 0;const n=r(936),a=r(2748);class i extends a.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){null!==t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[n.CedarModel.defaultValue]=t.valueConstraints.defaultValue),this.expandLiterals(t,e),super.expandValueConstraintsNode(e,t,r),e[n.CedarModel.multipleChoice]=t.multipleChoice}}t.JsonFieldWriterList=i},9513(e,t,r){t.ListFieldBuilderImpl=void 0;const n=r(4081),a=r(3350),i=r(4932),s=r(1676);class o extends a.TemplateFieldBuilder{multipleChoice=!1;literals=[];constructor(){super()}addListOption(e,t=!1){return this.literals.push(new n.ListOption(e,t)),this}build(){let e;if(e=this.multipleChoice?i.MultipleChoiceListFieldImpl.buildEmpty():s.SingleChoiceListFieldImpl.buildEmpty(),super.buildInternal(e),!this.multipleChoice){let e=-1;for(let t=this.literals.length-1;t>=0;t--)if(this.literals[t].selectedByDefault){e=t;break}-1!==e&&this.literals.forEach((t,r)=>{t.selectedByDefault=r===e})}return e.valueConstraints.literals=this.literals,e}}t.ListFieldBuilderImpl=o},5316(e,t,r){t.ListFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(1623);class o extends n.TemplateField{valueConstraints;multipleChoice;constructor(){super(),this.cedarFieldType=a.CedarFieldType.NULL,this.valueConstraints=new s.ValueConstraintsListField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD,this.multipleChoice=!1}}t.ListFieldImpl=o},4081(e,t,r){t.ListOption=void 0;const n=r(7282);class a extends n.ChoiceOptionEntity{constructor(e,t){super(e,t)}}t.ListOption=a},1623(e,t,r){t.ValueConstraintsListField=void 0;const n=r(4328);class a extends n.ValueConstraints{defaultValue=null;literals=[];constructor(){super()}}t.ValueConstraintsListField=a},3080(e,t,r){t.YamlFieldWriterList=void 0;const n=r(5430),a=r(9499),i=r(2099);class s extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){null!==t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[i.YamlKeys.default]=t.valueConstraints.defaultValue),this.expandLiterals(t,e)}getYamlType(e){return e.multipleChoice?a.YamlArtifactType.MULTI_SELECT_LIST.getValue():a.YamlArtifactType.SINGLE_SELECT_LIST.getValue()}}t.YamlFieldWriterList=s},1769(e,t,r){t.JsonFieldReaderNumeric=void 0;const n=r(8748),a=r(936),i=r(3447),s=r(4385),o=r(4074),l=r(6444);class c extends s.JsonTemplateFieldTypeSpecificReader{read(e,t,r,s){const c=o.NumericFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const d=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=d){const e=n.ReaderUtil.getString(d,a.CedarModel.numberType);null!==e&&(c.valueConstraints.numberType=i.NumberType.forValue(e)),c.valueConstraints.minValue=n.ReaderUtil.getNumber(d,a.CedarModel.minValue),c.valueConstraints.maxValue=n.ReaderUtil.getNumber(d,a.CedarModel.maxValue),c.valueConstraints.decimalPlaces=n.ReaderUtil.getNumber(d,a.CedarModel.decimalPlace),c.valueConstraints.unitOfMeasure=n.ReaderUtil.getString(d,a.CedarModel.unitOfMeasure),c.valueConstraints.defaultValue=n.ReaderUtil.getNumericDefault(d,a.CedarModel.defaultValue),l.NumericDefaultValueValidator.assertValid(c.valueConstraints.numberType,c.valueConstraints.defaultValue,c.valueConstraints.minValue,c.valueConstraints.maxValue)}return c}}t.JsonFieldReaderNumeric=c},4841(e,t,r){t.JsonFieldWriterNumeric=void 0;const n=r(9932),a=r(2733),i=r(2748),s=r(936),o=r(6444);class l extends i.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandPropertiesNode(e){e[a.JsonSchema.properties]=n.JsonTemplateFieldContentDynamic.PROPERTIES_VERBATIM_LITERAL}expandRequiredNode(e){e[a.JsonSchema.required]=[a.JsonSchema.atValue,a.JsonSchema.atType]}expandValueConstraintsNode(e,t,r){o.NumericDefaultValueValidator.assertValid(t.valueConstraints.numberType,t.valueConstraints.defaultValue,t.valueConstraints.minValue,t.valueConstraints.maxValue),e[s.CedarModel.numberType]=this.atomicWriter.write(t.valueConstraints.numberType),null!=t.valueConstraints.minValue&&(e[s.CedarModel.minValue]=t.valueConstraints.minValue),null!=t.valueConstraints.maxValue&&(e[s.CedarModel.maxValue]=t.valueConstraints.maxValue),null!=t.valueConstraints.decimalPlaces&&(e[s.CedarModel.decimalPlace]=t.valueConstraints.decimalPlaces),null!=t.valueConstraints.unitOfMeasure&&(e[s.CedarModel.unitOfMeasure]=t.valueConstraints.unitOfMeasure),null!=t.valueConstraints.defaultValue&&(e[s.CedarModel.defaultValue]=String(t.valueConstraints.defaultValue)),super.expandValueConstraintsNode(e,t,r)}}t.JsonFieldWriterNumeric=l},6444(e,t,r){t.NumericDefaultValueValidator=void 0;const n=r(3447);t.NumericDefaultValueValidator=class{static assertValid(e,t,r=null,a=null){if(null===t)return;if(!Number.isFinite(t))throw new Error("Numeric default must be finite.");const i=e.getValue();if(null===i)throw new Error("Numeric default requires a numeric datatype.");const s={[n.NumberTypeValues.BYTE]:[-128,127],[n.NumberTypeValues.SHORT]:[-32768,32767],[n.NumberTypeValues.INT]:[-2147483648,2147483647],[n.NumberTypeValues.LONG]:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER]}[i];if(void 0!==s){if(!Number.isSafeInteger(t))throw new Error(`Numeric default ${t} must be a safely representable integer for ${i}.`);if(t<s[0]||t>s[1])throw new Error(`Numeric default ${t} is outside the ${i} range.`)}if(i===n.NumberTypeValues.FLOAT){const e=Math.abs(t);if(e>34028234663852886e22||0!==e&&e<1401298464324817e-60)throw new Error(`Numeric default ${t} is outside the ${i} range.`)}if(null!==r&&t<r)throw new Error(`Numeric default ${t} is below minValue ${r}.`);if(null!==a&&t>a)throw new Error(`Numeric default ${t} is above maxValue ${a}.`)}}},3675(e,t,r){t.NumericFieldBuilderImpl=void 0;const n=r(3350),a=r(3447),i=r(4074),s=r(6444);class o extends n.TemplateFieldBuilder{numberType=a.NumberType.DECIMAL;minValue=null;maxValue=null;decimalPlaces=null;unitOfMeasure=null;defaultValue=null;constructor(){super()}static create(){return new o}withNumberType(e){return this.numberType=e,this}withMinValue(e){return this.minValue=e,this}withMaxValue(e){return this.maxValue=e,this}withDecimalPlaces(e){return this.decimalPlaces=e,this}withUnitOfMeasure(e){return this.unitOfMeasure=e,this}withDefaultValue(e){return this.defaultValue=e,this}build(){s.NumericDefaultValueValidator.assertValid(this.numberType,this.defaultValue,this.minValue,this.maxValue);const e=i.NumericFieldImpl.buildEmpty();return super.buildInternal(e),e.valueConstraints.numberType=this.numberType,e.valueConstraints.minValue=this.minValue,e.valueConstraints.maxValue=this.maxValue,e.valueConstraints.decimalPlaces=this.decimalPlaces,e.valueConstraints.unitOfMeasure=this.unitOfMeasure,e.valueConstraints.defaultValue=this.defaultValue,e}}t.NumericFieldBuilderImpl=o},4074(e,t,r){t.NumericFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(1211),o=r(3608);class l extends n.TemplateField{valueConstraints;constructor(){super(),this.cedarFieldType=a.CedarFieldType.NUMERIC,this.valueConstraints=new s.ValueConstraintsNumericField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.NumericFieldImpl=l},1211(e,t,r){t.ValueConstraintsNumericField=void 0;const n=r(4328),a=r(3447);class i extends n.ValueConstraints{numberType=a.NumberType.DECIMAL;minValue=null;maxValue=null;decimalPlaces=null;unitOfMeasure=null;defaultValue=null;constructor(){super()}}t.ValueConstraintsNumericField=i},1872(e,t,r){t.YamlFieldReaderNumeric=void 0;const n=r(8748),a=r(3447),i=r(5675),s=r(2099),o=r(4074),l=r(6444);class c extends i.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const c=o.NumericFieldImpl.buildEmpty(),d=n.ReaderUtil.getString(e,s.YamlKeys.datatype);return null!==d&&(c.valueConstraints.numberType=a.NumberType.forValue(d)),c.valueConstraints.minValue=n.ReaderUtil.getNumber(e,s.YamlKeys.minValue),c.valueConstraints.maxValue=n.ReaderUtil.getNumber(e,s.YamlKeys.maxValue),c.valueConstraints.decimalPlaces=n.ReaderUtil.getNumber(e,s.YamlKeys.decimalPlaces),c.valueConstraints.unitOfMeasure=n.ReaderUtil.getString(e,s.YamlKeys.unit),c.valueConstraints.defaultValue=n.ReaderUtil.getNumericDefault(e,s.YamlKeys.default),l.NumericDefaultValueValidator.assertValid(c.valueConstraints.numberType,c.valueConstraints.defaultValue,c.valueConstraints.minValue,c.valueConstraints.maxValue),c}}t.YamlFieldReaderNumeric=c},3292(e,t,r){t.YamlFieldWriterNumeric=void 0;const n=r(5430),a=r(2099),i=r(6444);class s extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){i.NumericDefaultValueValidator.assertValid(t.valueConstraints.numberType,t.valueConstraints.defaultValue,t.valueConstraints.minValue,t.valueConstraints.maxValue),e[a.YamlKeys.datatype]=this.atomicWriter.write(t.valueConstraints.numberType),null!=t.valueConstraints.minValue&&(e[a.YamlKeys.minValue]=t.valueConstraints.minValue),null!=t.valueConstraints.maxValue&&(e[a.YamlKeys.maxValue]=t.valueConstraints.maxValue),null!=t.valueConstraints.decimalPlaces&&(e[a.YamlKeys.decimalPlaces]=t.valueConstraints.decimalPlaces),null!=t.valueConstraints.unitOfMeasure&&(e[a.YamlKeys.unit]=t.valueConstraints.unitOfMeasure),null!=t.valueConstraints.defaultValue&&(e[a.YamlKeys.default]=t.valueConstraints.defaultValue)}}t.YamlFieldWriterNumeric=s},1468(e,t,r){t.JsonFieldReaderPhoneNumber=void 0;const n=r(4385),a=r(7459);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const i=a.PhoneNumberFieldImpl.buildEmpty();return this.readRequiredAndHidden(e,t),i}}t.JsonFieldReaderPhoneNumber=i},6876(e,t,r){t.JsonFieldWriterPhoneNumber=void 0;const n=r(2748);class a extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.JsonFieldWriterPhoneNumber=a},8084(e,t,r){t.PhoneNumberFieldBuilderImpl=void 0;const n=r(3350),a=r(7459);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.PhoneNumberFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.PhoneNumberFieldBuilderImpl=i},7459(e,t,r){t.PhoneNumberFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(4328),o=r(3608);class l extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.PHONE_NUMBER,this.valueConstraints=new s.ValueConstraints,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}}t.PhoneNumberFieldImpl=l},4329(e,t,r){t.YamlFieldReaderPhoneNumber=void 0;const n=r(5675),a=r(7459);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.PhoneNumberFieldImpl.buildEmpty()}}t.YamlFieldReaderPhoneNumber=i},9821(e,t,r){t.YamlFieldWriterPhoneNumber=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterPhoneNumber=a},9053(e,t,r){t.JsonFieldReaderRadio=void 0;const n=r(8748),a=r(936),i=r(3315),s=r(4385),o=r(8618);class l extends s.JsonTemplateFieldTypeSpecificReader{read(e,t,r,s){const l=o.RadioFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const c=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=c){const e=n.ReaderUtil.getNodeList(c,a.CedarModel.literals);null!==e&&e.forEach(e=>{const t=n.ReaderUtil.getString(e,a.CedarModel.label),r=n.ReaderUtil.getBoolean(e,a.CedarModel.selectedByDefault);if(null!=t){const e=new i.RadioOption(t,r);l.valueConstraints.literals.push(e)}})}return l}}t.JsonFieldReaderRadio=l},9309(e,t,r){t.JsonFieldWriterRadio=void 0;const n=r(936),a=r(2748);class i extends a.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){this.expandLiterals(t,e),super.expandValueConstraintsNode(e,t,r),e[n.CedarModel.multipleChoice]=!1}}t.JsonFieldWriterRadio=i},2875(e,t,r){t.RadioFieldBuilderImpl=void 0;const n=r(3350),a=r(3315),i=r(8618);class s extends n.TemplateFieldBuilder{literals=[];constructor(){super()}static create(){return new s}addRadioOption(e,t=!1){return this.literals.push(new a.RadioOption(e,t)),this}build(){const e=i.RadioFieldImpl.buildEmpty();super.buildInternal(e);let t=-1;for(let e=this.literals.length-1;e>=0;e--)if(this.literals[e].selectedByDefault){t=e;break}return-1!==t&&this.literals.forEach((e,r)=>{e.selectedByDefault=r===t}),e.valueConstraints.literals=this.literals,e}}t.RadioFieldBuilderImpl=s},8618(e,t,r){t.RadioFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(9931),o=r(587);class l extends n.TemplateField{valueConstraints;constructor(){super(),this.cedarFieldType=a.CedarFieldType.RADIO,this.valueConstraints=new s.ValueConstraintsRadioField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}isSingleInstanceByDefinition(){return!0}createDeploymentBuilder(e){return new o.ChildDeploymentInfoAlwaysSingleBuilder(this,e)}}t.RadioFieldImpl=l},3315(e,t,r){t.RadioOption=void 0;const n=r(7282);class a extends n.ChoiceOptionEntity{constructor(e,t){super(e,t)}}t.RadioOption=a},9931(e,t,r){t.ValueConstraintsRadioField=void 0;const n=r(4328);class a extends n.ValueConstraints{literals=[];constructor(){super()}}t.ValueConstraintsRadioField=a},4284(e,t,r){t.YamlFieldReaderRadio=void 0;const n=r(8748),a=r(3315),i=r(5675),s=r(2099),o=r(8618);class l extends i.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const l=o.RadioFieldImpl.buildEmpty(),c=n.ReaderUtil.getNodeList(e,s.YamlKeys.values);return null!==c&&c.forEach(e=>{const t=n.ReaderUtil.getString(e,s.YamlKeys.label),r=n.ReaderUtil.getBoolean(e,s.YamlKeys.selected);if(null!=t){const e=new a.RadioOption(t,r);l.valueConstraints.literals.push(e)}}),l}}t.YamlFieldReaderRadio=l},8136(e,t,r){t.YamlFieldWriterRadio=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){this.expandLiterals(t,e)}}t.YamlFieldWriterRadio=a},9315(e,t,r){t.JsonFieldReaderTemporal=void 0;const n=r(8748),a=r(936),i=r(8588),s=r(3764),o=r(7974),l=r(4385),c=r(964),d=r(6342);class u extends l.JsonTemplateFieldTypeSpecificReader{read(e,t,r,l){const u=c.TemporalFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const m=n.ReaderUtil.getNode(e,a.CedarModel.ui);null!=m&&(u.temporalGranularity=o.TemporalGranularity.forValue(n.ReaderUtil.getString(m,a.CedarModel.temporalGranularity)),u.inputTimeFormat=s.TimeFormat.forValue(n.ReaderUtil.getString(m,a.CedarModel.inputTimeFormat)),u.timezoneEnabled=n.ReaderUtil.getBoolean(m,a.CedarModel.timezoneEnabled));const p=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);if(null!=p){const e=n.ReaderUtil.getString(p,a.CedarModel.temporalType);null!==e&&(u.valueConstraints.temporalType=i.TemporalType.forValue(e)),u.valueConstraints.defaultValue=n.ReaderUtil.getString(p,a.CedarModel.defaultValue),d.TemporalDefaultValueValidator.assertValid(u.valueConstraints.temporalType,u.temporalGranularity,u.valueConstraints.defaultValue)}return u}}t.JsonFieldReaderTemporal=u},5459(e,t,r){t.JsonFieldWriterTemporal=void 0;const n=r(936),a=r(3764),i=r(7974),s=r(2748),o=r(2733),l=r(6342);class c extends s.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandUINode(e,t,r){super.expandUINode(e,t,r),t.temporalGranularity!==i.TemporalGranularity.NULL&&(e[n.CedarModel.temporalGranularity]=this.atomicWriter.write(t.temporalGranularity)),i.TemporalGranularity.hasTime(t.temporalGranularity)&&(t.inputTimeFormat!==a.TimeFormat.NULL&&(e[n.CedarModel.inputTimeFormat]=this.atomicWriter.write(t.inputTimeFormat)),e[n.CedarModel.timezoneEnabled]=t.timezoneEnabled)}expandValueConstraintsNode(e,t,r){l.TemporalDefaultValueValidator.assertValid(t.valueConstraints.temporalType,t.temporalGranularity,t.valueConstraints.defaultValue),e[n.CedarModel.temporalType]=this.atomicWriter.write(t.valueConstraints.temporalType),null!=t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[n.CedarModel.defaultValue]=t.valueConstraints.defaultValue),super.expandValueConstraintsNode(e,t,r)}expandRequiredNode(e){e[o.JsonSchema.required]=[o.JsonSchema.atValue,o.JsonSchema.atType]}}t.JsonFieldWriterTemporal=c},6342(e,t,r){t.TemporalDefaultValueValidator=void 0;const n=r(7974),a=r(8588);t.TemporalDefaultValueValidator=class{static zone="(?:Z|[+-](?:(?:0\\d|1[0-3]):[0-5]\\d|14:00))?";static hour="(?:[01]\\d|2[0-3])";static minute="[0-5]\\d";static second="[0-5]\\d";static assertValid(e,t,r){if(null===r||""===r)return;const n=e.getValue();if(null===n)throw new Error("Temporal default requires a temporal datatype.");if(!this.isCompatibleGranularity(e,t))throw new Error(`Temporal datatype ${n} is not compatible with ${t.getValue()} granularity.`);const i=this.datePattern(t,n===a.TemporalType.DATE.getValue()),s=this.timePattern(t);let o;if(o=n===a.TemporalType.DATE.getValue()?i:n===a.TemporalType.TIME.getValue()?s:this.dateTimePattern(t),!o.test(r)||!this.hasValidCalendarDate(r))throw new Error(`Temporal default "${r}" is not valid for ${n}`+(null===t.getValue()?".":` at ${t.getValue()} granularity.`))}static isCompatibleGranularity(e,t){return t===n.TemporalGranularity.NULL||(e===a.TemporalType.DATE?[n.TemporalGranularity.YEAR,n.TemporalGranularity.MONTH,n.TemporalGranularity.DAY].includes(t):e===a.TemporalType.TIME?n.TemporalGranularity.valuesWithTimes().includes(t):[n.TemporalGranularity.DAY,...n.TemporalGranularity.valuesWithTimes()].includes(t))}static datePattern(e,t){return e===n.TemporalGranularity.YEAR?/^\d{4}$/:e===n.TemporalGranularity.MONTH?/^\d{4}-(?:0[1-9]|1[0-2])$/:e!==n.TemporalGranularity.DAY&&t?/^\d{4}(?:-(?:0[1-9]|1[0-2])(?:-(?:0[1-9]|[12]\d|3[01]))?)?$/:/^\d{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[12]\d|3[01])$/}static timePattern(e){const t=this.zone,r=this.hour,a=this.minute,i=this.second;return e===n.TemporalGranularity.HOUR?new RegExp(`^${r}${t}$`):e===n.TemporalGranularity.MINUTE?new RegExp(`^${r}:${a}${t}$`):e===n.TemporalGranularity.SECOND?new RegExp(`^${r}:${a}:${i}${t}$`):e===n.TemporalGranularity.DECIMAL_SECOND?new RegExp(`^${r}:${a}:${i}\\.\\d+${t}$`):new RegExp(`^${r}(?::${a}(?::${i}(?:\\.\\d+)?)?)?${t}$`)}static dateTimePattern(e){const t="\\d{4}-(?:0[1-9]|1[0-2])-(?:0[1-9]|[12]\\d|3[01])";return e===n.TemporalGranularity.HOUR||e===n.TemporalGranularity.MINUTE||e===n.TemporalGranularity.SECOND||e===n.TemporalGranularity.DECIMAL_SECOND?new RegExp(`^${t}T${this.timePatternSource(e)}$`):e===n.TemporalGranularity.YEAR||e===n.TemporalGranularity.MONTH?/a^/:e===n.TemporalGranularity.DAY?new RegExp(`^${t}$`):new RegExp(`^${t}(?:T${this.timePatternSource(n.TemporalGranularity.NULL)})?$`)}static timePatternSource(e){return this.timePattern(e).source.replace(/^\^|\$$/g,"")}static hasValidCalendarDate(e){const t=/^(\d{4})-(\d{2})-(\d{2})/.exec(e);if(null===t)return!0;const r=Number(t[1]),n=Number(t[2]);return Number(t[3])<=[31,r%4!=0||r%100==0&&r%400!=0?28:29,31,30,31,30,31,31,30,31,30,31][n-1]}}},345(e,t,r){t.TemporalFieldBuilderImpl=void 0;const n=r(3350),a=r(3764),i=r(7974),s=r(8588),o=r(964),l=r(6342);class c extends n.TemplateFieldBuilder{timezoneEnabled=!1;inputTimeFormat=a.TimeFormat.NULL;temporalGranularity=i.TemporalGranularity.NULL;temporalType=s.TemporalType.DATETIME;defaultValue=null;constructor(){super()}static create(){return new c}withTimezoneEnabled(e){return this.timezoneEnabled=e,this}withInputTimeFormat(e){return this.inputTimeFormat=e,this}withTemporalGranularity(e){return this.temporalGranularity=e,this}withTemporalType(e){return this.temporalType=e,this}withDefaultValue(e){return this.defaultValue=e,this}build(){l.TemporalDefaultValueValidator.assertValid(this.temporalType,this.temporalGranularity,this.defaultValue);const e=o.TemporalFieldImpl.buildEmpty();return super.buildInternal(e),e.timezoneEnabled=this.timezoneEnabled,e.inputTimeFormat=this.inputTimeFormat,e.temporalGranularity=this.temporalGranularity,e.valueConstraints.temporalType=this.temporalType,e.valueConstraints.defaultValue=this.defaultValue,e}}t.TemporalFieldBuilderImpl=c},964(e,t,r){t.TemporalFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(3567),o=r(3764),l=r(7974),c=r(3608);class d extends n.TemplateField{valueConstraints;timezoneEnabled=!1;inputTimeFormat=o.TimeFormat.NULL;temporalGranularity=l.TemporalGranularity.NULL;constructor(){super(),this.cedarFieldType=a.CedarFieldType.TEMPORAL,this.valueConstraints=new s.ValueConstraintsTemporalField,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new d}createDeploymentBuilder(e){return new c.ChildDeploymentInfoBuilder(this,e)}}t.TemporalFieldImpl=d},3567(e,t,r){t.ValueConstraintsTemporalField=void 0;const n=r(4328),a=r(8588);class i extends n.ValueConstraints{temporalType=a.TemporalType.DATETIME;defaultValue=null;constructor(){super()}}t.ValueConstraintsTemporalField=i},384(e,t,r){t.YamlFieldReaderTemporal=void 0;const n=r(8748),a=r(8588),i=r(3764),s=r(7974),o=r(5675),l=r(2099),c=r(964),d=r(6342);class u extends o.YamlTemplateFieldTypeSpecificReader{read(e,t,r,o){const u=c.TemporalFieldImpl.buildEmpty();u.temporalGranularity=s.TemporalGranularity.forValue(n.ReaderUtil.getString(e,l.YamlKeys.granularity)),u.inputTimeFormat=i.TimeFormat.forValue(n.ReaderUtil.getString(e,l.YamlKeys.inputTimeFormat)),u.timezoneEnabled=n.ReaderUtil.getBoolean(e,l.YamlKeys.inputTimeZone);const m=n.ReaderUtil.getString(e,l.YamlKeys.datatype);return null!==m&&(u.valueConstraints.temporalType=a.TemporalType.forValue(m)),u.valueConstraints.defaultValue=n.ReaderUtil.getString(e,l.YamlKeys.default),d.TemporalDefaultValueValidator.assertValid(u.valueConstraints.temporalType,u.temporalGranularity,u.valueConstraints.defaultValue),u}}t.YamlFieldReaderTemporal=u},7436(e,t,r){t.YamlFieldWriterTemporal=void 0;const n=r(3764),a=r(7974),i=r(5430),s=r(2099),o=r(6342);class l extends i.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){o.TemporalDefaultValueValidator.assertValid(t.valueConstraints.temporalType,t.temporalGranularity,t.valueConstraints.defaultValue),e[s.YamlKeys.datatype]=this.atomicWriter.write(t.valueConstraints.temporalType),t.temporalGranularity!==a.TemporalGranularity.NULL?(e[s.YamlKeys.granularity]=this.atomicWriter.write(t.temporalGranularity),null!=t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[s.YamlKeys.default]=t.valueConstraints.defaultValue),t.temporalGranularity!==a.TemporalGranularity.YEAR&&t.temporalGranularity!==a.TemporalGranularity.MONTH&&t.temporalGranularity!==a.TemporalGranularity.DAY&&(t.inputTimeFormat!==n.TimeFormat.NULL&&(e[s.YamlKeys.inputTimeFormat]=this.atomicWriter.write(t.inputTimeFormat)),t.timezoneEnabled&&(e[s.YamlKeys.inputTimeZone]=t.timezoneEnabled))):null!=t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[s.YamlKeys.default]=t.valueConstraints.defaultValue)}}t.YamlFieldWriterTemporal=l},9683(e,t,r){t.JsonFieldReaderTextArea=void 0;const n=r(4385),a=r(5450),i=r(8748),s=r(936);class o extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){const o=a.TextAreaImpl.buildEmpty();this.readRequiredAndHidden(e,t);const l=i.ReaderUtil.getNode(e,s.CedarModel.valueConstraints);return null!=l&&(o.valueConstraints.defaultValue=i.ReaderUtil.getString(l,s.CedarModel.defaultValue)),o}}t.JsonFieldReaderTextArea=o},275(e,t,r){t.JsonFieldWriterTextArea=void 0;const n=r(2748),a=r(936);class i extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){null!==t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[a.CedarModel.defaultValue]=t.valueConstraints.defaultValue),super.expandValueConstraintsNode(e,t,r)}}t.JsonFieldWriterTextArea=i},1259(e,t,r){t.TextAreaBuilderImpl=void 0;const n=r(3350),a=r(5450);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.TextAreaImpl.buildEmpty();return super.buildInternal(e),e}}t.TextAreaBuilderImpl=i},5450(e,t,r){t.TextAreaImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(3608),o=r(5923);class l extends n.TemplateField{valueConstraints;constructor(){super(),this.cedarFieldType=a.CedarFieldType.TEXTAREA,this.valueConstraints=new o.ValueConstraintsTextArea,this.cedarArtifactType=i.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new s.ChildDeploymentInfoBuilder(this,e)}}t.TextAreaImpl=l},5923(e,t,r){t.ValueConstraintsTextArea=void 0;const n=r(4328);class a extends n.ValueConstraints{defaultValue=null;constructor(){super()}}t.ValueConstraintsTextArea=a},3168(e,t,r){t.YamlFieldReaderTextArea=void 0;const n=r(5675),a=r(5450);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.TextAreaImpl.buildEmpty()}}t.YamlFieldReaderTextArea=i},836(e,t,r){t.YamlFieldWriterTextArea=void 0;const n=r(5430);class a extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}}t.YamlFieldWriterTextArea=a},9241(e,t,r){t.JsonFieldReaderTextField=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(8972);class o extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.TextFieldImpl.buildEmpty();this.readRequiredAndHidden(e,t);const l=n.ReaderUtil.getNode(e,a.CedarModel.valueConstraints);return null!=l&&(o.valueConstraints.defaultValue=n.ReaderUtil.getString(l,a.CedarModel.defaultValue),o.valueConstraints.minLength=n.ReaderUtil.getNumber(l,a.CedarModel.minLength),o.valueConstraints.maxLength=n.ReaderUtil.getNumber(l,a.CedarModel.maxLength),o.valueConstraints.regex=n.ReaderUtil.getString(l,a.CedarModel.regex)),o}}t.JsonFieldReaderTextField=o},7501(e,t,r){t.JsonFieldWriterTextField=void 0;const n=r(936),a=r(2748);class i extends a.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNode(e,t,r){null!==t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[n.CedarModel.defaultValue]=t.valueConstraints.defaultValue),null!==t.valueConstraints.minLength&&(e[n.CedarModel.minLength]=t.valueConstraints.minLength),null!==t.valueConstraints.maxLength&&(e[n.CedarModel.maxLength]=t.valueConstraints.maxLength),super.expandValueConstraintsNode(e,t,r),null!==t.valueConstraints.regex&&(e[n.CedarModel.regex]=t.valueConstraints.regex)}}t.JsonFieldWriterTextField=i},7889(e,t,r){t.TextFieldBuilderImpl=void 0;const n=r(3350),a=r(8972);class i extends n.TemplateFieldBuilder{defaultValue=null;minLength=null;maxLength=null;regex=null;constructor(){super()}static create(){return new i}withDefaultValue(e){return this.defaultValue=e,this}withMinLength(e){return this.minLength=e,this}withMaxLength(e){return this.maxLength=e,this}withRegex(e){return this.regex=e,this}build(){const e=a.TextFieldImpl.buildEmpty();return super.buildInternal(e),e.valueConstraints.defaultValue=this.defaultValue,e.valueConstraints.minLength=this.minLength,e.valueConstraints.maxLength=this.maxLength,e.valueConstraints.regex=this.regex,e}}t.TextFieldBuilderImpl=i},8972(e,t,r){t.TextFieldImpl=void 0;const n=r(9129),a=r(9711),i=r(4869),s=r(2763),o=r(3608);class l extends n.TemplateField{valueConstraints;valueRecommendationEnabled=!1;constructor(){super(),this.cedarFieldType=i.CedarFieldType.TEXT,this.valueConstraints=new a.ValueConstraintsTextField,this.cedarArtifactType=s.CedarArtifactType.TEMPLATE_FIELD}static buildEmpty(){return new l}createDeploymentBuilder(e){return new o.ChildDeploymentInfoBuilder(this,e)}supportsValueRecommendation(){return!0}}t.TextFieldImpl=l},9711(e,t,r){t.ValueConstraintsTextField=void 0;const n=r(4328);class a extends n.ValueConstraints{defaultValue=null;minLength=null;maxLength=null;regex=null;constructor(){super()}}t.ValueConstraintsTextField=a},1268(e,t,r){t.YamlFieldReaderTextField=void 0;const n=r(8748),a=r(5675),i=r(2099),s=r(8972);class o extends a.YamlTemplateFieldTypeSpecificReader{read(e,t,r,a){const o=s.TextFieldImpl.buildEmpty();return o.valueConstraints.defaultValue=n.ReaderUtil.getString(e,i.YamlKeys.default),o.valueConstraints.minLength=n.ReaderUtil.getNumber(e,i.YamlKeys.minLength),o.valueConstraints.maxLength=n.ReaderUtil.getNumber(e,i.YamlKeys.maxLength),o.valueConstraints.regex=n.ReaderUtil.getString(e,i.YamlKeys.regex),o}}t.YamlFieldReaderTextField=o},6116(e,t,r){t.YamlFieldWriterTextField=void 0;const n=r(5430),a=r(2099);class i extends n.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandValueConstraintsNodeForYAML(e,t,r){null!=t.valueConstraints.defaultValue&&""!==t.valueConstraints.defaultValue&&(e[a.YamlKeys.default]=t.valueConstraints.defaultValue),null!=t.valueConstraints.minLength&&(e[a.YamlKeys.minLength]=t.valueConstraints.minLength),null!=t.valueConstraints.maxLength&&(e[a.YamlKeys.maxLength]=t.valueConstraints.maxLength),null!=t.valueConstraints.regex&&(e[a.YamlKeys.regex]=t.valueConstraints.regex)}}t.YamlFieldWriterTextField=i},8053(e,t,r){t.JsonStaticFieldWriter=void 0;const n=r(2748),a=r(2733),i=r(9251),s=r(936),o=r(5793),l=r(5747),c=r(3746),d=r(2475);class u extends n.JsonTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandUiNode(e,t){}buildUIObject(e){const t={[s.CedarModel.inputType]:this.atomicWriter.write(e.cedarFieldType.getUiInputType())};return this.expandUiNode(t,e),s.CedarModel.content in t||(t[s.CedarModel.content]=null),{[s.CedarModel.ui]:t}}getAsJsonNode(e){const t=this.buildUIObject(e);return{[a.JsonSchema.atId]:this.atomicWriter.write(e.at_id),[a.JsonSchema.atType]:this.atomicWriter.write(e.cedarArtifactType),[a.JsonSchema.atContext]:this.macroContext(e),[s.CedarModel.type]:this.atomicWriter.write(o.JavascriptType.OBJECT),[l.TemplateProperty.title]:e.title,[l.TemplateProperty.description]:e.description,...t,...this.macroSchemaNameAndDescription(e),...this.macroProvenance(e,this.atomicWriter),...this.macroSkos(e),[a.JsonSchema.schemaVersion]:this.atomicWriter.write(e.schema_schemaVersion),[l.TemplateProperty.additionalProperties]:this.atomicWriter.write(c.AdditionalProperties.FALSE),...this.macroStatusAndVersion(e,this.atomicWriter),[s.CedarModel.schema]:this.atomicWriter.write(d.ArtifactSchema.CURRENT)}}macroContext(e){return i.JsonTemplateFieldContentStatic.CONTEXT_VERBATIM}}t.JsonStaticFieldWriter=u},699(e,t){t.isSizedStaticField=function(e){return null!==e&&"width"in e&&"height"in e}},934(e,t,r){t.YamlStaticFieldWriter=void 0;const n=r(9517),a=r(5430),i=r(455);class s extends a.YamlTemplateFieldWriterInternal{constructor(e,t){super(e,t)}expandUINodeForYAML(e){return super.expandUINodeForYAML(e)}expandSizeForYAML(e){return n.JsonNode.getEmpty()}buildUIObject(e){return this.expandUINodeForYAML(e)}getYamlAsJsonNode(e,t=i.ChildDeploymentInfo.empty(),r=!1,a=!0){return{...this.macroType(e),...this.macroNameAndDescription(e),...this.macroSchemaIdentifier(e),...this.macroId(e,r,a),...this.macroStatusAndVersion(e,r),...this.macroSkos(e),...this.expandUINodeForYAML(e),...t.hasParent()?n.JsonNode.getEmpty():this.expandSizeForYAML(e),...this.macroProvenance(e,r),...this.macroDerivedFrom(e,r),...this.macroPreviousVersion(e,r),...this.macroAnnotations(e)}}}t.YamlStaticFieldWriter=s},9148(e,t,r){t.JsonFieldReaderImage=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(5573);class o extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.StaticImageFieldImpl.buildEmpty(),l=n.ReaderUtil.getNode(e,a.CedarModel.ui);o.content=n.ReaderUtil.getString(l,a.CedarModel.content);const c=n.ReaderUtil.getNode(l,a.CedarModel.size);return o.width=n.ReaderUtil.getNumber(c,a.CedarModel.width),o.height=n.ReaderUtil.getNumber(c,a.CedarModel.height),o}}t.JsonFieldReaderImage=o},8970(e,t,r){t.JsonFieldWriterStaticImage=void 0;const n=r(9517),a=r(936),i=r(8053);class s extends i.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){if(null!==t.content&&(e[a.CedarModel.content]=t.content),null!==t.width||null!==t.height){const r=n.JsonNode.getEmpty();null!==t.width&&(r[a.CedarModel.width]=t.width),null!==t.height&&(r[a.CedarModel.height]=t.height),e[a.CedarModel.size]=r}}}t.JsonFieldWriterStaticImage=s},3138(e,t,r){t.StaticImageFieldBuilderImpl=void 0;const n=r(3350),a=r(5573);class i extends n.TemplateFieldBuilder{content=null;width=null;height=null;constructor(){super()}static create(){return new i}withContent(e){return this.content=e,this}withWidth(e){return this.width=e,this}withHeight(e){return this.height=e,this}build(){const e=a.StaticImageFieldImpl.buildEmpty();return super.buildInternal(e),e.content=this.content,e.width=this.width,e.height=this.height,e}}t.StaticImageFieldBuilderImpl=i},5573(e,t,r){t.StaticImageFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{content=null;width=null;height=null;constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_IMAGE,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticImageFieldImpl=o},7941(e,t,r){t.YamlFieldReaderImage=void 0;const n=r(8748),a=r(2099),i=r(5675),s=r(5573);class o extends i.YamlTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.StaticImageFieldImpl.buildEmpty();return o.content=n.ReaderUtil.getString(e,a.YamlKeys.content),o.width=n.ReaderUtil.getNumber(e,a.YamlKeys.width),o.height=n.ReaderUtil.getNumber(e,a.YamlKeys.height),o}}t.YamlFieldReaderImage=o},4935(e,t,r){t.YamlFieldWriterStaticImage=void 0;const n=r(9517),a=r(934),i=r(2099);class s extends a.YamlStaticFieldWriter{constructor(e,t){super(e,t)}expandUINodeForYAML(e){const t=n.JsonNode.getEmpty();return null!==e.content&&(t[i.YamlKeys.content]=e.content),t}expandSizeForYAML(e){const t=n.JsonNode.getEmpty();return null!==e.width&&(t[i.YamlKeys.width]=e.width),null!==e.height&&(t[i.YamlKeys.height]=e.height),t}}t.YamlFieldWriterStaticImage=s},5933(e,t,r){t.JsonFieldReaderPageBreak=void 0;const n=r(4385),a=r(9046);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.StaticPageBreakFieldImpl.buildEmpty()}}t.JsonFieldReaderPageBreak=i},2347(e,t,r){t.JsonFieldWriterStaticPageBreak=void 0;const n=r(8053);class a extends n.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){}}t.JsonFieldWriterStaticPageBreak=a},2703(e,t,r){t.StaticPageBreakFieldBuilderImpl=void 0;const n=r(3350),a=r(9046);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.StaticPageBreakFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.StaticPageBreakFieldBuilderImpl=i},9046(e,t,r){t.StaticPageBreakFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_PAGE_BREAK,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticPageBreakFieldImpl=o},4568(e,t,r){t.YamlFieldReaderPageBreak=void 0;const n=r(5675),a=r(9046);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.StaticPageBreakFieldImpl.buildEmpty()}}t.YamlFieldReaderPageBreak=i},7594(e,t,r){t.YamlFieldWriterStaticPageBreak=void 0;const n=r(934);class a extends n.YamlStaticFieldWriter{constructor(e,t){super(e,t)}}t.YamlFieldWriterStaticPageBreak=a},6291(e,t,r){t.JsonFieldReaderRichText=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(5548);class o extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.StaticRichTextFieldImpl.buildEmpty(),l=n.ReaderUtil.getNode(e,a.CedarModel.ui);return o.content=n.ReaderUtil.getString(l,a.CedarModel.content),o}}t.JsonFieldReaderRichText=o},6029(e,t,r){t.JsonFieldWriterStaticRichText=void 0;const n=r(936),a=r(8053);class i extends a.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){null!==t.content&&(e[n.CedarModel.content]=t.content)}}t.JsonFieldWriterStaticRichText=i},9521(e,t,r){t.StaticRichTextFieldBuilderImpl=void 0;const n=r(3350),a=r(5548);class i extends n.TemplateFieldBuilder{content=null;constructor(){super()}static create(){return new i}withContent(e){return this.content=e,this}build(){const e=a.StaticRichTextFieldImpl.buildEmpty();return super.buildInternal(e),e.content=this.content,e}}t.StaticRichTextFieldBuilderImpl=i},5548(e,t,r){t.StaticRichTextFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{content=null;constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_RICH_TEXT,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticRichTextFieldImpl=o},1404(e,t,r){t.YamlFieldReaderRichText=void 0;const n=r(8748),a=r(5675),i=r(2099),s=r(5548);class o extends a.YamlTemplateFieldTypeSpecificReader{read(e,t,r,a){const o=s.StaticRichTextFieldImpl.buildEmpty();return o.content=n.ReaderUtil.getString(e,i.YamlKeys.content),o}}t.YamlFieldReaderRichText=o},6314(e,t,r){t.YamlFieldWriterStaticRichText=void 0;const n=r(9517),a=r(934),i=r(2099);class s extends a.YamlStaticFieldWriter{constructor(e,t){super(e,t)}expandUINodeForYAML(e){return null!==e.content?{[i.YamlKeys.content]:e.content}:n.JsonNode.getEmpty()}}t.YamlFieldWriterStaticRichText=s},6511(e,t,r){t.JsonFieldReaderSectionBreak=void 0;const n=r(4385),a=r(2546);class i extends n.JsonTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.StaticSectionBreakFieldImpl.buildEmpty()}}t.JsonFieldReaderSectionBreak=i},41(e,t,r){t.JsonFieldWriterStaticSectionsBreak=void 0;const n=r(8053);class a extends n.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){}}t.JsonFieldWriterStaticSectionsBreak=a},5795(e,t,r){t.StaticSectionBreakFieldBuilderImpl=void 0;const n=r(3350),a=r(2546);class i extends n.TemplateFieldBuilder{constructor(){super()}static create(){return new i}build(){const e=a.StaticSectionBreakFieldImpl.buildEmpty();return super.buildInternal(e),e}}t.StaticSectionBreakFieldBuilderImpl=i},2546(e,t,r){t.StaticSectionBreakFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_SECTION_BREAK,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticSectionBreakFieldImpl=o},3980(e,t,r){t.YamlFieldReaderSectionBreak=void 0;const n=r(5675),a=r(2546);class i extends n.YamlTemplateFieldTypeSpecificReader{read(e,t,r,n){return a.StaticSectionBreakFieldImpl.buildEmpty()}}t.YamlFieldReaderSectionBreak=i},6082(e,t,r){t.YAMLFieldWriterStaticSectionsBreak=void 0;const n=r(934);class a extends n.YamlStaticFieldWriter{constructor(e,t){super(e,t)}}t.YAMLFieldWriterStaticSectionsBreak=a},8596(e,t,r){t.JsonFieldReaderYoutube=void 0;const n=r(8748),a=r(936),i=r(4385),s=r(477);class o extends i.JsonTemplateFieldTypeSpecificReader{read(e,t,r,i){const o=s.StaticYoutubeFieldImpl.buildEmpty(),l=n.ReaderUtil.getNode(e,a.CedarModel.ui);o.videoId=n.ReaderUtil.getString(l,a.CedarModel.content);const c=n.ReaderUtil.getNode(l,a.CedarModel.size);return o.width=n.ReaderUtil.getNumber(c,a.CedarModel.width),o.height=n.ReaderUtil.getNumber(c,a.CedarModel.height),o}}t.JsonFieldReaderYoutube=o},6766(e,t,r){t.JsonFieldWriterStaticYoutube=void 0;const n=r(9517),a=r(936),i=r(8053);class s extends i.JsonStaticFieldWriter{constructor(e,t){super(e,t)}expandUiNode(e,t){if(null!==t.videoId&&(e[a.CedarModel.content]=t.videoId),null!==t.width||null!==t.height){const r=n.JsonNode.getEmpty();null!==t.width&&(r[a.CedarModel.width]=t.width),null!==t.height&&(r[a.CedarModel.height]=t.height),e[a.CedarModel.size]=r}}}t.JsonFieldWriterStaticYoutube=s},7674(e,t,r){t.StaticYoutubeFieldBuilderImpl=void 0;const n=r(3350),a=r(477);class i extends n.TemplateFieldBuilder{videoId=null;width=null;height=null;constructor(){super()}static create(){return new i}withVideoId(e){return this.videoId=e,this}withWidth(e){return this.width=e,this}withHeight(e){return this.height=e,this}build(){const e=a.StaticYoutubeFieldImpl.buildEmpty();return super.buildInternal(e),e.videoId=this.videoId,e.width=this.width,e.height=this.height,e}}t.StaticYoutubeFieldBuilderImpl=i},477(e,t,r){t.StaticYoutubeFieldImpl=void 0;const n=r(9129),a=r(4869),i=r(2763),s=r(8290);class o extends n.TemplateField{videoId=null;width=null;height=null;constructor(){super(),this.cedarFieldType=a.CedarFieldType.STATIC_YOUTUBE,this.cedarArtifactType=i.CedarArtifactType.STATIC_TEMPLATE_FIELD}static buildEmpty(){return new o}createDeploymentBuilder(e){return new s.ChildDeploymentInfoStaticBuilder(this,e)}}t.StaticYoutubeFieldImpl=o},7089(e,t,r){t.YamlFieldReaderYoutube=void 0;const n=r(8748),a=r(5675),i=r(2099),s=r(477);class o extends a.YamlTemplateFieldTypeSpecificReader{read(e,t,r,a){const o=s.StaticYoutubeFieldImpl.buildEmpty();return o.videoId=n.ReaderUtil.getString(e,i.YamlKeys.content),o.width=n.ReaderUtil.getNumber(e,i.YamlKeys.width),o.height=n.ReaderUtil.getNumber(e,i.YamlKeys.height),o}}t.YamlFieldReaderYoutube=o},1903(e,t,r){t.YamlFieldWriterStaticYoutube=void 0;const n=r(9517),a=r(934),i=r(2099);class s extends a.YamlStaticFieldWriter{constructor(e,t){super(e,t)}expandUINodeForYAML(e){const t=n.JsonNode.getEmpty();return null!==e.videoId&&(t[i.YamlKeys.content]=e.videoId),t}expandSizeForYAML(e){const t=n.JsonNode.getEmpty();return null!==e.width&&(t[i.YamlKeys.width]=e.width),null!==e.height&&(t[i.YamlKeys.height]=e.height),t}}t.YamlFieldWriterStaticYoutube=s},4033(e,t,r){t.AttributeValueNamePolicy=void 0;const n=r(936),a=r(2733),i=r(9327),s=r(3644),o=r(7723);class l{static RESERVED_NAMES=new Set([a.JsonSchema.atContext,a.JsonSchema.atId,a.JsonSchema.atType,a.JsonSchema.atValue,a.JsonSchema.atLanguage,a.JsonSchema.schemaIsBasedOn,a.JsonSchema.schemaName,a.JsonSchema.schemaDescription,a.JsonSchema.pavDerivedFrom,a.JsonSchema.pavCreatedOn,a.JsonSchema.pavCreatedBy,a.JsonSchema.pavLastUpdatedOn,a.JsonSchema.oslcModifiedBy,a.JsonSchema.rdfsLabel,n.CedarModel.skosPrefLabel,n.CedarModel.skosAltLabel,n.CedarModel.skosNotation,n.CedarModel.annotations]);constructor(){}static isReserved(e){return e.startsWith("@")||l.RESERVED_NAMES.has(e)}static findConflicts(e){const t=[];return l.scanContainer(e,[],t),t}static assertValid(e){const t=l.findConflicts(e)[0];if(void 0===t)return;const r=[...t.path,t.groupName,t.name].join("/"),n="reserved"===t.kind?"is reserved for instance metadata":"sibling"===t.kind?"collides with another child in the same object":`is also used by attribute-value field "${t.conflictingGroupName}"`;throw new Error(`Attribute-value name "${t.name}" at /${r} ${n}`)}static scanContainer(e,t,r){const n=l.attributeValueGroups(e),a=new Set(n.map(e=>e.name)),i=new Set(n.filter(e=>e.unpacked).flatMap(e=>e.attributeNames)),s=new Set(Object.keys(e.values).filter(e=>!a.has(e)&&!i.has(e))),o=new Map;for(const e of n){const n=new Set;for(const i of e.attributeNames){if(0===i.length)continue;l.isReserved(i)&&r.push({kind:"reserved",name:i,groupName:e.name,path:t}),(s.has(i)||a.has(i))&&r.push({kind:"sibling",name:i,groupName:e.name,path:t}),n.has(i)?r.push({kind:"duplicate",name:i,groupName:e.name,path:t,conflictingGroupName:e.name}):n.add(i);const c=o.get(i);void 0!==c&&c!==e.name?r.push({kind:"duplicate",name:i,groupName:e.name,path:t,conflictingGroupName:c}):o.set(i,e.name)}}for(const[n,s]of Object.entries(e.values))a.has(n)||i.has(n)||l.scanValue(s,[...t,n],r)}static scanValue(e,t,r){e instanceof o.InstanceDataContainer?l.scanContainer(e,t,r):Array.isArray(e)&&e.forEach((e,n)=>l.scanValue(e,[...t,n],r))}static attributeValueGroups(e){const t=[];for(const[r,n]of Object.entries(e.values))if(n instanceof i.InstanceDataAttributeValueField)t.push({name:r,attributeNames:Object.keys(n.values),unpacked:!1});else if(Array.isArray(n)){const e=n.filter(e=>e instanceof s.InstanceDataAttributeValueFieldName).map(e=>e.name);e.length>0&&t.push({name:r,attributeNames:e,unpacked:!0})}return t}}t.AttributeValueNamePolicy=l},9327(e,t){t.InstanceDataAttributeValueField=void 0,t.InstanceDataAttributeValueField=class{_name;_values={};_iris;constructor(e){this._name=e,this._values={},this._iris={}}addValue(e,t){this._values[e]=t}get name(){return this._name}get values(){return this._values}setIri(e,t){this._iris[e]=t}get iris(){return this._iris}}},3644(e,t){t.InstanceDataAttributeValueFieldName=void 0,t.InstanceDataAttributeValueFieldName=class{_name;constructor(e){this._name=e}get name(){return this._name}}},7723(e,t){t.InstanceDataContainer=void 0,t.InstanceDataContainer=class{_id=null;_values;_iris;constructor(){this._values={},this._iris={}}setValue(e,t){this._values[e]=t}hasValue(e){return Object.hasOwn(this._values,e)}removeValue(e){delete this._values[e],delete this._iris[e]}get values(){return this._values}set values(e){this._values=e}setIri(e,t){this._iris[e]=t}hasIri(e){return Object.hasOwn(this._iris,e)}removeIri(e){delete this._iris[e]}get iris(){return this._iris}set id(e){this._id=e}get id(){return this._id}}},8193(e,t,r){t.InstanceDataControlledAtom=void 0;const n=r(7571);class a{_id;_label;constructor(e,t,r){if(r!==n.PARSED_NODE&&((0,n.assertIri)(e,"InstanceDataControlledAtom"),null==t||""===t))throw new Error("InstanceDataControlledAtom requires a label. An IRI on its own is a link, not a controlled term.");this._id=e,this._label=t}static fromParsedNode(e,t){return new a(e,t,n.PARSED_NODE)}get id(){return this._id}get label(){return this._label}}t.InstanceDataControlledAtom=a},7548(e,t){t.InstanceDataEmptyAtom=void 0,t.InstanceDataEmptyAtom=class{_discarded;constructor(e=null){this._discarded=e}get discarded(){return this._discarded}hasDiscardedContent(){return null!==this._discarded&&Object.keys(this._discarded).length>0}}},4465(e,t){t.InstanceDataEmptyNode=void 0,t.InstanceDataEmptyNode=class{}},7571(e,t){function r(e,t){if(null==e||""===e)throw new Error(`${t} requires an IRI. An IRI-valued field with nothing in it is an empty node, not a null IRI.`)}t.InstanceDataLinkAtom=t.PARSED_NODE=void 0,t.assertIri=r,t.PARSED_NODE=Symbol("parsed node");class n{_id;constructor(e,n){n!==t.PARSED_NODE&&r(e,"InstanceDataLinkAtom"),this._id=e}static fromParsedNode(e){return new n(e,t.PARSED_NODE)}get id(){return this._id}}t.InstanceDataLinkAtom=n},5222(e,t){t.InstanceDataStringAtom=void 0,t.InstanceDataStringAtom=class{_value;constructor(e){this._value=e}get value(){return this._value}}},4877(e,t){t.InstanceDataTypedAtom=void 0,t.InstanceDataTypedAtom=class{_value;_type;constructor(e,t){if(null==t||""===t)throw new Error("InstanceDataTypedAtom requires a type. A literal with no declared type is an InstanceDataStringAtom.");this._value=e,this._type=t}get value(){return this._value}get type(){return this._type}}},9961(e,t,r){t.InstanceInflater=void 0;const n=r(7723),a=r(4465),i=r(2763),s=r(4869),o=r(7661),l=r(9129);class c{constructor(){}static inflate(e,t){return c.inflateContainer(e.dataContainer,t),e}static inflateContainer(e,t){const r=t.getChildrenInfo(),d=r.getChildIriMap();Object.keys(d).forEach(t=>e.setIri(t,d[t]));const u={};r.getChildrenNames().forEach(r=>{const d=t.getChild(r);let m=e.values[r];if(void 0===m){if(t.getChildInfo(r)?.atType===i.CedarArtifactType.STATIC_TEMPLATE_FIELD)return;m=d instanceof l.TemplateField&&d.cedarFieldType===s.CedarFieldType.ATTRIBUTE_VALUE?[]:new a.InstanceDataEmptyNode}d instanceof o.TemplateElement&&(m instanceof n.InstanceDataContainer?c.inflateContainer(m,d):Array.isArray(m)&&m.forEach(e=>{e instanceof n.InstanceDataContainer&&c.inflateContainer(e,d)})),u[r]=m}),Object.keys(e.values).forEach(t=>{Object.hasOwn(u,t)||(u[t]=e.values[t])}),e.values=u}}t.InstanceInflater=c},8410(e,t,r){t.InstanceValidator=void 0;const n=r(7723),a=r(7548),i=r(4465),s=r(5222),o=r(4877),l=r(7571),c=r(8193),d=r(3812),u=r(7661),m=r(964),p=r(4074),h=r(4036),f=r(2888),T=r(9760),y=r(3188),E=r(2733),C=r(9034),g=r(9327),I=r(3644),A=r(4033),b=r(2763),R="InstanceValidator";class S{constructor(){}static validate(e,t){const r=new h.JsonArtifactParsingResult;return S.validateContainer(e.dataContainer,t,new y.JsonPath,r),r}static validateContainer(e,t,r,n){const a=t.getChildrenInfo();for(const t of A.AttributeValueNamePolicy.findConflicts(e).filter(e=>0===e.path.length))n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,r.add(t.groupName,t.name),"a unique, non-reserved attribute-value name",t.name));for(const[t,i]of S.attributeValueGroups(e))for(const e of i){const i=a.get(e);null!==i&&i.atType!==b.CedarArtifactType.STATIC_TEMPLATE_FIELD&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,r.add(t,e),"a name different from every serializable template child",e))}for(const t of a.getChildrenNamesForRequiredInProperties())Object.hasOwn(e.values,t)||n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,r.add(t),t));for(const i of a.getChildrenNames()){const s=a.get(i);if(s?.uiInputType===C.UiInputType.ATTRIBUTE_VALUE)continue;const o=e.values[i];void 0!==o&&S.validateChild(i,o,s,t.getChild(i),r.add(i),n)}}static attributeValueGroups(e){const t=[];for(const[r,n]of Object.entries(e.values))if(n instanceof g.InstanceDataAttributeValueField)t.push([r,Object.keys(n.values)]);else if(Array.isArray(n)){const e=n.filter(e=>e instanceof I.InstanceDataAttributeValueFieldName).map(e=>e.name??"").filter(e=>e.length>0);e.length>0&&t.push([r,e])}return t}static validateChild(e,t,r,n,a,i){const s=r?.isMultiInAnyWay()??!1,o=Array.isArray(t)?t:null,l=null!==o;if(s===l)return null!==o?(S.validateCardinality(o,r,a,i),void o.forEach((e,t)=>S.validateItem(e,n,a.add(t),i))):void S.validateItem(t,n,a,i);i.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,a,s?"a list of values":"a single value",l?"a list of values":"a single value"))}static validateCardinality(e,t,r,n){if(!(t instanceof d.AbstractDynamicChildDeploymentInfo))return;const{minItems:a,maxItems:i}=t;null!==a&&e.length<a&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.MISSING_INDEX_IN_REAL_OBJECT,r,a,e.length)),null!==i&&e.length>i&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.UNEXPECTED_INDEX_IN_REAL_OBJECT,r,i,e.length))}static validateItem(e,t,r,a){if(t instanceof u.TemplateElement)return void(e instanceof n.InstanceDataContainer?S.validateContainer(e,t,r,a):S.isEmpty(e)?S.validateContainer(new n.InstanceDataContainer,t,r,a):a.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,r,"an element","a field value")));S.validateIri(e,r,a);const i=S.declaredValueType(t);null!==i&&S.validateTypedValue(e,i,r,a)}static validateIri(e,t,r){(e instanceof l.InstanceDataLinkAtom||e instanceof c.InstanceDataControlledAtom)&&null===e.id&&r.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,t.add(E.JsonSchema.atId),"an IRI",null))}static declaredValueType(e){return e instanceof m.TemporalFieldImpl?e.valueConstraints.temporalType.getValue():e instanceof p.NumericFieldImpl?e.valueConstraints.numberType.getValue():null}static validateTypedValue(e,t,r,n){S.isEmpty(e)||(e instanceof o.InstanceDataTypedAtom?null!==e.value&&e.type!==t&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.VALUE_MISMATCH,r.add(E.JsonSchema.atType),t,e.type??void 0)):e instanceof s.InstanceDataStringAtom&&null!==e.value&&n.addBlueprintComparisonError(new f.ComparisonError(R,T.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,r.add(E.JsonSchema.atType),t)))}static isEmpty(e){return e instanceof a.InstanceDataEmptyAtom||e instanceof i.InstanceDataEmptyNode||(e instanceof s.InstanceDataStringAtom||e instanceof o.InstanceDataTypedAtom)&&null===e.value}}t.InstanceValidator=S},2272(e,t,r){t.TemplateInstance=void 0;const n=r(2763),a=r(5697),i=r(7723);class s extends a.AbstractInstanceArtifact{dataContainer;constructor(){super(),this.cedarArtifactType=n.CedarArtifactType.TEMPLATE_INSTANCE,this.dataContainer=new i.InstanceDataContainer}static buildEmptyWithNullValues(){return new s}}t.TemplateInstance=s},4925(e,t,r){t.TemplateInstanceBuilder=void 0;const n=r(1641),a=r(2272),i=r(7723),s=r(8534);class o extends n.AbstractArtifactBuilder{schema_isBasedOn=s.CedarArtifactId.NULL;dataContainer=new i.InstanceDataContainer;withSchemaIsBasedOn(e){return e instanceof s.CedarArtifactId?this.schema_isBasedOn=e:this.schema_isBasedOn=s.CedarArtifactId.forValue(e),this}withDataValue(e,t){return this.dataContainer.setValue(e,t),this}withDataIri(e,t){return this.dataContainer.setIri(e,t),this}withDataId(e){return this.dataContainer.id=e,this}withDataContainer(e){return this.dataContainer=e,this}build(){const e=a.TemplateInstance.buildEmptyWithNullValues();return e.at_id=this.at_id,e.pav_createdOn=this.pav_createdOn,e.pav_createdBy=this.pav_createdBy,e.pav_lastUpdatedOn=this.pav_lastUpdatedOn,e.oslc_modifiedBy=this.oslc_modifiedBy,e.pav_derivedFrom=this.pav_derivedFrom,e.schema_name=this.schema_name,e.schema_description=this.schema_description,e.schema_isBasedOn=this.schema_isBasedOn,e.dataContainer=this.dataContainer,e}}t.TemplateInstanceBuilder=o},3281(e,t,r){t.Template=void 0;const n=r(3910),a=r(8557),i=r(1027),s=r(5451),o=r(2763);class l extends s.AbstractContainerArtifact{header=null;footer=null;constructor(){super(),this.cedarArtifactType=o.CedarArtifactType.TEMPLATE}static buildEmptyWithNullValues(){return new l}static buildEmptyWithDefaultValues(){const e=new l;return e.schema_schemaVersion=a.SchemaVersion.CURRENT,e.bibo_status=n.BiboStatus.DRAFT,e.pav_version=i.PavVersion.DEFAULT,e}isMultiInstanceByDefinition(){return!1}isSingleInstanceByDefinition(){return!1}createDeploymentBuilder(e){throw new Error("Method not supported.")}}t.Template=l},766(e,t,r){t.TemplateBuilder=void 0;const n=r(3281),a=r(1641);class i extends a.AbstractArtifactBuilder{header=null;footer=null;instanceTypeSpecification=null;children=[];withHeader(e){return this.header=e,this}withFooter(e){return this.footer=e,this}withInstanceTypeSpecification(e){return this.instanceTypeSpecification=e,this}addChild(e,t){return this.children.push([e,t]),this}build(){const e=n.Template.buildEmptyWithNullValues();return super.buildInternal(e),e.header=this.header,e.footer=this.footer,e.instanceTypeSpecification=this.instanceTypeSpecification,this.children.forEach(([t,r])=>{e.addChild(t,r)}),e}}t.TemplateBuilder=i},9517(e,t){t.JsonNode=void 0,t.JsonNode=class{static getEmpty(){return{}}static getEmptyList(){return[]}static hasEntries(e){return Object.keys(e).length>0}}},4531(e,t){t.BioportalTermType=t.BioportalTermTypeYamlValues=t.P=void 0,t.P={ONTOLOGY_CLASS:"OntologyClass",VALUE:"Value"},t.BioportalTermTypeYamlValues={ONTOLOGY_CLASS:"class",VALUE:"value"};class r{jsonValue;yamlValue;constructor(e,t){this.jsonValue=e,this.yamlValue=t}getJsonValue(){return this.jsonValue}getYamlValue(){return this.yamlValue}static ONTOLOGY_CLASS=new r(t.P.ONTOLOGY_CLASS,t.BioportalTermTypeYamlValues.ONTOLOGY_CLASS);static VALUE=new r(t.P.VALUE,t.BioportalTermTypeYamlValues.VALUE);static NULL=new r(null,null);static values(){return[r.ONTOLOGY_CLASS,r.VALUE]}static forJsonValue(e){for(const t of r.values())if(t.getJsonValue()===e)return t;return this.NULL}static forYamlValue(e){for(const t of r.values())if(t.getYamlValue()===e)return t;return this.NULL}}t.BioportalTermType=r},8534(e,t){t.CedarArtifactId=void 0;class r{value;constructor(e){this.value=e}getValue(){return this.value}static NULL=new r(null);static forValue(e){return null===e||""===e?r.NULL:new r(e)}}t.CedarArtifactId=r},2763(e,t){t.CedarArtifactType=t.df=t.KW=void 0,t.KW={TEMPLATE:"https://schema.metadatacenter.org/core/Template",TEMPLATE_ELEMENT:"https://schema.metadatacenter.org/core/TemplateElement",TEMPLATE_FIELD:"https://schema.metadatacenter.org/core/TemplateField",STATIC_TEMPLATE_FIELD:"https://schema.metadatacenter.org/core/StaticTemplateField",TEMPLATE_INSTANCE:"TemplateInstance"},t.df={TEMPLATE:"template",TEMPLATE_ELEMENT:"templateElement",TEMPLATE_FIELD:"templateField",STATIC_TEMPLATE_FIELD:"staticTemplateField",TEMPLATE_INSTANCE:"instance"};class r{value;yamlValue;constructor(e,t){this.value=e,this.yamlValue=t}getValue(){return this.value}getYamlValue(){return this.yamlValue}static TEMPLATE=new r(t.KW.TEMPLATE,t.df.TEMPLATE);static TEMPLATE_ELEMENT=new r(t.KW.TEMPLATE_ELEMENT,t.df.TEMPLATE_ELEMENT);static TEMPLATE_FIELD=new r(t.KW.TEMPLATE_FIELD,t.df.TEMPLATE_FIELD);static STATIC_TEMPLATE_FIELD=new r(t.KW.STATIC_TEMPLATE_FIELD,t.df.STATIC_TEMPLATE_FIELD);static TEMPLATE_INSTANCE=new r(t.KW.TEMPLATE_INSTANCE,t.df.TEMPLATE_INSTANCE);static NULL=new r(null,null);static values(){return[r.TEMPLATE,r.TEMPLATE_ELEMENT,r.TEMPLATE_FIELD,r.STATIC_TEMPLATE_FIELD,r.TEMPLATE_INSTANCE]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}static forYamlArtifactType(e){return e.isTemplate()?r.TEMPLATE:e.isElement()?r.TEMPLATE_ELEMENT:e.isDynamicField()?r.TEMPLATE_FIELD:e.isStaticField()?r.STATIC_TEMPLATE_FIELD:e.isTemplateInstance()?r.TEMPLATE_INSTANCE:r.NULL}}t.CedarArtifactType=r},8421(e,t){t.CedarFieldCategory=t.I=void 0,t.I={STATIC:"STATIC-field",DYNAMIC:"DYNAMIC-field",NONE:"NONE"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static values(){return[r.STATIC,r.DYNAMIC,r.NONE]}static STATIC=new r(t.I.STATIC);static DYNAMIC=new r(t.I.DYNAMIC);static NONE=new r(t.I.NONE);static NULL=new r(null)}t.CedarFieldCategory=r},4869(e,t,r){t.CedarFieldType=t.K=void 0;const n=r(9034),a=r(9499);t.K={TEXTFIELD:"DYNAMIC-textfield",TEXTAREA:"DYNAMIC-textarea",CONTROLLED_TERM:"DYNAMIC-controlled-term",LINK:"DYNAMIC-link",EXT_ROR:"DYNAMIC-ext-ror",EXT_ORCID:"DYNAMIC-ext-orcid",EXT_PFAS:"DYNAMIC-ext-pfas",EXT_PUBMED:"DYNAMIC-ext-pubmed",EXT_RRID:"DYNAMIC-ext-rrid",EXT_NIH_GRANT_ID:"DYNAMIC-ext-nih-grant-id",EXT_DOI:"DYNAMIC-ext-doi",TEMPORAL:"DYNAMIC-temporal",EMAIL:"DYNAMIC-email",NUMERIC:"DYNAMIC-numeric",PHONE_NUMBER:"DYNAMIC-phone-number",RADIO:"DYNAMIC-radio",CHECKBOX:"DYNAMIC-checkbox",SINGLE_SELECT_LIST:"DYNAMIC-single-select-list",MULTIPLE_SELECT_LIST:"DYNAMIC-multiple-select-list",ATTRIBUTE_VALUE:"DYNAMIC-attribute-value",STATIC_PAGE_BREAK:"STATIC-page-break",STATIC_SECTION_BREAK:"STATIC-section-break",STATIC_IMAGE:"STATIC-image",STATIC_RICH_TEXT:"STATIC-rich_text",STATIC_YOUTUBE:"STATIC-youtube"};class i{value;_uiInputType;_yamlType;staticField;constructor(e,t,r,n){this.value=e,this._uiInputType=t,this._yamlType=r,this.staticField=n}getValue(){return this.value}getUiInputType(){return this._uiInputType}getYamlType(){return this._yamlType}get isStaticField(){return this.staticField}static values(){return[i.TEXT,i.TEXTAREA,i.CONTROLLED_TERM,i.LINK,i.EXT_ROR,i.EXT_ORCID,i.EXT_PFAS,i.EXT_PUBMED,i.EXT_RRID,i.EXT_NIH_GRANT_ID,i.EXT_DOI,i.TEMPORAL,i.EMAIL,i.NUMERIC,i.PHONE_NUMBER,i.RADIO,i.CHECKBOX,i.SINGLE_SELECT_LIST,i.MULTIPLE_SELECT_LIST,i.ATTRIBUTE_VALUE,i.STATIC_PAGE_BREAK,i.STATIC_SECTION_BREAK,i.STATIC_IMAGE,i.STATIC_RICH_TEXT,i.STATIC_YOUTUBE]}static TEXT=new i(t.K.TEXTFIELD,n.UiInputType.TEXTFIELD,a.YamlArtifactType.TEXTFIELD,!1);static TEXTAREA=new i(t.K.TEXTAREA,n.UiInputType.TEXTAREA,a.YamlArtifactType.TEXTAREA,!1);static CONTROLLED_TERM=new i(t.K.CONTROLLED_TERM,n.UiInputType.TEXTFIELD,a.YamlArtifactType.CONTROLLED_TERM,!1);static LINK=new i(t.K.LINK,n.UiInputType.LINK,a.YamlArtifactType.LINK,!1);static EXT_ROR=new i(t.K.EXT_ROR,n.UiInputType.EXT_ROR,a.YamlArtifactType.EXT_ROR,!1);static EXT_ORCID=new i(t.K.EXT_ORCID,n.UiInputType.EXT_ORCID,a.YamlArtifactType.EXT_ORCID,!1);static EXT_PFAS=new i(t.K.EXT_PFAS,n.UiInputType.EXT_PFAS,a.YamlArtifactType.EXT_PFAS,!1);static EXT_PUBMED=new i(t.K.EXT_PUBMED,n.UiInputType.EXT_PUBMED,a.YamlArtifactType.EXT_PUBMED,!1);static EXT_RRID=new i(t.K.EXT_RRID,n.UiInputType.EXT_RRID,a.YamlArtifactType.EXT_RRID,!1);static EXT_NIH_GRANT_ID=new i(t.K.EXT_NIH_GRANT_ID,n.UiInputType.EXT_NIH_GRANT_ID,a.YamlArtifactType.EXT_NIH_GRANT_ID,!1);static EXT_DOI=new i(t.K.EXT_DOI,n.UiInputType.EXT_DOI,a.YamlArtifactType.EXT_DOI,!1);static TEMPORAL=new i(t.K.TEMPORAL,n.UiInputType.TEMPORAL,a.YamlArtifactType.TEMPORAL,!1);static EMAIL=new i(t.K.EMAIL,n.UiInputType.EMAIL,a.YamlArtifactType.EMAIL,!1);static NUMERIC=new i(t.K.NUMERIC,n.UiInputType.NUMERIC,a.YamlArtifactType.NUMERIC,!1);static PHONE_NUMBER=new i(t.K.PHONE_NUMBER,n.UiInputType.PHONE_NUMBER,a.YamlArtifactType.PHONE_NUMBER,!1);static RADIO=new i(t.K.RADIO,n.UiInputType.RADIO,a.YamlArtifactType.RADIO,!1);static CHECKBOX=new i(t.K.CHECKBOX,n.UiInputType.CHECKBOX,a.YamlArtifactType.CHECKBOX,!1);static SINGLE_SELECT_LIST=new i(t.K.SINGLE_SELECT_LIST,n.UiInputType.LIST,a.YamlArtifactType.SINGLE_SELECT_LIST,!1);static MULTIPLE_SELECT_LIST=new i(t.K.MULTIPLE_SELECT_LIST,n.UiInputType.LIST,a.YamlArtifactType.MULTI_SELECT_LIST,!1);static ATTRIBUTE_VALUE=new i(t.K.ATTRIBUTE_VALUE,n.UiInputType.ATTRIBUTE_VALUE,a.YamlArtifactType.ATTRIBUTE_VALUE,!1);static STATIC_PAGE_BREAK=new i(t.K.STATIC_PAGE_BREAK,n.UiInputType.PAGE_BREAK,a.YamlArtifactType.PAGE_BREAK,!0);static STATIC_SECTION_BREAK=new i(t.K.STATIC_SECTION_BREAK,n.UiInputType.SECTION_BREAK,a.YamlArtifactType.SECTION_BREAK,!0);static STATIC_IMAGE=new i(t.K.STATIC_IMAGE,n.UiInputType.IMAGE,a.YamlArtifactType.IMAGE,!0);static STATIC_RICH_TEXT=new i(t.K.STATIC_RICH_TEXT,n.UiInputType.RICH_TEXT,a.YamlArtifactType.RICH_TEXT,!0);static STATIC_YOUTUBE=new i(t.K.STATIC_YOUTUBE,n.UiInputType.YOUTUBE,a.YamlArtifactType.YOUTUBE,!0);static NULL=new i(null,n.UiInputType.NULL,a.YamlArtifactType.NULL,!0);static forUiInputType(e){for(const t of i.values())if(t.getUiInputType()===e)return t;return this.NULL}static forYamlArtifactType(e){for(const t of i.values())if(t.getYamlType()===e)return t;return this.NULL}}t.CedarFieldType=i},2234(e,t){t.CedarUser=void 0;class r{value;constructor(e){this.value=e}getValue(){return this.value}static NULL=new r(null);static forValue(e){return null===e?r.NULL:new r(e)}}t.CedarUser=r},3746(e,t){t.AdditionalProperties=t.P=void 0,t.P={FALSE:"false",ALLOW_ATTRIBUTE_VALUE:"allow-attribute-value"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static FALSE=new r(t.P.FALSE);static ALLOW_ATTRIBUTE_VALUE=new r(t.P.ALLOW_ATTRIBUTE_VALUE);static NULL=new r(null);static values(){return[r.FALSE,r.ALLOW_ATTRIBUTE_VALUE]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.AdditionalProperties=r},2475(e,t){t.ArtifactSchema=t.T=void 0,t.T={CURRENT:"http://json-schema.org/draft-04/schema#"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static CURRENT=new r(t.T.CURRENT);static NULL=new r(null);static forValue(e){return new r(null===e?t.T.CURRENT:e)}}t.ArtifactSchema=r},3910(e,t){t.BiboStatus=t.BiboStatusYamlValues=t.l=void 0,t.l={DRAFT:"bibo:draft",PUBLISHED:"bibo:published"},t.BiboStatusYamlValues={DRAFT:"draft",PUBLISHED:"published"};class r{jsonValue;yamlValue;constructor(e,t){this.jsonValue=e,this.yamlValue=t}getJsonValue(){return this.jsonValue}getYamlValue(){return this.yamlValue}static DRAFT=new r(t.l.DRAFT,t.BiboStatusYamlValues.DRAFT);static PUBLISHED=new r(t.l.PUBLISHED,t.BiboStatusYamlValues.PUBLISHED);static NULL=new r(null,null);static values(){return[r.DRAFT,r.PUBLISHED]}static forJsonValue(e){for(const t of r.values())if(t.getJsonValue()===e)return t;return this.NULL}static forYamlValue(e){for(const t of r.values())if(t.getYamlValue()===e)return t;return this.NULL}}t.BiboStatus=r},8802(e,t){t.Iri=void 0;class r{value;constructor(e){this.value=e}getValue(){return this.value}static empty(){return new r("")}isEmpty(){return""===this.value}}t.Iri=r},9857(e,t){t.IsoDate=void 0;class r{date;timezoneOffset;constructor(e,t){this.date=e,this.timezoneOffset=t}static NULL=new r(null,null);getValue(){if(null!=this.date){if("Z"===this.timezoneOffset)return this.date.toISOString().replace(/\.\d{3}Z$/,"Z");const e=this.timezoneOffset.match(/([+-])(\d{2}):(\d{2})/);if(e){const t="+"===e[1]?1:-1,r=parseInt(e[2],10)*t,n=parseInt(e[3],10)*t,a=this.date.getTime(),i=new Date(a+60*(60*r+n)*1e3),s=i.getUTCFullYear(),o=i.getUTCMonth()+1,l=i.getUTCDate(),c=i.getUTCHours(),d=i.getUTCMinutes(),u=i.getUTCSeconds();return`${s}-${o.toString().padStart(2,"0")}-${l.toString().padStart(2,"0")}T${c.toString().padStart(2,"0")}:${d.toString().padStart(2,"0")}:${u.toString().padStart(2,"0")}${this.timezoneOffset}`}return null}return null}static forValue(e){if(!e)return r.NULL;e=e.replace(/([+-]\d{2})(\d{2})$/,"$1:$2");const t=e.match(/Z|([+-])([01]\d):?([0-5]\d)$/)?.[0]??"Z",n=new Date("Z"!==t||e.endsWith("Z")?e:`${e}Z`);return new r(n,t)}static now(){const e=new Date,t=this.getCurrentGMTOffset();return new r(e,t)}static getCurrentGMTOffset(){const e=(new Date).getTimezoneOffset(),t=Math.abs(e),r=t%60;return`${e>0?"-":"+"}${Math.floor(t/60).toString().padStart(2,"0")}:${r.toString().padStart(2,"0")}`}}t.IsoDate=r},5793(e,t){t.JavascriptType=t.W=void 0,t.W={ARRAY:"array",OBJECT:"object",STRING:"string"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static ARRAY=new r(t.W.ARRAY);static OBJECT=new r(t.W.OBJECT);static STRING=new r(t.W.STRING);static NULL=new r(null);static values(){return[r.ARRAY,r.OBJECT,r.STRING]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.JavascriptType=r},7752(e,t){t.Language=void 0;class r{value;constructor(e){this.value=e}getValue(){return this.value}static NULL=new r(null);static forValue(e){return null===e||""===e?r.NULL:new r(e)}}t.Language=r},3447(e,t){t.NumberType=t.NumberTypeValues=void 0,t.NumberTypeValues={DECIMAL:"xsd:decimal",INT:"xsd:int",LONG:"xsd:long",BYTE:"xsd:byte",SHORT:"xsd:short",FLOAT:"xsd:float",DOUBLE:"xsd:double"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static DECIMAL=new r(t.NumberTypeValues.DECIMAL);static INT=new r(t.NumberTypeValues.INT);static LONG=new r(t.NumberTypeValues.LONG);static BYTE=new r(t.NumberTypeValues.BYTE);static SHORT=new r(t.NumberTypeValues.SHORT);static FLOAT=new r(t.NumberTypeValues.FLOAT);static DOUBLE=new r(t.NumberTypeValues.DOUBLE);static NULL=new r(null);static values(){return[r.DECIMAL,r.INT,r.LONG,r.BYTE,r.SHORT,r.FLOAT,r.DOUBLE]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.NumberType=r},1027(e,t,r){t.PavVersion=t.o=void 0;const n=r(4506);t.o={DEFAULT:"0.0.1"};class a extends n.SemVer{static DEFAULT=new a(t.o.DEFAULT);static NULL=new a(null);getDefaultValue(){return t.o.DEFAULT}static values(){return[a.DEFAULT,a.NULL]}static forValue(e){for(const t of a.values())if(t.getValue()===e)return t;return new a(e)}}t.PavVersion=a},6389(e,t,r){t.PropertyIri=void 0;const n=r(936);t.PropertyIri=class{static get namespace(){return n.CedarModel.propertyIriPrefix}}},8557(e,t,r){t.SchemaVersion=t.y=void 0;const n=r(4506);t.y={CURRENT:"1.6.0"};class a extends n.SemVer{static CURRENT=new a(t.y.CURRENT);static NULL=new a(null);getDefaultValue(){return t.y.CURRENT}static values(){return[a.CURRENT]}static forValue(e){for(const t of a.values())if(t.getValue()===e)return t;return new a(e)}}t.SchemaVersion=a},4506(e,t){t.SemVer=void 0,t.SemVer=class{value;constructor(e){this.value=this.validateVersion(e)}getValue(){return this.value}validateVersion(e){return null===e||/^\d+\.\d+\.\d+$/.test(e)?e:this.getDefaultValue()}}},7974(e,t){t.TemporalGranularity=t.TemporalGranularityValues=void 0,t.TemporalGranularityValues={YEAR:"year",MONTH:"month",DAY:"day",HOUR:"hour",MINUTE:"minute",SECOND:"second",DECIMAL_SECOND:"decimalSecond"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static YEAR=new r(t.TemporalGranularityValues.YEAR);static MONTH=new r(t.TemporalGranularityValues.MONTH);static DAY=new r(t.TemporalGranularityValues.DAY);static HOUR=new r(t.TemporalGranularityValues.HOUR);static MINUTE=new r(t.TemporalGranularityValues.MINUTE);static SECOND=new r(t.TemporalGranularityValues.SECOND);static DECIMAL_SECOND=new r(t.TemporalGranularityValues.DECIMAL_SECOND);static NULL=new r(null);static values(){return[r.YEAR,r.MONTH,r.DAY,r.HOUR,r.MINUTE,r.SECOND,r.DECIMAL_SECOND]}static valuesWithTimes(){return[r.HOUR,r.MINUTE,r.SECOND,r.DECIMAL_SECOND]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}static hasTime(e){return this.valuesWithTimes().includes(e)}}t.TemporalGranularity=r},8588(e,t){t.TemporalType=t.TemporalTypeValues=void 0,t.TemporalTypeValues={DATE:"xsd:date",TIME:"xsd:time",DATETIME:"xsd:dateTime"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static DATE=new r(t.TemporalTypeValues.DATE);static TIME=new r(t.TemporalTypeValues.TIME);static DATETIME=new r(t.TemporalTypeValues.DATETIME);static NULL=new r(null);static values(){return[r.DATE,r.TIME,r.DATETIME]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.TemporalType=r},3764(e,t){t.TimeFormat=t.TimeFormatValues=void 0,t.TimeFormatValues={H24:"24h",H12:"12h"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static H24=new r(t.TimeFormatValues.H24);static H12=new r(t.TimeFormatValues.H12);static NULL=new r(null);static values(){return[r.H24,r.H12]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.TimeFormat=r},9034(e,t){t.UiInputType=t.F=void 0,t.F={TEXTFIELD:"textfield",TEXTAREA:"textarea",LINK:"link",EXT_ROR:"ext-ror",EXT_ORCID:"ext-orcid",EXT_PFAS:"ext-pfas",EXT_PUBMED:"ext-pubmed",EXT_RRID:"ext-rrid",EXT_NIH_GRANT_ID:"ext-nih-grant-id",EXT_DOI:"ext-doi",TEMPORAL:"temporal",EMAIL:"email",NUMERIC:"numeric",PHONE_NUMBER:"phone-number",LIST:"list",CHECKBOX:"checkbox",RADIO:"radio",ATTRIBUTE_VALUE:"attribute-value",PAGE_BREAK:"page-break",SECTION_BREAK:"section-break",IMAGE:"image",RICH_TEXT:"richtext",YOUTUBE:"youtube"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static TEXTFIELD=new r(t.F.TEXTFIELD);static TEXTAREA=new r(t.F.TEXTAREA);static LINK=new r(t.F.LINK);static EXT_ROR=new r(t.F.EXT_ROR);static EXT_ORCID=new r(t.F.EXT_ORCID);static EXT_PFAS=new r(t.F.EXT_PFAS);static EXT_PUBMED=new r(t.F.EXT_PUBMED);static EXT_RRID=new r(t.F.EXT_RRID);static EXT_NIH_GRANT_ID=new r(t.F.EXT_NIH_GRANT_ID);static EXT_DOI=new r(t.F.EXT_DOI);static TEMPORAL=new r(t.F.TEMPORAL);static EMAIL=new r(t.F.EMAIL);static NUMERIC=new r(t.F.NUMERIC);static PHONE_NUMBER=new r(t.F.PHONE_NUMBER);static LIST=new r(t.F.LIST);static CHECKBOX=new r(t.F.CHECKBOX);static RADIO=new r(t.F.RADIO);static ATTRIBUTE_VALUE=new r(t.F.ATTRIBUTE_VALUE);static PAGE_BREAK=new r(t.F.PAGE_BREAK);static SECTION_BREAK=new r(t.F.SECTION_BREAK);static IMAGE=new r(t.F.IMAGE);static RICH_TEXT=new r(t.F.RICH_TEXT);static YOUTUBE=new r(t.F.YOUTUBE);static NULL=new r(null);static values(){return[r.TEXTFIELD,r.TEXTAREA,r.LINK,r.EXT_ROR,r.EXT_ORCID,r.EXT_PFAS,r.EXT_PUBMED,r.EXT_RRID,r.EXT_NIH_GRANT_ID,r.EXT_DOI,r.TEMPORAL,r.EMAIL,r.NUMERIC,r.PHONE_NUMBER,r.LIST,r.CHECKBOX,r.RADIO,r.ATTRIBUTE_VALUE,r.PAGE_BREAK,r.SECTION_BREAK,r.IMAGE,r.RICH_TEXT,r.YOUTUBE,r.NULL]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}}t.UiInputType=r},9499(e,t,r){t.YamlArtifactType=t.YamlArtifactTypeValues=void 0;const n=r(8421);t.YamlArtifactTypeValues={TEMPLATE:"template",ELEMENT:"element",TEXTFIELD:"text-field",CONTROLLED_TERM:"controlled-term-field",TEXTAREA:"text-area-field",LINK:"link-field",EXT_ROR:"ext-ror-field",EXT_ORCID:"ext-orcid-field",EXT_PFAS:"ext-pfas-field",EXT_PUBMED:"ext-pubmed-field",EXT_RRID:"ext-rrid-field",EXT_NIH_GRANT_ID:"ext-nih-grant-id-field",EXT_DOI:"ext-doi-field",TEMPORAL:"temporal-field",EMAIL:"email-field",NUMERIC:"numeric-field",PHONE_NUMBER:"phone-number-field",SINGLE_SELECT_LIST:"single-select-list-field",MULTI_SELECT_LIST:"multi-select-list-field",CHECKBOX:"checkbox-field",RADIO:"radio-field",ATTRIBUTE_VALUE:"attribute-value-field",PAGE_BREAK:"static-page-break",SECTION_BREAK:"static-section-break",IMAGE:"static-image",RICH_TEXT:"static-rich-text",YOUTUBE:"static-youtube-video",TEMPLATE_INSTANCE:"instance"};class a{value;category;constructor(e,t){this.value=e,this.category=t}getValue(){return this.value}static TEMPLATE=new a(t.YamlArtifactTypeValues.TEMPLATE,n.CedarFieldCategory.NONE);static ELEMENT=new a(t.YamlArtifactTypeValues.ELEMENT,n.CedarFieldCategory.NONE);static TEXTFIELD=new a(t.YamlArtifactTypeValues.TEXTFIELD,n.CedarFieldCategory.DYNAMIC);static CONTROLLED_TERM=new a(t.YamlArtifactTypeValues.CONTROLLED_TERM,n.CedarFieldCategory.DYNAMIC);static TEXTAREA=new a(t.YamlArtifactTypeValues.TEXTAREA,n.CedarFieldCategory.DYNAMIC);static LINK=new a(t.YamlArtifactTypeValues.LINK,n.CedarFieldCategory.DYNAMIC);static EXT_ROR=new a(t.YamlArtifactTypeValues.EXT_ROR,n.CedarFieldCategory.DYNAMIC);static EXT_ORCID=new a(t.YamlArtifactTypeValues.EXT_ORCID,n.CedarFieldCategory.DYNAMIC);static EXT_PFAS=new a(t.YamlArtifactTypeValues.EXT_PFAS,n.CedarFieldCategory.DYNAMIC);static EXT_PUBMED=new a(t.YamlArtifactTypeValues.EXT_PUBMED,n.CedarFieldCategory.DYNAMIC);static EXT_RRID=new a(t.YamlArtifactTypeValues.EXT_RRID,n.CedarFieldCategory.DYNAMIC);static EXT_NIH_GRANT_ID=new a(t.YamlArtifactTypeValues.EXT_NIH_GRANT_ID,n.CedarFieldCategory.DYNAMIC);static EXT_DOI=new a(t.YamlArtifactTypeValues.EXT_DOI,n.CedarFieldCategory.DYNAMIC);static TEMPORAL=new a(t.YamlArtifactTypeValues.TEMPORAL,n.CedarFieldCategory.DYNAMIC);static EMAIL=new a(t.YamlArtifactTypeValues.EMAIL,n.CedarFieldCategory.DYNAMIC);static NUMERIC=new a(t.YamlArtifactTypeValues.NUMERIC,n.CedarFieldCategory.DYNAMIC);static PHONE_NUMBER=new a(t.YamlArtifactTypeValues.PHONE_NUMBER,n.CedarFieldCategory.DYNAMIC);static SINGLE_SELECT_LIST=new a(t.YamlArtifactTypeValues.SINGLE_SELECT_LIST,n.CedarFieldCategory.DYNAMIC);static MULTI_SELECT_LIST=new a(t.YamlArtifactTypeValues.MULTI_SELECT_LIST,n.CedarFieldCategory.DYNAMIC);static CHECKBOX=new a(t.YamlArtifactTypeValues.CHECKBOX,n.CedarFieldCategory.DYNAMIC);static RADIO=new a(t.YamlArtifactTypeValues.RADIO,n.CedarFieldCategory.DYNAMIC);static ATTRIBUTE_VALUE=new a(t.YamlArtifactTypeValues.ATTRIBUTE_VALUE,n.CedarFieldCategory.DYNAMIC);static PAGE_BREAK=new a(t.YamlArtifactTypeValues.PAGE_BREAK,n.CedarFieldCategory.STATIC);static SECTION_BREAK=new a(t.YamlArtifactTypeValues.SECTION_BREAK,n.CedarFieldCategory.STATIC);static IMAGE=new a(t.YamlArtifactTypeValues.IMAGE,n.CedarFieldCategory.STATIC);static RICH_TEXT=new a(t.YamlArtifactTypeValues.RICH_TEXT,n.CedarFieldCategory.STATIC);static YOUTUBE=new a(t.YamlArtifactTypeValues.YOUTUBE,n.CedarFieldCategory.STATIC);static TEMPLATE_INSTANCE=new a(t.YamlArtifactTypeValues.TEMPLATE_INSTANCE,n.CedarFieldCategory.NONE);static NULL=new a(null,n.CedarFieldCategory.NULL);static values(){return[a.TEMPLATE,a.ELEMENT,a.TEXTFIELD,a.CONTROLLED_TERM,a.TEXTAREA,a.LINK,a.EXT_ROR,a.EXT_ORCID,a.EXT_PFAS,a.EXT_PUBMED,a.EXT_RRID,a.EXT_NIH_GRANT_ID,a.EXT_DOI,a.TEMPORAL,a.EMAIL,a.NUMERIC,a.PHONE_NUMBER,a.SINGLE_SELECT_LIST,a.MULTI_SELECT_LIST,a.CHECKBOX,a.RADIO,a.ATTRIBUTE_VALUE,a.PAGE_BREAK,a.SECTION_BREAK,a.IMAGE,a.RICH_TEXT,a.YOUTUBE,a.TEMPLATE_INSTANCE,a.NULL]}static forValue(e){for(const t of a.values())if(t.getValue()===e)return t;return this.NULL}isTemplate(){return this.value===t.YamlArtifactTypeValues.TEMPLATE}isElement(){return this.value===t.YamlArtifactTypeValues.ELEMENT}isField(){return this.isDynamicField()||this.isStaticField()}isStaticField(){return this.category===n.CedarFieldCategory.STATIC}isDynamicField(){return this.category===n.CedarFieldCategory.DYNAMIC}isTemplateInstance(){return this.value===t.YamlArtifactTypeValues.TEMPLATE_INSTANCE}}t.YamlArtifactType=a},2888(e,t){t.ComparisonError=void 0,t.ComparisonError=class{errorLocation;errorType;errorPath;expectedValue;encounteredValue;stackTopLines;constructor(e,t,r,n,a){this.errorLocation=e,this.errorType=t,this.errorPath=r,this.expectedValue=n,this.encounteredValue=a}}},9760(e,t){t.ComparisonErrorType=t.e=void 0,t.e={MISSING_KEY_IN_REAL_OBJECT:"missingKeyInRealObject",UNEXPECTED_KEY_IN_REAL_OBJECT:"unexpectedKeyInRealObject",VALUE_MISMATCH:"valueMismatch",MISSING_INDEX_IN_REAL_OBJECT:"missingIndexInRealObject",UNEXPECTED_INDEX_IN_REAL_OBJECT:"unexpectedIndexInRealObject",MISSING_VALUE_IN_REAL_OBJECT:"missingValueInRealObject",UNEXPECTED_VALUE_IN_REAL_OBJECT:"unexpectedValueInRealObject"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static MISSING_KEY_IN_REAL_OBJECT=new r(t.e.MISSING_KEY_IN_REAL_OBJECT);static UNEXPECTED_KEY_IN_REAL_OBJECT=new r(t.e.UNEXPECTED_KEY_IN_REAL_OBJECT);static VALUE_MISMATCH=new r(t.e.VALUE_MISMATCH);static MISSING_INDEX_IN_REAL_OBJECT=new r(t.e.MISSING_INDEX_IN_REAL_OBJECT);static UNEXPECTED_INDEX_IN_REAL_OBJECT=new r(t.e.UNEXPECTED_INDEX_IN_REAL_OBJECT);static MISSING_VALUE_IN_REAL_OBJECT=new r(t.e.MISSING_VALUE_IN_REAL_OBJECT);static UNEXPECTED_VALUE_IN_REAL_OBJECT=new r(t.e.UNEXPECTED_VALUE_IN_REAL_OBJECT);static NULL=new r(null);static values(){return[r.MISSING_KEY_IN_REAL_OBJECT,r.UNEXPECTED_KEY_IN_REAL_OBJECT,r.VALUE_MISMATCH,r.MISSING_INDEX_IN_REAL_OBJECT,r.UNEXPECTED_INDEX_IN_REAL_OBJECT,r.MISSING_VALUE_IN_REAL_OBJECT,r.UNEXPECTED_VALUE_IN_REAL_OBJECT]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}toJSON(){return this.value}}t.ComparisonErrorType=r},4325(e,t){t.ComparisonResult=void 0,t.ComparisonResult=class{comparisonErrors=[];comparisonWarnings=[];addComparisonError(e){this.comparisonErrors.push(e)}getComparisonErrors(){return this.comparisonErrors}getComparisonErrorCount(){return this.comparisonErrors.length}addComparisonWarning(e){this.comparisonWarnings.push(e)}getComparisonWarnings(){return this.comparisonWarnings}getComparisonWarningCount(){return this.comparisonWarnings.length}areEqual(){return 0===this.comparisonErrors.length&&0===this.comparisonWarnings.length}merge(e){this.comparisonErrors.push(...e.comparisonErrors),this.comparisonWarnings.push(...e.comparisonWarnings)}}},4036(e,t){t.JsonArtifactParsingResult=void 0,t.JsonArtifactParsingResult=class{blueprintComparisonErrors=[];blueprintComparisonWarnings=[];addBlueprintComparisonError(e){this.blueprintComparisonErrors.push(e)}getBlueprintComparisonErrors(){return this.blueprintComparisonErrors}getBlueprintComparisonErrorCount(){return this.blueprintComparisonErrors.length}addBlueprintComparisonWarning(e){this.blueprintComparisonWarnings.push(e)}getBlueprintComparisonWarnings(){return this.blueprintComparisonWarnings}getBlueprintComparisonWarningCount(){return this.blueprintComparisonWarnings.length}wasSuccessful(){return 0===this.blueprintComparisonErrors.length}adheresToBlueprint(){return 0===this.blueprintComparisonErrors.length&&0===this.blueprintComparisonWarnings.length}merge(e){this.blueprintComparisonErrors.push(...e.blueprintComparisonErrors),this.blueprintComparisonWarnings.push(...e.blueprintComparisonWarnings)}}},3056(e,t,r){t.JsonObjectComparator=void 0;const n=r(2888),a=r(3188),i=r(9760),s=r(5747),o=r(2733),l=r(936);class c{static compareBothWays(e,t,r,s,d,u=[]){!function t(r,s,m){const p=r.getLastComponent()==o.JsonSchema.required;if(Array.isArray(s)&&Array.isArray(m))if(p){const t=new Set(s),a=new Set(m);s.forEach((t,s)=>{const o=r.add(s);a.has(t)||e.addBlueprintComparisonError(new n.ComparisonError("oca01",i.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,o,t))}),m.forEach((a,s)=>{const o=r.add(s);t.has(a)||e.addBlueprintComparisonError(new n.ComparisonError("oca02",i.ComparisonErrorType.UNEXPECTED_VALUE_IN_REAL_OBJECT,o,void 0,a))})}else{const a=Math.max(s.length,m.length);for(let o=0;o<a;o++){const a=r.add(o);o in s?o in m?"object"==typeof s[o]&&null!==s[o]&&"object"==typeof m[o]&&null!==m[o]?t(a,s[o],m[o]):s[o]!==m[o]&&e.addBlueprintComparisonError(new n.ComparisonError("ocl03",i.ComparisonErrorType.VALUE_MISMATCH,a,s[o],m[o])):e.addBlueprintComparisonError(new n.ComparisonError("ocl02",i.ComparisonErrorType.MISSING_INDEX_IN_REAL_OBJECT,a,s[o])):e.addBlueprintComparisonError(new n.ComparisonError("ocl01",i.ComparisonErrorType.UNEXPECTED_INDEX_IN_REAL_OBJECT,a,void 0,m[o]))}}else new Set([...Object.keys(s),...Object.keys(m)]).forEach(p=>{const h=r.add(p);if(p in s)if(p in m){if("object"==typeof s[p]&&null!==s[p]&&"object"==typeof m[p]&&null!==m[p])t(h,s[p],m[p]);else if(s[p]!==m[p]){const t=new n.ComparisonError("oco03",i.ComparisonErrorType.VALUE_MISMATCH,h,s[p],m[p]);d.useWarningForKnownIssues()&&c.isKnownProductionVariation(h)?e.addBlueprintComparisonWarning(t):e.addBlueprintComparisonError(t)}}else d.useWarningForKnownIssues()&&(h.endsIn(l.CedarModel.literals,a.JsonPath.ANY,l.CedarModel.selectedByDefault)||h.endsIn(l.CedarModel.ui,l.CedarModel.pages)||c.isKnownProductionVariation(h))?e.addBlueprintComparisonWarning(new n.ComparisonError("wco02",i.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,h)):e.addBlueprintComparisonError(new n.ComparisonError("oco02",i.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,h));else d.useWarningForKnownIssues()&&(h.endsIn(o.JsonSchema.properties,o.JsonSchema.atLanguage)||c.isKnownProductionVariation(h))?e.addBlueprintComparisonWarning(new n.ComparisonError("wco01",i.ComparisonErrorType.UNEXPECTED_KEY_IN_REAL_OBJECT,h)):u.includes(p)||e.addBlueprintComparisonError(new n.ComparisonError("oco01",i.ComparisonErrorType.UNEXPECTED_KEY_IN_REAL_OBJECT,h))})}(s,t,r)}static isKnownProductionVariation(e){return e.endsIn(o.JsonSchema.atContext,s.TemplateProperty.additionalProperties)||e.endsIn(o.JsonSchema.atContext,o.JsonSchema.properties,a.JsonPath.ANY,l.CedarModel.enum,a.JsonPath.ANY)||e.endsIn(o.JsonSchema.atContext,o.JsonSchema.required,a.JsonPath.ANY)||e.endsIn(o.JsonSchema.atContext,a.JsonPath.ANY)||e.endsIn(l.CedarModel.ui,l.CedarModel.propertyDescriptions,a.JsonPath.ANY)||e.endsIn(l.CedarModel.ui,l.CedarModel.propertyDescriptions)||e.endsIn(l.CedarModel.ui,l.CedarModel.propertyLabels)||e.endsIn(o.JsonSchema.properties,a.JsonPath.ANY,l.CedarModel.enum,a.JsonPath.ANY)||e.endsIn(o.JsonSchema.required)}static reportToLeft(e,t,r){t.useWarningForKnownIssues()&&c.isKnownProductionVariation(r.errorPath)?e.addBlueprintComparisonWarning(r):e.addBlueprintComparisonError(r)}static compareToLeft(e,t,r,a,s){!function t(r,a,l){const d=r.getLastComponent()==o.JsonSchema.required;if(Array.isArray(a)&&Array.isArray(l))if(d){const t=new Set(l);a.forEach((a,o)=>{const l=r.add(o);t.has(a)||c.reportToLeft(e,s,new n.ComparisonError("ola01",i.ComparisonErrorType.MISSING_VALUE_IN_REAL_OBJECT,l,a))})}else a.forEach((o,d)=>{const u=r.add(d);d in l?"object"==typeof o&&null!==o&&"object"==typeof l[d]&&null!==l[d]?t(u,o,l[d]):o!==l[d]&&c.reportToLeft(e,s,new n.ComparisonError("oll02",i.ComparisonErrorType.VALUE_MISMATCH,u,o,l[d])):c.reportToLeft(e,s,new n.ComparisonError("oll01",i.ComparisonErrorType.MISSING_INDEX_IN_REAL_OBJECT,u,a[d]))});else Object.keys(a).forEach(o=>{const d=r.add(o);o in l?"object"==typeof a[o]&&null!==a[o]&&"object"==typeof l[o]&&null!==l[o]?t(d,a[o],l[o]):a[o]!==l[o]&&c.reportToLeft(e,s,new n.ComparisonError("olo02",i.ComparisonErrorType.VALUE_MISMATCH,d,a[o],l[o])):c.reportToLeft(e,s,new n.ComparisonError("olo01",i.ComparisonErrorType.MISSING_KEY_IN_REAL_OBJECT,d))})}(a,t,r)}static comparePrimitive(e,t,r,a){return t!==r&&e.addBlueprintComparisonError(new n.ComparisonError("opp1",i.ComparisonErrorType.VALUE_MISMATCH,a,t,r)),e}}t.JsonObjectComparator=c},1591(e,t){t.YamlArtifactParsingResult=void 0,t.YamlArtifactParsingResult=class{blueprintComparisonErrors=[];blueprintComparisonWarnings=[];addBlueprintComparisonError(e){this.blueprintComparisonErrors.push(e)}getBlueprintComparisonErrors(){return this.blueprintComparisonErrors}getBlueprintComparisonErrorCount(){return this.blueprintComparisonErrors.length}addBlueprintComparisonWarning(e){this.blueprintComparisonWarnings.push(e)}getBlueprintComparisonWarnings(){return this.blueprintComparisonWarnings}getBlueprintComparisonWarningCount(){return this.blueprintComparisonWarnings.length}wasSuccessful(){return 0===this.blueprintComparisonErrors.length}adheresToBlueprint(){return 0===this.blueprintComparisonErrors.length&&0===this.blueprintComparisonWarnings.length}merge(e){this.blueprintComparisonErrors.push(...e.blueprintComparisonErrors),this.blueprintComparisonWarnings.push(...e.blueprintComparisonWarnings)}}},6109(e,t){t.YamlComparisonErrorType=t.H=void 0,t.H={MISSING_KEY_IN_RIGHT_OBJECT:"missingKeyInRightObject",UNEXPECTED_KEY_IN_RIGHT_OBJECT:"unexpectedKeyInRightObject",VALUE_MISMATCH:"valueMismatch",MISSING_INDEX_IN_RIGHT_OBJECT:"missingIndexInRightObject",UNEXPECTED_INDEX_IN_RIGHT_OBJECT:"unexpectedIndexInRightObject",MISSING_VALUE_IN_RIGHT_OBJECT:"missingValueInRightObject",UNEXPECTED_VALUE_IN_RIGHT_OBJECT:"unexpectedValueInRightObject"};class r{value;constructor(e){this.value=e}getValue(){return this.value}static MISSING_KEY_IN_RIGHT_OBJECT=new r(t.H.MISSING_KEY_IN_RIGHT_OBJECT);static UNEXPECTED_KEY_IN_RIGHT_OBJECT=new r(t.H.UNEXPECTED_KEY_IN_RIGHT_OBJECT);static VALUE_MISMATCH=new r(t.H.VALUE_MISMATCH);static MISSING_INDEX_IN_RIGHT_OBJECT=new r(t.H.MISSING_INDEX_IN_RIGHT_OBJECT);static UNEXPECTED_INDEX_IN_RIGHT_OBJECT=new r(t.H.UNEXPECTED_INDEX_IN_RIGHT_OBJECT);static MISSING_VALUE_IN_RIGHT_OBJECT=new r(t.H.MISSING_VALUE_IN_RIGHT_OBJECT);static UNEXPECTED_VALUE_IN_RIGHT_OBJECT=new r(t.H.UNEXPECTED_VALUE_IN_RIGHT_OBJECT);static NULL=new r(null);static values(){return[r.MISSING_KEY_IN_RIGHT_OBJECT,r.UNEXPECTED_KEY_IN_RIGHT_OBJECT,r.VALUE_MISMATCH,r.MISSING_INDEX_IN_RIGHT_OBJECT,r.UNEXPECTED_INDEX_IN_RIGHT_OBJECT,r.MISSING_VALUE_IN_RIGHT_OBJECT,r.UNEXPECTED_VALUE_IN_RIGHT_OBJECT]}static forValue(e){for(const t of r.values())if(t.getValue()===e)return t;return this.NULL}toJSON(){return this.value}}t.YamlComparisonErrorType=r},1885(e,t,r){t.YamlObjectComparator=void 0;const n=r(2888),a=r(3188),i=r(6109),s=r(4325);t.YamlObjectComparator=class{static compare(e,t){const r=new s.ComparisonResult;return this.compareBothWays(r,e,t,new a.JsonPath),r}static compareBothWays(e,t,r,a){!function t(r,a,s){if(Array.isArray(a)&&Array.isArray(s)){const o=Math.max(a.length,s.length);for(let l=0;l<o;l++){const o=r.add(l);l in a?l in s?"object"==typeof a[l]&&null!==a[l]&&"object"==typeof s[l]&&null!==s[l]?t(o,a[l],s[l]):a[l]!==s[l]&&e.addComparisonError(new n.ComparisonError("ocl03",i.YamlComparisonErrorType.VALUE_MISMATCH,o,a[l],s[l])):e.addComparisonError(new n.ComparisonError("ocl02",i.YamlComparisonErrorType.MISSING_INDEX_IN_RIGHT_OBJECT,o,a[l])):e.addComparisonError(new n.ComparisonError("ocl01",i.YamlComparisonErrorType.UNEXPECTED_INDEX_IN_RIGHT_OBJECT,o,void 0,s[l]))}}else new Set([...Object.keys(a),...Object.keys(s)]).forEach(o=>{const l=r.add(o);o in a?o in s?"object"==typeof a[o]&&null!==a[o]&&"object"==typeof s[o]&&null!==s[o]?t(l,a[o],s[o]):a[o]!==s[o]&&e.addComparisonError(new n.ComparisonError("oco03",i.YamlComparisonErrorType.VALUE_MISMATCH,l,a[o],s[o])):e.addComparisonError(new n.ComparisonError("oco02",i.YamlComparisonErrorType.MISSING_KEY_IN_RIGHT_OBJECT,l)):e.addComparisonError(new n.ComparisonError("oco01",i.YamlComparisonErrorType.UNEXPECTED_KEY_IN_RIGHT_OBJECT,l))})}(a,t,r)}}},3188(e,t){t.JsonPath=void 0;class r{path;static ANY="*";constructor(...e){this.path=e}equal(e){return this.path.length===e.path.length&&this.path.every((t,r)=>t===e.path[r])}add(...e){return new r(...this.path,...e)}join(e){return new r(...this.path,...e.path)}toString(){let e="";return this.path.forEach(t=>{e+="number"==typeof t?`/[${t}]`:`/${t}`}),e+"/"}toJSON(){return this.toString()}getLastComponent(){return 0===this.path.length?null:this.path[this.path.length-1]}endsIn(...e){for(let t=1;t<=e.length;t++){if(t>this.path.length)return!1;const n=e[e.length-t];if(this.path[this.path.length-t]!==n&&n!=r.ANY)return!1}return!0}getLastNComponents(e){if(e<=0||0===this.path.length)return new r;const t=Math.max(this.path.length-e,0),n=this.path.slice(t);return new r(...n)}}t.JsonPath=r},6968(e,t,r){t.JsonContainerArtifactContent=void 0;const n=r(8748);class a{static CONTEXT_VERBATIM={xsd:"http://www.w3.org/2001/XMLSchema#",pav:"http://purl.org/pav/",bibo:"http://purl.org/ontology/bibo/",oslc:"http://open-services.net/ns/core#",schema:"http://schema.org/","schema:name":{"@type":"xsd:string"},"schema:description":{"@type":"xsd:string"},"pav:createdOn":{"@type":"xsd:dateTime"},"pav:createdBy":{"@type":"@id"},"pav:lastUpdatedOn":{"@type":"xsd:dateTime"},"oslc:modifiedBy":{"@type":"@id"}};static CONTEXT_VERBATIM_NO_BIBO;static{this.CONTEXT_VERBATIM_NO_BIBO=n.ReaderUtil.deepClone(this.CONTEXT_VERBATIM),n.ReaderUtil.deleteNodeKey(this.CONTEXT_VERBATIM_NO_BIBO,"bibo"),n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM_NO_BIBO),n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM)}}t.JsonContainerArtifactContent=a},6551(e,t,r){t.JsonTemplateContent=void 0;const n=r(8748);class a{static REQUIRED_PARTIAL=["@context","@id","schema:isBasedOn","schema:name","schema:description","pav:createdOn","pav:createdBy","pav:lastUpdatedOn","oslc:modifiedBy"];static PROPERTIES_PARTIAL={"@context":{type:"object",properties:{rdfs:{type:"string",format:"uri",enum:["http://www.w3.org/2000/01/rdf-schema#"]},xsd:{type:"string",format:"uri",enum:["http://www.w3.org/2001/XMLSchema#"]},pav:{type:"string",format:"uri",enum:["http://purl.org/pav/"]},schema:{type:"string",format:"uri",enum:["http://schema.org/"]},oslc:{type:"string",format:"uri",enum:["http://open-services.net/ns/core#"]},skos:{type:"string",format:"uri",enum:["http://www.w3.org/2004/02/skos/core#"]},"rdfs:label":{type:"object",properties:{"@type":{type:"string",enum:["xsd:string"]}}},"schema:isBasedOn":{type:"object",properties:{"@type":{type:"string",enum:["@id"]}}},"schema:name":{type:"object",properties:{"@type":{type:"string",enum:["xsd:string"]}}},"schema:description":{type:"object",properties:{"@type":{type:"string",enum:["xsd:string"]}}},"pav:derivedFrom":{type:"object",properties:{"@type":{type:"string",enum:["@id"]}}},"pav:createdOn":{type:"object",properties:{"@type":{type:"string",enum:["xsd:dateTime"]}}},"pav:createdBy":{type:"object",properties:{"@type":{type:"string",enum:["@id"]}}},"pav:lastUpdatedOn":{type:"object",properties:{"@type":{type:"string",enum:["xsd:dateTime"]}}},"oslc:modifiedBy":{type:"object",properties:{"@type":{type:"string",enum:["@id"]}}},"skos:notation":{type:"object",properties:{"@type":{type:"string",enum:["xsd:string"]}}}},required:["xsd","pav","schema","oslc","schema:isBasedOn","schema:name","schema:description","pav:createdOn","pav:createdBy","pav:lastUpdatedOn","oslc:modifiedBy"],additionalProperties:!1},"@id":{type:["string","null"],format:"uri"},"@type":{oneOf:[{type:"string",format:"uri"},{type:"array",minItems:1,items:{type:"string",format:"uri"},uniqueItems:!0}]},"schema:isBasedOn":{type:"string",format:"uri"},"schema:name":{type:"string",minLength:1},"schema:description":{type:"string"},"pav:derivedFrom":{type:"string",format:"uri"},"pav:createdOn":{type:["string","null"],format:"date-time"},"pav:createdBy":{type:["string","null"],format:"uri"},"pav:lastUpdatedOn":{type:["string","null"],format:"date-time"},"oslc:modifiedBy":{type:["string","null"],format:"uri"}};static REQUIRED_PARTIAL_KEY_MAP;static PROPERTIES_PARTIAL_KEY_LIST=[];static PROPERTIES_PARTIAL_KEY_MAP=new Map;static CONTEXT_VERBATIM_NO_BIBO;static{Object.keys(a.PROPERTIES_PARTIAL).forEach(e=>{this.PROPERTIES_PARTIAL_KEY_LIST.push(e),this.PROPERTIES_PARTIAL_KEY_MAP.set(e,!0)}),this.REQUIRED_PARTIAL_KEY_MAP=this.REQUIRED_PARTIAL.reduce((e,t)=>(e.set(t,!0),e),new Map),n.ReaderUtil.deepFreeze(this.REQUIRED_PARTIAL),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL),n.ReaderUtil.deepFreeze(this.REQUIRED_PARTIAL_KEY_MAP),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL_KEY_LIST),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL_KEY_MAP)}}t.JsonTemplateContent=a},1501(e,t,r){t.JsonTemplateElementContent=void 0;const n=r(8748);class a{static REQUIRED_PARTIAL=["@context","@id"];static PROPERTIES_PARTIAL={"@context":{type:"object",properties:{},required:[],additionalProperties:!1},"@id":{type:["string","null"],format:"uri"},"@type":{oneOf:[{type:"string",format:"uri"},{type:"array",minItems:1,items:{type:"string",format:"uri"},uniqueItems:!0}]}};static LEGACY_ID_TYPING={type:"string",format:"uri"};static acceptEitherIdTyping(e,t){const r=n.ReaderUtil.getNode(t,"@id");null!==r&&JSON.stringify(r)===JSON.stringify(a.LEGACY_ID_TYPING)&&(e["@id"]=n.ReaderUtil.deepClone(a.LEGACY_ID_TYPING))}static REQUIRED_PARTIAL_KEY_MAP;static PROPERTIES_PARTIAL_KEY_MAP=new Map;static CONTEXT_VERBATIM_NO_BIBO;static{Object.keys(a.PROPERTIES_PARTIAL).forEach(e=>{this.PROPERTIES_PARTIAL_KEY_MAP.set(e,!0)}),this.REQUIRED_PARTIAL_KEY_MAP=this.REQUIRED_PARTIAL.reduce((e,t)=>(e.set(t,!0),e),new Map),n.ReaderUtil.deepFreeze(this.REQUIRED_PARTIAL),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL),n.ReaderUtil.deepFreeze(this.REQUIRED_PARTIAL_KEY_MAP),n.ReaderUtil.deepFreeze(this.PROPERTIES_PARTIAL_KEY_MAP)}}t.JsonTemplateElementContent=a},9932(e,t,r){t.JsonTemplateFieldContentDynamic=void 0;const n=r(8748),a=r(2733),i=r(936);class s{static CONTEXT_VERBATIM={xsd:"http://www.w3.org/2001/XMLSchema#",pav:"http://purl.org/pav/",bibo:"http://purl.org/ontology/bibo/",oslc:"http://open-services.net/ns/core#",schema:"http://schema.org/",skos:"http://www.w3.org/2004/02/skos/core#","schema:name":{"@type":"xsd:string"},"schema:description":{"@type":"xsd:string"},"skos:prefLabel":{"@type":"xsd:string"},"skos:altLabel":{"@type":"xsd:string"},"pav:createdOn":{"@type":"xsd:dateTime"},"pav:createdBy":{"@type":"@id"},"pav:lastUpdatedOn":{"@type":"xsd:dateTime"},"oslc:modifiedBy":{"@type":"@id"}};static PROPERTIES_VERBATIM_LITERAL={"@type":{type:"string",format:"uri"},"rdfs:label":{type:["string","null"]},"@value":{type:["string","null"]},"@language":{type:["string","null"],minLength:1}};static PROPERTIES_VERBATIM_IRI={"@type":{type:"string",format:"uri"},"@id":{type:"string",format:"uri"},"rdfs:label":{type:["string","null"]},"skos:notation":{type:["string","null"]}};static ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_OUTSIDE={type:"object",properties:{"@value":{type:["string","null"]},"@type":{type:"string",format:"uri"}},required:["@value"],additionalProperties:!1};static ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE={type:"string",format:"uri"};static PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE;static PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION;static CONTEXT_VERBATIM_NO_BIBO;static{n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM),n.ReaderUtil.deepFreeze(this.PROPERTIES_VERBATIM_LITERAL),this.PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE=n.ReaderUtil.deepClone(this.PROPERTIES_VERBATIM_LITERAL),n.ReaderUtil.deleteNodeKey(this.PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE,a.JsonSchema.atLanguage),n.ReaderUtil.deepFreeze(this.PROPERTIES_VERBATIM_LITERAL_NO_AT_LANGUAGE),this.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION=n.ReaderUtil.deepClone(this.PROPERTIES_VERBATIM_IRI),n.ReaderUtil.deleteNodeKey(this.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION,i.CedarModel.skosNotation),n.ReaderUtil.deepFreeze(this.PROPERTIES_VERBATIM_IRI_NO_SKOS_NOTATION),this.CONTEXT_VERBATIM_NO_BIBO=n.ReaderUtil.deepClone(this.CONTEXT_VERBATIM),n.ReaderUtil.deleteNodeKey(this.CONTEXT_VERBATIM_NO_BIBO,"bibo"),n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM_NO_BIBO),n.ReaderUtil.deepFreeze(this.PROPERTIES_VERBATIM_IRI),n.ReaderUtil.deepFreeze(this.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_OUTSIDE),n.ReaderUtil.deepFreeze(this.ADDITIONAL_PROPERTIES_VERBATIM_ATTRIBUTE_VALUE_INSIDE)}}t.JsonTemplateFieldContentDynamic=s},9251(e,t,r){t.JsonTemplateFieldContentStatic=void 0;const n=r(8748);class a{static CONTEXT_VERBATIM={schema:"http://schema.org/",pav:"http://purl.org/pav/",bibo:"http://purl.org/ontology/bibo/",oslc:"http://open-services.net/ns/core#"};static CONTEXT_VERBATIM_NO_BIBO;static{n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM),this.CONTEXT_VERBATIM_NO_BIBO=n.ReaderUtil.deepClone(this.CONTEXT_VERBATIM),n.ReaderUtil.deleteNodeKey(this.CONTEXT_VERBATIM_NO_BIBO,"bibo"),n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM_NO_BIBO)}}t.JsonTemplateFieldContentStatic=a},350(e,t,r){t.JsonTemplateInstanceContent=void 0;const n=r(8748);class a{static CONTEXT_VERBATIM={rdfs:"http://www.w3.org/2000/01/rdf-schema#",xsd:"http://www.w3.org/2001/XMLSchema#",pav:"http://purl.org/pav/",schema:"http://schema.org/",oslc:"http://open-services.net/ns/core#",skos:"http://www.w3.org/2004/02/skos/core#","rdfs:label":{"@type":"xsd:string"},"schema:isBasedOn":{"@type":"@id"},"schema:name":{"@type":"xsd:string"},"schema:description":{"@type":"xsd:string"},"pav:derivedFrom":{"@type":"@id"},"pav:createdOn":{"@type":"xsd:dateTime"},"pav:createdBy":{"@type":"@id"},"pav:lastUpdatedOn":{"@type":"xsd:dateTime"},"oslc:modifiedBy":{"@type":"@id"},"skos:notation":{"@type":"xsd:string"}};static{n.ReaderUtil.deepFreeze(this.CONTEXT_VERBATIM)}}t.JsonTemplateInstanceContent=a},3198(e,t,r){r.d(t,{Alias:()=>x,CST:()=>n,Composer:()=>er,Document:()=>_t,Lexer:()=>Nr,LineCounter:()=>wr,Pair:()=>Ce,Parser:()=>Ur,Scalar:()=>W,Schema:()=>St,YAMLError:()=>Nt,YAMLMap:()=>Se,YAMLParseError:()=>wt,YAMLSeq:()=>ve,YAMLWarning:()=>Lt,default:()=>Wr,isAlias:()=>m,isCollection:()=>E,isDocument:()=>p,isMap:()=>h,isNode:()=>C,isPair:()=>f,isScalar:()=>T,isSeq:()=>y,parse:()=>Pr,parseAllDocuments:()=>Yr,parseDocument:()=>xr,stringify:()=>kr,visit:()=>R,visitAsync:()=>_}),r.r(t);var n={};r.r(n),r.d(n,{BOM:()=>hr,DOCUMENT:()=>fr,FLOW_END:()=>Tr,SCALAR:()=>yr,createScalarToken:()=>rr,isCollection:()=>Er,isScalar:()=>Cr,prettyToken:()=>gr,resolveAsScalar:()=>tr,setScalarValue:()=>nr,stringify:()=>sr,tokenType:()=>Ir,visit:()=>mr});var a={};r.r(a),r.d(a,{Alias:()=>x,CST:()=>n,Composer:()=>er,Document:()=>_t,Lexer:()=>Nr,LineCounter:()=>wr,Pair:()=>Ce,Parser:()=>Ur,Scalar:()=>W,Schema:()=>St,YAMLError:()=>Nt,YAMLMap:()=>Se,YAMLParseError:()=>wt,YAMLSeq:()=>ve,YAMLWarning:()=>Lt,isAlias:()=>m,isCollection:()=>E,isDocument:()=>p,isMap:()=>h,isNode:()=>C,isPair:()=>f,isScalar:()=>T,isSeq:()=>y,parse:()=>Pr,parseAllDocuments:()=>Yr,parseDocument:()=>xr,stringify:()=>kr,visit:()=>R,visitAsync:()=>_});const i=Symbol.for("yaml.alias"),s=Symbol.for("yaml.document"),o=Symbol.for("yaml.map"),l=Symbol.for("yaml.pair"),c=Symbol.for("yaml.scalar"),d=Symbol.for("yaml.seq"),u=Symbol.for("yaml.node.type"),m=e=>!!e&&"object"==typeof e&&e[u]===i,p=e=>!!e&&"object"==typeof e&&e[u]===s,h=e=>!!e&&"object"==typeof e&&e[u]===o,f=e=>!!e&&"object"==typeof e&&e[u]===l,T=e=>!!e&&"object"==typeof e&&e[u]===c,y=e=>!!e&&"object"==typeof e&&e[u]===d;function E(e){if(e&&"object"==typeof e)switch(e[u]){case o:case d:return!0}return!1}function C(e){if(e&&"object"==typeof e)switch(e[u]){case i:case o:case c:case d:return!0}return!1}const g=e=>(T(e)||E(e))&&!!e.anchor,I=Symbol("break visit"),A=Symbol("skip children"),b=Symbol("remove node");function R(e,t){const r=N(t);p(e)?S(null,e.contents,r,Object.freeze([e]))===b&&(e.contents=null):S(null,e,r,Object.freeze([]))}function S(e,t,r,n){const a=w(e,t,r,n);if(C(a)||f(a))return L(e,n,a),S(e,a,r,n);if("symbol"!=typeof a)if(E(t)){n=Object.freeze(n.concat(t));for(let e=0;e<t.items.length;++e){const a=S(e,t.items[e],r,n);if("number"==typeof a)e=a-1;else{if(a===I)return I;a===b&&(t.items.splice(e,1),e-=1)}}}else if(f(t)){n=Object.freeze(n.concat(t));const e=S("key",t.key,r,n);if(e===I)return I;e===b&&(t.key=null);const a=S("value",t.value,r,n);if(a===I)return I;a===b&&(t.value=null)}return a}async function _(e,t){const r=N(t);p(e)?await v(null,e.contents,r,Object.freeze([e]))===b&&(e.contents=null):await v(null,e,r,Object.freeze([]))}async function v(e,t,r,n){const a=await w(e,t,r,n);if(C(a)||f(a))return L(e,n,a),v(e,a,r,n);if("symbol"!=typeof a)if(E(t)){n=Object.freeze(n.concat(t));for(let e=0;e<t.items.length;++e){const a=await v(e,t.items[e],r,n);if("number"==typeof a)e=a-1;else{if(a===I)return I;a===b&&(t.items.splice(e,1),e-=1)}}}else if(f(t)){n=Object.freeze(n.concat(t));const e=await v("key",t.key,r,n);if(e===I)return I;e===b&&(t.key=null);const a=await v("value",t.value,r,n);if(a===I)return I;a===b&&(t.value=null)}return a}function N(e){return"object"==typeof e&&(e.Collection||e.Node||e.Value)?Object.assign({Alias:e.Node,Map:e.Node,Scalar:e.Node,Seq:e.Node},e.Value&&{Map:e.Value,Scalar:e.Value,Seq:e.Value},e.Collection&&{Map:e.Collection,Seq:e.Collection},e):e}function w(e,t,r,n){return"function"==typeof r?r(e,t,n):h(t)?r.Map?.(e,t,n):y(t)?r.Seq?.(e,t,n):f(t)?r.Pair?.(e,t,n):T(t)?r.Scalar?.(e,t,n):m(t)?r.Alias?.(e,t,n):void 0}function L(e,t,r){const n=t[t.length-1];if(E(n))n.items[e]=r;else if(f(n))"key"===e?n.key=r:n.value=r;else{if(!p(n)){const e=m(n)?"alias":"scalar";throw new Error(`Cannot replace node with ${e} parent`)}n.contents=r}}R.BREAK=I,R.SKIP=A,R.REMOVE=b,_.BREAK=I,_.SKIP=A,_.REMOVE=b;const F={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},O=e=>e.replace(/[!,[\]{}]/g,e=>F[e]);class V{constructor(e,t){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},V.defaultYaml,e),this.tags=Object.assign({},V.defaultTags,t)}clone(){const e=new V(this.yaml,this.tags);return e.docStart=this.docStart,e}atDocument(){const e=new V(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:V.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},V.defaultTags)}return e}add(e,t){this.atNextDocument&&(this.yaml={explicit:V.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},V.defaultTags),this.atNextDocument=!1);const r=e.trim().split(/[ \t]+/),n=r.shift();switch(n){case"%TAG":{if(2!==r.length&&(t(0,"%TAG directive should contain exactly two parts"),r.length<2))return!1;const[e,n]=r;return this.tags[e]=n,!0}case"%YAML":{if(this.yaml.explicit=!0,1!==r.length)return t(0,"%YAML directive should contain exactly one part"),!1;const[e]=r;return"1.1"===e||"1.2"===e?(this.yaml.version=e,!0):(t(6,`Unsupported YAML version ${e}`,/^\d+\.\d+$/.test(e)),!1)}default:return t(0,`Unknown directive ${n}`,!0),!1}}tagName(e,t){if("!"===e)return"!";if("!"!==e[0])return t(`Not a valid tag: ${e}`),null;if("<"===e[1]){const r=e.slice(2,-1);return"!"===r||"!!"===r?(t(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(">"!==e[e.length-1]&&t("Verbatim tags must end with a >"),r)}const[,r,n]=e.match(/^(.*!)([^!]*)$/s);n||t(`The ${e} tag has no suffix`);const a=this.tags[r];if(a)try{return a+decodeURIComponent(n)}catch(e){return t(String(e)),null}return"!"===r?e:(t(`Could not resolve tag: ${e}`),null)}tagString(e){for(const[t,r]of Object.entries(this.tags))if(e.startsWith(r))return t+O(e.substring(r.length));return"!"===e[0]?e:`!<${e}>`}toString(e){const t=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],r=Object.entries(this.tags);let n;if(e&&r.length>0&&C(e.contents)){const t={};R(e.contents,(e,r)=>{C(r)&&r.tag&&(t[r.tag]=!0)}),n=Object.keys(t)}else n=[];for(const[a,i]of r)"!!"===a&&"tag:yaml.org,2002:"===i||e&&!n.some(e=>e.startsWith(i))||t.push(`%TAG ${a} ${i}`);return t.join("\n")}}function B(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){const t=JSON.stringify(e);throw new Error(`Anchor must not contain whitespace or control characters: ${t}`)}return!0}function D(e){const t=new Set;return R(e,{Value(e,r){r.anchor&&t.add(r.anchor)}}),t}function M(e,t){for(let r=1;;++r){const n=`${e}${r}`;if(!t.has(n))return n}}function U(e,t,r,n){if(n&&"object"==typeof n)if(Array.isArray(n))for(let t=0,r=n.length;t<r;++t){const r=n[t],a=U(e,n,String(t),r);void 0===a?delete n[t]:a!==r&&(n[t]=a)}else if(n instanceof Map)for(const t of Array.from(n.keys())){const r=n.get(t),a=U(e,n,t,r);void 0===a?n.delete(t):a!==r&&n.set(t,a)}else if(n instanceof Set)for(const t of Array.from(n)){const r=U(e,n,t,t);void 0===r?n.delete(t):r!==t&&(n.delete(t),n.add(r))}else for(const[t,r]of Object.entries(n)){const a=U(e,n,t,r);void 0===a?delete n[t]:a!==r&&(n[t]=a)}return e.call(t,r,n)}function J(e,t,r){if(Array.isArray(e))return e.map((e,t)=>J(e,String(t),r));if(e&&"function"==typeof e.toJSON){if(!r||!g(e))return e.toJSON(t,r);const n={aliasCount:0,count:1,res:void 0};r.anchors.set(e,n),r.onCreate=e=>{n.res=e,delete r.onCreate};const a=e.toJSON(t,r);return r.onCreate&&r.onCreate(a),a}return"bigint"!=typeof e||r?.keep?e:Number(e)}V.defaultYaml={explicit:!1,version:"1.2"},V.defaultTags={"!!":"tag:yaml.org,2002:"};class Y{constructor(e){Object.defineProperty(this,u,{value:e})}clone(){const e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:t,maxAliasCount:r,onAnchor:n,reviver:a}={}){if(!p(e))throw new TypeError("A document argument is required");const i={anchors:new Map,doc:e,keep:!0,mapAsMap:!0===t,mapKeyWarned:!1,maxAliasCount:"number"==typeof r?r:100},s=J(this,"",i);if("function"==typeof n)for(const{count:e,res:t}of i.anchors.values())n(t,e);return"function"==typeof a?U(a,{"":s},"",s):s}}class x extends Y{constructor(e){super(i),this.source=e,Object.defineProperty(this,"tag",{set(){throw new Error("Alias nodes cannot have tags")}})}resolve(e,t){if(0===t?.maxAliasCount)throw new ReferenceError("Alias resolution is disabled");let r,n;t?.aliasResolveCache?r=t.aliasResolveCache:(r=[],R(e,{Node:(e,t)=>{(m(t)||g(t))&&r.push(t)}}),t&&(t.aliasResolveCache=r));for(const e of r){if(e===this)break;e.anchor===this.source&&(n=e)}return n}toJSON(e,t){if(!t)return{source:this.source};const{anchors:r,doc:n,maxAliasCount:a}=t,i=this.resolve(n,t);if(!i){const e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new ReferenceError(e)}let s=r.get(i);if(s||(J(i,null,t),s=r.get(i)),void 0===s?.res)throw new ReferenceError("This should not happen: Alias anchor was not resolved?");if(a>=0&&(s.count+=1,0===s.aliasCount&&(s.aliasCount=P(n,i,r)),s.count*s.aliasCount>a))throw new ReferenceError("Excessive alias count indicates a resource exhaustion attack");return s.res}toString(e,t,r){const n=`*${this.source}`;if(e){if(B(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){const e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new Error(e)}if(e.implicitKey)return`${n} `}return n}}function P(e,t,r){if(m(t)){const n=t.resolve(e),a=r&&n&&r.get(n);return a?a.count*a.aliasCount:0}if(E(t)){let n=0;for(const a of t.items){const t=P(e,a,r);t>n&&(n=t)}return n}if(f(t)){const n=P(e,t.key,r),a=P(e,t.value,r);return Math.max(n,a)}return 1}const k=e=>!e||"function"!=typeof e&&"object"!=typeof e;class W extends Y{constructor(e){super(c),this.value=e}toJSON(e,t){return t?.keep?this.value:J(this.value,e,t)}toString(){return String(this.value)}}function K(e,t,r){if(p(e)&&(e=e.contents),C(e))return e;if(f(e)){const t=r.schema[o].createNode?.(r.schema,null,r);return t.items.push(e),t}(e instanceof String||e instanceof Number||e instanceof Boolean||"undefined"!=typeof BigInt&&e instanceof BigInt)&&(e=e.valueOf());const{aliasDuplicateObjects:n,onAnchor:a,onTagObj:i,schema:s,sourceObjects:l}=r;let c;if(n&&e&&"object"==typeof e){if(c=l.get(e),c)return c.anchor??(c.anchor=a(e)),new x(c.anchor);c={anchor:null,node:null},l.set(e,c)}t?.startsWith("!!")&&(t="tag:yaml.org,2002:"+t.slice(2));let u=function(e,t,r){if(t){const e=r.filter(e=>e.tag===t),n=e.find(e=>!e.format)??e[0];if(!n)throw new Error(`Tag ${t} not found`);return n}return r.find(t=>t.identify?.(e)&&!t.format)}(e,t,s.tags);if(!u){if(e&&"function"==typeof e.toJSON&&(e=e.toJSON()),!e||"object"!=typeof e){const t=new W(e);return c&&(c.node=t),t}u=e instanceof Map?s[o]:Symbol.iterator in Object(e)?s[d]:s[o]}i&&(i(u),delete r.onTagObj);const m=u?.createNode?u.createNode(r.schema,e,r):"function"==typeof u?.nodeClass?.from?u.nodeClass.from(r.schema,e,r):new W(e);return t?m.tag=t:u.default||(m.tag=u.tag),c&&(c.node=m),m}function j(e,t,r){let n=r;for(let e=t.length-1;e>=0;--e){const r=t[e];if("number"==typeof r&&Number.isInteger(r)&&r>=0){const e=[];e[r]=n,n=e}else n=new Map([[r,n]])}return K(n,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw new Error("This should not happen, please report a bug.")},schema:e,sourceObjects:new Map})}W.BLOCK_FOLDED="BLOCK_FOLDED",W.BLOCK_LITERAL="BLOCK_LITERAL",W.PLAIN="PLAIN",W.QUOTE_DOUBLE="QUOTE_DOUBLE",W.QUOTE_SINGLE="QUOTE_SINGLE";const G=e=>null==e||"object"==typeof e&&!!e[Symbol.iterator]().next().done;class X extends Y{constructor(e,t){super(e),Object.defineProperty(this,"schema",{value:t,configurable:!0,enumerable:!1,writable:!0})}clone(e){const t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(t.schema=e),t.items=t.items.map(t=>C(t)||f(t)?t.clone(e):t),this.range&&(t.range=this.range.slice()),t}addIn(e,t){if(G(e))this.add(t);else{const[r,...n]=e,a=this.get(r,!0);if(E(a))a.addIn(n,t);else{if(void 0!==a||!this.schema)throw new Error(`Expected YAML collection at ${r}. Remaining path: ${n}`);this.set(r,j(this.schema,n,t))}}}deleteIn(e){const[t,...r]=e;if(0===r.length)return this.delete(t);const n=this.get(t,!0);if(E(n))return n.deleteIn(r);throw new Error(`Expected YAML collection at ${t}. Remaining path: ${r}`)}getIn(e,t){const[r,...n]=e,a=this.get(r,!0);return 0===n.length?!t&&T(a)?a.value:a:E(a)?a.getIn(n,t):void 0}hasAllNullValues(e){return this.items.every(t=>{if(!f(t))return!1;const r=t.value;return null==r||e&&T(r)&&null==r.value&&!r.commentBefore&&!r.comment&&!r.tag})}hasIn(e){const[t,...r]=e;if(0===r.length)return this.has(t);const n=this.get(t,!0);return!!E(n)&&n.hasIn(r)}setIn(e,t){const[r,...n]=e;if(0===n.length)this.set(r,t);else{const e=this.get(r,!0);if(E(e))e.setIn(n,t);else{if(void 0!==e||!this.schema)throw new Error(`Expected YAML collection at ${r}. Remaining path: ${n}`);this.set(r,j(this.schema,n,t))}}}}const $=e=>e.replace(/^(?!$)(?: $)?/gm,"#");function q(e,t){return/^\n+$/.test(e)?e.substring(1):t?e.replace(/^(?! *$)/gm,t):e}const H=(e,t,r)=>e.endsWith("\n")?q(r,t):r.includes("\n")?"\n"+q(r,t):(e.endsWith(" ")?"":" ")+r,z="block",Q="quoted";function Z(e,t,r="flow",{indentAtStart:n,lineWidth:a=80,minContentWidth:i=20,onFold:s,onOverflow:o}={}){if(!a||a<0)return e;a<i&&(i=0);const l=Math.max(1+i,1+a-t.length);if(e.length<=l)return e;const c=[],d={};let u,m,p=a-t.length;"number"==typeof n&&(n>a-Math.max(2,i)?c.push(0):p=a-n);let h=!1,f=-1,T=-1,y=-1;r===z&&(f=ee(e,f,t.length),-1!==f&&(p=f+l));for(let n;n=e[f+=1];){if(r===Q&&"\\"===n){switch(T=f,e[f+1]){case"x":f+=3;break;case"u":f+=5;break;case"U":f+=9;break;default:f+=1}y=f}if("\n"===n)r===z&&(f=ee(e,f,t.length)),p=f+t.length+l,u=void 0;else{if(" "===n&&m&&" "!==m&&"\n"!==m&&"\t"!==m){const t=e[f+1];t&&" "!==t&&"\n"!==t&&"\t"!==t&&(u=f)}if(f>=p)if(u)c.push(u),p=u+l,u=void 0;else if(r===Q){for(;" "===m||"\t"===m;)m=n,n=e[f+=1],h=!0;const t=f>y+1?f-2:T-1;if(d[t])return e;c.push(t),d[t]=!0,p=t+l,u=void 0}else h=!0}m=n}if(h&&o&&o(),0===c.length)return e;s&&s();let E=e.slice(0,c[0]);for(let n=0;n<c.length;++n){const a=c[n],i=c[n+1]||e.length;0===a?E=`\n${t}${e.slice(0,i)}`:(r===Q&&d[a]&&(E+=`${e[a]}\\`),E+=`\n${t}${e.slice(a+1,i)}`)}return E}function ee(e,t,r){let n=t,a=t+1,i=e[a];for(;" "===i||"\t"===i;)if(t<a+r)i=e[++t];else{do{i=e[++t]}while(i&&"\n"!==i);n=t,a=t+1,i=e[a]}return n}const te=(e,t)=>({indentAtStart:t?e.indent.length:e.indentAtStart,lineWidth:e.options.lineWidth,minContentWidth:e.options.minContentWidth}),re=e=>/^(%|---|\.\.\.)/m.test(e);function ne(e,t){const r=JSON.stringify(e);if(t.options.doubleQuotedAsJSON)return r;const{implicitKey:n}=t,a=t.options.doubleQuotedMinMultiLineLength,i=t.indent||(re(e)?" ":"");let s="",o=0;for(let e=0,t=r[e];t;t=r[++e])if(" "===t&&"\\"===r[e+1]&&"n"===r[e+2]&&(s+=r.slice(o,e)+"\\ ",e+=1,o=e,t="\\"),"\\"===t)switch(r[e+1]){case"u":{s+=r.slice(o,e);const t=r.substr(e+2,4);switch(t){case"0000":s+="\\0";break;case"0007":s+="\\a";break;case"000b":s+="\\v";break;case"001b":s+="\\e";break;case"0085":s+="\\N";break;case"00a0":s+="\\_";break;case"2028":s+="\\L";break;case"2029":s+="\\P";break;default:"00"===t.substr(0,2)?s+="\\x"+t.substr(2):s+=r.substr(e,6)}e+=5,o=e+1}break;case"n":if(n||'"'===r[e+2]||r.length<a)e+=1;else{for(s+=r.slice(o,e)+"\n\n";"\\"===r[e+2]&&"n"===r[e+3]&&'"'!==r[e+4];)s+="\n",e+=2;s+=i," "===r[e+2]&&(s+="\\"),e+=1,o=e+1}break;default:e+=1}return s=o?s+r.slice(o):r,n?s:Z(s,i,"quoted",te(t,!1))}function ae(e,t){if(!1===t.options.singleQuote||t.implicitKey&&e.includes("\n")||/[ \t]\n|\n[ \t]/.test(e))return ne(e,t);const r=t.indent||(re(e)?" ":""),n="'"+e.replace(/'/g,"''").replace(/\n+/g,`$&\n${r}`)+"'";return t.implicitKey?n:Z(n,r,"flow",te(t,!1))}function ie(e,t){const{singleQuote:r}=t.options;let n;if(!1===r)n=ne;else{const t=e.includes('"'),a=e.includes("'");n=t&&!a?ae:a&&!t?ne:r?ae:ne}return n(e,t)}let se;try{se=new RegExp("(^|(?<!\n))\n+(?!\n|$)","g")}catch{se=/\n+(?!\n|$)/g}function oe({comment:e,type:t,value:r},n,a,i){const{blockQuote:s,commentString:o,lineWidth:l}=n.options;if(!s||/\n[\t ]+$/.test(r))return ie(r,n);const c=n.indent||(n.forceBlockIndent||re(r)?" ":""),d="literal"===s||"folded"!==s&&t!==W.BLOCK_FOLDED&&(t===W.BLOCK_LITERAL||!function(e,t,r){if(!t||t<0)return!1;const n=t-r,a=e.length;if(a<=n)return!1;for(let t=0,r=0;t<a;++t)if("\n"===e[t]){if(t-r>n)return!0;if(r=t+1,a-r<=n)return!1}return!0}(r,l,c.length));if(!r)return d?"|\n":">\n";let u,m;for(m=r.length;m>0;--m){const e=r[m-1];if("\n"!==e&&"\t"!==e&&" "!==e)break}let p=r.substring(m);const h=p.indexOf("\n");-1===h?u="-":r===p||h!==p.length-1?(u="+",i&&i()):u="",p&&(r=r.slice(0,-p.length),"\n"===p[p.length-1]&&(p=p.slice(0,-1)),p=p.replace(se,`$&${c}`));let f,T=!1,y=-1;for(f=0;f<r.length;++f){const e=r[f];if(" "===e)T=!0;else{if("\n"!==e)break;y=f}}let E=r.substring(0,y<f?y+1:f);E&&(r=r.substring(E.length),E=E.replace(/\n+/g,`$&${c}`));let C=(T?c?"2":"1":"")+u;if(e&&(C+=" "+o(e.replace(/ ?[\r\n]+/g," ")),a&&a()),!d){const e=r.replace(/\n+/g,"\n$&").replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${c}`);let a=!1;const i=te(n,!0);"folded"!==s&&t!==W.BLOCK_FOLDED&&(i.onOverflow=()=>{a=!0});const o=Z(`${E}${e}${p}`,c,"block",i);if(!a)return`>${C}\n${c}${o}`}return`|${C}\n${c}${E}${r=r.replace(/\n+/g,`$&${c}`)}${p}`}function le(e,t,r,n){const{implicitKey:a,inFlow:i}=t,s="string"==typeof e.value?e:Object.assign({},e,{value:String(e.value)});let{type:o}=e;o!==W.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(s.value)&&(o=W.QUOTE_DOUBLE);const l=e=>{switch(e){case W.BLOCK_FOLDED:case W.BLOCK_LITERAL:return a||i?ie(s.value,t):oe(s,t,r,n);case W.QUOTE_DOUBLE:return ne(s.value,t);case W.QUOTE_SINGLE:return ae(s.value,t);case W.PLAIN:return function(e,t,r,n){const{type:a,value:i}=e,{actualString:s,implicitKey:o,indent:l,indentStep:c,inFlow:d}=t;if(o&&i.includes("\n")||d&&/[[\]{},]/.test(i))return ie(i,t);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(i))return o||d||!i.includes("\n")?ie(i,t):oe(e,t,r,n);if(!o&&!d&&a!==W.PLAIN&&i.includes("\n"))return oe(e,t,r,n);if(re(i)){if(""===l)return t.forceBlockIndent=!0,oe(e,t,r,n);if(o&&l===c)return ie(i,t)}const u=i.replace(/\n+/g,`$&\n${l}`);if(s){const e=e=>e.default&&"tag:yaml.org,2002:str"!==e.tag&&e.test?.test(u),{compat:r,tags:n}=t.doc.schema;if(n.some(e)||r?.some(e))return ie(i,t)}return o?u:Z(u,l,"flow",te(t,!1))}(s,t,r,n);default:return null}};let c=l(o);if(null===c){const{defaultKeyType:e,defaultStringType:r}=t.options,n=a&&e||r;if(c=l(n),null===c)throw new Error(`Unsupported default string type ${n}`)}return c}function ce(e,t){const r=Object.assign({blockQuote:!0,commentString:$,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:"true",verifyAliasOrder:!0},e.schema.toStringOptions,t);let n;switch(r.collectionStyle){case"block":n=!1;break;case"flow":n=!0;break;default:n=null}return{anchors:new Set,doc:e,flowCollectionPadding:r.flowCollectionPadding?" ":"",indent:"",indentStep:"number"==typeof r.indent?" ".repeat(r.indent):" ",inFlow:n,options:r}}function de(e,t,r,n){if(f(e))return e.toString(t,r,n);if(m(e)){if(t.doc.directives)return e.toString(t);if(t.resolvedAliases?.has(e))throw new TypeError("Cannot stringify circular structure without alias nodes");t.resolvedAliases?t.resolvedAliases.add(e):t.resolvedAliases=new Set([e]),e=e.resolve(t.doc)}let a;const i=C(e)?e:t.doc.createNode(e,{onTagObj:e=>a=e});a??(a=function(e,t){if(t.tag){const r=e.filter(e=>e.tag===t.tag);if(r.length>0)return r.find(e=>e.format===t.format)??r[0]}let r,n;if(T(t)){n=t.value;let a=e.filter(e=>e.identify?.(n));if(a.length>1){const e=a.filter(e=>e.test);e.length>0&&(a=e)}r=a.find(e=>e.format===t.format)??a.find(e=>!e.format)}else n=t,r=e.find(e=>e.nodeClass&&n instanceof e.nodeClass);if(!r)throw new Error(`Tag not resolved for ${n?.constructor?.name??(null===n?"null":typeof n)} value`);return r}(t.doc.schema.tags,i));const s=function(e,t,{anchors:r,doc:n}){if(!n.directives)return"";const a=[],i=(T(e)||E(e))&&e.anchor;i&&B(i)&&(r.add(i),a.push(`&${i}`));const s=e.tag??(t.default?null:t.tag);return s&&a.push(n.directives.tagString(s)),a.join(" ")}(i,a,t);s.length>0&&(t.indentAtStart=(t.indentAtStart??0)+s.length+1);const o="function"==typeof a.stringify?a.stringify(i,t,r,n):T(i)?le(i,t,r,n):i.toString(t,r,n);return s?T(i)||"{"===o[0]||"["===o[0]?`${s} ${o}`:`${s}\n${t.indent}${o}`:o}function ue(e,t){"debug"!==e&&"warn"!==e||console.warn(t)}const me="<<",pe={identify:e=>e===me||"symbol"==typeof e&&e.description===me,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new W(Symbol(me)),{addToJSMap:he}),stringify:()=>me};function he(e,t,r){const n=Te(e,r);if(y(n))for(const r of n.items)fe(e,t,r);else if(Array.isArray(n))for(const r of n)fe(e,t,r);else fe(e,t,n)}function fe(e,t,r){const n=Te(e,r);if(!h(n))throw new Error("Merge sources must be maps or map aliases");const a=n.toJSON(null,e,Map);for(const[e,r]of a)t instanceof Map?t.has(e)||t.set(e,r):t instanceof Set?t.add(e):Object.prototype.hasOwnProperty.call(t,e)||Object.defineProperty(t,e,{value:r,writable:!0,enumerable:!0,configurable:!0});return t}function Te(e,t){return e&&m(t)?t.resolve(e.doc,e):t}function ye(e,t,{key:r,value:n}){if(C(r)&&r.addToJSMap)r.addToJSMap(e,t,n);else if(((e,t)=>(pe.identify(t)||T(t)&&(!t.type||t.type===W.PLAIN)&&pe.identify(t.value))&&e?.doc.schema.tags.some(e=>e.tag===pe.tag&&e.default))(e,r))he(e,t,n);else{const a=J(r,"",e);if(t instanceof Map)t.set(a,J(n,a,e));else if(t instanceof Set)t.add(a);else{const i=function(e,t,r){if(null===t)return"";if("object"!=typeof t)return String(t);if(C(e)&&r?.doc){const t=ce(r.doc,{});t.anchors=new Set;for(const e of r.anchors.keys())t.anchors.add(e.anchor);t.inFlow=!0,t.inStringifyKey=!0;const n=e.toString(t);if(!r.mapKeyWarned){let e=JSON.stringify(n);e.length>40&&(e=e.substring(0,36)+'..."'),ue(r.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${e}. Set mapAsMap: true to use object keys.`),r.mapKeyWarned=!0}return n}return JSON.stringify(t)}(r,a,e),s=J(n,i,e);i in t?Object.defineProperty(t,i,{value:s,writable:!0,enumerable:!0,configurable:!0}):t[i]=s}}return t}function Ee(e,t,r){const n=K(e,void 0,r),a=K(t,void 0,r);return new Ce(n,a)}class Ce{constructor(e,t=null){Object.defineProperty(this,u,{value:l}),this.key=e,this.value=t}clone(e){let{key:t,value:r}=this;return C(t)&&(t=t.clone(e)),C(r)&&(r=r.clone(e)),new Ce(t,r)}toJSON(e,t){return ye(t,t?.mapAsMap?new Map:{},this)}toString(e,t,r){return e?.doc?function({key:e,value:t},r,n,a){const{allNullValues:i,doc:s,indent:o,indentStep:l,options:{commentString:c,indentSeq:d,simpleKeys:u}}=r;let m=C(e)&&e.comment||null;if(u){if(m)throw new Error("With simple keys, key nodes cannot have comments");if(E(e)||!C(e)&&"object"==typeof e)throw new Error("With simple keys, collection cannot be used as a key value")}let p=!u&&(!e||m&&null==t&&!r.inFlow||E(e)||(T(e)?e.type===W.BLOCK_FOLDED||e.type===W.BLOCK_LITERAL:"object"==typeof e));r=Object.assign({},r,{allNullValues:!1,implicitKey:!p&&(u||!i),indent:o+l});let h,f,g,I=!1,A=!1,b=de(e,r,()=>I=!0,()=>A=!0);if(!p&&!r.inFlow&&b.length>1024){if(u)throw new Error("With simple keys, single line scalar must not span more than 1024 characters");p=!0}if(r.inFlow){if(i||null==t)return I&&n&&n(),""===b?"?":p?`? ${b}`:b}else if(i&&!u||null==t&&p)return b=`? ${b}`,m&&!I?b+=H(b,r.indent,c(m)):A&&a&&a(),b;I&&(m=null),p?(m&&(b+=H(b,r.indent,c(m))),b=`? ${b}\n${o}:`):(b=`${b}:`,m&&(b+=H(b,r.indent,c(m)))),C(t)?(h=!!t.spaceBefore,f=t.commentBefore,g=t.comment):(h=!1,f=null,g=null,t&&"object"==typeof t&&(t=s.createNode(t))),r.implicitKey=!1,p||m||!T(t)||(r.indentAtStart=b.length+1),A=!1,d||!(l.length>=2)||r.inFlow||p||!y(t)||t.flow||t.tag||t.anchor||(r.indent=r.indent.substring(2));let R=!1;const S=de(t,r,()=>R=!0,()=>A=!0);let _=" ";if(m||h||f)_=h?"\n":"",f&&(_+=`\n${q(c(f),r.indent)}`),""!==S||r.inFlow?_+=`\n${r.indent}`:"\n"===_&&g&&(_="\n\n");else if(!p&&E(t)){const e=S[0],n=S.indexOf("\n"),a=-1!==n,i=r.inFlow??t.flow??0===t.items.length;if(a||!i){let t=!1;if(a&&("&"===e||"!"===e)){let r=S.indexOf(" ");"&"===e&&-1!==r&&r<n&&"!"===S[r+1]&&(r=S.indexOf(" ",r+1)),(-1===r||n<r)&&(t=!0)}t||(_=`\n${r.indent}`)}}else""!==S&&"\n"!==S[0]||(_="");return b+=_+S,r.inFlow?R&&n&&n():g&&!R?b+=H(b,r.indent,c(g)):A&&a&&a(),b}(this,e,t,r):JSON.stringify(this)}}function ge(e,t,r){return(t.inFlow??e.flow?Ae:Ie)(e,t,r)}function Ie({comment:e,items:t},r,{blockItemPrefix:n,flowChars:a,itemIndent:i,onChompKeep:s,onComment:o}){const{indent:l,options:{commentString:c}}=r,d=Object.assign({},r,{indent:i,type:null});let u=!1;const m=[];for(let e=0;e<t.length;++e){const a=t[e];let s=null;if(C(a))!u&&a.spaceBefore&&m.push(""),be(r,m,a.commentBefore,u),a.comment&&(s=a.comment);else if(f(a)){const e=C(a.key)?a.key:null;e&&(!u&&e.spaceBefore&&m.push(""),be(r,m,e.commentBefore,u))}u=!1;let o=de(a,d,()=>s=null,()=>u=!0);s&&(o+=H(o,i,c(s))),u&&s&&(u=!1),m.push(n+o)}let p;if(0===m.length)p=a.start+a.end;else{p=m[0];for(let e=1;e<m.length;++e){const t=m[e];p+=t?`\n${l}${t}`:"\n"}}return e?(p+="\n"+q(c(e),l),o&&o()):u&&s&&s(),p}function Ae({items:e},t,{flowChars:r,itemIndent:n}){const{indent:a,indentStep:i,flowCollectionPadding:s,options:{commentString:o}}=t;n+=i;const l=Object.assign({},t,{indent:n,inFlow:!0,type:null});let c=!1,d=0;const u=[];for(let r=0;r<e.length;++r){const a=e[r];let i=null;if(C(a))a.spaceBefore&&u.push(""),be(t,u,a.commentBefore,!1),a.comment&&(i=a.comment);else if(f(a)){const e=C(a.key)?a.key:null;e&&(e.spaceBefore&&u.push(""),be(t,u,e.commentBefore,!1),e.comment&&(c=!0));const r=C(a.value)?a.value:null;r?(r.comment&&(i=r.comment),r.commentBefore&&(c=!0)):null==a.value&&e?.comment&&(i=e.comment)}i&&(c=!0);let s=de(a,l,()=>i=null);c||(c=u.length>d||s.includes("\n")),r<e.length-1?s+=",":t.options.trailingComma&&(t.options.lineWidth>0&&(c||(c=u.reduce((e,t)=>e+t.length+2,2)+(s.length+2)>t.options.lineWidth)),c&&(s+=",")),i&&(s+=H(s,n,o(i))),u.push(s),d=u.length}const{start:m,end:p}=r;if(0===u.length)return m+p;if(!c){const e=u.reduce((e,t)=>e+t.length+2,2);c=t.options.lineWidth>0&&e>t.options.lineWidth}if(c){let e=m;for(const t of u)e+=t?`\n${i}${a}${t}`:"\n";return`${e}\n${a}${p}`}return`${m}${s}${u.join(" ")}${s}${p}`}function be({indent:e,options:{commentString:t}},r,n,a){if(n&&a&&(n=n.replace(/^\n+/,"")),n){const a=q(t(n),e);r.push(a.trimStart())}}function Re(e,t){const r=T(t)?t.value:t;for(const n of e)if(f(n)){if(n.key===t||n.key===r)return n;if(T(n.key)&&n.key.value===r)return n}}class Se extends X{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(o,e),this.items=[]}static from(e,t,r){const{keepUndefined:n,replacer:a}=r,i=new this(e),s=(e,s)=>{if("function"==typeof a)s=a.call(t,e,s);else if(Array.isArray(a)&&!a.includes(e))return;(void 0!==s||n)&&i.items.push(Ee(e,s,r))};if(t instanceof Map)for(const[e,r]of t)s(e,r);else if(t&&"object"==typeof t)for(const e of Object.keys(t))s(e,t[e]);return"function"==typeof e.sortMapEntries&&i.items.sort(e.sortMapEntries),i}add(e,t){let r;r=f(e)?e:e&&"object"==typeof e&&"key"in e?new Ce(e.key,e.value):new Ce(e,e?.value);const n=Re(this.items,r.key),a=this.schema?.sortMapEntries;if(n){if(!t)throw new Error(`Key ${r.key} already set`);T(n.value)&&k(r.value)?n.value.value=r.value:n.value=r.value}else if(a){const e=this.items.findIndex(e=>a(r,e)<0);-1===e?this.items.push(r):this.items.splice(e,0,r)}else this.items.push(r)}delete(e){const t=Re(this.items,e);return!!t&&this.items.splice(this.items.indexOf(t),1).length>0}get(e,t){const r=Re(this.items,e),n=r?.value;return(!t&&T(n)?n.value:n)??void 0}has(e){return!!Re(this.items,e)}set(e,t){this.add(new Ce(e,t),!0)}toJSON(e,t,r){const n=r?new r:t?.mapAsMap?new Map:{};t?.onCreate&&t.onCreate(n);for(const e of this.items)ye(t,n,e);return n}toString(e,t,r){if(!e)return JSON.stringify(this);for(const e of this.items)if(!f(e))throw new Error(`Map items must all be pairs; found ${JSON.stringify(e)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),ge(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:r,onComment:t})}}const _e={collection:"map",default:!0,nodeClass:Se,tag:"tag:yaml.org,2002:map",resolve:(e,t)=>(h(e)||t("Expected a mapping for this tag"),e),createNode:(e,t,r)=>Se.from(e,t,r)};class ve extends X{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(d,e),this.items=[]}add(e){this.items.push(e)}delete(e){const t=Ne(e);return"number"==typeof t&&this.items.splice(t,1).length>0}get(e,t){const r=Ne(e);if("number"!=typeof r)return;const n=this.items[r];return!t&&T(n)?n.value:n}has(e){const t=Ne(e);return"number"==typeof t&&t<this.items.length}set(e,t){const r=Ne(e);if("number"!=typeof r)throw new Error(`Expected a valid index, not ${e}.`);const n=this.items[r];T(n)&&k(t)?n.value=t:this.items[r]=t}toJSON(e,t){const r=[];t?.onCreate&&t.onCreate(r);let n=0;for(const e of this.items)r.push(J(e,String(n++),t));return r}toString(e,t,r){return e?ge(this,e,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:(e.indent||"")+" ",onChompKeep:r,onComment:t}):JSON.stringify(this)}static from(e,t,r){const{replacer:n}=r,a=new this(e);if(t&&Symbol.iterator in Object(t)){let e=0;for(let i of t){if("function"==typeof n){const r=t instanceof Set?i:String(e++);i=n.call(t,r,i)}a.items.push(K(i,void 0,r))}}return a}}function Ne(e){let t=T(e)?e.value:e;return t&&"string"==typeof t&&(t=Number(t)),"number"==typeof t&&Number.isInteger(t)&&t>=0?t:null}const we={collection:"seq",default:!0,nodeClass:ve,tag:"tag:yaml.org,2002:seq",resolve:(e,t)=>(y(e)||t("Expected a sequence for this tag"),e),createNode:(e,t,r)=>ve.from(e,t,r)},Le={identify:e=>"string"==typeof e,default:!0,tag:"tag:yaml.org,2002:str",resolve:e=>e,stringify:(e,t,r,n)=>le(e,t=Object.assign({actualString:!0},t),r,n)},Fe={identify:e=>null==e,createNode:()=>new W(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new W(null),stringify:({source:e},t)=>"string"==typeof e&&Fe.test.test(e)?e:t.options.nullStr},Oe={identify:e=>"boolean"==typeof e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:e=>new W("t"===e[0]||"T"===e[0]),stringify:({source:e,value:t},r)=>e&&Oe.test.test(e)&&t===("t"===e[0]||"T"===e[0])?e:t?r.options.trueStr:r.options.falseStr};function Ve({format:e,minFractionDigits:t,tag:r,value:n}){if("bigint"==typeof n)return String(n);const a="number"==typeof n?n:Number(n);if(!isFinite(a))return isNaN(a)?".nan":a<0?"-.inf":".inf";let i=Object.is(n,-0)?"-0":JSON.stringify(n);if(!e&&t&&(!r||"tag:yaml.org,2002:float"===r)&&/^-?\d/.test(i)&&!i.includes("e")){let e=i.indexOf(".");e<0&&(e=i.length,i+=".");let r=t-(i.length-e-1);for(;r-- >0;)i+="0"}return i}const Be={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>"nan"===e.slice(-3).toLowerCase()?NaN:"-"===e[0]?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:Ve},De={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e),stringify(e){const t=Number(e.value);return isFinite(t)?t.toExponential():Ve(e)}},Me={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(e){const t=new W(parseFloat(e)),r=e.indexOf(".");return-1!==r&&"0"===e[e.length-1]&&(t.minFractionDigits=e.length-r-1),t},stringify:Ve},Ue=e=>"bigint"==typeof e||Number.isInteger(e),Je=(e,t,r,{intAsBigInt:n})=>n?BigInt(e):parseInt(e.substring(t),r);function Ye(e,t,r){const{value:n}=e;return Ue(n)&&n>=0?r+n.toString(t):Ve(e)}const xe={identify:e=>Ue(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:(e,t,r)=>Je(e,2,8,r),stringify:e=>Ye(e,8,"0o")},Pe={identify:Ue,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:(e,t,r)=>Je(e,0,10,r),stringify:Ve},ke={identify:e=>Ue(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:(e,t,r)=>Je(e,2,16,r),stringify:e=>Ye(e,16,"0x")},We=[_e,we,Le,Fe,Oe,xe,Pe,ke,Be,De,Me];function Ke(e){return"bigint"==typeof e||Number.isInteger(e)}const je=({value:e})=>JSON.stringify(e),Ge=[_e,we].concat([{identify:e=>"string"==typeof e,default:!0,tag:"tag:yaml.org,2002:str",resolve:e=>e,stringify:je},{identify:e=>null==e,createNode:()=>new W(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:je},{identify:e=>"boolean"==typeof e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^true$|^false$/,resolve:e=>"true"===e,stringify:je},{identify:Ke,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(e,t,{intAsBigInt:r})=>r?BigInt(e):parseInt(e,10),stringify:({value:e})=>Ke(e)?e.toString():JSON.stringify(e)},{identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:e=>parseFloat(e),stringify:je}],{default:!0,tag:"",test:/^/,resolve:(e,t)=>(t(`Unresolved plain scalar ${JSON.stringify(e)}`),e)}),Xe={identify:e=>e instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve(e,t){if("function"==typeof atob){const t=atob(e.replace(/[\n\r]/g,"")),r=new Uint8Array(t.length);for(let e=0;e<t.length;++e)r[e]=t.charCodeAt(e);return r}return t("This environment does not support reading binary tags; either Buffer or atob is required"),e},stringify({comment:e,type:t,value:r},n,a,i){if(!r)return"";const s=r;let o;if("function"!=typeof btoa)throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required");{let e="";for(let t=0;t<s.length;++t)e+=String.fromCharCode(s[t]);o=btoa(e)}if(t??(t=W.BLOCK_LITERAL),t!==W.QUOTE_DOUBLE){const e=Math.max(n.options.lineWidth-n.indent.length,n.options.minContentWidth),r=Math.ceil(o.length/e),a=new Array(r);for(let t=0,n=0;t<r;++t,n+=e)a[t]=o.substr(n,e);o=a.join(t===W.BLOCK_LITERAL?"\n":" ")}return le({comment:e,type:t,value:o},n,a,i)}};function $e(e,t){if(y(e))for(let r=0;r<e.items.length;++r){let n=e.items[r];if(!f(n)){if(h(n)){n.items.length>1&&t("Each pair must have its own sequence indicator");const e=n.items[0]||new Ce(new W(null));if(n.commentBefore&&(e.key.commentBefore=e.key.commentBefore?`${n.commentBefore}\n${e.key.commentBefore}`:n.commentBefore),n.comment){const t=e.value??e.key;t.comment=t.comment?`${n.comment}\n${t.comment}`:n.comment}n=e}e.items[r]=f(n)?n:new Ce(n)}}else t("Expected a sequence for this tag");return e}function qe(e,t,r){const{replacer:n}=r,a=new ve(e);a.tag="tag:yaml.org,2002:pairs";let i=0;if(t&&Symbol.iterator in Object(t))for(let e of t){let s,o;if("function"==typeof n&&(e=n.call(t,String(i++),e)),Array.isArray(e)){if(2!==e.length)throw new TypeError(`Expected [key, value] tuple: ${e}`);s=e[0],o=e[1]}else if(e&&e instanceof Object){const t=Object.keys(e);if(1!==t.length)throw new TypeError(`Expected tuple with one key, not ${t.length} keys`);s=t[0],o=e[s]}else s=e;a.items.push(Ee(s,o,r))}return a}const He={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:$e,createNode:qe};class ze extends ve{constructor(){super(),this.add=Se.prototype.add.bind(this),this.delete=Se.prototype.delete.bind(this),this.get=Se.prototype.get.bind(this),this.has=Se.prototype.has.bind(this),this.set=Se.prototype.set.bind(this),this.tag=ze.tag}toJSON(e,t){if(!t)return super.toJSON(e);const r=new Map;t?.onCreate&&t.onCreate(r);for(const e of this.items){let n,a;if(f(e)?(n=J(e.key,"",t),a=J(e.value,n,t)):n=J(e,"",t),r.has(n))throw new Error("Ordered maps must not include duplicate keys");r.set(n,a)}return r}static from(e,t,r){const n=qe(e,t,r),a=new this;return a.items=n.items,a}}ze.tag="tag:yaml.org,2002:omap";const Qe={collection:"seq",identify:e=>e instanceof Map,nodeClass:ze,default:!1,tag:"tag:yaml.org,2002:omap",resolve(e,t){const r=$e(e,t),n=[];for(const{key:e}of r.items)T(e)&&(n.includes(e.value)?t(`Ordered maps must not include duplicate keys: ${e.value}`):n.push(e.value));return Object.assign(new ze,r)},createNode:(e,t,r)=>ze.from(e,t,r)};function Ze({value:e,source:t},r){return t&&(e?et:tt).test.test(t)?t:e?r.options.trueStr:r.options.falseStr}const et={identify:e=>!0===e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new W(!0),stringify:Ze},tt={identify:e=>!1===e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new W(!1),stringify:Ze},rt={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>"nan"===e.slice(-3).toLowerCase()?NaN:"-"===e[0]?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:Ve},nt={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e.replace(/_/g,"")),stringify(e){const t=Number(e.value);return isFinite(t)?t.toExponential():Ve(e)}},at={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(e){const t=new W(parseFloat(e.replace(/_/g,""))),r=e.indexOf(".");if(-1!==r){const n=e.substring(r+1).replace(/_/g,"");"0"===n[n.length-1]&&(t.minFractionDigits=n.length)}return t},stringify:Ve},it=e=>"bigint"==typeof e||Number.isInteger(e);function st(e,t,r,{intAsBigInt:n}){const a=e[0];if("-"!==a&&"+"!==a||(t+=1),e=e.substring(t).replace(/_/g,""),n){switch(r){case 2:e=`0b${e}`;break;case 8:e=`0o${e}`;break;case 16:e=`0x${e}`}const t=BigInt(e);return"-"===a?BigInt(-1)*t:t}const i=parseInt(e,r);return"-"===a?-1*i:i}function ot(e,t,r){const{value:n}=e;if(it(n)){const e=n.toString(t);return n<0?"-"+r+e.substr(1):r+e}return Ve(e)}const lt={identify:it,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(e,t,r)=>st(e,2,2,r),stringify:e=>ot(e,2,"0b")},ct={identify:it,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(e,t,r)=>st(e,1,8,r),stringify:e=>ot(e,8,"0")},dt={identify:it,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(e,t,r)=>st(e,0,10,r),stringify:Ve},ut={identify:it,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(e,t,r)=>st(e,2,16,r),stringify:e=>ot(e,16,"0x")};class mt extends Se{constructor(e){super(e),this.tag=mt.tag}add(e){let t;t=f(e)?e:e&&"object"==typeof e&&"key"in e&&"value"in e&&null===e.value?new Ce(e.key,null):new Ce(e,null),Re(this.items,t.key)||this.items.push(t)}get(e,t){const r=Re(this.items,e);return!t&&f(r)?T(r.key)?r.key.value:r.key:r}set(e,t){if("boolean"!=typeof t)throw new Error("Expected boolean value for set(key, value) in a YAML set, not "+typeof t);const r=Re(this.items,e);r&&!t?this.items.splice(this.items.indexOf(r),1):!r&&t&&this.items.push(new Ce(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,r){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,r);throw new Error("Set items must all have null values")}static from(e,t,r){const{replacer:n}=r,a=new this(e);if(t&&Symbol.iterator in Object(t))for(let e of t)"function"==typeof n&&(e=n.call(t,e,e)),a.items.push(Ee(e,null,r));return a}}mt.tag="tag:yaml.org,2002:set";const pt={collection:"map",identify:e=>e instanceof Set,nodeClass:mt,default:!1,tag:"tag:yaml.org,2002:set",createNode:(e,t,r)=>mt.from(e,t,r),resolve(e,t){if(h(e)){if(e.hasAllNullValues(!0))return Object.assign(new mt,e);t("Set items must all have null values")}else t("Expected a mapping for this tag");return e}};function ht(e,t){const r=e[0],n="-"===r||"+"===r?e.substring(1):e,a=e=>t?BigInt(e):Number(e),i=n.replace(/_/g,"").split(":").reduce((e,t)=>e*a(60)+a(t),a(0));return"-"===r?a(-1)*i:i}function ft(e){let{value:t}=e,r=e=>e;if("bigint"==typeof t)r=e=>BigInt(e);else if(isNaN(t)||!isFinite(t))return Ve(e);let n="";t<0&&(n="-",t*=r(-1));const a=r(60),i=[t%a];return t<60?i.unshift(0):(t=(t-i[0])/a,i.unshift(t%a),t>=60&&(t=(t-i[0])/a,i.unshift(t))),n+i.map(e=>String(e).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}const Tt={identify:e=>"bigint"==typeof e||Number.isInteger(e),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(e,t,{intAsBigInt:r})=>ht(e,r),stringify:ft},yt={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:e=>ht(e,!1),stringify:ft},Et={identify:e=>e instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve(e){const t=e.match(Et.test);if(!t)throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd");const[,r,n,a,i,s,o]=t.map(Number),l=t[7]?Number((t[7]+"00").substr(1,3)):0;let c=Date.UTC(r,n-1,a,i||0,s||0,o||0,l);const d=t[8];if(d&&"Z"!==d){let e=ht(d,!1);Math.abs(e)<30&&(e*=60),c-=6e4*e}return new Date(c)},stringify:({value:e})=>e?.toISOString().replace(/(T00:00:00)?\.000Z$/,"")??""},Ct=[_e,we,Le,Fe,et,tt,lt,ct,dt,ut,rt,nt,at,Xe,pe,Qe,He,pt,Tt,yt,Et],gt=new Map([["core",We],["failsafe",[_e,we,Le]],["json",Ge],["yaml11",Ct],["yaml-1.1",Ct]]),It={binary:Xe,bool:Oe,float:Me,floatExp:De,floatNaN:Be,floatTime:yt,int:Pe,intHex:ke,intOct:xe,intTime:Tt,map:_e,merge:pe,null:Fe,omap:Qe,pairs:He,seq:we,set:pt,timestamp:Et},At={"tag:yaml.org,2002:binary":Xe,"tag:yaml.org,2002:merge":pe,"tag:yaml.org,2002:omap":Qe,"tag:yaml.org,2002:pairs":He,"tag:yaml.org,2002:set":pt,"tag:yaml.org,2002:timestamp":Et};function bt(e,t,r){const n=gt.get(t);if(n&&!e)return r&&!n.includes(pe)?n.concat(pe):n.slice();let a=n;if(!a){if(!Array.isArray(e)){const e=Array.from(gt.keys()).filter(e=>"yaml11"!==e).map(e=>JSON.stringify(e)).join(", ");throw new Error(`Unknown schema "${t}"; use one of ${e} or define customTags array`)}a=[]}if(Array.isArray(e))for(const t of e)a=a.concat(t);else"function"==typeof e&&(a=e(a.slice()));return r&&(a=a.concat(pe)),a.reduce((e,t)=>{const r="string"==typeof t?It[t]:t;if(!r){const e=JSON.stringify(t),r=Object.keys(It).map(e=>JSON.stringify(e)).join(", ");throw new Error(`Unknown custom tag ${e}; use one of ${r}`)}return e.includes(r)||e.push(r),e},[])}const Rt=(e,t)=>e.key<t.key?-1:e.key>t.key?1:0;class St{constructor({compat:e,customTags:t,merge:r,resolveKnownTags:n,schema:a,sortMapEntries:i,toStringDefaults:s}){this.compat=Array.isArray(e)?bt(e,"compat"):e?bt(null,e):null,this.name="string"==typeof a&&a||"core",this.knownTags=n?At:{},this.tags=bt(t,this.name,r),this.toStringOptions=s??null,Object.defineProperty(this,o,{value:_e}),Object.defineProperty(this,c,{value:Le}),Object.defineProperty(this,d,{value:we}),this.sortMapEntries="function"==typeof i?i:!0===i?Rt:null}clone(){const e=Object.create(St.prototype,Object.getOwnPropertyDescriptors(this));return e.tags=this.tags.slice(),e}}class _t{constructor(e,t,r){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,u,{value:s});let n=null;"function"==typeof t||Array.isArray(t)?n=t:void 0===r&&t&&(r=t,t=void 0);const a=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},r);this.options=a;let{version:i}=a;r?._directives?(this.directives=r._directives.atDocument(),this.directives.yaml.explicit&&(i=this.directives.yaml.version)):this.directives=new V({version:i}),this.setSchema(i,r),this.contents=void 0===e?null:this.createNode(e,n,r)}clone(){const e=Object.create(_t.prototype,{[u]:{value:s}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=C(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){vt(this.contents)&&this.contents.add(e)}addIn(e,t){vt(this.contents)&&this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){const r=D(this);e.anchor=!t||r.has(t)?M(t||"a",r):t}return new x(e.anchor)}createNode(e,t,r){let n;if("function"==typeof t)e=t.call({"":e},"",e),n=t;else if(Array.isArray(t)){const e=e=>"number"==typeof e||e instanceof String||e instanceof Number,r=t.filter(e).map(String);r.length>0&&(t=t.concat(r)),n=t}else void 0===r&&t&&(r=t,t=void 0);const{aliasDuplicateObjects:a,anchorPrefix:i,flow:s,keepUndefined:o,onTagObj:l,tag:c}=r??{},{onAnchor:d,setAnchors:u,sourceObjects:m}=function(e,t){const r=[],n=new Map;let a=null;return{onAnchor:n=>{r.push(n),a??(a=D(e));const i=M(t,a);return a.add(i),i},setAnchors:()=>{for(const e of r){const t=n.get(e);if("object"!=typeof t||!t.anchor||!T(t.node)&&!E(t.node)){const t=new Error("Failed to resolve repeated object (this should not happen)");throw t.source=e,t}t.node.anchor=t.anchor}},sourceObjects:n}}(this,i||"a"),p=K(e,c,{aliasDuplicateObjects:a??!0,keepUndefined:o??!1,onAnchor:d,onTagObj:l,replacer:n,schema:this.schema,sourceObjects:m});return s&&E(p)&&(p.flow=!0),u(),p}createPair(e,t,r={}){const n=this.createNode(e,null,r),a=this.createNode(t,null,r);return new Ce(n,a)}delete(e){return!!vt(this.contents)&&this.contents.delete(e)}deleteIn(e){return G(e)?null!=this.contents&&(this.contents=null,!0):!!vt(this.contents)&&this.contents.deleteIn(e)}get(e,t){return E(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){return G(e)?!t&&T(this.contents)?this.contents.value:this.contents:E(this.contents)?this.contents.getIn(e,t):void 0}has(e){return!!E(this.contents)&&this.contents.has(e)}hasIn(e){return G(e)?void 0!==this.contents:!!E(this.contents)&&this.contents.hasIn(e)}set(e,t){null==this.contents?this.contents=j(this.schema,[e],t):vt(this.contents)&&this.contents.set(e,t)}setIn(e,t){G(e)?this.contents=t:null==this.contents?this.contents=j(this.schema,Array.from(e),t):vt(this.contents)&&this.contents.setIn(e,t)}setSchema(e,t={}){let r;switch("number"==typeof e&&(e=String(e)),e){case"1.1":this.directives?this.directives.yaml.version="1.1":this.directives=new V({version:"1.1"}),r={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":this.directives?this.directives.yaml.version=e:this.directives=new V({version:e}),r={resolveKnownTags:!0,schema:"core"};break;case null:this.directives&&delete this.directives,r=null;break;default:{const t=JSON.stringify(e);throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${t}`)}}if(t.schema instanceof Object)this.schema=t.schema;else{if(!r)throw new Error("With a null YAML version, the { schema: Schema } option is required");this.schema=new St(Object.assign(r,t))}}toJS({json:e,jsonArg:t,mapAsMap:r,maxAliasCount:n,onAnchor:a,reviver:i}={}){const s={anchors:new Map,doc:this,keep:!e,mapAsMap:!0===r,mapKeyWarned:!1,maxAliasCount:"number"==typeof n?n:100},o=J(this.contents,t??"",s);if("function"==typeof a)for(const{count:e,res:t}of s.anchors.values())a(t,e);return"function"==typeof i?U(i,{"":o},"",o):o}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw new Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){const t=JSON.stringify(e.indent);throw new Error(`"indent" option must be a positive integer, not ${t}`)}return function(e,t){const r=[];let n=!0===t.directives;if(!1!==t.directives&&e.directives){const t=e.directives.toString(e);t?(r.push(t),n=!0):e.directives.docStart&&(n=!0)}n&&r.push("---");const a=ce(e,t),{commentString:i}=a.options;if(e.commentBefore){1!==r.length&&r.unshift("");const t=i(e.commentBefore);r.unshift(q(t,""))}let s=!1,o=null;if(e.contents){if(C(e.contents)){if(e.contents.spaceBefore&&n&&r.push(""),e.contents.commentBefore){const t=i(e.contents.commentBefore);r.push(q(t,""))}a.forceBlockIndent=!!e.comment,o=e.contents.comment}const t=o?void 0:()=>s=!0;let l=de(e.contents,a,()=>o=null,t);o&&(l+=H(l,"",i(o))),"|"!==l[0]&&">"!==l[0]||"---"!==r[r.length-1]?r.push(l):r[r.length-1]=`--- ${l}`}else r.push(de(e.contents,a));if(e.directives?.docEnd)if(e.comment){const t=i(e.comment);t.includes("\n")?(r.push("..."),r.push(q(t,""))):r.push(`... ${t}`)}else r.push("...");else{let t=e.comment;t&&s&&(t=t.replace(/^\n+/,"")),t&&(s&&!o||""===r[r.length-1]||r.push(""),r.push(q(i(t),"")))}return r.join("\n")+"\n"}(this,e)}}function vt(e){if(E(e))return!0;throw new Error("Expected a YAML collection as document contents")}class Nt extends Error{constructor(e,t,r,n){super(),this.name=e,this.code=r,this.message=n,this.pos=t}}class wt extends Nt{constructor(e,t,r){super("YAMLParseError",e,t,r)}}class Lt extends Nt{constructor(e,t,r){super("YAMLWarning",e,t,r)}}const Ft=(e,t)=>r=>{if(-1===r.pos[0])return;r.linePos=r.pos.map(e=>t.linePos(e));const{line:n,col:a}=r.linePos[0];r.message+=` at line ${n}, column ${a}`;let i=a-1,s=e.substring(t.lineStarts[n-1],t.lineStarts[n]).replace(/[\n\r]+$/,"");if(i>=60&&s.length>80){const e=Math.min(i-39,s.length-79);s="…"+s.substring(e),i-=e-1}if(s.length>80&&(s=s.substring(0,79)+"…"),n>1&&/^ *$/.test(s.substring(0,i))){let r=e.substring(t.lineStarts[n-2],t.lineStarts[n-1]);r.length>80&&(r=r.substring(0,79)+"…\n"),s=r+s}if(/[^ ]/.test(s)){let e=1;const t=r.linePos[1];t?.line===n&&t.col>a&&(e=Math.max(1,Math.min(t.col-a,80-i)));const o=" ".repeat(i)+"^".repeat(e);r.message+=`:\n\n${s}\n${o}\n`}};function Ot(e,{flow:t,indicator:r,next:n,offset:a,onError:i,parentIndent:s,startOnNewline:o}){let l=!1,c=o,d=o,u="",m="",p=!1,h=!1,f=null,T=null,y=null,E=null,C=null,g=null,I=null;for(const a of e)switch(h&&("space"!==a.type&&"newline"!==a.type&&"comma"!==a.type&&i(a.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),h=!1),f&&(c&&"comment"!==a.type&&"newline"!==a.type&&i(f,"TAB_AS_INDENT","Tabs are not allowed as indentation"),f=null),a.type){case"space":t||"doc-start"===r&&"flow-collection"===n?.type||!a.source.includes("\t")||(f=a),d=!0;break;case"comment":{d||i(a,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const e=a.source.substring(1)||" ";u?u+=m+e:u=e,m="",c=!1;break}case"newline":c?u?u+=a.source:g&&"seq-item-ind"===r||(l=!0):m+=a.source,c=!0,p=!0,(T||y)&&(E=a),d=!0;break;case"anchor":T&&i(a,"MULTIPLE_ANCHORS","A node can have at most one anchor"),a.source.endsWith(":")&&i(a.offset+a.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0),T=a,I??(I=a.offset),c=!1,d=!1,h=!0;break;case"tag":y&&i(a,"MULTIPLE_TAGS","A node can have at most one tag"),y=a,I??(I=a.offset),c=!1,d=!1,h=!0;break;case r:(T||y)&&i(a,"BAD_PROP_ORDER",`Anchors and tags must be after the ${a.source} indicator`),g&&i(a,"UNEXPECTED_TOKEN",`Unexpected ${a.source} in ${t??"collection"}`),g=a,c="seq-item-ind"===r||"explicit-key-ind"===r,d=!1;break;case"comma":if(t){C&&i(a,"UNEXPECTED_TOKEN",`Unexpected , in ${t}`),C=a,c=!1,d=!1;break}default:i(a,"UNEXPECTED_TOKEN",`Unexpected ${a.type} token`),c=!1,d=!1}const A=e[e.length-1],b=A?A.offset+A.source.length:a;return h&&n&&"space"!==n.type&&"newline"!==n.type&&"comma"!==n.type&&("scalar"!==n.type||""!==n.source)&&i(n.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),f&&(c&&f.indent<=s||"block-map"===n?.type||"block-seq"===n?.type)&&i(f,"TAB_AS_INDENT","Tabs are not allowed as indentation"),{comma:C,found:g,spaceBefore:l,comment:u,hasNewline:p,anchor:T,tag:y,newlineAfterProp:E,end:b,start:I??b}}function Vt(e){if(!e)return null;switch(e.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(e.source.includes("\n"))return!0;if(e.end)for(const t of e.end)if("newline"===t.type)return!0;return!1;case"flow-collection":for(const t of e.items){for(const e of t.start)if("newline"===e.type)return!0;if(t.sep)for(const e of t.sep)if("newline"===e.type)return!0;if(Vt(t.key)||Vt(t.value))return!0}return!1;default:return!0}}function Bt(e,t,r){if("flow-collection"===t?.type){const n=t.end[0];n.indent!==e||"]"!==n.source&&"}"!==n.source||!Vt(t)||r(n,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}function Dt(e,t,r){const{uniqueKeys:n}=e.options;if(!1===n)return!1;const a="function"==typeof n?n:(e,t)=>e===t||T(e)&&T(t)&&e.value===t.value;return t.some(e=>a(e.key,r))}const Mt="All mapping items must start at the same column";function Ut(e,t,r,n){let a="";if(e){let i=!1,s="";for(const o of e){const{source:e,type:l}=o;switch(l){case"space":i=!0;break;case"comment":{r&&!i&&n(o,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const t=e.substring(1)||" ";a?a+=s+t:a=t,s="";break}case"newline":a&&(s+=e),i=!0;break;default:n(o,"UNEXPECTED_TOKEN",`Unexpected ${l} at node end`)}t+=e.length}}return{comment:a,offset:t}}const Jt="Block collections are not allowed within flow collections",Yt=e=>e&&("block-map"===e.type||"block-seq"===e.type);function xt(e,t,r,n,a,i){const s="block-map"===r.type?function({composeNode:e,composeEmptyNode:t},r,n,a,i){const s=new(i?.nodeClass??Se)(r.schema);r.atRoot&&(r.atRoot=!1);let o=n.offset,l=null;for(const i of n.items){const{start:c,key:d,sep:u,value:m}=i,p=Ot(c,{indicator:"explicit-key-ind",next:d??u?.[0],offset:o,onError:a,parentIndent:n.indent,startOnNewline:!0}),h=!p.found;if(h){if(d&&("block-seq"===d.type?a(o,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key"):"indent"in d&&d.indent!==n.indent&&a(o,"BAD_INDENT",Mt)),!p.anchor&&!p.tag&&!u){l=p.end,p.comment&&(s.comment?s.comment+="\n"+p.comment:s.comment=p.comment);continue}(p.newlineAfterProp||Vt(d))&&a(d??c[c.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else p.found?.indent!==n.indent&&a(o,"BAD_INDENT",Mt);r.atKey=!0;const f=p.end,T=d?e(r,d,p,a):t(r,f,c,null,p,a);r.schema.compat&&Bt(n.indent,d,a),r.atKey=!1,Dt(r,s.items,T)&&a(f,"DUPLICATE_KEY","Map keys must be unique");const y=Ot(u??[],{indicator:"map-value-ind",next:m,offset:T.range[2],onError:a,parentIndent:n.indent,startOnNewline:!d||"block-scalar"===d.type});if(o=y.end,y.found){h&&("block-map"!==m?.type||y.hasNewline||a(o,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings"),r.options.strict&&p.start<y.found.offset-1024&&a(T.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));const l=m?e(r,m,y,a):t(r,o,u,null,y,a);r.schema.compat&&Bt(n.indent,m,a),o=l.range[2];const c=new Ce(T,l);r.options.keepSourceTokens&&(c.srcToken=i),s.items.push(c)}else{h&&a(T.range,"MISSING_CHAR","Implicit map keys need to be followed by map values"),y.comment&&(T.comment?T.comment+="\n"+y.comment:T.comment=y.comment);const e=new Ce(T);r.options.keepSourceTokens&&(e.srcToken=i),s.items.push(e)}}return l&&l<o&&a(l,"IMPOSSIBLE","Map comment with trailing content"),s.range=[n.offset,o,l??o],s}(e,t,r,n,i):"block-seq"===r.type?function({composeNode:e,composeEmptyNode:t},r,n,a,i){const s=new(i?.nodeClass??ve)(r.schema);r.atRoot&&(r.atRoot=!1),r.atKey&&(r.atKey=!1);let o=n.offset,l=null;for(const{start:i,value:c}of n.items){const d=Ot(i,{indicator:"seq-item-ind",next:c,offset:o,onError:a,parentIndent:n.indent,startOnNewline:!0});if(!d.found){if(!(d.anchor||d.tag||c)){l=d.end,d.comment&&(s.comment=d.comment);continue}"block-seq"===c?.type?a(d.end,"BAD_INDENT","All sequence items must start at the same column"):a(o,"MISSING_CHAR","Sequence item without - indicator")}const u=c?e(r,c,d,a):t(r,d.end,i,null,d,a);r.schema.compat&&Bt(n.indent,c,a),o=u.range[2],s.items.push(u)}return s.range=[n.offset,o,l??o],s}(e,t,r,n,i):function({composeNode:e,composeEmptyNode:t},r,n,a,i){const s="{"===n.start.source,o=s?"flow map":"flow sequence",l=new(i?.nodeClass??(s?Se:ve))(r.schema);l.flow=!0;const c=r.atRoot;c&&(r.atRoot=!1),r.atKey&&(r.atKey=!1);let d=n.offset+n.start.source.length;for(let i=0;i<n.items.length;++i){const c=n.items[i],{start:u,key:m,sep:p,value:h}=c,T=Ot(u,{flow:o,indicator:"explicit-key-ind",next:m??p?.[0],offset:d,onError:a,parentIndent:n.indent,startOnNewline:!1});if(!T.found){if(!(T.anchor||T.tag||p||h)){0===i&&T.comma?a(T.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${o}`):i<n.items.length-1&&a(T.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${o}`),T.comment&&(l.comment?l.comment+="\n"+T.comment:l.comment=T.comment),d=T.end;continue}!s&&r.options.strict&&Vt(m)&&a(m,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(0===i)T.comma&&a(T.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${o}`);else if(T.comma||a(T.start,"MISSING_CHAR",`Missing , between ${o} items`),T.comment){let e="";e:for(const t of u)switch(t.type){case"comma":case"space":break;case"comment":e=t.source.substring(1);break e;default:break e}if(e){let t=l.items[l.items.length-1];f(t)&&(t=t.value??t.key),t.comment?t.comment+="\n"+e:t.comment=e,T.comment=T.comment.substring(e.length+1)}}if(s||p||T.found){r.atKey=!0;const i=T.end,f=m?e(r,m,T,a):t(r,i,u,null,T,a);Yt(m)&&a(f.range,"BLOCK_IN_FLOW",Jt),r.atKey=!1;const y=Ot(p??[],{flow:o,indicator:"map-value-ind",next:h,offset:f.range[2],onError:a,parentIndent:n.indent,startOnNewline:!1});if(y.found){if(!s&&!T.found&&r.options.strict){if(p)for(const e of p){if(e===y.found)break;if("newline"===e.type){a(e,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}T.start<y.found.offset-1024&&a(y.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else h&&("source"in h&&":"===h.source?.[0]?a(h,"MISSING_CHAR",`Missing space after : in ${o}`):a(y.start,"MISSING_CHAR",`Missing , or : between ${o} items`));const E=h?e(r,h,y,a):y.found?t(r,y.end,p,null,y,a):null;E?Yt(h)&&a(E.range,"BLOCK_IN_FLOW",Jt):y.comment&&(f.comment?f.comment+="\n"+y.comment:f.comment=y.comment);const C=new Ce(f,E);if(r.options.keepSourceTokens&&(C.srcToken=c),s){const e=l;Dt(r,e.items,f)&&a(i,"DUPLICATE_KEY","Map keys must be unique"),e.items.push(C)}else{const e=new Se(r.schema);e.flow=!0,e.items.push(C);const t=(E??f).range;e.range=[f.range[0],t[1],t[2]],l.items.push(e)}d=E?E.range[2]:y.end}else{const n=h?e(r,h,T,a):t(r,T.end,p,null,T,a);l.items.push(n),d=n.range[2],Yt(h)&&a(n.range,"BLOCK_IN_FLOW",Jt)}}const u=s?"}":"]",[m,...p]=n.end;let h=d;if(m?.source===u)h=m.offset+m.source.length;else{const e=o[0].toUpperCase()+o.substring(1);a(d,c?"MISSING_CHAR":"BAD_INDENT",c?`${e} must end with a ${u}`:`${e} in block collection must be sufficiently indented and end with a ${u}`),m&&1!==m.source.length&&p.unshift(m)}if(p.length>0){const e=Ut(p,h,r.options.strict,a);e.comment&&(l.comment?l.comment+="\n"+e.comment:l.comment=e.comment),l.range=[n.offset,h,e.offset]}else l.range=[n.offset,h,h];return l}(e,t,r,n,i),o=s.constructor;return"!"===a||a===o.tagName?(s.tag=o.tagName,s):(a&&(s.tag=a),s)}function Pt(e,t,r){const n=t.offset,a=function({offset:e,props:t},r,n){if("block-scalar-header"!==t[0].type)return n(t[0],"IMPOSSIBLE","Block scalar header not found"),null;const{source:a}=t[0],i=a[0];let s=0,o="",l=-1;for(let t=1;t<a.length;++t){const r=a[t];if(o||"-"!==r&&"+"!==r){const n=Number(r);!s&&n?s=n:-1===l&&(l=e+t)}else o=r}-1!==l&&n(l,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${a}`);let c=!1,d="",u=a.length;for(let e=1;e<t.length;++e){const a=t[e];switch(a.type){case"space":c=!0;case"newline":u+=a.source.length;break;case"comment":r&&!c&&n(a,"MISSING_CHAR","Comments must be separated from other tokens by white space characters"),u+=a.source.length,d=a.source.substring(1);break;case"error":n(a,"UNEXPECTED_TOKEN",a.message),u+=a.source.length;break;default:{n(a,"UNEXPECTED_TOKEN",`Unexpected token in block scalar header: ${a.type}`);const e=a.source;e&&"string"==typeof e&&(u+=e.length)}}}return{mode:i,indent:s,chomp:o,comment:d,length:u}}(t,e.options.strict,r);if(!a)return{value:"",type:null,comment:"",range:[n,n,n]};const i=">"===a.mode?W.BLOCK_FOLDED:W.BLOCK_LITERAL,s=t.source?function(e){const t=e.split(/\n( *)/),r=t[0],n=r.match(/^( *)/),a=[n?.[1]?[n[1],r.slice(n[1].length)]:["",r]];for(let e=1;e<t.length;e+=2)a.push([t[e],t[e+1]]);return a}(t.source):[];let o=s.length;for(let e=s.length-1;e>=0;--e){const t=s[e][1];if(""!==t&&"\r"!==t)break;o=e}if(0===o){const e="+"===a.chomp&&s.length>0?"\n".repeat(Math.max(1,s.length-1)):"";let r=n+a.length;return t.source&&(r+=t.source.length),{value:e,type:i,comment:a.comment,range:[n,r,r]}}let l=t.indent+a.indent,c=t.offset+a.length,d=0;for(let t=0;t<o;++t){const[n,i]=s[t];if(""!==i&&"\r"!==i){if(n.length<l){const e="Block scalars with more-indented leading empty lines must use an explicit indentation indicator";r(c+n.length,"MISSING_CHAR",e)}0===a.indent&&(l=n.length),d=t,0!==l||e.atRoot||r(c,"BAD_INDENT","Block scalar values in collections must be indented");break}0===a.indent&&n.length>l&&(l=n.length),c+=n.length+i.length+1}for(let e=s.length-1;e>=o;--e)s[e][0].length>l&&(o=e+1);let u="",m="",p=!1;for(let e=0;e<d;++e)u+=s[e][0].slice(l)+"\n";for(let e=d;e<o;++e){let[t,n]=s[e];c+=t.length+n.length+1;const o="\r"===n[n.length-1];if(o&&(n=n.slice(0,-1)),n&&t.length<l){const e="Block scalar lines must not be less indented than their "+(a.indent?"explicit indentation indicator":"first line");r(c-n.length-(o?2:1),"BAD_INDENT",e),t=""}i===W.BLOCK_LITERAL?(u+=m+t.slice(l)+n,m="\n"):t.length>l||"\t"===n[0]?(" "===m?m="\n":p||"\n"!==m||(m="\n\n"),u+=m+t.slice(l)+n,m="\n",p=!0):""===n?"\n"===m?u+="\n":m="\n":(u+=m+n,m=" ",p=!1)}switch(a.chomp){case"-":break;case"+":for(let e=o;e<s.length;++e)u+="\n"+s[e][0].slice(l);"\n"!==u[u.length-1]&&(u+="\n");break;default:u+="\n"}const h=n+a.length+t.source.length;return{value:u,type:i,comment:a.comment,range:[n,h,h]}}function kt(e,t,r){const{offset:n,type:a,source:i,end:s}=e;let o,l;const c=(e,t,a)=>r(n+e,t,a);switch(a){case"scalar":o=W.PLAIN,l=function(e,t){let r="";switch(e[0]){case"\t":r="a tab character";break;case",":r="flow indicator character ,";break;case"%":r="directive indicator character %";break;case"|":case">":r=`block scalar indicator ${e[0]}`;break;case"@":case"`":r=`reserved character ${e[0]}`}return r&&t(0,"BAD_SCALAR_START",`Plain value cannot start with ${r}`),Wt(e)}(i,c);break;case"single-quoted-scalar":o=W.QUOTE_SINGLE,l=function(e,t){return"'"===e[e.length-1]&&1!==e.length||t(e.length,"MISSING_CHAR","Missing closing 'quote"),Wt(e.slice(1,-1)).replace(/''/g,"'")}(i,c);break;case"double-quoted-scalar":o=W.QUOTE_DOUBLE,l=function(e,t){let r="";for(let n=1;n<e.length-1;++n){const a=e[n];if("\r"!==a||"\n"!==e[n+1])if("\n"===a){const{fold:t,offset:a}=Kt(e,n);r+=t,n=a}else if("\\"===a){let a=e[++n];const i=jt[a];if(i)r+=i;else if("\n"===a)for(a=e[n+1];" "===a||"\t"===a;)a=e[1+ ++n];else if("\r"===a&&"\n"===e[n+1])for(a=e[1+ ++n];" "===a||"\t"===a;)a=e[1+ ++n];else if("x"===a||"u"===a||"U"===a){const i="x"===a?2:"u"===a?4:8;r+=Gt(e,n+1,i,t),n+=i}else{const a=e.substr(n-1,2);t(n-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${a}`),r+=a}}else if(" "===a||"\t"===a){const t=n;let i=e[n+1];for(;" "===i||"\t"===i;)i=e[1+ ++n];"\n"===i||"\r"===i&&"\n"===e[n+2]||(r+=n>t?e.slice(t,n+1):a)}else r+=a}return'"'===e[e.length-1]&&1!==e.length||t(e.length,"MISSING_CHAR",'Missing closing "quote'),r}(i,c);break;default:return r(e,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${a}`),{value:"",type:null,comment:"",range:[n,n+i.length,n+i.length]}}const d=n+i.length,u=Ut(s,d,t,r);return{value:l,type:o,comment:u.comment,range:[n,d,u.offset]}}function Wt(e){let t,r;try{t=new RegExp("(.*?)(?<![ \t])[ \t]*\r?\n","sy"),r=new RegExp("[ \t]*(.*?)(?:(?<![ \t])[ \t]*)?\r?\n","sy")}catch{t=/(.*?)[ \t]*\r?\n/sy,r=/[ \t]*(.*?)[ \t]*\r?\n/sy}let n=t.exec(e);if(!n)return e;let a=n[1],i=" ",s=t.lastIndex;for(r.lastIndex=s;n=r.exec(e);)""===n[1]?"\n"===i?a+=i:i="\n":(a+=i+n[1],i=" "),s=r.lastIndex;const o=/[ \t]*(.*)/sy;return o.lastIndex=s,n=o.exec(e),a+i+(n?.[1]??"")}function Kt(e,t){let r="",n=e[t+1];for(;!(" "!==n&&"\t"!==n&&"\n"!==n&&"\r"!==n||"\r"===n&&"\n"!==e[t+2]);)"\n"===n&&(r+="\n"),n=e[(t+=1)+1];return r||(r=" "),{fold:r,offset:t}}const jt={0:"\0",a:"",b:"\b",e:"",f:"\f",n:"\n",r:"\r",t:"\t",v:"\v",N:"
",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\","\t":"\t"};function Gt(e,t,r,n){const a=e.substr(t,r),i=a.length===r&&/^[0-9a-fA-F]+$/.test(a)?parseInt(a,16):NaN;try{return String.fromCodePoint(i)}catch{const a=e.substr(t-2,r+2);return n(t-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${a}`),a}}function Xt(e,t,r,n){const{value:a,type:i,comment:s,range:o}="block-scalar"===t.type?Pt(e,t,n):kt(t,e.options.strict,n),l=r?e.directives.tagName(r.source,e=>n(r,"TAG_RESOLVE_FAILED",e)):null;let d,u;d=e.options.stringKeys&&e.atKey?e.schema[c]:l?function(e,t,r,n,a){if("!"===r)return e[c];const i=[];for(const t of e.tags)if(!t.collection&&t.tag===r){if(!t.default||!t.test)return t;i.push(t)}for(const e of i)if(e.test?.test(t))return e;const s=e.knownTags[r];return s&&!s.collection?(e.tags.push(Object.assign({},s,{default:!1,test:void 0})),s):(a(n,"TAG_RESOLVE_FAILED",`Unresolved tag: ${r}`,"tag:yaml.org,2002:str"!==r),e[c])}(e.schema,a,l,r,n):"scalar"===t.type?function({atKey:e,directives:t,schema:r},n,a,i){const s=r.tags.find(t=>(!0===t.default||e&&"key"===t.default)&&t.test?.test(n))||r[c];if(r.compat){const e=r.compat.find(e=>e.default&&e.test?.test(n))??r[c];s.tag!==e.tag&&i(a,"TAG_RESOLVE_FAILED",`Value may be parsed as either ${t.tagString(s.tag)} or ${t.tagString(e.tag)}`,!0)}return s}(e,a,t,n):e.schema[c];try{const i=d.resolve(a,e=>n(r??t,"TAG_RESOLVE_FAILED",e),e.options);u=T(i)?i:new W(i)}catch(e){const i=e instanceof Error?e.message:String(e);n(r??t,"TAG_RESOLVE_FAILED",i),u=new W(a)}return u.range=o,u.source=a,i&&(u.type=i),l&&(u.tag=l),d.format&&(u.format=d.format),s&&(u.comment=s),u}function $t(e,t,r){if(t){r??(r=t.length);for(let n=r-1;n>=0;--n){let r=t[n];switch(r.type){case"space":case"comment":case"newline":e-=r.source.length;continue}for(r=t[++n];"space"===r?.type;)e+=r.source.length,r=t[++n];break}}return e}const qt={composeNode:Ht,composeEmptyNode:zt};function Ht(e,t,r,n){const a=e.atKey,{spaceBefore:i,comment:s,anchor:o,tag:l}=r;let c,d=!0;switch(t.type){case"alias":c=function({options:e},{offset:t,source:r,end:n},a){const i=new x(r.substring(1));""===i.source&&a(t,"BAD_ALIAS","Alias cannot be an empty string"),i.source.endsWith(":")&&a(t+r.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);const s=t+r.length,o=Ut(n,s,e.strict,a);return i.range=[t,s,o.offset],o.comment&&(i.comment=o.comment),i}(e,t,n),(o||l)&&n(t,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":c=Xt(e,t,l,n),o&&(c.anchor=o.source.substring(1));break;case"block-map":case"block-seq":case"flow-collection":try{c=function(e,t,r,n,a){const i=n.tag,s=i?t.directives.tagName(i.source,e=>a(i,"TAG_RESOLVE_FAILED",e)):null;if("block-seq"===r.type){const{anchor:e,newlineAfterProp:t}=n,r=e&&i?e.offset>i.offset?e:i:e??i;r&&(!t||t.offset<r.offset)&&a(r,"MISSING_CHAR","Missing newline after block sequence props")}const o="block-map"===r.type?"map":"block-seq"===r.type?"seq":"{"===r.start.source?"map":"seq";if(!i||!s||"!"===s||s===Se.tagName&&"map"===o||s===ve.tagName&&"seq"===o)return xt(e,t,r,a,s);let l=t.schema.tags.find(e=>e.tag===s&&e.collection===o);if(!l){const n=t.schema.knownTags[s];if(n?.collection!==o)return n?a(i,"BAD_COLLECTION_TYPE",`${n.tag} used for ${o} collection, but expects ${n.collection??"scalar"}`,!0):a(i,"TAG_RESOLVE_FAILED",`Unresolved tag: ${s}`,!0),xt(e,t,r,a,s);t.schema.tags.push(Object.assign({},n,{default:!1})),l=n}const c=xt(e,t,r,a,s,l),d=l.resolve?.(c,e=>a(i,"TAG_RESOLVE_FAILED",e),t.options)??c,u=C(d)?d:new W(d);return u.range=c.range,u.tag=s,l?.format&&(u.format=l.format),u}(qt,e,t,r,n),o&&(c.anchor=o.source.substring(1))}catch(e){n(t,"RESOURCE_EXHAUSTION",e instanceof Error?e.message:String(e))}break;default:n(t,"UNEXPECTED_TOKEN","error"===t.type?t.message:`Unsupported token (type: ${t.type})`),d=!1}return c??(c=zt(e,t.offset,void 0,null,r,n)),o&&""===c.anchor&&n(o,"BAD_ALIAS","Anchor cannot be an empty string"),a&&e.options.stringKeys&&(!T(c)||"string"!=typeof c.value||c.tag&&"tag:yaml.org,2002:str"!==c.tag)&&n(l??t,"NON_STRING_KEY","With stringKeys, all keys must be strings"),i&&(c.spaceBefore=!0),s&&("scalar"===t.type&&""===t.source?c.comment=s:c.commentBefore=s),e.options.keepSourceTokens&&d&&(c.srcToken=t),c}function zt(e,t,r,n,{spaceBefore:a,comment:i,anchor:s,tag:o,end:l},c){const d=Xt(e,{type:"scalar",offset:$t(t,r,n),indent:-1,source:""},o,c);return s&&(d.anchor=s.source.substring(1),""===d.anchor&&c(s,"BAD_ALIAS","Anchor cannot be an empty string")),a&&(d.spaceBefore=!0),i&&(d.comment=i,d.range[2]=l),d}function Qt(e){if("number"==typeof e)return[e,e+1];if(Array.isArray(e))return 2===e.length?e:[e[0],e[1]];const{offset:t,source:r}=e;return[t,t+("string"==typeof r?r.length:1)]}function Zt(e){let t="",r=!1,n=!1;for(let a=0;a<e.length;++a){const i=e[a];switch(i[0]){case"#":t+=(""===t?"":n?"\n\n":"\n")+(i.substring(1)||" "),r=!0,n=!1;break;case"%":"#"!==e[a+1]?.[0]&&(a+=1),r=!1;break;default:r||(n=!0),r=!1}}return{comment:t,afterEmptyLine:n}}class er{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(e,t,r,n)=>{const a=Qt(e);n?this.warnings.push(new Lt(a,t,r)):this.errors.push(new wt(a,t,r))},this.directives=new V({version:e.version||"1.2"}),this.options=e}decorate(e,t){const{comment:r,afterEmptyLine:n}=Zt(this.prelude);if(r){const a=e.contents;if(t)e.comment=e.comment?`${e.comment}\n${r}`:r;else if(n||e.directives.docStart||!a)e.commentBefore=r;else if(E(a)&&!a.flow&&a.items.length>0){let e=a.items[0];f(e)&&(e=e.key);const t=e.commentBefore;e.commentBefore=t?`${r}\n${t}`:r}else{const e=a.commentBefore;a.commentBefore=e?`${r}\n${e}`:r}}if(t){for(let t=0;t<this.errors.length;++t)e.errors.push(this.errors[t]);for(let t=0;t<this.warnings.length;++t)e.warnings.push(this.warnings[t])}else e.errors=this.errors,e.warnings=this.warnings;this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:Zt(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,t=!1,r=-1){for(const t of e)yield*this.next(t);yield*this.end(t,r)}*next(e){switch(e.type){case"directive":this.directives.add(e.source,(t,r,n)=>{const a=Qt(e);a[0]+=t,this.onError(a,"BAD_DIRECTIVE",r,n)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{const t=function(e,t,{offset:r,start:n,value:a,end:i},s){const o=Object.assign({_directives:t},e),l=new _t(void 0,o),c={atKey:!1,atRoot:!0,directives:l.directives,options:l.options,schema:l.schema},d=Ot(n,{indicator:"doc-start",next:a??i?.[0],offset:r,onError:s,parentIndent:0,startOnNewline:!0});d.found&&(l.directives.docStart=!0,!a||"block-map"!==a.type&&"block-seq"!==a.type||d.hasNewline||s(d.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")),l.contents=a?Ht(c,a,d,s):zt(c,d.end,n,null,d,s);const u=l.contents.range[2],m=Ut(i,u,!1,s);return m.comment&&(l.comment=m.comment),l.range=[r,u,m.offset],l}(this.options,this.directives,e,this.onError);this.atDirectives&&!t.directives.docStart&&this.onError(e,"MISSING_CHAR","Missing directives-end/doc-start indicator line"),this.decorate(t,!1),this.doc&&(yield this.doc),this.doc=t,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push(e.source);break;case"error":{const t=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,r=new wt(Qt(e),"UNEXPECTED_TOKEN",t);this.atDirectives||!this.doc?this.errors.push(r):this.doc.errors.push(r);break}case"doc-end":{if(!this.doc){const t="Unexpected doc-end without preceding document";this.errors.push(new wt(Qt(e),"UNEXPECTED_TOKEN",t));break}this.doc.directives.docEnd=!0;const t=Ut(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),t.comment){const e=this.doc.comment;this.doc.comment=e?`${e}\n${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.push(new wt(Qt(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,t=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){const e=Object.assign({_directives:this.directives},this.options),r=new _t(void 0,e);this.atDirectives&&this.onError(t,"MISSING_CHAR","Missing directives-end indicator line"),r.range=[0,t,t],this.decorate(r,!1),yield r}}}function tr(e,t=!0,r){if(e){const n=(e,t,n)=>{const a="number"==typeof e?e:Array.isArray(e)?e[0]:e.offset;if(!r)throw new wt([a,a+1],t,n);r(a,t,n)};switch(e.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return kt(e,t,n);case"block-scalar":return Pt({options:{strict:t}},e,n)}}return null}function rr(e,t){const{implicitKey:r=!1,indent:n,inFlow:a=!1,offset:i=-1,type:s="PLAIN"}=t,o=le({type:s,value:e},{implicitKey:r,indent:n>0?" ".repeat(n):"",inFlow:a,options:{blockQuote:!0,lineWidth:-1}}),l=t.end??[{type:"newline",offset:-1,indent:n,source:"\n"}];switch(o[0]){case"|":case">":{const e=o.indexOf("\n"),t=o.substring(0,e),r=o.substring(e+1)+"\n",a=[{type:"block-scalar-header",offset:i,indent:n,source:t}];return ar(a,l)||a.push({type:"newline",offset:-1,indent:n,source:"\n"}),{type:"block-scalar",offset:i,indent:n,props:a,source:r}}case'"':return{type:"double-quoted-scalar",offset:i,indent:n,source:o,end:l};case"'":return{type:"single-quoted-scalar",offset:i,indent:n,source:o,end:l};default:return{type:"scalar",offset:i,indent:n,source:o,end:l}}}function nr(e,t,r={}){let{afterKey:n=!1,implicitKey:a=!1,inFlow:i=!1,type:s}=r,o="indent"in e?e.indent:null;if(n&&"number"==typeof o&&(o+=2),!s)switch(e.type){case"single-quoted-scalar":s="QUOTE_SINGLE";break;case"double-quoted-scalar":s="QUOTE_DOUBLE";break;case"block-scalar":{const t=e.props[0];if("block-scalar-header"!==t.type)throw new Error("Invalid block scalar header");s=">"===t.source[0]?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:s="PLAIN"}const l=le({type:s,value:t},{implicitKey:a||null===o,indent:null!==o&&o>0?" ".repeat(o):"",inFlow:i,options:{blockQuote:!0,lineWidth:-1}});switch(l[0]){case"|":case">":!function(e,t){const r=t.indexOf("\n"),n=t.substring(0,r),a=t.substring(r+1)+"\n";if("block-scalar"===e.type){const t=e.props[0];if("block-scalar-header"!==t.type)throw new Error("Invalid block scalar header");t.source=n,e.source=a}else{const{offset:t}=e,r="indent"in e?e.indent:-1,i=[{type:"block-scalar-header",offset:t,indent:r,source:n}];ar(i,"end"in e?e.end:void 0)||i.push({type:"newline",offset:-1,indent:r,source:"\n"});for(const t of Object.keys(e))"type"!==t&&"offset"!==t&&delete e[t];Object.assign(e,{type:"block-scalar",indent:r,props:i,source:a})}}(e,l);break;case'"':ir(e,l,"double-quoted-scalar");break;case"'":ir(e,l,"single-quoted-scalar");break;default:ir(e,l,"scalar")}}function ar(e,t){if(t)for(const r of t)switch(r.type){case"space":case"comment":e.push(r);break;case"newline":return e.push(r),!0}return!1}function ir(e,t,r){switch(e.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":e.type=r,e.source=t;break;case"block-scalar":{const n=e.props.slice(1);let a=t.length;"block-scalar-header"===e.props[0].type&&(a-=e.props[0].source.length);for(const e of n)e.offset+=a;delete e.props,Object.assign(e,{type:r,source:t,end:n});break}case"block-map":case"block-seq":{const n={type:"newline",offset:e.offset+t.length,indent:e.indent,source:"\n"};delete e.items,Object.assign(e,{type:r,source:t,end:[n]});break}default:{const n="indent"in e?e.indent:-1,a="end"in e&&Array.isArray(e.end)?e.end.filter(e=>"space"===e.type||"comment"===e.type||"newline"===e.type):[];for(const t of Object.keys(e))"type"!==t&&"offset"!==t&&delete e[t];Object.assign(e,{type:r,indent:n,source:t,end:a})}}}const sr=e=>"type"in e?or(e):lr(e);function or(e){switch(e.type){case"block-scalar":{let t="";for(const r of e.props)t+=or(r);return t+e.source}case"block-map":case"block-seq":{let t="";for(const r of e.items)t+=lr(r);return t}case"flow-collection":{let t=e.start.source;for(const r of e.items)t+=lr(r);for(const r of e.end)t+=r.source;return t}case"document":{let t=lr(e);if(e.end)for(const r of e.end)t+=r.source;return t}default:{let t=e.source;if("end"in e&&e.end)for(const r of e.end)t+=r.source;return t}}}function lr({start:e,key:t,sep:r,value:n}){let a="";for(const t of e)a+=t.source;if(t&&(a+=or(t)),r)for(const e of r)a+=e.source;return n&&(a+=or(n)),a}const cr=Symbol("break visit"),dr=Symbol("skip children"),ur=Symbol("remove item");function mr(e,t){"type"in e&&"document"===e.type&&(e={start:e.start,value:e.value}),pr(Object.freeze([]),e,t)}function pr(e,t,r){let n=r(t,e);if("symbol"==typeof n)return n;for(const a of["key","value"]){const i=t[a];if(i&&"items"in i){for(let t=0;t<i.items.length;++t){const n=pr(Object.freeze(e.concat([[a,t]])),i.items[t],r);if("number"==typeof n)t=n-1;else{if(n===cr)return cr;n===ur&&(i.items.splice(t,1),t-=1)}}"function"==typeof n&&"key"===a&&(n=n(t,e))}}return"function"==typeof n?n(t,e):n}mr.BREAK=cr,mr.SKIP=dr,mr.REMOVE=ur,mr.itemAtPath=(e,t)=>{let r=e;for(const[e,n]of t){const t=r?.[e];if(!t||!("items"in t))return;r=t.items[n]}return r},mr.parentCollection=(e,t)=>{const r=mr.itemAtPath(e,t.slice(0,-1)),n=t[t.length-1][0],a=r?.[n];if(a&&"items"in a)return a;throw new Error("Parent collection not found")};const hr="\ufeff",fr="",Tr="",yr="",Er=e=>!!e&&"items"in e,Cr=e=>!!e&&("scalar"===e.type||"single-quoted-scalar"===e.type||"double-quoted-scalar"===e.type||"block-scalar"===e.type);function gr(e){switch(e){case hr:return"<BOM>";case fr:return"<DOC>";case Tr:return"<FLOW_END>";case yr:return"<SCALAR>";default:return JSON.stringify(e)}}function Ir(e){switch(e){case hr:return"byte-order-mark";case fr:return"doc-mode";case Tr:return"flow-error-end";case yr:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case"\n":case"\r\n":return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(e[0]){case" ":case"\t":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}function Ar(e){switch(e){case void 0:case" ":case"\n":case"\r":case"\t":return!0;default:return!1}}const br=new Set("0123456789ABCDEFabcdef"),Rr=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),Sr=new Set(",[]{}"),_r=new Set(" ,[]{}\n\r\t"),vr=e=>!e||_r.has(e);class Nr{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,t=!1){if(e){if("string"!=typeof e)throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!t;let r=this.next??"stream";for(;r&&(t||this.hasChars(1));)r=yield*this.parseNext(r)}atLineEnd(){let e=this.pos,t=this.buffer[e];for(;" "===t||"\t"===t;)t=this.buffer[++e];return!t||"#"===t||"\n"===t||"\r"===t&&"\n"===this.buffer[e+1]}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let t=this.buffer[e];if(this.indentNext>0){let r=0;for(;" "===t;)t=this.buffer[++r+e];if("\r"===t){const t=this.buffer[r+e+1];if("\n"===t||!t&&!this.atEnd)return e+r+1}return"\n"===t||r>=this.indentNext||!t&&!this.atEnd?e+r:-1}if("-"===t||"."===t){const t=this.buffer.substr(e,3);if(("---"===t||"..."===t)&&Ar(this.buffer[e+3]))return-1}return e}getLine(){let e=this.lineEndPos;return("number"!=typeof e||-1!==e&&e<this.pos)&&(e=this.buffer.indexOf("\n",this.pos),this.lineEndPos=e),-1===e?this.atEnd?this.buffer.substring(this.pos):null:("\r"===this.buffer[e-1]&&(e-=1),this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(null===e)return this.setNext("stream");if(e[0]===hr&&(yield*this.pushCount(1),e=e.substring(1)),"%"===e[0]){let t=e.length,r=e.indexOf("#");for(;-1!==r;){const n=e[r-1];if(" "===n||"\t"===n){t=r-1;break}r=e.indexOf("#",r+1)}for(;;){const r=e[t-1];if(" "!==r&&"\t"!==r)break;t-=1}const n=(yield*this.pushCount(t))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-n),this.pushNewline(),"stream"}if(this.atLineEnd()){const t=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-t),yield*this.pushNewline(),"stream"}return yield fr,yield*this.parseLineStart()}*parseLineStart(){const e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext("line-start");if("-"===e||"."===e){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");const e=this.peek(3);if(("---"===e||"..."===e)&&Ar(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,"---"===e?"doc":"stream"}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!Ar(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){const[e,t]=this.peek(2);if(!t&&!this.atEnd)return this.setNext("block-start");if(("-"===e||"?"===e||":"===e)&&Ar(t)){const e=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=e,"block-start"}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);const e=this.getLine();if(null===e)return this.setNext("doc");let t=yield*this.pushIndicators();switch(e[t]){case"#":yield*this.pushCount(e.length-t);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(vr),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return t+=(yield*this.parseBlockScalarHeader()),t+=(yield*this.pushSpaces(!0)),yield*this.pushCount(e.length-t),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,t,r=-1;do{e=yield*this.pushNewline(),e>0?(t=yield*this.pushSpaces(!1),this.indentValue=r=t):t=0,t+=(yield*this.pushSpaces(!0))}while(e+t>0);const n=this.getLine();if(null===n)return this.setNext("flow");if((-1!==r&&r<this.indentNext&&"#"!==n[0]||0===r&&(n.startsWith("---")||n.startsWith("..."))&&Ar(n[3]))&&(r!==this.indentNext-1||1!==this.flowLevel||"]"!==n[0]&&"}"!==n[0]))return this.flowLevel=0,yield Tr,yield*this.parseLineStart();let a=0;for(;","===n[a];)a+=(yield*this.pushCount(1)),a+=(yield*this.pushSpaces(!0)),this.flowKey=!1;switch(a+=(yield*this.pushIndicators()),n[a]){case void 0:return"flow";case"#":return yield*this.pushCount(n.length-a),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(vr),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{const e=this.charAt(1);if(this.flowKey||Ar(e)||","===e)return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){const e=this.charAt(0);let t=this.buffer.indexOf(e,this.pos+1);if("'"===e)for(;-1!==t&&"'"===this.buffer[t+1];)t=this.buffer.indexOf("'",t+2);else for(;-1!==t;){let e=0;for(;"\\"===this.buffer[t-1-e];)e+=1;if(e%2==0)break;t=this.buffer.indexOf('"',t+1)}const r=this.buffer.substring(0,t);let n=r.indexOf("\n",this.pos);if(-1!==n){for(;-1!==n;){const e=this.continueScalar(n+1);if(-1===e)break;n=r.indexOf("\n",e)}-1!==n&&(t=n-("\r"===r[n-1]?2:1))}if(-1===t){if(!this.atEnd)return this.setNext("quoted-scalar");t=this.buffer.length}return yield*this.pushToIndex(t+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let e=this.pos;for(;;){const t=this.buffer[++e];if("+"===t)this.blockScalarKeep=!0;else if(t>"0"&&t<="9")this.blockScalarIndent=Number(t)-1;else if("-"!==t)break}return yield*this.pushUntil(e=>Ar(e)||"#"===e)}*parseBlockScalar(){let e,t=this.pos-1,r=0;e:for(let n=this.pos;e=this.buffer[n];++n)switch(e){case" ":r+=1;break;case"\n":t=n,r=0;break;case"\r":{const e=this.buffer[n+1];if(!e&&!this.atEnd)return this.setNext("block-scalar");if("\n"===e)break}default:break e}if(!e&&!this.atEnd)return this.setNext("block-scalar");if(r>=this.indentNext){-1===this.blockScalarIndent?this.indentNext=r:this.indentNext=this.blockScalarIndent+(0===this.indentNext?1:this.indentNext);do{const e=this.continueScalar(t+1);if(-1===e)break;t=this.buffer.indexOf("\n",e)}while(-1!==t);if(-1===t){if(!this.atEnd)return this.setNext("block-scalar");t=this.buffer.length}}let n=t+1;for(e=this.buffer[n];" "===e;)e=this.buffer[++n];if("\t"===e){for(;"\t"===e||" "===e||"\r"===e||"\n"===e;)e=this.buffer[++n];t=n-1}else if(!this.blockScalarKeep)for(;;){let e=t-1,n=this.buffer[e];"\r"===n&&(n=this.buffer[--e]);const a=e;for(;" "===n;)n=this.buffer[--e];if(!("\n"===n&&e>=this.pos&&e+1+r>a))break;t=e}return yield yr,yield*this.pushToIndex(t+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){const e=this.flowLevel>0;let t,r=this.pos-1,n=this.pos-1;for(;t=this.buffer[++n];)if(":"===t){const t=this.buffer[n+1];if(Ar(t)||e&&Sr.has(t))break;r=n}else if(Ar(t)){let a=this.buffer[n+1];if("\r"===t&&("\n"===a?(n+=1,t="\n",a=this.buffer[n+1]):r=n),"#"===a||e&&Sr.has(a))break;if("\n"===t){const e=this.continueScalar(n+1);if(-1===e)break;n=Math.max(n,e-2)}}else{if(e&&Sr.has(t))break;r=n}return t||this.atEnd?(yield yr,yield*this.pushToIndex(r+1,!0),e?"flow":"doc"):this.setNext("plain-scalar")}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,t){const r=this.buffer.slice(this.pos,e);return r?(yield r,this.pos+=r.length,r.length):(t&&(yield""),0)}*pushIndicators(){let e=0;e:for(;;){switch(this.charAt(0)){case"!":e+=(yield*this.pushTag()),e+=(yield*this.pushSpaces(!0));continue e;case"&":e+=(yield*this.pushUntil(vr)),e+=(yield*this.pushSpaces(!0));continue e;case"-":case"?":case":":{const t=this.flowLevel>0,r=this.charAt(1);if(Ar(r)||t&&Sr.has(r)){t?this.flowKey&&(this.flowKey=!1):this.indentNext=this.indentValue+1,e+=(yield*this.pushCount(1)),e+=(yield*this.pushSpaces(!0));continue e}}}break e}return e}*pushTag(){if("<"===this.charAt(1)){let e=this.pos+2,t=this.buffer[e];for(;!Ar(t)&&">"!==t;)t=this.buffer[++e];return yield*this.pushToIndex(">"===t?e+1:e,!1)}{let e=this.pos+1,t=this.buffer[e];for(;t;)if(Rr.has(t))t=this.buffer[++e];else{if("%"!==t||!br.has(this.buffer[e+1])||!br.has(this.buffer[e+2]))break;t=this.buffer[e+=3]}return yield*this.pushToIndex(e,!1)}}*pushNewline(){const e=this.buffer[this.pos];return"\n"===e?yield*this.pushCount(1):"\r"===e&&"\n"===this.charAt(1)?yield*this.pushCount(2):0}*pushSpaces(e){let t,r=this.pos-1;do{t=this.buffer[++r]}while(" "===t||e&&"\t"===t);const n=r-this.pos;return n>0&&(yield this.buffer.substr(this.pos,n),this.pos=r),n}*pushUntil(e){let t=this.pos,r=this.buffer[t];for(;!e(r);)r=this.buffer[++t];return yield*this.pushToIndex(t,!1)}}class wr{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let t=0,r=this.lineStarts.length;for(;t<r;){const n=t+r>>1;this.lineStarts[n]<e?t=n+1:r=n}return this.lineStarts[t]===e?{line:t+1,col:1}:0===t?{line:0,col:e}:{line:t,col:e-this.lineStarts[t-1]+1}}}}function Lr(e,t){for(let r=0;r<e.length;++r)if(e[r].type===t)return!0;return!1}function Fr(e){for(let t=0;t<e.length;++t)switch(e[t].type){case"space":case"comment":case"newline":break;default:return t}return-1}function Or(e){switch(e?.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function Vr(e){switch(e.type){case"document":return e.start;case"block-map":{const t=e.items[e.items.length-1];return t.sep??t.start}case"block-seq":return e.items[e.items.length-1].start;default:return[]}}function Br(e){if(0===e.length)return[];let t=e.length;e:for(;--t>=0;)switch(e[t].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break e}for(;"space"===e[++t]?.type;);return e.splice(t,e.length)}function Dr(e,t){if(t.length<1e5)Array.prototype.push.apply(e,t);else for(let r=0;r<t.length;++r)e.push(t[r])}function Mr(e){if("flow-seq-start"===e.start.type)for(const t of e.items)!t.sep||t.value||Lr(t.start,"explicit-key-ind")||Lr(t.sep,"map-value-ind")||(t.key&&(t.value=t.key),delete t.key,Or(t.value)?t.value.end?Dr(t.value.end,t.sep):t.value.end=t.sep:Dr(t.start,t.sep),delete t.sep)}class Ur{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new Nr,this.onNewLine=e}*parse(e,t=!1){this.onNewLine&&0===this.offset&&this.onNewLine(0);for(const r of this.lexer.lex(e,t))yield*this.next(r);t||(yield*this.end())}*next(e){if(this.source=e,this.atScalar)return this.atScalar=!1,yield*this.step(),void(this.offset+=e.length);const t=Ir(e);if(t)if("scalar"===t)this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=t,yield*this.step(),t){case"newline":this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case"space":this.atNewLine&&" "===e[0]&&(this.indent+=e.length);break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":this.atNewLine&&(this.indent+=e.length);break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=e.length}else{const t=`Not a YAML token: ${e}`;yield*this.pop({type:"error",offset:this.offset,message:t,source:e}),this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){const e=this.peek(1);if("doc-end"!==this.type||"doc-end"===e?.type){if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}else{for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source})}}peek(e){return this.stack[this.stack.length-e]}*pop(e){const t=e??this.stack.pop();if(t)if(0===this.stack.length)yield t;else{const e=this.peek(1);switch("block-scalar"===t.type?t.indent="indent"in e?e.indent:0:"flow-collection"===t.type&&"document"===e.type&&(t.indent=0),"flow-collection"===t.type&&Mr(t),e.type){case"document":e.value=t;break;case"block-scalar":e.props.push(t);break;case"block-map":{const r=e.items[e.items.length-1];if(r.value)return e.items.push({start:[],key:t,sep:[]}),void(this.onKeyLine=!0);if(!r.sep)return Object.assign(r,{key:t,sep:[]}),void(this.onKeyLine=!r.explicitKey);r.value=t;break}case"block-seq":{const r=e.items[e.items.length-1];r.value?e.items.push({start:[],value:t}):r.value=t;break}case"flow-collection":{const r=e.items[e.items.length-1];return void(!r||r.value?e.items.push({start:[],key:t,sep:[]}):r.sep?r.value=t:Object.assign(r,{key:t,sep:[]}))}default:yield*this.pop(),yield*this.pop(t)}if(!("document"!==e.type&&"block-map"!==e.type&&"block-seq"!==e.type||"block-map"!==t.type&&"block-seq"!==t.type)){const r=t.items[t.items.length-1];r&&!r.sep&&!r.value&&r.start.length>0&&-1===Fr(r.start)&&(0===t.indent||r.start.every(e=>"comment"!==e.type||e.indent<t.indent))&&("document"===e.type?e.end=r.start:e.items.push({start:r.start}),t.items.splice(-1,1))}}else{const e="Tried to pop an empty stack";yield{type:"error",offset:this.offset,source:"",message:e}}}*stream(){switch(this.type){case"directive-line":return void(yield{type:"directive",offset:this.offset,source:this.source});case"byte-order-mark":case"space":case"comment":case"newline":return void(yield this.sourceToken);case"doc-mode":case"doc-start":{const e={type:"document",offset:this.offset,start:[]};return"doc-start"===this.type&&e.start.push(this.sourceToken),void this.stack.push(e)}}yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document(e){if(e.value)return yield*this.lineEnd(e);switch(this.type){case"doc-start":return void(-1!==Fr(e.start)?(yield*this.pop(),yield*this.step()):e.start.push(this.sourceToken));case"anchor":case"tag":case"space":case"comment":case"newline":return void e.start.push(this.sourceToken)}const t=this.startBlockValue(e);t?this.stack.push(t):yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar(e){if("map-value-ind"===this.type){const t=Br(Vr(this.peek(2)));let r;e.end?(r=e.end,r.push(this.sourceToken),delete e.end):r=[this.sourceToken];const n={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:t,key:e,sep:r}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=n}else yield*this.lineEnd(e)}*blockScalar(e){switch(this.type){case"space":case"comment":case"newline":return void e.props.push(this.sourceToken);case"scalar":if(e.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let e=this.source.indexOf("\n")+1;for(;0!==e;)this.onNewLine(this.offset+e),e=this.source.indexOf("\n",e)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){const t=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,t.value){const r="end"in t.value?t.value.end:void 0,n=Array.isArray(r)?r[r.length-1]:void 0;"comment"===n?.type?r?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case"space":case"comment":if(t.value)e.items.push({start:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else{if(this.atIndentedComment(t.start,e.indent)){const r=e.items[e.items.length-2],n=r?.value?.end;if(Array.isArray(n))return Dr(n,t.start),n.push(this.sourceToken),void e.items.pop()}t.start.push(this.sourceToken)}return}if(this.indent>=e.indent){const r=!this.onKeyLine&&this.indent===e.indent,n=r&&(t.sep||t.explicitKey)&&"seq-item-ind"!==this.type;let a=[];if(n&&t.sep&&!t.value){const r=[];for(let n=0;n<t.sep.length;++n){const a=t.sep[n];switch(a.type){case"newline":r.push(n);break;case"space":break;case"comment":a.indent>e.indent&&(r.length=0);break;default:r.length=0}}r.length>=2&&(a=t.sep.splice(r[1]))}switch(this.type){case"anchor":case"tag":return void(n||t.value?(a.push(this.sourceToken),e.items.push({start:a}),this.onKeyLine=!0):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken));case"explicit-key-ind":return t.sep||t.explicitKey?n||t.value?(a.push(this.sourceToken),e.items.push({start:a,explicitKey:!0})):this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}):(t.start.push(this.sourceToken),t.explicitKey=!0),void(this.onKeyLine=!0);case"map-value-ind":if(t.explicitKey)if(t.sep)if(t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Lr(t.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:a,key:null,sep:[this.sourceToken]}]});else if(Or(t.key)&&!Lr(t.sep,"newline")){const e=Br(t.start),r=t.key,n=t.sep;n.push(this.sourceToken),delete t.key,delete t.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:e,key:r,sep:n}]})}else a.length>0?t.sep=t.sep.concat(a,this.sourceToken):t.sep.push(this.sourceToken);else if(Lr(t.start,"newline"))Object.assign(t,{key:null,sep:[this.sourceToken]});else{const e=Br(t.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:e,key:null,sep:[this.sourceToken]}]})}else t.sep?t.value||n?e.items.push({start:a,key:null,sep:[this.sourceToken]}):Lr(t.sep,"map-value-ind")?this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});return void(this.onKeyLine=!0);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const r=this.flowScalar(this.type);return void(n||t.value?(e.items.push({start:a,key:r,sep:[]}),this.onKeyLine=!0):t.sep?this.stack.push(r):(Object.assign(t,{key:r,sep:[]}),this.onKeyLine=!0))}default:{const n=this.startBlockValue(e);if(n){if("block-seq"===n.type){if(!t.explicitKey&&t.sep&&!Lr(t.sep,"newline"))return void(yield*this.pop({type:"error",offset:this.offset,message:"Unexpected block-seq-ind on same line with key",source:this.source}))}else r&&e.items.push({start:a});return void this.stack.push(n)}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){const t=e.items[e.items.length-1];switch(this.type){case"newline":if(t.value){const r="end"in t.value?t.value.end:void 0,n=Array.isArray(r)?r[r.length-1]:void 0;"comment"===n?.type?r?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.start.push(this.sourceToken);return;case"space":case"comment":if(t.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(t.start,e.indent)){const r=e.items[e.items.length-2],n=r?.value?.end;if(Array.isArray(n))return Dr(n,t.start),n.push(this.sourceToken),void e.items.pop()}t.start.push(this.sourceToken)}return;case"anchor":case"tag":if(t.value||this.indent<=e.indent)break;return void t.start.push(this.sourceToken);case"seq-item-ind":if(this.indent!==e.indent)break;return void(t.value||Lr(t.start,"seq-item-ind")?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken))}if(this.indent>e.indent){const t=this.startBlockValue(e);if(t)return void this.stack.push(t)}yield*this.pop(),yield*this.step()}*flowCollection(e){const t=e.items[e.items.length-1];if("flow-error-end"===this.type){let e;do{yield*this.pop(),e=this.peek(1)}while("flow-collection"===e?.type)}else if(0===e.end.length){switch(this.type){case"comma":case"explicit-key-ind":return void(!t||t.sep?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken));case"map-value-ind":return void(!t||t.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]}));case"space":case"comment":case"newline":case"anchor":case"tag":return void(!t||t.value?e.items.push({start:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken));case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const r=this.flowScalar(this.type);return void(!t||t.value?e.items.push({start:[],key:r,sep:[]}):t.sep?this.stack.push(r):Object.assign(t,{key:r,sep:[]}))}case"flow-map-end":case"flow-seq-end":return void e.end.push(this.sourceToken)}const r=this.startBlockValue(e);r?this.stack.push(r):(yield*this.pop(),yield*this.step())}else{const t=this.peek(2);if("block-map"===t.type&&("map-value-ind"===this.type&&t.indent===e.indent||"newline"===this.type&&!t.items[t.items.length-1].sep))yield*this.pop(),yield*this.step();else if("map-value-ind"===this.type&&"flow-collection"!==t.type){const r=Br(Vr(t));Mr(e);const n=e.end.splice(1,e.end.length);n.push(this.sourceToken);const a={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:r,key:e,sep:n}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=a}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let e=this.source.indexOf("\n")+1;for(;0!==e;)this.onNewLine(this.offset+e),e=this.source.indexOf("\n",e)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;const t=Br(Vr(e));return t.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;const t=Br(Vr(e));return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,t){return"comment"===this.type&&!(this.indent<=t)&&e.every(e=>"newline"===e.type||"space"===e.type)}*documentEnd(e){"doc-mode"!==this.type&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],"newline"===this.type&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],"newline"===this.type&&(yield*this.pop())}}}function Jr(e){const t=!1!==e.prettyErrors;return{lineCounter:e.lineCounter||t&&new wr||null,prettyErrors:t}}function Yr(e,t={}){const{lineCounter:r,prettyErrors:n}=Jr(t),a=new Ur(r?.addNewLine),i=new er(t),s=Array.from(i.compose(a.parse(e)));if(n&&r)for(const t of s)t.errors.forEach(Ft(e,r)),t.warnings.forEach(Ft(e,r));return s.length>0?s:Object.assign([],{empty:!0},i.streamInfo())}function xr(e,t={}){const{lineCounter:r,prettyErrors:n}=Jr(t),a=new Ur(r?.addNewLine),i=new er(t);let s=null;for(const t of i.compose(a.parse(e),!0,e.length))if(s){if("silent"!==s.options.logLevel){s.errors.push(new wt(t.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}}else s=t;return n&&r&&(s.errors.forEach(Ft(e,r)),s.warnings.forEach(Ft(e,r))),s}function Pr(e,t,r){let n;"function"==typeof t?n=t:void 0===r&&t&&"object"==typeof t&&(r=t);const a=xr(e,r);if(!a)return null;if(a.warnings.forEach(e=>ue(a.options.logLevel,e)),a.errors.length>0){if("silent"!==a.options.logLevel)throw a.errors[0];a.errors=[]}return a.toJS(Object.assign({reviver:n},r))}function kr(e,t,r){let n=null;if("function"==typeof t||Array.isArray(t)?n=t:void 0===r&&t&&(r=t),"string"==typeof r&&(r=r.length),"number"==typeof r){const e=Math.round(r);r=e<1?void 0:e>8?{indent:8}:{indent:e}}if(void 0===e){const{keepUndefined:e}=r??t??{};if(!e)return}return p(e)&&!n?e.toString(r):new _t(e,n,r).toString(r)}const Wr=a}};const t={};function r(n){const a=t[n];if(void 0!==a)return a.exports;const i=t[n]={exports:{}};return e[n].call(i.exports,i,i.exports,r),i.exports}r.d=(e,t)=>{if(Array.isArray(t))for(var n=0;n<t.length;){var a=t[n++],i=t[n++];r.o(e,a)?0===i&&n++:0===i?Object.defineProperty(e,a,{enumerable:!0,value:t[n++]}):Object.defineProperty(e,a,{enumerable:!0,get:i})}else for(var a in t)r.o(t,a)&&!r.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};let n={};(()=>{let e=n;Object.defineProperty(e,"__esModule",{value:!0}),e.ControlledTermDefaultValueBuilder=e.TemplateInstanceBuilder=e.InstanceDataControlledAtom=e.InstanceDataLinkAtom=e.InstanceDataTypedAtom=e.InstanceDataStringAtom=e.InstanceDataEmptyAtom=e.InstanceDataEmptyNode=e.AttributeValueNamePolicy=e.InstanceDataAttributeValueFieldName=e.InstanceDataAttributeValueField=e.InstanceDataContainer=e.TemplateInstance=e.TemplateBuilder=e.Template=e.TemplateElementBuilder=e.TemplateElement=e.TemplateField=e.AbstractArtifact=e.AbstractInstanceArtifact=e.CedarFieldType=e.AbstractContainerArtifact=e.AbstractSchemaArtifact=e.YamlTemplateWriter=e.JsonTemplateWriter=e.YamlTemplateElementWriter=e.JsonTemplateElementWriter=e.JsonTemplateInstanceReader=e.InstanceValidator=e.InstanceInflater=e.YamlTemplateInstanceReader=e.YamlTemplateReader=e.JsonTemplateReader=e.YamlTemplateElementReader=e.JsonTemplateElementReader=e.YamlTemplateFieldReader=e.JsonTemplateFieldReader=e.JsonAbstractArtifactWriter=e.JsonAbstractArtifactReader=e.JsonAbstractInstanceArtifactReader=e.JsonAbstractSchemaArtifactReader=e.CedarYamlWriters=e.CedarYamlReaders=e.CedarJsonWriters=e.CedarJsonReaders=e.CedarReaders=e.CedarWriters=e.CedarBuilders=e.YamlTemplateFieldWriter=e.JsonTemplateFieldWriter=void 0,e.YamlTemplateInstanceReaderResult=e.JsonTemplateInstanceReaderResult=e.YamlTemplateReaderResult=e.JsonTemplateReaderResult=e.YamlTemplateElementReaderResult=e.JsonTemplateElementReaderResult=e.YamlTemplateFieldReaderResult=e.JsonTemplateFieldReaderResult=e.ComparisonErrorType=e.Language=e.PavVersion=e.CedarUser=e.CedarArtifactType=e.CedarFieldCategory=e.YamlValues=e.JsonTemplateInstanceWriter=e.JsonTemplateInstanceContent=e.PropertyIri=e.RoundTrip=e.ComparisonError=e.CedarArtifactId=e.BioportalTermType=e.BiboStatus=e.Iri=e.NumberType=e.TemporalType=e.TimeFormat=e.TemporalGranularity=e.JsonPath=e.SchemaVersion=e.IsoDate=e.JsonNode=e.ChildDeploymentInfoStaticBuilder=e.ChildDeploymentInfoStatic=e.ChildDeploymentInfoAlwaysMultipleBuilder=e.ChildDeploymentInfoAlwaysMultiple=e.ChildDeploymentInfoAlwaysSingleBuilder=e.ChildDeploymentInfoAlwaysSingle=e.ChildDeploymentInfoBuilder=e.ChildDeploymentInfo=e.AbstractDynamicChildDeploymentInfoBuilder=e.AbstractDynamicChildDeploymentInfo=e.AbstractChildDeploymentInfoBuilder=e.AbstractChildDeploymentInfo=e.ControlledTermVersion=e.ControlledTermActionBuilder=e.ControlledTermValueSetBuilder=e.ControlledTermOntologyBuilder=e.ControlledTermClassBuilder=e.ControlledTermBranchBuilder=void 0,e.YamlObjectComparator=e.JsonObjectComparator=e.ComparisonResult=e.YamlArtifactParsingResult=e.JsonArtifactParsingResult=e.YamlArtifactReaderResult=e.JsonArtifactReaderResult=void 0;const t=r(8810);Object.defineProperty(e,"CedarWriters",{enumerable:!0,get:function(){return t.CedarWriters}});const a=r(6568);Object.defineProperty(e,"CedarBuilders",{enumerable:!0,get:function(){return a.CedarBuilders}});const i=r(4381);Object.defineProperty(e,"JsonTemplateFieldReader",{enumerable:!0,get:function(){return i.JsonTemplateFieldReader}});const s=r(7909);Object.defineProperty(e,"JsonTemplateElementReader",{enumerable:!0,get:function(){return s.JsonTemplateElementReader}});const o=r(5291);Object.defineProperty(e,"JsonTemplateReader",{enumerable:!0,get:function(){return o.JsonTemplateReader}});const l=r(2748);Object.defineProperty(e,"JsonTemplateFieldWriter",{enumerable:!0,get:function(){return l.JsonTemplateFieldWriterInternal}});const c=r(5430);Object.defineProperty(e,"YamlTemplateFieldWriter",{enumerable:!0,get:function(){return c.YamlTemplateFieldWriterInternal}});const d=r(6645);Object.defineProperty(e,"JsonTemplateElementWriter",{enumerable:!0,get:function(){return d.JsonTemplateElementWriter}});const u=r(7519);Object.defineProperty(e,"JsonTemplateWriter",{enumerable:!0,get:function(){return u.JsonTemplateWriter}});const m=r(5251);Object.defineProperty(e,"YamlTemplateElementWriter",{enumerable:!0,get:function(){return m.YamlTemplateElementWriter}});const p=r(1933);Object.defineProperty(e,"YamlTemplateWriter",{enumerable:!0,get:function(){return p.YamlTemplateWriter}});const h=r(9129);Object.defineProperty(e,"TemplateField",{enumerable:!0,get:function(){return h.TemplateField}});const f=r(7661);Object.defineProperty(e,"TemplateElement",{enumerable:!0,get:function(){return f.TemplateElement}});const T=r(1762);Object.defineProperty(e,"TemplateElementBuilder",{enumerable:!0,get:function(){return T.TemplateElementBuilder}});const y=r(3281);Object.defineProperty(e,"Template",{enumerable:!0,get:function(){return y.Template}});const E=r(766);Object.defineProperty(e,"TemplateBuilder",{enumerable:!0,get:function(){return E.TemplateBuilder}});const C=r(4925);Object.defineProperty(e,"TemplateInstanceBuilder",{enumerable:!0,get:function(){return C.TemplateInstanceBuilder}});const g=r(9517);Object.defineProperty(e,"JsonNode",{enumerable:!0,get:function(){return g.JsonNode}});const I=r(9857);Object.defineProperty(e,"IsoDate",{enumerable:!0,get:function(){return I.IsoDate}});const A=r(8557);Object.defineProperty(e,"SchemaVersion",{enumerable:!0,get:function(){return A.SchemaVersion}});const b=r(3188);Object.defineProperty(e,"JsonPath",{enumerable:!0,get:function(){return b.JsonPath}});const R=r(7974);Object.defineProperty(e,"TemporalGranularity",{enumerable:!0,get:function(){return R.TemporalGranularity}});const S=r(3764);Object.defineProperty(e,"TimeFormat",{enumerable:!0,get:function(){return S.TimeFormat}});const _=r(8588);Object.defineProperty(e,"TemporalType",{enumerable:!0,get:function(){return _.TemporalType}});const v=r(3447);Object.defineProperty(e,"NumberType",{enumerable:!0,get:function(){return v.NumberType}});const N=r(8802);Object.defineProperty(e,"Iri",{enumerable:!0,get:function(){return N.Iri}});const w=r(2957);Object.defineProperty(e,"ControlledTermBranchBuilder",{enumerable:!0,get:function(){return w.ControlledTermBranchBuilder}});const L=r(3091);Object.defineProperty(e,"ControlledTermClassBuilder",{enumerable:!0,get:function(){return L.ControlledTermClassBuilder}});const F=r(5491);Object.defineProperty(e,"ControlledTermOntologyBuilder",{enumerable:!0,get:function(){return F.ControlledTermOntologyBuilder}});const O=r(1556);Object.defineProperty(e,"ControlledTermValueSetBuilder",{enumerable:!0,get:function(){return O.ControlledTermValueSetBuilder}});const V=r(2480);Object.defineProperty(e,"ControlledTermDefaultValueBuilder",{enumerable:!0,get:function(){return V.ControlledTermDefaultValueBuilder}});const B=r(5753);Object.defineProperty(e,"ControlledTermVersion",{enumerable:!0,get:function(){return B.ControlledTermVersion}});const D=r(3910);Object.defineProperty(e,"BiboStatus",{enumerable:!0,get:function(){return D.BiboStatus}});const M=r(455);Object.defineProperty(e,"ChildDeploymentInfo",{enumerable:!0,get:function(){return M.ChildDeploymentInfo}});const U=r(3608);Object.defineProperty(e,"ChildDeploymentInfoBuilder",{enumerable:!0,get:function(){return U.ChildDeploymentInfoBuilder}});const J=r(8534);Object.defineProperty(e,"CedarArtifactId",{enumerable:!0,get:function(){return J.CedarArtifactId}});const Y=r(2888);Object.defineProperty(e,"ComparisonError",{enumerable:!0,get:function(){return Y.ComparisonError}});const x=r(1888);Object.defineProperty(e,"RoundTrip",{enumerable:!0,get:function(){return x.RoundTrip}});const P=r(6389);Object.defineProperty(e,"PropertyIri",{enumerable:!0,get:function(){return P.PropertyIri}});const k=r(6320);Object.defineProperty(e,"JsonTemplateInstanceWriter",{enumerable:!0,get:function(){return k.JsonTemplateInstanceWriter}});const W=r(350);Object.defineProperty(e,"JsonTemplateInstanceContent",{enumerable:!0,get:function(){return W.JsonTemplateInstanceContent}});const K=r(7733);Object.defineProperty(e,"ControlledTermActionBuilder",{enumerable:!0,get:function(){return K.ControlledTermActionBuilder}});const j=r(8349);Object.defineProperty(e,"YamlValues",{enumerable:!0,get:function(){return j.YamlValues}});const G=r(4531);Object.defineProperty(e,"BioportalTermType",{enumerable:!0,get:function(){return G.BioportalTermType}});const X=r(8421);Object.defineProperty(e,"CedarFieldCategory",{enumerable:!0,get:function(){return X.CedarFieldCategory}});const $=r(2999);Object.defineProperty(e,"YamlTemplateFieldReader",{enumerable:!0,get:function(){return $.YamlTemplateFieldReader}});const q=r(8239);Object.defineProperty(e,"YamlTemplateElementReader",{enumerable:!0,get:function(){return q.YamlTemplateElementReader}});const H=r(5677);Object.defineProperty(e,"YamlTemplateReader",{enumerable:!0,get:function(){return H.YamlTemplateReader}});const z=r(9946);Object.defineProperty(e,"YamlTemplateInstanceReader",{enumerable:!0,get:function(){return z.YamlTemplateInstanceReader}});const Q=r(9961);Object.defineProperty(e,"InstanceInflater",{enumerable:!0,get:function(){return Q.InstanceInflater}});const Z=r(8410);Object.defineProperty(e,"InstanceValidator",{enumerable:!0,get:function(){return Z.InstanceValidator}});const ee=r(2763);Object.defineProperty(e,"CedarArtifactType",{enumerable:!0,get:function(){return ee.CedarArtifactType}});const te=r(978);Object.defineProperty(e,"JsonAbstractSchemaArtifactReader",{enumerable:!0,get:function(){return te.JsonAbstractSchemaArtifactReader}});const re=r(1998);Object.defineProperty(e,"CedarReaders",{enumerable:!0,get:function(){return re.CedarReaders}});const ne=r(8333);Object.defineProperty(e,"AbstractSchemaArtifact",{enumerable:!0,get:function(){return ne.AbstractSchemaArtifact}});const ae=r(5451);Object.defineProperty(e,"AbstractContainerArtifact",{enumerable:!0,get:function(){return ae.AbstractContainerArtifact}});const ie=r(4869);Object.defineProperty(e,"CedarFieldType",{enumerable:!0,get:function(){return ie.CedarFieldType}});const se=r(3161);Object.defineProperty(e,"JsonAbstractArtifactWriter",{enumerable:!0,get:function(){return se.JsonAbstractArtifactWriter}});const oe=r(9760);Object.defineProperty(e,"ComparisonErrorType",{enumerable:!0,get:function(){return oe.ComparisonErrorType}});const le=r(9607);Object.defineProperty(e,"CedarJsonWriters",{enumerable:!0,get:function(){return le.CedarJsonWriters}});const ce=r(2103);Object.defineProperty(e,"CedarJsonReaders",{enumerable:!0,get:function(){return ce.CedarJsonReaders}});const de=r(5359);Object.defineProperty(e,"CedarYamlWriters",{enumerable:!0,get:function(){return de.CedarYamlWriters}});const ue=r(8639);Object.defineProperty(e,"CedarYamlReaders",{enumerable:!0,get:function(){return ue.CedarYamlReaders}});const me=r(5697);Object.defineProperty(e,"AbstractInstanceArtifact",{enumerable:!0,get:function(){return me.AbstractInstanceArtifact}});const pe=r(2674);Object.defineProperty(e,"AbstractArtifact",{enumerable:!0,get:function(){return pe.AbstractArtifact}});const he=r(2272);Object.defineProperty(e,"TemplateInstance",{enumerable:!0,get:function(){return he.TemplateInstance}});const fe=r(7723);Object.defineProperty(e,"InstanceDataContainer",{enumerable:!0,get:function(){return fe.InstanceDataContainer}});const Te=r(9327);Object.defineProperty(e,"InstanceDataAttributeValueField",{enumerable:!0,get:function(){return Te.InstanceDataAttributeValueField}});const ye=r(3644);Object.defineProperty(e,"InstanceDataAttributeValueFieldName",{enumerable:!0,get:function(){return ye.InstanceDataAttributeValueFieldName}});const Ee=r(4033);Object.defineProperty(e,"AttributeValueNamePolicy",{enumerable:!0,get:function(){return Ee.AttributeValueNamePolicy}});const Ce=r(4465);Object.defineProperty(e,"InstanceDataEmptyNode",{enumerable:!0,get:function(){return Ce.InstanceDataEmptyNode}});const ge=r(7548);Object.defineProperty(e,"InstanceDataEmptyAtom",{enumerable:!0,get:function(){return ge.InstanceDataEmptyAtom}});const Ie=r(5222);Object.defineProperty(e,"InstanceDataStringAtom",{enumerable:!0,get:function(){return Ie.InstanceDataStringAtom}});const Ae=r(4877);Object.defineProperty(e,"InstanceDataTypedAtom",{enumerable:!0,get:function(){return Ae.InstanceDataTypedAtom}});const be=r(7571);Object.defineProperty(e,"InstanceDataLinkAtom",{enumerable:!0,get:function(){return be.InstanceDataLinkAtom}});const Re=r(8193);Object.defineProperty(e,"InstanceDataControlledAtom",{enumerable:!0,get:function(){return Re.InstanceDataControlledAtom}});const Se=r(9232);Object.defineProperty(e,"JsonTemplateInstanceReader",{enumerable:!0,get:function(){return Se.JsonTemplateInstanceReader}});const _e=r(3326);Object.defineProperty(e,"JsonAbstractInstanceArtifactReader",{enumerable:!0,get:function(){return _e.JsonAbstractInstanceArtifactReader}});const ve=r(7993);Object.defineProperty(e,"JsonAbstractArtifactReader",{enumerable:!0,get:function(){return ve.JsonAbstractArtifactReader}});const Ne=r(7954);Object.defineProperty(e,"JsonTemplateReaderResult",{enumerable:!0,get:function(){return Ne.JsonTemplateReaderResult}});const we=r(2234);Object.defineProperty(e,"CedarUser",{enumerable:!0,get:function(){return we.CedarUser}});const Le=r(8518);Object.defineProperty(e,"JsonArtifactReaderResult",{enumerable:!0,get:function(){return Le.JsonArtifactReaderResult}});const Fe=r(4948);Object.defineProperty(e,"JsonTemplateElementReaderResult",{enumerable:!0,get:function(){return Fe.JsonTemplateElementReaderResult}});const Oe=r(6396);Object.defineProperty(e,"JsonTemplateFieldReaderResult",{enumerable:!0,get:function(){return Oe.JsonTemplateFieldReaderResult}});const Ve=r(6537);Object.defineProperty(e,"JsonTemplateInstanceReaderResult",{enumerable:!0,get:function(){return Ve.JsonTemplateInstanceReaderResult}});const Be=r(1027);Object.defineProperty(e,"PavVersion",{enumerable:!0,get:function(){return Be.PavVersion}});const De=r(3581);Object.defineProperty(e,"ChildDeploymentInfoStatic",{enumerable:!0,get:function(){return De.ChildDeploymentInfoStatic}});const Me=r(8290);Object.defineProperty(e,"ChildDeploymentInfoStaticBuilder",{enumerable:!0,get:function(){return Me.ChildDeploymentInfoStaticBuilder}});const Ue=r(2266);Object.defineProperty(e,"ChildDeploymentInfoAlwaysSingle",{enumerable:!0,get:function(){return Ue.ChildDeploymentInfoAlwaysSingle}});const Je=r(587);Object.defineProperty(e,"ChildDeploymentInfoAlwaysSingleBuilder",{enumerable:!0,get:function(){return Je.ChildDeploymentInfoAlwaysSingleBuilder}});const Ye=r(8878);Object.defineProperty(e,"ChildDeploymentInfoAlwaysMultiple",{enumerable:!0,get:function(){return Ye.ChildDeploymentInfoAlwaysMultiple}});const xe=r(3239);Object.defineProperty(e,"ChildDeploymentInfoAlwaysMultipleBuilder",{enumerable:!0,get:function(){return xe.ChildDeploymentInfoAlwaysMultipleBuilder}});const Pe=r(513);Object.defineProperty(e,"AbstractChildDeploymentInfo",{enumerable:!0,get:function(){return Pe.AbstractChildDeploymentInfo}});const ke=r(6910);Object.defineProperty(e,"AbstractChildDeploymentInfoBuilder",{enumerable:!0,get:function(){return ke.AbstractChildDeploymentInfoBuilder}});const We=r(4809);Object.defineProperty(e,"AbstractDynamicChildDeploymentInfoBuilder",{enumerable:!0,get:function(){return We.AbstractDynamicChildDeploymentInfoBuilder}});const Ke=r(3812);Object.defineProperty(e,"AbstractDynamicChildDeploymentInfo",{enumerable:!0,get:function(){return Ke.AbstractDynamicChildDeploymentInfo}});const je=r(4036);Object.defineProperty(e,"JsonArtifactParsingResult",{enumerable:!0,get:function(){return je.JsonArtifactParsingResult}});const Ge=r(1591);Object.defineProperty(e,"YamlArtifactParsingResult",{enumerable:!0,get:function(){return Ge.YamlArtifactParsingResult}});const Xe=r(4325);Object.defineProperty(e,"ComparisonResult",{enumerable:!0,get:function(){return Xe.ComparisonResult}});const $e=r(1885);Object.defineProperty(e,"YamlObjectComparator",{enumerable:!0,get:function(){return $e.YamlObjectComparator}});const qe=r(3056);Object.defineProperty(e,"JsonObjectComparator",{enumerable:!0,get:function(){return qe.JsonObjectComparator}});const He=r(7868);Object.defineProperty(e,"YamlTemplateReaderResult",{enumerable:!0,get:function(){return He.YamlTemplateReaderResult}});const ze=r(1790);Object.defineProperty(e,"YamlTemplateFieldReaderResult",{enumerable:!0,get:function(){return ze.YamlTemplateFieldReaderResult}});const Qe=r(4646);Object.defineProperty(e,"YamlTemplateElementReaderResult",{enumerable:!0,get:function(){return Qe.YamlTemplateElementReaderResult}});const Ze=r(6532);Object.defineProperty(e,"YamlArtifactReaderResult",{enumerable:!0,get:function(){return Ze.YamlArtifactReaderResult}});const et=r(147);Object.defineProperty(e,"YamlTemplateInstanceReaderResult",{enumerable:!0,get:function(){return et.YamlTemplateInstanceReaderResult}});const tt=r(7752);Object.defineProperty(e,"Language",{enumerable:!0,get:function(){return tt.Language}})})();const a=n.AbstractArtifact,i=n.AbstractChildDeploymentInfo,s=n.AbstractChildDeploymentInfoBuilder,o=n.AbstractContainerArtifact,l=n.AbstractDynamicChildDeploymentInfo,c=n.AbstractDynamicChildDeploymentInfoBuilder,d=n.AbstractInstanceArtifact,u=n.AbstractSchemaArtifact,m=n.AttributeValueNamePolicy,p=n.BiboStatus,h=n.BioportalTermType,f=n.CedarArtifactId,T=n.CedarArtifactType,y=n.CedarBuilders,E=n.CedarFieldCategory,C=n.CedarFieldType,g=n.CedarJsonReaders,I=n.CedarJsonWriters,A=n.CedarReaders,b=n.CedarUser,R=n.CedarWriters,S=n.CedarYamlReaders,_=n.CedarYamlWriters,v=n.ChildDeploymentInfo,N=n.ChildDeploymentInfoAlwaysMultiple,w=n.ChildDeploymentInfoAlwaysMultipleBuilder,L=n.ChildDeploymentInfoAlwaysSingle,F=n.ChildDeploymentInfoAlwaysSingleBuilder,O=n.ChildDeploymentInfoBuilder,V=n.ChildDeploymentInfoStatic,B=n.ChildDeploymentInfoStaticBuilder,D=n.ComparisonError,M=n.ComparisonErrorType,U=n.ComparisonResult,J=n.ControlledTermActionBuilder,Y=n.ControlledTermBranchBuilder,x=n.ControlledTermClassBuilder,P=n.ControlledTermDefaultValueBuilder,k=n.ControlledTermOntologyBuilder,W=n.ControlledTermValueSetBuilder,K=n.ControlledTermVersion,j=n.InstanceDataAttributeValueField,G=n.InstanceDataAttributeValueFieldName,X=n.InstanceDataContainer,$=n.InstanceDataControlledAtom,q=n.InstanceDataEmptyAtom,H=n.InstanceDataEmptyNode,z=n.InstanceDataLinkAtom,Q=n.InstanceDataStringAtom,Z=n.InstanceDataTypedAtom,ee=n.InstanceInflater,te=n.InstanceValidator,re=n.Iri,ne=n.IsoDate,ae=n.JsonAbstractArtifactReader,ie=n.JsonAbstractArtifactWriter,se=n.JsonAbstractInstanceArtifactReader,oe=n.JsonAbstractSchemaArtifactReader,le=n.JsonArtifactParsingResult,ce=n.JsonArtifactReaderResult,de=n.JsonNode,ue=n.JsonObjectComparator,me=n.JsonPath,pe=n.JsonTemplateElementReader,he=n.JsonTemplateElementReaderResult,fe=n.JsonTemplateElementWriter,Te=n.JsonTemplateFieldReader,ye=n.JsonTemplateFieldReaderResult,Ee=n.JsonTemplateFieldWriter,Ce=n.JsonTemplateInstanceContent,ge=n.JsonTemplateInstanceReader,Ie=n.JsonTemplateInstanceReaderResult,Ae=n.JsonTemplateInstanceWriter,be=n.JsonTemplateReader,Re=n.JsonTemplateReaderResult,Se=n.JsonTemplateWriter,_e=n.Language,ve=n.NumberType,Ne=n.PavVersion,we=n.PropertyIri,Le=n.RoundTrip,Fe=n.SchemaVersion,Oe=n.Template,Ve=n.TemplateBuilder,Be=n.TemplateElement,De=n.TemplateElementBuilder,Me=n.TemplateField,Ue=n.TemplateInstance,Je=n.TemplateInstanceBuilder,Ye=n.TemporalGranularity,xe=n.TemporalType,Pe=n.TimeFormat,ke=n.YamlArtifactParsingResult,We=n.YamlArtifactReaderResult,Ke=n.YamlObjectComparator,je=n.YamlTemplateElementReader,Ge=n.YamlTemplateElementReaderResult,Xe=n.YamlTemplateElementWriter,$e=n.YamlTemplateFieldReader,qe=n.YamlTemplateFieldReaderResult,He=n.YamlTemplateFieldWriter,ze=n.YamlTemplateInstanceReader,Qe=n.YamlTemplateInstanceReaderResult,Ze=n.YamlTemplateReader,et=n.YamlTemplateReaderResult,tt=n.YamlTemplateWriter,rt=n.YamlValues,nt=n.__esModule;export{a as AbstractArtifact,i as AbstractChildDeploymentInfo,s as AbstractChildDeploymentInfoBuilder,o as AbstractContainerArtifact,l as AbstractDynamicChildDeploymentInfo,c as AbstractDynamicChildDeploymentInfoBuilder,d as AbstractInstanceArtifact,u as AbstractSchemaArtifact,m as AttributeValueNamePolicy,p as BiboStatus,h as BioportalTermType,f as CedarArtifactId,T as CedarArtifactType,y as CedarBuilders,E as CedarFieldCategory,C as CedarFieldType,g as CedarJsonReaders,I as CedarJsonWriters,A as CedarReaders,b as CedarUser,R as CedarWriters,S as CedarYamlReaders,_ as CedarYamlWriters,v as ChildDeploymentInfo,N as ChildDeploymentInfoAlwaysMultiple,w as ChildDeploymentInfoAlwaysMultipleBuilder,L as ChildDeploymentInfoAlwaysSingle,F as ChildDeploymentInfoAlwaysSingleBuilder,O as ChildDeploymentInfoBuilder,V as ChildDeploymentInfoStatic,B as ChildDeploymentInfoStaticBuilder,D as ComparisonError,M as ComparisonErrorType,U as ComparisonResult,J as ControlledTermActionBuilder,Y as ControlledTermBranchBuilder,x as ControlledTermClassBuilder,P as ControlledTermDefaultValueBuilder,k as ControlledTermOntologyBuilder,W as ControlledTermValueSetBuilder,K as ControlledTermVersion,j as InstanceDataAttributeValueField,G as InstanceDataAttributeValueFieldName,X as InstanceDataContainer,$ as InstanceDataControlledAtom,q as InstanceDataEmptyAtom,H as InstanceDataEmptyNode,z as InstanceDataLinkAtom,Q as InstanceDataStringAtom,Z as InstanceDataTypedAtom,ee as InstanceInflater,te as InstanceValidator,re as Iri,ne as IsoDate,ae as JsonAbstractArtifactReader,ie as JsonAbstractArtifactWriter,se as JsonAbstractInstanceArtifactReader,oe as JsonAbstractSchemaArtifactReader,le as JsonArtifactParsingResult,ce as JsonArtifactReaderResult,de as JsonNode,ue as JsonObjectComparator,me as JsonPath,pe as JsonTemplateElementReader,he as JsonTemplateElementReaderResult,fe as JsonTemplateElementWriter,Te as JsonTemplateFieldReader,ye as JsonTemplateFieldReaderResult,Ee as JsonTemplateFieldWriter,Ce as JsonTemplateInstanceContent,ge as JsonTemplateInstanceReader,Ie as JsonTemplateInstanceReaderResult,Ae as JsonTemplateInstanceWriter,be as JsonTemplateReader,Re as JsonTemplateReaderResult,Se as JsonTemplateWriter,_e as Language,ve as NumberType,Ne as PavVersion,we as PropertyIri,Le as RoundTrip,Fe as SchemaVersion,Oe as Template,Ve as TemplateBuilder,Be as TemplateElement,De as TemplateElementBuilder,Me as TemplateField,Ue as TemplateInstance,Je as TemplateInstanceBuilder,Ye as TemporalGranularity,xe as TemporalType,Pe as TimeFormat,ke as YamlArtifactParsingResult,We as YamlArtifactReaderResult,Ke as YamlObjectComparator,je as YamlTemplateElementReader,Ge as YamlTemplateElementReaderResult,Xe as YamlTemplateElementWriter,$e as YamlTemplateFieldReader,qe as YamlTemplateFieldReaderResult,He as YamlTemplateFieldWriter,ze as YamlTemplateInstanceReader,Qe as YamlTemplateInstanceReaderResult,Ze as YamlTemplateReader,et as YamlTemplateReaderResult,tt as YamlTemplateWriter,rt as YamlValues,nt as __esModule,n as default};
|
|
2
2
|
//# sourceMappingURL=index.esm.js.map
|