extension

package
v0.0.0-...-3968f94 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var InvalidParams = errors.New("invalid params")

Functions

func ExistsExtensionType

func ExistsExtensionType(array []ExtensionInitializationParams, extensionType ExtensionType) bool

func ExtensionInitializationParamsToInstruction

func ExtensionInitializationParamsToInstruction(
	extension ExtensionInitializationParams,
	mint web3.PublicKey,
	programId web3.PublicKey,
) (web3.Instruction, error)

func Nested

func Nested[T interface {
	SetProgramId(key *web3.PublicKey) T
	SetAccounts(accounts []*web3.AccountMeta) error
}, T2 interface {
	Validate() error
}](programId *web3.PublicKey, innerBuilder T2, next func(data []byte) T) (web3.Instruction, error)

Types

type CpiGuardParams

type CpiGuardParams struct {
	Enable  bool
	Account web3.PublicKey
	Owner   web3.PublicKey
}

func NewCpiGuardParams

func NewCpiGuardParams(enable bool, account web3.PublicKey, owner web3.PublicKey) CpiGuardParams

func (CpiGuardParams) ExtensionType

func (m CpiGuardParams) ExtensionType() ExtensionType

type DefaultAccountStateParams

type DefaultAccountStateParams struct {
	State AccountState
}

func NewDefaultAccountStateParams

func NewDefaultAccountStateParams(state AccountState) DefaultAccountStateParams

func (DefaultAccountStateParams) ExtensionType

func (p DefaultAccountStateParams) ExtensionType() ExtensionType

type ExtensionInitializationParams

type ExtensionInitializationParams interface {
	ExtensionType() ExtensionType
}

type GroupMemberPointerParams

type GroupMemberPointerParams struct {
	Initialize *group_member_pointer.Initialize
	Update     *group_member_pointer.Update
}

func NewGroupMemberPointerParamsInitialize

func NewGroupMemberPointerParamsInitialize(authority web3.PublicKey,
	memberAddress web3.PublicKey,
	mint web3.PublicKey) GroupMemberPointerParams

func NewGroupMemberPointerParamsUpdate

func NewGroupMemberPointerParamsUpdate(
	memberAddress web3.PublicKey,
	mint web3.PublicKey,
	authority web3.PublicKey) GroupMemberPointerParams

func (GroupMemberPointerParams) ExtensionType

func (m GroupMemberPointerParams) ExtensionType() ExtensionType

type GroupPointerParams

type GroupPointerParams struct {
	Initialize *group_pointer.Initialize
	Update     *group_pointer.Update
}

func NewGroupPointerParamsInitialize

func NewGroupPointerParamsInitialize(authority web3.PublicKey,
	groupAddress web3.PublicKey,
	mint web3.PublicKey) GroupPointerParams

func NewGroupPointerParamsUpdate

func NewGroupPointerParamsUpdate(groupAddress web3.PublicKey,
	mint web3.PublicKey,
	authority web3.PublicKey) GroupPointerParams

func (GroupPointerParams) ExtensionType

func (m GroupPointerParams) ExtensionType() ExtensionType

type ImmutableOwnerParams

type ImmutableOwnerParams struct {
	Account web3.PublicKey
}

func NewImmutableOwnerParams

func NewImmutableOwnerParams(account web3.PublicKey) ImmutableOwnerParams

func (ImmutableOwnerParams) ExtensionType

func (m ImmutableOwnerParams) ExtensionType() ExtensionType

type InterestBearingConfigParams

type InterestBearingConfigParams struct {
	RateAuthority web3.PublicKey
	Rate          int16
}

func NewInterestBearingConfigParams

func NewInterestBearingConfigParams(rateAuthority *web3.PublicKey, rate int16) InterestBearingConfigParams

func (InterestBearingConfigParams) ExtensionType

func (p InterestBearingConfigParams) ExtensionType() ExtensionType

type MemoTransferParams

type MemoTransferParams struct {
	Enable       bool
	Account      web3.PublicKey
	AccountOwner web3.PublicKey
	MultiSigners []web3.PublicKey
}

func NewMemoTransferParams

func NewMemoTransferParams(enable bool, account web3.PublicKey, accountOwner web3.PublicKey, multiSigners ...web3.PublicKey) MemoTransferParams

func (MemoTransferParams) ExtensionType

func (m MemoTransferParams) ExtensionType() ExtensionType

type MetadataPointerParams

type MetadataPointerParams struct {
	Initialize *metadata_pointer.Initialize
	Update     *metadata_pointer.Update
}

func NewMetadataPointerParamsInitialize

func NewMetadataPointerParamsInitialize(
	authority *web3.PublicKey,
	metadataAddress *web3.PublicKey,
	mint web3.PublicKey) MetadataPointerParams

func NewMetadataPointerParamsUpdate

func NewMetadataPointerParamsUpdate(
	metadataAddress web3.PublicKey,
	mint web3.PublicKey,
	owner web3.PublicKey,
) MetadataPointerParams

func (MetadataPointerParams) ExtensionType

func (p MetadataPointerParams) ExtensionType() ExtensionType

type MintCloseAuthorityParams

type MintCloseAuthorityParams struct {
	CloseAuthority *web3.PublicKey
}

func NewMintCloseAuthorityParams

func NewMintCloseAuthorityParams(closeAuthority *web3.PublicKey) MintCloseAuthorityParams

func (MintCloseAuthorityParams) ExtensionType

func (p MintCloseAuthorityParams) ExtensionType() ExtensionType

type NonTransferableParams

type NonTransferableParams struct {
	Mint web3.PublicKey
}

func NewNonTransferableParams

func NewNonTransferableParams(mint web3.PublicKey) NonTransferableParams

func (NonTransferableParams) ExtensionType

func (m NonTransferableParams) ExtensionType() ExtensionType

type PermanentDelegateParams

type PermanentDelegateParams struct {
	Delegate web3.PublicKey
}

func NewPermanentDelegateParams

func NewPermanentDelegateParams(delegate web3.PublicKey) PermanentDelegateParams

func (PermanentDelegateParams) ExtensionType

func (p PermanentDelegateParams) ExtensionType() ExtensionType

type TransferFeeConfigParams

type TransferFeeConfigParams struct {
	ExtensionTyp               ExtensionType
	TransferFeeConfigAuthority *web3.PublicKey
	WithdrawWithheldAuthority  *web3.PublicKey
	TransferFeeBasisPoints     uint16
	MaximumFee                 uint64
}

func NewTransferFeeConfigParams

func NewTransferFeeConfigParams(
	transferFeeBasisPoints uint16,
	maximumFee uint64,
	transferFeeConfigAuthority, withdrawWithheldAuthority *web3.PublicKey,
) TransferFeeConfigParams

func (TransferFeeConfigParams) ExtensionType

func (p TransferFeeConfigParams) ExtensionType() ExtensionType

type TransferHookParams

type TransferHookParams struct {
	Initialize *transfer_hook.Initialize
	Update     *transfer_hook.Update
}

func NewTransferHookParamsInitialize

func NewTransferHookParamsInitialize(authority web3.PublicKey,
	programId web3.PublicKey,
	mint web3.PublicKey) TransferHookParams

func NewTransferHookParamsUpdate

func NewTransferHookParamsUpdate(programId web3.PublicKey,
	mint web3.PublicKey,
	authority web3.PublicKey) TransferHookParams

func (TransferHookParams) ExtensionType

func (p TransferHookParams) ExtensionType() ExtensionType

Jump to

Keyboard shortcuts

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