Interface StringLike

  • All Superinterfaces:
    CharSequence

    public interface StringLike
    extends CharSequence
    Defines an objects which acts similar to Java String.
    • Method Summary

      All Methods Instance Methods Default Methods 
      Modifier and Type Method Description
      default char charAt​(int i)  
      default boolean contains​(CharSequence string)
      Returns true if and only if this string contains the specified sequence of char values.
      default boolean contentEquals​(CharSequence content)
      Determines if the content of this HString equals the given char sequence.
      default boolean contentEqualsIgnoreCase​(CharSequence content)
      Determines if the content of this HString equals the given char sequence ignoring case.
      default boolean endsWith​(CharSequence suffix)
      Determines if this HString ends with the given suffix.
      default Language getLanguage()
      Gets the language of the HString.
      default int indexOf​(@NonNull CharSequence text)
      Returns the index within this string of the first occurrence of the specified substring.
      default int indexOf​(@NonNull CharSequence text, int start)
      Returns the index within this string of the first occurrence of the specified substring.
      default int length()  
      default Matcher matcher​(@NonNull String pattern)
      Returns a regular expression matcher for the given pattern over this HString
      default Matcher matcher​(@NonNull Pattern pattern)
      Returns a regular expression matcher for the given pattern over this HString
      default boolean matches​(@NonNull String regex)
      Tells whether or not this string matches the given regular expression.
      default String replace​(@NonNull CharSequence oldString, @NonNull CharSequence newString)
      Replaces all substrings of this string that matches the given string with the given replacement.
      default String replaceAll​(@NonNull String regex, @NonNull String replacement)
      Replaces all substrings of this string that matches the given regular expression with the given replacement.
      default String replaceFirst​(@NonNull String regex, @NonNull String replacement)
      Replaces the first substring of this string that matches the given regular expression with the given replacement.
      default boolean startsWith​(@NonNull CharSequence prefix)
      Tests if this HString starts with the specified prefix.
      default CharSequence subSequence​(int startInclusive, int endExclusive)  
      default char[] toCharArray()
      Converts this string to a new character array.
      default String toLowerCase()
      To lower case.
      default String toUpperCase()
      Converts the HString to upper case