DIAC1 ;SLCISC/KCM,MKB - Policy Evaluation API's ;17FEB2017
Source file <DIAC1.m>
action | A | extended action | Ea | event driver | Ed | subscriber | Su | protocol | O | limited protocol | LP | run routine | RR | broker | B | edit | E | server | Se | P | screenman | SM | inquire | I |
Package | Total | Caller Graph |
---|---|---|
VA FileMan | 2 | DDEG DIAC1T |
Name | Comments | DBIA/ICR reference |
---|---|---|
CANDO(DIFN,DIENS,DIACTN,DIUSR,DIVAL,DIFLDS,DITXT,DIERROR) | ;main API
; Can user take requested action on [given record in] this file? ; ; Returns 1 = Yes (permit) ; 0 = No (deny) ; "" = Undetermined/no applicable policy ; -1 = Error |
|
C1 | ; find & evaluate policy
|
|
CQ | ;return result
|
|
FIND(FILE,ACTION) | ; -- find matching Event, return Policy^Event iens
|
|
FQ | ||
EN | ; -- process policy DIPOL, returns DIRESULT (P/D)
; Expects all input parameters from $$CANDO to be defined and valid ; If DIZTRACE = true, the execution trace will be captured |
|
ENQ | ; exit
|
|
POP | ; -- pop the stack [set]
|
|
PROC | ; -- process member
|
|
POLICY(DIEN) | ; -- loop on matching rules of policy DIEN
|
|
MATCH(IEN) | ; -- return 1 or 0, if target matches
|
|
MQ | ;done
|
|
DISABLED(IEN) | ; -- return 1 or 0, if item is disabled
|
|
FCN(IEN) | ; -- run attribute function to accummulate DIVAL(key)=value
|
|
DONE(IEN) | ; -- return 1 or 0, if quit condition is met for policy IEN
|
|
COND(IEN) | ; -- evaluate any rule IEN conditions [return boolean in Y]
|
|
ADDMSG(IEN,RES) | ; -- add line to DIMSG array
|
|
MSG() | ;
|
|
OBLIG(IEN,RES) | ; -- execute obligation code
|
|
FIELDS(IEN,FN) | ; -- return available fields in DIFLDS
|
|
VIENS(IENS,FN) | ; -- validate IENS string for file# FN
|
|
ERROR(CODE,PARAM,TYPE) | ; -- create error message
|
|
TRACE(IEN,STK,ACT,COND) | ; -- set trace array
; DIZTRACE(#) = PolicyIEN ^ stack level ^ match? (1/0) ; or = PolicyIEN ^ stack level ^ done (2) ^ ResultFcnIEN ; DIZTRACE(#,c) = ConditionDA ^ stack level ^ result (1/0) |
|
NXT() | ; -- increment trace array subscript
|
Name | Line Occurrences (* Changed, ! Killed) |
---|---|
^DIAC( | FIELDS+3, FIELDS+4, FIELDS+5 |
^DIAC(1.6 - [#1.6] | EN+11, EN+20, PROC+3, PROC+11, POLICY+5, POLICY+6, POLICY+12, MATCH+2, MATCH+3, MATCH+5 , DISABLED+1, FCN+2, FCN+6, COND+2, COND+4, COND+5, ADDMSG+3, OBLIG+3, TRACE+6 |
^DIAC(1.61 - [#1.61] | CANDO+18, FIND+3, FIND+4 |
^DIAC(1.62 - [#1.62] | FCN+3, FCN+7, FCN+8, COND+8, OBLIG+4 |
^TMP("DIERR" | VIENS+6 |
^TMP("DIMSG" | EN+8 |
^VA(200 - [#200] | CANDO+14, CANDO+15 |
Name | Line Occurrences |
---|---|
$$COND | POLICY+13 |
$$DISABLED | EN+5, PROC+8, POLICY+9 |
$$DONE | EN+20, POLICY+5 |
$$FIND | C1+1 |
$$MATCH | PROC+7, POLICY+8 |
$$MSG | ADDMSG+10 |
$$NXT | TRACE+7 |
$$POLICY | EN+12, PROC+16 |
$$VIENS | CANDO+25 |
@( | EN+20 |
ADDMSG | POP+5, POLICY+16, POLICY+22 |
C1 | CANDO+17 |
CQ | CANDO+17, CANDO+23, CANDO+24, CANDO+25, CANDO+26 |
EN | C1+2 |
ENQ | EN+12 |
ERROR | CANDO+14, CANDO+19, CANDO+23, CANDO+24, CANDO+26, EN+4, EN+13, VIENS+7 |
FCN | EN+10, PROC+4, POLICY+7 |
FIELDS | CQ+2, POP+5, POLICY+16, POLICY+22 |
FQ | FIND+2 |
OBLIG | POP+5, POLICY+16, POLICY+22 |
TRACE | EN+5, EN+14, POP+1, PROC+7, PROC+8, PROC+12, POLICY+2, POLICY+5, POLICY+8, POLICY+9 , POLICY+10, POLICY+18, COND+9 |
Name | Field # of Occurrence |
---|---|
^( | COND+4, FIELDS+5 |
>> | Not killed explicitly |
* | Changed |
! | Killed |
~ | Newed |
Name | Field # of Occurrence |
---|---|
ACT | TRACE~, TRACE+5, TRACE+6, TRACE+7 |
ACTION | FIND~, FIND+2, FIND+3 |
CODE | FCN+1~, FCN+3*, DONE+1~, DONE+3*, COND+1~, COND+8*, OBLIG+1~, OBLIG+4*, ERROR~, ERROR+1 , ERROR+3 |
COND | TRACE~, TRACE+5 |
CONJ | MATCH+1~, MATCH+2*, MATCH+7, COND+1~, COND+2*, COND+10 |
DA | COND+1~, COND+4*, COND+5, COND+9 |
DIACMSG | EN+7~ |
DIACMSG( | ENQ+2, ENQ+3, ENQ+4, ADDMSG+10*, MSG+1, MSG+2* |
DIACT | CANDO+8~, CANDO+20*, C1+1*, CQ+2 |
DIACTN | CANDO~, CANDO+17, CANDO+18, CANDO+20*, CANDO+26, C1+1 |
DIEFFECT | POLICY+1~, POLICY+12*, POLICY+13, POLICY+14 |
DIEM | PROC+1~, PROC+3*, PROC+4, PROC+7, PROC+8, PROC+11, PROC+12, PROC+13, PROC+16 |
DIEN | POLICY~, POLICY+1, POLICY+2, POLICY+5, POLICY+6, POLICY+18, POLICY+21, POLICY+22 |
DIENS | CANDO~, CANDO+25 |
>> DIERR | CANDO+17, CQ+1, VIENS+2 |
DIERROR | CANDO~, VIENS+2, VIENS+4, VIENS+5, VIENS+6, ERROR+1, ERROR+3 |
DIFCN | EN+7~ |
DIFCN( | ENQ+1, POP+4, POLICY+21, FCN+7*, FCN+8*, DONE+3 |
DIFLDS | CANDO~, CANDO+9!, CQ+2, FIELDS+2, FIELDS+4* |
DIFLDS( | FIELDS+7*, FIELDS+8* |
DIFN | CANDO~, CANDO+21*, CANDO+23, CANDO+24, CANDO+25, C1+1 |
DII | COND+1~, COND+3*, COND+4*, COND+9 |
>> DIMSG | ENQ+3* |
DIPOL | CANDO+8~, CANDO+20*, C1+1*, C1+2*, EN+4, EN+5, EN+10, EN+11, EN+12, EN+13 , EN+14, EN+19, ENQ+1 |
DIRESULT | CANDO+8~, CANDO+10*, CQ+1, EN+12*, ENQ+1*, ENQ+2, ENQ+3, ENQ+4, POP+4*, POP+5 , PROC+16*, POLICY+1~, POLICY+4*, POLICY+13*, POLICY+14*, POLICY+16, POLICY+17, POLICY+21*, POLICY+22, POLICY+23 , FIELDS+1 |
DIRULE | POLICY+1~, POLICY+6*, POLICY+7, POLICY+8, POLICY+9, POLICY+10, POLICY+12, POLICY+13, POLICY+16 |
DISEQ | EN+7~, EN+19*, EN+20*, POP+8*, PROC+2, PROC+3, PROC+13*, POLICY+1~, POLICY+4*, POLICY+5* , POLICY+6, POLICY+18 |
DISTK | EN+7~, EN+11*, EN+14, EN+19*, EN+20, POP+1, POP+4, POP+5, POP+8*, PROC+2 , PROC+3, PROC+7, PROC+8, PROC+12, PROC+13*, POLICY+2, POLICY+5, POLICY+8, POLICY+9, POLICY+10 , POLICY+18, COND+9 |
DISTK( | EN+19*, EN+20, POP+1, POP+4, POP+5, POP+8, PROC+2*, PROC+3, PROC+13* |
DISTK(0 | EN+19* |
DITXT | CANDO~, EN+8*, ENQ+4 |
DITYPE | EN+7~, EN+11*, EN+12, EN+13 |
DIUSR | CANDO~, CANDO+13*, CANDO+14, CANDO+15 |
DIUSRNM | CANDO+8~, CANDO+15* |
DIVAL | CANDO~ |
DIVAL( | MATCH+4, ADDMSG+7 |
DIX | ERROR+2~, ERROR+3 |
DIX(1 | ERROR+2* |
DIX(2 | ERROR+2* |
>> DIZ | POLICY+17, TRACE+5, NXT+1*, NXT+2 |
>> DIZTRACE | EN+5, EN+14, POP+1, PROC+7, PROC+8, PROC+12, POLICY+2, POLICY+5, POLICY+8, POLICY+9 , POLICY+10, POLICY+17, POLICY+18, COND+9, FIELDS+9 |
>> DIZTRACE( | POLICY+17*, TRACE+5*, TRACE+7* |
>> DIZTRACE("FLDS" | FIELDS+9* |
DONE | MATCH+1~, MATCH+2*, MATCH+3, MATCH+7*, COND+1~, COND+2*, COND+4, COND+10* |
DR | FIELDS+4~, FIELDS+6*, FIELDS+7, FIELDS+8 |
DUZ | CANDO+13 |
FCN | FCN+1~, FCN+2*, FCN+3, FCN+6*, FCN+7, FCN+8, COND+1~, COND+7*, COND+8, OBLIG+1~ , OBLIG+3*, OBLIG+4 |
FILE | FIND~, FIND+2, FIND+3 |
FN | FIELDS~, FIELDS+3, FIELDS+4, FIELDS+5, FIELDS+9, VIENS~, VIENS+1 |
GBL | VIENS+1~*, VIENS+7 |
I | FIND+1~, FIND+3*, FIND+4, FIND+5, ADDMSG+1~, ADDMSG+5*, ADDMSG+6, ADDMSG+7, MSG+1~*, MSG+2 , MSG+3, FIELDS+4~*, FIELDS+5*, VIENS+4~*, VIENS+5*, VIENS+6 |
IEN | MATCH~, MATCH+2*, MATCH+3, MATCH+5, DISABLED~, DISABLED+1, FCN~, FCN+1*, FCN+2, FCN+6 , FCN+7, FCN+8, DONE~, DONE+2*, DONE+3, COND~, COND+2*, COND+4, COND+5, ADDMSG~ , ADDMSG+3, OBLIG~, OBLIG+3, FIELDS~, FIELDS+3, FIELDS+4, FIELDS+5, FIELDS+9, TRACE~, TRACE+5 , TRACE+6, TRACE+7 |
IENS | VIENS~, VIENS+1, VIENS+7 |
KEY | MATCH+1~, MATCH+3*, MATCH+4, MATCH+5 |
L | FIELDS+4~, FIELDS+6*, FIELDS+7, FIELDS+8 |
N | ADDMSG+1~, ADDMSG+2*, ADDMSG+3, OBLIG+1~, OBLIG+2*, OBLIG+3 |
PARAM | ERROR~, ERROR+1, ERROR+2 |
RES | ADDMSG~, ADDMSG+1, ADDMSG+2, ADDMSG+10, MSG+1, MSG+2, OBLIG~, OBLIG+1, OBLIG+2, TRACE+6~* , TRACE+7 |
S | FIELDS+4~, FIELDS+6*, FIELDS+7 |
STK | TRACE~, TRACE+5, TRACE+7 |
TYPE | ERROR~, ERROR+1, ERROR+2 |
U | CANDO+15, CANDO+20, CANDO+21, C1+1, FIND+4, FIND+5, EN+11, POP+8, PROC+2, PROC+11 , POLICY+12, POLICY+17, MATCH+2, DISABLED+1, FCN+2, FCN+6, FCN+8, COND+2, COND+5, COND+7 , ADDMSG+3, FIELDS+6, FIELDS+9, TRACE+5, TRACE+6, TRACE+7 |
X | FIND+1~, FIND+4*, FIND+5, MATCH+1~, MATCH+4*, MATCH+5, COND+1~, COND+5*, ADDMSG+1~, ADDMSG+3* , ADDMSG+4, ADDMSG+5, ADDMSG+6*, ADDMSG+7*, ADDMSG+8*, ADDMSG+10, FIELDS+5*, FIELDS+6, FIELDS+7, FIELDS+8 |
X0 | CANDO+18~*, CANDO+19, CANDO+20, CANDO+21, COND+1~, COND+5*, COND+7 |
Y | CANDO+8~, CQ+1*, CQ+2, CQ+3, FIND+1~*, FIND+3, FIND+5*, FQ, MATCH+1~, MATCH+2* , MATCH+5*, MATCH+6*, MATCH+7, MQ+1, DONE+1~, DONE+2*, DONE+5, COND+1~, COND+3*, COND+9 , COND+10, COND+11, ADDMSG+1~, ADDMSG+5*, ADDMSG+6, ADDMSG+7 |