Interface Storage

    • Method Detail

      • listDirectory

        List<Listing> listDirectory​(String directoryPath,
                                    boolean recursive)
        Return a list of all of the files an directories contained in the specified directory. An empty list is returned if the directory does not exist or has no children. If recursion is specified, then only leaf nodes are returned.
        Parameters:
        directoryPath - the path to the directory to list
        recursive - if children should be recursively listed
        Returns:
        list of children
      • fileExists

        boolean fileExists​(String filePath)
        Indicates if the file exists
        Parameters:
        filePath - path to the file
        Returns:
        true if it exists
      • readFile

        InputStream readFile​(String filePath)
        Streams the content of the specified file
        Parameters:
        filePath - path to the file
        Returns:
        input stream of file content
        Throws:
        NotFoundException - when the file does not exist