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

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


    }

    @Test
    public void testSecurityError()
    {
        IVariableNode node = getVariable("var a:SecurityError = new SecurityError();");
        asBlockWalker.visitVariable(node);
        assertOut("var a:SecurityError = new SecurityError()");
    }
View Full Code Here


    @Override
    @Test
    public void testField_withNamespaceTypeValueComplex()
    {
        IVariableNode node = getField("protected var foo:Foo = new Foo('bar', 42);");
        asBlockWalker.visitVariable(node);
        assertOut("/**\n * @protected\n * @type {Foo}\n */\nFalconTest_A.prototype.foo = new Foo('bar', 42)");
    }
View Full Code Here

    @Override
    @Test
    public void testField_withList()
    {
        IVariableNode node = getField("protected var a:int = 4, b:int = 11, c:int = 42;");
        asBlockWalker.visitVariable(node);
        assertOut("/**\n * @protected\n * @type {number}\n */\nFalconTest_A.prototype.a = 4;\n\n/**\n * @protected\n * @type {number}\n */\nFalconTest_A.prototype.b = 11;\n\n/**\n * @protected\n * @type {number}\n */\nFalconTest_A.prototype.c = 42");
    }
View Full Code Here

    }

    @Test
    public void testString()
    {
        IVariableNode node = getVariable("var a:String = new String(\"100\");");
        asBlockWalker.visitVariable(node);
        assertOut("var a:String = new String(\"100\")");
    }
View Full Code Here

    }

    @Test
    public void testSyntaxError()
    {
        IVariableNode node = getVariable("var a:SyntaxError = new SyntaxError();");
        asBlockWalker.visitVariable(node);
        assertOut("var a:SyntaxError = new SyntaxError()");
    }
View Full Code Here

    }

    @Test
    public void testTypeError()
    {
        IVariableNode node = getVariable("var a:TypeError = new TypeError();");
        asBlockWalker.visitVariable(node);
        assertOut("var a:TypeError = new TypeError()");
    }
View Full Code Here

    @Override
    @Test
    public void testConstant()
    {
        IVariableNode node = getField("static const foo;");
        asBlockWalker.visitVariable(node);
        assertOut("/**\n * @const\n * @type {*}\n */\nFalconTest_A.foo");
    }
View Full Code Here

    }

    @Test
    public void testUint()
    {
        IVariableNode node = getVariable("var a:uint = new uint(-100);");
        asBlockWalker.visitVariable(node);
        assertOut("var a:uint = new uint(-100)");
    }
View Full Code Here

    }

    @Test
    public void testConstant_nonStatic()
    {
        IVariableNode node = getField("const foo;");
        asBlockWalker.visitVariable(node);
        assertOut("/**\n * @const\n * @type {*}\n */\nFalconTest_A.prototype.foo");
    }
View Full Code Here

    @Override
    @Test
    public void testConstant_withType()
    {
        IVariableNode node = getField("static const foo:int;");
        asBlockWalker.visitVariable(node);
        assertOut("/**\n * @const\n * @type {number}\n */\nFalconTest_A.foo");
    }
View Full Code Here

TOP

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

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.