Show / Hide Table of Contents

Class BaseGraphCollection

Abstract Base Class for Graph Collections.
Inheritance
System.Object
BaseGraphCollection
GraphCollection
DatasetGraphCollection
WrapperGraphCollection
Implements
System.Collections.Generic.IEnumerable<IGraph>
System.Collections.IEnumerable
System.IDisposable
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
Assembly: dotNetRDF.dll
Syntax
public abstract class BaseGraphCollection : IEnumerable<IGraph>, IEnumerable, IDisposable
Remarks
Designed to allow the underlying storage of a Graph Collection to be changed at a later date without affecting classes that use it.

Properties

| Improve this Doc View Source

Count

Gets the number of Graphs in the Collection.
Declaration
public abstract int Count { get; }
Property Value
Type Description
System.Int32
| Improve this Doc View Source

GraphUris

Provides access to the Graph URIs of Graphs in the Collection.
Declaration
public abstract IEnumerable<Uri> GraphUris { get; }
Property Value
Type Description
System.Collections.Generic.IEnumerable<System.Uri>
| Improve this Doc View Source

Item[Uri]

Gets a Graph from the Collection.
Declaration
public abstract IGraph this[Uri graphUri] { get; }
Parameters
Type Name Description
System.Uri graphUri Graph Uri.
Property Value
Type Description
IGraph
Remarks
The null URI is used to reference the Default Graph.

Methods

| Improve this Doc View Source

Add(IGraph, Boolean)

Adds a Graph to the Collection.
Declaration
protected abstract bool Add(IGraph g, bool mergeIfExists)
Parameters
Type Name Description
IGraph g Graph to add.
System.Boolean mergeIfExists Sets whether the Graph should be merged with an existing Graph of the same Uri if present.
Returns
Type Description
System.Boolean
| Improve this Doc View Source

Contains(Uri)

Checks whether the Graph with the given Uri exists in this Graph Collection.
Declaration
public abstract bool Contains(Uri graphUri)
Parameters
Type Name Description
System.Uri graphUri Graph Uri to test.
Returns
Type Description
System.Boolean
Remarks
The null URI is used to reference the Default Graph.
| Improve this Doc View Source

Dispose()

Disposes of the Graph Collection.
Declaration
public abstract void Dispose()
Remarks
Invokes the System.IDisposable.Dispose() method of all Graphs contained in the Collection.
| Improve this Doc View Source

GetEnumerator()

Gets the Enumerator for the Collection.
Declaration
public abstract IEnumerator<IGraph> GetEnumerator()
Returns
Type Description
System.Collections.Generic.IEnumerator<IGraph>
| Improve this Doc View Source

RaiseGraphAdded(IGraph)

Helper method which raises the GraphAdded event manually.
Declaration
protected virtual void RaiseGraphAdded(IGraph g)
Parameters
Type Name Description
IGraph g Graph.
| Improve this Doc View Source

RaiseGraphRemoved(IGraph)

Helper method which raises the GraphRemoved event manually.
Declaration
protected virtual void RaiseGraphRemoved(IGraph g)
Parameters
Type Name Description
IGraph g Graph.
| Improve this Doc View Source

Remove(Uri)

Removes a Graph from the Collection.
Declaration
protected abstract bool Remove(Uri graphUri)
Parameters
Type Name Description
System.Uri graphUri Uri of the Graph to remove.
Returns
Type Description
System.Boolean
Remarks
The null URI is used to reference the Default Graph.

Events

| Improve this Doc View Source

GraphAdded

Event which is raised when a Graph is added to the Collection
Declaration
public event GraphEventHandler GraphAdded
Event Type
Type Description
GraphEventHandler
| Improve this Doc View Source

GraphRemoved

Event which is raised when a Graph is removed from the Collection
Declaration
public event GraphEventHandler GraphRemoved
Event Type
Type Description
GraphEventHandler

Explicit Interface Implementations

| Improve this Doc View Source

IEnumerable.GetEnumerator()

Gets the Enumerator for this Collection.
Declaration
IEnumerator IEnumerable.GetEnumerator()
Returns
Type Description
System.Collections.IEnumerator

Implements

System.Collections.Generic.IEnumerable<T>
System.Collections.IEnumerable
System.IDisposable

Extension Methods

Extensions.AsEnumerable<T>(T)
Extensions.IsDisjoint<T>(IEnumerable<T>, IEnumerable<T>)
Extensions.ChunkBy<T>(IEnumerable<T>, Int32)
  • Improve this Doc
  • View Source
In This Article
  • Properties
    • Count
    • GraphUris
    • Item[Uri]
  • Methods
    • Add(IGraph, Boolean)
    • Contains(Uri)
    • Dispose()
    • GetEnumerator()
    • RaiseGraphAdded(IGraph)
    • RaiseGraphRemoved(IGraph)
    • Remove(Uri)
  • Events
    • GraphAdded
    • GraphRemoved
  • Explicit Interface Implementations
    • IEnumerable.GetEnumerator()
  • Implements
  • Extension Methods
Back to top Generated by DocFX