pub struct Processor {}
Expand description
Program state handler.
Implementations
pub fn process_initialize_mint(
accounts: &[AccountInfo<'_>],
decimals: u8,
mint_authority: Pubkey,
freeze_authority: COption<Pubkey>
) -> ProgramResult
pub fn process_initialize_mint(
accounts: &[AccountInfo<'_>],
decimals: u8,
mint_authority: Pubkey,
freeze_authority: COption<Pubkey>
) -> ProgramResult
Processes an InitializeMint instruction.
pub fn process_initialize_mint2(
accounts: &[AccountInfo<'_>],
decimals: u8,
mint_authority: Pubkey,
freeze_authority: COption<Pubkey>
) -> ProgramResult
pub fn process_initialize_mint2(
accounts: &[AccountInfo<'_>],
decimals: u8,
mint_authority: Pubkey,
freeze_authority: COption<Pubkey>
) -> ProgramResult
Processes an InitializeMint2 instruction.
pub fn process_initialize_account(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>]
) -> ProgramResult
pub fn process_initialize_account(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>]
) -> ProgramResult
Processes an InitializeAccount instruction.
pub fn process_initialize_account2(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
owner: Pubkey
) -> ProgramResult
pub fn process_initialize_account2(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
owner: Pubkey
) -> ProgramResult
Processes an InitializeAccount2 instruction.
pub fn process_initialize_account3(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
owner: Pubkey
) -> ProgramResult
pub fn process_initialize_account3(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
owner: Pubkey
) -> ProgramResult
Processes an InitializeAccount3 instruction.
Processes a InitializeMultisig instruction.
Processes a InitializeMultisig2 instruction.
pub fn process_transfer(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
amount: u64,
expected_decimals: Option<u8>
) -> ProgramResult
pub fn process_transfer(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
amount: u64,
expected_decimals: Option<u8>
) -> ProgramResult
Processes a Transfer instruction.
pub fn process_approve(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
amount: u64,
expected_decimals: Option<u8>
) -> ProgramResult
pub fn process_approve(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
amount: u64,
expected_decimals: Option<u8>
) -> ProgramResult
Processes an Approve instruction.
Processes an Revoke instruction.
Processes a SetAuthority instruction.
pub fn process_mint_to(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
amount: u64,
expected_decimals: Option<u8>
) -> ProgramResult
pub fn process_mint_to(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
amount: u64,
expected_decimals: Option<u8>
) -> ProgramResult
Processes a MintTo instruction.
pub fn process_burn(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
amount: u64,
expected_decimals: Option<u8>
) -> ProgramResult
pub fn process_burn(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
amount: u64,
expected_decimals: Option<u8>
) -> ProgramResult
Processes a Burn instruction.
pub fn process_close_account(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>]
) -> ProgramResult
pub fn process_close_account(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>]
) -> ProgramResult
Processes a CloseAccount instruction.
pub fn process_toggle_freeze_account(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
freeze: bool
) -> ProgramResult
pub fn process_toggle_freeze_account(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
freeze: bool
) -> ProgramResult
Processes a FreezeAccount or a ThawAccount instruction.
pub fn process_sync_native(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>]
) -> ProgramResult
pub fn process_sync_native(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>]
) -> ProgramResult
Processes a SyncNative instruction
pub fn process(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
input: &[u8]
) -> ProgramResult
pub fn process(
program_id: &Pubkey,
accounts: &[AccountInfo<'_>],
input: &[u8]
) -> ProgramResult
Processes an Instruction.
pub fn check_account_owner(
program_id: &Pubkey,
account_info: &AccountInfo<'_>
) -> ProgramResult
pub fn check_account_owner(
program_id: &Pubkey,
account_info: &AccountInfo<'_>
) -> ProgramResult
Checks that the account is owned by the expected program
Checks two pubkeys for equality in a computationally cheap way using
sol_memcmp
pub fn validate_owner(
program_id: &Pubkey,
expected_owner: &Pubkey,
owner_account_info: &AccountInfo<'_>,
signers: &[AccountInfo<'_>]
) -> ProgramResult
pub fn validate_owner(
program_id: &Pubkey,
expected_owner: &Pubkey,
owner_account_info: &AccountInfo<'_>,
signers: &[AccountInfo<'_>]
) -> ProgramResult
Validates owner(s) are present