Microsoft.Xna.Framework.Input
Class GamePadButtons

java.lang.Object
  extended by System.ValueType
      extended by Microsoft.Xna.Framework.Input.GamePadButtons

public final class GamePadButtons
extends ValueType

Identifies whether the buttons on an Xbox 360 Controller are pressed or released.

Author:
Halofreak1990

Field Summary
 ButtonState A
          Identifies whether the A button on the Xbox 360 Controller is pressed.
 ButtonState B
          Identifies whether the B button on the Xbox 360 Controller is pressed.
 ButtonState Back
          Identifies whether the BACK button on the Xbox 360 Controller is pressed.
 ButtonState LeftShoulder
          Identifies whether the left shoulder (bumper) button on the Xbox 360 Controller is pressed.
 ButtonState LeftStick
          Identifies whether the left stick button on the Xbox 360 Controller is pressed (the stick is "clicked" in).
 ButtonState RightShoulder
          Identifies whether the right shoulder (bumper) button on the Xbox 360 Controller is pressed.
 ButtonState RightStick
          Identifies whether the right stick button on the Xbox 360 Controller is pressed (the stick is "clicked" in).
 ButtonState Start
          Identifies whether the START button on the Xbox 360 Controller is pressed.
 ButtonState X
          Identifies whether the X button on the Xbox 360 Controller is pressed.
 ButtonState Y
          Identifies whether the Y button on the Xbox 360 Controller is pressed.
 
Constructor Summary
GamePadButtons(java.util.EnumSet<Buttons> buttons)
          Initializes a new instance of the GamePadButtons class, setting the specified buttons to pressed.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Returns a value that indicates whether the current instance is equal to a specified object.
 int hashCode()
          Gets the hash code for this instance.
 java.lang.String toString()
          Retrieves a string representation of this object.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

A

public final ButtonState A
Identifies whether the A button on the Xbox 360 Controller is pressed.


B

public final ButtonState B
Identifies whether the B button on the Xbox 360 Controller is pressed.


X

public final ButtonState X
Identifies whether the X button on the Xbox 360 Controller is pressed.


Y

public final ButtonState Y
Identifies whether the Y button on the Xbox 360 Controller is pressed.


LeftStick

public final ButtonState LeftStick
Identifies whether the left stick button on the Xbox 360 Controller is pressed (the stick is "clicked" in).


RightStick

public final ButtonState RightStick
Identifies whether the right stick button on the Xbox 360 Controller is pressed (the stick is "clicked" in).


LeftShoulder

public final ButtonState LeftShoulder
Identifies whether the left shoulder (bumper) button on the Xbox 360 Controller is pressed.


RightShoulder

public final ButtonState RightShoulder
Identifies whether the right shoulder (bumper) button on the Xbox 360 Controller is pressed.


Back

public final ButtonState Back
Identifies whether the BACK button on the Xbox 360 Controller is pressed.


Start

public final ButtonState Start
Identifies whether the START button on the Xbox 360 Controller is pressed.

Constructor Detail

GamePadButtons

public GamePadButtons(java.util.EnumSet<Buttons> buttons)
Initializes a new instance of the GamePadButtons class, setting the specified buttons to pressed.

Parameters:
buttons - Buttons to initialize as pressed. Specify a single button, or combine multiple buttons using an EnumSet.
Method Detail

equals

public boolean equals(java.lang.Object obj)
Returns a value that indicates whether the current instance is equal to a specified object.

Overrides:
equals in class java.lang.Object
Parameters:
obj - Object with which to make the comparison.
Returns:
true if the current instance is equal to the specified object; false otherwise.

hashCode

public int hashCode()
Gets the hash code for this instance. #return Hash code for this object.

Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Retrieves a string representation of this object.

Overrides:
toString in class java.lang.Object
Returns:
String representation of this object.