Examples of JoinTableMetadata


Examples of com.impetus.kundera.metadata.model.JoinTableMetadata

                    }
                }
                // if relation type is many to many and relation via join table.
                else if ((relationType.equals(ForeignKey.MANY_TO_MANY)) && (entityMetadata.isRelationViaJoinTable()))
                {
                    JoinTableMetadata joinTableMetadata = relation.getJoinTableMetadata();
                    String joinTableName = joinTableMetadata != null ? joinTableMetadata.getJoinTableName() : null;
                    String joinColumnName = joinTableMetadata != null ? (String) joinTableMetadata.getJoinColumns()
                            .toArray()[0] : null;
                    String inverseJoinColumnName = joinTableMetadata != null ? (String) joinTableMetadata
                            .getInverseJoinColumns().toArray()[0] : null;
                    if (joinTableName != null)
                    {
                        TableInfo joinTableInfo = new TableInfo(joinTableName, Type.COLUMN_FAMILY.name(), String.class,
                                "key");
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.metadata.tables.JoinTableMetadata

       
        m_mappedBy = (annotation == null) ? "" : (String) MetadataHelper.invokeMethod("mappedBy", annotation);
       
        // Set the join table if one is present.
        if (isAnnotationPresent(JoinTable.class)) {
            m_joinTable = new JoinTableMetadata(getAnnotation(JoinTable.class), accessibleObject);
        }
       
        // Set the order if one is present.
        Annotation orderBy = getAnnotation(OrderBy.class);
        if (orderBy != null) {
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.metadata.tables.JoinTableMetadata

     */
    protected void processJoinTable(ManyToManyMapping mapping) {
        // Check that we loaded a join table otherwise default one.
        if (m_joinTable == null) {
            // TODO: Log a defaulting message.
            m_joinTable = new JoinTableMetadata(null, getAccessibleObject());
        }
       
        // Build the default table name
        String defaultName = getDescriptor().getPrimaryTableName() + "_" + getReferenceDescriptor().getPrimaryTableName();
       
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.metadata.tables.JoinTableMetadata

       
        m_mappedBy = (annotation == null) ? "" : (String) MetadataHelper.invokeMethod("mappedBy", annotation);
       
        // Set the join table if one is present.
        if (isAnnotationPresent(JoinTable.class)) {
            m_joinTable = new JoinTableMetadata(getAnnotation(JoinTable.class), accessibleObject);
        }
       
        // Set the order if one is present.
        Annotation orderBy = getAnnotation(OrderBy.class);
        if (orderBy != null) {
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.metadata.tables.JoinTableMetadata

     */
    protected void processJoinTable(ManyToManyMapping mapping) {
        // Check that we loaded a join table otherwise default one.
        if (m_joinTable == null) {
            // TODO: Log a defaulting message.
            m_joinTable = new JoinTableMetadata(null, getAccessibleObject());
        }
       
        // Build the default table name
        String defaultName = getDescriptor().getPrimaryTableName() + "_" + getReferenceDescriptor().getPrimaryTableName();
       
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.metadata.tables.JoinTableMetadata

        for (Object joinColumn : (Object[]) associationOverride.getAttributeArray("joinColumns")) {
            m_joinColumns.add(new JoinColumnMetadata((MetadataAnnotation)joinColumn, accessor));
        }
       
        // Set the join table.
        m_joinTable = new JoinTableMetadata((MetadataAnnotation) associationOverride.getAttribute("joinTable"), accessor);
    }
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.metadata.tables.JoinTableMetadata

       
        m_mappedBy = (annotation == null) ? "" : (String) MetadataHelper.invokeMethod("mappedBy", annotation);
       
        // Set the join table if one is present.
        if (isAnnotationPresent(JoinTable.class)) {
            m_joinTable = new JoinTableMetadata(getAnnotation(JoinTable.class), accessibleObject);
        }
       
        // Set the order if one is present.
        Annotation orderBy = getAnnotation(OrderBy.class);
        if (orderBy != null) {
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.metadata.tables.JoinTableMetadata

     */
    protected void processJoinTable(ManyToManyMapping mapping) {
        // Check that we loaded a join table otherwise default one.
        if (m_joinTable == null) {
            // TODO: Log a defaulting message.
            m_joinTable = new JoinTableMetadata(null, getAccessibleObject());
        }
       
        // Build the default table name
        String defaultName = getDescriptor().getPrimaryTableName() + "_" + getReferenceDescriptor().getPrimaryTableName();
       
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.metadata.tables.JoinTableMetadata

     * embeddable object as the value or key.
     */
    @Override
    protected void processAssociationOverride(AssociationOverrideMetadata associationOverride, EmbeddableMapping embeddableMapping, MetadataDescriptor owningDescriptor) {
        if (getMapping().isManyToManyMapping()) {
            JoinTableMetadata joinTable = associationOverride.getJoinTable();
       
            // Process any table defaults and log warning messages.
            String defaultName = owningDescriptor.getPrimaryTableName() + "_" + getReferenceDescriptor().getPrimaryTableName();
            processTable(joinTable, defaultName);
       
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.metadata.tables.JoinTableMetadata

            m_joinColumns.add(new JoinColumnMetadata(getAnnotation("org.eclipse.persistence.nosql.annotations.JoinField"), this));
        }
       
        // Set the join table if one is present.
        if (isAnnotationPresent(JPA_JOIN_TABLE)) {
            m_joinTable = new JoinTableMetadata(getAnnotation(JPA_JOIN_TABLE), this);
        }
       
        // Set the private owned if one is present.
        m_privateOwned = isAnnotationPresent(PrivateOwned.class);
       
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.