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

Side by Side Diff: net/disk_cache/in_flight_backend_io.h

Issue 7064033: Virtual destructors should have virtual keyword. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 9 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 | « net/disk_cache/file_lock.cc ('k') | net/disk_cache/mem_backend_impl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 NET_DISK_CACHE_IN_FLIGHT_BACKEND_IO_H_ 5 #ifndef NET_DISK_CACHE_IN_FLIGHT_BACKEND_IO_H_
6 #define NET_DISK_CACHE_IN_FLIGHT_BACKEND_IO_H_ 6 #define NET_DISK_CACHE_IN_FLIGHT_BACKEND_IO_H_
7 #pragma once 7 #pragma once
8 8
9 #include <list> 9 #include <list>
10 #include <string> 10 #include <string>
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 OP_MAX_BACKEND, 96 OP_MAX_BACKEND,
97 OP_READ, 97 OP_READ,
98 OP_WRITE, 98 OP_WRITE,
99 OP_READ_SPARSE, 99 OP_READ_SPARSE,
100 OP_WRITE_SPARSE, 100 OP_WRITE_SPARSE,
101 OP_GET_RANGE, 101 OP_GET_RANGE,
102 OP_CANCEL_IO, 102 OP_CANCEL_IO,
103 OP_IS_READY 103 OP_IS_READY
104 }; 104 };
105 105
106 ~BackendIO(); 106 virtual ~BackendIO();
107 107
108 void ExecuteBackendOperation(); 108 void ExecuteBackendOperation();
109 void ExecuteEntryOperation(); 109 void ExecuteEntryOperation();
110 110
111 BackendImpl* backend_; 111 BackendImpl* backend_;
112 net::CompletionCallback* callback_; 112 net::CompletionCallback* callback_;
113 Operation operation_; 113 Operation operation_;
114 net::CompletionCallbackImpl<BackendIO> my_callback_; 114 net::CompletionCallbackImpl<BackendIO> my_callback_;
115 115
116 // The arguments of all the operations we proxy: 116 // The arguments of all the operations we proxy:
(...skipping 15 matching lines...) Expand all
132 Task* task_; 132 Task* task_;
133 133
134 DISALLOW_COPY_AND_ASSIGN(BackendIO); 134 DISALLOW_COPY_AND_ASSIGN(BackendIO);
135 }; 135 };
136 136
137 // The specialized controller that keeps track of current operations. 137 // The specialized controller that keeps track of current operations.
138 class InFlightBackendIO : public InFlightIO { 138 class InFlightBackendIO : public InFlightIO {
139 public: 139 public:
140 InFlightBackendIO(BackendImpl* backend, 140 InFlightBackendIO(BackendImpl* backend,
141 base::MessageLoopProxy* background_thread); 141 base::MessageLoopProxy* background_thread);
142 ~InFlightBackendIO(); 142 virtual ~InFlightBackendIO();
143 143
144 // The operations we proxy: 144 // The operations we proxy:
145 void Init(net::CompletionCallback* callback); 145 void Init(net::CompletionCallback* callback);
146 void OpenEntry(const std::string& key, Entry** entry, 146 void OpenEntry(const std::string& key, Entry** entry,
147 net::CompletionCallback* callback); 147 net::CompletionCallback* callback);
148 void CreateEntry(const std::string& key, Entry** entry, 148 void CreateEntry(const std::string& key, Entry** entry,
149 net::CompletionCallback* callback); 149 net::CompletionCallback* callback);
150 void DoomEntry(const std::string& key, net::CompletionCallback* callback); 150 void DoomEntry(const std::string& key, net::CompletionCallback* callback);
151 void DoomAllEntries(net::CompletionCallback* callback); 151 void DoomAllEntries(net::CompletionCallback* callback);
152 void DoomEntriesBetween(const base::Time initial_time, 152 void DoomEntriesBetween(const base::Time initial_time,
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 196
197 BackendImpl* backend_; 197 BackendImpl* backend_;
198 scoped_refptr<base::MessageLoopProxy> background_thread_; 198 scoped_refptr<base::MessageLoopProxy> background_thread_;
199 199
200 DISALLOW_COPY_AND_ASSIGN(InFlightBackendIO); 200 DISALLOW_COPY_AND_ASSIGN(InFlightBackendIO);
201 }; 201 };
202 202
203 } // namespace disk_cache 203 } // namespace disk_cache
204 204
205 #endif // NET_DISK_CACHE_IN_FLIGHT_BACKEND_IO_H_ 205 #endif // NET_DISK_CACHE_IN_FLIGHT_BACKEND_IO_H_
OLDNEW
« no previous file with comments | « net/disk_cache/file_lock.cc ('k') | net/disk_cache/mem_backend_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698