Search in sources :

Example 21 with OutputClause

use of org.kie.dmn.model.api.OutputClause in project drools by kiegroup.

the class DecisionTableConverter method writeChildren.

@Override
protected void writeChildren(HierarchicalStreamWriter writer, MarshallingContext context, Object parent) {
    super.writeChildren(writer, context, parent);
    DecisionTable dt = (DecisionTable) parent;
    for (InputClause i : dt.getInput()) {
        writeChildrenNode(writer, context, i, INPUT);
    }
    for (OutputClause o : dt.getOutput()) {
        writeChildrenNode(writer, context, o, OUTPUT);
    }
    for (RuleAnnotationClause a : dt.getAnnotation()) {
        writeChildrenNode(writer, context, a, ANNOTATION);
    }
    for (DecisionRule r : dt.getRule()) {
        writeChildrenNode(writer, context, r, RULE);
    }
}
Also used : OutputClause(org.kie.dmn.model.api.OutputClause) DecisionTable(org.kie.dmn.model.api.DecisionTable) TDecisionTable(org.kie.dmn.model.v1_3.TDecisionTable) RuleAnnotationClause(org.kie.dmn.model.api.RuleAnnotationClause) InputClause(org.kie.dmn.model.api.InputClause) DecisionRule(org.kie.dmn.model.api.DecisionRule)

Example 22 with OutputClause

use of org.kie.dmn.model.api.OutputClause in project drools by kiegroup.

the class DecisionTableConverter method writeChildren.

@Override
protected void writeChildren(HierarchicalStreamWriter writer, MarshallingContext context, Object parent) {
    super.writeChildren(writer, context, parent);
    DecisionTable dt = (DecisionTable) parent;
    for (InputClause i : dt.getInput()) {
        writeChildrenNode(writer, context, i, INPUT);
    }
    for (OutputClause o : dt.getOutput()) {
        writeChildrenNode(writer, context, o, OUTPUT);
    }
    for (RuleAnnotationClause a : dt.getAnnotation()) {
        writeChildrenNode(writer, context, a, ANNOTATION);
    }
    for (DecisionRule r : dt.getRule()) {
        writeChildrenNode(writer, context, r, RULE);
    }
}
Also used : OutputClause(org.kie.dmn.model.api.OutputClause) DecisionTable(org.kie.dmn.model.api.DecisionTable) TDecisionTable(org.kie.dmn.model.v1_4.TDecisionTable) RuleAnnotationClause(org.kie.dmn.model.api.RuleAnnotationClause) InputClause(org.kie.dmn.model.api.InputClause) DecisionRule(org.kie.dmn.model.api.DecisionRule)

Aggregations

OutputClause (org.kie.dmn.model.api.OutputClause)22 DecisionTable (org.kie.dmn.model.api.DecisionTable)7 InputClause (org.kie.dmn.model.api.InputClause)7 DecisionRule (org.kie.dmn.model.api.DecisionRule)5 QName (javax.xml.namespace.QName)4 TOutputClause (org.kie.dmn.model.v1_2.TOutputClause)4 ArrayList (java.util.ArrayList)3 Decision (org.kie.dmn.model.api.Decision)3 TOutputClause (org.kie.dmn.model.v1_1.TOutputClause)3 TOutputClause (org.kie.dmn.model.v1_3.TOutputClause)3 DMNType (org.kie.dmn.api.core.DMNType)2 BaseDMNTypeImpl (org.kie.dmn.core.impl.BaseDMNTypeImpl)2 InformationItem (org.kie.dmn.model.api.InformationItem)2 LiteralExpression (org.kie.dmn.model.api.LiteralExpression)2 RuleAnnotationClause (org.kie.dmn.model.api.RuleAnnotationClause)2 TDecisionTable (org.kie.dmn.model.v1_2.TDecisionTable)2 TOutputClause (org.kie.dmn.model.v1_4.TOutputClause)2 File (java.io.File)1 FileOutputStream (java.io.FileOutputStream)1 IOException (java.io.IOException)1