Examples of JdoConf


Examples of org.castor.jdo.conf.JdoConf

    }
   
    public static final JDOManager getJDOManager(final String name)
    throws MappingException {
        if (!DatabaseRegistry.isDatabaseRegistred(name)) {
            JdoConf jdoConf = _registry.createJdoConf(name, _database, _transaction);
            String baseURL = _registry.getJdoConfBaseURL();
            JDOManager.loadConfiguration(jdoConf, baseURL);
        }

        return JDOManager.createInstance(name);
View Full Code Here

Examples of org.castor.jdo.conf.JdoConf

    }
   
    public static final JDOManager getJDOManager(final String name, final String[] mappings)
    throws MappingException {
        if (!DatabaseRegistry.isDatabaseRegistred(name)) {
            JdoConf jdoConf = _registry.createJdoConf(name, _database, _transaction, mappings);
            String baseURL = _registry.getJdoConfBaseURL();
            JDOManager.loadConfiguration(jdoConf, baseURL);
        }

        return JDOManager.createInstance(name);
View Full Code Here

Examples of org.castor.jdo.conf.JdoConf

        AbstractProperties properties = getProperties();
        boolean useProxies = properties.getBoolean(CPAProperties.USE_JDBC_PROXIES, true);

        AbstractConnectionFactory factory = null;
       
        JdoConf jdoConf = getJdoConf(DBNAME, MAPPING);
        if (jdoConf.getDatabase(0).getDatabaseChoice().getDriver() != null) {
            factory = new DriverConnectionFactory(jdoConf, 0, null);
        } else if (jdoConf.getDatabase(0).getDatabaseChoice().getDataSource() != null) {
            factory = new DataSourceConnectionFactory(jdoConf, 0, new Mapping());
        } else if (jdoConf.getDatabase(0).getDatabaseChoice().getDriver() != null) {
            factory = new JNDIConnectionFactory(jdoConf, 0, null);
        }
       
        factory.initializeFactory();
       
View Full Code Here

Examples of org.castor.jdo.conf.JdoConf

            || (engine == DatabaseEngineType.SQL_SERVER);
    }
   
    public void testDoubleEntities() throws Exception {
        try {
            JdoConf jdoConf = createJdoConf("double");
            JDOManager.loadConfiguration(jdoConf, getJdoConfBaseURL());
            fail();
        } catch (MappingException ex) {
            assertEquals("org.exolab.castor.mapping.MappingException",
                    ex.getClass().getName());
View Full Code Here

Examples of org.castor.jdo.conf.JdoConf

                    ex.getClass().getName());
        }
    }

    public void testIntEntities() throws Exception {
        JdoConf jdoConf = createJdoConf("int");
        JDOManager.loadConfiguration(jdoConf, getJdoConfBaseURL());
        JDOManager jdo = JDOManager.createInstance(DBNAME + "-int");

        Database db = jdo.getDatabase();
        db.begin();
View Full Code Here

Examples of org.castor.jdo.conf.JdoConf

       
        jdo = null;
    }

    public void testIntAndDoubleEntities() throws Exception {
        JdoConf jdoConf = createJdoConf("int-and-double");
        JDOManager.loadConfiguration(jdoConf, getJdoConfBaseURL());
        JDOManager jdo = JDOManager.createInstance(DBNAME + "-int-and-double");
       
        Database db = jdo.getDatabase();
        db.begin();
View Full Code Here

Examples of org.castor.jdo.conf.JdoConf

       
        jdo = null;
    }

    public void testIntAndIntegerEntities() throws Exception {
        JdoConf jdoConf = createJdoConf("int-and-integer");
        JDOManager.loadConfiguration(jdoConf, getJdoConfBaseURL());
        JDOManager jdo = JDOManager.createInstance(DBNAME + "-int-and-integer");
       
        Database db = jdo.getDatabase();
        db.begin();
View Full Code Here

Examples of org.castor.jdo.conf.JdoConf

       
        jdo = null;
    }

    public void testIntegerEntities() throws Exception {
        JdoConf jdoConf = createJdoConf("integer");
        JDOManager.loadConfiguration(jdoConf, getJdoConfBaseURL());
        JDOManager jdo = JDOManager.createInstance(DBNAME + "-integer");
       
        Database db = jdo.getDatabase();
        db.begin();
View Full Code Here

Examples of org.castor.jdo.conf.JdoConf

       
        jdo = null;
    }

    public void testIntegerAndDoubleEntities() throws Exception {
        JdoConf jdoConf = createJdoConf("integer-and-double");
        JDOManager.loadConfiguration(jdoConf, getJdoConfBaseURL());
        JDOManager jdo = JDOManager.createInstance(DBNAME + "-integer-and-double");
       
        Database db = jdo.getDatabase();
        db.begin();
View Full Code Here

Examples of org.castor.jdo.conf.JdoConf

       
        jdo = null;
    }
   
    public void testLoadNullIntAndIntegerEntities() throws Exception {
        JdoConf jdoConf = createJdoConf("int-and-integer");
        JDOManager.loadConfiguration(jdoConf, getJdoConfBaseURL());
        JDOManager jdo = JDOManager.createInstance(DBNAME + "-int-and-integer");
       
        Database db = jdo.getDatabase();
       
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.