Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

nl.aidministrator.rdf.sail
Interface RdfRepository  view RdfRepository download RdfRepository.java

All Superinterfaces:
RdfSource, Sail
All Known Subinterfaces:
RdfSchemaRepository

public interface RdfRepository
extends RdfSource

An extension of the read-only RdfSource interface that adds methods to add data to, and remove data from RDF repositories.

Version:
1.3, 02/07/02

Method Summary
 void addStatement(nl.aidministrator.rdf.sail.model.Resource subj, nl.aidministrator.rdf.sail.model.Resource pred, nl.aidministrator.rdf.sail.model.Value obj)
          Adds a statament to the repository.
 void changeNamespacePrefix(java.lang.String namespace, java.lang.String prefix)
          Changes the prefix of a namespace.
 void clearRepository()
          Clears the repository.
 void commitTransaction()
          Commits a started transaction.
 int removeStatements(nl.aidministrator.rdf.sail.model.Resource subj, nl.aidministrator.rdf.sail.model.Resource pred, nl.aidministrator.rdf.sail.model.Value obj)
          Removes data statements that match the (subject, predicate, object) pattern from the repository.
 void startTransaction()
          Starts a transaction.
 boolean transactionStarted()
          Checks whether a transaction has been started.
 
Methods inherited from interface nl.aidministrator.rdf.sail.RdfSource
getNamespaces, getStatements, hasStatement
 
Methods inherited from interface nl.aidministrator.rdf.sail.Sail
initialize, shutDown
 

Method Detail

startTransaction

public void startTransaction()
Starts a transaction. A transaction needs to be started before data can be added to or removed from the repository.


commitTransaction

public void commitTransaction()
Commits a started transaction. A transaction needs to be commited to be guaranteed that data has been added to, or removed from the repository.


transactionStarted

public boolean transactionStarted()
Checks whether a transaction has been started.


addStatement

public void addStatement(nl.aidministrator.rdf.sail.model.Resource subj,
                         nl.aidministrator.rdf.sail.model.Resource pred,
                         nl.aidministrator.rdf.sail.model.Value obj)
                  throws SailUpdateException
Adds a statament to the repository. You must start a transaction before this method can be used.


removeStatements

public int removeStatements(nl.aidministrator.rdf.sail.model.Resource subj,
                            nl.aidministrator.rdf.sail.model.Resource pred,
                            nl.aidministrator.rdf.sail.model.Value obj)
                     throws SailUpdateException
Removes data statements that match the (subject, predicate, object) pattern from the repository. All three parameters may be null to indicate wildcards. You must start a transaction before this method can be used.


clearRepository

public void clearRepository()
Clears the repository. After the repository was cleared, it will be in the same state as after initialization.


changeNamespacePrefix

public void changeNamespacePrefix(java.lang.String namespace,
                                  java.lang.String prefix)
                           throws SailUpdateException
Changes the prefix of a namespace. The new prefix must be unique in the repository; it is not allowed to be associated with any other namespace.