[
https://issues.jboss.org/browse/DROOLS-3475?page=com.atlassian.jira.plugi...
]
Michael Anstis updated DROOLS-3475:
-----------------------------------
Description:
The {{DecisionService}} node contains lists of {{DMNElementReference}} for "Output
Decisions", "Encapsulated Decisions", "Input Decision" and
"Input Data". These are currently only populated when unmarshalling a DMN XML
file to Stunner model. Their members are not maintained as and when Users add, delete etc
nodes that could affect them. They are used as reference when marshalling back from
Stunner to DML XML to maintain the positional information \[*\] of such references.
The {{DecisionService}} node reference lists should be updated as and when the User
interacts with the diagram (e.g. add/remove "Output Decision" to/from the
"Decision Service", add/remove "Encapsulated Decision" to/from the
"Decision Service", add/remove an "Input Data" or "Input
Decision" reference to/from the "Decision Service" or move the
"splitter" in such a way that could affect the "Output/Encapsulated"
Decisions. This will require (at least) custom commands for add/remove child, add
connection and update property (splitter location).
\[*\] See
[
here|https://github.com/kiegroup/kie-wb-common/blob/master/kie-wb-common-...]
that uses the order of the references set-up during marshalling from XML to Stunner to
ensure identical references maintain the same index in the list marshalled from Stunner to
XML. This is a DMN Specification requirement that "positional information" is
preserved (without using this transient mechanism it would otherwise be impossible to
preserve the index order as XML->Stunner looses the lists and Stunner->XML walks the
graph to add element references to the Decision Service. The original ordering is lost by
the conversion from {{List}} to _Graph_ to {{List}}.
This "workaround" to preserve ordering should NOT be required when the integrity
of {{DecisionService}} Node's element references is maintained by custom commands.
was:
The {{DecisionService}} node contains lists of {{DMNElementReference}} for "Output
Decisions", "Encapsulated Decisions", "Input Decision" and
"Input Data". These are currently only populated when unmarshalling a DMN XML
file to Stunner model. Their members are not maintained as and when Users add, delete etc
nodes that could affect them. They are used as reference when marshalling back from
Stunner to DML XML to maintain the positional information \[*\] of such references.
The {{DecisionService}} node reference lists should be updated as and when the User
interacts with the diagram (e.g. add/remove "Output Decision" to/from the
"Decision Service", add/remove "Encapsulated Decision" to/from the
"Decision Service", add/remove an "Input Data" or "Input
Decision" reference to/from the "Decision Service" or move the
"splitter" in such a way that could affect the "Output/Encapsulated"
Decisions. This will require (at least) custom commands for add/remove child, add
connection and update property (splitter location).
\[*\] See
[
here|https://github.com/kiegroup/kie-wb-common/blob/master/kie-wb-common-...]
that uses the order of the references set-up during marshalling from XML to Stunner to
ensure identical references maintain the same index in the list marshalled from Stunner to
XML. This is a DMN Specification requirement that "positional information" is
preserved (without using this transient mechanism it would otherwise be impossible to
preserve the index order as XML->Stunner looses the lists and Stunner->XML walks the
graph to add element references to the Decision Service. The original ordering is lost by
the conversion from {{List}}->_Graph_->{{List}}.
This "workaround" to preserve ordering should NOT be required when the integrity
of {{DecisionService}} Node's element references is maintained by custom commands.
[DMN Designer] Ensure integrity of DecisionService node
-------------------------------------------------------
Key: DROOLS-3475
URL:
https://issues.jboss.org/browse/DROOLS-3475
Project: Drools
Issue Type: Enhancement
Components: DMN Editor
Affects Versions: 7.15.0.Final
Reporter: Michael Anstis
Assignee: Michael Anstis
Priority: Major
Labels: drools-tools
The {{DecisionService}} node contains lists of {{DMNElementReference}} for "Output
Decisions", "Encapsulated Decisions", "Input Decision" and
"Input Data". These are currently only populated when unmarshalling a DMN XML
file to Stunner model. Their members are not maintained as and when Users add, delete etc
nodes that could affect them. They are used as reference when marshalling back from
Stunner to DML XML to maintain the positional information \[*\] of such references.
The {{DecisionService}} node reference lists should be updated as and when the User
interacts with the diagram (e.g. add/remove "Output Decision" to/from the
"Decision Service", add/remove "Encapsulated Decision" to/from the
"Decision Service", add/remove an "Input Data" or "Input
Decision" reference to/from the "Decision Service" or move the
"splitter" in such a way that could affect the "Output/Encapsulated"
Decisions. This will require (at least) custom commands for add/remove child, add
connection and update property (splitter location).
\[*\] See
[
here|https://github.com/kiegroup/kie-wb-common/blob/master/kie-wb-common-...]
that uses the order of the references set-up during marshalling from XML to Stunner to
ensure identical references maintain the same index in the list marshalled from Stunner to
XML. This is a DMN Specification requirement that "positional information" is
preserved (without using this transient mechanism it would otherwise be impossible to
preserve the index order as XML->Stunner looses the lists and Stunner->XML walks the
graph to add element references to the Decision Service. The original ordering is lost by
the conversion from {{List}} to _Graph_ to {{List}}.
This "workaround" to preserve ordering should NOT be required when the
integrity of {{DecisionService}} Node's element references is maintained by custom
commands.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)