pub struct DeterministicStateInitAction {
pub state_init: DeterministicAccountStateInit,
pub deposit: NearToken,
}Expand description
Deploy a contract with a deterministically derived account ID (NEP-616).
This enables creating accounts where the account ID is derived from the contract code and initial state, making them predictable and reproducible.
Fields§
§state_init: DeterministicAccountStateInitThe state initialization data.
deposit: NearTokenAmount to attach for storage costs.
Implementations§
Source§impl DeterministicStateInitAction
impl DeterministicStateInitAction
Sourcepub fn derive_account_id(&self) -> AccountId
pub fn derive_account_id(&self) -> AccountId
Derive the deterministic account ID for this action.
Convenience method that delegates to DeterministicAccountStateInit::derive_account_id.
Trait Implementations§
Source§impl BorshDeserialize for DeterministicStateInitAction
impl BorshDeserialize for DeterministicStateInitAction
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 Clone for DeterministicStateInitAction
impl Clone for DeterministicStateInitAction
Source§fn clone(&self) -> DeterministicStateInitAction
fn clone(&self) -> DeterministicStateInitAction
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 DeterministicStateInitAction
impl Debug for DeterministicStateInitAction
Source§impl PartialEq for DeterministicStateInitAction
impl PartialEq for DeterministicStateInitAction
Source§fn eq(&self, other: &DeterministicStateInitAction) -> bool
fn eq(&self, other: &DeterministicStateInitAction) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for DeterministicStateInitAction
impl StructuralPartialEq for DeterministicStateInitAction
Auto Trait Implementations§
impl Freeze for DeterministicStateInitAction
impl RefUnwindSafe for DeterministicStateInitAction
impl Send for DeterministicStateInitAction
impl Sync for DeterministicStateInitAction
impl Unpin for DeterministicStateInitAction
impl UnsafeUnpin for DeterministicStateInitAction
impl UnwindSafe for DeterministicStateInitAction
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.