コード例 #1
0
ファイル: CssRoot.cs プロジェクト: ishikasofat/Css
        public void InsertChild(int index, CssNode node)
        {
            node.Parent = this;

            children.Insert(index, node);
        }
コード例 #2
0
ファイル: CssRoot.cs プロジェクト: ishikasofat/Css
        public void RemoveChild(CssNode node)
        {
            node.Parent = null;

            children.Remove(node);
        }
コード例 #3
0
ファイル: CssRoot.cs プロジェクト: ishikasofat/Css
        public void AddChild(CssNode node)
        {
            node.Parent = this;

            children.Add(node);
        }
コード例 #4
0
ファイル: CssWriter.cs プロジェクト: carbon/Css
        public void WriteValue(CssNode value)
        {
            if (nodeCount > 50000) throw new Exception("Greater then 50000 nodes written");

            nodeCount++;

            switch (value.Kind)
            {
                case NodeKind.Variable   : WriteVariable((CssVariable)value); break;
                case NodeKind.ValueList  : WriteValueList((CssValueList)value); break;
                case NodeKind.Function   : WriteFunction((CssFunction)value); break;
                case NodeKind.Expression : WriteValue(EvalulateExpression((CssValue)value)); break;
                default                  : writer.Write(value.ToString()); break;
            }
        }
コード例 #5
0
ファイル: CssRoot.cs プロジェクト: carbon/Css
        public void RemoveChild(CssNode node)
        {
            node.Parent = null;

            children.Remove(node);
        }
コード例 #6
0
ファイル: CssRoot.cs プロジェクト: carbon/Css
        public void InsertChild(int index, CssNode node)
        {
            node.Parent = this;

            children.Insert(index, node);
        }
コード例 #7
0
ファイル: CssRoot.cs プロジェクト: carbon/Css
        public void AddChild(CssNode node)
        {
            node.Parent = this;

            children.Add(node);
        }
コード例 #8
0
ファイル: CssNode.cs プロジェクト: carbon/Css
        public CssNode(NodeKind kind, CssNode parent = null)
        {
            Kind = kind;

            this.parent = parent;
        }