value<T> static method
Extracts and converts a value from source to type T
Supports automatic conversion between:
- num ↔ int, double, String
- String ↔ num, int, double, bool
- Custom types via
builder
Implementation
static T? value<T>(
String key,
dynamic source, [
EntityBuilder<T>? builder,
]) {
final value = source is Map ? source[key] : null;
return _v(value, builder);
}