pub trait AsIpAddrs {
// Required method
fn as_ip_addrs(&self) -> Result<HashSet<IpAddr>>;
}Expand description
This trait allows for parsing an input into a set of one or multiple Ipv4Addr.
Required Methods§
fn as_ip_addrs(&self) -> Result<HashSet<IpAddr>>
Implementations on Foreign Types§
Source§impl AsIpAddrs for &str
Supports one address or multiple addresses separated by ,.
For example: “127.0.0.1,127.0.0.2”.
impl AsIpAddrs for &str
Supports one address or multiple addresses separated by ,.
For example: “127.0.0.1,127.0.0.2”.
If the string is empty, will return an empty set.
Source§impl AsIpAddrs for ()
Optimization for zero sized/empty values, as () will never take up any space or evaluate to
anything, helpful in contexts where we just want an empty value.
impl AsIpAddrs for ()
Optimization for zero sized/empty values, as () will never take up any space or evaluate to
anything, helpful in contexts where we just want an empty value.