|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.quartercode.quarterbukkit.api.scheduler.ScheduleTask
public abstract class ScheduleTask
This class is for implementing an easy to use schedule-task fir the Bukkit-Scheduler.
| Constructor Summary | |
|---|---|
ScheduleTask(org.bukkit.plugin.Plugin plugin)
Creates a schedule task with a custom Plugin. |
|
| Method Summary | |
|---|---|
ScheduleTask |
add(java.util.Collection<ScheduleTask> collection)
Adds the schedule task to a Collection (this may be a ScheduleGroup). |
ScheduleTask |
cancel()
Cancels this schedule task. |
boolean |
equals(java.lang.Object obj)
|
int |
hashCode()
|
boolean |
isRunning()
Returns if the ScheduleTask is running. |
ScheduleTask |
run(boolean sync,
long delay)
Deprecated. This method is deprecated. Use run(long) instead. |
ScheduleTask |
run(boolean sync,
long delay,
long period)
Deprecated. This method is deprecated. Use run(long, long) instead. |
ScheduleTask |
run(long delay)
Runs the scheduler once with a delay. |
ScheduleTask |
run(long delay,
long period)
Runs the scheduler repeating with a delay until it's cancelled. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.lang.Runnable |
|---|
run |
| Constructor Detail |
|---|
public ScheduleTask(org.bukkit.plugin.Plugin plugin)
Plugin. This is recommended!
plugin - The custom plugin.| Method Detail |
|---|
public boolean isRunning()
public ScheduleTask add(java.util.Collection<ScheduleTask> collection)
Collection (this may be a ScheduleGroup).
collection - The Collection to add the task.
@Deprecated
public ScheduleTask run(boolean sync,
long delay)
run(long) instead.
sync - Should the scheduler runs synced with the Bukkit-Main-Thread. Async tasks are deprecated!delay - The delay in ticks.
@Deprecated
public ScheduleTask run(boolean sync,
long delay,
long period)
run(long, long) instead.
sync - Should the scheduler runs synced with the Bukkit-Main-Thread. Async tasks are deprecated!delay - The delay in ticks.period - The delay between two repeatings in ticks.
public ScheduleTask run(long delay)
delay - The delay in ticks.
public ScheduleTask run(long delay,
long period)
delay - The delay in ticks.period - The delay between two repeatings in ticks.
public ScheduleTask cancel()
public int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||