Show / Hide Table of Contents

Class AbstractIndexedTripleCollection

An abstract base class for triple collections with a lookup index.

Inheritance
object
BaseTripleCollection
AbstractIndexedTripleCollection
SubTreeIndexedTripleCollection
TreeIndexedTripleCollection
Implements
IEnumerable<Triple>
IEnumerable
IDisposable
Inherited Members
BaseTripleCollection.this[Triple]
BaseTripleCollection.this[(INode s, INode p, INode o)]
BaseTripleCollection.ObjectNodes
BaseTripleCollection.PredicateNodes
BaseTripleCollection.SubjectNodes
BaseTripleCollection.QuotedObjectNodes
BaseTripleCollection.QuotedPredicateNodes
BaseTripleCollection.QuotedSubjectNodes
BaseTripleCollection.WithSubject(INode)
BaseTripleCollection.QuotedWithSubject(INode)
BaseTripleCollection.WithPredicate(INode)
BaseTripleCollection.QuotedWithPredicate(INode)
BaseTripleCollection.WithObject(INode)
BaseTripleCollection.QuotedWithObject(INode)
BaseTripleCollection.WithSubjectPredicate(INode, INode)
BaseTripleCollection.QuotedWithSubjectPredicate(INode, INode)
BaseTripleCollection.WithPredicateObject(INode, INode)
BaseTripleCollection.QuotedWithPredicateObject(INode, INode)
BaseTripleCollection.WithSubjectObject(INode, INode)
BaseTripleCollection.QuotedWithSubjectObject(INode, INode)
BaseTripleCollection.Dispose()
BaseTripleCollection.TripleAdded
BaseTripleCollection.TripleRemoved
BaseTripleCollection.RaiseTripleAdded(Triple)
BaseTripleCollection.RaiseTripleRemoved(Triple)
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: VDS.RDF
Assembly: dotNetRdf.dll
Syntax
public abstract class AbstractIndexedTripleCollection : BaseTripleCollection, IEnumerable<Triple>, IEnumerable, IDisposable

Fields

| Edit this page View Source

Triples

The triples asserted and quoted in the triple collection.

Declaration
protected readonly MultiDictionary<Triple, TripleRefs> Triples
Field Value
Type Description
MultiDictionary<Triple, TripleRefs>

Properties

| Edit this page View Source

Asserted

Gets the triples that are asserted in the collection.

Declaration
public override IEnumerable<Triple> Asserted { get; }
Property Value
Type Description
IEnumerable<Triple>
Overrides
BaseTripleCollection.Asserted
Remarks

This returns the same set of triples as the enumerator on this class, but as an IEnumerable<T> instance.

| Edit this page View Source

Count

Gets the number of asserted triples in the triple collection.

Declaration
public override int Count { get; }
Property Value
Type Description
int
Overrides
BaseTripleCollection.Count
| Edit this page View Source

Quoted

Gets the triples that are quoted in the collection.

Declaration
public override IEnumerable<Triple> Quoted { get; }
Property Value
Type Description
IEnumerable<Triple>
Overrides
BaseTripleCollection.Quoted
| Edit this page View Source

QuotedCount

Gets the number of quoted triples in the triple collection.

Declaration
public override int QuotedCount { get; }
Property Value
Type Description
int
Overrides
BaseTripleCollection.QuotedCount

Methods

| Edit this page View Source

Add(Triple)

Adds a Triple to the collection.

Declaration
protected override bool Add(Triple t)
Parameters
Type Name Description
Triple t

Triple.

Returns
Type Description
bool
Overrides
BaseTripleCollection.Add(Triple)
| Edit this page View Source

AddQuoted(ITripleNode)

Adds a quotation of a triple to the collection.

Declaration
protected void AddQuoted(ITripleNode tripleNode)
Parameters
Type Name Description
ITripleNode tripleNode

The triple node that quotes the triple to be added to the collection.

| Edit this page View Source

Contains(Triple)

Determines whether a given Triple is asserted in the Triple Collection.

