Rational Developer for System z
Enterprise COBOL for z/OS バージョン 4.1 プログラミング・ガイド


図の説明: IGYTCARA アプリケーションの各部分

この図では、相乗り通勤アプリケーション内の主要なプロシージャーの 構成が示されています。 次の疑似コードでは同じ情報が示されますが、ファイル処理エラー・ルーチンは 省略します。 段落 000-DO-MAIN-LOGIC は、メイン制御フローを記述します。 後続の段落は、主要なサブルーチンを記述します。

Main routine 000-DO-MAIN-LOGIC:

  1. Perform 050-create-VSAM-master-file
  2. Perform 100-Initialize-paragraph
  3. Perform until Update-transaction-eof
    1. Perform 200-Edit-update-transaction
    2. If no-errors perform 300-Update-commuter-record
    3. Else perform 400-Print-transaction-errors
    4. End-if
    5. End-perform
  4. Perform 700-Find-home-junction.
  5. Perform 800-Find-work-junction.
  6. Perform 1100-Print-headings.
  7. Perform 1200-Print-data.
  8. Stop run.

Subroutine 050-create-VSAM-master-file:

  1. Open output VSAM COMMUTER-FILE, write dummy record, close file
  2. Open I-O VSAM COMMUTER-FILE, delete dummy record, close file

Subroutine 100-Initialize-paragraph:

  1. Open files
  2. Move current date and time to report heading, save current date
  3. Load location table.

Subroutine 200-Edit-update-transaction:

  1. Validate identical items for ADD, REPLACE, and DELETE transactions
  2. Check against COMMUTER MASTER file for match;
  3. Validate remaining items for ADD and REPLACE transactions.

Subroutine 300-Update-commuter-master-record:

  1. Update commuter master file, print old record if any, print new record

Subroutine 400-Print-transaction-errors:

  1. Print invalid transaction and all detected errors

Subroutine 700-Find-home-junction:

  1. Search table for code/name match

Subroutine 800-Find-work-junction:

  1. Search table for code/name match

Subroutine 1100-Print-headings:

  1. Open the print file and print headings

Subroutine 1200-Print-data:

  1. Perform 1210-get-miles-time
  2. Perform 1220-store-miles-time
  3. Perform 1230-print-sub-data
  4. Perform 1240-compute-summary.

製品インストール・テープにあるサンプル・プログラムを確認して、 相乗り通勤アプリケーション内の他のプロシージャーについて理解することができます。

図の説明の終わり。


ご利用条件 | フィードバック

このインフォメーション・センターでは Eclipse テクノロジーが採用されています。(http://www.eclipse.org)