protected function importedNode()
 {
     if ($this->importedNode === null) {
         $storage = new LegacyStorage(Config::module('businessprocess')->getSection('global'));
         try {
             $this->importedBp = $storage->loadProcess($this->configName);
             if ($this->bp->usesSoftStates()) {
                 $this->importedBp->useSoftStates();
             } else {
                 $this->importedBp->useHardStates();
             }
             $this->importedBp->retrieveStatesFromBackend();
             $this->importedNode = $this->importedBp->getNode($this->name);
         } catch (Exception $e) {
             $node = new BpNode($this->bp, (object) array('name' => $this->name, 'operator' => '&', 'child_names' => array()));
             $node->setState(2);
             $node->setMissing(false)->setDowntime(false)->setAck(false)->setAlias($e->getMessage());
             $this->importedNode = $node;
         }
     }
     return $this->importedNode;
 }
 public function renderUnbound($view)
 {
     $html = '';
     $unbound = $this->getUnboundNodes();
     if (empty($unbound)) {
         return $html;
     }
     $parent = new BpNode($this, (object) array('name' => '__unbound__', 'operator' => '|', 'child_names' => array_keys($unbound)));
     $parent->getState();
     $parent->setMissing()->setDowntime(false)->setAck(false)->setAlias('Unbound nodes');
     $html .= $parent->renderHtml($view);
     return $html;
 }