public static class DateOperators.IsoDateFromParts extends DateOperators.TimezonedDateAggregationExpression implements DateOperators.DateParts<DateOperators.IsoDateFromParts>
| Modifier and Type | Class and Description |
|---|---|
static interface |
DateOperators.IsoDateFromParts.IsoDateFromPartsWithYear |
| Modifier and Type | Method and Description |
|---|---|
protected List<Object> |
append(Object value) |
protected Map<String,Object> |
append(String key,
Object value) |
protected Map<String,Object> |
argumentMap()
Get the argument map.
|
protected static List<Field> |
asFields(String... fieldRefs) |
protected boolean |
contains(Object key)
Check if the given key is available.
|
static DateOperators.IsoDateFromParts.IsoDateFromPartsWithYear |
dateFromParts()
|
protected <T> T |
get(int index)
Get the value at a given index.
|
protected <T> T |
get(Object key)
Get the value for a given key.
|
protected String |
getMongoMethod() |
DateOperators.IsoDateFromParts |
hour(Object hour)
Set the hour to the given value which must resolve to a value in range of
0 - 23. |
DateOperators.IsoDateFromParts |
isoDayOfWeek(Object day)
Set the day of week to the given value which must resolve to a weekday in range
1 - 7. |
DateOperators.IsoDateFromParts |
isoDayOfWeekOf(AggregationExpression expression)
Set the day of week to the result of the given
expression. |
DateOperators.IsoDateFromParts |
isoDayOfWeekOf(String fieldReference)
Set the day of week to the value resolved by following the given
field reference. |
DateOperators.IsoDateFromParts |
isoWeek(Object isoWeek)
Set the week of year to the given value which must resolve to a calendar week in range
1 - 53. |
DateOperators.IsoDateFromParts |
isoWeekOf(AggregationExpression expression)
Set the week of year to the result of the given
expression. |
DateOperators.IsoDateFromParts |
isoWeekOf(String fieldReference)
Set the week of year to the value resolved by following the given
field reference. |
DateOperators.IsoDateFromParts |
milliseconds(Object milliseconds)
Set the milliseconds to the given value which must resolve to a value in range
0 - 999. |
DateOperators.IsoDateFromParts |
minute(Object minute)
Set the minute to the given value which must resolve to a value in range
0 - 59. |
DateOperators.IsoDateFromParts |
second(Object second)
Set the second to the given value which must resolve to a value in range
0 - 59. |
org.bson.Document |
toDocument(AggregationOperationContext context)
|
org.bson.Document |
toDocument(Object value,
AggregationOperationContext context) |
protected List<Object> |
values() |
DateOperators.IsoDateFromParts |
withTimezone(DateOperators.Timezone timezone)
Optionally set the
DateOperators.Timezone to use. |
appendTimezone, hasTimezoneclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waithourOf, hourOf, millisecondsOf, millisecondsOf, minuteOf, minuteOf, secondOf, secondOfpublic static DateOperators.IsoDateFromParts.IsoDateFromPartsWithYear dateFromParts()
DateOperators.IsoDateFromParts.IsoDateFromPartsWithYear.public DateOperators.IsoDateFromParts isoWeek(Object isoWeek)
1 - 53.
Can be a simple value, field reference or expression.isoWeek - must not be null.IllegalArgumentException - if given isoWeek is null.public DateOperators.IsoDateFromParts isoWeekOf(String fieldReference)
field reference.fieldReference - must not be null.IllegalArgumentException - if given fieldReference is null.public DateOperators.IsoDateFromParts isoWeekOf(AggregationExpression expression)
expression.expression - must not be null.IllegalArgumentException - if given expression is null.public DateOperators.IsoDateFromParts isoDayOfWeek(Object day)
1 - 7. Can be
a simple value, field reference or expression.day - must not be null.IllegalArgumentException - if given isoWeek is null.public DateOperators.IsoDateFromParts isoDayOfWeekOf(String fieldReference)
field reference.fieldReference - must not be null.IllegalArgumentException - if given fieldReference is null.public DateOperators.IsoDateFromParts isoDayOfWeekOf(AggregationExpression expression)
expression.expression - must not be null.IllegalArgumentException - if given expression is null.public DateOperators.IsoDateFromParts hour(Object hour)
DateOperators.DateParts0 - 23. Can be a
simple value, field reference or expression.hour in interface DateOperators.DateParts<DateOperators.IsoDateFromParts>hour - must not be null.public DateOperators.IsoDateFromParts minute(Object minute)
DateOperators.DateParts0 - 59. Can be a
simple value, field reference or expression.minute in interface DateOperators.DateParts<DateOperators.IsoDateFromParts>minute - must not be null.public DateOperators.IsoDateFromParts second(Object second)
DateOperators.DateParts0 - 59. Can be a
simple value, field reference or expression.second in interface DateOperators.DateParts<DateOperators.IsoDateFromParts>second - must not be null.public DateOperators.IsoDateFromParts milliseconds(Object milliseconds)
DateOperators.DateParts0 - 999. Can be
a simple value, field reference or expression.milliseconds in interface DateOperators.DateParts<DateOperators.IsoDateFromParts>milliseconds - must not be null.public DateOperators.IsoDateFromParts withTimezone(DateOperators.Timezone timezone)
DateOperators.Timezone to use. If not specified UTC is used.withTimezone in class DateOperators.TimezonedDateAggregationExpressiontimezone - must not be null. Consider DateOperators.Timezone.none() instead.DateOperators.IsoDateFromParts.IllegalArgumentException - if given timezone is null.protected String getMongoMethod()
public org.bson.Document toDocument(AggregationOperationContext context)
AggregationExpressiontoDocument in interface AggregationExpressionpublic org.bson.Document toDocument(Object value, AggregationOperationContext context)
protected <T> T get(int index)
T - index - protected <T> T get(Object key)
T - key - protected boolean contains(Object key)
key - Copyright © 2011–2018 Pivotal Software, Inc.. All rights reserved.