Class AbstractValueBinding<V>

java.lang.Object
io.jmix.flowui.data.binding.impl.AbstractValueBinding<V>
All Implemented Interfaces:
JmixBinding, ValueBinding<V>
Direct Known Subclasses:
FieldValueBinding

public abstract class AbstractValueBinding<V> extends Object implements ValueBinding<V>
  • Field Details

    • applicationContext

      protected org.springframework.context.ApplicationContext applicationContext
    • messageTools

      protected MessageTools messageTools
    • metadataTools

      protected MetadataTools metadataTools
    • validator

      protected javax.validation.Validator validator
    • valueSource

      protected ValueSource<V> valueSource
    • component

      protected com.vaadin.flow.component.HasValue<?,V> component
    • componentValueChangeRegistration

      protected com.vaadin.flow.shared.Registration componentValueChangeRegistration
    • valueSourceValueChangeSubscription

      protected com.vaadin.flow.shared.Registration valueSourceValueChangeSubscription
    • valueSourceStateChangeSubscription

      protected com.vaadin.flow.shared.Registration valueSourceStateChangeSubscription
  • Constructor Details

    • AbstractValueBinding

      public AbstractValueBinding(ValueSource<V> valueSource, com.vaadin.flow.component.HasValue<?,V> component)
  • Method Details

    • setApplicationContext

      @Autowired public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
    • setMessageTools

      @Autowired public void setMessageTools(MessageTools messageTools)
    • setMetadataTools

      @Autowired public void setMetadataTools(MetadataTools metadataTools)
    • setValidator

      @Autowired public void setValidator(javax.validation.Validator validator)
    • getValueSource

      public ValueSource<V> getValueSource()
      Specified by:
      getValueSource in interface ValueBinding<V>
    • getComponent

      public com.vaadin.flow.component.HasValue<?,V> getComponent()
      Specified by:
      getComponent in interface ValueBinding<V>
    • bind

      public void bind()
      Specified by:
      bind in interface JmixBinding
    • valueSourceStateChanged

      protected void valueSourceStateChanged(DataUnit.StateChangeEvent event)
    • onValueSourceValueChange

      protected void onValueSourceValueChange(ValueSource.ValueChangeEvent<V> event)
    • onComponentValueChange

      protected void onComponentValueChange()
    • unbind

      public void unbind()
      Specified by:
      unbind in interface JmixBinding
    • activate

      public void activate()
      Specified by:
      activate in interface ValueBinding<V>
    • setValueToSource

      protected void setValueToSource(V value)
    • initRequired

      protected void initRequired(com.vaadin.flow.component.HasValue<?,V> component, MetaPropertyPath metaPropertyPath)
    • initBeanValidator

      protected void initBeanValidator(SupportsValidation component, MetaPropertyPath mpp)
    • getComponentValue

      protected abstract V getComponentValue()
    • setComponentValue

      protected abstract void setComponentValue(V value)
    • addComponentValueChangeListener

      protected com.vaadin.flow.shared.Registration addComponentValueChangeListener(Runnable listener)