pub struct BTreeGraph<R = Term> { /* private fields */ }
Expand description
BTree-based RDF graph.
Implementations§
Source§impl<R> BTreeGraph<R>
impl<R> BTreeGraph<R>
Sourcepub fn resources(&self) -> Resources<'_, R> ⓘ
pub fn resources(&self) -> Resources<'_, R> ⓘ
Returns an iterator over the resources of the graph.
Sourcepub fn into_indexed(self) -> IndexedBTreeGraph<R>
pub fn into_indexed(self) -> IndexedBTreeGraph<R>
Indexes the triples to allow more operation on this graph, such as
pattern matching using the PatternMatchingGraph
trait.
Source§impl<R: Ord> BTreeGraph<R>
impl<R: Ord> BTreeGraph<R>
Sourcepub fn contains_resource(&self, resource: &R) -> bool
pub fn contains_resource(&self, resource: &R) -> bool
Checks if the provided resource appears in any triple in the graph.
Sourcepub fn contains(&self, triple: Triple<&R>) -> bool
pub fn contains(&self, triple: Triple<&R>) -> bool
Checks if the provided triple is in the graph.
Trait Implementations§
Source§impl<R: Clone> Clone for BTreeGraph<R>
impl<R: Clone> Clone for BTreeGraph<R>
Source§fn clone(&self) -> BTreeGraph<R>
fn clone(&self) -> BTreeGraph<R>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<R: Debug> Debug for BTreeGraph<R>
impl<R: Debug> Debug for BTreeGraph<R>
Source§impl<R> Default for BTreeGraph<R>
impl<R> Default for BTreeGraph<R>
Source§impl<R: Clone + Ord> Extend<Triple<R>> for BTreeGraph<R>
impl<R: Clone + Ord> Extend<Triple<R>> for BTreeGraph<R>
Source§fn extend<T: IntoIterator<Item = Triple<R>>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = Triple<R>>>(&mut self, iter: T)
Extends a collection with the contents of an iterator. Read more
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
🔬This is a nightly-only experimental API. (
extend_one
)Extends a collection with exactly one element.
Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
🔬This is a nightly-only experimental API. (
extend_one
)Reserves capacity in a collection for the given number of additional elements. Read more
Source§impl<R> From<BTreeGraph<R>> for IndexedBTreeGraph<R>
impl<R> From<BTreeGraph<R>> for IndexedBTreeGraph<R>
Source§fn from(value: BTreeGraph<R>) -> Self
fn from(value: BTreeGraph<R>) -> Self
Converts to this type from the input type.
Source§impl<R: Clone + Ord> FromIterator<Triple<R>> for BTreeGraph<R>
impl<R: Clone + Ord> FromIterator<Triple<R>> for BTreeGraph<R>
Source§impl<R: Hash> Hash for BTreeGraph<R>
impl<R: Hash> Hash for BTreeGraph<R>
Source§impl<'a, R> IntoIterator for &'a BTreeGraph<R>
impl<'a, R> IntoIterator for &'a BTreeGraph<R>
Source§impl<R: Clone> IntoIterator for BTreeGraph<R>
impl<R: Clone> IntoIterator for BTreeGraph<R>
Source§impl<R: Ord> Ord for BTreeGraph<R>
impl<R: Ord> Ord for BTreeGraph<R>
Source§impl<R: PartialEq> PartialEq for BTreeGraph<R>
impl<R: PartialEq> PartialEq for BTreeGraph<R>
Source§impl<R: PartialOrd> PartialOrd for BTreeGraph<R>
impl<R: PartialOrd> PartialOrd for BTreeGraph<R>
Source§impl<R: RdfDisplay> RdfDisplay for BTreeGraph<R>
impl<R: RdfDisplay> RdfDisplay for BTreeGraph<R>
Source§fn rdf_fmt(&self, f: &mut Formatter<'_>) -> Result
fn rdf_fmt(&self, f: &mut Formatter<'_>) -> Result
Formats the value using the given formatter.
Source§fn rdf_display(&self) -> RdfDisplayed<&Self>
fn rdf_display(&self) -> RdfDisplayed<&Self>
Prepare the value to be formatted as an RDF syntax element.
Source§impl<R> ResourceTraversableGraph for BTreeGraph<R>
impl<R> ResourceTraversableGraph for BTreeGraph<R>
type GraphResources<'a> = Resources<'a, R> where R: 'a
fn graph_resources(&self) -> Self::GraphResources<'_>
fn graph_resource_count(&self) -> usize
Source§impl<R> TraversableGraph for BTreeGraph<R>
impl<R> TraversableGraph for BTreeGraph<R>
impl<R: Eq> Eq for BTreeGraph<R>
Auto Trait Implementations§
impl<R> Freeze for BTreeGraph<R>
impl<R> RefUnwindSafe for BTreeGraph<R>where
R: RefUnwindSafe,
impl<R> Send for BTreeGraph<R>where
R: Send,
impl<R> Sync for BTreeGraph<R>where
R: Sync,
impl<R> Unpin for BTreeGraph<R>where
R: Unpin,
impl<R> UnwindSafe for BTreeGraph<R>where
R: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.Source§impl<D> FallibleDataset for Dwhere
D: Dataset,
impl<D> FallibleDataset for Dwhere
D: Dataset,
Source§impl<D> FallibleGraph for Dwhere
D: Graph,
impl<D> FallibleGraph for Dwhere
D: Graph,
Source§impl<D> FallibleGraphMut for Dwhere
D: GraphMut,
impl<D> FallibleGraphMut for Dwhere
D: GraphMut,
fn try_insert( &mut self, triple: Triple<<D as FallibleGraph>::Resource>, ) -> Result<(), <D as FallibleGraph>::Error>
Source§impl<D> FallibleTraversableDataset for Dwhere
D: TraversableDataset,
impl<D> FallibleTraversableDataset for Dwhere
D: TraversableDataset,
Source§type TryQuads<'a> = InfallibleIterator<<D as TraversableDataset>::Quads<'a>>
where
D: 'a
type TryQuads<'a> = InfallibleIterator<<D as TraversableDataset>::Quads<'a>> where D: 'a
Fallible quads iterator.
fn try_quads(&self) -> <D as FallibleTraversableDataset>::TryQuads<'_>
Source§impl<D> FallibleTraversableGraph for Dwhere
D: TraversableGraph,
impl<D> FallibleTraversableGraph for Dwhere
D: TraversableGraph,
type TryTriples<'a> = InfallibleIterator<<D as TraversableGraph>::Triples<'a>> where D: 'a
fn try_triples(&self) -> <D as FallibleTraversableGraph>::TryTriples<'_>
Source§impl<G> NamedGraphTraversableDataset for Gwhere
G: Graph,
impl<G> NamedGraphTraversableDataset for Gwhere
G: Graph,
type NamedGraphs<'a> = Empty<&'a <G as Dataset>::Resource> where G: 'a
fn named_graphs(&self) -> <G as NamedGraphTraversableDataset>::NamedGraphs<'_>
fn named_graph_count(&self) -> usize
Source§impl<G> ResourceTraversableDataset for Gwhere
G: ResourceTraversableGraph,
impl<G> ResourceTraversableDataset for Gwhere
G: ResourceTraversableGraph,
type Resources<'a> = <G as ResourceTraversableGraph>::GraphResources<'a> where G: 'a
fn resources(&self) -> <G as ResourceTraversableDataset>::Resources<'_>
fn resource_count(&self) -> usize
Source§impl<G> TraversableDataset for Gwhere
G: TraversableGraph,
impl<G> TraversableDataset for Gwhere
G: TraversableGraph,
Source§type Quads<'a> = TripleToQuadIterator<<G as TraversableGraph>::Triples<'a>, &'a <G as Graph>::Resource>
where
G: 'a
type Quads<'a> = TripleToQuadIterator<<G as TraversableGraph>::Triples<'a>, &'a <G as Graph>::Resource> where G: 'a
Quads iterator.
Source§fn quads(&self) -> <G as TraversableDataset>::Quads<'_>
fn quads(&self) -> <G as TraversableDataset>::Quads<'_>
Returns an iterator over the quads of the dataset.