pub type ConsensusPublicKey = BLSPublicKey;

Aliased Type§

struct ConsensusPublicKey(/* private fields */);

Implementations

§

impl BLSPublicKey

pub fn raw(self) -> PublicKey

return raw public key

Trait Implementations

§

impl From<&BLSPrivateKey> for BLSPublicKey

§

fn from(private_key: &BLSPrivateKey) -> BLSPublicKey

Converts to this type from the input type.
§

impl From<PublicKey> for BLSPublicKey

§

fn from(raw: PublicKey) -> BLSPublicKey

Converts to this type from the input type.
§

impl From<BLSPublicKeyUnchecked> for BLSPublicKey

§

fn from(unchecked: BLSPublicKeyUnchecked) -> BLSPublicKey

Converts to this type from the input type.
§

impl Hash for BLSPublicKey

§

fn hash<H>(&self, state: &mut H)
where H: Hasher,

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
§

impl VerifyingKey for BLSPublicKey

§

type SignatureMaterial = BLSSignature

The associated signature type for this verifying key.
§

type SigningKeyMaterial = BLSPrivateKey

The associated signing key type for this verifying key.
§

fn verify_struct_signature<T>( &self, message: &T, signature: &Self::SignatureMaterial ) -> Result<(), Error>
where T: CryptoHash + Serialize,

We provide the striaghtfoward implementation which dispatches to the signature.
§

fn batch_verify<T>( message: &T, keys_and_signatures: Vec<(Self, Self::SignatureMaterial)> ) -> Result<(), Error>
where T: CryptoHash + Serialize,

We provide the implementation which dispatches to the signature.
§

impl PublicKey for BLSPublicKey

§

type PrivateKeyMaterial = BLSPrivateKey

We require public / private types to be coupled, i.e. their associated type is each other.
§

impl ValidCryptoMaterial for BLSPublicKey

§

fn to_bytes(&self) -> Vec<u8>

Convert the valid crypto material to bytes.
§

impl Debug for BLSPublicKey

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
§

impl TryFrom<&[u8]> for BLSPublicKey

§

fn try_from(bytes: &[u8]) -> Result<BLSPublicKey, CryptoMaterialError>

Deserialize an BLSPrivateKey. This method will also check for key validity.

§

type Error = CryptoMaterialError

The type returned in the event of a conversion error.
§

impl Display for BLSPublicKey

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
§

impl Serialize for BLSPublicKey

§

fn serialize<S>( &self, serializer: S ) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
§

impl<'de> Deserialize<'de> for BLSPublicKey

§

fn deserialize<D>( deserializer: D ) -> Result<BLSPublicKey, <D as Deserializer<'de>>::Error>
where D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
§

impl PartialEq for BLSPublicKey

§

fn eq(&self, other: &BLSPublicKey) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
§

impl Eq for BLSPublicKey

§

impl Clone for BLSPublicKey

§

fn clone(&self) -> BLSPublicKey

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more