Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8215281

Use String.isEmpty() when applicable in java.base

    Details

    • Subcomponent:
    • Resolved In Build:
      b24

      Backports

        Description

        Patterns like string.length() == 0, string.length() != 0, string.length() > 0 and "".equals(string) are common, especially in older code. Replace with isEmpty when applicable (always for string.length() ==/!=/> 0, when string can't be null for "".equals(string)

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  redestad Claes Redestad
                  Reporter:
                  redestad Claes Redestad
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  2 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: