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

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

Issue 2050123002: Remove OwnPtr from Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: First attempt to land. 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>
38 39
39 namespace blink { 40 namespace blink {
40 41
41 class Database; 42 class Database;
42 class SQLErrorData; 43 class SQLErrorData;
43 class SQLiteTransaction; 44 class SQLiteTransaction;
44 class SQLStatementBackend; 45 class SQLStatementBackend;
45 class SQLTransaction; 46 class SQLTransaction;
46 class SQLTransactionBackend; 47 class SQLTransactionBackend;
47 class SQLValue; 48 class SQLValue;
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 SQLTransactionState nextStateForTransactionError(); 104 SQLTransactionState nextStateForTransactionError();
104 SQLTransactionState runCurrentStatementAndGetNextState(); 105 SQLTransactionState runCurrentStatementAndGetNextState();
105 106
106 void getNextStatement(); 107 void getNextStatement();
107 108
108 CrossThreadPersistent<SQLTransaction> m_frontend; 109 CrossThreadPersistent<SQLTransaction> m_frontend;
109 CrossThreadPersistent<SQLStatementBackend> m_currentStatementBackend; 110 CrossThreadPersistent<SQLStatementBackend> m_currentStatementBackend;
110 111
111 Member<Database> m_database; 112 Member<Database> m_database;
112 Member<SQLTransactionWrapper> m_wrapper; 113 Member<SQLTransactionWrapper> m_wrapper;
113 OwnPtr<SQLErrorData> m_transactionError; 114 std::unique_ptr<SQLErrorData> m_transactionError;
114 115
115 bool m_hasCallback; 116 bool m_hasCallback;
116 bool m_hasSuccessCallback; 117 bool m_hasSuccessCallback;
117 bool m_hasErrorCallback; 118 bool m_hasErrorCallback;
118 bool m_shouldRetryCurrentStatement; 119 bool m_shouldRetryCurrentStatement;
119 bool m_modifiedDatabase; 120 bool m_modifiedDatabase;
120 bool m_lockAcquired; 121 bool m_lockAcquired;
121 bool m_readOnly; 122 bool m_readOnly;
122 bool m_hasVersionMismatch; 123 bool m_hasVersionMismatch;
123 124
124 Mutex m_statementMutex; 125 Mutex m_statementMutex;
125 Deque<CrossThreadPersistent<SQLStatementBackend>> m_statementQueue; 126 Deque<CrossThreadPersistent<SQLStatementBackend>> m_statementQueue;
126 127
127 OwnPtr<SQLiteTransaction> m_sqliteTransaction; 128 std::unique_ptr<SQLiteTransaction> m_sqliteTransaction;
128 }; 129 };
129 130
130 } // namespace blink 131 } // namespace blink
131 132
132 #endif // SQLTransactionBackend_h 133 #endif // SQLTransactionBackend_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698