|
||||||||||
| 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
An HTTP servlet wrapper interface to GenericBrokerRMI. The HTTP servlet wrapper is used when direct RMI connnections are blocked by firewalls. Each method below wraps a corresponding GenericBrokerRMI method. Method parameters are serialized and sent using HTTP to a wrapper servlet which calls the corresponding GenericBrokerRMI method and returns the results. int constants are used to identify which GenericBrokerRMI method to call
GenericBrokerRMI| Field Summary | |
static int |
ALREADYLOGGEDIN
call GenericBrokerRMI.alreadyLoggedIn(String, String) |
static int |
GETSOURCEDETAIL
call GenericBrokerRMI.getSourceDetail(String, String) |
static int |
LISTSOURCES
call GenericBrokerRMI.listSourceDetails(String) |
static int |
LISTSOURCESINREGION
call GenericBrokerRMI.listSourceDetails(String, GeographicalArea) |
static int |
LOGIN
call GenericBrokerRMI.loginToDataSource(String, String) |
static int |
LOGINWITHEMAIL
call GenericBrokerRMI.loginToDataSource(String, String, String) |
static int |
LOGINWITHPASSWORD
call GenericBrokerRMI.loginToDataSource(String, String, String, String) |
static int |
LOGOUTALLSOURCES
call GenericBrokerRMI.logOutOfAllSources(String) |
static int |
LOGOUTOFSOURCE
call GenericBrokerRMI.logOutOfSource(String, String) |
| Fields inherited from class net.agmodel.genericBroker.ServerHTTP |
CONNECT, CONNECTUSER, DISCONNECT |
| Fields inherited from class net.agmodel.genericBroker.ServiceHTTP |
HOSTPARAMEXTENSION, PORTPARAMEXTENSION, servlet |
| Constructor Summary | |
GenericBrokerHTTP(String host)
Create a linking class to communicate with the wrapper servlet on the default HTTP port (80). |
|
GenericBrokerHTTP(String host,
int port)
Create a linking class to communicate with the wrapper servlet on a nominated port. |
|
| Method Summary | |
boolean |
alreadyLoggedIn(String sessionID,
String sourceID)
Check whether any required connection to the specified database has already been established. |
DataSourceDetail |
getSourceDetail(String sessionID,
String dataSourceID)
Gets details about a single data source. |
DataSourceDetail[] |
listSourceDetails(String sessionID)
Get the details for all the data sources in the broker. |
DataSourceDetail[] |
listSourceDetails(String sessionID,
GeographicalArea ofInterest)
Get the details of the data sources in the broker that coincide with the area specified. |
boolean |
loginToDataSource(String sessionID,
String sourceID)
Establish a connection to the specified database without identifying the user in any way |
boolean |
loginToDataSource(String sessionID,
String sourceID,
String emailAddress)
Establish a connection to the specified database using the e-mail address supplied as identification. |
boolean |
loginToDataSource(String sessionID,
String sourceID,
String usercode,
String password)
Establish a connection to the specified database using the usercode and password supplied. |
void |
logOutOfAllSources(String sessionID)
Log out from any MetSources to which the client is currently logged in. |
void |
logOutOfSource(String sessionID,
String metSourceID)
Log out from the MetSource identified by the SourceID |
ServerResult |
supplyData(String sessionID,
ServerRequest request,
int callID)
Get the relevant data from a single station. |
| Methods inherited from class net.agmodel.genericBroker.ServerHTTP |
disconnect, getConnection, getConnection |
| Methods inherited from class net.agmodel.genericBroker.ServiceHTTP |
getServletPath |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int LISTSOURCES
public static final int LISTSOURCESINREGION
public static final int GETSOURCEDETAIL
public static final int ALREADYLOGGEDIN
public static final int LOGINWITHPASSWORD
public static final int LOGINWITHEMAIL
public static final int LOGIN
public static final int LOGOUTOFSOURCE
public static final int LOGOUTALLSOURCES
| Constructor Detail |
public GenericBrokerHTTP(String host,
int port)
throws GeneralException
host - the web server hosting the wrapper servlet
GeneralException
public GenericBrokerHTTP(String host)
throws GeneralException
host - the web server hosting the wrapper servlet
GeneralException| Method Detail |
public DataSourceDetail[] listSourceDetails(String sessionID)
throws GeneralException
sessionID - the ID returned by getConnection
GeneralException
public DataSourceDetail[] listSourceDetails(String sessionID,
GeographicalArea ofInterest)
throws GeneralException
sessionID - the ID returned by getConnectionofInterest - the area from which data is required
GeneralException
public DataSourceDetail getSourceDetail(String sessionID,
String dataSourceID)
throws GeneralException
sessionID - the ID returned by getConnection
IllegalArgumentException - if the data source ID is not known
GeneralException
public boolean alreadyLoggedIn(String sessionID,
String sourceID)
throws GeneralException
sessionID - the ID returned by getConnectionsourceID - the identifier assigned to the source by the broker - see listSourceDetails
GeneralException
public boolean loginToDataSource(String sessionID,
String sourceID,
String usercode,
String password)
throws GeneralException
sessionID - the ID returned by getConnectionsourceID - the identifier assigned to the source by the brokerusercode - a valid usercode on the sourcepassword - the corresponding password (warning - may be transmitted without encryption)
GeneralException
public boolean loginToDataSource(String sessionID,
String sourceID,
String emailAddress)
throws GeneralException
sessionID - the ID returned by getConnectionsourceID - the identifier assigned to the source by the broker - see listSourceDetailsemailAddress - the user's e-mail address
GeneralExceptiongetSourceDetail(String,String)
public boolean loginToDataSource(String sessionID,
String sourceID)
throws GeneralException
sessionID - the ID returned by getConnectionsourceID - the identifier assigned to the source by the broker - see listSourceDetails
GeneralExceptiongetSourceDetail(String,String)
public ServerResult supplyData(String sessionID,
ServerRequest request,
int callID)
throws GeneralException
sessionID - the ID returned by getConnectionrequest - specifies which station get data for, and what data to get
GeneralException
public void logOutOfSource(String sessionID,
String metSourceID)
throws GeneralException
sessionID - the ID returned by getConnectionmetSourceID - the identifier assigned to the source by MetBroker
GeneralException
public void logOutOfAllSources(String sessionID)
throws GeneralException
sessionID - the ID returned by getConnection
GeneralException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||