1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74
|
<! -- -*- tcl -*- doctools
-->
<html><head><title>null - Memory channels </title></head>
<! -- Generated from file 'null.man' by tcllib/doctools with format 'html'
-->
<! -- Copyright (c) 1996-2003 Andreas Kupries <andreas_kupries@users.sourceforge.net>
-->
<! -- CVS: $Id$ null.n
-->
<h1> null(n) 2.2 "Memory channels"</h1>
<a name="name"><h2>NAME</h2>
<p> null - Create and manipulate null channels
<a name="synopsis"><h2>SYNOPSIS</h2>
package require <b>Tcl</b><br>
package require <b>memchan</b><br>
<br><table border=1 width=100% cellspacing=0 cellpadding=0><tr bgcolor=lightyellow><td bgcolor=lightyellow><table 0 width=100% cellspacing=0 cellpadding=0><tr valign=top ><td ><b class='cmd'>null</b> </td></tr>
</table></td></tr></table>
<a name="description"><h2>DESCRIPTION</h2>
<p>
The command described here is only available in a not-yet released
version of the package. Use the CVS to get the sources.
<dl>
<dt><b class='cmd'>null</b> <dd>
creates a null channel which absorbs everything written into
it. Reading from it is not possible, or rather will always return zero
bytes. These channels are essentially Tcl-specific variants of the
null device for unixoid operating systems (/dev/null). Transfering the
generated channel between interpreters is possible but does not make
much sense.
</dl>
<a name="options"><h2>OPTIONS</h2>
Memory channels created by <b class='cmd'>null</b> provide one additional option to
set or query.
<dl>
<dt><i class='arg'>-delay ?milliseconds?</i><dd>
A <b class='cmd'>null</b> channel is always writable and readable. This means
that all <b class='cmd'>fileevent</b>-handlers will fire continuously. To
avoid starvation of other event sources the events raised by this
channel type have a configurable delay. This option is set in
milliseconds and defaults to 5.
</dl>
<p>
A null channel is always writable and never readable. This means that a
writable <b class='cmd'>fileevent</b>-handler will fire continuously and a readable
<b class='cmd'>fileevent</b>-handler never at all. The exception to the latter is
only the destruction of the channel which will cause the delivery of
an eof event to a readable handler.
<a name="seealso"><h2>SEE ALSO</h2>
memchan, fifo, fifo2, random, zero
<a name="keywords"><h2>KEYWORDS</h2>
null, in-memory channel, channel, i/o
<a name="copyright"><h2>COPYRIGHT</h2>
Copyright (c) 1996-2003 Andreas Kupries <andreas_kupries@users.sourceforge.net><br>
</body></html>
|