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

640 lines
16 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">
<meta name="Copyright" content="Copyright (c) 2006 by IBM Corporation">
<title>Translate Data Stream (QD0TRNDS) 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. -->
<!-- NETMG2 SCRIPT A converted by B2H R4.1 (346) (CMS) by HOLTJM at -->
<!-- RCHVMW2 on 29 Jan 1999 at 10:01:37 -->
<!-- Change History: -->
<!-- YYMMDD USERID Change description -->
<!-- This file has undergone html cleanup June 2002 by JET -->
<!--File Edited December 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>Translate Data Stream (QD0TRNDS) API</h2>
<div class="box" style="width: 70%;">
&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%">Translation session handle</td>
<td align="left" valign="top" width="20%">Input</td>
<td align="left" valign="top" width="20%">Char(16)</td>
</tr>
<tr>
<td align="center" valign="top">2</td>
<td align="left" valign="top">To buffer</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Char(*)</td>
</tr>
<tr>
<td align="center" valign="top">3</td>
<td align="left" valign="top">To buffer output length</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Binary(4)</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="left" valign="top">To buffer length</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Binary(4)</td>
</tr>
<tr>
<td align="center" valign="top">5</td>
<td align="left" valign="top">To buffer 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">From buffer</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Char(*)</td>
</tr>
<tr>
<td align="center" valign="top">7</td>
<td align="left" valign="top">From buffer length</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Binary(4)</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="left" valign="top">From buffer type</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Char(10)</td>
</tr>
<tr>
<td align="center" valign="top">9</td>
<td align="left" valign="top">Operation</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Char(1)</td>
</tr>
<tr>
<td align="center" valign="top">10</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;Default Public Authority: *USE<br>
<!-- iddvc RMBR -->
<br>
&nbsp;&nbsp;Threadsafe: No<br>
<!-- iddvc RMBR -->
<br>
</div>
<p>The Translate Data Stream (QD0TRNDS) API translates data from one format to
another format. The data formats depend on the parameter values you
specify.</p>
<br>
<!-- Please NOTE: DO NOT DELETE THIS SECTION if this API has no authorities and locks. -->
<!-- Instead, use the commented out coding below to indicate NONE. -->
<h3>Authorities and Locks</h3>
<!-- Use this if there are no authorities and locks. -->
<p>None.</p>
<br>
<h3>Required Parameter Group</h3>
<dl>
<dt><strong>Translation session handle</strong></dt>
<dd>INPUT; CHAR(16)
<p>The name of the translation session. This name is returned to your
application following the call to the QD0STRTS API.</p>
</dd>
<dt><strong>To buffer</strong></dt>
<dd>OUTPUT; CHAR(*)
<p>The buffer used to contain the output of the data stream translation. This
value should be large enough to contain the expected results.</p>
</dd>
<dt><strong>To buffer output length</strong></dt>
<dd>OUTPUT; BINARY(4)
<p>The length of the translated data that is placed in the to buffer
parameter.</p>
</dd>
<dt><strong>To buffer length</strong></dt>
<dd>INPUT; BINARY(4)
<p>The length of the buffer that is available for output.</p>
</dd>
<dt><strong>To buffer type</strong></dt>
<dd>INPUT; CHAR(10)
<p>The type of data to be put into the to buffer parameter. The possible values
are:</p>
<table cellpadding="3">
<!-- cols="15 85" -->
<tr>
<td align="left" valign="top"><em>5250</em></td>
<td valign="top">Create a 5250 data stream</td>
</tr>
<tr>
<td align="left" valign="top"><em>3270</em></td>
<td valign="top">Create a 3270 data stream</td>
</tr>
<tr>
<td align="left" valign="top"><em>3270RB</em></td>
<td valign="top">Create a 3270 data stream for the data stream that is expected
in response to a 3270 Read Buffer command</td>
</tr>
<tr>
<td align="left" valign="top"><em>*FORMAT</em></td>
<td valign="top">Create a formatted buffer for the data. See the <cite>SNA
Upline Facility Programming</cite>, SC41-5446, book to determine the format of
the buffer header.</td>
</tr>
</table>
<p>See <a href="#TBLOPTBL">Valid Parameter Combinations</a> for a list of the
allowable combinations of this parameter with the operations and from buffer
type parameters.</p>
</dd>
<dt><strong>From buffer</strong></dt>
<dd>INPUT; CHAR(*)
<p>The buffer that contains the data to be translated.</p>
</dd>
<dt><strong>From buffer length</strong></dt>
<dd>INPUT; BINARY(4)
<p>The length of the data contained in the from buffer parameter.</p>
</dd>
<dt><strong>From buffer type</strong></dt>
<dd>INPUT; CHAR(10)
<p>The type of data that is contained in the from buffer parameter. The
possible values are:</p>
<table cellpadding="3">
<!-- cols="15 85" -->
<tr>
<td align="left" valign="top"><em>5250</em></td>
<td valign="top">Contains a 5250 data stream</td>
</tr>
<tr>
<td align="left" valign="top"><em>5250RS</em></td>
<td valign="top">Contains a 5250 data stream that results from a 5250 Read
Screen command</td>
</tr>
<tr>
<td align="left" valign="top"><em>5250RSE</em></td>
<td valign="top">Contains a 5250 data stream that results from a 5250 Read
Screen with Extended Attributes command</td>
</tr>
<tr>
<td align="left" valign="top"><em>3270</em></td>
<td valign="top">Contains a 3270 data stream</td>
</tr>
<tr>
<td align="left" valign="top"><em>*FORMAT</em></td>
<td valign="top">Contains a formatted buffer for the data. See the <cite>SNA
Upline Facility Programming</cite> book, SC41-5446, to determine the format of
the buffer header.</td>
</tr>
</table>
<p>See <a href="#TBLOPTBL">Valid Parameter Combinations</a> for a list of the
allowable combinations of this parameter with the operations and to buffer type
parameters.</p>
</dd>
<dt><strong>Operation</strong></dt>
<dd>INPUT; CHAR(1)
<p>Indicates whether the data to be translated is input or output data. You can
specify the following values:</p>
<table cellpadding="3">
<!-- cols="15 85" -->
<tr>
<td align="left" valign="top"><em>I</em></td>
<td valign="top">The data to be translated is for an input operation</td>
</tr>
<tr>
<td align="left" valign="top"><em>O</em></td>
<td valign="top">The data to be translated is for an output operation</td>
</tr>
</table>
<p>See <a href="#TBLOPTBL">Valid Parameter Combinations</a> for a list of the
allowable combinations of this parameter with the to buffer type and from
buffer type parameters.</p>
</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>
<p>The following table lists the valid combinations of the from buffer type, to
buffer type, and operations parameters.</p>
<p><strong><a name="TBLOPTBL">Valid Parameter Combinations</a></strong><br>
</p>
<table border width="60%">
<tr>
<th valign="top">Operation</th>
<th valign="top">From BufferType</th>
<th valign="top">To BufferType</th>
</tr>
<tr>
<td align="center" valign="top" width="30%">O</td>
<td align="left" valign="top" width="35%">3270</td>
<td align="left" valign="top" width="35%">*FORMAT</td>
</tr>
<tr>
<td align="center" valign="top" width="30%">O</td>
<td align="left" valign="top" width="35%">3270</td>
<td align="left" valign="top" width="35%">5250</td>
</tr>
<tr>
<td align="center" valign="top" width="30%">O</td>
<td align="left" valign="top" width="35%">*FORMAT</td>
<td align="left" valign="top" width="35%">5250</td>
</tr>
<tr>
<td align="center" valign="top" width="30%">I</td>
<td align="left" valign="top" width="35%">5250</td>
<td align="left" valign="top" width="35%">*FORMAT</td>
</tr>
<tr>
<td align="center" valign="top" width="30%">I</td>
<td align="left" valign="top" width="35%">5250</td>
<td align="left" valign="top" width="35%">3270</td>
</tr>
<tr>
<td align="center" valign="top" width="30%">I</td>
<td align="left" valign="top" width="35%">*FORMAT</td>
<td align="left" valign="top" width="35%">3270</td>
</tr>
<tr>
<td align="center" valign="top" width="30%">I</td>
<td align="left" valign="top" width="35%">5250RS</td>
<td align="left" valign="top" width="35%">3270RB</td>
</tr>
<tr>
<td align="center" valign="top" width="30%">I</td>
<td align="left" valign="top" width="35%">5250RSE</td>
<td align="left" valign="top" width="35%">3270RB</td>
</tr>
</table>
<br>
<br>
<h3>Error Messages</h3>
<table width="100%" cellpadding="3">
<tr>
<th align="left" valign="top">Message ID</th>
<th align="left" valign="top">Error Message Text</th>
</tr>
<tr>
<td width="15%" valign="top">CPF3C90 E</td>
<td width="85%" valign="top">Literal value cannot be changed.</td>
</tr>
<tr>
<td valign="top">CPF3CF1 E</td>
<td valign="top">Error code parameter not valid.</td>
</tr>
<tr>
<td valign="top">CPF5D53 E</td>
<td valign="top">To and from buffers overlap.</td>
</tr>
<tr>
<td valign="top">CPF5D54 E</td>
<td valign="top">Value &amp;1 for operation parameter not valid.</td>
</tr>
<tr>
<td valign="top">CPF5D55 E</td>
<td valign="top">Value &amp;1 is not valid for the To buffer type
parameter.</td>
</tr>
<tr>
<td valign="top">CPF5D56 E</td>
<td valign="top">Value &amp;1 is not valid for the From buffer type
parameter.</td>
</tr>
<tr>
<td valign="top">CPF5D57 E</td>
<td valign="top">Combination of parameter values not valid.</td>
</tr>
<tr>
<td valign="top">CPF5D58 E</td>
<td valign="top">Translation session handle parameter value not valid.</td>
</tr>
<tr>
<td valign="top">CPF5D59 E</td>
<td valign="top">Value &amp;1 for from buffer length parameter not valid.</td>
</tr>
<tr>
<td valign="top">CPF5D5A E</td>
<td valign="top">Value &amp;1 for the to buffer length parameter not
valid.</td>
</tr>
<tr>
<td valign="top">CPF5D5C E</td>
<td valign="top">3270 data stream in from buffer not valid.
<p>An error was found while translating the 3270 data stream in the from
buffer. The error code for translation was &amp;1.</p>
<table cellpadding="3">
<tr>
<td valign="top"><em>X'0002'</em></td>
<td valign="top">A 3270 command or order that is not supported or not valid was
detected in the data stream.</td>
</tr>
<tr>
<td valign="top"><em>X'0003'</em></td>
<td valign="top">A parameter or address that is not valid was detected in the
3270 data stream.</td>
</tr>
<tr>
<td valign="top"><em>X'0004'</em></td>
<td valign="top">Excess fields were detected in the data stream. A certain
number of these fields are allowed based on the device specified on the
QD0STRTS call. This number of fields was exceeded.</td>
</tr>
<tr>
<td valign="top"><em>X'0021'</em></td>
<td valign="top">A set buffer address order is missing after a row-column AID
code.</td>
</tr>
<tr>
<td valign="top"><em>X'0863'</em></td>
<td valign="top">A character set attribute that is not valid was found in the
data stream.</td>
</tr>
</table>
<br>
</td>
</tr>
<tr>
<td valign="top">CPF5D5D E</td>
<td valign="top">5250 data stream in from buffer not valid.
<p>An error was found while translating the 5250 data stream in the from
buffer. The error code for the translation was &amp;1.</p>
<table cellpadding="3">
<tr>
<td valign="top"><em>X'0001'</em></td>
<td valign="top">A 5250 AID code that was not correct was found in the data
stream.</td>
</tr>
<tr>
<td valign="top"><em>X'0020'</em></td>
<td valign="top">A cursor position that was not valid was detected in the 5250
data stream.</td>
</tr>
<tr>
<td valign="top"><em>X'0021'</em></td>
<td valign="top">A set buffer address order is missing after a row-column AID
code.</td>
</tr>
<tr>
<td valign="top"><em>X'0022'</em></td>
<td valign="top">A set buffer address order that was not valid was found in the
data stream.</td>
</tr>
<tr>
<td valign="top"><em>X'D030'</em></td>
<td valign="top">A data stream resulting from a Read Screen with Extended
Attributes command was specified for a display device that does not support
extended attributes.</td>
</tr>
</table>
<br>
</td>
</tr>
<tr>
<td valign="top">CPF5D5E E</td>
<td valign="top">Return code in formatted buffer indicates error. Codes
returned in this message are listed in <cite>SNA Upline Facility
Programming</cite>, SC41-5446.</td>
</tr>
<tr>
<td valign="top">CPF5D5F E</td>
<td valign="top">Data integrity error in from buffer. The error code for the
translation was &amp;1. The possible error codes are:<br>
<br>
<table cellpadding="3">
<tr>
<td valign="top"><em>X'0023'</em></td>
<td valign="top">Character not valid.</td>
</tr>
<tr>
<td valign="top"><em>X'0050'</em></td>
<td valign="top">Shift out (X'0E') and shift in (X'0F') not correctly balanced
in a DBCS session.</td>
</tr>
<tr>
<td valign="top"><em>X'0051'</em></td>
<td valign="top">Shift out (X'0E') and shift in (X'0F') in a DBCS field.</td>
</tr>
<tr>
<td valign="top"><em>X'0052'</em></td>
<td valign="top">The dead position in a DBCS field is not null.</td>
</tr>
<tr>
<td valign="top"><em>X'0053'</em></td>
<td valign="top">A DBCS character is not valid.</td>
</tr>
</table>
<br>
</td>
</tr>
<tr>
<td valign="top">CPF5D60 E</td>
<td valign="top">To buffer not large enough for translation output.</td>
</tr>
<tr>
<td valign="top">CPF5D62 E</td>
<td valign="top">Error occurred in translation routines.</td>
</tr>
<tr>
<td valign="top">CPF5D63 E</td>
<td valign="top">Data integrity error in formatted buffer. The error code for
the translation was &amp;1. The possible error codes are:<br>
<br>
<table cellpadding="3">
<tr>
<td valign="top"><em>X'0023'</em></td>
<td valign="top">Character not valid.</td>
</tr>
<tr>
<td valign="top"><em>X'0050'</em></td>
<td valign="top">Shift out (X'0E') and shift in (X'0F') not correctly balanced
in a DBCS session.</td>
</tr>
<tr>
<td valign="top"><em>X'0051'</em></td>
<td valign="top">Shift out (X'0E') or shift in (X'0F') in a DBCS field.</td>
</tr>
<tr>
<td valign="top"><em>X'0052'</em></td>
<td valign="top">The dead position in a DBCS field is not null.</td>
</tr>
<tr>
<td valign="top"><em>X'0053'</em></td>
<td valign="top">A DBCS character is not valid.</td>
</tr>
</table>
<br>
</td>
</tr>
<tr>
<td valign="top">CPF5D64 E</td>
<td valign="top">To buffer length not valid for to buffer.</td>
</tr>
<tr>
<td valign="top">CPF5D65 E</td>
<td valign="top">From buffer length not valid for from buffer.</td>
</tr>
<tr>
<td valign="top">CPF5D67 E</td>
<td valign="top">Severe error occurred while addressing parameter list.</td>
</tr>
<tr>
<td valign="top">CPF9872 E</td>
<td valign="top">Program or service program &amp;1 in library &amp;2 ended.
Reason code &amp;3.</td>
</tr>
</table>
<br>
<hr>
API introduced: V2R2
<hr>
<center>
<table cellpadding="2" cellspacing="2">
<tr align="center">
<td valign="middle" align="center"><a href="#Top_Of_Page">Top</a> | <a href=
"comm.htm">Communications APIs</a> | <a href="aplist.htm">APIs by
category</a></td>
</tr>
</table>
</center>
</body>
</html>