Trait tendermint_machine::ext::Signer
source · pub trait Signer: Send + Sync {
type ValidatorId: ValidatorId;
type Signature: Signature;
// Required methods
fn validator_id<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Option<Self::ValidatorId>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn sign<'life0, 'life1, 'async_trait>(
&'life0 self,
msg: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = Self::Signature> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}
Expand description
A signer for a validator.
Required Associated Types§
type ValidatorId: ValidatorId
Required Methods§
sourcefn validator_id<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Option<Self::ValidatorId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn validator_id<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Option<Self::ValidatorId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Returns the validator’s current ID. Returns None if they aren’t a current validator.