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

Side by Side Diff: third_party/WebKit/Source/modules/webdatabase/SQLTransactionBackend.h

Issue 2080623002: Revert "Remove OwnPtr from Blink." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 /* 1 /*
2 * Copyright (C) 2007, 2013 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 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 17 matching lines...) Expand all
28 #ifndef SQLTransactionBackend_h 28 #ifndef SQLTransactionBackend_h
29 #define SQLTransactionBackend_h 29 #define SQLTransactionBackend_h
30 30
31 #include "modules/webdatabase/DatabaseBasicTypes.h" 31 #include "modules/webdatabase/DatabaseBasicTypes.h"
32 #include "modules/webdatabase/SQLStatement.h" 32 #include "modules/webdatabase/SQLStatement.h"
33 #include "modules/webdatabase/SQLTransactionStateMachine.h" 33 #include "modules/webdatabase/SQLTransactionStateMachine.h"
34 #include "platform/heap/Handle.h" 34 #include "platform/heap/Handle.h"
35 #include "wtf/Deque.h" 35 #include "wtf/Deque.h"
36 #include "wtf/Forward.h" 36 #include "wtf/Forward.h"
37 #include "wtf/ThreadingPrimitives.h" 37 #include "wtf/ThreadingPrimitives.h"
38 #include <memory>
39 38
40 namespace blink { 39 namespace blink {
41 40
42 class Database; 41 class Database;
43 class SQLErrorData; 42 class SQLErrorData;
44 class SQLiteTransaction; 43 class SQLiteTransaction;
45 class SQLStatementBackend; 44 class SQLStatementBackend;
46 class SQLTransaction; 45 class SQLTransaction;
47 class SQLTransactionBackend; 46 class SQLTransactionBackend;
48 class SQLValue; 47 class SQLValue;
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 SQLTransactionState nextStateForTransactionError(); 103 SQLTransactionState nextStateForTransactionError();
105 SQLTransactionState runCurrentStatementAndGetNextState(); 104 SQLTransactionState runCurrentStatementAndGetNextState();
106 105
107 void getNextStatement(); 106 void getNextStatement();
108 107
109 CrossThreadPersistent<SQLTransaction> m_frontend; 108 CrossThreadPersistent<SQLTransaction> m_frontend;
110 CrossThreadPersistent<SQLStatementBackend> m_currentStatementBackend; 109 CrossThreadPersistent<SQLStatementBackend> m_currentStatementBackend;
111 110
112 Member<Database> m_database; 111 Member<Database> m_database;
113 Member<SQLTransactionWrapper> m_wrapper; 112 Member<SQLTransactionWrapper> m_wrapper;
114 std::unique_ptr<SQLErrorData> m_transactionError; 113 OwnPtr<SQLErrorData> m_transactionError;
115 114
116 bool m_hasCallback; 115 bool m_hasCallback;
117 bool m_hasSuccessCallback; 116 bool m_hasSuccessCallback;
118 bool m_hasErrorCallback; 117 bool m_hasErrorCallback;
119 bool m_shouldRetryCurrentStatement; 118 bool m_shouldRetryCurrentStatement;
120 bool m_modifiedDatabase; 119 bool m_modifiedDatabase;
121 bool m_lockAcquired; 120 bool m_lockAcquired;
122 bool m_readOnly; 121 bool m_readOnly;
123 bool m_hasVersionMismatch; 122 bool m_hasVersionMismatch;
124 123
125 Mutex m_statementMutex; 124 Mutex m_statementMutex;
126 Deque<CrossThreadPersistent<SQLStatementBackend>> m_statementQueue; 125 Deque<CrossThreadPersistent<SQLStatementBackend>> m_statementQueue;
127 126
128 std::unique_ptr<SQLiteTransaction> m_sqliteTransaction; 127 OwnPtr<SQLiteTransaction> m_sqliteTransaction;
129 }; 128 };
130 129
131 } // namespace blink 130 } // namespace blink
132 131
133 #endif // SQLTransactionBackend_h 132 #endif // SQLTransactionBackend_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698