original_string: public function createFilterForFilterData(ServerRequest $request, array $filterData)
      {
          $charlist = 'abcdefghikmnopqrstuvwxyz';
  
          do {
              $slug = '';
              for ($i = 0; $i < 14; $i++) {
                  $slug .= substr($charlist, rand(0, 31), 1);
              }
          } while ($this->_slugExists($slug, $request));
  
          $this->save(new Filter([
              'plugin' => $request->getParam('plugin'),
              'controller' => $request->getParam('controller'),
              'action' => $request->getParam('action'),
              'slug' => $slug,
              'filter_data' => $this->_encodeFilterData($filterData)
          ]));
  
          return $slug;
      }
code: public function createFilterForFilterData(ServerRequest $request, array $filterData)
      {
          $charlist = 'abcdefghikmnopqrstuvwxyz';
  
          do {
              $slug = '';
              for ($i = 0; $i < 14; $i++) {
                  $slug .= substr($charlist, rand(0, 31), 1);
              }
          } while ($this->_slugExists($slug, $request));
  
          $this->save(new Filter([
              'plugin' => $request->getParam('plugin'),
              'controller' => $request->getParam('controller'),
              'action' => $request->getParam('action'),
              'slug' => $slug,
              'filter_data' => $this->_encodeFilterData($filterData)
          ]));
  
          return $slug;
      }
code_tokens: public function createFilterForFilterData ( ServerRequest $ request , array $ filterData ) { $ charlist = 'abcdefghikmnopqrstuvwxyz' ; do { $ slug = '' ; for ( $ i = 0 ; $ i < 14 ; $ i ++ ) { $ slug .= substr ( $ charlist , rand ( 0 , 31 ) , 1 ) ; } } while ( $ this -> _slugExists ( $ slug , $ request ) ) ; $ this -> save ( new Filter ( [ 'plugin' => $ request -> getParam ( 'plugin' ) , 'controller' => $ request -> getParam ( 'controller' ) , 'action' => $ request -> getParam ( 'action' ) , 'slug' => $ slug , 'filter_data' => $ this -> _encodeFilterData ( $ filterData ) ] ) ) ; return $ slug ; }
docstring: Create a new filter entry for the given request and filter data.
  
  @param ServerRequest $request
  @param array $filterData
  @return string The slug representing the given $filterData.
docstring_tokens: Create a new filter entry for the given request and filter data .