22namespace Kir \MySQL \Builder \Helpers ;
33
44use Kir \MySQL \Builder \Expr \OptionalExpression ;
5+ use Kir \MySQL \Builder \Internal \Types ;
6+ use Kir \MySQL \Builder \Traits \WhereBuilder ;
57
8+ /**
9+ * @phpstan-import-type DBParameterValueType from Types
10+ * @phpstan-import-type DBWhereExpressionType from WhereBuilder
11+ */
612abstract class ConditionAddHelper {
713 /**
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
1117 */
1218 public static function addCondition (callable $ addFn , $ expression , array $ args ): void {
1319 if ($ expression instanceof OptionalExpression) {
@@ -26,7 +32,7 @@ public static function addCondition(callable $addFn, $expression, array $args):
2632 /**
2733 * @param callable(string|array<string, mixed>, array<int, mixed>): void $addFn
2834 * @param array<string, mixed> $expression
29- * @param array<int, mixed > $args
35+ * @param array<int, DBParameterValueType > $args
3036 */
3137 private static function addAsArray (callable $ addFn , array $ expression , array $ args ): void {
3238 if (count ($ expression ) > 0 ) {
0 commit comments