public static Character toCharacterObject(String str) {
        if (StringUtils.isEmpty(str)) {
            return null;
        }
        return Character.valueOf(str.charAt(0));
    }
<p>Converts the String to a Character using the first character, returning
null for empty Strings.</p>

<p>For ASCII 7 bit characters, this uses a cache that will return the
same Character object each time.</p>

<pre>
  CharUtils.toCharacterObject(null) = null
  CharUtils.toCharacterObject("")   = null
  CharUtils.toCharacterObject("A")  = 'A'
  CharUtils.toCharacterObject("BA") = 'B'
</pre>

@param str  the character to convert
@return the Character value of the first letter of the String
android/android_framework/base/src/main/java/lang3/CharUtils.java