Remove socketOption functionality
authorKurt Pattyn <pattyn.kurt@gmail.com>
Sun, 26 Jan 2014 16:30:32 +0000 (17:30 +0100)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Sat, 1 Feb 2014 15:19:28 +0000 (16:19 +0100)
Removed the setSocketOption() and socketOption(0 methods as they are
not really relevant for web sockets. Also, internally for the underlying real
socket the LowDelayOption and KeepAliveOption are already set.
If ever needed, these methods can be added later.

Change-Id: Ibfa279990c5277970eaa2dbc2dd3a7d0cce7154e
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
src/websockets/qwebsocket.cpp
src/websockets/qwebsocket.h
src/websockets/qwebsocket_p.cpp
src/websockets/qwebsocket_p.h

index 17bd364..39998cc 100644 (file)
@@ -678,26 +678,6 @@ void QWebSocket::setReadBufferSize(qint64 size)
 }
 
 /*!
-    Sets the given \a option to the value described by \a value.
-    \sa socketOption()
-*/
-void QWebSocket::setSocketOption(QAbstractSocket::SocketOption option, const QVariant &value)
-{
-    Q_D(QWebSocket);
-    d->setSocketOption(option, value);
-}
-
-/*!
-    Returns the value of the option \a option.
-    \sa setSocketOption()
-*/
-QVariant QWebSocket::socketOption(QAbstractSocket::SocketOption option)
-{
-    Q_D(QWebSocket);
-    return d->socketOption(option);
-}
-
-/*!
     Returns true if the QWebSocket is valid.
  */
 bool QWebSocket::isValid() const
index 757cf36..15c3a82 100644 (file)
@@ -91,8 +91,6 @@ public:
     void resume();
     void setPauseMode(QAbstractSocket::PauseModes pauseMode);
 
-    void setSocketOption(QAbstractSocket::SocketOption option, const QVariant &value);
-    QVariant socketOption(QAbstractSocket::SocketOption option);
     QAbstractSocket::SocketState state() const;
 
     QWebSocketProtocol::Version version() const;
index 5d775ef..631e016 100644 (file)
@@ -1218,26 +1218,6 @@ void QWebSocketPrivate::setReadBufferSize(qint64 size)
 /*!
     \internal
  */
-void QWebSocketPrivate::setSocketOption(QAbstractSocket::SocketOption option, const QVariant &value)
-{
-    if (Q_LIKELY(m_pSocket))
-        m_pSocket->setSocketOption(option, value);
-}
-
-/*!
-    \internal
- */
-QVariant QWebSocketPrivate::socketOption(QAbstractSocket::SocketOption option)
-{
-    QVariant val;
-    if (Q_LIKELY(m_pSocket))
-        val = m_pSocket->socketOption(option);
-    return val;
-}
-
-/*!
-    \internal
- */
 bool QWebSocketPrivate::isValid() const
 {
     return (m_pSocket && m_pSocket->isValid());
index d3f13e2..f02e7ad 100644 (file)
@@ -127,8 +127,6 @@ public:
     void resume();
     void setPauseMode(QAbstractSocket::PauseModes pauseMode);
     void setReadBufferSize(qint64 size);
-    void setSocketOption(QAbstractSocket::SocketOption option, const QVariant &value);
-    QVariant socketOption(QAbstractSocket::SocketOption option);
     QAbstractSocket::SocketState state() const;
 
     QWebSocketProtocol::Version version() const;