public abstract class ConfigurableBuilder extends UiDslConfigurable.Simple implements ConfigurableWithOptionDescriptors
UiDslConfigurable.Simple
for more flexible alternative.Modifier | Constructor and Description |
---|---|
protected |
ConfigurableBuilder() |
protected |
ConfigurableBuilder(java.lang.String title) |
Modifier and Type | Method and Description |
---|---|
protected void |
checkBox(java.lang.String title,
<any> prop) |
protected void |
checkBox(java.lang.String title,
Getter<java.lang.Boolean> getter,
Setter<? super java.lang.Boolean> setter)
Adds check box with given
title . |
protected <V> void |
component(javax.swing.JComponent component,
Getter<? extends V> beanGetter,
Setter<? super V> beanSetter,
Getter<? extends V> componentGetter,
Setter<? super V> componentSetter)
Adds custom component (e.g.
|
void |
createComponentRow(RowBuilder builder) |
static java.lang.String |
getConfigurableTitle(UnnamedConfigurable configurable) |
java.util.List<OptionDescription> |
getOptionDescriptors(java.lang.String configurableId,
java.util.function.Function<? super java.lang.String,java.lang.String> nameConverter) |
java.lang.String |
getTitle() |
protected void |
setTitle(java.lang.String title) |
protected ConfigurableBuilder()
protected ConfigurableBuilder(java.lang.String title)
public java.lang.String getTitle()
protected void setTitle(java.lang.String title)
protected void checkBox(java.lang.String title, Getter<java.lang.Boolean> getter, Setter<? super java.lang.Boolean> setter)
title
.
Initial checkbox value is obtained from getter
.
After the apply, the value from the check box is written back to model via setter
.protected void checkBox(java.lang.String title, <any> prop)
protected <V> void component(javax.swing.JComponent component, Getter<? extends V> beanGetter, Setter<? super V> beanSetter, Getter<? extends V> componentGetter, Setter<? super V> componentSetter)
beanGetter
and applied to the component via componentSetter
.
E.g. text is read from the model and set to the edit box.
After the apply, the value from the component is queried via componentGetter
and written back to model via beanSetter
.
E.g. text from the edit box is queried and saved back to model bean.public java.util.List<OptionDescription> getOptionDescriptors(java.lang.String configurableId, java.util.function.Function<? super java.lang.String,java.lang.String> nameConverter)
getOptionDescriptors
in interface ConfigurableWithOptionDescriptors
public void createComponentRow(RowBuilder builder)
public static java.lang.String getConfigurableTitle(UnnamedConfigurable configurable)