summaryrefslogtreecommitdiffstats
path: root/doc/man/man3/tqsocket.3qt
diff options
context:
space:
mode:
Diffstat (limited to 'doc/man/man3/tqsocket.3qt')
-rw-r--r--doc/man/man3/tqsocket.3qt56
1 files changed, 28 insertions, 28 deletions
diff --git a/doc/man/man3/tqsocket.3qt b/doc/man/man3/tqsocket.3qt
index 19895395..67e432bb 100644
--- a/doc/man/man3/tqsocket.3qt
+++ b/doc/man/man3/tqsocket.3qt
@@ -11,7 +11,7 @@ QSocket \- Buffered TCP connection
.SH SYNOPSIS
\fC#include <ntqsocket.h>\fR
.PP
-Inherits QObject and QIODevice.
+Inherits TQObject and TQIODevice.
.PP
.SS "Public Members"
.in +1c
@@ -19,7 +19,7 @@ Inherits QObject and QIODevice.
.BI "enum \fBError\fR { ErrConnectionRefused, ErrHostNotFound, ErrSocketRead }"
.br
.ti -1c
-.BI "\fBQSocket\fR ( QObject * parent = 0, const char * name = 0 )"
+.BI "\fBQSocket\fR ( TQObject * parent = 0, const char * name = 0 )"
.br
.ti -1c
.BI "virtual \fB~QSocket\fR ()"
@@ -43,10 +43,10 @@ Inherits QObject and QIODevice.
.BI "virtual void \fBsetSocketDevice\fR ( QSocketDevice * device )"
.br
.ti -1c
-.BI "virtual void \fBconnectToHost\fR ( const QString & host, TQ_UINT16 port )"
+.BI "virtual void \fBconnectToHost\fR ( const TQString & host, TQ_UINT16 port )"
.br
.ti -1c
-.BI "QString \fBpeerName\fR () const"
+.BI "TQString \fBpeerName\fR () const"
.br
.ti -1c
.BI "virtual bool \fBopen\fR ( int m )"
@@ -103,7 +103,7 @@ Inherits QObject and QIODevice.
.BI "bool \fBcanReadLine\fR () const"
.br
.ti -1c
-.BI "virtual QString \fBreadLine\fR ()"
+.BI "virtual TQString \fBreadLine\fR ()"
.br
.ti -1c
.BI "TQ_UINT16 \fBport\fR () const"
@@ -151,11 +151,11 @@ Inherits QObject and QIODevice.
.SH DESCRIPTION
The QSocket class provides a buffered TCP connection.
.PP
-It provides a totally non-blocking QIODevice, and modifies and extends the API of QIODevice with socket-specific code.
+It provides a totally non-blocking TQIODevice, and modifies and extends the API of TQIODevice with socket-specific code.
.PP
Note that a QApplication must have been constructed before this class can be used.
.PP
-The functions you're likely to call most are connectToHost(), bytesAvailable(), canReadLine() and the ones it inherits from QIODevice.
+The functions you're likely to call most are connectToHost(), bytesAvailable(), canReadLine() and the ones it inherits from TQIODevice.
.PP
connectToHost() is the most-used function. As its name implies, it opens a connection to a named host.
.PP
@@ -165,7 +165,7 @@ The signals error(), connected(), readyRead() and connectionClosed() inform you
.PP
There are several access functions for the socket: state() returns whether the object is idle, is doing a DNS lookup, is connecting, has an operational connection, etc. address() and port() return the IP address and port used for the connection. The peerAddress() and peerPort() functions return the IP address and port used by the peer, and peerName() returns the name of the peer (normally the name that was passed to connectToHost()). socketDevice() returns a pointer to the QSocketDevice used for this socket.
.PP
-QSocket inherits QIODevice, and reimplements some functions. In general, you can treat it as a QIODevice for writing, and mostly also for reading. The match isn't perfect, since the QIODevice API is designed for devices that are controlled by the same machine, and an asynchronous peer-to-peer network connection isn't quite like that. For example, there is nothing that matches QIODevice::size() exactly. The documentation for open(), close(), flush(), size(), at(), atEnd(), readBlock(), writeBlock(), getch(), putch(), ungetch() and readLine() describes the differences in detail.
+QSocket inherits TQIODevice, and reimplements some functions. In general, you can treat it as a TQIODevice for writing, and mostly also for reading. The match isn't perfect, since the TQIODevice API is designed for devices that are controlled by the same machine, and an asynchronous peer-to-peer network connection isn't quite like that. For example, there is nothing that matches TQIODevice::size() exactly. The documentation for open(), close(), flush(), size(), at(), atEnd(), readBlock(), writeBlock(), getch(), putch(), ungetch() and readLine() describes the differences in detail.
.PP
\fBWarning:\fR QSocket is not suitable for use in threads. If you need to uses sockets in threads use the lower-level QSocketDevice class.
.PP
@@ -194,10 +194,10 @@ This enum defines the connection states:
.TP
\fCQSocket::Closing\fR - if the socket is closing down, but is not yet closed.
.SH MEMBER FUNCTION DOCUMENTATION
-.SH "QSocket::QSocket ( QObject * parent = 0, const char * name = 0 )"
+.SH "QSocket::QSocket ( TQObject * parent = 0, const char * name = 0 )"
Creates a QSocket object in QSocket::Idle state.
.PP
-The \fIparent\fR and \fIname\fR arguments are passed on to the QObject constructor.
+The \fIparent\fR and \fIname\fR arguments are passed on to the TQObject constructor.
.PP
Note that a QApplication must have been constructed before sockets can be used.
.SH "QSocket::~QSocket ()\fC [virtual]\fR"
@@ -209,17 +209,17 @@ Returns the host address of this socket. (This is normally the main IP address o
.SH "Offset QSocket::at () const\fC [virtual]\fR"
Returns the current read index. Since QSocket is a sequential device, the current read index is always zero.
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "bool QSocket::at ( Offset index )\fC [virtual]\fR"
This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
.PP
Moves the read index forward to \fIindex\fR and returns TRUE if the operation was successful; otherwise returns FALSE. Moving the index forward means skipping incoming data.
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "bool QSocket::atEnd () const\fC [virtual]\fR"
Returns TRUE if there is no more data to read; otherwise returns FALSE.
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "TQ_ULONG QSocket::bytesAvailable () const"
Returns the number of incoming bytes that can be read, i.e. the size of the input buffer. Equivalent to size().
.PP
@@ -273,8 +273,8 @@ See also state(), bytesToWrite(), and clearPendingData().
Examples:
.)l network/clientserver/client/client.cpp, network/httpd/httpd.cpp, and network/networkprotocol/nntp.cpp.
.PP
-Reimplemented from QIODevice.
-.SH "void QSocket::connectToHost ( const QString & host, TQ_UINT16 port )\fC [virtual]\fR"
+Reimplemented from TQIODevice.
+.SH "void QSocket::connectToHost ( const TQString & host, TQ_UINT16 port )\fC [virtual]\fR"
Attempts to make a connection to \fIhost\fR on the specified \fIport\fR and return immediately.
.PP
Any connection or pending connection is closed immediately, and QSocket goes into the HostLookup state. When the lookup succeeds, it emits hostFound(), starts a TCP connection and goes into the Connecting state. Finally, when the connection succeeds, it emits connected() and goes into the Connected state. If there is an error at any point, it emits error().
@@ -314,15 +314,15 @@ This signal is emitted after an error occurred. The parameter is the Error value
Examples:
.)l network/clientserver/client/client.cpp and network/networkprotocol/nntp.cpp.
.SH "void QSocket::flush ()\fC [virtual]\fR"
-Implementation of the abstract virtual QIODevice::flush() function.
+Implementation of the abstract virtual TQIODevice::flush() function.
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "int QSocket::getch ()\fC [virtual]\fR"
Reads a single byte/character from the internal read buffer. Returns the byte/character read, or -1 if there is nothing to be read.
.PP
See also bytesAvailable() and putch().
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "void QSocket::hostFound ()\fC [signal]\fR"
This signal is emitted after connectToHost() has been called and the host lookup has succeeded.
.PP
@@ -330,14 +330,14 @@ See also connected().
.PP
Example: network/networkprotocol/nntp.cpp.
.SH "bool QSocket::open ( int m )\fC [virtual]\fR"
-Opens the socket using the specified QIODevice file mode \fIm\fR. This function is called automatically when needed and you should not call it yourself.
+Opens the socket using the specified TQIODevice file mode \fIm\fR. This function is called automatically when needed and you should not call it yourself.
.PP
See also close().
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "QHostAddress QSocket::peerAddress () const"
Returns the address of the connected peer if the socket is in Connected state; otherwise an empty QHostAddress is returned.
-.SH "QString QSocket::peerName () const"
+.SH "TQString QSocket::peerName () const"
Returns the host name as specified to the connectToHost() function. An empty string is returned if none has been set.
.PP
Example: network/mail/smtp.cpp.
@@ -354,18 +354,18 @@ Returns \fIch\fR, or -1 if an error occurred.
.PP
See also getch().
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "TQ_LONG QSocket::readBlock ( char * data, TQ_ULONG maxlen )\fC [virtual]\fR"
Reads \fImaxlen\fR bytes from the socket into \fIdata\fR and returns the number of bytes read. Returns -1 if an error occurred.
.PP
Example: network/networkprotocol/nntp.cpp.
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "TQ_ULONG QSocket::readBufferSize () const"
Returns the size of the read buffer.
.PP
See also setReadBufferSize().
-.SH "QString QSocket::readLine ()\fC [virtual]\fR"
+.SH "TQString QSocket::readLine ()\fC [virtual]\fR"
Returns a line of text including a terminating newline character (\\n). Returns "" if canReadLine() returns FALSE.
.PP
See also canReadLine().
@@ -406,7 +406,7 @@ This function is useful if you need to subclass QSocketDevice and want to use th
.SH "Offset QSocket::size () const\fC [virtual]\fR"
Returns the number of incoming bytes that can be read right now (like bytesAvailable()).
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "int QSocket::socket () const"
Returns the socket number, or -1 if there is no socket at the moment.
.SH "QSocketDevice * QSocket::socketDevice ()"
@@ -421,9 +421,9 @@ See also QSocket::State.
Examples:
.)l network/clientserver/client/client.cpp and network/networkprotocol/nntp.cpp.
.SH "int QSocket::ungetch ( int ch )\fC [virtual]\fR"
-This implementation of the virtual function QIODevice::ungetch() prepends the character \fIch\fR to the read buffer so that the next read returns this character as the first character of the output.
+This implementation of the virtual function TQIODevice::ungetch() prepends the character \fIch\fR to the read buffer so that the next read returns this character as the first character of the output.
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "TQ_ULONG QSocket::waitForMore ( int msecs, bool * timeout ) const"
Wait up to \fImsecs\fR milliseconds for more data to be available.
.PP
@@ -443,7 +443,7 @@ Writes \fIlen\fR bytes to the socket from \fIdata\fR and returns the number of b
.PP
Example: network/networkprotocol/nntp.cpp.
.PP
-Reimplemented from QIODevice.
+Reimplemented from TQIODevice.
.SH "SEE ALSO"
.BR http://doc.trolltech.com/ntqsocket.html