Class RawScheduleEntry

All Implemented Interfaces:
Serializable, Comparable<Object>, FlightNumber, IDBean, FlightTimes, RoutePair, ViewEntry, Cacheable

public class RawScheduleEntry extends ScheduleEntry
A Schedule Entry with code share and day of week data.
Since:
8.0
Version:
11.2
Author:
Luke
See Also:
  • Constructor Details

    • RawScheduleEntry

      public RawScheduleEntry(Airline a, int fNumber, int leg)
      Creates the bean.
      Parameters:
      a - the Airline
      fNumber - the flight number
      leg - the leg number
    • RawScheduleEntry

      public RawScheduleEntry(Flight f)
      Creates the bean from an existing Flight.
      Parameters:
      f - the Flight
  • Method Details

    • getDays

      public Collection<DayOfWeek> getDays()
      Returns the day of the week this flight is operated on.
      Returns:
      a DayOfWeek enum
    • getDayCodes

      public String getDayCodes()
      Returns the day codes of the days of the week the flight is operated on.
      Returns:
      a set of day codes (1234567)
    • getDayMap

      public int getDayMap()
      Returns a bitmap of the days operated.
      Returns:
      a bitmap of ordinal values
    • getLineNumber

      public int getLineNumber()
      Returns the line number of this entry in the original source.
      Returns:
      the line number
    • getStartDate

      public LocalDate getStartDate()
      Returns the start of the operating range.
      Returns:
      the range start date
    • getEndDate

      public LocalDate getEndDate()
      Returns the end of the operating range.
      Returns:
      the range end date
    • getForceInclude

      public boolean getForceInclude()
      Returns whether this entry is always included.
      Returns:
      TRUE if always included, otherwise FALSE
    • getUpdated

      public boolean getUpdated()
      Returns whether this entry has been manually updated since import.
      Returns:
      TRUE if manually updated, otherwise FALSE
    • getHistoric

      public boolean getHistoric()
      Description copied from class: ScheduleEntry
      Returns the "historic flight" flag value for this flight.
      Overrides:
      getHistoric in class ScheduleEntry
      Returns:
      TRUE if this is a historic flight, FALSE otherwise
      See Also:
    • operatesOn

      public boolean operatesOn(LocalDate ld)
      Returns if a flight is operated on a particular date.
      Parameters:
      ld - the operating date
      Returns:
      TRUE if the flight is operated on this date, otherwise FALSE
    • addDayOfWeek

      public void addDayOfWeek(DayOfWeek d)
      Adds a day of the week that this flight is operated on.
      Parameters:
      d - a DayOfWeek
    • setDayMap

      public void setDayMap(int bitmap)
      Sets the day of the week that this flight is operated on.
      Parameters:
      bitmap - a DayOfWeek bitmap
    • setStartDate

      public void setStartDate(LocalDate d)
      Updates the start of the operating range.
      Parameters:
      d - the range start date
    • setEndDate

      public void setEndDate(LocalDate d)
      Updates the end of the operating range.
      Parameters:
      d - the range end date
    • setLineNumber

      public void setLineNumber(int ln)
      Updates the source file line number for this entry.
      Parameters:
      ln - the line number
    • setForceInclude

      public void setForceInclude(boolean doForce)
      Updates whether this entry should always be included in a schedule filter, even if the route is already imported.
      Parameters:
      doForce - TRUE if always loaded, otherwsie FALSE
    • setUpdated

      public void setUpdated(boolean isUpdated)
      Updates whether this entry has been manually updated.
      Parameters:
      isUpdated - TRUE if manually updated, otherwise FALSE
    • setArrivalPlusDays

      public void setArrivalPlusDays(int days)
      Updates the number of days forward to adjust the arrival date.
      Parameters:
      days - the number of days
    • toToday

      public ScheduleEntry toToday(LocalDate dt)
      Converts a RawScheduleEntry to a ScheduleEntry for the current date.
      Parameters:
      dt - today as a LocalDate
      Returns:
      a SceduleEntry, or null if the flight does not operate