SPI Tokens
Data Definition Language (DDL) Reference Manual — 426798-002
7- 21
TOKEN-MAP Statement
•
COBOL source code:
•
pTAL or TAL source code:
•
TACL source code:
•
C source code:
#pragma section jobinfo_map
static int jobinfo_map[] = {2303,3,12,17152,1024,2136};
•
Pascal source code:
?Section JOBINFO_MAP
VAR JOBINFO_MAP : Array [1..6 ] of INT16 := [2303,3,12,17152,
1024,2136];
The following example shows the DEFINITION and TOKEN-MAP statements when the
JOBINFO token is extended to add new fields associated with version “C10.”
TOKEN-MAP assn-map-jobinfo VALUE IS assn-tnm-jobinfo
DEF IS assn-ddl-jobinfo.
VERSION "C00" FOR jnumber THRU location.
VERSION "C10" FOR jobclass-is-present.
01 JOBINFO-MAP.
02 FILLER NATIVE-2 VALUE 2303.
02 FILLER NATIVE-2 VALUE 3.
02 FILLER NATIVE-2 VALUE 12. 02 FILLER NATIVE-2 VALUE 12.
02 FILLER NATIVE-2 VALUE 02 FILLER NATIVE-2 VALUE 17152.
02 FILLER NATIVE-2 VALUE 1024.
02 FILLER NATIVE-2 VALUE 2136.
END .
Token type XSPI-TYPE-MAP
Token number
Token byte length
Version “C00”
VST704.vsd
DEFINE JOBINFO^MAP = [2303,3,12,17152,1024,2136]#;•
LITERAL JOBINFO^MAP^WLN = 6;
Number of words in token
map
VST705.vsd
?Section JOBINFO^MAP Struct•
BEGIN•INT2 CODE VALUE INT2 CODE VALUE 150929411;
INT MAP (0:3) VALUE 12 17152 1024 2136;
END;
Value generated from token code
Values for rest of map
VST706.vsd
DEF assn-ddl-jobinfo.
02 jnumber TYPE zspi-ddl-int.
02 priority TYPE zspi-ddl-int.
02 location TYPE zspi-ddl-char8 SPI-NULL "X".
02 jobclass-is-present TYPE zspi-ddl-boolean.
02 jobclass TYPE zspi-ddl-int.
02 jobusername TYPE zspi-ddl-username.
END
Defines fields in extensible
structure
VST707.vsd