forked from Novactive/NovaeZSolrSearchExtraBundle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CustomField.php
40 lines (36 loc) · 997 Bytes
/
CustomField.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<?php
/**
* NovaeZSolrSearchExtraBundle.
*
* @package NovaeZSolrSearchExtraBundle
*
* @author Novactive <f.alexandre@novactive.com>
* @copyright 2018 Novactive
* @license https://github.com/Novactive/NovaeZSolrSearchExtraBundle/blob/master/LICENSE
*
*/
namespace Novactive\EzSolrSearchExtra\Query\SortClauseHandler;
use eZ\Publish\API\Repository\Values\Content\Query\SortClause as APISortClause;
use eZ\Publish\Core\Persistence\Database\SelectQuery;
use eZ\Publish\Core\Search\Legacy\Content\Common\Gateway\SortClauseHandler;
use Novactive\EzSolrSearchExtra\Query\SortClause;
/**
* Class CustomField.
*/
class CustomField extends SortClauseHandler
{
/**
* {@inheritdoc}
*/
public function accept(APISortClause $sortClause)
{
return $sortClause instanceof SortClause\CustomField;
}
/**
* {@inheritdoc}
*/
public function applySelect(SelectQuery $query, APISortClause $sortClause, $number)
{
return null;
}
}