# net.axay.kspigot.runnables

# Package net.axay.kspigot.runnables

## Types

ChainedRunnablePart
Link copied to clipboard
abstract class ChainedRunnablePart<T, R>(sync: Boolean)
Content copied to clipboard
ChainedRunnablePartFirst
Link copied to clipboard
class ChainedRunnablePartFirst<R>(runnable: () -> R, sync: Boolean) : ChainedRunnablePart<Unit, R>
Content copied to clipboard
ChainedRunnablePartThen
Link copied to clipboard
class ChainedRunnablePartThen<T, R>(runnable: (T) -> R, sync: Boolean, previous: ChainedRunnablePart<*, T>) : ChainedRunnablePart<T, R>
Content copied to clipboard
KSpigotRunnable
Link copied to clipboard
abstract class KSpigotRunnable(counterUp: Long?, counterDownToOne: Long?, counterDownToZero: Long?) : BukkitRunnable
Content copied to clipboard

## Functions

async
Link copied to clipboard

Starts an asynchronous task.

fun async(runnable: () -> Unit): BukkitTask
Content copied to clipboard
firstAsync
Link copied to clipboard
fun <R> firstAsync(runnable: () -> R): ChainedRunnablePartFirst<R>
Content copied to clipboard
firstDo
Link copied to clipboard
fun <R> firstDo(sync: Boolean, runnable: () -> R): ChainedRunnablePartFirst<R>
Content copied to clipboard
firstSync
Link copied to clipboard
fun <R> firstSync(runnable: () -> R): ChainedRunnablePartFirst<R>
Content copied to clipboard
sync
Link copied to clipboard

Starts a synchronous task.

fun sync(runnable: () -> Unit): BukkitTask
Content copied to clipboard
task
Link copied to clipboard

Starts a new BukkitRunnable.

fun task(sync: Boolean, delay: Long, period: Long?, howOften: Long?, safe: Boolean, endCallback: () -> Unit?, runnable: (KSpigotRunnable) -> Unit?)
Content copied to clipboard
thenAsync
Link copied to clipboard
fun <T, R, U> ChainedRunnablePart<T, R>.thenAsync(runnable: (R) -> U): ChainedRunnablePartThen<R, U>
Content copied to clipboard
thenDo
Link copied to clipboard
fun <T, R, U> ChainedRunnablePart<T, R>.thenDo(sync: Boolean, runnable: (R) -> U): ChainedRunnablePartThen<R, U>
Content copied to clipboard
thenSync
Link copied to clipboard
fun <T, R, U> ChainedRunnablePart<T, R>.thenSync(runnable: (R) -> U): ChainedRunnablePartThen<R, U>
Content copied to clipboard