|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--net.agmodel.genericBroker.ServiceHTTP
|
+--net.agmodel.genericBroker.ServerHTTP
|
+--net.agmodel.genericBroker.GenericBrokerHTTP
|
+--net.agmodel.weatherData.MetBrokerHTTP
Handles:
database connections,
requests for details of databases and weather stations, and
requests for weather data.
Typically a client establishes a MetBroker session through a call to ServerHTTP.getConnection(String,String).
The session manages connections to data sources, and also provides lists of available MetDataSources.
MetBroker decides how to deal with requests for met data either from single stations, or over geographical only exists for the duration of a user session, and doesn't serve any other clients.
| Field Summary | |
static int |
GETMETCATALOG
|
static int |
GETREGION
|
static int |
GETSTATION
|
static int |
GETSTATIONREGION
|
static String |
HTTPHOSTPARAM
|
static String |
HTTPPORTPARAM
|
static int |
LISTALLSTATIONS
|
static int |
LISTREGIONSFORMETSOURCE
|
static int |
LISTSTATIONSFORQUERY
|
static int |
LISTSTATIONSFORREGION
|
static int |
SUPPLYSPATIALDATA
|
static int |
SUPPLYSTATIONDATA
|
| Fields inherited from class net.agmodel.genericBroker.GenericBrokerHTTP |
ALREADYLOGGEDIN, GETSOURCEDETAIL, LISTSOURCES, LISTSOURCESINREGION, LOGIN, LOGINWITHEMAIL, LOGINWITHPASSWORD, LOGOUTALLSOURCES, LOGOUTOFSOURCE |
| Fields inherited from class net.agmodel.genericBroker.ServerHTTP |
CONNECT, CONNECTUSER, DISCONNECT |
| Fields inherited from class net.agmodel.genericBroker.ServiceHTTP |
HOSTPARAMEXTENSION, PORTPARAMEXTENSION, servlet |
| Constructor Summary | |
MetBrokerHTTP(String host)
|
|
MetBrokerHTTP(String host,
int port)
|
|
| Method Summary | |
boolean[][] |
getMetCatalog(String sessionID,
String metSourceID,
String stationID)
Check whether a station has ever recorded an element at a particular resolution. |
MetSourceDetail |
getMetSourceDetail(String sessionID,
String metSourceID)
Gets details about the MetSource in one object. |
Region |
getRegion(String sessionID,
String metSourceID,
String regionID)
Gets details of a region associated with a data source. |
protected String |
getServletPath()
|
String |
getStationRegionID(String sessionID,
String metSourceID,
String stationID)
Get the weather station's current region ID. |
WeatherStation |
getWeatherStation(String sessionID,
String metSourceID,
String stationID)
Get the details of the weather station |
WeatherStation[] |
listMatchingStations(String sessionID,
SpatialMetRequest request)
Get an array of all the stations that can potentially contribute to the request To contribute, stations must fall within the area specified in the request, and record elements requested, and have operated at some point during the period of interest of the request. |
MetSourceDetail[] |
listMetSourceDetails(String sessionID)
Get the details for all the MetSources in MetBroker. |
MetSourceDetail[] |
listMetSourceDetails(String sessionID,
GeographicalArea ofInterest)
Get the details of the MetSources in MetBroker that coincide with the area specified. |
Region[] |
listRegions(String sessionID,
String metSourceID)
Get a list of all regions for which the database holds data. |
WeatherStation[] |
listStations(String sessionID,
String metSourceID)
Get an array of all the stations in a source. |
WeatherStation[] |
listStations(String sessionID,
String metSourceID,
String regionID)
Get an array of all the stations in a database region. |
boolean |
loginToMetDataSource(String sessionID,
String sourceID,
String usercode,
String password)
Establish a connection to the specified database using the usercode and password supplied. |
SpatialMetSet |
supplyMetData(String sessionID,
SpatialMetRequest request)
Get the relevant data from multiple stations. |
StationDataSet |
supplyMetData(String sessionID,
StationMetRequest request)
Get the relevant data from a single station. |
| Methods inherited from class net.agmodel.genericBroker.GenericBrokerHTTP |
alreadyLoggedIn, getSourceDetail, listSourceDetails, listSourceDetails, loginToDataSource, loginToDataSource, loginToDataSource, logOutOfAllSources, logOutOfSource, supplyData |
| Methods inherited from class net.agmodel.genericBroker.ServerHTTP |
disconnect, getConnection, getConnection |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int LISTREGIONSFORMETSOURCE
public static final int LISTSTATIONSFORREGION
public static final int LISTALLSTATIONS
public static final int GETMETCATALOG
public static final int GETSTATIONREGION
public static final int SUPPLYSTATIONDATA
public static final int SUPPLYSPATIALDATA
public static final int LISTSTATIONSFORQUERY
public static final int GETREGION
public static final int GETSTATION
public static final String HTTPHOSTPARAM
public static final String HTTPPORTPARAM
| Constructor Detail |
public MetBrokerHTTP(String host,
int port)
throws GeneralException
public MetBrokerHTTP(String host)
throws GeneralException
| Method Detail |
protected String getServletPath()
getServletPath in class ServiceHTTP
public String getStationRegionID(String sessionID,
String metSourceID,
String stationID)
throws GeneralException
sessionID - the ID returned by getConnectionmetSourceID - the identifier assigned to the source by MetBrokerstationID - the identifier for the station used by the host database.
GeneralException
public MetSourceDetail[] listMetSourceDetails(String sessionID)
throws GeneralException
sessionID - the ID returned by getConnection
GeneralException
public MetSourceDetail[] listMetSourceDetails(String sessionID,
GeographicalArea ofInterest)
throws GeneralException
sessionID - the ID returned by getConnectionofInterest - the area from which weather data is required
GeneralExceptionfor a generic version
public MetSourceDetail getMetSourceDetail(String sessionID,
String metSourceID)
throws GeneralException
sessionID - the ID returned by getConnection
IllegalArgumentException - if the language is not known
GeneralExceptionfor a generic version
public boolean loginToMetDataSource(String sessionID,
String sourceID,
String usercode,
String password)
throws GeneralException
sessionID - the ID returned by getConnectionsourceID - the identifier assigned to the source by MetBrokerusercode - a valid usercode on the sourcepassword - the corresponding password (warning - may be transmitted without encryption)
GeneralException
public StationDataSet supplyMetData(String sessionID,
StationMetRequest request)
throws GeneralException
sessionID - the ID returned by getConnectionrequest - specifies which station get data for, and what data to get
GeneralException
public SpatialMetSet supplyMetData(String sessionID,
SpatialMetRequest request)
throws GeneralException
sessionID - the ID returned by getConnectionrequest - specifies which area to get data for, and what data to get
GeneralException
public Region[] listRegions(String sessionID,
String metSourceID)
throws GeneralException
sessionID - the ID returned by getConnectionmetSourceID - the identifier for the metsource
GeneralException
public Region getRegion(String sessionID,
String metSourceID,
String regionID)
throws GeneralException
sessionID - the ID returned by getConnectionmetSourceID - the identifier for the metsourceregionID - the identifier for the region
GeneralException
public WeatherStation[] listStations(String sessionID,
String metSourceID)
throws GeneralException
sessionID - the ID returned by getConnectionmetSourceID - the identifier for the metsource
GeneralException
public WeatherStation[] listStations(String sessionID,
String metSourceID,
String regionID)
throws GeneralException
sessionID - the ID returned by getConnectionmetSourceID - the identifier for the metsourceregionID - specifies the region for which data is required
GeneralException
public WeatherStation getWeatherStation(String sessionID,
String metSourceID,
String stationID)
throws GeneralException
sessionID - the ID returned by getConnectionmetSourceID - the identifier assigned to the source by MetBrokerstationID - the identifier for the station used by the host database.
GeneralException
public WeatherStation[] listMatchingStations(String sessionID,
SpatialMetRequest request)
throws GeneralException
sessionID - the ID returned by getConnectionrequest - specifies the data required
GeneralException
public boolean[][] getMetCatalog(String sessionID,
String metSourceID,
String stationID)
throws GeneralException
sessionID - the ID returned by getConnectionmetSourceID - the identifier assigned to the source by MetBrokerstationID - the identifier for the station used by the host database.
GeneralException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||