public class BackgroundServicesListImpl extends Observable implements BackgroundServicesList, ApplicationLifecycleListener
BackgroundServicesList
implementation.Constructor and Description |
---|
BackgroundServicesListImpl()
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
add(BackgroundService background)
Adds a background.
|
BackgroundService[] |
getBackgroundServices()
Gets all registered background services.
|
void |
remove(BackgroundService background)
Removes a background.
|
void |
stateChanged(Application application)
Called whenever an application has changed in the observed applications manager.
|
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, getObservers, hasChanged, notifyObservers, setChanged
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addObserver, deleteObserver
public BackgroundServicesListImpl()
public void add(BackgroundService background)
BackgroundServicesList
The observers will be notified with the background as argument.
add
in interface BackgroundServicesList
background
- the background to be added.public BackgroundService[] getBackgroundServices()
BackgroundServicesList
getBackgroundServices
in interface BackgroundServicesList
public void remove(BackgroundService background)
BackgroundServicesList
The observers are notified with the background as argument.
remove
in interface BackgroundServicesList
background
- the background to be removed.public void stateChanged(Application application)
ApplicationLifecycleListener
stateChanged
in interface ApplicationLifecycleListener
application
- the application that has changed.