N.B. for all of the following routines, a connection must
first be established using CZOPEN (see on Page
).
All of the following routines return:
IRC < 0 : error - explanatory message will be printed by routine IRC = 0 : success : see statistics in IQUEST IRC = 1 : cannot open remote file IRC = 2 : cannot open local file IRC = 3 : problem in file transfer For IRC = 0: IQUEST(11) = Number of records transferred IQUEST(12) = Number of kilobytes transferred IQUEST(13) = Transfer rate in KB/second IQUEST(14) = Number of hours elapsed (real time) IQUEST(15) = Number of minutes elapsed (real time) IQUEST(16) = Number of seconds elapsed (real time) IQUEST(17) = Number of seconds elapsed (CPU time)
N.B. file names for VM/CMS systems should be specified in
the form filename.filetype .filemode , e.g.
PROFILE.EXEC.A. VM mini-disks should be specified in the form
username .address ,e.g.
JAMIE , PUBWS.197 .
File transfer to and from VM/CMS systems and access to files
stored in VM/CMS systems is only possible to the current 'A-disk',
which can be changed using the XZCD routine (see on Page
).
CALL XZGETA (LOCAL,REMOTE,CHOPT,IRC)
This routine gets a text file from the remote system. If option 'S' is specified, statistics on the file transfer are printed. If option 'V' is specified, the local file will have variable length record format (IBM-VM systems only).
Example of using the XZGETA routine
CALL XZGETA('=','CZPACK.CARDS','S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZPUTA (LOCAL,REMOTE,CHOPT,IRC)
This routine sends a text file to the remote system. If option 'S' is specified, statistics on the file transfer are printed. If option 'V' is specified, the remote file will have variable length record format (IBM-VM systems only).
Example of using the XZPUTA routine
CALL XZPUTA('CZPACK.CARDS','=','S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZGETB (LOCAL,REMOTE,LRECL,CHOPT,IRC)
This routine gets a binary file from the remote system. The file must have fixed length records. ZEBRA FZ files in binary exchange format, PATCHY CETA files and EPIO files are examples of files that can be transferred with this routine. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZGETB routine
CALL XZGETB('FXFILE.DAT','FXFILE.VAX',32400,'S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZPUTB (LOCAL,REMOTE,LRECL,CHOPT,IRC)
This routine sends a binary file to the remote system. The file must have fixed length records. ZEBRA FZ files in binary exchange format, PATCHY CETA files and EPIO files are examples of files that can be transferred with this routine. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZPUTB routine
CALL XZPUTB('CZPACK.CETA','=',3600,'S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZGETD (LOCAL,REMOTE,LRECL,CHOPT,IRC)
This routine gets a direct access file from the remote system. ZEBRA FZ files in binary exchange format written with option D, ZEBRA RZ files (between like machines) are examples of files that can be transferred with this routine. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZGETD routine
CALL XZGETD('FXFILE.DAT','FXFILE.VAX',32400,'S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZPUTD (LOCAL,REMOTE,LRECL,CHOPT,IRC)
This routine sends a direct access file to the remote system. ZEBRA FZ files in binary exchange format written with option D, ZEBRA RZ files (between like machines) are examples of files that can be transferred with this routine. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZPUTD routine
CALL XZPUTD('FXFILE.DATA','=',32400,'S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZGETP (LOCAL,REMOTE,CHOPT,IRC)
This routine gets a binary PAM file from the remote system. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZGETP routine
CALL XZGETP('=','ZEBRA.PAM','S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZPUTP (LOCAL,REMOTE,CHOPT,IRC)
This routine sends a binary PAM file to the remote system. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZPUTP routine
CALL XZPUTP('KERNAPO.PAM','/cern/new/pam/kernapo/pam','S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZGETF (LOCAL,REMOTE,LRECL,LFORM,RRECL,RFORM,CHOPT,IRC)
This routine gets a binary file from the remote system. If the local file format or record length are not given, they default to the same values as on the remote system. The format may be 'A', for FZ exchange, ASCII mapping, 'X', for FZ exchange, binary, or ' ' for FZ native. For ASCII files the record length defaults to 80 bytes. For binary exchange format files, the record length is taken from the file itself. For native format files the record length must be specified. For binary exchange format files, a 'D' may also be specified, indicating that the file should be processed using direct-access I/O. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZGETB routine
*
* Transfer a remote ASCII exhange format file to a local
* binary exchange format file
*
CALL XZGETF('FXFILE.DAT','FXFILE.VAX',80,'A',32400,'X','S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZPUTF (LOCAL,REMOTE,LRECL,LFORM,RRECL,RFORM,CHOPT,IRC)
This routine sends a ZEBRA FZ file to the remote system. If the remote file format or record length are not given, they default to the same values as on the local system. The format may be 'A', for FZ exchange, ASCII mapping, 'X', for FZ exchange, binary, or ' ' for FZ native. For ASCII files the record length defaults to 80 bytes. For binary exchange format files, the record length is taken from the file itself. For native format files the record length must be specified. For binary exchange format files, a 'D' may also be specified, indicating that the file should be processed using direct-access I/O. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZPUTF routine
*
* Transfer the local exchange format file to a remote native
* format file
*
CALL XZPUTF('FZFILE.DATA','=',32400,'X',32400,' ','S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZGETR (LOCAL,REMOTE,CHOPT,IRC)
This routine gets a ZEBRA RZ file from the remote system. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZGETR routine
CALL XZGETR('=','HBOOK.CMZ','S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZPUTR (LOCAL,REMOTE,CHOPT,IRC)
This routine sends a ZEBRA RZ file to the remote system. ZEBRA RZ files include HBOOK histogram files, ntuples, CMZ files etc. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZPUTR routine
CALL XZPUTR('FPACK.CMZ','=,'S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZGETX (LOCAL,REMOTE,LRECL,CHOPT,IRC)
This routine retrieves an exchange format file from the remote system. An exchange format file is one with fixed length records and no control words. The XZGETX routine uses Fortran sequential I/O on all systems except Unix, where files are processed with direct access I/O to avoid the control words that are written at the beginning and end of each record with binary sequential Fortran I/O. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZGETX routine
CALL XZGETX('FXFILE.DAT','FXFILE.VAX',32400,'S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'
CALL XZPUTX (LOCAL,REMOTE,LRECL,CHOPT,IRC)
This routine sends an exchange format file to the remote system. An exchange format file is one with fixed length records and no control words. The XZPUTX routine uses Fortran sequential I/O on all systems except Unix, where files are processed with direct access I/O to avoid the control words that are written at the beginning and end of each record with binary sequential Fortran I/O. If option 'S' is specified, statistics on the file transfer are printed.
Example of using the XZPUTX routine
CALL XZPUTX('FXFILE.DATA','=',32400,'S',IRC)
IF(IRC.NE.0) PRINT *,'File transfer failed'