2
3
4
5
6
7
8
9
10
11
12
14#ifndef IPADDRESS_IPV6_NETWORK_HPP
15#define IPADDRESS_IPV6_NETWORK_HPP
23
24
25
26
27
30 using ip_address_type = ipv6_address;
33
34
35
36
37
38
39
40
42 const auto& network = *
static_cast<
const ip_network_base<ipv6_network_base>*>(
this);
43 return network.network_address().is_site_local() && network.broadcast_address().is_site_local();
48 auto result = address;
49 result.set_scope_id(
"");
54 return ip_network_base<ipv6_network_base>::from_address(remove_scope_id(network.network_address()), network.prefixlen());
59
60
61
62
63
64
65
68#ifdef IPADDRESS_NONTYPE_TEMPLATE_PARAMETER
71
72
73
74
75
76
77
78
79 IPADDRESS_EXPORT
template <fixed_string FixedString>
80 IPADDRESS_NODISCARD IPADDRESS_CONSTEVAL IPADDRESS_FORCE_INLINE ipv6_network operator
""_ipv6_net() IPADDRESS_NOEXCEPT {
81 return ipv6_network::parse<FixedString>();
87
88
89
90
91
92
93
94
95
97 return internal::parse_net_from_literal<ipv6_network_base,
char, ipv6_network::base_max_string_len + 4>(address, size);
101
102
103
104
105
106
107
108
109
111 return internal::parse_net_from_literal<ipv6_network_base,
wchar_t, ipv6_network::base_max_string_len + 4>(address, size);
115
116
117
118
119
120
121
122
123
125 return internal::parse_net_from_literal<ipv6_network_base,
char16_t, ipv6_network::base_max_string_len + 4>(address, size);
129
130
131
132
133
134
135
136
137
139 return internal::parse_net_from_literal<ipv6_network_base,
char32_t, ipv6_network::base_max_string_len + 4>(address, size);
Template base class for representing a network of IP addresses.
Definition ip-network-base.hpp:32
Base class for IPv6 network address manipulation.
Definition ipv6-network.hpp:28
constexpr inline bool is_site_local() const noexcept
Checks if the IPv6 network is site-local.
Definition ipv6-network.hpp:41
#define IPADDRESS_NOEXCEPT_WHEN_NO_EXCEPTIONS
Definition config.hpp:93
#define IPADDRESS_EXPORT
Definition config.hpp:42
#define IPADDRESS_NODISCARD
Definition config.hpp:98
#define IPADDRESS_FORCE_INLINE
Definition config.hpp:112
#define IPADDRESS_NAMESPACE
Definition config.hpp:38
#define IPADDRESS_NOEXCEPT
Definition config.hpp:89
#define IPADDRESS_NODISCARD_WHEN_NO_EXCEPTIONS
Definition config.hpp:102