class OneOneBuf[T] extends channel.N2NBuf[T] with AltCapableChannel[T]
A version of its namesake from io.threadcso.channel with the capacity to participate in alt
and serve
commands
- See also
- Alphabetic
- By Inheritance
- OneOneBuf
- AltCapableChannel
- Chan
- OutPort
- InPort
- N2NBuf
- SharedChan
- SharedInPort
- SharedOutPort
- Chan
- Debuggable
- Named
- OutPort
- InPort
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
- new OneOneBuf(size: Int, name: String)
Value Members
-
def
!(value: T): Unit
Output
value
to the port's channel. -
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
def
=!=>(gen: ⇒ T): OutPortEvent[T]
Construct an unconditional output event for use in an alternation.
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
=?=>(body: (T) ⇒ Unit): InPortEvent[T]
Construct an unconditional input event for use in an alternation.
-
def
=??=>(body: (T) ⇒ Unit): InPortEventExtended[T]
Construct an unconditional extended-rendezvous input event for use in an alternation.
-
def
?[U](f: (T) ⇒ U): U
Block until a value t is available for input, then return
f(
t)
-- equivalent tof(?())
. -
def
?(): T
Block until a value is available for input, then read and return it.
-
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). -
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
canInput: Boolean
Returns
false
if no further input will be supplied by this port. -
def
canOutput: Boolean
Returns
false
if no further output can be accepted by this port. -
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
def
close(): Unit
Signal that the channel is to be closed forthwith
-
def
closeIn(): Unit
Signal that no further attempts will be made to input from the invoking thread: idempotent
-
def
closeOut(): Unit
Signal that no further values will be output from the invoking thread: idempotent
-
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] )
-
def
finishedRW: String
Intelligible information about finished reads and writes
Intelligible information about finished reads and writes
- Definition Classes
- N2NBuf
- Annotations
- @elidable( FINEST )
-
def
finishedRead: Long
Increment count of finished reads
Increment count of finished reads
- Definition Classes
- N2NBuf
- Annotations
- @elidable( FINEST )
-
def
finishedWrite: Long
Increment count of finished writes
Increment count of finished writes
- Definition Classes
- N2NBuf
- Annotations
- @elidable( FINEST )
-
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
-
val
inPort: InPort[T]
this
as anInPort
this
as anInPort
- Definition Classes
- Chan
-
def
inPortEvent(portState: PortState): Unit
The channel has just changed its state in a way that will affect
inPortState
-
def
inPortState: PortState
Current state of this port: for alternation implementations
-
def
isEmpty: Boolean
- Definition Classes
- N2NBuf
- Annotations
- @inline()
-
def
isFull: Boolean
- Definition Classes
- N2NBuf
- Annotations
- @inline()
-
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
logLastInState(state: PortState): Unit
For detailed logging
For detailed logging
- Definition Classes
- AltCapableChannel
- Annotations
- @inline() @elidable( FINEST )
-
def
logLastOutState(state: PortState): Unit
For detailed logging
For detailed logging
- Definition Classes
- AltCapableChannel
- Annotations
- @inline() @elidable( FINEST )
-
def
logLastReg(port: String, unreg: Boolean, state: PortState): Unit
For detailed logging
For detailed logging
- Definition Classes
- AltCapableChannel
- Annotations
- @inline() @elidable( FINEST )
-
def
name: String
Return the name of the object
Return the name of the object
- Definition Classes
- Named
-
def
nameGenerator: NameGenerator
Discover the name generator
-
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
-
val
outPort: OutPort[T]
this
as anOutPort
this
as anOutPort
- Definition Classes
- Chan
-
def
outPortEvent(portState: PortState): Unit
The channel has just changed its state in a way that will affect
outPortState
-
def
outPortState: PortState
Current state of this port: for alternation implementations
-
def
readBefore(nsWait: basis.Nanoseconds): Option[T]
Block until the earlier of the following events happens:
-
val
reads: AtomicLong
Count oof the number of finished reads (writes)
Count oof the number of finished reads (writes)
- Definition Classes
- N2NBuf
-
def
register(): Unit
Register this object
Register this object
- Definition Classes
- Debuggable
-
def
registerIn(alt: Runnable, index: Int): PortState
Register an input event with this channel, and return the port state
Register an input event with this channel, and return the port state
- Definition Classes
- AltCapableChannel → InPort
-
def
registerOut(alt: Runnable, index: Int): PortState
Register an output event with this channel, and return the port state
Register an output event with this channel, and return the port state
- Definition Classes
- AltCapableChannel → OutPort
-
def
setInPortStateImp(portState: PortState): Unit
Standard implementation of
setInPortState
for alt-able channelStandard implementation of
setInPortState
for alt-able channel- Attributes
- protected
- Definition Classes
- AltCapableChannel
- Annotations
- @inline()
-
def
setName(name: String): Unit
Set the name using the name generator
Set the name using the name generator
- Definition Classes
- Named
-
def
setOutPortStateImp(portState: PortState): Unit
Standard implementation of
setOutPortState
for alt-able channelStandard implementation of
setOutPortState
for alt-able channel- Attributes
- protected
- Definition Classes
- AltCapableChannel
- Annotations
- @inline()
-
def
showState(out: PrintWriter): Unit
For use by the debugger
For use by the debugger
- Definition Classes
- AltCapableChannel → Debuggable
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
val
theIndex: Int
Index of this channel in the currently-registered running alternation
Index of this channel in the currently-registered running alternation
- Attributes
- protected[this]
- Definition Classes
- AltCapableChannel
- def toString(): String
-
def
unregister(): Unit
Unregister this object
Unregister this object
- Definition Classes
- Debuggable
-
def
unregisterIn(): PortState
Unregister an input event with this channel, and return the port state
Unregister an input event with this channel, and return the port state
- Definition Classes
- AltCapableChannel → InPort
-
def
unregisterOut(): PortState
Unregister an output event with this channel, and return the port state
Unregister an output event with this channel, and return the port state
- Definition Classes
- AltCapableChannel → OutPort
-
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): channel.Chan[T]
Set the name of this object and return it
Set the name of this object and return it
- Definition Classes
- Named
-
def
writeBefore(nsWait: Long)(value: T): Boolean
Output
value
to the port's channel beforensWait
has elapsed, and return true; or return false -
val
writes: AtomicLong
Count oof the number of finished reads (writes)
Count oof the number of finished reads (writes)
- Definition Classes
- N2NBuf