Package groovy.swing.binding

# Class AbstractSyntheticBinding

java.lang.Object
org.apache.groovy.swing.binding.AbstractFullBinding
groovy.swing.binding.AbstractSyntheticBinding

All Implemented Interfaces:
  `BindingUpdatable`, `FullBinding`

public abstract class AbstractSyntheticBinding extends AbstractFullBinding
Base class for bindings that observe synthetic Swing properties.

- ## Field Summary

  ### Fields inherited from class org.apache.groovy.swing.binding.AbstractFullBinding

  `converter, reverseConverter, sourceBinding, targetBinding, validator`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AbstractSyntheticBinding(PropertyBinding source, TargetBinding target, Class klass, String propertyName)`
  Creates a synthetic binding for the supplied property and component type.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `bind()`
  Installs the synthetic listeners if this binding is not already active.
  `void`
  `rebind()`
  Reinstalls the synthetic listeners when the binding is already active.
  `void`
  `setSourceBinding(SourceBinding source)`
  Validates and stores the source binding for this synthetic property.
  `void`
  `setTargetBinding(TargetBinding target)`
  Stores the target binding that receives propagated updates.
  `protected abstract void`
  `syntheticBind()`
  Hooks the synthetic listeners required by this binding.
  `protected abstract void`
  `syntheticUnbind()`
  Removes any synthetic listeners installed by this binding.
  `void`
  `unbind()`
  Removes the synthetic listeners if this binding is currently active.

  ### Methods inherited from class org.apache.groovy.swing.binding.AbstractFullBinding

  `getConverter, getReverseConverter, getSourceBinding, getTargetBinding, getValidator, reverseUpdate, setConverter, setReverseConverter, setValidator, update`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### AbstractSyntheticBinding

    public AbstractSyntheticBinding(PropertyBinding source, TargetBinding target, Class klass, String propertyName)
    Creates a synthetic binding for the supplied property and component type.
    Parameters:
      `source` - the source property binding
      `target` - the target binding
      `klass` - the supported component type
      `propertyName` - the synthetic property name

- ## Method Details

  - ### bind

    public void bind()
    Installs the synthetic listeners if this binding is not already active.

  - ### unbind

    public void unbind()
    Removes the synthetic listeners if this binding is currently active.

  - ### syntheticBind

    protected abstract void syntheticBind()
    Hooks the synthetic listeners required by this binding.

  - ### syntheticUnbind

    protected abstract void syntheticUnbind()
    Removes any synthetic listeners installed by this binding.

  - ### rebind

    public void rebind()
    Reinstalls the synthetic listeners when the binding is already active.

  - ### setSourceBinding

    public void setSourceBinding(SourceBinding source)
    Validates and stores the source binding for this synthetic property.
    Specified by:
      `setSourceBinding` in interface `FullBinding`
    Overrides:
      `setSourceBinding` in class `AbstractFullBinding`
    Parameters:
      `source` - the source binding to validate

  - ### setTargetBinding

    public void setTargetBinding(TargetBinding target)
    Stores the target binding that receives propagated updates.
    Specified by:
      `setTargetBinding` in interface `FullBinding`
    Overrides:
      `setTargetBinding` in class `AbstractFullBinding`
    Parameters:
      `target` - the target binding