|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.richclient.form.builder.AbstractFormBuilder
org.springframework.richclient.form.builder.TableFormBuilder
public class TableFormBuilder
A TableFormBuilder builds a form by using a TableLayoutBuilder
Constructor Summary | |
---|---|
TableFormBuilder(BindingFactory bindingFactory)
Creates an instances of the TableFormBuilder by using a BindingFactory |
|
TableFormBuilder(BindingFactory bindingFactory,
TableLayoutBuilder tableLayoutBuilder)
Creates an instances of the TableFormBuilder by using a BindingFactory and a given |
Method Summary | |
---|---|
JComponent[] |
add(Binding binding)
Adds the field binding to the form. |
JComponent[] |
add(Binding binding,
String attributes)
Adds the field binding to the form. |
JComponent[] |
add(String fieldName)
Adds the field to the form. |
JComponent[] |
add(String fieldName,
JComponent component)
Adds the field to the form by using the provided component. |
JComponent[] |
add(String fieldName,
JComponent component,
String attributes)
Adds the field to the form by using the provided component. |
JComponent[] |
add(String fieldName,
String attributes)
Adds the field to the form. |
JComponent[] |
addBinding(Binding binding,
JComponent wrappedControl,
String attributes)
adds a field binding to the form |
JComponent[] |
addBinding(Binding binding,
JComponent wrappedComponent,
String attributes,
String labelAttributes)
adds a field binding to the form |
JComponent[] |
addBinding(Binding binding,
String attributes,
String labelAttributes)
adds a field binding to the form. |
JComponent[] |
addInScrollPane(Binding binding)
Adds the field binding to the form. |
JComponent[] |
addInScrollPane(Binding binding,
String attributes)
Adds the field binding to the form. |
JComponent[] |
addInScrollPane(String fieldName)
Adds the field to the form by using the default binding. |
JComponent[] |
addInScrollPane(String fieldName,
String attributes)
Adds the field to the form by using the default binding. |
JComponent[] |
addPasswordField(String fieldName)
Adds the field to the form by using a password component. |
JComponent[] |
addPasswordField(String fieldName,
String attributes)
Adds the field to the form by using a password component. |
JComponent[] |
addSelector(String fieldName,
Constraint filter)
Adds the field to the form by using a selector component. |
JComponent[] |
addSelector(String fieldName,
Constraint filter,
String attributes)
Adds the field to the form by using a selector component. |
void |
addSeparator(String text)
Adds a labeled separator to the form. |
void |
addSeparator(String text,
String attributes)
Adds a labeled separator to the form |
JComponent[] |
addTextArea(String fieldName)
Adds the field to the form by using a text area component which is wrapped inside a scrollpane. |
JComponent[] |
addTextArea(String fieldName,
String attributes)
Adds the field to the form by using a text area component which is wrapped inside a scrollpane. |
JComponent |
getForm()
Returns the form which has been created by this builder |
String |
getLabelAttributes()
returns the default label layout attributes for the form. |
TableLayoutBuilder |
getLayoutBuilder()
Returns the layout builder which is used to build the layout of the added fields and labels |
void |
row()
adds a row to the form. |
void |
setLabelAttributes(String labelAttributes)
defines the default label layout attributes for the form. |
Methods inherited from class org.springframework.richclient.form.builder.AbstractFormBuilder |
---|
createBinding, createBinding, createDefaultBinding, createLabelFor, createPasswordField, createScrollPane, createSelector, createTextArea, getBindingFactory, getComponentFactory, getFormComponentInterceptor, getFormModel, setComponentFactory, setFormComponentInterceptorFactory |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TableFormBuilder(BindingFactory bindingFactory)
BindingFactory
bindingFactory
- the binding factory to use to create field bindings.public TableFormBuilder(BindingFactory bindingFactory, TableLayoutBuilder tableLayoutBuilder)
BindingFactory
and a given
bindingFactory
- the binding factory to use to create field bindings.Method Detail |
---|
public void row()
public JComponent[] add(String fieldName)
AbstractFormBuilder.createDefaultBinding(String)
is used to create the binding for the field
fieldName
- the name of the field to addattributes
- optional layout attributes for the component. See TableLayoutBuilder
for syntax details
public JComponent[] add(Binding binding)
binding
- the field binding to add
public JComponent[] add(String fieldName, String attributes)
AbstractFormBuilder.createDefaultBinding(String)
is used to create the binding for the field
fieldName
- the name of the field to addattributes
- optional layout attributes for the component. See TableLayoutBuilder
for syntax details
public JComponent[] add(Binding binding, String attributes)
binding
- the field binding to addattributes
- optional layout attributes for the component. See TableLayoutBuilder
for syntax details
public JComponent[] add(String fieldName, JComponent component)
fieldName
- the name of the field to addcomponent
- the component for the field
public JComponent[] add(String fieldName, JComponent component, String attributes)
AbstractFormBuilder.createBinding(String, JComponent)
is used to
create the binding of the field
fieldName
- the name of the field to addcomponent
- the component for the fieldattributes
- optional layout attributes for the component. See TableLayoutBuilder
for syntax details
public JComponent[] addSelector(String fieldName, Constraint filter)
AbstractFormBuilder.createSelector(String, Constraint)
is used to
create the component for the selector
fieldName
- the name of the field to addfilter
- optional filter constraint for the items of the selector
AbstractFormBuilder.createSelector(String, Constraint)
public JComponent[] addSelector(String fieldName, Constraint filter, String attributes)
fieldName
- the name of the field to addfilter
- optional filter constraint for the items of the selectorattributes
- optional layout attributes for the selector component. See TableLayoutBuilder
for syntax
details
public JComponent[] addPasswordField(String fieldName)
AbstractFormBuilder.createPasswordField(String)
is used to create
the component for the password field
fieldName
- the name of the field to add
AbstractFormBuilder.createPasswordField(String)
public JComponent[] addPasswordField(String fieldName, String attributes)
AbstractFormBuilder.createPasswordField(String)
is used to create
the component for the password field
fieldName
- the name of the field to addattributes
- optional layout attributes for the password component. See TableLayoutBuilder
for syntax
details
AbstractFormBuilder.createPasswordField(String)
public JComponent[] addTextArea(String fieldName)
Note: this method ensures that the the label of the textarea has a top vertical alignment if valign
is not defined in the default label attributes
fieldName
- the name of the field to add
AbstractFormBuilder.createTextArea(String)
public JComponent[] addTextArea(String fieldName, String attributes)
AbstractFormBuilder.createTextArea(String)
is used to create the component for the text area field
Note: this method ensures that the the label of the textarea has a top vertical alignment if valign
is not defined in the default label attributes
fieldName
- the name of the field to addattributes
- optional layout attributes for the scrollpane. See TableLayoutBuilder
for syntax details
AbstractFormBuilder.createTextArea(String)
public JComponent[] addInScrollPane(String fieldName)
fieldName
- the name of the field to add
public JComponent[] addInScrollPane(String fieldName, String attributes)
fieldName
- the name of the field to addattributes
- optional layout attributes for the scrollpane. See TableLayoutBuilder
for syntax details
AbstractFormBuilder.createScrollPane(String, JComponent)
public JComponent[] addInScrollPane(Binding binding)
binding
- the binding to use
AbstractFormBuilder.createScrollPane(String, JComponent)
public JComponent[] addInScrollPane(Binding binding, String attributes)
AbstractFormBuilder.createScrollPane(String, JComponent)
is used to create the component for the scrollpane
binding
- the binding to useattributes
- optional layout attributes for the scrollpane. See TableLayoutBuilder
for syntax details
AbstractFormBuilder.createScrollPane(String, JComponent)
public void addSeparator(String text)
text
- the key for the label. Must not be nullpublic void addSeparator(String text, String attributes)
text
- the key for the label. Must not be nullattributes
- optional attributes. See TableLayoutBuilder
for syntax detailspublic TableLayoutBuilder getLayoutBuilder()
public JComponent getForm()
public String getLabelAttributes()
public void setLabelAttributes(String labelAttributes)
labelAttributes
- layout attributes for the labels, if null no layout attributes will be applied to the labels. See
TableLayoutBuilder
for syntax details.public JComponent[] addBinding(Binding binding, String attributes, String labelAttributes)
setLabelAttributes(String)
binding
- the binding of the fieldattributes
- optional layout attributes for the label. If null no layout attributes will be applied to the label.
See TableLayoutBuilder
for syntax details
public JComponent[] addBinding(Binding binding, JComponent wrappedControl, String attributes)
binding
- the binding of the fieldwrappedControl
- the optional wrapped component. If null the component of the binding is used. This Parameter should be
used if the component of the binding is being wrapped inside this componentattributes
- optional layout attributes for the label. If null no layout attributes will be applied to the label.
See TableLayoutBuilder
for syntax details
public JComponent[] addBinding(Binding binding, JComponent wrappedComponent, String attributes, String labelAttributes)
binding
- the binding of the fieldwrappedComponent
- the optional wrapped component. If null the component of the binding is used. This Parameter should be
used if the component of the binding is being wrapped inside this componentattributes
- optional layout attributes for the wrapped component. If null no layout attributes will be applied to
the component. See TableLayoutBuilder
for syntax detailsattributes
- optional layout attributes for the label. If null no layout attributes will be applied to the label.
See TableLayoutBuilder
for syntax details
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |