0 Replies Latest reply on Mar 10, 2009 11:29 AM by (Paul_Reilly)

    [svn:fx-trunk] 5222: Initial MXML Vector support.

      Revision: 5222
      Author: preilly@adobe.com
      Date: 2009-03-10 12:29:18 -0700 (Tue, 10 Mar 2009)

      Log Message:
      -----------
      Initial MXML Vector support.

      tests Passed: checkintests

      Needs QA: YES

      Needs DOC: NO

      Bug fixes: SDK-19214

      API Change: NO

      Reviewer: Pete F.

      Code-level description of changes:

      frameworks/projects/framework/manifest.xml
      frameworks/mxml-manifest.xml

      Added Vector component.

      modules/compiler/src/java/flex2/compiler_en.properties

      Moved mxml.builder.AbstractBuilder.NullArrayElementStoreType to
      mxml.reflect.TypeTable.ElementTypeNotFound.

      Added mxml.InterfaceCompiler.VectorTypeRequired, mxml.builder.VectorBuilder.WrongElementType

      modules/compiler/src/java/flex2/compiler/abc/Method.java

      Added getReturnElementTypeName() and getParameterElementTypeNames().

      modules/compiler/src/java/flex2/compiler/abc/Variable.java

      Added getElementTypeName().

      modules/compiler/src/java/flex2/compiler/as3/reflect/Method.java

      Added parameterElementTypeNames and returnElementTypeName
      variables, modified constructor to initialize them, and added
      getters for them.

      Removed one line functionName() and refactored functionTypeName()
      into extractFunctionTypeInfo().

      modules/compiler/src/java/flex2/compiler/as3/reflect/Variable.java

      Added typeName variable, modified constructor to initialize it,
      and added getter for it.

      Removed variableName() and refactored variableTypeName() into
      extractVariableTypeInfo().

      modules/compiler/src/java/flex2/compiler/as3/reflect/TypeTable.java

      Modified createParameters() to handle the parameter element type names.

      modules/compiler/src/java/flex2/compiler/as3/AbstractSyntaxTreeUtil.java

      Added generateApplyTypeExpr() and modified
      generateTypeExpression() and generateVariableNew() to use it for
      Vector support.

      modules/compiler/src/java/flex2/compiler/SymbolTable.java

      Added VECTOR and added getElementTypeName() to NoType class.

      Modified getClass() to handle Vector.

      modules/compiler/src/java/flex2/compiler/mxml/dom/Analyzer.java
      modules/compiler/src/java/flex2/compiler/mxml/dom/AnalyzerAdapter.java

      Added analyze(VectorNode).

      modules/compiler/src/java/flex2/compiler/mxml/dom/VectorNode.java
      modules/compiler/src/java/flex2/compiler/mxml/reflect/ElementTypeNotFound.java
      modules/compiler/src/java/flex2/compiler/mxml/rep/Vector.java
      modules/compiler/src/java/flex2/compiler/mxml/builder/VectorBuilder.java

      Initial checkin.

      modules/compiler/src/java/flex2/compiler/mxml/dom/SyntaxTreeBuilder.java

      Added parseVector()

      modules/compiler/src/java/flex2/compiler/mxml/dom/MxmlScanner.java

      Modified createNode() to handle ParserConstants.START_VECTOR case.

      modules/compiler/src/java/flex2/compiler/mxml/lang/ValueNodeHandler.java

      Modified isValueNode() and invoke() to handle VectorNode.

      modules/compiler/src/java/flex2/compiler/mxml/lang/StandardDefs.java

      Added CLASS_VECTOR and PROP_TYPE.

      modules/compiler/src/java/flex2/compiler/mxml/lang/NodeTypeResolver.java

      Added vectorNode()

      modules/compiler/src/java/flex2/compiler/mxml/lang/TypeCompatibility.java

      Added OkCoerceToVector constant.

      Modified check() by renaming lvalueArrayElemType to
      lvalueElementType and added handling for vectorType.

      modules/compiler/src/java/flex2/compiler/mxml/reflect/Property.java

      Added getElementType() and removed getArrayElementType(), which
      was folded into getElementType().

      modules/compiler/src/java/flex2/compiler/mxml/reflect/TypeTable.java

      Added vectorType variable.

      Added getElementType() and removed getArrayElementType() from TypeHelper.

      modules/compiler/src/java/flex2/compiler/mxml/analyzer/SyntaxAnalyzer.java

      Added analyze(VectorNode.

      modules/compiler/src/java/flex2/compiler/mxml/rep/Array.java

      Made list and elementType protected, so Vector can subclass Array.

      modules/compiler/src/java/flex2/compiler/mxml/rep/init/ValueInitializer.java

      Modified getDefinitionBody() and generateDefinitionBody() to
      handle Vector.

      modules/compiler/src/java/flex2/compiler/mxml/rep/init/ArrayElementInitializer.java

      Implemented generateAssignExpr(), because it's now used by Vector.

      modules/compiler/src/java/flex2/compiler/mxml/rep/StatesModel.java

      Added try/catch for ElementTypeNotFound.

      modules/compiler/src/java/flex2/compiler/mxml/rep/decl/InitializedPropertyDeclaration.jav a

      Modified getTypeExpr() to handle Vector.

      modules/compiler/src/java/flex2/compiler/mxml/rep/DocumentInfo.java

      Added addVectorVarDecl().

      modules/compiler/src/java/flex2/compiler/mxml/builder/AbstractBuilder.java

      Renamed arrayElementType to elementType.

      Added OkCoerceToVector support.

      modules/compiler/src/java/flex2/compiler/mxml/builder/DocumentBuilder.java
      modules/compiler/src/java/flex2/compiler/mxml/builder/ArrayBuilder.java

      Added vectorNode(VectorNode).

      modules/compiler/src/java/flex2/compiler/mxml/Grammar.jj

      Added parseVector() everywhere we were calling parseArray().

      modules/compiler/src/java/flex2/compiler/mxml/InterfaceCompiler.java

      Added analyze(VectorNode).

      Modified registerVariable() to handle Vector.

      Added VectorTypeRequired compiler error.

      modules/compiler/src/java/flex2/compiler/mxml/MxmlVisitor.java

      Added parseVector().

      modules/compiler/src/java/flex2/compiler/util/Name.java
      modules/compiler/src/java/flex2/compiler/util/MultiName.java

      Added some asserts to catch problems earlier.

      Ticket Links:
      ------------
      http://bugs.adobe.com/jira/browse/SDK-19214

      Modified Paths:
      --------------
      flex/sdk/trunk/frameworks/mxml-manifest.xml
      flex/sdk/trunk/frameworks/projects/framework/manifest.xml
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/SymbolTable.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/abc/Method.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/abc/Variable.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/AbstractSyntaxTreeUtil.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/reflect/Method.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/reflect/NodeMagic.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/reflect/TypeTable.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/reflect/Variable.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/Grammar.jj
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/InterfaceCompiler.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/MxmlVisitor.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/analyzer/SyntaxAnalyzer.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/builder/AbstractBuilder.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/builder/AnonymousObjectGraph Builder.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/builder/ArrayBuilder.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/builder/DocumentBuilder.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/builder/RemoteObjectBuilder. java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/dom/Analyzer.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/dom/AnalyzerAdapter.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/dom/MxmlScanner.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/dom/SyntaxTreeBuilder.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/lang/NodeTypeResolver.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/lang/StandardDefs.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/lang/TypeCompatibility.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/lang/ValueNodeHandler.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/reflect/Property.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/reflect/TypeTable.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/rep/Array.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/rep/DocumentInfo.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/rep/StatesModel.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/rep/decl/InitializedProperty Declaration.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/rep/init/ArrayElementInitial izer.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/rep/init/ValueInitializer.ja va
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/util/MultiName.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/util/Name.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/util/PrefixMapping.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler_en.properties

      Added Paths:
      -----------
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/builder/VectorBuilder.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/dom/VectorNode.java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/reflect/ElementTypeNotFound. java
      flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/mxml/rep/Vector.java