aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Roberts <vieuxtech@gmail.com>2011-10-24 11:24:58 -0700
committerSam Roberts <vieuxtech@gmail.com>2012-04-11 13:45:59 -0700
commit12bde801f6a5d3a192dee29dda1266108aa98d45 (patch)
tree64c6166ae6d968f10d260ec5172de0ac1d4e576a
parent3a0fd4744daa972e59579a753af2da9dbde36edd (diff)
downloadluasocket-12bde801f6a5d3a192dee29dda1266108aa98d45.tar.gz
luasocket-12bde801f6a5d3a192dee29dda1266108aa98d45.tar.bz2
luasocket-12bde801f6a5d3a192dee29dda1266108aa98d45.zip
Document dirty, getfd, and setfd for select and tcp.
-rw-r--r--doc/reference.html3
-rw-r--r--doc/socket.html4
-rw-r--r--doc/tcp.html60
3 files changed, 67 insertions, 0 deletions
diff --git a/doc/reference.html b/doc/reference.html
index f13a6bd..edffc40 100644
--- a/doc/reference.html
+++ b/doc/reference.html
@@ -170,12 +170,15 @@ Support, Manual">
170<a href="tcp.html#bind">bind</a>, 170<a href="tcp.html#bind">bind</a>,
171<a href="tcp.html#close">close</a>, 171<a href="tcp.html#close">close</a>,
172<a href="tcp.html#connect">connect</a>, 172<a href="tcp.html#connect">connect</a>,
173<a href="tcp.html#dirty">dirty</a>,
174<a href="tcp.html#getfd">getfd</a>,
173<a href="tcp.html#getpeername">getpeername</a>, 175<a href="tcp.html#getpeername">getpeername</a>,
174<a href="tcp.html#getsockname">getsockname</a>, 176<a href="tcp.html#getsockname">getsockname</a>,
175<a href="tcp.html#getstats">getstats</a>, 177<a href="tcp.html#getstats">getstats</a>,
176<a href="tcp.html#listen">listen</a>, 178<a href="tcp.html#listen">listen</a>,
177<a href="tcp.html#receive">receive</a>, 179<a href="tcp.html#receive">receive</a>,
178<a href="tcp.html#send">send</a>, 180<a href="tcp.html#send">send</a>,
181<a href="tcp.html#setfd">setfd</a>,
179<a href="tcp.html#setoption">setoption</a>, 182<a href="tcp.html#setoption">setoption</a>,
180<a href="tcp.html#setstats">setstats</a>, 183<a href="tcp.html#setstats">setstats</a>,
181<a href="tcp.html#settimeout">settimeout</a>, 184<a href="tcp.html#settimeout">settimeout</a>,
diff --git a/doc/socket.html b/doc/socket.html
index f096e4b..4d44f01 100644
--- a/doc/socket.html
+++ b/doc/socket.html
@@ -217,6 +217,10 @@ method or <tt>accept</tt> might block forever.
217it to <tt>select</tt>, it will be ignored. 217it to <tt>select</tt>, it will be ignored.
218</p> 218</p>
219 219
220<p class=note>
221<b>Using select with non-socket objects</b>: Any object that implements <tt>getfd</tt> and <tt>dirty</tt> can be used with <tt>select</tt>, allowing objects from other libraries to be used within a <tt>socket.select</tt> driven loop.
222</p>
223
220<!-- sink ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> 224<!-- sink ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
221 225
222<p class=name id=sink> 226<p class=name id=sink>
diff --git a/doc/tcp.html b/doc/tcp.html
index 602c73c..ab70f04 100644
--- a/doc/tcp.html
+++ b/doc/tcp.html
@@ -507,6 +507,66 @@ This is the default mode;
507This function returns 1. 507This function returns 1.
508</p> 508</p>
509 509
510<!-- dirty +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
511
512<p class=name id=dirty>
513master:<b>dirty()</b><br>
514client:<b>dirty()</b><br>
515server:<b>dirty()</b>
516</p>
517
518<p class=description>
519Check the read buffer status.
520</p>
521
522<p class=return>
523Returns <tt>true</tt> if there is any data in the read buffer, <tt>false</tt> otherwise.
524</p>
525
526<p class=note>
527Note: <b>This is an internal method, any use is unlikely to be portable.</b>
528</p>
529
530<!-- getfd +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
531
532<p class=name id=getfd>
533master:<b>getfd()</b><br>
534client:<b>getfd()</b><br>
535server:<b>getfd()</b>
536</p>
537
538<p class=description>
539Returns the underling socket descriptor or handle associated to the object.
540</p>
541
542<p class=return>
543The descriptor or handle. In case the object has been closed, the return will be -1.
544</p>
545
546<p class=note>
547Note: <b>This is an internal method, any use is unlikely to be portable.</b>
548</p>
549
550<!-- setfd +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
551
552<p class=name id=setfd>
553master:<b>setfd(</b>fd<b>)</b><br>
554client:<b>setfd(</b>fd<b>)</b><br>
555server:<b>setfd(</b>fd<b>)</b>
556</p>
557
558<p class=description>
559Sets the underling socket descriptor or handle associated to the object. The current one is simply replaced, not closed, and no other change to the object state is made.
560</p>
561
562<p class=return>
563No return value.
564</p>
565
566<p class=note>
567Note: <b>This is an internal method, any use is unlikely to be portable.</b>
568</p>
569
510<!-- footer +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> 570<!-- footer +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
511 571
512<div class=footer> 572<div class=footer>