Package io.jmix.ui.component
Class ComponentGenerationContext
java.lang.Object
io.jmix.ui.component.ComponentGenerationContext
- Direct Known Subclasses:
JpqlFilterComponentGenerationContext
,PropertyFilterComponentGenerationContext
Contains information for
ComponentGenerationStrategy
when creating
components using UiComponentsGenerator
.-
Field Summary
Modifier and TypeFieldDescriptionprotected final MetaClass
protected Options
protected final String
protected Class<?>
protected ValueSource
protected org.dom4j.Element
-
Constructor Summary
ConstructorDescriptionComponentGenerationContext
(MetaClass metaClass, String property) Creates an instance of ComponentGenerationContext. -
Method Summary
Modifier and TypeMethodDescriptionClass<?>
org.dom4j.Element
setOptions
(Options options) Sets an options object, using fluent API method.setTargetClass
(Class<?> targetClass) Sets a target class for which a component is created, using fluent API method.setValueSource
(ValueSource valueSource) Sets a value source, using fluent API method.setXmlDescriptor
(org.dom4j.Element xmlDescriptor) Sets an XML descriptor which contains additional information, using fluent API method.
-
Field Details
-
metaClass
-
property
-
valueSource
-
options
-
xmlDescriptor
protected org.dom4j.Element xmlDescriptor -
targetClass
-
-
Constructor Details
-
ComponentGenerationContext
Creates an instance of ComponentGenerationContext.- Parameters:
metaClass
- the entity for which the component is createdproperty
- the entity attribute for which the component is created
-
-
Method Details
-
getMetaClass
- Returns:
- the entity for which the component is created
-
getProperty
- Returns:
- the entity attribute for which the component is created
-
getValueSource
- Returns:
- a value source that can be used to create the component
-
setValueSource
Sets a value source, using fluent API method.- Parameters:
valueSource
- a value source to set- Returns:
- this object
-
getOptions
- Returns:
- an options object
-
setOptions
Sets an options object, using fluent API method.- Parameters:
options
- an options object that can be used as optional to create the component- Returns:
- this object
-
getXmlDescriptor
@Nullable public org.dom4j.Element getXmlDescriptor()- Returns:
- an XML descriptor which contains additional information
-
setXmlDescriptor
Sets an XML descriptor which contains additional information, using fluent API method.- Parameters:
xmlDescriptor
- an XML descriptor which contains additional information- Returns:
- this object
-
getTargetClass
- Returns:
- a target class for which a component is created
-
setTargetClass
Sets a target class for which a component is created, using fluent API method. For instance, a target class can be a component or a screen.- Parameters:
targetClass
- a target class for which a component is created- Returns:
- this object
-