#[non_exhaustive]pub enum VideoError {
Show 14 variants
WrongKind(Kind),
MissingIdentifier,
MissingTitle,
MissingMedia,
MalformedParticipant,
MalformedTextTrack,
MalformedSegment,
MalformedOrigin,
InvalidDuration(String),
Media(MediaAttachmentError),
InvalidPublicKey(PublicKeyError),
InvalidUrl(UrlError),
InvalidRelayUrl(RelayUrlError),
InvalidTimestamp(TimestampError),
}Expand description
Errors raised by NIP-71 parsers.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
WrongKind(Kind)
Event kind is not one of the four NIP-71 kinds.
MissingIdentifier
Addressable event is missing its d tag.
MissingTitle
Required title tag is absent.
MissingMedia
Required imeta tag(s) are absent.
MalformedParticipant
p tag missing pubkey column.
MalformedTextTrack
text-track tag missing value column.
MalformedSegment
segment tag missing one of the required columns.
MalformedOrigin
origin tag missing one of the required columns.
InvalidDuration(String)
duration tag value could not be parsed as f64.
Media(MediaAttachmentError)
Wrapped imeta parser error.
InvalidPublicKey(PublicKeyError)
Wrapped pubkey parser error.
InvalidUrl(UrlError)
Wrapped URL parser error.
InvalidRelayUrl(RelayUrlError)
Wrapped relay-URL parser error.
InvalidTimestamp(TimestampError)
Wrapped timestamp parser error.
Trait Implementations§
Source§impl Debug for VideoError
impl Debug for VideoError
Source§impl Display for VideoError
impl Display for VideoError
Source§impl Error for VideoError
impl Error for VideoError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<MediaAttachmentError> for VideoError
impl From<MediaAttachmentError> for VideoError
Source§fn from(source: MediaAttachmentError) -> Self
fn from(source: MediaAttachmentError) -> Self
Converts to this type from the input type.
Source§impl From<PublicKeyError> for VideoError
impl From<PublicKeyError> for VideoError
Source§fn from(source: PublicKeyError) -> Self
fn from(source: PublicKeyError) -> Self
Converts to this type from the input type.
Source§impl From<RelayUrlError> for VideoError
impl From<RelayUrlError> for VideoError
Source§fn from(source: RelayUrlError) -> Self
fn from(source: RelayUrlError) -> Self
Converts to this type from the input type.
Source§impl From<TimestampError> for VideoError
impl From<TimestampError> for VideoError
Source§fn from(source: TimestampError) -> Self
fn from(source: TimestampError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for VideoError
impl RefUnwindSafe for VideoError
impl Send for VideoError
impl Sync for VideoError
impl Unpin for VideoError
impl UnsafeUnpin for VideoError
impl UnwindSafe for VideoError
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