Class GetGates

java.lang.Object
org.deltava.dao.DAO
org.deltava.dao.GetGates

public class GetGates extends DAO
A Data Access Object to load Airport gate information.
Since:
5.1
Version:
11.1
Author:
Luke
  • Constructor Details

    • GetGates

      public GetGates(Connection c)
      Initializes the Data Access Object.
      Parameters:
      c - the JDBC connection to use
  • Method Details

    • getAll

      public Collection<Gate> getAll() throws DAOException
      Returns all Airport gates.
      Returns:
      a Collection of Gates
      Throws:
      DAOException - if a JDBC error occurs
    • populate

      public void populate(FlightInfo info) throws DAOException
      Loads specific gates for an ACARS Flight.
      Parameters:
      info - the ACARS FlightInfo bean
      Throws:
      DAOException - if a JDBC error occurs
    • getGates

      public List<Gate> getGates(ICAOAirport a) throws DAOException
      Returns popular Gates for a particular Airport.
      Parameters:
      a - the Airport
      Returns:
      a List of Gates, ordered by name
      Throws:
      DAOException - if a JDBC error occurs
    • getUsage

      public GateUsage getUsage(RoutePair rp, boolean isDeparture, String dbName) throws DAOException
      Returns popular Gates for a particular Route.
      Parameters:
      rp - the RoutePair
      isDeparture - TRUE if returning preferred departure Gate, otherwise FALSE
      dbName - the database name
      Returns:
      a List of Gates, ordered by popularity
      Throws:
      DAOException - if a JDBC error occurs
    • getUsagePairs

      public List<Airport> getUsagePairs(Airport a, boolean isDeparture) throws DAOException
      Returns available Airports for Gate usage statistics for a given Airport.
      Parameters:
      a - the Airport
      isDeparture - TRUE for departure Gate statistics, otherwise FALSE
      Returns:
      a List of Airports
      Throws:
      DAOException - if a JDBC error occurs
    • getGate

      public Gate getGate(ICAOAirport a, String code) throws DAOException
      Loads a specific gate.
      Parameters:
      a - the ICAOAirport
      code - the Gate name
      Returns:
      a Collection of Gate beans
      Throws:
      DAOException - if a JDBC error occurs