|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.lehigh.swat.hawk.storage.StorageModel
edu.lehigh.swat.hawk.storage.PersistentStorageModel
edu.lehigh.swat.hawk.storage.simpledb.DatabaseStorage
public class DatabaseStorage
Field Summary | |
---|---|
protected java.util.Hashtable |
knownDocs
|
protected java.util.Hashtable |
knownOntos
|
protected java.util.Hashtable |
knownUrls
|
protected int |
maxUrlNum
|
protected int |
ontSeqNum
|
protected java.util.Hashtable |
propertyTypes
|
protected int |
sourceSeqNum
|
protected java.sql.Statement |
stmt
|
Constructor Summary | |
---|---|
DatabaseStorage(java.lang.String DBName)
Constructor. |
Method Summary | |
---|---|
void |
addDocument(Document d)
Add a document to this model. |
void |
close()
Close the database connection. |
Document |
createDocument()
Create an Document object. |
void |
createKb()
Initialize the database. |
Ontology |
createOntology()
Create an Ontology object. |
int |
decideCommitOnto(Document doc,
ObjectId id)
Decide which ontology would commit to giving the resource doc and objectId. |
void |
forcedExit()
Forced exit. |
java.lang.String |
getDBName()
Get the database name. |
Document |
getDocument(java.lang.String url)
Get the specified document. |
java.util.Iterator |
getDocumentIterator()
Get all the documents in the model. |
java.util.Hashtable |
getKnownOntologies()
retrieval ontologies already exist in database |
java.util.Hashtable |
getKnownUrls()
Retrieval Urls already exist in database |
int |
getOntSeq(java.lang.String ns)
Get the sequence number for giving ontology. |
java.util.Hashtable |
getPropertyTypes()
Get the types of properties. |
java.lang.String |
getQueryOntology()
Get the query ontology. |
int |
getSeqNum(DocId did)
Get the sequence number for giving Document |
void |
getSourceNum()
Get the maximum source sequence number in the databade. |
java.lang.String |
getTableName(ObjectId id)
Get the table name for giving id. |
protected int |
getUrlIndex(java.lang.String url)
Get the index for given uri. |
java.lang.String |
getViewDefinition(java.lang.String vName)
Get sql definition for giving view name. |
ResultSet |
issueQuery(Query qry)
Execute query and return results. |
void |
open()
Open a connection to the database. |
void |
setImplictImports(boolean imp)
Set whether or not include implictly imported documents. |
void |
setQueryOntology(java.lang.String uri)
Set the query ontology. |
void |
updateDocument(Document d)
Update a document. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected int ontSeqNum
protected int sourceSeqNum
protected int maxUrlNum
protected java.util.Hashtable knownOntos
protected java.util.Hashtable knownDocs
protected java.util.Hashtable knownUrls
protected java.util.Hashtable propertyTypes
protected java.sql.Statement stmt
Constructor Detail |
---|
public DatabaseStorage(java.lang.String DBName)
DBName
- Method Detail |
---|
public void open()
open
in class PersistentStorageModel
public void close()
close
in class PersistentStorageModel
public void addDocument(Document d)
addDocument
in class StorageModel
public Document getDocument(java.lang.String url)
getDocument
in class StorageModel
public void updateDocument(Document d)
updateDocument
in class StorageModel
public java.util.Iterator getDocumentIterator()
getDocumentIterator
in class StorageModel
public void setImplictImports(boolean imp)
setImplictImports
in class StorageModel
public Ontology createOntology()
createOntology
in class StorageModel
public Document createDocument()
createDocument
in class StorageModel
public java.util.Hashtable getKnownOntologies()
public void getSourceNum()
public void createKb()
public java.lang.String getTableName(ObjectId id)
public java.util.Hashtable getKnownUrls()
protected int getUrlIndex(java.lang.String url)
public int getSeqNum(DocId did)
getSeqNum
in class StorageModel
public java.lang.String getViewDefinition(java.lang.String vName)
public int getOntSeq(java.lang.String ns)
public void forcedExit()
public ResultSet issueQuery(Query qry)
issueQuery
in interface QueryableStorageModel
public java.util.Hashtable getPropertyTypes()
public int decideCommitOnto(Document doc, ObjectId id)
public void setQueryOntology(java.lang.String uri)
public java.lang.String getQueryOntology()
public java.lang.String getDBName()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |