Package org.andromda.metafacades.uml

Examples of org.andromda.metafacades.uml.ClassifierFacade


        {
            returnTypeName = "javax.jms.Message";
        }
        else
        {
            final ClassifierFacade returnType = this.getReturnType();
            returnTypeName = returnType != null ? returnType.getFullyQualifiedName() : null;
        }
        return returnTypeName;
    }
View Full Code Here


    protected java.lang.String handleGetDaoReferenceName()
    {
        String referenceName = null;

        final ClassifierFacade type = this.getType();
        if (type instanceof SpringManageableEntity)
        {
            final SpringManageableEntity entity = (SpringManageableEntity)type;
            referenceName = entity.getBeanName(false);
        }
View Full Code Here

        {
            return Collections.EMPTY_LIST;
        }
        Collection result = new ArrayList();
        result.addAll(getEntityRelations());
        ClassifierFacade classifier = (ClassifierFacade)this.getGeneralization();
        while (classifier != null && classifier instanceof EJBEntityFacade && classifier.isAbstract())
        {
            EJBEntityFacade entity = (EJBEntityFacade)classifier;
            result.addAll(entity.getEntityRelations());
            classifier = (ClassifierFacade)classifier.getGeneralization();
        }
        return result;
    }
View Full Code Here

    {
        Collection result = new ArrayList();
        for (final Iterator iterator = this.getAssociationEnds().iterator(); iterator.hasNext();)
        {
            EJBAssociationEndFacade associationEnd = (EJBAssociationEndFacade)iterator.next();
            ClassifierFacade target = associationEnd.getOtherEnd().getType();
            if (target instanceof EJBEntityFacade && associationEnd.getOtherEnd().isNavigable())
            {
                // Check the integrity constraint
                Object value =
                    associationEnd.getOtherEnd().getAssociation().findTaggedValue(EJBProfile.TAGGEDVALUE_GENERATE_CMR);
                String generateCmr = value == null ? null : value.toString();
                if (target.isAbstract() && !"false".equalsIgnoreCase(generateCmr))
                {
                    throw new IllegalStateException("Relation '" + associationEnd.getAssociation().getName() +
                        "' has the abstract target '" + target.getName() +
                        "'. Abstract targets are not allowed in EJB.");
                }
                result.add(associationEnd);
            }
        }
View Full Code Here

        {
            final Collection associationEnds = this.getAssociationEnds();
            for (final Iterator iterator = associationEnds.iterator(); iterator.hasNext() && !present;)
            {
                final AssociationEndFacade associationEnd = (AssociationEndFacade)iterator.next();
                final ClassifierFacade classifier = associationEnd.getOtherEnd().getType();
                present = classifier instanceof FrontEndUseCase;
            }

            // - a generalized role is still a role, and therefore is associated with the FrontEndUseCase
            if (!present)
View Full Code Here

    {
        name = StringUtils.trimToEmpty(name);
        Object value = this.findTaggedValue(name);
        if (follow)
        {
            ClassifierFacade type = this.getReturnType();
            while (value == null && type != null)
            {
                value = type.findTaggedValue(name);
                type = (ClassifierFacade)type.getGeneralization();
            }
        }
        return value;
    }
View Full Code Here

    {
        OperationFacade overriddenOperation = null;

        final String signature = this.getSignature(false);

        ClassifierFacade ancestor = this.getOwner().getSuperClass();
        while (overriddenOperation == null && ancestor != null)
        {
            for (Iterator operationIterator = ancestor.getOperations().iterator();
                 overriddenOperation == null && operationIterator.hasNext();)
            {
                final OperationFacade ancestorOperation = (OperationFacade)operationIterator.next();
                if (signature.equals(ancestorOperation.getSignature(false)))
                {
                    overriddenOperation = ancestorOperation;
                }
            }

            ancestor = ancestor.getSuperClass();
        }

        return overriddenOperation;
    }
View Full Code Here

    {
        name = StringUtils.trimToEmpty(name);
        Object value = findTaggedValue(name);
        if (follow)
        {
            ClassifierFacade type = this.getReturnType();
            while (value == null && type != null)
            {
                value = type.findTaggedValue(name);
                type = (ClassifierFacade)type.getGeneralization();
            }
        }
        return value;
    }
View Full Code Here

    {
        OperationFacade overriddenOperation = null;

        final String signature = this.getSignature(false);

        ClassifierFacade ancestor = this.getOwner().getSuperClass();
        while (overriddenOperation == null && ancestor != null)
        {
            for (Iterator operationIterator = ancestor.getOperations().iterator();
                 overriddenOperation == null && operationIterator.hasNext();)
            {
                final OperationFacade ancestorOperation = (OperationFacade)operationIterator.next();
                if (signature.equals(ancestorOperation.getSignature(false)))
                {
                    overriddenOperation = ancestorOperation;
                }
            }

            ancestor = ancestor.getSuperClass();
        }

        return overriddenOperation;
    }
View Full Code Here

    protected java.lang.String handleGetSqlType()
    {
        String value = null;
        if (this.getSqlMappings() != null)
        {
            final ClassifierFacade type = this.getType();
            if (type != null)
            {
                String typeName = type.getFullyQualifiedName(true);
                // if its an enumeration, the sql type is the literal type
                if (type.isEnumeration())
                {
                    ClassifierFacade literalType = ((EnumerationFacade)type).getLiteralType();
                    if (literalType != null)
                    {
                        typeName = literalType.getFullyQualifiedName(true);
                    }
                }
                value = this.getSqlMappings().getTo(typeName);
                final String columnLength = this.getColumnLength();
                if (StringUtils.isNotEmpty(columnLength))
View Full Code Here

TOP

Related Classes of org.andromda.metafacades.uml.ClassifierFacade

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.