Module spring.data.mongodb
Interface DateOperators.DateParts<T extends DateOperators.DateParts<T>>
- All Known Implementing Classes:
DateOperators.DateFromParts,DateOperators.IsoDateFromParts
- Enclosing class:
- DateOperators
public static interface DateOperators.DateParts<T extends DateOperators.DateParts<T>>
- Since:
- 2.1
- Author:
- Christoph Strobl
-
Method Summary
Modifier and TypeMethodDescriptionSet the hour to the given value which must resolve to a value in range of0 - 23.default TSet the hour to the value resolved by following the givenfield reference.default ThourOf(AggregationExpression expression) Set the hour to the result of the givenexpression.millisecond(Object millisecond) Set the millisecond to the given value which must resolve to a value in range0 - 999.default TmillisecondOf(String fieldReference) Set the millisecond to the value resolved by following the givenfield reference.default TmillisecondOf(AggregationExpression expression) Set the milliseconds to the result of the givenexpression.Set the minute to the given value which must resolve to a value in range0 - 59.default TSet the minute to the value resolved by following the givenfield reference.default TminuteOf(AggregationExpression expression) Set the minute to the result of the givenexpression.Set the second to the given value which must resolve to a value in range0 - 59.default TSet the second to the value resolved by following the givenfield reference.default TsecondOf(AggregationExpression expression) Set the second to the result of the givenexpression.
-
Method Details
-
hour
Set the hour to the given value which must resolve to a value in range of0 - 23. Can be a simple value,field referenceorexpression.- Parameters:
hour- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given hour is null
-
hourOf
Set the hour to the value resolved by following the givenfield reference.- Parameters:
fieldReference- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given fieldReference is null.
-
hourOf
Set the hour to the result of the givenexpression.- Parameters:
expression- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given expression is null.
-
minute
Set the minute to the given value which must resolve to a value in range0 - 59. Can be a simple value,field referenceorexpression.- Parameters:
minute- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given minute is null
-
minuteOf
Set the minute to the value resolved by following the givenfield reference.- Parameters:
fieldReference- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given fieldReference is null.
-
minuteOf
Set the minute to the result of the givenexpression.- Parameters:
expression- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given expression is null.
-
second
Set the second to the given value which must resolve to a value in range0 - 59. Can be a simple value,field referenceorexpression.- Parameters:
second- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given second is null
-
secondOf
Set the second to the value resolved by following the givenfield reference.- Parameters:
fieldReference- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given fieldReference is null.
-
secondOf
Set the second to the result of the givenexpression.- Parameters:
expression- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given expression is null.
-
millisecond
Set the millisecond to the given value which must resolve to a value in range0 - 999. Can be a simple value,field referenceorexpression.- Parameters:
millisecond- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given millisecond is null- Since:
- 3.2
-
millisecondOf
Set the millisecond to the value resolved by following the givenfield reference.- Parameters:
fieldReference- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given fieldReference is null.- Since:
- 3.2
-
millisecondOf
Set the milliseconds to the result of the givenexpression.- Parameters:
expression- must not be null.- Returns:
- new instance.
- Throws:
IllegalArgumentException- if given expression is null.- Since:
- 3.2
-