Class TimerTaskTime
java.lang.Object
me.hsgamer.hscore.bukkit.scheduler.TimerTaskTime
The time for repeating task
-
Method Summary
Modifier and TypeMethodDescriptionlonggetDelay()Get the delaylongGet the delay in tickslongGet the normalized delay.longGet the normalized delay in ticks.longGet the normalized period.longGet the normalized period in ticks.longGet the periodlongGet the period in ticksgetUnit()Get the unitstatic TimerTaskTimeof(long delayTicks, long periodTicks) Create a new time from ticksstatic TimerTaskTimeCreate a new time
-
Method Details
-
of
Create a new time- Parameters:
delay- the delayperiod- the periodunit- the unit- Returns:
- the time
-
of
Create a new time from ticks- Parameters:
delayTicks- the delay in ticksperiodTicks- the period in ticks- Returns:
- the time
-
getDelay
public long getDelay()Get the delay- Returns:
- the delay
-
getNormalizedDelay
public long getNormalizedDelay()Get the normalized delay. If the delay is less than or equal to 0, it will return 1 or 50 (if fromTicks is true).- Returns:
- the normalized delay
-
getPeriod
public long getPeriod()Get the period- Returns:
- the period
-
getNormalizedPeriod
public long getNormalizedPeriod()Get the normalized period. If the period is less than or equal to 0, it will return 1 or 50 (if fromTicks is true).- Returns:
- the normalized period
-
getUnit
Get the unit- Returns:
- the unit
-
getDelayTicks
public long getDelayTicks()Get the delay in ticks- Returns:
- the delay in ticks
-
getNormalizedDelayTicks
public long getNormalizedDelayTicks()Get the normalized delay in ticks. If the delay is less than or equal to 0, it will return 1.- Returns:
- the normalized delay in ticks
-
getPeriodTicks
public long getPeriodTicks()Get the period in ticks- Returns:
- the period in ticks
-
getNormalizedPeriodTicks
public long getNormalizedPeriodTicks()Get the normalized period in ticks. If the period is less than or equal to 0, it will return 1.- Returns:
- the normalized period in ticks
-