Package io.github.anass_abea.impl
Class DurationImpl
java.lang.Object
io.github.anass_abea.impl.DurationImpl
- All Implemented Interfaces:
Duration
public class DurationImpl extends java.lang.Object implements Duration
-
Constructor Summary
Constructors Constructor Description DurationImpl(long diff)
DurationImpl(long diff, boolean isPast, Unit unit)
DurationImpl(long diff, Unit unit)
-
Method Summary
Modifier and Type Method Description long
getDiff()
long
getNumberOfUnits()
Unit
getUnit()
boolean
isPast()
-
Constructor Details
-
DurationImpl
-
DurationImpl
-
DurationImpl
public DurationImpl(long diff)
-
-
Method Details
-
getDiff
public long getDiff() -
isPast
public boolean isPast() -
getUnit
-
getNumberOfUnits
public long getNumberOfUnits()- Specified by:
getNumberOfUnits
in interfaceDuration
-