pub struct MultisigAddSpendingLimitArgs {
pub create_key: Pubkey,
pub vault_index: u8,
pub mint: Pubkey,
pub amount: u64,
pub period: Period,
pub members: Vec<Pubkey>,
pub destinations: Vec<Pubkey>,
pub memo: Option<String>,
}Fields§
§create_key: PubkeyKey that is used to seed the SpendingLimit PDA.
vault_index: u8The index of the vault that the spending limit is for.
mint: PubkeyThe token mint the spending limit is for.
amount: u64The amount of tokens that can be spent in a period.
This amount is in decimals of the mint,
so 1 SOL would be 1_000_000_000 and 1 USDC would be 1_000_000.
period: PeriodThe reset period of the spending limit.
When it passes, the remaining amount is reset, unless it’s Period::OneTime.
members: Vec<Pubkey>Members of the Spending Limit that can use it. Don’t have to be members of the multisig.
destinations: Vec<Pubkey>The destination addresses the spending limit is allowed to sent funds to. If empty, funds can be sent to any address.
memo: Option<String>Memo is used for indexing only.
Trait Implementations§
Source§impl BorshDeserialize for MultisigAddSpendingLimitArgs
impl BorshDeserialize for MultisigAddSpendingLimitArgs
fn deserialize_reader<R: Read>(reader: &mut R) -> Result<Self, Error>
Source§fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
Deserializes this instance from a given slice of bytes.
Updates the buffer to point at the remaining bytes.
Source§fn try_from_slice(v: &[u8]) -> Result<Self, Error>
fn try_from_slice(v: &[u8]) -> Result<Self, Error>
Deserialize this instance from a slice of bytes.
fn try_from_reader<R>(reader: &mut R) -> Result<Self, Error>where
R: Read,
Source§impl BorshSerialize for MultisigAddSpendingLimitArgswhere
Pubkey: BorshSerialize,
u8: BorshSerialize,
u64: BorshSerialize,
Period: BorshSerialize,
Vec<Pubkey>: BorshSerialize,
Option<String>: BorshSerialize,
impl BorshSerialize for MultisigAddSpendingLimitArgswhere
Pubkey: BorshSerialize,
u8: BorshSerialize,
u64: BorshSerialize,
Period: BorshSerialize,
Vec<Pubkey>: BorshSerialize,
Option<String>: BorshSerialize,
Auto Trait Implementations§
impl Freeze for MultisigAddSpendingLimitArgs
impl RefUnwindSafe for MultisigAddSpendingLimitArgs
impl Send for MultisigAddSpendingLimitArgs
impl Sync for MultisigAddSpendingLimitArgs
impl Unpin for MultisigAddSpendingLimitArgs
impl UnsafeUnpin for MultisigAddSpendingLimitArgs
impl UnwindSafe for MultisigAddSpendingLimitArgs
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> 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