108 * such as {@code 2007-12-03}.
109 * <p>
110 * {@code LocalDate} is an immutable date-time object that represents a date,
111 * often viewed as year-month-day. Other date fields, such as day-of-year,
112 * day-of-week and week-of-year, can also be accessed.
113 * For example, the value "2nd October 2007" can be stored in a {@code LocalDate}.
114 * <p>
115 * This class does not store or represent a time or time-zone.
116 * Instead, it is a description of the date, as used for birthdays.
117 * It cannot represent an instant on the time-line without additional information
118 * such as an offset or time-zone.
119 * <p>
120 * The ISO-8601 calendar system is the modern civil calendar system used today
121 * in most of the world. It is equivalent to the proleptic Gregorian calendar
122 * system, in which today's rules for leap years are applied for all time.
123 * For most applications written today, the ISO-8601 rules are entirely suitable.
124 * However, any application that makes use of historical dates, and requires them
125 * to be accurate will find the ISO-8601 approach unsuitable.
126 *
127 * <p>
128 * This is a <a href="{@docRoot}/java/lang/doc-files/ValueBased.html">value-based</a>
129 * class; use of identity-sensitive operations (including reference equality
130 * ({@code ==}), identity hash code, or synchronization) on instances of
131 * {@code LocalDate} may have unpredictable results and should be avoided.
132 * The {@code equals} method should be used for comparisons.
133 *
134 * @implSpec
135 * This class is immutable and thread-safe.
136 *
137 * @since 1.8
138 */
139 public final class LocalDate
140 implements Temporal, TemporalAdjuster, ChronoLocalDate, Serializable {
141
142 /**
143 * The minimum supported {@code LocalDate}, '-999999999-01-01'.
144 * This could be used by an application as a "far past" date.
145 */
146 public static final LocalDate MIN = LocalDate.of(Year.MIN_VALUE, 1, 1);
147 /**
148 * The maximum supported {@code LocalDate}, '+999999999-12-31'.
|
108 * such as {@code 2007-12-03}.
109 * <p>
110 * {@code LocalDate} is an immutable date-time object that represents a date,
111 * often viewed as year-month-day. Other date fields, such as day-of-year,
112 * day-of-week and week-of-year, can also be accessed.
113 * For example, the value "2nd October 2007" can be stored in a {@code LocalDate}.
114 * <p>
115 * This class does not store or represent a time or time-zone.
116 * Instead, it is a description of the date, as used for birthdays.
117 * It cannot represent an instant on the time-line without additional information
118 * such as an offset or time-zone.
119 * <p>
120 * The ISO-8601 calendar system is the modern civil calendar system used today
121 * in most of the world. It is equivalent to the proleptic Gregorian calendar
122 * system, in which today's rules for leap years are applied for all time.
123 * For most applications written today, the ISO-8601 rules are entirely suitable.
124 * However, any application that makes use of historical dates, and requires them
125 * to be accurate will find the ISO-8601 approach unsuitable.
126 *
127 * <p>
128 * This is a <a href="{@docRoot}/java.base/java/lang/doc-files/ValueBased.html">value-based</a>
129 * class; use of identity-sensitive operations (including reference equality
130 * ({@code ==}), identity hash code, or synchronization) on instances of
131 * {@code LocalDate} may have unpredictable results and should be avoided.
132 * The {@code equals} method should be used for comparisons.
133 *
134 * @implSpec
135 * This class is immutable and thread-safe.
136 *
137 * @since 1.8
138 */
139 public final class LocalDate
140 implements Temporal, TemporalAdjuster, ChronoLocalDate, Serializable {
141
142 /**
143 * The minimum supported {@code LocalDate}, '-999999999-01-01'.
144 * This could be used by an application as a "far past" date.
145 */
146 public static final LocalDate MIN = LocalDate.of(Year.MIN_VALUE, 1, 1);
147 /**
148 * The maximum supported {@code LocalDate}, '+999999999-12-31'.
|