Trait holochain::conductor::conductor::DpkiService
source · pub trait DpkiService: Send + Sync {
// Required methods
fn is_key_valid<'life0, 'async_trait>(
&'life0 self,
key: AgentPubKey,
timestamp: Timestamp
) -> Pin<Box<dyn Future<Output = DpkiServiceResult<bool>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn key_mutation<'life0, 'async_trait>(
&'life0 self,
old_key: Option<AgentPubKey>,
new_key: Option<AgentPubKey>
) -> Pin<Box<dyn Future<Output = DpkiServiceResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn cell_ids<'a>(&'a self) -> HashSet<&'a CellId>;
}
Expand description
Interface for the DPKI service
Required Methods§
sourcefn is_key_valid<'life0, 'async_trait>(
&'life0 self,
key: AgentPubKey,
timestamp: Timestamp
) -> Pin<Box<dyn Future<Output = DpkiServiceResult<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn is_key_valid<'life0, 'async_trait>(
&'life0 self,
key: AgentPubKey,
timestamp: Timestamp
) -> Pin<Box<dyn Future<Output = DpkiServiceResult<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Check if the key is valid (properly created and not revoked) as-at the given Timestamp
sourcefn key_mutation<'life0, 'async_trait>(
&'life0 self,
old_key: Option<AgentPubKey>,
new_key: Option<AgentPubKey>
) -> Pin<Box<dyn Future<Output = DpkiServiceResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn key_mutation<'life0, 'async_trait>(
&'life0 self,
old_key: Option<AgentPubKey>,
new_key: Option<AgentPubKey>
) -> Pin<Box<dyn Future<Output = DpkiServiceResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Defines the different ways that keys can be created and destroyed: If an old key is specified, it will be destroyed If a new key is specified, it will be registered If both a new and an old key are specified, the new key will atomically replace the old key (If no keys are specified, nothing will happen)
Implementors§
impl DpkiService for DeepkeyBuiltin
impl DpkiService for MockDpkiService
Interface for the DPKI service