#[non_exhaustive]pub struct Http {
pub rules: Vec<HttpRule>,
pub fully_decode_reserved_expansion: bool,
}Expand description
Defines the HTTP configuration for an API service. It contains a list of HttpRule, each specifying the mapping of an RPC method to one or more HTTP REST API methods.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.rules: Vec<HttpRule>A list of HTTP configuration rules that apply to individual API methods.
NOTE: All service configuration rules follow “last one wins” order.
fully_decode_reserved_expansion: boolWhen set to true, URL path parameters will be fully URI-decoded except in cases of single segment matches in reserved expansion, where “%2F” will be left encoded.
The default behavior is to not decode RFC 6570 reserved characters in multi segment matches.
Implementations§
Source§impl Http
impl Http
Sourcepub fn set_fully_decode_reserved_expansion<T: Into<bool>>(self, v: T) -> Self
pub fn set_fully_decode_reserved_expansion<T: Into<bool>>(self, v: T) -> Self
Sets the value of fully_decode_reserved_expansion.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Http
impl<'de> Deserialize<'de> for Http
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>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Http
Auto Trait Implementations§
impl Freeze for Http
impl RefUnwindSafe for Http
impl Send for Http
impl Sync for Http
impl Unpin for Http
impl UnwindSafe for Http
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
Mutably borrows from an owned value. Read more