blob: 667803ceaf7729a9b3c498e1b5e0f22880588137 [file] [log] [blame]
Thomas Vachuska4f1a60c2014-10-28 13:39:07 -07001/*
Ray Milkey34c95902015-04-15 09:47:53 -07002 * Copyright 2014-2015 Open Networking Laboratory
Thomas Vachuska4f1a60c2014-10-28 13:39:07 -07003 *
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 */
Brian O'Connorabafb502014-12-02 22:26:20 -080016package org.onosproject.net.intent.impl;
tom95329eb2014-10-06 08:40:06 -070017
tom95329eb2014-10-06 08:40:06 -070018import java.util.Collection;
19
Ray Milkeyf9af43c2015-02-09 16:45:48 -080020import org.onosproject.net.NetworkResource;
21import org.onosproject.net.intent.Key;
22
tom95329eb2014-10-06 08:40:06 -070023/**
24 * Auxiliary service for tracking intent path flows and for notifying the
25 * intent service of environment changes via topology change delegate.
26 */
tom85258ee2014-10-07 00:10:02 -070027public interface ObjectiveTrackerService {
tom95329eb2014-10-06 08:40:06 -070028
29 /**
30 * Sets a topology change delegate.
31 *
32 * @param delegate topology change delegate
33 */
34 void setDelegate(TopologyChangeDelegate delegate);
35
36 /**
37 * Unsets topology change delegate.
38 *
39 * @param delegate topology change delegate
40 */
41 void unsetDelegate(TopologyChangeDelegate delegate);
42
43 /**
44 * Adds a path flow to be tracked.
45 *
Ray Milkeyf9af43c2015-02-09 16:45:48 -080046 * @param intentKey intent identity on whose behalf the path is being tracked
tom95329eb2014-10-06 08:40:06 -070047 * @param resources resources to track
48 */
Ray Milkeyf9af43c2015-02-09 16:45:48 -080049 // TODO consider using the IntentData here rather than just the key
Sho SHIMIZU3310a342015-05-13 12:14:05 -070050 void addTrackedResources(Key intentKey,
Thomas Vachuskab97cf282014-10-20 23:31:12 -070051 Collection<NetworkResource> resources);
tom95329eb2014-10-06 08:40:06 -070052
53 /**
54 * Removes a path flow to be tracked.
55 *
Ray Milkeyf9af43c2015-02-09 16:45:48 -080056 * @param intentKey intent identity on whose behalf the path is being tracked
tom95329eb2014-10-06 08:40:06 -070057 * @param resources resources to stop tracking
58 */
Sho SHIMIZU3310a342015-05-13 12:14:05 -070059 void removeTrackedResources(Key intentKey,
Thomas Vachuskab97cf282014-10-20 23:31:12 -070060 Collection<NetworkResource> resources);
tom95329eb2014-10-06 08:40:06 -070061
62}