pub fn calc_netmask_from_size4(size: u32) -> Ipv4Addr {
    let mut netmask: u32 = 0;
    for i in 0..size {
        netmask |= 0b1 << (31 - i)
    }
    Ipv4Addr::from(netmask)
}
/// Calculate an IPv4 netmask from a given size
Calculate an IPv4 netmask from a given size
Calculate an IPv4 netmask from a given size
pub fn calc_netmask_from_size4(size: u32) -> Ipv4Addr {
    let mut netmask: u32 = 0;
    for i in 0..size {
        netmask |= 0b1 << (31 - i)
    }
    Ipv4Addr::from(netmask)
}
pub fn calc_netmask_from_size4 ( size : u32 ) -> Ipv4Addr { let mut netmask : u32 = 0 ; for i in 0 .. size { netmask |= 0b1 << ( 31 - i ) } Ipv4Addr :: from ( netmask ) }
Calculate an IPv4 netmask from a given size
Calculate an IPv4 netmask from a given size
size
u32
size
u32