Class WsJSJoystickInputConfig

  • All Implemented Interfaces:
    InputConfig

    public class WsJSJoystickInputConfig
    extends java.lang.Object
    implements InputConfig
    Contains configurations for joystick axis.
    • Constructor Summary

      Constructors 
      Constructor Description
      WsJSJoystickInputConfig​(int p_port, int p_axis)
      Construct the joystick axis config
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int getAxis()
      Returns the joystick axis index.
      int getPort()
      Returns the controller port number from the driver station.
      java.lang.String toString()
      Builds a JSON String describing the joystick axis config.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • WsJSJoystickInputConfig

        public WsJSJoystickInputConfig​(int p_port,
                                       int p_axis)
        Construct the joystick axis config
        Parameters:
        p_port - Driver station controller port number.
        p_axis - Joystick axis index.
    • Method Detail

      • getPort

        public int getPort()
        Returns the controller port number from the driver station.
        Returns:
        The controller port number.
      • getAxis

        public int getAxis()
        Returns the joystick axis index.
        Returns:
        The joystick axis index.
      • toString

        public java.lang.String toString()
        Builds a JSON String describing the joystick axis config.
        Overrides:
        toString in class java.lang.Object
        Returns:
        Port number and axis number.