hp.com home products and services support and drivers solutions how to buy
cd-rom home
End of Jump to page title
HP OpenVMS systems
documentation

Jump to content


HP OpenVMS Programming Concepts Manual

HP OpenVMS Programming Concepts Manual


Previous Contents Index

E.5 BLISS Implementations

Table E-5 lists the OpenVMS data types and their corresponding BLISS data type declarations.

Table E-5 BLISS Implementations
OpenVMS Data Types BLISS Declarations
access_bit_names BLOCKVECTOR[32,8,BYTE]
access_mode UNSIGNED BYTE
address UNSIGNED LONG
address_range VECTOR[2,LONG,UNSIGNED]
arg_list VECTOR[ n,LONG,UNSIGNED]
where n is the number of arguments + 1.
ast_procedure UNSIGNED LONG
boolean UNSIGNED LONG
byte_signed SIGNED BYTE
byte_unsigned UNSIGNED BYTE
channel UNSIGNED WORD
char_string VECTOR[65536,BYTE,UNSIGNED]
complex_number F_Complex: VECTOR[2,LONG]
D_Complex: VECTOR[4,LONG]
G_Complex: VECTOR[4,LONG]
H_Complex: VECTOR[8,LONG]
cond_value UNSIGNED LONG
context UNSIGNED LONG
date_time VECTOR[2,LONG,UNSIGNED]
device_name VECTOR[ n,BYTE,UNSIGNED]
where n is the length of the device name.
ef_cluster_name VECTOR[ n,BYTE,UNSIGNED]
where n is the length of the event-flag cluster name.
ef_number UNSIGNED LONG
exit_handler_block BLOCK[ n,BYTE]
where n is the size of the exit-handler control block.
fab $FAB_DECL (from STARLET.REQ)
file_protection BLOCK[2,BYTE]
floating_point F_Floating: VECTOR[1,LONG]
D_Floating: VECTOR[2,LONG]
G_Floating: VECTOR[2,LONG]
H_Floating: VECTOR[4,LONG]
function_code BLOCK[2,WORD]
identifier UNSIGNED LONG
io_status_block BLOCK[8,BYTE]
item_list_2 BLOCKVECTOR[ n,8,BYTE]
where n is the number of the item descriptors + 1.
item_list_3 BLOCKVECTOR[ n,12,BYTE]
where n is the number of the item descriptors + 1.
  $ITMLST_DECL/$ITMLST_INIT
from STARLET.REQ
item_list_pair BLOCKVECTOR[ n,2,LONG]
where n is the number of the item descriptors + 1.
item_quota_list BLOCKVECTOR[ n,5,BYTE]
where n is the number of the quota descriptors + 1.
lock_id UNSIGNED_LONG
lock_status_block BLOCK[ n,BYTE]
where n is the size of the lock_status_block minus at least 8.
lock_value_block BLOCK[16,BYTE]
logical_name VECTOR[255,BYTE,UNSIGNED]
longword_signed SIGNED LONG
longword_unsigned UNSIGNED LONG
mask_byte BITVECTOR[8]
mask_longword BITVECTOR[32]
mask_quadword BITVECTOR[64]
mask_word BITVECTOR[16]
null_arg UNSIGNED LONG
octaword_signed VECTOR[4,LONG,UNSIGNED]
octaword_unsigned VECTOR[4,LONG,UNSIGNED]
page_protection UNSIGNED LONG
procedure UNSIGNED LONG
process_id UNSIGNED LONG
process_name VECTOR[ n,BYTE,UNSIGNED]
where n is the length of the process name.
quadword_signed VECTOR[2,LONG,UNSIGNED]
quadword_unsigned VECTOR[2,LONG,UNSIGNED]
rights_holder BLOCK[8,BYTE]
rights_id UNSIGNED LONG
rab $RAB_DECL
from STARLET.REQ
section_id VECTOR[2,LONG,UNSIGNED]
section_name VECTOR[ n,BYTE,UNSIGNED]
where n is the length of the global section name.
system_access_id VECTOR[2,LONG,UNSIGNED]
time_name VECTOR[ n,BYTE,UNSIGNED]
where n is the length of the time value in OpenVMS format.
transaction_id VECTOR[4,LONG,UNSIGNED]
uic UNSIGNED LONG
user_arg UNSIGNED LONG
varying_arg UNSIGNED LONG
vector_byte_signed VECTOR[ n,BYTE,SIGNED]
where n is the size of the array.
vector_byte_unsigned VECTOR[ n,BYTE,UNSIGNED]
where n is the size of the array.
vector_longword_signed VECTOR[ n,LONG,SIGNED]
where n is the size of the array.
vector_longword_unsigned VECTOR[ n,LONG,UNSIGNED]
where n is the size of the array.
vector_quadword_signed BLOCKVECTOR[ n,2,LONG]
where n is the size of the array.
vector_quadword_unsigned BLOCKVECTOR[ n,2,LONG]
where n is the size of the array.
vector_word_signed VECTOR[ n,BYTE,SIGNED]
where n is the size of the array.
vector_word_unsigned VECTOR[ n,BYTE,UNSIGNED]
where n is the size of the array.
word_signed SIGNED WORD
word_unsigned UNSIGNED WORD

