[−][src]Struct prototty_wasm_storage::WasmStorage
Methods
impl WasmStorage
[src]
pub fn new(js_byte_storage: JsByteStorage) -> Self
[src]
Trait Implementations
impl Storage for WasmStorage
[src]
fn load_raw<K>(&self, key: K) -> Result<Vec<u8>, LoadError> where
K: AsRef<str>,
[src]
K: AsRef<str>,
fn store_raw<K, V>(&mut self, key: K, value: V) -> Result<(), StoreError> where
K: AsRef<str>,
V: AsRef<[u8]>,
[src]
K: AsRef<str>,
V: AsRef<[u8]>,
fn remove_raw<K>(&mut self, key: K) -> Result<Vec<u8>, LoadError> where
K: AsRef<str>,
[src]
K: AsRef<str>,
fn exists<K>(&self, key: K) -> bool where
K: AsRef<str>,
[src]
K: AsRef<str>,
fn clear(&mut self)
[src]
fn load<K, T>(&self, key: K) -> Result<T, LoadError> where
K: AsRef<str>,
T: DeserializeOwned,
[src]
K: AsRef<str>,
T: DeserializeOwned,
fn store<K, T>(&mut self, key: K, value: &T) -> Result<(), StoreError> where
K: AsRef<str>,
T: Serialize,
[src]
K: AsRef<str>,
T: Serialize,
fn remove<K, T>(&mut self, key: K) -> Result<T, LoadError> where
K: AsRef<str>,
T: DeserializeOwned,
[src]
K: AsRef<str>,
T: DeserializeOwned,
Auto Trait Implementations
impl !Send for WasmStorage
impl !Sync for WasmStorage
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From for T
[src]
impl<T, U> TryFrom 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> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,