Class DraftFlightReport
java.lang.Object
org.deltava.beans.DatabaseBean
org.deltava.beans.Flight
org.deltava.beans.flight.FlightReport
org.deltava.beans.flight.DraftFlightReport
- All Implemented Interfaces:
Serializable
,Comparable<Object>
,AuthoredBean
,CalendarEntry
,FlightData
,FlightNumber
,IDBean
,FlightTimes
,RoutePair
,ViewEntry
,Cacheable
A class to store draft Flight Report data, with scheduled departure/arrival times.
- Since:
- 2.8
- Version:
- 11.5
- Author:
- Luke
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.deltava.beans.schedule.RoutePair
RoutePair.RoutePairImpl
-
Field Summary
Fields inherited from class org.deltava.beans.flight.FlightReport
ATTR_ACADEMY, ATTR_ACARS, ATTR_AIRSPACEWARN, ATTR_CHARTER, ATTR_CHECKRIDE, ATTR_DISPATCH, ATTR_DIVERT, ATTR_ETOPSWARN, ATTR_FDR_MASK, ATTR_FPI, ATTR_HISTORIC, ATTR_IVAO, ATTR_NOTRATED, ATTR_ONLINE_MASK, ATTR_PEDGE, ATTR_POSCON, ATTR_RANGEWARN, ATTR_REFUELWARN, ATTR_ROUTEWARN, ATTR_RWYSFCWARN, ATTR_RWYWARN, ATTR_SIMBRIEF, ATTR_SIMFDR, ATTR_TIMEWARN, ATTR_VATSIM, ATTR_WARN_MASK, ATTR_WEIGHTWARN, ATTR_XACARS, MIN_ACARS_CLIENT
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new Flight Report object with a given Flight.DraftFlightReport
(Airline a, int flightNumber, int leg) Creates a new Flight Report object with a given flight. -
Method Summary
Modifier and TypeMethodDescriptionReturns the planned altitude.Returns default comments with departure and arrival times.A method to return the exact length of the flight.getGateA()
Returns the arrival Gate name.getGateD()
Returns the departure Gate name.getTimeA()
Returns the scheduled arrival time in local time.getTimeD()
Returns the scheduled departure time in local time.boolean
hasGates()
Returns whether the flight has departure and arrival gates assigned.void
setAltitude
(String alt) Updates the planned altitude.void
Updates the arrival Gate name.void
Updates the departure Gate name.void
Updates the scheduled arrival time in local time.void
Updates the scheduled departure time in local time.Methods inherited from class org.deltava.beans.flight.FlightReport
addStatusUpdate, addStatusUpdate, compareTo, getAttributes, getAuthorID, getCaptEQType, getComments, getDatabaseID, getDate, getDisposedOn, getFDR, getLength, getLoadFactor, getNetwork, getPassengers, getRank, getRemarks, getRoute, getRowClassName, getSimulator, getStatus, getStatusUpdates, getSubmittedOn, hasAttribute, hasDatabaseID, setAttribute, setAttributes, setAuthorID, setCaptEQType, setCaptEQType, setComments, setDatabaseID, setDate, setDisposedOn, setID, setLeg, setLength, setLoadFactor, setNetwork, setPassengers, setRank, setRemarks, setRoute, setSimulator, setStatus, setSubmittedOn
Methods inherited from class org.deltava.beans.Flight
equals, getAirline, getAirportA, getAirportD, getCallsign, getDistance, getEquipmentType, getFlightCode, getFlightNumber, getLeg, getLegCode, getShortCode, hashCode, setAirline, setAirportA, setAirportD, setEquipmentType, setFlightNumber, toString
Methods inherited from class org.deltava.beans.DatabaseBean
cacheKey, getHexID, getID, validateID, validateID
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.deltava.beans.flight.FlightData
getEquipmentType
Methods inherited from interface org.deltava.beans.FlightNumber
getAirline, getFlightNumber, getLeg
Methods inherited from interface org.deltava.beans.schedule.FlightTimes
hasFlightTimes
Methods inherited from interface org.deltava.beans.schedule.RoutePair
createKey, getAirportA, getAirportD, getAirports, getDistance, getFlightType, includes, isPopulated, matches
-
Constructor Details
-
DraftFlightReport
Creates a new Flight Report object with a given Flight.- Parameters:
f
- the Flight bean
-
DraftFlightReport
Creates a new Flight Report object with a given flight.- Parameters:
a
- the AirlineflightNumber
- 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
-
-
Method Details
-
getTimeD
Returns the scheduled departure time in local time. The date portion should be ignored.- Specified by:
getTimeD
in interfaceFlightTimes
- Returns:
- the departure date/time
- See Also:
-
getTimeA
Returns the scheduled arrival time in local time. The date portion should be ignored.- Specified by:
getTimeA
in interfaceFlightTimes
- Returns:
- the arrival date/time
- See Also:
-
getAltitude
-
getGateD
-
getGateA
-
hasGates
public boolean hasGates()Returns whether the flight has departure and arrival gates assigned.- Returns:
- TRUE if departure and arrival gates are assigned, otherwise FALSE
-
setTimeD
Updates the scheduled departure time in local time. The date portion should be ignored.- Parameters:
dt
- the departure date/time
-
setTimeA
Updates the scheduled arrival time in local time. The date portion should be ignored.- Parameters:
dt
- the arrival date/time
-
setGateD
Updates the departure Gate name.- Parameters:
name
- the Gate name or null if not defined
-
setGateA
Updates the arrival Gate name.- Parameters:
name
- the Gate name or null if not defined
-
setAltitude
-
getDraftComments
Returns default comments with departure and arrival times.- Returns:
- the comments
-
getDuration
Description copied from class:Flight
A method to return the exact length of the flight.- Overrides:
getDuration
in classFlightReport
- Returns:
- a Duration
-