Examples of GerEntityManagerFactoryRefType


Examples of org.apache.geronimo.xbeans.geronimo.naming.GerEntityManagerFactoryRefType

    }

    public void buildNaming(XmlObject specDD, XmlObject plan, Configuration localConfiguration, Configuration remoteConfiguration, Module module, Map componentContext) throws DeploymentException {
        XmlObject[] EntityManagerFactoryRefsUntyped = getEntityManagerFactoryRefs(plan);
        for (int i = 0; i < EntityManagerFactoryRefsUntyped.length; i++) {
            GerEntityManagerFactoryRefType EntityManagerFactoryRef = (GerEntityManagerFactoryRefType) EntityManagerFactoryRefsUntyped[i];
            if (EntityManagerFactoryRef == null) {
                throw new DeploymentException("Could not read EntityManagerFactoryRef number " + i + " as the correct xml type");
            }
            String EntityManagerFactoryRefName = EntityManagerFactoryRef.getEntityManagerFactoryRefName();

            Set interfaceTypes = Collections.singleton("org.apache.geronimo.persistence.PersistenceUnitGBean");
            AbstractNameQuery persistenceUnitNameQuery;
            if (EntityManagerFactoryRef.isSetPersistenceUnitName()) {
                String persistenceUnitName = EntityManagerFactoryRef.getPersistenceUnitName();
                persistenceUnitNameQuery = new AbstractNameQuery(null, Collections.singletonMap("name", persistenceUnitName), interfaceTypes);
            } else {
                GerPatternType gbeanLocator = EntityManagerFactoryRef.getPattern();

                persistenceUnitNameQuery = buildAbstractNameQuery(gbeanLocator, null, null, interfaceTypes);
            }

            try {
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.naming.GerEntityManagerFactoryRefType

    public void buildNaming(XmlObject specDD, XmlObject plan, Configuration localConfiguration, Configuration remoteConfiguration, Module module, Map componentContext) throws DeploymentException {
        XmlObject[] EntityManagerFactoryRefsUntyped = getEntityManagerFactoryRefs(plan);
        for (int i = 0; i < EntityManagerFactoryRefsUntyped.length; i++) {
            XmlObject EntityManagerFactoryRefUntyped = EntityManagerFactoryRefsUntyped[i];
            GerEntityManagerFactoryRefType EntityManagerFactoryRef = (GerEntityManagerFactoryRefType) EntityManagerFactoryRefUntyped.copy().changeType(GerEntityManagerFactoryRefType.type);
            if (EntityManagerFactoryRef == null) {
                throw new DeploymentException("Could not read EntityManagerFactoryRef " + EntityManagerFactoryRefUntyped + " as the correct xml type");
            }
            String EntityManagerFactoryRefName = EntityManagerFactoryRef.getEntityManagerFactoryRefName();

            Set interfaceTypes = Collections.singleton("org.apache.geronimo.persistence.PersistenceUnitGBean");
            AbstractNameQuery persistenceUnitNameQuery;
            if (EntityManagerFactoryRef.isSetPersistenceUnitName()) {
                String persistenceUnitName = EntityManagerFactoryRef.getPersistenceUnitName();
                persistenceUnitNameQuery = new AbstractNameQuery(null, Collections.singletonMap("name", persistenceUnitName), interfaceTypes);
            } else {
                GerPatternType gbeanLocator = EntityManagerFactoryRef.getPattern();

                persistenceUnitNameQuery = ENCConfigBuilder.buildAbstractNameQuery(gbeanLocator, null, null, interfaceTypes);
            }

            try {
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.