use of org.wso2.carbon.bpel.core.ode.integration.utils.ActivityLifeCycleEventsDocumentBuilder in project carbon-business-process by wso2.
the class InstanceManagementServiceSkeleton method fillActivityLifeCycleEventsFromScope.
private void fillActivityLifeCycleEventsFromScope(ActivityLifeCycleEventsListType activityLifeCycleEventsList, ScopeDAO scope) {
// List<BpelEvent> events = scope.listEvents();
Set<EventDAOImpl> eventsEntities = ((ScopeDAOImpl) scope).getEvents();
List<BpelEvent> events = new ArrayList<BpelEvent>();
for (EventDAOImpl event : eventsEntities) {
events.add(event.getEvent());
}
ActivityLifeCycleEventsDocumentBuilder docBuilder = new ActivityLifeCycleEventsDocumentBuilder();
for (BpelEvent e : events) {
docBuilder.onEvent(e);
}
EventInfoListDocument infoList = docBuilder.getActivityLifeCycleEvents();
fillActivityLifeCycleEventsList(activityLifeCycleEventsList, infoList);
for (ScopeDAO childScope : scope.getChildScopes()) {
fillActivityLifeCycleEventsFromScope(activityLifeCycleEventsList, childScope);
}
}
Aggregations