[−][src]Struct ssvm_container::storage::file_system::FileSystem
A file object which facilitates CRUD style operations on the file system The default storage path is the calling user's home directory
Methods
impl FileSystem
[src]
pub fn init() -> FileSystem
[src]
Name
init
Purpose
Initialises a SSVMContainer file system object
Input
N/A
Returns
FileSystem object
Example
let fs = ssvm_container::storage::file_system::FileSystem::init();
pub fn create_application(&self, _bytecode_wasm: &str) -> String
[src]
Name
create_application
Purpose
Store Wasm on the file system so that it's funtions can be executed later
Input
An instance of the FileSystem object A complete .wasm file in string format
Returns
A unique identifier which can be used to access the application later
Example
let bytecode_wasm = String::from("0x1234567890"); let uuid = ssvm_container::storage::file_system::FileSystem::create_application(&fs, &bytecode_wasm);
pub fn read_application(&self, _application_uuid: &str) -> String
[src]
Name
read_application
Purpose
Read the Wasm of a given application
Input
An instance of the FileSystem object An application's uuid as a string
Returns
A complete .wasm file's contents, as a string
Example
let bytecode_wasm_string = ssvm_container::storage::file_system::FileSystem::read_application(&fs, &uuid);
pub fn update_application(
&self,
_application_uuid: &str,
_bytecode_wasm: &str
) -> String
[src]
&self,
_application_uuid: &str,
_bytecode_wasm: &str
) -> String
Name
update_application
Purpose
Update the Wasm of a given application (overrides existing .wasm file)
Input
An instance of the FileSystem object A complete .wasm file in string format
Returns
A unique identifier which can be used to access the application later
Example
ssvm_container::storage::file_system::FileSystem::update_application(&fs, &uuid, &bytecode_wasm_update);
pub fn delete_application(&self, _application_uuid: &str) -> String
[src]
Trait Implementations
Auto Trait Implementations
impl Send for FileSystem
impl Unpin for FileSystem
impl Sync for FileSystem
impl UnwindSafe for FileSystem
impl RefUnwindSafe for FileSystem
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,