The builtin type pipe.
Pipes are a thread-safe way to send objects from one thread to another
thread. Or from one collection of threads to another collection of
threads.
bool |
$isOpen
@file
| state of the pipe
|
int |
$bufferSize
@file
| maximum number of items buffered
|
|
|
NEW() @public | Create a new pipe with buffer size one.
|
|
NEW(bufferSize) @public | Create a new pipe with buffer size bufferSize.
|
|
$setBufferSize(bufferSize) @public | Change the buffer size to bufferSize.
|
|
$close() @public | Close the pipe.
|
|
$wait() @public | Wait for the pipe to be empty and closed.
|
|
$Size()
int @public | Return the number of items currently buffered and ready to be read.
|
|
$write(item)
status @public | Write one item into the pipe.
|
|
$read(st)
Titem @public | Read one item from the pipe.
|
|
$read()
Titem @public | Read one item from the pipe.
|
|