Class ParquetFileWriter

java.lang.Object
org.apache.drill.metastore.iceberg.write.ParquetFileWriter
All Implemented Interfaces:
FileWriter

public class ParquetFileWriter extends Object implements FileWriter
Parquet File Writer implementation. Creates Parquet file in given location and name and '.parquet' extension and writes given data into it. Note: if file already exists, write operation will fail.
  • Constructor Details

    • ParquetFileWriter

      public ParquetFileWriter(org.apache.iceberg.Table table)
  • Method Details

    • records

      public FileWriter records(List<org.apache.iceberg.data.Record> records)
      Description copied from interface: FileWriter
      Indicates list of records to be written.
      Specified by:
      records in interface FileWriter
      Parameters:
      records - list of records to be written into file
      Returns:
      current File Writer instance
    • location

      public FileWriter location(String location)
      Description copied from interface: FileWriter
      Indicates location where new file will be written to.
      Specified by:
      location in interface FileWriter
      Parameters:
      location - file location
      Returns:
      current File Writer instance
    • name

      public FileWriter name(String name)
      Description copied from interface: FileWriter
      Indicates name with which new file will be created.
      Specified by:
      name in interface FileWriter
      Parameters:
      name - file name
      Returns:
      current File Writer instance
    • write

      public File write()
      Description copied from interface: FileWriter
      Writes provided list of records into the file.
      Specified by:
      write in interface FileWriter
      Returns:
      written file information holder