Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

Phx::RawInputEngine::Driver Class Reference

The driver interface through which device drivers deposit the current device state to be read by clients. More...

#include <PhxRawInputEngine.h>

Inheritance diagram for Phx::RawInputEngine::Driver:

Phx::LockedPtrInterface< Driver > List of all members.

Public Types

typedef RawInputEngine::ButtonIdentifier ButtonIdentifier
typedef RawInputEngine::AxisIdentifier AxisIdentifier
typedef RawInputEngine::ButtonState ButtonState
typedef RawInputEngine::AxisState AxisState

Public Member Functions

virtual void listener (Listener *listener)=0
 Sets the listener to be notified by the input layer.
virtual void buttonName (ButtonIdentifier button, const String &name)=0
 Sets the text-name for a raw button.
virtual String buttonName (ButtonIdentifier button) const =0
 Retrives the text name for the given button.
virtual void buttonState (ButtonIdentifier button, ButtonState state)=0
 Sets the current button state for the given button.
virtual ButtonState buttonState (ButtonIdentifier button) const =0
 Gets the current state for a button as set by the driver.
virtual void axisName (AxisIdentifier axis, const String &name)=0
 Sets the text-name for a raw axis.
virtual String axisName (AxisIdentifier axis) const =0
 Retrives the text name for the give axis.
virtual void axisState (AxisIdentifier axis, AxisState state)=0
 Sets the current axis state for the given axis.
virtual AxisState axisState (AxisIdentifier axis) const =0
 Gets the current state for a axis as set by the driver.
const String & name () const
 Returns the name of this driver.

Protected Member Functions

void setName (const String &name)

Classes

class  Listener
 A listener that is notified by the input layer each frame. More...

Detailed Description

The driver interface through which device drivers deposit the current device state to be read by clients.


Member Function Documentation

virtual String Phx::RawInputEngine::Driver::axisName AxisIdentifier  axis  )  const [pure virtual]
 

Retrives the text name for the give axis.

Parameters:
axis The axis whose name should be returned.
Returns:
The name previous set for the given axis.

virtual void Phx::RawInputEngine::Driver::axisName AxisIdentifier  axis,
const String &  name
[pure virtual]
 

Sets the text-name for a raw axis.

The text name is what would be displayed to the user when binding raw axes to logical axes (e.g., "Mouse X" for the X axis of a mouse, or "Rotary 1" for a nondescript dial).

Parameters:
axis The identifier for the axis to be named.
name The new name for the axis.
Exceptions:
InUseException thrown if 'name' is already used to identify another axis.
PermissionException thrown if axis is INVALID_AXIS_IDENTIFIER;

virtual AxisState Phx::RawInputEngine::Driver::axisState AxisIdentifier  axis  )  const [pure virtual]
 

Gets the current state for a axis as set by the driver.

Parameters:
axis The axis whose state should be returned.
Returns:
The current state of the axis whose identifier is given.

virtual void Phx::RawInputEngine::Driver::axisState AxisIdentifier  axis,
AxisState  state
[pure virtual]
 

Sets the current axis state for the given axis.

Parameters:
axis The axis whose state should be set.
state The new state for the given axis.
Exceptions:
PermissionException thrown if axis is INVALID_AXIS_IDENTIFIER;

virtual String Phx::RawInputEngine::Driver::buttonName ButtonIdentifier  button  )  const [pure virtual]
 

Retrives the text name for the given button.

Parameters:
button The button whose name should be returned.
Returns:
The name previously set for the given button.

virtual void Phx::RawInputEngine::Driver::buttonName ButtonIdentifier  button,
const String &  name
[pure virtual]
 

Sets the text-name for a raw button.

The text name is what would be displayed to the user when binding raw buttons to logical buttons (e.g., "g" for the g key, or "Trigger" for a trigger on a joystick).

Parameters:
button The identifier for the button to be named.
name The new name for the button.
Exceptions:
InUseException thrown if name is already used to identify another button.
PermissionException thrown if button is INVALID_BUTTON_IDENTIFIER;

virtual ButtonState Phx::RawInputEngine::Driver::buttonState ButtonIdentifier  button  )  const [pure virtual]
 

Gets the current state for a button as set by the driver.

Parameters:
button The button whose state should be returned.
Returns:
The current state of the button whose identifier is given.

virtual void Phx::RawInputEngine::Driver::buttonState ButtonIdentifier  button,
ButtonState  state
[pure virtual]
 

Sets the current button state for the given button.

Parameters:
button The button whose state should be set.
state The new state for the given button.
Exceptions:
PermissionException thrown if button is INVALID_BUTTON_IDENTIFIER;

virtual void Phx::RawInputEngine::Driver::listener Listener listener  )  [pure virtual]
 

Sets the listener to be notified by the input layer.

Parameters:
listener The listener to be notified.

const String& Phx::RawInputEngine::Driver::name void   )  const [inline]
 

Returns the name of this driver.

Returns:
The name of the driver, as passed to RawInputEngine::newDriver().


The documentation for this class was generated from the following file:
Generated on Wed Dec 21 22:05:38 2005 for Phoenix OSFS by  doxygen 1.4.2