Class WrapperDataset
An abstract dataset wrapper that can be used to wrap another dataset and just modify some functionality i.e. provides a decorator over an existing dataset.
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: VDS.RDF.Query.Datasets
Assembly: dotNetRDF.dll
Syntax
public abstract class WrapperDataset : IConfigurationSerializable, IThreadSafeDataset, ISparqlDataset
Constructors
| Improve this Doc View SourceWrapperDataset(ISparqlDataset)
Creates a new wrapped dataset.
Declaration
public WrapperDataset(ISparqlDataset dataset)
Parameters
Type | Name | Description |
---|---|---|
ISparqlDataset | dataset | Dataset. |
Fields
| Improve this Doc View Source_dataset
Underlying Dataset.
Declaration
protected ISparqlDataset _dataset
Field Value
Type | Description |
---|---|
ISparqlDataset |
Properties
| Improve this Doc View SourceActiveGraphUris
Gets the Active Graph URIs.
Declaration
public virtual IEnumerable<Uri> ActiveGraphUris { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.Uri> |
DefaultGraphUris
Gets the Default Graph URIs.
Declaration
public virtual IEnumerable<Uri> DefaultGraphUris { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.Uri> |
Graphs
Gets the Graphs in the dataset.
Declaration
public virtual IEnumerable<IGraph> Graphs { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<IGraph> |
GraphUris
Gets the URIs of Graphs in the dataset.
Declaration
public virtual IEnumerable<Uri> GraphUris { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.Uri> |
HasTriples
Gets whether the dataset has any triples.
Declaration
public virtual bool HasTriples { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Item[Uri]
Gets a Graph from the dataset.
Declaration
public virtual IGraph this[Uri graphUri] { get; }
Parameters
Type | Name | Description |
---|---|---|
System.Uri | graphUri | Graph URI. |
Property Value
Type | Description |
---|---|
IGraph |
Lock
Gets the Lock used to ensure MRSW concurrency on the dataset when available.
Declaration
public ReaderWriterLockSlim Lock { get; }
Property Value
Type | Description |
---|---|
System.Threading.ReaderWriterLockSlim |
Triples
Gets all triples from the dataset.
Declaration
public virtual IEnumerable<Triple> Triples { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<Triple> |
UnderlyingDataset
Gets the underlying dataset.
Declaration
public ISparqlDataset UnderlyingDataset { get; }
Property Value
Type | Description |
---|---|
ISparqlDataset |
UsesUnionDefaultGraph
Gets whether the default graph is the union of all graphs.
Declaration
public virtual bool UsesUnionDefaultGraph { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
| Improve this Doc View SourceAddGraph(IGraph)
Adds a Graph to the dataset.
Declaration
public virtual bool AddGraph(IGraph g)
Parameters
Type | Name | Description |
---|---|---|
IGraph | g | Graph. |
Returns
Type | Description |
---|---|
System.Boolean |
ContainsTriple(Triple)
Gets whether the dataset contains a given triple.
Declaration
public virtual bool ContainsTriple(Triple t)
Parameters
Type | Name | Description |
---|---|---|
Triple | t | Triple. |
Returns
Type | Description |
---|---|
System.Boolean |
Discard()
Discards any changes to the dataset.
Declaration
public virtual void Discard()
Flush()
Flushes any changes to the dataset.
Declaration
public virtual void Flush()
GetModifiableGraph(Uri)
Gets a modifiable graph from the dataset.
Declaration
public virtual IGraph GetModifiableGraph(Uri graphUri)
Parameters
Type | Name | Description |
---|---|---|
System.Uri | graphUri | Graph URI. |
Returns
Type | Description |
---|---|
IGraph |
GetTriplesWithObject(INode)
Gets triples with a given object.
Declaration
public virtual IEnumerable<Triple> GetTriplesWithObject(INode obj)
Parameters
Type | Name | Description |
---|---|---|
INode | obj | Object. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<Triple> |
GetTriplesWithPredicate(INode)
Gets triples with a given predicate.
Declaration
public virtual IEnumerable<Triple> GetTriplesWithPredicate(INode pred)
Parameters
Type | Name | Description |
---|---|---|
INode | pred | Predicate. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<Triple> |
GetTriplesWithPredicateObject(INode, INode)
Gets triples with a given predicate and object.
Declaration
public virtual IEnumerable<Triple> GetTriplesWithPredicateObject(INode pred, INode obj)
Parameters
Type | Name | Description |
---|---|---|
INode | pred | Predicate. |
INode | obj | Object. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<Triple> |
GetTriplesWithSubject(INode)
Gets triples with a given subject.
Declaration
public virtual IEnumerable<Triple> GetTriplesWithSubject(INode subj)
Parameters
Type | Name | Description |
---|---|---|
INode | subj | Subject. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<Triple> |
GetTriplesWithSubjectObject(INode, INode)
Gets triples with a given subject and object.
Declaration
public virtual IEnumerable<Triple> GetTriplesWithSubjectObject(INode subj, INode obj)
Parameters
Type | Name | Description |
---|---|---|
INode | subj | Subject. |
INode | obj | Object. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<Triple> |
GetTriplesWithSubjectPredicate(INode, INode)
Gets triples with a given subject and predicate.
Declaration
public virtual IEnumerable<Triple> GetTriplesWithSubjectPredicate(INode subj, INode pred)
Parameters
Type | Name | Description |
---|---|---|
INode | subj | Subject. |
INode | pred | Predicate. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<Triple> |
HasGraph(Uri)
Gets whether the dataset contains a given Graph.
Declaration
public virtual bool HasGraph(Uri graphUri)
Parameters
Type | Name | Description |
---|---|---|
System.Uri | graphUri | Graph URI. |
Returns
Type | Description |
---|---|
System.Boolean |
RemoveGraph(Uri)
Removes a Graph from the dataset.
Declaration
public virtual bool RemoveGraph(Uri graphUri)
Parameters
Type | Name | Description |
---|---|---|
System.Uri | graphUri | Graph URI. |
Returns
Type | Description |
---|---|
System.Boolean |
ResetActiveGraph()
Resets the Active Graph.
Declaration
public virtual void ResetActiveGraph()
ResetDefaultGraph()
Resets the Default Graph.
Declaration
public virtual void ResetDefaultGraph()
SerializeConfiguration(ConfigurationSerializationContext)
Serializes the Configuration of the Dataset.
Declaration
public virtual void SerializeConfiguration(ConfigurationSerializationContext context)
Parameters
Type | Name | Description |
---|---|---|
ConfigurationSerializationContext | context | Serialization Context. |
SetActiveGraph(IEnumerable<Uri>)
Sets the Active Graph for the dataset.
Declaration
public virtual void SetActiveGraph(IEnumerable<Uri> graphUris)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Uri> | graphUris | Graph URIs. |
SetActiveGraph(Uri)
Sets the Active Graph for the dataset.
Declaration
public virtual void SetActiveGraph(Uri graphUri)
Parameters
Type | Name | Description |
---|---|---|
System.Uri | graphUri | Graph URI. |
SetDefaultGraph(IEnumerable<Uri>)
Sets the Default Graph for the dataset.
Declaration
public virtual void SetDefaultGraph(IEnumerable<Uri> graphUris)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Uri> | graphUris | Graph URIs. |
SetDefaultGraph(Uri)
Sets the Default Graph for the dataset.
Declaration
public virtual void SetDefaultGraph(Uri graphUri)
Parameters
Type | Name | Description |
---|---|---|
System.Uri | graphUri | Graph URI. |