58 : arrow_fs_(std::move(arrow_fs)) {}
61 static std::unique_ptr<FileIO> MakeMockFileIO();
64 static std::unique_ptr<FileIO> MakeLocalFileIO();
69 Result<std::unique_ptr<InputFile>> NewInputFile(std::string file_location)
override;
72 Result<std::unique_ptr<InputFile>> NewInputFile(std::string file_location,
73 size_t length)
override;
76 Result<std::unique_ptr<OutputFile>> NewOutputFile(std::string file_location)
override;
79 Status DeleteFile(
const std::string& file_location)
override;
82 Status
DeleteFiles(
const std::vector<std::string>& file_locations)
override;
85 const std::shared_ptr<::arrow::fs::FileSystem>&
fs()
const {
return arrow_fs_; }
88 friend Result<std::shared_ptr<::arrow::io::RandomAccessFile>> OpenArrowInputStream(
89 const std::shared_ptr<FileIO>& io,
const std::string& path,
90 std::optional<size_t> length);
92 friend Result<std::shared_ptr<::arrow::io::OutputStream>> OpenArrowOutputStream(
93 const std::shared_ptr<FileIO>& io,
const std::string& path,
bool overwrite);
96 Result<std::string> ResolvePath(
const std::string& file_location);
98 std::shared_ptr<::arrow::fs::FileSystem> arrow_fs_;