copyWith method

SafetyEvaluation copyWith({
  1. bool? isUnsafe,
  2. String? llmReason,
  3. int? safetyPromptVersion,
  4. List<SafetyRule>? matchedRuleId,
})

Implementation

SafetyEvaluation copyWith(
    {bool? isUnsafe,
    String? llmReason,
    int? safetyPromptVersion,
    List<enums.SafetyRule>? matchedRuleId}) {
  return SafetyEvaluation(
      isUnsafe: isUnsafe ?? this.isUnsafe,
      llmReason: llmReason ?? this.llmReason,
      safetyPromptVersion: safetyPromptVersion ?? this.safetyPromptVersion,
      matchedRuleId: matchedRuleId ?? this.matchedRuleId);
}