#[repr(i32)]pub enum PathRuleKind {
Prefix = 0,
Regex = 1,
Equals = 2,
RegexPath = 3,
}Expand description
The kind of filter used for path rules
Variants§
Prefix = 0
filters paths that start with a pattern, typically “/api”
Regex = 1
filters paths that match a regex pattern
Equals = 2
filters paths that exactly match a pattern, no more, no less
RegexPath = 3
filters paths that match a regex pattern, anchored at both ends like
REGEX, but tested against the path ALONE: the request-target up to
its first ? (sozu-proxy/sozu#1909, Gateway API RegularExpression
path match). REGEX keeps matching the path together with its query
string. Its $PATH\[n\] rewrite captures come from that path-only
match, and the request’s original ?query is appended to a rewritten
path that carries no ? of its own.
Implementations§
Source§impl PathRuleKind
impl PathRuleKind
Source§impl PathRuleKind
impl PathRuleKind
Sourcepub fn as_str_name(&self) -> &'static str
pub fn as_str_name(&self) -> &'static str
String value of the enum field names used in the ProtoBuf definition.
The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.
Sourcepub fn from_str_name(value: &str) -> Option<Self>
pub fn from_str_name(value: &str) -> Option<Self>
Creates an enum from field names used in the ProtoBuf definition.
Trait Implementations§
Source§impl Clone for PathRuleKind
impl Clone for PathRuleKind
impl Copy for PathRuleKind
Source§impl Debug for PathRuleKind
impl Debug for PathRuleKind
Source§impl Default for PathRuleKind
impl Default for PathRuleKind
Source§fn default() -> PathRuleKind
fn default() -> PathRuleKind
Source§impl<'de> Deserialize<'de> for PathRuleKind
impl<'de> Deserialize<'de> for PathRuleKind
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for PathRuleKind
Source§impl From<PathRuleKind> for i32
impl From<PathRuleKind> for i32
Source§fn from(value: PathRuleKind) -> i32
fn from(value: PathRuleKind) -> i32
Source§impl Hash for PathRuleKind
impl Hash for PathRuleKind
Source§impl Ord for PathRuleKind
impl Ord for PathRuleKind
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for PathRuleKind
impl PartialEq for PathRuleKind
Source§impl PartialOrd for PathRuleKind
impl PartialOrd for PathRuleKind
Source§impl Serialize for PathRuleKind
impl Serialize for PathRuleKind
impl StructuralPartialEq for PathRuleKind
Source§impl TryFrom<i32> for PathRuleKind
impl TryFrom<i32> for PathRuleKind
Source§type Error = UnknownEnumValue
type Error = UnknownEnumValue
Source§fn try_from(value: i32) -> Result<PathRuleKind, UnknownEnumValue>
fn try_from(value: i32) -> Result<PathRuleKind, UnknownEnumValue>
Auto Trait Implementations§
impl Freeze for PathRuleKind
impl RefUnwindSafe for PathRuleKind
impl Send for PathRuleKind
impl Sync for PathRuleKind
impl Unpin for PathRuleKind
impl UnsafeUnpin for PathRuleKind
impl UnwindSafe for PathRuleKind
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.