class BiMonthlyPeriodType extends CalendarPeriodType {

    @Override
    public Period createPeriod( DateTimeUnit dateTimeUnit, Calendar calendar )
    {
        DateTimeUnit start = new DateTimeUnit( dateTimeUnit );
        start.setMonth( ((start.getMonth() - 1) - ((start.getMonth() - 1) % 2)) + 1 );
        start.setDay( 1 );

        DateTimeUnit end = new DateTimeUnit( start );

        end = calendar.plusMonths( end, 1 );
        end.setDay( calendar.daysInMonth( end.getYear(), end.getMonth() ) );

        return toIsoPeriod( start, end, calendar );
    }

}