blob: 985549851a8a599d6b64b2412ed2d62d226d187f [file] [log] [blame]
Brian O'Connorb876bf12014-10-02 14:59:37 -07001package org.onlab.onos.net.intent;
2
Brian O'Connorcb900f42014-10-07 21:55:33 -07003import java.util.concurrent.Future;
4
5import org.onlab.onos.net.flow.CompletedBatchOperation;
6
Brian O'Connorb876bf12014-10-02 14:59:37 -07007/**
8 * Abstraction of entity capable of installing intents to the environment.
9 */
10public interface IntentInstaller<T extends InstallableIntent> {
11 /**
12 * Installs the specified intent to the environment.
13 *
14 * @param intent intent to be installed
15 * @throws IntentException if issues are encountered while installing the intent
16 */
Brian O'Connorcb900f42014-10-07 21:55:33 -070017 Future<CompletedBatchOperation> install(T intent);
Brian O'Connorb876bf12014-10-02 14:59:37 -070018
19 /**
20 * Uninstalls the specified intent from the environment.
21 *
22 * @param intent intent to be uninstalled
23 * @throws IntentException if issues are encountered while uninstalling the intent
24 */
Brian O'Connorcb900f42014-10-07 21:55:33 -070025 Future<CompletedBatchOperation> uninstall(T intent);
Brian O'Connorb876bf12014-10-02 14:59:37 -070026}