blob: d654f670e0eabe9287cc45018c5906479d135b4b [file] [log] [blame]
Jonathan Hart7804bea2014-01-07 10:50:52 -08001package net.onrc.onos.ofcontroller.proxyarp;
2
Naoki Shiota78e403c2014-02-20 17:13:36 -08003import java.net.InetAddress;
4
5// TODO This class is too generic to be handled by ProxyArpService.
Jonathan Hart7804bea2014-01-07 10:50:52 -08006/**
7 * Notification to another ONOS instance to send a packet out a single port.
8 *
9 */
10public class SinglePacketOutNotification extends PacketOutNotification {
11
12 private static final long serialVersionUID = 1L;
13
Naoki Shiota78e403c2014-02-20 17:13:36 -080014 private final InetAddress address;
Jonathan Hart7804bea2014-01-07 10:50:52 -080015 private final long outSwitch;
16 private final short outPort;
17
Naoki Shiota78e403c2014-02-20 17:13:36 -080018 public SinglePacketOutNotification(byte[] packet, InetAddress address,
19 long outSwitch, short outPort) {
Jonathan Hart7804bea2014-01-07 10:50:52 -080020 super(packet);
21
Naoki Shiota78e403c2014-02-20 17:13:36 -080022 this.address = address;
Jonathan Hart7804bea2014-01-07 10:50:52 -080023 this.outSwitch = outSwitch;
24 this.outPort = outPort;
25 }
26
27 public long getOutSwitch() {
28 return outSwitch;
29 }
30
31 public short getOutPort() {
32 return outPort;
33 }
34
Naoki Shiota78e403c2014-02-20 17:13:36 -080035 public InetAddress getTargetAddress() {
36 return address;
37 }
Jonathan Hart7804bea2014-01-07 10:50:52 -080038}