use of org.kie.workbench.common.stunner.bpmn.backend.converters.fromstunner.properties.DataObjectPropertyWriter in project kie-wb-common by kiegroup.
the class ArtifactsConverter method toDataObjectAnnotation.
private PropertyWriter toDataObjectAnnotation(Node<View<DataObject>, ?> node) {
org.eclipse.bpmn2.DataObjectReference element = bpmn2.createDataObjectReference();
element.setId(node.getUUID());
DataObjectPropertyWriter writer = propertyWriterFactory.of(element);
DataObject definition = node.getContent().getDefinition();
writer.setName(StringUtils.replaceIllegalCharsAttribute(StringUtils.replaceIllegalCharsForDataObjects(definition.getName().getValue())));
writer.setType(definition.getType().getValue().getType());
writer.setMetaData(definition.getAdvancedData().getMetaDataAttributes());
writer.setAbsoluteBounds(node);
return writer;
}
Aggregations