pub struct DelegateAction {
pub actions: Vec<NonDelegateAction>,
pub max_block_height: u64,
pub nonce: u64,
pub public_key: PublicKey,
pub receiver_id: AccountId,
pub sender_id: AccountId,
}
Expand description
This action allows to execute the inner actions behalf of the defined sender.
JSON schema
{
"description": "This action allows to execute the inner actions behalf of the defined sender.",
"type": "object",
"required": [
"actions",
"max_block_height",
"nonce",
"public_key",
"receiver_id",
"sender_id"
],
"properties": {
"actions": {
"description": "List of actions to be executed.\n\nWith the meta transactions MVP defined in NEP-366, nested\nDelegateActions are not allowed. A separate type is used to enforce it.",
"type": "array",
"items": {
"$ref": "#/components/schemas/NonDelegateAction"
}
},
"max_block_height": {
"description": "The maximal height of the block in the blockchain below which the given DelegateAction is valid.",
"type": "integer",
"format": "uint64",
"minimum": 0.0
},
"nonce": {
"description": "Nonce to ensure that the same delegate action is not sent twice by a\nrelayer and should match for given account's `public_key`.\nAfter this action is processed it will increment.",
"type": "integer",
"format": "uint64",
"minimum": 0.0
},
"public_key": {
"description": "Public key used to sign this delegated action.",
"allOf": [
{
"$ref": "#/components/schemas/PublicKey"
}
]
},
"receiver_id": {
"description": "Receiver of the delegated actions.",
"allOf": [
{
"$ref": "#/components/schemas/AccountId"
}
]
},
"sender_id": {
"description": "Signer of the delegated actions",
"allOf": [
{
"$ref": "#/components/schemas/AccountId"
}
]
}
}
}
Fields§
§actions: Vec<NonDelegateAction>
List of actions to be executed.
With the meta transactions MVP defined in NEP-366, nested DelegateActions are not allowed. A separate type is used to enforce it.
max_block_height: u64
The maximal height of the block in the blockchain below which the given DelegateAction is valid.
nonce: u64
Nonce to ensure that the same delegate action is not sent twice by a
relayer and should match for given account’s public_key
.
After this action is processed it will increment.
public_key: PublicKey
Public key used to sign this delegated action.
receiver_id: AccountId
Receiver of the delegated actions.
sender_id: AccountId
Signer of the delegated actions
Trait Implementations§
Source§impl Clone for DelegateAction
impl Clone for DelegateAction
Source§fn clone(&self) -> DelegateAction
fn clone(&self) -> DelegateAction
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 DelegateAction
impl Debug for DelegateAction
Source§impl<'de> Deserialize<'de> for DelegateAction
impl<'de> Deserialize<'de> for DelegateAction
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<&DelegateAction> for DelegateAction
impl From<&DelegateAction> for DelegateAction
Source§fn from(value: &DelegateAction) -> Self
fn from(value: &DelegateAction) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for DelegateAction
impl RefUnwindSafe for DelegateAction
impl Send for DelegateAction
impl Sync for DelegateAction
impl Unpin for DelegateAction
impl UnwindSafe for DelegateAction
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