Class GetSELCAL

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

public class GetSELCAL extends DAO
A Data Access Object to read aircraft SELCAL data.
Since:
1.0
Version:
9.0
Author:
Luke
  • Constructor Details

    • GetSELCAL

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

    • get

      public SelectCall get(String code) throws DAOException
      Returns SELCAL data for a particular code.
      Parameters:
      code - the SELCAL code
      Returns:
      a SelectCall or null if not found
      Throws:
      DAOException - if a JDBC error occurs
      NullPointerException - if code is null
    • getEquipmentTypes

      public Collection<String> getEquipmentTypes() throws DAOException
      Returns all aircraft types that have a SELCAL code.
      Returns:
      a Collection of aircraft types
      Throws:
      DAOException - if a JDBC error occurs
    • getCodes

      public Collection<SelectCall> getCodes(String orderBy) throws DAOException
      Returns all aircraft SELCAL codes.
      Parameters:
      orderBy - the column to sort results with
      Returns:
      a Collection of SelectCall beans
      Throws:
      DAOException - if a JDBC error occurs
    • getReserved

      public Collection<SelectCall> getReserved(int pilotID) throws DAOException
      Returns all reserved aircraft SELCAL codes.
      Parameters:
      pilotID - the Pilot's database ID
      Returns:
      a Collection of SelectCall beans
      Throws:
      DAOException - if a JDBC error occurs
    • getByEquipmentType

      public Collection<SelectCall> getByEquipmentType(String eqType) throws DAOException
      Returns all aircraft SELCAL codes for a particular aircraft type.
      Parameters:
      eqType - the equipment type
      Returns:
      a Collection of SelectCall beans
      Throws:
      DAOException - if a JDBC error occurs