Examples of CayenneMapEntry


Examples of org.apache.cayenne.util.CayenneMapEntry

        }

        StringBuffer buffer = new StringBuffer();

        // attribute or relationships
        CayenneMapEntry first = (CayenneMapEntry) path[1];
        buffer.append(first.getName());

        for (int i = 2; i < path.length; i++) {
            CayenneMapEntry pathEntry = (CayenneMapEntry) path[i];
            buffer.append(".").append(pathEntry.getName());
        }

        return buffer.toString();
    }
View Full Code Here

Examples of org.apache.cayenne.util.CayenneMapEntry

        superEntityCombo.addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent e) {
                // Change super-entity
                CayenneMapEntry superEntity = (CayenneMapEntry) superEntityCombo
                        .getSelectedItem();
                String name = (superEntity == null || superEntity == noInheritance)
                        ? null
                        : superEntity.getName();

                ObjEntity entity = mediator.getCurrentObjEntity();

                if (!Util.nullSafeEquals(name, entity.getSuperEntityName())) {
                    List<ObjAttribute> duplicateAttributes = null;
View Full Code Here

Examples of org.apache.cayenne.util.CayenneMapEntry

        private void appendPath(LinkedList<String> finalPath, CayenneMapEntry pathComponent) {
            finalPath.addLast(pathComponent.getName());
        }

        private void appendPath(LinkedList<String> finalPath, PathComponent<Attribute, Relationship> pathComponent) {
            CayenneMapEntry mapEntry = pathComponent.getAttribute() != null ? pathComponent.getAttribute()
                    : pathComponent.getRelationship();
            String name = mapEntry.getName();
            if (pathComponent.getJoinType() == JoinType.LEFT_OUTER) {
                name += OUTER_JOIN_INDICATOR;
            }

            finalPath.addLast(name);
View Full Code Here

Examples of org.apache.cayenne.util.CayenneMapEntry

    /**
     * Helper method to evaluate path expression with Cayenne Entity.
     */
    protected CayenneMapEntry evaluateEntityNode(Entity entity) {
        Iterator<CayenneMapEntry> path = entity.resolvePathComponents(this);
        CayenneMapEntry next = null;
        while (path.hasNext()) {
            next = path.next();
        }

        return next;
View Full Code Here

Examples of org.apache.cayenne.util.CayenneMapEntry

                                + objAttribute.getName())) {
                    // joins for attribute are generated if it is flattened and appears in original statement
                    Iterator<CayenneMapEntry> dbPathIterator = objAttribute
                            .getDbPathIterator();
                    while (dbPathIterator.hasNext()) {
                        CayenneMapEntry next = dbPathIterator.next();
                        if (next instanceof DbRelationship) {
                            DbRelationship rel = (DbRelationship) next;
                            context.append(" LEFT OUTER JOIN ");
                            String targetEntityName = quoter.quotedFullyQualifiedName((DbEntity) rel.getTargetEntity());
                            String subqueryTargetAlias = context.getTableAlias(id.getEntityId(), targetEntityName);
View Full Code Here

Examples of org.apache.cayenne.util.CayenneMapEntry

        superEntityCombo.addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent e) {
                // Change super-entity
                CayenneMapEntry superEntity = (CayenneMapEntry) superEntityCombo
                        .getSelectedItem();
                String name = (superEntity == noInheritance) ? null : superEntity
                        .getName();

                ObjEntity entity = mediator.getCurrentObjEntity();

                if (!Util.nullSafeEquals(name, entity.getSuperEntityName())) {
View Full Code Here

Examples of org.apache.cayenne.util.CayenneMapEntry

            // the sequence is important - call super with converted value,
            // then set an icon, and then return "this"
            ImageIcon icon = CellRenderers.iconForObject(value);

            if (value instanceof CayenneMapEntry) {
                CayenneMapEntry mapObject = (CayenneMapEntry) value;
                String label = mapObject.getName();

                if (mapObject instanceof Entity) {
                    Entity entity = (Entity) mapObject;

                    // for different namespace display its name
View Full Code Here

Examples of org.apache.cayenne.util.CayenneMapEntry

        }

        StringBuffer buffer = new StringBuffer();

        // attribute or relationships
        CayenneMapEntry first = (CayenneMapEntry) path[1];
        buffer.append(first.getName());

        for (int i = 2; i < path.length; i++) {
            CayenneMapEntry pathEntry = (CayenneMapEntry) path[i];
            buffer.append(".").append(pathEntry.getName());
        }

        return buffer.toString();
    }
View Full Code Here

Examples of org.apache.cayenne.util.CayenneMapEntry

                boolean hasFocus,
                int row,
                int column) {

            if (value instanceof CayenneMapEntry) {
                CayenneMapEntry mapObject = (CayenneMapEntry) value;
                String label = mapObject.getName();

                if (mapObject instanceof Entity) {
                    Entity entity = (Entity) mapObject;

                    // for different namespace display its name
View Full Code Here

Examples of org.apache.cayenne.util.CayenneMapEntry

                boolean hasFocus,
                int row,
                int column) {

            if (value instanceof CayenneMapEntry) {
                CayenneMapEntry mapObject = (CayenneMapEntry) value;
                String label = mapObject.getName();

                if (mapObject instanceof Entity) {
                    Entity entity = (Entity) mapObject;

                    // for different namespace display its name
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.