pub struct WordMetadata {
pub noun: Option<NounData>,
pub pronoun: Option<PronounData>,
pub verb: Option<VerbData>,
pub adjective: Option<AdjectiveData>,
pub adverb: Option<AdverbData>,
pub conjunction: Option<ConjunctionData>,
pub swear: Option<bool>,
pub dialect: Option<Dialect>,
pub determiner: bool,
pub preposition: bool,
pub common: bool,
pub derived_from: Option<WordId>,
}
Fields§
§noun: Option<NounData>
§pronoun: Option<PronounData>
§verb: Option<VerbData>
§adjective: Option<AdjectiveData>
§adverb: Option<AdverbData>
§conjunction: Option<ConjunctionData>
§swear: Option<bool>
§dialect: Option<Dialect>
The dialect this word belongs to. If no dialect is defined, it can be assumed that the word is valid in all dialects of English.
determiner: bool
Whether the word is a determiner.
preposition: bool
Whether the word is a preposition.
common: bool
Whether the word is considered especially common.
derived_from: Option<WordId>
Implementations§
Source§impl WordMetadata
impl WordMetadata
Sourcepub fn or(&self, other: &Self) -> Self
pub fn or(&self, other: &Self) -> Self
Produce a copy of self
with the known properties of other
set.
pub fn is_likely_homograph(&self) -> bool
Sourcepub fn is_proper_noun(&self) -> bool
pub fn is_proper_noun(&self) -> bool
Checks if the word is definitely a noun and more specifically is labeled as (a) proper.
Sourcepub fn is_not_proper_noun(&self) -> bool
pub fn is_not_proper_noun(&self) -> bool
Checks if the word is definitely a noun and more specifically is labeled as not (a) proper.
Sourcepub fn is_plural_noun(&self) -> bool
pub fn is_plural_noun(&self) -> bool
Checks if the word is definitely a noun and more specifically is labeled as (a) plural.
Sourcepub fn is_not_plural_noun(&self) -> bool
pub fn is_not_plural_noun(&self) -> bool
Checks if the word is definitely a noun and more specifically is labeled as not (a) plural.
Sourcepub fn is_possessive_noun(&self) -> bool
pub fn is_possessive_noun(&self) -> bool
Checks if the word is definitely a noun and more specifically is labeled as (a) possessive.
Sourcepub fn is_not_possessive_noun(&self) -> bool
pub fn is_not_possessive_noun(&self) -> bool
Checks if the word is definitely a noun and more specifically is labeled as not (a) possessive.
Sourcepub fn is_pronoun(&self) -> bool
pub fn is_pronoun(&self) -> bool
Checks if the word is definitely a pronoun.
Sourcepub fn is_plural_pronoun(&self) -> bool
pub fn is_plural_pronoun(&self) -> bool
Checks if the word is definitely a pronoun and more specifically is labeled as (a) plural.
Sourcepub fn is_not_plural_pronoun(&self) -> bool
pub fn is_not_plural_pronoun(&self) -> bool
Checks if the word is definitely a pronoun and more specifically is labeled as not (a) plural.
Sourcepub fn is_possessive_pronoun(&self) -> bool
pub fn is_possessive_pronoun(&self) -> bool
Checks if the word is definitely a pronoun and more specifically is labeled as (a) possessive.
Sourcepub fn is_not_possessive_pronoun(&self) -> bool
pub fn is_not_possessive_pronoun(&self) -> bool
Checks if the word is definitely a pronoun and more specifically is labeled as not (a) possessive.
Sourcepub fn is_linking_verb(&self) -> bool
pub fn is_linking_verb(&self) -> bool
Checks if the word is definitely a verb and more specifically is labeled as (a) linking.
Sourcepub fn is_not_linking_verb(&self) -> bool
pub fn is_not_linking_verb(&self) -> bool
Checks if the word is definitely a verb and more specifically is labeled as not (a) linking.
Sourcepub fn is_auxiliary_verb(&self) -> bool
pub fn is_auxiliary_verb(&self) -> bool
Checks if the word is definitely a verb and more specifically is labeled as (a) auxiliary.
Sourcepub fn is_not_auxiliary_verb(&self) -> bool
pub fn is_not_auxiliary_verb(&self) -> bool
Checks if the word is definitely a verb and more specifically is labeled as not (a) auxiliary.
Sourcepub fn is_conjunction(&self) -> bool
pub fn is_conjunction(&self) -> bool
Checks if the word is definitely a conjunction.
Sourcepub fn is_adjective(&self) -> bool
pub fn is_adjective(&self) -> bool
Checks if the word is definitely a adjective.
pub fn is_present_tense_verb(&self) -> bool
Sourcepub fn is_nominal(&self) -> bool
pub fn is_nominal(&self) -> bool
Checks if the word is definitely nominalpro.
Sourcepub fn is_plural_nominal(&self) -> bool
pub fn is_plural_nominal(&self) -> bool
Checks if the word is definitely a nominal and more specifically is labeled as (a) plural.
Sourcepub fn is_possessive_nominal(&self) -> bool
pub fn is_possessive_nominal(&self) -> bool
Checks if the word is definitely a nominal and more specifically is labeled as (a) possessive.
Sourcepub fn is_not_plural_nominal(&self) -> bool
pub fn is_not_plural_nominal(&self) -> bool
Checks if the word is definitely a nominal and more specifically is labeled as not (a) plural.
Sourcepub fn is_not_possessive_nominal(&self) -> bool
pub fn is_not_possessive_nominal(&self) -> bool
Checks if the word is definitely a nominal and more specifically is labeled as not (a) possessive.
Trait Implementations§
Source§impl Clone for WordMetadata
impl Clone for WordMetadata
Source§fn clone(&self) -> WordMetadata
fn clone(&self) -> WordMetadata
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for WordMetadata
impl Debug for WordMetadata
Source§impl Default for WordMetadata
impl Default for WordMetadata
Source§fn default() -> WordMetadata
fn default() -> WordMetadata
Source§impl<'de> Deserialize<'de> for WordMetadata
impl<'de> Deserialize<'de> for WordMetadata
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>,
Source§impl Hash for WordMetadata
impl Hash for WordMetadata
Source§impl PartialEq for WordMetadata
impl PartialEq for WordMetadata
Source§impl PartialOrd for WordMetadata
impl PartialOrd for WordMetadata
Source§impl Serialize for WordMetadata
impl Serialize for WordMetadata
impl Eq for WordMetadata
impl StructuralPartialEq for WordMetadata
Auto Trait Implementations§
impl Freeze for WordMetadata
impl RefUnwindSafe for WordMetadata
impl Send for WordMetadata
impl Sync for WordMetadata
impl Unpin for WordMetadata
impl UnwindSafe for WordMetadata
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
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§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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>
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>
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