Package org.eclipse.persistence.oxm.mappings

Examples of org.eclipse.persistence.oxm.mappings.XMLCompositeCollectionMapping


        descriptor.addMapping(getConverterMapping());
        descriptor.addMapping(getTypeConverterMapping());
        descriptor.addMapping(getObjectTypeConverterMapping());
        descriptor.addMapping(getStructConverterMapping());

        XMLCompositeCollectionMapping sequenceGeneratorsMapping = new XMLCompositeCollectionMapping();
        sequenceGeneratorsMapping.setAttributeName("m_sequenceGenerators");
        sequenceGeneratorsMapping.setGetMethodName("getSequenceGenerators");
        sequenceGeneratorsMapping.setSetMethodName("setSequenceGenerators");
        sequenceGeneratorsMapping.setReferenceClass(SequenceGeneratorMetadata.class);
        sequenceGeneratorsMapping.setXPath("orm:sequence-generator");
        descriptor.addMapping(sequenceGeneratorsMapping);
       
        XMLCompositeCollectionMapping tableGeneratorsMapping = new XMLCompositeCollectionMapping();
        tableGeneratorsMapping.setAttributeName("m_tableGenerators");
        tableGeneratorsMapping.setGetMethodName("getTableGenerators");
        tableGeneratorsMapping.setSetMethodName("setTableGenerators");
        tableGeneratorsMapping.setReferenceClass(TableGeneratorMetadata.class);
        tableGeneratorsMapping.setXPath("orm:table-generator");
        descriptor.addMapping(tableGeneratorsMapping);
       
        descriptor.addMapping(getNamedQueryMapping());       
        descriptor.addMapping(getNamedNativeQueryMapping());
        descriptor.addMapping(getNamedStoredProcedureQueryMapping());
        descriptor.addMapping(getResultSetMappingMapping());
       
        XMLCompositeCollectionMapping mappedSuperclassMapping = new XMLCompositeCollectionMapping();
        mappedSuperclassMapping.setAttributeName("m_mappedSuperclasses");
        mappedSuperclassMapping.setGetMethodName("getMappedSuperclasses");
        mappedSuperclassMapping.setSetMethodName("setMappedSuperclasses");
        mappedSuperclassMapping.setReferenceClass(MappedSuperclassAccessor.class);
        mappedSuperclassMapping.setXPath("orm:mapped-superclass");
        descriptor.addMapping(mappedSuperclassMapping);
       
        XMLCompositeCollectionMapping entityMapping = new XMLCompositeCollectionMapping();
        entityMapping.setAttributeName("m_entities");
        entityMapping.setGetMethodName("getEntities");
        entityMapping.setSetMethodName("setEntities");
        entityMapping.setReferenceClass(EntityAccessor.class);
        entityMapping.setXPath("orm:entity");
        descriptor.addMapping(entityMapping);
       
        XMLCompositeCollectionMapping embeddableMapping = new XMLCompositeCollectionMapping();
        embeddableMapping.setAttributeName("m_embeddables");
        embeddableMapping.setGetMethodName("getEmbeddables");
        embeddableMapping.setSetMethodName("setEmbeddables");
        embeddableMapping.setReferenceClass(EmbeddableAccessor.class);
        embeddableMapping.setXPath("orm:embeddable");
        descriptor.addMapping(embeddableMapping);
       
        // What about the version attribute???
        XMLDirectMapping versionMapping = new XMLDirectMapping();
        versionMapping.setAttributeName("m_version");
