diff options
Diffstat (limited to 'doc/man/man3/tqsocketdevice.3qt')
-rw-r--r-- | doc/man/man3/tqsocketdevice.3qt | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/doc/man/man3/tqsocketdevice.3qt b/doc/man/man3/tqsocketdevice.3qt index 99779fb98..820fe08f0 100644 --- a/doc/man/man3/tqsocketdevice.3qt +++ b/doc/man/man3/tqsocketdevice.3qt @@ -214,19 +214,19 @@ See also bind() and listen(). .SH "TQHostAddress TQSocketDevice::address () const" Returns the address of this socket device. This may be 0.0.0.0 for a while, but is set to something sensible as soon as a sensible value is available. .SH "bool TQSocketDevice::addressReusable () const" -Returns TRUE if the address of this socket can be used by other sockets at the same time, and FALSE if this socket claims exclusive ownership. +Returns true if the address of this socket can be used by other sockets at the same time, and false if this socket claims exclusive ownership. .PP See also setAddressReusable(). .SH "bool TQSocketDevice::bind ( const TQHostAddress & address, TQ_UINT16 port )\fC [virtual]\fR" -Assigns a name to an unnamed socket. The name is the host address \fIaddress\fR and the port number \fIport\fR. If the operation succeeds, bind() returns TRUE; otherwise it returns FALSE without changing what port() and address() return. +Assigns a name to an unnamed socket. The name is the host address \fIaddress\fR and the port number \fIport\fR. If the operation succeeds, bind() returns true; otherwise it returns false without changing what port() and address() return. .PP bind() is used by servers for setting up incoming connections. Call bind() before listen(). .SH "bool TQSocketDevice::blocking () const" -Returns TRUE if the socket is valid and in blocking mode; otherwise returns FALSE. +Returns true if the socket is valid and in blocking mode; otherwise returns false. .PP Note that this function does not set error(). .PP -\fBWarning:\fR On Windows, this function always returns TRUE since the ioctlsocket() function is broken. +\fBWarning:\fR On Windows, this function always returns true since the ioctlsocket() function is broken. .PP See also setBlocking() and isValid(). .SH "TQ_LONG TQSocketDevice::bytesAvailable () const" @@ -234,17 +234,17 @@ Returns the number of bytes available for reading, or -1 if an error occurred. .PP \fBWarning:\fR On Microsoft Windows, we use the ioctlsocket() function to determine the number of bytes queued on the socket. According to Microsoft (KB Q125486), ioctlsocket() sometimes returns an incorrect number. The only safe way to determine the amount of data on the socket is to read it using readBlock(). TQSocket has workarounds to deal with this problem. .SH "bool TQSocketDevice::connect ( const TQHostAddress & addr, TQ_UINT16 port )\fC [virtual]\fR" -Connects to the IP address and port specified by \fIaddr\fR and \fIport\fR. Returns TRUE if it establishes a connection; otherwise returns FALSE. If it returns FALSE, error() explains why. +Connects to the IP address and port specified by \fIaddr\fR and \fIport\fR. Returns true if it establishes a connection; otherwise returns false. If it returns false, error() explains why. .PP Note that error() commonly returns NoError for non-blocking sockets; this just means that you can call connect() again in a little while and it'll probably succeed. .SH "Error TQSocketDevice::error () const" Returns the first error seen. .SH "bool TQSocketDevice::isValid () const" -Returns TRUE if this is a valid socket; otherwise returns FALSE. +Returns true if this is a valid socket; otherwise returns false. .PP See also socket(). .SH "bool TQSocketDevice::listen ( int backlog )\fC [virtual]\fR" -Specifies how many pending connections a server socket can have. Returns TRUE if the operation was successful; otherwise returns FALSE. A \fIbacklog\fR value of 50 is quite common. +Specifies how many pending connections a server socket can have. Returns true if the operation was successful; otherwise returns false. A \fIbacklog\fR value of 50 is quite common. .PP The listen() call only applies to sockets where type() is Stream, i.e. not to Datagram sockets. listen() must not be called before bind() or after accept(). .PP @@ -280,13 +280,13 @@ Returns the size of the operating system send buffer. .PP See also setSendBufferSize(). .SH "void TQSocketDevice::setAddressReusable ( bool enable )\fC [virtual]\fR" -Sets the address of this socket to be usable by other sockets too if \fIenable\fR is TRUE, and to be used exclusively by this socket if \fIenable\fR is FALSE. +Sets the address of this socket to be usable by other sockets too if \fIenable\fR is true, and to be used exclusively by this socket if \fIenable\fR is false. .PP When a socket is reusable, other sockets can use the same port number (and IP address), which is generally useful. Of course other sockets cannot use the same (address,port,peer-address,peer-port) 4-tuple as this socket, so there is no risk of confusing the two TCP connections. .PP See also addressReusable(). .SH "void TQSocketDevice::setBlocking ( bool enable )\fC [virtual]\fR" -Makes the socket blocking if \fIenable\fR is TRUE or nonblocking if \fIenable\fR is FALSE. +Makes the socket blocking if \fIenable\fR is true or nonblocking if \fIenable\fR is false. .PP Sockets are blocking by default, but we recommend using nonblocking socket operations, especially for GUI programs that need to be responsive. .PP @@ -328,7 +328,7 @@ Wait up to \fImsecs\fR milliseconds for more data to be available. If \fImsecs\f .PP Returns the number of bytes available for reading, or -1 if an error occurred. .PP -If \fItimeout\fR is non-null and no error occurred (i.e. it does not return -1): this function sets \fI*timeout\fR to TRUE, if the reason for returning was that the timeout was reached; otherwise it sets \fI*timeout\fR to FALSE. This is useful to find out if the peer closed the connection. +If \fItimeout\fR is non-null and no error occurred (i.e. it does not return -1): this function sets \fI*timeout\fR to true, if the reason for returning was that the timeout was reached; otherwise it sets \fI*timeout\fR to false. This is useful to find out if the peer closed the connection. .PP \fBWarning:\fR This is a blocking call and should be avoided in event driven applications. .PP |