Package io.jmix.core.impl
Class TimeSourceImpl
java.lang.Object
io.jmix.core.impl.TimeSourceImpl
- All Implemented Interfaces:
TimeSource
Standard implementation of
TimeSource
interface.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionlong
Return current timestamp in milliseconds.Return current timestamp as Date instance.now()
ReturnZonedDateTime
for current timestamp.
-
Constructor Details
-
TimeSourceImpl
public TimeSourceImpl()
-
-
Method Details
-
currentTimestamp
Description copied from interface:TimeSource
Return current timestamp as Date instance.- Specified by:
currentTimestamp
in interfaceTimeSource
- Returns:
- current timestamp
-
currentTimeMillis
public long currentTimeMillis()Description copied from interface:TimeSource
Return current timestamp in milliseconds.- Specified by:
currentTimeMillis
in interfaceTimeSource
- Returns:
- number of milliseconds since 1970-01-01 00:00
-
now
Description copied from interface:TimeSource
ReturnZonedDateTime
for current timestamp.- Specified by:
now
in interfaceTimeSource
- Returns:
- ZonedDateTime
-