Examples of minusDays()


Examples of org.joda.time.LocalDate.minusDays()

      case MARDI_GRAS:
      case CARNIVAL:
        easterSunday = easterSunday.minusDays(47);
        break;
      case ASH_WEDNESDAY:
        easterSunday = easterSunday.minusDays(46);
        break;
      case MAUNDY_THURSDAY:
        easterSunday = easterSunday.minusDays(3);
        break;
      case GOOD_FRIDAY:
View Full Code Here

Examples of org.joda.time.LocalDate.minusDays()

        break;
      case ASH_WEDNESDAY:
        easterSunday = easterSunday.minusDays(46);
        break;
      case MAUNDY_THURSDAY:
        easterSunday = easterSunday.minusDays(3);
        break;
      case GOOD_FRIDAY:
        easterSunday = easterSunday.minusDays(2);
        break;
      case EASTER_SATURDAY:
View Full Code Here

Examples of org.joda.time.LocalDate.minusDays()

        break;
      case MAUNDY_THURSDAY:
        easterSunday = easterSunday.minusDays(3);
        break;
      case GOOD_FRIDAY:
        easterSunday = easterSunday.minusDays(2);
        break;
      case EASTER_SATURDAY:
        easterSunday = easterSunday.minusDays(1);
        break;
      case EASTER_MONDAY:
View Full Code Here

Examples of org.joda.time.LocalDate.minusDays()

        break;
      case GOOD_FRIDAY:
        easterSunday = easterSunday.minusDays(2);
        break;
      case EASTER_SATURDAY:
        easterSunday = easterSunday.minusDays(1);
        break;
      case EASTER_MONDAY:
        easterSunday = easterSunday.plusDays(1);
        break;
      case EASTER_TUESDAY:
View Full Code Here

Examples of org.joda.time.LocalDate.minusDays()

        continue;
      }
      LocalDate day = calendarUtil.create(year, f.getDay());
      day = moveDateToFirstOccurenceOfWeekday(f, day);
      int days = determineNumberOfDays(f);
      day = f.getWhen() == When.AFTER ? day.plusDays(days) : day.minusDays(days);
      HolidayType type = xmlUtil.getType(f.getLocalizedType());
      holidays.add(new Holiday(day, f.getDescriptionPropertiesKey(), type));
    }
  }
View Full Code Here

Examples of org.joda.time.LocalDate.minusDays()

        AvailabilityTimeLine timeLine = AvailabilityTimeLine.allValid();
        LocalDate intervalStart = contemporaryExample.minusDays(10);
        LocalDate intervalEnd = contemporaryExample.plusDays(5);

        timeLine.invalidAt(intervalStart, intervalEnd);
        timeLine.invalidAt(intervalStart.plusDays(2), intervalEnd.minusDays(2));

        assertFalse(timeLine.isValid(intervalEnd.minusDays(1)));
    }

    @Test
View Full Code Here

Examples of org.joda.time.LocalDate.minusDays()

        LocalDate intervalEnd = contemporaryExample.plusDays(5);

        timeLine.invalidAt(intervalStart, intervalEnd);
        timeLine.invalidAt(intervalStart.plusDays(2), intervalEnd.minusDays(2));

        assertFalse(timeLine.isValid(intervalEnd.minusDays(1)));
    }

    @Test
    public void addingAnIntervalThatItsNotCompletelyInvalid() {
        AvailabilityTimeLine timeLine = AvailabilityTimeLine.allValid();
View Full Code Here

Examples of org.joda.time.LocalDate.minusDays()

        LocalDate today = new LocalDate();
        LocalDate tomorrow = today.plusDays(1);
        EffortDuration oneHour = EffortDuration.hours(1);
        EffortDuration halfHour = EffortDuration.minutes(30);
        assertEquals(IntraDayDate.create(today, halfHour),
                IntraDayDate.create(tomorrow.minusDays(1), halfHour));
        assertEquals(IntraDayDate.create(today, halfHour).hashCode(), IntraDayDate
                .create(tomorrow.minusDays(1), halfHour).hashCode());
        assertThat(IntraDayDate.create(today, halfHour),
                not(equalTo(IntraDayDate.create(today, oneHour))));
    }
View Full Code Here

Examples of org.joda.time.LocalDate.minusDays()

        EffortDuration oneHour = EffortDuration.hours(1);
        EffortDuration halfHour = EffortDuration.minutes(30);
        assertEquals(IntraDayDate.create(today, halfHour),
                IntraDayDate.create(tomorrow.minusDays(1), halfHour));
        assertEquals(IntraDayDate.create(today, halfHour).hashCode(), IntraDayDate
                .create(tomorrow.minusDays(1), halfHour).hashCode());
        assertThat(IntraDayDate.create(today, halfHour),
                not(equalTo(IntraDayDate.create(today, oneHour))));
    }

    @Test
View Full Code Here

Examples of org.joda.time.LocalDate.minusDays()

    public void whenResettingAssignmentsOnIntervalOnlyTheOnesAtTheIntervalAreAdded() {
        givenADerivedAllocation();
        LocalDate start = new LocalDate(2008, 12, 1);
        givenDayAssignments(start, worker, 8, 8, 8, 8);
        derivedAllocation.resetAssignmentsTo(dayAssignments);
        DerivedDayAssignment newAssignment = DerivedDayAssignment.create(start
                .minusDays(1), 3, worker, derivedAllocation);
        derivedAllocation.resetAssignmentsTo(start, start.plusDays(4), Arrays
                .asList(newAssignment));
        assertTrue(derivedAllocation.getAssignments().isEmpty());
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.