Constructor and Description |
---|
TimerTrigger()
Constructs a new timer trigger.
|
TimerTrigger(long firstTime)
Creates a timer trigger.
|
TimerTrigger(long firstTime,
long period)
Creates a timer trigger.
|
Modifier and Type | Method and Description |
---|---|
long |
getFirstTime() |
long |
getPeriod() |
long |
nextTime(long now)
Returns the time of the next trigger event
|
void |
setFirstTime(long firstTime) |
void |
setPeriod(long period) |
java.lang.String |
toString() |
public TimerTrigger()
public TimerTrigger(long firstTime)
firstTime
- The first time the trigger should fire, in milliseconds.public TimerTrigger(long firstTime, long period)
firstTime
- The first time the trigger should fire, in milliseconds.period
- The interval, in milliseconds, the timer should be triggered.public void setFirstTime(long firstTime)
public long getFirstTime()
public void setPeriod(long period)
public long getPeriod()
public long nextTime(long now)
public java.lang.String toString()
toString
in class java.lang.Object