#[repr(u32)]pub enum ClockworkError {
InvalidThreadResponse = 0,
InvalidThreadState = 1,
InvalidTriggerVariant = 2,
TriggerConditionFailed = 3,
ThreadBusy = 4,
ThreadPaused = 5,
RateLimitExeceeded = 6,
MaxRateLimitExceeded = 7,
UnauthorizedWrite = 8,
WithdrawalTooLarge = 9,
}
Expand description
Errors for the the Clockwork thread program.
Variants§
InvalidThreadResponse = 0
Thrown if a exec response has an invalid program ID or cannot be parsed.
InvalidThreadState = 1
Thrown if a thread has an invalid state and cannot complete the operation.
InvalidTriggerVariant = 2
TThe provided trigger variant is invalid.
TriggerConditionFailed = 3
Thrown if a exec instruction is invalid because the thread’s trigger condition has not been met.
ThreadBusy = 4
ThreadPaused = 5
Thrown if a request is invalid because the thread is currently paused.
RateLimitExeceeded = 6
Thrown if a exec instruction would cause a thread to exceed its rate limit.
MaxRateLimitExceeded = 7
Thrown if a thread authority attempts to set a rate limit above the maximum allowed value.
Thrown if an inner instruction attempted to write to an unauthorized address.
WithdrawalTooLarge = 9
Thrown if the user attempts to withdraw SOL that would put a thread below it’s minimum rent threshold.
Implementations§
Trait Implementations§
Source§impl Clone for ClockworkError
impl Clone for ClockworkError
Source§fn clone(&self) -> ClockworkError
fn clone(&self) -> ClockworkError
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ClockworkError
impl Debug for ClockworkError
Source§impl Display for ClockworkError
impl Display for ClockworkError
Source§impl From<ClockworkError> for Error
impl From<ClockworkError> for Error
Source§fn from(error_code: ClockworkError) -> Error
fn from(error_code: ClockworkError) -> Error
Converts to this type from the input type.
Source§impl From<ClockworkError> for u32
impl From<ClockworkError> for u32
Source§fn from(e: ClockworkError) -> u32
fn from(e: ClockworkError) -> u32
Converts to this type from the input type.
impl Copy for ClockworkError
Auto Trait Implementations§
impl Freeze for ClockworkError
impl RefUnwindSafe for ClockworkError
impl Send for ClockworkError
impl Sync for ClockworkError
impl Unpin for ClockworkError
impl UnwindSafe for ClockworkError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more