Class RdcBoxDelegateImpl

java.lang.Object
org.tentackle.fx.rdc.component.delegate.RdcBoxDelegateImpl

public class RdcBoxDelegateImpl extends Object
Common implementation for choice- and combobox delegates.
  • Constructor Details

    • RdcBoxDelegateImpl

      public RdcBoxDelegateImpl(FxComponent component, Supplier<javafx.collections.ObservableList> itemSupplier, Supplier<PdoComponentAddon> pdoAddonSupplier)
      Creates the delegate impl.
      Parameters:
      component - the component
      itemSupplier - gets the list of items shown by the component
      pdoAddonSupplier - get the PDO addon
  • Method Details

    • prepareSetType

      public void prepareSetType(Class<?> type)
      Prepare the component's setType method.
      Parameters:
      type - the type
    • getDomainContext

      public DomainContext getDomainContext()
      Gets the domain context from the binding properties.
      Returns:
      the context, null if not bound or no such property
    • prepareSetViewValue

      public void prepareSetViewValue()
      Prepare the component's setViewValue method.
    • getLoadAllPdosCallback

      public <T extends PersistentDomainObject<T>> javafx.util.Callback<T,Collection<T>> getLoadAllPdosCallback()
      Gets the callback to load all PDOs.
      Used by PdoComponentAddon.getAllPdos(PersistentDomainObject).
      Returns:
      the callback
    • setLoadAllPdosCallback

      public <T extends PersistentDomainObject<T>> void setLoadAllPdosCallback(javafx.util.Callback<T,Collection<T>> loadAllPdosCallback)
      Sets the callback to load all PDOs.
      Used by PdoComponentAddon.getAllPdos(PersistentDomainObject).
      Parameters:
      loadAllPdosCallback - the callback