/// Create a new scanner instance.
Create a new scanner instance.
Create a new scanner instance .
fn new(
            tc: ThreadingContext, 
            device: &EthernetDevice) -> IcmpScanner {
            let mask    = raw::utils::ipv4addr_to_u32(&device.netmask);
            let addr    = raw::utils::ipv4addr_to_u32(&device.ip_addr);
            let network = addr & mask;
            IcmpScanner {
                device:  device.clone(),
                scanner: Scanner::new(tc, &device.name),
                mask:    mask,
                network: network
            }
        }
fn new ( tc : ThreadingContext , device : & EthernetDevice ) -> IcmpScanner { let mask = raw :: utils :: ipv4addr_to_u32 ( & device . netmask ) ; let addr = raw :: utils :: ipv4addr_to_u32 ( & device . ip_addr ) ; let network = addr & mask ; IcmpScanner { device : device . clone ( ) , scanner : Scanner :: new ( tc , & device . name ) , mask : mask , network : network } }
Create a new scanner instance.
Create a new scanner instance .
tc
ThreadingContext
device
&EthernetDevice