#[repr(C)]pub enum AdminInstruction {
RampA(RampAData),
StopRampA,
Pause,
Unpause,
SetFeeAccount,
ApplyNewAdmin,
CommitNewAdmin,
SetNewFees(Fees),
}
Expand description
Admin only instructions.
Variants§
RampA(RampAData)
Starts a ramp of A to the next value.
[writable]
StableSwap[signer]
Admin account
StopRampA
Cancels the pending ramp of A.
[writable]
StableSwap[signer]
Admin account
Pause
Pauses swap, deposit, and withdraw_one.
[writable]
StableSwap[signer]
Admin account
Unpause
Unpauses the swap.
[writable]
StableSwap[signer]
Admin account
SetFeeAccount
Sets the account that receives admin fees.
[writable]
StableSwap[signer]
Admin account[]
Token account to receive fees. Must have mint of Token A or Token B.
ApplyNewAdmin
Finalizes the admin transfer. This is run after CommitNewAdmin.
[writable]
StableSwap[signer]
Admin account
CommitNewAdmin
Commits a new admin. The admin must accept ownership within 3 days.
[writable]
StableSwap[signer]
Admin account[]
New admin account
SetNewFees(Fees)
Updates the swap fees.
[writable]
StableSwap[signer]
Admin account
Implementations§
Source§impl AdminInstruction
impl AdminInstruction
Sourcepub fn unpack(input: &[u8]) -> Result<Option<Self>, ProgramError>
pub fn unpack(input: &[u8]) -> Result<Option<Self>, ProgramError>
Unpacks a byte buffer into a AdminInstruction.
Trait Implementations§
Source§impl Clone for AdminInstruction
impl Clone for AdminInstruction
Source§fn clone(&self) -> AdminInstruction
fn clone(&self) -> AdminInstruction
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for AdminInstruction
impl Debug for AdminInstruction
Source§impl PartialEq for AdminInstruction
impl PartialEq for AdminInstruction
impl Copy for AdminInstruction
impl StructuralPartialEq for AdminInstruction
Auto Trait Implementations§
impl Freeze for AdminInstruction
impl RefUnwindSafe for AdminInstruction
impl Send for AdminInstruction
impl Sync for AdminInstruction
impl Unpin for AdminInstruction
impl UnwindSafe for AdminInstruction
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more