diff options
Diffstat (limited to 'src/libstore/store-api.hh')
-rw-r--r-- | src/libstore/store-api.hh | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/libstore/store-api.hh b/src/libstore/store-api.hh index 84ede157e87a..347387f03403 100644 --- a/src/libstore/store-api.hh +++ b/src/libstore/store-api.hh @@ -140,9 +140,10 @@ struct BuildResult struct BasicDerivation; struct Derivation; +struct FSAccessor; -class Store +class Store : public std::enable_shared_from_this<Store> { public: @@ -314,6 +315,9 @@ public: remain. */ virtual bool verifyStore(bool checkContents, bool repair) = 0; + /* Return an object to access files in the Nix store. */ + virtual ref<FSAccessor> getFSAccessor() = 0; + /* Utility functions. */ /* Read a derivation, after ensuring its existence through @@ -345,6 +349,12 @@ public: }; +class LocalFSStore : public Store +{ + ref<FSAccessor> getFSAccessor() override; +}; + + /* !!! These should be part of the store API, I guess. */ /* Throw an exception if `path' is not directly in the Nix store. */ |