Class PropertiesBasedIpV6RoutingDataFactory
java.lang.Object
org.pcap4j.packet.factory.propertiesbased.PropertiesBasedIpV6RoutingDataFactory
- All Implemented Interfaces:
PacketFactory<IpV6ExtRoutingPacket.IpV6RoutingData, IpV6RoutingType>
public final class PropertiesBasedIpV6RoutingDataFactory
extends Object
implements PacketFactory<IpV6ExtRoutingPacket.IpV6RoutingData, IpV6RoutingType>
- Since:
- pcap4j 0.9.14
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionClass<? extends IpV6ExtRoutingPacket.IpV6RoutingData> Class<? extends IpV6ExtRoutingPacket.IpV6RoutingData> newInstance(byte[] rawData, int offset, int length) newInstance(byte[] rawData, int offset, int length, Class<? extends IpV6ExtRoutingPacket.IpV6RoutingData> dataClass) newInstance(byte[] rawData, int offset, int length, IpV6RoutingType type)
-
Field Details
-
INSTANCE
-
-
Constructor Details
-
PropertiesBasedIpV6RoutingDataFactory
private PropertiesBasedIpV6RoutingDataFactory()
-
-
Method Details
-
getInstance
- Returns:
- the singleton instance of PropertiesBasedIpV6RoutingDataFactory.
-
newInstance
public IpV6ExtRoutingPacket.IpV6RoutingData newInstance(byte[] rawData, int offset, int length, IpV6RoutingType type) - Specified by:
newInstancein interfacePacketFactory<IpV6ExtRoutingPacket.IpV6RoutingData, IpV6RoutingType>- Parameters:
rawData- rawDataoffset- offsetlength- lengthtype- number- Returns:
- a new data object.
-
newInstance
- Specified by:
newInstancein interfacePacketFactory<IpV6ExtRoutingPacket.IpV6RoutingData, IpV6RoutingType>- Parameters:
rawData- rawDataoffset- offsetlength- length- Returns:
- a new data object.
-
newInstance
public IpV6ExtRoutingPacket.IpV6RoutingData newInstance(byte[] rawData, int offset, int length, Class<? extends IpV6ExtRoutingPacket.IpV6RoutingData> dataClass) - Parameters:
rawData- rawDataoffset- offsetlength- lengthdataClass- dataClass- Returns:
- a new IpV6RoutingData object.
- Throws:
IllegalStateException- if an access to the newInstance method of the dataClass fails.IllegalArgumentException- if an exception other thanIllegalRawDataExceptionis thrown by newInstance method of the dataClass.NullPointerException- if any of arguments are null.
-
getTargetClass
- Specified by:
getTargetClassin interfacePacketFactory<IpV6ExtRoutingPacket.IpV6RoutingData, IpV6RoutingType>- Parameters:
type- number- Returns:
- a
Classobject this factory instantiates byPacketFactory.newInstance(byte[], int, int, NamedNumber)with the number argument.
-
getTargetClass
- Specified by:
getTargetClassin interfacePacketFactory<IpV6ExtRoutingPacket.IpV6RoutingData, IpV6RoutingType>- Returns:
- a
Classobject this factory instantiates byPacketFactory.newInstance(byte[], int, int).
-