trait Chan[T] extends InPort[T] with OutPort[T] with Named[Chan[T]] with debug.REGISTRY.Debuggable
- Alphabetic
- By Inheritance
- Chan
- Debuggable
- Named
- OutPort
- InPort
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Abstract Value Members
-
abstract
def
!(value: T): Unit
Output
value
to the port's channel.Output
value
to the port's channel.- Definition Classes
- OutPort
-
abstract
def
?[U](f: (T) ⇒ U): U
Block until a value t is available for input, then return
f(
t)
-- equivalent tof(?())
.Block until a value t is available for input, then return
f(
t)
-- equivalent tof(?())
.- Definition Classes
- InPort
-
abstract
def
?(): T
Block until a value is available for input, then read and return it.
Block until a value is available for input, then read and return it.
- Definition Classes
- InPort
-
abstract
def
??[U](f: (T) ⇒ U): U
Block until a value t is available for input, then return
f(
t)
.Block until a value t is available for input, then return
f(
t)
. If the inport is provided by a synchronized channel then synchronisation with the termination of the sender's!
is at the termination of the computation off(
t)
(this is sometimes called an extended rendezvous).- Definition Classes
- InPort
-
abstract
def
canInput: Boolean
Returns
false
if no further input will be supplied by this port.Returns
false
if no further input will be supplied by this port. Returningtrue
is not a guarantee that further input will be supplied.- Definition Classes
- InPort
-
abstract
def
canOutput: Boolean
Returns
false
if no further output can be accepted by this port.Returns
false
if no further output can be accepted by this port. Returningtrue
is not a guarantee that further output will be accepted.- Definition Classes
- OutPort
-
abstract
def
close(): Unit
Signal that the channel is to be closed forthwith
-
abstract
def
closeIn(): Unit
Signal that no further attempts will be made to input from the invoking thread: idempotent
Signal that no further attempts will be made to input from the invoking thread: idempotent
- Definition Classes
- InPort
-
abstract
def
closeOut(): Unit
Signal that no further values will be output from the invoking thread: idempotent
Signal that no further values will be output from the invoking thread: idempotent
- Definition Classes
- OutPort
-
abstract
def
inPortState: PortState
Current state of this port: for alternation implementations
Current state of this port: for alternation implementations
- Definition Classes
- InPort
-
abstract
def
nameGenerator: NameGenerator
Discover the name generator
Discover the name generator
- Definition Classes
- Named
-
abstract
def
outPortState: PortState
Current state of this port: for alternation implementations
Current state of this port: for alternation implementations
- Definition Classes
- OutPort
-
abstract
def
readBefore(ns: Long): Option[T]
Block until the earlier of the following events happens:
Block until the earlier of the following events happens:
- 1. A value, t, is available for input.
- 2.
ns
nanoseconds have elapsed.Return
Some(
t)
in case 1, andNone
in case 2.The longest possible wait that can specified this way is about 146 years.
- Definition Classes
- InPort
-
abstract
def
writeBefore(nsWait: Long)(value: T): Boolean
Output
value
to the port's channel beforensWait
has elapsed, and return true; or return falseOutput
value
to the port's channel beforensWait
has elapsed, and return true; or return false- Definition Classes
- OutPort
Concrete Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
-
def
getWaiting: Seq[Thread]
Return a sequence of the threads currently waiting for this object, if any.
Return a sequence of the threads currently waiting for this object, if any. Default is the empty sequence.
- Definition Classes
- Debuggable
-
def
hasState: Boolean
This object has a state worth showing right now: false if showState will do no output.
This object has a state worth showing right now: false if showState will do no output.
- Definition Classes
- Debuggable
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
-
def
inPortEvent(portState: PortState): Unit
The channel has just changed its state in a way that will affect
inPortState
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
val
key: StateKey
This object's key in the registry (if non-negative)
This object's key in the registry (if non-negative)
- Definition Classes
- Debuggable
-
def
name: String
Return the name of the object
Return the name of the object
- Definition Classes
- Named
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
nothing: T
The null value for this port -- equivalent to
null.asInstanceOf[T]
.The null value for this port -- equivalent to
null.asInstanceOf[T]
. Useful to initialise variables that will in due course be assigned values by reading from the port.- Definition Classes
- InPort
- Annotations
- @inline()
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
-
def
outPortEvent(portState: PortState): Unit
The channel has just changed its state in a way that will affect
outPortState
-
def
register(): Unit
Register this object
Register this object
- Definition Classes
- Debuggable
-
def
setName(name: String): Unit
Set the name using the name generator
Set the name using the name generator
- Definition Classes
- Named
-
def
showState(out: PrintWriter): Unit
Show the current state of this object: default uses
toString
Show the current state of this object: default uses
toString
- Definition Classes
- Debuggable
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- Named → AnyRef → Any
-
def
unregister(): Unit
Unregister this object
Unregister this object
- Definition Classes
- Debuggable
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
def
withDebugger[T](condition: Boolean)(body: ⇒ T): T
Conditionally
register
this object with the debugger only for the duration of the evaluation ofbody
.Conditionally
register
this object with the debugger only for the duration of the evaluation ofbody
. To be used as a last resort for the exasperated CSO toolkit debugger.- Definition Classes
- Debuggable
-
def
withName(__name: String): Chan[T]
Set the name of this object and return it
Set the name of this object and return it
- Definition Classes
- Named