pub enum UtilError {
Show 18 variants
CreateDir(PathBuf, Error),
RemoveDir(PathBuf, Error),
WriteFile(PathBuf, Error),
GetMetadata(PathBuf, Error),
MakeExec(PathBuf, Error),
Copy(PathBuf, PathBuf, Error),
SetPermissions(PathBuf, Error),
Read(PathBuf, Error),
Utf8(PathBuf, FromUtf8Error),
TimeFormat(Format),
CreateFile(PathBuf, Error),
Execute(&'static str, CommandError),
ClientBuild(Error),
Client(Error),
BuildRequest(Error),
Get(String, Error),
GetBody(String, Error),
UnwantedStatus(StatusCode),
}Expand description
Errors from utility functions.
Variants§
CreateDir(PathBuf, Error)
Can’t create directory.
RemoveDir(PathBuf, Error)
Can’t remove directory.
WriteFile(PathBuf, Error)
Can’t write file.
GetMetadata(PathBuf, Error)
Can’t get file metadata.
MakeExec(PathBuf, Error)
Can’t make executable.
Copy(PathBuf, PathBuf, Error)
Can’t copy file.
SetPermissions(PathBuf, Error)
Can’t set file permissions.
Read(PathBuf, Error)
Can’t read file.
Utf8(PathBuf, FromUtf8Error)
Can’t read file as UTF-8.
TimeFormat(Format)
Can’t format time as string.
CreateFile(PathBuf, Error)
Can’t create file.
Execute(&'static str, CommandError)
Can’t run program.
ClientBuild(Error)
Can’t build an HTTP client.
Client(Error)
Can’t create an HTTP client.
BuildRequest(Error)
Can’t build an HTTP request.
Get(String, Error)
Can’t get file with GET.
GetBody(String, Error)
Can’t get GET response body.
UnwantedStatus(StatusCode)
HTTP GET returned weird status code.
Trait Implementations§
Source§impl Error for UtilError
impl Error for UtilError
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<UtilError> for AptRepoError
impl From<UtilError> for AptRepoError
Source§impl From<UtilError> for CargoError
impl From<UtilError> for CargoError
Source§impl From<UtilError> for HttpGetError
impl From<UtilError> for HttpGetError
Source§impl From<UtilError> for ImageStoreError
impl From<UtilError> for ImageStoreError
Source§impl From<UtilError> for ProjectError
impl From<UtilError> for ProjectError
Auto Trait Implementations§
impl Freeze for UtilError
impl !RefUnwindSafe for UtilError
impl Send for UtilError
impl Sync for UtilError
impl Unpin for UtilError
impl UnsafeUnpin for UtilError
impl !UnwindSafe for UtilError
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.