I am trying to benefit from the use of TimeCategory in Groovy and although it is a neat class, seems the locale to be used is stuck at English.
The documentation says that the Duration class (parent of TimeCategory) will Get the DST offset (if any) for the default locale and the given date1
Although I alter the locale in the execution of the program, there is no change in the outcome. Any hints or thoughts how can this be done?
use(groovy.time.TimeCategory) {
expirationDate = creationDate + 5.years
duration = expirationDate - new Date()
}
Outputing duration is something like: 1822 days, 16 hours, 3 minutes... Stuck in English