#[non_exhaustive]pub enum ErrorKind {
AlreadyRunning(AlreadyRunning),
ServicesOff(ServicesOff),
IO(Error),
Fmt(Error),
ParseInt(ParseIntError),
Utf8(FromUtf8Error),
TaskJoin(TaskJoinError),
Clipboard(ClipboardError),
Custom(Box<dyn ErrorTrait + Send + Sync>),
}
Expand description
The kind of an error that may happen when executing a terminal operation.
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.
AlreadyRunning(AlreadyRunning)
Terminal services already running.
ServicesOff(ServicesOff)
Event listener and/or renderer disconnected.
IO(Error)
This is an IO error.
Fmt(Error)
This is a formatting error.
ParseInt(ParseIntError)
This is an error from a bad integer parse attempt.
Utf8(FromUtf8Error)
This is an string from UTF-8 conversion error.
TaskJoin(TaskJoinError)
This is an error from failing to join a task, either because it was cancelled, or because it panicked.
Clipboard(ClipboardError)
This is an error that may happen accessing clipboard.
Custom(Box<dyn ErrorTrait + Send + Sync>)
A custom error, stored in a trait object.
Implementations§
Trait Implementations§
source§impl From<AlreadyRunning> for ErrorKind
impl From<AlreadyRunning> for ErrorKind
source§fn from(error: AlreadyRunning) -> Self
fn from(error: AlreadyRunning) -> Self
Converts to this type from the input type.
source§impl From<ClipboardError> for ErrorKind
impl From<ClipboardError> for ErrorKind
source§fn from(error: ClipboardError) -> Self
fn from(error: ClipboardError) -> Self
Converts to this type from the input type.
source§impl From<FromUtf8Error> for ErrorKind
impl From<FromUtf8Error> for ErrorKind
source§fn from(error: FromUtf8Error) -> Self
fn from(error: FromUtf8Error) -> Self
Converts to this type from the input type.
source§impl From<ParseIntError> for ErrorKind
impl From<ParseIntError> for ErrorKind
source§fn from(error: ParseIntError) -> Self
fn from(error: ParseIntError) -> Self
Converts to this type from the input type.
source§impl From<ServicesOff> for ErrorKind
impl From<ServicesOff> for ErrorKind
source§fn from(error: ServicesOff) -> Self
fn from(error: ServicesOff) -> Self
Converts to this type from the input type.
source§impl From<TaskJoinError> for ErrorKind
impl From<TaskJoinError> for ErrorKind
source§fn from(error: TaskJoinError) -> Self
fn from(error: TaskJoinError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for ErrorKind
impl Send for ErrorKind
impl Sync for ErrorKind
impl Unpin for ErrorKind
impl !UnwindSafe for ErrorKind
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
source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere T: Any,
source§fn into_any(self: Box<T, Global>) -> Box<dyn Any, Global>
fn into_any(self: Box<T, Global>) -> Box<dyn Any, Global>
Convert
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.source§fn into_any_rc(self: Rc<T, Global>) -> Rc<dyn Any, Global>
fn into_any_rc(self: Rc<T, Global>) -> Rc<dyn Any, Global>
Convert
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.