|
23 | 23 |
|
24 | 24 | import org.springframework.data.domain.Sort;
|
25 | 25 | import org.springframework.data.domain.Sort.Direction;
|
| 26 | +import org.springframework.data.mongodb.core.aggregation.ExposedFields.DirectFieldReference; |
26 | 27 | import org.springframework.data.mongodb.core.aggregation.ExposedFields.ExposedField;
|
27 | 28 | import org.springframework.data.mongodb.core.aggregation.ExposedFields.FieldReference;
|
28 |
| -import org.springframework.data.mongodb.core.aggregation.ExposedFields.DirectFieldReference; |
29 |
| -import org.springframework.data.mongodb.core.aggregation.Fields.AggregationField; |
30 | 29 | import org.springframework.data.mongodb.core.aggregation.FieldsExposingAggregationOperation.InheritsFieldsAggregationOperation;
|
| 30 | +import org.springframework.data.mongodb.core.aggregation.Fields.*; |
31 | 31 | import org.springframework.data.mongodb.core.query.Criteria;
|
32 | 32 | import org.springframework.data.mongodb.core.query.CriteriaDefinition;
|
33 | 33 | import org.springframework.data.mongodb.core.query.NearQuery;
|
@@ -396,68 +396,6 @@ public static LookupOperation lookup(Field from, Field localField, Field foreign
|
396 | 396 | return new LookupOperation(from, localField, foreignField, as);
|
397 | 397 | }
|
398 | 398 |
|
399 |
| - /** |
400 |
| - * Creates a new {@link IfNullOperator} for the given {@code field} and {@code replacement} value. |
401 |
| - * |
402 |
| - * @param field must not be {@literal null}. |
403 |
| - * @param replacement must not be {@literal null}. |
404 |
| - * @return never {@literal null}. |
405 |
| - * @since 1.10 |
406 |
| - */ |
407 |
| - public static IfNullOperator ifNull(String field, Object replacement) { |
408 |
| - return IfNullOperator.newBuilder().ifNull(field).thenReplaceWith(replacement); |
409 |
| - } |
410 |
| - |
411 |
| - /** |
412 |
| - * Creates a new {@link IfNullOperator} for the given {@link Field} and {@link Field} to obtain a value from. |
413 |
| - * |
414 |
| - * @param field must not be {@literal null}. |
415 |
| - * @param replacement must not be {@literal null}. |
416 |
| - * @return never {@literal null}. |
417 |
| - * @since 1.10 |
418 |
| - */ |
419 |
| - public static IfNullOperator ifNull(Field field, Field replacement) { |
420 |
| - return IfNullOperator.newBuilder().ifNull(field).thenReplaceWith(replacement); |
421 |
| - } |
422 |
| - |
423 |
| - /** |
424 |
| - * Creates a new {@link IfNullOperator} for the given {@link Field} and {@code replacement} value. |
425 |
| - * |
426 |
| - * @param field must not be {@literal null}. |
427 |
| - * @param replacement must not be {@literal null}. |
428 |
| - * @return never {@literal null}. |
429 |
| - * @since 1.10 |
430 |
| - */ |
431 |
| - public static IfNullOperator ifNull(Field field, Object replacement) { |
432 |
| - return IfNullOperator.newBuilder().ifNull(field).thenReplaceWith(replacement); |
433 |
| - } |
434 |
| - |
435 |
| - /** |
436 |
| - * Creates a new {@link ConditionalOperator} for the given {@link Field} that holds a {@literal boolean} value. |
437 |
| - * |
438 |
| - * @param booleanField must not be {@literal null}. |
439 |
| - * @param then must not be {@literal null}. |
440 |
| - * @param otherwise must not be {@literal null}. |
441 |
| - * @return never {@literal null}. |
442 |
| - * @since 1.10 |
443 |
| - */ |
444 |
| - public static ConditionalOperator conditional(Field booleanField, Object then, Object otherwise) { |
445 |
| - return ConditionalOperator.newBuilder().when(booleanField).then(then).otherwise(otherwise); |
446 |
| - } |
447 |
| - |
448 |
| - /** |
449 |
| - * Creates a new {@link ConditionalOperator} for the given {@link Criteria}. |
450 |
| - * |
451 |
| - * @param criteria must not be {@literal null}. |
452 |
| - * @param then must not be {@literal null}. |
453 |
| - * @param otherwise must not be {@literal null}. |
454 |
| - * @return never {@literal null}. |
455 |
| - * @since 1.10 |
456 |
| - */ |
457 |
| - public static ConditionalOperator conditional(Criteria criteria, Object then, Object otherwise) { |
458 |
| - return ConditionalOperator.newBuilder().when(criteria).then(then).otherwise(otherwise); |
459 |
| - } |
460 |
| - |
461 | 399 | /**
|
462 | 400 | * Creates a new {@link Fields} instance for the given field names.
|
463 | 401 | *
|
|
0 commit comments