firstWhereOrNullMap method
Future<Map<String, dynamic> ?>
firstWhereOrNullMap({
- Iterable<
ColumnDefinition< ? columns(IEntity, dynamic> >- TMeta t
- List<
OrmOrder> ? orderBy(- TMeta t
- required Filter where(
- TMeta t
- int? offset,
- bool? useIsolate,
- Map<
String, dynamic> ? isolateArgs, - void onIsolatePreMap()?,
inherited
Implementation
@override
Future<Map<String, dynamic>?> firstWhereOrNullMap({
Iterable<ColumnDefinition>? Function(TMeta t)? columns,
List<OrmOrder>? Function(TMeta t)? orderBy,
required Filter Function(TMeta t) where,
int? offset,
final bool? useIsolate,
Map<String, dynamic>? isolateArgs,
void Function(Map<String, dynamic>? isolateArgs)? onIsolatePreMap,
}) async {
List<Map<String, dynamic>> maps = await queryMap(
where: where,
columns: columns ?? (t) => t.columns,
limit: 1,
offset: offset,
orderBy: orderBy,
useIsolate: useIsolate,
isolateArgs: isolateArgs,
onIsolatePreMap: onIsolatePreMap,
);
if (maps.isNotEmpty) {
return maps.first;
}
return null;
}