1 | <?php |
||
23 | abstract class AbstractBuilder implements BuilderInterface |
||
24 | { |
||
25 | /** |
||
26 | * @var TableFactoryInterface |
||
27 | */ |
||
28 | private $tableFactory; |
||
29 | |||
30 | /** |
||
31 | * @var QueryCompilerInterface |
||
32 | */ |
||
33 | private $queryCompiler; |
||
34 | |||
35 | /** |
||
36 | * @var ParameterManagerInterface |
||
37 | */ |
||
38 | private $parameterManager; |
||
39 | |||
40 | /** |
||
41 | * @param TableFactoryInterface $tableFactory |
||
42 | * @param QueryCompilerInterface $queryCompiler |
||
43 | * @param ParameterManagerInterface $parameterManager |
||
44 | */ |
||
45 | 34 | public function __construct( |
|
46 | TableFactoryInterface $tableFactory, |
||
47 | QueryCompilerInterface $queryCompiler, |
||
48 | ParameterManagerInterface $parameterManager |
||
49 | ) { |
||
50 | 34 | $this->tableFactory = $tableFactory; |
|
51 | 34 | $this->queryCompiler = $queryCompiler; |
|
52 | 34 | $this->parameterManager = $parameterManager; |
|
53 | 34 | } |
|
54 | |||
55 | /** |
||
56 | * @return BuilderInterface |
||
57 | */ |
||
58 | 34 | public function getQueryBuilder() |
|
62 | |||
63 | /** |
||
64 | * @return TableFactoryInterface |
||
65 | */ |
||
66 | 32 | public function getTableFactory() |
|
70 | |||
71 | /** |
||
72 | * @return QueryCompilerInterface |
||
73 | */ |
||
74 | 34 | public function getQueryCompiler() |
|
78 | |||
79 | /** |
||
80 | * @return ParameterManagerInterface |
||
81 | */ |
||
82 | 34 | public function getParameterManager() |
|
86 | |||
87 | /** |
||
88 | * @inheritdoc |
||
89 | */ |
||
90 | 34 | public function buildSQL() |
|
94 | |||
95 | /** |
||
96 | * @inheritdoc |
||
97 | */ |
||
98 | 22 | public function objectToString($object) |
|
102 | |||
103 | /** |
||
104 | * @param ConnectionInterface $connection |
||
|
|||
105 | * |
||
106 | * @return Query |
||
107 | */ |
||
108 | 13 | public function buildQuery(ConnectionInterface $connection = null) |
|
116 | } |
This check looks for
@param
annotations where the type inferred by our type inference engine differs from the declared type.It makes a suggestion as to what type it considers more descriptive.
Most often this is a case of a parameter that can be null in addition to its declared types.