Class EncryptingFileIO

  • All Implemented Interfaces:
    java.io.Closeable, java.io.Serializable, java.lang.AutoCloseable, FileIO

    public class EncryptingFileIO
    extends java.lang.Object
    implements FileIO, java.io.Serializable
    See Also:
    Serialized Form
    • Method Detail

      • bulkDecrypt

        public java.util.Map<java.lang.String,​InputFile> bulkDecrypt​(java.lang.Iterable<? extends ContentFile<?>> files)
      • newInputFile

        public InputFile newInputFile​(java.lang.String path)
        Description copied from interface: FileIO
        Get a InputFile instance to read bytes from the file at the given path.
        Specified by:
        newInputFile in interface FileIO
      • newInputFile

        public InputFile newInputFile​(java.lang.String path,
                                      long length)
        Description copied from interface: FileIO
        Get a InputFile instance to read bytes from the file at the given path, with a known file length.
        Specified by:
        newInputFile in interface FileIO
      • newDecryptingInputFile

        public InputFile newDecryptingInputFile​(java.lang.String path,
                                                java.nio.ByteBuffer buffer)
      • newDecryptingInputFile

        public InputFile newDecryptingInputFile​(java.lang.String path,
                                                long length,
                                                java.nio.ByteBuffer buffer)
      • newOutputFile

        public OutputFile newOutputFile​(java.lang.String path)
        Description copied from interface: FileIO
        Get a OutputFile instance to write bytes to the file at the given path.
        Specified by:
        newOutputFile in interface FileIO
      • newEncryptingOutputFile

        public EncryptedOutputFile newEncryptingOutputFile​(java.lang.String path)
      • deleteFile

        public void deleteFile​(java.lang.String path)
        Description copied from interface: FileIO
        Delete the file at the given path.
        Specified by:
        deleteFile in interface FileIO
      • close

        public void close()
        Description copied from interface: FileIO
        Close File IO to release underlying resources.

        Calling this method is only required when this FileIO instance is no longer expected to be used, and the resources it holds need to be explicitly released to avoid resource leaks.

        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface java.io.Closeable
        Specified by:
        close in interface FileIO