Documentation ¶
Index ¶
- Constants
- type Initialize
- func (init Initialize) Build() *Instruction
- func (init Initialize) MarshalWithEncoder(encoder *encodbin.Encoder) (err error)
- func (init *Initialize) SetAdministrator(asset common.Address) *Initialize
- func (init *Initialize) SetAssetAccount(asset common.Address) *Initialize
- func (init *Initialize) SetPrimaryWorker(asset common.Address) *Initialize
- func (init *Initialize) SetSecondaryWorker(asset common.Address) *Initialize
- func (init *Initialize) SetSingerA(asset common.Address) *Initialize
- func (init *Initialize) SetSingerB(asset common.Address) *Initialize
- func (init *Initialize) SetSingerC(asset common.Address) *Initialize
- func (init *Initialize) SetUserAccount(asset common.Address) *Initialize
- type Instruction
- func (inst *Instruction) Accounts() (out []*base.AccountMeta)
- func (inst *Instruction) Data() ([]byte, error)
- func (inst *Instruction) MarshalWithEncoder(encoder *encodbin.Encoder) error
- func (inst *Instruction) ProgramID() common.Address
- func (inst *Instruction) SetProgramID(tokenProgramID common.Address)
- type ProxyRaydiumSwapBaseIn
- type SyncNativeAssetAta
- func (init SyncNativeAssetAta) Build() *Instruction
- func (init SyncNativeAssetAta) MarshalWithEncoder(encoder *encodbin.Encoder) (err error)
- func (init *SyncNativeAssetAta) SetAdministrator(val common.Address) *SyncNativeAssetAta
- func (init *SyncNativeAssetAta) SetAsset(val common.Address) *SyncNativeAssetAta
- func (init *SyncNativeAssetAta) SetMint(val common.Address) *SyncNativeAssetAta
- func (init *SyncNativeAssetAta) SetWarpSolAccount(val common.Address) *SyncNativeAssetAta
- func (init *SyncNativeAssetAta) SetWorker(val common.Address) *SyncNativeAssetAta
- type TransferLamportsToAta
- func (init TransferLamportsToAta) Build() *Instruction
- func (init TransferLamportsToAta) MarshalWithEncoder(encoder *encodbin.Encoder) (err error)
- func (init *TransferLamportsToAta) SetAdministrator(val common.Address) *TransferLamportsToAta
- func (init *TransferLamportsToAta) SetAmount(val uint64) *TransferLamportsToAta
- func (init *TransferLamportsToAta) SetAsset(val common.Address) *TransferLamportsToAta
- func (init *TransferLamportsToAta) SetMint(val common.Address) *TransferLamportsToAta
- func (init *TransferLamportsToAta) SetWarpSolAccount(val common.Address) *TransferLamportsToAta
- func (init *TransferLamportsToAta) SetWorker(val common.Address) *TransferLamportsToAta
Constants ¶
View Source
const ( Discriminator_initialize uint64 = 0xafaf6d1f0d989bed Discriminator_transferLamportsToAta uint64 = 0x19abfdc53787513b Discriminator_syncNativeAta uint64 = 0xf22a38bcd6c68795 Discriminator_proxyOrcaSwap uint64 = 0xddbc843aea104171 Discriminator_proxyRaydiumSwapBaseIn uint64 = 0x1c49426140d5541a )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Initialize ¶
type Initialize struct { //资产账户 Asset common.Address //FeePayer User common.Address //资产合约超级管理员 Administrator common.Address //多签管理员一 SingerA common.Address //多签管理员二 SingerB common.Address //多签管理员三 SingerC common.Address //工作者(主) PrimaryWorker common.Address //工作者(次) SecondaryWorker common.Address base.AccountMetaSlice `bin:"-" borsh_skip:"true"` }
func NewInitInstruction ¶
func NewInitInstructionBuilder ¶
func NewInitInstructionBuilder() *Initialize
func (Initialize) Build ¶
func (init Initialize) Build() *Instruction
func (Initialize) MarshalWithEncoder ¶
func (init Initialize) MarshalWithEncoder(encoder *encodbin.Encoder) (err error)
func (*Initialize) SetAdministrator ¶
func (init *Initialize) SetAdministrator(asset common.Address) *Initialize
合约超级管理员.
func (*Initialize) SetAssetAccount ¶
func (init *Initialize) SetAssetAccount(asset common.Address) *Initialize
资产账户
func (*Initialize) SetPrimaryWorker ¶
func (init *Initialize) SetPrimaryWorker(asset common.Address) *Initialize
工作者(主)
func (*Initialize) SetSecondaryWorker ¶
func (init *Initialize) SetSecondaryWorker(asset common.Address) *Initialize
工作者(副)
func (*Initialize) SetSingerA ¶
func (init *Initialize) SetSingerA(asset common.Address) *Initialize
多签A
func (*Initialize) SetSingerB ¶
func (init *Initialize) SetSingerB(asset common.Address) *Initialize
多签B
func (*Initialize) SetSingerC ¶
func (init *Initialize) SetSingerC(asset common.Address) *Initialize
多签C
func (*Initialize) SetUserAccount ¶
func (init *Initialize) SetUserAccount(asset common.Address) *Initialize
FeePayer
type Instruction ¶
type Instruction struct { encodbin.BaseVariant AssertExecutorProgramID common.Address }
func (*Instruction) Accounts ¶
func (inst *Instruction) Accounts() (out []*base.AccountMeta)
func (*Instruction) Data ¶
func (inst *Instruction) Data() ([]byte, error)
func (*Instruction) MarshalWithEncoder ¶
func (inst *Instruction) MarshalWithEncoder(encoder *encodbin.Encoder) error
func (*Instruction) ProgramID ¶
func (inst *Instruction) ProgramID() common.Address
func (*Instruction) SetProgramID ¶
func (inst *Instruction) SetProgramID(tokenProgramID common.Address)
type ProxyRaydiumSwapBaseIn ¶
type ProxyRaydiumSwapBaseIn struct { AmmProgram common.Address Amm common.Address AmmAuthority common.Address AmmOpenOrders common.Address AmmTargetOrders common.Address AmmCoinVault common.Address AmmPcVault common.Address MarketProgram common.Address Market common.Address MarketBids common.Address MarketAsks common.Address MarketEventQueue common.Address MarketCoinVault common.Address MarketPcVault common.Address MarketVaultSigner common.Address //out by only owner asset ata. UserTokenSource common.Address //in by only owner asset ata. UserTokenDestination common.Address Asset common.Address Administrator common.Address Worker common.Address //交易得到的代币Mint地址,填写错误会导致模拟交易失败! //only destination token mint. Mint common.Address AmountIn uint64 MinimumAmountOut uint64 //当source余额为0时,是否自动关闭ata账户并且返回SOL到Worker. CanClose bool base.AccountMetaSlice `bin:"-" borsh_skip:"true"` }
func NewProxyRaydiumSwapBaseIn ¶
func NewProxyRaydiumSwapBaseIn( AmmProgram common.Address, Amm common.Address, AmmAuthority common.Address, AmmOpenOrders common.Address, AmmTargetOrders common.Address, AmmCoinVault common.Address, AmmPcVault common.Address, MarketProgram common.Address, Market common.Address, MarketBids common.Address, MarketAsks common.Address, MarketEventQueue common.Address, MarketCoinVault common.Address, MarketPcVault common.Address, MarketVaultSigner common.Address, UserTokenSource common.Address, UserTokenDestination common.Address, Asset common.Address, Administrator common.Address, Worker common.Address, Mint common.Address, AmountIn uint64, MinimumAmountOut uint64, CanClose bool, ) *ProxyRaydiumSwapBaseIn
func (ProxyRaydiumSwapBaseIn) Build ¶
func (init ProxyRaydiumSwapBaseIn) Build() *Instruction
func (ProxyRaydiumSwapBaseIn) MarshalWithEncoder ¶
func (init ProxyRaydiumSwapBaseIn) MarshalWithEncoder(encoder *encodbin.Encoder) (err error)
type SyncNativeAssetAta ¶
type SyncNativeAssetAta struct { //资产账户 Asset common.Address //Ata账户(强制owner是Asset) WarpSolAccount common.Address //Mint地址 Mint common.Address //资产账户管理员地址 Administrator common.Address //工作者 Worker common.Address AssociatedTokenProgram common.Address TokenProgram common.Address SystemProgram common.Address base.AccountMetaSlice `bin:"-" borsh_skip:"true"` }
func NewSyncNativeAssetAtaInstructionBuilder ¶
func NewSyncNativeAssetAtaInstructionBuilder() *SyncNativeAssetAta
func (SyncNativeAssetAta) Build ¶
func (init SyncNativeAssetAta) Build() *Instruction
func (SyncNativeAssetAta) MarshalWithEncoder ¶
func (init SyncNativeAssetAta) MarshalWithEncoder(encoder *encodbin.Encoder) (err error)
func (*SyncNativeAssetAta) SetAdministrator ¶
func (init *SyncNativeAssetAta) SetAdministrator(val common.Address) *SyncNativeAssetAta
func (*SyncNativeAssetAta) SetAsset ¶
func (init *SyncNativeAssetAta) SetAsset(val common.Address) *SyncNativeAssetAta
func (*SyncNativeAssetAta) SetMint ¶
func (init *SyncNativeAssetAta) SetMint(val common.Address) *SyncNativeAssetAta
func (*SyncNativeAssetAta) SetWarpSolAccount ¶
func (init *SyncNativeAssetAta) SetWarpSolAccount(val common.Address) *SyncNativeAssetAta
func (*SyncNativeAssetAta) SetWorker ¶
func (init *SyncNativeAssetAta) SetWorker(val common.Address) *SyncNativeAssetAta
type TransferLamportsToAta ¶
type TransferLamportsToAta struct { //资产账户 Asset common.Address //Ata账户(强制owner是Asset) WarpSolAccount common.Address //Mint地址 Mint common.Address //资产账户管理员地址 Administrator common.Address //工作者 Worker common.Address //转移数量 Amount uint64 AssociatedTokenProgram common.Address TokenProgram common.Address SystemProgram common.Address base.AccountMetaSlice `bin:"-" borsh_skip:"true"` }
func NewTransferLamportsToAtaInstructionBuilder ¶
func NewTransferLamportsToAtaInstructionBuilder() *TransferLamportsToAta
func (TransferLamportsToAta) Build ¶
func (init TransferLamportsToAta) Build() *Instruction
func (TransferLamportsToAta) MarshalWithEncoder ¶
func (init TransferLamportsToAta) MarshalWithEncoder(encoder *encodbin.Encoder) (err error)
func (*TransferLamportsToAta) SetAdministrator ¶
func (init *TransferLamportsToAta) SetAdministrator(val common.Address) *TransferLamportsToAta
func (*TransferLamportsToAta) SetAmount ¶
func (init *TransferLamportsToAta) SetAmount(val uint64) *TransferLamportsToAta
func (*TransferLamportsToAta) SetAsset ¶
func (init *TransferLamportsToAta) SetAsset(val common.Address) *TransferLamportsToAta
func (*TransferLamportsToAta) SetMint ¶
func (init *TransferLamportsToAta) SetMint(val common.Address) *TransferLamportsToAta
func (*TransferLamportsToAta) SetWarpSolAccount ¶
func (init *TransferLamportsToAta) SetWarpSolAccount(val common.Address) *TransferLamportsToAta
func (*TransferLamportsToAta) SetWorker ¶
func (init *TransferLamportsToAta) SetWorker(val common.Address) *TransferLamportsToAta
Click to show internal directories.
Click to hide internal directories.