exceptions.cpp
Go to the documentation of this file.
1#include "exceptions.h"
2
3#include <sstream>
4
6{
7
8 BinaryIOError::BinaryIOError(const std::string& operation,
9 const std::string& path,
10 const std::string& reason,
11 const std::ios_base::failure& causing) :
12 VoxelGridIOError("Failed to " + operation + " voxel grid from/to '" + path +
13 "'.\n"
14 "Reason: " +
15 reason +
16 "\n"
17 "Caused by : " +
18 std::string(causing.what()))
19 {
20 }
21
22 BinaryReadError::BinaryReadError(const std::string& message,
23 const std::ios_base::failure& causing) :
24 VoxelGridIOError(message + "\nCaused by: " + std::string(causing.what()))
25 {
26 }
27
28
29} // namespace visionx::voxelgrid::error::io
BinaryIOError(const std::string &operation, const std::string &path, const std::string &reason, const std::ios_base::failure &causing)
Definition exceptions.cpp:8
BinaryReadError(const std::string &message, const std::ios_base::failure &causing)
Base class for exceptions in this library.
Definition exceptions.h:14