ModifyHeaderInfo constructor
ModifyHeaderInfo({
- required String header,
- required HeaderOperation operation,
- String? value,
- String? regexFilter,
- String? regexSubstitution,
- HeaderRegexOptions? regexOptions,
Implementation
ModifyHeaderInfo({
/// The name of the header to be modified.
required String header,
/// The operation to be performed on a header.
/// <!-- TODO(crbug.com/352093575): Make this field optional: It is ignored
/// if `regexSubstitution` is specified but is required otherwise. -->
required HeaderOperation operation,
/// The new value for the header. Must be specified for `append`
/// and `set` operations.
/// <!-- TODO(crbug.com/352093575): Ignored if `regexSubstitution` is
/// specified, -->
String? value,
/// A regular expression to match against the header value. This follows the
/// RE2 syntax for consistency with the rest of the API.
String? regexFilter,
/// Substitution pattern for the response header. `regexFilter` must be
/// specified for this to be valid. Takes precedence over `value` and
/// `operation` if specified and valid.
String? regexSubstitution,
/// Options for the regex filter. If not specified, all options will be
/// default.
HeaderRegexOptions? regexOptions,
}) : _wrapped = $js.ModifyHeaderInfo(
header: header,
operation: operation.toJS,
value: value,
regexFilter: regexFilter,
regexSubstitution: regexSubstitution,
regexOptions: regexOptions?.toJS,
);