<?xml version="1.0" encoding="iso-8859-1"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd"> <html><head><title>QTcpSocket Class Reference</title><style>h3.fn,span.fn { margin-left: 1cm; text-indent: -1cm } a:link { color: #004faf; text-decoration: none } a:visited { color: #672967; text-decoration: none } td.postheader { font-family: sans-serif } tr.address { font-family: sans-serif } body { background: #ffffff; color: black; } </style></head><body><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr /><td align="left" valign="top" width="32"><img align="left" border="0" height="32" src="images/rb-logo.png" width="32" /></td><td width="1">  </td><td class="postheader" valign="center"><a href="index.html"><font color="#004faf">Home</font></a> · <a href="classes.html"><font color="#004faf">All Classes</font></a> · <a href="modules.html"><font color="#004faf">Modules</font></a></td></table><h1 align="center">QTcpSocket Class Reference<br /><sup><sup>[<a href="qtnetwork.html">QtNetwork</a> module]</sup></sup></h1><p>The QTcpSocket class provides a TCP socket. <a href="#details">More...</a></p> <p>Inherits <a href="qabstractsocket.html">QAbstractSocket</a>.</p><p>Inherited by <a href="qsslsocket.html">QSslSocket</a>.</p><h3>Methods</h3><ul><li><div class="fn" /><b><a href="qtcpsocket.html#QTcpSocket">__init__</a></b> (<i>self</i>, QObject <i>parent</i> = None)</li></ul><a name="details" /><hr /><h2>Detailed Description</h2><p>The QTcpSocket class provides a TCP socket.</p> <p>TCP (Transmission Control Protocol) is a reliable, stream-oriented, connection-oriented transport protocol. It is especially well suited for continuous transmission of data.</p> <p>QTcpSocket is a convenience subclass of <a href="qabstractsocket.html">QAbstractSocket</a> that allows you to establish a TCP connection and transfer streams of data. See the <a href="qabstractsocket.html">QAbstractSocket</a> documentation for details.</p> <p><b>Note:</b> TCP sockets cannot be opened in <a href="qiodevice.html#OpenModeFlag-enum">QIODevice.Unbuffered</a> mode.</p> <a id="symbian-platform-security-requirements" name="symbian-platform-security-requirements" /> <h3>Symbian Platform Security Requirements</h3> <p>On Symbian, processes which use this class must have the <tt>NetworkServices</tt> platform security capability. If the client process lacks this capability, it will result in a panic.</p> <p>Platform security capabilities are added via the <a href="qmake-variable-reference.html#target-capability">TARGET.CAPABILITY</a> qmake variable.</p> <hr /><h2>Method Documentation</h2><h3 class="fn"><a name="QTcpSocket" />QTcpSocket.__init__ (<i>self</i>, <a href="qobject.html">QObject</a> <i>parent</i> = None)</h3><p>The <i>parent</i> argument, if not None, causes <i>self</i> to be owned by Qt instead of PyQt.</p><p>Creates a <a href="qtcpsocket.html">QTcpSocket</a> object in state <tt>UnconnectedState</tt>.</p> <p><i>parent</i> is passed on to the <a href="qobject.html">QObject</a> constructor.</p> <p><b>See also</b> <a href="qabstractsocket.html#socketType">socketType</a>().</p> <address><hr /><div align="center"><table border="0" cellspacing="0" width="100%"><tr class="address"><td align="left" width="25%">PyQt 4.10.3 for X11</td><td align="center" width="50%">Copyright © <a href="http://www.riverbankcomputing.com">Riverbank Computing Ltd</a> and <a href="http://www.qtsoftware.com">Nokia</a> 2012</td><td align="right" width="25%">Qt 4.8.5</td></tr></table></div></address></body></html>