Examples of DbConfig


Examples of org.qdao.DBConfig

      NoSuchMethodException, ClassNotFoundException, SQLException {
    return initializeDBEngine(config).getEntityDao(clazz, isLogger);
  }

  public static IDBEngine initializeDBEngine()  {
    DBConfig config = DBConfig.getInstance();
    // config.driver = "oracle.jdbc.driver.OracleDriver";
    // System.out.println(config.driver.indexOf("oracle"));
    // config.username = "QDAO";
    // config.password = "QDAO";
    // config.url = "jdbc:oracle:thin:@WAMNET-SVR:1521:WAMNET";
View Full Code Here

Examples of org.qdao.DBConfig

   * 2010/03/03 11:59:41
   */
  public static IDBEngine initializeDBEngine(String[] jarPaths, String driver, String url, String username, String password) throws InstantiationException, IllegalAccessException,
      ClassNotFoundException,
      SQLException {
    DBConfig config = DBConfig.getInstance();
    config.driver = driver;
    config.username = username;
    config.password = password;
    config.url = url;
    config.jarPath = jarPaths;
View Full Code Here

Examples of org.xtreemfs.babudb.lsmdb.DBConfig

       
        this.configuration = configuration;
        this.responseManager = new ResponseManagerImpl(configuration.getMaxQueueLength());
        this.txnMan = new TransactionManagerImpl(configuration.getSyncMode().equals(SyncMode.ASYNC));
        this.databaseManager = new DatabaseManagerImpl(this);
        this.dbConfigFile = new DBConfig(this);
        this.snapshotManager = new SnapshotManagerImpl(this);
        this.dbCheckptr = new CheckpointerImpl(this);
    }
View Full Code Here

Examples of play.db.DBConfig

            closeConnection(connection);
        }
    }
   
    public static DataSource getDatasource() {
        DBConfig dbConfig = DB.getDBConfig(DBConfig.defaultDbConfigName, true);
        if (dbConfig==null) {
            return null;
        }
        return dbConfig.getDatasource();
    }
View Full Code Here

Examples of play.db.DBConfig

            dbConfigName = DBConfig.defaultDbConfigName;
        }
       
        try {
            List<String> names = new ArrayList<String>();
            DBConfig dbConfig = DB.getDBConfig(dbConfigName);
            ResultSet rs = dbConfig.getConnection().getMetaData().getTables(null, null, null, new String[]{"TABLE"});
            while (rs.next()) {
                String name = rs.getString("TABLE_NAME");
                names.add(name);
            }
            disableForeignKeyConstraints(dbConfig);
            for (String name : names) {
                if(Arrays.binarySearch(dontDeleteTheseTables, name) < 0) {
                    if (Logger.isTraceEnabled()) {
                        Logger.trace("Dropping content of table %s", name);
                    }
                    dbConfig.execute(getDeleteTableStmt(dbConfig.getUrl(), name) + ";");
                }
            }
            enableForeignKeyConstraints(dbConfig);
            Play.pluginCollection.afterFixtureLoad();
        } catch (Exception e) {
View Full Code Here

Examples of test.org.magicbox.dbunit.DBConfig

   
    dbUrls.pulisciDb();
  }
 
  public void testInsertConfigUrl(String url){
    DBConfig dbConfig= new DBConfig();
    assertNull( _dao.getConfigUrl());
    String urlConfig="CONVERT_URL_TO_LOWERCASE_BEFORE_COMPARISON\n"+
      "PATTERN_TYPE_APACHE_ANT\n"+
      "/*.admin=ROLE_ADMIN\n"+
      "/*.page=ROLE_ADMIN,ROLE_USER\n"+
      "/*.csv=ROLE_USER\n"+
      "/*.pdf=ROLE_USER\n"+
      "/*.xls=ROLE_USER\n"+
      "/*.htm=ROLE_USER\n"+
      "/*.graph=ROLE_USER\n"+
      "/dwr/*=ROLE_USER,ROLE_ADMIN\n"+
      "/feed/atom.xml=ROLE_ADMIN,ROLE_USER,ROLE_ANON\n"+
      "/feed/rss.xml=ROLE_ANON,ROLE_USER,ROLE_ADMIN\n";
    assertTrue(_dao.insertConfigUrl(urlConfig) > 0);
    dbConfig.pulisciDb();
  }
View Full Code Here

Examples of test.org.magicbox.dbunit.DBConfig

    assertTrue(_dao.insertConfigUrl(urlConfig) > 0);
    dbConfig.pulisciDb();
  }
 
  public void testUpdateConfigUrl(){
    DBConfig dbConfig= new DBConfig();
    dbConfig.preparaDb();
    String urlConfig="CONVERT_URL_TO_LOWERCASE_BEFORE_COMPARISON\n"+
      "PATTERN_TYPE_APACHE_ANT\n"+
      "/pippo.admin=ROLE_ADMIN\n"+
      "/pluto.page=ROLE_ADMIN,ROLE_USER\n"+
      "/paperino.csv=ROLE_USER\n"+
      "/ciccio.pdf=ROLE_USER\n"+
      "/paperone.xls=ROLE_USER\n"+
      "/paperinik.htm=ROLE_USER\n"+
      "/archimede.graph=ROLE_USER\n"+
      "/dwr/*=ROLE_USER,ROLE_ADMIN\n"+
      "/feed/atom.xml=ROLE_ADMIN,ROLE_USER,ROLE_ANON\n"+
      "/feed/rss.xml=ROLE_ANON,ROLE_USER,ROLE_ADMIN\n";
    assertTrue(_dao.updateConfigUrl(urlConfig) == 1);
    dbConfig.pulisciDb();
  }
View Full Code Here

Examples of test.org.magicbox.dbunit.DBConfig

   
    dbUrls.pulisciDb();
  }
 
  public void testSelectUrl() {
    DBConfig dbConfig = new DBConfig();
    dbConfig.preparaDb();
   
    String acegiUrl = _dao.getConfigUrl();
    assertTrue(acegiUrl.length() > 47);
   
    dbConfig.pulisciDb();
  }
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.