Package org.apache.flex.abc.visitors

Examples of org.apache.flex.abc.visitors.ITraitVisitor.visitEnd()


                initMethodVisitor.visitEnd();
               
                ITraitVisitor initMethodTraitVisitor =
                    classGen.getCTraitsVisitor().visitMethodTrait(ABCConstants.TRAIT_Method, new Name("init"), 0, initMethodInfo);
                initMethodTraitVisitor.visitStart();
                initMethodTraitVisitor.visitEnd();

                codegenInfoMethod(classGen,
                        flexProject.getCompatibilityVersion(),
                        getMainClassQName(),
                        getPreloaderClassReference(),
View Full Code Here


                initMethodVisitor.visitEnd();
               
                ITraitVisitor initMethodTraitVisitor =
                    classGen.getCTraitsVisitor().visitMethodTrait(ABCConstants.TRAIT_Method, new Name("init"), 0, initMethodInfo);
                initMethodTraitVisitor.visitStart();
                initMethodTraitVisitor.visitEnd();
            }
            classGen.finishScript();
           
            DoABCTag doABC = new DoABCTag();
            try
View Full Code Here

        // add "goto_definition_help" metadata to user defined metadata.
        ITraitVisitor tv = classScope.getGlobalScope().traitsVisitor.visitClassTrait(
            TRAIT_Class, className, 0, cinfo);
        IMetaInfo[] metaTags = ClassDirectiveProcessor.getAllMetaTags(classDefinition);
        classScope.processMetadata(tv, metaTags);
        tv.visitEnd();
       
        // Make any vistEnd method calls
        // that were deferred.
        // callVisitEnds must be called on the same thread
        // that started code generation.  Since we don't generate
View Full Code Here

                }
               
                if ( tv != null )
                {
                    this.currentScope.processMetadata(tv, funcDef.getAllMetaTags());
                    tv.visitEnd();
                }
            }
            else if (!conflictsWithOtherDefinition)
            {
                // Duplicate that is not a "conflict" - must be a global, where dupes are "allowed" as
View Full Code Here

            //  in the traits because that is a semantic error
            //  in this context.
            ITraitVisitor tv = this.currentScope.traitsVisitor.visitSlotTrait(ABCConstants.TRAIT_Const, var_name, ITraitsVisitor.RUNTIME_SLOT, var_type, LexicalScope.noInitializer);
            this.currentScope.declareVariableName(var_name);
            this.currentScope.processMetadata(tv, varDef.getAllMetaTags());
            tv.visitEnd();
        }
        //  Run the BURM to process any initialization instructions.
        processDirective(var);
    }
View Full Code Here

        traitVisitor.visitStart();
        if (isFinal)
            traitVisitor.visitAttribute(Trait.TRAIT_FINAL, true);
        if (isOverride)
            traitVisitor.visitAttribute(Trait.TRAIT_OVERRIDE, true);
        traitVisitor.visitEnd();
    }

    /**
     * Utility method to add a static method to the generated class.
     *
 
View Full Code Here

            boolean needsRest,
            InstructionList body)
    {
        ITraitVisitor traitVisitor = addMethodToTraits(ctraits, methodName, parameterTypes, returnType, defaultParameterValues, needsRest, ABCConstants.TRAIT_Method, body);
        traitVisitor.visitStart();
        traitVisitor.visitEnd();
    }

    /**
     * Utility method to add an instance getter to the generated class.
     *
 
View Full Code Here

     */
    public void addITraitsGetter(Name getterName, Name returnType, InstructionList body)
    {
        ITraitVisitor traitVisitor = addMethodToTraits(itraits, getterName, Collections.<Name>emptyList(), returnType, Collections.<Object>emptyList(), false, ABCConstants.TRAIT_Getter, body);
        traitVisitor.visitStart();
        traitVisitor.visitEnd();
    }
   
    /**
     * Utility method to add a static getter to the generated class.
     *
 
View Full Code Here

     */
    public void addCTraitsGetter(Name getterName, Name returnType, InstructionList body)
    {
        ITraitVisitor traitVisitor = addMethodToTraits(ctraits, getterName, Collections.<Name>emptyList(), returnType, Collections.<Object>emptyList(), false, ABCConstants.TRAIT_Getter, body);
        traitVisitor.visitStart();
        traitVisitor.visitEnd();
    }

    /**
     * Utility method to add a member variable to a class.
     *
 
View Full Code Here

     */
    public void addMemberVariable(Name variableName, Name type)
    {
        ITraitVisitor traitVisitor = itraits.visitSlotTrait(ABCConstants.TRAIT_Var, variableName, ITraitsVisitor.RUNTIME_SLOT, type, LexicalScope.noInitializer);
        traitVisitor.visitStart();
        traitVisitor.visitEnd();
    }

    /**
     * @return protected namespace if it is asked for while creating this helper class
     */
 
View Full Code Here

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