pub enum VersionStrategy {
UrlPath,
Header(String),
QueryParam(String),
AcceptHeader,
}
Expand description
API versioning strategy
Variants§
UrlPath
Version specified in URL path (e.g., /api/v1/users)
Header(String)
Version specified in header (e.g., Api-Version: v1)
QueryParam(String)
Version specified in query parameter (e.g., ?version=v1)
AcceptHeader
Version specified in Accept header (e.g., Accept: application/vnd.api+json;version=1)
Trait Implementations§
Source§impl Clone for VersionStrategy
impl Clone for VersionStrategy
Source§fn clone(&self) -> VersionStrategy
fn clone(&self) -> VersionStrategy
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for VersionStrategy
impl Debug for VersionStrategy
Source§impl Default for VersionStrategy
impl Default for VersionStrategy
Source§impl<'de> Deserialize<'de> for VersionStrategy
impl<'de> Deserialize<'de> for VersionStrategy
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
Auto Trait Implementations§
impl Freeze for VersionStrategy
impl RefUnwindSafe for VersionStrategy
impl Send for VersionStrategy
impl Sync for VersionStrategy
impl Unpin for VersionStrategy
impl UnwindSafe for VersionStrategy
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