Expirable

gopher.impl.Expirable
See theExpirable companion object
trait Expirable[A]

Object, which can be expired (usually - reader or writer in SelectGroup) Usage protocol is next: capture if A inside is used, call markUsed and use A if A inside is unused for some reason -- call markFree

Attributes

Companion
object
Source
Expirable.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
trait Reader[A]
class SimpleReader
class MReader
class MReader
class WrappedReader[B]
class ReaderRecord[A]
trait Writer[A]
class SimpleWriter[A]
class WriterRecord[A]
Show all

Members list

Value members

Abstract methods

def canExpire: Boolean

called when reader/writer can become no more available for some reason

called when reader/writer can become no more available for some reason

Attributes

Source
Expirable.scala
def capture(): Capture[A]

capture object, and after this we can or use one (markUsed will be called) or abandon (markFree)

capture object, and after this we can or use one (markUsed will be called) or abandon (markFree)

Attributes

Source
Expirable.scala
def isExpired: Boolean

if this object is expired and should be deleted from queue (for example: when reader is belong to select group and some other action in this select group was performed)

if this object is expired and should be deleted from queue (for example: when reader is belong to select group and some other action in this select group was performed)

Attributes

Source
Expirable.scala
def markFree(): Unit

Called when we can't use captured function (i.e. get function but ).

Called when we can't use captured function (i.e. get function but ).

Attributes

Source
Expirable.scala
def markUsed(): Unit

Called when we submitt to task executor readFunction and now is safe to make exprire all other readers/writers in the same select group

Called when we submitt to task executor readFunction and now is safe to make exprire all other readers/writers in the same select group

Attributes

Source
Expirable.scala