copyWith method

Query copyWith({
  1. QueryAction? action,
  2. List<ProviderQuery<Provider<Model>>>? forProviders,
  3. int? limit,
  4. List<LimitBy>? limitBy,
  5. int? offset,
  6. List<OrderBy>? orderBy,
  7. @Deprecated('Use limit, offset, limitBy, orderBy, or forProviders instead.') Map<String, dynamic>? providerArgs,
  8. List<WhereCondition>? where,
})

Reconstruct the Query with passed overrides

Implementation

Query copyWith({
  QueryAction? action,
  List<ProviderQuery>? forProviders,
  int? limit,
  List<LimitBy>? limitBy,
  int? offset,
  List<OrderBy>? orderBy,
  @Deprecated('Use limit, offset, limitBy, orderBy, or forProviders instead.')
  Map<String, dynamic>? providerArgs,
  List<WhereCondition>? where,
}) =>
    Query(
      action: action ?? this.action,
      forProviders: forProviders ?? this.forProviders,
      limit: limit ?? this.limit,
      limitBy: limitBy ?? this.limitBy,
      offset: offset ?? this.offset,
      orderBy: orderBy ?? this.orderBy,
      providerArgs: providerArgs ?? this.providerArgs,
      where: where ?? this.where,
    );