站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss 4.0.1 sp1 server API Documentation 英文版文档

MessageEndpointInterceptor (JBoss Server API) - JBoss 4.0.1 sp1 server API Documentation 英文版文档


org.jboss.ejb.plugins.inflow
Class MessageEndpointInterceptor

java.lang.Object
  extended byorg.jboss.proxy.Interceptor
      extended byorg.jboss.ejb.plugins.inflow.MessageEndpointInterceptor
All Implemented Interfaces:
Externalizable, Serializable

public class MessageEndpointInterceptor
extends Interceptor

Implements the application server message endpoint requirements.

Version:
$Revision: 1.5 $
Author:
Adrian Brock
See Also:
Serialized Form

Field Summary
protected  boolean delivered
          Whether we have delivered a message
protected  Thread inUseThread
          The in use thread
static String MESSAGE_ENDPOINT_FACTORY
          The key for the factory
static String MESSAGE_ENDPOINT_XARESOURCE
          The key for the xa resource
protected  ClassLoader oldClassLoader
          The old classloader of the thread
protected  EDU.oswego.cs.dl.util.concurrent.SynchronizedBoolean released
          Whether this proxy has been released
protected  Transaction suspended
          Any suspended transaction
protected  Transaction transaction
          Any transaction we started
 
Fields inherited from class org.jboss.proxy.Interceptor
nextInterceptor
 
Constructor Summary
MessageEndpointInterceptor()
           
 
Method Summary
protected  void after(Invocation mi)
          After delivery processing.
protected  void before(Invocation mi)
          Before delivery processing.
protected  Object delivery(Invocation mi)
          Delivery.
protected  void endTransaction(Invocation mi, boolean commit)
          End the transaction
protected  void finish(String context, Invocation mi, boolean commit)
          Finish the current delivery
protected  MessageDrivenContainer getContainer(Invocation mi)
          Get the container
protected  JBossMessageEndpointFactory getMessageEndpointFactory(Invocation mi)
          Get the message endpoint factory
protected  String getProxyString(Invocation mi)
          Get our proxy's string value.
 Object invoke(Invocation mi)
           
protected  void release(Invocation mi)
          Release this message endpoint.
protected  void releaseThreadLock(Invocation mi)
          Release the thread lock
protected  void resetContextClassLoader(Invocation mi)
          Reset the context classloader
protected  void startTransaction(String context, Invocation mi, MessageDrivenContainer container)
          Start a transaction
 
Methods inherited from class org.jboss.proxy.Interceptor
getNext, readExternal, setNext, writeExternal
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MESSAGE_ENDPOINT_FACTORY

public static final String MESSAGE_ENDPOINT_FACTORY
The key for the factory

See Also:
Constant Field Values

MESSAGE_ENDPOINT_XARESOURCE

public static final String MESSAGE_ENDPOINT_XARESOURCE
The key for the xa resource

See Also:
Constant Field Values

released

protected EDU.oswego.cs.dl.util.concurrent.SynchronizedBoolean released
Whether this proxy has been released


delivered

protected boolean delivered
Whether we have delivered a message


inUseThread

protected Thread inUseThread
The in use thread


oldClassLoader

protected ClassLoader oldClassLoader
The old classloader of the thread


transaction

protected Transaction transaction
Any transaction we started


suspended

protected Transaction suspended
Any suspended transaction

Constructor Detail

MessageEndpointInterceptor

public MessageEndpointInterceptor()
Method Detail

invoke

public Object invoke(Invocation mi)
              throws Throwable
Specified by:
invoke in class Interceptor
Throws:
Throwable

release

protected void release(Invocation mi)
                throws Throwable
Release this message endpoint.

Parameters:
mi - the invocation
Throws:
Throwable - for any error

before

protected void before(Invocation mi)
               throws Throwable
Before delivery processing.

Parameters:
mi - the invocation
Throws:
Throwable - for any error

after

protected void after(Invocation mi)
              throws Throwable
After delivery processing.

Parameters:
mi - the invocation
Throws:
Throwable - for any error

delivery

protected Object delivery(Invocation mi)
                   throws Throwable
Delivery.

Parameters:
mi - the invocation
Returns:
the result of the delivery
Throws:
Throwable - for any error

finish

protected void finish(String context,
                      Invocation mi,
                      boolean commit)
               throws Throwable
Finish the current delivery

Parameters:
context - the lifecycle method
mi - the invocation
commit - whether to commit
Throws:
Throwable - for any error

startTransaction

protected void startTransaction(String context,
                                Invocation mi,
                                MessageDrivenContainer container)
                         throws Throwable
Start a transaction

Parameters:
context - the lifecycle method
mi - the invocation
container - the container
Throws:
Throwable - for any error

endTransaction

protected void endTransaction(Invocation mi,
                              boolean commit)
                       throws Throwable
End the transaction

Parameters:
mi - the invocation
commit - whether to try to commit
Throws:
Throwable - for any error

resetContextClassLoader

protected void resetContextClassLoader(Invocation mi)
Reset the context classloader

Parameters:
mi - the invocation

releaseThreadLock

protected void releaseThreadLock(Invocation mi)
Release the thread lock

Parameters:
mi - the invocation

getProxyString

protected String getProxyString(Invocation mi)
Get our proxy's string value.

Parameters:
mi - the invocation
Returns:
the string

getMessageEndpointFactory

protected JBossMessageEndpointFactory getMessageEndpointFactory(Invocation mi)
Get the message endpoint factory

Returns:
the message endpoint factory

getContainer

protected MessageDrivenContainer getContainer(Invocation mi)
Get the container

Returns:
the container


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.