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

JTextComponent.setText(null) throws NullPointerException.

XMLWordPrintable

    • hopper
    • x86
    • windows_nt
    • Verified



      Name: stC104175 Date: 04/17/2000


      java version "1.2.2"
      Classic VM (build JDK-1.2.2-001, native threads, symcjit)

      When calling JTextComponent.setText(null), the following exception is thrown:

      java.lang.NullPointerException:
              at java.io.StringReader.<init>(StringReader.java:38)

      Despite the exception, the text is removed from the editor (as specified in the
      setText() JavaDoc). Tested both with JTextArea and JEditorPane components.
      (Review ID: 103783)
      ======================================================================

            apikalev Andrey Pikalev
            stompkinsunw Sean Tompkins (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: