jp.terasoluna.fw.batch.standard
クラス StandardSupportLogicResultHandler

java.lang.Object
  上位を拡張 jp.terasoluna.fw.batch.standard.StandardSupportLogicResultHandler
すべての実装されたインタフェース:
SupportLogicResultHandler
直系の既知のサブクラス:
TransactionalSupportLogicResultHandler

public class StandardSupportLogicResultHandler
extends java.lang.Object
implements SupportLogicResultHandler

SupportLogicResultHandler インタフェースの標準実装クラス。

このクラスでは、サポートロジック処理結果が NORMAL_ENDERROR_ENDであるときに、ジョブステータスを更新する。


フィールドの概要
private static org.apache.commons.logging.Log log
          ログインスタンス。
 
コンストラクタの概要
StandardSupportLogicResultHandler()
           
 
メソッドの概要
 void handle(BLogicResult blogicResult, JobStatus jobStatus, java.lang.String name)
          サポート処理の実行結果を処理する。
protected  void processErrorContinue(JobStatus jobStatus, BLogicResult bLogicResult, java.lang.String name)
          BLogicResult のリターンコードが ERROR_CONTINUE であるときの処理を行う。
protected  void processErrorEnd(JobStatus jobStatus, BLogicResult bLogicResult, java.lang.String name)
          BLogicResult のリターンコードが ERROR_END で あるときの処理を行う。
protected  void processNormalContinue(JobStatus jobStatus, BLogicResult bLogicResult, java.lang.String name)
          BLogicResult のリターンコードが NORMAL_CONTINUE であるときの処理を行う。
protected  void processNormalEnd(JobStatus jobStatus, BLogicResult bLogicResult, java.lang.String name)
          BLogicResult のリターンコードが NORMAL_END で あるときの処理を行う。
protected  void writeErrorLog(JobStatus jobStatus, BLogicResult result, java.lang.String name)
          サポートロジックの処理結果のエラーログを出力する。
protected  void writeWarnLog(JobStatus jobStatus, BLogicResult result, java.lang.String name)
          サポートロジックの処理結果の警告ログを出力する。
 
クラス java.lang.Object から継承されたメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

フィールドの詳細

log

private static org.apache.commons.logging.Log log
ログインスタンス。

コンストラクタの詳細

StandardSupportLogicResultHandler

public StandardSupportLogicResultHandler()
メソッドの詳細

handle

public void handle(BLogicResult blogicResult,
                   JobStatus jobStatus,
                   java.lang.String name)
サポート処理の実行結果を処理する。

定義:
インタフェース SupportLogicResultHandler 内の handle
パラメータ:
blogicResult - サポート処理の実行結果
jobStatus - ジョブステータス
name - サポート処理クラスに設定された名前

processNormalContinue

protected void processNormalContinue(JobStatus jobStatus,
                                     BLogicResult bLogicResult,
                                     java.lang.String name)
BLogicResult のリターンコードが NORMAL_CONTINUE であるときの処理を行う。

パラメータ:
jobStatus - ジョブステータス
bLogicResult - ビジネスロジック処理結果
name - サポート処理クラスに設定された名前

processNormalEnd

protected void processNormalEnd(JobStatus jobStatus,
                                BLogicResult bLogicResult,
                                java.lang.String name)
BLogicResult のリターンコードが NORMAL_END で あるときの処理を行う。

JobStatusのジョブ状態を JobStatus.STATE.ENDING_NORMALLY に更新し、 BLogicResult のジョブ終了コードを JobStatus に反映する。

パラメータ:
jobStatus - ジョブステータス
bLogicResult - ビジネスロジック処理結果
name - サポート処理クラスに設定された名前

processErrorContinue

protected void processErrorContinue(JobStatus jobStatus,
                                    BLogicResult bLogicResult,
                                    java.lang.String name)
BLogicResult のリターンコードが ERROR_CONTINUE であるときの処理を行う。

警告ログを出力する。

パラメータ:
jobStatus - ジョブステータス
bLogicResult - サポート処理の実行結果
name - サポート処理クラスに設定された名前

processErrorEnd

protected void processErrorEnd(JobStatus jobStatus,
                               BLogicResult bLogicResult,
                               java.lang.String name)
BLogicResult のリターンコードが ERROR_END で あるときの処理を行う。

エラーログを出力する。

JobStatusのジョブ状態を JobStatus.STATE.ENDING_ABNORMALLY に更新し、 BLogicResult のジョブ終了コードを JobStatus に反映する。

パラメータ:
jobStatus - ジョブステータス
bLogicResult - ビジネスロジック処理結果
name - サポート処理クラスに設定された名前

writeErrorLog

protected void writeErrorLog(JobStatus jobStatus,
                             BLogicResult result,
                             java.lang.String name)
サポートロジックの処理結果のエラーログを出力する。

パラメータ:
jobStatus - ジョブステータス
result - サポートロジックの処理結果
name - サポート処理クラスに設定された名前

writeWarnLog

protected void writeWarnLog(JobStatus jobStatus,
                            BLogicResult result,
                            java.lang.String name)
サポートロジックの処理結果の警告ログを出力する。

パラメータ:
jobStatus - ジョブステータス
result - サポートロジックの処理結果
name - サポート処理クラスに設定された名前