#[non_exhaustive]#[repr(u8)]pub enum VaultAction<Address> {
UpdateVaultConfig {
vault_address: Address,
args: UpdateVaultConfigArgs,
},
ProcessWithdrawalQueue {
vault_address: Address,
},
WhitelistDepositor {
vault_address: Address,
user_address: Address,
},
UnwhitelistDepositor {
vault_address: Address,
user_address: Address,
},
DelegateVaultUser {
vault_address: Address,
delegate: Address,
name: CustomString,
},
RevokeVaultDelegation {
vault_address: Address,
delegate: Address,
},
DelegateVaultUserV1 {
vault_address: Address,
delegate: Address,
name: CustomString,
expires_at: Option<UnixTimestampMicros>,
flags: u32,
},
}Expand description
Vault management operations requiring vault leadership.
These operations can only be called by the vault leader (the address that created the vault).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
UpdateVaultConfig
Update vault configuration (leader only).
ProcessWithdrawalQueue
Process pending vault withdrawals.
Fields
§
vault_address: AddressWhitelistDepositor
Whitelist a depositor for the vault.
UnwhitelistDepositor
Remove a depositor from the vault whitelist.
DelegateVaultUser
Delegate vault trading to another address.
RevokeVaultDelegation
Revoke vault trading delegation.
DelegateVaultUserV1
Delegate vault trading with optional expiry and flags
Fields
§
vault_address: Address§
delegate: Address§
name: CustomString§
expires_at: Option<UnixTimestampMicros>Trait Implementations§
Source§impl<Address> AsRef<str> for VaultAction<Address>
impl<Address> AsRef<str> for VaultAction<Address>
Source§impl<Address> BorshDeserialize for VaultAction<Address>where
Address: BorshDeserialize,
impl<Address> BorshDeserialize for VaultAction<Address>where
Address: BorshDeserialize,
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<Address> BorshSerialize for VaultAction<Address>where
Address: BorshSerialize,
impl<Address> BorshSerialize for VaultAction<Address>where
Address: BorshSerialize,
Source§impl<Address: Clone> Clone for VaultAction<Address>
impl<Address: Clone> Clone for VaultAction<Address>
Source§fn clone(&self) -> VaultAction<Address>
fn clone(&self) -> VaultAction<Address>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<Address: Debug> Debug for VaultAction<Address>
impl<Address: Debug> Debug for VaultAction<Address>
Source§impl<'de, Address> Deserialize<'de> for VaultAction<Address>where
Address: Deserialize<'de>,
impl<'de, Address> Deserialize<'de> for VaultAction<Address>where
Address: Deserialize<'de>,
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<Address> EnumExt for VaultAction<Address>where
Address: BorshDeserialize,
impl<Address> EnumExt for VaultAction<Address>where
Address: BorshDeserialize,
Source§impl<'_enum, Address> From<&'_enum VaultAction<Address>> for VaultActionDiscriminants
impl<'_enum, Address> From<&'_enum VaultAction<Address>> for VaultActionDiscriminants
Source§fn from(val: &'_enum VaultAction<Address>) -> VaultActionDiscriminants
fn from(val: &'_enum VaultAction<Address>) -> VaultActionDiscriminants
Converts to this type from the input type.
Source§impl<Address> From<VaultAction<Address>> for CallMessage<Address>
impl<Address> From<VaultAction<Address>> for CallMessage<Address>
Source§fn from(v: VaultAction<Address>) -> Self
fn from(v: VaultAction<Address>) -> Self
Converts to this type from the input type.
Source§impl<Address> From<VaultAction<Address>> for VaultActionDiscriminants
impl<Address> From<VaultAction<Address>> for VaultActionDiscriminants
Source§fn from(val: VaultAction<Address>) -> VaultActionDiscriminants
fn from(val: VaultAction<Address>) -> VaultActionDiscriminants
Converts to this type from the input type.
Source§impl<Address: Hash> Hash for VaultAction<Address>
impl<Address: Hash> Hash for VaultAction<Address>
Source§impl<Address: JsonSchema> JsonSchema for VaultAction<Address>
impl<Address: JsonSchema> JsonSchema for VaultAction<Address>
Source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref keyword. Read moreSource§impl<Address: Ord> Ord for VaultAction<Address>
impl<Address: Ord> Ord for VaultAction<Address>
Source§fn cmp(&self, other: &VaultAction<Address>) -> Ordering
fn cmp(&self, other: &VaultAction<Address>) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl<Address: PartialEq> PartialEq for VaultAction<Address>
impl<Address: PartialEq> PartialEq for VaultAction<Address>
Source§fn eq(&self, other: &VaultAction<Address>) -> bool
fn eq(&self, other: &VaultAction<Address>) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl<Address: PartialOrd> PartialOrd for VaultAction<Address>
impl<Address: PartialOrd> PartialOrd for VaultAction<Address>
Source§impl<Address> Serialize for VaultAction<Address>where
Address: Serialize,
impl<Address> Serialize for VaultAction<Address>where
Address: Serialize,
Source§impl<Address> UniversalWallet for VaultAction<Address>where
__SovVirtualWallet_VaultAction_UpdateVaultConfig<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_ProcessWithdrawalQueue<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_WhitelistDepositor<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_UnwhitelistDepositor<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_DelegateVaultUser<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_RevokeVaultDelegation<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_DelegateVaultUserV1<Address>: UniversalWallet,
Self: 'static,
impl<Address> UniversalWallet for VaultAction<Address>where
__SovVirtualWallet_VaultAction_UpdateVaultConfig<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_ProcessWithdrawalQueue<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_WhitelistDepositor<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_UnwhitelistDepositor<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_DelegateVaultUser<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_RevokeVaultDelegation<Address>: UniversalWallet,
__SovVirtualWallet_VaultAction_DelegateVaultUserV1<Address>: UniversalWallet,
Self: 'static,
Source§fn scaffold() -> Item<IndexLinking>
fn scaffold() -> Item<IndexLinking>
Generate the “scaffolding” of the item. If the item is a primtive, this is just the corresponding primtive.
If the type is composed of other types, this is the container with all links set to
Link::Placeholder.Source§fn get_child_links(schema: &mut Schema) -> Vec<Link>
fn get_child_links(schema: &mut Schema) -> Vec<Link>
Ensure that each type contained in the outer type (i.e. the type of each struct/tuple field) is added to the schema,
and return a
Link connecting the child to the parent. Read moreSource§fn get_child_templates(schema: &mut Schema) -> TransactionTemplateSet
fn get_child_templates(schema: &mut Schema) -> TransactionTemplateSet
Empty by default
When derived by the macro, builds a template set from annotations on the fields + the field
types’ own get_child_templates()
Source§fn write_schema(schema: &mut Schema) -> Link
fn write_schema(schema: &mut Schema) -> Link
Writes the type to the schema if it is not already present and returns a link to it. Read more
Source§fn make_root_of(schema: &mut Schema)
fn make_root_of(schema: &mut Schema)
Writes the type and all its children to the schema, if not already present, and sets the
type as a root type. Generates any templates defined on that type.
Source§fn make_linkable(schema: &mut Schema) -> Link
fn make_linkable(schema: &mut Schema) -> Link
Gets a link to the type, writing the type to the schema if necessary.
Source§fn id_override() -> Option<ItemId>
fn id_override() -> Option<ItemId>
Override the type ID of the item. This should typically not be written by hand. Instead,
use the
OverrideSchema trait.impl<Address: Eq> Eq for VaultAction<Address>
impl<Address> StructuralPartialEq for VaultAction<Address>
Auto Trait Implementations§
impl<Address> Freeze for VaultAction<Address>where
Address: Freeze,
impl<Address> RefUnwindSafe for VaultAction<Address>where
Address: RefUnwindSafe,
impl<Address> Send for VaultAction<Address>where
Address: Send,
impl<Address> Sync for VaultAction<Address>where
Address: Sync,
impl<Address> Unpin for VaultAction<Address>where
Address: Unpin,
impl<Address> UnsafeUnpin for VaultAction<Address>where
Address: UnsafeUnpin,
impl<Address> UnwindSafe for VaultAction<Address>where
Address: UnwindSafe,
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