com.holonplatform.core.beans

## Enum Converter.BUILTIN

- java.lang.Object
- - java.lang.Enum<Converter.BUILTIN>
  - - com.holonplatform.core.beans.Converter.BUILTIN

- All Implemented Interfaces:
    Serializable, Comparable<Converter.BUILTIN>
  Enclosing class:
    Converter

      public static enum Converter.BUILTIN
      extends Enum<Converter.BUILTIN>

  Builtin `PropertyValueConverter`s which can be used with `Converter.builtin()` attribute.

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `ENUM_BY_NAME` Builtin converter to convert `Enum` property values into their `String` name value and back.
    `ENUM_BY_ORDINAL` Builtin converter to convert `Enum` property values into their `Integer` ordinal value and back.
    `LOCALDATE` Builtin converter to convert `Date` property values into `LocalDate`s and back.
    `LOCALDATETIME` Builtin converter to convert `Date` property values into `LocalDateTime`s and back.
    `NONE` Placeholder to represent a value not setted for builtin converter.
    `NUMERIC_BOOLEAN` Builtin converter to treat a property as a numeric boolean (i.e. converting `null` or `0` numeric values into `Boolean.FALSE` value and any other value into `Boolean.TRUE`), expecting `Integer` type as model type. value.

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Class<? extends PropertyValueConverter>` | `getConverter()` Get the `PropertyValueConverter` class
    `static Converter.BUILTIN` | `valueOf(String name)` Returns the enum constant of this type with the specified name.
    `static Converter.BUILTIN[]` | `values()` Returns an array containing the constants of this enum type, in the order they are declared.

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

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

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

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

- - ### Enum Constant Detail

    - #### NONE

          public static final Converter.BUILTIN NONE

      Placeholder to represent a value not setted for builtin converter.

    - #### NUMERIC_BOOLEAN

          public static final Converter.BUILTIN NUMERIC_BOOLEAN

      Builtin converter to treat a property as a numeric boolean (i.e. converting `null` or `0` numeric values into `Boolean.FALSE` value and any other value into `Boolean.TRUE`), expecting `Integer` type as model type. value.

    - #### ENUM_BY_ORDINAL

          public static final Converter.BUILTIN ENUM_BY_ORDINAL

      Builtin converter to convert `Enum` property values into their `Integer` ordinal value and back. The property type must be an `Enum` type.

    - #### ENUM_BY_NAME

          public static final Converter.BUILTIN ENUM_BY_NAME

      Builtin converter to convert `Enum` property values into their `String` name value and back. The property type must be an `Enum` type.

    - #### LOCALDATE

          public static final Converter.BUILTIN LOCALDATE

      Builtin converter to convert `Date` property values into `LocalDate`s and back.

    - #### LOCALDATETIME

          public static final Converter.BUILTIN LOCALDATETIME

      Builtin converter to convert `Date` property values into `LocalDateTime`s and back.

  - ### Method Detail

    - #### values

          public static Converter.BUILTIN[] 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 (Converter.BUILTIN c : Converter.BUILTIN.values())
              System.out.println(c);

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

    - #### valueOf

          public static Converter.BUILTIN 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

    - #### getConverter

          public Class<? extends PropertyValueConverter> getConverter()

      Get the `PropertyValueConverter` class
      Returns:
        PropertyValueConverter class

Copyright © 2019 The Holon Platform. All rights reserved.