pub enum StringValue {
String(String),
NormalizedString(NormalizedString),
Token(TokenBuf),
Language(LanguageBuf),
Name(NameBuf),
NCName(NCNameBuf),
Id(IdBuf),
IdRef(IdRefBuf),
NMToken(NMTokenBuf),
}
Expand description
Any specialized str
value.
Variants§
String(String)
NormalizedString(NormalizedString)
Token(TokenBuf)
Language(LanguageBuf)
Name(NameBuf)
NCName(NCNameBuf)
Id(IdBuf)
IdRef(IdRefBuf)
NMToken(NMTokenBuf)
Implementations§
Source§impl StringValue
impl StringValue
pub fn datatype(&self) -> StringDatatype
Source§impl StringValue
impl StringValue
pub fn as_ref(&self) -> StringValueRef<'_>
Trait Implementations§
Source§impl Clone for StringValue
impl Clone for StringValue
Source§fn clone(&self) -> StringValue
fn clone(&self) -> StringValue
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 StringValue
impl Debug for StringValue
Source§impl Display for StringValue
impl Display for StringValue
Source§impl From<NCNameValue> for StringValue
impl From<NCNameValue> for StringValue
Source§fn from(value: NCNameValue) -> Self
fn from(value: NCNameValue) -> Self
Converts to this type from the input type.
Source§impl From<NameValue> for StringValue
impl From<NameValue> for StringValue
Source§impl From<NormalizedStringValue> for StringValue
impl From<NormalizedStringValue> for StringValue
Source§fn from(value: NormalizedStringValue) -> Self
fn from(value: NormalizedStringValue) -> Self
Converts to this type from the input type.
Source§impl From<StringValue> for Value
impl From<StringValue> for Value
Source§fn from(value: StringValue) -> Self
fn from(value: StringValue) -> Self
Converts to this type from the input type.
Source§impl From<TokenValue> for StringValue
impl From<TokenValue> for StringValue
Source§fn from(value: TokenValue) -> Self
fn from(value: TokenValue) -> Self
Converts to this type from the input type.
Source§impl TryFrom<StringValue> for NCNameValue
impl TryFrom<StringValue> for NCNameValue
Source§type Error = StringValue
type Error = StringValue
The type returned in the event of a conversion error.
Source§fn try_from(value: StringValue) -> Result<Self, StringValue>
fn try_from(value: StringValue) -> Result<Self, StringValue>
Performs the conversion.
Source§impl TryFrom<StringValue> for NameValue
impl TryFrom<StringValue> for NameValue
Source§type Error = StringValue
type Error = StringValue
The type returned in the event of a conversion error.
Source§fn try_from(value: StringValue) -> Result<Self, StringValue>
fn try_from(value: StringValue) -> Result<Self, StringValue>
Performs the conversion.
Source§impl TryFrom<StringValue> for NormalizedStringValue
impl TryFrom<StringValue> for NormalizedStringValue
Source§type Error = StringValue
type Error = StringValue
The type returned in the event of a conversion error.
Source§fn try_from(value: StringValue) -> Result<Self, StringValue>
fn try_from(value: StringValue) -> Result<Self, StringValue>
Performs the conversion.
Source§impl TryFrom<StringValue> for TokenValue
impl TryFrom<StringValue> for TokenValue
Source§type Error = StringValue
type Error = StringValue
The type returned in the event of a conversion error.
Source§fn try_from(value: StringValue) -> Result<Self, StringValue>
fn try_from(value: StringValue) -> Result<Self, StringValue>
Performs the conversion.
Source§impl TryFrom<Value> for StringValue
impl TryFrom<Value> for StringValue
Auto Trait Implementations§
impl Freeze for StringValue
impl RefUnwindSafe for StringValue
impl Send for StringValue
impl Sync for StringValue
impl Unpin for StringValue
impl UnwindSafe for StringValue
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