OLD | NEW |
(Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef IDBDatabaseObserverImpl_h |
| 6 #define IDBDatabaseObserverImpl_h |
| 7 |
| 8 #include "Source/modules/indexeddb/indexed_db.mojom-blink.h" |
| 9 #include "bindings/core/v8/ScriptValue.h" |
| 10 #include "bindings/core/v8/ScriptWrappable.h" |
| 11 #include "mojo/public/cpp/bindings/binding.h" |
| 12 |
| 13 namespace blink { |
| 14 |
| 15 class IDBOpenDBRequest; |
| 16 |
| 17 class IDBDatabaseObserverImpl : WTF_NON_EXPORTED_BASE(public indexed_db::mojom::
blink::DatabaseObserver) |
| 18 { |
| 19 public: |
| 20 static indexed_db::mojom::blink::DatabaseObserverPtr Create(IDBOpenDBRequest
*); |
| 21 |
| 22 private: |
| 23 IDBDatabaseObserverImpl(indexed_db::mojom::blink::DatabaseObserverRequest, I
DBOpenDBRequest*); |
| 24 ~IDBDatabaseObserverImpl(); |
| 25 DECLARE_TRACE(); |
| 26 |
| 27 // indexed_db::mojom::blink::DatabaseObserver: |
| 28 void OnTransactionAborted(int64_t hostTransactionId, indexed_db::mojom::blin
k::ErrorInfoPtr) override; |
| 29 void OnTransactionCompleted(int64_t hostTransactionId) override; |
| 30 void OnForcedClosed() override; |
| 31 void OnVersionChange(int64_t oldVersion, int64_t newVersion) override; |
| 32 |
| 33 WeakMember<IDBOpenDBRequest> m_request; |
| 34 |
| 35 mojo::Binding<indexed_db::mojom::blink::DatabaseObserver> m_binding; |
| 36 |
| 37 DISALLOW_COPY_AND_ASSIGN(IDBDatabaseObserverImpl); |
| 38 }; |
| 39 |
| 40 } // namespace blink |
| 41 |
| 42 #endif // IDBDatabaseObserverImpl_h |
OLD | NEW |