dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #30303
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 15386: minor fixes to calendar classes
------------------------------------------------------------
revno: 15386
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2014-05-23 17:34:22 +0200
message:
minor fixes to calendar classes
modified:
dhis-2/dhis-api/src/main/java/org/hisp/dhis/calendar/DateUnit.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/calendar/DateUnitPeriodTypeParser.java
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/calendar/DateUnit.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/calendar/DateUnit.java 2014-05-21 13:47:37 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/calendar/DateUnit.java 2014-05-23 15:34:22 +0000
@@ -87,20 +87,20 @@
public DateUnit( DateUnit dateUnit )
{
+ this( dateUnit.isIso8601() );
this.year = dateUnit.getYear();
this.month = dateUnit.getMonth();
this.day = dateUnit.getDay();
this.dayOfWeek = dateUnit.getDayOfWeek();
- this.iso8601 = dateUnit.isIso8601();
}
public DateUnit( DateUnit dateUnit, boolean iso8601 )
{
+ this( iso8601 );
this.year = dateUnit.getYear();
this.month = dateUnit.getMonth();
this.day = dateUnit.getDay();
this.dayOfWeek = dateUnit.getDayOfWeek();
- this.iso8601 = iso8601;
}
public DateUnit( int year, int month, int day, boolean iso8601 )
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/calendar/DateUnitPeriodTypeParser.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/calendar/DateUnitPeriodTypeParser.java 2014-05-21 11:12:07 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/calendar/DateUnitPeriodTypeParser.java 2014-05-23 15:34:22 +0000
@@ -41,7 +41,7 @@
*/
public class DateUnitPeriodTypeParser implements PeriodTypeParser
{
- private Map<String, Pattern> compileCache = Maps.newHashMap();
+ private final Map<String, Pattern> compileCache = Maps.newHashMap();
private static CalendarService calendarService;