com.hp.hpl.jena.sdb
Class SDBFactory

java.lang.Object
  extended by com.hp.hpl.jena.sdb.SDBFactory

public class SDBFactory
extends Object

Various operations to create or connect objects to do with SDB: SDBConnections, Stores, Models, Graphs. Convenience calls.

Author:
Andy Seaborne

Constructor Summary
SDBFactory()
           
 
Method Summary
static com.hp.hpl.jena.query.Dataset connectDataset(Connection jdbcConnection, StoreDesc desc)
          Connect to the RDF dataset in a store, using existing JDBC connection and a store description.
static com.hp.hpl.jena.query.Dataset connectDataset(SDBConnection sdbConnection, StoreDesc desc)
          Connect to the RDF dataset in a store, using existing SDBConnection and a store description.
static com.hp.hpl.jena.query.Dataset connectDataset(Store store)
          Connect to the RDF dataset in a store.
static com.hp.hpl.jena.query.Dataset connectDataset(StoreDesc desc)
          Connect to the RDF dataset in a store.
static com.hp.hpl.jena.query.Dataset connectDataset(String configFile)
          Connect to the RDF dataset in a store, based on a Store assembler file.
static com.hp.hpl.jena.graph.Graph connectDefaultGraph(Store store)
          Connect to the default graph in a store, based on a Store description.
static com.hp.hpl.jena.graph.Graph connectDefaultGraph(StoreDesc desc)
          Connect to the default graph in a store, based on a Store description.
static com.hp.hpl.jena.graph.Graph connectDefaultGraph(String configFile)
          Connect to the default graph in a store, based on a Store assembler file.
static com.hp.hpl.jena.rdf.model.Model connectDefaultModel(Store store)
          Connect to the default model in a store
static com.hp.hpl.jena.rdf.model.Model connectDefaultModel(StoreDesc desc)
          Connect to the default model in a store
static com.hp.hpl.jena.rdf.model.Model connectDefaultModel(String configFile)
          Connect to the default model in a store, using the store description in a file.
static com.hp.hpl.jena.update.GraphStore connectGraphStore(Connection jdbcConnection, StoreDesc desc)
          Connect to the store as a GraphStore, using existing JDBC connection and a store description.
static com.hp.hpl.jena.update.GraphStore connectGraphStore(SDBConnection sdbConnection, StoreDesc desc)
          Connect to the store as a GraphStore, using existing SDBConnection and a store description.
static com.hp.hpl.jena.update.GraphStore connectGraphStore(Store store)
          Connect to the store as a GraphStore
static com.hp.hpl.jena.update.GraphStore connectGraphStore(StoreDesc desc)
          Connect to the store as a GraphStore.
static com.hp.hpl.jena.update.GraphStore connectGraphStore(String configFile)
          Connect to the store as a GraphStore, based on a Store assembler file.
static com.hp.hpl.jena.graph.Graph connectNamedGraph(StoreDesc desc, com.hp.hpl.jena.graph.Node node)
          Connect to a named graph in a store, based on a store description.
static com.hp.hpl.jena.graph.Graph connectNamedGraph(StoreDesc desc, String iri)
          Connect to a named graph in a store, based on a store description.
static com.hp.hpl.jena.graph.Graph connectNamedGraph(Store store, com.hp.hpl.jena.graph.Node node)
          Connect to a named graph in a store.
static com.hp.hpl.jena.graph.Graph connectNamedGraph(Store store, String iri)
          Connect to a named graph in a store.
static com.hp.hpl.jena.graph.Graph connectNamedGraph(String configFile, com.hp.hpl.jena.graph.Node node)
          Connect to a named graph in a store, based on a store description file.
static com.hp.hpl.jena.graph.Graph connectNamedGraph(String configFile, String iri)
          Connect to a named graph in a store, based on a store description file.
static com.hp.hpl.jena.rdf.model.Model connectNamedModel(StoreDesc desc, com.hp.hpl.jena.rdf.model.Resource resource)
          Connect to the named model in a store
static com.hp.hpl.jena.rdf.model.Model connectNamedModel(StoreDesc desc, String iri)
          Connect to the named model in a store
static com.hp.hpl.jena.rdf.model.Model connectNamedModel(Store store, com.hp.hpl.jena.rdf.model.Resource resource)
          Connect to the named model in a store
static com.hp.hpl.jena.rdf.model.Model connectNamedModel(Store store, String iri)
          Connect to the named model in a store
static com.hp.hpl.jena.rdf.model.Model connectNamedModel(String configFile, com.hp.hpl.jena.rdf.model.Resource resource)
          Connect to the named model in a store
static com.hp.hpl.jena.rdf.model.Model connectNamedModel(String configFile, String iri)
          Connect to the named model in a store
static Store connectStore(Connection sqlConnection, StoreDesc desc)
          Connect to a store, based on an existing JDBC connection and a store description.
static Store connectStore(SDBConnection sdbConnection, StoreDesc desc)
          Connect to a store, based on an existing SDB connection and a store description.
static Store connectStore(StoreDesc desc)
          Connect to a store, based on a store description.
