public class DatasetGraphMonitor extends DatasetGraphWrapper
| Constructor and Description |
|---|
DatasetGraphMonitor(DatasetGraph dsg,
DatasetChanges monitor)
Create a DatasetGraph wrapper that monitors the dataset for changes (add or delete quads).
|
DatasetGraphMonitor(DatasetGraph dsg,
DatasetChanges monitor,
boolean recordOnlyIfRealChange)
Create a DatasetGraph wrapper that monitors the dataset for changes (add or delete quads).
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(Node g,
Node s,
Node p,
Node o)
Add a quad
|
void |
add(Quad quad)
Add a quad
|
void |
addGraph(Node gn,
Graph g)
Add the given graph to the dataset.
|
void |
delete(Node g,
Node s,
Node p,
Node o)
Delete a quad
|
void |
delete(Quad quad)
Delete a quad
|
void |
deleteAny(Node g,
Node s,
Node p,
Node o)
Delete any quads matching the pattern
|
DatasetChanges |
getMonitor()
Return the monitor
|
DatasetGraph |
monitored()
Return the monitored DatasetGraph
|
void |
removeGraph(Node gn)
Remove all data associated with the named graph
|
void |
sync() |
clear, close, contains, contains, containsGraph, find, find, find, findNG, getContext, getDefaultGraph, getGraph, getLock, getWrapped, isEmpty, listGraphNodes, setDefaultGraph, size, toStringpublic DatasetGraphMonitor(DatasetGraph dsg, DatasetChanges monitor)
dsg - The DatasetGraph to monitormonitor - The handler for a changeDatasetChanges,
QuadActionpublic DatasetGraphMonitor(DatasetGraph dsg, DatasetChanges monitor, boolean recordOnlyIfRealChange)
dsg - The DatasetGraph to monitormonitor - The handler for a changerecordOnlyIfRealChange - If true, check to see if the chnage would have an effect (e.g. add is a new quad).
If false, log changes as ADD/DELETE regardless of whether the dataset actually changes.DatasetChanges,
QuadActionpublic DatasetChanges getMonitor()
public DatasetGraph monitored()
public void add(Quad quad)
DatasetGraphadd in interface DatasetGraphadd in class DatasetGraphWrapperpublic void add(Node g, Node s, Node p, Node o)
DatasetGraphadd in interface DatasetGraphadd in class DatasetGraphWrapperpublic void delete(Quad quad)
DatasetGraphdelete in interface DatasetGraphdelete in class DatasetGraphWrapperpublic void delete(Node g, Node s, Node p, Node o)
DatasetGraphdelete in interface DatasetGraphdelete in class DatasetGraphWrapperpublic void deleteAny(Node g, Node s, Node p, Node o)
DatasetGraphdeleteAny in interface DatasetGraphdeleteAny in class DatasetGraphWrapperpublic void addGraph(Node gn, Graph g)
DatasetGraphDatasetGraph.getGraph(com.hp.hpl.jena.graph.Node)addGraph in interface DatasetGraphaddGraph in class DatasetGraphWrapperpublic void removeGraph(Node gn)
DatasetGraphremoveGraph in interface DatasetGraphremoveGraph in class DatasetGraphWrapperpublic void sync()
sync in interface Syncsync in class DatasetGraphWrapperLicenced under the Apache License, Version 2.0