Package org.apache.flex.compiler.tree.as

Examples of org.apache.flex.compiler.tree.as.IAccessorNode


    //--------------------------------------------------------------------------

    @Test
    public void testGetAccessor()
    {
        IAccessorNode node = getAccessor("function get foo():int{return -1;}");
        asBlockWalker.visitFunction(node);
        assertOut("function get foo():int {\n\treturn -1;\n}");
    }
View Full Code Here


    }

    @Test
    public void testGetAccessor_withNamespace()
    {
        IAccessorNode node = getAccessor("public function get foo():int{return -1;}");
        asBlockWalker.visitFunction(node);
        assertOut("public function get foo():int {\n\treturn -1;\n}");
    }
View Full Code Here

    }

    @Test
    public void testGetAccessor_withNamespaceOverride()
    {
        IAccessorNode node = getAccessor("public override function get foo():int{return -1;}");
        asBlockWalker.visitFunction(node);
        assertOut("public override function get foo():int {\n\treturn -1;\n}");
    }
View Full Code Here

    }

    @Test
    public void testGetAccessor_withStatic()
    {
        IAccessorNode node = getAccessor("public static function get foo():int{return -1;}");
        asBlockWalker.visitFunction(node);
        assertOut("public static function get foo():int {\n\treturn -1;\n}");
    }
View Full Code Here

    }

    @Test
    public void testSetAccessor()
    {
        IAccessorNode node = getAccessor("function set foo(value:int):void{}");
        asBlockWalker.visitFunction(node);
        assertOut("function set foo(value:int):void {\n}");
    }
View Full Code Here

    }

    @Test
    public void testSetAccessor_withNamespace()
    {
        IAccessorNode node = getAccessor("public function set foo(value:int):void{}");
        asBlockWalker.visitFunction(node);
        assertOut("public function set foo(value:int):void {\n}");
    }
View Full Code Here

    }

    @Test
    public void testSetAccessor_withNamespaceOverride()
    {
        IAccessorNode node = getAccessor("public override function set foo(value:int):void{}");
        asBlockWalker.visitFunction(node);
        assertOut("public override function set foo(value:int):void {\n}");
    }
View Full Code Here

    }

    @Test
    public void testSetAccessor_withStatic()
    {
        IAccessorNode node = getAccessor("public static function set foo(value:int):void{}");
        asBlockWalker.visitFunction(node);
        assertOut("public static function set foo(value:int):void {\n}");
    }
View Full Code Here

    protected IAccessorNode getAccessor(String code)
    {
        String source = "package {public class A {" + code + "}}";
        IFileNode node = getFileNode(source);
        IAccessorNode child = (IAccessorNode) findFirstDescendantOfType(node,
                IAccessorNode.class);
        return child;
    }
View Full Code Here

    //--------------------------------------------------------------------------

    @Test
    public void testGetAccessor()
    {
        IAccessorNode node = getAccessor("function get foo():int{return -1;}");
        visitor.visitFunction(node);
        assertOut("function get foo():int {\n\treturn -1;\n}");
    }
View Full Code Here

TOP

Related Classes of org.apache.flex.compiler.tree.as.IAccessorNode

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.