3using System.Threading.Tasks;
15 private int count = 0;
34 if (!(Source is
null))
36 if (this.first is
null)
39 this.sources.Add(Source);
51 if (!(Source is
null))
53 if (this.first is
null)
56 this.sources.Add(Source);
67 return this.CreateJoinedEnumerator();
74 IEnumerator IEnumerable.GetEnumerator()
76 return this.CreateJoinedEnumerator();
79 private IEnumerator<ISemanticTriple> CreateJoinedEnumerator()
83 foreach (ISemanticCube Source
in this.sources)
84 Enumerators.
Add(Source.GetEnumerator());
86 return new JoinedTripleEnumerator(Enumerators,
true);
96 if (this.first is
null)
119 if (this.first is
null)
142 if (this.first is
null)
166 if (this.first is
null)
190 if (this.first is
null)
214 if (this.first is
null)
238 if (this.first is
null)
262 if (this.first is
null)
286 if (this.first is
null)
311 if (this.first is
null)
389 default:
return null;
404 if (Axis1Index == Axis2Index)
406 if (Value1.Equals(Value2))
407 return await this.
GetTriples(Value1, Axis1Index);
In-memory semantic plane.
Enumerator of elements from a collection of semantic data sources. The enumerator can remove duplicat...
async Task< ISemanticLine > GetTriplesBySubjectAndPredicate(ISemanticElement Subject, ISemanticElement Predicate)
Gets available triples in the cube, having a given subject and predicate.
async Task< IEnumerable< ISemanticTriple > > GetTriples(ISemanticElement Value1, int Axis1Index, ISemanticElement Value2, int Axis2Index)
Gets available triples in the cube, having two given values, along two given axes.
async Task< IEnumerable< ISemanticTriple > > GetTriples(ISemanticElement Value, int AxisIndex)
Gets available triples in the cube, having a given value, along a given axis.
async Task< ISemanticLine > GetTriplesByPredicateAndObject(ISemanticElement Predicate, ISemanticElement Object)
Gets available triples in the cube, having a given predicate and object.
async Task< ISemanticLine > GetTriplesBySubjectAndObject(ISemanticElement Subject, ISemanticElement Object)
Gets available triples in the cube, having a given subject and object.
async Task< ISemanticLine > GetTriplesByPredicateAndSubject(ISemanticElement Predicate, ISemanticElement Subject)
Gets available triples in the cube, having a given predicate and subject.
void Add(ISemanticCube Source)
Adds a source to the data set.
async Task< ISemanticLine > GetTriplesByObjectAndPredicate(ISemanticElement Object, ISemanticElement Predicate)
Gets available triples in the cube, having a given object and predicate.
async Task< IEnumerator< ISemanticElement > > GetPredicateEnumerator()
Gets an enumerator of all predicates.
async Task< ISemanticPlane > GetTriplesBySubject(ISemanticElement Subject)
Gets available triples in the cube, having a given subject.
async Task< ISemanticLine > GetTriplesByObjectAndSubject(ISemanticElement Object, ISemanticElement Subject)
Gets available triples in the cube, having a given object and subject.
async Task< ISemanticPlane > GetTriplesByPredicate(ISemanticElement Predicate)
Gets available triples in the cube, having a given predicate.
async Task< IEnumerator< ISemanticElement > > GetSubjectEnumerator()
Gets an enumerator of all subjects.
async Task< IEnumerable< ISemanticTriple > > GetTriplesBySubjectAndPredicateAndObject(ISemanticElement Subject, ISemanticElement Predicate, ISemanticElement Object)
Gets available triples in the cube, having a given subject, predicate and object.
IEnumerator< ISemanticTriple > GetEnumerator()
Gets an enumerator of available data sources.
SemanticDataSet(params ISemanticCube[] Sources)
In-memory semantic cube.
async Task< IEnumerator< ISemanticElement > > GetObjectEnumerator()
Gets an enumerator of all objects.
SemanticDataSet(IEnumerable< ISemanticCube > Sources)
In-memory semantic cube.
async Task< ISemanticPlane > GetTriplesByObject(ISemanticElement Object)
Gets available triples in the cube, having a given object.
A chunked list is a linked list of chunks of objects of type T .
void Add(T Item)
Adds an item to the collection.
Interface for semantic cubes.
Task< IEnumerator< ISemanticElement > > GetObjectEnumerator()
Gets an enumerator of all objects.
Task< ISemanticLine > GetTriplesByPredicateAndSubject(ISemanticElement Predicate, ISemanticElement Subject)
Gets available triples in the cube, having a given predicate and subject.
Task< IEnumerable< ISemanticTriple > > GetTriplesBySubjectAndPredicateAndObject(ISemanticElement Subject, ISemanticElement Predicate, ISemanticElement Object)
Gets available triples in the cube, having a given subject, predicate and object.
Task< ISemanticLine > GetTriplesBySubjectAndObject(ISemanticElement Subject, ISemanticElement Object)
Gets available triples in the cube, having a given subject and object.
Task< ISemanticLine > GetTriplesByObjectAndSubject(ISemanticElement Object, ISemanticElement Subject)
Gets available triples in the cube, having a given object and subject.
Task< ISemanticPlane > GetTriplesBySubject(ISemanticElement Subject)
Gets available triples in the cube, having a given subject.
Task< ISemanticLine > GetTriplesBySubjectAndPredicate(ISemanticElement Subject, ISemanticElement Predicate)
Gets available triples in the cube, having a given subject and predicate.
Task< IEnumerator< ISemanticElement > > GetPredicateEnumerator()
Gets an enumerator of all predicates.
Task< IEnumerator< ISemanticElement > > GetSubjectEnumerator()
Gets an enumerator of all subjects.
Task< ISemanticPlane > GetTriplesByPredicate(ISemanticElement Predicate)
Gets available triples in the cube, having a given predicate.
Task< ISemanticPlane > GetTriplesByObject(ISemanticElement Object)
Gets available triples in the cube, having a given object.
Task< ISemanticLine > GetTriplesByObjectAndPredicate(ISemanticElement Object, ISemanticElement Predicate)
Gets available triples in the cube, having a given object and predicate.
Task< ISemanticLine > GetTriplesByPredicateAndObject(ISemanticElement Predicate, ISemanticElement Object)
Gets available triples in the cube, having a given predicate and object.
Interface for semantic nodes.
Interface for semantic triples.