Game Control Plus  1.2.2
 All Classes Namespaces Functions Variables Pages
net.java.games.input.Keyboard Class Reference
Inheritance diagram for net.java.games.input.Keyboard:

Public Member Functions

Type getType ()
 
final boolean isKeyDown (Component.Identifier.Key key_id)
 
- Public Member Functions inherited from net.java.games.input.AbstractController
final Controller[] getControllers ()
 
final Component[] getComponents ()
 
final Component getComponent (Component.Identifier id)
 
final Rumbler[] getRumblers ()
 
PortType getPortType ()
 
int getPortNumber ()
 
final String getName ()
 
String toString ()
 
final void setEventQueueSize (int size)
 
final EventQueue getEventQueue ()
 
synchronized boolean poll ()
 

Protected Member Functions

 Keyboard (String name, Component[] keys, Controller[] children, Rumbler[] rumblers)
 
- Protected Member Functions inherited from net.java.games.input.AbstractController
 AbstractController (String name, Component[] components, Controller[] children, Rumbler[] rumblers)
 
void setDeviceEventQueueSize (int size) throws IOException
 
abstract boolean getNextDeviceEvent (Event event) throws IOException
 
void pollDevice () throws IOException
 

Additional Inherited Members

- Static Package Attributes inherited from net.java.games.input.AbstractController
static final int EVENT_QUEUE_DEPTH = 32
 

Detailed Description

A Keyboard is a type of controller consisting of a single controller, they keypad, which contains several axes (the keys). By default, all keys are set to receive polling data.

Constructor & Destructor Documentation

net.java.games.input.Keyboard.Keyboard ( String  name,
Component[]  keys,
Controller[]  children,
Rumbler[]  rumblers 
)
protected

Protected constructor. Subclasses should initialize the array of axes to an array of keys.

Parameters
nameThe name of the keyboard

Member Function Documentation

Type net.java.games.input.Keyboard.getType ( )
virtual

Returns the type of the Controller.

Reimplemented from net.java.games.input.AbstractController.