KPG1_ABSET

Separates a list of items into a character array

Description:

The routine separates a list of items into an character array and finds the minimum number of characters required to specify each item uniquely, and the length in characters of the longest item of the list.

Invocation

CALL KPG1_ABSET( SEPAR, OPTS, ARRAY, NELM, MINCH, MAXNOC, STATUS )

Arguments

SEPAR = CHARACTER ( ) (Given)
The separator that divides the list of items.
OPTS = CHARACTER ( ) (Given)
Contains a list of items separated by the delimiter SEPAR. It is limited to 132 characters.
ARRAY( ) = CHARACTER ( ) (Returned)
The list divided into an array of values. The list is in alphabetic order.
NELM = INTEGER (Returned)
The number of elements in the list, and stored in ARRAY.
MCH( ) = CHARACTER ( ) (Returned)
The minimum number of initial characters to identify each of the items in the list uniquely. In the special case when an option equals the start of another option, MCH for the first option equals the option s length (ignoring trailing blanks) in characters; MCH for the the second will be at least one character greater.
MINCH = INTEGER (Returned)
The minimum number of initial characters that can identify an item in the list uniquely. In other words, the minimum value of the elements of MCH.
MAXNOC = INTEGER (Returned)
The maximum length of an item in the array, ignoring trailing blanks.
STATUS = INTEGER (Given and Returned)
The global status.

Notes: