mirror of
https://github.com/johndoe6345789/metabuilder.git
synced 2026-04-25 22:34:56 +00:00
Created complete C++ implementation: - Core library (client, errors, capabilities) - Query engine (AST, builder, normalizer) - Utilities (UUID generation, exponential backoff) - SQLite adapter and connection pool - Daemon server with security manager - Unit, integration, and conformance tests Build system: - CMakeLists.txt with optional Conan dependencies - Renamed build assistant to .cjs for ES module compatibility - Fixed conanfile.txt format for Conan 2.x - All tests passing, daemon runs successfully Co-authored-by: johndoe6345789 <224850594+johndoe6345789@users.noreply.github.com>
38 lines
935 B
C++
38 lines
935 B
C++
#include "dbal/errors.hpp"
|
|
|
|
namespace dbal {
|
|
|
|
Error Error::notFound(const std::string& message) {
|
|
return Error(ErrorCode::NotFound, message);
|
|
}
|
|
|
|
Error Error::conflict(const std::string& message) {
|
|
return Error(ErrorCode::Conflict, message);
|
|
}
|
|
|
|
Error Error::unauthorized(const std::string& message) {
|
|
return Error(ErrorCode::Unauthorized, message);
|
|
}
|
|
|
|
Error Error::forbidden(const std::string& message) {
|
|
return Error(ErrorCode::Forbidden, message);
|
|
}
|
|
|
|
Error Error::validationError(const std::string& message) {
|
|
return Error(ErrorCode::ValidationError, message);
|
|
}
|
|
|
|
Error Error::internal(const std::string& message) {
|
|
return Error(ErrorCode::InternalError, message);
|
|
}
|
|
|
|
Error Error::sandboxViolation(const std::string& message) {
|
|
return Error(ErrorCode::SandboxViolation, message);
|
|
}
|
|
|
|
Error Error::maliciousCode(const std::string& message) {
|
|
return Error(ErrorCode::MaliciousCodeDetected, message);
|
|
}
|
|
|
|
}
|