[][src]Enum solana_program::program_error::ProgramError

pub enum ProgramError {
    Custom(u32),
    InvalidArgument,
    InvalidInstructionData,
    InvalidAccountData,
    AccountDataTooSmall,
    InsufficientFunds,
    IncorrectProgramId,
    MissingRequiredSignature,
    AccountAlreadyInitialized,
    UninitializedAccount,
    NotEnoughAccountKeys,
    AccountBorrowFailed,
    MaxSeedLengthExceeded,
    InvalidSeeds,
}

Reasons the program may fail

Variants

Custom(u32)

Allows on-chain programs to implement program-specific error types and see them returned by the Solana runtime. A program-specific error may be any type that is represented as or serialized to a u32 integer.

InvalidArgument
InvalidInstructionData
InvalidAccountData
AccountDataTooSmall
InsufficientFunds
IncorrectProgramId
MissingRequiredSignature
AccountAlreadyInitialized
UninitializedAccount
NotEnoughAccountKeys
AccountBorrowFailed
MaxSeedLengthExceeded
InvalidSeeds

Trait Implementations

impl Clone for ProgramError[src]

impl Debug for ProgramError[src]

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

impl Display for ProgramError[src]

impl Eq for ProgramError[src]

impl Error for ProgramError[src]

impl From<ProgramError> for u64[src]

impl From<PubkeyError> for ProgramError[src]

impl From<u64> for ProgramError[src]

impl PartialEq<ProgramError> for ProgramError[src]

impl PrintProgramError for ProgramError[src]

impl Serialize for ProgramError[src]

impl StructuralEq for ProgramError[src]

impl StructuralPartialEq for ProgramError[src]

impl TryFrom<InstructionError> for ProgramError[src]

type Error = InstructionError

The type returned in the event of a conversion error.

Auto Trait Implementations

Blanket Implementations

impl<T> AbiEnumVisitor for T where
    T: AbiExample + Serialize + ?Sized
[src]

impl<T> AbiEnumVisitor for T where
    T: Serialize + ?Sized
[src]

impl<T> AbiExample for T[src]

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, 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>,