Class SetNews

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

public class SetNews extends DAO
A Data Access Object to write System News and NOTAMs to the database.
Since:
1.0
Version:
10.6
Author:
Luke
  • Constructor Details

    • SetNews

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

    • write

      public void write(News n) throws DAOException
      Writes a System News entry to the database. This can handle inserts and edits.
      Parameters:
      n - the News entry to write
      Throws:
      DAOException - if a JDBC error occ
    • write

      public void write(Notice n) throws DAOException
      Writes a Notice to Airmen (NOTAM) to the database. This can handle inserts and edits.
      Parameters:
      n - the Notice entry to write
      Throws:
      DAOException - if a JDBC error occurs
    • delete

      public void delete(int id, boolean isNOTAM) throws DAOException
      Deletes a News Entry/NOTAM from the database.
      Parameters:
      id - the Database ID of the NOTAM or News Entry
      isNOTAM - TRUE if deleting a NOTAM, otherwise FALSE
      Throws:
      DAOException - if a JDBC error occurs