@Deprecated public abstract class GenericFormBuilder extends FormBuilderBase
FormBuilder.
Encapsulates basic actions that can be done with all form builder implementations,
and delegates the actual parts that require layout decisions to the actual
implementation.LOG| Constructor and Description |
|---|
GenericFormBuilder()
Deprecated.
Default ctor.
|
GenericFormBuilder(Class<T> clz,
IReadOnlyModel<T> mdl)
Deprecated.
Create one primed with a model and class.
|
GenericFormBuilder(T instance)
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addContent(NodeBase item)
Deprecated.
Add any kind of content into the next "control area".
|
abstract void |
addContent(NodeBase label,
NodeBase[] control,
boolean editable)
Deprecated.
|
void |
addContent(NodeBase label,
NodeBase control,
boolean editable)
Deprecated.
|
void |
addContent(String label,
NodeBase control,
boolean editable)
Deprecated.
|
protected abstract void |
addControl(NodeBase label,
NodeBase labelnode,
NodeBase[] list,
boolean mandatory,
boolean editable,
PropertyMetaModel<?> pmm)
Deprecated.
|
protected abstract void |
addControl(String label,
NodeBase labelnode,
NodeBase[] list,
boolean mandatory,
boolean editable,
PropertyMetaModel<?> pmm)
Deprecated.
This is the actual workhorse doing the per-builder actual placement and layouting of a {control, label} pair.
|
IControl<?> |
addDisplayProp(String name)
Deprecated.
Add a display-only field for the specified property.
|
IControl<?> |
addDisplayProp(String name,
String label)
Deprecated.
Add an input for the specified property just as
addProp(String, String),
only this input won't be editable (ever). |
<V,T extends NodeBase & IDisplayControl<V>> |
addDisplayProp(String propertyname,
T ctl)
Deprecated.
|
IControl<?>[] |
addDisplayProps(String... names)
Deprecated.
Add the specified properties to the form as display-only properties, in the current
mode.
|
void |
addLabelAndControl(Label label,
String errorLocation,
NodeBase control,
boolean mandatory)
Deprecated.
Add a fully manually specified label and control to the layout.
|
void |
addLabelAndControl(String label,
NodeBase control,
boolean mandatory)
Deprecated.
Add a fully manually specified label and control to the layout.
|
protected abstract IControl<?>[] |
addListOfProperties(boolean editable,
String... names)
Deprecated.
Handle placement of a list of property names, all obeying the current mode in effect.
|
<T> IControl<T> |
addProp(QField<?,T> field)
Deprecated.
|
IControl<?> |
addProp(String name)
Deprecated.
Add an input for the specified property.
|
IControl<?> |
addProp(String name,
boolean editable)
Deprecated.
Add an input for the specified property.
|
IControl<?> |
addProp(String name,
boolean editable,
boolean mandatory)
Deprecated.
Add an input for the specified property.
|
IControl<?> |
addProp(String name,
String label)
Deprecated.
Add an input for the specified property.
|
<C> IControl<C> |
addProp(String name,
String label,
boolean editable,
boolean mandatory)
Deprecated.
Add an input for the specified property.
|
<V,T extends NodeBase & IControl<V>> |
addProp(String name,
String label,
T ctl)
Deprecated.
Add a user-specified control for a given property.
|
<V,T extends NodeBase & IControl<V>> |
addProp(String propertyname,
T ctl)
Deprecated.
Add a user-specified control for a given property.
|
void |
addPropertyAndControl(String propertyName,
NodeBase nb,
boolean mandatory)
Deprecated.
This adds a fully user-specified control for a given property with it's default label,
without creating any binding.
|
protected <C> IControl<C> |
addPropertyControl(String name,
String label,
PropertyMetaModel<C> pmm,
boolean editable,
boolean editableFixed)
Deprecated.
|
IControl<?>[] |
addProps(String... names)
Deprecated.
Add the specified properties to the form, in the current mode.
|
createControlFor, getBindings, getBuilder, getClassMeta, getControlLabelFactory, getCurrentInputClass, getModel, resolveProperty, setBindings, setClassModel, setControlLabelFactory, setInstance, setMetaModel, updateReadOnlypublic GenericFormBuilder()
public GenericFormBuilder(Class<T> clz, IReadOnlyModel<T> mdl)
T - clz - mdl - public GenericFormBuilder(T instance)
T - instance - protected abstract void addControl(String label, NodeBase labelnode, NodeBase[] list, boolean mandatory, boolean editable, PropertyMetaModel<?> pmm)
label - labelnode - list - mandatory - T when the node is mandatory, needed by the label factoryeditable - T when the node is editable, needed by the label factorypmm - protected abstract void addControl(NodeBase label, NodeBase labelnode, NodeBase[] list, boolean mandatory, boolean editable, PropertyMetaModel<?> pmm)
public abstract void addContent(NodeBase label, NodeBase[] control, boolean editable)
public void addContent(@Nonnull NodeBase item)
item - protected abstract IControl<?>[] addListOfProperties(boolean editable, String... names)
editable - names - public IControl<?> addProp(String name)
name - public IControl<?> addProp(String name, String label)
name - label - The label text to use. Use the empty string to prevent a label from being generated. This still adds an empty cell for the label though.@Nonnull public <C> IControl<C> addProp(String name, String label, boolean editable, boolean mandatory)
name - label - Add custom label.editable - When false this adds a display-only field, when true a fully editable control.mandatory - Specify if field is mandatory. This always overrides the mandatoryness of the metadata which is questionable.public IControl<?> addProp(String name, boolean editable)
name - editable - When false add a display-only control, else add an editable control.public IControl<?> addProp(String name, boolean editable, boolean mandatory)
name - editable - When false this adds a display-only field, when true a fully editable control.mandatory - Specify if field is mandatory. This always overrides the mandatoryness of the metadata which is questionable.public IControl<?> addDisplayProp(String name)
name - public IControl<?> addDisplayProp(String name, String label)
addProp(String, String),
only this input won't be editable (ever).name - label - public <V,T extends NodeBase & IControl<V>> IControl<V> addProp(String propertyname, T ctl)
addPropertyAndControl(String, NodeBase, boolean).
FORMAL-INTERFACE.propertyname - ctl - public <V,T extends NodeBase & IDisplayControl<V>> IControl<V> addDisplayProp(String propertyname, T ctl)
public <V,T extends NodeBase & IControl<V>> IControl<V> addProp(String name, String label, T ctl)
name - label - The label text to use. Use the empty string to prevent a label from being generated. This still adds an empty cell for the label though.ctl - public void addLabelAndControl(String label, NodeBase control, boolean mandatory)
label - control - mandatory - public void addLabelAndControl(Label label, String errorLocation, NodeBase control, boolean mandatory)
label - errorLocation - control - mandatory - protected <C> IControl<C> addPropertyControl(String name, String label, PropertyMetaModel<C> pmm, boolean editable, boolean editableFixed)
name - label - pmm - editable - when false, the rendered control will be display-only.public void addPropertyAndControl(String propertyName, NodeBase nb, boolean mandatory)
propertyName - nb - mandatory - public IControl<?>[] addProps(String... names)
f.append().addProps("a", "b","c");
all three fields are appended to the current row.
FORMAL-INTERFACE.names - public IControl<?>[] addDisplayProps(String... names)
f.append().addProps("a", "b","c");
all three fields are appended to the current row.
FORMAL-INTERFACE.names - Copyright © 2017 etc.to. All rights reserved.