2016-10-18 02:29:58 +00:00
|
|
|
//! Re-exported hyper HTTP library types.
|
|
|
|
//!
|
2017-01-27 07:08:15 +00:00
|
|
|
//! All types that are re-exported from Hyper reside inside of this module.
|
2016-10-18 02:29:58 +00:00
|
|
|
//! These types will, with certainty, be removed with time, but they reside here
|
|
|
|
//! while necessary.
|
|
|
|
|
2021-07-02 13:48:40 +00:00
|
|
|
#[doc(hidden)] pub use hyper::{Body, Error, Request, Response, Version};
|
2019-12-11 00:34:23 +00:00
|
|
|
#[doc(hidden)] pub use hyper::body::{Bytes, HttpBody, Sender as BodySender};
|
|
|
|
#[doc(hidden)] pub use hyper::rt::Executor;
|
2020-12-24 01:02:40 +00:00
|
|
|
#[doc(hidden)] pub use hyper::server::Server;
|
2019-12-11 00:34:23 +00:00
|
|
|
#[doc(hidden)] pub use hyper::service::{make_service_fn, service_fn, Service};
|
2019-05-19 17:58:19 +00:00
|
|
|
|
2019-06-30 16:45:17 +00:00
|
|
|
#[doc(hidden)] pub use http::header::HeaderMap;
|
2019-05-19 17:58:19 +00:00
|
|
|
#[doc(hidden)] pub use http::header::HeaderName as HeaderName;
|
|
|
|
#[doc(hidden)] pub use http::header::HeaderValue as HeaderValue;
|
|
|
|
#[doc(hidden)] pub use http::method::Method;
|
2019-06-30 16:45:17 +00:00
|
|
|
#[doc(hidden)] pub use http::request::Parts as RequestParts;
|
|
|
|
#[doc(hidden)] pub use http::response::Builder as ResponseBuilder;
|
2019-05-19 17:58:19 +00:00
|
|
|
#[doc(hidden)] pub use http::status::StatusCode;
|
2019-12-15 19:01:10 +00:00
|
|
|
#[doc(hidden)] pub use http::uri::{Uri, Parts as UriParts};
|
2017-01-27 07:08:15 +00:00
|
|
|
|
2019-06-30 16:45:17 +00:00
|
|
|
/// Reexported http header types.
|
2017-01-27 07:08:15 +00:00
|
|
|
pub mod header {
|
2019-06-30 16:45:17 +00:00
|
|
|
macro_rules! import_http_headers {
|
2017-01-27 07:08:15 +00:00
|
|
|
($($name:ident),*) => ($(
|
2019-05-19 17:58:19 +00:00
|
|
|
pub use http::header::$name as $name;
|
2017-01-27 07:08:15 +00:00
|
|
|
)*)
|
|
|
|
}
|
|
|
|
|
2019-06-30 16:45:17 +00:00
|
|
|
import_http_headers! {
|
|
|
|
ACCEPT, ACCEPT_CHARSET, ACCEPT_ENCODING, ACCEPT_LANGUAGE, ACCEPT_RANGES,
|
|
|
|
ACCESS_CONTROL_ALLOW_CREDENTIALS, ACCESS_CONTROL_ALLOW_HEADERS,
|
2019-05-19 17:58:19 +00:00
|
|
|
ACCESS_CONTROL_ALLOW_METHODS, ACCESS_CONTROL_ALLOW_ORIGIN,
|
|
|
|
ACCESS_CONTROL_EXPOSE_HEADERS, ACCESS_CONTROL_MAX_AGE,
|
2019-06-30 16:45:17 +00:00
|
|
|
ACCESS_CONTROL_REQUEST_HEADERS, ACCESS_CONTROL_REQUEST_METHOD, ALLOW,
|
|
|
|
AUTHORIZATION, CACHE_CONTROL, CONNECTION, CONTENT_DISPOSITION,
|
|
|
|
CONTENT_ENCODING, CONTENT_LANGUAGE, CONTENT_LENGTH, CONTENT_LOCATION,
|
|
|
|
CONTENT_RANGE, CONTENT_SECURITY_POLICY,
|
|
|
|
CONTENT_SECURITY_POLICY_REPORT_ONLY, CONTENT_TYPE, DATE, ETAG, EXPECT,
|
|
|
|
EXPIRES, FORWARDED, FROM, HOST, IF_MATCH, IF_MODIFIED_SINCE,
|
|
|
|
IF_NONE_MATCH, IF_RANGE, IF_UNMODIFIED_SINCE, LAST_MODIFIED, LINK,
|
|
|
|
LOCATION, ORIGIN, PRAGMA, RANGE, REFERER, REFERRER_POLICY, REFRESH,
|
|
|
|
STRICT_TRANSPORT_SECURITY, TE, TRANSFER_ENCODING, UPGRADE, USER_AGENT,
|
|
|
|
VARY
|
2017-01-27 07:08:15 +00:00
|
|
|
}
|
|
|
|
}
|