public class NotifyingModelSetLayer extends DelegatingModelSet implements NotifyingModelSet
baseModelSet| Constructor and Description |
|---|
NotifyingModelSetLayer(ModelSet modelset) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addModel(Model model)
Adds a model to this ModelSet.
|
void |
addModelSetChangedListener(ModelChangedListener listener) |
void |
addModelSetChangedListener(ModelChangedListener listener,
QuadPattern pattern) |
void |
addStatement(Statement statement)
This method creates a Model named statement.getContextURI if needed.
|
Model |
getDefaultModel()
The default model is used when the ModelSet is loaded from a
serialisation that has no context.
|
Model |
getModel(URI contextURI)
Get the Model with the passed URI.
|
ClosableIterator<Model> |
getModels() |
void |
removeModelSetChangedListener(ModelChangedListener listener) |
void |
removeStatement(Statement statement)
Removes the statement (s,p,o) from a model named statement.getContext().
|
void |
update(DiffReader diff)
Apply the changes given by this diff
|
addModel, addModelSet, addReificationOf, addReificationOf, close, commit, containsModel, containsStatements, createBlankNode, createQuadPattern, createURI, deleteReification, findStatements, getAllReificationsOf, getDelegatedModelSet, getModelURIs, getNamespace, getNamespaces, getUnderlyingModelImplementation, getUnderlyingModelSetImplementation, hasReifications, isEmpty, isOpen, open, queryConstruct, querySelect, readFrom, readFrom, readFrom, readFrom, readFrom, readFrom, removeModel, removeNamespace, setAutocommit, setNamespace, size, sparqlAsk, sparqlConstruct, sparqlDescribe, sparqlSelect, writeTo, writeTo, writeTo, writeToaddAll, addStatement, contains, countStatements, createBlankNode, createDatatypeLiteral, createLanguageTagLiteral, createPlainLiteral, createStatement, createStatement, dump, findStatements, isLocked, isValidURI, iterator, lock, newRandomUniqueURI, removeAll, removeAll, removeStatement, removeStatements, removeStatements, serialize, unlockclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcreateStatement, dump, removeAllserializecontains, countStatements, findStatementsaddAll, addStatement, removeAll, removeStatement, removeStatements, removeStatementsiteratorforEach, spliteratorcreateBlankNode, createDatatypeLiteral, createLanguageTagLiteral, createPlainLiteral, createStatement, isValidURI, newRandomUniqueURIpublic NotifyingModelSetLayer(ModelSet modelset)
public void addModelSetChangedListener(ModelChangedListener listener)
addModelSetChangedListener in interface NotifyingModelSetpublic void addModelSetChangedListener(ModelChangedListener listener, QuadPattern pattern)
addModelSetChangedListener in interface NotifyingModelSetlistener - to be notified on matching eventspattern - all add or remove statement events matching the pattern
will be send to the listener. Updates are always send.public void removeModelSetChangedListener(ModelChangedListener listener)
removeModelSetChangedListener in interface NotifyingModelSetpublic boolean addModel(Model model)
ModelSetaddModel in interface ModelSetaddModel in class DelegatingModelSetpublic void addStatement(Statement statement) throws ModelRuntimeException
ModelSetAddRemoveaddStatement in interface ModelSetAddRemoveaddStatement in class DelegatingModelSetModelRuntimeException - if any internal (I/O related) exception occurspublic Model getDefaultModel()
ModelSetgetDefaultModel in interface ModelSetgetDefaultModel in class DelegatingModelSetpublic Model getModel(URI contextURI)
ModelSetModelSet.isOpen() is false.
Note that the returned model is tied to this ModelSet. Any
changes in the model will be reflected here, closing this ModelSet will
close the returned Model. To avoid side-effects, closing the returned
Model will NOT close this ModelSet. Closing the returned model will not
affect objects returned by previous calls to this method, hence this
method should always return a new copy of the Model object to allow
callers to close() a returned model.getModel in interface ModelSetgetModel in class DelegatingModelSetcontextURI - the URI of the context. This is the same as the name of
the named graph.public ClosableIterator<Model> getModels()
getModels in interface ModelSetgetModels in class DelegatingModelSetpublic void removeStatement(Statement statement) throws ModelRuntimeException
ModelSetAddRemoveremoveStatement in interface ModelSetAddRemoveremoveStatement in class DelegatingModelSetstatement - a StatementModelRuntimeException - if any internal (I/O related) exception occurspublic void update(DiffReader diff) throws ModelRuntimeException
ModelSetAddRemoveupdate in interface ModelSetAddRemoveupdate in class DelegatingModelSetModelRuntimeException - if the ModelSet is lockedCopyright © 2005–2016 IT-Consulting Dr. Max V?lkel | Project started at FZI Forschungszentrum Informatik, www.fzi.de. All rights reserved.