Declaration
public override bool Contains(Triple t)
Parameters
Type Name Description
Triple t

The Triple to test.

Returns
Type Description
bool

True if the triple exists as an asserted triple in the collection.

Overrides
BaseTripleCollection.Contains(Triple)
| Edit this page View Source

ContainsQuoted(Triple)

Determines whether a given triple is quoted by a triple node of a triple in the collection.

Declaration
public override bool ContainsQuoted(Triple t)
Parameters
Type Name Description
Triple t

The triple to test.

Returns
Type Description
bool

True if the triple is quoted in the triple collection, false otherwise.

Overrides
BaseTripleCollection.ContainsQuoted(Triple)
| Edit this page View Source

Delete(Triple)

Deletes a triple from the collection.

Declaration
protected override bool Delete(Triple t)
Parameters
Type Name Description
Triple t

Triple.

Returns
Type Description
bool
Overrides
BaseTripleCollection.Delete(Triple)
| Edit this page View Source

GetEnumerator()

Gets the typed Enumerator for the Triple Collection.

Declaration
public override IEnumerator<Triple> GetEnumerator()
Returns
Type Description
IEnumerator<Triple>

An enumerator over the asserted triples in the triple collection.

Overrides
BaseTripleCollection.GetEnumerator()
| Edit this page View Source

IndexAsserted(Triple)

Override in derived classes to add an asserted triple to the index.

Declaration
protected abstract void IndexAsserted(Triple t)
Parameters
Type Name Description
Triple t

Triple to add.

| Edit this page View Source

IndexQuoted(Triple)

Override in derived classes to add a quoted triple to the index.

Declaration
protected abstract void IndexQuoted(Triple t)
Parameters
Type Name Description
Triple t

Triple to add.

| Edit this page View Source

RemoveQuoted(ITripleNode)

Removes a quote reference to a triple from the collection.

Declaration
protected void RemoveQuoted(ITripleNode tripleNode)
Parameters
Type Name Description
ITripleNode tripleNode

The node containing the triple to be 'unquoted'.

Remarks

This method decreases the quote reference count for the triple. If the reference count drops to 0, the triple is removed from the quoted triples index. If the reference count drops to 0 and the triple is not asserted in the graph, it will be removed from the collection count. If the triple itself quotes other triples, then this process is applied out recursively.

| Edit this page View Source

UnindexAsserted(Triple)

Override in derived classes to remove an asserted triple from the index.

Declaration
protected abstract void UnindexAsserted(Triple t)
Parameters
Type Name Description
Triple t

Triple to remove.

| Edit this page View Source

UnindexQuoted(Triple)

Override in derived classes to remove a quoted triple from the index.

Declaration
protected abstract void UnindexQuoted(Triple t)
Parameters
Type Name Description
Triple t

Implements

IEnumerable<T>
IEnumerable
IDisposable

Extension Methods

Extensions.ChunkBy<T>(IEnumerable<T>, int)
Extensions.IsDisjoint<T>(IEnumerable<T>, IEnumerable<T>)
Extensions.WithObject(IEnumerable<Triple>, INode)
Extensions.WithPredicate(IEnumerable<Triple>, INode)
Extensions.WithSubject(IEnumerable<Triple>, INode)
LiteralExtensions.ToTripleCollection(IEnumerable<Triple>, bool)
Extensions.ToSafeString(object)
Extensions.AsEnumerable<T>(T)
  • Edit this page
  • View Source
In this article
  • Fields
    • Triples
  • Properties
    • Asserted
    • Count
    • Quoted
    • QuotedCount
  • Methods
    • Add(Triple)
    • AddQuoted(ITripleNode)
    • Contains(Triple)
    • ContainsQuoted(Triple)
    • Delete(Triple)
    • GetEnumerator()
    • IndexAsserted(Triple)
    • IndexQuoted(Triple)
    • RemoveQuoted(ITripleNode)
    • UnindexAsserted(Triple)
    • UnindexQuoted(Triple)
  • Implements
  • Extension Methods
Back to top Generated by DocFX