View Full Code Here


        embeddedIdMapping.setSetMethodName("setEmbeddedId");
        embeddedIdMapping.setReferenceClass(EmbeddedIdAccessor.class);
        embeddedIdMapping.setXPath("orm:embedded-id");
        descriptor.addMapping(embeddedIdMapping);
       
        XMLCompositeCollectionMapping idsMapping = new XMLCompositeCollectionMapping();
        idsMapping.setAttributeName("m_ids");
        idsMapping.setGetMethodName("getIds");
        idsMapping.setSetMethodName("setIds");
        idsMapping.setReferenceClass(IdAccessor.class);
        idsMapping.setXPath("orm:id");
        descriptor.addMapping(idsMapping);
       
        XMLCompositeCollectionMapping basicsMapping = new XMLCompositeCollectionMapping();
        basicsMapping.setAttributeName("m_basics");
        basicsMapping.setGetMethodName("getBasics");
        basicsMapping.setSetMethodName("setBasics");
        basicsMapping.setReferenceClass(BasicAccessor.class);
        basicsMapping.setXPath("orm:basic");
        descriptor.addMapping(basicsMapping);
       
        XMLCompositeCollectionMapping basicCollectionsMapping = new XMLCompositeCollectionMapping();
        basicCollectionsMapping.setAttributeName("m_basicCollections");
        basicCollectionsMapping.setGetMethodName("getBasicCollections");
        basicCollectionsMapping.setSetMethodName("setBasicCollections");
        basicCollectionsMapping.setReferenceClass(BasicCollectionAccessor.class);
        basicCollectionsMapping.setXPath("orm:basic-collection");
        descriptor.addMapping(basicCollectionsMapping);
       
        XMLCompositeCollectionMapping basicMapsMapping = new XMLCompositeCollectionMapping();
        basicMapsMapping.setAttributeName("m_basicMaps");
        basicMapsMapping.setGetMethodName("getBasicMaps");
        basicMapsMapping.setSetMethodName("setBasicMaps");
        basicMapsMapping.setReferenceClass(BasicMapAccessor.class);
        basicMapsMapping.setXPath("orm:basic-map");
        descriptor.addMapping(basicMapsMapping);
       
        XMLCompositeCollectionMapping versionsMapping = new XMLCompositeCollectionMapping();
        versionsMapping.setAttributeName("m_versions");
        versionsMapping.setGetMethodName("getVersions");
        versionsMapping.setSetMethodName("setVersions");
        versionsMapping.setReferenceClass(VersionAccessor.class);
        versionsMapping.setXPath("orm:version");
        descriptor.addMapping(versionsMapping);
       
        XMLCompositeCollectionMapping manyToOnesMapping = new XMLCompositeCollectionMapping();
        manyToOnesMapping.setAttributeName("m_manyToOnes");
        manyToOnesMapping.setGetMethodName("getManyToOnes");
        manyToOnesMapping.setSetMethodName("setManyToOnes");
        manyToOnesMapping.setReferenceClass(ManyToOneAccessor.class);
        manyToOnesMapping.setXPath("orm:many-to-one");
        descriptor.addMapping(manyToOnesMapping);
       
        XMLCompositeCollectionMapping oneToManysMapping = new XMLCompositeCollectionMapping();
        oneToManysMapping.setAttributeName("m_oneToManys");
        oneToManysMapping.setGetMethodName("getOneToManys");
        oneToManysMapping.setSetMethodName("setOneToManys");
        oneToManysMapping.setReferenceClass(OneToManyAccessor.class);
        oneToManysMapping.setXPath("orm:one-to-many");
        descriptor.addMapping(oneToManysMapping);
       
        XMLCompositeCollectionMapping oneToOnesMapping = new XMLCompositeCollectionMapping();
        oneToOnesMapping.setAttributeName("m_oneToOnes");
        oneToOnesMapping.setGetMethodName("getOneToOnes");
        oneToOnesMapping.setSetMethodName("setOneToOnes");
        oneToOnesMapping.setReferenceClass(OneToOneAccessor.class);
        oneToOnesMapping.setXPath("orm:one-to-one");
        descriptor.addMapping(oneToOnesMapping);
       
        XMLCompositeCollectionMapping variableOneToOnesMapping = new XMLCompositeCollectionMapping();
        variableOneToOnesMapping.setAttributeName("m_variableOneToOnes");
        variableOneToOnesMapping.setGetMethodName("getVariableOneToOnes");
        variableOneToOnesMapping.setSetMethodName("setVariableOneToOnes");
        variableOneToOnesMapping.setReferenceClass(VariableOneToOneAccessor.class);
        variableOneToOnesMapping.setXPath("orm:variable-one-to-one");
        descriptor.addMapping(variableOneToOnesMapping);
       
        XMLCompositeCollectionMapping manyToManysMapping = new XMLCompositeCollectionMapping();
        manyToManysMapping.setAttributeName("m_manyToManys");
        manyToManysMapping.setGetMethodName("getManyToManys");
        manyToManysMapping.setSetMethodName("setManyToManys");
        manyToManysMapping.setReferenceClass(ManyToManyAccessor.class);
        manyToManysMapping.setXPath("orm:many-to-many");
        descriptor.addMapping(manyToManysMapping);
       
        XMLCompositeCollectionMapping embeddedsMapping = new XMLCompositeCollectionMapping();
        embeddedsMapping.setAttributeName("m_embeddeds");
        embeddedsMapping.setGetMethodName("getEmbeddeds");
        embeddedsMapping.setSetMethodName("setEmbeddeds");
        embeddedsMapping.setReferenceClass(EmbeddedAccessor.class);
        embeddedsMapping.setXPath("orm:embedded");
        descriptor.addMapping(embeddedsMapping);
       
        XMLCompositeCollectionMapping transformationsMapping = new XMLCompositeCollectionMapping();
        transformationsMapping.setAttributeName("m_transformations");
        transformationsMapping.setGetMethodName("getTransformations");
        transformationsMapping.setSetMethodName("setTransformations");
        transformationsMapping.setReferenceClass(TransformationAccessor.class);
        transformationsMapping.setXPath("orm:transformation");
        descriptor.addMapping(transformationsMapping);
       
        XMLCompositeCollectionMapping transientsMapping = new XMLCompositeCollectionMapping();
        transientsMapping.setAttributeName("m_transients");
        transientsMapping.setGetMethodName("getTransients");
        transientsMapping.setSetMethodName("setTransients");
        transientsMapping.setReferenceClass(TransientAccessor.class);
        transientsMapping.setXPath("orm:transient");
        descriptor.addMapping(transientsMapping);
       
        return descriptor;
    }
