Clean up WebSocket code
authorachristensen@apple.com <achristensen@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Jun 2016 20:10:30 +0000 (20:10 +0000)
committerachristensen@apple.com <achristensen@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Jun 2016 20:10:30 +0000 (20:10 +0000)
commitfbe22631fd350d24fbf53dc5bf969afeb0ab2b69
tree9fac76627cbbee242d001099d3135de702004e16
parented9512ed21c067f6d174f2589634a481aac0bd6c
Clean up WebSocket code
https://bugs.webkit.org/show_bug.cgi?id=158551

Reviewed by Darin Adler.

Source/WebCore:

No new tests.  There is no change in behavior.
There seems to be no reason why SocketStreamHandle should be an AuthenticationClient.

* Modules/websockets/ThreadableWebSocketChannel.h:
* Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
(WebCore::ThreadableWebSocketChannelClientWrapper::setSendRequestResult):
(WebCore::ThreadableWebSocketChannelClientWrapper::bufferedAmount):
(WebCore::ThreadableWebSocketChannelClientWrapper::setBufferedAmount):
(WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData):
(WebCore::ThreadableWebSocketChannelClientWrapper::didUpdateBufferedAmount):
(WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshake):
(WebCore::ThreadableWebSocketChannelClientWrapper::didClose):
* Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
* Modules/websockets/WebSocket.cpp:
(WebCore::joinStrings):
(WebCore::saturateAdd):
(WebCore::WebSocket::send):
(WebCore::WebSocket::readyState):
(WebCore::WebSocket::bufferedAmount):
(WebCore::WebSocket::didReceiveBinaryData):
(WebCore::WebSocket::didReceiveMessageError):
(WebCore::WebSocket::didUpdateBufferedAmount):
(WebCore::WebSocket::didStartClosingHandshake):
(WebCore::WebSocket::didClose):
* Modules/websockets/WebSocket.h:
* Modules/websockets/WebSocketChannel.cpp:
(WebCore::WebSocketChannel::WebSocketChannel):
(WebCore::WebSocketChannel::~WebSocketChannel):
(WebCore::WebSocketChannel::send):
(WebCore::WebSocketChannel::bufferedAmount):
(WebCore::WebSocketChannel::resume):
(WebCore::WebSocketChannel::willOpenSocketStream):
(WebCore::WebSocketChannel::didOpenSocketStream):
(WebCore::WebSocketChannel::didCloseSocketStream):
(WebCore::WebSocketChannel::didReceiveSocketStreamData):
(WebCore::WebSocketChannel::didUpdateBufferedAmount):
(WebCore::WebSocketChannel::didFailSocketStream):
(WebCore::WebSocketChannel::didStartLoading):
(WebCore::WebSocketChannel::appendToBuffer):
(WebCore::WebSocketChannel::processBuffer):
(WebCore::WebSocketChannel::resumeTimerFired):
(WebCore::WebSocketChannel::startClosingHandshake):
(WebCore::WebSocketChannel::didReceiveAuthenticationChallenge): Deleted.
(WebCore::WebSocketChannel::didCancelAuthenticationChallenge): Deleted.
* Modules/websockets/WebSocketChannel.h:
* Modules/websockets/WebSocketChannelClient.h:
(WebCore::WebSocketChannelClient::~WebSocketChannelClient):
(WebCore::WebSocketChannelClient::didConnect):
(WebCore::WebSocketChannelClient::didReceiveMessage):
(WebCore::WebSocketChannelClient::didReceiveBinaryData):
(WebCore::WebSocketChannelClient::didReceiveMessageError):
(WebCore::WebSocketChannelClient::didUpdateBufferedAmount):
(WebCore::WebSocketChannelClient::didStartClosingHandshake):
(WebCore::WebSocketChannelClient::didClose):
(WebCore::WebSocketChannelClient::WebSocketChannelClient):
* Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
(WebCore::WorkerThreadableWebSocketChannel::send):
(WebCore::WorkerThreadableWebSocketChannel::bufferedAmount):
(WebCore::WorkerThreadableWebSocketChannel::Peer::bufferedAmount):
(WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveBinaryData):
(WebCore::WorkerThreadableWebSocketChannel::Peer::didUpdateBufferedAmount):
(WebCore::WorkerThreadableWebSocketChannel::Peer::didStartClosingHandshake):
(WebCore::WorkerThreadableWebSocketChannel::Peer::didClose):
(WebCore::WorkerThreadableWebSocketChannel::Bridge::send):
(WebCore::WorkerThreadableWebSocketChannel::Bridge::bufferedAmount):
* Modules/websockets/WorkerThreadableWebSocketChannel.h:
* platform/network/BlobData.cpp:
(WebCore::BlobData::appendData):
(WebCore::BlobData::appendFile):
* platform/network/BlobData.h:
(WebCore::BlobDataItem::BlobDataItem):
* platform/network/BlobRegistry.h:
* platform/network/BlobRegistryImpl.cpp:
(WebCore::BlobRegistryImpl::appendStorageItems):
(WebCore::BlobRegistryImpl::registerFileBlobURL):
(WebCore::BlobRegistryImpl::registerBlobURL):
(WebCore::BlobRegistryImpl::registerBlobURLOptionallyFileBacked):
(WebCore::BlobRegistryImpl::registerBlobURLForSlice):
* platform/network/BlobRegistryImpl.h:
* platform/network/SocketStreamHandleBase.cpp:
(WebCore::SocketStreamHandleBase::send):
(WebCore::SocketStreamHandleBase::disconnect):
(WebCore::SocketStreamHandleBase::sendPendingData):
* platform/network/SocketStreamHandleBase.h:
* platform/network/SocketStreamHandleClient.h:
(WebCore::SocketStreamHandleClient::~SocketStreamHandleClient):
(WebCore::SocketStreamHandleClient::willOpenSocketStream):
(WebCore::SocketStreamHandleClient::didOpenSocketStream):
(WebCore::SocketStreamHandleClient::didCloseSocketStream):
(WebCore::SocketStreamHandleClient::didReceiveSocketStreamData):
(WebCore::SocketStreamHandleClient::didUpdateBufferedAmount):
(WebCore::SocketStreamHandleClient::didFailSocketStream):
(WebCore::SocketStreamHandleClient::didReceiveAuthenticationChallenge): Deleted.
(WebCore::SocketStreamHandleClient::didCancelAuthenticationChallenge): Deleted.
* platform/network/cf/SocketStreamHandle.h:
(WebCore::SocketStreamHandle::create):
(WebCore::SocketStreamHandle::refAuthenticationClient): Deleted.
(WebCore::SocketStreamHandle::derefAuthenticationClient): Deleted.
* platform/network/cf/SocketStreamHandleCFNet.cpp:
(WebCore::SocketStreamHandle::SocketStreamHandle):
(WebCore::SocketStreamHandle::addCONNECTCredentials):
(WebCore::SocketStreamHandle::copyCFStreamDescription):
(WebCore::SocketStreamHandle::readStreamCallback):
(WebCore::SocketStreamHandle::writeStreamCallback):
(WebCore::SocketStreamHandle::reportErrorToClient):
(WebCore::SocketStreamHandle::~SocketStreamHandle):
(WebCore::SocketStreamHandle::platformClose):
(WebCore::SocketStreamHandle::port):
(WebCore::SocketStreamHandle::receivedCredential): Deleted.
(WebCore::SocketStreamHandle::receivedRequestToContinueWithoutCredential): Deleted.
(WebCore::SocketStreamHandle::receivedCancellation): Deleted.
(WebCore::SocketStreamHandle::receivedRequestToPerformDefaultHandling): Deleted.
(WebCore::SocketStreamHandle::receivedChallengeRejection): Deleted.
* platform/network/curl/ResourceHandleCurl.cpp:
* platform/network/curl/SocketStreamHandle.h:
(WebCore::SocketStreamHandle::SocketData::SocketData):
* platform/network/curl/SocketStreamHandleCurl.cpp:
(WebCore::SocketStreamHandle::platformClose):
(WebCore::SocketStreamHandle::readData):
(WebCore::SocketStreamHandle::didReceiveData):
(WebCore::SocketStreamHandle::didOpenSocket):
(WebCore::SocketStreamHandle::createCopy):
(WebCore::SocketStreamHandle::didReceiveAuthenticationChallenge): Deleted.
(WebCore::SocketStreamHandle::receivedCredential): Deleted.
(WebCore::SocketStreamHandle::receivedRequestToContinueWithoutCredential): Deleted.
(WebCore::SocketStreamHandle::receivedCancellation): Deleted.
(WebCore::SocketStreamHandle::receivedRequestToPerformDefaultHandling): Deleted.
(WebCore::SocketStreamHandle::receivedChallengeRejection): Deleted.
* platform/network/soup/SocketStreamHandle.h:
(WebCore::SocketStreamHandle::create):
* platform/network/soup/SocketStreamHandleSoup.cpp:
(WebCore::getHandleFromId):
(WebCore::deactivateHandle):
(WebCore::activateHandle):
(WebCore::SocketStreamHandle::SocketStreamHandle):
(WebCore::SocketStreamHandle::~SocketStreamHandle):
(WebCore::SocketStreamHandle::connected):
(WebCore::SocketStreamHandle::readBytes):
(WebCore::SocketStreamHandle::platformSend):
(WebCore::SocketStreamHandle::platformClose):
(WebCore::SocketStreamHandle::beginWaitingForSocketWritability):
(WebCore::SocketStreamHandle::didReceiveAuthenticationChallenge): Deleted.
(WebCore::SocketStreamHandle::receivedCredential): Deleted.
(WebCore::SocketStreamHandle::receivedRequestToContinueWithoutCredential): Deleted.
(WebCore::SocketStreamHandle::receivedCancellation): Deleted.
(WebCore::SocketStreamHandle::receivedRequestToPerformDefaultHandling): Deleted.
(WebCore::SocketStreamHandle::receivedChallengeRejection): Deleted.

