/// <summary> /// Initializes a new instance of the <see cref="ComponentMapMutableCore"/> class. /// </summary> /// <param name="compMap"> /// The comp map. /// </param> public ComponentMapMutableCore(IComponentMapObject compMap) : base(compMap) { if (compMap.MapConceptRef != null) { this.mapConceptRef = compMap.MapConceptRef; } if (compMap.MapTargetConceptRef != null) { this.mapTargetConceptRef = compMap.MapTargetConceptRef; } if (compMap.RepMapRef != null) { this.repMapRef = new RepresentationMapRefMutableCore(compMap.RepMapRef); } }
/// <summary> /// Initializes a new instance of the <see cref="RepresentationMapRefCore"/> class. /// </summary> /// <param name="xref"> /// The xref. /// </param> /// <param name="parent"> /// The parent. /// </param> /// <exception cref="SdmxSemmanticException"> /// Throws Validate exception. /// </exception> protected internal RepresentationMapRefCore(IRepresentationMapRefMutableObject xref, ISdmxStructure parent) : base(xref, parent) { this.valueMappings = new DictionaryOfSets<string, string>(); if (xref.CodelistMap != null) { this.codelistMap = new CrossReferenceImpl(this, xref.CodelistMap); } if (xref.ToTextFormat != null) { this.toTextFormat = new TextFormatObjectCore(xref.ToTextFormat, this); } if (xref.ValueMappings != null) { this.valueMappings = new DictionaryOfSets<string, string>(xref.ValueMappings); } this.toValueType = xref.ToValueType; try { this.Validate(); } catch (SdmxSemmanticException ex) { throw new SdmxSemmanticException(ex, ExceptionCode.ObjectStructureConstructionError, this); } catch (Exception th) { throw new SdmxException(th, ExceptionCode.ObjectStructureConstructionError, this); } }