Overview | Project | Class | Tree | Deprecated | Index

Nestopia Core API

FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD

## api
Class Nes::Api::Rewinder

    Base
       |
       +--Nes::Api::Rewinder

class Nes::Api::Rewinder
extends Base

Game rewinder interface.

Inner Classes, Typedefs, and Enums
`enum` | `Nes::Api::Rewinder::Direction` Direction.
`enum` | `Nes::Api::Rewinder::State` Rewinder state.
`typedef` | `Nes::Api::Rewinder::StateCallback` Rewinder state callback prototype.

Field Summary
`static Nes::Api::Rewinder::StateCaller` | `stateCallback` Rewinder state callback manager.

Constructor Summary
`Rewinder( T& instance )` Interface constructor.

Method Summary
`Result` | `Enable( bool state = true )` Enables rewinder.
`void` | `EnableSound( bool state = true )` Enables backward sound.
`Nes::Api::Rewinder::Direction` | `GetDirection() const` Returns the current direction.
`bool` | `IsEnabled() const` Checks if rewinder is enabled.
`bool` | `IsSoundEnabled() const` Checks if backward sound is enabled.
`void` | `Reset()` Resets rewinder.
`Result` | `SetDirection( Nes::Api::Rewinder::Direction direction )` Sets direction.

Field Detail

### stateCallback

    public static Nes::Api::Rewinder::StateCaller stateCallback;

  Rewinder state callback manager. Static object used for adding the user defined callback.

Constructor Detail

### Rewinder

    public Rewinder( T& instance );

  Interface constructor.

Parameters:
  `instance` - emulator instance

Method Detail

### Enable

    public Result Enable( bool state = true ) throw();

  Enables rewinder.

Parameters:
  `state` - true to enable
Returns:
  result code

### EnableSound

    public void EnableSound( bool state = true ) throw();

  Enables backward sound.

Parameters:
  `state` - true to enable

### GetDirection

    public Nes::Api::Rewinder::Direction GetDirection() const throw();

  Returns the current direction.

Returns:
  current direction

### IsEnabled

    public bool IsEnabled() const throw();

  Checks if rewinder is enabled.

Returns:
  true if enabled

### IsSoundEnabled

    public bool IsSoundEnabled() const throw();

  Checks if backward sound is enabled.

Returns:
  true if enabled

### Reset

    public void Reset() throw();

  Resets rewinder.

### SetDirection

    public Result SetDirection( Nes::Api::Rewinder::Direction direction ) throw();

  Sets direction.

Parameters:
  `direction` - direction, FORWARD or BACKWARD
Returns:
  result code

Overview | Project | Class | Tree | Deprecated | Index

Nestopia Core API

FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD