Added mechanism for apps to easily add their own custom link/node/host highlighting wihout having to create a new UI extensions
Change-Id: Iefa21d76190c60db79a4b07a8b22e301d29fe58e
diff --git a/core/api/src/main/java/org/onosproject/ui/UiExtensionService.java b/core/api/src/main/java/org/onosproject/ui/UiExtensionService.java
index 9e03a51..f1ea508 100644
--- a/core/api/src/main/java/org/onosproject/ui/UiExtensionService.java
+++ b/core/api/src/main/java/org/onosproject/ui/UiExtensionService.java
@@ -56,6 +56,22 @@
}
/**
+ * Registers the specified topo hilighter factory.
+ *
+ * @param factory UI topo higlighter factory to register
+ */
+ default void register(UiTopoHighlighterFactory factory) {
+ }
+
+ /**
+ * Unregisters the specified user interface extension.
+ *
+ * @param factory UI topo higlighter factory to unregister
+ */
+ default void unregister(UiTopoHighlighterFactory factory) {
+ }
+
+ /**
* Returns the list of registered user interface extensions.
*
* @return list of extensions
@@ -80,6 +96,15 @@
}
/**
+ * Returns the list of registered topo highlighter factories.
+ *
+ * @return list of highlighter factories
+ */
+ default List<UiTopoHighlighterFactory> getTopoHighlighterFactories() {
+ return new ArrayList<UiTopoHighlighterFactory>();
+ }
+
+ /**
* Returns the navigation pane localization bundle.
*
* @return the navigation localization bundle