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_BASE_NET_UTIL_H_ | 5 #ifndef NET_BASE_NET_UTIL_H_ |
6 #define NET_BASE_NET_UTIL_H_ | 6 #define NET_BASE_NET_UTIL_H_ |
7 | 7 |
8 #include "build/build_config.h" | 8 #include "build/build_config.h" |
9 | 9 |
10 #if defined(OS_WIN) | 10 #if defined(OS_WIN) |
(...skipping 450 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
461 | 461 |
462 // struct that is used by GetNetworkList() to represent a network | 462 // struct that is used by GetNetworkList() to represent a network |
463 // interface. | 463 // interface. |
464 struct NET_EXPORT NetworkInterface { | 464 struct NET_EXPORT NetworkInterface { |
465 NetworkInterface(); | 465 NetworkInterface(); |
466 NetworkInterface(const std::string& name, | 466 NetworkInterface(const std::string& name, |
467 const std::string& friendly_name, | 467 const std::string& friendly_name, |
468 uint32 interface_index, | 468 uint32 interface_index, |
469 NetworkChangeNotifier::ConnectionType type, | 469 NetworkChangeNotifier::ConnectionType type, |
470 const IPAddressNumber& address, | 470 const IPAddressNumber& address, |
471 uint32 network_prefix, | 471 uint32 prefix_length, |
472 int ip_address_attributes); | 472 int ip_address_attributes); |
473 ~NetworkInterface(); | 473 ~NetworkInterface(); |
474 | 474 |
475 std::string name; | 475 std::string name; |
476 std::string friendly_name; // Same as |name| on non-Windows. | 476 std::string friendly_name; // Same as |name| on non-Windows. |
477 uint32 interface_index; // Always 0 on Android. | 477 uint32 interface_index; // Always 0 on Android. |
478 NetworkChangeNotifier::ConnectionType type; | 478 NetworkChangeNotifier::ConnectionType type; |
479 IPAddressNumber address; | 479 IPAddressNumber address; |
480 uint32 network_prefix; | 480 uint32 prefix_length; |
481 int ip_address_attributes; // Combination of |IPAddressAttributes|. | 481 int ip_address_attributes; // Combination of |IPAddressAttributes|. |
482 }; | 482 }; |
483 | 483 |
484 typedef std::vector<NetworkInterface> NetworkInterfaceList; | 484 typedef std::vector<NetworkInterface> NetworkInterfaceList; |
485 | 485 |
486 // Policy settings to include/exclude network interfaces. | 486 // Policy settings to include/exclude network interfaces. |
487 enum HostAddressSelectionPolicy { | 487 enum HostAddressSelectionPolicy { |
488 INCLUDE_HOST_SCOPE_VIRTUAL_INTERFACES = 0x0, | 488 INCLUDE_HOST_SCOPE_VIRTUAL_INTERFACES = 0x0, |
489 EXCLUDE_HOST_SCOPE_VIRTUAL_INTERFACES = 0x1, | 489 EXCLUDE_HOST_SCOPE_VIRTUAL_INTERFACES = 0x1, |
490 }; | 490 }; |
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
573 DSCP_CS5 = 40, // Video | 573 DSCP_CS5 = 40, // Video |
574 DSCP_EF = 46, // Voice | 574 DSCP_EF = 46, // Voice |
575 DSCP_CS6 = 48, // Voice | 575 DSCP_CS6 = 48, // Voice |
576 DSCP_CS7 = 56, // Control messages | 576 DSCP_CS7 = 56, // Control messages |
577 DSCP_LAST = DSCP_CS7 | 577 DSCP_LAST = DSCP_CS7 |
578 }; | 578 }; |
579 | 579 |
580 } // namespace net | 580 } // namespace net |
581 | 581 |
582 #endif // NET_BASE_NET_UTIL_H_ | 582 #endif // NET_BASE_NET_UTIL_H_ |
OLD | NEW |