From 11b5eca580900a677fdf9a5d6cd990b0700ad5ad Mon Sep 17 00:00:00 2001 From: Kurt Pattyn Date: Sun, 26 Jan 2014 17:30:32 +0100 Subject: Remove socketOption functionality 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 --- src/websockets/qwebsocket.cpp | 20 -------------------- src/websockets/qwebsocket.h | 2 -- src/websockets/qwebsocket_p.cpp | 20 -------------------- src/websockets/qwebsocket_p.h | 2 -- 4 files changed, 44 deletions(-) diff --git a/src/websockets/qwebsocket.cpp b/src/websockets/qwebsocket.cpp index 17bd364..39998cc 100644 --- a/src/websockets/qwebsocket.cpp +++ b/src/websockets/qwebsocket.cpp @@ -677,26 +677,6 @@ void QWebSocket::setReadBufferSize(qint64 size) d->setReadBufferSize(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. */ diff --git a/src/websockets/qwebsocket.h b/src/websockets/qwebsocket.h index 757cf36..15c3a82 100644 --- a/src/websockets/qwebsocket.h +++ b/src/websockets/qwebsocket.h @@ -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; diff --git a/src/websockets/qwebsocket_p.cpp b/src/websockets/qwebsocket_p.cpp index 5d775ef..631e016 100644 --- a/src/websockets/qwebsocket_p.cpp +++ b/src/websockets/qwebsocket_p.cpp @@ -1215,26 +1215,6 @@ void QWebSocketPrivate::setReadBufferSize(qint64 size) m_pSocket->setReadBufferSize(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 */ diff --git a/src/websockets/qwebsocket_p.h b/src/websockets/qwebsocket_p.h index d3f13e2..f02e7ad 100644 --- a/src/websockets/qwebsocket_p.h +++ b/src/websockets/qwebsocket_p.h @@ -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; -- cgit v1.2.1