Example of an ADSDL and an ADS

 

An example showing parts of an ADSDL and an ADS is given here. For full details of all the fields, see the references already cited. Values in the diagrams shown like this:

ABCD
1234
show hexadecimal values as you would see them in an ISPF editor with hex on. This is equivalent to the hexadecimal value X'A1B2C3D4'.

This diagram shows the start of the ADSDL (even though the eyecatcher shows ADSL):

...½ADSL...........±....CHO         L .........┌.......&$...TRANID  
000BCCED0000000100040000CCD444444444D400000F000F000100054000EDCDCC44...
005814230001000B001900033860000000003000000F000E00080000A00039159400...
↑           ↑                                   ↑   ↑       ↑
|           adsdl_field_count                   |   |       adsdl_first_field
adsdl_length                                    |   adsdl_map_columns
                                                adsdl_map_lines
The fields named in this example show the following:

adsdl_length

This ADSDL is 0x05B8 bytes long

adsdl_field_count

There are 0x1B (27) named fields in the ADS

adsdl_map_lines

The map has 0x18 (24) lines

adsdl_map_columns

The map has 0x50 (80) columns

adsdl_first_field

The start of the first field description in the ADSDL.
The next diagram shows the ADSDL first field descriptor and part of the next field descriptor.
TRANID                          ................L ..TERMID        
EDCDCC444444444444444444444444440000000000000000D400ECDDCC4444444444...
3915940000000000000000000000000000060000000C000430003594940000000000...
↑                               ↑       ↑   ↑       ↑
adsdl_field_name                |       |   |       adsdl_next_field
                                |       |   adsdl_field_data_len
                                |       adsdl_field_offset
                                adsdl_field_name_len
The fields named in this example show the following:

adsdl_field_name

The name of the field in the ADS, in this case TRANID. Only the value of the field appears in the ADS, not its name.

adsdl_field_name_len

The length of the name of the field, in this case six bytes.

adsdl_field_offset

The absolute offset of the field from the start of the ADS. The offset is given as 0x0C (twelve) bytes, even though this is the first field. The reason is that the first twelve bytes of the ADS are reserved and do not contain information for the application programmer.

adsdl_field_data_len

The data length of the named field, in this case four bytes.

adsdl_next_field

The start of the next field description.
The next diagram shows the start of the ADS, which is in long form. The values here relate directly to the sample ADSDL shown above and are for the field named as TRANID in adsdl_field_name.
....................................................BAAA............
0000000000000002000000000000000000000000000000000000CCCC000200000000...
000000000000000C0000000000000000000000000000000000002111000C00000000...
↑           ↑                                       ↑   ↑
|           Offset to next field                    |   Start of next field      
12 bytes reserved                                   Value of field 
The meanings of the values shown here are as follows:

12 bytes reserved

Reserved space at the start of every ADS, in both short and long form

Offset to next field

The information given for the current field is 0x2C bytes long, from the start of this fullword length value.

Value of field

The value of the field, whose name is identified as TRANID in the ADSDL, is BAAA. The offset of the data is always 0x28 bytes from the start of the field for an ADS in long form.

Start of next field

The start of the information for the next field in the ADS.
In this case, the field information is an exact multiple of fullwords. If this were not the case, padding bytes would appear after the data value and before the next field to ensure that it started on a fullword boundary. The padding bytes would be included in the offset to next field value.

A number of attribute and extended attribute values for the field, not identified here, appear between the fullword giving the offset to the next field and the field value itself.

 

Parent topic:

Interpreting outbound SEND MAP and RECEIVE MAP vectors


fg15640_