tom | 64b7aac | 2014-08-26 00:18:21 -0700 | [diff] [blame] | 1 | package org.onlab.onos.net; |
| 2 | |
| 3 | import org.onlab.onos.net.provider.Provided; |
| 4 | |
| 5 | /** |
| 6 | * Abstraction of a network infrastructure link. |
| 7 | */ |
tom | 43387f3 | 2014-08-27 14:42:43 -0700 | [diff] [blame^] | 8 | public interface Link extends Provided { |
| 9 | // TODO: Consider extending graph Edge<Element> once the graph module is available |
tom | 18567e9 | 2014-08-26 01:39:47 -0700 | [diff] [blame] | 10 | |
| 11 | /** |
| 12 | * Coarse representation of the link type. |
| 13 | */ |
| 14 | public enum Type { |
| 15 | /** |
| 16 | * Signifies that this is a direct single-segment link. |
| 17 | */ |
| 18 | DIRECT, |
| 19 | |
| 20 | /** |
| 21 | * Signifies that this link is potentially comprised from multiple |
tom | d3097b0 | 2014-08-26 10:40:29 -0700 | [diff] [blame] | 22 | * underlying segments or hops, and as such should be used to tag |
| 23 | * links traversing optical paths, tunnels or intervening 'dark' |
| 24 | * switches. |
tom | 18567e9 | 2014-08-26 01:39:47 -0700 | [diff] [blame] | 25 | */ |
| 26 | INDIRECT |
| 27 | } |
tom | 64b7aac | 2014-08-26 00:18:21 -0700 | [diff] [blame] | 28 | |
| 29 | /** |
| 30 | * Returns the link source connection point. |
| 31 | * |
| 32 | * @return link source connection point |
| 33 | */ |
| 34 | ConnectPoint src(); |
| 35 | |
| 36 | /** |
| 37 | * Returns the link destination connection point. |
| 38 | * |
| 39 | * @return link destination connection point |
| 40 | */ |
| 41 | ConnectPoint dst(); |
| 42 | |
tom | 18567e9 | 2014-08-26 01:39:47 -0700 | [diff] [blame] | 43 | // LinkInfo info(); // Additional link information / decorations |
| 44 | |
tom | 64b7aac | 2014-08-26 00:18:21 -0700 | [diff] [blame] | 45 | } |