Expand description
An ERC20-like Token program for the Solana blockchain
Re-exports§
pub use solana_zk_sdk;
Modules§
- error
Deprecated - Error types
- extension
- Extensions available to token mints and accounts
- generic_
token_ account Deprecated - Generic Token Account, copied from
spl_token::state - instruction
Deprecated - Instruction types
- native_
mint Deprecated - The Mint that represents the native token
- offchain
- Offchain helper for fetching required accounts to build instructions
- onchain
- On-chain program invoke helper to perform on-chain
transfer_checkedwith correct accounts - pod
Deprecated - Rewrites of the base state types represented as Pods
- pod_
instruction - Rewrites of the instruction data types represented as Pods
- processor
- Program state processor
- state
Deprecated - State transition types
Constants§
- ID
- The const program ID.
Functions§
- amount_
to_ ui_ amount - Convert a raw amount to its UI representation (using the decimals field defined in its mint)
- amount_
to_ ui_ amount_ string - Convert a raw amount to its UI representation (using the decimals field defined in its mint)
- amount_
to_ ui_ amount_ string_ trimmed - Convert a raw amount to its UI representation using the given decimals field Excess zeroes or unneeded decimal point are trimmed.
- check_
id - Returns
trueif given pubkey is the program ID. - check_
program_ account - Checks that the supplied program ID is correct for spl-token-2022
- check_
system_ program_ account - Checks if the supplied program ID is that of the system program
- check_
zk_ elgamal_ proof_ program_ account - Checks that the supplied program ID is correct for the ZK ElGamal proof program
- id
- Returns the program ID.
- try_
ui_ amount_ into_ amount - Try to convert a UI representation of a token amount to its raw amount using the given decimals field
- ui_
amount_ to_ amount - Convert the UI representation of a token amount (using the decimals field defined in its mint) to the raw amount