use of org.kie.workbench.common.stunner.bpmn.backend.converters.customproperties.DeclarationList in project kie-wb-common by kiegroup.
the class AssignmentsInfos method of.
public static AssignmentsInfo of(final List<DataInput> datainput, final List<DataInputAssociation> inputAssociations, final List<DataOutput> dataoutput, final List<DataOutputAssociation> outputAssociations, boolean alternativeEncoding) {
DeclarationList inputs = dataInputDeclarations(datainput);
DeclarationList outputs = dataOutputDeclarations(dataoutput);
AssociationList associations = new AssociationList(inAssociationDeclarations(inputAssociations), outAssociationDeclarations(outputAssociations));
return new AssignmentsInfo(new ParsedAssignmentsInfo(inputs, outputs, associations, alternativeEncoding).toString());
}
use of org.kie.workbench.common.stunner.bpmn.backend.converters.customproperties.DeclarationList in project kie-wb-common by kiegroup.
the class SubProcessPropertyWriter method setProcessVariables.
public void setProcessVariables(ProcessVariables processVariables) {
String value = processVariables.getValue();
DeclarationList declarationList = DeclarationList.fromString(value);
List<Property> properties = process.getProperties();
declarationList.getDeclarations().forEach(decl -> {
VariableScope.Variable variable = variableScope.declare(this.process.getId(), decl.getIdentifier(), decl.getType());
properties.add(variable.getTypedIdentifier());
});
}
use of org.kie.workbench.common.stunner.bpmn.backend.converters.customproperties.DeclarationList in project kie-wb-common by kiegroup.
the class ProcessPropertyWriter method setProcessVariables.
public void setProcessVariables(ProcessVariables processVariables) {
String value = processVariables.getValue();
DeclarationList declarationList = DeclarationList.fromString(value);
List<Property> properties = process.getProperties();
declarationList.getDeclarations().forEach(decl -> {
VariableScope.Variable variable = variableScope.declare(this.process.getId(), decl.getIdentifier(), decl.getType());
properties.add(variable.getTypedIdentifier());
this.itemDefinitions.add(variable.getTypeDeclaration());
});
}
Aggregations