///////////////////////////////////////////////////////////////////////////////////////////////////
        ////////////BUILD FROM MUTABLE OBJECT                 //////////////////////////////////////////////////
        ///////////////////////////////////////////////////////////////////////////////////////////////////
        #region Constructors and Destructors

        /// <summary>
        /// Initializes a new instance of the <see cref="ConstraintDataKeySetCore"/> class.
        /// </summary>
        /// <param name="mutable">
        /// The mutable. 
        /// </param>
        /// <param name="parent">
        /// The parent. 
        /// </param>
        public ConstraintDataKeySetCore(IConstraintDataKeySetMutableObject mutable, IConstraintObject parent)
            : base(SdmxStructureType.GetFromEnum(SdmxStructureEnumType.ConstrainedDataKeyset), parent)
        {
            this.contstrainedKeys = new List<IConstrainedDataKey>();

            foreach (IConstrainedDataKeyMutableObject each in mutable.ConstrainedDataKeys)
            {
                IConstrainedDataKey cdk = new ConstrainedDataKeyCore(each, this);
                if (ObjectUtil.ValidCollection(cdk.KeyValues))
                {
                    this.contstrainedKeys.Add(cdk);
                }
            }
        }
        ///////////////////////////////////////////////////////////////////////////////////////////////////
        ////////////BUILD FROM V2.1 SCHEMA                 //////////////////////////////////////////////////
        ///////////////////////////////////////////////////////////////////////////////////////////////////

        /// <summary>
        /// Initializes a new instance of the <see cref="ConstraintDataKeySetCore"/> class.
        /// </summary>
        /// <param name="dataKeySetType">
        /// The data key set type. 
        /// </param>
        /// <param name="parent">
        /// The parent. 
        /// </param>
        public ConstraintDataKeySetCore(DataKeySetType dataKeySetType, IConstraintObject parent)
            : base(SdmxStructureType.GetFromEnum(SdmxStructureEnumType.ConstrainedDataKeyset), parent)
        {
            this.contstrainedKeys = new List<IConstrainedDataKey>();
            if (dataKeySetType.Key != null)
            {
                foreach (DistinctKeyType currentKey in dataKeySetType.Key)
                {
                    IConstrainedDataKey cdk = new ConstrainedDataKeyCore(currentKey, this);
                    if (ObjectUtil.ValidCollection(cdk.KeyValues))
                    {
                        this.contstrainedKeys.Add(cdk);
                    }
                }
            }
        }