pub struct ListTriples<'a, T, B, L> { /* private fields */ }Expand description
Iterator over the RDF quads generated from a list of JSON-LD objects.
If the list contains nested lists, the iterator will also emit quads for those nested lists.
Implementations§
Source§impl<'a, T, B, L> ListTriples<'a, T, B, L>
impl<'a, T, B, L> ListTriples<'a, T, B, L>
Sourcepub fn new(list: &'a [IndexedObject<T, B>], head_ref: ValidId<T, B>) -> Self
pub fn new(list: &'a [IndexedObject<T, B>], head_ref: ValidId<T, B>) -> Self
Creates a new ListTriples.
Sourcepub fn with<'n, V: Vocabulary<Iri = T, BlankId = B, Literal = L>, G: LocalGenerator>(
self,
vocabulary: &'n mut V,
generator: G,
rdf_direction: Option<RdfDirection>,
) -> ListTriplesWith<'a, 'n, V, G> ⓘ
pub fn with<'n, V: Vocabulary<Iri = T, BlankId = B, Literal = L>, G: LocalGenerator>( self, vocabulary: &'n mut V, generator: G, rdf_direction: Option<RdfDirection>, ) -> ListTriplesWith<'a, 'n, V, G> ⓘ
Binds this iterator to a vocabulary and generator.
Sourcepub fn next<V, G: LocalGenerator>(
&mut self,
vocabulary: &mut V,
generator: &mut G,
rdf_direction: Option<RdfDirection>,
) -> Option<Triple<T, B, L>>where
T: Clone,
B: Clone,
L: Clone,
V: Vocabulary<Iri = T, BlankId = B, Literal = L> + VocabularyMut,
pub fn next<V, G: LocalGenerator>(
&mut self,
vocabulary: &mut V,
generator: &mut G,
rdf_direction: Option<RdfDirection>,
) -> Option<Triple<T, B, L>>where
T: Clone,
B: Clone,
L: Clone,
V: Vocabulary<Iri = T, BlankId = B, Literal = L> + VocabularyMut,
Produces the next triple of the list, allocating blank node identifiers as needed.
Auto Trait Implementations§
impl<'a, T, B, L> Freeze for ListTriples<'a, T, B, L>
impl<'a, T, B, L> RefUnwindSafe for ListTriples<'a, T, B, L>where
SmallVec<[ListItemTriples<'a, T, B, L>; 2]>: RefUnwindSafe,
Option<GeneralizedTriple<ValidId<T, B>, ValidId<T, B>, Value<T, B, L>>>: RefUnwindSafe,
impl<'a, T, B, L> Send for ListTriples<'a, T, B, L>
impl<'a, T, B, L> Sync for ListTriples<'a, T, B, L>
impl<'a, T, B, L> Unpin for ListTriples<'a, T, B, L>
impl<'a, T, B, L> UnsafeUnpin for ListTriples<'a, T, B, L>where
SmallVec<[ListItemTriples<'a, T, B, L>; 2]>: UnsafeUnpin,
Option<GeneralizedTriple<ValidId<T, B>, ValidId<T, B>, Value<T, B, L>>>: UnsafeUnpin,
impl<'a, T, B, L> UnwindSafe for ListTriples<'a, T, B, L>where
SmallVec<[ListItemTriples<'a, T, B, L>; 2]>: UnwindSafe,
Option<GeneralizedTriple<ValidId<T, B>, ValidId<T, B>, Value<T, B, L>>>: 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> BorrowUnordered for T
impl<T> BorrowUnordered for T
Source§fn as_unordered(&self) -> &Unordered<T>
fn as_unordered(&self) -> &Unordered<T>
Views this value as an
Unordered reference.