Package com.plotsquared.core.util.task
Class TaskTime
java.lang.Object
com.plotsquared.core.util.task.TaskTime
Task timings
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic interface -
Method Summary
Modifier and TypeMethodDescriptionboolean@org.checkerframework.checker.index.qual.NonNegative longgetTime()Get the task time@NonNull TaskTime.TaskUnitgetUnit()Get the time unitinthashCode()static @NonNull TaskTimems(@org.checkerframework.checker.index.qual.NonNegative long ms)Create a new task time in millisecondsstatic @NonNull TaskTimeseconds(@org.checkerframework.checker.index.qual.NonNegative long seconds)Create a new task time in secondsstatic @NonNull TaskTimeticks(@org.checkerframework.checker.index.qual.NonNegative long ticks)Create a new task time in server ticks
-
Method Details
-
seconds
public static @NonNull TaskTime seconds(@org.checkerframework.checker.index.qual.NonNegative long seconds)Create a new task time in seconds- Parameters:
seconds- Seconds- Returns:
- Created task time instance
-
ticks
public static @NonNull TaskTime ticks(@org.checkerframework.checker.index.qual.NonNegative long ticks)Create a new task time in server ticks- Parameters:
ticks- Server ticks- Returns:
- Created task time instance
-
ms
Create a new task time in milliseconds- Parameters:
ms- Milliseconds- Returns:
- Created task time instance
-
getTime
public @org.checkerframework.checker.index.qual.NonNegative long getTime()Get the task time- Returns:
- Task time
-
getUnit
Get the time unit- Returns:
- Time unit
-
equals
-
hashCode
public int hashCode()
-