Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8192939 Remove Finalize methods from FileInputStream and FileOutputStream
  3. JDK-8213888

Release Note: Removal of finalize Methods from FileInputStream and FileOutputStream

    XMLWordPrintable

Details

    • Verified

    Description

      The `finalize` methods of `FileInputStream` and `FileOutputStream` were deprecated for removal in JDK 9. They have been removed in this release.
      The` java.lang.ref.Cleaner` has been implemented since JDK 9 as the primary mechanism to close file descriptors that are no longer reachable from `FileInputStream` and `FileOutputStream`. The recommended approach to close files is to explicitly call `close` or to use `try-with-resources`.

      Attachments

        Activity

          People

            rriggs Roger Riggs
            rriggs Roger Riggs
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: