JavaGenes, NASA Ames. Written largely by Al Globus

gov.nasa.javaGenes.EOSscheduling
Class Horizon

java.lang.Object
  extended bygov.nasa.javaGenes.EOSscheduling.TimeInterval
      extended bygov.nasa.javaGenes.EOSscheduling.Horizon
All Implemented Interfaces:
java.io.Serializable

public class Horizon
extends TimeInterval

default timestep is seconds

See Also:
Serialized Form

Field Summary
protected  int duration
           
protected  int end
           
protected  java.util.Date endDate
           
protected  long endJavaEpoch
           
static int NOT_SCHEDULED
           
protected  int start
           
protected  java.util.Date startDate
           
protected  long startJavaEpoch
           
 
Constructor Summary
protected Horizon()
           
  Horizon(java.lang.String startAsStkTimeString, java.lang.String endAsStkTimeString)
           
 
Method Summary
 Horizon copy()
           
static int defaultStart()
           
 int getDuration()
           
static int getDurationOf(java.lang.String startAsStkTimeString, java.lang.String endAsStkTimeString)
           
 int getEnd()
           
 int getIntegerTimeAt(java.util.Date date)
           
 int getStart()
           
 boolean includes(AccessWindow window)
           
 boolean includes(Horizon horizon)
           
 boolean isValid()
           
protected  void setDerivedValues()
           
static void setMillisecondsPerTimestep(int inMillisecondsPerTimestep)
          changes all time calculations.
 boolean theSame(Horizon other)
           
 
Methods inherited from class gov.nasa.javaGenes.EOSscheduling.TimeInterval
includes
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NOT_SCHEDULED

public static final int NOT_SCHEDULED
See Also:
Constant Field Values

startDate

protected java.util.Date startDate

endDate

protected java.util.Date endDate

startJavaEpoch

protected long startJavaEpoch

endJavaEpoch

protected long endJavaEpoch

start

protected int start

end

protected int end

duration

protected int duration
Constructor Detail

Horizon

protected Horizon()

Horizon

public Horizon(java.lang.String startAsStkTimeString,
               java.lang.String endAsStkTimeString)
Method Detail

setMillisecondsPerTimestep

public static void setMillisecondsPerTimestep(int inMillisecondsPerTimestep)
changes all time calculations. Only use before creating any Horizons.


defaultStart

public static int defaultStart()

getDurationOf

public static int getDurationOf(java.lang.String startAsStkTimeString,
                                java.lang.String endAsStkTimeString)
Returns:
in seconds by default, use setMillisecondsPerTimestep to change

theSame

public boolean theSame(Horizon other)

setDerivedValues

protected void setDerivedValues()

getIntegerTimeAt

public int getIntegerTimeAt(java.util.Date date)

includes

public boolean includes(AccessWindow window)

includes

public boolean includes(Horizon horizon)

getStart

public int getStart()
Specified by:
getStart in class TimeInterval

getEnd

public int getEnd()
Specified by:
getEnd in class TimeInterval

getDuration

public int getDuration()
Overrides:
getDuration in class TimeInterval

isValid

public boolean isValid()

copy

public Horizon copy()

JavaGenes, NASA Ames. Written largely by Al Globus