javaeetutorial
  1. javaeetutorial
  2. JAVAEETUTORIAL-124

technically incorrect statement in context of Java

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 6.0.7-5
    • Fix Version/s: 6.0.7-5
    • Component/s: doc
    • Labels:
      None

      Description

      There is 'An empty string is represented as "". It is a character array of zero characters. A null string is represented by null. It can be described as the absence of a string instance.' as the second paragraph after "Validating Null and Empty Strings" on the page named "Using Bean Validation" at http://docs.oracle.com/javaee/6/tutorial/doc/gircz.html. The second sentence is not correct in the Java context. A character array is mutable. A String is not. So a string in Java is not a character array. It may be more technically accurate to say "It is a character sequence of zero characters." As String implements CharSequence, this is technically correct as well as conceptually correct.

        Activity

        Hide
        Kim Haase added a comment -

        Checked in fix that changes "array" to "sequence".

        Show
        Kim Haase added a comment - Checked in fix that changes "array" to "sequence".
        Hide
        Kim Haase added a comment -

        Thank you for catching this error.

        Show
        Kim Haase added a comment - Thank you for catching this error.

          People

          • Assignee:
            Kim Haase
            Reporter:
            Brant Gurganus
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: