jsky.timeline
Interface TimeLineModel

All Known Implementing Classes:
DefaultTimeLineModel

public interface TimeLineModel

The model for a time line.

This code was developed by NASA, Goddard Space Flight Center, Code 588 for the Scientist's Expert Assistant (SEA) project.

Version:
05/19/99
Author:
M. Fishman

Field Summary
static java.lang.String ALL_NODES_REMOVED
           
static java.lang.String NODE_ADDED
           
static java.lang.String NODE_REMOVED
           
 
Method Summary
 void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
          add a property change listener to the time line.
 void addTimeLineNode(TimeLineNodeModel node)
          add a time line node to the time line without checking its legality
 boolean contains(TimeLineNodeModel model)
          returns whether or not the model contains the specified node
 java.util.Date getDateForTime(Time time)
          takes a time and converts it into a date where the new date is equal to the start date + the time
 Time getEndTime()
          get the ending value of the timeline
 int getIntervalCount()
          get the number of intervals in the time line
 java.util.Date getStartDate()
          get the start date
 Time getStartTime()
          get the starting value in the timeline
 Time getTimeForDate(java.util.Date date)
          takes a date and convert it to a time where the new time is equal to the date - start date
 java.util.Iterator getTimeLineNodesIterator()
          get an iterator for the time line nodes
 void removeAllTimeLineNodes()
          remove all time line nodes from time line
 void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
          remove a property change listener from the time line
 void removeTimeLineNode(TimeLineNodeModel node)
          remove a time line node from the time line
 void setStartDate(java.util.Date date)
          set the date from which the timeline should start Note: if the date is not null then all time values are considered offsets from it
 

Field Detail

NODE_ADDED

static final java.lang.String NODE_ADDED
See Also:
Constant Field Values

NODE_REMOVED

static final java.lang.String NODE_REMOVED
See Also:
Constant Field Values

ALL_NODES_REMOVED

static final java.lang.String ALL_NODES_REMOVED
See Also:
Constant Field Values
Method Detail

addTimeLineNode

void addTimeLineNode(TimeLineNodeModel node)
add a time line node to the time line without checking its legality


removeTimeLineNode

void removeTimeLineNode(TimeLineNodeModel node)
remove a time line node from the time line


removeAllTimeLineNodes

void removeAllTimeLineNodes()
remove all time line nodes from time line


getIntervalCount

int getIntervalCount()
get the number of intervals in the time line


getTimeLineNodesIterator

java.util.Iterator getTimeLineNodesIterator()
get an iterator for the time line nodes


addPropertyChangeListener

void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
add a property change listener to the time line.


removePropertyChangeListener

void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
remove a property change listener from the time line


getDateForTime

java.util.Date getDateForTime(Time time)
takes a time and converts it into a date where the new date is equal to the start date + the time


getTimeForDate

Time getTimeForDate(java.util.Date date)
takes a date and convert it to a time where the new time is equal to the date - start date


setStartDate

void setStartDate(java.util.Date date)
set the date from which the timeline should start Note: if the date is not null then all time values are considered offsets from it


getStartDate

java.util.Date getStartDate()
get the start date


getStartTime

Time getStartTime()
get the starting value in the timeline


getEndTime

Time getEndTime()
get the ending value of the timeline


contains

boolean contains(TimeLineNodeModel model)
returns whether or not the model contains the specified node