Previous Topic Next topic Print topic


The Parameter Block

The code below is from the copybook MFUSRPRM.CPY. It describes the parameter block that is passed to the user module. The copybook is located in the $COBDIR/cpylib directory. See the comments in the code for descriptions of each field:

      *===============================================================
      *   Copyright (C) 2007-2015 Micro Focus Limited.
      *   All rights reserved.
      *===============================================================

      *****************************************************************
      * Data items related to the module specified by MFFTP_USR_PGM   *
      *                                                               *
      * (tag)-usr-ftp-function-init                               *
      *   Function to be performed set as follows:                    *
      *   if (tag)-usr-ftp-function-init                          *
      *      used to cause the module to be loaded to ensure it exists*
      *   if (tag)-usr-ftp-function-call                          *
      *      normal call                                              *
      * (tag)-usr-ftp-return-code                                 *
      *   Indicate result of the call                                 *
      *   set (tag)-usr-ftp-ok true on an INIT call or if a       *
      *       normal call was deemed successful. The calling routine  *
      *       will scan the output to determine if the call to the    *
      *       FTP client was successful                               *
      *   set (tag)-usr-ftp-fail true if this module determines   *
      *       that there was a problem and that the calling module    *
      *       should not check the output                             *
      * (tag)-usr-ftp-ip-file-data.                               *
      *   Contains the length and fully qualified name of the file    *
      *   holding the normalised FTP control statements. This may be  *
      *   used directly or read to created an edited version as input *
      *   to the FTP client                                           *
      *    (tag)-usr-ftp-ip-name-len                              *
      *      actual length of the data in (tag)-usr-ftp-ip-name   *
      *    (tag)-usr-ftp-ip-name                                  *
      *      actual file name of the file holding the normalised FTP  *
      *      control statements                                       *
      * (tag)-usr-ftp-op-file-data.                               *
      *   Contains the length and fully qualified name of the file    *
      *   to hold the output from the FTP client that will be checked *
      *   (if appropriate) and printed by the calling routine. This   *
      *   may be the actual output from the FTP client or this        *
      *   routine may write an edited version here, for example to    *
      *   remove sensitive information.                               *
      *    (tag)-usr-ftp-op-name-len                              *
      *      actual length of the data in (tag)-usr-ftp-op-name   *
      *    (tag)-usr-ftp-op-name                                  *
      *      actual file name of the file to hold the output from the *
      *      FTP client (actual or edited)                            *
      * (tag)-usr-ftp-tmp-file-data.                              *
      *   Contains the length and the name of a directory that may be *
      *   used as a work are to hold temporary files.                 *
      *    (tag)-usr-ftp-tmp-name-len                             *
      *      actual length of the data in (tag)-usr-ftp-tmp-nam   *
      *    (tag)-usr-ftp-tmp-name                                 *
      *      The name of a directory that may be used to create       *
      *      temporary files, for example an edited input file or the *
      *      output from the FTP client before it is edited           *
      *****************************************************************
      *                                                               *
       01  (tag)-mfftp-usr-ftp-parm.
         05  (tag)-usr-ftp-function                pic x(1).
           88  (tag)-usr-ftp-function-init         value '0'.
           88  (tag)-usr-ftp-function-call         value '1'.
         05  (tag)-usr-ftp-return-code             pic x(1).
           88  (tag)-usr-ftp-ok                    value '0'.
           88  (tag)-usr-ftp-fail                  value '1'.
         05  (tag)-usr-ftp-msg1                    pic x(64).
         05  (tag)-usr-ftp-msg2                    pic x(64).
         05  (tag)-usr-ftp-pass-ip-data.
           10  (tag)-usr-ftp-pass-ip-fname-len     pic 9(3).
           10  (tag)-usr-ftp-pass-ip-fname         pic x(512).
         05  (tag)-usr-ftp-pass-op-data.
           10  (tag)-usr-ftp-pass-op-fname-len     pic 9(3).
           10  (tag)-usr-ftp-pass-op-fname         pic x(512).
         05  (tag)-usr-ftp-user-ip-data.
           10  (tag)-usr-ftp-user-ip-fname-len     pic 9(3).
           10  (tag)-usr-ftp-user-ip-fname         pic x(512).
         05  (tag)-usr-ftp-user-op-data.
           10  (tag)-usr-ftp-user-op-fname-len     pic 9(3).
           10  (tag)-usr-ftp-user-op-fname         pic x(512).
         05  (tag)-usr-ftp-temp-data.
           10  (tag)-usr-ftp-temp-fname-len        pic 9(3).
           10  (tag)-usr-ftp-temp-fname            pic x(512).
Previous Topic Next topic Print topic