DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
dunedaq::oks::FailedAddComment Class Reference

Cannot add comment. Such exception is thrown when OKS cannot add new comment. More...

#include <file.hpp>

Inheritance diagram for dunedaq::oks::FailedAddComment:
[legend]
Collaboration diagram for dunedaq::oks::FailedAddComment:
[legend]

Public Member Functions

 FailedAddComment (const OksFile &file, const exception &reason) noexcept
 
 FailedAddComment (const OksFile &file, const std::string &reason) noexcept
 
virtual ~FailedAddComment () noexcept
 
- Public Member Functions inherited from dunedaq::oks::exception
 exception (const std::string &what_arg, int level_arg) noexcept
 
virtual ~exception () noexcept
 
int level () const noexcept
 
virtual const char * what () const noexcept
 

Static Private Member Functions

static std::string fill (const OksFile &file, const std::string &reason) noexcept
 

Detailed Description

Cannot add comment. Such exception is thrown when OKS cannot add new comment.

Definition at line 195 of file file.hpp.

Constructor & Destructor Documentation

◆ FailedAddComment() [1/2]

dunedaq::oks::FailedAddComment::FailedAddComment ( const OksFile & file,
const exception & reason )
inlinenoexcept

The constructor gets reason from nested oks exception.

Definition at line 200 of file file.hpp.

200: exception (fill(file, reason.what()), reason.level() + 1) { }
static std::string fill(const OksFile &file, const std::string &reason) noexcept
Definition file.cpp:216
caught dunedaq::conffwk::Exception exception
std::string const reason(ers::Issue const &)

◆ FailedAddComment() [2/2]

dunedaq::oks::FailedAddComment::FailedAddComment ( const OksFile & file,
const std::string & reason )
inlinenoexcept

The constructor gets reason from non-oks exception.

Definition at line 203 of file file.hpp.

203: exception (fill(file, reason), 0) { }

◆ ~FailedAddComment()

virtual dunedaq::oks::FailedAddComment::~FailedAddComment ( )
inlinevirtualnoexcept

Definition at line 205 of file file.hpp.

205{ }

Member Function Documentation

◆ fill()

std::string dunedaq::oks::FailedAddComment::fill ( const OksFile & file,
const std::string & reason )
staticprivatenoexcept

Definition at line 216 of file file.cpp.

217 {
218 return ( std::string("Failed to add new comment to file \'") + file.get_full_file_name() + "\' because:\n" + reason);
219 }

The documentation for this class was generated from the following files: