ForwardingListener

gears.async.Listener.ForwardingListener
See theForwardingListener companion object
abstract case class ForwardingListener[T](src: Source[_], inner: Listener[_]) extends Listener[T]

A special class of listener that forwards the inner listener through the given source. For purposes of Async.Source.dropListener these listeners are compared for equality by the hash of the source and the inner listener.

Attributes

Companion
object
Graph
Supertypes
trait Serializable
trait Product
trait Equals
trait Listener[T]
class Object
trait Matchable
class Any
Show all

Members list

Value members

Inherited methods

final inline def acquireLock(): Boolean

Attempts to lock the listener, if such a lock exists. Succeeds with true immediately if lock is null.

Attempts to lock the listener, if such a lock exists. Succeeds with true immediately if lock is null.

Attributes

Inherited from:
Listener
def completeNow(data: T, source: Source[T]): Boolean

Attempts to acquire locks and then calling complete with the given item and source. If locking fails, releaseLock is automatically called.

Attempts to acquire locks and then calling complete with the given item and source. If locking fails, releaseLock is automatically called.

Attributes

Inherited from:
Listener
def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product
final inline def releaseLock(): Unit

Release the listener's lock if it exists.

Release the listener's lock if it exists.

Attributes

Inherited from:
Listener

Inherited and Abstract methods

def complete(data: T, source: Source[T]): Unit

Complete the listener with the given item, from the given source. If the listener exposes a Listener.ListenerLock, it is required to acquire this lock before calling complete. This can also be done conveniently with completeNow. For performance reasons, this condition is usually not checked and will end up causing unexpected behavior if not satisfied.

Complete the listener with the given item, from the given source. If the listener exposes a Listener.ListenerLock, it is required to acquire this lock before calling complete. This can also be done conveniently with completeNow. For performance reasons, this condition is usually not checked and will end up causing unexpected behavior if not satisfied.

The listener must automatically release its own lock upon completion.

Attributes

Inherited from:
Listener

Inherited and Abstract fields

val lock: ListenerLock | Null

Represents the exposed API for synchronization on listeners at receiving time. If the listener does not have any form of synchronization, lock should be null.

Represents the exposed API for synchronization on listeners at receiving time. If the listener does not have any form of synchronization, lock should be null.

Attributes

Inherited from:
Listener