#include "components/no_state_prefetch/common/no_state_prefetch_url_loader_throttle.h"
#include "base/functional/bind.h"
#include "base/location.h"
#include "base/task/sequenced_task_runner.h"
#include "build/build_config.h"
#include "components/no_state_prefetch/common/no_state_prefetch_utils.h"
#include "content/public/common/content_constants.h"
#include "mojo/public/cpp/bindings/remote.h"
#include "net/base/load_flags.h"
#include "net/url_request/redirect_info.h"
#include "services/network/public/cpp/resource_request.h"
#include "services/network/public/mojom/url_response_head.mojom.h"
#include "third_party/blink/public/common/loader/resource_type_util.h"
namespace prerender {
namespace {
const char kPurposeHeaderName[] = …;
const char kPurposeHeaderValue[] = …;
void CallCancelPrerenderForUnsupportedScheme(
mojo::PendingRemote<prerender::mojom::PrerenderCanceler> canceler) { … }
}
NoStatePrefetchURLLoaderThrottle::NoStatePrefetchURLLoaderThrottle(
mojo::PendingRemote<prerender::mojom::PrerenderCanceler> canceler)
: … { … }
NoStatePrefetchURLLoaderThrottle::~NoStatePrefetchURLLoaderThrottle() { … }
void NoStatePrefetchURLLoaderThrottle::DetachFromCurrentSequence() { … }
void NoStatePrefetchURLLoaderThrottle::WillStartRequest(
network::ResourceRequest* request,
bool* defer) { … }
const char* NoStatePrefetchURLLoaderThrottle::NameForLoggingWillStartRequest() { … }
void NoStatePrefetchURLLoaderThrottle::WillRedirectRequest(
net::RedirectInfo* redirect_info,
const network::mojom::URLResponseHead& response_head,
bool* defer,
std::vector<std::string>* ,
net::HttpRequestHeaders* ,
net::HttpRequestHeaders* ) { … }
void NoStatePrefetchURLLoaderThrottle::OnTimedOut() { … }
}