MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / UnknownPackage

Class UnknownPackage

include/Core/System/Exceptions.hpp:59–75  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

57 };
58
59 class UnknownPackage : public Exception
60 {
61 public:
62 UnknownPackage(std::string_view package,
63 const std::vector<std::string>& allPackages, DebugInfo info)
64 : Exception("UnknownPackage", info)
65 {
66 this->error(
67 "Impossible to get Package '{}', please check it is correctly installed");
68 std::vector<std::string> suggestions
69 = Utils::String::sortByDistance(package.data(), allPackages, 5);
70 std::transform(suggestions.begin(), suggestions.end(), suggestions.begin(),
71 Utils::String::quote);
72 this->hint("Maybe you meant to get one of these packages : ({})",
73 fmt::join(suggestions, ", "));
74 }
75 };
76
77 class PackageFileNotFound : public Exception
78 {

Callers 2

GetPackageLocationFunction · 0.85
LoadFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected