com.holonplatform.vaadin.flow.components

## Interface ValueHolder.ValueChangeEvent<V>

- Type Parameters:
    `V` - Value type
  All Superinterfaces:
    Serializable
  All Known Subinterfaces:
    GroupValueChangeEvent<V,P,C,G>
  Enclosing interface:
    ValueHolder<V,E extends ValueHolder.ValueChangeEvent<V>>

      public static interface ValueHolder.ValueChangeEvent<V>
      extends Serializable

  A `ValueHolder.ValueChangeListener` event.

- - ### Method Summary

    All Methods Static Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `static <T> ValueHolder.ValueChangeEvent<T>` | `create(ValueHolder<T,?> source, T oldValue, T value, boolean userOriginated)` Create a new `ValueHolder.ValueChangeEvent`.
    `V` | `getOldValue()` Returns the value of the source before this value change event occurred.
    `ValueHolder<V,?>` | `getSource()` Get the source of this value change event.
    `V` | `getValue()` Returns the new value that triggered this value change event.
    `boolean` | `isUserOriginated()` Returns whether this event was triggered by user interaction, on the client side, or programmatically, on the server side.

- - ### Method Detail

    - #### isUserOriginated

          boolean isUserOriginated()

      Returns whether this event was triggered by user interaction, on the client side, or programmatically, on the server side.
      Returns:
        `true` if this event originates from the client, `false` otherwise.

    - #### getSource

          ValueHolder<V,?> getSource()

      Get the source of this value change event.
      Returns:
        the `ValueHolder` type source

    - #### getOldValue

          V getOldValue()

      Returns the value of the source before this value change event occurred.
      Returns:
        the old value

    - #### getValue

          V getValue()

      Returns the new value that triggered this value change event.
      Returns:
        the new value

    - #### create

          static <T> ValueHolder.ValueChangeEvent<T> create(ValueHolder<T,?> source,
                                                            T oldValue,
                                                            T value,
                                                            boolean userOriginated)

      Create a new `ValueHolder.ValueChangeEvent`.
      Type Parameters:
        `T` - Value type
      Parameters:
        `source` - Source (not null)
        `oldValue` - Old value
        `value` - New value
        `userOriginated` - Whether is a client-side (user originated) change event or server side
      Returns:
        A new `ValueHolder.ValueChangeEvent` instance

Copyright © 2020 The Holon Platform. All rights reserved.