Trait tinychain::gateway::Client [−][src]
pub trait Client { #[must_use] fn fetch<'life0, 'life1, 'life2, 'life3, 'async_trait, T: FromStream<Context = ()>>(
&'life0 self,
txn_id: &'life1 TxnId,
link: &'life2 Link,
key: &'life3 Value
) -> Pin<Box<dyn Future<Output = TCResult<T>> + Send + 'async_trait>>
where
T: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: 'async_trait; #[must_use] fn get<'life0, 'async_trait>(
&'life0 self,
txn: Txn,
link: Link,
key: Value
) -> Pin<Box<dyn Future<Output = TCResult<State>> + Send + 'async_trait>>
where
'life0: 'async_trait,
Self: 'async_trait; #[must_use] fn put<'life0, 'async_trait>(
&'life0 self,
txn: Txn,
link: Link,
key: Value,
value: State
) -> Pin<Box<dyn Future<Output = TCResult<()>> + Send + 'async_trait>>
where
'life0: 'async_trait,
Self: 'async_trait; #[must_use] fn post<'life0, 'async_trait>(
&'life0 self,
txn: Txn,
link: Link,
params: State
) -> Pin<Box<dyn Future<Output = TCResult<State>> + Send + 'async_trait>>
where
'life0: 'async_trait,
Self: 'async_trait; #[must_use] fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
txn: &'life1 Txn,
link: Link,
key: Value
) -> Pin<Box<dyn Future<Output = TCResult<()>> + Send + 'async_trait>>
where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait; }
Expand description
A client used by Gateway
Required methods
#[must_use]fn fetch<'life0, 'life1, 'life2, 'life3, 'async_trait, T: FromStream<Context = ()>>(
&'life0 self,
txn_id: &'life1 TxnId,
link: &'life2 Link,
key: &'life3 Value
) -> Pin<Box<dyn Future<Output = TCResult<T>> + Send + 'async_trait>> where
T: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn fetch<'life0, 'life1, 'life2, 'life3, 'async_trait, T: FromStream<Context = ()>>(&'life0 self,
txn_id: &'life1 TxnId,
link: &'life2 Link,
key: &'life3 Value
) -> Pin<Box<dyn Future<Output = TCResult<T>> + Send + 'async_trait>> where
T: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: 'async_trait,
Expand description
Read a simple value.
#[must_use]fn get<'life0, 'async_trait>(
&'life0 self,
txn: Txn,
link: Link,
key: Value
) -> Pin<Box<dyn Future<Output = TCResult<State>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn get<'life0, 'async_trait>(&'life0 self,
txn: Txn,
link: Link,
key: Value
) -> Pin<Box<dyn Future<Output = TCResult<State>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Expand description
Read a State
.
#[must_use]fn put<'life0, 'async_trait>(
&'life0 self,
txn: Txn,
link: Link,
key: Value,
value: State
) -> Pin<Box<dyn Future<Output = TCResult<()>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn put<'life0, 'async_trait>(&'life0 self,
txn: Txn,
link: Link,
key: Value,
value: State
) -> Pin<Box<dyn Future<Output = TCResult<()>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Expand description
Set key
= value
within the state referred to by link
.
#[must_use]fn post<'life0, 'async_trait>(
&'life0 self,
txn: Txn,
link: Link,
params: State
) -> Pin<Box<dyn Future<Output = TCResult<State>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn post<'life0, 'async_trait>(&'life0 self,
txn: Txn,
link: Link,
params: State
) -> Pin<Box<dyn Future<Output = TCResult<State>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Expand description
Execute a remote POST op.
#[must_use]fn delete<'life0, 'life1, 'async_trait>(
&'life0 self,
txn: &'life1 Txn,
link: Link,
key: Value
) -> Pin<Box<dyn Future<Output = TCResult<()>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn delete<'life0, 'life1, 'async_trait>(&'life0 self,
txn: &'life1 Txn,
link: Link,
key: Value
) -> Pin<Box<dyn Future<Output = TCResult<()>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Expand description
Delete key
from the state referred to by link
.