Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(859)

Unified Diff: third_party/WebKit/public/platform/modules/websockets/WebSocketHandshakeRequestInfo.h

Issue 2279763003: Revert "Move WebSocketHandleImpl into Blink" (Closed)
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/public/platform/modules/websockets/WebSocketHandshakeRequestInfo.h
diff --git a/third_party/WebKit/public/platform/modules/serviceworker/WebServiceWorkerProviderClient.h b/third_party/WebKit/public/platform/modules/websockets/WebSocketHandshakeRequestInfo.h
similarity index 65%
copy from third_party/WebKit/public/platform/modules/serviceworker/WebServiceWorkerProviderClient.h
copy to third_party/WebKit/public/platform/modules/websockets/WebSocketHandshakeRequestInfo.h
index ac5e003d0ac850ad9783e41d975bc786dc959744..0ab3a9a46edfd51ccad7e2531cdc952e32141fa1 100644
--- a/third_party/WebKit/public/platform/modules/serviceworker/WebServiceWorkerProviderClient.h
+++ b/third_party/WebKit/public/platform/modules/websockets/WebSocketHandshakeRequestInfo.h
@@ -28,31 +28,36 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef WebServiceWorkerProviderClient_h
-#define WebServiceWorkerProviderClient_h
+#ifndef WebSocketHandshakeRequestInfo_h
+#define WebSocketHandshakeRequestInfo_h
#include "public/platform/WebCommon.h"
-#include "public/platform/WebMessagePortChannel.h"
-#include "public/platform/modules/serviceworker/WebServiceWorker.h"
-
-#include <memory>
+#include "public/platform/WebNonCopyable.h"
+#include "public/platform/WebPrivatePtr.h"
namespace blink {
-class WebServiceWorker;
class WebString;
+class WebSocketHandshakeRequest;
+class WebURL;
-// This class is the interface for embedders to talk to
-// ServiceWorkerContainer.
-class BLINK_PLATFORM_EXPORT WebServiceWorkerProviderClient {
+class WebSocketHandshakeRequestInfo : public WebNonCopyable {
public:
- virtual ~WebServiceWorkerProviderClient() { }
+ BLINK_PLATFORM_EXPORT WebSocketHandshakeRequestInfo();
+ BLINK_PLATFORM_EXPORT ~WebSocketHandshakeRequestInfo();
+
+ BLINK_PLATFORM_EXPORT void setURL(const WebURL&);
+ BLINK_PLATFORM_EXPORT void addHeaderField(const WebString& name, const WebString& value);
+ BLINK_PLATFORM_EXPORT void setHeadersText(const WebString&);
- virtual void setController(std::unique_ptr<WebServiceWorker::Handle>, bool shouldNotifyControllerChange) = 0;
+#if INSIDE_BLINK
+ BLINK_PLATFORM_EXPORT const WebSocketHandshakeRequest& toCoreRequest() const { return *m_private.get(); }
+#endif // INSIDE_BLINK
- virtual void dispatchMessageEvent(std::unique_ptr<WebServiceWorker::Handle>, const WebString& message, const WebMessagePortChannelArray& channels) = 0;
+private:
+ WebPrivatePtr<WebSocketHandshakeRequest> m_private;
};
} // namespace blink
-#endif // WebServiceWorkerProviderClient_h
+#endif // WebSocketHandshakeRequestInfo_h

Powered by Google App Engine
This is Rietveld 408576698