13 #ifndef PLSSVM_EXCEPTIONS_EXCEPTIONS_HPP_
14 #define PLSSVM_EXCEPTIONS_EXCEPTIONS_HPP_
21 #include <string_view>
Exception type thrown if a data_set is used inappropriately.
Definition: exceptions.hpp:88
data_set_exception(const std::string &msg, source_location loc=source_location::current())
Construct a new exception forwarding the exception message and source location to plssvm::exception.
Base class for all custom exception types. Forwards its message to std::runtime_error and saves the e...
Definition: exceptions.hpp:29
source_location loc_
The call side source location information.
Definition: exceptions.hpp:56
exception(const std::string &msg, std::string_view class_name="exception", source_location loc=source_location::current())
Construct a new exception forwarding the exception message to std::runtime_error.
std::string_view class_name_
The name of the thrown exception class.
Definition: exceptions.hpp:54
const source_location & loc() const noexcept
Returns the information of the call side where the exception was thrown.
std::string what_with_loc() const
Returns a string containing the exception's what() message, the name of the thrown exception class,...
Exception type thrown if the provided file couldn't be found.
Definition: exceptions.hpp:101
file_not_found_exception(const std::string &msg, source_location loc=source_location::current())
Construct a new exception forwarding the exception message and source location to plssvm::exception.
Exception type thrown if the file_reader is used inappropriately (e.g., if two files should be opened...
Definition: exceptions.hpp:75
file_reader_exception(const std::string &msg, source_location loc=source_location::current())
Construct a new exception forwarding the exception message and source location to plssvm::exception.
Exception type thrown if an error in the generic plssvm::detail::gpu_device_ptr occurred.
Definition: exceptions.hpp:153
gpu_device_ptr_exception(const std::string &msg, source_location loc=source_location::current())
Construct a new exception forwarding the exception message and source location to plssvm::exception.
Exception type thrown if the provided parameter is invalid.
Definition: exceptions.hpp:62
invalid_parameter_exception(const std::string &msg, source_location loc=source_location::current())
Construct a new exception forwarding the exception message and source location to plssvm::exception.
The plssvm::source_location class represents certain information about the source code,...
Definition: source_location.hpp:25
static constexpr source_location current(const char *file_name=__builtin_FILE(), const char *function_name=__builtin_FUNCTION(), int line=__builtin_LINE(), int column=0) noexcept
Construct new source location information about the current call side.
Definition: source_location.hpp:35
Exception type thrown if the requested backend is not supported on the target machine.
Definition: exceptions.hpp:127
unsupported_backend_exception(const std::string &msg, source_location loc=source_location::current())
Construct a new exception forwarding the exception message and source location to plssvm::exception.
Exception type thrown if the requested kernel type is not supported.
Definition: exceptions.hpp:140
unsupported_kernel_type_exception(const std::string &msg, source_location loc=source_location::current())
Construct a new exception forwarding the exception message and source location to plssvm::exception.
The main namespace containing all public API functions.
Definition: backend_types.hpp:24
Implements a custom std::source_location implementation for C++17.