Class TempDirectory.CloseablePath

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.nio.file.Path dir  
    • Constructor Summary

      Constructors 
      Constructor Description
      CloseablePath​(java.nio.file.Path dir)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void close()
      Close underlying resources.
      private java.io.IOException createIOExceptionWithAttachedFailures​(java.util.SortedMap<java.nio.file.Path,​java.io.IOException> failures)  
      private java.util.SortedMap<java.nio.file.Path,​java.io.IOException> deleteAllFilesAndDirectories()  
      (package private) java.nio.file.Path get()  
      private java.nio.file.Path relativizeSafely​(java.nio.file.Path path)  
      private void tryToDeleteOnExit​(java.nio.file.Path path)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • dir

        private final java.nio.file.Path dir
    • Constructor Detail

      • CloseablePath

        CloseablePath​(java.nio.file.Path dir)
    • Method Detail

      • get

        java.nio.file.Path get()
      • deleteAllFilesAndDirectories

        private java.util.SortedMap<java.nio.file.Path,​java.io.IOException> deleteAllFilesAndDirectories()
                                                                                                        throws java.io.IOException
        Throws:
        java.io.IOException
      • createIOExceptionWithAttachedFailures

        private java.io.IOException createIOExceptionWithAttachedFailures​(java.util.SortedMap<java.nio.file.Path,​java.io.IOException> failures)
      • tryToDeleteOnExit

        private void tryToDeleteOnExit​(java.nio.file.Path path)
      • relativizeSafely

        private java.nio.file.Path relativizeSafely​(java.nio.file.Path path)