Uploaded image for project: 'Commons Lang'
  1. Commons Lang
  2. LANG-608

Some StringUtils methods should take an int character instead of char to use String API features.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.5
    • 3.0
    • lang.*
    • None

    Description

      Change the APIs from char to int character input to match underlying JRE API called. There is no need to narrow the input type argument to the JRE, in fact this causes us to loose support for Unicode supplementary characters. The APIs changed are:

      • indexOf(String, char) -> indexOf(String, int)
      • indexOf(String, char, int) -> indexOf(String, int, int)
      • lastIndexOf(String, char) -> lastIndexOf(String, int)
      • lastIndexOf(String, char, int) -> lastIndexOf(String, int, int)
      • contains(String, char) -> contains(String, int)

      The matches methods like String#indexOf(int)

      Attachments

        Activity

          People

            ggregory Gary D. Gregory
            ggregory Gary D. Gregory
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: