[][src]Struct i18n_build::error::PathError

pub struct PathError {
    pub path: PathBuf,
    pub kind: PathErrorKind,
}

This error type collates all the various generic file/path related errors in this application into one place, so that they can be translated easily.

Fields

path: PathBuf

The path associated with this error

kind: PathErrorKind

What specific kind of error this is

Implementations

impl PathError[src]

pub fn cannot_create_dir<P: Into<PathBuf>>(path: P, source: Error) -> PathError[src]

An error for when a directory cannot be created.

pub fn cannot_create_file<P: Into<PathBuf>>(path: P, source: Error) -> PathError[src]

An error for when a file cannot be created.

pub fn cannot_delete_dir<P: Into<PathBuf>>(path: P, source: Error) -> PathError[src]

An error for when a directory cannot be deleted.

pub fn cannot_delete_file<P: Into<PathBuf>>(path: P, source: Error) -> PathError[src]

An error for when a file cannot be deleted.

pub fn cannot_rename_file<P: Into<PathBuf>>(
    from: P,
    to: P,
    source: Error
) -> PathError
[src]

An error for when a file cannot be renamed.

pub fn does_not_exist<P: Into<PathBuf>>(path: P) -> PathError[src]

An error for when the given path does not exist (when it was expected to exist).

pub fn not_valid_utf8<F: Into<String>, P: Into<PathBuf>>(
    path: P,
    for_item: F,
    path_type: PathType
) -> PathError
[src]

An error for when the given path contains some characters which do not conform to the UTF-8 standard/encoding.

pub fn not_inside_dir<S: Into<String>, P: Into<PathBuf>>(
    path: P,
    parent_name: S,
    parent_path: P
) -> PathError
[src]

An error for when the given path is not inside another given path which is a directory.

Trait Implementations

impl Debug for PathError[src]

impl Display for PathError[src]

impl Error for PathError[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.