#[repr(C)]pub struct StreamInstruction {
pub start_time: u64,
pub end_time: u64,
pub deposited_amount: u64,
pub total_amount: u64,
pub period: u64,
pub cliff: u64,
pub cliff_amount: u64,
pub is_cancelable_by_sender: bool,
pub is_cancelable_by_recipient: bool,
pub is_withdrawal_public: bool,
pub is_transferable: bool,
pub padding: u32,
}Expand description
The struct containing instructions for initializing a stream
Fields§
§start_time: u64Timestamp when the tokens start vesting
end_time: u64Timestamp when all tokens are fully vested
deposited_amount: u64Initially deposited amount of tokens (currently not used, set to total_amount and left for extension in future)
total_amount: u64Total amount of the tokens in the escrow account if contract is fully vested
period: u64Time step (period) in seconds per which the vesting occurs
cliff: u64Vesting contract “cliff” timestamp
cliff_amount: u64Amount unlocked at the “cliff” timestamp
is_cancelable_by_sender: boolWhether or not a stream can be canceled by a sender (currently not used, set to TRUE)
is_cancelable_by_recipient: boolWhether or not a stream can be canceled by a recipient (currently not used, set to FALSE)
is_withdrawal_public: boolWhether or not a 3rd party can initiate withdraw in the name of recipient (currently not used, set to FALSE)
is_transferable: boolWhether or not a recipient can transfer the stream (currently not used, set to TRUE)
padding: u32Implementations§
Trait Implementations§
Source§impl BorshDeserialize for StreamInstruction
impl BorshDeserialize for StreamInstruction
Source§impl BorshSerialize for StreamInstruction
impl BorshSerialize for StreamInstruction
Source§impl Clone for StreamInstruction
impl Clone for StreamInstruction
Source§fn clone(&self) -> StreamInstruction
fn clone(&self) -> StreamInstruction
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for StreamInstruction
impl Debug for StreamInstruction
Auto Trait Implementations§
impl Freeze for StreamInstruction
impl RefUnwindSafe for StreamInstruction
impl Send for StreamInstruction
impl Sync for StreamInstruction
impl Unpin for StreamInstruction
impl UnwindSafe for StreamInstruction
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> 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>
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