pub struct CollusionRingGenerator { /* private fields */ }Expand description
Generates collusion rings from available employee and vendor pools.
Implementations§
Source§impl CollusionRingGenerator
impl CollusionRingGenerator
Sourcepub fn generate(
&mut self,
employee_ids: &[String],
vendor_ids: &[String],
start_date: NaiveDate,
months: u32,
) -> Vec<CollusionRing>
pub fn generate( &mut self, employee_ids: &[String], vendor_ids: &[String], start_date: NaiveDate, months: u32, ) -> Vec<CollusionRing>
Generate collusion rings and advance them over the simulation period.
Creates 1-3 rings (resources permitting) from the supplied employee and
vendor ID pools, picks ring types appropriate to the available entities,
populates each ring with Conspirator members, and then advances every
ring month-by-month.
Auto Trait Implementations§
impl Freeze for CollusionRingGenerator
impl RefUnwindSafe for CollusionRingGenerator
impl Send for CollusionRingGenerator
impl Sync for CollusionRingGenerator
impl Unpin for CollusionRingGenerator
impl UnsafeUnpin for CollusionRingGenerator
impl UnwindSafe for CollusionRingGenerator
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.