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

Side by Side Diff: chrome/browser/extensions/api/sync_file_system/sync_file_system_api.h

Issue 624153002: replace OVERRIDE and FINAL with override and final in chrome/browser/extensions/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_EXTENSIONS_API_SYNC_FILE_SYSTEM_SYNC_FILE_SYSTEM_API_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_SYNC_FILE_SYSTEM_SYNC_FILE_SYSTEM_API_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_SYNC_FILE_SYSTEM_SYNC_FILE_SYSTEM_API_H_ 6 #define CHROME_BROWSER_EXTENSIONS_API_SYNC_FILE_SYSTEM_SYNC_FILE_SYSTEM_API_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "chrome/browser/extensions/chrome_extension_function.h" 10 #include "chrome/browser/extensions/chrome_extension_function.h"
(...skipping 13 matching lines...) Expand all
24 class SyncFileSystemDeleteFileSystemFunction 24 class SyncFileSystemDeleteFileSystemFunction
25 : public ChromeAsyncExtensionFunction { 25 : public ChromeAsyncExtensionFunction {
26 public: 26 public:
27 // TODO(kinuko,calvinlo): Uncomment this or delete this class when 27 // TODO(kinuko,calvinlo): Uncomment this or delete this class when
28 // we decide if we want to revive this function. 28 // we decide if we want to revive this function.
29 // DECLARE_EXTENSION_FUNCTION("syncFileSystem.deleteFileSystem", 29 // DECLARE_EXTENSION_FUNCTION("syncFileSystem.deleteFileSystem",
30 // SYNCFILESYSTEM_DELETEFILESYSTEM) 30 // SYNCFILESYSTEM_DELETEFILESYSTEM)
31 31
32 protected: 32 protected:
33 virtual ~SyncFileSystemDeleteFileSystemFunction() {} 33 virtual ~SyncFileSystemDeleteFileSystemFunction() {}
34 virtual bool RunAsync() OVERRIDE; 34 virtual bool RunAsync() override;
35 35
36 private: 36 private:
37 void DidDeleteFileSystem(base::File::Error error); 37 void DidDeleteFileSystem(base::File::Error error);
38 }; 38 };
39 39
40 class SyncFileSystemGetFileStatusFunction 40 class SyncFileSystemGetFileStatusFunction
41 : public ChromeAsyncExtensionFunction { 41 : public ChromeAsyncExtensionFunction {
42 public: 42 public:
43 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getFileStatus", 43 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getFileStatus",
44 SYNCFILESYSTEM_GETFILESYNCSTATUS) 44 SYNCFILESYSTEM_GETFILESYNCSTATUS)
45 45
46 protected: 46 protected:
47 virtual ~SyncFileSystemGetFileStatusFunction() {} 47 virtual ~SyncFileSystemGetFileStatusFunction() {}
48 virtual bool RunAsync() OVERRIDE; 48 virtual bool RunAsync() override;
49 49
50 private: 50 private:
51 void DidGetFileStatus( 51 void DidGetFileStatus(
52 const sync_file_system::SyncStatusCode sync_service_status, 52 const sync_file_system::SyncStatusCode sync_service_status,
53 const sync_file_system::SyncFileStatus sync_file_status); 53 const sync_file_system::SyncFileStatus sync_file_status);
54 }; 54 };
55 55
56 class SyncFileSystemGetFileStatusesFunction 56 class SyncFileSystemGetFileStatusesFunction
57 : public ChromeAsyncExtensionFunction { 57 : public ChromeAsyncExtensionFunction {
58 public: 58 public:
59 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getFileStatuses", 59 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getFileStatuses",
60 SYNCFILESYSTEM_GETFILESYNCSTATUSES) 60 SYNCFILESYSTEM_GETFILESYNCSTATUSES)
61 SyncFileSystemGetFileStatusesFunction(); 61 SyncFileSystemGetFileStatusesFunction();
62 62
63 protected: 63 protected:
64 virtual ~SyncFileSystemGetFileStatusesFunction(); 64 virtual ~SyncFileSystemGetFileStatusesFunction();
65 virtual bool RunAsync() OVERRIDE; 65 virtual bool RunAsync() override;
66 66
67 private: 67 private:
68 typedef std::pair<sync_file_system::SyncStatusCode, 68 typedef std::pair<sync_file_system::SyncStatusCode,
69 sync_file_system::SyncFileStatus> FileStatusPair; 69 sync_file_system::SyncFileStatus> FileStatusPair;
70 typedef std::map<storage::FileSystemURL, 70 typedef std::map<storage::FileSystemURL,
71 FileStatusPair, 71 FileStatusPair,
72 storage::FileSystemURL::Comparator> URLToStatusMap; 72 storage::FileSystemURL::Comparator> URLToStatusMap;
73 73
74 void DidGetFileStatus(const storage::FileSystemURL& file_system_url, 74 void DidGetFileStatus(const storage::FileSystemURL& file_system_url,
75 sync_file_system::SyncStatusCode sync_status_code, 75 sync_file_system::SyncStatusCode sync_status_code,
76 sync_file_system::SyncFileStatus sync_file_statuses); 76 sync_file_system::SyncFileStatus sync_file_statuses);
77 77
78 unsigned int num_expected_results_; 78 unsigned int num_expected_results_;
79 unsigned int num_results_received_; 79 unsigned int num_results_received_;
80 URLToStatusMap file_sync_statuses_; 80 URLToStatusMap file_sync_statuses_;
81 }; 81 };
82 82
83 class SyncFileSystemGetUsageAndQuotaFunction 83 class SyncFileSystemGetUsageAndQuotaFunction
84 : public ChromeAsyncExtensionFunction { 84 : public ChromeAsyncExtensionFunction {
85 public: 85 public:
86 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getUsageAndQuota", 86 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getUsageAndQuota",
87 SYNCFILESYSTEM_GETUSAGEANDQUOTA) 87 SYNCFILESYSTEM_GETUSAGEANDQUOTA)
88 88
89 protected: 89 protected:
90 virtual ~SyncFileSystemGetUsageAndQuotaFunction() {} 90 virtual ~SyncFileSystemGetUsageAndQuotaFunction() {}
91 virtual bool RunAsync() OVERRIDE; 91 virtual bool RunAsync() override;
92 92
93 private: 93 private:
94 void DidGetUsageAndQuota(storage::QuotaStatusCode status, 94 void DidGetUsageAndQuota(storage::QuotaStatusCode status,
95 int64 usage, 95 int64 usage,
96 int64 quota); 96 int64 quota);
97 }; 97 };
98 98
99 class SyncFileSystemRequestFileSystemFunction 99 class SyncFileSystemRequestFileSystemFunction
100 : public ChromeAsyncExtensionFunction { 100 : public ChromeAsyncExtensionFunction {
101 public: 101 public:
102 DECLARE_EXTENSION_FUNCTION("syncFileSystem.requestFileSystem", 102 DECLARE_EXTENSION_FUNCTION("syncFileSystem.requestFileSystem",
103 SYNCFILESYSTEM_REQUESTFILESYSTEM) 103 SYNCFILESYSTEM_REQUESTFILESYSTEM)
104 104
105 protected: 105 protected:
106 virtual ~SyncFileSystemRequestFileSystemFunction() {} 106 virtual ~SyncFileSystemRequestFileSystemFunction() {}
107 virtual bool RunAsync() OVERRIDE; 107 virtual bool RunAsync() override;
108 108
109 private: 109 private:
110 typedef SyncFileSystemRequestFileSystemFunction self; 110 typedef SyncFileSystemRequestFileSystemFunction self;
111 111
112 // Returns the file system context for this extension. 112 // Returns the file system context for this extension.
113 storage::FileSystemContext* GetFileSystemContext(); 113 storage::FileSystemContext* GetFileSystemContext();
114 114
115 void DidOpenFileSystem(const GURL& root_url, 115 void DidOpenFileSystem(const GURL& root_url,
116 const std::string& file_system_name, 116 const std::string& file_system_name,
117 base::File::Error error); 117 base::File::Error error);
118 }; 118 };
119 119
120 class SyncFileSystemSetConflictResolutionPolicyFunction 120 class SyncFileSystemSetConflictResolutionPolicyFunction
121 : public ChromeSyncExtensionFunction { 121 : public ChromeSyncExtensionFunction {
122 public: 122 public:
123 DECLARE_EXTENSION_FUNCTION("syncFileSystem.setConflictResolutionPolicy", 123 DECLARE_EXTENSION_FUNCTION("syncFileSystem.setConflictResolutionPolicy",
124 SYNCFILESYSTEM_SETCONFLICTRESOLUTIONPOLICY) 124 SYNCFILESYSTEM_SETCONFLICTRESOLUTIONPOLICY)
125 125
126 protected: 126 protected:
127 virtual ~SyncFileSystemSetConflictResolutionPolicyFunction() {} 127 virtual ~SyncFileSystemSetConflictResolutionPolicyFunction() {}
128 virtual bool RunSync() OVERRIDE; 128 virtual bool RunSync() override;
129 }; 129 };
130 130
131 class SyncFileSystemGetConflictResolutionPolicyFunction 131 class SyncFileSystemGetConflictResolutionPolicyFunction
132 : public ChromeSyncExtensionFunction { 132 : public ChromeSyncExtensionFunction {
133 public: 133 public:
134 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getConflictResolutionPolicy", 134 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getConflictResolutionPolicy",
135 SYNCFILESYSTEM_GETCONFLICTRESOLUTIONPOLICY) 135 SYNCFILESYSTEM_GETCONFLICTRESOLUTIONPOLICY)
136 136
137 protected: 137 protected:
138 virtual ~SyncFileSystemGetConflictResolutionPolicyFunction() {} 138 virtual ~SyncFileSystemGetConflictResolutionPolicyFunction() {}
139 virtual bool RunSync() OVERRIDE; 139 virtual bool RunSync() override;
140 }; 140 };
141 141
142 class SyncFileSystemGetServiceStatusFunction 142 class SyncFileSystemGetServiceStatusFunction
143 : public ChromeSyncExtensionFunction { 143 : public ChromeSyncExtensionFunction {
144 public: 144 public:
145 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getServiceStatus", 145 DECLARE_EXTENSION_FUNCTION("syncFileSystem.getServiceStatus",
146 SYNCFILESYSTEM_GETSERVICESTATUS) 146 SYNCFILESYSTEM_GETSERVICESTATUS)
147 147
148 protected: 148 protected:
149 virtual ~SyncFileSystemGetServiceStatusFunction() {} 149 virtual ~SyncFileSystemGetServiceStatusFunction() {}
150 virtual bool RunSync() OVERRIDE; 150 virtual bool RunSync() override;
151 }; 151 };
152 152
153 } // namespace extensions 153 } // namespace extensions
154 154
155 #endif // CHROME_BROWSER_EXTENSIONS_API_SYNC_FILE_SYSTEM_SYNC_FILE_SYSTEM_API_H _ 155 #endif // CHROME_BROWSER_EXTENSIONS_API_SYNC_FILE_SYSTEM_SYNC_FILE_SYSTEM_API_H _
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698