parse_ip_or_cidr

Function parse_ip_or_cidr 

Source
pub fn parse_ip_or_cidr(s: &str) -> Option<(IpAddr, u8)>
Expand description

Parse ip, ip/prefix into (network address, prefix length). Returns None for anything that is not a well-formed IPv4/IPv6 address or CIDR (including prefixes wider than the address family allows).