OSI/MHS Gateway Programmatic Interface (GPI) Programming Guide
TAL Program Example
OSI/MHS Gateway Programmatic Interface (GPI) Programming Guide—424822-001
A-12
descriptor_list[2].type := MH_T_CONTENT_RETURN_REQUESTED;
descriptor_list[2].syntax := OM_S_BOOLEAN;
descriptor_list[2].value.boolean := OM_FALSE ;
descriptor_list[3].type := MH_T_CONTENT_TYPE;
descriptor_list[3].syntax := OM_S_INTEGER;
descriptor_list[3].value.integer := MH_CTI_P2_1988 ;
descriptor_list[4].type := MH_T_CONVERSION_PROHIBITED;
descriptor_list[4].syntax := OM_S_BOOLEAN;
descriptor_list[4].value.boolean := OM_FALSE ;
descriptor_list[5].type := MH_T_DISCLOSURE_ALLOWED;
descriptor_list[5].syntax := OM_S_BOOLEAN;
descriptor_list[5].value.boolean := OM_FALSE ;
descriptor_list[6].type := MH_T_PRIORITY;
descriptor_list[6].syntax := OM_S_ENUMERATION;
descriptor_list[6].value.enumeration := MH_PTY_NORMAL ;
local_rc := GPI_OM_INSERT_ ( root_id, -- Root object identifier
IGNORED_FOR_SINGLE_VALUED_ATT,
descriptor_list,
descriptor_count);
RETURN (local_rc);
END; -- End insert_root_attributes
?page
---------------------------------------------------------------------------
-- Function Name: build_and_insert_bilateral_obj --
-- --
-- Arguments: root_id IN --
-- --
-- Return: Return code from the function call --
-- --
-- Description: This function creates the mh_c_bilateral_information--
-- object with the initial value parameter set to TRUE.--
-- This will cause the object to be populated with the --
-- attributes that have default values. One of these --
-- attributes, the PRMD_IDENTIFER, is then removed --
-- because it is not wanted in our message. The --
-- function then adds in the MH_T_INFORMATION --
-- attribute, before inserting the entire --
-- mh_c_bilateral_information object into the root --
-- object. --
---------------------------------------------------------------------------
INT PROC build_and_insert_bilateral_obj (root_id);
INT(32) root_id;
BEGIN
INT local_rc; -- RETURN code from the function call
INT(32)
descriptor_count := 1D, -- Count of the elements
total_number, -- The number of values of the specified
-- attribute
local_object; -- Local object identifier
STRING .EXT data_buf_in[0:131]; -- Buffer for string data
STRUCT
.EXT descriptor_list(OM_descriptor)[0:1]; -- Descriptor list
-- Initialize the descriptor list