|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
An AEFSessionFactory provides access to AEFSession objects through an implementation of the Factory design pattern. The factory represents a collection of virtual terminals which can be accessed through the factory's getSession() methods.
The AEFSessionFactory implementation provides resource pooling to facilitate efficient use of the AEFSession instances. The factory is configured in config.properties, where values for the range of valid terminal numbers and the capacity of the factory are specified.
The AEFSessionFactory registers as a provider to one or more SessionServers which in turn provide client access to sessions while distributing the load among the factory instances.
Field Summary | |
---|---|
static java.lang.String |
NAME
Name used for RMI naming |
Method Summary | |
---|---|
void |
destroySession(java.lang.String terminalNumber)
Destroys an AEFSession. |
java.util.Collection |
getActiveTerminalNumbers()
Get an enumeration of the terminal numbers of active AEFSessions in this factory. |
com.ibm.retail.AEF.session.AEFSession |
getAvailableSession(com.ibm.retail.AEF.session.SessionParameters parms)
Get an AEFSession object with a status of "available". |
com.ibm.retail.AEF.factory.AEFSessionFactoryInfo |
getFactoryInfo()
Get information about this factory. |
com.ibm.retail.AEF.factory.AEFSessionFactory |
getSelfReference()
Returns a self reference. |
com.ibm.retail.AEF.session.AEFSession |
getSession(java.lang.String terminalNumber,
com.ibm.retail.AEF.session.SessionParameters parms)
Get an AEFSession object by terminal number. |
boolean |
sessionExists(java.lang.String terminalNumber)
Returns true if a session for this terminal number has been created. |
Field Detail |
public static final java.lang.String NAME
Method Detail |
public com.ibm.retail.AEF.session.AEFSession getAvailableSession(com.ibm.retail.AEF.session.SessionParameters parms) throws java.rmi.RemoteException, AEFException
This method establishes a client reference to the session and removes it from the pool of available sessions.
parms
- SessionParameters object contains all parameters for the session as name-value pairs
java.rmi.RemoteException
- if remote access fails
AEFException
- if a session can not be createdpublic com.ibm.retail.AEF.session.AEFSession getSession(java.lang.String terminalNumber, com.ibm.retail.AEF.session.SessionParameters parms) throws java.rmi.RemoteException, AEFException
This method does not remove the session from the pool of available sessions. Clients can remove the session from the available session pool by invoking the reference() method of the particular AEFSession.
terminalNumber
- number of the terminal session requestedparms
- SessionParameters object contains all parameters for the session as name-value pairs
java.rmi.RemoteException
- if remote access fails
AEFException
- if a session can not be createdpublic void destroySession(java.lang.String terminalNumber) throws java.rmi.RemoteException, AEFException
This method applies only to virtual (CSS) sessions. Invoking this method terminates the POS application and removes the AEFSession from the SessionPool.
terminalNumber
- identifies the session to be destroyed
java.rmi.RemoteException
- if server is not available
AEFException
- if an error occurs destroying the session
AEFException error codes are:
public com.ibm.retail.AEF.factory.AEFSessionFactoryInfo getFactoryInfo() throws java.rmi.RemoteException
Information can be used to determine factory load (utilization) for load balancing across multiple factories.
java.rmi.RemoteException
- if an instance of an object can not be createdpublic boolean sessionExists(java.lang.String terminalNumber) throws java.rmi.RemoteException
terminalNumber
- identifies the session
java.rmi.RemoteException
- if error occurs in remote accesspublic java.util.Collection getActiveTerminalNumbers() throws java.rmi.RemoteException
java.rmi.RemoteException
- if an instance of an object can not be createdpublic com.ibm.retail.AEF.factory.AEFSessionFactory getSelfReference() throws java.rmi.RemoteException
java.rmi.RemoteException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |