|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.nrao.sss.model.proposal.Session
public class Session
Placeholder for time when we integrate proposal work. A proposed observation session.
A session consists of one or more session pairs
, each
of which brings together a source and a resource. A session is a close
cousin of a scheduling block, which is used
during the observation preparation and scheduling phases.
CVS Info:
$Revision: 1709 $ |
$Date: 2008-11-14 11:22:37 -0700 (Fri, 14 Nov 2008) $ |
$Author: dharland $ |
Field Summary |
---|
Fields inherited from interface edu.nrao.sss.util.Identifiable |
---|
UNIDENTIFIED |
Constructor Summary | |
---|---|
Session()
Creates a new instance. |
Method Summary | |
---|---|
void |
addSessionPair(SessionPair newPair)
Add a new session pair to this session. |
String |
getComments()
Returns the proposer's comments for this observation session. |
Long |
getId()
|
String |
getMaximumLst()
Returns the latest local sidereal time for this observation session. |
double |
getMinimumElevation()
Returns the minimum acceptable elevation (of which source?) for this session. |
String |
getMinimumLst()
Returns the earliest local sidereal time for this observation session. |
String |
getName()
Returns the name of this session. |
int |
getRepeatCount()
Returns the number of times to repeat this session. |
String |
getSchedulingConstraint()
Returns the scheduling constraints for this session. |
TimeDuration |
getSeparation()
Returns the separation in time between successive repeats of this session. |
Set<SessionPair> |
getSessionPairs()
Returns this session's set of session pairs. |
TimeDuration |
getSessionTime()
Returns the amount of time needed for one execution of this session. |
TimeDuration |
getTotalTime()
Returns the total time needed for this session after accounting for the desired number of executions. |
void |
removeSessionPair(SessionPair oldPair)
Removes the given session pair from this session. |
void |
reset()
Resets this session to its initial state. |
void |
setComments(String comments)
Sets the proposer's comments for this observation session. |
void |
setMaximumLst(String lstMax)
Sets the latest local sidereal time for this observation session. |
void |
setMinimumElevation(double degrees)
Sets the minimum acceptable elevation (of which source?) for this session. |
void |
setMinimumLst(String lstMin)
Sets the earliest local sidereal time for this observation session. |
void |
setName(String newName)
Sets the name of this session to newName . |
void |
setRepeatCount(int repeats)
Sets the number of times to repeat this session. |
void |
setSchedulingConstraint(String constraint)
Sets the scheduling constraints specified by a proposal's author for this session. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Session()
Method Detail |
---|
public void reset()
public Long getId()
getId
in interface Identifiable
public void setName(String newName)
newName
.
If newName
is null or the empty string
(""), the request to change the name will be
denied and the current name will remain in place.
newName
- the name of this session.public String getName()
public void addSessionPair(SessionPair newPair)
newPair
- the new session pair to be added to this session. If
newPair
is null this method does nothing.public void removeSessionPair(SessionPair oldPair)
oldPair
- the session pair to be removed from this session.public Set<SessionPair> getSessionPairs()
Note that this session's actual collection of pairs is returned, not a clone thereof. This means that any changes a client makes to the collection will be reflected in this session.
This method is guaranteed to return a non-null value, though the set it returns may be empty.
public void setMinimumLst(String lstMin)
The general form of the string is hh:mm:ss.sss. Leading zeroes are not required, though all three parts (hours, minutes, seconds) are required. Fractional seconds are not required. Examples of valid text strings:
Valid ranges for each part:
If the parameter string is not well formed, or if the values are not in
the ranges given above, an IllegalArgumentException
is thrown.
See the note in getMinimumLst()
about the relationship between
the minimum and maximum LST values.
lstMin
- the earliest local sidereal time for this observation
session.
IllegalArgumentException
- if lstMin
does not follow the
conventions set forth in the method comments.public String getMinimumLst()
Note that, using a 24-hour clock that resets to zero at LST midnight, the "minimum" might be a greater number than the maximum. In this situation, it will be understood that the interval crosses midnight and into the next day.
public void setMaximumLst(String lstMax)
See setMinimumLst(String)
for information about the form of
the parameter string. See also the note in getMinimumLst()
about the relationship between the minimum and maximum LST values.
lstMax
- the latest local sidereal time for this observation
session.
IllegalArgumentException
- if lstMax
does not follow the
conventions set forth in the method comments of
setLstMinimum
.public String getMaximumLst()
getMinimumLst()
.
public void setMinimumElevation(double degrees)
degrees
- the minimum acceptable elevation, measured in degrees above
the horizon. This value must be between 0.0 and 90.0,
inclusive.
IllegalArgumentException
- if degrees
is not within the range
stated above.public double getMinimumElevation()
public void setSchedulingConstraint(String constraint)
constraint
- the scheduling constraints for this session.public String getSchedulingConstraint()
public void setRepeatCount(int repeats)
repeats
- the number of times to repeat this session.
If repeats
is less than zero, it will be treated
as zero.public int getRepeatCount()
public TimeDuration getSeparation()
public TimeDuration getSessionTime()
public TimeDuration getTotalTime()
public void setComments(String comments)
comments
- the proposer's comments for this observation session.
If comments
is null, it will be treated
as the empty string.public String getComments()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |