Guardian Procedure Calls Reference Manual (G06.25+)

Formatter Edit Descriptors
Guardian Procedure Calls Reference Manual522629-013
F-17
The I Edit Descriptor
b an unsigned integer constant that defines the number base of the external
data and cannot be less than 2 or greater than 16.
On output, the I
w edit descriptor causes the external field to consist of zero or more
leading blanks (followed by a minus if the value of the internal data is negative, or an
optional plus otherwise), followed by the magnitude of the internal value in the form of
an unsigned integer constant without leading zeros. An integer constant always
consists of at least one digit. If the number of characters produced exceeds the value
of
w, the entire field of width w is filled with asterisks.
The output from an I
w.m edit descriptor is the same as that from the Iw edit descriptor,
except that the unsigned integer constant consists of at least
m digits and, if necessary,
has leading zeros. The value of
m must not exceed the value of w. If m is zero and the
internal data is zero, the output field consists only of blank characters, regardless of
the sign control in effect.
The output from an I
w.m.b edit descriptor is the same as that from the Iw.m edit
descriptor, except that the unsigned integer constant is represented in the number
base
b. With the Iw edit and Iw.m edit descriptors, the output is treated as if b were
present and equal to 10. For example:
The “|” character is used to denote the boundaries of the output field.
On input, the I
w.m edit descriptor and the Iw.m.b edit descriptor are treated identically to
the I
w edit descriptor. These edit descriptors indicate that the field to be edited
occupies
w positions. In the input field, the character string must be in the form of an
optionally signed integer constant consisting only of base
b digits, except for the
interpretation blanks. Leading blanks on input are not significant, and the interpretation
of any other blanks is determined by blank control descriptors (BN and BZ). For
example:
Format Data Value Result
I7 100 | 100|
I7.2 -1 | -01|
I7.6 100 | 000100|
I7.6 -1 |-000001|
I7.6.8 28 | 000034|
I7.1.2 -5 | -101|
External Field Format Data Element Value
| 100| I7 100
| -01| I7 -1
| 1 | I7 1
| 1 | BZ,I7 1000
| 1 2 | BZ,I7 10200
| 1 2 | BN,I7 12