use of org.onosproject.net.packet.PacketContextAdapter in project onos by opennetworkinglab.
the class NeighbourResolutionManagerTest method context.
/**
* Creates a packet context for the given packet coming in the given port.
*
* @param packet packet to wrap in a packet context
* @param inPort input port of the packet
* @return packet context
*/
private static PacketContext context(Ethernet packet, ConnectPoint inPort) {
InboundPacket inboundPacket = new DefaultInboundPacket(inPort, packet, null);
OutboundPacket outboundPacket = new DefaultOutboundPacket(null, null, null);
return new PacketContextAdapter(0, inboundPacket, outboundPacket, false);
}
Aggregations