#include "components/assist_ranker/ranker_url_fetcher.h"
#include "base/functional/bind.h"
#include "base/memory/ref_counted.h"
#include "net/base/load_flags.h"
#include "net/http/http_status_code.h"
#include "net/traffic_annotation/network_traffic_annotation.h"
#include "services/network/public/cpp/resource_request.h"
#include "services/network/public/cpp/simple_url_loader.h"
#include "services/network/public/mojom/url_loader_factory.mojom.h"
namespace assist_ranker {
namespace {
const int kMaxRetry = …;
}
RankerURLFetcher::RankerURLFetcher()
: … { … }
RankerURLFetcher::~RankerURLFetcher() { … }
bool RankerURLFetcher::Request(
const GURL& url,
RankerURLFetcher::Callback callback,
network::mojom::URLLoaderFactory* url_loader_factory) { … }
void RankerURLFetcher::OnSimpleLoaderComplete(
std::unique_ptr<std::string> response_body) { … }
}