org.deltava.dao
Class GetWeather
java.lang.Object
org.deltava.dao.DAO
org.deltava.dao.WeatherDAO
org.deltava.dao.GetWeather
- All Implemented Interfaces:
- CachingDAO
public class GetWeather
- extends WeatherDAO
A Data Access Object to load weather data from the database.
- Since:
- 2.7
- Version:
- 2.7
- Author:
- Luke
| Methods inherited from class org.deltava.dao.DAO |
commitTransaction, createTimestamp, executeUpdate, expandDate, formatDBName, getNewID, getQueryCount, prepareStatement, prepareStatementWithoutLimits, rollbackTransaction, setManualCommit, setQueryMax, setQueryStart, setQueryTimeout, startTransaction |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GetWeather
public GetWeather(Connection c)
- Initializes the Data Access Object.
- Parameters:
c - the JDBC connection to use
get
public WeatherDataBean get(WeatherDataBean.Type t,
String code)
throws DAOException
- Retrieves an arbitrary weather data object from the database.
- Parameters:
t - the WeatherDataBean Typecode - the observation station code
- Returns:
- a WeatherDataBean, or null if none found
- Throws:
DAOException - if a JDBC error occurs
getMETAR
public METAR getMETAR(String code)
throws DAOException
- Retrieves the METAR for a particular observation station.
- Parameters:
code - the observation station code
- Returns:
- a METAR object, or null if not found
- Throws:
DAOException - if a JDBC error occurs
getTAF
public TAF getTAF(String code)
throws DAOException
- Retrieves the TAF for a particular observation station.
- Parameters:
code - the observation station code
- Returns:
- a TAF object, or null if not found
- Throws:
DAOException - if a JDBC error occurs
Copyright © 2004-2009 Global Virtual Airlines Group. All Rights Reserved.