Package org.apache.cayenne.map

Examples of org.apache.cayenne.map.EntityInheritanceTree


        // append Entity qualifiers, taking inheritance into account
        ObjEntity entity = getObjEntity();

        if (entity != null) {
            EntityInheritanceTree tree = queryAssembler
                    .getEntityResolver()
                    .lookupInheritanceTree(entity);
            Expression entityQualifier = (tree != null) ? tree
                    .qualifierForEntityAndSubclasses() : entity.getDeclaredQualifier();
            if (entityQualifier != null) {
                qualifier = (qualifier != null)
                        ? qualifier.andExp(entityQualifier)
                        : entityQualifier;
View Full Code Here


            else {
                createToOneProperty(descriptor, objRelationship);
            }
        }

        EntityInheritanceTree inheritanceTree = descriptorMap
                .getResolver()
                .lookupInheritanceTree(descriptor.getEntity().getName());
        descriptor.setEntityInheritanceTree(inheritanceTree);
        indexSubclassDescriptors(descriptor, inheritanceTree);
        indexQualifiers(descriptor, inheritanceTree);
View Full Code Here

        this.context = context;
        this.cache = context.getObjectStore().getDataRowCache();
        this.refreshObjects = refresh;
        this.descriptor = descriptor;

        EntityInheritanceTree inheritanceTree = context
                .getEntityResolver()
                .lookupInheritanceTree(descriptor.getEntity());
        this.descriptorResolutionStrategy = inheritanceTree != null
                ? new InheritanceStrategy()
                : new NoInheritanceStrategy();
View Full Code Here

            else {
                createToOneProperty(descriptor, objRelationship);
            }
        }

        EntityInheritanceTree inheritanceTree = descriptorMap
                .getResolver()
                .lookupInheritanceTree(descriptor.getEntity());
        indexSubclassDescriptors(descriptor, inheritanceTree);
        indexQualifiers(descriptor, inheritanceTree);
View Full Code Here

            else {
                createToOneProperty(descriptor, objRelationship);
            }
        }

        EntityInheritanceTree inheritanceTree = descriptorMap
                .getResolver()
                .lookupInheritanceTree(descriptor.getEntity().getName());
        descriptor.setEntityInheritanceTree(inheritanceTree);
        indexSubclassDescriptors(descriptor, inheritanceTree);
        indexQualifiers(descriptor, inheritanceTree);
View Full Code Here

            else {
                createToOneProperty(descriptor, objRelationship);
            }
        }

        EntityInheritanceTree inheritanceTree = descriptorMap
                .getResolver()
                .lookupInheritanceTree(descriptor.getEntity());
        descriptor.setEntityInheritanceTree(inheritanceTree);
        indexSubclassDescriptors(descriptor, inheritanceTree);
        indexQualifiers(descriptor, inheritanceTree);
View Full Code Here

        this.columnMap = new HashMap<String, Integer>();
    }

    SelectDescriptor<Object> buildSegment() {

        EntityInheritanceTree inheritanceTree = classDescriptor
                .getEntityInheritanceTree();

        // non-leaf entity
        if (inheritanceTree != null) {
            return buildNonLeafSegment(inheritanceTree);
View Full Code Here

        // since JDBC row reader won't inject JOINED entity name, we have to
        // detect it here...

        ObjEntity entity = null;
        ClassDescriptor descriptor = resolver.getDescriptor();
        EntityInheritanceTree entityInheritanceTree = descriptor
                .getEntityInheritanceTree();

        if (entityInheritanceTree != null) {
            entity = entityInheritanceTree.entityMatchingRow(row);
        }

        if (entity == null) {
            entity = descriptor.getEntity();
        }
View Full Code Here

        this.context = context;
        this.cache = context.getObjectStore().getDataRowCache();
        this.refreshObjects = refresh;
        this.descriptor = descriptor;

        EntityInheritanceTree inheritanceTree = context
                .getEntityResolver()
                .lookupInheritanceTree(descriptor.getEntity());
        this.descriptorResolutionStrategy = inheritanceTree != null
                ? new InheritanceStrategy()
                : new NoInheritanceStrategy();
View Full Code Here

        // append Entity qualifiers, taking inheritance into account
        ObjEntity entity = getObjEntity();

        if (entity != null) {
            EntityInheritanceTree tree = queryAssembler
                    .getEntityResolver()
                    .lookupInheritanceTree(entity);
            Expression entityQualifier = (tree != null) ? tree
                    .qualifierForEntityAndSubclasses() : entity.getDeclaredQualifier();
            if (entityQualifier != null) {
                qualifier = (qualifier != null)
                        ? qualifier.andExp(entityQualifier)
                        : entityQualifier;
View Full Code Here

TOP

Related Classes of org.apache.cayenne.map.EntityInheritanceTree

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.