12
Interprogram Communication
COBOL programs can communicate with each other, as well as with non-COBOL
programs. Program-to-program communication is conducted by using one (or
combinations) of the following:
•
The CALL statement
•
External data
•
cobcall
routine
•
cobcancel
routine
•
cobfunc
routine
12.1 Multiple COBOL Program Run Units
A multiple COBOL program run unit consists of either of the following:
•
One main (driver) program and one or more separately compiled programs;
each program may or may not have contained programs
•
One main program with one or more contained (nested) programs
Separately compiled programs can be concatenated in one source file, or can be
written as separate source files.
12.1.1 Examples of COBOL Run Units
Example 12–1 shows a run unit with three separately compiled programs, none of
which have contained programs. MAIN-PROGRAM (
1
) calls separate program
SUB1 (
2
), that calls separate program SUB2 (
3
).
Interprogram Communication 12–1
Содержание COBOL AAQ2G1FTK
Страница 22: ......
Страница 30: ......
Страница 94: ......
Страница 110: ......
Страница 146: ......
Страница 180: ......
Страница 194: ...Processing Files and Records 6 1 Defi...
Страница 300: ......
Страница 490: ......
Страница 516: ......
Страница 517: ......
Страница 530: ......
Страница 534: ......
Страница 590: ......
Страница 620: ......