jPOS 1.6.1 API Documentation

org.jpos.q2.iso
Class QMUX

java.lang.Object
  extended by org.jpos.q2.QBeanSupport
      extended by org.jpos.q2.iso.QMUX
All Implemented Interfaces:
Configurable, MUX, QMUXMBean, QBean, QBeanSupportMBean, QPersist, SpaceListener, Loggeable

public class QMUX
extends QBeanSupport
implements SpaceListener, MUX, QMUXMBean, Loggeable

Version:
$Revision: 2619 $ $Date: 2008-04-17 10:12:30 -0700 (Thu, 17 Apr 2008) $
Author:
Alejandro Revilla

Nested Class Summary
 class QMUX.AsyncRequest
           
 
Field Summary
 
Fields inherited from class org.jpos.q2.QBeanSupport
stateString
 
Fields inherited from interface org.jpos.q2.QBean
DESTROYED, FAILED, STARTED, STARTING, STOPPED, STOPPING
 
Constructor Summary
QMUX()
           
 
Method Summary
 void addISORequestListener(ISORequestListener l)
           
 void dump(java.io.PrintStream p, java.lang.String indent)
           
 java.lang.String getCountersAsString()
           
 java.lang.String getInQueue()
           
 java.lang.String getKey(ISOMsg m)
           
static MUX getMUX(java.lang.String name)
           
 java.lang.String getOutQueue()
           
 Space getSpace()
           
 java.lang.String getUnhandledQueue()
           
 void initService()
           
 boolean isConnected()
           
 void notify(java.lang.Object k, java.lang.Object value)
          Called by Space implementation whenever an object with the given key is being placed in the Space.
 boolean removeISORequestListener(ISORequestListener l)
           
 ISOMsg request(ISOMsg m, long timeout)
           
 void request(ISOMsg m, long timeout, ISOResponseListener rl, java.lang.Object handBack)
           
 void resetCounters()
           
 void setInQueue(java.lang.String in)
           
 void setOutQueue(java.lang.String out)
           
 void setUnhandledQueue(java.lang.String unhandled)
           
 void startService()
           
 void stopService()
           
 
Methods inherited from class org.jpos.q2.QBeanSupport
destroy, getConfiguration, getFactory, getLoader, getLoaderURLS, getLog, getLogger, getName, getPersist, getServer, getState, getStateAsString, init, isModified, running, setConfiguration, setLogger, setModified, setName, setPersist, setServer, setState, shutdownQ2, start, stop
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jpos.q2.QBeanSupportMBean
getLoader, getLoaderURLS, getLogger, getName, getServer, setLogger, setName, setPersist, setServer, shutdownQ2
 
Methods inherited from interface org.jpos.q2.QBean
destroy, getState, getStateAsString, init, start, stop
 
Methods inherited from interface org.jpos.q2.QPersist
getPersist, isModified
 

Constructor Detail

QMUX

public QMUX()
Method Detail

initService

public void initService()
                 throws ConfigurationException
Throws:
ConfigurationException

startService

public void startService()

stopService

public void stopService()

getMUX

public static MUX getMUX(java.lang.String name)
                  throws NameRegistrar.NotFoundException
Returns:
MUX with name using NameRegistrar
Throws:
NameRegistrar.NotFoundException
See Also:
NameRegistrar

request

public ISOMsg request(ISOMsg m,
                      long timeout)
               throws ISOException
Specified by:
request in interface MUX
Parameters:
m - message to send
timeout - amount of time in millis to wait for a response
Returns:
response or null
Throws:
ISOException

notify

public void notify(java.lang.Object k,
                   java.lang.Object value)
Description copied from interface: SpaceListener

Called by Space implementation whenever an object with the given key is being placed in the Space.

Specified by:
notify in interface SpaceListener
Parameters:
k - Object's key
value - Object's value

getKey

public java.lang.String getKey(ISOMsg m)
                        throws ISOException
Throws:
ISOException

setInQueue

public void setInQueue(java.lang.String in)
Specified by:
setInQueue in interface QMUXMBean

getInQueue

public java.lang.String getInQueue()
Specified by:
getInQueue in interface QMUXMBean

setOutQueue

public void setOutQueue(java.lang.String out)
Specified by:
setOutQueue in interface QMUXMBean

getOutQueue

public java.lang.String getOutQueue()
Specified by:
getOutQueue in interface QMUXMBean

getSpace

public Space getSpace()

setUnhandledQueue

public void setUnhandledQueue(java.lang.String unhandled)
Specified by:
setUnhandledQueue in interface QMUXMBean

getUnhandledQueue

public java.lang.String getUnhandledQueue()
Specified by:
getUnhandledQueue in interface QMUXMBean

request

public void request(ISOMsg m,
                    long timeout,
                    ISOResponseListener rl,
                    java.lang.Object handBack)
             throws ISOException
Specified by:
request in interface MUX
Throws:
ISOException

addISORequestListener

public void addISORequestListener(ISORequestListener l)

removeISORequestListener

public boolean removeISORequestListener(ISORequestListener l)

resetCounters

public void resetCounters()
Specified by:
resetCounters in interface QMUXMBean

getCountersAsString

public java.lang.String getCountersAsString()
Specified by:
getCountersAsString in interface QMUXMBean

isConnected

public boolean isConnected()
Specified by:
isConnected in interface MUX
Returns:
true if connected

dump

public void dump(java.io.PrintStream p,
                 java.lang.String indent)
Specified by:
dump in interface Loggeable

jPOS.org