static Store connectStore(String configFile)
          Connect to a store, based on store and connection descriptions in a file.
static SDBConnection createConnection(Connection conn)
          Create a connection to a database from a JDBC connection.
static SDBConnection createConnection(SDBConnectionDesc desc)
          Create a connection to a database from connection description.
static SDBConnection createConnection(String configFile)
          Create a connection to a database from connection description in a file.
static SDBConnection createConnection(String jdbcURL, String user, String password)
          Create a connection to a database.
static Connection createSqlConnection(com.hp.hpl.jena.rdf.model.Model model)
          Create JDBC connection associated with the SDB connection description in a model.
static Connection createSqlConnection(SDBConnectionDesc desc)
          Create JDBC connection associated with the SDB connection description.
static Connection createSqlConnection(String configFile)
          Create JDBC connection associated with the SDB connection description in a file.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SDBFactory

public SDBFactory()
Method Detail

createConnection

public static SDBConnection createConnection(String jdbcURL,
                                             String user,
                                             String password)
Create a connection to a database.

Parameters:
jdbcURL -
user -
password -
Returns:
SDBConnection

createConnection

public static SDBConnection createConnection(SDBConnectionDesc desc)
Create a connection to a database from connection description.

Parameters:
desc - SDB connection description
Returns:
SDBConnection

createConnection

public static SDBConnection createConnection(Connection conn)
Create a connection to a database from a JDBC connection.

Parameters:
conn - JDBC connection
Returns:
SDBConnection

createConnection

public static SDBConnection createConnection(String configFile)
Create a connection to a database from connection description in a file.

Parameters:
configFile - Filename to be read and parsed (Jena assembler)
Returns:
SDBConnection

createSqlConnection

public static Connection createSqlConnection(SDBConnectionDesc desc)
Create JDBC connection associated with the SDB connection description.

Parameters:
desc - SDB connection description
Returns:
Connection

createSqlConnection

public static Connection createSqlConnection(String configFile)
Create JDBC connection associated with the SDB connection description in a file.

Parameters:
configFile - Filename
Returns:
Connection

createSqlConnection

public static Connection createSqlConnection(com.hp.hpl.jena.rdf.model.Model model)
Create JDBC connection associated with the SDB connection description in a model.

Parameters:
model - Model
Returns:
Connection

connectStore

public static Store connectStore(String configFile)
Connect to a store, based on store and connection descriptions in a file.

Parameters:
configFile - Filename for assembler for Store and SDBConenction
Returns:
Store

connectStore

public static Store connectStore(StoreDesc desc)
Connect to a store, based on a store description.

Parameters:
desc - Store description object
Returns:
Store

connectStore

public static Store connectStore(SDBConnection sdbConnection,
                                 StoreDesc desc)
Connect to a store, based on an existing SDB connection and a store description.

Parameters:
sdbConnection - SDBConnection object
desc - Store description object
Returns:
Store

connectStore

public static Store connectStore(Connection sqlConnection,
                                 StoreDesc desc)
Connect to a store, based on an existing JDBC connection and a store description.

Parameters:
sqlConnection - JDBC connection
desc - Store description object
Returns:
Store

connectDataset

public static com.hp.hpl.jena.query.Dataset connectDataset(Store store)
Connect to the RDF dataset in a store.

Parameters:
store -
Returns:
Dataset

connectDataset

public static com.hp.hpl.jena.query.Dataset connectDataset(StoreDesc desc)
Connect to the RDF dataset in a store.

Parameters:
desc - Store description
Returns:
Dataset

connectDataset

public static com.hp.hpl.jena.query.Dataset connectDataset(SDBConnection sdbConnection,
                                                           StoreDesc desc)
Connect to the RDF dataset in a store, using existing SDBConnection and a store description.

Parameters:
sdbConnection - SDB connection
desc - Store description object
Returns:
Dataset

connectDataset

public static com.hp.hpl.jena.query.Dataset connectDataset(Connection jdbcConnection,
                                                           StoreDesc desc)
Connect to the RDF dataset in a store, using existing JDBC connection and a store description.

Parameters:
jdbcConnection - JDBC connection
desc - Store description object
Returns:
Dataset

connectDataset

public static com.hp.hpl.jena.query.Dataset connectDataset(String configFile)
Connect to the RDF dataset in a store, based on a Store assembler file.

Parameters:
configFile -
Returns:
Dataset

connectGraphStore

public static com.hp.hpl.jena.update.GraphStore connectGraphStore(Store store)
Connect to the store as a GraphStore

Parameters:
store -
Returns:
GraphStore

connectGraphStore

public static com.hp.hpl.jena.update.GraphStore connectGraphStore(StoreDesc desc)
Connect to the store as a GraphStore.

Parameters:
desc - Store description
Returns:
GraphStore

connectGraphStore

public static com.hp.hpl.jena.update.GraphStore connectGraphStore(SDBConnection sdbConnection,
                                                                  StoreDesc desc)
Connect to the store as a GraphStore, using existing SDBConnection and a store description.

