1 | <?php |
||
13 | class Datatable110QueryParser extends QueryParser |
||
14 | { |
||
15 | |||
16 | /** |
||
17 | * Method to determine if this parser can handle the query parameters. If so then the parser should return true |
||
18 | * and be able to return a DTQueryConfiguration |
||
19 | * |
||
20 | * @param Request $request The current request, that should be investigated |
||
21 | * @return bool true if the parser is able to parse the query parameters and to return a DTQueryConfiguration |
||
22 | */ |
||
23 | public function canParse(Request $request) |
||
27 | |||
28 | /** |
||
29 | * Method that should parse the request and return a DTQueryConfiguration |
||
30 | * |
||
31 | * @param Request $request The current request that should be investigated |
||
32 | * @param ColumnConfiguration[] $columnConfiguration The configuration of the columns |
||
33 | * @return QueryConfiguration the configuration the provider can use to prepare the data |
||
34 | */ |
||
35 | public function parse(Request $request, array $columnConfiguration) |
||
64 | |||
65 | /** |
||
66 | * Helper function that will check if a variable is empty |
||
67 | * @param mixed $string |
||
68 | * @return bool true if empty, false otherwise |
||
69 | */ |
||
70 | private function isEmpty($string) |
||
74 | |||
75 | /** |
||
76 | * @param ParameterBag $query |
||
77 | * @param QueryConfigurationBuilder $builder |
||
78 | */ |
||
79 | public function getDrawCall($query, $builder) |
||
85 | |||
86 | /** |
||
87 | * @param ParameterBag $query |
||
88 | * @param QueryConfigurationBuilder $builder |
||
89 | */ |
||
90 | public function getStart($query, $builder) |
||
96 | |||
97 | /** |
||
98 | * @param ParameterBag $query |
||
99 | * @param QueryConfigurationBuilder $builder |
||
100 | */ |
||
101 | public function getLength($query, $builder) |
||
107 | |||
108 | /** |
||
109 | * @param ParameterBag $query |
||
110 | * @param QueryConfigurationBuilder $builder |
||
111 | */ |
||
112 | public function getSearch($query, $builder) |
||
118 | |||
119 | /** |
||
120 | * @param ParameterBag $query |
||
121 | * @param QueryConfigurationBuilder $builder |
||
122 | */ |
||
123 | public function getRegex($query, $builder) |
||
129 | |||
130 | /** |
||
131 | * @param ParameterBag $query |
||
132 | * @param QueryConfigurationBuilder $builder |
||
133 | * @param ColumnConfiguration[] $columnConfiguration |
||
134 | */ |
||
135 | private function getOrder(ParameterBag $query, QueryConfigurationBuilder $builder, array $columnConfiguration) |
||
150 | } |