Skip to main content

SinkError

Trait SinkError 

Source
pub trait SinkError: Sized {
    // Required method
    fn error_message<T: Display>(message: T) -> Self;

    // Provided method
    fn error_io(err: Error) -> Self { ... }
}
Expand description

A trait that describes errors that can be reported by searchers and implementations of Sink.

Required Methods§

Source

fn error_message<T: Display>(message: T) -> Self

A constructor for converting any value that satisfies the std::fmt::Display trait into an error.

Provided Methods§

Source

fn error_io(err: Error) -> Self

A constructor for converting I/O errors that occur while searching into an error of this type.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl SinkError for Error

Implementors§