Chromium Code Reviews| Index: sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart |
| diff --git a/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart b/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart |
| index 9dd0d9a6f6a4810a54abfb6379801cd2095a1dc7..c7d0bb6b0c2466b05c235046b3e9cb706def7aea 100644 |
| --- a/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart |
| +++ b/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart |
| @@ -267,6 +267,31 @@ class Database extends EventTarget native "IDBDatabase" { |
| return _transaction(storeName_OR_storeNames, mode); |
| } |
| + Transaction transactionString(String storeName, String mode) { |
|
blois
2013/06/24 16:58:02
can this be transactionStore and transactionStores
Emily Fortuna
2013/06/25 03:53:31
Done.
|
| + if (mode != 'readonly' && mode != 'readwrite') { |
| + throw new ArgumentError(mode); |
| + } |
| + // Try and create a transaction with a string mode. Browsers that expect a |
| + // numeric mode tend to convert the string into a number. This fails |
| + // silently, resulting in zero ('readonly'). |
| + return _transaction(storeName, mode); |
| + } |
| + |
| + Transaction transactionList(List<String> storeNames, String mode) { |
| + if (mode != 'readonly' && mode != 'readwrite') { |
| + throw new ArgumentError(mode); |
| + } |
| + List storeNames_1 = convertDartToNative_StringArray(storeNames); |
| + return _transaction(storeNames_1, mode); |
| + } |
| + |
| + Transaction transactionStringList(DomStringList storeNames, String mode) { |
| + if (mode != 'readonly' && mode != 'readwrite') { |
| + throw new ArgumentError(mode); |
| + } |
| + return _transaction(storeNames_1, mode); |
| + } |
| + |
| @JSName('transaction') |
| Transaction _transaction(stores, mode) native; |