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

Method isEmpty

base/src/main/java/net/time4j/Duration.java:3082–3094  ·  view source on GitHub ↗
(TimeSpan<U> timespan)

Source from the content-addressed store, hash-verified

3080
3081 // wildcard capture
3082 private static <U> boolean isEmpty(TimeSpan<U> timespan) {
3083
3084 List<Item<U>> items = timespan.getTotalLength();
3085
3086 for (int i = 0, n = items.size(); i < n; i++) {
3087 if (items.get(i).getAmount() > 0) {
3088 return false;
3089 }
3090 }
3091
3092 return true;
3093
3094 }
3095
3096 private static <U extends IsoUnit> Duration<U> create(
3097 Map<U, Long> map,

Callers 8

plusMethod · 0.95
multipliedByMethod · 0.95
toCalendarPeriodMethod · 0.95
toClockPeriodMethod · 0.95
truncatedToMethod · 0.95
toStringMethod · 0.95
mergeMethod · 0.95

Calls 4

getTotalLengthMethod · 0.65
getMethod · 0.65
sizeMethod · 0.45
getAmountMethod · 0.45

Tested by

no test coverage detected