diff options
author | Lorry Tar Creator <lorry-tar-importer@lorry> | 2017-06-27 06:07:23 +0000 |
---|---|---|
committer | Lorry Tar Creator <lorry-tar-importer@lorry> | 2017-06-27 06:07:23 +0000 |
commit | 1bf1084f2b10c3b47fd1a588d85d21ed0eb41d0c (patch) | |
tree | 46dcd36c86e7fbc6e5df36deb463b33e9967a6f7 /Source/WebCore/Modules/websockets/WebSocketHandshake.h | |
parent | 32761a6cee1d0dee366b885b7b9c777e67885688 (diff) | |
download | WebKitGtk-tarball-master.tar.gz |
webkitgtk-2.16.5HEADwebkitgtk-2.16.5master
Diffstat (limited to 'Source/WebCore/Modules/websockets/WebSocketHandshake.h')
-rw-r--r-- | Source/WebCore/Modules/websockets/WebSocketHandshake.h | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/Source/WebCore/Modules/websockets/WebSocketHandshake.h b/Source/WebCore/Modules/websockets/WebSocketHandshake.h index ccab04501..9f701c530 100644 --- a/Source/WebCore/Modules/websockets/WebSocketHandshake.h +++ b/Source/WebCore/Modules/websockets/WebSocketHandshake.h @@ -28,8 +28,7 @@ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#ifndef WebSocketHandshake_h -#define WebSocketHandshake_h +#pragma once #if ENABLE(WEB_SOCKETS) @@ -37,13 +36,12 @@ #include "ResourceResponse.h" #include "WebSocketExtensionDispatcher.h" #include "WebSocketExtensionProcessor.h" -#include <wtf/PassOwnPtr.h> #include <wtf/text/WTFString.h> namespace WebCore { +class Document; class ResourceRequest; -class ScriptExecutionContext; class WebSocketHandshake { WTF_MAKE_NONCOPYABLE(WebSocketHandshake); WTF_MAKE_FAST_ALLOCATED; @@ -51,7 +49,7 @@ public: enum Mode { Incomplete, Normal, Failed, Connected }; - WebSocketHandshake(const URL&, const String& protocol, ScriptExecutionContext*); + WebSocketHandshake(const URL&, const String& protocol, Document*, bool allowCookies); ~WebSocketHandshake(); const URL& url() const; @@ -70,7 +68,7 @@ public: ResourceRequest clientHandshakeRequest() const; void reset(); - void clearScriptExecutionContext(); + void clearDocument(); int readServerHandshake(const char* header, size_t len); Mode mode() const; @@ -78,7 +76,6 @@ public: String serverWebSocketProtocol() const; String serverSetCookie() const; - String serverSetCookie2() const; String serverUpgrade() const; String serverConnection() const; String serverWebSocketAccept() const; @@ -86,7 +83,7 @@ public: const ResourceResponse& serverHandshakeResponse() const; - void addExtensionProcessor(PassOwnPtr<WebSocketExtensionProcessor>); + void addExtensionProcessor(std::unique_ptr<WebSocketExtensionProcessor>); static String getExpectedWebSocketAccept(const String& secWebSocketKey); @@ -103,9 +100,10 @@ private: URL m_url; String m_clientProtocol; bool m_secure; - ScriptExecutionContext* m_context; + Document* m_document; Mode m_mode; + bool m_allowCookies; ResourceResponse m_serverHandshakeResponse; @@ -120,5 +118,3 @@ private: } // namespace WebCore #endif // ENABLE(WEB_SOCKETS) - -#endif // WebSocketHandshake_h |