X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4cc90442d0e65ab148e9f3398fcd7315360daa7a..aea22172eff902cd6c1badf117c6c6564623938c:/docs/latex/wx/socket.tex?ds=sidebyside diff --git a/docs/latex/wx/socket.tex b/docs/latex/wx/socket.tex index 1c8d64aa73..096c6a9f18 100644 --- a/docs/latex/wx/socket.tex +++ b/docs/latex/wx/socket.tex @@ -109,13 +109,13 @@ a \helpref{wxSocketEvent}{wxsocketevent} argument. \latexignore{\rtfignore{\wxheading{Function groups}}} -\membersection{Construction and destruction} +\membersection{Construction and destruction}\label{socketconstruction} \helpref{wxSocketBase}{wxsocketbaseconstruct}\\ \helpref{\destruct{wxSocketBase}}{wxsocketbasedestruct}\\ \helpref{Destroy}{wxsocketbasedestroy} -\membersection{Socket state} +\membersection{Socket state}\label{socketstate} Functions to retrieve current state and miscellaneous info. @@ -131,7 +131,7 @@ Functions to retrieve current state and miscellaneous info. \helpref{SaveState}{wxsocketbasesavestate}\\ \helpref{RestoreState}{wxsocketbaserestorestate} -\membersection{Basic IO} +\membersection{Basic IO}\label{socketbasicio} Functions that perform basic IO functionality. @@ -163,7 +163,7 @@ Functions that allow applications to customize socket IO as needed. \helpref{SetFlags}{wxsocketbasesetflags}\\ \helpref{SetTimeout}{wxsocketbasesettimeout} -\membersection{Handling socket events} +\membersection{Handling socket events}\label{socketevents} Functions that allow applications to receive socket events. @@ -593,6 +593,7 @@ The following flags can be used: \twocolitem{{\bf wxSOCKET\_NOWAIT}}{Read/write as much data as possible and return immediately.} \twocolitem{{\bf wxSOCKET\_WAITALL}}{Wait for all required data to be read/written unless an error occurs.} \twocolitem{{\bf wxSOCKET\_BLOCK}}{Block the GUI (do not yield) while reading/writing data.} +\twocolitem{{\bf wxSOCKET\_REUSEADDR}}{Allows the use of an in-use port (wxServerSocket only)} \end{twocollist} A brief overview on how to use these flags follows. @@ -626,6 +627,13 @@ during IO calls, so the GUI will remain blocked until the operation completes. If it is not used, then the application must take extra care to avoid unwanted reentrance. +The {\bf wxSOCKET\_REUSEADDR} flag controls the use of the SO\_REUSEADDR standard +setsockopt() flag. This flag allows the socket to bind to a port that is already in use. +This is mostly used on UNIX-based systems to allow rapid starting and stopping of a server - +otherwise you may have to wait several minutes for the port to become available. +This option can have suprising platform dependent behavior, check the documentation for +your platforms implementation of setsockopt(). + So: {\bf wxSOCKET\_NONE} will try to read at least SOME data, no matter how much. @@ -639,6 +647,8 @@ the data. {\bf wxSOCKET\_BLOCK} has nothing to do with the previous flags and it controls whether the GUI blocks. +{\bf wxSOCKET\_REUSEADDR} controls special platform-specific behavior for wxServerSocket. + % % SetNotify % @@ -1053,7 +1063,7 @@ For a detailed explanation, see \helpref{wxSocketBase::SetFlags}{wxsocketbaseset % % wxSocketClient % -\membersection{wxSocketClient::wxSocketClient} +\membersection{wxSocketClient::wxSocketClient}\label{wxsocketclientctor} \func{}{wxSocketClient}{\param{wxSocketFlags}{ flags = wxSOCKET\_NONE}} @@ -1066,7 +1076,7 @@ Constructor. % % ~wxSocketClient % -\membersection{wxSocketClient::\destruct{wxSocketClient}} +\membersection{wxSocketClient::\destruct{wxSocketClient}}\label{wxsocketclientdtor} \func{}{\destruct{wxSocketClient}}{\void} @@ -1199,7 +1209,7 @@ to member functions that take a wxSocketEvent argument. \latexignore{\rtfignore{\wxheading{Members}}} -\membersection{wxSocketEvent::wxSocketEvent} +\membersection{wxSocketEvent::wxSocketEvent}\label{wxsocketeventctor} \func{}{wxSocketEvent}{\param{int}{ id = 0}}