pub enum APIKeyLocation {
Query,
Header,
Cookie,
}Expand description
Where an API key is carried in a request.
The wire form is OpenAPI’s: one of "query", "header",
or "cookie". The proto’s string location accepts the
same three values; the enum rejects anything else at
the call site that constructs the value.
Variants§
Query
The key is a query parameter
(e.g. ?api_key=...).
Header
The key is an HTTP request header
(e.g. X-API-Key: ...).
Cookie
The key is a cookie
(e.g. Cookie: session=...).
Trait Implementations§
Source§impl Clone for APIKeyLocation
impl Clone for APIKeyLocation
impl Copy for APIKeyLocation
Source§impl Debug for APIKeyLocation
impl Debug for APIKeyLocation
Source§impl<'de> Deserialize<'de> for APIKeyLocation
impl<'de> Deserialize<'de> for APIKeyLocation
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 Eq for APIKeyLocation
Source§impl Hash for APIKeyLocation
impl Hash for APIKeyLocation
Source§impl PartialEq for APIKeyLocation
impl PartialEq for APIKeyLocation
Source§impl Serialize for APIKeyLocation
impl Serialize for APIKeyLocation
impl StructuralPartialEq for APIKeyLocation
Auto Trait Implementations§
impl Freeze for APIKeyLocation
impl RefUnwindSafe for APIKeyLocation
impl Send for APIKeyLocation
impl Sync for APIKeyLocation
impl Unpin for APIKeyLocation
impl UnsafeUnpin for APIKeyLocation
impl UnwindSafe for APIKeyLocation
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