Crate af_sui_types

Source
Expand description

Aftermath’s extensions to sui_sdk_types.

Includes some types and constants from the original sui_types and move_core_types that are not present in sui_sdk_types. This crate also re-exports a lot of the types in sui_sdk_types.

This crate was originally conceived with the following objectives:

  • serde compatibility with the full Sui checkpoint data
  • avoiding dynamic error types so that callers could match against errors and react accordingly
  • using a minimal set of dependencies
  • SemVer compatibility

The long-term plan is to deprecate most of this in favor of sui_sdk_types. However, there are some types in that crate that don’t expose all of the attributes/methods we need yet.

Re-exports§

pub use sui_sdk_types::ActiveJwk;
pub use sui_sdk_types::Address;
pub use sui_sdk_types::Argument;
pub use sui_sdk_types::CheckpointCommitment;
pub use sui_sdk_types::CheckpointContents;
pub use sui_sdk_types::CheckpointContentsDigest;
pub use sui_sdk_types::CheckpointDigest;
pub use sui_sdk_types::CheckpointSequenceNumber;
pub use sui_sdk_types::CheckpointSummary;
pub use sui_sdk_types::CheckpointTimestamp;
pub use sui_sdk_types::Command;
pub use sui_sdk_types::ConsensusCommitDigest;
pub use sui_sdk_types::Digest;
pub use sui_sdk_types::EffectsAuxiliaryDataDigest;
pub use sui_sdk_types::EndOfEpochData;
pub use sui_sdk_types::EpochId;
pub use sui_sdk_types::Event;
pub use sui_sdk_types::ExecutionError;
pub use sui_sdk_types::ExecutionStatus;
pub use sui_sdk_types::GasCostSummary;
pub use sui_sdk_types::IdOperation;
pub use sui_sdk_types::Identifier;
pub use sui_sdk_types::Jwk;
pub use sui_sdk_types::JwkId;
pub use sui_sdk_types::MoveCall;
pub use sui_sdk_types::MovePackage;
pub use sui_sdk_types::ObjectDigest;
pub use sui_sdk_types::ObjectId;
pub use sui_sdk_types::ObjectIn;
pub use sui_sdk_types::ObjectOut;
pub use sui_sdk_types::ProgrammableTransaction;
pub use sui_sdk_types::ProtocolVersion;
pub use sui_sdk_types::SignedTransaction;
pub use sui_sdk_types::StructTag;
pub use sui_sdk_types::Transaction;
pub use sui_sdk_types::TransactionDigest;
pub use sui_sdk_types::TransactionEffects;
pub use sui_sdk_types::TransactionEffectsDigest;
pub use sui_sdk_types::TransactionEffectsV1;
pub use sui_sdk_types::TransactionEffectsV2;
pub use sui_sdk_types::TransactionEvents;
pub use sui_sdk_types::TransactionEventsDigest;
pub use sui_sdk_types::TransactionExpiration;
pub use sui_sdk_types::TransactionKind;
pub use sui_sdk_types::TypeOrigin;
pub use sui_sdk_types::TypeParseError;
pub use sui_sdk_types::TypeTag;
pub use sui_sdk_types::UnchangedSharedKind;
pub use sui_sdk_types::UpgradeInfo;
pub use sui_sdk_types::UserSignature;
pub use sui_sdk_types::Version;

Modules§

encoding
Encoding types used by Sui.
sui
Aftermath’s versions of sui_types.
u256u256

Structs§

ChainIdentifier
Representation of a network’s identifier by the genesis checkpoint’s digest
CheckpointData
CheckpointTransaction
GasData
Gas payment information for a transaction.
IdentStr
A borrowed identifier.
InvalidIdentifierError
MoveObject
MoveObjectType
Wrapper around StructTag with a space-efficient representation for common types like coins.
Object
Alias of sui_types::object::ObjectInner, skipping the Arc in sui_types::object::Object.
TransactionDataV1
U256u256

Enums§

ObjectArg
Object argument for a programmable transaction.
Owner
The entity that owns an object.
TransactionData
The payload that gets sent to the full node as base64 BCS bytes.
TransactionFromBase64Error

Constants§

ADD_STAKE_FUN_NAME
ADD_STAKE_MUL_COIN_FUN_NAME
BRIDGE_ADDRESS
BRIDGE_PACKAGE_ID
CLOCK_ID
Object ID of the onchain Clock.
COIN_METADATA_STRUCT_NAME
COIN_MODULE_NAME
COIN_STRUCT_NAME
COIN_TREASURE_CAP_NAME
DEEPBOOK_ADDRESS
DEEPBOOK_PACKAGE_ID
DYNAMIC_FIELD_FIELD_STRUCT_NAME
DYNAMIC_FIELD_MODULE_NAME
DYNAMIC_OBJECT_FIELD_MODULE_NAME
DYNAMIC_OBJECT_FIELD_WRAPPER_STRUCT_NAME
GAS_MODULE_NAME
GAS_STRUCT_NAME
MAX_VALIDATOR_COUNT
Maximum number of active validators at any moment. We do not allow the number of validators in any epoch to go above this.
MIN_VALIDATOR_JOINING_STAKE_MIST
Lower-bound on the amount of stake required to become a validator.
MIST_PER_SUI
MOVE_STDLIB_ADDRESS
MOVE_STDLIB_PACKAGE_ID
OBJECT_DIGEST_CANCELLED
OBJECT_DIGEST_DELETED
A marker that signifies the object is deleted.
OBJECT_DIGEST_WRAPPED
A marker that signifies the object is wrapped into another object.
PAY_JOIN_FUNC_NAME
PAY_MODULE_NAME
PAY_SPLIT_N_FUNC_NAME
PAY_SPLIT_VEC_FUNC_NAME
STAKED_SUI_STRUCT_NAME
STAKING_POOL_MODULE_NAME
SUI_FRAMEWORK_ADDRESS
SUI_FRAMEWORK_PACKAGE_ID
SUI_SYSTEM_ADDRESS
SUI_SYSTEM_PACKAGE_ID
SYSTEM_PACKAGE_ADDRESSES
TOTAL_SUPPLY_MIST
Total supply denominated in Mist
TOTAL_SUPPLY_SUI
Total supply denominated in Sui
VALIDATOR_LOW_STAKE_GRACE_PERIOD
A validator can have stake below validator_low_stake_threshold for this many epochs before being kicked out.
VALIDATOR_LOW_STAKE_THRESHOLD_MIST
Threshold below which validators enter a grace period to be removed.
VALIDATOR_VERY_LOW_STAKE_THRESHOLD_MIST
Validators with stake below validator_very_low_stake_threshold will be removed immediately at epoch change, no grace period.
WITHDRAW_STAKE_FUN_NAME

Traits§

TransactionDataAPI
TransactionEffectsAPI
Common interface for all transaction effect versions.

Functions§

address
const-ructor for Sui addresses.
decode_base64_default
Convenience method for decoding base64 bytes the way Sui expects.
encode_base64_default
Convenience method for encoding bytes to base64 the way Sui expects.
hex_address_bytes
32-byte address from a hex byte vector, optionally 0x-prefixed.
is_system_package
object_id
const-ructor for object IDs.

Type Aliases§

ObjectRef
Reference to a particular object.