Struct mjolnir::mjolnir_lib::generators::adversary_vote_casts_generator::AdversaryVoteCastsGenerator
source · pub struct AdversaryVoteCastsGenerator<'a, S: SyncNode + Send> {
expiry_generator: BlockDateGenerator,
voter: Wallet,
vote_plans: Vec<VotePlan>,
voting_privacy: PayloadType,
node: RemoteJormungandr,
rand: OsRng,
fragment_sender: FragmentSender<'a, S>,
max_splits: usize,
}
Fields§
§expiry_generator: BlockDateGenerator
§voter: Wallet
§vote_plans: Vec<VotePlan>
§voting_privacy: PayloadType
§node: RemoteJormungandr
§rand: OsRng
§fragment_sender: FragmentSender<'a, S>
§max_splits: usize
Implementations§
source§impl<'a, S: SyncNode + Send> AdversaryVoteCastsGenerator<'a, S>
impl<'a, S: SyncNode + Send> AdversaryVoteCastsGenerator<'a, S>
pub fn new( expiry_generator: BlockDateGenerator, voter: Wallet, vote_plans: Vec<VotePlan>, node: RemoteJormungandr, fragment_sender: FragmentSender<'a, S> ) -> Self
fn send(&mut self) -> Result<MemPoolCheck, FragmentSenderError>
fn wrong_vote_plan(&self) -> Fragment
fn wrong_proposal_index(&self) -> Fragment
fn wrong_voting_privacy(&self) -> Fragment
fn wrong_choice(&self) -> Fragment
Trait Implementations§
Auto Trait Implementations§
impl<'a, S> !RefUnwindSafe for AdversaryVoteCastsGenerator<'a, S>
impl<'a, S> Send for AdversaryVoteCastsGenerator<'a, S>where S: Sync,
impl<'a, S> !Sync for AdversaryVoteCastsGenerator<'a, S>
impl<'a, S> Unpin for AdversaryVoteCastsGenerator<'a, S>
impl<'a, S> !UnwindSafe for AdversaryVoteCastsGenerator<'a, S>
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request