Boolean isTriggeredByEvent = parseBooleanAttribute(subProcessElement.attribute("triggeredByEvent"), false);
activity.setProperty("triggeredByEvent", isTriggeredByEvent);
// event subprocesses are not scopes
activity.setScope(!isTriggeredByEvent);
activity.setActivityBehavior(new SubProcessActivityBehavior());
parseScope(subProcessElement, activity);
for (BpmnParseListener parseListener : parseListeners) {
parseListener.parseSubProcess(subProcessElement, scope, activity);
}