com.dlsc.flexgantt.model.calendar
Class AbstractCalendarEntry

java.lang.Object
  extended by com.dlsc.flexgantt.model.calendar.AbstractCalendarEntry
All Implemented Interfaces:
ICalendarEntry, java.lang.Comparable<AbstractCalendarEntry>
Direct Known Subclasses:
HolidayCalendarEntry, WeekendCalendarEntry

public abstract class AbstractCalendarEntry
extends java.lang.Object
implements ICalendarEntry, java.lang.Comparable<AbstractCalendarEntry>

An abstract implementation of the ICalendarEntry interface.

Since:
1.0
Author:
Dirk Lemmermann

Constructor Summary
AbstractCalendarEntry()
          Constructs a new calendar entry with an undefined time span.
AbstractCalendarEntry(ITimeSpan span)
          Constructs a new calendar entry.
 
Method Summary
 int compareTo(AbstractCalendarEntry entry)
           
 ITimeSpan getTimeSpan()
          Returns the time span of the calendar entry.
 void setTimeSpan(ITimeSpan span)
          Specifies a new time span for the calendar entry.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractCalendarEntry

public AbstractCalendarEntry(ITimeSpan span)
Constructs a new calendar entry.

Parameters:
span - the calendar entry's time span allocation.
Since:
1.0

AbstractCalendarEntry

public AbstractCalendarEntry()
Constructs a new calendar entry with an undefined time span.

Since:
1.0
See Also:
TimeSpan.UNDEFINED
Method Detail

setTimeSpan

public void setTimeSpan(ITimeSpan span)
Specifies a new time span for the calendar entry.

Parameters:
span - the calendar entry's new time span
Since:
1.0

getTimeSpan

public ITimeSpan getTimeSpan()
Description copied from interface: ICalendarEntry
Returns the time span of the calendar entry.

Specified by:
getTimeSpan in interface ICalendarEntry
Returns:
the calendar entry's time span

compareTo

public int compareTo(AbstractCalendarEntry entry)
Specified by:
compareTo in interface java.lang.Comparable<AbstractCalendarEntry>