copyWith method

RequestDetails copyWith({
  1. String? requestName,
  2. String? requestMethod,
  3. String? url,
  4. int? statusCode,
  5. dynamic headers,
  6. dynamic requestBody,
  7. dynamic responseBody,
  8. DateTime? sentTime,
})

Implementation

RequestDetails copyWith({
  String? requestName,
  String? requestMethod,
  String? url,
  int? statusCode,
  headers,
  requestBody,
  responseBody,
  DateTime? sentTime,
}) {
  return RequestDetails(
    requestName: requestName ?? this.requestName,
    requestMethod: requestMethod ?? this.requestMethod,
    url: url ?? this.url,
    statusCode: statusCode ?? this.statusCode,
    headers: headers ?? this.headers,
    requestBody: requestBody ?? this.requestBody,
    responseBody: responseBody ?? this.responseBody,
    sentTime: sentTime ?? this.sentTime,
  );
}