Class AbstractInternationalString

    • Constructor Detail

      • AbstractInternationalString

        public AbstractInternationalString()
        Constructs an international string.
    • Method Detail

      • subSequence

        public CharSequence subSequence​(int start,
                                        int end)
        Returns a subsequence of the string in the default locale. The subsequence is a String object starting with the character value at the specified index and ending with the character value at index end - 1.
        Specified by:
        subSequence in interface CharSequence
        start - The start index, inclusive.
        end - The end index, exclusive.
        The specified subsequence.
        IndexOutOfBoundsException - if start or end is out of range.
      • toString

        public abstract String toString​(Locale locale)
        Returns this string in the given locale. If no string is available in the given locale, then some default locale is used. The default locale is implementation-dependent. It may or may not be the system default).
        Specified by:
        toString in interface InternationalString
        locale - The desired locale for the string to be returned, or null for a string in the implementation default locale.
        The string in the given locale if available, or in the default locale otherwise.
      • compareTo

        public int compareTo​(InternationalString object)
        Compares this string with the specified object for order. This method compare the string in the default locale, as returned by toString().
        Specified by:
        compareTo in interface Comparable<InternationalString>
        object - The string to compare with this string.
        A negative number if this string is before the given string, a positive number if after, or 0 if equals.