blob: 4fd53afc12461745129f97e7423062325402d2c4 [file] [log] [blame]
Jonathan Hart062a2e82014-02-03 09:41:57 -08001package net.onrc.onos.ofcontroller.networkgraph;
2
Yuta HIGUCHI181d34d2014-02-05 15:05:46 -08003/**
4 * Interface of Link Object exposed to the "NB" read-only Topology.
5 *
6 * Everything returned by these interfaces must be either Unmodifiable view,
7 * immutable object, or a copy of the original "SB" In-memory Topology.
8 *
9 */
Jonathan Hart062a2e82014-02-03 09:41:57 -080010public interface Link {
11 public Port getSourcePort();
12 public Port getDestinationPort();
13 public Switch getSourceSwitch();
14 public Switch getDestinationSwitch();
Toshio Koide0c9106d2014-02-19 15:26:38 -080015
Jonathan Hart062a2e82014-02-03 09:41:57 -080016 public long getLastSeenTime();
Toshio Koide2f570c12014-02-06 16:55:32 -080017
Jonathan Hart062a2e82014-02-03 09:41:57 -080018 public int getCost();
Toshio Koide2f570c12014-02-06 16:55:32 -080019 public Double getCapacity();
Yuta HIGUCHI181d34d2014-02-05 15:05:46 -080020
Jonathan Hart062a2e82014-02-03 09:41:57 -080021 // Not sure if we want to expose these northbound
Toshio Koide2f570c12014-02-06 16:55:32 -080022 // Toshi: I think these are unnecessary because we can get them
23 // Toshi: like "this.getSourcePort().getSwitch()" etc.
Toshio Koide0c9106d2014-02-19 15:26:38 -080024 @Deprecated
Toshio Koide2f570c12014-02-06 16:55:32 -080025 public Long getSourceSwitchDpid();
Toshio Koide0c9106d2014-02-19 15:26:38 -080026 @Deprecated
Toshio Koide2f570c12014-02-06 16:55:32 -080027 public Long getSourcePortNumber();
Toshio Koide0c9106d2014-02-19 15:26:38 -080028 @Deprecated
Toshio Koide2f570c12014-02-06 16:55:32 -080029 public Long getDestinationSwitchDpid();
Toshio Koide0c9106d2014-02-19 15:26:38 -080030 @Deprecated
Toshio Koide2f570c12014-02-06 16:55:32 -080031 public Long getDestinationPortNumber();
Jonathan Hart062a2e82014-02-03 09:41:57 -080032}