Class ScheduleSearchEntry
java.lang.Object
org.deltava.beans.DatabaseBean
org.deltava.beans.Flight
org.deltava.beans.schedule.ScheduleEntry
org.deltava.beans.schedule.ScheduleSearchEntry
- All Implemented Interfaces:
Serializable, Comparable<Object>, FlightNumber, IDBean, FlightTimes, RoutePair, ViewEntry, Cacheable
A class to store Schedule Entry information with Dispatch route counts.
- Since:
- 2.3
- Version:
- 10.1
- Author:
- Luke
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface RoutePair
RoutePair.RoutePairImplModifier and TypeInterfaceDescriptionstatic classHelper class when all you need is a naked RoutePair. -
Field Summary
Fields inherited from class ScheduleEntry
_arrivalPlusDays, EQ_VARIESModifier and TypeFieldDescriptionprotected intAdjusts the arrival date/time forward by a certain number of days.static final StringVariable equipment code. -
Constructor Summary
ConstructorsConstructorDescriptionScheduleSearchEntry(Airline a, int number, int leg) Creates a new Schedule Entry object with a given flight. -
Method Summary
Modifier and TypeMethodDescriptionintReturns the number of ACARS dispatch routes available between these airports.intReturns the number of times the route has been flown.Returns the last date the route was flown on.Returns the row CSS class name if displayed in a view table.voidsetDispatchRoutes(int routes) Updates the number of ACARS dispatch routes available between these airports.voidsetFlightCount(int cnt) Updates the number of times the route has been flown.voidUpdates the last date the route was flown on.Methods inherited from class ScheduleEntry
adjustForDST, getAcademy, getArrivalPlusDays, getCodeShare, getDuration, getHasDSTAdjustment, getHistoric, getID, getLength, getRemarks, getSource, getTimeA, getTimeD, hashCode, isVariable, setAcademy, setCodeShare, setHistoric, setID, setLength, setRemarks, setSource, setTimeA, setTimeD, toStringModifier and TypeMethodDescriptionbooleanAdjusts the arrival time if the DST offsets for either Airport have changed from the effective date of this schedule etnry.booleanReturns if this flight is part of the Flight Academy.intReturns the number of days forward to adjust the arrival time.If a codeshare, the flight code of the operator's flight.final DurationA method to return the exact length of the flight.booleanReturns whether the arrival time has been adjusted for DST changes between the effective date of this Schedule Entry and the current date.booleanReturns the "historic flight" flag value for this flight.final intgetID()Returns the database ID of the schedule entry.final intReturns the length of the flight, in hours multiplied by 10.Returns any operator notes for this flight.Returns the original source of this Schedule Entry.getTimeA()Returns the arrival time of the flight, with full timezone information.getTimeD()Returns the departure time of the flight, with full timezone information.inthashCode()static booleanisVariable(Flight f) Helper method to determine if flight is using a variable equipment type.voidsetAcademy(boolean academy) Updates this Schedule entry's "Flight Academy flight" flag.voidsetCodeShare(String flightCode) If this is a codeshare flight, the flight code of the operator's flight.voidsetHistoric(boolean historic) Updates this Schedule entry's "historic flight" flag.final voidsetID(int id) Sets the database ID of this schedule entry.voidsetLength(int len) Sets the length of a flight leg.voidsetRemarks(String remarks) Updates any notes (usually about codehsare operator) for this flight.voidsetSource(ScheduleSource src) Updates the source of this entry.voidSets the arrival time for this flight.voidSets the departure time for this flight.toString()Methods inherited from class Flight
compareTo, equals, getAirline, getAirportA, getAirportD, getCallsign, getDistance, getEquipmentType, getFlightCode, getFlightNumber, getLeg, getLegCode, getShortCode, setAirline, setAirportA, setAirportD, setEquipmentType, setFlightNumber, setLegModifier and TypeMethodDescriptionintbooleanReturns the Airline.Returns the arrival Airport.Returns the departure Airport.Returns the flight code as a callsign, using the Airline ICAO code.intReturns the distance between the Airports.Returns the Equipment type for this flightReturns a text representation of the Flight in the format "CODE### Leg #".intReturns the Flight Number.intgetLeg()Returns the Flight Leg.Returns an abbreviated version of the Flight code with a dash instead of text.Returns the Flight code without the leg.voidSet the Airline for this flight.voidSets the Arrival Airport object for this flight.voidSets the Departure Airport object for this flight.voidsetEquipmentType(String eqType) Sets the equipment type for this flight.voidsetFlightNumber(int fNumber) Set the Flight Number for this flightvoidsetLeg(int leg) Sets the Flight leg for this flightMethods inherited from class DatabaseBean
cacheKey, getHexID, validateID, validateIDModifier and TypeMethodDescriptioncacheKey()Returns the cache key for this object.getHexID()Returns the hexadecimal database ID of this object.static voidvalidateID(int oldID, int newID) Validates a database ID.static voidvalidateID(int oldID, int newID, boolean allowZero) Validates a database ID.Methods inherited from interface FlightTimes
hasFlightTimesModifier and TypeMethodDescriptiondefault booleanReturns if both the departure and arrrival date/times have been populated.Methods inherited from interface RoutePair
createKey, getAirports, getFlightType, includes, isPopulated, matches, midPointModifier and TypeMethodDescriptiondefault StringReturns a key that describes the route pair.Returns the airports in this Route Pair.default FlightTypeReturns the flight type for customs/gate purposes.default booleanReturns whether this RoutePair includes a particular IATA or ICAO code.default booleanReturns whether both airports are populated.default booleanReturns whether this RoutePair matches a particular Route Pair.default GeoLocationmidPoint()Returns the midpoint between the two Airports on a Great Circle route.
-
Constructor Details
-
ScheduleSearchEntry
Creates a new Schedule Entry object with a given flight.- Parameters:
a- the Airlinenumber- the Flight Numberleg- the Leg Number- Throws:
NullPointerException- if the Airline Code is nullIllegalArgumentException- if the Flight Report is zero or negativeIllegalArgumentException- if the Leg is less than 1 or greater than 5- See Also:
-
-
Method Details
-
getDispatchRoutes
public int getDispatchRoutes()Returns the number of ACARS dispatch routes available between these airports.- Returns:
- the number of routes
-
getFlightCount
public int getFlightCount()Returns the number of times the route has been flown.- Returns:
- the number of flights
-
getLastFlownOn
Returns the last date the route was flown on.- Returns:
- the date/time of the last flight
-
setDispatchRoutes
public void setDispatchRoutes(int routes) Updates the number of ACARS dispatch routes available between these airports.- Parameters:
routes- the number of routes
-
setFlightCount
public void setFlightCount(int cnt) Updates the number of times the route has been flown.- Parameters:
cnt- the number of flights
-
setLastFlownOn
Updates the last date the route was flown on.- Parameters:
dt- the date/time of the last flight
-
getRowClassName
Returns the row CSS class name if displayed in a view table.- Specified by:
getRowClassNamein interfaceViewEntry- Overrides:
getRowClassNamein classScheduleEntry- Returns:
- the CSS class name
-