blob: 70e392fb18f335a18be0310e42213adfc75f504e [file] [log] [blame]
Thomas Vachuska4f1a60c2014-10-28 13:39:07 -07001/*
2 * Copyright 2014 Open Networking Laboratory
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
tomcfde0622014-09-09 11:02:42 -070016package org.onlab.onos.net.topology;
17
18import org.onlab.onos.net.Provided;
tom43387f32014-08-27 14:42:43 -070019
20/**
21 * Represents a network topology computation snapshot.
22 */
tomd1900f32014-09-03 14:08:16 -070023public interface Topology extends Provided {
tom43387f32014-08-27 14:42:43 -070024
Yuta HIGUCHI33b5e762014-10-16 20:00:04 -070025 // FIXME: Following is not true right now. It is actually System.nanoTime(),
26 // which has no relation to epoch time, wall clock, etc.
tom43387f32014-08-27 14:42:43 -070027 /**
28 * Returns the time, specified in milliseconds since start of epoch,
29 * when the topology became active and made available.
30 *
31 * @return time in milliseconds since start of epoch
32 */
33 long time();
34
35 /**
36 * Returns the number of SCCs (strongly connected components) in the
37 * topology.
38 *
39 * @return number of clusters
40 */
41 int clusterCount();
42
43 /**
44 * Returns the number of infrastructure devices in the topology.
45 *
46 * @return number of devices
47 */
48 int deviceCount();
49
50
51 /**
52 * Returns the number of infrastructure links in the topology.
53 *
54 * @return number of links
55 */
56 int linkCount();
57
58 /**
59 * Returns the number of infrastructure paths computed between devices
60 * in the topology. This means the number of all the shortest paths
61 * (hop-count) between all device pairs.
62 *
63 * @return number of paths
64 */
65 int pathCount();
66
67}