@@ -239,55 +239,55 @@ public protocol Expr: Sendable {
239
239
/// ```swift
240
240
/// // Check if 'candidateSkills' contains all skills from 'requiredSkill1' and 'requiredSkill2'
241
241
/// fields
242
- /// Field("candidateSkills").arrayContainsAll(Field("requiredSkill1"), Field("requiredSkill2"))
242
+ /// Field("candidateSkills").arrayContainsAll([ Field("requiredSkill1"), Field("requiredSkill2")] )
243
243
/// ```
244
244
///
245
- /// - Parameter values: A variadic list of `Expr` elements to check for in the array represented
245
+ /// - Parameter values: A list of `Expr` elements to check for in the array represented
246
246
/// by `self`.
247
247
/// - Returns: A new `BooleanExpr` representing the 'array_contains_all' comparison.
248
- func arrayContainsAll( _ values: Expr ... ) -> BooleanExpr
248
+ func arrayContainsAll( _ values: [ Expr ] ) -> BooleanExpr
249
249
250
250
/// Creates an expression that checks if an array (from `self`) contains all the specified literal
251
251
/// elements.
252
252
/// Assumes `self` evaluates to an array.
253
253
///
254
254
/// ```swift
255
255
/// // Check if 'tags' contains both "urgent" and "review"
256
- /// Field("tags").arrayContainsAll("urgent", "review")
256
+ /// Field("tags").arrayContainsAll([ "urgent", "review"] )
257
257
/// ```
258
258
///
259
- /// - Parameter values: A variadic list of `Sendable` literal elements to check for in the array
259
+ /// - Parameter values: A list of `Sendable` literal elements to check for in the array
260
260
/// represented by `self`.
261
261
/// - Returns: A new `BooleanExpr` representing the 'array_contains_all' comparison.
262
- func arrayContainsAll( _ values: Sendable ... ) -> BooleanExpr
262
+ func arrayContainsAll( _ values: [ Sendable ] ) -> BooleanExpr
263
263
264
264
/// Creates an expression that checks if an array (from `self`) contains any of the specified
265
265
/// element expressions.
266
266
/// Assumes `self` evaluates to an array.
267
267
///
268
268
/// ```swift
269
269
/// // Check if 'userGroups' contains any group from 'allowedGroup1' or 'allowedGroup2' fields
270
- /// Field("userGroups").arrayContainsAny(Field("allowedGroup1"), Field("allowedGroup2"))
270
+ /// Field("userGroups").arrayContainsAny([ Field("allowedGroup1"), Field("allowedGroup2")] )
271
271
/// ```
272
272
///
273
- /// - Parameter values: A variadic list of `Expr` elements to check for in the array represented
273
+ /// - Parameter values: A list of `Expr` elements to check for in the array represented
274
274
/// by `self`.
275
275
/// - Returns: A new `BooleanExpr` representing the 'array_contains_any' comparison.
276
- func arrayContainsAny( _ values: Expr ... ) -> BooleanExpr
276
+ func arrayContainsAny( _ values: [ Expr ] ) -> BooleanExpr
277
277
278
278
/// Creates an expression that checks if an array (from `self`) contains any of the specified
279
279
/// literal elements.
280
280
/// Assumes `self` evaluates to an array.
281
281
///
282
282
/// ```swift
283
283
/// // Check if 'categories' contains either "electronics" or "books"
284
- /// Field("categories").arrayContainsAny("electronics", "books")
284
+ /// Field("categories").arrayContainsAny([ "electronics", "books"] )
285
285
/// ```
286
286
///
287
- /// - Parameter values: A variadic list of `Sendable` literal elements to check for in the array
287
+ /// - Parameter values: A list of `Sendable` literal elements to check for in the array
288
288
/// represented by `self`.
289
289
/// - Returns: A new `BooleanExpr` representing the 'array_contains_any' comparison.
290
- func arrayContainsAny( _ values: Sendable ... ) -> BooleanExpr
290
+ func arrayContainsAny( _ values: [ Sendable ] ) -> BooleanExpr
291
291
292
292
/// Creates an expression that calculates the length of an array.
293
293
/// Assumes `self` evaluates to an array.
@@ -341,51 +341,51 @@ public protocol Expr: Sendable {
341
341
///
342
342
/// ```swift
343
343
/// // Check if 'categoryID' field is equal to 'featuredCategory' or 'popularCategory' fields
344
- /// Field("categoryID").eqAny(Field("featuredCategory"), Field("popularCategory"))
344
+ /// Field("categoryID").eqAny([ Field("featuredCategory"), Field("popularCategory")] )
345
345
/// ```
346
346
///
347
- /// - Parameter others: A variadic list of `Expr` values to check against.
347
+ /// - Parameter others: A list of `Expr` values to check against.
348
348
/// - Returns: A new `BooleanExpr` representing the 'IN' comparison (eq_any).
349
- func eqAny( _ others: Expr ... ) -> BooleanExpr
349
+ func eqAny( _ others: [ Expr ] ) -> BooleanExpr
350
350
351
351
/// Creates an expression that checks if this expression is equal to any of the provided literal
352
352
/// values.
353
353
/// This is similar to an "IN" operator in SQL.
354
354
///
355
355
/// ```swift
356
356
/// // Check if 'category' is "Electronics", "Books", or "Home Goods"
357
- /// Field("category").eqAny("Electronics", "Books", "Home Goods")
357
+ /// Field("category").eqAny([ "Electronics", "Books", "Home Goods"] )
358
358
/// ```
359
359
///
360
- /// - Parameter others: A variadic list of `Sendable` literal values to check against.
360
+ /// - Parameter others: A list of `Sendable` literal values to check against.
361
361
/// - Returns: A new `BooleanExpr` representing the 'IN' comparison (eq_any).
362
- func eqAny( _ others: Sendable ... ) -> BooleanExpr
362
+ func eqAny( _ others: [ Sendable ] ) -> BooleanExpr
363
363
364
364
/// Creates an expression that checks if this expression is not equal to any of the provided
365
365
/// expression values.
366
366
/// This is similar to a "NOT IN" operator in SQL.
367
367
///
368
368
/// ```swift
369
369
/// // Check if 'statusValue' is not equal to 'archivedStatus' or 'deletedStatus' fields
370
- /// Field("statusValue").notEqAny(Field("archivedStatus"), Field("deletedStatus"))
370
+ /// Field("statusValue").notEqAny([ Field("archivedStatus"), Field("deletedStatus")] )
371
371
/// ```
372
372
///
373
- /// - Parameter others: A variadic list of `Expr` values to check against.
373
+ /// - Parameter others: A list of `Expr` values to check against.
374
374
/// - Returns: A new `BooleanExpr` representing the 'NOT IN' comparison (not_eq_any).
375
- func notEqAny( _ others: Expr ... ) -> BooleanExpr
375
+ func notEqAny( _ others: [ Expr ] ) -> BooleanExpr
376
376
377
377
/// Creates an expression that checks if this expression is not equal to any of the provided
378
378
/// literal values.
379
379
/// This is similar to a "NOT IN" operator in SQL.
380
380
///
381
381
/// ```swift
382
382
/// // Check if 'status' is neither "pending" nor "archived"
383
- /// Field("status").notEqAny("pending", "archived")
383
+ /// Field("status").notEqAny([ "pending", "archived"] )
384
384
/// ```
385
385
///
386
- /// - Parameter others: A variadic list of `Sendable` literal values to check against.
386
+ /// - Parameter others: A list of `Sendable` literal values to check against.
387
387
/// - Returns: A new `BooleanExpr` representing the 'NOT IN' comparison (not_eq_any).
388
- func notEqAny( _ others: Sendable ... ) -> BooleanExpr
388
+ func notEqAny( _ others: [ Sendable ] ) -> BooleanExpr
389
389
390
390
// MARK: Checks
391
391
@@ -495,7 +495,7 @@ public protocol Expr: Sendable {
495
495
///
496
496
/// - Parameter pattern: The literal string pattern to search for. Use "%" as a wildcard.
497
497
/// - Returns: A new `FunctionExpr` representing the 'like' comparison.
498
- func like( _ pattern: String ) -> FunctionExpr
498
+ func like( _ pattern: String ) -> BooleanExpr
499
499
500
500
/// Creates an expression that performs a case-sensitive string comparison using wildcards against
501
501
/// an expression pattern.
@@ -509,7 +509,7 @@ public protocol Expr: Sendable {
509
509
/// - Parameter pattern: An `Expr` (evaluating to a string) representing the pattern to search
510
510
/// for.
511
511
/// - Returns: A new `FunctionExpr` representing the 'like' comparison.
512
- func like( _ pattern: Expr ) -> FunctionExpr
512
+ func like( _ pattern: Expr ) -> BooleanExpr
513
513
514
514
/// Creates an expression that checks if a string (from `self`) contains a specified regular
515
515
/// expression literal as a substring.
0 commit comments