blob: 62fc9f8fd307bcb9742df7ba5aaaa8ada1c13cfd [file] [log] [blame]
tom64b7aac2014-08-26 00:18:21 -07001package org.onlab.onos.net;
2
3import org.onlab.onos.net.provider.Provided;
4
5/**
6 * Abstraction of a network infrastructure link.
7 */
tom18567e92014-08-26 01:39:47 -07008public interface Link extends Provided { // TODO: Also should extend graph Edge once the graph module is checked in
9
10 /**
11 * Coarse representation of the link type.
12 */
13 public enum Type {
14 /**
15 * Signifies that this is a direct single-segment link.
16 */
17 DIRECT,
18
19 /**
20 * Signifies that this link is potentially comprised from multiple
21 * underlying segments or hops, e.g. optical links, tunnel links,
22 * multi-hop links spanning 'dark' switches
23 */
24 INDIRECT
25 }
tom64b7aac2014-08-26 00:18:21 -070026
27 /**
28 * Returns the link source connection point.
29 *
30 * @return link source connection point
31 */
32 ConnectPoint src();
33
34 /**
35 * Returns the link destination connection point.
36 *
37 * @return link destination connection point
38 */
39 ConnectPoint dst();
40
tom18567e92014-08-26 01:39:47 -070041 // LinkInfo info(); // Additional link information / decorations
42
tom64b7aac2014-08-26 00:18:21 -070043}