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 theDashletFactory
instances of the OSGI container.- Author:
- Christian Pape
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
DashletSelector.ServiceListChangedListener
Definition of theDashletSelector.ServiceListChangedListener
interface.
-
Constructor Summary
Constructors Constructor Description DashletSelector()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addServiceListChangedListener(DashletSelector.ServiceListChangedListener serviceListChangedListener)
Method for adding aDashletSelector.ServiceListChangedListener
.void
bind(DashletFactory dashletFactory)
This method adds aDashletFactory
to the list of available dashlet factories.DashletFactory
getDashletFactoryForName(String name)
Returns theDashletFactory
instance for a given nane.List<DashletFactory>
getDashletFactoryList()
Returns the list ofDashletFactory
instances known by this class.void
removeServiceListChangedListener(DashletSelector.ServiceListChangedListener serviceListChangedListener)
Method for removing aDashletSelector.ServiceListChangedListener
.void
start(org.osgi.framework.BundleContext context)
Start method of this registry.void
stop(org.osgi.framework.BundleContext context)
Stop method of this registry.void
unbind(DashletFactory dashletFactory)
This method removes aDashletFactory
from the list of available dashlet factories.
-
-
-
Method Detail
-
start
public void start(org.osgi.framework.BundleContext context) throws Exception
Start method of this registry.- Specified by:
start
in interfaceorg.osgi.framework.BundleActivator
- Parameters:
context
- theBundleContext
- Throws:
Exception
-
stop
public void stop(org.osgi.framework.BundleContext context) throws Exception
Stop method of this registry.- Specified by:
stop
in interfaceorg.osgi.framework.BundleActivator
- Parameters:
context
- theBundleContext
- Throws:
Exception
-
bind
public void bind(DashletFactory dashletFactory)
This method adds aDashletFactory
to the list of available dashlet factories.- Parameters:
dashletFactory
- the newDashletFactory
-
unbind
public void unbind(DashletFactory dashletFactory)
This method removes aDashletFactory
from the list of available dashlet factories.- Parameters:
dashletFactory
- theDashletFactory
to be removed
-
addServiceListChangedListener
public void addServiceListChangedListener(DashletSelector.ServiceListChangedListener serviceListChangedListener)
Method for adding aDashletSelector.ServiceListChangedListener
.- Parameters:
serviceListChangedListener
- theDashletSelector.ServiceListChangedListener
to add
-
removeServiceListChangedListener
public void removeServiceListChangedListener(DashletSelector.ServiceListChangedListener serviceListChangedListener)
Method for removing aDashletSelector.ServiceListChangedListener
.- Parameters:
serviceListChangedListener
- theDashletSelector.ServiceListChangedListener
to be removed
-
getDashletFactoryList
public List<DashletFactory> getDashletFactoryList()
Returns the list ofDashletFactory
instances known by this class.- Returns:
- a
List
ofDashletFactory
instances
-
getDashletFactoryForName
public DashletFactory getDashletFactoryForName(String name)
Returns theDashletFactory
instance for a given nane.- Parameters:
name
- the naem fo theDashletFactory
- Returns:
- the
DashletFactory
-
-