| OLD | NEW |
| 1 library indexed_db; | 1 library indexed_db; |
| 2 | 2 |
| 3 import 'dart:html'; | 3 import 'dart:html'; |
| 4 import 'dart:html_common'; | 4 import 'dart:html_common'; |
| 5 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 5 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 6 // for details. All rights reserved. Use of this source code is governed by a | 6 // for details. All rights reserved. Use of this source code is governed by a |
| 7 // BSD-style license that can be found in the LICENSE file. | 7 // BSD-style license that can be found in the LICENSE file. |
| 8 | 8 |
| 9 // DO NOT EDIT | 9 // DO NOT EDIT |
| 10 // Auto-generated dart:svg library. | 10 // Auto-generated dart:svg library. |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 125 | 125 |
| 126 | 126 |
| 127 const String _idbKey = '=List|=Object|num|String'; // TODO(sra): Add Date. | 127 const String _idbKey = '=List|=Object|num|String'; // TODO(sra): Add Date. |
| 128 const _annotation_Creates_IDBKey = const Creates(_idbKey); | 128 const _annotation_Creates_IDBKey = const Creates(_idbKey); |
| 129 const _annotation_Returns_IDBKey = const Returns(_idbKey); | 129 const _annotation_Returns_IDBKey = const Returns(_idbKey); |
| 130 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 130 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 131 // for details. All rights reserved. Use of this source code is governed by a | 131 // for details. All rights reserved. Use of this source code is governed by a |
| 132 // BSD-style license that can be found in the LICENSE file. | 132 // BSD-style license that can be found in the LICENSE file. |
| 133 | 133 |
| 134 | 134 |
| 135 /// @domName IDBCursor; @docsEditable true | 135 /// @docsEditable true |
| 136 @DomName("IDBCursor") |
| 136 class Cursor native "*IDBCursor" { | 137 class Cursor native "*IDBCursor" { |
| 137 | 138 |
| 138 /// @domName IDBCursor.direction; @docsEditable true | 139 /// @docsEditable true |
| 140 @DomName("IDBCursor.direction") |
| 139 final String direction; | 141 final String direction; |
| 140 | 142 |
| 141 /// @domName IDBCursor.key; @docsEditable true | 143 /// @docsEditable true |
| 142 @_annotation_Creates_IDBKey @_annotation_Returns_IDBKey | 144 @DomName("IDBCursor.key") @_annotation_Creates_IDBKey @_annotation_Returns_IDB
Key |
| 143 final Object key; | 145 final Object key; |
| 144 | 146 |
| 145 /// @domName IDBCursor.primaryKey; @docsEditable true | 147 /// @docsEditable true |
| 148 @DomName("IDBCursor.primaryKey") |
| 146 final Object primaryKey; | 149 final Object primaryKey; |
| 147 | 150 |
| 148 /// @domName IDBCursor.source; @docsEditable true | 151 /// @docsEditable true |
| 152 @DomName("IDBCursor.source") |
| 149 final dynamic source; | 153 final dynamic source; |
| 150 | 154 |
| 151 /// @domName IDBCursor.advance; @docsEditable true | 155 /// @docsEditable true |
| 156 @DomName("IDBCursor.advance") |
| 152 void advance(int count) native; | 157 void advance(int count) native; |
| 153 | 158 |
| 154 /// @domName IDBCursor.continueFunction; @docsEditable true | 159 /// @docsEditable true |
| 155 void continueFunction([/*IDBKey*/ key]) { | 160 void continueFunction([/*IDBKey*/ key]) { |
| 156 if (?key) { | 161 if (?key) { |
| 157 var key_1 = _convertDartToNative_IDBKey(key); | 162 var key_1 = _convertDartToNative_IDBKey(key); |
| 158 _continueFunction_1(key_1); | 163 _continueFunction_1(key_1); |
| 159 return; | 164 return; |
| 160 } | 165 } |
| 161 _continueFunction_2(); | 166 _continueFunction_2(); |
| 162 return; | 167 return; |
| 163 } | 168 } |
| 164 @JSName('continue') | 169 @JSName('continue') |
| 170 @DomName("IDBCursor.continue") |
| 165 void _continueFunction_1(key) native; | 171 void _continueFunction_1(key) native; |
| 166 @JSName('continue') | 172 @JSName('continue') |
| 173 @DomName("IDBCursor.continue") |
| 167 void _continueFunction_2() native; | 174 void _continueFunction_2() native; |
| 168 | 175 |
| 169 /// @domName IDBCursor.delete; @docsEditable true | 176 /// @docsEditable true |
| 177 @DomName("IDBCursor.delete") |
| 170 Request delete() native; | 178 Request delete() native; |
| 171 | 179 |
| 172 /// @domName IDBCursor.update; @docsEditable true | 180 /// @docsEditable true |
| 173 Request update(/*any*/ value) { | 181 Request update(/*any*/ value) { |
| 174 var value_1 = convertDartToNative_SerializedScriptValue(value); | 182 var value_1 = convertDartToNative_SerializedScriptValue(value); |
| 175 return _update_1(value_1); | 183 return _update_1(value_1); |
| 176 } | 184 } |
| 177 @JSName('update') | 185 @JSName('update') |
| 186 @DomName("IDBCursor.update") |
| 178 Request _update_1(value) native; | 187 Request _update_1(value) native; |
| 179 } | 188 } |
| 180 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 189 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 181 // for details. All rights reserved. Use of this source code is governed by a | 190 // for details. All rights reserved. Use of this source code is governed by a |
| 182 // BSD-style license that can be found in the LICENSE file. | 191 // BSD-style license that can be found in the LICENSE file. |
| 183 | 192 |
| 184 | 193 |
| 185 /// @domName IDBCursorWithValue; @docsEditable true | 194 /// @docsEditable true |
| 195 @DomName("IDBCursorWithValue") |
| 186 class CursorWithValue extends Cursor native "*IDBCursorWithValue" { | 196 class CursorWithValue extends Cursor native "*IDBCursorWithValue" { |
| 187 | 197 |
| 188 /// @domName IDBCursorWithValue.value; @docsEditable true | 198 /// @docsEditable true |
| 189 @annotation_Creates_SerializedScriptValue @annotation_Returns_SerializedScript
Value | 199 @DomName("IDBCursorWithValue.value") @annotation_Creates_SerializedScriptValue
@annotation_Returns_SerializedScriptValue |
| 190 final Object value; | 200 final Object value; |
| 191 } | 201 } |
| 192 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 202 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 193 // for details. All rights reserved. Use of this source code is governed by a | 203 // for details. All rights reserved. Use of this source code is governed by a |
| 194 // BSD-style license that can be found in the LICENSE file. | 204 // BSD-style license that can be found in the LICENSE file. |
| 195 | 205 |
| 196 | 206 |
| 197 /// @domName IDBDatabase | 207 @DomName("IDBDatabase") |
| 198 class Database extends EventTarget native "*IDBDatabase" { | 208 class Database extends EventTarget native "*IDBDatabase" { |
| 199 | 209 |
| 200 Transaction transaction(storeName_OR_storeNames, String mode) { | 210 Transaction transaction(storeName_OR_storeNames, String mode) { |
| 201 if (mode != 'readonly' && mode != 'readwrite') { | 211 if (mode != 'readonly' && mode != 'readwrite') { |
| 202 throw new ArgumentError(mode); | 212 throw new ArgumentError(mode); |
| 203 } | 213 } |
| 204 | 214 |
| 205 // TODO(sra): Ensure storeName_OR_storeNames is a string or List<String>, | 215 // TODO(sra): Ensure storeName_OR_storeNames is a string or List<String>, |
| 206 // and copy to JavaScript array if necessary. | 216 // and copy to JavaScript array if necessary. |
| 207 | 217 |
| 208 // Try and create a transaction with a string mode. Browsers that expect a | 218 // Try and create a transaction with a string mode. Browsers that expect a |
| 209 // numeric mode tend to convert the string into a number. This fails | 219 // numeric mode tend to convert the string into a number. This fails |
| 210 // silently, resulting in zero ('readonly'). | 220 // silently, resulting in zero ('readonly'). |
| 211 return _transaction(storeName_OR_storeNames, mode); | 221 return _transaction(storeName_OR_storeNames, mode); |
| 212 } | 222 } |
| 213 | 223 |
| 214 @JSName('transaction') | 224 @JSName('transaction') |
| 215 Transaction _transaction(stores, mode) native; | 225 Transaction _transaction(stores, mode) native; |
| 216 | 226 |
| 217 | 227 |
| 218 /// @domName EventTarget.addEventListener, EventTarget.removeEventListener, Ev
entTarget.dispatchEvent; @docsEditable true | 228 /// @docsEditable true |
| 229 @DomName("EventTarget.addEventListener, EventTarget.removeEventListener, Event
Target.dispatchEvent") |
| 219 DatabaseEvents get on => | 230 DatabaseEvents get on => |
| 220 new DatabaseEvents(this); | 231 new DatabaseEvents(this); |
| 221 | 232 |
| 222 /// @domName IDBDatabase.name; @docsEditable true | 233 /// @docsEditable true |
| 234 @DomName("IDBDatabase.name") |
| 223 final String name; | 235 final String name; |
| 224 | 236 |
| 225 /// @domName IDBDatabase.objectStoreNames; @docsEditable true | 237 /// @docsEditable true |
| 238 @DomName("IDBDatabase.objectStoreNames") |
| 226 @Returns('DomStringList') @Creates('DomStringList') | 239 @Returns('DomStringList') @Creates('DomStringList') |
| 227 final List<String> objectStoreNames; | 240 final List<String> objectStoreNames; |
| 228 | 241 |
| 229 /// @domName IDBDatabase.version; @docsEditable true | 242 /// @docsEditable true |
| 243 @DomName("IDBDatabase.version") |
| 230 final dynamic version; | 244 final dynamic version; |
| 231 | 245 |
| 232 /// @domName IDBDatabase.addEventListener; @docsEditable true | 246 /// @docsEditable true |
| 233 @JSName('addEventListener') | 247 @JSName('addEventListener') |
| 248 @DomName("IDBDatabase.addEventListener") |
| 234 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu
re]) native; | 249 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu
re]) native; |
| 235 | 250 |
| 236 /// @domName IDBDatabase.close; @docsEditable true | 251 /// @docsEditable true |
| 252 @DomName("IDBDatabase.close") |
| 237 void close() native; | 253 void close() native; |
| 238 | 254 |
| 239 /// @domName IDBDatabase.createObjectStore; @docsEditable true | 255 /// @docsEditable true |
| 240 ObjectStore createObjectStore(String name, [Map options]) { | 256 ObjectStore createObjectStore(String name, [Map options]) { |
| 241 if (?options) { | 257 if (?options) { |
| 242 var options_1 = convertDartToNative_Dictionary(options); | 258 var options_1 = convertDartToNative_Dictionary(options); |
| 243 return _createObjectStore_1(name, options_1); | 259 return _createObjectStore_1(name, options_1); |
| 244 } | 260 } |
| 245 return _createObjectStore_2(name); | 261 return _createObjectStore_2(name); |
| 246 } | 262 } |
| 247 @JSName('createObjectStore') | 263 @JSName('createObjectStore') |
| 264 @DomName("IDBDatabase.createObjectStore") |
| 248 ObjectStore _createObjectStore_1(name, options) native; | 265 ObjectStore _createObjectStore_1(name, options) native; |
| 249 @JSName('createObjectStore') | 266 @JSName('createObjectStore') |
| 267 @DomName("IDBDatabase.createObjectStore") |
| 250 ObjectStore _createObjectStore_2(name) native; | 268 ObjectStore _createObjectStore_2(name) native; |
| 251 | 269 |
| 252 /// @domName IDBDatabase.deleteObjectStore; @docsEditable true | 270 /// @docsEditable true |
| 271 @DomName("IDBDatabase.deleteObjectStore") |
| 253 void deleteObjectStore(String name) native; | 272 void deleteObjectStore(String name) native; |
| 254 | 273 |
| 255 /// @domName IDBDatabase.dispatchEvent; @docsEditable true | 274 /// @docsEditable true |
| 256 @JSName('dispatchEvent') | 275 @JSName('dispatchEvent') |
| 276 @DomName("IDBDatabase.dispatchEvent") |
| 257 bool $dom_dispatchEvent(Event evt) native; | 277 bool $dom_dispatchEvent(Event evt) native; |
| 258 | 278 |
| 259 /// @domName IDBDatabase.removeEventListener; @docsEditable true | 279 /// @docsEditable true |
| 260 @JSName('removeEventListener') | 280 @JSName('removeEventListener') |
| 281 @DomName("IDBDatabase.removeEventListener") |
| 261 void $dom_removeEventListener(String type, EventListener listener, [bool useCa
pture]) native; | 282 void $dom_removeEventListener(String type, EventListener listener, [bool useCa
pture]) native; |
| 262 } | 283 } |
| 263 | 284 |
| 264 /// @docsEditable true | 285 /// @docsEditable true |
| 265 class DatabaseEvents extends Events { | 286 class DatabaseEvents extends Events { |
| 266 /// @docsEditable true | 287 /// @docsEditable true |
| 267 DatabaseEvents(EventTarget _ptr) : super(_ptr); | 288 DatabaseEvents(EventTarget _ptr) : super(_ptr); |
| 268 | 289 |
| 269 /// @docsEditable true | 290 /// @docsEditable true |
| 270 EventListenerList get abort => this['abort']; | 291 EventListenerList get abort => this['abort']; |
| 271 | 292 |
| 272 /// @docsEditable true | 293 /// @docsEditable true |
| 273 EventListenerList get error => this['error']; | 294 EventListenerList get error => this['error']; |
| 274 | 295 |
| 275 /// @docsEditable true | 296 /// @docsEditable true |
| 276 EventListenerList get versionChange => this['versionchange']; | 297 EventListenerList get versionChange => this['versionchange']; |
| 277 } | 298 } |
| 278 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 299 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 279 // for details. All rights reserved. Use of this source code is governed by a | 300 // for details. All rights reserved. Use of this source code is governed by a |
| 280 // BSD-style license that can be found in the LICENSE file. | 301 // BSD-style license that can be found in the LICENSE file. |
| 281 | 302 |
| 282 | 303 |
| 283 /// @domName IDBFactory | 304 |
| 305 @DomName("IDBFactory") |
| 284 @SupportedBrowser(SupportedBrowser.CHROME) | 306 @SupportedBrowser(SupportedBrowser.CHROME) |
| 285 @SupportedBrowser(SupportedBrowser.FIREFOX, '15') | 307 @SupportedBrowser(SupportedBrowser.FIREFOX, '15') |
| 286 @SupportedBrowser(SupportedBrowser.IE, '10') | 308 @SupportedBrowser(SupportedBrowser.IE, '10') |
| 287 @Experimental() | 309 @Experimental() |
| 288 class IdbFactory native "*IDBFactory" { | 310 class IdbFactory native "*IDBFactory" { |
| 289 /** | 311 /** |
| 290 * Checks to see if Indexed DB is supported on the current platform. | 312 * Checks to see if Indexed DB is supported on the current platform. |
| 291 */ | 313 */ |
| 292 static bool get supported { | 314 static bool get supported { |
| 293 return JS('bool', | 315 return JS('bool', |
| 294 '!!(window.indexedDB || ' | 316 '!!(window.indexedDB || ' |
| 295 'window.webkitIndexedDB || ' | 317 'window.webkitIndexedDB || ' |
| 296 'window.mozIndexedDB)'); | 318 'window.mozIndexedDB)'); |
| 297 } | 319 } |
| 298 | 320 |
| 299 | 321 |
| 300 /// @domName IDBFactory.cmp; @docsEditable true | 322 /// @docsEditable true |
| 301 int cmp(/*IDBKey*/ first, /*IDBKey*/ second) { | 323 int cmp(/*IDBKey*/ first, /*IDBKey*/ second) { |
| 302 var first_1 = _convertDartToNative_IDBKey(first); | 324 var first_1 = _convertDartToNative_IDBKey(first); |
| 303 var second_2 = _convertDartToNative_IDBKey(second); | 325 var second_2 = _convertDartToNative_IDBKey(second); |
| 304 return _cmp_1(first_1, second_2); | 326 return _cmp_1(first_1, second_2); |
| 305 } | 327 } |
| 306 @JSName('cmp') | 328 @JSName('cmp') |
| 329 @DomName("IDBFactory.cmp") |
| 307 int _cmp_1(first, second) native; | 330 int _cmp_1(first, second) native; |
| 308 | 331 |
| 309 /// @domName IDBFactory.deleteDatabase; @docsEditable true | 332 /// @docsEditable true |
| 333 @DomName("IDBFactory.deleteDatabase") |
| 310 VersionChangeRequest deleteDatabase(String name) native; | 334 VersionChangeRequest deleteDatabase(String name) native; |
| 311 | 335 |
| 312 /// @domName IDBFactory.open; @docsEditable true | 336 /// @docsEditable true |
| 313 @Returns('Request') @Creates('Request') @Creates('Database') | 337 @DomName("IDBFactory.open") @Returns('Request') @Creates('Request') @Creates('
Database') |
| 314 OpenDBRequest open(String name, [int version]) native; | 338 OpenDBRequest open(String name, [int version]) native; |
| 315 | 339 |
| 316 /// @domName IDBFactory.webkitGetDatabaseNames; @docsEditable true | 340 /// @docsEditable true |
| 341 @DomName("IDBFactory.webkitGetDatabaseNames") |
| 317 Request webkitGetDatabaseNames() native; | 342 Request webkitGetDatabaseNames() native; |
| 318 | 343 |
| 319 } | 344 } |
| 320 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 345 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 321 // for details. All rights reserved. Use of this source code is governed by a | 346 // for details. All rights reserved. Use of this source code is governed by a |
| 322 // BSD-style license that can be found in the LICENSE file. | 347 // BSD-style license that can be found in the LICENSE file. |
| 323 | 348 |
| 324 | 349 |
| 325 /// @domName IDBIndex; @docsEditable true | 350 /// @docsEditable true |
| 351 @DomName("IDBIndex") |
| 326 class Index native "*IDBIndex" { | 352 class Index native "*IDBIndex" { |
| 327 | 353 |
| 328 /// @domName IDBIndex.keyPath; @docsEditable true | 354 /// @docsEditable true |
| 355 @DomName("IDBIndex.keyPath") |
| 329 final dynamic keyPath; | 356 final dynamic keyPath; |
| 330 | 357 |
| 331 /// @domName IDBIndex.multiEntry; @docsEditable true | 358 /// @docsEditable true |
| 359 @DomName("IDBIndex.multiEntry") |
| 332 final bool multiEntry; | 360 final bool multiEntry; |
| 333 | 361 |
| 334 /// @domName IDBIndex.name; @docsEditable true | 362 /// @docsEditable true |
| 363 @DomName("IDBIndex.name") |
| 335 final String name; | 364 final String name; |
| 336 | 365 |
| 337 /// @domName IDBIndex.objectStore; @docsEditable true | 366 /// @docsEditable true |
| 367 @DomName("IDBIndex.objectStore") |
| 338 final ObjectStore objectStore; | 368 final ObjectStore objectStore; |
| 339 | 369 |
| 340 /// @domName IDBIndex.unique; @docsEditable true | 370 /// @docsEditable true |
| 371 @DomName("IDBIndex.unique") |
| 341 final bool unique; | 372 final bool unique; |
| 342 | 373 |
| 343 /// @domName IDBIndex.count; @docsEditable true | 374 /// @docsEditable true |
| 344 Request count([key_OR_range]) { | 375 Request count([key_OR_range]) { |
| 345 if (!?key_OR_range) { | 376 if (!?key_OR_range) { |
| 346 return _count_1(); | 377 return _count_1(); |
| 347 } | 378 } |
| 348 if ((key_OR_range is KeyRange || key_OR_range == null)) { | 379 if ((key_OR_range is KeyRange || key_OR_range == null)) { |
| 349 return _count_2(key_OR_range); | 380 return _count_2(key_OR_range); |
| 350 } | 381 } |
| 351 if (?key_OR_range) { | 382 if (?key_OR_range) { |
| 352 var key_1 = _convertDartToNative_IDBKey(key_OR_range); | 383 var key_1 = _convertDartToNative_IDBKey(key_OR_range); |
| 353 return _count_3(key_1); | 384 return _count_3(key_1); |
| 354 } | 385 } |
| 355 throw new ArgumentError("Incorrect number or type of arguments"); | 386 throw new ArgumentError("Incorrect number or type of arguments"); |
| 356 } | 387 } |
| 357 @JSName('count') | 388 @JSName('count') |
| 389 @DomName("IDBIndex.count") |
| 358 Request _count_1() native; | 390 Request _count_1() native; |
| 359 @JSName('count') | 391 @JSName('count') |
| 392 @DomName("IDBIndex.count") |
| 360 Request _count_2(KeyRange range) native; | 393 Request _count_2(KeyRange range) native; |
| 361 @JSName('count') | 394 @JSName('count') |
| 395 @DomName("IDBIndex.count") |
| 362 Request _count_3(key) native; | 396 Request _count_3(key) native; |
| 363 | 397 |
| 364 /// @domName IDBIndex.get; @docsEditable true | 398 /// @docsEditable true |
| 365 Request get(key) { | 399 Request get(key) { |
| 366 if ((key is KeyRange || key == null)) { | 400 if ((key is KeyRange || key == null)) { |
| 367 return _get_1(key); | 401 return _get_1(key); |
| 368 } | 402 } |
| 369 if (?key) { | 403 if (?key) { |
| 370 var key_1 = _convertDartToNative_IDBKey(key); | 404 var key_1 = _convertDartToNative_IDBKey(key); |
| 371 return _get_2(key_1); | 405 return _get_2(key_1); |
| 372 } | 406 } |
| 373 throw new ArgumentError("Incorrect number or type of arguments"); | 407 throw new ArgumentError("Incorrect number or type of arguments"); |
| 374 } | 408 } |
| 375 @JSName('get') | 409 @JSName('get') |
| 376 @Returns('Request') @Creates('Request') @annotation_Creates_SerializedScriptVa
lue | 410 @DomName("IDBIndex.get") @Returns('Request') @Creates('Request') @annotation_C
reates_SerializedScriptValue |
| 377 Request _get_1(KeyRange key) native; | 411 Request _get_1(KeyRange key) native; |
| 378 @JSName('get') | 412 @JSName('get') |
| 379 @Returns('Request') @Creates('Request') @annotation_Creates_SerializedScriptVa
lue | 413 @DomName("IDBIndex.get") @Returns('Request') @Creates('Request') @annotation_C
reates_SerializedScriptValue |
| 380 Request _get_2(key) native; | 414 Request _get_2(key) native; |
| 381 | 415 |
| 382 /// @domName IDBIndex.getKey; @docsEditable true | 416 /// @docsEditable true |
| 383 Request getKey(key) { | 417 Request getKey(key) { |
| 384 if ((key is KeyRange || key == null)) { | 418 if ((key is KeyRange || key == null)) { |
| 385 return _getKey_1(key); | 419 return _getKey_1(key); |
| 386 } | 420 } |
| 387 if (?key) { | 421 if (?key) { |
| 388 var key_1 = _convertDartToNative_IDBKey(key); | 422 var key_1 = _convertDartToNative_IDBKey(key); |
| 389 return _getKey_2(key_1); | 423 return _getKey_2(key_1); |
| 390 } | 424 } |
| 391 throw new ArgumentError("Incorrect number or type of arguments"); | 425 throw new ArgumentError("Incorrect number or type of arguments"); |
| 392 } | 426 } |
| 393 @JSName('getKey') | 427 @JSName('getKey') |
| 394 @Returns('Request') @Creates('Request') @annotation_Creates_SerializedScriptVa
lue @Creates('ObjectStore') | 428 @DomName("IDBIndex.getKey") @Returns('Request') @Creates('Request') @annotatio
n_Creates_SerializedScriptValue @Creates('ObjectStore') |
| 395 Request _getKey_1(KeyRange key) native; | 429 Request _getKey_1(KeyRange key) native; |
| 396 @JSName('getKey') | 430 @JSName('getKey') |
| 397 @Returns('Request') @Creates('Request') @annotation_Creates_SerializedScriptVa
lue @Creates('ObjectStore') | 431 @DomName("IDBIndex.getKey") @Returns('Request') @Creates('Request') @annotatio
n_Creates_SerializedScriptValue @Creates('ObjectStore') |
| 398 Request _getKey_2(key) native; | 432 Request _getKey_2(key) native; |
| 399 | 433 |
| 400 /// @domName IDBIndex.openCursor; @docsEditable true | 434 /// @docsEditable true |
| 401 Request openCursor([key_OR_range, String direction]) { | 435 Request openCursor([key_OR_range, String direction]) { |
| 402 if (!?key_OR_range && | 436 if (!?key_OR_range && |
| 403 !?direction) { | 437 !?direction) { |
| 404 return _openCursor_1(); | 438 return _openCursor_1(); |
| 405 } | 439 } |
| 406 if ((key_OR_range is KeyRange || key_OR_range == null) && | 440 if ((key_OR_range is KeyRange || key_OR_range == null) && |
| 407 !?direction) { | 441 !?direction) { |
| 408 return _openCursor_2(key_OR_range); | 442 return _openCursor_2(key_OR_range); |
| 409 } | 443 } |
| 410 if ((key_OR_range is KeyRange || key_OR_range == null)) { | 444 if ((key_OR_range is KeyRange || key_OR_range == null)) { |
| 411 return _openCursor_3(key_OR_range, direction); | 445 return _openCursor_3(key_OR_range, direction); |
| 412 } | 446 } |
| 413 if (?key_OR_range && | 447 if (?key_OR_range && |
| 414 !?direction) { | 448 !?direction) { |
| 415 var key_1 = _convertDartToNative_IDBKey(key_OR_range); | 449 var key_1 = _convertDartToNative_IDBKey(key_OR_range); |
| 416 return _openCursor_4(key_1); | 450 return _openCursor_4(key_1); |
| 417 } | 451 } |
| 418 if (?key_OR_range) { | 452 if (?key_OR_range) { |
| 419 var key_2 = _convertDartToNative_IDBKey(key_OR_range); | 453 var key_2 = _convertDartToNative_IDBKey(key_OR_range); |
| 420 return _openCursor_5(key_2, direction); | 454 return _openCursor_5(key_2, direction); |
| 421 } | 455 } |
| 422 throw new ArgumentError("Incorrect number or type of arguments"); | 456 throw new ArgumentError("Incorrect number or type of arguments"); |
| 423 } | 457 } |
| 424 @JSName('openCursor') | 458 @JSName('openCursor') |
| 425 @Returns('Request') @Creates('Request') @Creates('Cursor') | 459 @DomName("IDBIndex.openCursor") @Returns('Request') @Creates('Request') @Creat
es('Cursor') |
| 426 Request _openCursor_1() native; | 460 Request _openCursor_1() native; |
| 427 @JSName('openCursor') | 461 @JSName('openCursor') |
| 428 @Returns('Request') @Creates('Request') @Creates('Cursor') | 462 @DomName("IDBIndex.openCursor") @Returns('Request') @Creates('Request') @Creat
es('Cursor') |
| 429 Request _openCursor_2(KeyRange range) native; | 463 Request _openCursor_2(KeyRange range) native; |
| 430 @JSName('openCursor') | 464 @JSName('openCursor') |
| 431 @Returns('Request') @Creates('Request') @Creates('Cursor') | 465 @DomName("IDBIndex.openCursor") @Returns('Request') @Creates('Request') @Creat
es('Cursor') |
| 432 Request _openCursor_3(KeyRange range, direction) native; | 466 Request _openCursor_3(KeyRange range, direction) native; |
| 433 @JSName('openCursor') | 467 @JSName('openCursor') |
| 434 @Returns('Request') @Creates('Request') @Creates('Cursor') | 468 @DomName("IDBIndex.openCursor") @Returns('Request') @Creates('Request') @Creat
es('Cursor') |
| 435 Request _openCursor_4(key) native; | 469 Request _openCursor_4(key) native; |
| 436 @JSName('openCursor') | 470 @JSName('openCursor') |
| 437 @Returns('Request') @Creates('Request') @Creates('Cursor') | 471 @DomName("IDBIndex.openCursor") @Returns('Request') @Creates('Request') @Creat
es('Cursor') |
| 438 Request _openCursor_5(key, direction) native; | 472 Request _openCursor_5(key, direction) native; |
| 439 | 473 |
| 440 /// @domName IDBIndex.openKeyCursor; @docsEditable true | 474 /// @docsEditable true |
| 441 Request openKeyCursor([key_OR_range, String direction]) { | 475 Request openKeyCursor([key_OR_range, String direction]) { |
| 442 if (!?key_OR_range && | 476 if (!?key_OR_range && |
| 443 !?direction) { | 477 !?direction) { |
| 444 return _openKeyCursor_1(); | 478 return _openKeyCursor_1(); |
| 445 } | 479 } |
| 446 if ((key_OR_range is KeyRange || key_OR_range == null) && | 480 if ((key_OR_range is KeyRange || key_OR_range == null) && |
| 447 !?direction) { | 481 !?direction) { |
| 448 return _openKeyCursor_2(key_OR_range); | 482 return _openKeyCursor_2(key_OR_range); |
| 449 } | 483 } |
| 450 if ((key_OR_range is KeyRange || key_OR_range == null)) { | 484 if ((key_OR_range is KeyRange || key_OR_range == null)) { |
| 451 return _openKeyCursor_3(key_OR_range, direction); | 485 return _openKeyCursor_3(key_OR_range, direction); |
| 452 } | 486 } |
| 453 if (?key_OR_range && | 487 if (?key_OR_range && |
| 454 !?direction) { | 488 !?direction) { |
| 455 var key_1 = _convertDartToNative_IDBKey(key_OR_range); | 489 var key_1 = _convertDartToNative_IDBKey(key_OR_range); |
| 456 return _openKeyCursor_4(key_1); | 490 return _openKeyCursor_4(key_1); |
| 457 } | 491 } |
| 458 if (?key_OR_range) { | 492 if (?key_OR_range) { |
| 459 var key_2 = _convertDartToNative_IDBKey(key_OR_range); | 493 var key_2 = _convertDartToNative_IDBKey(key_OR_range); |
| 460 return _openKeyCursor_5(key_2, direction); | 494 return _openKeyCursor_5(key_2, direction); |
| 461 } | 495 } |
| 462 throw new ArgumentError("Incorrect number or type of arguments"); | 496 throw new ArgumentError("Incorrect number or type of arguments"); |
| 463 } | 497 } |
| 464 @JSName('openKeyCursor') | 498 @JSName('openKeyCursor') |
| 465 @Returns('Request') @Creates('Request') @Creates('Cursor') | 499 @DomName("IDBIndex.openKeyCursor") @Returns('Request') @Creates('Request') @Cr
eates('Cursor') |
| 466 Request _openKeyCursor_1() native; | 500 Request _openKeyCursor_1() native; |
| 467 @JSName('openKeyCursor') | 501 @JSName('openKeyCursor') |
| 468 @Returns('Request') @Creates('Request') @Creates('Cursor') | 502 @DomName("IDBIndex.openKeyCursor") @Returns('Request') @Creates('Request') @Cr
eates('Cursor') |
| 469 Request _openKeyCursor_2(KeyRange range) native; | 503 Request _openKeyCursor_2(KeyRange range) native; |
| 470 @JSName('openKeyCursor') | 504 @JSName('openKeyCursor') |
| 471 @Returns('Request') @Creates('Request') @Creates('Cursor') | 505 @DomName("IDBIndex.openKeyCursor") @Returns('Request') @Creates('Request') @Cr
eates('Cursor') |
| 472 Request _openKeyCursor_3(KeyRange range, direction) native; | 506 Request _openKeyCursor_3(KeyRange range, direction) native; |
| 473 @JSName('openKeyCursor') | 507 @JSName('openKeyCursor') |
| 474 @Returns('Request') @Creates('Request') @Creates('Cursor') | 508 @DomName("IDBIndex.openKeyCursor") @Returns('Request') @Creates('Request') @Cr
eates('Cursor') |
| 475 Request _openKeyCursor_4(key) native; | 509 Request _openKeyCursor_4(key) native; |
| 476 @JSName('openKeyCursor') | 510 @JSName('openKeyCursor') |
| 477 @Returns('Request') @Creates('Request') @Creates('Cursor') | 511 @DomName("IDBIndex.openKeyCursor") @Returns('Request') @Creates('Request') @Cr
eates('Cursor') |
| 478 Request _openKeyCursor_5(key, direction) native; | 512 Request _openKeyCursor_5(key, direction) native; |
| 479 } | 513 } |
| 480 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 514 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 481 // for details. All rights reserved. Use of this source code is governed by a | 515 // for details. All rights reserved. Use of this source code is governed by a |
| 482 // BSD-style license that can be found in the LICENSE file. | 516 // BSD-style license that can be found in the LICENSE file. |
| 483 | 517 |
| 484 | 518 |
| 485 /// @domName IDBKey; @docsEditable true | 519 /// @docsEditable true |
| 520 @DomName("IDBKey") |
| 486 class Key native "*IDBKey" { | 521 class Key native "*IDBKey" { |
| 487 } | 522 } |
| 488 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 523 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 489 // for details. All rights reserved. Use of this source code is governed by a | 524 // for details. All rights reserved. Use of this source code is governed by a |
| 490 // BSD-style license that can be found in the LICENSE file. | 525 // BSD-style license that can be found in the LICENSE file. |
| 491 | 526 |
| 492 | 527 |
| 493 /// @domName IDBKeyRange | 528 @DomName("IDBKeyRange") |
| 494 class KeyRange native "*IDBKeyRange" { | 529 class KeyRange native "*IDBKeyRange" { |
| 495 /** | 530 @DomName("IDBKeyRange.only") |
| 496 * @domName IDBKeyRange.only | |
| 497 */ | |
| 498 factory KeyRange.only(/*Key*/ value) => | 531 factory KeyRange.only(/*Key*/ value) => |
| 499 _KeyRangeFactoryProvider.createKeyRange_only(value); | 532 _KeyRangeFactoryProvider.createKeyRange_only(value); |
| 500 | 533 |
| 501 /** | 534 @DomName("IDBKeyRange.lowerBound") |
| 502 * @domName IDBKeyRange.lowerBound | |
| 503 */ | |
| 504 factory KeyRange.lowerBound(/*Key*/ bound, [bool open = false]) => | 535 factory KeyRange.lowerBound(/*Key*/ bound, [bool open = false]) => |
| 505 _KeyRangeFactoryProvider.createKeyRange_lowerBound(bound, open); | 536 _KeyRangeFactoryProvider.createKeyRange_lowerBound(bound, open); |
| 506 | 537 |
| 507 /** | 538 @DomName("IDBKeyRange.upperBound") |
| 508 * @domName IDBKeyRange.upperBound | |
| 509 */ | |
| 510 factory KeyRange.upperBound(/*Key*/ bound, [bool open = false]) => | 539 factory KeyRange.upperBound(/*Key*/ bound, [bool open = false]) => |
| 511 _KeyRangeFactoryProvider.createKeyRange_upperBound(bound, open); | 540 _KeyRangeFactoryProvider.createKeyRange_upperBound(bound, open); |
| 512 | 541 |
| 513 /** | 542 @DomName("KeyRange.bound") |
| 514 * @domName KeyRange.bound | |
| 515 */ | |
| 516 factory KeyRange.bound(/*Key*/ lower, /*Key*/ upper, | 543 factory KeyRange.bound(/*Key*/ lower, /*Key*/ upper, |
| 517 [bool lowerOpen = false, bool upperOpen = false]) => | 544 [bool lowerOpen = false, bool upperOpen = false]) => |
| 518 _KeyRangeFactoryProvider.createKeyRange_bound( | 545 _KeyRangeFactoryProvider.createKeyRange_bound( |
| 519 lower, upper, lowerOpen, upperOpen); | 546 lower, upper, lowerOpen, upperOpen); |
| 520 | 547 |
| 521 | 548 |
| 522 /// @domName IDBKeyRange.lower; @docsEditable true | 549 /// @docsEditable true |
| 523 dynamic get lower => _convertNativeToDart_IDBKey(this._lower); | 550 dynamic get lower => _convertNativeToDart_IDBKey(this._lower); |
| 524 @JSName('lower') | 551 @JSName('lower') |
| 552 @DomName("IDBKeyRange.lower") |
| 525 final dynamic _lower; | 553 final dynamic _lower; |
| 526 | 554 |
| 527 /// @domName IDBKeyRange.lowerOpen; @docsEditable true | 555 /// @docsEditable true |
| 556 @DomName("IDBKeyRange.lowerOpen") |
| 528 final bool lowerOpen; | 557 final bool lowerOpen; |
| 529 | 558 |
| 530 /// @domName IDBKeyRange.upper; @docsEditable true | 559 /// @docsEditable true |
| 531 dynamic get upper => _convertNativeToDart_IDBKey(this._upper); | 560 dynamic get upper => _convertNativeToDart_IDBKey(this._upper); |
| 532 @JSName('upper') | 561 @JSName('upper') |
| 562 @DomName("IDBKeyRange.upper") |
| 533 final dynamic _upper; | 563 final dynamic _upper; |
| 534 | 564 |
| 535 /// @domName IDBKeyRange.upperOpen; @docsEditable true | 565 /// @docsEditable true |
| 566 @DomName("IDBKeyRange.upperOpen") |
| 536 final bool upperOpen; | 567 final bool upperOpen; |
| 537 | 568 |
| 538 /// @domName IDBKeyRange.bound_; @docsEditable true | 569 /// @docsEditable true |
| 539 static KeyRange bound_(/*IDBKey*/ lower, /*IDBKey*/ upper, [bool lowerOpen, bo
ol upperOpen]) { | 570 static KeyRange bound_(/*IDBKey*/ lower, /*IDBKey*/ upper, [bool lowerOpen, bo
ol upperOpen]) { |
| 540 if (?upperOpen) { | 571 if (?upperOpen) { |
| 541 var lower_1 = _convertDartToNative_IDBKey(lower); | 572 var lower_1 = _convertDartToNative_IDBKey(lower); |
| 542 var upper_2 = _convertDartToNative_IDBKey(upper); | 573 var upper_2 = _convertDartToNative_IDBKey(upper); |
| 543 return _bound__1(lower_1, upper_2, lowerOpen, upperOpen); | 574 return _bound__1(lower_1, upper_2, lowerOpen, upperOpen); |
| 544 } | 575 } |
| 545 if (?lowerOpen) { | 576 if (?lowerOpen) { |
| 546 var lower_3 = _convertDartToNative_IDBKey(lower); | 577 var lower_3 = _convertDartToNative_IDBKey(lower); |
| 547 var upper_4 = _convertDartToNative_IDBKey(upper); | 578 var upper_4 = _convertDartToNative_IDBKey(upper); |
| 548 return _bound__2(lower_3, upper_4, lowerOpen); | 579 return _bound__2(lower_3, upper_4, lowerOpen); |
| 549 } | 580 } |
| 550 var lower_5 = _convertDartToNative_IDBKey(lower); | 581 var lower_5 = _convertDartToNative_IDBKey(lower); |
| 551 var upper_6 = _convertDartToNative_IDBKey(upper); | 582 var upper_6 = _convertDartToNative_IDBKey(upper); |
| 552 return _bound__3(lower_5, upper_6); | 583 return _bound__3(lower_5, upper_6); |
| 553 } | 584 } |
| 554 @JSName('bound') | 585 @JSName('bound') |
| 586 @DomName("IDBKeyRange.bound") |
| 555 static KeyRange _bound__1(lower, upper, lowerOpen, upperOpen) native; | 587 static KeyRange _bound__1(lower, upper, lowerOpen, upperOpen) native; |
| 556 @JSName('bound') | 588 @JSName('bound') |
| 589 @DomName("IDBKeyRange.bound") |
| 557 static KeyRange _bound__2(lower, upper, lowerOpen) native; | 590 static KeyRange _bound__2(lower, upper, lowerOpen) native; |
| 558 @JSName('bound') | 591 @JSName('bound') |
| 592 @DomName("IDBKeyRange.bound") |
| 559 static KeyRange _bound__3(lower, upper) native; | 593 static KeyRange _bound__3(lower, upper) native; |
| 560 | 594 |
| 561 /// @domName IDBKeyRange.lowerBound_; @docsEditable true | 595 /// @docsEditable true |
| 562 static KeyRange lowerBound_(/*IDBKey*/ bound, [bool open]) { | 596 static KeyRange lowerBound_(/*IDBKey*/ bound, [bool open]) { |
| 563 if (?open) { | 597 if (?open) { |
| 564 var bound_1 = _convertDartToNative_IDBKey(bound); | 598 var bound_1 = _convertDartToNative_IDBKey(bound); |
| 565 return _lowerBound__1(bound_1, open); | 599 return _lowerBound__1(bound_1, open); |
| 566 } | 600 } |
| 567 var bound_2 = _convertDartToNative_IDBKey(bound); | 601 var bound_2 = _convertDartToNative_IDBKey(bound); |
| 568 return _lowerBound__2(bound_2); | 602 return _lowerBound__2(bound_2); |
| 569 } | 603 } |
| 570 @JSName('lowerBound') | 604 @JSName('lowerBound') |
| 605 @DomName("IDBKeyRange.lowerBound") |
| 571 static KeyRange _lowerBound__1(bound, open) native; | 606 static KeyRange _lowerBound__1(bound, open) native; |
| 572 @JSName('lowerBound') | 607 @JSName('lowerBound') |
| 608 @DomName("IDBKeyRange.lowerBound") |
| 573 static KeyRange _lowerBound__2(bound) native; | 609 static KeyRange _lowerBound__2(bound) native; |
| 574 | 610 |
| 575 /// @domName IDBKeyRange.only_; @docsEditable true | 611 /// @docsEditable true |
| 576 static KeyRange only_(/*IDBKey*/ value) { | 612 static KeyRange only_(/*IDBKey*/ value) { |
| 577 var value_1 = _convertDartToNative_IDBKey(value); | 613 var value_1 = _convertDartToNative_IDBKey(value); |
| 578 return _only__1(value_1); | 614 return _only__1(value_1); |
| 579 } | 615 } |
| 580 @JSName('only') | 616 @JSName('only') |
| 617 @DomName("IDBKeyRange.only") |
| 581 static KeyRange _only__1(value) native; | 618 static KeyRange _only__1(value) native; |
| 582 | 619 |
| 583 /// @domName IDBKeyRange.upperBound_; @docsEditable true | 620 /// @docsEditable true |
| 584 static KeyRange upperBound_(/*IDBKey*/ bound, [bool open]) { | 621 static KeyRange upperBound_(/*IDBKey*/ bound, [bool open]) { |
| 585 if (?open) { | 622 if (?open) { |
| 586 var bound_1 = _convertDartToNative_IDBKey(bound); | 623 var bound_1 = _convertDartToNative_IDBKey(bound); |
| 587 return _upperBound__1(bound_1, open); | 624 return _upperBound__1(bound_1, open); |
| 588 } | 625 } |
| 589 var bound_2 = _convertDartToNative_IDBKey(bound); | 626 var bound_2 = _convertDartToNative_IDBKey(bound); |
| 590 return _upperBound__2(bound_2); | 627 return _upperBound__2(bound_2); |
| 591 } | 628 } |
| 592 @JSName('upperBound') | 629 @JSName('upperBound') |
| 630 @DomName("IDBKeyRange.upperBound") |
| 593 static KeyRange _upperBound__1(bound, open) native; | 631 static KeyRange _upperBound__1(bound, open) native; |
| 594 @JSName('upperBound') | 632 @JSName('upperBound') |
| 633 @DomName("IDBKeyRange.upperBound") |
| 595 static KeyRange _upperBound__2(bound) native; | 634 static KeyRange _upperBound__2(bound) native; |
| 596 | 635 |
| 597 } | 636 } |
| 598 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 637 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 599 // for details. All rights reserved. Use of this source code is governed by a | 638 // for details. All rights reserved. Use of this source code is governed by a |
| 600 // BSD-style license that can be found in the LICENSE file. | 639 // BSD-style license that can be found in the LICENSE file. |
| 601 | 640 |
| 602 | 641 |
| 603 /// @domName IDBObjectStore; @docsEditable true | 642 /// @docsEditable true |
| 643 @DomName("IDBObjectStore") |
| 604 class ObjectStore native "*IDBObjectStore" { | 644 class ObjectStore native "*IDBObjectStore" { |
| 605 | 645 |
| 606 /// @domName IDBObjectStore.autoIncrement; @docsEditable true | 646 /// @docsEditable true |
| 647 @DomName("IDBObjectStore.autoIncrement") |
| 607 final bool autoIncrement; | 648 final bool autoIncrement; |
| 608 | 649 |
| 609 /// @domName IDBObjectStore.indexNames; @docsEditable true | 650 /// @docsEditable true |
| 651 @DomName("IDBObjectStore.indexNames") |
| 610 @Returns('DomStringList') @Creates('DomStringList') | 652 @Returns('DomStringList') @Creates('DomStringList') |
| 611 final List<String> indexNames; | 653 final List<String> indexNames; |
| 612 | 654 |
| 613 /// @domName IDBObjectStore.keyPath; @docsEditable true | 655 /// @docsEditable true |
| 656 @DomName("IDBObjectStore.keyPath") |
| 614 final dynamic keyPath; | 657 final dynamic keyPath; |
| 615 | 658 |
| 616 /// @domName IDBObjectStore.name; @docsEditable true | 659 /// @docsEditable true |
| 660 @DomName("IDBObjectStore.name") |
| 617 final String name; | 661 final String name; |
| 618 | 662 |
| 619 /// @domName IDBObjectStore.transaction; @docsEditable true | 663 /// @docsEditable true |
| 664 @DomName("IDBObjectStore.transaction") |
| 620 final Transaction transaction; | 665 final Transaction transaction; |
| 621 | 666 |
| 622 /// @domName IDBObjectStore.add; @docsEditable true | 667 /// @docsEditable true |
| 623 Request add(/*any*/ value, [/*IDBKey*/ key]) { | 668 Request add(/*any*/ value, [/*IDBKey*/ key]) { |
| 624 if (?key) { | 669 if (?key) { |
| 625 var value_1 = convertDartToNative_SerializedScriptValue(value); | 670 var value_1 = convertDartToNative_SerializedScriptValue(value); |
| 626 var key_2 = _convertDartToNative_IDBKey(key); | 671 var key_2 = _convertDartToNative_IDBKey(key); |
| 627 return _add_1(value_1, key_2); | 672 return _add_1(value_1, key_2); |
| 628 } | 673 } |
| 629 var value_3 = convertDartToNative_SerializedScriptValue(value); | 674 var value_3 = convertDartToNative_SerializedScriptValue(value); |
| 630 return _add_2(value_3); | 675 return _add_2(value_3); |
| 631 } | 676 } |
| 632 @JSName('add') | 677 @JSName('add') |
| 633 @Returns('Request') @Creates('Request') @_annotation_Creates_IDBKey | 678 @DomName("IDBObjectStore.add") @Returns('Request') @Creates('Request') @_annot
ation_Creates_IDBKey |
| 634 Request _add_1(value, key) native; | 679 Request _add_1(value, key) native; |
| 635 @JSName('add') | 680 @JSName('add') |
| 636 @Returns('Request') @Creates('Request') @_annotation_Creates_IDBKey | 681 @DomName("IDBObjectStore.add") @Returns('Request') @Creates('Request') @_annot
ation_Creates_IDBKey |
| 637 Request _add_2(value) native; | 682 Request _add_2(value) native; |
| 638 | 683 |
| 639 /// @domName IDBObjectStore.clear; @docsEditable true | 684 /// @docsEditable true |
| 685 @DomName("IDBObjectStore.clear") |
| 640 Request clear() native; | 686 Request clear() native; |
| 641 | 687 |
| 642 /// @domName IDBObjectStore.count; @docsEditable true | 688 /// @docsEditable true |
| 643 Request count([key_OR_range]) { | 689 Request count([key_OR_range]) { |
| 644 if (!?key_OR_range) { | 690 if (!?key_OR_range) { |
| 645 return _count_1(); | 691 return _count_1(); |
| 646 } | 692 } |
| 647 if ((key_OR_range is KeyRange || key_OR_range == null)) { | 693 if ((key_OR_range is KeyRange || key_OR_range == null)) { |
| 648 return _count_2(key_OR_range); | 694 return _count_2(key_OR_range); |
| 649 } | 695 } |
| 650 if (?key_OR_range) { | 696 if (?key_OR_range) { |
| 651 var key_1 = _convertDartToNative_IDBKey(key_OR_range); | 697 var key_1 = _convertDartToNative_IDBKey(key_OR_range); |
| 652 return _count_3(key_1); | 698 return _count_3(key_1); |
| 653 } | 699 } |
| 654 throw new ArgumentError("Incorrect number or type of arguments"); | 700 throw new ArgumentError("Incorrect number or type of arguments"); |
| 655 } | 701 } |
| 656 @JSName('count') | 702 @JSName('count') |
| 703 @DomName("IDBObjectStore.count") |
| 657 Request _count_1() native; | 704 Request _count_1() native; |
| 658 @JSName('count') | 705 @JSName('count') |
| 706 @DomName("IDBObjectStore.count") |
| 659 Request _count_2(KeyRange range) native; | 707 Request _count_2(KeyRange range) native; |
| 660 @JSName('count') | 708 @JSName('count') |
| 709 @DomName("IDBObjectStore.count") |
| 661 Request _count_3(key) native; | 710 Request _count_3(key) native; |
| 662 | 711 |
| 663 /// @domName IDBObjectStore.createIndex; @docsEditable true | 712 /// @docsEditable true |
| 664 Index createIndex(String name, keyPath, [Map options]) { | 713 Index createIndex(String name, keyPath, [Map options]) { |
| 665 if ((keyPath is List<String> || keyPath == null) && | 714 if ((keyPath is List<String> || keyPath == null) && |
| 666 !?options) { | 715 !?options) { |
| 667 return _createIndex_1(name, keyPath); | 716 return _createIndex_1(name, keyPath); |
| 668 } | 717 } |
| 669 if ((keyPath is List<String> || keyPath == null)) { | 718 if ((keyPath is List<String> || keyPath == null)) { |
| 670 var options_1 = convertDartToNative_Dictionary(options); | 719 var options_1 = convertDartToNative_Dictionary(options); |
| 671 return _createIndex_2(name, keyPath, options_1); | 720 return _createIndex_2(name, keyPath, options_1); |
| 672 } | 721 } |
| 673 if ((keyPath is String || keyPath == null) && | 722 if ((keyPath is String || keyPath == null) && |
| 674 !?options) { | 723 !?options) { |
| 675 return _createIndex_3(name, keyPath); | 724 return _createIndex_3(name, keyPath); |
| 676 } | 725 } |
| 677 if ((keyPath is String || keyPath == null)) { | 726 if ((keyPath is String || keyPath == null)) { |
| 678 var options_2 = convertDartToNative_Dictionary(options); | 727 var options_2 = convertDartToNative_Dictionary(options); |
| 679 return _createIndex_4(name, keyPath, options_2); | 728 return _createIndex_4(name, keyPath, options_2); |
| 680 } | 729 } |
| 681 throw new ArgumentError("Incorrect number or type of arguments"); | 730 throw new ArgumentError("Incorrect number or type of arguments"); |
| 682 } | 731 } |
| 683 @JSName('createIndex') | 732 @JSName('createIndex') |
| 733 @DomName("IDBObjectStore.createIndex") |
| 684 Index _createIndex_1(name, List<String> keyPath) native; | 734 Index _createIndex_1(name, List<String> keyPath) native; |
| 685 @JSName('createIndex') | 735 @JSName('createIndex') |
| 736 @DomName("IDBObjectStore.createIndex") |
| 686 Index _createIndex_2(name, List<String> keyPath, options) native; | 737 Index _createIndex_2(name, List<String> keyPath, options) native; |
| 687 @JSName('createIndex') | 738 @JSName('createIndex') |
| 739 @DomName("IDBObjectStore.createIndex") |
| 688 Index _createIndex_3(name, String keyPath) native; | 740 Index _createIndex_3(name, String keyPath) native; |
| 689 @JSName('createIndex') | 741 @JSName('createIndex') |
| 742 @DomName("IDBObjectStore.createIndex") |
| 690 Index _createIndex_4(name, String keyPath, options) native; | 743 Index _createIndex_4(name, String keyPath, options) native; |
| 691 | 744 |
| 692 /// @domName IDBObjectStore.delete; @docsEditable true | 745 /// @docsEditable true |
| 693 Request delete(key_OR_keyRange) { | 746 Request delete(key_OR_keyRange) { |
| 694 if ((key_OR_keyRange is KeyRange || key_OR_keyRange == null)) { | 747 if ((key_OR_keyRange is KeyRange || key_OR_keyRange == null)) { |
| 695 return _delete_1(key_OR_keyRange); | 748 return _delete_1(key_OR_keyRange); |
| 696 } | 749 } |
| 697 if (?key_OR_keyRange) { | 750 if (?key_OR_keyRange) { |
| 698 var key_1 = _convertDartToNative_IDBKey(key_OR_keyRange); | 751 var key_1 = _convertDartToNative_IDBKey(key_OR_keyRange); |
| 699 return _delete_2(key_1); | 752 return _delete_2(key_1); |
| 700 } | 753 } |
| 701 throw new ArgumentError("Incorrect number or type of arguments"); | 754 throw new ArgumentError("Incorrect number or type of arguments"); |
| 702 } | 755 } |
| 703 @JSName('delete') | 756 @JSName('delete') |
| 757 @DomName("IDBObjectStore.delete") |
| 704 Request _delete_1(KeyRange keyRange) native; | 758 Request _delete_1(KeyRange keyRange) native; |
| 705 @JSName('delete') | 759 @JSName('delete') |
| 760 @DomName("IDBObjectStore.delete") |
| 706 Request _delete_2(key) native; | 761 Request _delete_2(key) native; |
| 707 | 762 |
| 708 /// @domName IDBObjectStore.deleteIndex; @docsEditable true | 763 /// @docsEditable true |
| 764 @DomName("IDBObjectStore.deleteIndex") |
| 709 void deleteIndex(String name) native; | 765 void deleteIndex(String name) native; |
| 710 | 766 |
| 711 /// @domName IDBObjectStore.getObject; @docsEditable true | 767 /// @docsEditable true |
| 712 Request getObject(key) { | 768 Request getObject(key) { |
| 713 if ((key is KeyRange || key == null)) { | 769 if ((key is KeyRange || key == null)) { |
| 714 return _getObject_1(key); | 770 return _getObject_1(key); |
| 715 } | 771 } |
| 716 if (?key) { | 772 if (?key) { |
| 717 var key_1 = _convertDartToNative_IDBKey(key); | 773 var key_1 = _convertDartToNative_IDBKey(key); |
| 718 return _getObject_2(key_1); | 774 return _getObject_2(key_1); |
| 719 } | 775 } |
| 720 throw new ArgumentError("Incorrect number or type of arguments"); | 776 throw new ArgumentError("Incorrect number or type of arguments"); |
| 721 } | 777 } |
| 722 @JSName('get') | 778 @JSName('get') |
| 723 @Returns('Request') @Creates('Request') @annotation_Creates_SerializedScriptVa
lue | 779 @DomName("IDBObjectStore.get") @Returns('Request') @Creates('Request') @annota
tion_Creates_SerializedScriptValue |
| 724 Request _getObject_1(KeyRange key) native; | 780 Request _getObject_1(KeyRange key) native; |
| 725 @JSName('get') | 781 @JSName('get') |
| 726 @Returns('Request') @Creates('Request') @annotation_Creates_SerializedScriptVa
lue | 782 @DomName("IDBObjectStore.get") @Returns('Request') @Creates('Request') @annota
tion_Creates_SerializedScriptValue |
| 727 Request _getObject_2(key) native; | 783 Request _getObject_2(key) native; |
| 728 | 784 |
| 729 /// @domName IDBObjectStore.index; @docsEditable true | 785 /// @docsEditable true |
| 786 @DomName("IDBObjectStore.index") |
| 730 Index index(String name) native; | 787 Index index(String name) native; |
| 731 | 788 |
| 732 /// @domName IDBObjectStore.openCursor; @docsEditable true | 789 /// @docsEditable true |
| 733 Request openCursor([key_OR_range, String direction]) { | 790 Request openCursor([key_OR_range, String direction]) { |
| 734 if (!?key_OR_range && | 791 if (!?key_OR_range && |
| 735 !?direction) { | 792 !?direction) { |
| 736 return _openCursor_1(); | 793 return _openCursor_1(); |
| 737 } | 794 } |
| 738 if ((key_OR_range is KeyRange || key_OR_range == null) && | 795 if ((key_OR_range is KeyRange || key_OR_range == null) && |
| 739 !?direction) { | 796 !?direction) { |
| 740 return _openCursor_2(key_OR_range); | 797 return _openCursor_2(key_OR_range); |
| 741 } | 798 } |
| 742 if ((key_OR_range is KeyRange || key_OR_range == null)) { | 799 if ((key_OR_range is KeyRange || key_OR_range == null)) { |
| 743 return _openCursor_3(key_OR_range, direction); | 800 return _openCursor_3(key_OR_range, direction); |
| 744 } | 801 } |
| 745 if (?key_OR_range && | 802 if (?key_OR_range && |
| 746 !?direction) { | 803 !?direction) { |
| 747 var key_1 = _convertDartToNative_IDBKey(key_OR_range); | 804 var key_1 = _convertDartToNative_IDBKey(key_OR_range); |
| 748 return _openCursor_4(key_1); | 805 return _openCursor_4(key_1); |
| 749 } | 806 } |
| 750 if (?key_OR_range) { | 807 if (?key_OR_range) { |
| 751 var key_2 = _convertDartToNative_IDBKey(key_OR_range); | 808 var key_2 = _convertDartToNative_IDBKey(key_OR_range); |
| 752 return _openCursor_5(key_2, direction); | 809 return _openCursor_5(key_2, direction); |
| 753 } | 810 } |
| 754 throw new ArgumentError("Incorrect number or type of arguments"); | 811 throw new ArgumentError("Incorrect number or type of arguments"); |
| 755 } | 812 } |
| 756 @JSName('openCursor') | 813 @JSName('openCursor') |
| 757 @Returns('Request') @Creates('Request') @Creates('Cursor') | 814 @DomName("IDBObjectStore.openCursor") @Returns('Request') @Creates('Request')
@Creates('Cursor') |
| 758 Request _openCursor_1() native; | 815 Request _openCursor_1() native; |
| 759 @JSName('openCursor') | 816 @JSName('openCursor') |
| 760 @Returns('Request') @Creates('Request') @Creates('Cursor') | 817 @DomName("IDBObjectStore.openCursor") @Returns('Request') @Creates('Request')
@Creates('Cursor') |
| 761 Request _openCursor_2(KeyRange range) native; | 818 Request _openCursor_2(KeyRange range) native; |
| 762 @JSName('openCursor') | 819 @JSName('openCursor') |
| 763 @Returns('Request') @Creates('Request') @Creates('Cursor') | 820 @DomName("IDBObjectStore.openCursor") @Returns('Request') @Creates('Request')
@Creates('Cursor') |
| 764 Request _openCursor_3(KeyRange range, direction) native; | 821 Request _openCursor_3(KeyRange range, direction) native; |
| 765 @JSName('openCursor') | 822 @JSName('openCursor') |
| 766 @Returns('Request') @Creates('Request') @Creates('Cursor') | 823 @DomName("IDBObjectStore.openCursor") @Returns('Request') @Creates('Request')
@Creates('Cursor') |
| 767 Request _openCursor_4(key) native; | 824 Request _openCursor_4(key) native; |
| 768 @JSName('openCursor') | 825 @JSName('openCursor') |
| 769 @Returns('Request') @Creates('Request') @Creates('Cursor') | 826 @DomName("IDBObjectStore.openCursor") @Returns('Request') @Creates('Request')
@Creates('Cursor') |
| 770 Request _openCursor_5(key, direction) native; | 827 Request _openCursor_5(key, direction) native; |
| 771 | 828 |
| 772 /// @domName IDBObjectStore.put; @docsEditable true | 829 /// @docsEditable true |
| 773 Request put(/*any*/ value, [/*IDBKey*/ key]) { | 830 Request put(/*any*/ value, [/*IDBKey*/ key]) { |
| 774 if (?key) { | 831 if (?key) { |
| 775 var value_1 = convertDartToNative_SerializedScriptValue(value); | 832 var value_1 = convertDartToNative_SerializedScriptValue(value); |
| 776 var key_2 = _convertDartToNative_IDBKey(key); | 833 var key_2 = _convertDartToNative_IDBKey(key); |
| 777 return _put_1(value_1, key_2); | 834 return _put_1(value_1, key_2); |
| 778 } | 835 } |
| 779 var value_3 = convertDartToNative_SerializedScriptValue(value); | 836 var value_3 = convertDartToNative_SerializedScriptValue(value); |
| 780 return _put_2(value_3); | 837 return _put_2(value_3); |
| 781 } | 838 } |
| 782 @JSName('put') | 839 @JSName('put') |
| 783 @Returns('Request') @Creates('Request') @_annotation_Creates_IDBKey | 840 @DomName("IDBObjectStore.put") @Returns('Request') @Creates('Request') @_annot
ation_Creates_IDBKey |
| 784 Request _put_1(value, key) native; | 841 Request _put_1(value, key) native; |
| 785 @JSName('put') | 842 @JSName('put') |
| 786 @Returns('Request') @Creates('Request') @_annotation_Creates_IDBKey | 843 @DomName("IDBObjectStore.put") @Returns('Request') @Creates('Request') @_annot
ation_Creates_IDBKey |
| 787 Request _put_2(value) native; | 844 Request _put_2(value) native; |
| 788 } | 845 } |
| 789 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 846 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 790 // for details. All rights reserved. Use of this source code is governed by a | 847 // for details. All rights reserved. Use of this source code is governed by a |
| 791 // BSD-style license that can be found in the LICENSE file. | 848 // BSD-style license that can be found in the LICENSE file. |
| 792 | 849 |
| 793 | 850 |
| 794 /// @domName IDBOpenDBRequest; @docsEditable true | 851 /// @docsEditable true |
| 852 @DomName("IDBOpenDBRequest") |
| 795 class OpenDBRequest extends Request implements EventTarget native "*IDBOpenDBReq
uest" { | 853 class OpenDBRequest extends Request implements EventTarget native "*IDBOpenDBReq
uest" { |
| 796 | 854 |
| 797 /// @domName EventTarget.addEventListener, EventTarget.removeEventListener, Ev
entTarget.dispatchEvent; @docsEditable true | 855 /// @docsEditable true |
| 856 @DomName("EventTarget.addEventListener, EventTarget.removeEventListener, Event
Target.dispatchEvent") |
| 798 OpenDBRequestEvents get on => | 857 OpenDBRequestEvents get on => |
| 799 new OpenDBRequestEvents(this); | 858 new OpenDBRequestEvents(this); |
| 800 } | 859 } |
| 801 | 860 |
| 802 /// @docsEditable true | 861 /// @docsEditable true |
| 803 class OpenDBRequestEvents extends RequestEvents { | 862 class OpenDBRequestEvents extends RequestEvents { |
| 804 /// @docsEditable true | 863 /// @docsEditable true |
| 805 OpenDBRequestEvents(EventTarget _ptr) : super(_ptr); | 864 OpenDBRequestEvents(EventTarget _ptr) : super(_ptr); |
| 806 | 865 |
| 807 /// @docsEditable true | 866 /// @docsEditable true |
| 808 EventListenerList get blocked => this['blocked']; | 867 EventListenerList get blocked => this['blocked']; |
| 809 | 868 |
| 810 /// @docsEditable true | 869 /// @docsEditable true |
| 811 EventListenerList get upgradeNeeded => this['upgradeneeded']; | 870 EventListenerList get upgradeNeeded => this['upgradeneeded']; |
| 812 } | 871 } |
| 813 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 872 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 814 // for details. All rights reserved. Use of this source code is governed by a | 873 // for details. All rights reserved. Use of this source code is governed by a |
| 815 // BSD-style license that can be found in the LICENSE file. | 874 // BSD-style license that can be found in the LICENSE file. |
| 816 | 875 |
| 817 | 876 |
| 818 /// @domName IDBRequest; @docsEditable true | 877 /// @docsEditable true |
| 878 @DomName("IDBRequest") |
| 819 class Request extends EventTarget native "*IDBRequest" { | 879 class Request extends EventTarget native "*IDBRequest" { |
| 820 | 880 |
| 821 /// @domName EventTarget.addEventListener, EventTarget.removeEventListener, Ev
entTarget.dispatchEvent; @docsEditable true | 881 /// @docsEditable true |
| 882 @DomName("EventTarget.addEventListener, EventTarget.removeEventListener, Event
Target.dispatchEvent") |
| 822 RequestEvents get on => | 883 RequestEvents get on => |
| 823 new RequestEvents(this); | 884 new RequestEvents(this); |
| 824 | 885 |
| 825 /// @domName IDBRequest.error; @docsEditable true | 886 /// @docsEditable true |
| 887 @DomName("IDBRequest.error") |
| 826 final DomError error; | 888 final DomError error; |
| 827 | 889 |
| 828 /// @domName IDBRequest.readyState; @docsEditable true | 890 /// @docsEditable true |
| 891 @DomName("IDBRequest.readyState") |
| 829 final String readyState; | 892 final String readyState; |
| 830 | 893 |
| 831 /// @domName IDBRequest.result; @docsEditable true | 894 /// @docsEditable true |
| 832 dynamic get result => _convertNativeToDart_IDBAny(this._result); | 895 dynamic get result => _convertNativeToDart_IDBAny(this._result); |
| 833 @JSName('result') | 896 @JSName('result') |
| 834 @Creates('Null') | 897 @DomName("IDBRequest.result") @Creates('Null') |
| 835 final dynamic _result; | 898 final dynamic _result; |
| 836 | 899 |
| 837 /// @domName IDBRequest.source; @docsEditable true | 900 /// @docsEditable true |
| 838 @Creates('Null') | 901 @DomName("IDBRequest.source") @Creates('Null') |
| 839 final dynamic source; | 902 final dynamic source; |
| 840 | 903 |
| 841 /// @domName IDBRequest.transaction; @docsEditable true | 904 /// @docsEditable true |
| 905 @DomName("IDBRequest.transaction") |
| 842 final Transaction transaction; | 906 final Transaction transaction; |
| 843 | 907 |
| 844 /// @domName IDBRequest.webkitErrorMessage; @docsEditable true | 908 /// @docsEditable true |
| 909 @DomName("IDBRequest.webkitErrorMessage") |
| 845 final String webkitErrorMessage; | 910 final String webkitErrorMessage; |
| 846 | 911 |
| 847 /// @domName IDBRequest.addEventListener; @docsEditable true | 912 /// @docsEditable true |
| 848 @JSName('addEventListener') | 913 @JSName('addEventListener') |
| 914 @DomName("IDBRequest.addEventListener") |
| 849 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu
re]) native; | 915 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu
re]) native; |
| 850 | 916 |
| 851 /// @domName IDBRequest.dispatchEvent; @docsEditable true | 917 /// @docsEditable true |
| 852 @JSName('dispatchEvent') | 918 @JSName('dispatchEvent') |
| 919 @DomName("IDBRequest.dispatchEvent") |
| 853 bool $dom_dispatchEvent(Event evt) native; | 920 bool $dom_dispatchEvent(Event evt) native; |
| 854 | 921 |
| 855 /// @domName IDBRequest.removeEventListener; @docsEditable true | 922 /// @docsEditable true |
| 856 @JSName('removeEventListener') | 923 @JSName('removeEventListener') |
| 924 @DomName("IDBRequest.removeEventListener") |
| 857 void $dom_removeEventListener(String type, EventListener listener, [bool useCa
pture]) native; | 925 void $dom_removeEventListener(String type, EventListener listener, [bool useCa
pture]) native; |
| 858 } | 926 } |
| 859 | 927 |
| 860 /// @docsEditable true | 928 /// @docsEditable true |
| 861 class RequestEvents extends Events { | 929 class RequestEvents extends Events { |
| 862 /// @docsEditable true | 930 /// @docsEditable true |
| 863 RequestEvents(EventTarget _ptr) : super(_ptr); | 931 RequestEvents(EventTarget _ptr) : super(_ptr); |
| 864 | 932 |
| 865 /// @docsEditable true | 933 /// @docsEditable true |
| 866 EventListenerList get error => this['error']; | 934 EventListenerList get error => this['error']; |
| 867 | 935 |
| 868 /// @docsEditable true | 936 /// @docsEditable true |
| 869 EventListenerList get success => this['success']; | 937 EventListenerList get success => this['success']; |
| 870 } | 938 } |
| 871 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 939 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 872 // for details. All rights reserved. Use of this source code is governed by a | 940 // for details. All rights reserved. Use of this source code is governed by a |
| 873 // BSD-style license that can be found in the LICENSE file. | 941 // BSD-style license that can be found in the LICENSE file. |
| 874 | 942 |
| 875 | 943 |
| 876 /// @domName IDBTransaction; @docsEditable true | 944 /// @docsEditable true |
| 945 @DomName("IDBTransaction") |
| 877 class Transaction extends EventTarget native "*IDBTransaction" { | 946 class Transaction extends EventTarget native "*IDBTransaction" { |
| 878 | 947 |
| 879 /// @domName EventTarget.addEventListener, EventTarget.removeEventListener, Ev
entTarget.dispatchEvent; @docsEditable true | 948 /// @docsEditable true |
| 949 @DomName("EventTarget.addEventListener, EventTarget.removeEventListener, Event
Target.dispatchEvent") |
| 880 TransactionEvents get on => | 950 TransactionEvents get on => |
| 881 new TransactionEvents(this); | 951 new TransactionEvents(this); |
| 882 | 952 |
| 883 /// @domName IDBTransaction.db; @docsEditable true | 953 /// @docsEditable true |
| 954 @DomName("IDBTransaction.db") |
| 884 final Database db; | 955 final Database db; |
| 885 | 956 |
| 886 /// @domName IDBTransaction.error; @docsEditable true | 957 /// @docsEditable true |
| 958 @DomName("IDBTransaction.error") |
| 887 final DomError error; | 959 final DomError error; |
| 888 | 960 |
| 889 /// @domName IDBTransaction.mode; @docsEditable true | 961 /// @docsEditable true |
| 962 @DomName("IDBTransaction.mode") |
| 890 final String mode; | 963 final String mode; |
| 891 | 964 |
| 892 /// @domName IDBTransaction.webkitErrorMessage; @docsEditable true | 965 /// @docsEditable true |
| 966 @DomName("IDBTransaction.webkitErrorMessage") |
| 893 final String webkitErrorMessage; | 967 final String webkitErrorMessage; |
| 894 | 968 |
| 895 /// @domName IDBTransaction.abort; @docsEditable true | 969 /// @docsEditable true |
| 970 @DomName("IDBTransaction.abort") |
| 896 void abort() native; | 971 void abort() native; |
| 897 | 972 |
| 898 /// @domName IDBTransaction.addEventListener; @docsEditable true | 973 /// @docsEditable true |
| 899 @JSName('addEventListener') | 974 @JSName('addEventListener') |
| 975 @DomName("IDBTransaction.addEventListener") |
| 900 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu
re]) native; | 976 void $dom_addEventListener(String type, EventListener listener, [bool useCaptu
re]) native; |
| 901 | 977 |
| 902 /// @domName IDBTransaction.dispatchEvent; @docsEditable true | 978 /// @docsEditable true |
| 903 @JSName('dispatchEvent') | 979 @JSName('dispatchEvent') |
| 980 @DomName("IDBTransaction.dispatchEvent") |
| 904 bool $dom_dispatchEvent(Event evt) native; | 981 bool $dom_dispatchEvent(Event evt) native; |
| 905 | 982 |
| 906 /// @domName IDBTransaction.objectStore; @docsEditable true | 983 /// @docsEditable true |
| 984 @DomName("IDBTransaction.objectStore") |
| 907 ObjectStore objectStore(String name) native; | 985 ObjectStore objectStore(String name) native; |
| 908 | 986 |
| 909 /// @domName IDBTransaction.removeEventListener; @docsEditable true | 987 /// @docsEditable true |
| 910 @JSName('removeEventListener') | 988 @JSName('removeEventListener') |
| 989 @DomName("IDBTransaction.removeEventListener") |
| 911 void $dom_removeEventListener(String type, EventListener listener, [bool useCa
pture]) native; | 990 void $dom_removeEventListener(String type, EventListener listener, [bool useCa
pture]) native; |
| 912 } | 991 } |
| 913 | 992 |
| 914 /// @docsEditable true | 993 /// @docsEditable true |
| 915 class TransactionEvents extends Events { | 994 class TransactionEvents extends Events { |
| 916 /// @docsEditable true | 995 /// @docsEditable true |
| 917 TransactionEvents(EventTarget _ptr) : super(_ptr); | 996 TransactionEvents(EventTarget _ptr) : super(_ptr); |
| 918 | 997 |
| 919 /// @docsEditable true | 998 /// @docsEditable true |
| 920 EventListenerList get abort => this['abort']; | 999 EventListenerList get abort => this['abort']; |
| 921 | 1000 |
| 922 /// @docsEditable true | 1001 /// @docsEditable true |
| 923 EventListenerList get complete => this['complete']; | 1002 EventListenerList get complete => this['complete']; |
| 924 | 1003 |
| 925 /// @docsEditable true | 1004 /// @docsEditable true |
| 926 EventListenerList get error => this['error']; | 1005 EventListenerList get error => this['error']; |
| 927 } | 1006 } |
| 928 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1007 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 929 // for details. All rights reserved. Use of this source code is governed by a | 1008 // for details. All rights reserved. Use of this source code is governed by a |
| 930 // BSD-style license that can be found in the LICENSE file. | 1009 // BSD-style license that can be found in the LICENSE file. |
| 931 | 1010 |
| 932 | 1011 |
| 933 /// @domName IDBVersionChangeEvent; @docsEditable true | 1012 /// @docsEditable true |
| 1013 @DomName("IDBVersionChangeEvent") |
| 934 class UpgradeNeededEvent extends Event native "*IDBVersionChangeEvent" { | 1014 class UpgradeNeededEvent extends Event native "*IDBVersionChangeEvent" { |
| 935 | 1015 |
| 936 /// @domName IDBVersionChangeEvent.newVersion; @docsEditable true | 1016 /// @docsEditable true |
| 1017 @DomName("IDBUpgradeNeededEvent.newVersion") |
| 937 final int newVersion; | 1018 final int newVersion; |
| 938 | 1019 |
| 939 /// @domName IDBVersionChangeEvent.oldVersion; @docsEditable true | 1020 /// @docsEditable true |
| 1021 @DomName("IDBUpgradeNeededEvent.oldVersion") |
| 940 final int oldVersion; | 1022 final int oldVersion; |
| 941 } | 1023 } |
| 942 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1024 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 943 // for details. All rights reserved. Use of this source code is governed by a | 1025 // for details. All rights reserved. Use of this source code is governed by a |
| 944 // BSD-style license that can be found in the LICENSE file. | 1026 // BSD-style license that can be found in the LICENSE file. |
| 945 | 1027 |
| 946 | 1028 |
| 947 /// @domName IDBVersionChangeEvent; @docsEditable true | 1029 /// @docsEditable true |
| 1030 @DomName("IDBVersionChangeEvent") |
| 948 class VersionChangeEvent extends Event native "*IDBVersionChangeEvent" { | 1031 class VersionChangeEvent extends Event native "*IDBVersionChangeEvent" { |
| 949 | 1032 |
| 950 /// @domName IDBVersionChangeEvent.version; @docsEditable true | 1033 /// @docsEditable true |
| 1034 @DomName("IDBVersionChangeEvent.version") |
| 951 final String version; | 1035 final String version; |
| 952 } | 1036 } |
| 953 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1037 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 954 // for details. All rights reserved. Use of this source code is governed by a | 1038 // for details. All rights reserved. Use of this source code is governed by a |
| 955 // BSD-style license that can be found in the LICENSE file. | 1039 // BSD-style license that can be found in the LICENSE file. |
| 956 | 1040 |
| 957 | 1041 |
| 958 /// @domName IDBVersionChangeRequest; @docsEditable true | 1042 /// @docsEditable true |
| 1043 @DomName("IDBVersionChangeRequest") |
| 959 class VersionChangeRequest extends Request implements EventTarget native "*IDBVe
rsionChangeRequest" { | 1044 class VersionChangeRequest extends Request implements EventTarget native "*IDBVe
rsionChangeRequest" { |
| 960 | 1045 |
| 961 /// @domName EventTarget.addEventListener, EventTarget.removeEventListener, Ev
entTarget.dispatchEvent; @docsEditable true | 1046 /// @docsEditable true |
| 1047 @DomName("EventTarget.addEventListener, EventTarget.removeEventListener, Event
Target.dispatchEvent") |
| 962 VersionChangeRequestEvents get on => | 1048 VersionChangeRequestEvents get on => |
| 963 new VersionChangeRequestEvents(this); | 1049 new VersionChangeRequestEvents(this); |
| 964 } | 1050 } |
| 965 | 1051 |
| 966 /// @docsEditable true | 1052 /// @docsEditable true |
| 967 class VersionChangeRequestEvents extends RequestEvents { | 1053 class VersionChangeRequestEvents extends RequestEvents { |
| 968 /// @docsEditable true | 1054 /// @docsEditable true |
| 969 VersionChangeRequestEvents(EventTarget _ptr) : super(_ptr); | 1055 VersionChangeRequestEvents(EventTarget _ptr) : super(_ptr); |
| 970 | 1056 |
| 971 /// @docsEditable true | 1057 /// @docsEditable true |
| 972 EventListenerList get blocked => this['blocked']; | 1058 EventListenerList get blocked => this['blocked']; |
| 973 } | 1059 } |
| 974 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1060 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 975 // for details. All rights reserved. Use of this source code is governed by a | 1061 // for details. All rights reserved. Use of this source code is governed by a |
| 976 // BSD-style license that can be found in the LICENSE file. | 1062 // BSD-style license that can be found in the LICENSE file. |
| 977 | 1063 |
| 978 | 1064 |
| 979 /// @domName IDBAny; @docsEditable true | 1065 /// @docsEditable true |
| 1066 @DomName("IDBAny") |
| 980 class _Any native "*IDBAny" { | 1067 class _Any native "*IDBAny" { |
| 981 } | 1068 } |
| OLD | NEW |