com.holonplatform.vaadin.flow.components.builders

## Interface ComponentConfigurator<C extends ComponentConfigurator<C>>

- Type Parameters:
    `C` - Concrete configurator type
  All Superinterfaces:
    HasElementConfigurator<C>
  All Known Subinterfaces:
    BaseDateInputBuilder<D,B>, BeanListingBuilder<T>, BeanListingBuilder.DatastoreBeanListingBuilder<T>, BeanListingConfigurator<T,C>, BooleanInputBuilder, ButtonBuilder, ButtonConfigurator<C>, ButtonConfigurator.BaseButtonConfigurator, ComponentBuilder<C,B>, ComponentConfigurator.BaseComponentConfigurator, ContextMenuBuilder, ContextMenuConfigurator<L,M,C>, DateInputBuilder, DateTimeInputBuilder, DialogBuilder<B>, DialogBuilder.ConfirmDialogBuilder, DialogBuilder.MessageDialogBuilder, DialogBuilder.QuestionDialogBuilder, DialogConfigurator<C>, DialogConfigurator.ClosableDialogConfigurator<C>, FormLayoutBuilder, FormLayoutConfigurator<C>, FormLayoutConfigurator.BaseFormLayoutConfigurator, HasValueInputBuilder<T,H,C>, HorizontalLayoutBuilder, HtmlComponentConfigurator<C>, InputAdapterBuilder<T,V,H,C,B>, InputBuilder<T,E,C,B>, InputConfigurator<T,E,C>, InputConfigurator.BaseInputConfigurator<T>, InputConverterBuilder<T,V,H,C>, InputValueConfigurator<T,E,C>, ItemListingBuilder<T,P,L,B>, ItemListingConfigurator<T,P,L,C>, ItemListingConfigurator.ItemListingContextMenuBuilder<T,P,L,B>, LabelBuilder<L>, LabelConfigurator<L,C>, LabelConfigurator.BaseLabelConfigurator<L>, LocalDateInputBuilder, LocalDateTimeInputBuilder, LocalTimeInputBuilder, MultiSelectInputBuilder<T,ITEM,B>, NativeButtonBuilder, NavigationLink.Builder, NumberInputBuilder<T>, OptionsModeMultiSelectInputBuilder<T,ITEM,B>, OptionsModeMultiSelectInputBuilder.DatastoreItemOptionsModeMultiSelectInputBuilder<T,ITEM>, OptionsModeMultiSelectInputBuilder.DatastorePropertyOptionsModeMultiSelectInputBuilder<T>, OptionsModeMultiSelectInputBuilder.ItemOptionsModeMultiSelectInputBuilder<T,ITEM>, OptionsModeMultiSelectInputBuilder.PropertyOptionsModeMultiSelectInputBuilder<T>, OptionsModeSingleSelectInputBuilder<T,ITEM,B>, OptionsModeSingleSelectInputBuilder.DatastoreItemOptionsModeSingleSelectInputBuilder<T,ITEM>, OptionsModeSingleSelectInputBuilder.DatastorePropertyOptionsModeSingleSelectInputBuilder<T>, OptionsModeSingleSelectInputBuilder.ItemOptionsModeSingleSelectInputBuilder<T,ITEM>, OptionsModeSingleSelectInputBuilder.PropertyOptionsModeSingleSelectInputBuilder<T>, PasswordInputBuilder, PropertyFormConfigurator<L,E,G,C>, PropertyInputFormBuilder<C>, PropertyListingBuilder, PropertyListingBuilder.DatastorePropertyListingBuilder, PropertyListingConfigurator<C>, PropertyViewFormBuilder<C>, SelectableInputConfigurator<T,S,C>, SelectModeSingleSelectInputBuilder<T,ITEM,B>, SelectModeSingleSelectInputBuilder.DatastoreItemSelectModeSingleSelectInputBuilder<T,ITEM>, SelectModeSingleSelectInputBuilder.DatastorePropertySelectModeSingleSelectInputBuilder<T>, SelectModeSingleSelectInputBuilder.ItemSelectModeSingleSelectInputBuilder<T,ITEM>, SelectModeSingleSelectInputBuilder.PropertySelectModeSingleSelectInputBuilder<T>, SingleSelectInputBuilder<T,ITEM,B>, StringAreaInputBuilder, StringInputBuilder, ThemableFlexComponentConfigurator<C>, ThemableFlexComponentConfigurator.HorizontalLayoutConfigurator, ThemableFlexComponentConfigurator.VerticalLayoutConfigurator, VerticalLayoutBuilder, ViewComponentBuilder<T>

      public interface ComponentConfigurator<C extends ComponentConfigurator<C>>
      extends HasElementConfigurator<C>

  Interface to configure a `Component`.
  Since:
    5.2.0

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface and Description
    --- | ---
    `static interface` | `ComponentConfigurator.BaseComponentConfigurator` Base component configurator.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `default C` | `hidden()` Set the component as not visible.
    `C` | `id(String id)` Sets the id of the root element of this component.
    `C` | `visible(boolean visible)` Sets the component visibility.
    `C` | `withAttachListener(com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.AttachEvent> listener)` Add an `AttachEvent` `ComponentEventListener` to the component, called after the component is attached to the application.
    `C` | `withDetachListener(com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.DetachEvent> listener)` Add an `DetachEvent` `ComponentEventListener` to the component, called before the component is detached from the application.

    - ### Methods inherited from interface com.holonplatform.vaadin.flow.components.builders.HasElementConfigurator

      `withEventListener, withEventListener, withThemeName`

- - ### Method Detail

    - #### id

          C id(String id)

      Sets the id of the root element of this component. The id is used with various APIs to identify the element, and it should be unique on the page.
      Parameters:
        `id` - the id to set, or `null` to remove any previously set id
      Returns:
        this

    - #### visible

          C visible(boolean visible)

      Sets the component visibility.

      When a component is set as invisible, all the updates of the component from the server to the client are blocked until the component is set as visible again.

      Invisible components don't receive any updates from the client-side.

      Parameters:
        `visible` - Whether the component is visible
      Returns:
        this

    - #### hidden

          default C hidden()

      Set the component as not visible.

      When a component is set as invisible, all the updates of the component from the server to the client are blocked until the component is set as visible again.

      Invisible components don't receive any updates from the client-side.

      Returns:
        this
      See Also:
        `visible(boolean)`

    - #### withAttachListener

          C withAttachListener(com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.AttachEvent> listener)

      Add an `AttachEvent` `ComponentEventListener` to the component, called after the component is attached to the application.
      Parameters:
        `listener` - Listener to add
      Returns:
        this

    - #### withDetachListener

          C withDetachListener(com.vaadin.flow.component.ComponentEventListener<com.vaadin.flow.component.DetachEvent> listener)

      Add an `DetachEvent` `ComponentEventListener` to the component, called before the component is detached from the application.
      Parameters:
        `listener` - Listener to add
      Returns:
        this

Copyright © 2019 The Holon Platform. All rights reserved.