Business process family: tasks, gateways, events, pools and lanes

Overview

Base Control: BusinessControl : MaterialControl
Namespace: Beep.Skia.Business

The BusinessControl is the root control for this diagram family. It inherits MaterialControl and provides shared port management, styling, and template methods for all nodes in the family.

This family contains 23 node types.

Node Types

Node ClassShapeDescription
StartEventCircle (thin)Process start trigger.
EndEventCircle (thick)Process end/termination.
TaskNodeRounded rectangleGeneric task/activity.
BusinessTaskRounded rectangle + iconBusiness task with role assignment.
ActionNodeRounded rectangleManual/user action step.
DecisionDiamondExclusive gateway (XOR) decision point.
GatewayDiamond with iconGeneric gateway (AND/OR/XOR).
SubProcessRounded rectangle + expand iconExpandable sub-process with child diagram.
EventNodeCircle (intermediate)Intermediate event (timer, message, error, signal).
AnnotationOpen bracket with textText annotation for any element.
DatabaseCylinderDatabase data store.
DataStoreOpen-ended rectangleData repository (XML, file, document store).
DataObjectDocument with folded cornerData object passed between activities.
DocumentDocument iconDocument/report artifact.
ExternalDataCloud/databaseExternal data source connection.
DepartmentSwimlaneOrganizational department/unit swimlane.
PersonPerson iconIndividual actor/role.
RoleTag/labelRole definition for task assignment.
GroupBorder/containerGroup of related activities.
BusinessSystemServer/system boxIT system/service performing automated tasks.
RuleEngineHexagon/gearBusiness rules engine node.
RuleFlowArrow with conditionConditional flow governed by business rules.
ConditionBuilderExpression builderVisual condition/expression builder.

StartEvent

Process start trigger.

ShapeCircle (thin)
Input Ports0
Output Ports1

EndEvent

Process end/termination.

ShapeCircle (thick)
Input Ports1+
Output Ports0

TaskNode

Generic task/activity.

ShapeRounded rectangle
Input Ports1
Output Ports1

BusinessTask

Business task with role assignment.

ShapeRounded rectangle + icon
Input Ports1
Output Ports1

ActionNode

Manual/user action step.

ShapeRounded rectangle
Input Ports1
Output Ports1

Decision

Exclusive gateway (XOR) decision point.

ShapeDiamond
Input Ports1
Output Ports2+

Gateway

Generic gateway (AND/OR/XOR).

ShapeDiamond with icon
Input Ports1+
Output Ports1+

SubProcess

Expandable sub-process with child diagram.

ShapeRounded rectangle + expand icon
Input Ports1
Output Ports1

EventNode

Intermediate event (timer, message, error, signal).

ShapeCircle (intermediate)
Input Ports1
Output Ports1

Annotation

Text annotation for any element.

ShapeOpen bracket with text
Input Ports0
Output Ports0

Database

Database data store.

ShapeCylinder
Input Ports1
Output Ports1

DataStore

Data repository (XML, file, document store).

ShapeOpen-ended rectangle
Input Ports1
Output Ports1

DataObject

Data object passed between activities.

ShapeDocument with folded corner
Input Ports1
Output Ports1

Document

Document/report artifact.

ShapeDocument icon
Input Ports1
Output Ports1

ExternalData

External data source connection.

ShapeCloud/database
Input Ports1
Output Ports1

Department

Organizational department/unit swimlane.

ShapeSwimlane
Input Ports0
Output Ports0

Person

Individual actor/role.

ShapePerson icon
Input Ports1
Output Ports1

Role

Role definition for task assignment.

ShapeTag/label
Input Ports1
Output Ports1

Group

Group of related activities.

ShapeBorder/container
Input Ports0
Output Ports0

BusinessSystem

IT system/service performing automated tasks.

ShapeServer/system box
Input Ports1
Output Ports1

RuleEngine

Business rules engine node.

ShapeHexagon/gear
Input Ports1
Output Ports1

RuleFlow

Conditional flow governed by business rules.

ShapeArrow with condition
Input Ports0
Output Ports0

ConditionBuilder

Visual condition/expression builder.

ShapeExpression builder
Input Ports1
Output Ports1

Connection Points

Every node in this family exposes connection points (ports) for linking to other nodes. Port positions are computed lazily by LayoutPorts(), which runs when MarkPortsDirty() flags the layout as stale after a move or resize.

Node ClassInput PortsOutput PortsExtra
StartEvent01—
EndEvent1+0—
TaskNode11—
BusinessTask11—
ActionNode11—
Decision12+—
Gateway1+1+—
SubProcess11—
EventNode11—
Annotation00—
Database11—
DataStore11—
DataObject11—
Document11—
ExternalData11—
Department00—
Person11—
Role11—
Group00—
BusinessSystem11—
RuleEngine11—
RuleFlow00—
ConditionBuilder11—

Connection Conventions

When building diagrams with this family, follow these conventions:

  • Start events have no inputs; end events have no outputs
  • Gateways route flow based on conditions
  • Swimlanes (Department) partition the diagram horizontally
  • Data objects connect to activities via dashed association lines

Usage Example

Complete example showing creation, node placement, and connection:

C# Example

var biz = new BusinessControl
{
    X = 50, Y = 50,
    Width = 700, Height = 500
};
drawingManager.AddComponent(biz);

var start = new StartEvent { X = 80, Y = 200, EventName = "Order Received" };
var task = new BusinessTask { X = 220, Y = 200, TaskName = "Validate Order" };
var decision = new Decision { X = 380, Y = 200, DecisionName = "Valid?" };
var sys = new BusinessSystem { X = 200, Y = 350, SystemName = "ERP" };
var end = new EndEvent { X = 550, Y = 200, EventName = "Order Processed" };

drawingManager.AddComponent(start);
drawingManager.AddComponent(task);
drawingManager.AddComponent(decision);
drawingManager.AddComponent(sys);
drawingManager.AddComponent(end);

drawingManager.ConnectComponents(start.OutPoints[0], task.InPoints[0]);
drawingManager.ConnectComponents(task.OutPoints[0], decision.InPoints[0]);
drawingManager.ConnectComponents(decision.OutPoints[1], sys.InPoints[0]);

BPMN Import and Export

The family round-trips BPMN 2.0 XML so diagrams can be exchanged with process-modeling tools:

MemberTypeDescription
BpmnExporter.Export(components, lines, processName)stringSerializes the diagram to BPMN XML.
BpmnImporter.Parse(xml)BpmnImportResultParses XML without touching the canvas.
BpmnImporter.LoadInto(manager, xml)BpmnImportResultParses and materializes the process on a canvas.
BpmnImportResult.ProcessNamestringName of the imported process.
BpmnImportResult.Components / FlowslistsCreated nodes and sequence flows.
BpmnImportResult.WarningsList<string>Non-fatal issues encountered while parsing.
// Export the current diagram
var exporter = new BpmnExporter();
string xml = exporter.Export(drawingManager.GetComponents(), drawingManager.GetLines(), "Order Process");
File.WriteAllText("process.bpmn", xml);

// Import into a fresh canvas
var importer = new BpmnImporter();
var result = importer.LoadInto(drawingManager, File.ReadAllText("process.bpmn"));
foreach (var warning in result.Warnings)
    Console.WriteLine($"warning: {warning}");