pub struct State<P: PoolParams> {
pub hashes: Vec<Vec<Num<P::Fr>>>,
pub items: Vec<(Account<P::Fr>, Note<P::Fr>)>,
pub default_hashes: Vec<Num<P::Fr>>,
pub sigma: Num<P::Fs>,
pub account_id: usize,
pub note_id: Vec<usize>,
}
Fields§
§hashes: Vec<Vec<Num<P::Fr>>>
§items: Vec<(Account<P::Fr>, Note<P::Fr>)>
§default_hashes: Vec<Num<P::Fr>>
§sigma: Num<P::Fs>
§account_id: usize
§note_id: Vec<usize>
Implementations§
Source§impl<P: PoolParams> State<P>
impl<P: PoolParams> State<P>
pub fn random_sample_state<R: Rng>(rng: &mut R, params: &P) -> Self
pub fn random_sample_transfer<R: Rng>( &self, rng: &mut R, params: &P, ) -> (TransferPub<P::Fr>, TransferSec<P::Fr>)
Auto Trait Implementations§
impl<P> Freeze for State<P>
impl<P> RefUnwindSafe for State<P>
impl<P> Send for State<P>
impl<P> Sync for State<P>
impl<P> Unpin for State<P>
impl<P> UnwindSafe for State<P>
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<Out, S> FromSeed<S> for Outwhere
S: SeedBoxGen<Out>,
impl<Out, S> FromSeed<S> for Outwhere
S: SeedBoxGen<Out>,
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