Package org.bukkit.scheduler
Interface BukkitTask
-
public interface BukkitTaskRepresents a task being executed by the scheduler
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidcancel()Will attempt to cancel this task.@NotNull PlugingetOwner()Returns the Plugin that owns this task.intgetTaskId()Returns the taskId for the task.booleanisCancelled()Returns true if this task has been cancelled.booleanisSync()Returns true if the Task is a sync task.
-
-
-
Method Detail
-
getTaskId
int getTaskId()
Returns the taskId for the task.- Returns:
- Task id number
-
getOwner
@NotNull @NotNull Plugin getOwner()
Returns the Plugin that owns this task.- Returns:
- The Plugin that owns the task
-
isSync
boolean isSync()
Returns true if the Task is a sync task.- Returns:
- true if the task is run by main thread
-
isCancelled
boolean isCancelled()
Returns true if this task has been cancelled.- Returns:
- true if the task has been cancelled
-
cancel
void cancel()
Will attempt to cancel this task.
-
-