Package org.andromda.translation.ocl.node

Examples of org.andromda.translation.ocl.node.ATypeDeclaration


        public AVariableDeclarationList getList()
        {

            TName initialName = (TName)this.orderedNames.getFirst();

            ATypeDeclaration typeDeclaration = (ATypeDeclaration)namesAndTypes.get(initialName);

            List variableDeclarationListTails = new ArrayList();
            if (!this.orderedNames.isEmpty())
            {
                int orderedNameSize = orderedNames.size();
                for (int ctr = 1; ctr < orderedNameSize; ctr++)
                {
                    ACommaFeatureCallParameterOption name = (ACommaFeatureCallParameterOption)this.orderedNames.get(
                            ctr);

                    ATypeDeclaration typeDecl = (ATypeDeclaration)this.namesAndTypes.get(name);

                    AVariableDeclaration variableDeclaration = new AVariableDeclaration(getName(name.getExpression()),
                            typeDecl);

                    variableDeclarationListTails.add(new AVariableDeclarationListTail(name.getComma(),
View Full Code Here


        OperationDeclaration operationDeclaration = null;

        AOperation op = (AOperation)operation;

        ATypeDeclaration typeDeclaration = (ATypeDeclaration)op.getReturnTypeDeclaration();
        String returnType = null;
        if (typeDeclaration != null)
        {
            returnType = ObjectUtils.toString(typeDeclaration.getType());
        }

        operationDeclaration = new OperationDeclarationImpl(ObjectUtils.toString(op.getName()), returnType, ConcreteSyntaxUtils.getVariableDeclarations(
                operation));
        return operationDeclaration;
View Full Code Here

                                                                PEqualExpression initialValue)
    {
        ExceptionUtils.checkNull("variableDeclaration", variableDeclaration);

        AVariableDeclaration declaration = (AVariableDeclaration)variableDeclaration;
        ATypeDeclaration typeDeclaration = (ATypeDeclaration)declaration.getTypeDeclaration();
        String type = null;
        String name = ObjectUtils.toString(declaration.getName()).trim();
        if (typeDeclaration != null)
        {
            type = ObjectUtils.toString(typeDeclaration.getType());
        }
        return new VariableDeclarationImpl(name, type, ObjectUtils.toString(initialValue).trim());
    }
View Full Code Here

TOP

Related Classes of org.andromda.translation.ocl.node.ATypeDeclaration

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