com.silvermindsoftware.hitch
Interface Binder

All Known Implementing Classes:
BinderImpl

public interface Binder

Interface for convenience beans binding support between model and GUI.

Author:
Stefan Wismer (SWI)
File-location:
Binder
Last check-in date:
2009-08-04 13:59:45 +0200 (Di, 04. Aug 2009) by swismer for revision 3873

Method Summary
 org.jdesktop.beansbinding.BindingGroup addAutoBinding(Container container, boolean performValidate, String... modelId)
           
 org.jdesktop.beansbinding.AutoBinding addAutoBinding(Container container, JComponent component, BindingCreator creator, boolean performValidate)
          Bind a component to a model using a specific binding creator.
 org.jdesktop.beansbinding.BindingGroup addAutoBinding(Container container, String... modelId)
          Add all bindings that can be derived from the binding annotations.
 org.jdesktop.beansbinding.AutoBinding addManualBinding(org.jdesktop.beansbinding.AutoBinding.UpdateStrategy strategy, Object model, String property, JComponent component, boolean performValidate)
          Bind a component to a model using the standard binding creator.
 org.jdesktop.beansbinding.AutoBinding addManualBinding(org.jdesktop.beansbinding.AutoBinding binding)
          Bind a component to a model completely manually.
 org.jdesktop.beansbinding.AutoBinding addManualBinding(org.jdesktop.beansbinding.AutoBinding binding, boolean performValidate)
          Bind a component to a model completely manually.
 org.jdesktop.beansbinding.AutoBinding addManualBinding(Object model, String property, JComponent component, BindingCreator creator, boolean performValidate)
          Bind a component to a model using a specific binding creator.
 void addValidationResponder(org.jdesktop.beansbinding.AutoBinding binding, ValidationResponder responder)
          Add a custom validation responder to a binding.
 void addValidationResponder(org.jdesktop.beansbinding.BindingGroup group, ValidationResponder responder)
          Add a custom validation responder to a binding group.
 void bindAll()
          Bind all managed bindings.
 org.jdesktop.beansbinding.BindingGroup find(Object model, String property, JComponent component)
          Find a specific binding.
 void remove(org.jdesktop.beansbinding.AutoBinding binding)
          Remove a binding.
 void remove(org.jdesktop.beansbinding.BindingGroup group)
          Remove a binding group.
 void removeAll()
          Remove all bindings.
 void unbindAll()
          Unbind all managed bindings.
 

Method Detail

addAutoBinding

org.jdesktop.beansbinding.BindingGroup addAutoBinding(Container container,
                                                      String... modelId)
Add all bindings that can be derived from the binding annotations. The name of the annotated fields must match a property of the model (field prefix "m_" is removed if applicable).

Parameters:
container - the GUI component container to bind to
modelId - the optional model identifiers (to select models to bind)
Returns:
the added binding group

addAutoBinding

org.jdesktop.beansbinding.BindingGroup addAutoBinding(Container container,
                                                      boolean performValidate,
                                                      String... modelId)
Parameters:
container - the GUI component container to bind to
performValidate - validate user input
modelId - the optional model identifiers (to select models to bind)
Returns:
the added binding group

addAutoBinding

org.jdesktop.beansbinding.AutoBinding addAutoBinding(Container container,
                                                     JComponent component,
                                                     BindingCreator creator,
                                                     boolean performValidate)
Bind a component to a model using a specific binding creator.

Parameters:
container - the GUI component container to bind to
component - the form component to bind to
creator - the specific binding creator
performValidate - determines if a validation should be performed
Returns:
the created binding

addManualBinding

org.jdesktop.beansbinding.AutoBinding addManualBinding(org.jdesktop.beansbinding.AutoBinding.UpdateStrategy strategy,
                                                       Object model,
                                                       String property,
                                                       JComponent component,
                                                       boolean performValidate)
Bind a component to a model using the standard binding creator.

Parameters:
model - the model to bind
property - the property of the model to bind
component - the form component to bind
performValidate - determines if a validation should be performed
Returns:
the created binding

addManualBinding

org.jdesktop.beansbinding.AutoBinding addManualBinding(Object model,
                                                       String property,
                                                       JComponent component,
                                                       BindingCreator creator,
                                                       boolean performValidate)
Bind a component to a model using a specific binding creator.

Parameters:
model - the model to bind
property - the property of the model to bind
component - the form component to bind to
creator - the specific binding creator
performValidate - determines if a validation should be performed
Returns:
the created binding

addManualBinding

org.jdesktop.beansbinding.AutoBinding addManualBinding(org.jdesktop.beansbinding.AutoBinding binding)
Bind a component to a model completely manually.

Parameters:
binding - the binding to add
Returns:
the added binding

addManualBinding

org.jdesktop.beansbinding.AutoBinding addManualBinding(org.jdesktop.beansbinding.AutoBinding binding,
                                                       boolean performValidate)
Bind a component to a model completely manually.

Parameters:
binding - the binding to add
performValidate - determines if a validation should be performed
Returns:
the added binding

remove

void remove(org.jdesktop.beansbinding.BindingGroup group)
Remove a binding group.

Parameters:
group - the binding group to remove

remove

void remove(org.jdesktop.beansbinding.AutoBinding binding)
Remove a binding.

Parameters:
binding - the binding to remove

removeAll

void removeAll()
Remove all bindings.


find

org.jdesktop.beansbinding.BindingGroup find(Object model,
                                            String property,
                                            JComponent component)
Find a specific binding. Parameters being null mean "don't care".

Parameters:
model - the model to bind
property - the property of the model to bind to
component - the form component to bind to
Returns:
the found bindings or null if none

addValidationResponder

void addValidationResponder(org.jdesktop.beansbinding.AutoBinding binding,
                            ValidationResponder responder)
Add a custom validation responder to a binding.

Parameters:
binding - the binding
responder - the validation responder

addValidationResponder

void addValidationResponder(org.jdesktop.beansbinding.BindingGroup group,
                            ValidationResponder responder)
Add a custom validation responder to a binding group.

Parameters:
group - the binding group
responder - the validation responder

bindAll

void bindAll()
Bind all managed bindings.


unbindAll

void unbindAll()
Unbind all managed bindings.



Copyright © 2005-2011 ELCA. All Rights Reserved.