Class ArpPacket.ArpHeader

    • Method Detail

      • getHardwareType

        public ArpHardwareType getHardwareType()
        Returns:
        hardwareType
      • getProtocolType

        public EtherType getProtocolType()
        Returns:
        protocolType
      • getHardwareAddrLength

        public byte getHardwareAddrLength()
        Returns:
        hardwareAddrLength
      • getHardwareAddrLengthAsInt

        public int getHardwareAddrLengthAsInt()
        Returns:
        hardwareAddrLength
      • getProtocolAddrLength

        public byte getProtocolAddrLength()
        Returns:
        protocolAddrLength
      • getProtocolAddrLengthAsInt

        public int getProtocolAddrLengthAsInt()
        Returns:
        protocolAddrLength
      • getOperation

        public ArpOperation getOperation()
        Returns:
        operation
      • getSrcHardwareAddr

        public MacAddress getSrcHardwareAddr()
        Returns:
        srcHardwareAddr
      • getSrcProtocolAddr

        public java.net.InetAddress getSrcProtocolAddr()
        Returns:
        srcProtocolAddr
      • getDstHardwareAddr

        public MacAddress getDstHardwareAddr()
        Returns:
        dstHardwareAddr
      • getDstProtocolAddr

        public java.net.InetAddress getDstProtocolAddr()
        Returns:
        dstProtocolAddr
      • length

        public int length()
        Description copied from class: AbstractPacket.AbstractHeader
        Returns the header length in bytes. This method calls calcLength() and caches the return value when it is called for the first time, and then, this method returns the cached value from the second time.
        Specified by:
        length in interface Packet.Header
        Overrides:
        length in class AbstractPacket.AbstractHeader
        Returns:
        the length of the byte stream of the header represented by this object in bytes