Searched refs:weeks (Results 1 - 8 of 8) sorted by relevance

/libcore/ojluni/src/test/java/time/test/java/time/
H A DTestLocalDate.java211 for (int weeks = 0; weeks < 365 * 8; weeks++) {
212 LocalDate t = reference.plusWeeks(weeks).plusWeeks(-weeks);
215 t = reference.plusWeeks(-weeks).plusWeeks(weeks);
339 for (int weeks = 0; weeks < 365 * 8; weeks
[all...]
/libcore/ojluni/src/main/java/java/time/chrono/
H A DAbstractChronology.java407 * the difference in months, then the difference in weeks, then in days.
411 * the amount in weeks and days to reach their values. If the mode is strict,
417 * years, months and weeks in {@code ALIGNED_DAY_OF_WEEK_IN_MONTH}.
419 * the years, months and weeks have been handled.
425 * the difference in weeks, then in days.
429 * the amount in weeks and days to reach their values. If the mode is strict,
434 * The approach is the same as described above for years and weeks in
436 * next or same matching day-of-week once the years and weeks have been handled.
585 long weeks = Math.subtractExact(fieldValues.remove(ALIGNED_WEEK_OF_MONTH), 1);
587 return date(y, 1, 1).plus(months, MONTHS).plus(weeks, WEEK
649 resolveAligned(ChronoLocalDate base, long months, long weeks, long dow) argument
[all...]
/libcore/ojluni/src/main/java/java/time/temporal/
H A DWeekFields.java121 * Together these two values allow a year or month to be divided into weeks.
125 * The calculation ensures that weeks never overlap a month boundary.
146 * The calculation ensures that weeks never overlap a year boundary.
157 * The first and last weeks of a year may contain days from the
182 // however, setting the week value should be lenient (use plus/minus weeks)
197 * The ISO-8601 standard defines a calendar system based on weeks.
220 * The unit is equal to either 52 or 53 weeks.
435 * This represents the concept of the count of weeks within the month where weeks
469 * Then take the week-of-month, subtract one, and add the amount in weeks t
[all...]
/libcore/ojluni/src/main/java/java/time/
H A DPeriod.java193 * Obtains a {@code Period} representing a number of weeks.
196 * equal to the number of weeks multiplied by 7.
199 * @param weeks the number of weeks, positive or negative
200 * @return the period, with the input weeks converted to days, not null
202 public static Period ofWeeks(int weeks) { argument
203 return create(0, 0, Math.multiplyExact(weeks, 7));
295 * years, months, weeks and days, accepted in upper or lower case.
335 int weeks = parseNumber(text, weekMatch, negate);
337 days = Math.addExact(days, Math.multiplyExact(weeks,
[all...]
H A DOffsetDateTime.java1239 * Returns a copy of this OffsetDateTime with the specified number of weeks added.
1241 * This method adds the specified amount in weeks to the days field incrementing
1249 * @param weeks the weeks to add, may be negative
1250 * @return an {@code OffsetDateTime} based on this date-time with the weeks added, not null
1253 public OffsetDateTime plusWeeks(long weeks) { argument
1254 return with(dateTime.plusWeeks(weeks), offset);
1428 * Returns a copy of this {@code OffsetDateTime} with the specified number of weeks subtracted.
1430 * This method subtracts the specified amount in weeks from the days field decrementing
1438 * @param weeks th
1442 minusWeeks(long weeks) argument
[all...]
H A DLocalDateTime.java1245 * Returns a copy of this {@code LocalDateTime} with the specified number of weeks added.
1247 * This method adds the specified amount in weeks to the days field incrementing
1255 * @param weeks the weeks to add, may be negative
1256 * @return a {@code LocalDateTime} based on this date-time with the weeks added, not null
1259 public LocalDateTime plusWeeks(long weeks) { argument
1260 LocalDate newDate = date.plusWeeks(weeks);
1442 * Returns a copy of this {@code LocalDateTime} with the specified number of weeks subtracted.
1444 * This method subtracts the specified amount in weeks from the days field decrementing
1452 * @param weeks th
1456 minusWeeks(long weeks) argument
[all...]
H A DZonedDateTime.java1650 * Returns a copy of this {@code ZonedDateTime} with the specified number of weeks added.
1653 * {@link LocalDateTime#plusWeeks(long) adding weeks} to the local date-time.
1663 * @param weeks the weeks to add, may be negative
1664 * @return a {@code ZonedDateTime} based on this date-time with the weeks added, not null
1667 public ZonedDateTime plusWeeks(long weeks) { argument
1668 return resolveLocal(dateTime.plusWeeks(weeks));
1891 * Returns a copy of this {@code ZonedDateTime} with the specified number of weeks subtracted.
1894 * {@link LocalDateTime#minusWeeks(long) subtracting weeks} to the local date-time.
1904 * @param weeks th
1908 minusWeeks(long weeks) argument
[all...]
/libcore/ojluni/src/test/java/time/tck/java/time/
H A DTCKLocalDateTime.java1563 for (int weeks = 0; weeks < 365 * 8; weeks++) {
1564 LocalDateTime t = reference.plusWeeks(weeks).plusWeeks(-weeks);
1567 t = reference.plusWeeks(-weeks).plusWeeks(weeks);
2252 for (int weeks = 0; weeks < 365 * 8; weeks
[all...]

Completed in 207 milliseconds