Class ProcessDiagramLayoutFactory
java.lang.Object
org.camunda.bpm.engine.impl.bpmn.diagram.ProcessDiagramLayoutFactory
Provides positions and dimensions of elements in a process diagram as
provided by
RepositoryService.getProcessDiagram(String).- Author:
- Falko Menge
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected Map<String,DiagramNode> fixFlowNodePositionsIfModelFromAdonis(Document bpmnModel, Map<String, DiagramNode> elementBoundsFromBpmnDi) getBpmnProcessDiagramLayout(Document bpmnModel, InputStream imageStream) Provides positions and dimensions of elements in a BPMN process diagram as provided byRepositoryService.getProcessDiagram(String).protected DocumentBuilderFactoryprotected DiagramNodegetDiagramBoundsFromBpmnDi(Document bpmnModel) protected DiagramNodegetDiagramBoundsFromImage(BufferedImage image, int offsetTop, int offsetBottom) protected DiagramNodegetDiagramBoundsFromImage(InputStream imageStream) protected DiagramNodegetDiagramBoundsFromImage(InputStream imageStream, int offsetTop, int offsetBottom) protected Map<String,DiagramNode> getElementBoundsFromBpmnDi(Document bpmnModel) getProcessDiagramLayout(InputStream bpmnXmlStream, InputStream imageStream) Provides positions and dimensions of elements in a process diagram as provided byRepositoryService.getProcessDiagram(String).protected booleanisExportedFromAdonis50(Document bpmnModel) protected DiagramNodeparseBounds(Element boundsElement) protected DocumentparseXml(InputStream bpmnXmlStream) protected Map<String,DiagramElement> transformBoundsForImage(DiagramNode diagramBoundsImage, DiagramNode diagramBoundsXml, Map<String, DiagramNode> listOfBounds) protected DiagramNodetransformBoundsForImage(DiagramNode diagramBoundsImage, DiagramNode diagramBoundsXml, DiagramNode elementBounds)
-
Constructor Details
-
ProcessDiagramLayoutFactory
public ProcessDiagramLayoutFactory()
-
-
Method Details
-
getProcessDiagramLayout
Provides positions and dimensions of elements in a process diagram as provided byRepositoryService.getProcessDiagram(String). Currently, it only supports BPMN 2.0 models.- Parameters:
bpmnXmlStream- BPMN 2.0 XML fileimageStream- BPMN 2.0 diagram in PNG format (JPEG and other formats supported byImageIOmay also work)- Returns:
- Layout of the process diagram
-
getBpmnProcessDiagramLayout
Provides positions and dimensions of elements in a BPMN process diagram as provided byRepositoryService.getProcessDiagram(String).- Parameters:
bpmnModel- BPMN 2.0 XML documentimageStream- BPMN 2.0 diagram in PNG format (JPEG and other formats supported byImageIOmay also work)- Returns:
- Layout of the process diagram
-
parseXml
-
getDiagramBoundsFromBpmnDi
-
getDiagramBoundsFromImage
-
getDiagramBoundsFromImage
protected DiagramNode getDiagramBoundsFromImage(InputStream imageStream, int offsetTop, int offsetBottom) -
getDiagramBoundsFromImage
protected DiagramNode getDiagramBoundsFromImage(BufferedImage image, int offsetTop, int offsetBottom) -
getElementBoundsFromBpmnDi
-
parseBounds
-
transformBoundsForImage
protected Map<String,DiagramElement> transformBoundsForImage(DiagramNode diagramBoundsImage, DiagramNode diagramBoundsXml, Map<String, DiagramNode> listOfBounds) -
transformBoundsForImage
protected DiagramNode transformBoundsForImage(DiagramNode diagramBoundsImage, DiagramNode diagramBoundsXml, DiagramNode elementBounds) -
fixFlowNodePositionsIfModelFromAdonis
protected Map<String,DiagramNode> fixFlowNodePositionsIfModelFromAdonis(Document bpmnModel, Map<String, DiagramNode> elementBoundsFromBpmnDi) -
isExportedFromAdonis50
-
getConfiguredDocumentBuilderFactory
-