Package org.apache.iceberg.encryption
Class AesGcmOutputFile
- java.lang.Object
-
- org.apache.iceberg.encryption.AesGcmOutputFile
-
- All Implemented Interfaces:
OutputFile
public class AesGcmOutputFile extends java.lang.Object implements OutputFile
-
-
Constructor Summary
Constructors Constructor Description AesGcmOutputFile(OutputFile targetFile, byte[] dataKey, byte[] fileAADPrefix)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PositionOutputStream
create()
Create a new file and return aPositionOutputStream
to it.PositionOutputStream
createOrOverwrite()
Create a new file and return aPositionOutputStream
to it.java.lang.String
location()
Return the location this output file will create.InputFile
toInputFile()
Return anInputFile
for the location of this output file.
-
-
-
Constructor Detail
-
AesGcmOutputFile
public AesGcmOutputFile(OutputFile targetFile, byte[] dataKey, byte[] fileAADPrefix)
-
-
Method Detail
-
create
public PositionOutputStream create()
Description copied from interface:OutputFile
Create a new file and return aPositionOutputStream
to it.If the file already exists, this will throw an exception.
- Specified by:
create
in interfaceOutputFile
- Returns:
- an output stream that can report its position
-
createOrOverwrite
public PositionOutputStream createOrOverwrite()
Description copied from interface:OutputFile
Create a new file and return aPositionOutputStream
to it.If the file already exists, this will not throw an exception and will replace the file.
- Specified by:
createOrOverwrite
in interfaceOutputFile
- Returns:
- an output stream that can report its position
-
location
public java.lang.String location()
Description copied from interface:OutputFile
Return the location this output file will create.- Specified by:
location
in interfaceOutputFile
- Returns:
- the location of this output file
-
toInputFile
public InputFile toInputFile()
Description copied from interface:OutputFile
Return anInputFile
for the location of this output file.- Specified by:
toInputFile
in interfaceOutputFile
- Returns:
- an input file for the location of this output file
-
-