find method
Future<List<MethodInfo> >
find(
- Session session, {
- WhereExpressionBuilder<
MethodInfoTable> ? where, - int? limit,
- int? offset,
- OrderByBuilder<
MethodInfoTable> ? orderBy, - bool orderDescending = false,
- OrderByListBuilder<
MethodInfoTable> ? orderByList, - Transaction? transaction,
Returns a list of MethodInfos matching the given query parameters.
Use where
to specify which items to include in the return value.
If none is specified, all items will be returned.
To specify the order of the items use orderBy
or orderByList
when sorting by multiple columns.
The maximum number of items can be set by limit
. If no limit is set,
all items matching the query will be returned.
offset
defines how many items to skip, after which limit
(or all)
items are read from the database.
var persons = await Persons.db.find(
session,
where: (t) => t.lastName.equals('Jones'),
orderBy: (t) => t.firstName,
limit: 100,
);
Implementation
Future<List<MethodInfo>> find(
_i1.Session session, {
_i1.WhereExpressionBuilder<MethodInfoTable>? where,
int? limit,
int? offset,
_i1.OrderByBuilder<MethodInfoTable>? orderBy,
bool orderDescending = false,
_i1.OrderByListBuilder<MethodInfoTable>? orderByList,
_i1.Transaction? transaction,
}) async {
return session.db.find<MethodInfo>(
where: where?.call(MethodInfo.t),
orderBy: orderBy?.call(MethodInfo.t),
orderByList: orderByList?.call(MethodInfo.t),
orderDescending: orderDescending,
limit: limit,
offset: offset,
transaction: transaction,
);
}