19 #include "lfilesystem/lfilesystem_Export.h"
83 [[nodiscard]]
bool references (const
FilesystemEntry& entry, std::
size_t recursionDepth = 50) const noexcept;
88 [[nodiscard]]
bool referencesSameLocationAs (const
SymLink& other) const;
91 [[nodiscard]]
bool isDangling() const noexcept;
93 [[nodiscard]]
bool isSymLink() const noexcept final;
94 [[nodiscard]]
bool isFile() const noexcept final;
95 [[nodiscard]]
bool isDirectory() const noexcept final;
106 static std::optional<
SymLink> create (const
Path& linkPath, const
Path& target) noexcept;
133 [[nodiscard]]
FilesystemEntry follow_recurse (std::
size_t counter, std::
size_t limit) const;
134 [[nodiscard]]
bool references_recurse (const
FilesystemEntry& entry, std::
size_t counter, std::
size_t limit) const;
148 struct LFILE_EXPORT hash<limes::files::SymLink> final
This class represents a directory on the filesystem.
The base class for any kind of object on the filesystem.
FilesystemEntry()=default
Creates a FilesystemEntry with an empty path.
This class represents a symbolic link on the filesystem.
FilesystemEntry follow(std::size_t recursionDepth=50) const noexcept
Follows the symbolic link to find its target.
SymLink(const Path &symLinkPath, const FilesystemEntry &linkTarget)
Creates a symbolic link object (the link itself will also be created on the filesystem).
std::filesystem::path Path
Convenience typedef for filesystem paths.
This file defines the FilesystemEntry class.