mirror of
https://github.com/servo/servo.git
synced 2025-08-11 08:25:32 +01:00
sort all uses
This commit is contained in:
parent
d3c7e31722
commit
ec07178b6f
269 changed files with 903 additions and 931 deletions
|
@ -2,16 +2,16 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use net_traits::{LoadData, Metadata, LoadConsumer};
|
||||
use net_traits::ProgressMsg::Done;
|
||||
use mime_classifier::MIMEClassifier;
|
||||
use resource_task::start_sending;
|
||||
use file_loader;
|
||||
use mime_classifier::MIMEClassifier;
|
||||
use net_traits::ProgressMsg::Done;
|
||||
use net_traits::{LoadData, Metadata, LoadConsumer};
|
||||
use resource_task::start_sending;
|
||||
|
||||
use url::Url;
|
||||
use hyper::header::ContentType;
|
||||
use hyper::http::RawStatus;
|
||||
use hyper::mime::{Mime, TopLevel, SubLevel};
|
||||
use url::Url;
|
||||
use util::resource_files::resources_dir_path;
|
||||
|
||||
use std::fs::PathExt;
|
||||
|
|
|
@ -9,10 +9,10 @@ use net_traits::CookieSource;
|
|||
use pub_domains::PUB_DOMAINS;
|
||||
|
||||
use cookie_rs;
|
||||
use time::{Tm, now, at, Duration};
|
||||
use url::Url;
|
||||
use std::borrow::ToOwned;
|
||||
use std::net::{Ipv4Addr, Ipv6Addr};
|
||||
use time::{Tm, now, at, Duration};
|
||||
use url::Url;
|
||||
|
||||
/// A stored cookie that wraps the definition in cookie-rs. This is used to implement
|
||||
/// various behaviours defined in the spec that rely on an associated request URL,
|
||||
|
|
|
@ -5,10 +5,10 @@
|
|||
//! Implementation of cookie storage as specified in
|
||||
//! http://tools.ietf.org/html/rfc6265
|
||||
|
||||
use net_traits::CookieSource;
|
||||
use url::Url;
|
||||
use cookie::Cookie;
|
||||
use net_traits::CookieSource;
|
||||
use std::cmp::Ordering;
|
||||
use url::Url;
|
||||
|
||||
pub struct CookieStorage {
|
||||
cookies: Vec<Cookie>
|
||||
|
|
|
@ -2,17 +2,17 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use net_traits::{LoadData, Metadata, LoadConsumer};
|
||||
use net_traits::ProgressMsg::{Payload, Done};
|
||||
use mime_classifier::MIMEClassifier;
|
||||
use net_traits::ProgressMsg::{Payload, Done};
|
||||
use net_traits::{LoadData, Metadata, LoadConsumer};
|
||||
use resource_task::start_sending;
|
||||
|
||||
use rustc_serialize::base64::FromBase64;
|
||||
|
||||
use hyper::mime::Mime;
|
||||
use std::sync::Arc;
|
||||
use url::percent_encoding::percent_decode;
|
||||
use url::SchemeData;
|
||||
use url::percent_encoding::percent_decode;
|
||||
|
||||
pub fn factory(load_data: LoadData, senders: LoadConsumer, _classifier: Arc<MIMEClassifier>) {
|
||||
// NB: we don't spawn a new task.
|
||||
|
|
|
@ -2,18 +2,18 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use url::Url;
|
||||
use hyper::method::Method;
|
||||
use hyper::mime::{Mime, TopLevel, SubLevel, Attr, Value};
|
||||
use hyper::header::{Header, Headers, ContentType, IfModifiedSince, IfNoneMatch};
|
||||
use hyper::header::{Accept, IfUnmodifiedSince, IfMatch, IfRange, Location};
|
||||
use hyper::header::{HeaderView, AcceptLanguage, ContentLanguage};
|
||||
use hyper::header::{QualityItem, qitem, q};
|
||||
use hyper::status::StatusCode;
|
||||
use fetch::cors_cache::{CORSCache, CacheRequestDetails};
|
||||
use fetch::response::{Response, ResponseType};
|
||||
use hyper::header::{Accept, IfUnmodifiedSince, IfMatch, IfRange, Location};
|
||||
use hyper::header::{Header, Headers, ContentType, IfModifiedSince, IfNoneMatch};
|
||||
use hyper::header::{HeaderView, AcceptLanguage, ContentLanguage};
|
||||
use hyper::header::{QualityItem, qitem, q};
|
||||
use hyper::method::Method;
|
||||
use hyper::mime::{Mime, TopLevel, SubLevel, Attr, Value};
|
||||
use hyper::status::StatusCode;
|
||||
use std::ascii::AsciiExt;
|
||||
use std::str::FromStr;
|
||||
use url::Url;
|
||||
|
||||
/// A [request context](https://fetch.spec.whatwg.org/#concept-request-context)
|
||||
#[derive(Copy, Clone, PartialEq)]
|
||||
|
|
|
@ -2,11 +2,11 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use url::Url;
|
||||
use hyper::status::StatusCode;
|
||||
use hyper::header::Headers;
|
||||
use hyper::status::StatusCode;
|
||||
use std::ascii::AsciiExt;
|
||||
use std::sync::mpsc::Receiver;
|
||||
use url::Url;
|
||||
|
||||
/// [Response type](https://fetch.spec.whatwg.org/#concept-response-type)
|
||||
#[derive(Clone, PartialEq, Copy)]
|
||||
|
|
|
@ -2,9 +2,9 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use net_traits::{LoadData, Metadata, LoadConsumer};
|
||||
use net_traits::ProgressMsg::{Payload, Done};
|
||||
use mime_classifier::MIMEClassifier;
|
||||
use net_traits::ProgressMsg::{Payload, Done};
|
||||
use net_traits::{LoadData, Metadata, LoadConsumer};
|
||||
use resource_task::{start_sending, start_sending_sniffed, ProgressSender};
|
||||
|
||||
use std::borrow::ToOwned;
|
||||
|
|
|
@ -2,10 +2,10 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use net_traits::{IncludeSubdomains, IPV4_REGEX, IPV6_REGEX};
|
||||
use rustc_serialize::json::{decode};
|
||||
use time;
|
||||
use url::Url;
|
||||
use net_traits::{IncludeSubdomains, IPV4_REGEX, IPV6_REGEX};
|
||||
|
||||
use std::str::{from_utf8};
|
||||
|
||||
|
|
|
@ -2,41 +2,41 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use net_traits::{ControlMsg, CookieSource, LoadData, Metadata, LoadConsumer, IncludeSubdomains};
|
||||
use devtools_traits::{ChromeToDevtoolsControlMsg, DevtoolsControlMsg, NetworkEvent};
|
||||
use hsts::{HSTSList, secure_url};
|
||||
use mime_classifier::MIMEClassifier;
|
||||
use net_traits::ProgressMsg::{Payload, Done};
|
||||
use net_traits::hosts::replace_hosts;
|
||||
use devtools_traits::{ChromeToDevtoolsControlMsg, DevtoolsControlMsg, NetworkEvent};
|
||||
use mime_classifier::MIMEClassifier;
|
||||
use net_traits::{ControlMsg, CookieSource, LoadData, Metadata, LoadConsumer, IncludeSubdomains};
|
||||
use resource_task::{start_sending_opt, start_sending_sniffed_opt};
|
||||
use hsts::{HSTSList, secure_url};
|
||||
|
||||
use ipc_channel::ipc::{self, IpcSender};
|
||||
use log;
|
||||
use std::collections::HashSet;
|
||||
use file_loader;
|
||||
use flate2::read::{DeflateDecoder, GzDecoder};
|
||||
use hyper::client::Request;
|
||||
use hyper::header::{AcceptEncoding, Accept, ContentLength, ContentType, Host, Location, qitem, Quality, QualityItem};
|
||||
use hyper::header::StrictTransportSecurity;
|
||||
use hyper::Error as HttpError;
|
||||
use hyper::client::Request;
|
||||
use hyper::header::StrictTransportSecurity;
|
||||
use hyper::header::{AcceptEncoding, Accept, ContentLength, ContentType, Host, Location, qitem, Quality, QualityItem};
|
||||
use hyper::method::Method;
|
||||
use hyper::mime::{Mime, TopLevel, SubLevel};
|
||||
use hyper::net::{HttpConnector, HttpsConnector, Openssl};
|
||||
use hyper::status::{StatusCode, StatusClass};
|
||||
use std::error::Error;
|
||||
use ipc_channel::ipc::{self, IpcSender};
|
||||
use log;
|
||||
use openssl::ssl::{SslContext, SslMethod, SSL_VERIFY_PEER};
|
||||
use std::collections::HashSet;
|
||||
use std::error::Error;
|
||||
use std::io::{self, Read, Write};
|
||||
use std::sync::Arc;
|
||||
use std::sync::Mutex;
|
||||
use std::sync::mpsc::{Sender, channel};
|
||||
use util::task::spawn_named;
|
||||
use util::resource_files::resources_dir_path;
|
||||
use util::opts;
|
||||
use url::{Url, UrlParser};
|
||||
use util::opts;
|
||||
use util::resource_files::resources_dir_path;
|
||||
use util::task::spawn_named;
|
||||
|
||||
use uuid;
|
||||
use std::borrow::ToOwned;
|
||||
use std::boxed::FnBox;
|
||||
use uuid;
|
||||
|
||||
pub fn factory(resource_mgr_chan: IpcSender<ControlMsg>,
|
||||
devtools_chan: Option<Sender<DevtoolsControlMsg>>,
|
||||
|
|
|
@ -5,21 +5,21 @@
|
|||
use ipc_channel::ipc::{self, IpcSender};
|
||||
use ipc_channel::router::ROUTER;
|
||||
use net_traits::image::base::{Image, load_from_memory};
|
||||
use net_traits::image_cache_task::{ImageState, ImageCacheTask, ImageCacheChan, ImageCacheCommand};
|
||||
use net_traits::image_cache_task::ImageResponder;
|
||||
use net_traits::image_cache_task::{ImageCacheResult, ImageResponse, UsePlaceholder};
|
||||
use net_traits::image_cache_task::{ImageState, ImageCacheTask, ImageCacheChan, ImageCacheCommand};
|
||||
use net_traits::load_whole_resource;
|
||||
use net_traits::{AsyncResponseTarget, ControlMsg, LoadData, ResponseAction, ResourceTask, LoadConsumer};
|
||||
use std::borrow::ToOwned;
|
||||
use std::collections::HashMap;
|
||||
use std::collections::hash_map::Entry::{Occupied, Vacant};
|
||||
use std::mem;
|
||||
use std::sync::Arc;
|
||||
use std::sync::mpsc::{channel, Sender, Receiver, Select};
|
||||
use url::Url;
|
||||
use util::resource_files::resources_dir_path;
|
||||
use util::task::spawn_named;
|
||||
use util::taskpool::TaskPool;
|
||||
use url::Url;
|
||||
use net_traits::{AsyncResponseTarget, ControlMsg, LoadData, ResponseAction, ResourceTask, LoadConsumer};
|
||||
use net_traits::image_cache_task::ImageResponder;
|
||||
|
||||
///
|
||||
/// TODO(gw): Remaining work on image cache:
|
||||
|
|
|
@ -5,19 +5,19 @@
|
|||
//! A task that takes a URL and streams back the binary data.
|
||||
|
||||
use about_loader;
|
||||
use cookie;
|
||||
use cookie_storage::CookieStorage;
|
||||
use data_loader;
|
||||
use file_loader;
|
||||
use http_loader;
|
||||
use cookie_storage::CookieStorage;
|
||||
use cookie;
|
||||
use mime_classifier::MIMEClassifier;
|
||||
|
||||
use net_traits::ProgressMsg::Done;
|
||||
use net_traits::{ControlMsg, LoadData, LoadResponse, LoadConsumer, CookieSource};
|
||||
use net_traits::{Metadata, ProgressMsg, ResourceTask, AsyncResponseTarget, ResponseAction};
|
||||
use net_traits::ProgressMsg::Done;
|
||||
use url::Url;
|
||||
use util::opts;
|
||||
use util::task::spawn_named;
|
||||
use url::Url;
|
||||
|
||||
use hsts::{HSTSList, HSTSEntry, preload_hsts_domains};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue