Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(169)

Unified Diff: net/http/http_server_properties_manager.cc

Issue 1018943002: Update HttpServerProperties::*AlternateProtocol* interface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/http/http_server_properties_manager.cc
diff --git a/net/http/http_server_properties_manager.cc b/net/http/http_server_properties_manager.cc
index 5ff11633a55593b67ea2fb0e5655bb86ddf62bc6..3c20bfdc2439b0734ddc44e4a85633d13702fb25 100644
--- a/net/http/http_server_properties_manager.cc
+++ b/net/http/http_server_properties_manager.cc
@@ -186,21 +186,21 @@ AlternativeService HttpServerPropertiesManager::GetAlternativeService(
return http_server_properties_impl_->GetAlternativeService(origin);
}
-void HttpServerPropertiesManager::SetAlternateProtocol(
+void HttpServerPropertiesManager::SetAlternativeService(
const HostPortPair& origin,
- uint16 alternate_port,
- AlternateProtocol alternate_protocol,
- double alternate_probability) {
+ const AlternativeService& alternative_service,
+ double alternative_probability) {
DCHECK(network_task_runner_->RunsTasksOnCurrentThread());
- http_server_properties_impl_->SetAlternateProtocol(
- origin, alternate_port, alternate_protocol, alternate_probability);
+ http_server_properties_impl_->SetAlternativeService(
+ origin, alternative_service, alternative_probability);
ScheduleUpdatePrefsOnNetworkThread();
}
-void HttpServerPropertiesManager::SetBrokenAlternateProtocol(
- const HostPortPair& origin) {
+void HttpServerPropertiesManager::MarkAlternativeServiceBroken(
+ const AlternativeService& alternative_service) {
DCHECK(network_task_runner_->RunsTasksOnCurrentThread());
- http_server_properties_impl_->SetBrokenAlternateProtocol(origin);
+ http_server_properties_impl_->MarkAlternativeServiceBroken(
+ alternative_service);
ScheduleUpdatePrefsOnNetworkThread();
}
@@ -219,24 +219,24 @@ bool HttpServerPropertiesManager::IsAlternativeServiceBroken(
alternative_service);
}
-bool HttpServerPropertiesManager::WasAlternateProtocolRecentlyBroken(
- const HostPortPair& origin) {
+bool HttpServerPropertiesManager::WasAlternativeServiceRecentlyBroken(
+ const AlternativeService& alternative_service) {
DCHECK(network_task_runner_->RunsTasksOnCurrentThread());
- return http_server_properties_impl_->WasAlternateProtocolRecentlyBroken(
- origin);
+ return http_server_properties_impl_->WasAlternativeServiceRecentlyBroken(
+ alternative_service);
}
-void HttpServerPropertiesManager::ConfirmAlternateProtocol(
- const HostPortPair& origin) {
+void HttpServerPropertiesManager::ConfirmAlternativeService(
+ const AlternativeService& alternative_service) {
DCHECK(network_task_runner_->RunsTasksOnCurrentThread());
- http_server_properties_impl_->ConfirmAlternateProtocol(origin);
+ http_server_properties_impl_->ConfirmAlternativeService(alternative_service);
ScheduleUpdatePrefsOnNetworkThread();
}
-void HttpServerPropertiesManager::ClearAlternateProtocol(
+void HttpServerPropertiesManager::ClearAlternativeService(
const HostPortPair& origin) {
DCHECK(network_task_runner_->RunsTasksOnCurrentThread());
- http_server_properties_impl_->ClearAlternateProtocol(origin);
+ http_server_properties_impl_->ClearAlternativeService(origin);
ScheduleUpdatePrefsOnNetworkThread();
}

Powered by Google App Engine
This is Rietveld 408576698