org.jboss.mq.server
Class JMSServerInterceptorSupport

java.lang.Object
  extended byorg.jboss.mq.server.JMSServerInterceptorSupport
All Implemented Interfaces:
JMSServerInterceptor (src)
Direct Known Subclasses:
ClientMonitorInterceptor (src) , ClientReconnectInterceptor (src) , JMSDestinationManager (src) , NonPersistentInterceptor (src) , ServerSecurityInterceptor (src) , TracingInterceptor (src)

public class JMSServerInterceptorSupport
extends java.lang.Object
implements JMSServerInterceptor (src)

A pass through JMSServerInvoker.


Field Summary
protected  Logger (src) log
           
protected  JMSServerInterceptor (src) nextInterceptor
          Next invoker in chain.
 
Constructor Summary
JMSServerInterceptorSupport()
           
 
Method Summary
 void acknowledge(ConnectionToken (src)  dc, AcknowledgementRequest (src)  item)
          #Description of the Method
 void addMessage(ConnectionToken (src)  dc, SpyMessage (src)  message)
          Add the message to the destination.
 java.lang.String authenticate(java.lang.String userName, java.lang.String password)
          Check user for autentication.
 SpyMessage (src) [] browse(ConnectionToken (src)  dc, Destination (src)  dest, java.lang.String selector)
          #Description of the Method
 void checkID(java.lang.String ID)
          Check id, must not be taken.
 java.lang.String checkUser(java.lang.String userName, java.lang.String password)
          Check user for autentication.
 void connectionClosing(ConnectionToken (src)  dc)
          #Description of the Method
 Queue (src) createQueue(ConnectionToken (src)  dc, java.lang.String dest)
          #Description of the Method
 Topic (src) createTopic(ConnectionToken (src)  dc, java.lang.String dest)
          #Description of the Method
 void deleteTemporaryDestination(ConnectionToken (src)  dc, SpyDestination (src)  dest)
          #Description of the Method
 void destroySubscription(ConnectionToken (src)  dc, DurableSubscriptionID (src)  id)
          #Description of the Method
 SpyTopic (src) getDurableTopic(DurableSubscriptionID (src)  sub)
          Get the topic the durable subscription is on.
 java.lang.String getID()
          Gets a clientID from server.
 JMSServerInterceptor (src) getNext()
          Get next invoker in chain to be called.
 Subscription (src) getSubscription(ConnectionToken (src)  dc, int subscriberId)
          Get the subscription that match the id.
 TemporaryQueue (src) getTemporaryQueue(ConnectionToken (src)  dc)
          Gets the TemporaryQueue attribute of the ServerIL object
 TemporaryTopic (src) getTemporaryTopic(ConnectionToken (src)  dc)
          Gets the TemporaryTopic attribute of the ServerIL object
 java.lang.ThreadGroup getThreadGroup()
          Get the thread group of the server.
 void ping(ConnectionToken (src)  dc, long clientTime)
          #Description of the Method
 SpyMessage (src) receive(ConnectionToken (src)  dc, int subscriberId, long wait)
          #Description of the Method
 void setEnabled(ConnectionToken (src)  dc, boolean enabled)
          Sets the Enabled attribute of the ServerIL object
 void setNext(JMSServerInterceptor (src)  server)
          Set next invoker in chain to be called.
 void subscribe(ConnectionToken (src)  dc, Subscription (src)  s)
           
 void transact(ConnectionToken (src)  dc, TransactionRequest (src)  t)
          #Description of the Method
 void unsubscribe(ConnectionToken (src)  dc, int subscriptionId)
          #Description of the Method
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected Logger (src)  log

nextInterceptor

protected JMSServerInterceptor (src)  nextInterceptor
Next invoker in chain.

Constructor Detail

JMSServerInterceptorSupport

public JMSServerInterceptorSupport()
Method Detail

setNext

