| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 module content; | 5 module content.mojom; |
| 6 | 6 |
| 7 import "components/leveldb/public/interfaces/leveldb.mojom"; | 7 import "components/leveldb/public/interfaces/leveldb.mojom"; |
| 8 | 8 |
| 9 // Gives information about changes to a LevelDB database. | 9 // Gives information about changes to a LevelDB database. |
| 10 // The reason this is a parameter to DeleteAll and GetAll below, instead of | 10 // The reason this is a parameter to DeleteAll and GetAll below, instead of |
| 11 // being specified when opening a LevelDBWrapper, is to avoid the client getting | 11 // being specified when opening a LevelDBWrapper, is to avoid the client getting |
| 12 // callbacks for changes that have already been applied to its database that | 12 // callbacks for changes that have already been applied to its database that |
| 13 // it's fetching via GetAll or it's clearing via DeleteAll. | 13 // it's fetching via GetAll or it's clearing via DeleteAll. |
| 14 // In the methods below, |source| is a user-defined string which was passed to | 14 // In the methods below, |source| is a user-defined string which was passed to |
| 15 // the various LevelDBWrapper methods. | 15 // the various LevelDBWrapper methods. |
| (...skipping 28 matching lines...) Expand all Loading... |
| 44 => (leveldb.DatabaseError status); | 44 => (leveldb.DatabaseError status); |
| 45 | 45 |
| 46 // Returns the value of the |key|. | 46 // Returns the value of the |key|. |
| 47 Get(array<uint8> key) => (leveldb.DatabaseError status, array<uint8> value); | 47 Get(array<uint8> key) => (leveldb.DatabaseError status, array<uint8> value); |
| 48 | 48 |
| 49 // Only used with small databases. Returns all key/value pairs. | 49 // Only used with small databases. Returns all key/value pairs. |
| 50 [Sync] | 50 [Sync] |
| 51 GetAll(LevelDBObserver observer) | 51 GetAll(LevelDBObserver observer) |
| 52 => (leveldb.DatabaseError status, array<KeyValue> data); | 52 => (leveldb.DatabaseError status, array<KeyValue> data); |
| 53 }; | 53 }; |
| OLD | NEW |