ibm-information-center/dist/eclipse/plugins/i5OS.ic.apis_5.4.0.1/QTERTVMV.htm

713 lines
23 KiB
HTML
Raw Permalink Normal View History

2024-04-02 14:02:31 +00:00
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Copyright" content="Copyright (c) 2006 by IBM Corporation">
<title>Retrieve Module Views (QteRetrieveModuleViews) API</title>
<!-- Begin Header Records ========================================== -->
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<!-- DEBUG1 SCRIPT A converted by B2H R4.1 (346) (CMS) by V2KEA304 -->
<!-- at RCHVMW2 on 29 Jan 1999 at 16:05:09 -->
<!-- Change History: -->
<!-- YYMMDD USERID Change description -->
<!--File Edited November 2001 -->
<!--End Header Records -->
<link rel="stylesheet" type="text/css" href="../rzahg/ic.css">
</head>
<body>
<a name="top_Of_Page"></a>
<!-- Java sync-link -->
<script language="Javascript" src="../rzahg/synch.js" type="text/javascript">
</script>
<h2>Retrieve Module Views (QteRetrieveModuleViews) API</h2>
<div class="box" style="width: 75%;">
<br>
&nbsp;&nbsp;Required Parameter Group:<br>
<!-- iddvc RMBR -->
<br>
<table width="100%">
<tr>
<td align="center" valign="top" width="10%">1</td>
<td align="left" valign="top" width="50%">Receiver variable</td>
<td align="left" valign="top" width="15%">Output</td>
<td align="left" valign="top" width="25%">Char(*)</td>
</tr>
<tr>
<td align="center" valign="top">2</td>
<td align="left" valign="top">Length of receiver variable</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Binary(4)</td>
</tr>
<tr>
<td align="center" valign="top">3</td>
<td align="left" valign="top">Format name</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Char(8)</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="left" valign="top">Qualified program name</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Char(20) or Char(*)</td>
</tr>
<tr>
<td align="center" valign="top">5</td>
<td align="left" valign="top">Program type</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Char(10)</td>
</tr>
<tr>
<td align="center" valign="top">6</td>
<td align="left" valign="top">Module name</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Char(10) or Binary(4)</td>
</tr>
<tr>
<td align="center" valign="top">7</td>
<td align="left" valign="top">Returned library name</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Char(10) or Char(*)</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="left" valign="top">Error code</td>
<td align="left" valign="top">I/O</td>
<td align="left" valign="top">Char(*)</td>
</tr>
</table>
<br>
&nbsp;&nbsp;Service Program: QTEDBGS<br>
<!-- iddvc RMBR -->
<br>
&nbsp;&nbsp;Threadsafe: No<br>
<!-- iddvc RMBR -->
<br>
</div>
<p>The Retrieve Module Views (QteRetrieveModuleViews) API is used to return a list of modules and views associated with a specified program to the caller of the API. The list includes all of the following:</p>
<ul>
<li>All modules bound to the program that can be debugged<br><br></li>
<li>Every view (by number and type) that was created by the compiler when the module object was created<br><br></li>
<li>Views created by the OPM RPG, OPM COBOL, and OPM CL compilers using the *SRCDBG and *LSTDBG options<br><br></li>
<li>Views created by the JAVA language support in i5/OS</li>
</ul>
<p>If you specify a module name, a list of views for that module is returned. If you specify *ALL for the module name, the list includes all modules for a given program.</p>
<p>The module name parameter must be specified as either *ALL or blanks for OPM programs. The statement view and a source view (or the statement view and a listing view) are always returned. The module name field is returned as blanks.</p>
<p>This API also supports JAVA class file debug views. In this case the program type parameter must be *CLASS and the qualified program name parameter must be a null-terminated JAVA class file name. The class path name of the file that contains the JAVA class file is returned in the returned library name parameter. For JAVA, the module name parameter must be specified as a binary field that contains the number of bytes provided in the returned library name field for JAVA class path name information.</p>
<p>Information returned by the Retrieve Module Views API is used by the calling program as input parameters to the Register Debug View API. Every module returned has at least one view associated with it. This is the statement view. It can be assumed that any additional views returned have text associated with them, and source debug can be done on these modules.</p>
<br>
<h3>Authorities</h3>
<p>The authorities required are dependent on the program type parameter. If the program type is *PGM or *SRVPGM, the authorities are as follows:</p>
<dl>
<dt><em>Program Authority</em></dt>
<dd>Either *SERVICE and *USE, or *CHANGE<br><br></dd>
<dt><em>Library Authority</em></dt>
<dd>*USE
<p>If the program type is *CLASS, the authorities are as follows:</p></dd>
<dt><em>Class File Authority</em></dt>
<dd>*R</dd>
</dl>
<br>
<h3>Required Parameter Group</h3>
<dl>
<dt><strong>Receiver variable</strong></dt>
<dd>OUTPUT; CHAR(*)
<p>A variable that is to receive the information requested. You can specify the size of this area to be smaller than that needed to hold the information. In this case, only part of the information is returned. However, the number of bytes that the API needs to return all of the information is still returned.</p>
</dd>
<dt><strong>Length of receiver variable</strong></dt>
<dd>INPUT; BINARY(4)
<p>The length of the receiver variable. The minimum length is 8 bytes.</p>
<p>It is suggested that a length of 8 be passed to the API, which fills in the first two fields of the receiver variable. One of the fields, bytes available, indicates how much space must be provided. This space can then be obtained, and a second call to the API can be made.</p>
</dd>
<dt><strong>Format name</strong></dt>
<dd>INPUT; CHAR(8)
<p>The content and format of the module view information that is returned. The only valid value for this parameter is:</p>
<table cellpadding="3">
<!-- cols="15 85" -->
<tr>
<td valign="top"><em>VEWL0100</em></td>
<td valign="top">Module view information. For more information, see <a href="#HDRVEWL">VEWL0100 Format</a>.</td>
</tr>
</table>
<br>
</dd>
<dt><strong>Qualified program name</strong></dt>
<dd>INPUT; CHAR(20) or CHAR(*)
<p>The format of this parameter is dependent on the program type parameter. If the program type is *PGM or *SRVPGM, the format of this parameter is as follows:</p>
<ul>
<li>The name of a program about which module and view information is listed.<br><br></li>
<li>The first 10 characters contain the program name.<br><br></li>
<li>The second 10 characters contain the name of the library where the program can be located.<br><br></li>
<li>Both entries must be left-justified.</li>
</ul>
<p>The following special values may be used for the library name:</p>
<table cellpadding="3">
<!-- cols="15 85" -->
<tr>
<td valign="top"><em>*CURLIB</em></td>
<td valign="top">The job's current library.</td>
</tr>
<tr>
<td valign="top"><em>*LIBL</em></td>
<td valign="top">The library list.</td>
</tr>
</table>
<p>If the program type is *CLASS, the format of this parameter is as follows:</p>
<blockquote>
<p>The null-terminated class file name of the JAVA class.</p>
</blockquote>
</dd>
<dt><strong>Program type</strong></dt>
<dd>INPUT; CHAR(10)
<p>The type of program for which a view is to be registered. This is the object type of the program object. The allowable values are:</p>
<table cellpadding="3">
<!-- cols="15 85" -->
<tr>
<td valign="top"><em>*PGM</em></td>
<td valign="top">ILE or OPM program</td>
</tr>
<tr>
<td valign="top"><em>*SRVPGM</em></td>
<td valign="top">ILE service program</td>
</tr>
<tr>
<td valign="top"><em>*CLASS</em></td>
<td valign="top">JAVA class file name</td>
</tr>
</table>
<br>
</dd>
<dt><strong>Module name</strong></dt>
<dd>INPUT; CHAR(10) or BINARY(4)
<p>The format of this parameter is dependent on the program type parameter.If the program type is *PGM or *SRVPGM, the format of this parameter is as follows:</p>
<ul>
<li>A module name or *ALL (*ALL refers to all modules in the program).<br><br></li>
<li>The module name parameter must be specified as either *ALL or blanks for OPM programs.</li>
</ul>
<p>If the program type is *CLASS, the format of this parameter is as follows:</p>
<ul>
<li>A 4-byte binary field. This field contains the number of bytes provided in the returned library name parameter for returning JAVA class path name information.<br><br></li>
<li>The value specified in this parameter must be at least 8 bytes.</li>
</ul>
<br>
</dd>
<dt><strong>Returned library name</strong></dt>
<dd>OUTPUT; CHAR(10) or CHAR(*)
<p>The format of this parameter is dependent on the program type parameter.If the program type is *PGM or *SRVPGM, the format of this parameter is OUTPUT CHAR(10) as follows:</p>
<ul>
<li>The library where the program was found. This is useful when *LIBL or *CURLIB is specified for the program library.</li>
</ul>
<p>If the program type is *CLASS, the format of this parameter is OUTPUT CHAR(*) as follows:</p>
<ul>
<li>Class path name information for the requested class file. For more information, see <a href="#HDRJVCLP">Format of JAVA Returned Library Name Parameter</a>.</li>
</ul>
<br>
</dd>
<dt><strong>Error code</strong></dt>
<dd>I/O; CHAR(*)
<p>The structure in which to return error information. For the format of the structure, see <a href="../apiref/error.htm#hdrerrcod">Error Code Parameter</a>.</p>
</dd>
</dl>
<br>
<h3><a name="HDRVEWL">VEWL0100 Format</a></h3>
<p>The following table shows the format of the receiver variable for the VEWL0100 format.For more information on the fields, see <a href="#HDRVEW">Field Descriptions</a>.</p>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Bytes returned</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Bytes available</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Number of elements</td>
</tr>
<tr>
<td align="left" valign="top" colspan="4"><strong>Note:</strong> The following fields repeat once for each element.</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Module name</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">View type</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">CHAR(20)</td>
<td align="left" valign="top">Compiler ID</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Main indicator</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">CHAR(13)</td>
<td align="left" valign="top">View timestamp</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">CHAR(50)</td>
<td align="left" valign="top">View description</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">CHAR(3)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">View number</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Number of views</td>
</tr>
</table>
<p>All views for a module are listed together in the receiver variable. The number of views field contains the total number of views for the module. The views are contiguous.</p>
<br>
<h3><a name="HDRVEW">Field Descriptions</a></h3>
<p><strong>Bytes available.</strong> The number of bytes of data available to be returned to the user.</p>
<p><strong>Bytes returned.</strong> The number of bytes of data returned to the user.</p>
<p><strong>Compiler ID.</strong> The ID of the compiler that generated this view. For unique identification the first 4 bytes are used as follows:</p>
<table cellpadding="3">
<!-- cols="15 85" -->
<tr>
<td valign="top"><em>x'00050000'</em></td>
<td valign="top">ILE C</td>
</tr>
<tr>
<td valign="top"><em>x'00050001'</em></td>
<td valign="top">CSET C++ cooperative compiler</td>
</tr>
<tr>
<td valign="top"><em>x'00060000'</em></td>
<td valign="top">ILE CL</td>
</tr>
<tr>
<td valign="top"><em>x'00060001'</em></td>
<td valign="top">OPM CL</td>
</tr>
<tr>
<td valign="top"><em>x'00070000'</em></td>
<td valign="top">OPM COBOL</td>
</tr>
<tr>
<td valign="top"><em>x'00070001'</em></td>
<td valign="top">ILE COBOL</td>
</tr>
<tr>
<td valign="top"><em>x'00170001'</em></td>
<td valign="top">OPM RPG</td>
</tr>
<tr>
<td valign="top"><em>x'00170002'</em></td>
<td valign="top">ILE RPG</td>
</tr>
<tr>
<td valign="top"><em>x'001D0000'</em></td>
<td valign="top">JAVA</td>
</tr>
</table>
<p><strong>Main indicator.</strong> Whether the module is a main module (entry point) for the program. The main indicator field can have one of the following values:</p>
<table cellpadding="3">
<!-- cols="15 85" -->
<tr>
<td valign="top"><em>*MAIN</em></td>
<td valign="top">Module is a main module</td>
</tr>
<tr>
<td valign="top"><em>*NOMAIN</em></td>
<td valign="top">Module is not a main module</td>
</tr>
</table>
<p>There is at most one main module per program. Service programs contain no main entry point. *MAIN is always returned for OPM programs. For JAVA class files *MAIN is returned if the class file has a main procedure. Otherwise, *NOMAIN is returned for JAVA.</p>
<p><strong>Module name.</strong> The name of the module for this list entry. For OPM programs and JAVA class files, the module name is returned as blanks.</p>
<p><strong>Number of elements.</strong> The number of elements returned in the receiver variable. Each element has the same format, and it is repeated in the receiver variable. If the number of elements is zero and the receiver variable has room for at least one element, the program has no views in the module requested. If the module requested is *ALL, zero elements indicate the program cannot be debugged. For OPM programs, a CPF9584 error code is returned, instead of a zero number of elements value, if the program cannot be debugged. For class files, a CPF9599 error code is returned, instead of a zero number of elements value, if the program cannot be debugged.</p>
<p><strong>Number of views.</strong> The number of views in this module listed in the receiver variable</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>View description.</strong> A character string that describes the view.</p>
<p><strong>View number.</strong> A number that identifies a view within a module. Each view has a unique view number, which is used when you specify a specific view to register using the Register Debug View API.</p>
<p><strong>View timestamp.</strong> The timestamp indicating when the view was created. It has the format of the American National Standard timestamp.</p>
<p><strong>View type.</strong> The type of view. The view type can be one of the following values:</p>
<table cellpadding="3">
<!-- cols="15 85" -->
<tr>
<td valign="top"><em>*TEXT</em></td>
<td valign="top">This is a view where text comes from files or text supplied by the processor.</td>
</tr>
<tr>
<td valign="top"><em>*LISTING</em></td>
<td valign="top">This is a view where text comes entirely from text supplied by the processor.</td>
</tr>
<tr>
<td valign="top"><em>*STATEMENT</em></td>
<td valign="top">This is a view consisting of statement identifiers. All modules have a statement view.</td>
</tr>
</table>
<br><br>
<h3><a name="HDRJVCLP">Format of JAVA Returned Library Name
Parameter</a></h3>
<p>When the program type parameter is *CLASS, class path name information is returned in the returned library name parameter. The following table shows the format of the returned library name parameter when the JAVA class file view information is retrieved. For more information on the fields, see <a href="#HDRRLIB1">Field Descriptions</a>.</p>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Bytes returned</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Bytes available</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to class path name</td>
</tr>
<tr>
<td align="center" valign="top">C</td>
<td align="center" valign="top">C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of class path name</td>
</tr>
<tr>
<td align="center" valign="top">&nbsp;</td>
<td align="center" valign="top">&nbsp;</td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">Class path name</td>
</tr>
</table>
<br><br>
<h3><a name="HDRRLIB1">Field Descriptions</a></h3>
<p><strong>Bytes available.</strong> The number of bytes available to be returned in the returned library name parameter. If the bytes available value is larger than the bytes provided value passed in the module name parameter, the API should be called again with a value that is at least as large as the bytes available. If the space provided is not large enough, the string space is filled with as many characters of the class path name as will fit.</p>
<p><strong>Bytes returned.</strong> The number of bytes returned in the returned library name parameter.</p>
<p><strong>Class path name.</strong> The path name of the file that contains the class file that was retrieved.</p>
<p><strong>Length of class path name.</strong> The length of the class path name returned.</p>
<p><strong>Offset to class path name.</strong> The offset from the start of the returned library name parameter to the class path name.</p>
<br>
<h3>Error Messages</h3>
<table width="100%" cellpadding="3">
<!-- cols="15 85" -->
<tr>
<th align="left" valign="top">Message ID</th>
<th align="left" valign="top">Error Message Text</th>
</tr>
<tr>
<td align="left" valign="top">CPF3C21 E</td>
<td valign="top">Format name &amp;1 is not valid.</td>
</tr>
<tr>
<td align="left" valign="top">CPF3C24 E</td>
<td valign="top">Length of the receiver variable is not valid.</td>
</tr>
<tr>
<td align="left" valign="top">CPF3CF1 E</td>
<td valign="top">Error code parameter not valid.</td>
</tr>
<tr>
<td align="left" valign="top">CPF3CF2 E</td>
<td valign="top">Error(s) occurred during running of &amp;1 API.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9541 E</td>
<td valign="top">Not in debug mode.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9549 E</td>
<td valign="top">Error addressing API parameter.</td>
</tr>
<tr>
<td align="left" valign="top">CPF954F E</td>
<td valign="top">Module &amp;1 not found.</td>
</tr>
<tr>
<td align="left" valign="top">CPF955F E</td>
<td valign="top">Program &amp;1 not a bound program.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9584 E</td>
<td valign="top">OPM program &amp;1 cannot be added to ILE debug environment.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9585 E</td>
<td valign="top">Program &amp;1 already active in OPM debug environment.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9587 E</td>
<td valign="top">Module name value &amp;1 not valid.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9591 E</td>
<td valign="top">Value specified in module name parameter is not valid.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9592 E</td>
<td valign="top">Class file not found.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9593 E</td>
<td valign="top">Not authorized to class file.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9594 E</td>
<td valign="top">JAVA class file not available.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9599 E</td>
<td valign="top">Class file cannot be debugged.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9801 E</td>
<td valign="top">Object &amp;2 in library &amp;3 not found.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9802 E</td>
<td valign="top">Not authorized to object &amp;2 in &amp;3.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9803 E</td>
<td valign="top">Cannot allocate object &amp;2 in library &amp;3.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9809 E</td>
<td valign="top">Library &amp;1 cannot be accessed.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9810 E</td>
<td valign="top">Library &amp;1 not found.</td>
</tr>
<tr>
<td align="left" valign="top">CPF9820 E</td>
<td valign="top">Not authorized to use library &amp;1.</td>
</tr>
</table>
<br>
<hr>
API introduced: V2R3
<hr>
<center>
<table cellpadding="2" cellspacing="2">
<tr align="center">
<td valign="middle" align="center">
<a href="#top_Of_Page">Top</a> |
<a href="debug1.htm">Debugger APIs</a> |
<a href="aplist.htm">APIs by category</a></td>
</tr>
</table>
</center>
<br>
</body>
</html>