ChangeEventImpl

class ChangeEventImpl[T](_bud: State[(Pulse[T], Pulse[Diff[T]])], signal: Signal[T], name: ReName) extends Base[(Pulse[T], Pulse[Diff[T]])] with Derived with Event[Diff[T]] with DisconnectableImpl
trait Event[Diff[T]]
trait InterpMacro[Option[Diff[T]]]
trait MacroAccess[Option[Diff[T]], Interp[Option[Diff[T]]]]
trait EventCompat[Diff[T]]
trait Interp[Option[Diff[T]]]
trait Derived
class Base[(Pulse[T], Pulse[Diff[T]])]
trait ReSource
class Object
trait Matchable
class Any

Document{}

final
def +=(handler: Diff[T] => Unit)(implicit ticket: CreationTicket): Observe

Adds an observer.

Adds an observer.

See also

observe

Inherited from
Event
final
def \[U](except: Event[U])(implicit ticket: CreationTicket): Event[Diff[T]]

Propagates the event only when except does not fire.

Propagates the event only when except does not fire.

Inherited from
Event
final
def and[U, R](other: Event[U])(merger: (Diff[T], U) => R)(implicit ticket: CreationTicket): Event[R]

Merge the event with the other, if both fire simultaneously.

Merge the event with the other, if both fire simultaneously.

Inherited from
Event
@compileTimeOnly(_root_.scala.StringContext.apply("", " apply can only be used inside of reactive expressions").s(this))
final
def apply(): Option[Diff[T]]

Makes the enclosing reactive expression depend on the current value of the reactive. Is an alias for value.

Makes the enclosing reactive expression depend on the current value of the reactive. Is an alias for value.

See also

value

Inherited from
MacroAccess
final
def collect[U](expression: PartialFunction[Diff[T], U])(implicit ticket: CreationTicket): Event[U]

Collects the results from a partial function

Collects the results from a partial function

Inherited from
EventCompat
final
def count()(implicit ticket: CreationTicket): Signal[Int]

Counts the occurrences of the event. The argument of the event is discarded. Always starts from 0 when the count is created (no matter how often the event has activated in the past).

Counts the occurrences of the event. The argument of the event is discarded. Always starts from 0 when the count is created (no matter how often the event has activated in the past).

Inherited from
Event
final
def dropParam(implicit ticket: CreationTicket): Event[Unit]

Drop the event parameter; equivalent to map((_: Any) => ())

Drop the event parameter; equivalent to map((_: Any) => ())

Inherited from
Event
final
def filter(expression: Diff[T] => Boolean)(implicit ticket: CreationTicket): Event[Diff[T]]

Filters the event, only propagating the value when the filter is true.

Filters the event, only propagating the value when the filter is true.

Inherited from
EventCompat
final
def flatten[R](implicit flatten: Flatten[Event[Diff[T]], R]): R

Flattens the inner value.

Flattens the inner value.

Inherited from
Event
final
def fold[A](init: A)(op: (A, Diff[T]) => A)(implicit ticket: CreationTicket): Signal[A]

Folds events with a given operation to create a Signal.

Folds events with a given operation to create a Signal.

Inherited from
EventCompat
final
def iterate[A](init: A)(f: A => A)(implicit ticket: CreationTicket): Signal[A]

Applies a function on the current value of the signal every time the event occurs, starting with the init value before the first event occurrence

Applies a function on the current value of the signal every time the event occurs, starting with the init value before the first event occurrence

Inherited from
Event
final
def last[A >: Diff[T]](n: Int)(implicit ticket: CreationTicket): Signal[LinearSeq[A]]

Returns a signal which holds the last n events in a list. At the beginning the list increases in size up to when n values are available

Returns a signal which holds the last n events in a list. At the beginning the list increases in size up to when n values are available

Inherited from
Event
final
def latest[A >: Diff[T]]()(implicit ticket: CreationTicket): Signal[A]

returns a signal holding the latest value of the event.

returns a signal holding the latest value of the event.

Inherited from
Event
final
def latest[A >: Diff[T]](init: A)(implicit ticket: CreationTicket): Signal[A]

