Skip to main content

format_inet

Function format_inet 

Source
pub fn format_inet(family: u8, bits: u8, addr: &[u8; 16]) -> String
Expand description

v7.37.5 ζ-A — render an INET/CIDR address as canonical PG text: IPv4: a.b.c.d/bits; IPv6: xxxx:xxxx:.../bits. The mask is elided when it equals the family default (32 for IPv4, 128 for IPv6), per PG convention.