317 lines
15 KiB
HTML
317 lines
15 KiB
HTML
|
|
||
|
<!doctype html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||
|
<html>
|
||
|
<head><META http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||
|
<title>Generate Command Documentation (GENCMDDOC)</title>
|
||
|
<link rel="stylesheet" type="text/css" href="../rzahg/ic.css">
|
||
|
</head>
|
||
|
<body bgcolor="white">
|
||
|
<script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
|
||
|
<a name="GENCMDDOC.Top_Of_Page"></a>
|
||
|
<h2>Generate Command Documentation (GENCMDDOC)</h2>
|
||
|
<table width="100%">
|
||
|
<tr>
|
||
|
<td valign="top" align="left"><b>Where allowed to run: </b>All environments (*ALL)<br>
|
||
|
<b>Threadsafe: </b>No
|
||
|
</td>
|
||
|
<td valign="top" align="right">
|
||
|
<a href="#GENCMDDOC.PARAMETERS.TABLE">Parameters</a><br>
|
||
|
<a href="#GENCMDDOC.COMMAND.EXAMPLES">Examples</a><br>
|
||
|
<a href="#GENCMDDOC.ERROR.MESSAGES">Error messages</a></td>
|
||
|
</tr>
|
||
|
</table>
|
||
|
|
||
|
<div> <a name="GENCMDDOC"></a>
|
||
|
<p>The Generate Command Documentation (GENCMDDOC) command generates an output file which contains documentation for a Control Language (CL) command. The generated file will be one of the following:
|
||
|
</p>
|
||
|
<ul>
|
||
|
<li>If *HTML is specified for the <b>Generation options (GENOPT)</b> parameter, the file will contain HyperText Markup Language (HTML) source. The generated file can be displayed using a standard internet browser, and conforms to HTML 4.0 specifications. The information used to generate the file is retrieved from the specified command (*CMD) object and any command help panel group (*PNLGRP) objects associated with the command.
|
||
|
</li>
|
||
|
<li>If *UIM is specified for the GENOPT parameter, the file will contain User Interface Manager (UIM) source. The generated source is an outline for the online command help for the command. The information used to generate the file is retrieved only from the specified command (*CMD) object. This option is intended to simplify the task of writing online help for CL commands.
|
||
|
<p>See the CL information in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter, for more information on writing command documentation using UIM.
|
||
|
</p>
|
||
|
</li>
|
||
|
</ul>
|
||
|
<p><b>Restrictions:</b>
|
||
|
</p>
|
||
|
<ul>
|
||
|
<li>You must have use (*USE) authority to the specified command and execute (*EXECUTE) authority for the library that the command is in. If a generic name or *ALL is specified for the command name, no output file is generated for any commands that you do not have *USE authority for.
|
||
|
</li>
|
||
|
<li>For each associated panel group that contains command help information for the specified command, you must have *USE authority to the panel group and *EXECUTE authority for the library that the panel group is in.
|
||
|
</li>
|
||
|
<li>You must have execute (*X) authority to the directories in the path for the generated file, and write and execute (*WX) authorities to the parent directory of the generated file.
|
||
|
</li>
|
||
|
<li>If the output file does not exist, the public authority will be determined by the <b>os400.file.create.auth</b> Java property value. If this Java property has not been set, the public authority for a created stream file is set to *RW.
|
||
|
</li>
|
||
|
<li>If the output file already exists, you must have write (*W) authority to the file and *YES must be specified for the <b>Replace file (REPLACE)</b> parameter.
|
||
|
</li>
|
||
|
<li>This command does not support proxy CL commands.
|
||
|
</li>
|
||
|
</ul>
|
||
|
</div>
|
||
|
<table width="100%">
|
||
|
<tr><td align="right"><a href="#GENCMDDOC.Top_Of_Page">Top</a></td></tr>
|
||
|
</table>
|
||
|
<hr size="2" width="100%">
|
||
|
|
||
|
<div>
|
||
|
<h3><a name="GENCMDDOC.PARAMETERS.TABLE">Parameters</a></h3>
|
||
|
<table border="1" cellpadding="4" cellspacing="0">
|
||
|
<!-- col1="10" col2="15" col3="30" col4="10" -->
|
||
|
<tr>
|
||
|
<th bgcolor="aqua" valign="bottom" align="left">Keyword</th>
|
||
|
<th bgcolor="aqua" valign="bottom" align="left">Description</th>
|
||
|
<th bgcolor="aqua" valign="bottom" align="left">Choices</th>
|
||
|
<th bgcolor="aqua" valign="bottom" align="left">Notes</th>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td valign="top" rowspan="3"><a href="#GENCMDDOC.CMD"><b>CMD</b></a></td>
|
||
|
<td valign="top">Command</td>
|
||
|
<td valign="top"><i>Qualified object name</i></td>
|
||
|
<td valign="top" rowspan="3">Required, Positional 1</td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td valign="top">Qualifier 1: Command</td>
|
||
|
<td valign="top"><i>Generic name, name</i>, *ALL</td>
|
||
|
</tr><tr>
|
||
|
<td valign="top">Qualifier 2: Library</td>
|
||
|
<td valign="top"><i>Name</i>, <b><u>*LIBL</u></b>, *CURLIB</td>
|
||
|
</tr><tr>
|
||
|
<td valign="top"><a href="#GENCMDDOC.TODIR"><b>TODIR</b></a></td>
|
||
|
<td valign="top">To directory</td>
|
||
|
<td valign="top"><i>Path name</i>, <b><u>'.'</u></b></td>
|
||
|
<td valign="top">Optional</td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td valign="top"><a href="#GENCMDDOC.TOSTMF"><b>TOSTMF</b></a></td>
|
||
|
<td valign="top">To stream file</td>
|
||
|
<td valign="top"><i>Character value</i>, <b><u>*CMD</u></b></td>
|
||
|
<td valign="top">Optional</td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td valign="top"><a href="#GENCMDDOC.REPLACE"><b>REPLACE</b></a></td>
|
||
|
<td valign="top">Replace file</td>
|
||
|
<td valign="top"><b><u>*YES</u></b>, *NO</td>
|
||
|
<td valign="top">Optional</td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td valign="top"><a href="#GENCMDDOC.GENOPT"><b>GENOPT</b></a></td>
|
||
|
<td valign="top">Generation options</td>
|
||
|
<td valign="top">Values (up to 3 repetitions): *HTML, *UIM, *NOSHOWCHOICEPGMVAL, *SHOWCHOICEPGMVAL, *NOSERVICE, *SERVICE</td>
|
||
|
<td valign="top">Optional</td>
|
||
|
</tr>
|
||
|
</table>
|
||
|
|
||
|
<table width="100%">
|
||
|
<tr><td align="right"><a href="#GENCMDDOC.Top_Of_Page">Top</a></td></tr>
|
||
|
</table>
|
||
|
</div>
|
||
|
<div> <a name="GENCMDDOC.CMD"></a>
|
||
|
<h3>Command (CMD)</h3>
|
||
|
<p>Specifies the command for which a documentation output file is to be generated.
|
||
|
</p>
|
||
|
<p>
|
||
|
<b>Note: </b>If a generic command name or *ALL is specified for the command name, *LIBL is not allowed as the library name qualifier and the value for the <b>To stream file (TOSTMF)</b> parameter must be *CMD.
|
||
|
</p>
|
||
|
<p>This is a required parameter.
|
||
|
</p>
|
||
|
<p><b>Qualifier 1: Command</b>
|
||
|
</p>
|
||
|
<dl>
|
||
|
<dt><b>*ALL</b></dt>
|
||
|
<dd>Documentation files for all of the commands in the specified library are to be generated.
|
||
|
</dd>
|
||
|
<dt><b><i>generic-name</i></b></dt>
|
||
|
<dd>Specify the generic name of the commands for which documentation files are to be generated. A generic name is a character string that contains one or more characters followed by an asterisk (*). If a generic name is specified, all commands that have names with the same prefix as the generic command name will have documentation files generated.
|
||
|
</dd>
|
||
|
<dt><b><i>name</i></b></dt>
|
||
|
<dd>Specify the name of the command for which you want to generate a documentation output file.
|
||
|
</dd>
|
||
|
</dl>
|
||
|
<p><b>Qualifier 2: Library</b>
|
||
|
</p>
|
||
|
<dl>
|
||
|
<dt><b><u>*LIBL</u></b></dt>
|
||
|
<dd>All libraries in the library list for the current thread are searched until the first match is found.
|
||
|
</dd>
|
||
|
</dl>
|
||
|
<dl>
|
||
|
<dt><b>*CURLIB</b></dt>
|
||
|
<dd>The current library for the job is used to locate the command. If no library is specified as the current library for the job, QGPL is used.
|
||
|
</dd>
|
||
|
<dt><b><i>name</i></b></dt>
|
||
|
<dd>Specify the name of the library where the command is located.
|
||
|
</dd>
|
||
|
</dl>
|
||
|
</div>
|
||
|
<table width="100%">
|
||
|
<tr><td align="right"><a href="#GENCMDDOC.Top_Of_Page">Top</a></td></tr>
|
||
|
</table>
|
||
|
<div> <a name="GENCMDDOC.TODIR"></a>
|
||
|
<h3>To directory (TODIR)</h3>
|
||
|
<p>Specifies the directory in which the generated command documentation file will be stored. The file name to be used within this directory is specified by the <b>To stream file (TOSTMF)</b> parameter.
|
||
|
</p>
|
||
|
<dl>
|
||
|
<dt><b><u>'.'</u></b></dt>
|
||
|
<dd>The output file will be stored in the current working directory.
|
||
|
</dd>
|
||
|
<dt><b><i>path-name</i></b></dt>
|
||
|
<dd>Specify the path name for the directory where you want the generated output file stored.
|
||
|
</dd>
|
||
|
</dl>
|
||
|
</div>
|
||
|
<table width="100%">
|
||
|
<tr><td align="right"><a href="#GENCMDDOC.Top_Of_Page">Top</a></td></tr>
|
||
|
</table>
|
||
|
<div> <a name="GENCMDDOC.TOSTMF"></a>
|
||
|
<h3>To stream file (TOSTMF)</h3>
|
||
|
<p>Specifies the target stream file to be used to store the generated command documentation file. The specified file will be located using the directory path specified for the <b>To directory (TODIR)</b> parameter.
|
||
|
</p>
|
||
|
<p>
|
||
|
<b>Note: </b>If a generic command name or *ALL is specified for the <b>Command (CMD)</b> parameter, the value specified or defaulted for this parameter must be *CMD.
|
||
|
</p>
|
||
|
<dl>
|
||
|
<dt><b><u>*CMD</u></b></dt>
|
||
|
<dd>If the TODIR parameter specifies that the target is in the /QSYS.LIB file system, the generated file name will be same as the command name.
|
||
|
<p>Otherwise, the generated file name depends on whether *HTML or *UIM is specified for the <b>Generation options (GENOPT)</b> parameter. If *HTML is specified, the generated file name will be <b>libname_cmdname.html</b>, where <b>cmdname</b> is the command name and <b>libname</b> is the name of the library where the command is located. If *UIM is specified, the generated file name will be <b>libname_cmdname.uim</b>
|
||
|
</p>
|
||
|
</dd>
|
||
|
<dt><b><i>character-value</i></b></dt>
|
||
|
<dd>Specify the name to be used for the generated command documentation file.
|
||
|
</dd>
|
||
|
</dl>
|
||
|
</div>
|
||
|
<table width="100%">
|
||
|
<tr><td align="right"><a href="#GENCMDDOC.Top_Of_Page">Top</a></td></tr>
|
||
|
</table>
|
||
|
<div> <a name="GENCMDDOC.REPLACE"></a>
|
||
|
<h3>Replace file (REPLACE)</h3>
|
||
|
<p>Specifies whether or not to replace an existing file in the target directory (TODIR parameter) by the file name specified or generated (TOSTMF parameter).
|
||
|
</p>
|
||
|
<dl>
|
||
|
<dt><b><u>*YES</u></b></dt>
|
||
|
<dd>If a file already exists by the name specified or implied, the file contents will be replaced with the generated command documentation file.
|
||
|
</dd>
|
||
|
<dt><b>*NO</b></dt>
|
||
|
<dd>If a file already exists by the name specified or implied, an error message is sent and no command documentation file is generated. If no file by the same name exists in the target directory, the file will be created and no error message sent.
|
||
|
</dd>
|
||
|
</dl>
|
||
|
</div>
|
||
|
<table width="100%">
|
||
|
<tr><td align="right"><a href="#GENCMDDOC.Top_Of_Page">Top</a></td></tr>
|
||
|
</table>
|
||
|
<div> <a name="GENCMDDOC.GENOPT"></a>
|
||
|
<h3>Generation options (GENOPT)</h3>
|
||
|
<p>Specifies options to control the command information to be generated. Multiple option values can be specified in any order on this parameter. If neither or both of the values in each group are specified, the underlined value will be used.
|
||
|
</p>
|
||
|
<p>
|
||
|
<b>Note: </b>The underlined values for this parameter are <i>similar</i> to, but not <i>actually</i> default values, and therefore, cannot be changed with the Change Command Default (CHGCMDDFT) command.
|
||
|
</p>
|
||
|
<p><b>Generated Source Option</b>
|
||
|
</p>
|
||
|
<dl>
|
||
|
<dt><b><u>*HTML</u></b></dt>
|
||
|
<dd>The generated file will contain HyperText Markup Language (HTML) source. The generated file can be displayed using a standard internet browser, and conforms to HTML 4.0 specifications. The information used to generate the file is retrieved from the specified command (*CMD) object and any command help panel group (*PNLGRP) objects associated with the command.
|
||
|
</dd>
|
||
|
<dt><b>*UIM</b></dt>
|
||
|
<dd>The generated file will contain User Interface Manager (UIM) source. The generated source is an outline for the online command help for the command. The information used to generate the file is retrieved only from the specified command (*CMD) object. This option is intended to simplify the task of writing online help for CL commands. After editing the generated file to add descriptive text for the command and storing the source in a source file member, this UIM source can be used as input to the Create Panel Group (CRTPNLGRP) command to create a command help panel group for the command.
|
||
|
<p>See the CL information in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter, for more information on writing command documentation using UIM.
|
||
|
</p>
|
||
|
</dd>
|
||
|
</dl>
|
||
|
<p><b>Choice Program Values Option</b>
|
||
|
</p>
|
||
|
<dl>
|
||
|
<dt><b><u>*NOSHOWCHOICEPGMVAL</u></b></dt>
|
||
|
<dd>For command parameters that have an associated <i>choices program</i>, do not show the values which would be returned from the choices program in the generated parameter summary table. Choices program values can vary from system to system. Not showing the choices program values gives you just the parameter values defined in the command object.
|
||
|
</dd>
|
||
|
<dt><b>*SHOWCHOICEPGMVAL</b></dt>
|
||
|
<dd>For command parameters that have an associated <i>choices program</i>, show the values returned from calling the choices program in the generated parameter summary table. Showing the choice program values gives you the same parameter values that you would see if prompting the command on this system.
|
||
|
</dd>
|
||
|
</dl>
|
||
|
<p><b>Service Option</b>
|
||
|
</p>
|
||
|
<dl>
|
||
|
<dt><b><u>*NOSERVICE</u></b></dt>
|
||
|
<dd>No extra trace or dump information is generated.
|
||
|
</dd>
|
||
|
<dt><b>*SERVICE</b></dt>
|
||
|
<dd>This option is intended to be used if the command is not working and you are told by your software service provider to write an APAR for the problem. Specifying this option will cause additional trace and dump information to be generated. Send this additional generated information with the APAR.
|
||
|
</dd>
|
||
|
</dl>
|
||
|
</div>
|
||
|
<table width="100%">
|
||
|
<tr><td align="right"><a href="#GENCMDDOC.Top_Of_Page">Top</a></td></tr>
|
||
|
</table>
|
||
|
<hr size="2" width="100%">
|
||
|
<div><h3><a name="GENCMDDOC.COMMAND.EXAMPLES">Examples</a> </h3>
|
||
|
<p><b>Example 1: Generating HTML Documentation for an i5/OS Command</b>
|
||
|
</p>
|
||
|
<p>
|
||
|
<pre>
|
||
|
GENCMDDOC CMD(CRTUSRPRF)
|
||
|
</pre>
|
||
|
</p>
|
||
|
<p>This command generates a documentation file for the CRTUSRPRF command. The command will be located using the library list for the current thread. The generated stream file will be stored in the current working directory of the job. Assuming the command is found in library QSYS, the generated file name will be <b>QSYS_CRTUSRPRF.html</b>. If a file by that name already exists in the target directory, it will be replaced by the generated file.
|
||
|
</p>
|
||
|
<p><b>Example 2: Generating UIM Documentation for User Command</b>
|
||
|
</p>
|
||
|
<p>
|
||
|
<pre>
|
||
|
GENCMDDOC CMD(MYLIB/MYCMD)
|
||
|
TODIR('/QSYS.LIB/MYLIB.LIB/QPNLSRC.FILE')
|
||
|
TOSTMF('MYCMD.MBR') REPLACE(*NO) GENOPT(*UIM)
|
||
|
</pre>
|
||
|
</p>
|
||
|
<p>This command generates a documentation file for command MYCMD which is located in library MYLIB. The generated file will be stored in file QPNLSRC in library MYLIB with a member name of MYCMD. If a member already exists in the target file with this name, an error message will be sent and no documentation file will be generated.
|
||
|
</p>
|
||
|
</div>
|
||
|
<table width="100%">
|
||
|
<tr><td align="right"><a href="#GENCMDDOC.Top_Of_Page">Top</a></td></tr>
|
||
|
</table>
|
||
|
<hr size="2" width="100%">
|
||
|
<div><h3><a name="GENCMDDOC.ERROR.MESSAGES">Error messages</a> </h3>
|
||
|
<p><b><u>*ESCAPE Messages</u></b>
|
||
|
</p>
|
||
|
<dl>
|
||
|
<dt><b>CPF6E74</b></dt>
|
||
|
<dd>&1 command documents failed; &2 command documents created successfully.
|
||
|
</dd>
|
||
|
<dt><b>CPF6E75</b></dt>
|
||
|
<dd>Error detected on the CMD parameter.
|
||
|
</dd>
|
||
|
<dt><b>CPF9801</b></dt>
|
||
|
<dd>Object &2 in library &3 not found.
|
||
|
</dd>
|
||
|
<dt><b>CPF9802</b></dt>
|
||
|
<dd>Not authorized to object &2 in &3.
|
||
|
</dd>
|
||
|
<dt><b>CPF9810</b></dt>
|
||
|
<dd>Library &1 not found.
|
||
|
</dd>
|
||
|
<dt><b>CPF9820</b></dt>
|
||
|
<dd>Not authorized to use library &1.
|
||
|
</dd>
|
||
|
<dt><b>CPF9899</b></dt>
|
||
|
<dd>Error occurred during processing of command.
|
||
|
</dd>
|
||
|
<dt><b>CPFA09C</b></dt>
|
||
|
<dd>Not authorized to object. Object is &1.
|
||
|
</dd>
|
||
|
<dt><b>CPFA0A0</b></dt>
|
||
|
<dd>Object already exists. Object is &1.
|
||
|
</dd>
|
||
|
<dt><b>CPFA0A9</b></dt>
|
||
|
<dd>Object not found. Object is &1.
|
||
|
</dd>
|
||
|
<dt><b>CPF6E67</b></dt>
|
||
|
<dd>Command documentation not generated for proxy command &1 in &2.
|
||
|
</dd>
|
||
|
</dl>
|
||
|
</div>
|
||
|
<table width="100%">
|
||
|
<tr><td align="right"><a href="#GENCMDDOC.Top_Of_Page">Top</a></td></tr>
|
||
|
</table>
|
||
|
</body>
|
||
|
</html>
|