| OLD | NEW |
| (Empty) | |
| 1 // Copyright 2017 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 STORAGE_BROWSER_BLOB_BLOB_IMPL_H_ |
| 6 #define STORAGE_BROWSER_BLOB_BLOB_IMPL_H_ |
| 7 |
| 8 #include "mojo/public/cpp/bindings/binding_set.h" |
| 9 #include "third_party/WebKit/public/platform/blobs.mojom.h" |
| 10 |
| 11 namespace storage { |
| 12 |
| 13 class BlobDataHandle; |
| 14 |
| 15 // Self destroys when no more bindings exist. |
| 16 class BlobImpl : public mojom::Blob { |
| 17 public: |
| 18 BlobImpl(std::unique_ptr<BlobDataHandle> handle, mojom::BlobRequest request); |
| 19 |
| 20 void Clone(mojom::BlobRequest request) override; |
| 21 void InternalGetUUID(InternalGetUUIDCallback callback) override; |
| 22 |
| 23 private: |
| 24 ~BlobImpl() override; |
| 25 void OnConnectionError(); |
| 26 |
| 27 std::unique_ptr<BlobDataHandle> handle_; |
| 28 |
| 29 mojo::BindingSet<mojom::Blob> bindings_; |
| 30 }; |
| 31 |
| 32 } // namespace storage |
| 33 |
| 34 #endif // STORAGE_BROWSER_BLOB_BLOB_IMPL_H_ |
| OLD | NEW |