Export Body and RequestBuilder for client wrappers
This commit is contained in:
		| @@ -1,10 +1,12 @@ | |||||||
| use std::io::Read; | use std::io::Read; | ||||||
|  |  | ||||||
|  | /// Body type for a request. | ||||||
| pub struct Body { | pub struct Body { | ||||||
|     reader: Kind, |     reader: Kind, | ||||||
| } | } | ||||||
|  |  | ||||||
| impl Body { | impl Body { | ||||||
|  |     /// Instantiate a `Body` from a reader. | ||||||
|     pub fn new<R: Read + 'static>(reader: R) -> Body { |     pub fn new<R: Read + 'static>(reader: R) -> Body { | ||||||
|         Body { |         Body { | ||||||
|             reader: Kind::Reader(Box::new(reader), None), |             reader: Kind::Reader(Box::new(reader), None), | ||||||
|   | |||||||
| @@ -47,8 +47,9 @@ pub use hyper::version::HttpVersion; | |||||||
| pub use hyper::Url; | pub use hyper::Url; | ||||||
| pub use url::ParseError as UrlError; | pub use url::ParseError as UrlError; | ||||||
|  |  | ||||||
| pub use self::client::{Client, Response}; | pub use self::client::{Client, Response, RequestBuilder}; | ||||||
| pub use self::error::{Error, Result}; | pub use self::error::{Error, Result}; | ||||||
|  | pub use self::body::Body; | ||||||
|  |  | ||||||
| mod body; | mod body; | ||||||
| mod client; | mod client; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user