public static String right(String str, int len) {
        if (str == null) {
            return null;
        }
        if (len < 0) {
            return EMPTY;
        }
        if (str.length() <= len) {
            return str;
        }
        return str.substring(str.length() - len);
    }
<p>Gets the rightmost {@code len} characters of a String.</p>

<p>If {@code len} characters are not available, or the String
is {@code null}, the String will be returned without an
an exception. An empty String is returned if len is negative.</p>

<pre>
StringUtils.right(null, *)    = null
StringUtils.right(*, -ve)     = ""
StringUtils.right("", *)      = ""
StringUtils.right("abc", 0)   = ""
StringUtils.right("abc", 2)   = "bc"
StringUtils.right("abc", 4)   = "abc"
</pre>

@param str  the String to get the rightmost characters from, may be null
@param len  the length of the required String
@return the rightmost characters, {@code null} if null String input
android/android_framework/base/src/main/java/lang3/StringUtils.java