pub struct HeaderValueOption {
pub header: Option<HeaderValue>,
pub append: Option<BoolValue>,
pub append_action: i32,
pub keep_empty_value: bool,
}
Expand description
Header name/value pair plus option to control append behavior.
Fields§
§header: Option<HeaderValue>
Header name/value pair that this option applies to.
append: Option<BoolValue>
Should the value be appended? If true (default), the value is appended to
existing values. Otherwise it replaces any existing values.
This field is deprecated and please use
:ref:append_action <envoy_v3_api_field_config.core.v3.HeaderValueOption.append_action>
as replacement.
.. note::
The :ref:external authorization service <envoy_v3_api_msg_service.auth.v3.CheckResponse>
and
:ref:external processor service <envoy_v3_api_msg_service.ext_proc.v3.ProcessingResponse>
have
default value (false
) for this field.
append_action: i32
Describes the action taken to append/overwrite the given value for an existing header
or to only add this header if it’s absent.
Value defaults to :ref:APPEND_IF_EXISTS_OR_ADD <envoy_v3_api_enum_value_config.core.v3.HeaderValueOption.HeaderAppendAction.APPEND_IF_EXISTS_OR_ADD>
.
keep_empty_value: bool
Is the header value allowed to be empty? If false (default), custom headers with empty values are dropped, otherwise they are added.
Implementations§
Source§impl HeaderValueOption
impl HeaderValueOption
Sourcepub fn append_action(&self) -> HeaderAppendAction
pub fn append_action(&self) -> HeaderAppendAction
Returns the enum value of append_action
, or the default if the field is set to an invalid enum value.
Sourcepub fn set_append_action(&mut self, value: HeaderAppendAction)
pub fn set_append_action(&mut self, value: HeaderAppendAction)
Sets append_action
to the provided enum value.
Trait Implementations§
Source§impl Clone for HeaderValueOption
impl Clone for HeaderValueOption
Source§fn clone(&self) -> HeaderValueOption
fn clone(&self) -> HeaderValueOption
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for HeaderValueOption
impl Debug for HeaderValueOption
Source§impl Default for HeaderValueOption
impl Default for HeaderValueOption
Source§impl Message for HeaderValueOption
impl Message for HeaderValueOption
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
.Source§impl Name for HeaderValueOption
impl Name for HeaderValueOption
Source§const NAME: &'static str = "HeaderValueOption"
const NAME: &'static str = "HeaderValueOption"
Message
.
This name is the same as it appears in the source .proto file, e.g. FooBar
.Source§const PACKAGE: &'static str = "envoy.config.core.v3"
const PACKAGE: &'static str = "envoy.config.core.v3"
.
, e.g. google.protobuf
.Source§fn full_name() -> String
fn full_name() -> String
Message
.
It’s prefixed with the package name and names of any parent messages,
e.g. google.rpc.BadRequest.FieldViolation
.
By default, this is the package name followed by the message name.
Fully-qualified names must be unique within a domain of Type URLs.Source§impl PartialEq for HeaderValueOption
impl PartialEq for HeaderValueOption
impl StructuralPartialEq for HeaderValueOption
Auto Trait Implementations§
impl Freeze for HeaderValueOption
impl RefUnwindSafe for HeaderValueOption
impl Send for HeaderValueOption
impl Sync for HeaderValueOption
impl Unpin for HeaderValueOption
impl UnwindSafe for HeaderValueOption
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request