Enum rsbadges::BadgeError[][src]

pub enum BadgeError {
    BadCommandLineArgs(String),
    ColorNotValid(String),
    CannotSaveToFile(String),
    CannotEmbedLogo(String),
    CannotLoadFont,
    InvalidStyle(String),
}

Error types that may occur on badge generation.

Badges are lazily evaluated, in a fashion; their data is not verified until they are actually generated into SVGs. RSBadges tries to be loud about malformed data or prevented actions via the error types below.

Variants

BadCommandLineArgs(String)

The arguments passed to the command line cannot be successfully parsed.

ColorNotValid(String)

A color assigned to the Badge does not have a valid CSS color format. See the CSS color picker for vaild examples.

CannotSaveToFile(String)

RSBadges is unable to save the generated badge to an SVG. This is usually a file system error, not an error with badge generation.

RSBadges is unable to download the logo specified, and therefore cannot embed the data into the SVG. This is usually due to a malformed logo URI.

CannotLoadFont

RSBadges can’t load the font file it uses to measure out the width of the badge. This probably means the file has somehow become corrupted.

InvalidStyle(String)

RSBadges has received a request to create a badge type it does not know about. This can only happen from the command line, since a Style is an enum via the API.

Trait Implementations

impl Debug for BadgeError[src]

impl Display for BadgeError[src]

impl Error for BadgeError[src]

impl PartialEq<BadgeError> for BadgeError[src]

impl StructuralPartialEq for BadgeError[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> Conv for T

impl<T> Conv for T

impl<T> FmtForward for T

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

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

impl<T> Pipe for T where
    T: ?Sized

impl<T> Pipe for T

impl<T> PipeAsRef for T

impl<T> PipeBorrow for T

impl<T> PipeDeref for T

impl<T> PipeRef for T

impl<T> Tap for T

impl<T> Tap for T

impl<T, U> TapAsRef<U> for T where
    U: ?Sized

impl<T, U> TapBorrow<U> for T where
    U: ?Sized

impl<T> TapDeref for T

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

impl<T> TryConv for T

impl<T> TryConv for T

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,