Enum libqaul::error::Error[][src]

pub enum Error {
    NotAuthorised,
    NoUser,
    ContactExists,
    NoContact,
    InvalidQuery,
    NoData,
    InvalidPayload,
    CallbackTimeout,
    NoSign,
    BadSign,
    NetworkFault,
    NoRoute,
    BadSerialise,
    NoService,
    ServiceExists,
    CommFault,
}

libqaul service API error states

All errors that can occur in interaction with the API are encoded as variants on this enum. In most cases, no additional metadata is provided and needs to be inferred from whatever context or function call emitted the error. Check the variant doc comments for a broad overview, as well as detailed usage instructions.

A note on language

Most variants of this enum use either an Invalid or No prefix. Invalid data is data that was either not expected or badly formatted. No in this case takes the place of Unknown, meaning that a query could not be fulfilled.

Variants

NotAuthorised

Not authorised to perform this action

NoUser

The desired user was not known

ContactExists

The provided contact already exists

NoContact

The desired contact does not exist

InvalidQuery

Invalid search query

NoData

No data was returned for the provided query

InvalidPayload

Invalid payload (probably too big)

CallbackTimeout

A function callback timed out

NoSign

Signature with an unknown public key

BadSign

Fraudulent signature for a known public key

NetworkFault

A generic networking error occured

NoRoute

Failed to find a route to this user

BadSerialise

Some serialisation action failed

NoService

No such service was found

ServiceExists

A sevice with this name already exists

CommFault

Some internal components failed to communicate

Implementations

impl Error[src]

pub fn help(&self) -> String[src]

Trait Implementations

impl Clone for Error[src]

impl Copy for Error[src]

impl Debug for Error[src]

impl<'de> Deserialize<'de> for Error[src]

impl Display for Error[src]

impl Eq for Error[src]

impl Error for Error[src]

impl PartialEq<Error> for Error[src]

impl Serialize for Error[src]

impl StructuralEq for Error[src]

impl StructuralPartialEq for Error[src]

Auto Trait Implementations

impl RefUnwindSafe for Error

impl Send for Error

impl Sync for Error

impl Unpin for Error

impl UnwindSafe for Error

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> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

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

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

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

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.

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

impl<T> WithSubscriber for T[src]