use of org.onlab.packet.DHCP6.MsgType in project onos by opennetworkinglab.
the class Dhcp6HandlerUtil method getDhcp6LeafMessageType.
/**
* Determine DHCP message type (direct DHCPv6 or wrapped into relay messages).
*
* @param relayPacket {@link DHCP6} packet to be parsed
* @return {@link DHCP6.MsgType} contained message type of dhcpv6 packet/relay-message
*/
public static DHCP6.MsgType getDhcp6LeafMessageType(DHCP6 relayPacket) {
checkNotNull(relayPacket);
DHCP6 dhcp6Child = getDhcp6Leaf(relayPacket);
return DHCP6.MsgType.getType(dhcp6Child != null ? dhcp6Child.getMsgType() : relayPacket.getMsgType());
}
Aggregations