Enum ocl::Error
[−]
[src]
pub enum Error { ErrCode(i32, String), String(String), Nul(NulError), Io(Error), FromUtf8Error(FromUtf8Error), }
An enum containing either a String
or one of several other standard
error types.
Implements the usual error traits.
Variants
ErrCode(i32, String)
String(String)
Nul(NulError)
Io(Error)
FromUtf8Error(FromUtf8Error)
Methods
impl Error
[src]
fn new<S: Into<String>>(desc: S) -> Error
Returns a new Error
with the description string: desc
.
fn err<T, S: Into<String>>(desc: S) -> Result<T>
Returns a new ocl::Result::Err
containing an ocl::Error
with the
given description.
fn errcode<T, S: Into<String>>(code: i32, desc: S) -> Result<T>
Returns a new ocl::Result::Err
containing an ocl::Error
with the
given error code and description.
Trait Implementations
impl Error for Error
[src]
fn description(&self) -> &str
A short description of the error. Read more
fn cause(&self) -> Option<&Error>
1.0.0
The lower-level cause of this error, if any. Read more
impl Into<String> for Error
[src]
impl From<String> for Error
[src]
impl<'a> From<&'a str> for Error
[src]
impl From<NulError> for Error
[src]
impl From<Error> for Error
[src]
impl From<FromUtf8Error> for Error
[src]
fn from(err: FromUtf8Error) -> Error
Performs the conversion.