[−][src]Trait sophia::graph::Graph
Generic trait for RDF graphs.
For convenience, this trait is implemented by standard collections of triples.
NB: the semantics of this trait allows a graph to contain duplicate triples;
see also SetGraph
.
Associated Types
type Triple: TripleStreamingMode
Determine the type of Triple
s
that the methods of this graph will yield
(see streaming_mode
type Error: 'static + Error
The error type that this graph may raise.
Required methods
fn triples(
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, Self::Triple>, Self::Error>>>
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, Self::Triple>, Self::Error>>>
An iterator visiting all triples of this graph in arbitrary order.
This iterator is fallible:
its items are Result
s,
an error may occur at any time during the iteration.
Examples
The result of this method is an iterator,
so it can be used in a for
loop:
for t in graph.triples() { let t = t?; // rethrow error if any // do something with t }
Another way is to use the specific methods provided by
TripleSource
,
for example:
graph.triples().for_each_triple(|t| { // do something with t })?; // rethrow error if any
Provided methods
fn triples_with_s<TS>(
&'s self,
s: &'s TS
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TS: TTerm + ?Sized,
&'s self,
s: &'s TS
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TS: TTerm + ?Sized,
An iterator visiting all triples with the given subject.
See also triples
.
fn triples_with_p<TP>(
&'s self,
p: &'s TP
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TP: TTerm + ?Sized,
&'s self,
p: &'s TP
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TP: TTerm + ?Sized,
An iterator visiting all triples with the given predicate.
See also triples
.
fn triples_with_o<TO>(
&'s self,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TO: TTerm + ?Sized,
&'s self,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TO: TTerm + ?Sized,
An iterator visiting all triples with the given object.
See also triples
.
fn triples_with_sp<TS, TP>(
&'s self,
s: &'s TS,
p: &'s TP
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
&'s self,
s: &'s TS,
p: &'s TP
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
An iterator visiting all triples with the given subject and predicate.
See also triples
.
fn triples_with_so<TS, TO>(
&'s self,
s: &'s TS,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TO: TTerm + ?Sized,
TS: TTerm + ?Sized,
&'s self,
s: &'s TS,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TO: TTerm + ?Sized,
TS: TTerm + ?Sized,
An iterator visiting all triples with the given subject and object.
See also triples
.
fn triples_with_po<TP, TO>(
&'s self,
p: &'s TP,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
&'s self,
p: &'s TP,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
An iterator visiting all triples with the given predicate and object.
See also triples
.
fn triples_with_spo<TS, TP, TO>(
&'s self,
s: &'s TS,
p: &'s TP,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
&'s self,
s: &'s TS,
p: &'s TP,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
An iterator visiting all triples with the given subject, predicate and object.
See also triples
.
fn contains<TS, TP, TO>(
&self,
s: &TS,
p: &TP,
o: &TO
) -> Result<bool, Self::Error> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
&self,
s: &TS,
p: &TP,
o: &TO
) -> Result<bool, Self::Error> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
Return true
if this graph contains the given triple.
fn triples_matching<S, P, O>(
&'s self,
ms: &'s S,
mp: &'s P,
mo: &'s O
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
O: TermMatcher + ?Sized,
P: TermMatcher + ?Sized,
S: TermMatcher + ?Sized,
&'s self,
ms: &'s S,
mp: &'s P,
mo: &'s O
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, Self::Triple>, Self::Error>> + 's> where
O: TermMatcher + ?Sized,
P: TermMatcher + ?Sized,
S: TermMatcher + ?Sized,
An iterator visiting all triples matching the given subject, predicate and object.
See also triples
.
Usage
Term references or arrays of term references are typically used as term matchers.
The special ANY
matcher can also be used to match anything.
use sophia_api::term::matcher::ANY; let s = Namespace::new("http://schema.org/")?; let city = s.get("City")?; let country = s.get("Country")?; for t in graph.triples_matching(&ANY, &rdf::type_, &[&city, &country]) { println!("{} was found", t?.s()); }
Closures (accepting &dyn TTerm
) can also be used, but notice that,
for technical reasons, they must be enclosed in a 1-sized array.
use sophia_api::term::matcher::ANY; for t in graph.triples_matching( &ANY, &rdfs::label, &[|t: &dyn TTerm| t.kind() == Literal && t.value().contains("needle")] ) { println!("{} was found", t?.s()); }
fn subjects(
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
Build a Hashset of all the terms used as subject in this Graph.
fn predicates(
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
Build a Hashset of all the terms used as predicate in this Graph.
fn objects(
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
Build a Hashset of all the terms used as object in this Graph.
fn iris(
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
Build a Hashset of all the IRIs used in this Graph.
fn bnodes(
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
Build a Hashset of all the BNodes used in this Graph.
fn literals(
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
Build a Hashset of all the Literals used in this Graph.
fn variables(
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
&self
) -> Result<HashSet<<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term, RandomState>, Self::Error> where
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Clone,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Eq,
<<Self::Triple as TripleStreamingMode>::UnsafeTriple as UnsafeTriple>::Term: Hash,
Build a Hashset of all the variables used in this Graph.
fn as_dataset(&self) -> GraphAsDataset<Self, &Self>
Dataset
adapter borrowing this graph
fn as_dataset_mut(&mut self) -> GraphAsDataset<Self, &mut Self>
Dataset
adapter borrowing this graph mutably
fn into_dataset(self) -> GraphAsDataset<Self, Self>
Dataset
adapter taking ownership of this graph
Implementations on Foreign Types
impl<T> Graph for Vec<T> where
T: Triple,
[src]
T: Triple,
type Triple = ByRef<T>
type Error = Infallible
fn triples(
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, <Vec<T> as Graph>::Triple>, <Vec<T> as Graph>::Error>>>
[src]
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, <Vec<T> as Graph>::Triple>, <Vec<T> as Graph>::Error>>>
impl<T> Graph for [T] where
T: Triple,
[src]
T: Triple,
type Triple = ByRef<T>
type Error = Infallible
fn triples(
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, <[T] as Graph>::Triple>, <[T] as Graph>::Error>>>
[src]
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, <[T] as Graph>::Triple>, <[T] as Graph>::Error>>>
impl<T, BH> Graph for HashSet<T, BH> where
BH: BuildHasher,
T: Eq + Hash + Triple,
[src]
BH: BuildHasher,
T: Eq + Hash + Triple,
type Triple = ByRef<T>
type Error = Infallible
fn triples(
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, <HashSet<T, BH> as Graph>::Triple>, <HashSet<T, BH> as Graph>::Error>>>
[src]
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, <HashSet<T, BH> as Graph>::Triple>, <HashSet<T, BH> as Graph>::Error>>>
Implementors
impl<D, E, M> Graph for DatasetGraph<D, E, M> where
D: Dataset + ?Sized,
E: Borrow<D>,
M: GraphNameMatcher,
[src]
D: Dataset + ?Sized,
E: Borrow<D>,
M: GraphNameMatcher,
type Triple = FromQuad<<D as Dataset>::Quad>
type Error = <D as Dataset>::Error
fn triples(
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>>>
[src]
&self
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'_, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>>>
fn triples_with_s<TS>(
&'s self,
s: &'s TS
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TS: TTerm + ?Sized,
[src]
&'s self,
s: &'s TS
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TS: TTerm + ?Sized,
fn triples_with_p<TP>(
&'s self,
p: &'s TP
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TP: TTerm + ?Sized,
[src]
&'s self,
p: &'s TP
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TP: TTerm + ?Sized,
fn triples_with_o<TO>(
&'s self,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TO: TTerm + ?Sized,
[src]
&'s self,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TO: TTerm + ?Sized,
fn triples_with_sp<TS, TP>(
&'s self,
s: &'s TS,
p: &'s TP
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
[src]
&'s self,
s: &'s TS,
p: &'s TP
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
fn triples_with_so<TS, TO>(
&'s self,
s: &'s TS,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TO: TTerm + ?Sized,
TS: TTerm + ?Sized,
[src]
&'s self,
s: &'s TS,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TO: TTerm + ?Sized,
TS: TTerm + ?Sized,
fn triples_with_po<TP, TO>(
&'s self,
p: &'s TP,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
[src]
&'s self,
p: &'s TP,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
fn triples_with_spo<TS, TP, TO>(
&'s self,
s: &'s TS,
p: &'s TP,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
[src]
&'s self,
s: &'s TS,
p: &'s TP,
o: &'s TO
) -> Box<dyn Iterator<Item = Result<StreamedTriple<'s, <DatasetGraph<D, E, M> as Graph>::Triple>, <DatasetGraph<D, E, M> as Graph>::Error>> + 's> where
TO: TTerm + ?Sized,
TP: TTerm + ?Sized,
TS: TTerm + ?Sized,
impl<I> Graph for HashGraph<I> where
I: TermIndexMap,
I::Index: Hash,
<I::Factory as TermFactory>::TermData: 'static,
[src]
I: TermIndexMap,
I::Index: Hash,
<I::Factory as TermFactory>::TermData: 'static,
type Triple = ByTermRefs<Term<Self::TermData>>
type Error = Infallible
fn triples(&self) -> GTripleSource<'_, Self>
[src]
impl<T> Graph for OpsWrapper<T> where
T: IndexedGraph + Graph<Triple = ByTermRefs<Term<<T as IndexedGraph>::TermData>>>,
[src]
T: IndexedGraph + Graph<Triple = ByTermRefs<Term<<T as IndexedGraph>::TermData>>>,
type Triple = <Self::Wrapped as Graph>::Triple
type Error = <Self::Wrapped as Graph>::Error
fn triples(&self) -> GTripleSource<'_, Self>
[src]
fn triples_with_s<'s_, TS_: ?Sized>(
&'s_ self,
s: &'s_ TS_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
[src]
&'s_ self,
s: &'s_ TS_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
fn triples_with_p<'s_, TP_: ?Sized>(
&'s_ self,
p: &'s_ TP_
) -> GTripleSource<'s_, Self> where
TP_: TTerm,
[src]
&'s_ self,
p: &'s_ TP_
) -> GTripleSource<'s_, Self> where
TP_: TTerm,
fn triples_with_o<'s_, TO_: ?Sized>(
&'s_ self,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TO_: TTerm,
[src]
&'s_ self,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TO_: TTerm,
fn triples_with_sp<'s_, TS_: ?Sized, TP_: ?Sized>(
&'s_ self,
s: &'s_ TS_,
p: &'s_ TP_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TP_: TTerm,
[src]
&'s_ self,
s: &'s_ TS_,
p: &'s_ TP_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TP_: TTerm,
fn triples_with_so<'s_, TS_: ?Sized, TO_: ?Sized>(
&'s_ self,
s: &'s_ TS_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TO_: TTerm,
[src]
&'s_ self,
s: &'s_ TS_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TO_: TTerm,
fn triples_with_po<'s_, TP_: ?Sized, TO_: ?Sized>(
&'s_ self,
p: &'s_ TP_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TP_: TTerm,
TO_: TTerm,
[src]
&'s_ self,
p: &'s_ TP_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TP_: TTerm,
TO_: TTerm,
fn triples_with_spo<'s_, TS_: ?Sized, TP_: ?Sized, TO_: ?Sized>(
&'s_ self,
s: &'s_ TS_,
p: &'s_ TP_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TP_: TTerm,
TO_: TTerm,
[src]
&'s_ self,
s: &'s_ TS_,
p: &'s_ TP_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TP_: TTerm,
TO_: TTerm,
fn contains<TS_: ?Sized, TP_: ?Sized, TO_: ?Sized>(
&self,
s: &TS_,
p: &TP_,
o: &TO_
) -> GResult<Self, bool> where
TS_: TTerm,
TP_: TTerm,
TO_: TTerm,
[src]
&self,
s: &TS_,
p: &TP_,
o: &TO_
) -> GResult<Self, bool> where
TS_: TTerm,
TP_: TTerm,
TO_: TTerm,
fn subjects(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn predicates(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn objects(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn iris(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn bnodes(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn literals(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn variables(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
impl<T> Graph for SpoWrapper<T> where
T: IndexedGraph + Graph<Triple = ByTermRefs<Term<<T as IndexedGraph>::TermData>>>,
[src]
T: IndexedGraph + Graph<Triple = ByTermRefs<Term<<T as IndexedGraph>::TermData>>>,
type Triple = <Self::Wrapped as Graph>::Triple
type Error = <Self::Wrapped as Graph>::Error
fn triples(&self) -> GTripleSource<'_, Self>
[src]
fn triples_with_s<'s_, TS_: ?Sized>(
&'s_ self,
s: &'s_ TS_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
[src]
&'s_ self,
s: &'s_ TS_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
fn triples_with_p<'s_, TP_: ?Sized>(
&'s_ self,
p: &'s_ TP_
) -> GTripleSource<'s_, Self> where
TP_: TTerm,
[src]
&'s_ self,
p: &'s_ TP_
) -> GTripleSource<'s_, Self> where
TP_: TTerm,
fn triples_with_o<'s_, TO_: ?Sized>(
&'s_ self,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TO_: TTerm,
[src]
&'s_ self,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TO_: TTerm,
fn triples_with_sp<'s_, TS_: ?Sized, TP_: ?Sized>(
&'s_ self,
s: &'s_ TS_,
p: &'s_ TP_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TP_: TTerm,
[src]
&'s_ self,
s: &'s_ TS_,
p: &'s_ TP_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TP_: TTerm,
fn triples_with_so<'s_, TS_: ?Sized, TO_: ?Sized>(
&'s_ self,
s: &'s_ TS_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TO_: TTerm,
[src]
&'s_ self,
s: &'s_ TS_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TO_: TTerm,
fn triples_with_po<'s_, TP_: ?Sized, TO_: ?Sized>(
&'s_ self,
p: &'s_ TP_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TP_: TTerm,
TO_: TTerm,
[src]
&'s_ self,
p: &'s_ TP_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TP_: TTerm,
TO_: TTerm,
fn triples_with_spo<'s_, TS_: ?Sized, TP_: ?Sized, TO_: ?Sized>(
&'s_ self,
s: &'s_ TS_,
p: &'s_ TP_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TP_: TTerm,
TO_: TTerm,
[src]
&'s_ self,
s: &'s_ TS_,
p: &'s_ TP_,
o: &'s_ TO_
) -> GTripleSource<'s_, Self> where
TS_: TTerm,
TP_: TTerm,
TO_: TTerm,
fn contains<TS_: ?Sized, TP_: ?Sized, TO_: ?Sized>(
&self,
s: &TS_,
p: &TP_,
o: &TO_
) -> GResult<Self, bool> where
TS_: TTerm,
TP_: TTerm,
TO_: TTerm,
[src]
&self,
s: &TS_,
p: &TP_,
o: &TO_
) -> GResult<Self, bool> where
TS_: TTerm,
TP_: TTerm,
TO_: TTerm,
fn subjects(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn predicates(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn objects(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn iris(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn bnodes(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn literals(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,
fn variables(&self) -> GResult<Self, HashSet<GTerm<Self>>> where
GTerm<Self>: Clone + Eq + Hash,
[src]
GTerm<Self>: Clone + Eq + Hash,