returns a signal holding the latest value of the event.

returns a signal holding the latest value of the event.

Value Params
init

initial value of the returned signal

Inherited from
Event
final
def latestOption[A >: Diff[T]]()(implicit ticket: CreationTicket): Signal[Option[A]]

Holds the latest value of an event as an Option, None before the first event occured

Holds the latest value of an event as an Option, None before the first event occured

Inherited from
Event
final
def list[A >: Diff[T]]()(implicit ticket: CreationTicket): Signal[List[A]]

collects events resulting in a variable holding a list of all values.

collects events resulting in a variable holding a list of all values.

Inherited from
Event
final
def map[A](expression: Diff[T] => A)(implicit ticket: CreationTicket): Event[A]

Transform the event.

Transform the event.

Inherited from
EventCompat
final
def observe(onValue: Diff[T] => Unit, onError: Throwable => Unit, fireImmediately: Boolean)(implicit ticket: CreationTicket): Observe

Add an observer.

Add an observer.

Returns

the resulting rescala.operator.Observing.Observe can be used to remove the observer.

Inherited from
Event
final
def reduce[A](reducer: (=> A, => Diff[T]) => A)(implicit ticket: CreationTicket): Signal[A]

reduces events with a given reduce function to create a Signal

reduces events with a given reduce function to create a Signal

Inherited from
Event
final
def toggle[A](a: Signal[A], b: Signal[A])(implicit ticket: CreationTicket): Signal[A]

Switch back and forth between two signals on occurrence of event e

Switch back and forth between two signals on occurrence of event e

Inherited from
Event
@compileTimeOnly("value can only be used inside of reactive expressions")
final
def value: Option[Diff[T]]

Makes the enclosing reactive expression depend on the current value of the reactive. Is an alias for rescala.macros.MacroAccess.apply.

Makes the enclosing reactive expression depend on the current value of the reactive. Is an alias for rescala.macros.MacroAccess.apply.

See also

apply

Inherited from
MacroAccess
final
def zip[U](other: Event[U])(implicit ticket: CreationTicket): Event[(Diff[T], U)]

Merge the event with the other into a tuple, if both fire simultaneously.

Merge the event with the other into a tuple, if both fire simultaneously.

See also

and

Inherited from
Event
final
def zipOuter[U](other: Event[U])(implicit ticket: CreationTicket): Event[(Option[Diff[T]], Option[U])]

Merge the event with the other into a tuple, even if only one of them fired.

Merge the event with the other into a tuple, even if only one of them fired.

Inherited from
Event
final
def ||[U >: Diff[T]](other: Event[U])(implicit ticket: CreationTicket): Event[U]

Events disjunction. Propagates the values if any of the events fires. Only propagates the left event if both fire.

Events disjunction. Propagates the values if any of the events fires. Only propagates the left event if both fire.

Inherited from
Event

Type members

Types

override
type Value = (Pulse[T], Pulse[Diff[T]])

Inherited types

final
Inherited from
Derived
final
type Rout = Result[Value]
Inherited from
Derived

Value members

Concrete methods

override
def internalAccess(v: (Pulse[T], Pulse[Diff[T]])): Pulse[Diff[T]]
Definition Classes
override
def interpret(v: Value): Option[Diff[T]]
Definition Classes

Inherited methods

final
def disconnect()(implicit engine: Scheduler): Unit
Inherited from
DisconnectableImpl
def guardReevaluate(rein: ReIn)(normalEval: => Rout): Rout
Inherited from
DisconnectableImpl
final
def recover[R >: Diff[T]](onFailure: PartialFunction[Throwable, Option[R]])(implicit ticket: CreationTicket): Event[R]

Uses a partial function onFailure to recover an error carried by the event into a value when returning Some(value), or filters the error when returning None

Uses a partial function onFailure to recover an error carried by the event into a value when returning Some(value), or filters the error when returning None

Inherited from
Event
def resource: Interp[Option[Diff[T]]]
Inherited from
Event
override
def toString: String
Definition Classes
Base -> Any
Inherited from
Base