Source/WebKit2:

* WebProcess/FileAPI/BlobRegistryProxy.cpp:
(WebKit::BlobRegistryProxy::registerFileBlobURL):
* WebProcess/FileAPI/BlobRegistryProxy.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@201880 268f45cc-cd09-0410-ab3c-d52691b4dbfc
29 files changed:
Source/WebCore/ChangeLog
Source/WebCore/Modules/websockets/ThreadableWebSocketChannel.h
Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp
Source/WebCore/Modules/websockets/ThreadableWebSocketChannelClientWrapper.h
Source/WebCore/Modules/websockets/WebSocket.cpp
Source/WebCore/Modules/websockets/WebSocket.h
Source/WebCore/Modules/websockets/WebSocketChannel.cpp
Source/WebCore/Modules/websockets/WebSocketChannel.h
Source/WebCore/Modules/websockets/WebSocketChannelClient.h
Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.cpp
Source/WebCore/Modules/websockets/WorkerThreadableWebSocketChannel.h
Source/WebCore/platform/network/BlobData.cpp
Source/WebCore/platform/network/BlobData.h
Source/WebCore/platform/network/BlobRegistry.h
Source/WebCore/platform/network/BlobRegistryImpl.cpp
Source/WebCore/platform/network/BlobRegistryImpl.h
Source/WebCore/platform/network/SocketStreamHandleBase.cpp
Source/WebCore/platform/network/SocketStreamHandleBase.h
Source/WebCore/platform/network/SocketStreamHandleClient.h
Source/WebCore/platform/network/cf/SocketStreamHandle.h
Source/WebCore/platform/network/cf/SocketStreamHandleCFNet.cpp
Source/WebCore/platform/network/curl/ResourceHandleCurl.cpp
Source/WebCore/platform/network/curl/SocketStreamHandle.h
Source/WebCore/platform/network/curl/SocketStreamHandleCurl.cpp
Source/WebCore/platform/network/soup/SocketStreamHandle.h
Source/WebCore/platform/network/soup/SocketStreamHandleSoup.cpp
Source/WebKit2/ChangeLog
Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.cpp
Source/WebKit2/WebProcess/FileAPI/BlobRegistryProxy.h