#[non_exhaustive]
pub enum EmbedValidationErrorType {
AuthorNameTooLarge {
chars: usize,
},
ColorNotRgb {
color: u32,
},
DescriptionTooLarge {
chars: usize,
},
EmbedTooLarge {
chars: usize,
},
FieldNameTooLarge {
chars: usize,
},
FieldValueTooLarge {
chars: usize,
},
FooterTextTooLarge {
chars: usize,
},
TitleTooLarge {
chars: usize,
},
TooManyFields {
amount: usize,
},
}
Expand description
Type of EmbedValidationError
that occurred.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
AuthorNameTooLarge
Fields
chars: usize
Provided number of codepoints.
Embed author’s name is larger than AUTHOR_NAME_LENGTH
.
ColorNotRgb
Fields
color: u32
Provided color hex value.
Color is larger than a valid RGB hexadecimal value.
DescriptionTooLarge
Fields
chars: usize
Provided number of codepoints.
Embed description is larger than DESCRIPTION_LENGTH
.
EmbedTooLarge
Fields
chars: usize
Provided number of codepoints.
Combined content of all embed fields is larger than
EMBED_TOTAL_LENGTH
.
This includes author name, description, footer, field names and values, and title.
FieldNameTooLarge
Fields
chars: usize
Provided number of codepoints.
A field’s name is larger than FIELD_NAME_LENGTH
.
FieldValueTooLarge
Fields
chars: usize
Provided number of codepoints.
A field’s value is larger than FIELD_VALUE_LENGTH
.
FooterTextTooLarge
Footer text is larger than FOOTER_TEXT_LENGTH
.
TitleTooLarge
Fields
chars: usize
Provided number of codepoints.
Title is larger than TITLE_LENGTH
.
TooManyFields
Fields
amount: usize
Provided number of fields.
There are more than FIELD_COUNT
number of fields in the embed.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for EmbedValidationErrorType
impl Send for EmbedValidationErrorType
impl Sync for EmbedValidationErrorType
impl Unpin for EmbedValidationErrorType
impl UnwindSafe for EmbedValidationErrorType
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more