public static final class MroObservation.Orbit extends java.lang.Object implements java.lang.Comparable<MroObservation.Orbit>
orbit pass
: 13071a, for example, is orbit
13071 on the ascending pass.
The orbit number is simply a positive integer count of the number of times MRO has orbited Mars since orbital insertion.
The pass indicates whether MRO is moving from the south pole north ("ascending") or from the north pole south ("descending"). An ascending pass is indicated with a lowercase a, and a descending pass with a lowercase d.
To instantiate an orbit object, use one of the valueOf static methods.
Modifier and Type | Method and Description |
---|---|
int |
compareTo(MroObservation.Orbit o)
Compares this orbit to another orbit.
|
boolean |
equals(java.lang.Object o)
Indicates whether some other object is "equal to" this one.
|
int |
getOrbitNumber()
Gets the orbit number.
|
MroObservation.OrbitPass |
getOrbitPass()
Gets the orbit pass
|
int |
hashCode()
Returns a hash code value for this orbit.
|
java.lang.String |
toString()
Gets a string representation of this orbit.
|
static MroObservation.Orbit |
valueOf(int orbitNumber,
MroObservation.OrbitPass orbitPass)
Creates a new, immutable orbit from a non-negative integer orbit number and
an orbit pass.
|
static MroObservation.Orbit |
valueOf(java.lang.String text)
Creates a new, immutable orbit from an element of text.
|
public int getOrbitNumber()
public MroObservation.OrbitPass getOrbitPass()
public java.lang.String toString()
toString
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
o
- the object to which this object is compared.public int compareTo(MroObservation.Orbit o)
orbit number
is less than the
other's. If the orbit numbers are the same, this orbit is less than the
other if its orbit pass
is MroObservation.OrbitPass.ASCENDING
and the other's is MroObservation.OrbitPass.DESCENDING
.compareTo
in interface java.lang.Comparable<MroObservation.Orbit>
o
- the orbit to be compared.public static MroObservation.Orbit valueOf(int orbitNumber, MroObservation.OrbitPass orbitPass)
orbitNumber
- the orbit number, which must be non-negative.orbitPass
- the orbit pass.java.lang.IllegalArgumentException
- if the orbit number is negative.public static MroObservation.Orbit valueOf(java.lang.String text)
text
- the orbit text to parse.java.lang.IllegalArgumentException
- if the text does not parse to a valid
orbit (a positive integer followed by an "a" or a "d").Copyright \ (C) Arizona Board of Regents on behalf of the \ Planetary Image Research Laboratory, Lunar and \ Planetary Laboratory at the University of Arizona