pub struct ClassificationString(/* private fields */);
Expand description
A classification value stored as a string
Implementations§
Source§impl ClassificationString
impl ClassificationString
pub fn new( classification: String, parser: &Arc<ClassificationParser>, ) -> Result<Self, ModelError>
pub fn try_unrestricted() -> Option<Self>
pub fn unrestricted(parser: &ClassificationParser) -> Self
pub fn as_str(&self) -> &str
pub fn default_unrestricted() -> ClassificationString
Trait Implementations§
Source§impl Clone for ClassificationString
impl Clone for ClassificationString
Source§fn clone(&self) -> ClassificationString
fn clone(&self) -> ClassificationString
Returns a copy 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 ClassificationString
impl Debug for ClassificationString
Source§impl Described<ElasticMeta> for ClassificationString
impl Described<ElasticMeta> for ClassificationString
Source§fn metadata() -> Descriptor<ElasticMeta>
fn metadata() -> Descriptor<ElasticMeta>
Get self description of this type
Source§impl<'de> Deserialize<'de> for ClassificationString
impl<'de> Deserialize<'de> for ClassificationString
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<ClassificationString> for String
impl From<ClassificationString> for String
Source§fn from(value: ClassificationString) -> Self
fn from(value: ClassificationString) -> Self
Converts to this type from the input type.
Source§impl PartialEq for ClassificationString
impl PartialEq for ClassificationString
Source§impl Serialize for ClassificationString
impl Serialize for ClassificationString
impl Eq for ClassificationString
Auto Trait Implementations§
impl Freeze for ClassificationString
impl RefUnwindSafe for ClassificationString
impl Send for ClassificationString
impl Sync for ClassificationString
impl Unpin for ClassificationString
impl UnwindSafe for ClassificationString
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> 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.Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more