public void setNext(JMSServerInterceptor (src)  server)
Set next invoker in chain to be called. Is mot often the real JMSServer

Specified by:
setNext in interface JMSServerInterceptor (src)

getNext

public JMSServerInterceptor (src)  getNext()
Description copied from interface: JMSServerInterceptor (src)
Get next invoker in chain to be called. Is mot often the real JMSServer

Specified by:
getNext in interface JMSServerInterceptor (src)
See Also:
JMSServerInterceptor.getNext()

getThreadGroup

public java.lang.ThreadGroup getThreadGroup()
Get the thread group of the server.

Specified by:
getThreadGroup in interface JMSServerInterceptor (src)

getID

public java.lang.String getID()
                       throws JMSException (src) 
Gets a clientID from server.

Specified by:
getID in interface JMSServerInterceptor (src)
Returns:
The ID value
Throws:
JMSException (src) - Description of Exception

getTemporaryTopic

public TemporaryTopic (src)  getTemporaryTopic(ConnectionToken (src)  dc)
                                 throws JMSException (src) 
Gets the TemporaryTopic attribute of the ServerIL object

Specified by:
getTemporaryTopic in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
Returns:
The TemporaryTopic value
Throws:
JMSException (src) - Description of Exception

getTemporaryQueue

public TemporaryQueue (src)  getTemporaryQueue(ConnectionToken (src)  dc)
                                 throws JMSException (src) 
Gets the TemporaryQueue attribute of the ServerIL object

Specified by:
getTemporaryQueue in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
Returns:
The TemporaryQueue value
Throws:
JMSException (src) - Description of Exception

connectionClosing

public void connectionClosing(ConnectionToken (src)  dc)
                       throws JMSException (src) 
#Description of the Method

Specified by:
connectionClosing in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
Throws:
JMSException (src) - Description of Exception

checkID

public void checkID(java.lang.String ID)
             throws JMSException (src) 
Check id, must not be taken.

Specified by:
checkID in interface JMSServerInterceptor (src)
Parameters:
ID - a clientID
Throws:
JMSException (src) - if ID is already taken

addMessage

public void addMessage(ConnectionToken (src)  dc,
                       SpyMessage (src)  message)
                throws JMSException (src) 
Add the message to the destination.

Specified by:
addMessage in interface JMSServerInterceptor (src)
Parameters:
dc - The feature to be added to the Message attribute
message - The feature to be added to the Message attribute
Throws:
JMSException (src) - Description of Exception

createQueue

public Queue (src)  createQueue(ConnectionToken (src)  dc,
                         java.lang.String dest)
                  throws JMSException (src) 
#Description of the Method

Specified by:
createQueue in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
dest - Description of Parameter
Returns:
Description of the Returned Value
Throws:
JMSException (src) - Description of Exception

createTopic

public Topic (src)  createTopic(ConnectionToken (src)  dc,
                         java.lang.String dest)
                  throws JMSException (src) 
#Description of the Method

Specified by:
createTopic in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
dest - Description of Parameter
Returns:
Description of the Returned Value
Throws:
JMSException (src) - Description of Exception

deleteTemporaryDestination

public void deleteTemporaryDestination(ConnectionToken (src)  dc,
                                       SpyDestination (src)  dest)
                                throws JMSException (src) 
#Description of the Method

Specified by:
deleteTemporaryDestination in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
dest - Description of Parameter
Throws:
JMSException (src) - Description of Exception

transact

public void transact(ConnectionToken (src)  dc,
                     TransactionRequest (src)  t)
              throws JMSException (src) 
#Description of the Method

Specified by:
transact in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
t - Description of Parameter
Throws:
JMSException (src) - Description of Exception

acknowledge

public void acknowledge(ConnectionToken (src)  dc,
                        AcknowledgementRequest (src)  item)
                 throws JMSException (src) 
#Description of the Method

Specified by:
acknowledge in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
item - Description of Parameter
Throws:
JMSException (src) - Description of Exception

browse

