pub struct Director { /* private fields */ }Implementations§
Source§impl Director
impl Director
pub fn new(schedule: Schedule, seed: u64) -> Result<Self, DirectorError>
pub fn schedule(&self) -> &Schedule
pub fn now(&self) -> u64
pub fn load(&self) -> u64
pub fn table_load(&self, table: u32) -> u64
pub fn alive(&self, id: u32) -> u32
pub fn is_quiet(&self) -> bool
pub fn weight(&self, id: u32) -> u32
pub fn set_weight(&mut self, id: u32, weight: u32) -> Option<u32>
pub fn died(&mut self, id: u32, count: u32) -> u32
pub fn tick(&mut self, spots: &Spots<'_>, out: &mut Vec<SpawnOrder>)
pub fn save(&self) -> Vec<u8> ⓘ
pub fn restore(&mut self, bytes: &[u8]) -> Result<(), DirectorError>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Director
impl RefUnwindSafe for Director
impl Send for Director
impl Sync for Director
impl Unpin for Director
impl UnsafeUnpin for Director
impl UnwindSafe for Director
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