| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef NET_HTTP_HTTP_SERVER_PROPERTIES_H_ | 5 #ifndef NET_HTTP_HTTP_SERVER_PROPERTIES_H_ |
| 6 #define NET_HTTP_HTTP_SERVER_PROPERTIES_H_ | 6 #define NET_HTTP_HTTP_SERVER_PROPERTIES_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 301 // Returns true iff |alternative_service| was recently broken. | 301 // Returns true iff |alternative_service| was recently broken. |
| 302 // |alternative_service.host| must not be empty. | 302 // |alternative_service.host| must not be empty. |
| 303 virtual bool WasAlternativeServiceRecentlyBroken( | 303 virtual bool WasAlternativeServiceRecentlyBroken( |
| 304 const AlternativeService& alternative_service) = 0; | 304 const AlternativeService& alternative_service) = 0; |
| 305 | 305 |
| 306 // Confirms that |alternative_service| is working. | 306 // Confirms that |alternative_service| is working. |
| 307 // |alternative_service.host| must not be empty. | 307 // |alternative_service.host| must not be empty. |
| 308 virtual void ConfirmAlternativeService( | 308 virtual void ConfirmAlternativeService( |
| 309 const AlternativeService& alternative_service) = 0; | 309 const AlternativeService& alternative_service) = 0; |
| 310 | 310 |
| 311 // Clear all alternative services for |origin|. | |
| 312 virtual void ClearAlternativeServices(const url::SchemeHostPort& origin) = 0; | |
| 313 | |
| 314 // Returns all alternative service mappings. | 311 // Returns all alternative service mappings. |
| 315 // Returned alternative services may have empty hostnames. | 312 // Returned alternative services may have empty hostnames. |
| 316 virtual const AlternativeServiceMap& alternative_service_map() const = 0; | 313 virtual const AlternativeServiceMap& alternative_service_map() const = 0; |
| 317 | 314 |
| 318 // Returns all alternative service mappings as human readable strings. | 315 // Returns all alternative service mappings as human readable strings. |
| 319 // Empty alternative service hostnames will be printed as such. | 316 // Empty alternative service hostnames will be printed as such. |
| 320 virtual std::unique_ptr<base::Value> GetAlternativeServiceInfoAsValue() | 317 virtual std::unique_ptr<base::Value> GetAlternativeServiceInfoAsValue() |
| 321 const = 0; | 318 const = 0; |
| 322 | 319 |
| 323 // Gets a reference to the SettingsMap stored for a host. | 320 // Gets a reference to the SettingsMap stored for a host. |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 374 virtual void SetMaxServerConfigsStoredInProperties( | 371 virtual void SetMaxServerConfigsStoredInProperties( |
| 375 size_t max_server_configs_stored_in_properties) = 0; | 372 size_t max_server_configs_stored_in_properties) = 0; |
| 376 | 373 |
| 377 private: | 374 private: |
| 378 DISALLOW_COPY_AND_ASSIGN(HttpServerProperties); | 375 DISALLOW_COPY_AND_ASSIGN(HttpServerProperties); |
| 379 }; | 376 }; |
| 380 | 377 |
| 381 } // namespace net | 378 } // namespace net |
| 382 | 379 |
| 383 #endif // NET_HTTP_HTTP_SERVER_PROPERTIES_H_ | 380 #endif // NET_HTTP_HTTP_SERVER_PROPERTIES_H_ |
| OLD | NEW |