pub trait Relabel<T, B> {
// Required method
fn relabel_with<N: VocabularyMut<Iri = T, BlankId = B>, G: LocalGenerator>(
&mut self,
vocabulary: &mut N,
generator: &mut G,
relabeling: &mut HashMap<B, ValidId<T, B>>,
) -> Result<(), GeneratedIdError>
where T: Clone + Eq + Hash,
B: Clone + Eq + Hash;
// Provided method
fn relabel<G: LocalGenerator>(
&mut self,
generator: &mut G,
relabeling: &mut HashMap<B, ValidId<T, B>>,
) -> Result<(), GeneratedIdError>
where T: Clone + Eq + Hash,
B: Clone + Eq + Hash,
(): Vocabulary<Iri = T, BlankId = B> { ... }
}Expand description
Fragments whose blank node identifiers can be renamed.
Required Methods§
Sourcefn relabel_with<N: VocabularyMut<Iri = T, BlankId = B>, G: LocalGenerator>(
&mut self,
vocabulary: &mut N,
generator: &mut G,
relabeling: &mut HashMap<B, ValidId<T, B>>,
) -> Result<(), GeneratedIdError>
fn relabel_with<N: VocabularyMut<Iri = T, BlankId = B>, G: LocalGenerator>( &mut self, vocabulary: &mut N, generator: &mut G, relabeling: &mut HashMap<B, ValidId<T, B>>, ) -> Result<(), GeneratedIdError>
Relabels every blank node, recording the mapping so shared nodes keep the same new identifier.
§Errors
Returns an error when the generator runs out of identifiers.
Provided Methods§
Sourcefn relabel<G: LocalGenerator>(
&mut self,
generator: &mut G,
relabeling: &mut HashMap<B, ValidId<T, B>>,
) -> Result<(), GeneratedIdError>
fn relabel<G: LocalGenerator>( &mut self, generator: &mut G, relabeling: &mut HashMap<B, ValidId<T, B>>, ) -> Result<(), GeneratedIdError>
Relabels every blank node, recording the mapping.
§Errors
Returns an error when the generator runs out of identifiers.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".