blob: db51374a85ce999a8835b88608915123e285c283 [file] [log] [blame]
alshabibb7b40632014-09-28 21:30:00 -07001package org.onlab.onos.net.proxyarp;
2
3import org.onlab.packet.Ethernet;
4import org.onlab.packet.IpPrefix;
5
6/**
7 * Service for processing arp requests on behalf of applications.
8 */
tomf5d85d42014-10-02 05:27:56 -07009// TODO: move to the peer host package
alshabibb7b40632014-09-28 21:30:00 -070010public interface ProxyArpService {
11
12 /**
13 * Returns whether this particular ip address is known to the system.
14 *
15 * @param addr
16 * a ip address
17 * @return true if know, false otherwise
18 */
19 boolean known(IpPrefix addr);
20
21 /**
22 * Sends a reply for a given request. If the host is not known then the arp
23 * will be flooded at all edge ports.
24 *
alshabibb5522ff2014-09-29 19:20:00 -070025 * @param eth
alshabibb7b40632014-09-28 21:30:00 -070026 * an arp request
27 */
alshabibb5522ff2014-09-29 19:20:00 -070028 void reply(Ethernet eth);
29
30 /**
31 * Forwards an ARP request to its destination. Floods at the edge the ARP request if the
32 * destination is not known.
33 * @param eth an ethernet frame containing an ARP request.
34 */
35 void forward(Ethernet eth);
alshabibb7b40632014-09-28 21:30:00 -070036
37}