Record Class Whacknet.RobotTelemetry

java.lang.Object
java.lang.Record
frc.lib.lowlevel.Whacknet.RobotTelemetry
Enclosing class:
Whacknet

public static record Whacknet.RobotTelemetry(long timestampUs, Angle roll, Angle pitch, Angle yaw, AngularVelocity rollVel, AngularVelocity pitchVel, AngularVelocity yawVel) extends Record
A record representing the robot's telemetry data.
  • Constructor Details

    • RobotTelemetry

      public RobotTelemetry(long timestampUs, Angle roll, Angle pitch, Angle yaw, AngularVelocity rollVel, AngularVelocity pitchVel, AngularVelocity yawVel)
      Creates an instance of a RobotTelemetry record class.
      Parameters:
      timestampUs - the value for the timestampUs record component
      roll - the value for the roll record component
      pitch - the value for the pitch record component
      yaw - the value for the yaw record component
      rollVel - the value for the rollVel record component
      pitchVel - the value for the pitchVel record component
      yawVel - the value for the yawVel record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • timestampUs

      public long timestampUs()
      Returns the value of the timestampUs record component.
      Returns:
      the value of the timestampUs record component
    • roll

      public Angle roll()
      Returns the value of the roll record component.
      Returns:
      the value of the roll record component
    • pitch

      public Angle pitch()
      Returns the value of the pitch record component.
      Returns:
      the value of the pitch record component
    • yaw

      public Angle yaw()
      Returns the value of the yaw record component.
      Returns:
      the value of the yaw record component
    • rollVel

      public AngularVelocity rollVel()
      Returns the value of the rollVel record component.
      Returns:
      the value of the rollVel record component
    • pitchVel

      public AngularVelocity pitchVel()
      Returns the value of the pitchVel record component.
      Returns:
      the value of the pitchVel record component
    • yawVel

      public AngularVelocity yawVel()
      Returns the value of the yawVel record component.
      Returns:
      the value of the yawVel record component