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 multisig that can use the spending limit. In case a member is removed from the multisig, the spending limit will remain existent (until explicitly deleted), but the removed member will not be able to use it anymore.
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>
Source§fn try_from_slice(v: &[u8]) -> Result<Self, Error>
fn try_from_slice(v: &[u8]) -> Result<Self, Error>
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 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
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>
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>
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