pub enum MessageValidationErrorType {
AttachmentFilename {
filename: String,
},
ComponentCount {
count: usize,
},
ComponentInvalid {
idx: usize,
kind: ComponentValidationErrorType,
},
ContentInvalid,
EmbedInvalid {
idx: usize,
kind: EmbedValidationErrorType,
},
StickersInvalid {
len: usize,
},
TooManyEmbeds,
WebhookUsername,
}Expand description
Type of MessageValidationError that occurred.
Variants
AttachmentFilename
Fields
filename: StringInvalid filename.
Attachment filename is not valid.
ComponentCount
Fields
count: usizeNumber of components that were provided.
Too many message components were provided.
ComponentInvalid
Fields
idx: usizeIndex of the component.
kind: ComponentValidationErrorTypeAdditional details about the validation failure type.
An invalid message component was provided.
ContentInvalid
Returned when the content is over 2000 UTF-16 characters.
EmbedInvalid
Fields
idx: usizeIndex of the embed.
kind: EmbedValidationErrorTypeAdditional details about the validation failure type.
Returned when the embed is invalid.
StickersInvalid
Fields
len: usizeInvalid length.
Amount of stickers provided is invalid.
TooManyEmbeds
Too many embeds were provided.
A followup message can have up to 10 embeds.
WebhookUsername
Provided webhook username was invalid.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for MessageValidationErrorType
impl Send for MessageValidationErrorType
impl Sync for MessageValidationErrorType
impl Unpin for MessageValidationErrorType
impl UnwindSafe for MessageValidationErrorType
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