Package org.onlab.packet.dhcp
Class Dhcp6InterfaceIdOption
- java.lang.Object
-
- org.onlab.packet.BasePacket
-
- org.onlab.packet.dhcp.Dhcp6Option
-
- org.onlab.packet.dhcp.Dhcp6InterfaceIdOption
-
- All Implemented Interfaces:
IPacket
public final class Dhcp6InterfaceIdOption extends Dhcp6Option
Relay option for DHCPv6. Based on RFC-3315.
-
-
Field Summary
-
Fields inherited from class org.onlab.packet.dhcp.Dhcp6Option
DEFAULT_LEN, UNSIGNED_SHORT_MASK
-
Fields inherited from class org.onlab.packet.BasePacket
parent, payload
-
-
Constructor Summary
Constructors Constructor Description Dhcp6InterfaceIdOption()Default constructor.Dhcp6InterfaceIdOption(Dhcp6Option dhcp6Option)Constructs a DHCPv6 relay option with DHCPv6 option.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static Deserializer<Dhcp6Option>deserializer()Gets deserializer for DHCPv6 relay option.shortgetCode()Gets the code of this option.byte[]getData()Gets the data of this option.byte[]getInPort()Gets inPort string.shortgetLength()Gets the length of this option.MacAddressgetMacAddress()Gets Mac address.shortgetVlanId()Gets the vlan id of interface id.voidsetInPort(byte[] port)Sets inPort string.voidsetMacAddress(MacAddress macAddress)Sets MacAddress address.voidsetVlanId(short vlanId)Sets the vlan id of interface id.StringtoString()-
Methods inherited from class org.onlab.packet.dhcp.Dhcp6Option
equals, getToStringHelper, hashCode, serialize, setCode, setData, setLength
-
Methods inherited from class org.onlab.packet.BasePacket
clone, getParent, getPayload, resetChecksum, setParent, setPayload
-
-
-
-
Constructor Detail
-
Dhcp6InterfaceIdOption
public Dhcp6InterfaceIdOption()
Default constructor.
-
Dhcp6InterfaceIdOption
public Dhcp6InterfaceIdOption(Dhcp6Option dhcp6Option)
Constructs a DHCPv6 relay option with DHCPv6 option.- Parameters:
dhcp6Option- the DHCPv6 option
-
-
Method Detail
-
getCode
public short getCode()
Description copied from class:Dhcp6OptionGets the code of this option.- Overrides:
getCodein classDhcp6Option- Returns:
- the code
-
getLength
public short getLength()
Description copied from class:Dhcp6OptionGets the length of this option.- Overrides:
getLengthin classDhcp6Option- Returns:
- the length of this option
-
getData
public byte[] getData()
Description copied from class:Dhcp6OptionGets the data of this option.- Overrides:
getDatain classDhcp6Option- Returns:
- the data of this option
-
setMacAddress
public void setMacAddress(MacAddress macAddress)
Sets MacAddress address.- Parameters:
macAddress- the client peer MacAddress
-
getMacAddress
public MacAddress getMacAddress()
Gets Mac address.- Returns:
- the client peer mac address
-
setInPort
public void setInPort(byte[] port)
Sets inPort string.- Parameters:
port- the port from which client packet is received
-
getInPort
public byte[] getInPort()
Gets inPort string.- Returns:
- the port from which client packet is received
-
setVlanId
public void setVlanId(short vlanId)
Sets the vlan id of interface id.- Parameters:
vlanId- the vlanid of client packet
-
getVlanId
public short getVlanId()
Gets the vlan id of interface id.- Returns:
- the vlan id
-
deserializer
public static Deserializer<Dhcp6Option> deserializer()
Gets deserializer for DHCPv6 relay option.- Returns:
- the deserializer
-
toString
public String toString()
- Overrides:
toStringin classDhcp6Option
-
-