#[repr(u32)]
pub enum ClockworkError {
    InvalidThreadResponse,
    InvalidThreadState,
    TriggerNotActive,
    ThreadBusy,
    ThreadPaused,
    RateLimitExeceeded,
    MaxRateLimitExceeded,
    UnauthorizedWrite,
    WithdrawalTooLarge,
}
Expand description

Errors for the the Clockwork thread program.

Variants§

§

InvalidThreadResponse

Thrown if a exec response has an invalid program ID or cannot be parsed.

§

InvalidThreadState

Thrown if a thread has an invalid state and cannot complete the operation.

§

TriggerNotActive

Thrown if a exec instruction is invalid because the thread’s trigger condition has not been met.

§

ThreadBusy

§

ThreadPaused

Thrown if a request is invalid because the thread is currently paused.

§

RateLimitExeceeded

Thrown if a exec instruction would cause a thread to exceed its rate limit.

§

MaxRateLimitExceeded

Thrown if a thread authority attempts to set a rate limit above the maximum allowed value.

§

UnauthorizedWrite

Thrown if an inner instruction attempted to write to an unauthorized address.

§

WithdrawalTooLarge

Thrown if the user attempts to withdraw SOL that would put a thread below it’s minimum rent threshold.

Implementations§

Gets the name of this [#enum_name].

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Formats the value using the given formatter. Read more
Converts to this type from the input type.
Converts to this type from the input type.

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The alignment of pointer.
The type for initializers.
Initializes a with the given initializer. Read more
Dereferences the given pointer. Read more
Mutably dereferences the given pointer. Read more
Drops the object pointed to by the given pointer. Read more
Should always be Self
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
Converts the given value to a String. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.