blob: 25a27be652eeaf6cfc6227901d143ce18fa35f3b [file] [log] [blame]
Jonathan Hart472062d2014-04-03 10:56:48 -07001package net.onrc.onos.core.topology;
Jonathan Hart062a2e82014-02-03 09:41:57 -08002
3import java.net.InetAddress;
4import java.util.Collection;
5
6import net.floodlightcontroller.util.MACAddress;
7
Yuta HIGUCHI181d34d2014-02-05 15:05:46 -08008/**
9 * Interface of Device Object exposed to the "NB" read-only Topology.
10 *
Yuta HIGUCHI8d9fddf2014-02-10 13:32:16 -080011 * TODO What a Device Object represent is unclear at the moment.
12 *
Yuta HIGUCHI181d34d2014-02-05 15:05:46 -080013 * Everything returned by these interfaces must be either Unmodifiable view,
14 * immutable object, or a copy of the original "SB" In-memory Topology.
15 *
16 */
Jonathan Hart062a2e82014-02-03 09:41:57 -080017public interface Device {
Pavlin Radoslavov7c8f69a2014-02-19 19:01:45 -080018 /**
19 * Get the device MAC address.
20 *
21 * @return the device MAC address.
22 */
23 public MACAddress getMacAddress();
Yuta HIGUCHI181d34d2014-02-05 15:05:46 -080024
Pavlin Radoslavov7c8f69a2014-02-19 19:01:45 -080025 /**
26 * Get the device IP addresses.
27 *
28 * @return the device IP addresses.
29 */
30 public Collection<InetAddress> getIpAddress();
Yuta HIGUCHI181d34d2014-02-05 15:05:46 -080031
Pavlin Radoslavov7c8f69a2014-02-19 19:01:45 -080032 /**
33 * Get the device attachment points.
34 *
35 * Add requirement for Iteration order? Latest observed port first.
36 *
37 * @return the device attachment points.
38 */
39 public Iterable<Port> getAttachmentPoints();
Yuta HIGUCHI181d34d2014-02-05 15:05:46 -080040
Pavlin Radoslavov7c8f69a2014-02-19 19:01:45 -080041 /**
42 * Get the device last seen time.
43 *
44 * TODO: what is the time definition?
45 *
46 * @return the device last seen time.
47 */
48 public long getLastSeenTime();
Jonathan Hart062a2e82014-02-03 09:41:57 -080049}