Package com.jformdesigner.model
Class FormBindingGroup
- java.lang.Object
-
- com.jformdesigner.model.FormObject
-
- com.jformdesigner.model.FormBindingGroup
-
- All Implemented Interfaces:
FormSelectable
public class FormBindingGroup extends FormObject implements FormSelectable
A form binding represents a group of bindings in the form model. Usually aBindingGroup.- Since:
- 5.0
-
-
Field Summary
Fields Modifier and Type Field Description static StringPROP_BOUNDstatic StringPROP_NAME-
Fields inherited from class com.jformdesigner.model.FormObject
NULL_VALUE
-
-
Constructor Summary
Constructors Constructor Description FormBindingGroup(Class<?> bindingGroupClass)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanaccept(FormBindingVisitor visitor)Accepts the given visitor.voidaddBinding(FormBinding binding)Adds a form binding to the end of this form binding group.voidaddBinding(FormBinding binding, int index)Adds a form binding to this form binding group at the specified position.Objectclone()Clones this form binding group.FormBindinggetBinding(int index)Returns the form binding atindex.intgetBindingCount()Returns the number of form bindings in this form binding group.Class<?>getBindingGroupClass()Returns the binding group class.intgetBindingIndex(FormBinding binding)Returns the index ofbindingin this binding group; or -1 if the binding is not a child of this binding group.FormBinding[]getBindings()Returns all form bindings in this form binding group.StringgetName()Returns the name of this binding group.FormRootgetRoot()Returns the form root of this form binding group.voidremoveBinding(int index)Removes the form binding at the specified index from this form binding group.voidremoveBinding(FormBinding binding)Removes the specified form binding from this form binding group.StringtoString()Returns a string representation of the object.-
Methods inherited from class com.jformdesigner.model.FormObject
equals, getClientProperty, getProperties, getProperty, getProperty, getPropertyBoolean, getPropertyBoolean, getPropertyCount, getPropertyDouble, getPropertyDouble, getPropertyInt, getPropertyInt, getPropertyNames, getPropertyString, getPropertyString, getReferenceCount, hashCode, properties, propertyNames, putClientProperty, setProperty, setProperty, setProperty, setPropertyBoolean, setPropertyBoolean, setPropertyDouble, setPropertyDouble, setPropertyInt, setPropertyInt, setPropertyString
-
-
-
-
Field Detail
-
PROP_NAME
public static final String PROP_NAME
- See Also:
- Constant Field Values
-
PROP_BOUND
public static final String PROP_BOUND
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
FormBindingGroup
public FormBindingGroup(Class<?> bindingGroupClass)
-
-
Method Detail
-
getBindingGroupClass
public Class<?> getBindingGroupClass()
Returns the binding group class.
-
getName
public String getName()
Returns the name of this binding group.
-
getBindingCount
public int getBindingCount()
Returns the number of form bindings in this form binding group.
-
getBinding
public FormBinding getBinding(int index)
Returns the form binding atindex.
-
getBindings
public FormBinding[] getBindings()
Returns all form bindings in this form binding group.
-
getBindingIndex
public int getBindingIndex(FormBinding binding)
Returns the index ofbindingin this binding group; or -1 if the binding is not a child of this binding group.
-
addBinding
public void addBinding(FormBinding binding)
Adds a form binding to the end of this form binding group.
-
addBinding
public void addBinding(FormBinding binding, int index)
Adds a form binding to this form binding group at the specified position.- Parameters:
binding- The form binding to be added.index- The position in the binding list at which to insert the binding; or -1 to insert at the end
-
removeBinding
public void removeBinding(FormBinding binding)
Removes the specified form binding from this form binding group.
-
removeBinding
public void removeBinding(int index)
Removes the form binding at the specified index from this form binding group.
-
getRoot
public FormRoot getRoot()
Returns the form root of this form binding group.
-
accept
public boolean accept(FormBindingVisitor visitor)
Accepts the given visitor. The visitor'sFormBindingVisitor.visit(com.jformdesigner.model.FormBinding)is called with all form bindings of this form binding group.- Parameters:
visitor- The visitor.- Returns:
- The result of
FormBindingVisitor.visit(com.jformdesigner.model.FormBinding).
-
toString
public String toString()
Returns a string representation of the object.- Overrides:
toStringin classFormObject
-
-