pub enum ActionView {
Show 13 variants
CreateAccount,
DeployContract {
code: String,
},
FunctionCall {
args: FunctionArgs,
deposit: String,
gas: u64,
method_name: String,
},
Transfer {
deposit: String,
},
Stake {
public_key: PublicKey,
stake: String,
},
AddKey {
access_key: AccessKeyView,
public_key: PublicKey,
},
DeleteKey {
public_key: PublicKey,
},
DeleteAccount {
beneficiary_id: AccountId,
},
Delegate {
delegate_action: DelegateAction,
signature: Signature,
},
DeployGlobalContract {
code: String,
},
DeployGlobalContractByAccountId {
code: String,
},
UseGlobalContract {
code_hash: CryptoHash,
},
UseGlobalContractByAccountId {
account_id: AccountId,
},
}
Expand description
ActionView
JSON schema
{
"oneOf": [
{
"type": "string",
"enum": [
"CreateAccount"
]
},
{
"type": "object",
"required": [
"DeployContract"
],
"properties": {
"DeployContract": {
"type": "object",
"required": [
"code"
],
"properties": {
"code": {
"type": "string",
"format": "bytes"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"FunctionCall"
],
"properties": {
"FunctionCall": {
"type": "object",
"required": [
"args",
"deposit",
"gas",
"method_name"
],
"properties": {
"args": {
"$ref": "#/components/schemas/FunctionArgs"
},
"deposit": {
"type": "string"
},
"gas": {
"type": "integer",
"format": "uint64",
"minimum": 0.0
},
"method_name": {
"type": "string"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"Transfer"
],
"properties": {
"Transfer": {
"type": "object",
"required": [
"deposit"
],
"properties": {
"deposit": {
"type": "string"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"Stake"
],
"properties": {
"Stake": {
"type": "object",
"required": [
"public_key",
"stake"
],
"properties": {
"public_key": {
"$ref": "#/components/schemas/PublicKey"
},
"stake": {
"type": "string"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"AddKey"
],
"properties": {
"AddKey": {
"type": "object",
"required": [
"access_key",
"public_key"
],
"properties": {
"access_key": {
"$ref": "#/components/schemas/AccessKeyView"
},
"public_key": {
"$ref": "#/components/schemas/PublicKey"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"DeleteKey"
],
"properties": {
"DeleteKey": {
"type": "object",
"required": [
"public_key"
],
"properties": {
"public_key": {
"$ref": "#/components/schemas/PublicKey"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"DeleteAccount"
],
"properties": {
"DeleteAccount": {
"type": "object",
"required": [
"beneficiary_id"
],
"properties": {
"beneficiary_id": {
"$ref": "#/components/schemas/AccountId"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"Delegate"
],
"properties": {
"Delegate": {
"type": "object",
"required": [
"delegate_action",
"signature"
],
"properties": {
"delegate_action": {
"$ref": "#/components/schemas/DelegateAction"
},
"signature": {
"$ref": "#/components/schemas/Signature"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"DeployGlobalContract"
],
"properties": {
"DeployGlobalContract": {
"type": "object",
"required": [
"code"
],
"properties": {
"code": {
"type": "string",
"format": "bytes"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"DeployGlobalContractByAccountId"
],
"properties": {
"DeployGlobalContractByAccountId": {
"type": "object",
"required": [
"code"
],
"properties": {
"code": {
"type": "string",
"format": "bytes"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"UseGlobalContract"
],
"properties": {
"UseGlobalContract": {
"type": "object",
"required": [
"code_hash"
],
"properties": {
"code_hash": {
"$ref": "#/components/schemas/CryptoHash"
}
}
}
},
"additionalProperties": false
},
{
"type": "object",
"required": [
"UseGlobalContractByAccountId"
],
"properties": {
"UseGlobalContractByAccountId": {
"type": "object",
"required": [
"account_id"
],
"properties": {
"account_id": {
"$ref": "#/components/schemas/AccountId"
}
}
}
},
"additionalProperties": false
}
]
}
Variants§
CreateAccount
DeployContract
FunctionCall
Transfer
Stake
AddKey
DeleteKey
DeleteAccount
Delegate
DeployGlobalContract
DeployGlobalContractByAccountId
UseGlobalContract
Fields
§
code_hash: CryptoHash
UseGlobalContractByAccountId
Trait Implementations§
Source§impl Clone for ActionView
impl Clone for ActionView
Source§fn clone(&self) -> ActionView
fn clone(&self) -> ActionView
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 ActionView
impl Debug for ActionView
Source§impl<'de> Deserialize<'de> for ActionView
impl<'de> Deserialize<'de> for ActionView
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<&ActionView> for ActionView
impl From<&ActionView> for ActionView
Source§fn from(value: &ActionView) -> Self
fn from(value: &ActionView) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ActionView
impl RefUnwindSafe for ActionView
impl Send for ActionView
impl Sync for ActionView
impl Unpin for ActionView
impl UnwindSafe for ActionView
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