2
2
namespace Kir \MySQL \Builder \Helpers ;
3
3
4
4
use Kir \MySQL \Builder \Expr \OptionalExpression ;
5
+ use Kir \MySQL \Builder \Internal \Types ;
6
+ use Kir \MySQL \Builder \Traits \WhereBuilder ;
5
7
8
+ /**
9
+ * @phpstan-import-type DBParameterValueType from Types
10
+ * @phpstan-import-type DBWhereExpressionType from WhereBuilder
11
+ */
6
12
abstract class ConditionAddHelper {
7
13
/**
8
- * @param callable(string|array<string, mixed >, array<int, mixed >): void $addFn
9
- * @param string|array<string, mixed>|object|OptionalExpression $expression
10
- * @param array<int, mixed > $args
14
+ * @param callable(string|array<string, null|scalar >, array<int, DBParameterValueType >): void $addFn
15
+ * @param DBWhereExpressionType $expression
16
+ * @param array<DBParameterValueType > $args
11
17
*/
12
18
public static function addCondition (callable $ addFn , $ expression , array $ args ): void {
13
19
if ($ expression instanceof OptionalExpression) {
@@ -26,7 +32,7 @@ public static function addCondition(callable $addFn, $expression, array $args):
26
32
/**
27
33
* @param callable(string|array<string, mixed>, array<int, mixed>): void $addFn
28
34
* @param array<string, mixed> $expression
29
- * @param array<int, mixed > $args
35
+ * @param array<int, DBParameterValueType > $args
30
36
*/
31
37
private static function addAsArray (callable $ addFn , array $ expression , array $ args ): void {
32
38
if (count ($ expression ) > 0 ) {
0 commit comments