Bukkit-API  1.7.9-R0.2
The inofficial Bukkit-API
BukkitTask.java
1 package org.bukkit.scheduler;
2 
3 import org.bukkit.plugin.Plugin;
4 
5 /**
6  * Represents a task being executed by the scheduler
7  */
8 public interface BukkitTask {
9 
10  /**
11  * Returns the taskId for the task.
12  *
13  * @return Task id number
14  */
15  public int getTaskId();
16 
17  /**
18  * Returns the Plugin that owns this task.
19  *
20  * @return The Plugin that owns the task
21  */
22  public Plugin getOwner();
23 
24  /**
25  * Returns true if the Task is a sync task.
26  *
27  * @return true if the task is run by main thread
28  */
29  public boolean isSync();
30 
31  /**
32  * Will attempt to cancel this task.
33  */
34  public void cancel();
35 }