Package jetbrains.buildServer
Class MockTimeService
- java.lang.Object
-
- jetbrains.buildServer.MockTimeService
-
- All Implemented Interfaces:
DefaultMessagesInfo.MessagesTimeService,TimeService
public class MockTimeService extends Object implements TimeService, DefaultMessagesInfo.MessagesTimeService
-
-
Field Summary
Fields Modifier and Type Field Description longmyTime
-
Constructor Summary
Constructors Constructor Description MockTimeService()MockTimeService(long time)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DategetNow()voidinc()voidinc(long amount, TimeUnit timeUnit)voidjumpTo(int periodInSeconds)voidjumpTo(long periodInMilliseconds)longnow()Provides current time millis.voidsetTime(long currentTimeMillis)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface jetbrains.buildServer.util.TimeService
nowDate
-
-
-
-
Method Detail
-
now
public long now()
Description copied from interface:TimeServiceProvides current time millis.- Specified by:
nowin interfaceTimeService- Returns:
- current time.
-
getNow
public Date getNow()
- Specified by:
getNowin interfaceDefaultMessagesInfo.MessagesTimeService
-
inc
public void inc()
-
inc
public void inc(long amount, TimeUnit timeUnit)
-
jumpTo
public void jumpTo(int periodInSeconds)
-
jumpTo
public void jumpTo(long periodInMilliseconds)
-
setTime
public void setTime(long currentTimeMillis)
-
-