[−][src]Trait vade::traits::VcResolver
Implementing struct supports fetching vc documents by their id.
Required methods
#[must_use]fn check_vc<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
vc_id: &'life1 str,
value: &'life2 str
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
&'life0 self,
vc_id: &'life1 str,
value: &'life2 str
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Checks given VC document. A VC document is considered as valid if returning (). Resolver may throw to indicate
- that it is not responsible for this VC
- that it considers this VC as invalid
Arguments
vc_id
- vc_id to check document forvalue
- value to check
#[must_use]fn get_vc_document<'life0, 'life1, 'async_trait>(
&'life0 self,
vd_id: &'life1 str
) -> Pin<Box<dyn Future<Output = Result<String, Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
&'life0 self,
vd_id: &'life1 str
) -> Pin<Box<dyn Future<Output = Result<String, Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
#[must_use]fn set_vc_document<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
key: &'life1 str,
value: &'life2 str
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
&'life0 mut self,
key: &'life1 str,
value: &'life2 str
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Implementors
impl VcResolver for RustStorageCache
[src]
fn check_vc<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
vc_id: &'life1 str,
_value: &'life2 str
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
[src]
&'life0 self,
vc_id: &'life1 str,
_value: &'life2 str
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Checks given Vc document. A Vc document is considered as valid if returning (). Resolver may throw to indicate
- that it is not responsible for this Vc
- that it considers this Vc as invalid
Currently the test vc_id
"test"
is accepted as valid.
Arguments
vc_id
- vc_id to check document forvalue
- value to check
fn get_vc_document<'life0, 'life1, 'async_trait>(
&'life0 self,
vc_name: &'life1 str
) -> Pin<Box<dyn Future<Output = Result<String, Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
[src]
&'life0 self,
vc_name: &'life1 str
) -> Pin<Box<dyn Future<Output = Result<String, Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn set_vc_document<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
vc_name: &'life1 str,
value: &'life2 str
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
[src]
&'life0 mut self,
vc_name: &'life1 str,
value: &'life2 str
) -> Pin<Box<dyn Future<Output = Result<(), Box<dyn Error>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,