private Node generateFlow(final Scope scope, final Flow flow, final BPELProcess bpelprocess) throws CoreException { this.log.finest("start generate flow"); Node flowNode = null; if (flow != null) { final List<Node> childNodes = new ArrayList<Node>(); Node activityNode = null; for (final Activity activity : flow.getActivities()) { activityNode = this.generateActivity(scope, activity, bpelprocess); if (activityNode != null) { childNodes.add(activityNode); } else { throw new CoreException("Impossible to generate activity: " + activity.getName()); } } flowNode = CreationPatternFactory.getInstance().createForkPattern( flow.getName(), childNodes, scope); } this.log.finest("end generate flow"); return flowNode; }
private Node generateSequence(final Scope scope, final Sequence sequence, final BPELProcess bpelprocess) throws CoreException { this.log.finest("start generate sequence"); Node sequenceNode = null; if (sequence != null) { final List<Node> childNodes = new ArrayList<Node>(); Node activityNode = null; for (final Activity activity : sequence.getActivities()) { activityNode = this.generateActivity(scope, activity, bpelprocess); if (activityNode != null) { childNodes.add(activityNode); } else { throw new CoreException("Impossible to generate activity: " + activity.getName()); } } // TODO Manage non-functional behaviours in process (set to null for // now) sequenceNode = CreationPatternFactory.getInstance() .createSequencePattern(sequence.getName(), childNodes, scope, null); } this.log.finest("end generate sequence"); return sequenceNode; }
public CatchAllImpl(final TActivityContainer model, final BPELElement parent) { super(Constants._CatchAll_QNAME, model, parent); // get activity try { this.activity = ActivityImpl.analyzeActivityContainer(this.model, this); } catch (final BPELException e) { final Activity activity = (Activity) this.getParent(); BPELStaticAnalysisImpl.getInstance().addError(new BPELErrorImpl(this, new BPELException("In catchAll of " + activity.getName() + " => " + e.getMessage(), e))); } }