A time API with timezone/cron for vrml library
<dependency>
<groupId>group.rxcloud</groupId>
<artifactId>vrml-time</artifactId>
<version>1.1.4</version>
</dependency>
The ThreadLocal time utils. Avoid the overhead of creating DateFormat repeatedly. Focus on the three types of Date/Time/DateTime. Operation orientation to the Date/Timestamp/String.
// use static func
ThreadLocalTimeUtils.func(params);
TimeZone time conversion.
TimeZone -12 ~ +12 based on UTC.
// TimeZone conversion
TimeZoneUtils.parseTimezoneTimestamp(sourceTimezone, targetTimezone, sourceTimestamp);
Parse the cron expression.
Three parsing approaches are supported : DAY/WEEK/MONTH.
Support for parsing timezone transitions.
// cron expression resolution for timezone conversion
CronExpressionUtils.parseCronToTargetTimeZone(TimeZoneCronParseBuilder builder);
// cron expression resolution
CronExpressionUtils.parseCron(SimpleCronParseBuilder builder);
Check it out below:
import CronExpressionUtilsTest;
import TimeZoneUtilsTest;
import ThreadLocalTimeUtilsTest;
Developer repository can be found here.
<dependency>
<groupId>group.rxcloud</groupId>
<artifactId>vrml-time</artifactId>
<version>1.1.4</version>
</dependency>
A small number of users have reported problems building vrml. Read our contribution guide for details.