Class GetNavRoute
java.lang.Object
org.deltava.dao.DAO
org.deltava.dao.GetNavData
org.deltava.dao.GetNavAirway
org.deltava.dao.GetOceanicRoute
org.deltava.dao.GetNavRoute
A Data Access Object to load routes.
- Since:
- 2.6
- Version:
- 12.1
- Author:
- Luke
-
Field Summary
Fields inherited from class GetNavAirway
_aCacheModifier and TypeFieldDescriptionprotected static final Cache<CacheableList<Airway>> Airway cache.Fields inherited from class DAO
_queryMax, _queryStart, _queryTimeout, WGS84_SRIDModifier and TypeFieldDescriptionprotected intThe maximum number of rows to return.protected intThe row number at which to start returning results.protected intThe query timeout, in seconds.protected static final intThe SRID used for geolocation queries. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetRouteWaypoints(String route, GeoLocation start) Returns all waypoints for a route, expanding Airways but NOT SID/STARs.populate(FlightRoute rt) Populates a flight route with waypoint beans.voidSets the effective date when looking up Oceanic Tracks.Methods inherited from class GetOceanicRoute
get, getOceanic, getOceanicTrackDates, getOceanicTracks, loadConcordeNATsModifier and TypeMethodDescriptionget(OceanicTrackInfo.Type routeType, Instant vd) Returns a specific Oceanic Route.Returns a list of oceanic routes.getOceanicTrackDates(OceanicTrackInfo.Type routeType) Returns the dates for which oceanic track waypoints are available.getOceanicTracks(OceanicTrackInfo.Type routeType, Instant dt) Returns all of the oceanic route waypoints for a particular date.Returns Concorde-specific North Atlantic Tracks.Methods inherited from class GetNavAirway
getAirways, getAll, getBestRoute, getBestRoute, getRoute, getRoute, getRoute, getRouteNames, getRoutes, getSIDRunwaysModifier and TypeMethodDescriptiongetAirways(String name) Loads a Airway definitions from the database.getAll()Returns all SIDs/STARs in the database.getBestRoute(ICAOAirport a, TerminalRoute.Type t, String name, String wp, String rwy) Returns the most likely Terminal Route used based on the Airport, Name, last waypoint and runway.getBestRoute(ICAOAirport a, TerminalRoute.Type t, String name, String wp, Runway rwy) Returns the most likely Terminal Route used based on the Airport, Name, last waypoint and runway.Loads a SID/STAR from the navigation database.getRoute(ICAOAirport a, TerminalRoute.Type t, String name) Retrieves a specifc SID/STAR.getRoute(ICAOAirport a, TerminalRoute.Type t, String name, boolean ignoreVersion) Retrieves a specifc SID/STAR.Returns all SIDs/STARs in the database.Loads all SIDs/STARs for a particular Airport.Returns the available SID runways for a particular Airport.Methods inherited from class GetNavData
get, getAirport, getAll, getBearingRange, getBestRunway, getByID, getIntersections, getObjects, getRunway, getRunways, getRunways, getRunwaysModifier and TypeMethodDescriptionReturns a Navigation object.getAirport(String code) Returns an Airport location from the database.Returns all navaids of a particular type in the database.getBearingRange(String code) Retrieves "special" navaids such as CODE[bearing][distance].getBestRunway(ICAOAirport a, Simulator sim, GeoLocation loc, int hdg) Returns the likeliest runway for a takeoff or landing.getByID(Collection<String> ids) Returns a group of Navigation objects.getIntersections(GeoLocation loc, int distance) Returns all Intersections within a set number of miles from a point.getObjects(GeoLocation loc, int distance) Returns all Navigation objects (except Intersections/Runways/Gates) within a set number of miles from a point.getRunway(ICAOAirport a, String rwyCode, Simulator sim) Returns information about a particular airport Runway.Returns all Runways in the database.Returns information about all airport Runways in all Simulators.getRunways(ICAOAirport a, Simulator sim) Returns all Runways for a particular Airport.Methods inherited from class DAO
commitTransaction, createTimestamp, executeIDs, executeUpdate, executeUpdate, expandDate, formatDBName, formatLocation, getNewID, getQueryCount, prepare, prepareWithoutLimits, rollbackTransaction, setQueryMax, setQueryStart, setQueryTimeout, startTransaction, toID, toID, toInstantModifier and TypeMethodDescriptionprotected voidCommits a multi-step transaction to the database.protected static TimestampNull-safe conversion of an Instant to a Timestamp.Helper method to extract database ID data from the result set.protected static intexecuteUpdate(PreparedStatement ps, int minUpdateCount) Executes an UPDATE transaction on a prepared statement, and throws aSQLExceptionif less than the expected number of rows were updated.protected static intexecuteUpdate(PreparedStatement ps, int minPerUpdate, int minTotal) Executes an batched UPDATE transaction on a prepared statement, and throws aSQLExceptionif less than the expected number of rows were updated per batch entry.protected static InstantexpandDate(Date dt) Converts a date-only JDBC value into a full timestamp.protected static StringformatDBName(String db) Formats a database name by converting to lowercase.protected static StringConverts a geographic location into a MySQL WKT formatted point.protected intgetNewID()Returns the AUTO_INC column value generated by the previous JDBC transaction.static final longReturns the total number of queries executed since the JVM was started.protected PreparedStatementInitialize the prepared statement with an arbitrary SQL statement.protected PreparedStatementInitialize the prepared statement with an abitrary SQL statement, without applying the DAO's query result limitations.protected voidRolls back a multi-step transaction before it is completed.final voidsetQueryMax(int maxRows) Sets the maximum number of rows in the returned result set.final voidsetQueryStart(int rowStart) Sets the first row of the results to return.voidsetQueryTimeout(int timeout) Sets the timeout for any SQL operations.protected voidMarks the start of a multi-step database transaction.protected static IntegerConverts a Database bean or an Integer into an Integer.protected static Collection<Integer> toID(Collection<?> ids) Converts a collection of Objects into Integer IDs.protected static InstantNull-safe conversion of a Timestamp to an Instant.
-
Constructor Details
-
GetNavRoute
Initializes the Data Access Object.- Parameters:
c- the JDBC connection to use
-
-
Method Details
-
setEffectiveDate
Sets the effective date when looking up Oceanic Tracks.- Parameters:
dt- the effective date/time
-
getRouteWaypoints
public List<NavigationDataBean> getRouteWaypoints(String route, GeoLocation start) throws DAOException Returns all waypoints for a route, expanding Airways but NOT SID/STARs.- Parameters:
route- the space-delimited routestart- the starting point- Returns:
- an ordered List of NavigationDataBeans
- Throws:
DAOException- if a JDBC error occurs
-
populate
Populates a flight route with waypoint beans.- Parameters:
rt- the FlightRoute bean to populate- Returns:
- a populated DispatchRoute
- Throws:
DAOException- if a JDBC error occurs
-