copyWith method

RealtimeTool copyWith({
  1. String? type,
  2. String? name,
  3. Object? description = unsetCopyWithValue,
  4. Object? parameters = unsetCopyWithValue,
})

Returns a copy with the given fields replaced.

Pass null for description or parameters to clear the existing value.

Implementation

RealtimeTool copyWith({
  String? type,
  String? name,
  Object? description = unsetCopyWithValue,
  Object? parameters = unsetCopyWithValue,
}) => RealtimeTool(
  type: type ?? this.type,
  name: name ?? this.name,
  description: identical(description, unsetCopyWithValue)
      ? this.description
      : description as String?,
  parameters: identical(parameters, unsetCopyWithValue)
      ? this.parameters
      : parameters as Map<String, dynamic>?,
);