Enum mpesa::MpesaError[][src]

pub enum MpesaError {
Show variants AuthenticationError(Value), B2bError(Value), B2cError(Value), C2bRegisterError(Value), C2bSimulateError(Value), AccountBalanceError(Value), MpesaExpressRequestError(Value), NetworkError(Error), ParseError(Error), EnvironmentalVariableError(VarError), EncryptionError(ErrorStack), Message(&'static str), ErrorResponse(Value),
}
Expand description

Mpesa error stack

Variants

AuthenticationError(Value)
B2bError(Value)
B2cError(Value)
C2bRegisterError(Value)
C2bSimulateError(Value)
AccountBalanceError(Value)
MpesaExpressRequestError(Value)
NetworkError(Error)
ParseError(Error)
EnvironmentalVariableError(VarError)
EncryptionError(ErrorStack)
Message(&'static str)
ErrorResponse(Value)

Trait Implementations

impl Debug for MpesaError[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Display for MpesaError[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Fail for MpesaError[src]

fn name(&self) -> Option<&str>[src]

Returns the “name” of the error. Read more

fn cause(&self) -> Option<&dyn Fail>[src]

Returns a reference to the underlying cause of this failure, if it is an error that wraps other errors. Read more

fn backtrace(&self) -> Option<&Backtrace>[src]

Returns a reference to the Backtrace carried by this failure, if it carries one. Read more

fn context<D>(self, context: D) -> Context<D> where
    D: Display + Send + Sync + 'static, 
[src]

Provides context for this failure. Read more

fn compat(self) -> Compat<Self>[src]

Wraps this failure in a compatibility wrapper that implements std::error::Error. Read more

impl From<&'static str> for MpesaError[src]

fn from(e: &'static str) -> Self[src]

Performs the conversion.

impl From<Error> for MpesaError[src]

fn from(e: Error) -> Self[src]

Performs the conversion.

impl From<Error> for MpesaError[src]

fn from(e: Error) -> Self[src]

Performs the conversion.

impl From<ErrorStack> for MpesaError[src]

fn from(e: ErrorStack) -> Self[src]

Performs the conversion.

impl From<VarError> for MpesaError[src]

fn from(e: VarError) -> Self[src]

Performs the conversion.

Auto Trait Implementations

Blanket Implementations

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

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> AsFail for T where
    T: Fail
[src]

pub fn as_fail(&self) -> &(dyn Fail + 'static)[src]

Converts a reference to Self into a dynamic trait object of Fail.

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

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

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

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

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

pub fn from(t: T) -> T[src]

Performs the conversion.

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

pub fn into(self) -> U[src]

Performs the conversion.

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

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

Converts the given value to a String. Read more

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.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

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.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.