« Back to Fachhochschule Nordwestschweiz FHNW

Rule Family Table (Table in ADOxx)

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Rule Family Table (Table in ADOxx)
Answer
5/12/14 12:59 PM
Dear ADOx.org Team,
I would like to ask some questions. I created the Decision Model Diagram on based of the Decision Model of Barbara von Halle and Larry Goldberg. In this diagram there is an octagonal shape that called, "Business Decision". The Business Decision is connected to different hexagonal shapes that called, "Rule Family". Moreover, the Rule Family shape is connected to the table that called "Rule Family Table" by using an attribute of the type "Intermodel reference". In the Rule Family-GraphRep I used the option TEXT and I inserted the names in general; Conclusion, Inferred Conditions and Conditions. (As Figure shows)

My questions are:
1) How can have the possibility to insert the names in this shape during the use of ADOxx Modelling Toolkit, instead of having fix names. That menas the shape have to be divide in 3 parts:
- First part shows Conclusion name
- Second part shows differenet Conditions names (Inferred Conditions)
- Third part shows different Conditions names (Another kind of Conditions)

For example instead of having the general name of "Conclusion" in the shape, I could have the possibility to write the name as "Policy Renewal Override", thus in this way I can reuse this shape several time. The same of Conditions as well.

2) And if there is any possibility for inserting the names in this shape, how can it appear this change automatically in the Rule family Table in the first row?


Thank you
Attachment

Attachment

Attachments: Example.jpg (45.8k), Question.jpg (40.6k)

Moved to implementation team category.
Answer
5/12/14 3:14 PM as a reply to Anonymous.
Moved to implementation team category.

RE: Rule Family Table (Table in ADOxx)
Answer
5/15/14 8:56 AM as a reply to Anonymous.
In order to accomplish this, please have a look at the GRAPHREP section (http://www.adoxx.org/live/graphrep) of the documentation page and the GRAPHREP repository (http://www.adoxx.org/live/adoxx-graphrep-repository).

We propose the following approach:
1. Access table content using AVAL and set-row, set-col statements in GRAPHREP
2. Represent it in the GRAPHREP implementation of the object

Attached a sample implementation of the proposal as an ABL and also the GRAPHREP code:


 1GRAPHREP layer:-1
 2AVAL set-row: (1) set-col:"Conclusion" dep:"Rule Family Table"
 3TEXT (dep) x:-.0cm y:-2.3cm w:c:3.5cm h:t line-break:words
 4
 5AVAL set-row: (1) set-col:"Condition n.1" dep:"Rule Family Table"
 6TEXT (dep) x:-.0cm y:-.8cm w:c:3.5cm h:t line-break:words color: black
 7
 8AVAL set-row: (1) set-col:"Condition n.2" dep:"Rule Family Table"
 9TEXT (dep) x:-.0cm y:0.8cm w:c:3.5cm h:t line-break:words
10
11#=====================================================
12
13# select type for color
14AVAL atype:"Type"
15
16
17IF (atype = "DRF")
18{
19  FONT h:0.3cm color: black bold
20  TEXT "DRF" x:-1.5cm y:1.5cm w:c
21}
22
23ELSIF (atype = "RF")
24{
25  FONT h:0.3cm color:red bold
26  TEXT "RF" x:-1.5cm y:1.5cm w:c
27}
28
29
30PEN w:0.05cm color:gray
31LINE x1:1cm y1:-1.5cm x2:-1cm y2:-1.5cm
32
33PEN w:0.02cm style:dash color:black
34LINE x1:1cm y1:0.3cm x2:-1cm y2:0.3cm
35
36PEN w:0.1cm color:black
37POLYGON 7
38 x1:2cm     y1:2cm
39 x2:-2cm    y2:2cm
40 x3:-2cm    y3:-2cm
41 x4:-1cm    y4:-3cm
42 x5:1cm     y5:-3cm
43 x6:2cm     y6:-2cm
44 x7:2cm     y7:1cm
45
46
47#===============================================================
Attachments: GRAPHREP Table Content.abl (13.7k)

RE: Rule Family Table (Table in ADOxx)
Answer
5/21/14 8:04 AM as a reply to Wilfrid Utz.
Dear ADOx.org Team,
Thank you very much for your time and help in answering my question.
I would like to ask another question about the FILL color. I tried to use the "FILL color:lightgreen", because I would like to have the base colore for this shape but after added it, I cannot see the separation lines. How can solve this problem?
Attachment

Attachments: FILL color.PNG (15.3k)

RE: Rule Family Table (Table in ADOxx)
Answer
5/26/14 1:20 PM as a reply to Anonymous.
Thanks for your message. The reason for this behaviour is that in GRAPHREP the code is executed sequentially and builds upon each other. This means that the lines are actually there but behin the filled POLYGON. Please find below an update the also shows the lines.

 1GRAPHREP layer:-1
 2AVAL set-row: (1) set-col:"Conclusion" dep:"Rule Family Table"
 3TEXT (dep) x:-.0cm y:-2.3cm w:c:3.5cm h:t line-break:words
 4
 5AVAL set-row: (1) set-col:"Condition n.1" dep:"Rule Family Table"
 6TEXT (dep) x:-.0cm y:-.8cm w:c:3.5cm h:t line-break:words color: black
 7
 8AVAL set-row: (1) set-col:"Condition n.2" dep:"Rule Family Table"
 9TEXT (dep) x:-.0cm y:0.8cm w:c:3.5cm h:t line-break:words
10
11#=====================================================
12
13# select type for color
14AVAL atype:"Type"
15
16
17IF (atype = "DRF")
18{
19  FONT h:0.3cm color: black bold
20  TEXT "DRF" x:-1.5cm y:1.5cm w:c
21}
22
23ELSIF (atype = "RF")
24{
25  FONT h:0.3cm color:red bold
26  TEXT "RF" x:-1.5cm y:1.5cm w:c
27}
28
29
30PEN w:0.1cm color:black
31FILL color:lightgreen
32POLYGON 7
33 x1:2cm     y1:2cm
34 x2:-2cm    y2:2cm
35 x3:-2cm    y3:-2cm
36 x4:-1cm    y4:-3cm
37 x5:1cm     y5:-3cm
38 x6:2cm     y6:-2cm
39 x7:2cm     y7:1cm
40
41PEN w:0.05cm color:gray
42LINE x1:1cm y1:-1.5cm x2:-1cm y2:-1.5cm
43
44PEN w:0.02cm style:dash color:black
45LINE x1:1cm y1:0.3cm x2:-1cm y2:0.3cm
46
47
48#===============================================================