|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.vinculumtech.carrierwave.session.ClientSession
ClientSession is the root class for all CarrierWave interactions. Create a new session by
invoking createClientSession()
.
The properties parameter is passed to the concrete implementation of ClientSession. For the
EJBClientSession, JNDI connection and authentication properties can be passed.
The properties parameter is also checked for the ClientSession class name to instantiate. This allows
a single client to use an EJB, RMI, JMS, or local ClientSession interface.
Use the resulting instance of ClientSession to connect or disconnect from the remote server. Or to
get references to QueryClient
, or RepositoryClient
.
Field Summary | |
static java.lang.String |
CLIENT_SESSION
|
static java.lang.String |
CLIENT_SESSION_DEFAULT
|
Constructor Summary | |
ClientSession()
|
Method Summary | |
void |
connect()
Creates a connection to the remote server |
protected abstract CommonClient |
connectCommonClient()
|
static ClientSession |
createClientSession(java.util.Properties properties)
A factory method to return instances of ClientSession for the given set of properties. Note the returned instance is not a singleton, a new instance is returned on every call allowing for multiple sessions in a single process against any server specified in the Properties parameter. The Properties excpected on the EJBClientSession are standard JNDI context values. |
protected abstract void |
destroyCommonClient(CommonClient commonClient)
|
void |
disconnect()
Destroys a connection to the remote server |
protected CommonClient |
getCommonClient()
|
java.util.Properties |
getProperties()
|
java.lang.String |
getProperty(java.lang.String property,
java.lang.String defaultValue)
|
QueryClient |
getQueryClient()
|
RepositoryClient |
getRepositoryClient()
|
void |
handleGraphException(GraphException exception)
|
void |
handleGraphPlanException(GraphPlanException exception)
|
void |
handleRemoteException(java.rmi.RemoteException exception)
|
void |
handleUndeclaredThrowableException(java.lang.reflect.UndeclaredThrowableException exception)
|
void |
handleUnknownException(java.lang.Exception exception)
|
boolean |
isAutoConnect()
|
boolean |
isConnected()
Returns true iff a connection has already been established. |
void |
setAutoConnect(boolean isAutoConnect)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String CLIENT_SESSION
public static final java.lang.String CLIENT_SESSION_DEFAULT
Constructor Detail |
public ClientSession()
Method Detail |
public static ClientSession createClientSession(java.util.Properties properties)
Context.INITIAL_CONTEXT_FACTORY // default is ClientSession.DEFAULT_INITIAL_CONTEXT_FACTORY
Context.SECURITY_PRINCIPAL
Context.SECURITY_CREDENTIALS
Context.PROVIDER_URL
public java.util.Properties getProperties()
public java.lang.String getProperty(java.lang.String property, java.lang.String defaultValue)
protected CommonClient getCommonClient() throws ClientSessionException
ClientSessionException
public QueryClient getQueryClient()
public RepositoryClient getRepositoryClient()
public boolean isConnected()
public void connect() throws ClientSessionException
ClientSessionException
public void disconnect() throws ClientSessionException
ClientSessionException
public boolean isAutoConnect()
public void setAutoConnect(boolean isAutoConnect)
protected abstract CommonClient connectCommonClient() throws SessionFailureException
SessionFailureException
protected abstract void destroyCommonClient(CommonClient commonClient) throws SessionFailureException
SessionFailureException
public void handleUndeclaredThrowableException(java.lang.reflect.UndeclaredThrowableException exception) throws SessionFailureException
SessionFailureException
public void handleRemoteException(java.rmi.RemoteException exception) throws SessionFailureException
SessionFailureException
public void handleGraphException(GraphException exception) throws GraphException
GraphException
public void handleGraphPlanException(GraphPlanException exception) throws GraphPlanException
GraphPlanException
public void handleUnknownException(java.lang.Exception exception) throws SessionFailureException
SessionFailureException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |