blob: f1b45421740219ef42b7a594244365ffe584c8e4 [file] [log] [blame]
tom210f3f32014-09-16 17:33:40 -07001package org.onlab.onos.net.topology;
tom4774c8f2014-09-16 11:17:08 -07002
tomcbefa232014-09-16 14:17:20 -07003import org.onlab.onos.net.ElementId;
tom4774c8f2014-09-16 11:17:08 -07004import org.onlab.onos.net.Path;
tom4774c8f2014-09-16 11:17:08 -07005
6import java.util.Set;
7
8/**
9 * Service for obtaining pre-computed paths or for requesting computation of
10 * paths using the current topology snapshot.
11 */
12public interface PathService {
13
14 /**
15 * Returns the set of all shortest paths, precomputed in terms of hop-count,
tomcbefa232014-09-16 14:17:20 -070016 * between the specified source and destination elements.
tom4774c8f2014-09-16 11:17:08 -070017 *
tomcbefa232014-09-16 14:17:20 -070018 * @param src source element
19 * @param dst destination element
20 * @return set of all shortest paths between the two elements
tom4774c8f2014-09-16 11:17:08 -070021 */
tomcbefa232014-09-16 14:17:20 -070022 Set<Path> getPaths(ElementId src, ElementId dst);
tom4774c8f2014-09-16 11:17:08 -070023
24 /**
25 * Returns the set of all shortest paths, computed using the supplied
tomcbefa232014-09-16 14:17:20 -070026 * edge-weight entity, between the specified source and destination
27 * network elements.
tom4774c8f2014-09-16 11:17:08 -070028 *
tomcbefa232014-09-16 14:17:20 -070029 * @param src source element
30 * @param dst destination element
31 * @return set of all shortest paths between the two element
tom4774c8f2014-09-16 11:17:08 -070032 */
tomcbefa232014-09-16 14:17:20 -070033 Set<Path> getPaths(ElementId src, ElementId dst, LinkWeight weight);
tom4774c8f2014-09-16 11:17:08 -070034
35}