Definition of Response and related enums/concepts

This commit is contained in:
Manish Goregaokar 2014-07-30 23:28:49 +05:30
parent 56e735ee79
commit e678943939
3 changed files with 105 additions and 4 deletions

View file

@ -53,8 +53,7 @@ pub enum ResponseTainting {
Opaque // Opaque
}
/// A Request as defined by the [Fetch spec](http://fetch.spec.whatwg.org/#requests)
///
/// A [Request](http://fetch.spec.whatwg.org/#requests) as defined by the Fetch spec
pub struct Request {
pub method: Method,
pub url: Url,
@ -82,7 +81,7 @@ pub struct Request {
}
impl Request {
fn new(url: Url, context: Context) -> Request {
pub fn new(url: Url, context: Context) -> Request {
Request {
method: Get,
url: url,