Transaction transaction(storeName_OR_storeNames, String mode)

Source

Transaction transaction(storeName_OR_storeNames, String mode) {
  if (mode != 'readonly' && mode != 'readwrite') {
    throw new ArgumentError("Invalid transaction mode $mode");
  }
  var names;
  if (storeName_OR_storeNames == null) {
    throw new ArgumentError("stores may not be null in transaction");
  } else if (storeName_OR_storeNames is String || storeName_OR_storeNames is DomStringList) {
    names = unwrap_jso(storeName_OR_storeNames);
  } else if (storeName_OR_storeNames is List<String>) {
    names = convertDartToNative_List(storeName_OR_storeNames);
  } else {
    throw new ArgumentError("Invalid store(s) $store_Name_OR_storeNames");
  }

  return wrap_jso(_blink.BlinkIDBDatabase.instance.transaction_Callback_2_(unwrap_jso(this), names, mode));
}