Package io.jmix.ui.component.impl
Class AbstractEntityAwareScreenFacet<E,S extends Screen>
java.lang.Object
io.jmix.ui.component.impl.AbstractFacet
io.jmix.ui.component.impl.AbstractScreenFacet<S>
io.jmix.ui.component.impl.AbstractEntityAwareScreenFacet<E,S>
- All Implemented Interfaces:
EntityAwareScreenFacet<E>
,Facet
,ScreenFacet<S>
,org.springframework.beans.factory.Aware
,org.springframework.context.ApplicationContextAware
- Direct Known Subclasses:
EditorScreenFacetImpl
,LookupScreenFacetImpl
public abstract class AbstractEntityAwareScreenFacet<E,S extends Screen>
extends AbstractScreenFacet<S>
implements EntityAwareScreenFacet<E>
-
Field Summary
Modifier and TypeFieldDescriptionprotected CollectionContainer<E>
protected EntityPicker<E>
protected ListComponent<E>
Fields inherited from class io.jmix.ui.component.impl.AbstractScreenFacet
actionId, afterCloseListeners, afterShowListeners, applicationContext, buttonId, openMode, optionsProvider, properties, screen, screenClass, screenConfigurer, screenId
Fields inherited from class io.jmix.ui.component.impl.AbstractFacet
id, owner
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
setContainer
(CollectionContainer<E> container) SetsCollectionContainer
.void
setEntityClass
(Class<E> entityClass) Sets entity class.void
setEntityPicker
(EntityPicker<E> entityPicker) Sets theEntityPicker
component.void
setListComponent
(ListComponent<E> listComponent) Sets list component.Methods inherited from class io.jmix.ui.component.impl.AbstractScreenFacet
addAfterCloseEventListener, addAfterShowEventListener, applyScreenConfigurer, getActionTarget, getButtonTarget, getOpenMode, getOptionsProvider, getProperties, getScreenClass, getScreenConfigurer, getScreenId, getScreenOptions, initScreenListeners, injectScreenProperties, internalRemoveAfterCloseEventListener, internalRemoveAfterShowEventListener, setActionTarget, setApplicationContext, setButtonTarget, setOpenMode, setOptionsProvider, setOwner, setProperties, setScreenClass, setScreenConfigurer, setScreenId, subscribe, subscribeOnAction, subscribeOnButton
Methods inherited from class io.jmix.ui.component.impl.AbstractFacet
getEventHub, getId, getOwner, hasSubscriptions, publish, setId, unsubscribe
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.jmix.ui.component.ScreenFacet
create, show
-
Field Details
-
entityClass
-
entityPicker
-
listComponent
-
container
-
-
Constructor Details
-
AbstractEntityAwareScreenFacet
public AbstractEntityAwareScreenFacet()
-
-
Method Details
-
setEntityClass
Description copied from interface:EntityAwareScreenFacet
Sets entity class.- Specified by:
setEntityClass
in interfaceEntityAwareScreenFacet<E>
- Parameters:
entityClass
- entity class
-
getEntityClass
- Specified by:
getEntityClass
in interfaceEntityAwareScreenFacet<E>
- Returns:
- entity class
-
setListComponent
Description copied from interface:EntityAwareScreenFacet
Sets list component.The component is used to get the
container
if it is not set explicitly byEntityAwareScreenFacet.setContainer(CollectionContainer)
method.Usually, the list component is a
Table
orDataGrid
displaying the list of entities.- Specified by:
setListComponent
in interfaceEntityAwareScreenFacet<E>
-
getListComponent
- Specified by:
getListComponent
in interfaceEntityAwareScreenFacet<E>
- Returns:
- list component
-
setEntityPicker
Description copied from interface:EntityAwareScreenFacet
Sets theEntityPicker
component.If the field is set, the framework sets the committed entity to the field after successful editor commit.
- Specified by:
setEntityPicker
in interfaceEntityAwareScreenFacet<E>
-
getEntityPicker
- Specified by:
getEntityPicker
in interfaceEntityAwareScreenFacet<E>
- Returns:
EntityPicker
-
setContainer
Description copied from interface:EntityAwareScreenFacet
SetsCollectionContainer
.The container is updated after the screen is committed. If the container is
Nested
, the framework automatically initializes the reference to the parent entity and sets up data contexts for editing compositions.- Specified by:
setContainer
in interfaceEntityAwareScreenFacet<E>
-
getContainer
- Specified by:
getContainer
in interfaceEntityAwareScreenFacet<E>
- Returns:
CollectionContainer
-