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

Side by Side Diff: webkit/fileapi/file_system_quota_client.h

Issue 15535006: Move browser-specific FileAPI code from webkit/fileapi to webkit/browser/fileapi (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « webkit/fileapi/file_system_context.cc ('k') | webkit/fileapi/file_system_quota_client.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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.
4
5 #ifndef WEBKIT_FILEAPI_FILE_SYSTEM_QUOTA_CLIENT_H_
6 #define WEBKIT_FILEAPI_FILE_SYSTEM_QUOTA_CLIENT_H_
7
8 #include <set>
9 #include <string>
10 #include <utility>
11
12 #include "base/basictypes.h"
13 #include "base/compiler_specific.h"
14 #include "base/files/file_path.h"
15 #include "base/memory/ref_counted.h"
16 #include "webkit/fileapi/file_system_quota_util.h"
17 #include "webkit/fileapi/file_system_types.h"
18 #include "webkit/quota/quota_client.h"
19 #include "webkit/storage/webkit_storage_export.h"
20
21 namespace base {
22 class SequencedTaskRunner;
23 }
24
25 namespace fileapi {
26
27 class FileSystemContext;
28
29 // An instance of this class is created per-profile. This class
30 // is self-destructed and will delete itself when OnQuotaManagerDestroyed
31 // is called.
32 // All of the public methods of this class are called by the quota manager
33 // (except for the constructor/destructor).
34 class WEBKIT_STORAGE_EXPORT_PRIVATE FileSystemQuotaClient
35 : public NON_EXPORTED_BASE(quota::QuotaClient) {
36 public:
37 FileSystemQuotaClient(
38 FileSystemContext* file_system_context,
39 bool is_incognito);
40 virtual ~FileSystemQuotaClient();
41
42 // QuotaClient methods.
43 virtual quota::QuotaClient::ID id() const OVERRIDE;
44 virtual void OnQuotaManagerDestroyed() OVERRIDE;
45 virtual void GetOriginUsage(const GURL& origin_url,
46 quota::StorageType type,
47 const GetUsageCallback& callback) OVERRIDE;
48 virtual void GetOriginsForType(
49 quota::StorageType type,
50 const GetOriginsCallback& callback) OVERRIDE;
51 virtual void GetOriginsForHost(
52 quota::StorageType type,
53 const std::string& host,
54 const GetOriginsCallback& callback) OVERRIDE;
55 virtual void DeleteOriginData(
56 const GURL& origin,
57 quota::StorageType type,
58 const DeletionCallback& callback) OVERRIDE;
59
60 private:
61 base::SequencedTaskRunner* file_task_runner() const;
62
63 scoped_refptr<FileSystemContext> file_system_context_;
64
65 bool is_incognito_;
66
67 DISALLOW_COPY_AND_ASSIGN(FileSystemQuotaClient);
68 };
69
70 } // namespace fileapi
71
72 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_QUOTA_CLIENT_H_
OLDNEW
« no previous file with comments | « webkit/fileapi/file_system_context.cc ('k') | webkit/fileapi/file_system_quota_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698