copyWith method

ApiLogOptions copyWith({
  1. bool? enabled,
  2. bool? request,
  3. bool? requestHeader,
  4. bool? requestBody,
  5. bool? responseHeader,
  6. bool? responseBody,
  7. bool? error,
  8. int? maxWidth,
  9. bool? compact,
  10. void logPrint(
    1. Object object
    )?,
})

Returns a copy with the given fields replaced.

Implementation

ApiLogOptions copyWith({
  bool? enabled,
  bool? request,
  bool? requestHeader,
  bool? requestBody,
  bool? responseHeader,
  bool? responseBody,
  bool? error,
  int? maxWidth,
  bool? compact,
  void Function(Object object)? logPrint,
}) {
  return ApiLogOptions(
    enabled: enabled ?? this.enabled,
    request: request ?? this.request,
    requestHeader: requestHeader ?? this.requestHeader,
    requestBody: requestBody ?? this.requestBody,
    responseHeader: responseHeader ?? this.responseHeader,
    responseBody: responseBody ?? this.responseBody,
    error: error ?? this.error,
    maxWidth: maxWidth ?? this.maxWidth,
    compact: compact ?? this.compact,
    logPrint: logPrint ?? this.logPrint,
  );
}