pub enum DriveCommand {
Show 17 variants ShadowRpcAuth, CreateStorageAccount { name: String, size: Byte, }, DeleteStorageAccount { storage_account: Pubkey, }, CancelDeleteStorageAccount { storage_account: Pubkey, }, ClaimStake { storage_account: Pubkey, }, AddStorage { storage_account: Pubkey, size: Byte, }, AddImmutableStorage { storage_account: Pubkey, size: Byte, }, ReduceStorage { storage_account: Pubkey, size: Byte, }, MakeStorageImmutable { storage_account: Pubkey, }, GetStorageAccount { storage_account: Pubkey, }, GetStorageAccounts { owner: Option<Pubkey>, }, ListFiles { storage_account: Pubkey, }, GetText { storage_account: Pubkey, filename: String, }, GetObjectData { storage_account: Pubkey, file: String, }, DeleteFile { storage_account: Pubkey, filename: String, }, EditFile { storage_account: Pubkey, path: PathBuf, }, StoreFiles { storage_account: Pubkey, files: Vec<PathBuf>, },
}

Variants§

§

ShadowRpcAuth

§

CreateStorageAccount

Fields

§name: String

Unique identifier for your storage account

§size: Byte

File size string, accepts KB, MB, GB, e.g. “10MB”

Create an account on which to store data. Storage accounts can be globally, irreversibly marked immutable for a one-time fee. Otherwise, files can be added or deleted from them, and space rented indefinitely.

§

DeleteStorageAccount

Fields

§storage_account: Pubkey

The account to delete

Queues a storage account for deletion. While the request is still enqueued and not yet carried out, a cancellation can be made (see cancel-delete-storage-account subcommand).

§

CancelDeleteStorageAccount

Fields

§storage_account: Pubkey

The account for which to cancel deletion.

Cancels the deletion of a storage account enqueued for deletion.

§

ClaimStake

Fields

§storage_account: Pubkey

The account whose stake to claim.

Redeem tokens afforded to a storage account after reducing storage capacity.

§

AddStorage

Fields

§storage_account: Pubkey

Storage account to modify

§size: Byte

File size string, accepts KB, MB, GB, e.g. “10MB”

Increase the capacity of a storage account.

§

AddImmutableStorage

Fields

§storage_account: Pubkey

Storage account to modify

§size: Byte

File size string, accepts KB, MB, GB, e.g. “10MB”

Increase the immutable storage capacity of a storage account.

§

ReduceStorage

Fields

§storage_account: Pubkey

Storage account to modify

§size: Byte

File size string, accepts KB, MB, GB, e.g. “10MB”

Reduce the capacity of a storage account.

§

MakeStorageImmutable

Fields

§storage_account: Pubkey

Storage account to be marked immutable

Make a storage account immutable. This is irreversible.

§

GetStorageAccount

Fields

§storage_account: Pubkey

Account whose metadata will be fetched.

Fetch the metadata pertaining to a storage account.

§

GetStorageAccounts

Fields

§owner: Option<Pubkey>

Searches for storage accounts owned by this owner.

Fetch a list of storage accounts owned by a particular pubkey. If no owner is provided, the configured signer is used.

§

ListFiles

Fields

§storage_account: Pubkey

Storage account whose files to list.

List all the files in a storage account.

§

GetText

Fields

§storage_account: Pubkey

Storage account where the file is located.

§filename: String

Name of the file to fetch

Get a file, assume it’s text, and print it.

§

GetObjectData

Fields

§storage_account: Pubkey

Storage account where the file is located.

§file: String

Name of the file to examine.

Get basic file object data from a storage account file.

§

DeleteFile

Fields

§storage_account: Pubkey

Storage account where the file to delete is located.

§filename: String

Name of the file to delete.

Delete a file from a storage account.

§

EditFile

Fields

§storage_account: Pubkey

Storage account where the file to edit is located.

§path: PathBuf

Path to the new version of the file. Must be the same name as the file you are editing.

Has to be the same name as a previously uploaded file

§

StoreFiles

Fields

§storage_account: Pubkey

The storage account on which to upload the files

§files: Vec<PathBuf>

A list of one or more filepaths, each of which is to be uploaded.

Upload one or more files to a storage account.

Implementations§

source§

impl DriveCommand

source

pub async fn process<T: Signer>( &self, signer: &T, client_signer: T, rpc_url: &str, skip_confirm: bool, auth: Option<String> ) -> Result<()>

Trait Implementations§

source§

impl CommandFactory for DriveCommand

source§

fn into_app<'b>() -> Command<'b>

Deprecated, replaced with CommandFactory::command
source§

fn into_app_for_update<'b>() -> Command<'b>

Deprecated, replaced with CommandFactory::command_for_update
source§

fn command<'help>() -> App<'help>

Build a Command that can instantiate Self. Read more
source§

fn command_for_update<'help>() -> App<'help>

Build a Command that can update self. Read more
source§

impl Debug for DriveCommand

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromArgMatches for DriveCommand

source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
source§

fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches ) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
source§

fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches ) -> Result<(), Error>

Assign values from ArgMatches to self.
source§

fn update_from_arg_matches_mut<'b>( &mut self, __clap_arg_matches: &mut ArgMatches ) -> Result<(), Error>

Assign values from ArgMatches to self.
source§

impl Parser for DriveCommand

source§

fn parse() -> Self

Parse from std::env::args_os(), exit on error
source§

fn try_parse() -> Result<Self, Error>

Parse from std::env::args_os(), return Err on error.
source§

fn parse_from<I, T>(itr: I) -> Selfwhere I: IntoIterator<Item = T>, T: Into<OsString> + Clone,

Parse from iterator, exit on error
source§

fn try_parse_from<I, T>(itr: I) -> Result<Self, Error>where I: IntoIterator<Item = T>, T: Into<OsString> + Clone,

Parse from iterator, return Err on error.
source§

fn update_from<I, T>(&mut self, itr: I)where I: IntoIterator<Item = T>, T: Into<OsString> + Clone,

Update from iterator, exit on error
source§

fn try_update_from<I, T>(&mut self, itr: I) -> Result<(), Error>where I: IntoIterator<Item = T>, T: Into<OsString> + Clone,

Update from iterator, return Err on error.
source§

impl Subcommand for DriveCommand

source§

fn augment_subcommands<'b>(__clap_app: Command<'b>) -> Command<'b>

Append to Command so it can instantiate Self. Read more
source§

fn augment_subcommands_for_update<'b>(__clap_app: Command<'b>) -> Command<'b>

Append to Command so it can update self. Read more
source§

fn has_subcommand(__clap_name: &str) -> bool

Test whether Self can parse a specific subcommand

Auto Trait Implementations§

Blanket Implementations§

§

impl<T> AbiExample for T

§

default fn example() -> T

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere T: 'a,

§

fn implicit( self, class: Class, constructed: bool, tag: u32 ) -> TaggedParser<'a, Implicit, Self, E>

source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> Pointable for T

§

const ALIGN: usize = mem::align_of::<T>()

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
source§

impl<T> Same<T> for T

§

type Output = T

Should always be Self
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for Twhere V: MultiLane<T>,

§

fn vzip(self) -> V

source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more