org.apache.tamaya.inject.api

## Enum UpdatePolicy

- java.lang.Object
- - java.lang.Enum<UpdatePolicy>
  - - org.apache.tamaya.inject.api.UpdatePolicy

- All Implemented Interfaces:
    Serializable, Comparable<UpdatePolicy>

      public enum UpdatePolicy
      extends Enum<UpdatePolicy>

  Policy to control how new values are applied to a `DynamicValue`.

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `EXPLCIT` New values or not applied, but stored in the newValue property.
    `IMMEDEATE` New values are applied immedately and registered listeners are informed about the change.
    `LOG_ONLY` All listeners are informed about the change encountered, but the value will not be applied.
    `NEVER` New values are always immedately discarded, listeners are not triggered.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static UpdatePolicy` | `valueOf(String name)` Returns the enum constant of this type with the specified name.
    `static UpdatePolicy[]` | `values()` Returns an array containing the constants of this enum type, in the order they are declared.

    - ### Methods inherited from class java.lang.Enum

      `clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Enum Constant Detail

    - #### IMMEDEATE

          public static final UpdatePolicy IMMEDEATE

      New values are applied immedately and registered listeners are informed about the change.

    - #### EXPLCIT

          public static final UpdatePolicy EXPLCIT

      New values or not applied, but stored in the newValue property. Explcit call to DynamicValue#commit of DynamicValue#commitAndGet are required to accept the change and inform the listeners about the change. Registered listeners will be informed, when the commit was performed explicitly.

    - #### NEVER

          public static final UpdatePolicy NEVER

      New values are always immedately discarded, listeners are not triggered.

    - #### LOG_ONLY

          public static final UpdatePolicy LOG_ONLY

      All listeners are informed about the change encountered, but the value will not be applied.

  - ### Method Detail

    - #### values

          public static UpdatePolicy[] values()

      Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:

          for (UpdatePolicy c : UpdatePolicy.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static UpdatePolicy valueOf(String name)

      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
        `name` - the name of the enum constant to be returned.
      Returns:
        the enum constant with the specified name
      Throws:
        `IllegalArgumentException` - if this enum type has no constant with the specified name
        `NullPointerException` - if the argument is null

Copyright © 2014–2016 Apache Software Foundation. All rights reserved.