Module org.pcap4j.core
Package org.pcap4j.packet
Class IpV6NeighborDiscoveryTargetLinkLayerAddressOption
java.lang.Object
org.pcap4j.packet.IpV6NeighborDiscoveryTargetLinkLayerAddressOption
- All Implemented Interfaces:
Serializable,IcmpV6CommonPacket.IpV6NeighborDiscoveryOption
public final class IpV6NeighborDiscoveryTargetLinkLayerAddressOption
extends Object
implements IcmpV6CommonPacket.IpV6NeighborDiscoveryOption
- Since:
- pcap4j 0.9.15
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final byteprivate static final intprivate static final intprivate static final intprivate final byte[]private static final longprivate final IpV6NeighborDiscoveryOptionTypeprivate static final intprivate static final int -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateIpV6NeighborDiscoveryTargetLinkLayerAddressOption(byte[] rawData, int offset, int length) privateIpV6NeighborDiscoveryTargetLinkLayerAddressOption(IpV6NeighborDiscoveryTargetLinkLayerAddressOption.Builder builder) -
Method Summary
Modifier and TypeMethodDescriptionbooleanbyteintbyte[]byte[]getType()inthashCode()intlength()newInstance(byte[] rawData, int offset, int length) A static factory method.toString()
-
Field Details
-
serialVersionUID
private static final long serialVersionUID- See Also:
-
TYPE_OFFSET
private static final int TYPE_OFFSET- See Also:
-
TYPE_SIZE
private static final int TYPE_SIZE- See Also:
-
LENGTH_OFFSET
private static final int LENGTH_OFFSET- See Also:
-
LENGTH_SIZE
private static final int LENGTH_SIZE- See Also:
-
LINK_LAYER_ADDRESS_OFFSET
private static final int LINK_LAYER_ADDRESS_OFFSET- See Also:
-
type
-
length
private final byte length -
linkLayerAddress
private final byte[] linkLayerAddress
-
-
Constructor Details
-
IpV6NeighborDiscoveryTargetLinkLayerAddressOption
private IpV6NeighborDiscoveryTargetLinkLayerAddressOption(byte[] rawData, int offset, int length) throws IllegalRawDataException - Throws:
IllegalRawDataException
-
IpV6NeighborDiscoveryTargetLinkLayerAddressOption
private IpV6NeighborDiscoveryTargetLinkLayerAddressOption(IpV6NeighborDiscoveryTargetLinkLayerAddressOption.Builder builder)
-
-
Method Details
-
newInstance
public static IpV6NeighborDiscoveryTargetLinkLayerAddressOption newInstance(byte[] rawData, int offset, int length) throws IllegalRawDataException A static factory method. This method validates the arguments byByteArrays.validateBounds(byte[], int, int), which may throw exceptions undocumented here.- Parameters:
rawData- rawDataoffset- offsetlength- length- Returns:
- a new IpV6NeighborDiscoveryTargetLinkLayerAddressOption object.
- Throws:
IllegalRawDataException- if parsing the raw data fails.
-
getType
- Specified by:
getTypein interfaceIcmpV6CommonPacket.IpV6NeighborDiscoveryOption- Returns:
- type
-
getLength
public byte getLength()- Returns:
- length
-
getLengthAsInt
public int getLengthAsInt()- Returns:
- length
-
getLinkLayerAddress
public byte[] getLinkLayerAddress()- Returns:
- linkLayerAddress
-
getLinkLayerAddressAsMacAddress
- Returns:
- a MacAddress object
-
length
public int length()- Specified by:
lengthin interfaceIcmpV6CommonPacket.IpV6NeighborDiscoveryOption- Returns:
- length
-
getRawData
public byte[] getRawData()- Specified by:
getRawDatain interfaceIcmpV6CommonPacket.IpV6NeighborDiscoveryOption- Returns:
- raw data
-
getBuilder
- Returns:
- a new Builder object populated with this object's fields.
-
toString
-
equals
-
hashCode
public int hashCode()
-