diff --git a/contracts/generated/access_controller/AcceptOwnership.go b/contracts/generated/access_controller/AcceptOwnership.go index 6c5177cde..23541f084 100644 --- a/contracts/generated/access_controller/AcceptOwnership.go +++ b/contracts/generated/access_controller/AcceptOwnership.go @@ -16,7 +16,7 @@ type AcceptOwnership struct { // [0] = [WRITE] state // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewAcceptOwnershipInstructionBuilder creates a new `AcceptOwnership` instruction builder. @@ -35,7 +35,7 @@ func (inst *AcceptOwnership) SetStateAccount(state ag_solanago.PublicKey) *Accep // GetStateAccount gets the "state" account. func (inst *AcceptOwnership) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -46,7 +46,7 @@ func (inst *AcceptOwnership) SetAuthorityAccount(authority ag_solanago.PublicKey // GetAuthorityAccount gets the "authority" account. func (inst *AcceptOwnership) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst AcceptOwnership) Build() *Instruction { @@ -92,8 +92,8 @@ func (inst *AcceptOwnership) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/access_controller/AddAccess.go b/contracts/generated/access_controller/AddAccess.go index 3c7488630..c4506b7ec 100644 --- a/contracts/generated/access_controller/AddAccess.go +++ b/contracts/generated/access_controller/AddAccess.go @@ -18,7 +18,7 @@ type AddAccess struct { // [1] = [SIGNER] owner // // [2] = [] address - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewAddAccessInstructionBuilder creates a new `AddAccess` instruction builder. @@ -37,7 +37,7 @@ func (inst *AddAccess) SetStateAccount(state ag_solanago.PublicKey) *AddAccess { // GetStateAccount gets the "state" account. func (inst *AddAccess) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetOwnerAccount sets the "owner" account. @@ -48,7 +48,7 @@ func (inst *AddAccess) SetOwnerAccount(owner ag_solanago.PublicKey) *AddAccess { // GetOwnerAccount gets the "owner" account. func (inst *AddAccess) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAddressAccount sets the "address" account. @@ -59,7 +59,7 @@ func (inst *AddAccess) SetAddressAccount(address ag_solanago.PublicKey) *AddAcce // GetAddressAccount gets the "address" account. func (inst *AddAccess) GetAddressAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst AddAccess) Build() *Instruction { @@ -108,9 +108,9 @@ func (inst *AddAccess) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("address", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("address", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/access_controller/Initialize.go b/contracts/generated/access_controller/Initialize.go index ce22ef71b..78fbaa644 100644 --- a/contracts/generated/access_controller/Initialize.go +++ b/contracts/generated/access_controller/Initialize.go @@ -16,7 +16,7 @@ type Initialize struct { // [0] = [WRITE] state // // [1] = [SIGNER] owner - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewInitializeInstructionBuilder creates a new `Initialize` instruction builder. @@ -35,7 +35,7 @@ func (inst *Initialize) SetStateAccount(state ag_solanago.PublicKey) *Initialize // GetStateAccount gets the "state" account. func (inst *Initialize) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetOwnerAccount sets the "owner" account. @@ -46,7 +46,7 @@ func (inst *Initialize) SetOwnerAccount(owner ag_solanago.PublicKey) *Initialize // GetOwnerAccount gets the "owner" account. func (inst *Initialize) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst Initialize) Build() *Instruction { @@ -92,8 +92,8 @@ func (inst *Initialize) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta("state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("owner", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta("state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("owner", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/access_controller/RemoveAccess.go b/contracts/generated/access_controller/RemoveAccess.go index 567a66b5a..31bafb811 100644 --- a/contracts/generated/access_controller/RemoveAccess.go +++ b/contracts/generated/access_controller/RemoveAccess.go @@ -18,7 +18,7 @@ type RemoveAccess struct { // [1] = [SIGNER] owner // // [2] = [] address - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewRemoveAccessInstructionBuilder creates a new `RemoveAccess` instruction builder. @@ -37,7 +37,7 @@ func (inst *RemoveAccess) SetStateAccount(state ag_solanago.PublicKey) *RemoveAc // GetStateAccount gets the "state" account. func (inst *RemoveAccess) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetOwnerAccount sets the "owner" account. @@ -48,7 +48,7 @@ func (inst *RemoveAccess) SetOwnerAccount(owner ag_solanago.PublicKey) *RemoveAc // GetOwnerAccount gets the "owner" account. func (inst *RemoveAccess) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAddressAccount sets the "address" account. @@ -59,7 +59,7 @@ func (inst *RemoveAccess) SetAddressAccount(address ag_solanago.PublicKey) *Remo // GetAddressAccount gets the "address" account. func (inst *RemoveAccess) GetAddressAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst RemoveAccess) Build() *Instruction { @@ -108,9 +108,9 @@ func (inst *RemoveAccess) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("address", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("address", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/access_controller/TransferOwnership.go b/contracts/generated/access_controller/TransferOwnership.go index c6b8f3f50..e057d2030 100644 --- a/contracts/generated/access_controller/TransferOwnership.go +++ b/contracts/generated/access_controller/TransferOwnership.go @@ -17,7 +17,7 @@ type TransferOwnership struct { // [0] = [WRITE] state // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewTransferOwnershipInstructionBuilder creates a new `TransferOwnership` instruction builder. @@ -42,7 +42,7 @@ func (inst *TransferOwnership) SetStateAccount(state ag_solanago.PublicKey) *Tra // GetStateAccount gets the "state" account. func (inst *TransferOwnership) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -53,7 +53,7 @@ func (inst *TransferOwnership) SetAuthorityAccount(authority ag_solanago.PublicK // GetAuthorityAccount gets the "authority" account. func (inst *TransferOwnership) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst TransferOwnership) Build() *Instruction { @@ -108,8 +108,8 @@ func (inst *TransferOwnership) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/ocr2/AcceptOwnership.go b/contracts/generated/ocr2/AcceptOwnership.go index 666a8211b..aec920ac5 100644 --- a/contracts/generated/ocr2/AcceptOwnership.go +++ b/contracts/generated/ocr2/AcceptOwnership.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -16,7 +16,7 @@ type AcceptOwnership struct { // [0] = [WRITE] state // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewAcceptOwnershipInstructionBuilder creates a new `AcceptOwnership` instruction builder. @@ -35,7 +35,7 @@ func (inst *AcceptOwnership) SetStateAccount(state ag_solanago.PublicKey) *Accep // GetStateAccount gets the "state" account. func (inst *AcceptOwnership) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -46,7 +46,7 @@ func (inst *AcceptOwnership) SetAuthorityAccount(authority ag_solanago.PublicKey // GetAuthorityAccount gets the "authority" account. func (inst *AcceptOwnership) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst AcceptOwnership) Build() *Instruction { @@ -92,8 +92,8 @@ func (inst *AcceptOwnership) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/ocr2/AcceptOwnership_test.go b/contracts/generated/ocr2/AcceptOwnership_test.go index 4771fa165..d3776ba67 100644 --- a/contracts/generated/ocr2/AcceptOwnership_test.go +++ b/contracts/generated/ocr2/AcceptOwnership_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/AcceptPayeeship.go b/contracts/generated/ocr2/AcceptPayeeship.go index 95ae73dc3..80913b2c3 100644 --- a/contracts/generated/ocr2/AcceptPayeeship.go +++ b/contracts/generated/ocr2/AcceptPayeeship.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -20,7 +20,7 @@ type AcceptPayeeship struct { // [2] = [] transmitter // // [3] = [] proposedPayee - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewAcceptPayeeshipInstructionBuilder creates a new `AcceptPayeeship` instruction builder. @@ -39,7 +39,7 @@ func (inst *AcceptPayeeship) SetStateAccount(state ag_solanago.PublicKey) *Accep // GetStateAccount gets the "state" account. func (inst *AcceptPayeeship) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -50,7 +50,7 @@ func (inst *AcceptPayeeship) SetAuthorityAccount(authority ag_solanago.PublicKey // GetAuthorityAccount gets the "authority" account. func (inst *AcceptPayeeship) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetTransmitterAccount sets the "transmitter" account. @@ -61,7 +61,7 @@ func (inst *AcceptPayeeship) SetTransmitterAccount(transmitter ag_solanago.Publi // GetTransmitterAccount gets the "transmitter" account. func (inst *AcceptPayeeship) GetTransmitterAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetProposedPayeeAccount sets the "proposedPayee" account. @@ -72,7 +72,7 @@ func (inst *AcceptPayeeship) SetProposedPayeeAccount(proposedPayee ag_solanago.P // GetProposedPayeeAccount gets the "proposedPayee" account. func (inst *AcceptPayeeship) GetProposedPayeeAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } func (inst AcceptPayeeship) Build() *Instruction { @@ -124,10 +124,10 @@ func (inst *AcceptPayeeship) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=4]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta(" transmitter", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta("proposedPayee", inst.AccountMetaSlice[3])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta(" transmitter", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta("proposedPayee", inst.AccountMetaSlice.Get(3))) }) }) }) diff --git a/contracts/generated/ocr2/AcceptPayeeship_test.go b/contracts/generated/ocr2/AcceptPayeeship_test.go index 6a8f5c967..66ef97b2a 100644 --- a/contracts/generated/ocr2/AcceptPayeeship_test.go +++ b/contracts/generated/ocr2/AcceptPayeeship_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/AcceptProposal.go b/contracts/generated/ocr2/AcceptProposal.go index af4398090..9b5fb37ed 100644 --- a/contracts/generated/ocr2/AcceptProposal.go +++ b/contracts/generated/ocr2/AcceptProposal.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -27,7 +27,7 @@ type AcceptProposal struct { // [5] = [] vaultAuthority // // [6] = [] tokenProgram - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewAcceptProposalInstructionBuilder creates a new `AcceptProposal` instruction builder. @@ -52,7 +52,7 @@ func (inst *AcceptProposal) SetStateAccount(state ag_solanago.PublicKey) *Accept // GetStateAccount gets the "state" account. func (inst *AcceptProposal) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetProposalAccount sets the "proposal" account. @@ -63,7 +63,7 @@ func (inst *AcceptProposal) SetProposalAccount(proposal ag_solanago.PublicKey) * // GetProposalAccount gets the "proposal" account. func (inst *AcceptProposal) GetProposalAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetReceiverAccount sets the "receiver" account. @@ -74,7 +74,7 @@ func (inst *AcceptProposal) SetReceiverAccount(receiver ag_solanago.PublicKey) * // GetReceiverAccount gets the "receiver" account. func (inst *AcceptProposal) GetReceiverAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetAuthorityAccount sets the "authority" account. @@ -85,7 +85,7 @@ func (inst *AcceptProposal) SetAuthorityAccount(authority ag_solanago.PublicKey) // GetAuthorityAccount gets the "authority" account. func (inst *AcceptProposal) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } // SetTokenVaultAccount sets the "tokenVault" account. @@ -96,7 +96,7 @@ func (inst *AcceptProposal) SetTokenVaultAccount(tokenVault ag_solanago.PublicKe // GetTokenVaultAccount gets the "tokenVault" account. func (inst *AcceptProposal) GetTokenVaultAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[4] + return inst.AccountMetaSlice.Get(4) } // SetVaultAuthorityAccount sets the "vaultAuthority" account. @@ -107,7 +107,7 @@ func (inst *AcceptProposal) SetVaultAuthorityAccount(vaultAuthority ag_solanago. // GetVaultAuthorityAccount gets the "vaultAuthority" account. func (inst *AcceptProposal) GetVaultAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[5] + return inst.AccountMetaSlice.Get(5) } // SetTokenProgramAccount sets the "tokenProgram" account. @@ -118,7 +118,7 @@ func (inst *AcceptProposal) SetTokenProgramAccount(tokenProgram ag_solanago.Publ // GetTokenProgramAccount gets the "tokenProgram" account. func (inst *AcceptProposal) GetTokenProgramAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[6] + return inst.AccountMetaSlice.Get(6) } func (inst AcceptProposal) Build() *Instruction { @@ -188,13 +188,13 @@ func (inst *AcceptProposal) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=7]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta(" receiver", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[3])) - accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice[4])) - accountsBranch.Child(ag_format.Meta("vaultAuthority", inst.AccountMetaSlice[5])) - accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice[6])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta(" receiver", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(3))) + accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice.Get(4))) + accountsBranch.Child(ag_format.Meta("vaultAuthority", inst.AccountMetaSlice.Get(5))) + accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice.Get(6))) }) }) }) diff --git a/contracts/generated/ocr2/AcceptProposal_test.go b/contracts/generated/ocr2/AcceptProposal_test.go index 71e1660a0..1d085aff5 100644 --- a/contracts/generated/ocr2/AcceptProposal_test.go +++ b/contracts/generated/ocr2/AcceptProposal_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/Close.go b/contracts/generated/ocr2/Close.go index f4dfe5f16..1018424d3 100644 --- a/contracts/generated/ocr2/Close.go +++ b/contracts/generated/ocr2/Close.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -24,7 +24,7 @@ type Close struct { // [4] = [] vaultAuthority // // [5] = [] tokenProgram - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewCloseInstructionBuilder creates a new `Close` instruction builder. @@ -43,7 +43,7 @@ func (inst *Close) SetStateAccount(state ag_solanago.PublicKey) *Close { // GetStateAccount gets the "state" account. func (inst *Close) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetReceiverAccount sets the "receiver" account. @@ -54,7 +54,7 @@ func (inst *Close) SetReceiverAccount(receiver ag_solanago.PublicKey) *Close { // GetReceiverAccount gets the "receiver" account. func (inst *Close) GetReceiverAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAuthorityAccount sets the "authority" account. @@ -65,7 +65,7 @@ func (inst *Close) SetAuthorityAccount(authority ag_solanago.PublicKey) *Close { // GetAuthorityAccount gets the "authority" account. func (inst *Close) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetTokenVaultAccount sets the "tokenVault" account. @@ -76,7 +76,7 @@ func (inst *Close) SetTokenVaultAccount(tokenVault ag_solanago.PublicKey) *Close // GetTokenVaultAccount gets the "tokenVault" account. func (inst *Close) GetTokenVaultAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } // SetVaultAuthorityAccount sets the "vaultAuthority" account. @@ -87,7 +87,7 @@ func (inst *Close) SetVaultAuthorityAccount(vaultAuthority ag_solanago.PublicKey // GetVaultAuthorityAccount gets the "vaultAuthority" account. func (inst *Close) GetVaultAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[4] + return inst.AccountMetaSlice.Get(4) } // SetTokenProgramAccount sets the "tokenProgram" account. @@ -98,7 +98,7 @@ func (inst *Close) SetTokenProgramAccount(tokenProgram ag_solanago.PublicKey) *C // GetTokenProgramAccount gets the "tokenProgram" account. func (inst *Close) GetTokenProgramAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[5] + return inst.AccountMetaSlice.Get(5) } func (inst Close) Build() *Instruction { @@ -156,12 +156,12 @@ func (inst *Close) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=6]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" receiver", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice[3])) - accountsBranch.Child(ag_format.Meta("vaultAuthority", inst.AccountMetaSlice[4])) - accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice[5])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" receiver", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice.Get(3))) + accountsBranch.Child(ag_format.Meta("vaultAuthority", inst.AccountMetaSlice.Get(4))) + accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice.Get(5))) }) }) }) diff --git a/contracts/generated/ocr2/CloseProposal.go b/contracts/generated/ocr2/CloseProposal.go index 3f852ecf3..1adb45395 100644 --- a/contracts/generated/ocr2/CloseProposal.go +++ b/contracts/generated/ocr2/CloseProposal.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -18,7 +18,7 @@ type CloseProposal struct { // [1] = [WRITE] receiver // // [2] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewCloseProposalInstructionBuilder creates a new `CloseProposal` instruction builder. @@ -37,7 +37,7 @@ func (inst *CloseProposal) SetProposalAccount(proposal ag_solanago.PublicKey) *C // GetProposalAccount gets the "proposal" account. func (inst *CloseProposal) GetProposalAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetReceiverAccount sets the "receiver" account. @@ -48,7 +48,7 @@ func (inst *CloseProposal) SetReceiverAccount(receiver ag_solanago.PublicKey) *C // GetReceiverAccount gets the "receiver" account. func (inst *CloseProposal) GetReceiverAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAuthorityAccount sets the "authority" account. @@ -59,7 +59,7 @@ func (inst *CloseProposal) SetAuthorityAccount(authority ag_solanago.PublicKey) // GetAuthorityAccount gets the "authority" account. func (inst *CloseProposal) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst CloseProposal) Build() *Instruction { @@ -108,9 +108,9 @@ func (inst *CloseProposal) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" receiver", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" receiver", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/ocr2/CloseProposal_test.go b/contracts/generated/ocr2/CloseProposal_test.go index 80ffba3e6..205f1cf25 100644 --- a/contracts/generated/ocr2/CloseProposal_test.go +++ b/contracts/generated/ocr2/CloseProposal_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/Close_test.go b/contracts/generated/ocr2/Close_test.go index 43c83073c..1dd86086b 100644 --- a/contracts/generated/ocr2/Close_test.go +++ b/contracts/generated/ocr2/Close_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/CreateProposal.go b/contracts/generated/ocr2/CreateProposal.go index 9ed55f296..de9df7930 100644 --- a/contracts/generated/ocr2/CreateProposal.go +++ b/contracts/generated/ocr2/CreateProposal.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -17,7 +17,7 @@ type CreateProposal struct { // [0] = [WRITE] proposal // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewCreateProposalInstructionBuilder creates a new `CreateProposal` instruction builder. @@ -42,7 +42,7 @@ func (inst *CreateProposal) SetProposalAccount(proposal ag_solanago.PublicKey) * // GetProposalAccount gets the "proposal" account. func (inst *CreateProposal) GetProposalAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -53,7 +53,7 @@ func (inst *CreateProposal) SetAuthorityAccount(authority ag_solanago.PublicKey) // GetAuthorityAccount gets the "authority" account. func (inst *CreateProposal) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst CreateProposal) Build() *Instruction { @@ -108,8 +108,8 @@ func (inst *CreateProposal) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/ocr2/CreateProposal_test.go b/contracts/generated/ocr2/CreateProposal_test.go index 7c769350b..89f18f149 100644 --- a/contracts/generated/ocr2/CreateProposal_test.go +++ b/contracts/generated/ocr2/CreateProposal_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/FinalizeProposal.go b/contracts/generated/ocr2/FinalizeProposal.go index 92bad057c..5abd17d97 100644 --- a/contracts/generated/ocr2/FinalizeProposal.go +++ b/contracts/generated/ocr2/FinalizeProposal.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -16,7 +16,7 @@ type FinalizeProposal struct { // [0] = [WRITE] proposal // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewFinalizeProposalInstructionBuilder creates a new `FinalizeProposal` instruction builder. @@ -35,7 +35,7 @@ func (inst *FinalizeProposal) SetProposalAccount(proposal ag_solanago.PublicKey) // GetProposalAccount gets the "proposal" account. func (inst *FinalizeProposal) GetProposalAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -46,7 +46,7 @@ func (inst *FinalizeProposal) SetAuthorityAccount(authority ag_solanago.PublicKe // GetAuthorityAccount gets the "authority" account. func (inst *FinalizeProposal) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst FinalizeProposal) Build() *Instruction { @@ -92,8 +92,8 @@ func (inst *FinalizeProposal) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/ocr2/FinalizeProposal_test.go b/contracts/generated/ocr2/FinalizeProposal_test.go index 04552a616..43e74f84b 100644 --- a/contracts/generated/ocr2/FinalizeProposal_test.go +++ b/contracts/generated/ocr2/FinalizeProposal_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/Initialize.go b/contracts/generated/ocr2/Initialize.go index 472075dd2..b9cf89e98 100644 --- a/contracts/generated/ocr2/Initialize.go +++ b/contracts/generated/ocr2/Initialize.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -40,7 +40,7 @@ type Initialize struct { // [11] = [] tokenProgram // // [12] = [] associatedTokenProgram - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewInitializeInstructionBuilder creates a new `Initialize` instruction builder. @@ -71,7 +71,7 @@ func (inst *Initialize) SetStateAccount(state ag_solanago.PublicKey) *Initialize // GetStateAccount gets the "state" account. func (inst *Initialize) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetFeedAccount sets the "feed" account. @@ -82,7 +82,7 @@ func (inst *Initialize) SetFeedAccount(feed ag_solanago.PublicKey) *Initialize { // GetFeedAccount gets the "feed" account. func (inst *Initialize) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetPayerAccount sets the "payer" account. @@ -93,7 +93,7 @@ func (inst *Initialize) SetPayerAccount(payer ag_solanago.PublicKey) *Initialize // GetPayerAccount gets the "payer" account. func (inst *Initialize) GetPayerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetOwnerAccount sets the "owner" account. @@ -104,7 +104,7 @@ func (inst *Initialize) SetOwnerAccount(owner ag_solanago.PublicKey) *Initialize // GetOwnerAccount gets the "owner" account. func (inst *Initialize) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } // SetTokenMintAccount sets the "tokenMint" account. @@ -115,7 +115,7 @@ func (inst *Initialize) SetTokenMintAccount(tokenMint ag_solanago.PublicKey) *In // GetTokenMintAccount gets the "tokenMint" account. func (inst *Initialize) GetTokenMintAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[4] + return inst.AccountMetaSlice.Get(4) } // SetTokenVaultAccount sets the "tokenVault" account. @@ -126,7 +126,7 @@ func (inst *Initialize) SetTokenVaultAccount(tokenVault ag_solanago.PublicKey) * // GetTokenVaultAccount gets the "tokenVault" account. func (inst *Initialize) GetTokenVaultAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[5] + return inst.AccountMetaSlice.Get(5) } // SetVaultAuthorityAccount sets the "vaultAuthority" account. @@ -137,7 +137,7 @@ func (inst *Initialize) SetVaultAuthorityAccount(vaultAuthority ag_solanago.Publ // GetVaultAuthorityAccount gets the "vaultAuthority" account. func (inst *Initialize) GetVaultAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[6] + return inst.AccountMetaSlice.Get(6) } // SetRequesterAccessControllerAccount sets the "requesterAccessController" account. @@ -148,7 +148,7 @@ func (inst *Initialize) SetRequesterAccessControllerAccount(requesterAccessContr // GetRequesterAccessControllerAccount gets the "requesterAccessController" account. func (inst *Initialize) GetRequesterAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[7] + return inst.AccountMetaSlice.Get(7) } // SetBillingAccessControllerAccount sets the "billingAccessController" account. @@ -159,7 +159,7 @@ func (inst *Initialize) SetBillingAccessControllerAccount(billingAccessControlle // GetBillingAccessControllerAccount gets the "billingAccessController" account. func (inst *Initialize) GetBillingAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[8] + return inst.AccountMetaSlice.Get(8) } // SetRentAccount sets the "rent" account. @@ -170,7 +170,7 @@ func (inst *Initialize) SetRentAccount(rent ag_solanago.PublicKey) *Initialize { // GetRentAccount gets the "rent" account. func (inst *Initialize) GetRentAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[9] + return inst.AccountMetaSlice.Get(9) } // SetSystemProgramAccount sets the "systemProgram" account. @@ -181,7 +181,7 @@ func (inst *Initialize) SetSystemProgramAccount(systemProgram ag_solanago.Public // GetSystemProgramAccount gets the "systemProgram" account. func (inst *Initialize) GetSystemProgramAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[10] + return inst.AccountMetaSlice.Get(10) } // SetTokenProgramAccount sets the "tokenProgram" account. @@ -192,7 +192,7 @@ func (inst *Initialize) SetTokenProgramAccount(tokenProgram ag_solanago.PublicKe // GetTokenProgramAccount gets the "tokenProgram" account. func (inst *Initialize) GetTokenProgramAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[11] + return inst.AccountMetaSlice.Get(11) } // SetAssociatedTokenProgramAccount sets the "associatedTokenProgram" account. @@ -203,7 +203,7 @@ func (inst *Initialize) SetAssociatedTokenProgramAccount(associatedTokenProgram // GetAssociatedTokenProgramAccount gets the "associatedTokenProgram" account. func (inst *Initialize) GetAssociatedTokenProgramAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[12] + return inst.AccountMetaSlice.Get(12) } func (inst Initialize) Build() *Instruction { @@ -295,19 +295,19 @@ func (inst *Initialize) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=13]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta(" payer", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice[3])) - accountsBranch.Child(ag_format.Meta(" tokenMint", inst.AccountMetaSlice[4])) - accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice[5])) - accountsBranch.Child(ag_format.Meta(" vaultAuthority", inst.AccountMetaSlice[6])) - accountsBranch.Child(ag_format.Meta("requesterAccessController", inst.AccountMetaSlice[7])) - accountsBranch.Child(ag_format.Meta(" billingAccessController", inst.AccountMetaSlice[8])) - accountsBranch.Child(ag_format.Meta(" rent", inst.AccountMetaSlice[9])) - accountsBranch.Child(ag_format.Meta(" systemProgram", inst.AccountMetaSlice[10])) - accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice[11])) - accountsBranch.Child(ag_format.Meta(" associatedTokenProgram", inst.AccountMetaSlice[12])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta(" payer", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice.Get(3))) + accountsBranch.Child(ag_format.Meta(" tokenMint", inst.AccountMetaSlice.Get(4))) + accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice.Get(5))) + accountsBranch.Child(ag_format.Meta(" vaultAuthority", inst.AccountMetaSlice.Get(6))) + accountsBranch.Child(ag_format.Meta("requesterAccessController", inst.AccountMetaSlice.Get(7))) + accountsBranch.Child(ag_format.Meta(" billingAccessController", inst.AccountMetaSlice.Get(8))) + accountsBranch.Child(ag_format.Meta(" rent", inst.AccountMetaSlice.Get(9))) + accountsBranch.Child(ag_format.Meta(" systemProgram", inst.AccountMetaSlice.Get(10))) + accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice.Get(11))) + accountsBranch.Child(ag_format.Meta(" associatedTokenProgram", inst.AccountMetaSlice.Get(12))) }) }) }) diff --git a/contracts/generated/ocr2/Initialize_test.go b/contracts/generated/ocr2/Initialize_test.go index e007c15fe..d87fdfea9 100644 --- a/contracts/generated/ocr2/Initialize_test.go +++ b/contracts/generated/ocr2/Initialize_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/PayOracles.go b/contracts/generated/ocr2/PayOracles.go index 9a6a69a5f..dfd8762bc 100644 --- a/contracts/generated/ocr2/PayOracles.go +++ b/contracts/generated/ocr2/PayOracles.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -24,7 +24,7 @@ type PayOracles struct { // [4] = [] vaultAuthority // // [5] = [] tokenProgram - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewPayOraclesInstructionBuilder creates a new `PayOracles` instruction builder. @@ -43,7 +43,7 @@ func (inst *PayOracles) SetStateAccount(state ag_solanago.PublicKey) *PayOracles // GetStateAccount gets the "state" account. func (inst *PayOracles) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -54,7 +54,7 @@ func (inst *PayOracles) SetAuthorityAccount(authority ag_solanago.PublicKey) *Pa // GetAuthorityAccount gets the "authority" account. func (inst *PayOracles) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAccessControllerAccount sets the "accessController" account. @@ -65,7 +65,7 @@ func (inst *PayOracles) SetAccessControllerAccount(accessController ag_solanago. // GetAccessControllerAccount gets the "accessController" account. func (inst *PayOracles) GetAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetTokenVaultAccount sets the "tokenVault" account. @@ -76,7 +76,7 @@ func (inst *PayOracles) SetTokenVaultAccount(tokenVault ag_solanago.PublicKey) * // GetTokenVaultAccount gets the "tokenVault" account. func (inst *PayOracles) GetTokenVaultAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } // SetVaultAuthorityAccount sets the "vaultAuthority" account. @@ -87,7 +87,7 @@ func (inst *PayOracles) SetVaultAuthorityAccount(vaultAuthority ag_solanago.Publ // GetVaultAuthorityAccount gets the "vaultAuthority" account. func (inst *PayOracles) GetVaultAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[4] + return inst.AccountMetaSlice.Get(4) } // SetTokenProgramAccount sets the "tokenProgram" account. @@ -98,7 +98,7 @@ func (inst *PayOracles) SetTokenProgramAccount(tokenProgram ag_solanago.PublicKe // GetTokenProgramAccount gets the "tokenProgram" account. func (inst *PayOracles) GetTokenProgramAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[5] + return inst.AccountMetaSlice.Get(5) } func (inst PayOracles) Build() *Instruction { @@ -156,12 +156,12 @@ func (inst *PayOracles) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=6]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice[3])) - accountsBranch.Child(ag_format.Meta(" vaultAuthority", inst.AccountMetaSlice[4])) - accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice[5])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice.Get(3))) + accountsBranch.Child(ag_format.Meta(" vaultAuthority", inst.AccountMetaSlice.Get(4))) + accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice.Get(5))) }) }) }) diff --git a/contracts/generated/ocr2/PayOracles_test.go b/contracts/generated/ocr2/PayOracles_test.go index 9755c339c..ce8dbdb81 100644 --- a/contracts/generated/ocr2/PayOracles_test.go +++ b/contracts/generated/ocr2/PayOracles_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/ProposeConfig.go b/contracts/generated/ocr2/ProposeConfig.go index 4fb2783d9..468c428d6 100644 --- a/contracts/generated/ocr2/ProposeConfig.go +++ b/contracts/generated/ocr2/ProposeConfig.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -18,7 +18,7 @@ type ProposeConfig struct { // [0] = [WRITE] proposal // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewProposeConfigInstructionBuilder creates a new `ProposeConfig` instruction builder. @@ -49,7 +49,7 @@ func (inst *ProposeConfig) SetProposalAccount(proposal ag_solanago.PublicKey) *P // GetProposalAccount gets the "proposal" account. func (inst *ProposeConfig) GetProposalAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -60,7 +60,7 @@ func (inst *ProposeConfig) SetAuthorityAccount(authority ag_solanago.PublicKey) // GetAuthorityAccount gets the "authority" account. func (inst *ProposeConfig) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst ProposeConfig) Build() *Instruction { @@ -119,8 +119,8 @@ func (inst *ProposeConfig) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/ocr2/ProposeConfig_test.go b/contracts/generated/ocr2/ProposeConfig_test.go index 202ff02aa..937c5ef48 100644 --- a/contracts/generated/ocr2/ProposeConfig_test.go +++ b/contracts/generated/ocr2/ProposeConfig_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/ProposePayees.go b/contracts/generated/ocr2/ProposePayees.go index 9d7f461a6..f6bec3bd1 100644 --- a/contracts/generated/ocr2/ProposePayees.go +++ b/contracts/generated/ocr2/ProposePayees.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -13,12 +13,11 @@ import ( // ProposePayees is the `proposePayees` instruction. type ProposePayees struct { TokenMint *ag_solanago.PublicKey - Payees *[]ag_solanago.PublicKey // [0] = [WRITE] proposal // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewProposePayeesInstructionBuilder creates a new `ProposePayees` instruction builder. @@ -35,12 +34,6 @@ func (inst *ProposePayees) SetTokenMint(tokenMint ag_solanago.PublicKey) *Propos return inst } -// SetPayees sets the "payees" parameter. -func (inst *ProposePayees) SetPayees(payees []ag_solanago.PublicKey) *ProposePayees { - inst.Payees = &payees - return inst -} - // SetProposalAccount sets the "proposal" account. func (inst *ProposePayees) SetProposalAccount(proposal ag_solanago.PublicKey) *ProposePayees { inst.AccountMetaSlice[0] = ag_solanago.Meta(proposal).WRITE() @@ -49,7 +42,7 @@ func (inst *ProposePayees) SetProposalAccount(proposal ag_solanago.PublicKey) *P // GetProposalAccount gets the "proposal" account. func (inst *ProposePayees) GetProposalAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -60,7 +53,7 @@ func (inst *ProposePayees) SetAuthorityAccount(authority ag_solanago.PublicKey) // GetAuthorityAccount gets the "authority" account. func (inst *ProposePayees) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst ProposePayees) Build() *Instruction { @@ -86,9 +79,6 @@ func (inst *ProposePayees) Validate() error { if inst.TokenMint == nil { return errors.New("TokenMint parameter is not set") } - if inst.Payees == nil { - return errors.New("Payees parameter is not set") - } } // Check whether all (required) accounts are set: @@ -112,15 +102,14 @@ func (inst *ProposePayees) EncodeToTree(parent ag_treeout.Branches) { ParentFunc(func(instructionBranch ag_treeout.Branches) { // Parameters of the instruction: - instructionBranch.Child("Params[len=2]").ParentFunc(func(paramsBranch ag_treeout.Branches) { + instructionBranch.Child("Params[len=1]").ParentFunc(func(paramsBranch ag_treeout.Branches) { paramsBranch.Child(ag_format.Param("TokenMint", *inst.TokenMint)) - paramsBranch.Child(ag_format.Param(" Payees", *inst.Payees)) }) // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) @@ -132,11 +121,6 @@ func (obj ProposePayees) MarshalWithEncoder(encoder *ag_binary.Encoder) (err err if err != nil { return err } - // Serialize `Payees` param: - err = encoder.Encode(obj.Payees) - if err != nil { - return err - } return nil } func (obj *ProposePayees) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { @@ -145,11 +129,6 @@ func (obj *ProposePayees) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err if err != nil { return err } - // Deserialize `Payees`: - err = decoder.Decode(&obj.Payees) - if err != nil { - return err - } return nil } @@ -157,13 +136,11 @@ func (obj *ProposePayees) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err func NewProposePayeesInstruction( // Parameters: tokenMint ag_solanago.PublicKey, - payees []ag_solanago.PublicKey, // Accounts: proposal ag_solanago.PublicKey, authority ag_solanago.PublicKey) *ProposePayees { return NewProposePayeesInstructionBuilder(). SetTokenMint(tokenMint). - SetPayees(payees). SetProposalAccount(proposal). SetAuthorityAccount(authority) } diff --git a/contracts/generated/ocr2/ProposePayees_test.go b/contracts/generated/ocr2/ProposePayees_test.go index e481ff962..fff1d8e90 100644 --- a/contracts/generated/ocr2/ProposePayees_test.go +++ b/contracts/generated/ocr2/ProposePayees_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/RequestNewRound.go b/contracts/generated/ocr2/RequestNewRound.go index 123222300..62a9dd07f 100644 --- a/contracts/generated/ocr2/RequestNewRound.go +++ b/contracts/generated/ocr2/RequestNewRound.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -18,7 +18,7 @@ type RequestNewRound struct { // [1] = [SIGNER] authority // // [2] = [] accessController - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewRequestNewRoundInstructionBuilder creates a new `RequestNewRound` instruction builder. @@ -37,7 +37,7 @@ func (inst *RequestNewRound) SetStateAccount(state ag_solanago.PublicKey) *Reque // GetStateAccount gets the "state" account. func (inst *RequestNewRound) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -48,7 +48,7 @@ func (inst *RequestNewRound) SetAuthorityAccount(authority ag_solanago.PublicKey // GetAuthorityAccount gets the "authority" account. func (inst *RequestNewRound) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAccessControllerAccount sets the "accessController" account. @@ -59,7 +59,7 @@ func (inst *RequestNewRound) SetAccessControllerAccount(accessController ag_sola // GetAccessControllerAccount gets the "accessController" account. func (inst *RequestNewRound) GetAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst RequestNewRound) Build() *Instruction { @@ -108,9 +108,9 @@ func (inst *RequestNewRound) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/ocr2/RequestNewRound_test.go b/contracts/generated/ocr2/RequestNewRound_test.go index 16ba010d8..fa5cd68a3 100644 --- a/contracts/generated/ocr2/RequestNewRound_test.go +++ b/contracts/generated/ocr2/RequestNewRound_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/SetBilling.go b/contracts/generated/ocr2/SetBilling.go index 1256c86dc..ba9e79ce9 100644 --- a/contracts/generated/ocr2/SetBilling.go +++ b/contracts/generated/ocr2/SetBilling.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -26,7 +26,7 @@ type SetBilling struct { // [4] = [] vaultAuthority // // [5] = [] tokenProgram - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewSetBillingInstructionBuilder creates a new `SetBilling` instruction builder. @@ -57,7 +57,7 @@ func (inst *SetBilling) SetStateAccount(state ag_solanago.PublicKey) *SetBilling // GetStateAccount gets the "state" account. func (inst *SetBilling) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -68,7 +68,7 @@ func (inst *SetBilling) SetAuthorityAccount(authority ag_solanago.PublicKey) *Se // GetAuthorityAccount gets the "authority" account. func (inst *SetBilling) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAccessControllerAccount sets the "accessController" account. @@ -79,7 +79,7 @@ func (inst *SetBilling) SetAccessControllerAccount(accessController ag_solanago. // GetAccessControllerAccount gets the "accessController" account. func (inst *SetBilling) GetAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetTokenVaultAccount sets the "tokenVault" account. @@ -90,7 +90,7 @@ func (inst *SetBilling) SetTokenVaultAccount(tokenVault ag_solanago.PublicKey) * // GetTokenVaultAccount gets the "tokenVault" account. func (inst *SetBilling) GetTokenVaultAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } // SetVaultAuthorityAccount sets the "vaultAuthority" account. @@ -101,7 +101,7 @@ func (inst *SetBilling) SetVaultAuthorityAccount(vaultAuthority ag_solanago.Publ // GetVaultAuthorityAccount gets the "vaultAuthority" account. func (inst *SetBilling) GetVaultAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[4] + return inst.AccountMetaSlice.Get(4) } // SetTokenProgramAccount sets the "tokenProgram" account. @@ -112,7 +112,7 @@ func (inst *SetBilling) SetTokenProgramAccount(tokenProgram ag_solanago.PublicKe // GetTokenProgramAccount gets the "tokenProgram" account. func (inst *SetBilling) GetTokenProgramAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[5] + return inst.AccountMetaSlice.Get(5) } func (inst SetBilling) Build() *Instruction { @@ -183,12 +183,12 @@ func (inst *SetBilling) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=6]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice[3])) - accountsBranch.Child(ag_format.Meta(" vaultAuthority", inst.AccountMetaSlice[4])) - accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice[5])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice.Get(3))) + accountsBranch.Child(ag_format.Meta(" vaultAuthority", inst.AccountMetaSlice.Get(4))) + accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice.Get(5))) }) }) }) diff --git a/contracts/generated/ocr2/SetBillingAccessController.go b/contracts/generated/ocr2/SetBillingAccessController.go index 89017f089..34b0392ac 100644 --- a/contracts/generated/ocr2/SetBillingAccessController.go +++ b/contracts/generated/ocr2/SetBillingAccessController.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -18,7 +18,7 @@ type SetBillingAccessController struct { // [1] = [SIGNER] authority // // [2] = [] accessController - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewSetBillingAccessControllerInstructionBuilder creates a new `SetBillingAccessController` instruction builder. @@ -37,7 +37,7 @@ func (inst *SetBillingAccessController) SetStateAccount(state ag_solanago.Public // GetStateAccount gets the "state" account. func (inst *SetBillingAccessController) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -48,7 +48,7 @@ func (inst *SetBillingAccessController) SetAuthorityAccount(authority ag_solanag // GetAuthorityAccount gets the "authority" account. func (inst *SetBillingAccessController) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAccessControllerAccount sets the "accessController" account. @@ -59,7 +59,7 @@ func (inst *SetBillingAccessController) SetAccessControllerAccount(accessControl // GetAccessControllerAccount gets the "accessController" account. func (inst *SetBillingAccessController) GetAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst SetBillingAccessController) Build() *Instruction { @@ -108,9 +108,9 @@ func (inst *SetBillingAccessController) EncodeToTree(parent ag_treeout.Branches) // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/ocr2/SetBillingAccessController_test.go b/contracts/generated/ocr2/SetBillingAccessController_test.go index 2c6efde1f..4d73910ac 100644 --- a/contracts/generated/ocr2/SetBillingAccessController_test.go +++ b/contracts/generated/ocr2/SetBillingAccessController_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/SetBilling_test.go b/contracts/generated/ocr2/SetBilling_test.go index e4d00c397..84882d6a7 100644 --- a/contracts/generated/ocr2/SetBilling_test.go +++ b/contracts/generated/ocr2/SetBilling_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/SetRequesterAccessController.go b/contracts/generated/ocr2/SetRequesterAccessController.go index f9587dc70..f80a34a49 100644 --- a/contracts/generated/ocr2/SetRequesterAccessController.go +++ b/contracts/generated/ocr2/SetRequesterAccessController.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -18,7 +18,7 @@ type SetRequesterAccessController struct { // [1] = [SIGNER] authority // // [2] = [] accessController - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewSetRequesterAccessControllerInstructionBuilder creates a new `SetRequesterAccessController` instruction builder. @@ -37,7 +37,7 @@ func (inst *SetRequesterAccessController) SetStateAccount(state ag_solanago.Publ // GetStateAccount gets the "state" account. func (inst *SetRequesterAccessController) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -48,7 +48,7 @@ func (inst *SetRequesterAccessController) SetAuthorityAccount(authority ag_solan // GetAuthorityAccount gets the "authority" account. func (inst *SetRequesterAccessController) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAccessControllerAccount sets the "accessController" account. @@ -59,7 +59,7 @@ func (inst *SetRequesterAccessController) SetAccessControllerAccount(accessContr // GetAccessControllerAccount gets the "accessController" account. func (inst *SetRequesterAccessController) GetAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst SetRequesterAccessController) Build() *Instruction { @@ -108,9 +108,9 @@ func (inst *SetRequesterAccessController) EncodeToTree(parent ag_treeout.Branche // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/ocr2/SetRequesterAccessController_test.go b/contracts/generated/ocr2/SetRequesterAccessController_test.go index ae14b2453..c2965c0b2 100644 --- a/contracts/generated/ocr2/SetRequesterAccessController_test.go +++ b/contracts/generated/ocr2/SetRequesterAccessController_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/TransferOwnership.go b/contracts/generated/ocr2/TransferOwnership.go index 8168fd378..de8bb5511 100644 --- a/contracts/generated/ocr2/TransferOwnership.go +++ b/contracts/generated/ocr2/TransferOwnership.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -17,7 +17,7 @@ type TransferOwnership struct { // [0] = [WRITE] state // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewTransferOwnershipInstructionBuilder creates a new `TransferOwnership` instruction builder. @@ -42,7 +42,7 @@ func (inst *TransferOwnership) SetStateAccount(state ag_solanago.PublicKey) *Tra // GetStateAccount gets the "state" account. func (inst *TransferOwnership) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -53,7 +53,7 @@ func (inst *TransferOwnership) SetAuthorityAccount(authority ag_solanago.PublicK // GetAuthorityAccount gets the "authority" account. func (inst *TransferOwnership) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst TransferOwnership) Build() *Instruction { @@ -108,8 +108,8 @@ func (inst *TransferOwnership) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/ocr2/TransferOwnership_test.go b/contracts/generated/ocr2/TransferOwnership_test.go index 2bbdd9fb1..580f53962 100644 --- a/contracts/generated/ocr2/TransferOwnership_test.go +++ b/contracts/generated/ocr2/TransferOwnership_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/TransferPayeeship.go b/contracts/generated/ocr2/TransferPayeeship.go index 1eb5e1bb7..f24cc2708 100644 --- a/contracts/generated/ocr2/TransferPayeeship.go +++ b/contracts/generated/ocr2/TransferPayeeship.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -22,7 +22,7 @@ type TransferPayeeship struct { // [3] = [] payee // // [4] = [] proposedPayee - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewTransferPayeeshipInstructionBuilder creates a new `TransferPayeeship` instruction builder. @@ -41,7 +41,7 @@ func (inst *TransferPayeeship) SetStateAccount(state ag_solanago.PublicKey) *Tra // GetStateAccount gets the "state" account. func (inst *TransferPayeeship) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -52,7 +52,7 @@ func (inst *TransferPayeeship) SetAuthorityAccount(authority ag_solanago.PublicK // GetAuthorityAccount gets the "authority" account. func (inst *TransferPayeeship) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetTransmitterAccount sets the "transmitter" account. @@ -63,7 +63,7 @@ func (inst *TransferPayeeship) SetTransmitterAccount(transmitter ag_solanago.Pub // GetTransmitterAccount gets the "transmitter" account. func (inst *TransferPayeeship) GetTransmitterAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetPayeeAccount sets the "payee" account. @@ -74,7 +74,7 @@ func (inst *TransferPayeeship) SetPayeeAccount(payee ag_solanago.PublicKey) *Tra // GetPayeeAccount gets the "payee" account. func (inst *TransferPayeeship) GetPayeeAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } // SetProposedPayeeAccount sets the "proposedPayee" account. @@ -85,7 +85,7 @@ func (inst *TransferPayeeship) SetProposedPayeeAccount(proposedPayee ag_solanago // GetProposedPayeeAccount gets the "proposedPayee" account. func (inst *TransferPayeeship) GetProposedPayeeAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[4] + return inst.AccountMetaSlice.Get(4) } func (inst TransferPayeeship) Build() *Instruction { @@ -140,11 +140,11 @@ func (inst *TransferPayeeship) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=5]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta(" transmitter", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta(" payee", inst.AccountMetaSlice[3])) - accountsBranch.Child(ag_format.Meta("proposedPayee", inst.AccountMetaSlice[4])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta(" transmitter", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta(" payee", inst.AccountMetaSlice.Get(3))) + accountsBranch.Child(ag_format.Meta("proposedPayee", inst.AccountMetaSlice.Get(4))) }) }) }) diff --git a/contracts/generated/ocr2/TransferPayeeship_test.go b/contracts/generated/ocr2/TransferPayeeship_test.go index 1928c73c2..76c4e0427 100644 --- a/contracts/generated/ocr2/TransferPayeeship_test.go +++ b/contracts/generated/ocr2/TransferPayeeship_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/WithdrawFunds.go b/contracts/generated/ocr2/WithdrawFunds.go index c2f8629a3..c667b4ef4 100644 --- a/contracts/generated/ocr2/WithdrawFunds.go +++ b/contracts/generated/ocr2/WithdrawFunds.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -27,7 +27,7 @@ type WithdrawFunds struct { // [5] = [WRITE] recipient // // [6] = [] tokenProgram - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewWithdrawFundsInstructionBuilder creates a new `WithdrawFunds` instruction builder. @@ -52,7 +52,7 @@ func (inst *WithdrawFunds) SetStateAccount(state ag_solanago.PublicKey) *Withdra // GetStateAccount gets the "state" account. func (inst *WithdrawFunds) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -63,7 +63,7 @@ func (inst *WithdrawFunds) SetAuthorityAccount(authority ag_solanago.PublicKey) // GetAuthorityAccount gets the "authority" account. func (inst *WithdrawFunds) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAccessControllerAccount sets the "accessController" account. @@ -74,7 +74,7 @@ func (inst *WithdrawFunds) SetAccessControllerAccount(accessController ag_solana // GetAccessControllerAccount gets the "accessController" account. func (inst *WithdrawFunds) GetAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetTokenVaultAccount sets the "tokenVault" account. @@ -85,7 +85,7 @@ func (inst *WithdrawFunds) SetTokenVaultAccount(tokenVault ag_solanago.PublicKey // GetTokenVaultAccount gets the "tokenVault" account. func (inst *WithdrawFunds) GetTokenVaultAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } // SetVaultAuthorityAccount sets the "vaultAuthority" account. @@ -96,7 +96,7 @@ func (inst *WithdrawFunds) SetVaultAuthorityAccount(vaultAuthority ag_solanago.P // GetVaultAuthorityAccount gets the "vaultAuthority" account. func (inst *WithdrawFunds) GetVaultAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[4] + return inst.AccountMetaSlice.Get(4) } // SetRecipientAccount sets the "recipient" account. @@ -107,7 +107,7 @@ func (inst *WithdrawFunds) SetRecipientAccount(recipient ag_solanago.PublicKey) // GetRecipientAccount gets the "recipient" account. func (inst *WithdrawFunds) GetRecipientAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[5] + return inst.AccountMetaSlice.Get(5) } // SetTokenProgramAccount sets the "tokenProgram" account. @@ -118,7 +118,7 @@ func (inst *WithdrawFunds) SetTokenProgramAccount(tokenProgram ag_solanago.Publi // GetTokenProgramAccount gets the "tokenProgram" account. func (inst *WithdrawFunds) GetTokenProgramAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[6] + return inst.AccountMetaSlice.Get(6) } func (inst WithdrawFunds) Build() *Instruction { @@ -188,13 +188,13 @@ func (inst *WithdrawFunds) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=7]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice[3])) - accountsBranch.Child(ag_format.Meta(" vaultAuthority", inst.AccountMetaSlice[4])) - accountsBranch.Child(ag_format.Meta(" recipient", inst.AccountMetaSlice[5])) - accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice[6])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice.Get(3))) + accountsBranch.Child(ag_format.Meta(" vaultAuthority", inst.AccountMetaSlice.Get(4))) + accountsBranch.Child(ag_format.Meta(" recipient", inst.AccountMetaSlice.Get(5))) + accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice.Get(6))) }) }) }) diff --git a/contracts/generated/ocr2/WithdrawFunds_test.go b/contracts/generated/ocr2/WithdrawFunds_test.go index e7644d18d..6c5cc6b04 100644 --- a/contracts/generated/ocr2/WithdrawFunds_test.go +++ b/contracts/generated/ocr2/WithdrawFunds_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/WithdrawPayment.go b/contracts/generated/ocr2/WithdrawPayment.go index f8b1fefab..b62568460 100644 --- a/contracts/generated/ocr2/WithdrawPayment.go +++ b/contracts/generated/ocr2/WithdrawPayment.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -24,7 +24,7 @@ type WithdrawPayment struct { // [4] = [WRITE] payee // // [5] = [] tokenProgram - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewWithdrawPaymentInstructionBuilder creates a new `WithdrawPayment` instruction builder. @@ -43,7 +43,7 @@ func (inst *WithdrawPayment) SetStateAccount(state ag_solanago.PublicKey) *Withd // GetStateAccount gets the "state" account. func (inst *WithdrawPayment) GetStateAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -54,7 +54,7 @@ func (inst *WithdrawPayment) SetAuthorityAccount(authority ag_solanago.PublicKey // GetAuthorityAccount gets the "authority" account. func (inst *WithdrawPayment) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetTokenVaultAccount sets the "tokenVault" account. @@ -65,7 +65,7 @@ func (inst *WithdrawPayment) SetTokenVaultAccount(tokenVault ag_solanago.PublicK // GetTokenVaultAccount gets the "tokenVault" account. func (inst *WithdrawPayment) GetTokenVaultAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetVaultAuthorityAccount sets the "vaultAuthority" account. @@ -76,7 +76,7 @@ func (inst *WithdrawPayment) SetVaultAuthorityAccount(vaultAuthority ag_solanago // GetVaultAuthorityAccount gets the "vaultAuthority" account. func (inst *WithdrawPayment) GetVaultAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } // SetPayeeAccount sets the "payee" account. @@ -87,7 +87,7 @@ func (inst *WithdrawPayment) SetPayeeAccount(payee ag_solanago.PublicKey) *Withd // GetPayeeAccount gets the "payee" account. func (inst *WithdrawPayment) GetPayeeAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[4] + return inst.AccountMetaSlice.Get(4) } // SetTokenProgramAccount sets the "tokenProgram" account. @@ -98,7 +98,7 @@ func (inst *WithdrawPayment) SetTokenProgramAccount(tokenProgram ag_solanago.Pub // GetTokenProgramAccount gets the "tokenProgram" account. func (inst *WithdrawPayment) GetTokenProgramAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[5] + return inst.AccountMetaSlice.Get(5) } func (inst WithdrawPayment) Build() *Instruction { @@ -156,12 +156,12 @@ func (inst *WithdrawPayment) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=6]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta("vaultAuthority", inst.AccountMetaSlice[3])) - accountsBranch.Child(ag_format.Meta(" payee", inst.AccountMetaSlice[4])) - accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice[5])) + accountsBranch.Child(ag_format.Meta(" state", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta(" tokenVault", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta("vaultAuthority", inst.AccountMetaSlice.Get(3))) + accountsBranch.Child(ag_format.Meta(" payee", inst.AccountMetaSlice.Get(4))) + accountsBranch.Child(ag_format.Meta(" tokenProgram", inst.AccountMetaSlice.Get(5))) }) }) }) diff --git a/contracts/generated/ocr2/WithdrawPayment_test.go b/contracts/generated/ocr2/WithdrawPayment_test.go index f2d9e624f..0e3d5a85e 100644 --- a/contracts/generated/ocr2/WithdrawPayment_test.go +++ b/contracts/generated/ocr2/WithdrawPayment_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/WriteOffchainConfig.go b/contracts/generated/ocr2/WriteOffchainConfig.go index 4606ce8cd..17c098171 100644 --- a/contracts/generated/ocr2/WriteOffchainConfig.go +++ b/contracts/generated/ocr2/WriteOffchainConfig.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "errors" @@ -17,7 +17,7 @@ type WriteOffchainConfig struct { // [0] = [WRITE] proposal // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewWriteOffchainConfigInstructionBuilder creates a new `WriteOffchainConfig` instruction builder. @@ -42,7 +42,7 @@ func (inst *WriteOffchainConfig) SetProposalAccount(proposal ag_solanago.PublicK // GetProposalAccount gets the "proposal" account. func (inst *WriteOffchainConfig) GetProposalAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -53,7 +53,7 @@ func (inst *WriteOffchainConfig) SetAuthorityAccount(authority ag_solanago.Publi // GetAuthorityAccount gets the "authority" account. func (inst *WriteOffchainConfig) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst WriteOffchainConfig) Build() *Instruction { @@ -108,8 +108,8 @@ func (inst *WriteOffchainConfig) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" proposal", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/ocr2/WriteOffchainConfig_test.go b/contracts/generated/ocr2/WriteOffchainConfig_test.go index 8a9c917e1..16b8aed1a 100644 --- a/contracts/generated/ocr2/WriteOffchainConfig_test.go +++ b/contracts/generated/ocr2/WriteOffchainConfig_test.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/accounts.go b/contracts/generated/ocr2/accounts.go index 71627c0d9..724fd9e16 100644 --- a/contracts/generated/ocr2/accounts.go +++ b/contracts/generated/ocr2/accounts.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "fmt" diff --git a/contracts/generated/ocr2/instructions.go b/contracts/generated/ocr2/instructions.go index c38fde6db..2dc0c1598 100644 --- a/contracts/generated/ocr2/instructions.go +++ b/contracts/generated/ocr2/instructions.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/testing_utils.go b/contracts/generated/ocr2/testing_utils.go index 3b5eb4e93..4e270a6ed 100644 --- a/contracts/generated/ocr2/testing_utils.go +++ b/contracts/generated/ocr2/testing_utils.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( "bytes" diff --git a/contracts/generated/ocr2/types.go b/contracts/generated/ocr2/types.go index 53906e7fc..ae5c1a040 100644 --- a/contracts/generated/ocr2/types.go +++ b/contracts/generated/ocr2/types.go @@ -1,6 +1,6 @@ // Code generated by https://github.com/gagliardetto/anchor-go. DO NOT EDIT. -package ocr_2 +package ocr2 import ( ag_binary "github.com/gagliardetto/binary" diff --git a/contracts/generated/store/AcceptFeedOwnership.go b/contracts/generated/store/AcceptFeedOwnership.go index 8c958bebb..2e4515863 100644 --- a/contracts/generated/store/AcceptFeedOwnership.go +++ b/contracts/generated/store/AcceptFeedOwnership.go @@ -18,7 +18,7 @@ type AcceptFeedOwnership struct { // [1] = [] proposedOwner // // [2] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewAcceptFeedOwnershipInstructionBuilder creates a new `AcceptFeedOwnership` instruction builder. @@ -37,7 +37,7 @@ func (inst *AcceptFeedOwnership) SetFeedAccount(feed ag_solanago.PublicKey) *Acc // GetFeedAccount gets the "feed" account. func (inst *AcceptFeedOwnership) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetProposedOwnerAccount sets the "proposedOwner" account. @@ -48,7 +48,7 @@ func (inst *AcceptFeedOwnership) SetProposedOwnerAccount(proposedOwner ag_solana // GetProposedOwnerAccount gets the "proposedOwner" account. func (inst *AcceptFeedOwnership) GetProposedOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAuthorityAccount sets the "authority" account. @@ -59,7 +59,7 @@ func (inst *AcceptFeedOwnership) SetAuthorityAccount(authority ag_solanago.Publi // GetAuthorityAccount gets the "authority" account. func (inst *AcceptFeedOwnership) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst AcceptFeedOwnership) Build() *Instruction { @@ -108,9 +108,9 @@ func (inst *AcceptFeedOwnership) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("proposedOwner", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("proposedOwner", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/store/AcceptStoreOwnership.go b/contracts/generated/store/AcceptStoreOwnership.go index b7176ddbc..346da347e 100644 --- a/contracts/generated/store/AcceptStoreOwnership.go +++ b/contracts/generated/store/AcceptStoreOwnership.go @@ -16,7 +16,7 @@ type AcceptStoreOwnership struct { // [0] = [WRITE] store // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewAcceptStoreOwnershipInstructionBuilder creates a new `AcceptStoreOwnership` instruction builder. @@ -35,7 +35,7 @@ func (inst *AcceptStoreOwnership) SetStoreAccount(store ag_solanago.PublicKey) * // GetStoreAccount gets the "store" account. func (inst *AcceptStoreOwnership) GetStoreAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -46,7 +46,7 @@ func (inst *AcceptStoreOwnership) SetAuthorityAccount(authority ag_solanago.Publ // GetAuthorityAccount gets the "authority" account. func (inst *AcceptStoreOwnership) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst AcceptStoreOwnership) Build() *Instruction { @@ -92,8 +92,8 @@ func (inst *AcceptStoreOwnership) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" store", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" store", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/store/CloseFeed.go b/contracts/generated/store/CloseFeed.go index bf411b454..f64dfcd77 100644 --- a/contracts/generated/store/CloseFeed.go +++ b/contracts/generated/store/CloseFeed.go @@ -20,7 +20,7 @@ type CloseFeed struct { // [2] = [WRITE] receiver // // [3] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewCloseFeedInstructionBuilder creates a new `CloseFeed` instruction builder. @@ -39,7 +39,7 @@ func (inst *CloseFeed) SetFeedAccount(feed ag_solanago.PublicKey) *CloseFeed { // GetFeedAccount gets the "feed" account. func (inst *CloseFeed) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetOwnerAccount sets the "owner" account. @@ -50,7 +50,7 @@ func (inst *CloseFeed) SetOwnerAccount(owner ag_solanago.PublicKey) *CloseFeed { // GetOwnerAccount gets the "owner" account. func (inst *CloseFeed) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetReceiverAccount sets the "receiver" account. @@ -61,7 +61,7 @@ func (inst *CloseFeed) SetReceiverAccount(receiver ag_solanago.PublicKey) *Close // GetReceiverAccount gets the "receiver" account. func (inst *CloseFeed) GetReceiverAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetAuthorityAccount sets the "authority" account. @@ -72,7 +72,7 @@ func (inst *CloseFeed) SetAuthorityAccount(authority ag_solanago.PublicKey) *Clo // GetAuthorityAccount gets the "authority" account. func (inst *CloseFeed) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } func (inst CloseFeed) Build() *Instruction { @@ -124,10 +124,10 @@ func (inst *CloseFeed) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=4]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta(" receiver", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[3])) + accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta(" receiver", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(3))) }) }) }) diff --git a/contracts/generated/store/CreateFeed.go b/contracts/generated/store/CreateFeed.go index 20aecbd83..d6aa494a2 100644 --- a/contracts/generated/store/CreateFeed.go +++ b/contracts/generated/store/CreateFeed.go @@ -20,7 +20,7 @@ type CreateFeed struct { // [0] = [WRITE] feed // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewCreateFeedInstructionBuilder creates a new `CreateFeed` instruction builder. @@ -63,7 +63,7 @@ func (inst *CreateFeed) SetFeedAccount(feed ag_solanago.PublicKey) *CreateFeed { // GetFeedAccount gets the "feed" account. func (inst *CreateFeed) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -74,7 +74,7 @@ func (inst *CreateFeed) SetAuthorityAccount(authority ag_solanago.PublicKey) *Cr // GetAuthorityAccount gets the "authority" account. func (inst *CreateFeed) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst CreateFeed) Build() *Instruction { @@ -141,8 +141,8 @@ func (inst *CreateFeed) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/store/Initialize.go b/contracts/generated/store/Initialize.go index bf45fc7a6..fc0430fe9 100644 --- a/contracts/generated/store/Initialize.go +++ b/contracts/generated/store/Initialize.go @@ -18,7 +18,7 @@ type Initialize struct { // [1] = [SIGNER] owner // // [2] = [] loweringAccessController - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewInitializeInstructionBuilder creates a new `Initialize` instruction builder. @@ -37,7 +37,7 @@ func (inst *Initialize) SetStoreAccount(store ag_solanago.PublicKey) *Initialize // GetStoreAccount gets the "store" account. func (inst *Initialize) GetStoreAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetOwnerAccount sets the "owner" account. @@ -48,7 +48,7 @@ func (inst *Initialize) SetOwnerAccount(owner ag_solanago.PublicKey) *Initialize // GetOwnerAccount gets the "owner" account. func (inst *Initialize) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetLoweringAccessControllerAccount sets the "loweringAccessController" account. @@ -59,7 +59,7 @@ func (inst *Initialize) SetLoweringAccessControllerAccount(loweringAccessControl // GetLoweringAccessControllerAccount gets the "loweringAccessController" account. func (inst *Initialize) GetLoweringAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst Initialize) Build() *Instruction { @@ -108,9 +108,9 @@ func (inst *Initialize) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" store", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("loweringAccessController", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" store", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("loweringAccessController", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/store/LowerFlag.go b/contracts/generated/store/LowerFlag.go index 4e634b4ec..19b0656b8 100644 --- a/contracts/generated/store/LowerFlag.go +++ b/contracts/generated/store/LowerFlag.go @@ -20,7 +20,7 @@ type LowerFlag struct { // [2] = [SIGNER] authority // // [3] = [] accessController - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewLowerFlagInstructionBuilder creates a new `LowerFlag` instruction builder. @@ -39,7 +39,7 @@ func (inst *LowerFlag) SetFeedAccount(feed ag_solanago.PublicKey) *LowerFlag { // GetFeedAccount gets the "feed" account. func (inst *LowerFlag) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetOwnerAccount sets the "owner" account. @@ -50,7 +50,7 @@ func (inst *LowerFlag) SetOwnerAccount(owner ag_solanago.PublicKey) *LowerFlag { // GetOwnerAccount gets the "owner" account. func (inst *LowerFlag) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAuthorityAccount sets the "authority" account. @@ -61,7 +61,7 @@ func (inst *LowerFlag) SetAuthorityAccount(authority ag_solanago.PublicKey) *Low // GetAuthorityAccount gets the "authority" account. func (inst *LowerFlag) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } // SetAccessControllerAccount sets the "accessController" account. @@ -72,7 +72,7 @@ func (inst *LowerFlag) SetAccessControllerAccount(accessController ag_solanago.P // GetAccessControllerAccount gets the "accessController" account. func (inst *LowerFlag) GetAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[3] + return inst.AccountMetaSlice.Get(3) } func (inst LowerFlag) Build() *Instruction { @@ -124,10 +124,10 @@ func (inst *LowerFlag) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=4]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[2])) - accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice[3])) + accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(2))) + accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice.Get(3))) }) }) }) diff --git a/contracts/generated/store/Query.go b/contracts/generated/store/Query.go index 01f11e98c..dcda56832 100644 --- a/contracts/generated/store/Query.go +++ b/contracts/generated/store/Query.go @@ -16,7 +16,7 @@ type Query struct { Scope Scope // [0] = [] feed - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewQueryInstructionBuilder creates a new `Query` instruction builder. @@ -41,7 +41,7 @@ func (inst *Query) SetFeedAccount(feed ag_solanago.PublicKey) *Query { // GetFeedAccount gets the "feed" account. func (inst *Query) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } func (inst Query) Build() *Instruction { @@ -93,7 +93,7 @@ func (inst *Query) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=1]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta("feed", inst.AccountMetaSlice[0])) + accountsBranch.Child(ag_format.Meta("feed", inst.AccountMetaSlice.Get(0))) }) }) }) @@ -104,22 +104,22 @@ func (obj Query) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { { tmp := scopeContainer{} switch realvalue := obj.Scope.(type) { - case *Version: + case *ScopeVersion: tmp.Enum = 0 tmp.Version = *realvalue - case *Decimals: + case *ScopeDecimals: tmp.Enum = 1 tmp.Decimals = *realvalue - case *Description: + case *ScopeDescription: tmp.Enum = 2 tmp.Description = *realvalue - case *RoundData: + case *ScopeRoundData: tmp.Enum = 3 tmp.RoundData = *realvalue - case *LatestRoundData: + case *ScopeLatestRoundData: tmp.Enum = 4 tmp.LatestRoundData = *realvalue - case *Aggregator: + case *ScopeAggregator: tmp.Enum = 5 tmp.Aggregator = *realvalue } @@ -140,17 +140,17 @@ func (obj *Query) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { } switch tmp.Enum { case 0: - obj.Scope = (*Version)(&tmp.Enum) + obj.Scope = (*ScopeVersion)(&tmp.Enum) case 1: - obj.Scope = (*Decimals)(&tmp.Enum) + obj.Scope = (*ScopeDecimals)(&tmp.Enum) case 2: - obj.Scope = (*Description)(&tmp.Enum) + obj.Scope = (*ScopeDescription)(&tmp.Enum) case 3: obj.Scope = &tmp.RoundData case 4: - obj.Scope = (*LatestRoundData)(&tmp.Enum) + obj.Scope = (*ScopeLatestRoundData)(&tmp.Enum) case 5: - obj.Scope = (*Aggregator)(&tmp.Enum) + obj.Scope = (*ScopeAggregator)(&tmp.Enum) default: return fmt.Errorf("unknown enum index: %v", tmp.Enum) } diff --git a/contracts/generated/store/SetLoweringAccessController.go b/contracts/generated/store/SetLoweringAccessController.go index c31c1514d..e6f389e43 100644 --- a/contracts/generated/store/SetLoweringAccessController.go +++ b/contracts/generated/store/SetLoweringAccessController.go @@ -18,7 +18,7 @@ type SetLoweringAccessController struct { // [1] = [SIGNER] authority // // [2] = [] accessController - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewSetLoweringAccessControllerInstructionBuilder creates a new `SetLoweringAccessController` instruction builder. @@ -37,7 +37,7 @@ func (inst *SetLoweringAccessController) SetStoreAccount(store ag_solanago.Publi // GetStoreAccount gets the "store" account. func (inst *SetLoweringAccessController) GetStoreAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -48,7 +48,7 @@ func (inst *SetLoweringAccessController) SetAuthorityAccount(authority ag_solana // GetAuthorityAccount gets the "authority" account. func (inst *SetLoweringAccessController) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAccessControllerAccount sets the "accessController" account. @@ -59,7 +59,7 @@ func (inst *SetLoweringAccessController) SetAccessControllerAccount(accessContro // GetAccessControllerAccount gets the "accessController" account. func (inst *SetLoweringAccessController) GetAccessControllerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst SetLoweringAccessController) Build() *Instruction { @@ -108,9 +108,9 @@ func (inst *SetLoweringAccessController) EncodeToTree(parent ag_treeout.Branches // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" store", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" store", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" authority", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("accessController", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/store/SetValidatorConfig.go b/contracts/generated/store/SetValidatorConfig.go index d3aa39c38..8dd28b3df 100644 --- a/contracts/generated/store/SetValidatorConfig.go +++ b/contracts/generated/store/SetValidatorConfig.go @@ -19,7 +19,7 @@ type SetValidatorConfig struct { // [1] = [] owner // // [2] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewSetValidatorConfigInstructionBuilder creates a new `SetValidatorConfig` instruction builder. @@ -44,7 +44,7 @@ func (inst *SetValidatorConfig) SetFeedAccount(feed ag_solanago.PublicKey) *SetV // GetFeedAccount gets the "feed" account. func (inst *SetValidatorConfig) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetOwnerAccount sets the "owner" account. @@ -55,7 +55,7 @@ func (inst *SetValidatorConfig) SetOwnerAccount(owner ag_solanago.PublicKey) *Se // GetOwnerAccount gets the "owner" account. func (inst *SetValidatorConfig) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAuthorityAccount sets the "authority" account. @@ -66,7 +66,7 @@ func (inst *SetValidatorConfig) SetAuthorityAccount(authority ag_solanago.Public // GetAuthorityAccount gets the "authority" account. func (inst *SetValidatorConfig) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst SetValidatorConfig) Build() *Instruction { @@ -124,9 +124,9 @@ func (inst *SetValidatorConfig) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/store/SetWriter.go b/contracts/generated/store/SetWriter.go index 4e70a5437..008afbc90 100644 --- a/contracts/generated/store/SetWriter.go +++ b/contracts/generated/store/SetWriter.go @@ -19,7 +19,7 @@ type SetWriter struct { // [1] = [] owner // // [2] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewSetWriterInstructionBuilder creates a new `SetWriter` instruction builder. @@ -44,7 +44,7 @@ func (inst *SetWriter) SetFeedAccount(feed ag_solanago.PublicKey) *SetWriter { // GetFeedAccount gets the "feed" account. func (inst *SetWriter) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetOwnerAccount sets the "owner" account. @@ -55,7 +55,7 @@ func (inst *SetWriter) SetOwnerAccount(owner ag_solanago.PublicKey) *SetWriter { // GetOwnerAccount gets the "owner" account. func (inst *SetWriter) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAuthorityAccount sets the "authority" account. @@ -66,7 +66,7 @@ func (inst *SetWriter) SetAuthorityAccount(authority ag_solanago.PublicKey) *Set // GetAuthorityAccount gets the "authority" account. func (inst *SetWriter) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst SetWriter) Build() *Instruction { @@ -124,9 +124,9 @@ func (inst *SetWriter) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/store/Submit.go b/contracts/generated/store/Submit.go index 85a44e116..cb9d9feb8 100644 --- a/contracts/generated/store/Submit.go +++ b/contracts/generated/store/Submit.go @@ -17,7 +17,7 @@ type Submit struct { // [0] = [WRITE] feed // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewSubmitInstructionBuilder creates a new `Submit` instruction builder. @@ -42,7 +42,7 @@ func (inst *Submit) SetFeedAccount(feed ag_solanago.PublicKey) *Submit { // GetFeedAccount gets the "feed" account. func (inst *Submit) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -53,7 +53,7 @@ func (inst *Submit) SetAuthorityAccount(authority ag_solanago.PublicKey) *Submit // GetAuthorityAccount gets the "authority" account. func (inst *Submit) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst Submit) Build() *Instruction { @@ -108,8 +108,8 @@ func (inst *Submit) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/store/TransferFeedOwnership.go b/contracts/generated/store/TransferFeedOwnership.go index e54eae85e..c939afefa 100644 --- a/contracts/generated/store/TransferFeedOwnership.go +++ b/contracts/generated/store/TransferFeedOwnership.go @@ -19,7 +19,7 @@ type TransferFeedOwnership struct { // [1] = [] owner // // [2] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewTransferFeedOwnershipInstructionBuilder creates a new `TransferFeedOwnership` instruction builder. @@ -44,7 +44,7 @@ func (inst *TransferFeedOwnership) SetFeedAccount(feed ag_solanago.PublicKey) *T // GetFeedAccount gets the "feed" account. func (inst *TransferFeedOwnership) GetFeedAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetOwnerAccount sets the "owner" account. @@ -55,7 +55,7 @@ func (inst *TransferFeedOwnership) SetOwnerAccount(owner ag_solanago.PublicKey) // GetOwnerAccount gets the "owner" account. func (inst *TransferFeedOwnership) GetOwnerAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } // SetAuthorityAccount sets the "authority" account. @@ -66,7 +66,7 @@ func (inst *TransferFeedOwnership) SetAuthorityAccount(authority ag_solanago.Pub // GetAuthorityAccount gets the "authority" account. func (inst *TransferFeedOwnership) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[2] + return inst.AccountMetaSlice.Get(2) } func (inst TransferFeedOwnership) Build() *Instruction { @@ -124,9 +124,9 @@ func (inst *TransferFeedOwnership) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=3]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice[1])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[2])) + accountsBranch.Child(ag_format.Meta(" feed", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta(" owner", inst.AccountMetaSlice.Get(1))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(2))) }) }) }) diff --git a/contracts/generated/store/TransferStoreOwnership.go b/contracts/generated/store/TransferStoreOwnership.go index b2d9bbcd0..2c7143dc4 100644 --- a/contracts/generated/store/TransferStoreOwnership.go +++ b/contracts/generated/store/TransferStoreOwnership.go @@ -17,7 +17,7 @@ type TransferStoreOwnership struct { // [0] = [WRITE] store // // [1] = [SIGNER] authority - ag_solanago.AccountMetaSlice `bin:"-" borsh_skip:"true"` + ag_solanago.AccountMetaSlice `bin:"-"` } // NewTransferStoreOwnershipInstructionBuilder creates a new `TransferStoreOwnership` instruction builder. @@ -42,7 +42,7 @@ func (inst *TransferStoreOwnership) SetStoreAccount(store ag_solanago.PublicKey) // GetStoreAccount gets the "store" account. func (inst *TransferStoreOwnership) GetStoreAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[0] + return inst.AccountMetaSlice.Get(0) } // SetAuthorityAccount sets the "authority" account. @@ -53,7 +53,7 @@ func (inst *TransferStoreOwnership) SetAuthorityAccount(authority ag_solanago.Pu // GetAuthorityAccount gets the "authority" account. func (inst *TransferStoreOwnership) GetAuthorityAccount() *ag_solanago.AccountMeta { - return inst.AccountMetaSlice[1] + return inst.AccountMetaSlice.Get(1) } func (inst TransferStoreOwnership) Build() *Instruction { @@ -108,8 +108,8 @@ func (inst *TransferStoreOwnership) EncodeToTree(parent ag_treeout.Branches) { // Accounts of the instruction: instructionBranch.Child("Accounts[len=2]").ParentFunc(func(accountsBranch ag_treeout.Branches) { - accountsBranch.Child(ag_format.Meta(" store", inst.AccountMetaSlice[0])) - accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice[1])) + accountsBranch.Child(ag_format.Meta(" store", inst.AccountMetaSlice.Get(0))) + accountsBranch.Child(ag_format.Meta("authority", inst.AccountMetaSlice.Get(1))) }) }) }) diff --git a/contracts/generated/store/types.go b/contracts/generated/store/types.go index 84dc701f0..65ae77070 100644 --- a/contracts/generated/store/types.go +++ b/contracts/generated/store/types.go @@ -98,55 +98,55 @@ type Scope interface { type scopeContainer struct { Enum ag_binary.BorshEnum `borsh_enum:"true"` - Version Version - Decimals Decimals - Description Description - RoundData RoundData - LatestRoundData LatestRoundData - Aggregator Aggregator + Version ScopeVersion + Decimals ScopeDecimals + Description ScopeDescription + RoundData ScopeRoundData + LatestRoundData ScopeLatestRoundData + Aggregator ScopeAggregator } -type Version uint8 +type ScopeVersion uint8 -func (obj Version) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { +func (obj ScopeVersion) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { return nil } -func (obj *Version) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { +func (obj *ScopeVersion) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { return nil } -func (_ *Version) isScope() {} +func (_ *ScopeVersion) isScope() {} -type Decimals uint8 +type ScopeDecimals uint8 -func (obj Decimals) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { +func (obj ScopeDecimals) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { return nil } -func (obj *Decimals) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { +func (obj *ScopeDecimals) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { return nil } -func (_ *Decimals) isScope() {} +func (_ *ScopeDecimals) isScope() {} -type Description uint8 +type ScopeDescription uint8 -func (obj Description) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { +func (obj ScopeDescription) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { return nil } -func (obj *Description) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { +func (obj *ScopeDescription) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { return nil } -func (_ *Description) isScope() {} +func (_ *ScopeDescription) isScope() {} -type RoundData struct { +type ScopeRoundData struct { RoundId uint32 } -func (obj RoundData) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { +func (obj ScopeRoundData) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { // Serialize `RoundId` param: err = encoder.Encode(obj.RoundId) if err != nil { @@ -155,7 +155,7 @@ func (obj RoundData) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) return nil } -func (obj *RoundData) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { +func (obj *ScopeRoundData) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { // Deserialize `RoundId`: err = decoder.Decode(&obj.RoundId) if err != nil { @@ -164,28 +164,28 @@ func (obj *RoundData) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err erro return nil } -func (_ *RoundData) isScope() {} +func (_ *ScopeRoundData) isScope() {} -type LatestRoundData uint8 +type ScopeLatestRoundData uint8 -func (obj LatestRoundData) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { +func (obj ScopeLatestRoundData) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { return nil } -func (obj *LatestRoundData) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { +func (obj *ScopeLatestRoundData) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { return nil } -func (_ *LatestRoundData) isScope() {} +func (_ *ScopeLatestRoundData) isScope() {} -type Aggregator uint8 +type ScopeAggregator uint8 -func (obj Aggregator) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { +func (obj ScopeAggregator) MarshalWithEncoder(encoder *ag_binary.Encoder) (err error) { return nil } -func (obj *Aggregator) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { +func (obj *ScopeAggregator) UnmarshalWithDecoder(decoder *ag_binary.Decoder) (err error) { return nil } -func (_ *Aggregator) isScope() {} +func (_ *ScopeAggregator) isScope() {}