| Index: content/browser/websocket/websocket_manager.h
|
| diff --git a/content/browser/websocket/websocket_manager.h b/content/browser/websocket/websocket_manager.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..34ea1588ae1e069703878a081d123ece8cba0138
|
| --- /dev/null
|
| +++ b/content/browser/websocket/websocket_manager.h
|
| @@ -0,0 +1,42 @@
|
| +// Copyright 2013 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef CONTENT_BROWSER_RENDERER_HOST_WEBSOCKET_MANAGER_H_
|
| +#define CONTENT_BROWSER_RENDERER_HOST_WEBSOCKET_MANAGER_H_
|
| +
|
| +#include "base/macros.h"
|
| +#include "content/common/content_export.h"
|
| +#include "content/common/websocket.mojom.h"
|
| +
|
| +namespace content {
|
| +
|
| +class ChromeBlobStorageContext;
|
| +class StoragePartition;
|
| +
|
| +// The WebSocketManager is a per child process instance that manages the
|
| +// lifecycle of WebSocketImpl objects. It is responsible for creating
|
| +// WebSocketImpl objects for each WebSocketRequest and throttling the number of
|
| +// WebSocketImpl objects in use.
|
| +class CONTENT_EXPORT WebSocketManager {
|
| + public:
|
| + // These public methods are called on the UI thread.
|
| +
|
| + WebSocketManager(
|
| + int process_id,
|
| + StoragePartition* storage_partition,
|
| + const scoped_refptr<ChromeBlobStorageContext>& blob_storage_context);
|
| + ~WebSocketManager();
|
| +
|
| + void CreateWebSocket(int render_frame_id, mojom::WebSocketRequest request);
|
| +
|
| + private:
|
| + class IOThreadState;
|
| + IOThreadState* io_thread_state_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(WebSocketManager);
|
| +};
|
| +
|
| +} // namespace content
|
| +
|
| +#endif // CONTENT_BROWSER_RENDERER_HOST_WEBSOCKET_MANAGER_H_
|
|
|