diff options
author | John Ericson <John.Ericson@Obsidian.Systems> | 2023-03-25 19:12:44 -0400 |
---|---|---|
committer | John Ericson <John.Ericson@Obsidian.Systems> | 2023-03-29 23:22:07 -0400 |
commit | 8cab89a94b28a51b8dcbbe4b681df3c633a41aec (patch) | |
tree | e86d269dbadffd99a9885593e9a8ea7419fce54e /src/libstore/path.hh | |
parent | 10dc2e2e7cc28276c989b72a3a98c4b5542211e4 (diff) |
Convert a bunch of comments in headers to Doxygen documentation
The internal API docs now contain more useful information.
Co-authored-by: Théophane Hufschmitt <7226587+thufschmitt@users.noreply.github.com>
Diffstat (limited to 'src/libstore/path.hh')
-rw-r--r-- | src/libstore/path.hh | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/src/libstore/path.hh b/src/libstore/path.hh index 1e5579b90..2730541c6 100644 --- a/src/libstore/path.hh +++ b/src/libstore/path.hh @@ -8,13 +8,22 @@ namespace nix { struct Hash; +/** + * \ref StorePath "Store path" is the fundamental reference type of Nix. + * A store paths refers to a Store object. + * + * See glossary.html#gloss-store-path for more information on a + * conceptual level. + */ class StorePath { std::string baseName; public: - /* Size of the hash part of store paths, in base-32 characters. */ + /** + * Size of the hash part of store paths, in base-32 characters. + */ constexpr static size_t HashLen = 32; // i.e. 160 bits constexpr static size_t MaxPathLen = 211; @@ -45,8 +54,9 @@ public: return baseName != other.baseName; } - /* Check whether a file name ends with the extension for - derivations. */ + /** + * Check whether a file name ends with the extension for derivations. + */ bool isDerivation() const; std::string_view name() const @@ -67,7 +77,10 @@ public: typedef std::set<StorePath> StorePathSet; typedef std::vector<StorePath> StorePaths; -/* Extension of derivations in the Nix store. */ +/** + * The file extension of \ref Derivation derivations when serialized + * into store objects. + */ const std::string drvExtension = ".drv"; } |