R-Type  2
Doom but in better
Loading...
Searching...
No Matches
NotFound.cpp
Go to the documentation of this file.
1/*
2** EPITECH PROJECT, 2024
3** rtype (Workspace)
4** File description:
5** NotFound.cpp
6*/
7
15
16namespace CustomExceptions
17{
18 FileNotFound::FileNotFound(const std::string &error)
19 {
20 _msg = "Error: The file provided was not found or readable.\n";
21 _msg += "The file path you provided is: ";
22 _msg += error;
23 _buffer = _msg.c_str();
24 };
25
27
28 const char *FileNotFound::what() const noexcept
29 {
30 return _buffer;
31 }
32
33}
File in charge of informing the user that the content they tried to access was not found.
const char * what() const noexcept
Retrieves the error message.
Definition NotFound.cpp:28
FileNotFound(const std::string &error="")
Construct a new File Not Found object.
Definition NotFound.cpp:18
~FileNotFound()
Destroy the File Not Found object.
Definition NotFound.cpp:26