OSI/MHS Gateway Programmatic Interface (GPI) Programming Guide
C Program Example
OSI/MHS Gateway Programmatic Interface (GPI) Programming Guide—424822-001
B-37
descriptor_list_3,
&total_number,
&actual_number,
string_buffer,
STRING_BUFFER_LEN,
&actual_string_len,
&total_string_len );
if (( local_rc == OM_RC_SUCCESS ) || (local_rc == ZGPI_RC_WARNING))
{
if ( local_rc == ZGPI_RC_WARNING )
printf (" WARNING! number: %d \n", local_rc );
/* Print the two multivalued attributes */
for ( counter = 0 ; counter < 2 ; ++counter )
{
local_rc = GPI_OM_EXAMINE_
( descriptor_list_3[counter].value.object.object,
OM_TRUE, /* Values returned */
0, /* First element */
MAX_DESCRIPTORS,
descriptor_list,
&total_number,
&actual_number,
string_buffer,
STRING_BUFFER_LEN,
&actual_string_len,
&total_string_len );
if (( local_rc == OM_RC_SUCCESS ) ||
( local_rc == ZGPI_RC_WARNING ))
{
if ( local_rc == ZGPI_RC_WARNING )
printf (" WARNING! number: %d \n",local_rc );
max_PRINT_DEF = 5;
print_arr[0].type = MH_T_EXPLICIT_CONVERSION;
print_arr[1].type = MH_T_MTA_REPORT_REQUEST;
print_arr[2].type = MH_T_MTA_RESPONSIBILITY;
print_arr[3].type = MH_T_ORIGINATOR_REPORT_REQUEST;
print_arr[4].type = MH_T_RECIPIENT_NUMBER;
print_arr[0].text = " Explicit Conversion: ";
print_arr[1].text = " MTA Report Request: ";
print_arr[2].text = " MTA Responsibility: ";
print_arr[3].text = " Originator Report Request";
print_arr[4].text = " Recipient Number: ";
printf (" Recipient Descriptors\n");
print_attributes ( max_PRINT_DEF,
print_arr,
descriptor_list,
actual_number);
/* Print subobject or name */
max_PRINT_DEF = 6;
f_descriptor_list[0].type = MH_T_ADMD_NAME;
f_descriptor_list[1].type = MH_T_COUNTRY_NAME;
f_descriptor_list[2].type = MH_T_PRMD_NAME;
f_descriptor_list[3].type = MH_T_ORGANIZATION_NAME;
f_descriptor_list[4].type = MH_T_ORGANIZATIONAL_UNIT_NME_1;
f_descriptor_list[5].type = MH_T_SURNAME;
print_arr[0].type = MH_T_ADMD_NAME;
print_arr[1].type = MH_T_COUNTRY_NAME;