Class DashletSelector
- java.lang.Object
-
- org.opennms.features.vaadin.dashboard.config.DashletSelector
-
- All Implemented Interfaces:
org.osgi.framework.BundleActivator
public class DashletSelector extends Object implements org.osgi.framework.BundleActivator
This class is responsible for holding theDashletFactoryinstances of the OSGI container.- Author:
- Christian Pape
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceDashletSelector.ServiceListChangedListenerDefinition of theDashletSelector.ServiceListChangedListenerinterface.
-
Constructor Summary
Constructors Constructor Description DashletSelector()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddServiceListChangedListener(DashletSelector.ServiceListChangedListener serviceListChangedListener)Method for adding aDashletSelector.ServiceListChangedListener.voidbind(DashletFactory dashletFactory)This method adds aDashletFactoryto the list of available dashlet factories.DashletFactorygetDashletFactoryForName(String name)Returns theDashletFactoryinstance for a given nane.List<DashletFactory>getDashletFactoryList()Returns the list ofDashletFactoryinstances known by this class.voidremoveServiceListChangedListener(DashletSelector.ServiceListChangedListener serviceListChangedListener)Method for removing aDashletSelector.ServiceListChangedListener.voidstart(org.osgi.framework.BundleContext context)Start method of this registry.voidstop(org.osgi.framework.BundleContext context)Stop method of this registry.voidunbind(DashletFactory dashletFactory)This method removes aDashletFactoryfrom the list of available dashlet factories.
-
-
-
Method Detail
-
start
public void start(org.osgi.framework.BundleContext context) throws ExceptionStart method of this registry.- Specified by:
startin interfaceorg.osgi.framework.BundleActivator- Parameters:
context- theBundleContext- Throws:
Exception
-
stop
public void stop(org.osgi.framework.BundleContext context) throws ExceptionStop method of this registry.- Specified by:
stopin interfaceorg.osgi.framework.BundleActivator- Parameters:
context- theBundleContext- Throws:
Exception
-
bind
public void bind(DashletFactory dashletFactory)
This method adds aDashletFactoryto the list of available dashlet factories.- Parameters:
dashletFactory- the newDashletFactory
-
unbind
public void unbind(DashletFactory dashletFactory)
This method removes aDashletFactoryfrom the list of available dashlet factories.- Parameters:
dashletFactory- theDashletFactoryto be removed
-
addServiceListChangedListener
public void addServiceListChangedListener(DashletSelector.ServiceListChangedListener serviceListChangedListener)
Method for adding aDashletSelector.ServiceListChangedListener.- Parameters:
serviceListChangedListener- theDashletSelector.ServiceListChangedListenerto add
-
removeServiceListChangedListener
public void removeServiceListChangedListener(DashletSelector.ServiceListChangedListener serviceListChangedListener)
Method for removing aDashletSelector.ServiceListChangedListener.- Parameters:
serviceListChangedListener- theDashletSelector.ServiceListChangedListenerto be removed
-
getDashletFactoryList
public List<DashletFactory> getDashletFactoryList()
Returns the list ofDashletFactoryinstances known by this class.- Returns:
- a
ListofDashletFactoryinstances
-
getDashletFactoryForName
public DashletFactory getDashletFactoryForName(String name)
Returns theDashletFactoryinstance for a given nane.- Parameters:
name- the naem fo theDashletFactory- Returns:
- the
DashletFactory
-
-