Blue Brain BioExplorer
TaskRuntimeError.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2015-2024, EPFL/Blue Brain Project
3  *
4  * Responsible Author: Daniel.Nachbaur@epfl.ch
5  *
6  * This file is part of Blue Brain BioExplorer <https://github.com/BlueBrain/BioExplorer>
7  *
8  * This library is free software; you can redistribute it and/or modify it under
9  * the terms of the GNU Lesser General Public License version 3.0 as published
10  * by the Free Software Foundation.
11  *
12  * This library is distributed in the hope that it will be useful, but WITHOUT
13  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
14  * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
15  * details.
16  *
17  * You should have received a copy of the GNU Lesser General Public License
18  * along with this library; if not, write to the Free Software Foundation, Inc.,
19  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
20  */
21 
22 #pragma once
23 
24 #include <stdexcept>
25 
26 namespace core
27 {
32 class TaskRuntimeError : public std::runtime_error
33 {
34 public:
35  TaskRuntimeError(const std::string& message, const int code_ = -1, const std::string& data_ = "")
36  : std::runtime_error(message)
37  , code(code_)
38  , data(data_)
39  {
40  }
41 
42  const int code;
43  const std::string data;
44 };
45 } // namespace core
TaskRuntimeError(const std::string &message, const int code_=-1, const std::string &data_="")
const std::string data