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

Replace uses of Class.newInstance

    XMLWordPrintable

    Details

      Description

      The Class.newInstance() method is deprecated in favor of Contructor.newinstance(). According to the API docs for the former:

          clazz.newInstance()

      can be replaced by

          clazz.getDeclaredConstructor().newInstance()
       
      There are 12 calls to newInstance in JavaFX, 9 in javafx.graphics and 3 in javafx.fxml

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              aghaisas Ajit Ghaisas
              Reporter:
              kcr Kevin Rushforth
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: