pub enum VoteInstruction {
    InitializeAccount(VoteInit),
    Authorize(Pubkey, VoteAuthorize),
    Vote(Vote),
    Withdraw(u64),
    UpdateValidatorIdentity,
    UpdateCommission(u8),
    VoteSwitch(Vote, Hash),
    AuthorizeChecked(VoteAuthorize),
    UpdateVoteState(VoteStateUpdate),
    UpdateVoteStateSwitch(VoteStateUpdate, Hash),
    AuthorizeWithSeed(VoteAuthorizeWithSeedArgs),
    AuthorizeCheckedWithSeed(VoteAuthorizeCheckedWithSeedArgs),
}

Variants§

§

InitializeAccount(VoteInit)

Initialize a vote account

Account references

  1. [WRITE] Uninitialized vote account
  2. [] Rent sysvar
  3. [] Clock sysvar
  4. [SIGNER] New validator identity (node_pubkey)
§

Authorize(Pubkey, VoteAuthorize)

Authorize a key to send votes or issue a withdrawal

Account references

  1. [WRITE] Vote account to be updated with the Pubkey for authorization
  2. [] Clock sysvar
  3. [SIGNER] Vote or withdraw authority
§

Vote(Vote)

A Vote instruction with recent votes

Account references

  1. [WRITE] Vote account to vote with
  2. [] Slot hashes sysvar
  3. [] Clock sysvar
  4. [SIGNER] Vote authority
§

Withdraw(u64)

Withdraw some amount of funds

Account references

  1. [WRITE] Vote account to withdraw from
  2. [WRITE] Recipient account
  3. [SIGNER] Withdraw authority
§

UpdateValidatorIdentity

Update the vote account’s validator identity (node_pubkey)

Account references

  1. [WRITE] Vote account to be updated with the given authority public key
  2. [SIGNER] New validator identity (node_pubkey)
  3. [SIGNER] Withdraw authority
§

UpdateCommission(u8)

Update the commission for the vote account

Account references

  1. [WRITE] Vote account to be updated
  2. [SIGNER] Withdraw authority
§

VoteSwitch(Vote, Hash)

A Vote instruction with recent votes

Account references

  1. [WRITE] Vote account to vote with
  2. [] Slot hashes sysvar
  3. [] Clock sysvar
  4. [SIGNER] Vote authority
§

AuthorizeChecked(VoteAuthorize)

Authorize a key to send votes or issue a withdrawal

This instruction behaves like Authorize with the additional requirement that the new vote or withdraw authority must also be a signer.

Account references

  1. [WRITE] Vote account to be updated with the Pubkey for authorization
  2. [] Clock sysvar
  3. [SIGNER] Vote or withdraw authority
  4. [SIGNER] New vote or withdraw authority
§

UpdateVoteState(VoteStateUpdate)

Update the onchain vote state for the signer.

Account references

  1. [Write] Vote account to vote with
  2. [SIGNER] Vote authority
§

UpdateVoteStateSwitch(VoteStateUpdate, Hash)

Update the onchain vote state for the signer along with a switching proof.

Account references

  1. [Write] Vote account to vote with
  2. [SIGNER] Vote authority
§

AuthorizeWithSeed(VoteAuthorizeWithSeedArgs)

Given that the current Voter or Withdrawer authority is a derived key, this instruction allows someone who can sign for that derived key’s base key to authorize a new Voter or Withdrawer for a vote account.

Account references

  1. [Write] Vote account to be updated
  2. [] Clock sysvar
  3. [SIGNER] Base key of current Voter or Withdrawer authority’s derived key
§

AuthorizeCheckedWithSeed(VoteAuthorizeCheckedWithSeedArgs)

Given that the current Voter or Withdrawer authority is a derived key, this instruction allows someone who can sign for that derived key’s base key to authorize a new Voter or Withdrawer for a vote account.

This instruction behaves like AuthorizeWithSeed with the additional requirement that the new vote or withdraw authority must also be a signer.

Account references

  1. [Write] Vote account to be updated
  2. [] Clock sysvar
  3. [SIGNER] Base key of current Voter or Withdrawer authority’s derived key
  4. [SIGNER] New vote or withdraw authority

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Deserialize this value from the given Serde deserializer. Read more
This method tests for self and other values to be equal, and is used by ==.
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
Compare self to key and return true if they are equal.

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The alignment of pointer.
The type for initializers.
Initializes a with the given initializer. Read more
Dereferences the given pointer. Read more
Mutably dereferences the given pointer. Read more
Drops the object pointed to by the given pointer. Read more
Should always be Self
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more