Class StringToLocaleConverter

  • All Implemented Interfaces:
    org.springframework.core.convert.converter.Converter<java.lang.String,​java.util.Locale>

    public class StringToLocaleConverter
    extends java.lang.Object
    implements org.springframework.core.convert.converter.Converter<java.lang.String,​java.util.Locale>
    Converts String presentation of a locale to a Locale. This implementation ignores any parts of the Locale besides language and country because that is the level of locale support inside the ECP. Variant and extension parts won't make any difference in the application.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Locale convert​(java.lang.String tag)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • StringToLocaleConverter

        public StringToLocaleConverter()
    • Method Detail

      • convert

        public java.util.Locale convert​(java.lang.String tag)
        Specified by:
        convert in interface org.springframework.core.convert.converter.Converter<java.lang.String,​java.util.Locale>