Struct PeekOptions
pub struct PeekOptions { /* private fields */ }std only.Expand description
Options of the functional peekers that read both sides of a bridge.
Implementations§
§impl PeekOptions
impl PeekOptions
pub fn new() -> PeekOptions
pub fn new() -> PeekOptions
Options using PeekPolicy::FAIL_OPEN, no scope and the default egress limit.
pub fn with_policy(self, policy: PeekPolicy) -> PeekOptions
pub fn with_policy(self, policy: PeekPolicy) -> PeekOptions
Set the PeekPolicy applied to cutoffs.
pub fn set_policy(&mut self, policy: PeekPolicy) -> &mut PeekOptions
pub fn set_policy(&mut self, policy: PeekPolicy) -> &mut PeekOptions
Set the PeekPolicy applied to cutoffs.
pub fn maybe_with_scope(self, scope: Option<WeakScope>) -> PeekOptions
pub fn maybe_with_scope(self, scope: Option<WeakScope>) -> PeekOptions
Set the scope that can cut the peek short, usually the scope the
input runs in, see scope_context.
pub fn maybe_set_scope(&mut self, scope: Option<WeakScope>) -> &mut PeekOptions
pub fn maybe_set_scope(&mut self, scope: Option<WeakScope>) -> &mut PeekOptions
Set the scope that can cut the peek short, usually the scope the
input runs in, see scope_context.
pub fn with_scope(self, scope: WeakScope) -> PeekOptions
pub fn with_scope(self, scope: WeakScope) -> PeekOptions
Set the scope that can cut the peek short, usually the scope the
input runs in, see scope_context.
pub fn set_scope(&mut self, scope: WeakScope) -> &mut PeekOptions
pub fn set_scope(&mut self, scope: WeakScope) -> &mut PeekOptions
Set the scope that can cut the peek short, usually the scope the
input runs in, see scope_context.
pub fn without_scope(self) -> PeekOptions
pub fn without_scope(self) -> PeekOptions
Set the scope that can cut the peek short, usually the scope the
input runs in, see scope_context.
pub fn unset_scope(&mut self) -> &mut PeekOptions
pub fn unset_scope(&mut self) -> &mut PeekOptions
Set the scope that can cut the peek short, usually the scope the
input runs in, see scope_context.
pub fn with_max_egress_peek_size(
self,
max_egress_peek_size: NonZero<usize>,
) -> PeekOptions
pub fn with_max_egress_peek_size( self, max_egress_peek_size: NonZero<usize>, ) -> PeekOptions
Set the byte limit for peeking the egress.
pub fn set_max_egress_peek_size(
&mut self,
max_egress_peek_size: NonZero<usize>,
) -> &mut PeekOptions
pub fn set_max_egress_peek_size( &mut self, max_egress_peek_size: NonZero<usize>, ) -> &mut PeekOptions
Set the byte limit for peeking the egress.
pub fn waiter<'a, E>(
&self,
egress: Option<&'a mut E>,
predicate: &'a dyn PeekEgressPredicate,
) -> PeekWaiter<'a>
pub fn waiter<'a, E>( &self, egress: Option<&'a mut E>, predicate: &'a dyn PeekEgressPredicate, ) -> PeekWaiter<'a>
A PeekWaiter reading egress, if any, judged by predicate.
Trait Implementations§
§impl Clone for PeekOptions
impl Clone for PeekOptions
§fn clone(&self) -> PeekOptions
fn clone(&self) -> PeekOptions
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more§impl Debug for PeekOptions
impl Debug for PeekOptions
§impl Default for PeekOptions
impl Default for PeekOptions
§fn default() -> PeekOptions
fn default() -> PeekOptions
Auto Trait Implementations§
impl !RefUnwindSafe for PeekOptions
impl !UnwindSafe for PeekOptions
impl Forget for PeekOptions
impl Freeze for PeekOptions
impl Move for PeekOptions
impl Send for PeekOptions
impl Sync for PeekOptions
impl Unpin for PeekOptions
impl UnsafeUnpin for PeekOptions
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a rama_grpc::Request§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§fn and<P, B, E>(self, other: P) -> And<T, P>
fn and<P, B, E>(self, other: P) -> And<T, P>
Policy that returns Action::Follow only if self and other return
Action::Follow. Read more