E.6 C and C++ Implementations

Table E-6 lists the OpenVMS data types and their corresponding C and C++ data type declarations.

Table E-6 C and C++ Implementations
OpenVMS Data Types C and C++ Declarations
access_bit_names User defined 1
access_mode unsigned char
address User defined 1 *pointer 2,4
address_range int *array [2] 2,3,4
arg_list User defined 1
ast_procedure Pointer to function 2
boolean unsigned long int
byte_signed char
byte_unsigned unsigned char
channel unsigned short int
char_string char array[ n] 3,5
complex_number User defined 1
cond_value unsigned long int
context unsigned long int
date_time User defined 1
device_name char array[ n] 3,5
ef_cluster_name char array[ n] 3,5
ef_number unsigned long int
exit_handler_block User defined 1
fab #include <fab.h>
struct FAB
file_protection unsigned short int or user defined 1
floating_point float, double, or long double
function_code unsigned long int or user defined 1
identifier unsigned long int *pointer 2,4
invo_context_blk 6 #include <libicb.h>
struct invo_context_blk
invo_handle 6 unsigned long int
io_status_block User defined 1
item_list_2 User defined 1
item_list_3 User defined 1
item_list_pair User defined 1
item_quota_list User defined 1
lock_id unsigned long int
lock_status_block User defined 1
lock_value_block User defined 1
logical_name char array[ n] 3,5
longword_signed long int
longword_unsigned unsigned long int
mask_byte unsigned char
mask_longword unsigned long int
mask_quadword User defined 1
mask_word unsigned short int
mechanism_args #include <chfdef.h>
struct chf$mech_array
null_arg unsigned long int
octaword_signed User defined 1
octaword_unsigned User defined 1
page_protection unsigned long int
procedure Pointer to function 2
process_id unsigned long int
process_name char array[ n] 3,5
quadword_signed User defined 1
quadword_unsigned User defined 1
rights_holder User defined 1
rights_id unsigned long int
rab #include <rab.h>
struct RAB
section_id User defined 1
section_name char array[ n] 3,5
system_access_id User defined 1
time_name char array[ n] 3,5
transaction_id User defined 1
uic unsigned long int
user_arg User defined 1
varying_arg User defined 1
vector_byte_signed char array[ n] 3,5
vector_byte_unsigned unsigned char array[ n] 3,5
vector_longword_signed long int array[ n] 3,5
vector_longword_unsigned unsigned long int array[ n] 3,5
vector_quadword_signed User defined 1
vector_quadword_unsigned User defined 1
vector_word_signed short int array[ n] 3,5
vector_word_unsigned unsigned short int array[ n] 3,5
word_signed short int
word_unsigned unsigned short int


1The declaration of a user-defined data structure depends on how the data will be used. Such data structures can be declared in a variety of ways, each of which is suitable only to specific applications.
2C and C++ pointers are declared with special syntax and are associated with the data type of the object being pointed to. This object is often user defined.
3The term array denotes the syntax of a C or C++ array declaration.
4The data type specified can be changed to any valid C or C++ data type.
5The size of the array must be substituted for n.
6Alpha and I64 specific.

E.7 COBOL Implementations

Table E-7 lists the OpenVMS data types and their corresponding COBOL data type declarations.

Table E-7 COBOL Implementations
OpenVMS Data Types COBOL Declarations
access_bit_names na ... PIC X(128) 1
access_mode na ... PIC X 1
The access_mode data type is usually passed BY VALUE as PIC 9(5) COMP.
address USAGE POINTER
address_range 01 ADDRESS-RANGE
02 BEGINNING-ADDRESS USAGE POINTER
02 ENDING-ADDRESS USAGE POINTER
arg_list na ... Constructed by the compiler as a result of using the COBOL CALL statement. An argument list may be created as follows, but cannot be referenced by the COBOL CALL statement.

