public class Test {
public static void main(String[] args) {
Duration duration = Duration.ofSeconds(61);
// 1 minute 1 second
System.out.println(DurationFormatUtils.formatDurationWords(duration.toMillis(), true, true));
// 0天0小时1分钟1秒
System.out.println(DurationFormatUtils.formatDuration(duration.toMillis(), "d'天'H'小时'm'分钟's'秒'"));
// 00天00小时01分钟01秒
System.out.println(DurationFormatUtils.formatDuration(duration.toMillis(), "dd天HH小时mm分钟ss秒"));
}
}