flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mschma...@apache.org
Subject svn commit: r1452955 [4/9] - in /flex/falcon/trunk: compiler.jx.tests/src/org/apache/flex/compiler/internal/as/ compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/ compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/as/ compile...
Date Tue, 05 Mar 2013 19:22:09 GMT
Added: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLNodes.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLNodes.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLNodes.java (added)
+++ flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLNodes.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,169 @@
+package org.apache.flex.compiler.internal.codegen.mxml;
+
+import org.apache.flex.compiler.internal.test.MXMLTestBase;
+import org.apache.flex.compiler.tree.mxml.IMXMLPropertySpecifierNode;
+import org.junit.Test;
+
+public class TestMXMLNodes extends MXMLTestBase
+{
+
+    @Test
+    public void testSimpleNode()
+    {
+        String code = "<s:Button />";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Button></Button>");
+    }
+
+    @Test
+    public void testSimpleNodeWithId()
+    {
+        String code = "<s:Button id=\"myBtn\"/>";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Button id=\"myBtn\"></Button>");
+    }
+
+    @Test
+    public void testSimpleNodeWithAttribute()
+    {
+        String code = "<s:Button label=\"Click me\" />";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Button label=\"Click me\"></Button>");
+    }
+
+    @Test
+    public void testSimpleNodeWithInnerText()
+    {
+        String code = "<s:Button>Click me</s:Button>";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Button label=\"Click me\"></Button>");
+    }
+
+    @Test
+    public void testAnotherSimpleNodeWithInnerText()
+    {
+        String code = "<s:Label>Hello World!</s:Label>";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Label text=\"Hello World!\"></Label>");
+    }
+
+    @Test
+    public void testSimpleNodeWithMultipleAttributes()
+    {
+        String code = "<s:Button visible=\"false\" x=\"100\" width=\"1.5\" label=\"Click me ;-)\" color=\"0xFF0000\"/>";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Button visible=\"false\" color=\"16711680\" width=\"1.5\" label=\"Click me ;-)\" x=\"100\"></Button>");
+    }
+
+    @Test
+    public void testNodeWithChild()
+    {
+        String code = "<s:Group><s:RadioButton /></s:Group>";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Group><RadioButton></RadioButton></Group>");
+    }
+
+    @Test
+    public void testNodeWithChildAndAttribute()
+    {
+        String code = "<s:Group id=\"myGrp\"><s:RadioButton /></s:Group>";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Group id=\"myGrp\"><RadioButton></RadioButton></Group>");
+    }
+
+    @Test
+    public void testNodeWithNestedChildren()
+    {
+        String code = "<s:Group><s:Group><s:Group>" + "<s:RadioButton />"
+                + "</s:Group></s:Group></s:Group>";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Group><Group><Group><RadioButton></RadioButton></Group></Group></Group>");
+    }
+
+    @Test
+    public void testNodeWithNestedChildrenAndAttribute()
+    {
+        String code = "<s:Group><s:Group><s:Group>"
+                + "<s:RadioButton id=\"myRB\"/>"
+                + "</s:Group></s:Group></s:Group>";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Group><Group><Group><RadioButton id=\"myRB\"></RadioButton></Group></Group></Group>");
+    }
+
+    @Test
+    public void testNodeWithNestedChildrenAndInnerText()
+    {
+        String code = "<s:Group><s:Group><s:Group>"
+                + "<s:Button>Click me</s:Button>"
+                + "</s:Group></s:Group></s:Group>";
+
+        IMXMLPropertySpecifierNode node = (IMXMLPropertySpecifierNode) getNode(
+                code, IMXMLPropertySpecifierNode.class,
+                MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitPropertySpecifier(node);
+
+        assertOut("<Group><Group><Group><Button label=\"Click me\"></Button></Group></Group></Group>");
+    }
+
+}

