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 | 18567e9 | 2014-08-26 01:39:47 -0700 | [diff] [blame] | 8 | public 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 |
tom | d3097b0 | 2014-08-26 10:40:29 -0700 | [diff] [blame^] | 21 | * underlying segments or hops, and as such should be used to tag |
| 22 | * links traversing optical paths, tunnels or intervening 'dark' |
| 23 | * switches. |
tom | 18567e9 | 2014-08-26 01:39:47 -0700 | [diff] [blame] | 24 | */ |
| 25 | INDIRECT |
| 26 | } |
tom | 64b7aac | 2014-08-26 00:18:21 -0700 | [diff] [blame] | 27 | |
| 28 | /** |
| 29 | * Returns the link source connection point. |
| 30 | * |
| 31 | * @return link source connection point |
| 32 | */ |
| 33 | ConnectPoint src(); |
| 34 | |
| 35 | /** |
| 36 | * Returns the link destination connection point. |
| 37 | * |
| 38 | * @return link destination connection point |
| 39 | */ |
| 40 | ConnectPoint dst(); |
| 41 | |
tom | 18567e9 | 2014-08-26 01:39:47 -0700 | [diff] [blame] | 42 | // LinkInfo info(); // Additional link information / decorations |
| 43 | |
tom | 64b7aac | 2014-08-26 00:18:21 -0700 | [diff] [blame] | 44 | } |