org.seasar.jca.inbound
クラス AbstractMessageEndpointImpl

java.lang.Object
  上位を拡張 org.seasar.jca.inbound.AbstractMessageEndpointImpl
すべての実装されたインタフェース:
MessageEndpoint
直系の既知のサブクラス:
JMSMessageEndpointImpl

public abstract class AbstractMessageEndpointImpl
extends Object
implements MessageEndpoint

MessageEndpointの抽象クラスです.

作成者:
koichik

フィールドの概要
protected  boolean beforeDeliveryCalled
          beforeDelivery(Method)が呼び出された場合はtrue
protected  ClassLoader classLoader
          クラスローダ
protected  MessageEndpointFactory messageEndpointFactory
          メッセージエンドポイントファクトリ
protected  boolean processing
          メッセージエンドポイント固有のハンドラメソッドを処理中ならtrue
protected  boolean succeeded
          メッセージエンドポイント固有のハンドラメソッドが正常に終了した場合はtrue
protected  Transaction transaction
          トランザクション
protected  TransactionManager transactionManager
          トランザクションマネージャ
protected  XAResource xaResource
          XAリソース
 
コンストラクタの概要
AbstractMessageEndpointImpl(MessageEndpointFactory messageEndpointFactory, TransactionManager transactionManager, XAResource xaResource, ClassLoader classLoader)
          インスタンスを構築します.
 
メソッドの概要
 void afterDelivery()
           
protected  void assertBeforeDeliveryCalled()
          beforeDelivery(Method)が呼び出されて正常に終了していなければ例外をスローします.
protected  void assertNotProcessing()
          メッセージエンドポイント固有のハンドラメソッドが処理中でないことを確認します.
 void beforeDelivery(Method method)
           
protected  void beginTransaction()
          トランザクションを開始します.
protected  void cleanup()
          メッセージエンドポイントの後処理をします.
protected  void endTransaction()
          トランザクションを終了します.
protected  ClassLoader getClassLoader()
          クラスローダを返します.
protected  boolean isBeforeDeliveryCalled()
          MessageEndpoint.beforeDelivery(Method)が呼び出されていなければtrueを返します.
protected  boolean isProcessing()
          メッセージエンドポイント固有のハンドラメソッドが処理中であればtrueを返します.
protected  boolean isSucceeded()
          メッセージエンドポイント固有のハンドラメソッドが正常に処理終了した場合はtrueを返します.
 void release()
           
protected  void setProcessing(boolean processing)
          メッセージエンドポイント固有のハンドラメソッドが処理中であればtrueを設定します.
protected  void setSucceeded(boolean succeeded)
          メッセージエンドポイント固有のハンドラメソッドが正常に処理終了した場合はtrueを設定します.
 
クラス java.lang.Object から継承されたメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

フィールドの詳細

messageEndpointFactory

protected MessageEndpointFactory messageEndpointFactory
メッセージエンドポイントファクトリ


transactionManager

protected TransactionManager transactionManager
トランザクションマネージャ


transaction

protected Transaction transaction
トランザクション


xaResource

protected XAResource xaResource
XAリソース


classLoader

protected ClassLoader classLoader
クラスローダ


beforeDeliveryCalled

protected boolean beforeDeliveryCalled
beforeDelivery(Method)が呼び出された場合はtrue


processing

protected boolean processing
メッセージエンドポイント固有のハンドラメソッドを処理中ならtrue


succeeded

protected boolean succeeded
メッセージエンドポイント固有のハンドラメソッドが正常に終了した場合はtrue

コンストラクタの詳細

AbstractMessageEndpointImpl

public AbstractMessageEndpointImpl(MessageEndpointFactory messageEndpointFactory,
                                   TransactionManager transactionManager,
                                   XAResource xaResource,
                                   ClassLoader classLoader)
インスタンスを構築します.

パラメータ:
messageEndpointFactory - メッセージエンドポイントファクトリ
transactionManager - トランザクションマネージャ
xaResource - XAリソース
classLoader - クラスローダ
メソッドの詳細

beforeDelivery

public void beforeDelivery(Method method)
                    throws NoSuchMethodException,
                           ResourceException
定義:
インタフェース MessageEndpoint 内の beforeDelivery
例外:
NoSuchMethodException
ResourceException

afterDelivery

public void afterDelivery()
                   throws ResourceException
定義:
インタフェース MessageEndpoint 内の afterDelivery
例外:
ResourceException

release

public void release()
定義:
インタフェース MessageEndpoint 内の release

beginTransaction

protected void beginTransaction()
                         throws ResourceException
トランザクションを開始します.

例外:
ResourceException - トランザクションの開始中に例外が発生した場合

endTransaction

protected void endTransaction()
                       throws ResourceException
トランザクションを終了します.

メッセージエンドポイント固有のハンドラメソッドが正常に終了し,トランザクションマネージャが トランザクション中であればトランザクションをコミットします. それ以外の場合はトランザクションをロールバックします.

例外:
ResourceException - トランザクションの終了中に例外が発生した場合

assertBeforeDeliveryCalled

protected void assertBeforeDeliveryCalled()
                                   throws IllegalStateException
beforeDelivery(Method)が呼び出されて正常に終了していなければ例外をスローします.

例外:
IllegalStateException - beforeDelivery(Method)が呼び出されて正常に終了していない場合

assertNotProcessing

protected void assertNotProcessing()
メッセージエンドポイント固有のハンドラメソッドが処理中でないことを確認します.

例外:
IllegalStateException - メッセージエンドポイント固有のハンドラメソッドが処理中の場合

cleanup

protected void cleanup()
メッセージエンドポイントの後処理をします.


getClassLoader

protected ClassLoader getClassLoader()
クラスローダを返します.

戻り値:
クラスローダ

isBeforeDeliveryCalled

protected boolean isBeforeDeliveryCalled()
MessageEndpoint.beforeDelivery(Method)が呼び出されていなければtrueを返します.

戻り値:
MessageEndpoint.beforeDelivery(Method)が呼び出されていなければtrue

isProcessing

protected boolean isProcessing()
メッセージエンドポイント固有のハンドラメソッドが処理中であればtrueを返します.

戻り値:
メッセージエンドポイント固有のハンドラメソッドが処理中であればtrue

setProcessing

protected void setProcessing(boolean processing)
メッセージエンドポイント固有のハンドラメソッドが処理中であればtrueを設定します.

パラメータ:
processing - メッセージエンドポイント固有のハンドラメソッドが処理中であればtrue

isSucceeded

protected boolean isSucceeded()
メッセージエンドポイント固有のハンドラメソッドが正常に処理終了した場合はtrueを返します.

戻り値:
メッセージエンドポイント固有のハンドラメソッドが正常に処理終了した場合はtrue

setSucceeded

protected void setSucceeded(boolean succeeded)
メッセージエンドポイント固有のハンドラメソッドが正常に処理終了した場合はtrueを設定します.

パラメータ:
succeeded - メッセージエンドポイント固有のハンドラメソッドが正常に処理終了した場合はtrue


Copyright © 2005-2007 The Seasar Foundation. All Rights Reserved.