Module spring.data.mongodb
Interface SetWindowFieldsOperation.WindowUnit
- All Known Implementing Classes:
SetWindowFieldsOperation.WindowUnits
- Enclosing class:
- SetWindowFieldsOperation
public static interface SetWindowFieldsOperation.WindowUnit
The actual time unit to apply to a
SetWindowFieldsOperation.Window.-
Method Summary
Modifier and TypeMethodDescriptionfrom(ChronoUnit chronoUnit) Converts the given chrono unit into aSetWindowFieldsOperation.WindowUnit.Converts the given time unit into aSetWindowFieldsOperation.WindowUnit.name()
-
Method Details
-
name
String name() -
from
Converts the given time unit into aSetWindowFieldsOperation.WindowUnit. Supported units are: days, hours, minutes, seconds, and milliseconds.- Parameters:
timeUnit- the time unit to convert, must not be null.- Returns:
- Throws:
IllegalArgumentException- if theTimeUnitis null or not supported for conversion.
-
from
Converts the given chrono unit into aSetWindowFieldsOperation.WindowUnit. Supported units are: years, weeks, months, days, hours, minutes, seconds, and millis.- Parameters:
chronoUnit- the chrono unit to convert, must not be null.- Returns:
- Throws:
IllegalArgumentException- if theTimeUnitis null or not supported for conversion.
-