aboutsummaryrefslogtreecommitdiff
path: root/src/libstore/downstream-placeholder.hh
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstore/downstream-placeholder.hh')
-rw-r--r--src/libstore/downstream-placeholder.hh12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/libstore/downstream-placeholder.hh b/src/libstore/downstream-placeholder.hh
index 97f77e6b8..9372dcd58 100644
--- a/src/libstore/downstream-placeholder.hh
+++ b/src/libstore/downstream-placeholder.hh
@@ -3,6 +3,7 @@
#include "hash.hh"
#include "path.hh"
+#include "derived-path.hh"
namespace nix {
@@ -73,6 +74,17 @@ public:
const DownstreamPlaceholder & drvPlaceholder,
std::string_view outputName,
const ExperimentalFeatureSettings & xpSettings = experimentalFeatureSettings);
+
+ /**
+ * Convenience constructor that handles both cases (unknown
+ * content-addressed output and unknown derivation), delegating as
+ * needed to `unknownCaOutput` and `unknownDerivation`.
+ *
+ * Recursively builds up a placeholder from a
+ * `SingleDerivedPath::Built.drvPath` chain.
+ */
+ static DownstreamPlaceholder fromSingleDerivedPathBuilt(
+ const SingleDerivedPath::Built & built);
};
}