Examples of DbJoin


Examples of org.apache.cayenne.map.DbJoin

        String targetAlias = node.getTargetTableAlias();

        List<DbJoin> joins = relationship.getJoins();
        int len = joins.size();
        for (int i = 0; i < len; i++) {
            DbJoin join = joins.get(i);

            if (i > 0) {
                out.append(" AND ");
            }

            out.append(srcAlias).append('.').append(join.getSourceName());

            switch (node.getJoinType()) {
                case INNER:
                    out.append(" = ");
                    break;
                case LEFT_OUTER:
                    out.append(" * ");
                    break;
                default:
                    throw new IllegalArgumentException("Unsupported join type: "
                            + node.getJoinType());
            }

            out.append(targetAlias).append('.').append(join.getTargetName());

        }

        for (JoinTreeNode child : node.getChildren()) {
            out.append(" AND ");
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.