pub enum RdfDirection {
I18nDatatype,
CompoundLiteral,
}
Expand description
Direction representation method.
Used by the RDF serializer to decide how to encode
Direction
s.
Variants§
I18nDatatype
Encode direction in the string value type IRI using the
https://www.w3.org/ns/i18n#
prefix.
If a language tag is present the IRI will be of the form
https://www.w3.org/ns/i18n#language_direction
or simply
https://www.w3.org/ns/i18n#direction
otherwise where direction
is
either rtl
or ltr
.
CompoundLiteral
Encode the direction using a compound literal value.
In this case the direction tagged string is encoded with a fresh blank
node identifier _:b
and the following triples:
_:b http://www.w3.org/1999/02/22-rdf-syntax-ns#value value@language
_:b http://www.w3.org/1999/02/22-rdf-syntax-ns#direction direction
where direction
is either rtl
or ltr
.
Trait Implementations§
Source§impl Clone for RdfDirection
impl Clone for RdfDirection
Source§fn clone(&self) -> RdfDirection
fn clone(&self) -> RdfDirection
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 Debug for RdfDirection
impl Debug for RdfDirection
Source§impl FromStr for RdfDirection
impl FromStr for RdfDirection
Source§type Err = InvalidRdfDirection
type Err = InvalidRdfDirection
The associated error which can be returned from parsing.
Source§fn from_str(s: &str) -> Result<RdfDirection, <RdfDirection as FromStr>::Err>
fn from_str(s: &str) -> Result<RdfDirection, <RdfDirection as FromStr>::Err>
Parses a string
s
to return a value of this type. Read moreSource§impl Hash for RdfDirection
impl Hash for RdfDirection
Source§impl Ord for RdfDirection
impl Ord for RdfDirection
Source§fn cmp(&self, other: &RdfDirection) -> Ordering
fn cmp(&self, other: &RdfDirection) -> 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 PartialEq for RdfDirection
impl PartialEq for RdfDirection
Source§impl PartialOrd for RdfDirection
impl PartialOrd for RdfDirection
Source§impl<'a> TryFrom<&'a str> for RdfDirection
impl<'a> TryFrom<&'a str> for RdfDirection
Source§type Error = InvalidRdfDirection
type Error = InvalidRdfDirection
The type returned in the event of a conversion error.
Source§fn try_from(
value: &'a str,
) -> Result<RdfDirection, <RdfDirection as TryFrom<&'a str>>::Error>
fn try_from( value: &'a str, ) -> Result<RdfDirection, <RdfDirection as TryFrom<&'a str>>::Error>
Performs the conversion.
impl Copy for RdfDirection
impl Eq for RdfDirection
impl StructuralPartialEq for RdfDirection
Auto Trait Implementations§
impl Freeze for RdfDirection
impl RefUnwindSafe for RdfDirection
impl Send for RdfDirection
impl Sync for RdfDirection
impl Unpin for RdfDirection
impl UnwindSafe for RdfDirection
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
fn as_unordered(&self) -> &Unordered<T>
Source§impl<T> CallHasher for T
impl<T> CallHasher for T
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.