OSI/FTAM Programming Reference Manual

NonStop FTAM Programming Examples
HP NonStop OSI/FTAM Programming Reference Manual528611-001
G-180
Example 2 in TAL—Moving a File Between Two
Remote Systems (in Wait Mode)
739 !------------------------------------------------------------------!
740 ! Set the document type in the contents_type structure to FTAM-3. !
741 !------------------------------------------------------------------!
742 contents_type.zid := ZFTM^VAL^CNTNTSTYPE^DOCTYPE;
743 contents_type.zdoctype.zdoctypename.znum^elements := NUM_ELEM;
744 contents_type.zdoctype.zdoctypename.zobj^id ':=' ftam_doc_type FOR
745 NUM_ELEM WORDS;
746
747 !------------------------------------------------------------------!
748 ! Set MSL to present and set to length to 512 bytes. !
749 !------------------------------------------------------------------!
750 contents_type.zdoctype.zmaxstringlenispresent := ZAPS^VAL^PRESENT;
751 contents_type.zdoctype.zmaxstringlen := 512D;
752
753 !------------------------------------------------------------------!
754 ! Set the remaining contents_type.zdoctype elements to !
755 ! ZAPS^VAL^ABSENT. !
756 !------------------------------------------------------------------!
757 contents_type.zdoctype.zuniversalclassispresent := ZAPS^VAL^ABSENT;
758 contents_type.zdoctype.zstringsigispresent := ZAPS^VAL^ABSENT;
759 contents_type.zdoctype.zfileattrsispresent := ZAPS^VAL^ABSENT;
760
761 !------------------------------------------------------------------!
762 ! Establish the source-file file-selection and file-open regimes. !
763 !------------------------------------------------------------------!
764
765 !------------------------------------------------------------------!
766 ! Use the FTM procedures FTM_SELECT_REQ_, FTM_READ_ATTRIB_REQ_, !
767 ! and FTM_OPEN_REQ_ to select the file, read the file attributes, !
768 ! and open the source file. These three requests are processed as !
769 ! a group. Initialize all necessary parameters. !
770 !------------------------------------------------------------------!
771
772 !------------------------------------------------------------------!
773 ! Initialize the parameters for the FTM_SELECT_REQ_ procedure call.!
774 !------------------------------------------------------------------!
775
776 !------------------------------------------------------------------!
777 ! Initialize the file name according to the remote system !