ABB.Swum.Nodes.FieldDeclarationNode.ToString C# (CSharp) Method

ToString() public method

Creates a string representation, including the field's type and name.
public ToString ( ) : string
return string
        public override string ToString() {
            return string.Format("[ {0} - {1} ]", Type.ToString(), base.ToString());
        }

Usage Example

Exemplo n.º 1
0
        public void TestConstructSwum()
        {
            string testSrcML = "<class>class <name>foo</name> <block>{<private type=\"default\"><decl_stmt><decl><type><name>int</name></type> <name>a</name></decl>;</decl_stmt></private>}</block>;</class>";
            XElement xml = XElement.Parse(string.Format(srcMLFormat, testSrcML), LoadOptions.PreserveWhitespace);
            FieldContext fc = ContextBuilder.BuildFieldContext(xml.Descendants(SRC.Declaration).First());

            FieldDeclarationNode fdn = new FieldDeclarationNode("a", fc);
            FieldRule rule = new FieldRule(posData, tagger, splitter);
            rule.ConstructSwum(fdn);
            Console.WriteLine(fdn.ToString());
        }
All Usage Examples Of ABB.Swum.Nodes.FieldDeclarationNode::ToString