pub struct GeneratorSet(pub VerkeyGroup, pub Vec<SignatureGroup>);Expand description
second element is a vector of length l+2 and is of form [h, h_0, h_1, h_2, …, h_l]
Tuple Fields§
§0: VerkeyGroup§1: Vec<SignatureGroup>Implementations§
Source§impl GeneratorSet
impl GeneratorSet
pub fn new(T: u128, prefix: &str) -> Result<Self, PixelError>
Sourcepub fn create_generators(
T: u128,
prefix: &str,
) -> Result<Vec<SignatureGroup>, PixelError>
pub fn create_generators( T: u128, prefix: &str, ) -> Result<Vec<SignatureGroup>, PixelError>
Returns generators to be used in the protocol. Takes time period T and a prefix string that is used to create generators by hashing the prefix string concatenated with integers. T+1 must be a power of 2.
Auto Trait Implementations§
impl Freeze for GeneratorSet
impl RefUnwindSafe for GeneratorSet
impl Send for GeneratorSet
impl Sync for GeneratorSet
impl Unpin for GeneratorSet
impl UnsafeUnpin for GeneratorSet
impl UnwindSafe for GeneratorSet
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more