View Full Code Here

    /**
     * INTERNAL:
     */
    protected XMLCompositeCollectionMapping getHintMapping() {
        XMLCompositeCollectionMapping hintMapping = new XMLCompositeCollectionMapping();
        hintMapping.setAttributeName("m_hints");
        hintMapping.setGetMethodName("getHints");
        hintMapping.setSetMethodName("setHints");
        hintMapping.setReferenceClass(QueryHintMetadata.class);
        hintMapping.setXPath("orm:hint");
        return hintMapping;
    }
View Full Code Here

   
    /**
     * INTERNAL:
     */
    protected XMLCompositeCollectionMapping getInverseJoinColumnMapping() {
        XMLCompositeCollectionMapping joinColumnMapping = new XMLCompositeCollectionMapping();
        joinColumnMapping.setAttributeName("m_inverseJoinColumns");
        joinColumnMapping.setGetMethodName("getInverseJoinColumns");
        joinColumnMapping.setSetMethodName("setInverseJoinColumns");
        joinColumnMapping.setReferenceClass(JoinColumnMetadata.class);
        joinColumnMapping.setXPath("orm:inverse-join-column");
        return joinColumnMapping;
    }
View Full Code Here

   
    /**
     * INTERNAL:
     */
    protected XMLCompositeCollectionMapping getJoinColumnMapping() {
        XMLCompositeCollectionMapping joinColumnMapping = new XMLCompositeCollectionMapping();
        joinColumnMapping.setAttributeName("m_joinColumns");
        joinColumnMapping.setGetMethodName("getJoinColumns");
        joinColumnMapping.setSetMethodName("setJoinColumns");
        joinColumnMapping.setReferenceClass(JoinColumnMetadata.class);
        joinColumnMapping.setXPath("orm:join-column");
        return joinColumnMapping;
    }