public SpyMessage (src) [] browse(ConnectionToken (src)  dc,
                           Destination (src)  dest,
                           java.lang.String selector)
                    throws JMSException (src) 
#Description of the Method

Specified by:
browse in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
dest - Description of Parameter
selector - Description of Parameter
Returns:
Description of the Returned Value
Throws:
JMSException (src) - Description of Exception

receive

public SpyMessage (src)  receive(ConnectionToken (src)  dc,
                          int subscriberId,
                          long wait)
                   throws JMSException (src) 
#Description of the Method

Specified by:
receive in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
subscriberId - Description of Parameter
wait - Description of Parameter
Returns:
Description of the Returned Value
Throws:
JMSException (src) - Description of Exception

setEnabled

public void setEnabled(ConnectionToken (src)  dc,
                       boolean enabled)
                throws JMSException (src) 
Sets the Enabled attribute of the ServerIL object

Specified by:
setEnabled in interface JMSServerInterceptor (src)
Parameters:
dc - The new Enabled value
enabled - The new Enabled value
Throws:
JMSException (src) - Description of Exception

unsubscribe

public void unsubscribe(ConnectionToken (src)  dc,
                        int subscriptionId)
                 throws JMSException (src) 
#Description of the Method

Specified by:
unsubscribe in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
subscriptionId - Description of Parameter
Throws:
JMSException (src) - Description of Exception

destroySubscription

public void destroySubscription(ConnectionToken (src)  dc,
                                DurableSubscriptionID (src)  id)
                         throws JMSException (src) 
#Description of the Method

Specified by:
destroySubscription in interface JMSServerInterceptor (src)
Parameters:
id - Description of Parameter
Throws:
JMSException (src) - Description of Exception

checkUser

public java.lang.String checkUser(java.lang.String userName,
                                  java.lang.String password)
                           throws JMSException (src) 
Check user for autentication.

Specified by:
checkUser in interface JMSServerInterceptor (src)
Parameters:
userName - Description of Parameter
password - Description of Parameter
Returns:
a clientId.
Throws:
JMSException (src) - if user was not allowed to login

authenticate

public java.lang.String authenticate(java.lang.String userName,
                                     java.lang.String password)
                              throws JMSException (src) 
Check user for autentication.

Specified by:
authenticate in interface JMSServerInterceptor (src)
Parameters:
userName - Description of Parameter
password - Description of Parameter
Returns:
a sessionId
Throws:
JMSException (src) - if user was not allowed to login

subscribe

public void subscribe(ConnectionToken (src)  dc,
                      Subscription (src)  s)
               throws JMSException (src) 
Specified by:
subscribe in interface JMSServerInterceptor (src)
Parameters:
dc - org.jboss.mq.ConnectionToken
s - org.jboss.mq.Subscription
Throws:
JMSException (src) - The exception description.

ping

public void ping(ConnectionToken (src)  dc,
                 long clientTime)
          throws JMSException (src) 
#Description of the Method

Specified by:
ping in interface JMSServerInterceptor (src)
Parameters:
dc - Description of Parameter
clientTime - Description of Parameter
Throws:
JMSException (src) - Description of Exception

getDurableTopic

public SpyTopic (src)  getDurableTopic(DurableSubscriptionID (src)  sub)
                         throws JMSException (src) 
Description copied from interface: JMSServerInterceptor (src)
Get the topic the durable subscription is on. Primary for internal use in the server, and not for the IL's.

Specified by:
getDurableTopic in interface JMSServerInterceptor (src)
Throws:
JMSException (src)

getSubscription

public Subscription (src)  getSubscription(ConnectionToken (src)  dc,
                                    int subscriberId)
                             throws JMSException (src) 
Description copied from interface: JMSServerInterceptor (src)
Get the subscription that match the id.

Specified by:
getSubscription in interface JMSServerInterceptor (src)
Throws:
JMSException (src) - if it can not find the subscription.