OLD | NEW |
(Empty) | |
| 1 |
| 2 class _IDBIndexImpl extends _DOMTypeBase implements IDBIndex { |
| 3 _IDBIndexImpl._wrap(ptr) : super._wrap(ptr); |
| 4 |
| 5 String get keyPath() => _wrap(_ptr.keyPath); |
| 6 |
| 7 bool get multiEntry() => _wrap(_ptr.multiEntry); |
| 8 |
| 9 String get name() => _wrap(_ptr.name); |
| 10 |
| 11 IDBObjectStore get objectStore() => _wrap(_ptr.objectStore); |
| 12 |
| 13 bool get unique() => _wrap(_ptr.unique); |
| 14 |
| 15 IDBRequest count([IDBKeyRange range = null]) { |
| 16 if (range === null) { |
| 17 return _wrap(_ptr.count()); |
| 18 } else { |
| 19 return _wrap(_ptr.count(_unwrap(range))); |
| 20 } |
| 21 } |
| 22 |
| 23 IDBRequest getObject(IDBKey key) { |
| 24 return _wrap(_ptr.getObject(_unwrap(key))); |
| 25 } |
| 26 |
| 27 IDBRequest getKey(IDBKey key) { |
| 28 return _wrap(_ptr.getKey(_unwrap(key))); |
| 29 } |
| 30 |
| 31 IDBRequest openCursor([IDBKeyRange range = null, int direction = null]) { |
| 32 if (range === null) { |
| 33 if (direction === null) { |
| 34 return _wrap(_ptr.openCursor()); |
| 35 } |
| 36 } else { |
| 37 if (direction === null) { |
| 38 return _wrap(_ptr.openCursor(_unwrap(range))); |
| 39 } else { |
| 40 return _wrap(_ptr.openCursor(_unwrap(range), _unwrap(direction))); |
| 41 } |
| 42 } |
| 43 throw "Incorrect number or type of arguments"; |
| 44 } |
| 45 |
| 46 IDBRequest openKeyCursor([IDBKeyRange range = null, int direction = null]) { |
| 47 if (range === null) { |
| 48 if (direction === null) { |
| 49 return _wrap(_ptr.openKeyCursor()); |
| 50 } |
| 51 } else { |
| 52 if (direction === null) { |
| 53 return _wrap(_ptr.openKeyCursor(_unwrap(range))); |
| 54 } else { |
| 55 return _wrap(_ptr.openKeyCursor(_unwrap(range), _unwrap(direction))); |
| 56 } |
| 57 } |
| 58 throw "Incorrect number or type of arguments"; |
| 59 } |
| 60 } |
OLD | NEW |