コード例 #1
0
 public FeatureStatus(JToken node) : base(node)
 {
     if (node["type"] != null)
     {
         this._Type = (FeatureStatusType)ParseEnum(typeof(FeatureStatusType), node["type"].Value <string>());
     }
     if (node["value"] != null)
     {
         this._Value = ParseInt(node["value"].Value <string>());
     }
 }
コード例 #2
0
        public FeatureStatus(XmlElement node) : base(node)
        {
            foreach (XmlElement propertyNode in node.ChildNodes)
            {
                switch (propertyNode.Name)
                {
                case "type":
                    this._Type = (FeatureStatusType)ParseEnum(typeof(FeatureStatusType), propertyNode.InnerText);
                    continue;

                case "value":
                    this._Value = ParseInt(propertyNode.InnerText);
                    continue;
                }
            }
        }