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

Side by Side Diff: Source/modules/webdatabase/DatabaseTask.h

Issue 198213005: Oilpan: Prepare to move AbstractSQLTransactionBackend, SQLTransactionBackend, and SQLTransactionCoo… (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007, 2008, 2013 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008, 2013 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 #if !LOG_DISABLED 135 #if !LOG_DISABLED
136 virtual const char* debugTaskName() const OVERRIDE; 136 virtual const char* debugTaskName() const OVERRIDE;
137 #endif 137 #endif
138 }; 138 };
139 139
140 class DatabaseBackend::DatabaseTransactionTask FINAL : public DatabaseTask { 140 class DatabaseBackend::DatabaseTransactionTask FINAL : public DatabaseTask {
141 public: 141 public:
142 virtual ~DatabaseTransactionTask(); 142 virtual ~DatabaseTransactionTask();
143 143
144 // Transaction task is never synchronous, so no 'synchronizer' parameter. 144 // Transaction task is never synchronous, so no 'synchronizer' parameter.
145 static PassOwnPtr<DatabaseTransactionTask> create(PassRefPtr<SQLTransactionB ackend> transaction) 145 static PassOwnPtr<DatabaseTransactionTask> create(PassRefPtrWillBeRawPtr<SQL TransactionBackend> transaction)
146 { 146 {
147 return adoptPtr(new DatabaseTransactionTask(transaction)); 147 return adoptPtr(new DatabaseTransactionTask(transaction));
148 } 148 }
149 149
150 SQLTransactionBackend* transaction() const { return m_transaction.get(); } 150 SQLTransactionBackend* transaction() const { return m_transaction.get(); }
151 151
152 private: 152 private:
153 explicit DatabaseTransactionTask(PassRefPtr<SQLTransactionBackend>); 153 explicit DatabaseTransactionTask(PassRefPtrWillBeRawPtr<SQLTransactionBacken d>);
154 154
155 virtual void doPerformTask() OVERRIDE; 155 virtual void doPerformTask() OVERRIDE;
156 virtual void taskCancelled() OVERRIDE; 156 virtual void taskCancelled() OVERRIDE;
157 #if !LOG_DISABLED 157 #if !LOG_DISABLED
158 virtual const char* debugTaskName() const OVERRIDE; 158 virtual const char* debugTaskName() const OVERRIDE;
159 #endif 159 #endif
160 160
161 RefPtr<SQLTransactionBackend> m_transaction; 161 RefPtrWillBeCrossThreadPersistent<SQLTransactionBackend> m_transaction;
162 }; 162 };
163 163
164 class DatabaseBackend::DatabaseTableNamesTask FINAL : public DatabaseTask { 164 class DatabaseBackend::DatabaseTableNamesTask FINAL : public DatabaseTask {
165 public: 165 public:
166 static PassOwnPtr<DatabaseTableNamesTask> create(DatabaseBackend* db, Databa seTaskSynchronizer* synchronizer, Vector<String>& names) 166 static PassOwnPtr<DatabaseTableNamesTask> create(DatabaseBackend* db, Databa seTaskSynchronizer* synchronizer, Vector<String>& names)
167 { 167 {
168 return adoptPtr(new DatabaseTableNamesTask(db, synchronizer, names)); 168 return adoptPtr(new DatabaseTableNamesTask(db, synchronizer, names));
169 } 169 }
170 170
171 private: 171 private:
172 DatabaseTableNamesTask(DatabaseBackend*, DatabaseTaskSynchronizer*, Vector<S tring>& names); 172 DatabaseTableNamesTask(DatabaseBackend*, DatabaseTaskSynchronizer*, Vector<S tring>& names);
173 173
174 virtual void doPerformTask() OVERRIDE; 174 virtual void doPerformTask() OVERRIDE;
175 #if !LOG_DISABLED 175 #if !LOG_DISABLED
176 virtual const char* debugTaskName() const OVERRIDE; 176 virtual const char* debugTaskName() const OVERRIDE;
177 #endif 177 #endif
178 178
179 Vector<String>& m_tableNames; 179 Vector<String>& m_tableNames;
180 }; 180 };
181 181
182 } // namespace WebCore 182 } // namespace WebCore
183 183
184 #endif // DatabaseTask_h 184 #endif // DatabaseTask_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698