コード例 #1
0
ファイル: TextGroup.cs プロジェクト: w01f/VolgaTeam.Dashboard
		public void Deserialize(XmlNode node)
		{
			foreach (XmlNode childNode in node.ChildNodes)
			{
				switch (childNode.Name)
				{
					case "Separator":
						Separator = childNode.InnerText;
						break;
					case "BorderLeft":
						BorderLeft = childNode.InnerText;
						break;
					case "BorderRight":
						BorderRight = childNode.InnerText;
						break;
					case "TextItem":
						{
							var textItem = new TextItem();
							textItem.Deserialize(childNode);
							Items.Add(textItem);
						}
						break;
					case "TextGroup":
						{
							var textItem = new TextGroup();
							textItem.Deserialize(childNode);
							Items.Add(textItem);
						}
						break;
				}
			}
		}
コード例 #2
0
        public void Deserialize(XmlNode node)
        {
            foreach (XmlNode childNode in node.ChildNodes)
            {
                switch (childNode.Name)
                {
                case "Separator":
                    Separator = childNode.InnerText;
                    break;

                case "BorderLeft":
                    BorderLeft = childNode.InnerText;
                    break;

                case "BorderRight":
                    BorderRight = childNode.InnerText;
                    break;

                case "TextItem":
                {
                    var textItem = new TextItem();
                    textItem.Deserialize(childNode);
                    Items.Add(textItem);
                }
                break;

                case "TextGroup":
                {
                    var textItem = new TextGroup();
                    textItem.Deserialize(childNode);
                    Items.Add(textItem);
                }
                break;
                }
            }
        }