Propchange: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLNodes.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLScript.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLScript.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLScript.java (added)
+++ flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLScript.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,91 @@
+package org.apache.flex.compiler.internal.codegen.mxml;
+
+import org.apache.flex.compiler.internal.test.MXMLTestBase;
+import org.apache.flex.compiler.tree.mxml.IMXMLScriptNode;
+import org.junit.Ignore;
+import org.junit.Test;
+
+public class TestMXMLScript extends MXMLTestBase
+{
+
+    @Test
+    public void testEmptyScript()
+    {
+        String code = "" + "<fx:Script><![CDATA[]]></fx:Script>";
+
+        IMXMLScriptNode node = (IMXMLScriptNode) getNode(code,
+                IMXMLScriptNode.class, MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitScript(node);
+
+        assertOut("<script><![CDATA[]]></script>");
+    }
+
+    @Test
+    public void testSimpleScript()
+    {
+        String code = "" + "<fx:Script><![CDATA["
+                + "    private const GREETING:String = \"Hello world!\";"
+                + "]]></fx:Script>";
+
+        IMXMLScriptNode node = (IMXMLScriptNode) getNode(code,
+                IMXMLScriptNode.class, MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitScript(node);
+
+        assertOut("<script><![CDATA[\n\tprivate const GREETING:String = \"Hello world!\";\n]]></script>");
+    }
+
+    @Test
+    public void testMultiLineScript()
+    {
+        String code = "" + "<fx:Script><![CDATA["
+                + "    public var goodbye:String = \"Bye bye :-(\";"
+                + "    private const GREETING:String = \"Hello world!\";"
+                + "]]></fx:Script>";
+
+        IMXMLScriptNode node = (IMXMLScriptNode) getNode(code,
+                IMXMLScriptNode.class, MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitScript(node);
+
+        assertOut("<script><![CDATA[\n\tpublic var goodbye:String = \"Bye bye :-(\";\n\tprivate const GREETING:String = \"Hello world!\";\n]]></script>");
+    }
+
+    @Test
+    public void testComplexScript()
+    {
+        // TODO (erikdebruin) fix indentation...
+        String code = "" + "<fx:Script><![CDATA[" + "    var n:int = 3;"
+                + "    for (var i:int = 0; i < n; i++)" + "    {"
+                + "        Alert.show(\"Hi\");" + "    }" + "]]></fx:Script>";
+
+        IMXMLScriptNode node = (IMXMLScriptNode) getNode(code,
+                IMXMLScriptNode.class, MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitScript(node);
+
+        assertOut("<script><![CDATA[\n\tvar n:int = 3;\n\tfor (var i:int = 0; i < n; i++) {\n\tAlert.show(\"Hi\");\n};\n]]></script>");
+    }
+
+    @Ignore
+    @Test
+    public void testFunctionScript()
+    {
+        // TODO (erikdebruin) this isn't working...
+        String code = "" + "<fx:Script><![CDATA["
+                + "    public static function beNice(input:*):Object" + "    {"
+                + "        Alert.show(\"I'm nice :-P\");"
+                + "        return null;" + "    }" + "]]></fx:Script>";
+
+        IMXMLScriptNode node = (IMXMLScriptNode) getNode(code,
+                IMXMLScriptNode.class, MXMLTestBase.WRAP_LEVEL_DOCUMENT);
+
+        mxmlBlockWalker.visitScript(node);
+
+        System.out.println(writer.toString());
+
+        assertOut("<script><![CDATA[\n\tvar n:int = 3;\n\tfor (var i:int = 0; i < n; i++) {\n\tAlert.show(\"Hi\");\n};\n]]></script>");
+    }
+
+}

Propchange: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/TestMXMLScript.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/flexjs/TestFlexJSMXMLApplication.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/flexjs/TestFlexJSMXMLApplication.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/flexjs/TestFlexJSMXMLApplication.java (added)
+++ flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/flexjs/TestFlexJSMXMLApplication.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,96 @@
+package org.apache.flex.compiler.internal.codegen.mxml.flexjs;
+
+import org.apache.flex.compiler.internal.test.FlexJSTestBase;
+import org.apache.flex.compiler.tree.mxml.IMXMLFileNode;
+import org.junit.Ignore;
+import org.junit.Test;
+
+public class TestFlexJSMXMLApplication extends FlexJSTestBase
+{
+
+    // TODO (erikdebruin) this needs to become JS Goog output ;-)
+
+    @Test
+    public void testBasicFlexJSApp()
+    {
+        String code = ""
+                + "<basic:Application xmlns:basic=\"library://ns.apache.org/flexjs/basic\">"
+                + "</basic:Application>";
+
+        IMXMLFileNode node = compileMXML(code);
+
+        mxmlBlockWalker.visitFile(node);
+
+        assertOut("<Application>\n</Application>");
+    }
+
+    @Test
+    public void testFlexJSAppWithEvent()
+    {
+        String code = ""
+                + "<basic:Application xmlns:basic=\"library://ns.apache.org/flexjs/basic\""
+                + "                   initialize=\"MyModel(model).labelText='Hello World'\">"
+                + "</basic:Application>";
+
+        IMXMLFileNode node = compileMXML(code);
+
+        mxmlBlockWalker.visitFile(node);
+
+        assertOut("<Application initialize=\"MyModel(model).labelText = 'Hello World'\">\n</Application>");
+    }
+
+    @Test
+    public void testFlexJSAppWithNode()
+    {
+        String code = ""
+                + "<basic:Application xmlns:basic=\"library://ns.apache.org/flexjs/basic\">"
+                + "    <basic:beads />" + "</basic:Application>";
+
+        IMXMLFileNode node = compileMXML(code);
+
+        mxmlBlockWalker.visitFile(node);
+
+        assertOut("<Application>\n\t<beads></beads>\n</Application>");
+    }
+
+    @Test
+    public void testFlexJSAppWithNodeAndChild()
+    {
+        String code = ""
+                + "<basic:Application xmlns:fx=\"http://ns.adobe.com/mxml/2009\""
+                + "                   xmlns:local=\"*\""
+                + "                   xmlns:basic=\"library://ns.apache.org/flexjs/basic\">"
+                + "    <basic:beads>"
+                + "        <basic:HTTPService id=\"service\">"
+                + "            <basic:LazyCollection id=\"collection\">"
+                + "                <basic:inputParser>"
+                + "                    <basic:JSONInputParser />"
+                + "                </basic:inputParser>"
+                + "                <basic:itemConverter>"
+                + "                    <local:StockDataJSONItemConverter />"
+                + "                </basic:itemConverter>"
+                + "            </basic:LazyCollection id=\"collection\">"
+                + "        </basic:HTTPService>" + "    </basic:beads>"
+                + "</basic:Application>";
+
+        IMXMLFileNode node = compileMXML(code);
+
+        mxmlBlockWalker.visitFile(node);
+
+        assertOut("<Application>\n\t<beads>\n\t\t<HTTPService id=\"service\">\n\t\t\t<beads>\n\t\t\t\t<LazyCollection id=\"collection\">\n\t\t\t\t\t<inputParser>\n\t\t\t\t\t\t<JSONInputParser>\n\t\t\t\t\t\t</JSONInputParser>\n\t\t\t\t\t</inputParser>\n\t\t\t\t\t<itemConverter>\n\t\t\t\t\t\t<StockDataJSONItemConverter>\n\t\t\t\t\t\t</StockDataJSONItemConverter>\n\t\t\t\t\t</itemConverter>\n\t\t\t\t</LazyCollection>\n\t\t\t</beads>\n\t\t</HTTPService>\n\t</beads>\n</Application>");
+    }
+
+    @Ignore
+    @Test
+    public void MXMLClassNode_flashDisplaySprite()
+    {
+        IMXMLFileNode node = compileMXML("FlexJSTest", true, asjsRoot
+                + "examples/FlexJSTest_again", false);
+
+        mxmlBlockWalker.visitFile(node);
+
+        //System.out.println(writer.toString());
+
+        assertOut("");
+    }
+}

Propchange: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/codegen/mxml/flexjs/TestFlexJSMXMLApplication.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/AMDTestBase.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/AMDTestBase.java?rev=1452955&r1=1452954&r2=1452955&view=diff
==============================================================================
--- flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/AMDTestBase.java (original)
+++ flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/AMDTestBase.java Tue Mar  5 19:22:05 2013
@@ -21,8 +21,8 @@ package org.apache.flex.compiler.interna
 
 import java.io.File;
 
-import org.apache.flex.compiler.common.driver.IBackend;
-import org.apache.flex.compiler.internal.js.driver.amd.AMDBackend;
+import org.apache.flex.compiler.driver.IBackend;
+import org.apache.flex.compiler.internal.driver.js.amd.AMDBackend;
 import org.apache.flex.compiler.tree.as.IClassNode;
 import org.apache.flex.compiler.tree.as.IDefinitionNode;
 import org.apache.flex.compiler.tree.as.IFileNode;
@@ -48,7 +48,7 @@ public abstract class AMDTestBase extend
     protected IInterfaceNode interfaceNode;
 
     private String projectPath;
-    
+
     @Override
     public void setUp()
     {
@@ -58,7 +58,7 @@ public abstract class AMDTestBase extend
         asBlockWalker = backend.createWalker(project, errors, asEmitter);
 
         projectPath = "test-files/amd/simple-project/src";
-        
+
         String target = getTypeUnderTest().replace(".", File.separator);
         String targetDir = projectPath + File.separator
                 + target.substring(0, target.lastIndexOf(File.separator));
@@ -82,16 +82,15 @@ public abstract class AMDTestBase extend
     {
         libraries.add(new File(FilenameNormalization.normalize(env.FPSDK
                 + "/11.1/playerglobal.swc")));
-        
+
         super.addLibraries();
     }
-    
+
     @Override
     public void addSourcePaths()
     {
-        sourcePaths.add(new File(FilenameNormalization
-                .normalize(projectPath)));
-        
+        sourcePaths.add(new File(FilenameNormalization.normalize(projectPath)));
+
         super.addSourcePaths();
     }
 

Modified: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/ASTestBase.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/ASTestBase.java?rev=1452955&r1=1452954&r2=1452955&view=diff
==============================================================================
--- flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/ASTestBase.java (original)
+++ flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/ASTestBase.java Tue Mar  5 19:22:05 2013
@@ -2,8 +2,8 @@ package org.apache.flex.compiler.interna
 
 import java.io.File;
 
-import org.apache.flex.compiler.common.driver.IBackend;
-import org.apache.flex.compiler.internal.as.driver.ASBackend;
+import org.apache.flex.compiler.driver.IBackend;
+import org.apache.flex.compiler.internal.driver.as.ASBackend;
 import org.apache.flex.compiler.tree.as.IASNode;
 import org.apache.flex.compiler.tree.as.IAccessorNode;
 import org.apache.flex.compiler.tree.as.IBinaryOperatorNode;
@@ -25,7 +25,7 @@ public class ASTestBase extends TestBase
     public void setUp()
     {
         super.setUp();
-        
+
         asEmitter = backend.createEmitter(writer);
         asBlockWalker = backend.createWalker(project, errors, asEmitter);
     }
@@ -39,7 +39,7 @@ public class ASTestBase extends TestBase
                 + "/frameworks/libs/framework.swc")));
         libraries.add(new File(FilenameNormalization.normalize(env.SDK
                 + "/frameworks/libs/spark.swc")));
-        
+
         super.addLibraries();
     }
 
@@ -48,7 +48,7 @@ public class ASTestBase extends TestBase
     {
         return new ASBackend();
     }
-    
+
     //--------------------------------------------------------------------------
     // Node "factory"
     //--------------------------------------------------------------------------
@@ -78,8 +78,8 @@ public class ASTestBase extends TestBase
             code = "public class A {" + code + "}";
 
         if (wrapLevel >= WRAP_LEVEL_PACKAGE)
-            code = "package"
-                    + ((includePackage) ? " foo.bar" : "") + " {" + code + "}";
+            code = "package" + ((includePackage) ? " foo.bar" : "") + " {"
+                    + code + "}";
 
         IFileNode node = compileAS(code);
 

Modified: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/FlexJSTestBase.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/FlexJSTestBase.java?rev=1452955&r1=1452954&r2=1452955&view=diff
==============================================================================
--- flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/FlexJSTestBase.java (original)
+++ flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/FlexJSTestBase.java Tue Mar  5 19:22:05 2013
@@ -2,8 +2,8 @@ package org.apache.flex.compiler.interna
 
 import java.io.File;
 
-import org.apache.flex.compiler.common.driver.IBackend;
-import org.apache.flex.compiler.internal.mxml.driver.flexjs.MXMLFlexJSBackend;
+import org.apache.flex.compiler.driver.IBackend;
+import org.apache.flex.compiler.internal.driver.mxml.flexjs.MXMLFlexJSBackend;
 import org.apache.flex.compiler.mxml.MXMLNamespaceMapping;
 import org.apache.flex.utils.FilenameNormalization;
 import org.junit.Ignore;

Modified: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/ITestBase.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/ITestBase.java?rev=1452955&r1=1452954&r2=1452955&view=diff
==============================================================================
--- flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/ITestBase.java (original)
+++ flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/ITestBase.java Tue Mar  5 19:22:05 2013
@@ -4,7 +4,9 @@ public interface ITestBase
 {
 
     void addLibraries();
+
     void addNamespaceMappings();
+
     void addSourcePaths();
 
 }

Modified: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/MXMLTestBase.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/MXMLTestBase.java?rev=1452955&r1=1452954&r2=1452955&view=diff
==============================================================================
--- flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/MXMLTestBase.java (original)
+++ flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/MXMLTestBase.java Tue Mar  5 19:22:05 2013
@@ -2,8 +2,8 @@ package org.apache.flex.compiler.interna
 
 import java.io.File;
 
-import org.apache.flex.compiler.common.driver.IBackend;
-import org.apache.flex.compiler.internal.mxml.driver.MXMLBackend;
+import org.apache.flex.compiler.driver.IBackend;
+import org.apache.flex.compiler.internal.driver.mxml.MXMLBackend;
 import org.apache.flex.compiler.mxml.MXMLNamespaceMapping;
 import org.apache.flex.compiler.tree.mxml.IMXMLFileNode;
 import org.apache.flex.compiler.tree.mxml.IMXMLNode;

Modified: flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/TestBase.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/TestBase.java?rev=1452955&r1=1452954&r2=1452955&view=diff
==============================================================================
--- flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/TestBase.java (original)
+++ flex/falcon/trunk/compiler.jx.tests/src/org/apache/flex/compiler/internal/test/TestBase.java Tue Mar  5 19:22:05 2013
@@ -15,24 +15,24 @@ import java.util.ArrayList;
 import java.util.Collection;
 import java.util.List;
 
-import org.apache.flex.compiler.as.codegen.IASEmitter;
-import org.apache.flex.compiler.common.driver.IBackend;
-import org.apache.flex.compiler.internal.as.codegen.ASFilterWriter;
+import org.apache.flex.compiler.codegen.as.IASEmitter;
+import org.apache.flex.compiler.codegen.mxml.IMXMLEmitter;
+import org.apache.flex.compiler.driver.IBackend;
+import org.apache.flex.compiler.internal.codegen.as.ASFilterWriter;
 import org.apache.flex.compiler.internal.projects.FlexProject;
 import org.apache.flex.compiler.internal.projects.FlexProjectConfigurator;
 import org.apache.flex.compiler.internal.projects.ISourceFileHandler;
 import org.apache.flex.compiler.internal.tree.as.FunctionNode;
 import org.apache.flex.compiler.internal.workspaces.Workspace;
 import org.apache.flex.compiler.mxml.IMXMLNamespaceMapping;
-import org.apache.flex.compiler.mxml.codegen.IMXMLEmitter;
 import org.apache.flex.compiler.problems.ICompilerProblem;
 import org.apache.flex.compiler.tree.as.IASNode;
 import org.apache.flex.compiler.tree.as.IFileNode;
 import org.apache.flex.compiler.tree.mxml.IMXMLFileNode;
 import org.apache.flex.compiler.units.ICompilationUnit;
 import org.apache.flex.compiler.utils.EnvProperties;
-import org.apache.flex.compiler.visitor.IASBlockWalker;
-import org.apache.flex.compiler.visitor.IMXMLBlockWalker;
+import org.apache.flex.compiler.visitor.as.IASBlockWalker;
+import org.apache.flex.compiler.visitor.mxml.IMXMLBlockWalker;
 import org.apache.flex.utils.FilenameNormalization;
 import org.junit.After;
 import org.junit.Before;
@@ -50,7 +50,7 @@ public class TestBase implements ITestBa
 
     protected IBackend backend;
     protected ASFilterWriter writer;
-    
+
     protected IASEmitter asEmitter;
     protected IMXMLEmitter mxmlEmitter;
 
@@ -263,8 +263,8 @@ public class TestBase implements ITestBa
     {
         String testFileDir = FilenameNormalization.normalize("test-files");
 
-        File testFile = new File(testFileDir
-                + File.separator + sourceDir + File.separator + fileName
+        File testFile = new File(testFileDir + File.separator + sourceDir
+                + File.separator + fileName
                 + (isJS ? ".js" : inputFileExtension));
 
         String code = "";

Propchange: flex/falcon/trunk/compiler.jx/bin/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Tue Mar  5 19:22:05 2013
@@ -0,0 +1 @@
+org

Modified: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/clients/MXMLJSC.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/clients/MXMLJSC.java?rev=1452955&r1=1452954&r2=1452955&view=diff
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/clients/MXMLJSC.java (original)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/clients/MXMLJSC.java Tue Mar  5 19:22:05 2013
@@ -32,27 +32,29 @@ import java.util.List;
 import java.util.Set;
 
 import org.apache.commons.io.FilenameUtils;
-import org.apache.flex.compiler.as.codegen.IASWriter;
 import org.apache.flex.compiler.clients.problems.ProblemPrinter;
 import org.apache.flex.compiler.clients.problems.ProblemQuery;
 import org.apache.flex.compiler.clients.problems.WorkspaceProblemFormatter;
+import org.apache.flex.compiler.codegen.as.IASWriter;
+import org.apache.flex.compiler.codegen.js.IJSPublisher;
 import org.apache.flex.compiler.common.VersionInfo;
-import org.apache.flex.compiler.common.driver.IBackend;
 import org.apache.flex.compiler.config.Configuration;
 import org.apache.flex.compiler.config.ConfigurationBuffer;
 import org.apache.flex.compiler.config.Configurator;
 import org.apache.flex.compiler.config.ICompilerSettingsConstants;
+import org.apache.flex.compiler.driver.IBackend;
+import org.apache.flex.compiler.driver.js.IJSApplication;
 import org.apache.flex.compiler.exceptions.ConfigurationException;
 import org.apache.flex.compiler.exceptions.ConfigurationException.IOError;
 import org.apache.flex.compiler.exceptions.ConfigurationException.MustSpecifyTarget;
 import org.apache.flex.compiler.exceptions.ConfigurationException.OnlyOneSource;
-import org.apache.flex.compiler.internal.as.driver.ASBackend;
-import org.apache.flex.compiler.internal.js.codegen.JSPublisher;
-import org.apache.flex.compiler.internal.js.codegen.JSSharedData;
-import org.apache.flex.compiler.internal.js.codegen.goog.JSGoogPublisher;
-import org.apache.flex.compiler.internal.js.driver.JSBackend;
-import org.apache.flex.compiler.internal.js.driver.amd.AMDBackend;
-import org.apache.flex.compiler.internal.js.driver.goog.GoogBackend;
+import org.apache.flex.compiler.internal.codegen.js.JSPublisher;
+import org.apache.flex.compiler.internal.codegen.js.JSSharedData;
+import org.apache.flex.compiler.internal.codegen.js.goog.JSGoogPublisher;
+import org.apache.flex.compiler.internal.driver.as.ASBackend;
+import org.apache.flex.compiler.internal.driver.js.JSBackend;
+import org.apache.flex.compiler.internal.driver.js.amd.AMDBackend;
+import org.apache.flex.compiler.internal.driver.js.goog.GoogBackend;
 import org.apache.flex.compiler.internal.projects.CompilerProject;
 import org.apache.flex.compiler.internal.projects.FlexProject;
 import org.apache.flex.compiler.internal.projects.ISourceFileHandler;
@@ -60,8 +62,6 @@ import org.apache.flex.compiler.internal
 import org.apache.flex.compiler.internal.units.ResourceModuleCompilationUnit;
 import org.apache.flex.compiler.internal.units.SourceCompilationUnitFactory;
 import org.apache.flex.compiler.internal.workspaces.Workspace;
-import org.apache.flex.compiler.js.IJSApplication;
-import org.apache.flex.compiler.js.codegen.IJSPublisher;
 import org.apache.flex.compiler.problems.ConfigurationProblem;
 import org.apache.flex.compiler.problems.ICompilerProblem;
 import org.apache.flex.compiler.problems.InternalCompilerProblem;
@@ -146,18 +146,22 @@ public class MXMLJSC
         {
             if (s.contains("-js-output-type"))
             {
-                JSOutputType outputType = JSOutputType.fromString(s.split("=")[1]);
-                
+                JSOutputType outputType = JSOutputType
+                        .fromString(s.split("=")[1]);
+
                 switch (outputType)
                 {
-                case AMD :
-                    backend = new AMDBackend(); break;
-                case FLEXJS :
-                    backend = new JSBackend(); break;
-                case GOOG :
-                    backend = new GoogBackend(); break;
+                case AMD:
+                    backend = new AMDBackend();
+                    break;
+                case FLEXJS:
+                    backend = new JSBackend();
+                    break;
+                case GOOG:
+                    backend = new GoogBackend();
+                    break;
                 }
-                
+
                 break;
             }
         }
@@ -704,8 +708,8 @@ public class MXMLJSC
             // Print version if "-version" is present.
             if (configBuffer.getVar("version") != null) //$NON-NLS-1$
             {
-                println(VersionInfo.buildMessage()
-                        + " (" + JSSharedData.COMPILER_VERSION + ")");
+                println(VersionInfo.buildMessage() + " ("
+                        + JSSharedData.COMPILER_VERSION + ")");
                 return false;
             }
             //

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IASGlobalFunctionConstants.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IASGlobalFunctionConstants.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IASGlobalFunctionConstants.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IASGlobalFunctionConstants.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,92 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen;
+
+/**
+ * AS3 language global functions, such as Array, encodeURI, isNaN etc.
+ * 
+ * @author Erik de Bruin
+ */
+public interface IASGlobalFunctionConstants
+{
+    static final String Array = "Array";
+    static final String Boolean = "Boolean";
+    static final String decodeURI = "decodeURI";
+    static final String decodeURIComponent = "decodeURIComponent";
+    static final String encodeURI = "encodeURI";
+    static final String encodeURIComponent = "encodeURIComponent";
+    static final String escape = "escape";
+    static final String _int = "int";
+    static final String isFinite = "isFinite";
+    static final String isNaN = "isNaN";
+    static final String isXMLName = "isXMLName";
+    static final String Number = "Number";
+    static final String Object = "Object";
+    static final String parseFloat = "parseFloat";
+    static final String parseInt = "parseInt";
+    static final String String = "String";
+    static final String trace = "trace";
+    static final String uint = "uint";
+    static final String unescape = "unescape";
+    static final String Vector = "Vector";
+    static final String XML = "XML";
+    static final String XMLList = "XMLList";
+
+    /**
+     * An enumeration of core built-in functions.
+     */
+    public static enum BuiltinType
+    {
+        ARRAY(IASGlobalFunctionConstants.Array), BOOLEAN(
+                IASGlobalFunctionConstants.Boolean), DECODEURI(
+                IASGlobalFunctionConstants.decodeURI), DECODEURICOMPONENT(
+                IASGlobalFunctionConstants.decodeURIComponent), ENCODEURI(
+                IASGlobalFunctionConstants.encodeURI), ENCODEURICOMPONENT(
+                IASGlobalFunctionConstants.encodeURIComponent), ESCAPE(
+                IASGlobalFunctionConstants.escape), INT(
+                IASGlobalFunctionConstants._int), ISFINITE(
+                IASGlobalFunctionConstants.isFinite), ISNAN(
+                IASGlobalFunctionConstants.isNaN), ISXMLNAME(
+                IASGlobalFunctionConstants.isXMLName), NUMBER(
+                IASGlobalFunctionConstants.Number), OBJECT(
+                IASGlobalFunctionConstants.Object), PARSEFLOAT(
+                IASGlobalFunctionConstants.parseFloat), PARSEINT(
+                IASGlobalFunctionConstants.parseInt), STRING(
+                IASGlobalFunctionConstants.String), TRACE(
+                IASGlobalFunctionConstants.trace), UINT(
+                IASGlobalFunctionConstants.uint), UNESCAPE(
+                IASGlobalFunctionConstants.unescape), VECTOR(
+                IASGlobalFunctionConstants.Vector), XML(
+                IASGlobalFunctionConstants.XML), XMLLIST(
+                IASGlobalFunctionConstants.XMLList);
+
+        private BuiltinType(String name)
+        {
+            this.name = name;
+        }
+
+        private final String name;
+
+        public String getName()
+        {
+            return name;
+        }
+    }
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IASGlobalFunctionConstants.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IDocEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IDocEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IDocEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IDocEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,32 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen;
+
+/**
+ * Base interface for documentation emitters.
+ * 
+ * @author Michael Schmalle
+ */
+public interface IDocEmitter
+{
+    void begin();
+
+    void end();
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IDocEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,100 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen;
+
+import org.apache.flex.compiler.internal.codegen.as.ASEmitterTokens;
+
+/**
+ * @author Michael Schmalle
+ * @author Erik de Bruin
+ */
+public interface IEmitter
+{
+
+    /**
+     * Pushes an indent into the emitter so after newlines are emitted, the
+     * output is correctly formatted.
+     */
+    void indentPush();
+
+    /**
+     * Pops an indent from the emitter so after newlines are emitted, the output
+     * is correctly formatted.
+     */
+    void indentPop();
+
+    /**
+     * Writes a string to the writer.
+     * 
+     * @param value The string to write to the output buffer.
+     */
+    void write(IEmitterTokens value);
+
+    void write(String value);
+
+    /**
+     * Writes newline character(s)
+     */
+    void writeNewline();
+
+    /**
+     * Writes the <code>value</code> and then a newline which will automatically
+     * have the indent applied after the \n character.
+     * 
+     * @param value The String value to write before the \n is appended.
+     */
+    void writeNewline(IEmitterTokens value);
+
+    void writeNewline(String value);
+
+    /**
+     * Writes the <code>value</code> after a push or pop of the indent.
+     * <p>
+     * This method effectively lets you write a value and then indent our
+     * outdent. The method can be useful in the following where your cursor
+     * writer is at <code>[0]</code>, you write
+     * <code>writeNewline("if (foo) {", true);</code> and the cursor after the
+     * call will end up at <code>[1]</code>.
+     * 
+     * <pre>
+     * [0]if (foo) {
+     *     [1]this.something;
+     * }
+     * </pre>
+     * 
+     * @param value The String value to write before the \n is appended.
+     * @param pushIndent Whether to push indent <code>true</code> or pop indent
+     * <code>false</code>.
+     */
+    void writeNewline(IEmitterTokens value, boolean pushIndent);
+
+    void writeNewline(String value, boolean pushIndent);
+
+    /**
+     * Writes a {@link ASEmitterTokens} character to the buffer and appends a
+     * space after automatically.
+     * 
+     * @param value The {@link ASEmitterTokens} value.
+     */
+    void writeToken(IEmitterTokens value);
+
+    void writeToken(String value);
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitterTokens.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitterTokens.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitterTokens.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitterTokens.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,6 @@
+package org.apache.flex.compiler.codegen;
+
+public interface IEmitterTokens
+{
+    String getToken();
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/IEmitterTokens.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,349 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.as;
+
+import java.io.Writer;
+
+import org.apache.flex.compiler.codegen.IDocEmitter;
+import org.apache.flex.compiler.codegen.IEmitter;
+import org.apache.flex.compiler.definitions.IPackageDefinition;
+import org.apache.flex.compiler.internal.tree.as.FunctionObjectNode;
+import org.apache.flex.compiler.internal.tree.as.LabeledStatementNode;
+import org.apache.flex.compiler.internal.tree.as.NamespaceAccessExpressionNode;
+import org.apache.flex.compiler.tree.as.IASNode;
+import org.apache.flex.compiler.tree.as.IBinaryOperatorNode;
+import org.apache.flex.compiler.tree.as.IBlockNode;
+import org.apache.flex.compiler.tree.as.ICatchNode;
+import org.apache.flex.compiler.tree.as.IClassNode;
+import org.apache.flex.compiler.tree.as.IContainerNode;
+import org.apache.flex.compiler.tree.as.IDynamicAccessNode;
+import org.apache.flex.compiler.tree.as.IExpressionNode;
+import org.apache.flex.compiler.tree.as.IForLoopNode;
+import org.apache.flex.compiler.tree.as.IFunctionCallNode;
+import org.apache.flex.compiler.tree.as.IFunctionNode;
+import org.apache.flex.compiler.tree.as.IGetterNode;
+import org.apache.flex.compiler.tree.as.IIdentifierNode;
+import org.apache.flex.compiler.tree.as.IIfNode;
+import org.apache.flex.compiler.tree.as.IImportNode;
+import org.apache.flex.compiler.tree.as.IInterfaceNode;
+import org.apache.flex.compiler.tree.as.IIterationFlowNode;
+import org.apache.flex.compiler.tree.as.IKeywordNode;
+import org.apache.flex.compiler.tree.as.ILanguageIdentifierNode;
+import org.apache.flex.compiler.tree.as.ILiteralNode;
+import org.apache.flex.compiler.tree.as.IMemberAccessExpressionNode;
+import org.apache.flex.compiler.tree.as.INamespaceNode;
+import org.apache.flex.compiler.tree.as.INumericLiteralNode;
+import org.apache.flex.compiler.tree.as.IObjectLiteralValuePairNode;
+import org.apache.flex.compiler.tree.as.IParameterNode;
+import org.apache.flex.compiler.tree.as.IReturnNode;
+import org.apache.flex.compiler.tree.as.ISetterNode;
+import org.apache.flex.compiler.tree.as.ISwitchNode;
+import org.apache.flex.compiler.tree.as.ITernaryOperatorNode;
+import org.apache.flex.compiler.tree.as.IThrowNode;
+import org.apache.flex.compiler.tree.as.ITryNode;
+import org.apache.flex.compiler.tree.as.ITypedExpressionNode;
+import org.apache.flex.compiler.tree.as.IUnaryOperatorNode;
+import org.apache.flex.compiler.tree.as.IVariableNode;
+import org.apache.flex.compiler.tree.as.IWhileLoopNode;
+import org.apache.flex.compiler.tree.as.IWithNode;
+import org.apache.flex.compiler.tree.metadata.IMetaTagNode;
+import org.apache.flex.compiler.visitor.IBlockWalker;
+import org.apache.flex.compiler.visitor.IASNodeStrategy;
+
+/**
+ * The {@link IASEmitter} interface allows abstraction between the
+ * {@link IASNodeStrategy} and the current output buffer {@link Writer}.
+ * 
+ * @author Michael Schmalle
+ */
+public interface IASEmitter extends IEmitter
+{
+    IBlockWalker getWalker();
+
+    void setWalker(IBlockWalker asBlockWalker);
+
+    IDocEmitter getDocEmitter();
+
+    void setDocEmitter(IDocEmitter value);
+
+    void emitImport(IImportNode node);
+
+    void emitPackageHeader(IPackageDefinition definition);
+
+    void emitPackageHeaderContents(IPackageDefinition definition);
+
+    void emitPackageContents(IPackageDefinition definition);
+
+    void emitPackageFooter(IPackageDefinition definition);
+
+    /**
+     * Emit a Class.
+     * 
+     * @param node The {@link IClassNode} class.
+     */
+    void emitClass(IClassNode node);
+
+    /**
+     * Emit an Interface.
+     * 
+     * @param node The {@link IInterfaceNode} class.
+     */
+    void emitInterface(IInterfaceNode node);
+
+    /**
+     * Emit a documentation comment for a Class field or constant
+     * {@link IVariableNode}.
+     * 
+     * @param node The {@link IVariableNode} class field member.
+     */
+    void emitFieldDocumentation(IVariableNode node);
+
+    /**
+     * Emit a full Class field member.
+     * 
+     * @param node The {@link IVariableNode} class field member.
+     */
+    void emitField(IVariableNode node);
+
+    /**
+     * Emit a documentation comment for a Class method {@link IFunctionNode}.
+     * 
+     * @param node The {@link IFunctionNode} class method member.
+     */
+    void emitMethodDocumentation(IFunctionNode node);
+
+    /**
+     * Emit a full Class or Interface method member.
+     * 
+     * @param node The {@link IFunctionNode} class method member.
+     */
+    void emitMethod(IFunctionNode node);
+
+    /**
+     * Emit a documentation comment for a Class method {@link IGetterNode}.
+     * 
+     * @param node The {@link IGetterNode} class accessor member.
+     */
+    void emitGetAccessorDocumentation(IGetterNode node);
+
+    /**
+     * Emit a full Class getter member.
+     * 
+     * @param node The {@link IVariableNode} class getter member.
+     */
+    void emitGetAccessor(IGetterNode node);
+
+    /**
+     * Emit a documentation comment for a Class accessor {@link IGetterNode}.
+     * 
+     * @param node The {@link ISetterNode} class accessor member.
+     */
+    void emitSetAccessorDocumentation(ISetterNode node);
+
+    /**
+     * Emit a full Class setter member.
+     * 
+     * @param node The {@link ISetterNode} class setter member.
+     */
+    void emitSetAccessor(ISetterNode node);
+
+    void emitParameter(IParameterNode node);
+
+    /**
+     * Emit a namespace member.
+     * 
+     * @param node The {@link INamespaceNode} class member.
+     */
+    void emitNamespace(INamespaceNode node);
+
+    //--------------------------------------------------------------------------
+    // Statements
+    //--------------------------------------------------------------------------
+
+    /**
+     * Emit a statement found within an {@link IBlockNode}.
+     * 
+     * @param node The {@link IASNode} statement.
+     */
+    void emitStatement(IASNode node);
+
+    /**
+     * Emit a <code>if(){}else if(){}else{}</code> statement.
+     * 
+     * @param node The {@link IIfNode} node.
+     */
+    void emitIf(IIfNode node);
+
+    /**
+     * Emit a <code>for each</code> statement.
+     * 
+     * @param node The {@link IForLoopNode} node.
+     */
+    void emitForEachLoop(IForLoopNode node);
+
+    /**
+     * Emit a <code>for</code> statement.
+     * 
+     * @param node The {@link IForLoopNode} node.
+     */
+    void emitForLoop(IForLoopNode node);
+
+    /**
+     * Emit a <code>switch(){}</code> statement.
+     * 
+     * @param node The {@link ISwitchNode} node.
+     */
+    void emitSwitch(ISwitchNode node);
+
+    /**
+     * Emit a <code>while(){}</code> statement.
+     * 
+     * @param node The {@link IWhileLoopNode} node.
+     */
+    void emitWhileLoop(IWhileLoopNode node);
+
+    /**
+     * Emit a <code>do{}while()</code> statement.
+     * 
+     * @param node The {@link IWhileLoopNode} node.
+     */
+    void emitDoLoop(IWhileLoopNode node);
+
+    /**
+     * Emit a <code>with(){}</code> statement.
+     * 
+     * @param node The {@link IWithNode} node.
+     */
+    void emitWith(IWithNode node);
+
+    /**
+     * Emit a <code>throw</code> statement.
+     * 
+     * @param node The {@link IThrowNode} node.
+     */
+    void emitThrow(IThrowNode node);
+
+    /**
+     * Emit a <code>try{}</code> statement.
+     * 
+     * @param node The {@link ITryNode} node.
+     */
+    void emitTry(ITryNode node);
+
+    /**
+     * Emit a <code>catch(){}</code> statement.
+     * 
+     * @param node The {@link ICatchNode} node.
+     */
+    void emitCatch(ICatchNode node);
+
+    /**
+     * Emit a <code>foo:{}</code> statement.
+     * 
+     * @param node The {@link LabeledStatementNode} node.
+     */
+    void emitLabelStatement(LabeledStatementNode node);
+
+    void emitReturn(IReturnNode node);
+
+    //--------------------------------------------------------------------------
+    // Expressions
+    //--------------------------------------------------------------------------
+
+    /**
+     * Emit a variable declaration found in expression statements within scoped
+     * blocks.
+     * 
+     * @param node The {@link IVariableNode} or chain of variable nodes.
+     */
+    void emitVarDeclaration(IVariableNode node);
+
+    // TODO (mschmalle) we need IFunctionObjectNode API for FunctionObjectNode
+    /**
+     * Emit an anonymous {@link FunctionObjectNode}.
+     * 
+     * @param node The anonymous {@link FunctionObjectNode}.
+     */
+    void emitFunctionObject(IExpressionNode node);
+
+    /**
+     * Emit a header at the start of a function block.
+     * 
+     * @param node The {@link IFunctionNode} node.
+     */
+    void emitFunctionBlockHeader(IFunctionNode node);
+
+    /**
+     * Emit a function call like <code>new Foo()</code> or <code>foo(42)</code>.
+     * 
+     * @param node The {@link IFunctionCallNode} node.
+     */
+    void emitFunctionCall(IFunctionCallNode node);
+
+    void emitIterationFlow(IIterationFlowNode node);
+
+    void emitNamespaceAccessExpression(NamespaceAccessExpressionNode node);
+
+    void emitMemberAccessExpression(IMemberAccessExpressionNode node);
+
+    void emitDynamicAccess(IDynamicAccessNode node);
+
+    void emitTypedExpression(ITypedExpressionNode node);
+
+    void emitObjectLiteralValuePair(IObjectLiteralValuePairNode node);
+
+    void emitIdentifier(IIdentifierNode node);
+
+    void emitLiteral(ILiteralNode node);
+
+    void emitLiteralContainer(IContainerNode node);
+
+    void emitNumericLiteral(INumericLiteralNode node);
+
+    //--------------------------------------------------------------------------
+    // Operators
+    //--------------------------------------------------------------------------
+
+    void emitUnaryOperator(IUnaryOperatorNode node);
+
+    void emitAsOperator(IBinaryOperatorNode node);
+
+    void emitIsOperator(IBinaryOperatorNode node);
+
+    /**
+     * Emit an operator statement.
+     * 
+     * @param node The {@link IBinaryOperatorNode} or chain of variable nodes.
+     */
+    void emitBinaryOperator(IBinaryOperatorNode node);
+
+    void emitTernaryOperator(ITernaryOperatorNode node);
+
+    //--------------------------------------------------------------------------
+    // Node
+    //--------------------------------------------------------------------------
+
+    void emitKeyword(IKeywordNode node);
+
+    void emitLanguageIdentifier(ILanguageIdentifierNode node);
+
+    void emitMetaTag(IMetaTagNode node);
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASWriter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASWriter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASWriter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASWriter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,51 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.as;
+
+import java.io.Closeable;
+import java.io.File;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.OutputStream;
+
+/**
+ * An ActionScript writer that outputs cross compiled string data to the output
+ * stream.
+ * 
+ * @author Michael Schmalle
+ */
+public interface IASWriter extends Closeable
+{
+    /**
+     * Start writing to output stream.
+     * 
+     * @param out output stream
+     */
+    void writeTo(OutputStream out);
+
+    /**
+     * Start writing to a file.
+     * 
+     * @param out The output {@link File}.
+     * @return The number of bytes written.
+     */
+    int writeTo(File out) throws FileNotFoundException, IOException;
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/as/IASWriter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSDocEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSDocEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSDocEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSDocEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,33 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.js;
+
+import org.apache.flex.compiler.codegen.IDocEmitter;
+
+/**
+ * The {@link IJSDocEmitter} interface allows the abstraction of JavaScript
+ * document comments to be emitted per tag.
+ * 
+ * @author Michael Schmalle
+ */
+public interface IJSDocEmitter extends IDocEmitter
+{
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSDocEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,36 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.js;
+
+import java.io.Writer;
+
+import org.apache.flex.compiler.codegen.as.IASEmitter;
+import org.apache.flex.compiler.visitor.IASNodeStrategy;
+
+/**
+ * The {@link IJSEmitter} interface allows abstraction between the
+ * {@link IASNodeStrategy} and the current output buffer {@link Writer}.
+ * 
+ * @author Michael Schmalle
+ */
+public interface IJSEmitter extends IASEmitter
+{
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSPublisher.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSPublisher.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSPublisher.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSPublisher.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,38 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.js;
+
+import java.io.File;
+import java.io.IOException;
+
+/**
+ * The {@link IJSPublisher} interface allows the abstraction of project output
+ * generation.
+ * 
+ * @author Erik de Bruin
+ */
+public interface IJSPublisher
+{
+
+    File getOutputFolder();
+
+    void publish() throws IOException;
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSPublisher.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSWriter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSWriter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSWriter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSWriter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,33 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.js;
+
+import org.apache.flex.compiler.codegen.as.IASWriter;
+
+/**
+ * A JavaScript writer that outputs cross compiled string data to the output
+ * stream.
+ * 
+ * @author Michael Schmalle
+ */
+public interface IJSWriter extends IASWriter
+{
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/IJSWriter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDDocEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDDocEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDDocEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDDocEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,40 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.js.amd;
+
+import org.apache.flex.compiler.codegen.js.IJSDocEmitter;
+
+/**
+ * The {@link IJSAMDDocEmitter} interface allows the abstraction of JavaScript
+ * document comments to be emitted per tag.
+ * <p>
+ * The purpose of the API is to clamp emitted output to JavaScript doc tags. The
+ * output can be multiline but is specific to one tag. This allows a full
+ * comment to be created without worrying about how to assemble the tags.
+ * <p>
+ * TODO (mschmalle) Might make a comment API and tag API so comments are not
+ * dependent on tag creation IE IJSDocEmitter and IJSDocTagEmitter
+ * 
+ * @author Michael Schmalle
+ */
+public interface IJSAMDDocEmitter extends IJSDocEmitter
+{
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDDocEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,33 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.js.amd;
+
+import org.apache.flex.compiler.codegen.js.IJSEmitter;
+
+/**
+ * The {@link IJSAMDEmitter} interface allows abstraction between the base
+ * JavaScript and the AMD specific IJSAMDEmitter.
+ * 
+ * @author Michael Schmalle
+ */
+public interface IJSAMDEmitter extends IJSEmitter
+{
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/amd/IJSAMDEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogDocEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogDocEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogDocEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogDocEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,133 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.js.goog;
+
+import org.apache.flex.compiler.codegen.js.IJSDocEmitter;
+import org.apache.flex.compiler.definitions.IClassDefinition;
+import org.apache.flex.compiler.definitions.IDefinition;
+import org.apache.flex.compiler.definitions.ITypeDefinition;
+import org.apache.flex.compiler.projects.ICompilerProject;
+import org.apache.flex.compiler.tree.as.IASNode;
+import org.apache.flex.compiler.tree.as.IFunctionNode;
+import org.apache.flex.compiler.tree.as.IInterfaceNode;
+import org.apache.flex.compiler.tree.as.IParameterNode;
+import org.apache.flex.compiler.tree.as.IVariableNode;
+
+/**
+ * The {@link IJSGoogDocEmitter} interface allows the abstraction of JavaScript
+ * document comments to be emitted per tag.
+ * <p>
+ * The purpose of the API is to clamp emitted output to JavaScript doc tags. The
+ * output can be multiline but is specific to one tag. This allows a full
+ * comment to be created without worrying about how to assemble the tags.
+ * <p>
+ * The current tags were found at
+ * https://developers.google.com/closure/compiler/docs/js-for-compiler#types
+ * <p>
+ * TODO (mschmalle) Might make a comment API and tag API so comments are not
+ * dependent on tag creation IE IJSDocEmitter and IJSDocTagEmitter
+ * 
+ * @author Michael Schmalle
+ */
+public interface IJSGoogDocEmitter extends IJSDocEmitter
+{
+
+    void emitInterfaceDoc(IInterfaceNode node);
+
+    void emitFieldDoc(IVariableNode node, IDefinition def);
+
+    void emitMethodDoc(IFunctionNode node, ICompilerProject project);
+
+    void emitVarDoc(IVariableNode node, IDefinition def);
+
+    /*
+     * https://developers.google.com/closure/compiler/docs/js-for-compiler#types
+     *- @const - Marks a variable as read-only. The compiler can inline @const variables
+     *
+     *- @define - Indicates a constant that can be overridden by the compiler at compile-time.
+     *
+     * @deprecated - Warns against using the marked function, method, or property should not be used.
+     * 
+     *- @enum - Specifies the type of an enum. An enum is an object whose properties constitute a 
+     *        set of related constants. The @enum tag must be followed by a type expression. 
+     *        
+     * @expose - Declares an exposed property. Exposed properties will not be removed, or renamed, 
+     *         or collapsed, or optimized in any way by the compiler.
+     *         
+     *- @extends - Marks a class or interface as inheriting from another class. A class marked 
+     *           with @extends must also be marked with either @constructor or @interface. 
+     *           
+     *- @implements - Used with @constructor to indicate that a class implements an interface. 
+     *
+     *- @inheritDoc - tag implies the @override tag.  has exactly the same documentation.
+     *
+     * @interface - Marks a function as an interface.
+     * 
+     * @lends
+     * 
+     * @license|@preserve - Tells the compiler to insert the associated comment before the compiled
+     *                      code for the marked file.
+     *                      
+     * @nosideeffects - Indicates that a call to the declared function has no side effects
+     * 
+     *- @override - Indicates that a method or property of a subclass intentionally hides a method or 
+     *              property of the superclass.
+     *              
+     * @param - Used with method, function and constructor definitions to specify the types of function 
+     *          arguments. 
+     *          
+     * @private - Marks a member as private. Only code in the same file can access global variables and 
+     *            functions marked @private. Constructors marked @private can only be instantiated by code 
+     *            in the same file and by their static and instance members. 
+     *            
+     * @protected - Indicates that a member or property is protected.
+     * 
+     * @return - Specifies the return types of method and function definitions. The @return tag must be 
+     *           followed by a type expression. 
+     *           
+     * @this - Specifies the type of the object to which the keyword this refers within a function. 
+     *         The @this tag must be followed by a type expression. 
+     *         
+     * @type - Identifies the type of a variable, property, or expression. The @type tag must be 
+     *         followed by a type expression. 
+     *         
+     * @typedef - Declares an alias for a more complex type. 
+     */
+
+    void emitConst(IVariableNode node);
+
+    void emitExtends(IClassDefinition superDefinition, String packageName);
+
+    void emitImplements(ITypeDefinition definition, String packageName);
+
+    void emitOverride(IFunctionNode node);
+
+    void emitParam(IParameterNode node, String packageName);
+
+    void emitPrivate(IASNode node);
+
+    void emitProtected(IASNode node);
+
+    void emitReturn(IFunctionNode node, String packageName);
+
+    void emitThis(ITypeDefinition node, String packageName);
+
+    void emitType(IASNode node, String packageName);
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogDocEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,33 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.js.goog;
+
+import org.apache.flex.compiler.codegen.js.IJSEmitter;
+
+/**
+ * The {@link IJSGoogEmitter} interface allows abstraction between the base
+ * JavaScript and the 'goog' specific IJSGoogEmitter.
+ * 
+ * @author Michael Schmalle
+ */
+public interface IJSGoogEmitter extends IJSEmitter
+{
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/js/goog/IJSGoogEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/IMXMLEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/IMXMLEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/IMXMLEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/IMXMLEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,101 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.mxml;
+
+import java.io.Writer;
+
+import org.apache.flex.compiler.codegen.IEmitter;
+import org.apache.flex.compiler.tree.mxml.IMXMLArrayNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLBooleanNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLClassDefinitionNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLDocumentNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLEventSpecifierNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLInstanceNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLIntNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLLiteralNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLNumberNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLPropertySpecifierNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLScriptNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLStringNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLStyleSpecifierNode;
+import org.apache.flex.compiler.tree.mxml.IMXMLUintNode;
+import org.apache.flex.compiler.visitor.IBlockWalker;
+import org.apache.flex.compiler.visitor.IASNodeStrategy;
+
+/**
+ * The {@link IMXMLEmitter} interface allows abstraction between the
+ * {@link IASNodeStrategy} and the current output buffer {@link Writer}.
+ * 
+ * @author Michael Schmalle
+ * @author Erik de Bruin
+ */
+public interface IMXMLEmitter extends IEmitter
+{
+
+    IBlockWalker getMXMLWalker();
+
+    void setMXMLWalker(IBlockWalker mxmlBlockWalker);
+
+    //--------------------------------------------------------------------------
+
+    void emitDocumentHeader(IMXMLDocumentNode node);
+
+    void emitDocumentFooter(IMXMLDocumentNode node);
+
+    //--------------------------------------------------------------------------
+
+    void emitClass(IMXMLClassDefinitionNode node);
+
+    //--------------------------------------------------------------------------
+
+    void emitEventSpecifier(IMXMLEventSpecifierNode node);
+
+    void emitInstance(IMXMLInstanceNode node);
+
+    void emitPropertySpecifier(IMXMLPropertySpecifierNode node);
+
+    void emitScript(IMXMLScriptNode node);
+
+    void emitStyleSpecifier(IMXMLStyleSpecifierNode node);
+
+    //--------------------------------------------------------------------------
+
+    void emitArray(IMXMLArrayNode node);
+
+    void emitBoolean(IMXMLBooleanNode node);
+
+    void emitInt(IMXMLIntNode node);
+
+    void emitNumber(IMXMLNumberNode node);
+
+    void emitString(IMXMLStringNode node);
+
+    void emitUint(IMXMLUintNode node);
+
+    //--------------------------------------------------------------------------
+
+    void emitLiteral(IMXMLLiteralNode node);
+
+    //--------------------------------------------------------------------------
+
+    void emitPropertySpecifiers(IMXMLPropertySpecifierNode[] nodes,
+            boolean emitAttributes);
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/IMXMLEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/flexjs/IMXMLFlexJSEmitter.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/flexjs/IMXMLFlexJSEmitter.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/flexjs/IMXMLFlexJSEmitter.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/flexjs/IMXMLFlexJSEmitter.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,36 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.codegen.mxml.flexjs;
+
+import java.io.Writer;
+
+import org.apache.flex.compiler.codegen.mxml.IMXMLEmitter;
+import org.apache.flex.compiler.visitor.IASNodeStrategy;
+
+/**
+ * The {@link IMXMLFlexJSEmitter} interface allows abstraction between the
+ * {@link IASNodeStrategy} and the current output buffer {@link Writer}.
+ * 
+ * @author Erik de Bruin
+ */
+public interface IMXMLFlexJSEmitter extends IMXMLEmitter
+{
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/codegen/mxml/flexjs/IMXMLFlexJSEmitter.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/driver/IApplication.java
URL: http://svn.apache.org/viewvc/flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/driver/IApplication.java?rev=1452955&view=auto
==============================================================================
--- flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/driver/IApplication.java (added)
+++ flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/driver/IApplication.java Tue Mar  5 19:22:05 2013
@@ -0,0 +1,31 @@
+/*
+ *
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ */
+
+package org.apache.flex.compiler.driver;
+
+/**
+ * The ActionScript model interface used when implementing build targets that
+ * create javascript applications cross compiled from actionscript.
+ * 
+ * @author Michael Schmalle
+ */
+public interface IApplication
+{
+
+}

Propchange: flex/falcon/trunk/compiler.jx/src/org/apache/flex/compiler/driver/IApplication.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message