addresslookuptable

package
v1.8.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 15, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const LOOKUP_TABLE_META_SIZE = 56

The serialized size of lookup table metadata.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddressLookupTableState

type AddressLookupTableState struct {
	TypeIndex                  uint32
	DeactivationSlot           uint64
	LastExtendedSlot           uint64
	LastExtendedSlotStartIndex uint8
	Authority                  *solana.PublicKey
	Addresses                  solana.PublicKeySlice
}

func DecodeAddressLookupTableState

func DecodeAddressLookupTableState(data []byte) (*AddressLookupTableState, error)

DecodeAddressLookupTableState decodes the given account bytes into a AddressLookupTableState.

func GetAddressLookupTable

func GetAddressLookupTable(
	ctx context.Context,
	rpcClient *rpc.Client,
	address solana.PublicKey,
) (*AddressLookupTableState, error)

func GetAddressLookupTableStateWithOpts

func GetAddressLookupTableStateWithOpts(
	ctx context.Context,
	rpcClient *rpc.Client,
	address solana.PublicKey,
	opts *rpc.GetAccountInfoOpts,
) (*AddressLookupTableState, error)

func (AddressLookupTableState) IsActive

func (a AddressLookupTableState) IsActive() bool

func (AddressLookupTableState) MarshalWithEncoder

func (a AddressLookupTableState) MarshalWithEncoder(encoder *bin.Encoder) error

func (*AddressLookupTableState) UnmarshalWithDecoder

func (a *AddressLookupTableState) UnmarshalWithDecoder(decoder *bin.Decoder) (err error)

type KeyedAddressLookupTable

type KeyedAddressLookupTable struct {
	Key   solana.PublicKey
	State AddressLookupTableState
}

func NewKeyedAddressLookupTable

func NewKeyedAddressLookupTable(key solana.PublicKey) *KeyedAddressLookupTable

func (KeyedAddressLookupTable) MarshalWithEncoder

func (a KeyedAddressLookupTable) MarshalWithEncoder(encoder *bin.Encoder) error

func (*KeyedAddressLookupTable) UnmarshalWithDecoder

func (a *KeyedAddressLookupTable) UnmarshalWithDecoder(decoder *bin.Decoder) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL