Interface IDirectory

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void delete()
      Delete the repository.
      boolean exists​(java.lang.String filePath)
      Check the existence of a file.
      java.lang.String getDescription()
      Generate a general description of the directory, used mainly to compose exception messages.
      java.io.InputStream getInputStream​(java.lang.String filePath)
      Get an InputStream to a repository file.
      java.io.OutputStream getOutputStream​(java.lang.String filePath)
      Get an OutputStream to a repository file.
      • Methods inherited from interface java.io.Closeable

        close
    • Method Detail

      • getInputStream

        java.io.InputStream getInputStream​(java.lang.String filePath)
                                    throws java.io.FileNotFoundException,
                                           java.io.IOException
        Get an InputStream to a repository file.
        Parameters:
        filePath - path to the file.
        Returns:
        InputStream to file found in specified filePath.
        Throws:
        java.io.FileNotFoundException - if no file was found in specified filePath.
        java.io.IOException - if an I/O error occurs.
      • getOutputStream

        java.io.OutputStream getOutputStream​(java.lang.String filePath)
                                      throws java.io.IOException
        Get an OutputStream to a repository file.
        Parameters:
        filePath - path to the file.
        Returns:
        OutputStream to the new file
        Throws:
        java.io.IOException - if an I/O error occurs.
      • exists

        boolean exists​(java.lang.String filePath)
                throws java.io.IOException
        Check the existence of a file.
        Parameters:
        filePath - path to the file to be checked.
        Returns:
        true, if the specified file exists.
        Throws:
        java.io.IOException - if an I/O error occurs.
      • getDescription

        java.lang.String getDescription()
        Generate a general description of the directory, used mainly to compose exception messages.
        Returns:
        directory description.
      • delete

        void delete()
             throws java.io.IOException
        Delete the repository.
        Throws:
        java.io.IOException - if an I/O error occurs.