nix-super/src/libutil/fs-sink.hh

26 lines
548 B
C++
Raw Normal View History

#pragma once
///@file
#include "types.hh"
#include "serialise.hh"
namespace nix {
/**
* \todo Fix this API, it sucks.
*/
struct ParseSink
{
virtual void createDirectory(const Path & path) { };
virtual void createRegularFile(const Path & path) { };
virtual void closeRegularFile() { };
virtual void isExecutable() { };
virtual void preallocateContents(uint64_t size) { };
virtual void receiveContents(std::string_view data) { };
virtual void createSymlink(const Path & path, const std::string & target) { };
};
}