Enum deepl_openapi::models::formality::Formality
source · pub enum Formality {
Default,
More,
Less,
PreferMore,
PreferLess,
}
Expand description
Sets whether the translated text should lean towards formal or informal language.
This feature currently only works for target languages
DE
(German),
FR
(French),
IT
(Italian),
ES
(Spanish),
NL
(Dutch),
PL
(Polish),
PT-PT
,
PT-BR
(Portuguese)
and RU
(Russian).
Setting this parameter with a target language that does not support formality will fail,
unless one of the prefer_...
options are used.
Possible options are:
* default
(default)
* more
- for a more formal language
* less
- for a more informal language
* prefer_more
- for a more formal language if available, otherwise fallback to default formality
* prefer_less
- for a more informal language if available, otherwise fallback to default formality
Variants§
Trait Implementations§
source§impl<'de> Deserialize<'de> for Formality
impl<'de> Deserialize<'de> for Formality
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 Ord for Formality
impl Ord for Formality
source§impl PartialEq<Formality> for Formality
impl PartialEq<Formality> for Formality
source§impl PartialOrd<Formality> for Formality
impl PartialOrd<Formality> for Formality
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for Formality
impl Eq for Formality
impl StructuralEq for Formality
impl StructuralPartialEq for Formality
Auto Trait Implementations§
impl RefUnwindSafe for Formality
impl Send for Formality
impl Sync for Formality
impl Unpin for Formality
impl UnwindSafe for Formality
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.