MCPcopy Create free account
hub / github.com/MenoData/Time4J / withEmptyUnit

Method withEmptyUnit

base/src/main/java/net/time4j/PrettyTime.java:492–508  ·  view source on GitHub ↗
(CalendarUnit emptyUnit)

Source from the content-addressed store, hash-verified

490 * @see #print(Duration, TextWidth)
491 */
492 public PrettyTime withEmptyUnit(CalendarUnit emptyUnit) {
493 if (this.emptyUnit.equals(emptyUnit)) {
494 return this;
495 }
496
497 return new PrettyTime(
498 this.locale,
499 this.refClock,
500 this.numsys,
501 this.zeroDigit,
502 this.minusSign,
503 emptyUnit,
504 this.weekToDays,
505 this.shortStyle,
506 this.stdListSeparator,
507 this.endListSeparator);
508 }
509
510 /**
511 * <p>Defines the time unit used for formatting an empty duration. </p>

Callers 4

withEmptyDayUnitMethod · 0.80
withEmptyMinuteUnitMethod · 0.80
withEmptyNullUnitMethod · 0.80
print0MonthsArabic2Method · 0.80

Calls 1

equalsMethod · 0.45

Tested by 4

withEmptyDayUnitMethod · 0.64
withEmptyMinuteUnitMethod · 0.64
withEmptyNullUnitMethod · 0.64
print0MonthsArabic2Method · 0.64