Skip to main content

HttpVersion

Type Alias HttpVersion 

Source
pub type HttpVersion = Version;
Expand description

HTTP 版本提取器

获取当前请求的 HTTP 版本(HTTP/1.0、HTTP/1.1、HTTP/2.0 等)。

Aliased Type§

pub struct HttpVersion(/* private fields */);

Trait Implementations§

Source§

impl<S> FromRequestParts<S> for HttpVersion

Source§

type Error = ExtractorError

提取过程中可能发生的错误
Source§

fn from_request_parts( parts: &RequestParts, _state: &S, ) -> Result<Self, Self::Error>

从请求中提取数据 Read more