copyWith method
A copy with the given fields replaced (null = keep current).
Implementation
RedactionConfig copyWith({
bool? enabled,
bool? blockMode,
Map<RedactionLayer, bool>? layerToggles,
List<RegExp>? allowlistRegexes,
double? minEntropy,
int? minLength,
Set<String>? toolAllow,
Set<String>? toolDeny,
}) {
return RedactionConfig(
enabled: enabled ?? this.enabled,
blockMode: blockMode ?? this.blockMode,
layerToggles: layerToggles ?? this.layerToggles,
allowlistRegexes: allowlistRegexes ?? this.allowlistRegexes,
minEntropy: minEntropy ?? this.minEntropy,
minLength: minLength ?? this.minLength,
toolAllow: toolAllow ?? this.toolAllow,
toolDeny: toolDeny ?? this.toolDeny,
);
}