View Full Code Here

   
    /**
     * INTERNAL:
     */
    protected XMLCompositeCollectionMapping getNamedNativeQueryMapping() {
        XMLCompositeCollectionMapping namedNativeQueryMapping = new XMLCompositeCollectionMapping();
        namedNativeQueryMapping.setAttributeName("m_namedNativeQueries");
        namedNativeQueryMapping.setGetMethodName("getNamedNativeQueries");
        namedNativeQueryMapping.setSetMethodName("setNamedNativeQueries");
        namedNativeQueryMapping.setReferenceClass(NamedNativeQueryMetadata.class);
        namedNativeQueryMapping.setXPath("orm:named-native-query");
        return namedNativeQueryMapping;
    }
View Full Code Here

   
    /**
     * INTERNAL:
     */
    protected XMLCompositeCollectionMapping getNamedQueryMapping() {
        XMLCompositeCollectionMapping namedQueryMapping = new XMLCompositeCollectionMapping();
        namedQueryMapping.setAttributeName("m_namedQueries");
        namedQueryMapping.setGetMethodName("getNamedQueries");
        namedQueryMapping.setSetMethodName("setNamedQueries");
        namedQueryMapping.setReferenceClass(NamedQueryMetadata.class);
        namedQueryMapping.setXPath("orm:named-query");
        return namedQueryMapping;
    }
View Full Code Here

   
    /**
     * INTERNAL:
     */
    protected XMLCompositeCollectionMapping getNamedStoredProcedureQueryMapping() {
        XMLCompositeCollectionMapping namedStoredProcedureQueryMapping = new XMLCompositeCollectionMapping();
        namedStoredProcedureQueryMapping.setAttributeName("m_namedStoredProcedureQueries");
        namedStoredProcedureQueryMapping.setGetMethodName("getNamedStoredProcedureQueries");
        namedStoredProcedureQueryMapping.setSetMethodName("setNamedStoredProcedureQueries");
        namedStoredProcedureQueryMapping.setReferenceClass(NamedStoredProcedureQueryMetadata.class);
        namedStoredProcedureQueryMapping.setXPath("orm:named-stored-procedure-query");
        return namedStoredProcedureQueryMapping;
    }
View Full Code Here

   
    /**
     * INTERNAL:
     */
    protected XMLCompositeCollectionMapping getObjectTypeConverterMapping() {
        XMLCompositeCollectionMapping objectTypeConvertersMapping = new XMLCompositeCollectionMapping();
        objectTypeConvertersMapping.setAttributeName("m_objectTypeConverters");
        objectTypeConvertersMapping.setGetMethodName("getObjectTypeConverters");
        objectTypeConvertersMapping.setSetMethodName("setObjectTypeConverters");
        objectTypeConvertersMapping.setReferenceClass(ObjectTypeConverterMetadata.class);
        objectTypeConvertersMapping.setXPath("orm:object-type-converter");
        return objectTypeConvertersMapping;
    }
View Full Code Here

   
    /**
     * INTERNAL:
     */
    protected XMLCompositeCollectionMapping getPrimaryKeyJoinColumnMapping() {
        XMLCompositeCollectionMapping primaryKeyJoinColumnMapping = new XMLCompositeCollectionMapping();
        primaryKeyJoinColumnMapping.setAttributeName("m_primaryKeyJoinColumns");
        primaryKeyJoinColumnMapping.setGetMethodName("getPrimaryKeyJoinColumns");
        primaryKeyJoinColumnMapping.setSetMethodName("setPrimaryKeyJoinColumns");
        primaryKeyJoinColumnMapping.setReferenceClass(PrimaryKeyJoinColumnMetadata.class);
        primaryKeyJoinColumnMapping.setXPath("orm:primary-key-join-column");
        return primaryKeyJoinColumnMapping;
    }
View Full Code Here

TOP

Related Classes of org.eclipse.persistence.oxm.mappings.XMLCompositeCollectionMapping

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.