Scheduler

trait Scheduler[T <: Txn[T]]

A Scheduler uses a logical frame clock to execute functions transactionally at specific times. It is parametrized in S in order to perform transactions, but it does not store any state that would need the scheduler to be handled with stm.Source. It can be safely stored in a regular value.

A Scheduler uses a logical frame clock to execute functions transactionally at specific times. It is parametrized in S in order to perform transactions, but it does not store any state that would need the scheduler to be handled with stm.Source. It can be safely stored in a regular value.

Companion
object
class Object
trait Matchable
class Any
trait Offline[T]

Value members

Abstract methods

def cancel(token: Int)(tx: T): Unit

Cancels a scheduled action. It is ok to use an old token that was already completed or cancelled.

Cancels a scheduled action. It is ok to use an old token that was already completed or cancelled.

def schedule(time: Long)(fun: T => Unit)(tx: T): Int

Schedules the execution of a function at a given time. Time is given as an "absolute" frame in the sense of AuralContext.time. Returns a token that can be used to cancel the action. The token is >= 0.

Schedules the execution of a function at a given time. Time is given as an "absolute" frame in the sense of AuralContext.time. Returns a token that can be used to cancel the action. The token is >= 0.

def stepTag[A](fun: T => A): A

Performs a tagged transaction step.

Performs a tagged transaction step.

See also

de.sciss.lucre.Cursor.stepTag

def time(tx: T): Long

Logical time frame based on TimeRef.SampleRate and with zero corresponding to creation time. Frames elapsed with wall-clock but are stable within a transaction.

Logical time frame based on TimeRef.SampleRate and with zero corresponding to creation time. Frames elapsed with wall-clock but are stable within a transaction.

Implicits

Implicits

implicit def cursor: Cursor[T]