Fix build break
[chromium-blink-merge.git] / content / renderer / websharedworkerrepository_impl.h
blob4263c8e97d9e536f4e5ce5150bac58e9958afc20
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CONTENT_RENDERER_WEBSHAREDWORKERREPOSITORY_IMPL_H_
6 #define CONTENT_RENDERER_WEBSHAREDWORKERREPOSITORY_IMPL_H_
8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebSharedWorkerRepository.h"
10 #include "base/hash_tables.h"
12 namespace WebKit {
13 class WebSharedWorker;
16 namespace content {
18 class WebSharedWorkerRepositoryImpl : public WebKit::WebSharedWorkerRepository {
19 public:
20 WebSharedWorkerRepositoryImpl();
21 virtual ~WebSharedWorkerRepositoryImpl();
23 virtual void addSharedWorker(WebKit::WebSharedWorker*, DocumentID document);
24 virtual void documentDetached(DocumentID document);
26 // Returns true if the document has created a SharedWorker (used by the
27 // WebKit code to determine if the document can be suspended).
28 virtual bool hasSharedWorkers(DocumentID document);
30 private:
31 // The set of documents that have created a SharedWorker.
32 typedef base::hash_set<DocumentID> DocumentSet;
33 DocumentSet shared_worker_parents_;
36 } // namespace content
38 #endif // CONTENT_RENDERER_WEBSHAREDWORKERREPOSITORY_IMPL_H_