OSI/FTAM Programming Reference Manual

NonStop FTAM Programming Examples
HP NonStop OSI/FTAM Programming Reference Manual528611-001
G-56
Example 1 in TAL—Updating a Remote File (in
Nowait Mode)
Example 1 in TAL—Updating a Remote File (in
Nowait Mode)
1 !-----------------------------------------------------------------------!
2 ! !
3 ! Example 1 in TAL - Updating a Remote FTAM-2 File (in Nowait Mode) !
4 ! !
5 !-----------------------------------------------------------------------!
6 ! !
7 ! Program Name: EXTINSF2 !
8 ! !
9 ! Program Description: !
10 ! !
11 ! This program, in nowait mode, inserts five records into a remote !
12 ! FTAM-2 file. The application initiates and manages this data !
13 ! transfer. It opens and reads a local (Enscribe relative) file !
14 ! using Guardian system procedures and sends five records as data !
15 ! requests to the remote file. Both the Guardian system calls !
16 ! and the Tandem FTAM procedure calls are made in nowait mode. !
17 ! !
18 ! The main procedure contains the initialization code, the control !
19 ! statements for the main processing loop, and the termination code. !
20 ! This procedure analyzes input received from MFM_AWAITIOX_ and !
21 ! calls one of three procedures to perform processing as indicated: !
22 ! !
23 ! ftam_io_cmpl A routine that handles FTAM I/O !
24 ! completions !
25 ! !
26 ! ftam_event_rcvd A routine that handles FTAM events !
27 ! received from the remote responder !
28 ! !
29 ! data_transfer A routine that obtains data from the !
30 ! local file, formats it, and then !
31 ! sends it to the remote file !
32 ! !
33 ! Four error-handling routines are used in this program: !
34 ! !
35 ! check_error A procedure that checks for errors !
36 ! returned by FTM indication and !