Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

ONEVT Set condition for job variable event

&pagelevel(4)&pagelevel

General

Domain:


Job variables

Macro type:


Type S (with version=0): standard form/C/D/E/L form
Type S (with version=1): standard form/C/D/E/L/M form,
see section “The MF operand”

Macro description

The ONEVT macro is used to specify a condition and assign an event item. During program execution, a POSSIG is initiated by the system when the event “condition satisfied” or “catalog exported” occurs.
A maximum can be set for the number of POSSIG calls to be executed.
For more information on eventing, see the “Executive Macros” manual [4].

Macro call format and operand description

Operation

Operands

ONEVT

'cond.expr' / addr1 / (r1)

,EIID=addr / (r)

[,POST=value / (r)]

,COUNT=1  / int / (r) 

{
     ,VERSION=0
         
,MF=S / (D,pre) / D / (E,..) / C / (C,pre) / L
    
|

     ,VERSION=1
          ,MF=S / C / D / E / L / M
         [,
PARAM=addr / (r)]
    
     ,PREFIX=J / pre
    
     ,MACID=VSC / macid
}


'cond.expr'
The condition is specified as a direct operand and must be enclosed in apostrophes. Because the apostrophe is used as a syntax character in assembler language, the following rules must be observed:
Each apostrophe within “cond.expression” must be doubled. The maximum length of “cond.expression” without the enclosing apostrophes is 127 bytes.
Special job variables are not allowed.

addr1

Symbolic address of a user program area containing the “cond.expression”.
The record format must be variable. The area starts with a 4-byte field, the first two bytes of which contain the length of the “cond.expression” in bytes + 4.

Example

SYMADR1      DC  Y(END-SYMADR1)
             DS  CL2
             DC  'conditional expression'
END          EQU *

(r1)
Register containing the address of the “cond.expression”, which must be in the format described under “addr1” above. The “cond.expression” must not contain special job variables.

EIID=
Names the event item ID made available to the user program by the TU eventing macro ENAEI. The ENAEI macro must be called before the ONEVT macro.

addr
Symbolic address of the event item ID.

(r)
Register containing the address of the event item ID.

POST=
Specifies a 2-byte value which can be used at program level to identify ONEVT. It is passed to the user program in the two rightmost bytes of the post code. The post code is four bytes long and is passed to the program when events such as “condition satisfied” etc. occur.

val
2-byte long Assembler constant of freely selectable format.

(r)

Register containing the address of a 2-byte field in which the user stored the “value”.

Post code format:

Event-dependent
indicator

Condition result

'ONEVT'
identification “value”

1 byte

1 byte

2 bytes

Meanings of the first two bytes:

    • event-dependent indicator:
      X'14'  specifies that the event was caused by an ONEVT macro.

    • condition result:
      specifies the “reason” for the POSSIG specified by the system.
      X'00':  condition satisfied
      X'08':  catalog exported

If the POST operand is not present, no “value” for the ONEVT identification (i.e. X'00000000') is transferred.

COUNT=
Specifies the maximum number of POSSIG macros that may be issued by the system (1 <= number <= 32767); default value = 1.
The COUNT operand determines how often a program will be notified of an event.

int
Number of POSSIG macros permitted for the “condition satisfied” event.
When this number is reached, the ONEVT macro is deactivated.
Irrespective of the COUNT operand entry, the ONEVT macro is deactivated immediately following a POSSIG macro caused by the event “catalog exported”, or by a DONEVT macro.

(r)
Register containing the address of a half word in which the value of the COUNT operand is stored.

VERSION=
Specifies which version of BS2000 the macro expansion is to be compatible with.

0
Default value; the macro expansion is compatible with JV <= V8.7.
With the C and D forms of this macro call a prefix (pre=1...3 letters) can be specified. Default: pre=ONE

1
The macro expansion is compatible with JV >= V10.0.
With the C form, D form or M form of the macro call a prefix (p=1 letter) can be specified, and with the C and D forms MACID also.

MF=
PREFIX=
MACID=
PARAM=
For a description of the MF, PREFIX, MACID and PARAM operands, see "The MF operand".
The permitted values and the defaults for MF for this macro are indicated at the beginning of the macro description, those for PREFIX and MACID in the description of the VERSION operand.

Function

Users can subject the result “condition satisfied” - about which they are informed by POSSIG - to BS2000-TU eventing as they see fit. For example, they may wait until “condition satisfied” has occurred (SOLSIG COND=) or a contingency process is executed asynchronously when “condition satisfied” applies (SOLSIG COID=...).


Return information and error flags

With VERSION=0:

R15





bb



aa

A return code relating to execution of the ONEVT macro (VERSION=0) is passed in register R15:

(aa = return switch, bb = secondary indicator)

X'bb'

X'aa'

Meaning

X'00'

X'00'

Execution terminated normally

X'00'

X'04'

Function not executed: invalid address for event item or condition or invalid COUNT value used

X'04'

X'04'

Function not executed: event item not found

X'08'

X'04'

Function not executed: invalid conditional expression

X'10'

X'04'

Function not executed: specified job variable cannot be accessed


X'FF'

Function not executed: CJC not available in the system

With VERSION=1:

Following initialization of the standard header (when MF=S/L is specified in the call), the return information is made available at the symbolic address <PREFIX><MACID>RET (4 bytes).

Standard-
header




