1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
mod builder;
mod built;
mod multipart;
mod request_metadata;
pub use qiniu_http::SyncRequestBody;
use smart_default::SmartDefault;
use std::borrow::Cow;
#[cfg(feature = "async")]
pub use qiniu_http::AsyncRequestBody;
pub type QueryPairKey<'q> = Cow<'q, str>;
pub type QueryPairValue<'q> = Cow<'q, str>;
pub type QueryPair<'q> = (QueryPairKey<'q>, QueryPairValue<'q>);
#[derive(Clone, Copy, Debug, SmartDefault)]
#[non_exhaustive]
pub enum Idempotent {
Always,
#[default]
Default,
Never,
}
pub use builder::{RequestBuilder, RequestBuilderParts, RequestParts, SyncRequestBuilder};
pub(super) use built::{InnerRequest, InnerRequestParts};
pub use multipart::{FieldName, FileName, Multipart, Part, PartMetadata, SyncMultipart, SyncPart, SyncPartBody};
#[cfg(feature = "async")]
pub use {
builder::AsyncRequestBuilder,
multipart::{AsyncMultipart, AsyncPart, AsyncPartBody},
};
pub(super) type SyncInnerRequest<'r, E> = InnerRequest<'r, SyncRequestBody<'r>, E>;
#[cfg(feature = "async")]
#[cfg_attr(feature = "docs", doc(cfg(feature = "async")))]
pub(super) type AsyncInnerRequest<'r, E> = InnerRequest<'r, AsyncRequestBody<'r>, E>;