use of org.apache.jena.sdb.StoreDesc in project jena by apache.
the class StoreCreator method getIndexMySQL.
public static Store getIndexMySQL() {
if (sdbmsi == null) {
JDBC.loadDriverMySQL();
SDBConnection sdb = SDBFactory.createConnection(// "sdb_test", "jena", "swara"
"jdbc:mysql://localhost/test2-index", "user", "password");
StoreDesc desc = new StoreDesc(LayoutType.LayoutTripleNodesIndex, DatabaseType.MySQL);
sdbmsi = new StoreTriplesNodesIndexMySQL(sdb, desc);
sdbmsi.getTableFormatter().create();
} else
sdbmsi.getTableFormatter().truncate();
return sdbmsi;
}
use of org.apache.jena.sdb.StoreDesc in project jena by apache.
the class StoreCreator method getHashMySQL.
public static Store getHashMySQL() {
if (sdbmsh == null) {
JDBC.loadDriverMySQL();
SDBConnection sdb = SDBFactory.createConnection("jdbc:mysql://localhost/test2-hash", "user", "password");
StoreDesc desc = new StoreDesc(LayoutType.LayoutTripleNodesHash, DatabaseType.MySQL);
sdbmsh = new StoreTriplesNodesHashMySQL(sdb, desc);
sdbmsh.getTableFormatter().create();
} else
sdbmsh.getTableFormatter().truncate();
return sdbmsh;
}
use of org.apache.jena.sdb.StoreDesc in project jena by apache.
the class StoreCreator method getHashHSQL.
public static Store getHashHSQL() {
if (sdbhsh == null) {
JDBC.loadDriverHSQL();
SDBConnection sdb = SDBFactory.createConnection("jdbc:hsqldb:mem:bname", "sa", "");
StoreDesc desc = new StoreDesc(LayoutType.LayoutTripleNodesHash, DatabaseType.HSQLDB);
sdbhsh = new StoreTriplesNodesHashHSQL(sdb, desc);
sdbhsh.getTableFormatter().create();
} else
sdbhsh.getTableFormatter().truncate();
return sdbhsh;
}
use of org.apache.jena.sdb.StoreDesc in project jena by apache.
the class StoreCreator method getIndexSAP.
public static Store getIndexSAP() {
if (sdbsapi == null) {
JDBC.loadDriverSAP();
SDBConnection sdb = SDBFactory.createConnection("jdbc:sap://localhost/test2-index", "user", "password");
StoreDesc desc = new StoreDesc(LayoutType.LayoutTripleNodesIndex, DatabaseType.SAP);
sdbsapi = new StoreTriplesNodesIndexSAP(sdb, desc);
sdbsapi.getTableFormatter().create();
} else
sdbsapi.getTableFormatter().truncate();
return sdbsapi;
}
use of org.apache.jena.sdb.StoreDesc in project jena by apache.
the class StoreCreator method getHashPgSQL.
public static Store getHashPgSQL() {
if (sdbpgh == null) {
JDBC.loadDriverPGSQL();
SDBConnection sdb = SDBFactory.createConnection("jdbc:postgresql://localhost/test2-hash", "user", "password");
StoreDesc desc = new StoreDesc(LayoutType.LayoutTripleNodesHash, DatabaseType.PostgreSQL);
sdbpgh = new StoreTriplesNodesHashPGSQL(sdb, desc);
sdbpgh.getTableFormatter().create();
} else
sdbpgh.getTableFormatter().truncate();
return sdbpgh;
}
Aggregations