public final class CalendricalContext extends Object implements Serializable
| Constructor and Description |
|---|
CalendricalContext(boolean strict,
boolean checkUnusedFields)
Constructs an instance that can merge the specified calendrical.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj)
Is this context equal to the specified context.
|
DateResolver |
getDateResolver()
Gets the date resolver to use.
|
int |
hashCode()
A hashcode for this context.
|
boolean |
isCheckUnusedFields()
Checks whether to check unused fields.
|
boolean |
isStrict()
Checks whether calculations will use strict rules or not.
|
LocalDate |
resolveDate(int year,
int month,
int dayOfMonth)
Resolves the year, month and day-of-month to a date using ISO chronology rules.
|
public CalendricalContext(boolean strict,
boolean checkUnusedFields)
strict - whether to use strict rulescheckUnusedFields - whether to check unused fieldspublic boolean isStrict()
public boolean isCheckUnusedFields()
public DateResolver getDateResolver()
public LocalDate resolveDate(int year, int month, int dayOfMonth)
The three input parameters are resolved to a date. If the context specifies a date resolver, then that is used. Otherwise, the strict/lenient flag is used.
year - the year to resolvemonth - the month to resolvedayOfMonth - the day-of-month to resolveIllegalCalendarFieldValueException - if one of the fields has an invalid valueCalendricalException - if the input date does not match the stored datepublic boolean equals(Object obj)
Copyright © 2024. All rights reserved.