sky.monome.event.button
Class ButtonEvent<B extends ButtonManager<B>>


java.lang.Object

  extended by java.util.EventObject

      extended by sky.monome.event.GenericEvent<B>

          extended by sky.monome.event.button.ButtonEvent<B>

Type Parameters:
B - Type of button manager that triggers button events.
All Implemented Interfaces:
java.io.Serializable

public class ButtonEvent<B extends ButtonManager<B>>
extends GenericEvent<B>

Button event's information object. Button events are triggered by ButtonManager objects.

Author:
PJ Skyman
See Also:
Serialized Form

Nested Class Summary
static class ButtonEvent.ButtonAction
          Button action.
 
Field Summary
protected  ButtonEvent.ButtonAction buttonAction
          Action associated with this button event.
 
Fields inherited from class sky.monome.event.GenericEvent
when
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
ButtonEvent(long when, B source, ButtonEvent.ButtonAction buttonAction)
          Constructs a button event with the specified time, source and button action.
 
Method Summary
 ButtonEvent.ButtonAction getButtonAction()
          Returns the action associated with this button event.
 
Methods inherited from class sky.monome.event.GenericEvent
getSource2, getWhen
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

buttonAction


protected final ButtonEvent.ButtonAction buttonAction
Action associated with this button event.

Constructor Detail

ButtonEvent


public ButtonEvent(long when,

                   B source,

                   ButtonEvent.ButtonAction buttonAction)
Constructs a button event with the specified time, source and button action.

Parameters:
when - Time of this event, in milliseconds since the time zero in the Unix world.
source - Source of this event. ButtonManager objects are sources for button events.
buttonAction - Action associated with this button event.
Method Detail

getButtonAction


public ButtonEvent.ButtonAction getButtonAction()
Returns the action associated with this button event.

Returns:
The action associated with this button event.