01 ARG-LIST
02 ARG-COUNT PIC S9(5) COMP
02 ARG-BY-VALUE PIC S9(5) COMP
02 ARG-BY-REFERENCE USAGE POINTER
02 VALUE REFERENCE ARG-NAME
... continue as needed
ast_procedure 01 AST-PROC PIC 9(5) COMP 2
boolean 01 BOOLEAN-VALUE PIC 9(5) COMP 2
byte_signed na ... PIC X 1
byte_unsigned na ... PIC X 1
channel 01 CHANNEL PIC 9(4) COMP 2
char_string 01 CHAR-STRING PIC X to PIC X(65535)
complex_number na ... PIC X( n), where n is the length. 1
cond_value 01 COND-VALUE PIC 9(5) COMP 2
context 01 CONTEXT PIC 9(5) COMP 2
date_time na ... PIC X(16) 1
device_name 01 DEVICE-NAME PIC X( n), where n is the length.
ef_cluster_name 01 CLUSTER-NAME PIC X( n), where n is the length.
ef_number 01 EF-NO PIC 9(5) COMP 2
exit_handler_block na ... PIC X( n), where n is the length. 1
fab na ... Too complex for general COBOL use. Most of a FAB structure can be described by a lengthy COBOL record description, but such a FAB cannot then be referenced by a COBOL I-O statement. It is much simpler to do the I-O completely within COBOL, and let the COBOL compiler generate the FAB structure or do the I-O in another language.
file_protection 01 FILE-PROT PIC 9(4) COMP 2
floating_point 01 F-FLOAT USAGE COMP-1
01 D-FLOAT USAGE COMP-2
The G-float and H-float data types are not supported in COBOL.
function_code 01 FUNCTION-CODE
02 MAJOR-FUNCTION PIC 9(4) COMP 2
02 SUB-FUNCTION PIC 9(4) COMP 2
identifier 01 ID PIC 9(5) COMP 2
invo_context_blk 3 na
invo_handle 3 na
io_status_block 01 IOSB
02 COND-VAL PIC 9(4) COMP 2
02 BYTE-CNT PIC 9(4) COMP 2
02 DEV-INFO PIC 9(5) COMP 2
item_list_2 01 ITEM-LIST-TWO
02 ITEM-LIST OCCURS n TIMES
04 COMP-LENGTH PIC S9(4) COMP
04 ITEM-CODE PIC S9(4) COMP
04 COMP-ADDRESS PIC S9(5) COMP
02 TERMINATOR PIC S9(5) COMP VALUE 0
item_list_3 01 ITEM-LIST-3
02 ITEM-LIST OCCURS n TIMES
04 BUF-LEN PIC S9(4) COMP
04 ITEM-CODE PIC S9(4) COMP
04 BUFFER-ADDRESS PIC S9(5) COMP
04 LENGTH-ADDRESS PIC S9(5) COMP
02 TERMINATOR PIC S9(5) COMP VALUE 0
item_list_pair 01 ITEM-LIST-PAIR
02 ITEM-LIST OCCURS n TIMES
04 ITEM-CODE PIC S9(5) COMP
04 ITEM-VALUE PIC S9(5) COMP
02 TERMINATOR PIC S9(5) COMP VALUE 0
item_quota_list na
lock_id 01 LOCK-ID PIC 9(5) COMP 2
lock_status_block na
lock_value_block na
logical_name 01 LOG-NAME PIC X TO X(255)
longword_signed 01 LWS PIC S9(5) COMP
longword_unsigned 01 LWU PIC 9(5) COMP 2
mask_byte na ... PIC X 1
mask_longword 01 MLW PIC 9(5) COMP 2
mask_quadword 01 MQW PIC 9(18) COMP 2
mask_word 01 MW PIC 9(4) COMP 2
mechanism_args na
null_arg CALL ... USING OMITTED or
PIC S9(5) COMP VALUE 0 passed USING BY VALUE
octaword_signed na
octaword_unsigned na
page_protection 01 PAGE-PROT PIC 9(5) COMP 2
procedure 01 ENTRY-MASK PIC 9(5) COMP 2
process_id 01 PID PIC 9(5) COMP 2
process_name 01 PROCESS-NAME PIC X TO X(15)
quadword_signed 01 QWS PIC S9(18) COMP
quadword_unsigned 01 QWU PIC 9(18) COMP 2
rights_holder 01 RIGHTS-HOLDER
02 RIGHTS-ID PIC 9(5) COMP 2
02 ACCESS-RIGHTS PIC 9(5) COMP 2
rights_id 01 RIGHTS-ID PIC 9(5) COMP 2
rab na ... Too complex for general COBOL use. Most of a RAB structure can be described by a lengthy COBOL record description, but such a RAB cannot then be referenced by a COBOL I-O statement. It is much simpler to do the I-O completely within COBOL, and let the COBOL compiler generate the RAB structure, or do the I-O in another language.
section_id 01 SECTION-ID PIC 9(18) COMP 2
section_name 01 SECTION-NAME PIC X to X(43)
system_access_id 01 SECTION-ACCESS-ID PIC 9(18) COMP 2
time_name 01 TIME-NAME PIC X( n), where n is the length.
transaction_id na
uic 01 UIC PIC 9(5) COMP 2
user_arg 01 USER-ARG PIC 9(5) COMP 2
varying_arg Depends on the application.
vector_byte_signed na ... 3
vector_byte_unsigned na ... 3
vector_longword_signed na ... 3
vector_longword_unsigned na ... 3
vector_quadword_signed na ... 3
vector_quadword_unsigned na ... 3
vector_word_signed na ... 3
vector_word_unsigned na ... 4
word_signed 01 WS PIC S9(4) COMP
word_unsigned 01 WS PIC 9(4) COMP 2


1Most OpenVMS data types not directly supported in COBOL can be represented as an alphanumeric data item of a certain number of bytes. While COBOL does not interpret the data type, you can use it to pass objects from one language to another.
2Although unsigned computational data structures are not directly supported in COBOL, you may substitute the signed equivalent provided you do not exceed the range of the signed data structure.
3Alpha and I64 specific.
4COBOL does not permit the passing of variable-length data structures.


Previous Next Contents Index