public interface WidgetContainer<T extends Widget>
initialize(Map)) as well as managing widget focus and cleanup process.
Example: Creating and loading a Widget.WidgetConfig,
Widget,
WidgetFactory| Modifier and Type | Method and Description |
|---|---|
void |
addCockpitEventAcceptor(CockpitEventAcceptor acceptor)
Registers the
CockpitEventAcceptor acceptor with this widget container. |
void |
cleanup()
Performs widget cleanup i.e.
|
void |
focusWidget(String widgetCode)
Focuses the widget associated with the specified widget code.
|
String |
getFocusedWidgetCode()
Returns the widget code of the currently focused widget.
|
T |
getWidget(String widgetCode)
Returns the widget associated with the specified widget code.
|
WidgetFactory |
getWidgetFactory()
Returns the
WidgetFactory used for creating widgets. |
Map<String,T> |
initialize(Map<String,WidgetConfig> widgetMap)
Initializes this container i.e.
|
void |
removeCockpitEventAcceptor(CockpitEventAcceptor acceptor)
Unregisters the
CockpitEventAcceptor acceptor with this widget container. |
void |
setWidgetFactory(WidgetFactory widgetFactory)
Sets the
WidgetFactory used for creating widgets. |
Map<String,T> initialize(Map<String,WidgetConfig> widgetMap)
WidgetConfig map.widgetMap - map containing widget codes and configurations used when creating the widgetsvoid cleanup()
T getWidget(String widgetCode)
widgetCode - widget codeString getFocusedWidgetCode()
void focusWidget(String widgetCode)
widgetCode - widget codevoid setWidgetFactory(WidgetFactory widgetFactory)
WidgetFactory used for creating widgets.widgetFactory - the widget factoryWidgetFactory getWidgetFactory()
WidgetFactory used for creating widgets.void addCockpitEventAcceptor(CockpitEventAcceptor acceptor)
CockpitEventAcceptor acceptor with this widget container.acceptor - the event acceptor to registervoid removeCockpitEventAcceptor(CockpitEventAcceptor acceptor)
CockpitEventAcceptor acceptor with this widget container.acceptor - the event acceptor to unregisterCopyright © 2017 SAP SE. All Rights Reserved.