[][src]Trait glib::error::ErrorDomain

pub trait ErrorDomain: Copy {
    fn domain() -> Quark;
fn code(self) -> i32;
fn from(code: i32) -> Option<Self>
    where
        Self: Sized
; }
[]

GLib error domain.

This trait is implemented by error enums that represent error domains (types).

Required methods

fn domain() -> Quark[]

Returns the quark identifying the error domain.

As returned from g_some_error_quark.

fn code(self) -> i32[]

Gets the integer representation of the variant.

fn from(code: i32) -> Option<Self> where
    Self: Sized
[]

Tries to convert an integer code to an enum variant.

By convention, the Failed variant, if present, is a catch-all, i.e. any unrecognized codes map to it.

Implementors

impl ErrorDomain for FileError[src][]

impl ErrorDomain for KeyFileError[src][]

impl ErrorDomain for IOErrorEnum

impl ErrorDomain for ResourceError

impl ErrorDomain for CoreError

impl ErrorDomain for LibraryError

impl ErrorDomain for ParseError

impl ErrorDomain for PluginError

impl ErrorDomain for ResourceError

impl ErrorDomain for StreamError

impl ErrorDomain for URIError

impl ErrorDomain for GLContextError

impl ErrorDomain for GLSLError

impl ErrorDomain for GLWindowError

impl ErrorDomain for PlayerError