Engine²
Open-source game engine written in C++.
Loading...
Searching...
No Matches
OBJLoaderError.hpp
Go to the documentation of this file.
1/**************************************************************************
2 * EngineSquared v0.1.1
3 *
4 * EngineSquared is a software package, part of the Engine² organization.
5 *
6 * This file is part of the EngineSquared project that is under MIT License.
7 * Copyright © 2025-present by @EngineSquared, All rights reserved.
8 *
9 * EngineSquared is a free software: you can redistribute it and/or modify
10 * it under the terms of the MIT License. See the project's LICENSE file for
11 * the full license text and details.
12 *
13 * @file OBJLoaderError.hpp
14 * @brief OBJLoaderError class declaration.
15 *
16 * This class is used to represent errors that occur while loading OBJ files.
17 *
18 * @author @EngineSquared
19 * @version 0.1.1
20 * @date 2025-10-03
21 **************************************************************************/
22
23#pragma once
24
25#include <cstring>
26#include <stdexcept>
27#include <string>
28
29namespace Object {
30
48class OBJLoaderError : public std::exception {
49 public:
50 explicit OBJLoaderError(const std::string &message) : _msg("OBJLoader error: " + message) {};
51
52 const char *what() const throw() override { return this->_msg.c_str(); };
53
54 private:
55 std::string _msg;
56};
57
58} // namespace Object
const char * what() const override
Definition OBJLoaderError.hpp:52
std::string _msg
Definition OBJLoaderError.hpp:55
OBJLoaderError(const std::string &message)
Definition OBJLoaderError.hpp:50
Definition AmbientLight.hpp:5