read<T> method

T read<T>(
  1. String key
)

Reads an arbitrary value from the row and maps it to a fitting dart type. The dart type T must be supported by the type system of the database used (mostly contains booleans, strings, numbers and dates).

Implementation

T read<T>(String key) {
  final type = _db.typeSystem.forDartType<T>();

  return type.mapFromDatabaseResponse(data[key]) as T;
}