- java.lang.Object
-
- org.pcap4j.packet.IpV4RouteOption
-
- All Implemented Interfaces:
java.io.Serializable,IpV4Packet.IpV4Option
- Direct Known Subclasses:
IpV4LooseSourceRouteOption,IpV4RecordRouteOption,IpV4StrictSourceRouteOption
abstract class IpV4RouteOption extends java.lang.Object implements IpV4Packet.IpV4Option
- Since:
- pcap4j 0.9.11
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classIpV4RouteOption.Builder<T extends IpV4RouteOption>
-
Field Summary
Fields Modifier and Type Field Description private bytelengthprivate bytepointerprivate java.util.List<java.net.Inet4Address>routeDataprivate static longserialVersionUID
-
Constructor Summary
Constructors Modifier Constructor Description protectedIpV4RouteOption(byte[] rawData, int offset, int length)protectedIpV4RouteOption(IpV4RouteOption.Builder<? extends IpV4RouteOption> builder)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)abstract IpV4RouteOption.Builder<? extends IpV4RouteOption>getBuilder()bytegetLength()intgetLengthAsInt()bytegetPointer()intgetPointerAsInt()byte[]getRawData()java.util.List<java.net.Inet4Address>getRouteData()abstract IpV4OptionTypegetType()inthashCode()intlength()java.lang.StringtoString()
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
length
private final byte length
-
pointer
private final byte pointer
-
routeData
private final java.util.List<java.net.Inet4Address> routeData
-
-
Constructor Detail
-
IpV4RouteOption
protected IpV4RouteOption(byte[] rawData, int offset, int length) throws IllegalRawDataException- Throws:
IllegalRawDataException
-
IpV4RouteOption
protected IpV4RouteOption(IpV4RouteOption.Builder<? extends IpV4RouteOption> builder)
-
-
Method Detail
-
getType
public abstract IpV4OptionType getType()
- Specified by:
getTypein interfaceIpV4Packet.IpV4Option- Returns:
- type
-
getLength
public byte getLength()
- Returns:
- length
-
getLengthAsInt
public int getLengthAsInt()
- Returns:
- length
-
getPointer
public byte getPointer()
- Returns:
- pointer
-
getPointerAsInt
public int getPointerAsInt()
- Returns:
- pointer
-
getRouteData
public java.util.List<java.net.Inet4Address> getRouteData()
- Returns:
- routeData
-
length
public int length()
- Specified by:
lengthin interfaceIpV4Packet.IpV4Option- Returns:
- length
-
getRawData
public byte[] getRawData()
- Specified by:
getRawDatain interfaceIpV4Packet.IpV4Option- Returns:
- raw data
-
getBuilder
public abstract IpV4RouteOption.Builder<? extends IpV4RouteOption> getBuilder()
- Returns:
- a new Builder object populated with this object's fields.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-