public class Main extends HandlerQueueManager<Main> implements Handler<CommandLine,java.lang.Integer>
 1. コマンドライン引数のパース。
 2. コンポーネント設定ファイル(xml)の読み込みとハンドラー構成の初期化
 3. ハンドラーキューに対する後続処理の委譲。
 4. 終了/エラー処理。
    (結果コードはハンドラキューの戻り値、または送出された例外をもとに設定する。)
 
 
 以下は、本クラスの使用例である。
 (起動オプションに設定した値は、CommandLineオブジェクトから取得できる。)
 
 起動コマンドの例
 
 java                                                 \
     -server                                          \
     -Xmx128m                                         \
     -Dsample=100                                     \
 nablarch.fw.launcher.Main                            \
     -diConfig    file:./batch-config.xml             \
     -requestPath admin.DataUnloadBatchAction/BC0012  \
     -userId      testUser                            \
     -namedParam  value                               \
     value1
 
 起動コマンドの説明
 アプリケーション引数(JVMへの設定である起動コマンドの説明は行わない)
           -Dsample      コンポーネント設定ファイル中の埋め込みパラメータの値。例では、${sample}に100が設定される。
 Mainクラスへの引数
   (必須)  -diConfig     コンポーネント設定ファイルのファイルパス。クラスパス配下のxmlファイルを指定。
   (必須)  -requestPath  実行対象のアクションハンドラクラス名/リクエストIDを指定。
   (必須)  -userId       プロセスの実行権限ユーザID。セッション変数とスレッドコンテキストに保持される。
           -namedParam   名前付きパラメータ。CommandLineに使用される属性値を指定。
           value1        無名パラメータ。CommandLineに使用される属性値を指定。
| Constructor and Description | 
|---|
Main()  | 
| Modifier and Type | Method and Description | 
|---|---|
static int | 
execute(CommandLine commandLine)
バッチを実行する。
 
  
handle(CommandLine, ExecutionContext)に処理を委譲して結果を返す。 | 
java.util.List<Handler> | 
getHandlerQueue()
現在のハンドラキューの内容を返す。 
 | 
java.lang.Integer | 
handle(CommandLine commandLine,
      ExecutionContext context)
入力データに対する処理を実行する。 
 | 
protected void | 
initializeLog()
各種ログの初期化を行う。 
 | 
static void | 
main(java.lang.String... args)
メインメソッド。
 
 本メソッドでは、以下の内容をログ出力する。
 
 起動時
 起動オプションや、起動引数(詳細は、 
LauncherLogUtil.getStartLogMsg(CommandLine)を参照)
 終了時
 終了コードや処理時間(詳細は、LauncherLogUtil.getEndLogMsg(int, long)を参照})
 
 及び処理終了時 | 
protected void | 
outputAppSettingsLog()
アプリケーション設定のログを出力する。 
 | 
protected Main | 
setupExecutionContext(CommandLine commandLine,
                     ExecutionContext context)
バッチコントローラ起動前準備を行う。 
実行コンテキストを生成し、以下の処理を行う。 コンポーネント設定ファイルに定義したハンドラキューの設定 DataReaderの設定
     DataReaderFactoryの設定
     ディスパッチハンドラの設定
     セッションスコープにプロセスの実行権限ユーザIDと、起動オプションのマップを設定
  | 
protected void | 
setUpSystemRepository(java.lang.String configFilePath)
コンポーネント設定ファイルの設定にしたがって、システムリポジトリの初期化を行う。 
 | 
addHandler, addHandler, addHandler, addHandler, addHandler, addHandlers, clearHandlers, getHandlerOf, getMethodBinder, setHandlerQueue, setMethodBinderpublic java.util.List<Handler> getHandlerQueue()
HandlerQueueManagergetHandlerQueue in class HandlerQueueManager<Main>public static void main(java.lang.String... args)
LauncherLogUtil.getStartLogMsg(CommandLine)を参照)
 LauncherLogUtil.getEndLogMsg(int, long)を参照})
 args - コマンドライン引数public java.lang.Integer handle(CommandLine commandLine, ExecutionContext context)
handle in interface Handler<CommandLine,java.lang.Integer>commandLine - 入力データcontext - 実行コンテキスト@Published(tag="architect") public static int execute(CommandLine commandLine)
handle(CommandLine, ExecutionContext)に処理を委譲して結果を返す。commandLine - 起動オプションprotected Main setupExecutionContext(CommandLine commandLine, ExecutionContext context)
DataReaderの設定DataReaderFactoryの設定commandLine - 起動オプションcontext - 実行コンテキストprotected void setUpSystemRepository(java.lang.String configFilePath)
configFilePath - コンポーネント設定ファイルのパスprotected void initializeLog()
protected void outputAppSettingsLog()