1 | <?php declare(strict_types = 1); |
||
5 | class FacileMongoDbBundleExtension extends \Twig_Extension |
||
6 | { |
||
7 | private $methodDataTranslationMap = [ |
||
8 | 'aggregate' => 'Pipeline', |
||
9 | 'insertOne' => 'Document', |
||
10 | 'updateOne' => 'Update', |
||
11 | 'findOneAndUpdate' => 'Update', |
||
12 | 'replaceOne' => 'Replacement', |
||
13 | ]; |
||
14 | |||
15 | public function getFunctions() |
||
22 | |||
23 | /** |
||
24 | * @param string $label |
||
25 | * @param string $methodName |
||
26 | * |
||
27 | * @return string |
||
28 | */ |
||
29 | 1 | public function queryFilterTranslate(string $label, string $methodName): string |
|
33 | |||
34 | /** |
||
35 | * @param string $label |
||
36 | * @param string $methodName |
||
37 | * |
||
38 | * @return string |
||
39 | */ |
||
40 | 6 | public function queryDataTranslate(string $label, string $methodName): string |
|
44 | |||
45 | /** |
||
46 | * Returns the name of the extension. |
||
47 | * |
||
48 | * @return string The extension name |
||
49 | */ |
||
50 | public function getName() |
||
54 | } |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.