original_string: public function createConditionGenerator($query, SearchCondition $searchCondition)
      {
          if ($query instanceof NativeQuery) {
              return new NativeQueryConditionGenerator($query, $searchCondition);
          }
  
          if ($query instanceof Query || $query instanceof QueryBuilder) {
              return new DqlConditionGenerator($query, $searchCondition);
          }
  
          throw new \InvalidArgumentException(
              sprintf('Query "%s" is not supported by the DoctrineOrmFactory.', \get_class($query))
          );
      }
code: public function createConditionGenerator($query, SearchCondition $searchCondition)
      {
          if ($query instanceof NativeQuery) {
              return new NativeQueryConditionGenerator($query, $searchCondition);
          }
  
          if ($query instanceof Query || $query instanceof QueryBuilder) {
              return new DqlConditionGenerator($query, $searchCondition);
          }
  
          throw new \InvalidArgumentException(
              sprintf('Query "%s" is not supported by the DoctrineOrmFactory.', \get_class($query))
          );
      }
code_tokens: public function createConditionGenerator ( $ query , SearchCondition $ searchCondition ) { if ( $ query instanceof NativeQuery ) { return new NativeQueryConditionGenerator ( $ query , $ searchCondition ) ; } if ( $ query instanceof Query || $ query instanceof QueryBuilder ) { return new DqlConditionGenerator ( $ query , $ searchCondition ) ; } throw new \ InvalidArgumentException ( sprintf ( 'Query "%s" is not supported by the DoctrineOrmFactory.' , \ get_class ( $ query ) ) ) ; }
docstring: Creates a new ConditionGenerator for the SearchCondition.
  
  Conversions are applied using the 'doctrine_dbal_conversion' option (when present).
  
  @param NativeQuery|Query|QueryBuilder $query           Doctrine ORM (Native)Query object
  @param SearchCondition                $searchCondition SearchCondition object
  
  @return NativeQueryConditionGenerator|DqlConditionGenerator
docstring_tokens: Creates a new ConditionGenerator for the SearchCondition .