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

Side by Side Diff: third_party/WebKit/Source/modules/indexeddb/IDBRequest.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) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google 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 28 matching lines...) Expand all
39 #include "modules/EventModules.h" 39 #include "modules/EventModules.h"
40 #include "modules/ModulesExport.h" 40 #include "modules/ModulesExport.h"
41 #include "modules/indexeddb/IDBAny.h" 41 #include "modules/indexeddb/IDBAny.h"
42 #include "modules/indexeddb/IDBTransaction.h" 42 #include "modules/indexeddb/IDBTransaction.h"
43 #include "modules/indexeddb/IndexedDB.h" 43 #include "modules/indexeddb/IndexedDB.h"
44 #include "platform/blob/BlobData.h" 44 #include "platform/blob/BlobData.h"
45 #include "platform/heap/Handle.h" 45 #include "platform/heap/Handle.h"
46 #include "public/platform/WebBlobInfo.h" 46 #include "public/platform/WebBlobInfo.h"
47 #include "public/platform/modules/indexeddb/WebIDBCursor.h" 47 #include "public/platform/modules/indexeddb/WebIDBCursor.h"
48 #include "public/platform/modules/indexeddb/WebIDBTypes.h" 48 #include "public/platform/modules/indexeddb/WebIDBTypes.h"
49 #include <memory>
50 49
51 namespace blink { 50 namespace blink {
52 51
53 class DOMException; 52 class DOMException;
54 class ExceptionState; 53 class ExceptionState;
55 class IDBCursor; 54 class IDBCursor;
56 struct IDBDatabaseMetadata; 55 struct IDBDatabaseMetadata;
57 class IDBValue; 56 class IDBValue;
58 57
59 class MODULES_EXPORT IDBRequest 58 class MODULES_EXPORT IDBRequest
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 90
92 DEFINE_ATTRIBUTE_EVENT_LISTENER(success); 91 DEFINE_ATTRIBUTE_EVENT_LISTENER(success);
93 DEFINE_ATTRIBUTE_EVENT_LISTENER(error); 92 DEFINE_ATTRIBUTE_EVENT_LISTENER(error);
94 93
95 void setCursorDetails(IndexedDB::CursorType, WebIDBCursorDirection); 94 void setCursorDetails(IndexedDB::CursorType, WebIDBCursorDirection);
96 void setPendingCursor(IDBCursor*); 95 void setPendingCursor(IDBCursor*);
97 void abort(); 96 void abort();
98 97
99 virtual void onError(DOMException*); 98 virtual void onError(DOMException*);
100 virtual void onSuccess(const Vector<String>&); 99 virtual void onSuccess(const Vector<String>&);
101 virtual void onSuccess(std::unique_ptr<WebIDBCursor>, IDBKey*, IDBKey* prima ryKey, PassRefPtr<IDBValue>); 100 virtual void onSuccess(PassOwnPtr<WebIDBCursor>, IDBKey*, IDBKey* primaryKey , PassRefPtr<IDBValue>);
102 virtual void onSuccess(IDBKey*); 101 virtual void onSuccess(IDBKey*);
103 virtual void onSuccess(PassRefPtr<IDBValue>); 102 virtual void onSuccess(PassRefPtr<IDBValue>);
104 virtual void onSuccess(const Vector<RefPtr<IDBValue>>&); 103 virtual void onSuccess(const Vector<RefPtr<IDBValue>>&);
105 virtual void onSuccess(int64_t); 104 virtual void onSuccess(int64_t);
106 virtual void onSuccess(); 105 virtual void onSuccess();
107 virtual void onSuccess(IDBKey*, IDBKey* primaryKey, PassRefPtr<IDBValue>); 106 virtual void onSuccess(IDBKey*, IDBKey* primaryKey, PassRefPtr<IDBValue>);
108 107
109 // Only IDBOpenDBRequest instances should receive these: 108 // Only IDBOpenDBRequest instances should receive these:
110 virtual void onBlocked(int64_t oldVersion) { ASSERT_NOT_REACHED(); } 109 virtual void onBlocked(int64_t oldVersion) { ASSERT_NOT_REACHED(); }
111 virtual void onUpgradeNeeded(int64_t oldVersion, std::unique_ptr<WebIDBDatab ase>, const IDBDatabaseMetadata&, WebIDBDataLoss, String dataLossMessage) { ASSE RT_NOT_REACHED(); } 110 virtual void onUpgradeNeeded(int64_t oldVersion, PassOwnPtr<WebIDBDatabase>, const IDBDatabaseMetadata&, WebIDBDataLoss, String dataLossMessage) { ASSERT_NO T_REACHED(); }
112 virtual void onSuccess(std::unique_ptr<WebIDBDatabase>, const IDBDatabaseMet adata&) { ASSERT_NOT_REACHED(); } 111 virtual void onSuccess(PassOwnPtr<WebIDBDatabase>, const IDBDatabaseMetadata &) { ASSERT_NOT_REACHED(); }
113 112
114 // ActiveScriptWrappable 113 // ActiveScriptWrappable
115 bool hasPendingActivity() const final; 114 bool hasPendingActivity() const final;
116 115
117 // ActiveDOMObject 116 // ActiveDOMObject
118 void stop() final; 117 void stop() final;
119 118
120 // EventTarget 119 // EventTarget
121 const AtomicString& interfaceName() const override; 120 const AtomicString& interfaceName() const override;
122 ExecutionContext* getExecutionContext() const final; 121 ExecutionContext* getExecutionContext() const final;
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 RefPtr<IDBValue> m_cursorValue; 168 RefPtr<IDBValue> m_cursorValue;
170 169
171 bool m_didFireUpgradeNeededEvent = false; 170 bool m_didFireUpgradeNeededEvent = false;
172 bool m_preventPropagation = false; 171 bool m_preventPropagation = false;
173 bool m_resultDirty = true; 172 bool m_resultDirty = true;
174 }; 173 };
175 174
176 } // namespace blink 175 } // namespace blink
177 176
178 #endif // IDBRequest_h 177 #endif // IDBRequest_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698