15 Path(
const std::filesystem::path& path);
16 Path(std::filesystem::path&& path)
noexcept;
18 [[nodiscard]]
const std::filesystem::path&
fsPath()
const {
return filePath; }
22 [[nodiscard]] std::size_t
hash() const noexcept;
24 operator const
std::filesystem::path&()
const {
return filePath; }
51 MeshPath(
const std::filesystem::path& path,
const std::string& assetName);
97 [[nodiscard]] std::size_t
hash() const noexcept;
Classes which are related to asset loading are mostly stored in this namespace.
Identifies a named mesh-like asset inside an asset file.
std::size_t hash() const noexcept
Calculates a hash for use in unordered containers.
bool operator==(const MeshPath &other) const
Compares two asset paths by file path and asset name.
MeshPath()=default
Creates an empty asset path.
MeshPath & operator=(MeshPath &&) noexcept=default
Move-assigns an asset path.
MeshPath(const std::filesystem::path &path, const std::string &assetName)
Creates an asset path for a named asset in a file.
std::filesystem::path filePath_
MeshPath & operator=(const MeshPath &)=default
Copy-assigns an asset path.
const std::filesystem::path & getFilePath() const
Gets the source file path.
MeshPath(MeshPath &&other) noexcept
Move-constructs an asset path.
std::string getAssetHandle() const
Gets a combined string key for file path and asset name.
MeshPath(const MeshPath &other) noexcept
Copy-constructs an asset path.
void reset()
Clears the file path and asset name.
const std::string & getAssetName() const
Gets the asset name inside the source file.
bool empty() const
Checks whether this path doesn't point to anything. So it is empty.
Identifies a single asset file on disk.
bool operator==(const Path &other) const
std::string string() const
std::filesystem::path filePath
std::size_t hash() const noexcept
const std::filesystem::path & getFilePath() const
const std::filesystem::path & fsPath() const
Path(const std::filesystem::path &path)
Path(std::filesystem::path &&path) noexcept
size_t operator()(const Asset::MeshPath &path) const noexcept
size_t operator()(const Asset::Path &path) const noexcept