How to Use the New Hi-Li Features [ COMMUNICATOR 3000 MPE/iX Release 5.0 (Core Software Release X.50.20) ] MPE/iX Communicators
COMMUNICATOR 3000 MPE/iX Release 5.0 (Core Software Release X.50.20)
How to Use the New Hi-Li Features
by Rachel Schwab
Commercial Systems Division
The A.00.11 version of Hi-Li is available on this MPE/iX release. This
version contains several bug fixes and four new features. These new
features are:
1. Forms caching
2. Functionality to suppress the terminal bell
3. YYMMDD, COBOL packed, and COBOL zoned data conversion support
4. Application buffer and form initialization merge enhancement
The first and second features have been implemented by adding new modes
to the HPDSETENV and HPDGETENV intrinsics. The third feature has been
implemented by new type conversion codes added to the available data
mapping methods. The fourth feature has been implemented by new data
mapping methods added to those allowed by the HPDSEND and HPDREAD
intrinsics. A description of these changes follows.
HPDSETENV Changes
Four new modes for forms caching and one new mode for suppressing the
terminal bell have been added to the HPDSETENV intrinsic. Following is a
description of this intrinsic with details about the new modes and their
corresponding ENVBUF parameters.
R R I R R
HPDSETENV (GLOBALPAK, RETURNPAK, MODE, ENVBUFDESCRPT, ENVBUF)
Allows application to configure elements of the current execution environment.
Abbreviation definition:
I = integer (4 bytes).
R = Pascal record, COBOL group, array in BASIC, FORTRAN, and Transact.
Parameters:
---------------------------------------------------------------------
| GLOBALPAK | compound parameter, input to intrinsic |
| | |
| RETURNPAK | compound parameter, output from intrinsic |
| | |
| MODE | four-byte integer, input to intrinsic |
| | |
| | 2 = native language identifier, |
| | 3 = auto test option, |
| | * new * 7 = bell option, |
| | * new * 37 = cache directory, |
| | * new * 38 = form background loading, |
| | * new * 53 = cache entry (purge), |
| | * new * 54 = cache entry (load), |
| | 78 = device (switch out of block mode), |
| | 79 = device (switch into block mode). |
| | |
| ENVBUFDESCRPT | four-byte integer, input to intrinsic |
| | |
| ENVBUF | compound parameter, input to intrinsic |
| | |
| | This parameter defines the area that contains the |
| | configuration update. The value you supply for |
| | this parameter depends on the mode you have |
| | specified. Here are the details for the * new * |
| | modes listed above. For the other modes, please |
| | consult the "High-Level Screen Management |
| | Intrinsics Library (Hi-Li) Reference Manual" |
| | (32424-600001). |
| | |
| | Mode Element Length/Format |
| | 7 bell option four-byte integer |
| | 0 = sound bell, |
| | 1 = suppress bell. |
| | |
| | 37 cache directory four-byte integer **AND** |
| | 88-byte character array |
| | |
| | Note: The forms file must not be open. |
| | |
| | The integer parameter contains the cache |
| | directory size in entries, one per form |
| | (must be a value between 1 and 255). |
| | |
| | The character array is for an unimplemented |
| | feature. It should be initialized to blanks.|
| | |
| | 38 form background four-byte integer |
| | loading 1 = disable form background |
| | loading, |
| | all others = enable |
| | background loading |
| | (default). |
| | ********************************************** |
| | * For modes 53 and 54, the forms files * |
| | * must be open, the device must be * |
| | * enabled, and the cache directory must * |
| | * be configured. * |
| | * * |
| | * If the device is not Local Forms Storage * |
| | * (LFS) capable, an error will be returned. * |
| | * LFS capability may be ascertained after * |
| | * device enable with HPDGetEnv intrinsic * |
| | * mode=4. Third integer in returned EnvBuf * |
| | * "device token" will contain the device * |
| | * identifier determined when device enabled.* |
| | * See Appendix G, Table G-1, in the "Data * |
| | * Entry and Forms Management System VPLUS * |
| | * Reference Manual" (32209-60002). * |
| | ********************************************** |
| | |
| | 53 cache entry 60-byte character array |
| | |
| | Name of form to purge from |
| | cache, left-justified. Will |
| | be upshifted. |
| | |
| | 54 cache entry 60-byte character array |
| | |
| | Name of form to load to |
| | cache, left-justifed. Will |
| | be upshifted. |
---------------------------------------------------------------------
HPDGETENV Changes
The bell option mode has also been added to the HPDGETENV intrinsic.
Following is a description of this intrinsic with details about the new
mode and its corresponding ENVBUF parameter.
R R I R R
HPDGETENV (GLOBALPAK, RETURNPAK, MODE, ENVBUFDESCRPT, ENVBUF)
Retrieves configuration of current execution environment elements.
Abbreviation definition:
I = integer (4 bytes).
R = Pascal record, COBOL group, array in BASIC, FORTRAN, and Transact.
Parameters:
---------------------------------------------------------------------
| GLOBALPAK | compound parameter, input to intrinsic |
| | |
| RETURNPAK | compound parameter, output from intrinsic |
| | |
| MODE | four-byte integer, input to intrinsic |
| | |
| | 1 = interface library version, |
| | 2 = native language identifier, |
| | 3 = auto test option, |
| | 4 = device token, |
| | 5 = form token, |
| | * new * 7 = bell option, |
| | |
| ENVBUFDESCRPT | four-byte integer, input to intrinsic |
| | |
| ENVBUF | compound parameter, input to intrinsic |
| | |
| | This parameter defines the area where the |
| | requested element configuration is returned. The |
| | value you supply for this parameter depends on |
| | the mode you have specified. Here are the |
| | details for the * new * mode listed above. For |
| | the other modes, please consult the "Data Entry |
| | Forms Management System VPLUS Reference Manual" |
| | (32209-60002). |
| | |
| | Mode Element Length/Format |
| | 7 bell option four-byte integer |
| | 0 = sound bell, |
| | 1 = suppress bell. |
---------------------------------------------------------------------
HPDGETENV and HPDSETENV Errors and Exceptions:
*new* -73 Form loaded indicator not set.
*new* -71 @ Unable to load cache entry (form).
*new* -69 @ Unable to purge cache entry (form).
-68 Unrecognized auto test option code passed.
*new* -67 Cache directory space value out of range.
*new* -66 No cache directory space configured.
-65 Terminal has not been switched out of block mode.
-64 @ Attempt to switch device into block mode failed.
-63 @ Attempt to switch device out of block mode failed.
-62 Language characteristic may not be set for current forms file.
*new* -61 May not configure cache if forms file already open.
-60 @ Attempt to configure language failed.
-58 @ Attempt to return forms file language characteristic failed.
-56 Unrecognized configuration mode code passed.
-27 Terminal was switched out of block mode (and is not "enabled").
-17 Terminal is not enabled.
-9 Forms file is not open.
-6 Communications area is not set up.
-5 Inappropriate filename passed.
YYMMDD, COBOL Packed, and COBOL Zoned Data Conversion Support
Chapter 4 in the High-Level Screen Management Intrinsics Library (Hi-Li)
Reference Manual (32424-60001) discusses the available data mapping
methods. With this version of Hi-Li, enhancements have been made to the
D and E methods of data transfer. These methods allow you to transfer
data or a subset of data and provide data type conversion within your
application.
The DATADESCRPT parameter is a compound parameter used in the HPDREAD,
HPDSEND, and HPDPRINTFORM intrinsics to tell Hi-Li how you want to
transfer data between your application and your form. It contains ten
subparameters. One of these subparameters, TYPCNVCODE, is a four-byte
integer that tells Hi-Li the type of data conversion you want performed.
Several new values are available for this subparameter to support YYMMDD,
COBOL packed, and COBOL zoned data conversion.
Following is a list of the available TYPCNVCODEs and their meanings:
Value(s) Conversion Type
0 No conversion.
1 Two-byte integer conversion.
2 Four-byte integer conversion.
3 Four-byte HP3000 format floating point (real)
conversion.
4 Eight-byte HP3000 format floating point (long)
conversion.
5 Reserved for four-byte IEEE format floating point
(real) conversion.
6 Reserved for eight-byte IEEE format floating point
(long) conversion.
7 *new* Six-byte YYMMDD date conversion.
1010..1189, * Thousands digit indicates COBOL data type:
2010..2189,
3010..3189,
4010..4189 *new*
Value Type
1nnn Unsigned COBOL packed
type.
2nnn Signed COBOL packed
type.
3nnn Unsigned COBOL zoned
type.
4nnn Signed COBOL zoned
type.
* Hundreds and tens digits indicate total
number of 9s in the COBOL PIC clause; 18
digits maximum.
* Ones digit indicates number of 9s to the
right of the V character in the COBOL PIC
clause; 9 decimal places maximum.
* Examples:
* PIC S9(9)V9(9) COMP-3 is specified as
2189.
* PIC 9(18) COMP-3 is specified as
1180.
* PIC SV9 is specified as 4011.
* PIC 9 is specified as 3010.
Application Buffer and Form Initialization Merge Enhancement
Two additional data mapping methods for mapping data that is to be moved
between the application and the fields in the form are available on this
release to supplement the two methods previously available.
The mapping method which is to be used by HPDSEND and/or HPDREAD is
indicated by the value in the DESCRPTTYPE subparameter of the DATADESCRPT
parameter. Following is a list of the possible values for this four-byte
integer subparameter and explanations for each value.
Value Meaning
-1 Do not transfer data.
0 Move concatenated string of data from/to DATABUF;
the number of bytes moved is equal to the sum of
the lengths of all the fields in the form; no data
conversion is performed.
1 *new* For HPDSEND, non-blank application buffer fields
overlay corresponding fields in the form which were
initialized to blanks by form specifications. For
HPDREAD, same mapping as specifying 0; that is, no
data conversion is performed.
2 *new* For HPDSEND, non-blank application buffer fields
overlay corresponding fields in the form. For
HPDREAD, same mapping as specifying 0; that is, no
data conversion is performed.
By using one of the new DESCRPTTYPE (1 or 2) values, the application can
merge the application buffer content with the form specification
initialization.
MPE/iX Communicators