GnuCash c935c2f+
Loading...
Searching...
No Matches
Public Member Functions
ErrorList Struct Reference

Public Member Functions

void add_error (std::string msg)
 
std::string str ()
 

Detailed Description

Definition at line 471 of file gnc-import-tx.cpp.

Member Function Documentation

◆ add_error()

void ErrorList::add_error ( std::string  msg)

Definition at line 480 of file gnc-import-tx.cpp.

481{
482 m_error.emplace_back (msg);
483}

◆ str()

std::string ErrorList::str ( )

Definition at line 485 of file gnc-import-tx.cpp.

486{
487 auto err_msg = std::string();
488 if (!m_error.empty())
489 {
490 auto add_bullet_item = [](std::string& a, std::string& b)->std::string { return std::move(a) + "\n• " + b; };
491 err_msg = std::accumulate (m_error.begin(), m_error.end(), std::move (err_msg), add_bullet_item);
492 err_msg.erase (0, 1);
493 }
494
495 return err_msg;
496}

The documentation for this struct was generated from the following file: