Package slash.navigation.common
Record Class ValueAndOrientation
java.lang.Object
java.lang.Record
slash.navigation.common.ValueAndOrientation
Value and
Orientation of GPS coordinates.- Author:
- Christian Pesch
-
Constructor Summary
ConstructorsConstructorDescriptionValueAndOrientation(double value, Orientation orientation) Creates an instance of aValueAndOrientationrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanIndicates whether some other object is "equal to" this one.inthashCode()Returns a hash code value for this object.Returns the value of theorientationrecord component.toString()Returns a string representation of this record class.doublevalue()Returns the value of thevaluerecord component.
-
Constructor Details
-
Method Details
-
equals
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 withObjects::equals(Object,Object); primitive components are compared with '=='. -
hashCode
public int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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. -
value
public double value()Returns the value of thevaluerecord component.- Returns:
- the value of the
valuerecord component
-
orientation
Returns the value of theorientationrecord component.- Returns:
- the value of the
orientationrecord component
-