v0.1.0-pre.008

This commit is contained in:
2026-07-23 20:40:38 +02:00
parent f5bd8fab7f
commit 12b42a31b8
26 changed files with 6686 additions and 280 deletions

View File

@@ -1,5 +1,5 @@
// file: kb-lib/src/decoder/spl.rs
// version: 4
// version: 5
//! `spl` decoder family.
@@ -37,6 +37,22 @@ pub(crate) use self::associated_token_account::spl_associated_token_account_deco
pub(crate) use self::associated_token_account::spl_associated_token_account_entry;
/// Reads one bounded Associated Token Account payload.
pub(crate) use self::associated_token_account::spl_associated_token_account_payload;
/// One parsed SPL ElGamal registry instruction.
pub(crate) use self::elgamal_registry::ParsedRegistryInstruction;
/// Current stable SPL ElGamal registry event contract version.
pub(crate) use self::elgamal_registry::SPL_ELGAMAL_REGISTRY_EVENT_VERSION;
/// Maximum retained SPL ElGamal registry instruction payload size.
pub(crate) use self::elgamal_registry::SPL_ELGAMAL_REGISTRY_MAX_INSTRUCTION_BYTES;
/// Stable SPL ElGamal registry surface code.
pub(crate) use self::elgamal_registry::SPL_ELGAMAL_REGISTRY_SURFACE_CODE;
/// Canonical tracing target for the SPL ElGamal registry decoder.
pub(crate) use self::elgamal_registry::SPL_ELGAMAL_REGISTRY_TRACING_TARGET;
/// Decodes one bounded SPL ElGamal registry instruction.
pub(crate) use self::elgamal_registry::spl_elgamal_registry_decode;
/// Decodes one bounded SPL ElGamal registry instruction payload.
pub(crate) use self::elgamal_registry::spl_elgamal_registry_decode_payload;
/// Parses one exact SPL ElGamal registry instruction.
pub(crate) use self::elgamal_registry::spl_elgamal_registry_parse;
/// Maximum payload prefix retained for bounded diagnostics.
pub(crate) use self::memo::SPL_MEMO_DIAGNOSTIC_PREFIX_BYTES;
/// Current stable Memo decoded event contract version.
@@ -77,10 +93,52 @@ pub(crate) use self::token::spl_token_decode;
pub(crate) use self::token::spl_token_entry_for_tag;
/// Returns the first byte of one retained classic SPL Token payload.
pub(crate) use self::token::spl_token_payload_tag;
/// Maximum prefix retained in bounded Token-2022 diagnostics.
pub(crate) use self::token_2022::SPL_TOKEN_2022_DIAGNOSTIC_PREFIX_BYTES;
/// Current stable Token-2022 decoded event contract version.
pub(crate) use self::token_2022::SPL_TOKEN_2022_EVENT_VERSION;
/// Exact top-level instruction inventory published by the resolved Token-2022 interface.
pub(crate) use self::token_2022::SPL_TOKEN_2022_INSTRUCTION_ENTRIES;
/// Maximum total account metas consumed by one Token-2022 batch.
pub(crate) use self::token_2022::SPL_TOKEN_2022_MAX_BATCH_ACCOUNTS;
/// Maximum decoded sub-instructions in one Token-2022 batch.
pub(crate) use self::token_2022::SPL_TOKEN_2022_MAX_BATCH_INSTRUCTIONS;
/// Maximum retained Token-2022 instruction payload size.
pub(crate) use self::token_2022::SPL_TOKEN_2022_MAX_INSTRUCTION_BYTES;
/// Maximum retained UTF-8 string size for embedded Token Metadata instructions.
pub(crate) use self::token_2022::SPL_TOKEN_2022_MAX_METADATA_STRING_BYTES;
/// Stable Token-2022 surface code.
pub(crate) use self::token_2022::SPL_TOKEN_2022_SURFACE_CODE;
/// Canonical tracing target for the Token-2022 decoder.
pub(crate) use self::token_2022::SPL_TOKEN_2022_TRACING_TARGET;
/// Decodes one bounded Token-2022 instruction.
pub(crate) use self::token_2022::spl_token_2022_decode;
/// Returns the exact entry matching one Token-2022 tag.
pub(crate) use self::token_2022::spl_token_2022_entry_for_tag;
/// Returns the first byte of one retained Token-2022 payload.
pub(crate) use self::token_2022::spl_token_2022_payload_tag;
/// Exact decoder for the SPL Associated Token Account program.
pub use self::associated_token_account::SplAssociatedTokenAccountDecoder;
/// Exact byte length of one SPL ElGamal registry account.
pub use self::elgamal_registry::ELGAMAL_REGISTRY_ACCOUNT_LEN;
/// Parsed SPL ElGamal public-key registry account.
pub use self::elgamal_registry::ElGamalRegistryState;
/// Exact decoder for the SPL ElGamal registry program.
pub use self::elgamal_registry::SplElgamalRegistryDecoder;
/// Parses one exact SPL ElGamal registry account.
pub use self::elgamal_registry::parse_elgamal_registry_state;
/// Exact decoder for the three registered SPL Memo generations.
pub use self::memo::SplMemoDecoder;
/// Exact decoder for the classic SPL Token program.
pub use self::token::SplTokenDecoder;
/// Exact decoder for the Token-2022 program.
pub use self::token_2022::SplToken2022Decoder;
/// Parsed Token-2022 Mint, Account, or Multisig state.
pub use self::token_2022::Token2022State;
/// Exact Token-2022 base account state kind.
pub use self::token_2022::Token2022StateKind;
/// One exact Token-2022 TLV entry.
pub use self::token_2022::Token2022TlvEntry;
/// Parses one Token-2022 Mint, Account, or Multisig state.
pub use self::token_2022::parse_token_2022_state;