ccbbaaaa
A return relating to execution of the ONEVT macro (VERSION=1) is passed in the standard header:
(aaaa = main code, bb = subcode1, cc = subcode2)

X'cc'

X'aaaa'

Meaning

X'00'

X'0000'

Execution terminated normally

X'00'

X'0004'

Function not executed: invalid address for condition or event item, or illegal value for COUNT

X'04'

X'0004'

Function not executed: event item not found

X'08'

X'0004'

Function not executed: error in condition

X'10'

X'0004'

Function not executed: a specified job variable cannot be accessed

X'14'

X'0004'

Function not executed: insufficient memory

X'18'

X'0004'

Function not executed: eventing mechanism not available


X'FFFF'

Function not executed: error during initialization of standard header. See chapter "Macro level".

In addition to the return codes named in VERSION=0 or 1, the general JV return codes for basic errors (e.g. invalid address for the operand list) may also appear. To find their meaning, see the relevant explanation under macro IDEJVS (see "Macro level").

DSECT

  ONEVT    ONEVT MF=D,VERSION=1
1 ONEVT    MFCHK MF=D,                                                   C
1                SUPPORT=(C,D,E,L,M,S),                                  C
1                PREFIX=J,                                               C
1                MACID=VSC,                                              C
1                DMACID=VSC,                                             C
1                DNAME=ONEVTPL,                                          C
1                PARAM=,                                                 C
1                SVC=190
2 ONEVT    DSECT ,
2                *,##### PREFIX=J, MACID=VSC #####
1 JVSCFHDR   FHDR  MF=(C,JVSC),EQUATES=NO
2 JVSCFHDR DS    0A
2 JVSCFHE  DS    0XL8            0   GENERAL PARAMETER AREA HEADER
2 *
2 JVSCIFID DS    0A              0   INTERFACE IDENTIFIER
2 JVSCFCTU DS    AL2             0   FUNCTION UNIT NUMBER
2 *                                  BIT 15    HEADER FLAG BIT,
2 *                                  MUST BE RESET UNTIL FURTHER NOTICE
2 *                                  BIT 14-12 UNUSED, MUST BE RESET
2 *                                  BIT 11-0  REAL FUNCTION UNIT NUMBER
2 JVSCFCT  DS    AL1             2   FUNCTION NUMBER
2 JVSCFCTV DS    AL1             3   FUNCTION INTERFACE VERSION NUMBER
2 *
2 JVSCRET  DS    0A              4   GENERAL RETURN CODE
2 JVSCSRET DS    0AL2            4   SUB RETURN CODE
2 JVSCSR2  DS    AL1             4   SUB RETURN CODE 2
2 JVSCSR1  DS    AL1             5   SUB RETURN CODE 1
2 JVSCMRET DS    0AL2            6   MAIN RETURN CODE
2 JVSCMR2  DS    AL1             6   MAIN RETURN CODE 2
2 JVSCMR1  DS    AL1             7   MAIN RETURN CODE 1
2 JVSCFHL  EQU   8               8   GENERAL OPERAND LIST HEADER LENGTH
2 *
1 JVSCUNU1   DS    CL3                        UNUSED
1 JVSCPCON   DS    X                          PARAM.-CONTROL
1 JVSCCORE   EQU   X'80'                      A(CONDITION) IN REGISTER
1 JVSCEREG   EQU   X'40'                      A(IDENTIFIER) IN REGISTER
1 JVSCPREG   EQU   X'20'                      POST IN REGISTER
1 JVSCCREG   EQU   X'10'                      COUNT IN REGISTER
1 JVSCPTPR   EQU   X'02'                      P2 CALLER 
1 JVSCCOND   DS    A                          A(CONDITION)
1          ORG   JVSCCOND
1 JVSCCONR   DS    AL1                        REG. CONT. A(COND.)
1          DS    AL3                          NOT USED IN THIS CONTEXT
1 JVSCEIID    DS    A                         A(IDENTIFIER)
1          ORG   JVSCEIID
1 JVSCEIDR   DS    AL1                        REG. CONT. A(IDENTIFIER)
1          DS    AL3                          NOT USED IN THIS CONTEXT
1 JVSCPOST   DS    H                          POST-VALUE
1          ORG   JVSCPOST
1 JVSCPOSR   DS    AL1                        REG. CONT. POST-VALUE
1          DS    AL1                          NOT USED IN THIS CONTEXT
1 JVSCCNT    DS    H                          COUNT-VALUE
1          ORG   JVSCCNT
1 JVSCCNTR   DS    AL1                        REG. CONT. COUNT-VALUE
1          DS    AL1                          NOT USED IN THIS CONTEXT
1 JVSCJVS    DS    F                          RESERVED
1 JVSC#      EQU   *-JVSCFHDR                 LENGTH
1 *
1 * RETURNCODES
1 *
1 JVSCOK     EQU   X'00000000'               SUCCESSFUL CALL
1 JVSCINAD   EQU   X'00010004'               INVALID PARM.-LIST
1 JVSCINEI   EQU   X'04010004'               INVALID IDENTIFIER
1 JVSCSYTE   EQU   X'08000004'               SYNTAX ERROR IN CONDITION
1 JVSCJVNA   EQU   X'10000004'               JV NOT ACCESSABLE
1 JVSCSYSE   EQU   X'14000004'               SYSTEM ERROR ($GETMEM)
1 JVSCBOER   EQU   X'18000004'               SYSTEM ERROR (BOURSES)