|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
Defines a central interface for connecting to a Cams server and accessing services.
| Method Summary | |
void |
addConnectionExceptionListener(ConnectionExceptionListener listener)
Adds the specified listener to this CamsClient. |
void |
connect()
Connect to the CamsServer. |
void |
destroy()
Destroy the CamsClient. |
void |
disconnect()
Disconnect from the CamsServer. |
String |
getServerUrl()
Get the Cams Server URL |
void |
initialize(Config config)
Initialize the CamsClient. |
boolean |
isConnected()
Check to see if connected to the CamsServer. |
void |
removeConnectionExceptionListener(ConnectionExceptionListener listener)
Removes the specified listener from this CamsClient. |
| Methods inherited from interface com.cafesoft.core.service.ServiceFinder |
find, find, find |
| Method Detail |
public void initialize(Config config)
throws ConfigException
config - Configuration Properties.
ConfigExceptionpublic String getServerUrl()
public void connect()
The underlying client implementation may create any number of network connections to support the configured Cams services. Connection creation can be "eager" or "lazy", but the underlying CamsClient implementation should at least establish that a CamsServer is located and listening at the configured URL. //@exception ConnectionException if the CamsClient fails to connect to the CamsServer. If the CamsClient attempts to create more than one Connection, then ConnectionException is thrown if any single Connection cannot be created. Any existing Connections should be cleaned up by invoking disconnect().
public boolean isConnected()
public void disconnect()
Any open connections to the CamsServer are gracefully disconnected and destroyed.
public void addConnectionExceptionListener(ConnectionExceptionListener listener)
listener - receives connection exceptionspublic void removeConnectionExceptionListener(ConnectionExceptionListener listener)
listener - receives connection exceptionspublic void destroy()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||