public function bind(\Nethgui\Controller\RequestInterface $request)
 {
     parent::bind($request);
     $this->position = $this->bindPosition($request);
     if (intval($this->position) <= 0) {
         throw new \Nethgui\Exception\HttpException('Not found', 404, 1399992980);
     }
     $subrequest = $request->spawnRequest($this->position);
     if ($subrequest->hasParameter('f') || $subrequest->hasParameter('Submit')) {
         $this->workflow->resume($this->getParent()->getSession());
     } else {
         // start a new workflow generating a random rule key
         $defaults = $this->getRuleDefaults();
         foreach (array('SrcRaw', 'DstRaw', 'ServiceRaw', 'status', 'Description', 'LogType', 'Action') as $f) {
             if ($request->hasParameter($f)) {
                 $defaults[$f] = $request->getParameter($f);
             }
         }
         $this->workflow->start($this->getParent()->getSession(), $this->getIdentifier(), $this->getIdentifier() . '/' . $this->position, $this->generateNextRuleId(), $defaults);
     }
     $this->worker->ruleId = $this->workflow->getRuleId();
     $this->worker->bind($request);
     $this->workflow->copyTo($this->worker->parameters, array('SrcRaw', 'DstRaw', 'ServiceRaw', 'status', 'Description', 'LogType', 'Action'));
     if ($request->isMutation()) {
         $this->worker->parameters['Position'] = $this->position;
     }
 }