1 | <?php declare(strict_types = 1); |
||
7 | class FacileMongoDbBundleExtension extends \Twig_Extension |
||
8 | { |
||
9 | private $methodDataTranslationMap = [ |
||
10 | 'aggregate' => 'Pipeline', |
||
11 | 'insertOne' => 'Document', |
||
12 | 'updateOne' => 'Update', |
||
13 | 'findOneAndUpdate' => 'Update', |
||
14 | 'replaceOne' => 'Replacement', |
||
15 | ]; |
||
16 | |||
17 | /** |
||
18 | * @return array |
||
19 | */ |
||
20 | public function getFunctions() |
||
28 | |||
29 | /** |
||
30 | * @param string $label |
||
31 | * @param string $methodName |
||
32 | * |
||
33 | * @return string |
||
34 | */ |
||
35 | 1 | public function queryFilterTranslate(string $label, string $methodName): string |
|
39 | |||
40 | /** |
||
41 | * @param string $label |
||
42 | * @param string $methodName |
||
43 | * |
||
44 | * @return string |
||
45 | */ |
||
46 | 6 | public function queryDataTranslate(string $label, string $methodName): string |
|
50 | |||
51 | 12 | public function isQueryExplainable(string $methodName): bool |
|
55 | |||
56 | /** |
||
57 | * Returns the name of the extension. |
||
58 | * |
||
59 | * @return string The extension name |
||
60 | */ |
||
61 | 1 | public function getName() |
|
65 | } |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.