com.holonplatform.core.i18n

## Interface Localizable

- All Known Subinterfaces:
    BeanProperty<T>, BeanProperty.Builder<T>, FunctionExpression.FunctionExpressionProperty<T>, FunctionExpression.PathFunctionExpressionProperty<P,T>, PathProperty<T>, PathProperty.PathPropertyBuilder<T>, Property<T>, VirtualProperty<T>, VirtualProperty.Builder<T,B>
  All Known Implementing Classes:
    Validator.ValidationException, Validator.ValidationMessage

      public interface Localizable

  Provides message code, arguments and default value to obtain a localized message.
  Since:
    5.0.0
  See Also:
    `LocalizationContext`

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface and Description
    --- | ---
    `static interface` | `Localizable.Builder<B extends Localizable.Builder<B>>` Base interface for `Localizable` building
    `static interface` | `Localizable.LocalizableBuilder` `Localizable` builder
    `static class` | `Localizable.LocalizationException` Exception thrown for localization related errors.

  - ### Method Summary

    All Methods Static Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `static Localizable.LocalizableBuilder` | `builder()` Get a builder to create a `Localizable` instance
    `String` | `getMessage()` Get the default message to use if a `getMessageCode()` is not available or a localized message which corresponds to the message code cannot be found or no localization handler is available for message translation.
    `default Object[]` | `getMessageArguments()` Optional arguments to use for message localization.
    `String` | `getMessageCode()` Get the message code to use to obtain a localized message

- - ### Method Detail

    - #### getMessageCode

          String getMessageCode()

      Get the message code to use to obtain a localized message
      Returns:
        Message code

    - #### getMessage

          String getMessage()

      Get the default message to use if a `getMessageCode()` is not available or a localized message which corresponds to the message code cannot be found or no localization handler is available for message translation.
      Returns:
        Default message

    - #### getMessageArguments

          default Object[] getMessageArguments()

      Optional arguments to use for message localization.

      By default this method returns `null`. Override it to provide message localization arguments.

      Arguments resolution process is dependend from concrete localization handler. For example, a predefined argument placeholder character may be used to define arguments substitution positions within the localized message.

      Returns:
        Message localization arguments, or `null` if none

    - #### builder

          static Localizable.LocalizableBuilder builder()

      Get a builder to create a `Localizable` instance
      Returns:
        Localizable builder

Copyright © 2017 The Holon Platform. All rights reserved.