org.springframework.validation.beanvalidation

## 类 LocaleContextMessageInterpolator

- java.lang.Object
- - org.springframework.validation.beanvalidation.LocaleContextMessageInterpolator

- 所有已实现的接口:
    MessageInterpolator

      public class LocaleContextMessageInterpolator
      extends Object
      implements MessageInterpolator

  Delegates to a target `MessageInterpolator` implementation but enforces Spring's managed Locale. Typically used to wrap the validation provider's default interpolator.
  从以下版本开始:
    3.0
  作者:
    Juergen Hoeller
  另请参阅:
    `LocaleContextHolder.getLocale()`

- - ### 嵌套类概要

    - ### 从接口继承的嵌套类/接口 javax.validation.MessageInterpolator

      `MessageInterpolator.Context`

  - ### 构造器概要

    构造器
    构造器和说明
    `LocaleContextMessageInterpolator(MessageInterpolator targetInterpolator)` Create a new LocaleContextMessageInterpolator, wrapping the given target interpolator.

  - ### 方法概要

    所有方法 实例方法 具体方法
    限定符和类型 | 方法和说明
    --- | ---
    `String` | `interpolate(String message, MessageInterpolator.Context context)`
    `String` | `interpolate(String message, MessageInterpolator.Context context, Locale locale)`

    - ### 从类继承的方法 java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### 构造器详细资料

    - #### LocaleContextMessageInterpolator

          public LocaleContextMessageInterpolator(MessageInterpolator targetInterpolator)

      Create a new LocaleContextMessageInterpolator, wrapping the given target interpolator.
      参数:
        `targetInterpolator` - the target MessageInterpolator to wrap

  - ### 方法详细资料

    - #### interpolate

          public String interpolate(String message,
                                    MessageInterpolator.Context context)

      指定者:
        `interpolate` 在接口中 `MessageInterpolator`

    - #### interpolate

          public String interpolate(String message,
                                    MessageInterpolator.Context context,
                                    Locale locale)

      指定者:
        `interpolate` 在接口中 `MessageInterpolator`