[][src]Struct codegame::History

pub struct History<G: Game, T: RendererData<G>> { /* fields omitted */ }

Implementations

impl<G: Game, T: RendererData<G>> History<G, T>[src]

pub fn load(path: &str) -> impl Future<Output = Self>[src]

impl<G: Game, T: RendererData<G>> History<G, T>[src]

pub fn save(&self, writer: &mut dyn Write) -> Result<()>[src]

impl<G: Game, T: RendererData<G>> History<G, T>[src]

pub fn new(initial_game_state: G) -> Self[src]

pub fn current_state(&self) -> RenderState<'_, G, T>[src]

pub fn len(&self) -> usize[src]

pub fn go_to(
    &mut self,
    tick_time: f64,
    collect_events: bool
) -> Box<dyn Iterator<Item = G::Event>>

Notable traits for Box<R, Global>

impl<R> Read for Box<R, Global> where
    R: Read + ?Sized
impl<W> Write for Box<W, Global> where
    W: Write + ?Sized
impl<F, A> Future for Box<F, A> where
    F: Unpin + Future + ?Sized,
    A: Allocator + 'static, 
type Output = <F as Future>::Output;
[src]

pub fn tick_handler(&self) -> impl FnMut(&G, Vec<G::Event>) + Send + 'static[src]

pub fn debug_command_handler(
    &self
) -> impl Fn(usize, bool, DebugCommand<G>) + Send + 'static
[src]

Auto Trait Implementations

impl<G, T> RefUnwindSafe for History<G, T> where
    G: RefUnwindSafe,
    T: RefUnwindSafe,
    <G as Game>::DebugData: RefUnwindSafe,
    <G as Game>::Event: RefUnwindSafe
[src]

impl<G, T> Send for History<G, T> where
    <G as Game>::DebugData: Send + Sync,
    <G as Diff>::Delta: Send,
    <T as Diff>::Delta: Send,
    <G as Game>::Event: Send + Sync
[src]

impl<G, T> Sync for History<G, T> where
    <G as Game>::DebugData: Send + Sync,
    <G as Diff>::Delta: Send,
    <T as Diff>::Delta: Send,
    <G as Game>::Event: Send + Sync
[src]

impl<G, T> Unpin for History<G, T> where
    G: Unpin,
    T: Unpin
[src]

impl<G, T> UnwindSafe for History<G, T> where
    G: UnwindSafe,
    T: UnwindSafe,
    <G as Game>::DebugData: RefUnwindSafe,
    <G as Game>::Event: RefUnwindSafe
[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Pointable for T

type Init = T

The type for initializers.

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,