pub enum LiteralType<I = IriBuf> {
Any(I),
LangString(LangTagBuf),
}
Expand description
RDF literal type.
Variants§
Implementations§
Source§impl<I> LiteralType<I>
impl<I> LiteralType<I>
pub fn is_lang_string(&self) -> bool
pub fn lang_tag(&self) -> Option<&LangTag>
pub fn is_xsd_string_with( &self, vocabulary: &impl IriVocabulary<Iri = I>, ) -> bool
pub fn is_xsd_string(&self) -> boolwhere
I: IsXsdStringIri,
pub fn is_iri(&self, iri: &I) -> boolwhere
I: PartialEq,
pub fn as_ref(&self) -> LiteralTypeRef<'_, I>
pub fn as_lexical_type_ref_with<'a>( &'a self, vocabulary: &'a impl IriVocabulary<Iri = I>, ) -> LexicalLiteralTypeRef<'a>
Source§impl LiteralType
impl LiteralType
pub fn as_lexical_type_ref(&self) -> LexicalLiteralTypeRef<'_>
Trait Implementations§
Source§impl<I> Clone for LiteralType<I>where
I: Clone,
impl<I> Clone for LiteralType<I>where
I: Clone,
Source§fn clone(&self) -> LiteralType<I>
fn clone(&self) -> LiteralType<I>
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<I> Debug for LiteralType<I>where
I: Debug,
impl<I> Debug for LiteralType<I>where
I: Debug,
Source§impl<V, I> EmbedIntoVocabulary<V> for LiteralType<I>where
I: EmbedIntoVocabulary<V>,
impl<V, I> EmbedIntoVocabulary<V> for LiteralType<I>where
I: EmbedIntoVocabulary<V>,
Source§type Embedded = LiteralType<<I as EmbedIntoVocabulary<V>>::Embedded>
type Embedded = LiteralType<<I as EmbedIntoVocabulary<V>>::Embedded>
Type of the value once embedded into the vocabulary.
fn embed_into_vocabulary( self, vocabulary: &mut V, ) -> <LiteralType<I> as EmbedIntoVocabulary<V>>::Embedded
Source§impl<V, I> EmbeddedIntoVocabulary<V> for LiteralType<I>where
I: EmbeddedIntoVocabulary<V>,
impl<V, I> EmbeddedIntoVocabulary<V> for LiteralType<I>where
I: EmbeddedIntoVocabulary<V>,
type Embedded = LiteralType<<I as EmbeddedIntoVocabulary<V>>::Embedded>
fn embedded_into_vocabulary( &self, vocabulary: &mut V, ) -> <LiteralType<I> as EmbeddedIntoVocabulary<V>>::Embedded
Source§impl<V> ExtractFromVocabulary<V> for LiteralType<<V as IriVocabulary>::Iri>where
V: IriVocabulary,
impl<V> ExtractFromVocabulary<V> for LiteralType<<V as IriVocabulary>::Iri>where
V: IriVocabulary,
type Extracted = LiteralType
fn extract_from_vocabulary( self, vocabulary: &V, ) -> <LiteralType<<V as IriVocabulary>::Iri> as ExtractFromVocabulary<V>>::Extracted
Source§impl<V> ExtractedFromVocabulary<V> for LiteralType<<V as IriVocabulary>::Iri>where
V: IriVocabulary,
impl<V> ExtractedFromVocabulary<V> for LiteralType<<V as IriVocabulary>::Iri>where
V: IriVocabulary,
type Extracted = LiteralType
Source§fn extracted_from_vocabulary(
&self,
vocabulary: &V,
) -> <LiteralType<<V as IriVocabulary>::Iri> as ExtractedFromVocabulary<V>>::Extracted
fn extracted_from_vocabulary( &self, vocabulary: &V, ) -> <LiteralType<<V as IriVocabulary>::Iri> as ExtractedFromVocabulary<V>>::Extracted
Exports a value embedded into the vocabulary
V
. Read moreSource§impl<I> Hash for LiteralType<I>where
I: Hash,
impl<I> Hash for LiteralType<I>where
I: Hash,
Source§impl<I> Ord for LiteralType<I>where
I: Ord,
impl<I> Ord for LiteralType<I>where
I: Ord,
Source§fn cmp(&self, other: &LiteralType<I>) -> Ordering
fn cmp(&self, other: &LiteralType<I>) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl<'a, I> PartialEq<LiteralTypeRef<'a, I>> for LiteralType<I>where
I: PartialEq,
impl<'a, I> PartialEq<LiteralTypeRef<'a, I>> for LiteralType<I>where
I: PartialEq,
Source§impl<I> PartialEq for LiteralType<I>where
I: PartialEq,
impl<I> PartialEq for LiteralType<I>where
I: PartialEq,
Source§impl<I> PartialOrd for LiteralType<I>where
I: PartialOrd,
impl<I> PartialOrd for LiteralType<I>where
I: PartialOrd,
Source§impl<I> RdfDisplay for LiteralType<I>where
I: RdfDisplay,
impl<I> RdfDisplay for LiteralType<I>where
I: RdfDisplay,
impl<I> Eq for LiteralType<I>where
I: Eq,
impl<I> StructuralPartialEq for LiteralType<I>
Auto Trait Implementations§
impl<I> Freeze for LiteralType<I>where
I: Freeze,
impl<I> RefUnwindSafe for LiteralType<I>where
I: RefUnwindSafe,
impl<I> Send for LiteralType<I>where
I: Send,
impl<I> Sync for LiteralType<I>where
I: Sync,
impl<I> Unpin for LiteralType<I>where
I: Unpin,
impl<I> UnwindSafe for LiteralType<I>where
I: 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.