diff options
| author | Sam Roberts <vieuxtech@gmail.com> | 2012-04-11 14:18:20 -0700 |
|---|---|---|
| committer | Sam Roberts <vieuxtech@gmail.com> | 2012-04-11 14:18:20 -0700 |
| commit | 4b671f4551e98ac9e1d9a7407d3dffdd7eb1d3dc (patch) | |
| tree | ba92aa753ae1b145760cb1c5e69c886d3bf11328 /doc | |
| parent | f399ab25fcecad2ff96a5977e8eaf069bb45473c (diff) | |
| parent | 195b2a74bb3f368b1f31f9c8bbc1ce0f54de2035 (diff) | |
| download | luasocket-4b671f4551e98ac9e1d9a7407d3dffdd7eb1d3dc.tar.gz luasocket-4b671f4551e98ac9e1d9a7407d3dffdd7eb1d3dc.tar.bz2 luasocket-4b671f4551e98ac9e1d9a7407d3dffdd7eb1d3dc.zip | |
Merge branch 'git-sam' into diego-sam-mwild-integration
Conflicts in options.c were just due to independent small functions
being close to each other.
unix.c in mwild was broken, it wasn't using LUASOCKET_API.
serial.c needed luaL_reg renamed, and to use LUASOCKET_API.
makefile didn't respect standard DESTDIR and prefix makefile
variables, and didn't allow LUAV variable to select lua version to build
against.
I've tested the top-level install-both target builds and installs
against both lua5.1 and lua5.2, but not done further testing.
Conflicts:
README
config
gem/ltn012.tex
makefile
src/makefile
src/options.c
src/options.h
src/tcp.c
src/usocket.c
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/reference.html | 17 | ||||
| -rw-r--r-- | doc/socket.html | 4 | ||||
| -rw-r--r-- | doc/tcp.html | 95 |
3 files changed, 110 insertions, 6 deletions
diff --git a/doc/reference.html b/doc/reference.html index 31f6ecf..8da3956 100644 --- a/doc/reference.html +++ b/doc/reference.html | |||
| @@ -42,9 +42,9 @@ Support, Manual"> | |||
| 42 | <blockquote> | 42 | <blockquote> |
| 43 | <a href="dns.html">DNS (in socket)</a> | 43 | <a href="dns.html">DNS (in socket)</a> |
| 44 | <blockquote> | 44 | <blockquote> |
| 45 | <a href="dns.html#toip">toip</a>, | 45 | <a href="dns.html#gethostname">gethostname</a>, |
| 46 | <a href="dns.html#tohostname">tohostname</a>, | 46 | <a href="dns.html#tohostname">tohostname</a>, |
| 47 | <a href="dns.html#gethostname">gethostname</a>. | 47 | <a href="dns.html#toip">toip</a>. |
| 48 | </blockquote> | 48 | </blockquote> |
| 49 | </blockquote> | 49 | </blockquote> |
| 50 | 50 | ||
| @@ -108,9 +108,9 @@ Support, Manual"> | |||
| 108 | <a href="mime.html">MIME</a> | 108 | <a href="mime.html">MIME</a> |
| 109 | <blockquote> | 109 | <blockquote> |
| 110 | <a href="mime.html#high">high-level</a>: | 110 | <a href="mime.html#high">high-level</a>: |
| 111 | <a href="mime.html#normalize">normalize</a>, | ||
| 112 | <a href="mime.html#decode">decode</a>, | 111 | <a href="mime.html#decode">decode</a>, |
| 113 | <a href="mime.html#encode">encode</a>, | 112 | <a href="mime.html#encode">encode</a>, |
| 113 | <a href="mime.html#normalize">normalize</a>, | ||
| 114 | <a href="mime.html#stuff">stuff</a>, | 114 | <a href="mime.html#stuff">stuff</a>, |
| 115 | <a href="mime.html#wrap">wrap</a>. | 115 | <a href="mime.html#wrap">wrap</a>. |
| 116 | </blockquote> | 116 | </blockquote> |
| @@ -120,10 +120,10 @@ Support, Manual"> | |||
| 120 | <a href="mime.html#dot">dot</a>, | 120 | <a href="mime.html#dot">dot</a>, |
| 121 | <a href="mime.html#eol">eol</a>, | 121 | <a href="mime.html#eol">eol</a>, |
| 122 | <a href="mime.html#qp">qp</a>, | 122 | <a href="mime.html#qp">qp</a>, |
| 123 | <a href="mime.html#wrp">wrp</a>, | 123 | <a href="mime.html#qpwrp">qpwrp</a>, |
| 124 | <a href="mime.html#qpwrp">qpwrp</a>. | ||
| 125 | <a href="mime.html#unb64">unb64</a>, | 124 | <a href="mime.html#unb64">unb64</a>, |
| 126 | <a href="mime.html#unqp">unqp</a>, | 125 | <a href="mime.html#unqp">unqp</a>, |
| 126 | <a href="mime.html#wrp">wrp</a>. | ||
| 127 | </blockquote> | 127 | </blockquote> |
| 128 | </blockquote> | 128 | </blockquote> |
| 129 | 129 | ||
| @@ -142,6 +142,8 @@ Support, Manual"> | |||
| 142 | <blockquote> | 142 | <blockquote> |
| 143 | <a href="socket.html">Socket</a> | 143 | <a href="socket.html">Socket</a> |
| 144 | <blockquote> | 144 | <blockquote> |
| 145 | <a href="socket.html#bind">bind</a>, | ||
| 146 | <a href="socket.html#connect">connect</a>, | ||
| 145 | <a href="socket.html#debug">_DEBUG</a>, | 147 | <a href="socket.html#debug">_DEBUG</a>, |
| 146 | <a href="dns.html#dns">dns</a>, | 148 | <a href="dns.html#dns">dns</a>, |
| 147 | <a href="socket.html#gettime">gettime</a>, | 149 | <a href="socket.html#gettime">gettime</a>, |
| @@ -169,11 +171,16 @@ Support, Manual"> | |||
| 169 | <a href="tcp.html#bind">bind</a>, | 171 | <a href="tcp.html#bind">bind</a>, |
| 170 | <a href="tcp.html#close">close</a>, | 172 | <a href="tcp.html#close">close</a>, |
| 171 | <a href="tcp.html#connect">connect</a>, | 173 | <a href="tcp.html#connect">connect</a>, |
| 174 | <a href="tcp.html#dirty">dirty</a>, | ||
| 175 | <a href="tcp.html#getfd">getfd</a>, | ||
| 176 | <a href="tcp.html#getoption">getoption</a>, | ||
| 172 | <a href="tcp.html#getpeername">getpeername</a>, | 177 | <a href="tcp.html#getpeername">getpeername</a>, |
| 173 | <a href="tcp.html#getsockname">getsockname</a>, | 178 | <a href="tcp.html#getsockname">getsockname</a>, |
| 174 | <a href="tcp.html#getstats">getstats</a>, | 179 | <a href="tcp.html#getstats">getstats</a>, |
| 180 | <a href="tcp.html#listen">listen</a>, | ||
| 175 | <a href="tcp.html#receive">receive</a>, | 181 | <a href="tcp.html#receive">receive</a>, |
| 176 | <a href="tcp.html#send">send</a>, | 182 | <a href="tcp.html#send">send</a>, |
| 183 | <a href="tcp.html#setfd">setfd</a>, | ||
| 177 | <a href="tcp.html#setoption">setoption</a>, | 184 | <a href="tcp.html#setoption">setoption</a>, |
| 178 | <a href="tcp.html#setstats">setstats</a>, | 185 | <a href="tcp.html#setstats">setstats</a>, |
| 179 | <a href="tcp.html#settimeout">settimeout</a>, | 186 | <a href="tcp.html#settimeout">settimeout</a>, |
diff --git a/doc/socket.html b/doc/socket.html index 490ab50..2267b4a 100644 --- a/doc/socket.html +++ b/doc/socket.html | |||
| @@ -244,6 +244,10 @@ method or <tt>accept</tt> might block forever. | |||
| 244 | it to <tt>select</tt>, it will be ignored. | 244 | it to <tt>select</tt>, it will be ignored. |
| 245 | </p> | 245 | </p> |
| 246 | 246 | ||
| 247 | <p class=note> | ||
| 248 | <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. | ||
| 249 | </p> | ||
| 250 | |||
| 247 | <!-- sink ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | 251 | <!-- sink ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> |
| 248 | 252 | ||
| 249 | <p class=name id=sink> | 253 | <p class=name id=sink> |
diff --git a/doc/tcp.html b/doc/tcp.html index d1d2154..f59d7ac 100644 --- a/doc/tcp.html +++ b/doc/tcp.html | |||
| @@ -397,7 +397,40 @@ disables the Nagle's algorithm for the connection. | |||
| 397 | </ul> | 397 | </ul> |
| 398 | 398 | ||
| 399 | <p class=return> | 399 | <p class=return> |
| 400 | The method returns 1 in case of success, or <b><tt>nil</tt></b> otherwise. | 400 | The method returns 1 in case of success, or <b><tt>nil</tt></b> |
| 401 | followed by an error message otherwise. | ||
| 402 | </p> | ||
| 403 | |||
| 404 | <p class=note> | ||
| 405 | Note: The descriptions above come from the man pages. | ||
| 406 | </p> | ||
| 407 | |||
| 408 | <!-- getoption ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | ||
| 409 | |||
| 410 | <p class=name id=getoption> | ||
| 411 | client:<b>getoption(</b>option)</b><br> | ||
| 412 | server:<b>getoption(</b>option)</b> | ||
| 413 | </p> | ||
| 414 | |||
| 415 | <p class=description> | ||
| 416 | Gets options for the TCP object. | ||
| 417 | See <a href=#setoption><tt>setoption</tt></a> for description of the | ||
| 418 | option names and values. | ||
| 419 | </p> | ||
| 420 | |||
| 421 | <p class=parameters> | ||
| 422 | <tt>Option</tt> is a string with the option name. | ||
| 423 | <ul> | ||
| 424 | |||
| 425 | <li> '<tt>keepalive</tt>' | ||
| 426 | <li> '<tt>linger</tt>' | ||
| 427 | <li> '<tt>reuseaddr</tt>' | ||
| 428 | <li> '<tt>tcp-nodelay</tt>' | ||
| 429 | </ul> | ||
| 430 | |||
| 431 | <p class=return> | ||
| 432 | The method returns the option <tt>value</tt> in case of success, or | ||
| 433 | <b><tt>nil</tt></b> followed by an error message otherwise. | ||
| 401 | </p> | 434 | </p> |
| 402 | 435 | ||
| 403 | <p class=note> | 436 | <p class=note> |
| @@ -508,6 +541,66 @@ This is the default mode; | |||
| 508 | This function returns 1. | 541 | This function returns 1. |
| 509 | </p> | 542 | </p> |
| 510 | 543 | ||
| 544 | <!-- dirty +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | ||
| 545 | |||
| 546 | <p class=name id=dirty> | ||
| 547 | master:<b>dirty()</b><br> | ||
| 548 | client:<b>dirty()</b><br> | ||
| 549 | server:<b>dirty()</b> | ||
| 550 | </p> | ||
| 551 | |||
| 552 | <p class=description> | ||
| 553 | Check the read buffer status. | ||
| 554 | </p> | ||
| 555 | |||
| 556 | <p class=return> | ||
| 557 | Returns <tt>true</tt> if there is any data in the read buffer, <tt>false</tt> otherwise. | ||
| 558 | </p> | ||
| 559 | |||
| 560 | <p class=note> | ||
| 561 | Note: <b>This is an internal method, any use is unlikely to be portable.</b> | ||
| 562 | </p> | ||
| 563 | |||
| 564 | <!-- getfd +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | ||
| 565 | |||
| 566 | <p class=name id=getfd> | ||
| 567 | master:<b>getfd()</b><br> | ||
| 568 | client:<b>getfd()</b><br> | ||
| 569 | server:<b>getfd()</b> | ||
| 570 | </p> | ||
| 571 | |||
| 572 | <p class=description> | ||
| 573 | Returns the underling socket descriptor or handle associated to the object. | ||
| 574 | </p> | ||
| 575 | |||
| 576 | <p class=return> | ||
| 577 | The descriptor or handle. In case the object has been closed, the return will be -1. | ||
| 578 | </p> | ||
| 579 | |||
| 580 | <p class=note> | ||
| 581 | Note: <b>This is an internal method, any use is unlikely to be portable.</b> | ||
| 582 | </p> | ||
| 583 | |||
| 584 | <!-- setfd +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | ||
| 585 | |||
| 586 | <p class=name id=setfd> | ||
| 587 | master:<b>setfd(</b>fd<b>)</b><br> | ||
| 588 | client:<b>setfd(</b>fd<b>)</b><br> | ||
| 589 | server:<b>setfd(</b>fd<b>)</b> | ||
| 590 | </p> | ||
| 591 | |||
| 592 | <p class=description> | ||
| 593 | Sets 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. | ||
| 594 | </p> | ||
| 595 | |||
| 596 | <p class=return> | ||
| 597 | No return value. | ||
| 598 | </p> | ||
| 599 | |||
| 600 | <p class=note> | ||
| 601 | Note: <b>This is an internal method, any use is unlikely to be portable.</b> | ||
| 602 | </p> | ||
| 603 | |||
| 511 | <!-- footer +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | 604 | <!-- footer +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> |
| 512 | 605 | ||
| 513 | <div class=footer> | 606 | <div class=footer> |
