public interface ContentPresenter
ContentView
, it represents a view type in the workbench.
Magnolia provides default implementations of this interface for displaying data as a tree, list or thumbnails.implentationClass
property of a ContentPresenterDefinition
,
and by registering such definition in the workbench's contentViews node in configuration.Modifier and Type | Method and Description |
---|---|
void |
expand(Object itemId)
Make sure the given items are visible in the content view.
|
List<Object> |
getSelectedItemIds() |
void |
refresh()
Refreshes the data container and view.
|
void |
select(List<Object> itemIds)
Selects the given items in the content view.
|
void |
setSelectedItemIds(List<Object> itemId)
Sets the selected item ids for this presenter to react on, e.g. with keyboard shortcuts.
|
ContentView |
start(WorkbenchDefinition workbenchDefinition,
info.magnolia.event.EventBus eventBus,
String viewTypeName,
ContentConnector contentConnector)
Initializes the presenter with the workbench definition, eventBus and viewType name.
|
ContentView start(WorkbenchDefinition workbenchDefinition, info.magnolia.event.EventBus eventBus, String viewTypeName, ContentConnector contentConnector)
workbenchDefinition
- the workbench definition that defines which data to presenteventBus
- the event bus to fire e.g. selection events onviewTypeName
- the view type as defined in the presenter definitioncontentConnector
- void refresh()
List<Object> getSelectedItemIds()
void setSelectedItemIds(List<Object> itemId)
void expand(Object itemId)
itemId
- Copyright © 2019 Magnolia International Ltd.. All rights reserved.