Parameters:
sdbConnection - SDB connection
desc - Store description object
Returns:
GraphStore

connectGraphStore

public static com.hp.hpl.jena.update.GraphStore connectGraphStore(Connection jdbcConnection,
                                                                  StoreDesc desc)
Connect to the store as a GraphStore, using existing JDBC connection and a store description.

Parameters:
jdbcConnection - JDBC connection
desc - Store description object
Returns:
GraphStore

connectGraphStore

public static com.hp.hpl.jena.update.GraphStore connectGraphStore(String configFile)
Connect to the store as a GraphStore, based on a Store assembler file.

Parameters:
configFile -
Returns:
GraphStore

connectDefaultGraph

public static com.hp.hpl.jena.graph.Graph connectDefaultGraph(String configFile)
Connect to the default graph in a store, based on a Store assembler file.

Parameters:
configFile -
Returns:
Graph

connectDefaultGraph

public static com.hp.hpl.jena.graph.Graph connectDefaultGraph(StoreDesc desc)
Connect to the default graph in a store, based on a Store description.

Parameters:
desc - Store description object
Returns:
Graph

connectDefaultGraph

public static com.hp.hpl.jena.graph.Graph connectDefaultGraph(Store store)
Connect to the default graph in a store, based on a Store description.

Parameters:
store - The store containing the dataset for the default graph
Returns:
Graph

connectNamedGraph

public static com.hp.hpl.jena.graph.Graph connectNamedGraph(String configFile,
                                                            String iri)
Connect to a named graph in a store, based on a store description file.

Parameters:
configFile -
iri -
Returns:
Graph

connectNamedGraph

public static com.hp.hpl.jena.graph.Graph connectNamedGraph(StoreDesc desc,
                                                            String iri)
Connect to a named graph in a store, based on a store description.

Parameters:
desc -
iri -
Returns:
Graph

connectNamedGraph

public static com.hp.hpl.jena.graph.Graph connectNamedGraph(Store store,
                                                            String iri)
Connect to a named graph in a store.

Parameters:
store -
iri -
Returns:
Graph

connectNamedGraph

public static com.hp.hpl.jena.graph.Graph connectNamedGraph(String configFile,
                                                            com.hp.hpl.jena.graph.Node node)
Connect to a named graph in a store, based on a store description file.

Parameters:
configFile -
node -
Returns:
Graph

connectNamedGraph

public static com.hp.hpl.jena.graph.Graph connectNamedGraph(StoreDesc desc,
                                                            com.hp.hpl.jena.graph.Node node)
Connect to a named graph in a store, based on a store description.

Parameters:
desc -
node -
Returns:
Graph

connectNamedGraph

public static com.hp.hpl.jena.graph.Graph connectNamedGraph(Store store,
                                                            com.hp.hpl.jena.graph.Node node)
Connect to a named graph in a store.

Parameters:
store -
node -
Returns:
Graph

connectDefaultModel

public static com.hp.hpl.jena.rdf.model.Model connectDefaultModel(String configFile)
Connect to the default model in a store, using the store description in a file.

Parameters:
configFile - Filename
Returns:
Model

connectDefaultModel

public static com.hp.hpl.jena.rdf.model.Model connectDefaultModel(StoreDesc desc)
Connect to the default model in a store

Parameters:
desc -
Returns:
Model

connectDefaultModel

public static com.hp.hpl.jena.rdf.model.Model connectDefaultModel(Store store)
Connect to the default model in a store

Parameters:
store -
Returns:
Model

connectNamedModel

public static com.hp.hpl.jena.rdf.model.Model connectNamedModel(StoreDesc desc,
                                                                String iri)
Connect to the named model in a store

Parameters:
desc -
iri -
Returns:
Model

connectNamedModel

public static com.hp.hpl.jena.rdf.model.Model connectNamedModel(Store store,
                                                                String iri)
Connect to the named model in a store

Parameters:
store -
iri -
Returns:
Model

connectNamedModel

public static com.hp.hpl.jena.rdf.model.Model connectNamedModel(String configFile,
                                                                String iri)
Connect to the named model in a store

Parameters:
configFile -
iri -
Returns:
Model

connectNamedModel

public static com.hp.hpl.jena.rdf.model.Model connectNamedModel(StoreDesc desc,
                                                                com.hp.hpl.jena.rdf.model.Resource resource)
Connect to the named model in a store

Parameters:
desc -
resource -
Returns:
Model

connectNamedModel

public static com.hp.hpl.jena.rdf.model.Model connectNamedModel(Store store,
                                                                com.hp.hpl.jena.rdf.model.Resource resource)
Connect to the named model in a store

Parameters:
store -
resource -
Returns:
Model

connectNamedModel

public static com.hp.hpl.jena.rdf.model.Model connectNamedModel(String configFile,
                                                                com.hp.hpl.jena.rdf.model.Resource resource)
Connect to the named model in a store

Parameters:
configFile -
resource -
Returns:
Model


Copyright ? 2006, 2007, 2008, 2009 Hewlett-Packard Development Company, LP Copyright ? 2010 Epimorphics Ltd.