Reporting: Wire ReportingDelegate into ChromeNetworkDelegate

https://codereview.chromium.org/2891133003
This commit is contained in:
deepak1556 2017-08-24 00:50:08 +03:00 committed by Cheng Zhao
parent 7d1c1700f8
commit 12a4321e2b
2 changed files with 30 additions and 0 deletions

View file

@ -147,4 +147,28 @@ bool NetworkDelegate::OnCancelURLRequestWithPolicyViolatingReferrerHeader(
return false;
}
// TODO(deepak1556) : Enable after hooking into the reporting service
// https://crbug.com/704259
bool NetworkDelegate::OnCanQueueReportingReport(
const url::Origin& origin) const {
return false;
}
bool NetworkDelegate::OnCanSendReportingReport(
const url::Origin& origin) const {
return false;
}
bool NetworkDelegate::OnCanSetReportingClient(
const url::Origin& origin,
const GURL& endpoint) const {
return false;
}
bool NetworkDelegate::OnCanUseReportingClient(
const url::Origin& origin,
const GURL& endpoint) const {
return false;
}
} // namespace brightray

View file

@ -68,6 +68,12 @@ class NetworkDelegate : public net::NetworkDelegate {
const net::URLRequest& request,
const GURL& target_url,
const GURL& referrer_url) const override;
bool OnCanQueueReportingReport(const url::Origin& origin) const override;
bool OnCanSendReportingReport(const url::Origin& origin) const override;
bool OnCanSetReportingClient(const url::Origin& origin,
const GURL& endpoint) const override;
bool OnCanUseReportingClient(const url::Origin& origin,
const GURL& endpoint) const override;
private:
std::vector<std::string> ignore_connections_limit_domains_;