Nix
2.36.0
Nix, the purely functional package manager; unstable internal interfaces
Toggle main menu visibility
Loading...
Searching...
No Matches
downstream-placeholder.hh
Go to the documentation of this file.
1
#pragma once
3
4
#include "
nix/util/hash.hh
"
5
#include "
nix/util/json-impls.hh
"
6
#include "
nix/store/path.hh
"
7
#include "
nix/store/derived-path.hh
"
8
9
namespace
nix {
10
19
template
<
typename
Input>
20
using
DrvRef
= std::variant<OutputName, Input>;
21
42
class
DownstreamPlaceholder
43
{
48
Hash
hash;
49
53
DownstreamPlaceholder(
Hash
hash)
54
: hash(hash)
55
{
56
}
57
58
public
:
63
std::string
render
()
const
;
64
74
static
DownstreamPlaceholder
unknownCaOutput
(
75
const
StorePath
& drvPath,
76
OutputNameView
outputName,
77
const
ExperimentalFeatureSettings
& xpSettings = experimentalFeatureSettings);
78
88
static
DownstreamPlaceholder
unknownDerivation
(
89
const
DownstreamPlaceholder & drvPlaceholder,
90
OutputNameView
outputName,
91
const
ExperimentalFeatureSettings
& xpSettings = experimentalFeatureSettings);
92
101
static
DownstreamPlaceholder
fromSingleDerivedPathBuilt
(
102
const
SingleDerivedPath::Built & built,
103
const
ExperimentalFeatureSettings
& xpSettings = experimentalFeatureSettings);
104
};
105
106
}
// namespace nix
107
108
namespace
nlohmann {
109
110
template
<
typename
Item>
111
struct
adl_serializer<nix::DrvRef<Item>>
112
{
113
static
nix::DrvRef<Item>
from_json(
const
json & json);
114
static
void
to_json(json & json,
const
nix::DrvRef<Item>
& t);
115
};
116
117
extern
template
struct
adl_serializer<nix::DrvRef<nix::StorePath>>;
118
extern
template
struct
adl_serializer<nix::DrvRef<nix::SingleDerivedPath>>;
119
120
}
// namespace nlohmann
nix::DownstreamPlaceholder::unknownCaOutput
static DownstreamPlaceholder unknownCaOutput(const StorePath &drvPath, OutputNameView outputName, const ExperimentalFeatureSettings &xpSettings=experimentalFeatureSettings)
Definition
downstream-placeholder.cc:12
nix::DownstreamPlaceholder::render
std::string render() const
Definition
downstream-placeholder.cc:7
nix::DownstreamPlaceholder::unknownDerivation
static DownstreamPlaceholder unknownDerivation(const DownstreamPlaceholder &drvPlaceholder, OutputNameView outputName, const ExperimentalFeatureSettings &xpSettings=experimentalFeatureSettings)
Definition
downstream-placeholder.cc:23
nix::DownstreamPlaceholder::fromSingleDerivedPathBuilt
static DownstreamPlaceholder fromSingleDerivedPathBuilt(const SingleDerivedPath::Built &built, const ExperimentalFeatureSettings &xpSettings=experimentalFeatureSettings)
Definition
downstream-placeholder.cc:36
nix::StorePath
Definition
path.hh:33
nix::DrvRef
std::variant< OutputName, Input > DrvRef
Definition
downstream-placeholder.hh:20
json-impls.hh
derived-path.hh
nix::OutputNameView
std::string_view OutputNameView
Definition
outputs-spec.hh:24
path.hh
hash.hh
nix::ExperimentalFeatureSettings
Definition
configuration.hh:558
nix::Hash
Definition
hash.hh:58
libstore
include
nix
store
downstream-placeholder.hh
Generated by
1.18.0