selectIDsBy<I extends Object> method
FutureOr<Iterable<I> >
selectIDsBy<I extends Object>(
- EntityMatcher matcher, {
- Object? parameters,
- List? positionalParameters,
- Map<
String, Object?> ? namedParameters, - Transaction? transaction,
- int? limit,
override
Implementation
@override
FutureOr<Iterable<I>> selectIDsBy<I extends Object>(
EntityMatcher matcher, {
Object? parameters,
List? positionalParameters,
Map<String, Object?>? namedParameters,
Transaction? transaction,
int? limit,
}) {
if (matcher is ConditionID) {
var id = matcher.resolveIDValue(
parameters: parameters ?? namedParameters,
);
return existsID(
id,
transaction: transaction,
).resolveMapped((exists) => exists ? [id] : []);
}
if (matcher is ConditionIdIN) {
var ids = matcher.idsValues.whereType<I>().toList();
return existIDs(ids, transaction: transaction);
}
throw UnsupportedError(
"Relationship select not supported for: (${matcher.runtimeTypeNameUnsafe}) $matcher @ $tableName ($this)",
);
}