|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.nrao.sss.model.project.scan.TippingPosition
public class TippingPosition
A position used by a TippingScan
.
Version Info:
$Revision: 1494 $ |
$Date: 2008-08-14 13:51:17 -0600 (Thu, 14 Aug 2008) $ |
$Author: dharland $ (last person to modify) |
Constructor Summary | |
---|---|
TippingPosition()
|
Method Summary | |
---|---|
TippingPosition |
clone()
Returns a position that is a copy of this one. |
int |
compareTo(TippingPosition other)
Compares this position with the other for order. |
boolean |
equals(Object o)
Returns true if o is equal to this position. |
ScanTimeType |
getDurationType()
Returns the type of duration used by this position. |
Angle |
getElevation()
Returns the elevation of this position. |
TimeDuration |
getTimeAtPosition()
Returns the amount of time that the containing scan should spend at this position. |
ScanTimeSpecification |
getTimeSpec()
A convenience method for fetching the time spent at this position. |
int |
hashCode()
Returns a hash code value for this position. |
void |
setDurationType(ScanTimeType newType)
Sets a new duration type for this position. |
void |
setElevation(Angle elevation)
Sets the elevation of this position. |
void |
setTimeAtPosition(TimeDuration duration)
Sets the amount of time that the containing scan should spend at this position. |
void |
setTimeSpec(ScanTimeSpecification newSpec)
A convenience method for setting the time spent at this position. |
String |
toString()
Returns a text representation of this tipping position. |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public TippingPosition()
Method Detail |
---|
public void setElevation(Angle elevation)
If offset
is null, it will be treated as
a non-null angle of zero degrees.
elevation
- the elevation of this position.public Angle getElevation()
The returned value is guaranteed to be non-null. It is also the elevation that is held internally by this position, so any changes made to the returned elevation will be reflected in this object.
public void setTimeAtPosition(TimeDuration duration)
If duration
is null, it will be treated as
a non-null duration of size zero.
duration
- the amount of time that should be spent at this position.public TimeDuration getTimeAtPosition()
The returned value is guaranteed to be non-null. It is also the duration that is held internally by this position, so any changes made to the returned duration will be reflected in this object.
public void setDurationType(ScanTimeType newType)
newType
- the new duration type for this position.
If this value is null, the default duration type of
ON_SOURCE_SIDEREAL will be used.
This value must have its isDuration() method
return true. If it does not, an
IllegalArgumentException is thrown.
IllegalArgumentException
- if newType
is not a duration type.public ScanTimeType getDurationType()
getTimeAtPosition()
.
The returned type will be non-null and its isDuration() method will always return true.
public void setTimeSpec(ScanTimeSpecification newSpec)
getTimeType()
and
getDuration()
methods
to set the time at position and duration type of this object.
newSpec
- the provider of the time at position and duration type values for
this position. A value of null will result in a
NullPointerException
.
IllegalArgumentException
- if the time type held by newSpec
is not a duration type.public ScanTimeSpecification getTimeSpec()
public String toString()
toString
in class Object
public int compareTo(TippingPosition other)
other
for order.
compareTo
in interface Comparable<TippingPosition>
public TippingPosition clone()
If anything goes wrong during the cloning procedure,
a RuntimeException
will be thrown.
clone
in class Object
public boolean equals(Object o)
o
is equal to this position.
equals
in class Object
public int hashCode()
hashCode
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |