com.holonplatform.vaadin7.components

## Interface PropertyInputGroup.Builder<G extends PropertyInputGroup,B extends PropertyInputGroup.Builder<G,B>>

- Type Parameters:
    `G` - Actual `PropertyInputGroup` type
    `B` - Concrete builder type
  All Known Subinterfaces:
    PropertyInputForm.PropertyInputFormBuilder<C>, PropertyInputGroup.PropertyInputGroupBuilder
  Enclosing interface:
    PropertyInputGroup

      public static interface PropertyInputGroup.Builder<G extends PropertyInputGroup,B extends PropertyInputGroup.Builder<G,B>>

  Base `PropertyInputGroup` builder.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `default <T> B` | `bind(com.holonplatform.core.property.Property<T> property, Input.InputPropertyRenderer<T> renderer)` Convenience method to set a specific `PropertyRenderer` to use to render the `Input` to bind to given `property` using the `Input.InputPropertyRenderer` functional interface.
    `default <T> B` | `bind(com.holonplatform.core.property.Property<T> property, Input<T> input)` Bind the given `property` to given `input` instance.
    `<T> B` | `bind(com.holonplatform.core.property.Property<T> property, com.holonplatform.core.property.PropertyRenderer<Input<T>,T> renderer)` Set the specific `PropertyRenderer` to use to render the `Input` to bind to given `property`.
    `G` | `build()` Build the `PropertyInputGroup`.
    `<T> B` | `defaultValue(com.holonplatform.core.property.Property<T> property, PropertyInputGroup.DefaultValueProvider<T> defaultValueProvider)` Set the default value provider for given `property`.
    `<T> B` | `hidden(com.holonplatform.core.property.Property<T> property)` Set the given property as hidden.
    `B` | `ignoreMissingInputs(boolean ignoreMissingInputs)` Set whether to ignore properties without a bound `Input`.
    `B` | `ignorePropertyValidation()` Set to ignore any `Property` registered `Validator` when binding the property to an `Input` component, i.e. to not inherit property `Validator`s when the property-input binding is performed.
    `<P extends com.holonplatform.core.property.Property> B` | `properties(Iterable<P> properties)` Add given properties to the `PropertyInputGroup` property set.
    `<P extends com.holonplatform.core.property.Property> B` | `properties(P... properties)` Add given properties to the `PropertyInputGroup` property set.
    `B` | `propertiesValidationStatusHandler(ValidationStatusHandler validationStatusHandler)` Set the `ValidationStatusHandler` to use to track all the properties validation status changes.
    `<T> B` | `readOnly(com.holonplatform.core.property.Property<T> property)` Set the given property as read-only.
    `<T> B` | `required(com.holonplatform.core.property.Property<T> property)` Set the given property as required.
    `<T> B` | `required(com.holonplatform.core.property.Property<T> property, com.holonplatform.core.i18n.Localizable message)` Set the given property as required.
    `default <T> B` | `required(com.holonplatform.core.property.Property<T> property, String message)` Set the given property as required.
    `default <T> B` | `required(com.holonplatform.core.property.Property<T> property, String message, String messageCode, Object... arguments)` Set the given property as required.
    `<T> B` | `required(com.holonplatform.core.property.Property<T> property, com.holonplatform.core.Validator<T> validator)` Set the given property as required, using given `Validator` to check the property value.
    `B` | `stopOverallValidationAtFirstFailure(boolean stopOverallValidationAtFirstFailure)` Set whether to stop overall validation at first validation failure.
    `B` | `stopValidationAtFirstFailure(boolean stopValidationAtFirstFailure)` Set whether to stop validation at first validation failure.
    `B` | `validateOnValueChange(boolean validateOnValueChange)` Sets whether to validate the available `Input`s value every time the `Input` value changes.
    `default B` | `validationStatusHandler(com.vaadin.ui.Label statusLabel)` Set the `Label` to use as status label to track overall validation status changes.
    `default <T> B` | `validationStatusHandler(com.holonplatform.core.property.Property<T> property, com.vaadin.ui.Label statusLabel)` Set the `Label` to use to track given `property` validation status changes.
    `<T> B` | `validationStatusHandler(com.holonplatform.core.property.Property<T> property, ValidationStatusHandler validationStatusHandler)` Set the `ValidationStatusHandler` to use to track given `property` validation status changes.
    `B` | `validationStatusHandler(ValidationStatusHandler validationStatusHandler)` Set the `ValidationStatusHandler` to use to track overall validation status changes.
    `B` | `withPostProcessor(PropertyBinding.PostProcessor<Input<?>> postProcessor)` Add a `PropertyBinding.PostProcessor` to allow further `Input` configuration before the input is actually bound to a property.
    `default <T> B` | `withValidator(com.holonplatform.core.property.Property<T> property, com.vaadin.data.Validator validator)` Adds a `Validator` to the `Input` bound to given `property`.
    `<T> B` | `withValidator(com.holonplatform.core.property.Property<T> property, com.holonplatform.core.Validator<T> validator)` Adds a `Validator` to the `Input` bound to given `property`.
    `default B` | `withValidator(com.vaadin.data.Validator validator)` Adds a `Validator` to the `PropertyInputGroup`.
    `B` | `withValidator(com.holonplatform.core.Validator<com.holonplatform.core.property.PropertyBox> validator)` Adds a `Validator` to the `PropertyInputGroup`, using a `PropertyBox` to provide the property values to validate.

- - ### Method Detail

    - #### properties

          <P extends com.holonplatform.core.property.Property> B properties(P... properties)

      Add given properties to the `PropertyInputGroup` property set.
      Type Parameters:
        `P` - Property type
      Parameters:
        `properties` - Properties to add
      Returns:
        this

    - #### properties

          <P extends com.holonplatform.core.property.Property> B properties(Iterable<P> properties)

      Add given properties to the `PropertyInputGroup` property set.
      Type Parameters:
        `P` - Property type
      Parameters:
        `properties` - Properties to add (not null)
      Returns:
        this

    - #### readOnly

          <T> B readOnly(com.holonplatform.core.property.Property<T> property)

      Set the given property as read-only. If a property is read-only, the `Input` bound to the property will be setted as read-only too, and its value will never be written to a `PropertyBox` nor validated.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property to set as read-only (not null)
      Returns:
        this

    - #### required

          <T> B required(com.holonplatform.core.property.Property<T> property)

      Set the given property as required. If a property is required, the `Input` bound to the property will be setted as required, and its validation will fail when empty.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property to set as required (not null)
      Returns:
        this

    - #### required

          <T> B required(com.holonplatform.core.property.Property<T> property,
                         com.holonplatform.core.Validator<T> validator)

      Set the given property as required, using given `Validator` to check the property value. If a property is required, the `Input` bound to the property will be setted as required, and its validation will fail when empty.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property to set as required (not null)
        `validator` - The `Validator` to use to check the required property value (not null)
      Returns:
        this

    - #### required

          <T> B required(com.holonplatform.core.property.Property<T> property,
                         com.holonplatform.core.i18n.Localizable message)

      Set the given property as required. If a property is required, the `Input` bound to the property will be setted as required, and its validation will fail when empty.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property to set as required (not null)
        `message` - The message to use to notify the required validation failure
      Returns:
        this

    - #### required

          default <T> B required(com.holonplatform.core.property.Property<T> property,
                                 String message,
                                 String messageCode,
                                 Object... arguments)

      Set the given property as required. If a property is required, the `Input` bound to the property will be setted as required, and its validation will fail when empty.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property to set as required (not null)
        `message` - The default message to use to notify the required validation failure
        `messageCode` - The message localization code
        `arguments` - Optional message translation arguments
      Returns:
        this

    - #### required

          default <T> B required(com.holonplatform.core.property.Property<T> property,
                                 String message)

      Set the given property as required. If a property is required, the `Input` bound to the property will be setted as required, and its validation will fail when empty.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property to set as required (not null)
        `message` - The default message to use to notify the required validation failure
      Returns:
        this

    - #### hidden

          <T> B hidden(com.holonplatform.core.property.Property<T> property)

      Set the given property as hidden. If a property is hidden, the `Input` bound to the property will never be generated, but its value will be written to a `PropertyBox` using `PropertyInputGroup.getValue()`.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property to set as hidden (not null)
      Returns:
        this

    - #### defaultValue

          <T> B defaultValue(com.holonplatform.core.property.Property<T> property,
                             PropertyInputGroup.DefaultValueProvider<T> defaultValueProvider)

      Set the default value provider for given `property`.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property (not null)
        `defaultValueProvider` - DefaultValueProvider (not null)
      Returns:
        this

    - #### withValidator

          <T> B withValidator(com.holonplatform.core.property.Property<T> property,
                              com.holonplatform.core.Validator<T> validator)

      Adds a `Validator` to the `Input` bound to given `property`.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property (not null)
        `validator` - Validator to add (not null)
      Returns:
        this

    - #### withValidator

          default <T> B withValidator(com.holonplatform.core.property.Property<T> property,
                                      com.vaadin.data.Validator validator)

      Adds a `Validator` to the `Input` bound to given `property`.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property (not null)
        `validator` - Validator to add (not null)
      Returns:
        this

    - #### withValidator

          B withValidator(com.holonplatform.core.Validator<com.holonplatform.core.property.PropertyBox> validator)

      Adds a `Validator` to the `PropertyInputGroup`, using a `PropertyBox` to provide the property values to validate.
      Parameters:
        `validator` - Validator to add (not null)
      Returns:
        this

    - #### withValidator

          default B withValidator(com.vaadin.data.Validator validator)

      Adds a `Validator` to the `PropertyInputGroup`.
      Parameters:
        `validator` - Validator to add (not null)
      Returns:
        this

    - #### validationStatusHandler

          <T> B validationStatusHandler(com.holonplatform.core.property.Property<T> property,
                                        ValidationStatusHandler validationStatusHandler)

      Set the `ValidationStatusHandler` to use to track given `property` validation status changes.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property for which to set the validation status handler
        `validationStatusHandler` - the `ValidationStatusHandler` to associate to given `property` (not null)
      Returns:
        this

    - #### validationStatusHandler

          default <T> B validationStatusHandler(com.holonplatform.core.property.Property<T> property,
                                                com.vaadin.ui.Label statusLabel)

      Set the `Label` to use to track given `property` validation status changes.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property for which to set the validation status label
        `statusLabel` - the status `Label` to use to track given `property` validation status (not null)
      Returns:
        this

    - #### propertiesValidationStatusHandler

          B propertiesValidationStatusHandler(ValidationStatusHandler validationStatusHandler)

      Set the `ValidationStatusHandler` to use to track all the properties validation status changes.

      A specific `ValidationStatusHandler` for each property can be configured using `validationStatusHandler(Property, ValidationStatusHandler)`.

      Parameters:
        `validationStatusHandler` - the `ValidationStatusHandler` to set
      Returns:
        this

    - #### validationStatusHandler

          B validationStatusHandler(ValidationStatusHandler validationStatusHandler)

      Set the `ValidationStatusHandler` to use to track overall validation status changes.
      Parameters:
        `validationStatusHandler` - the `ValidationStatusHandler` to set (not null)
      Returns:
        this

    - #### validationStatusHandler

          default B validationStatusHandler(com.vaadin.ui.Label statusLabel)

      Set the `Label` to use as status label to track overall validation status changes.
      Parameters:
        `statusLabel` - the status `Label` to set (not null)
      Returns:
        this

    - #### validateOnValueChange

          B validateOnValueChange(boolean validateOnValueChange)

      Sets whether to validate the available `Input`s value every time the `Input` value changes.

      Default is `true`.

      Parameters:
        `validateOnValueChange` - `true` to perform value validation every time a `Input` value changes, `false` if not
      Returns:
        this

    - #### stopValidationAtFirstFailure

          B stopValidationAtFirstFailure(boolean stopValidationAtFirstFailure)

      Set whether to stop validation at first validation failure. If `true`, only the first `Validator.ValidationException` is thrown at validation, otherwise a `Validator.ValidationException` containing all the occurred validation exception is thrown.
      Parameters:
        `stopValidationAtFirstFailure` - `true` to stop validation at first validation failure
      Returns:
        this

    - #### stopOverallValidationAtFirstFailure

          B stopOverallValidationAtFirstFailure(boolean stopOverallValidationAtFirstFailure)

      Set whether to stop overall validation at first validation failure. If `true`, only the first `PropertyInputGroup.OverallValidationException` is thrown at validation, otherwise a `PropertyInputGroup.OverallValidationException` containing all the occurred validation exception is thrown.

      The overall validation is the one which is performed using validators added with `withValidator(Validator)` method.

      Parameters:
        `stopOverallValidationAtFirstFailure` - `true` to stop overall validation at first validation failure
      Returns:
        this

    - #### ignorePropertyValidation

          B ignorePropertyValidation()

      Set to ignore any `Property` registered `Validator` when binding the property to an `Input` component, i.e. to not inherit property `Validator`s when the property-input binding is performed.
      Returns:
        this

    - #### bind

          <T> B bind(com.holonplatform.core.property.Property<T> property,
                     com.holonplatform.core.property.PropertyRenderer<Input<T>,T> renderer)

      Set the specific `PropertyRenderer` to use to render the `Input` to bind to given `property`.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property (not null)
        `renderer` - Property renderer (not null)
      Returns:
        this

    - #### bind

          default <T> B bind(com.holonplatform.core.property.Property<T> property,
                             Input.InputPropertyRenderer<T> renderer)

      Convenience method to set a specific `PropertyRenderer` to use to render the `Input` to bind to given `property` using the `Input.InputPropertyRenderer` functional interface.
      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property (not null)
        `renderer` - Property renderer (not null)
      Returns:
        this

    - #### bind

          default <T> B bind(com.holonplatform.core.property.Property<T> property,
                             Input<T> input)

      Bind the given `property` to given `input` instance. If the property was already bound to a `Input`, the old input will be replaced by the new input.

      This method also adds property validators to given `Input` when applicable.

      Type Parameters:
        `T` - Property type
      Parameters:
        `property` - Property (not null)
        `input` - Input to bind (not null)
      Returns:
        this

    - #### ignoreMissingInputs

          B ignoreMissingInputs(boolean ignoreMissingInputs)

      Set whether to ignore properties without a bound `Input`. Default is `false`, and an exception is thrown if a property of the `PropertyInputGroup` cannot be bound to any input component.
      Parameters:
        `ignoreMissingInputs` - Whether to ignore when the `Input` for a property is missing
      Returns:
        this

    - #### withPostProcessor

          B withPostProcessor(PropertyBinding.PostProcessor<Input<?>> postProcessor)

      Add a `PropertyBinding.PostProcessor` to allow further `Input` configuration before the input is actually bound to a property.
      Parameters:
        `postProcessor` - the `PropertyBinding.PostProcessor` to add (not null)
      Returns:
        this

    - #### build

          G build()

      Build the `PropertyInputGroup`.
      Returns:
        a new `PropertyInputGroup` instance

Copyright © 2019 The Holon Platform. All rights reserved.