Exemplo n.º 1
0
 protected function parseSubProcess($id, \DOMElement $el, BusinessProcessBuilder $builder)
 {
     $parentSubId = $this->subProcessId;
     $this->subProcessId = $id;
     try {
         $triggeredByEvent = 'true' === strtolower($el->getAttribute('triggeredByEvent'));
         $inner = $this->parseProcessDefinition($el);
         if ($triggeredByEvent) {
             $sub = $builder->eventSubProcess($id, $parentSubId, $inner, $el->getAttribute('name'));
         } else {
             $sub = $builder->subProcess($id, $inner, $el->getAttribute('name'));
         }
         $sub->setAsyncBefore($this->getAsyncBefore($el));
         $sub->setAsyncAfter($this->getAsyncAfter($el));
         return $sub;
     } finally {
         $this->subProcessId = $parentSubId;
     }
 }