49#include <lal/io/treebank_file_report.hpp>
50#include <lal/io/treebank_file_error.hpp>
51#include <lal/io/treebank_collection_report_location.hpp>
71 typedef std::vector<treebank_collection_report_location>
error_list;
104 const uint64_t line_number,
105 const std::
string& treebank_file_name,
106 const std::
string& treebank_id,
120 const uint64_t line_number,
121 std::string&& treebank_file_name,
122 std::string&& treebank_id,
129 std::move(treebank_file_name),
130 std::move(treebank_id),
152 c += rep.report.get_num_errors();
Report on a treebank collection.
Definition treebank_collection_report.hpp:67
std::vector< treebank_collection_report_location > error_list
The list of reports of errors of the treebanks within the collection.
Definition treebank_collection_report.hpp:71
treebank_collection_report(treebank_file_error &&err) noexcept
Constructor with a single head vector error.
Definition treebank_collection_report.hpp:86
void set_treebank_error(const treebank_file_error &err) noexcept
Sets the error concerning the main file of the collection.
Definition treebank_collection_report.hpp:136
const error_list & get_treebank_reports() const noexcept
Returns the list of error reports for every treebank file.
Definition treebank_collection_report.hpp:162
void add_report(const uint64_t line_number, const std::string &treebank_file_name, const std::string &treebank_id, const treebank_file_report &err) noexcept
Adds a report on a treebank file.
Definition treebank_collection_report.hpp:103
~treebank_collection_report() noexcept=default
Default destructor.
error_list m_reports
The error in the head vector and the line number where it happened.
Definition treebank_collection_report.hpp:175
const treebank_file_error & get_treebank_error() const noexcept
Returns the only treebank error concerning the file (if any).
Definition treebank_collection_report.hpp:170
std::size_t get_num_errors() const noexcept
Returns the number of errors in this report.
Definition treebank_collection_report.hpp:147
treebank_collection_report() noexcept=default
Default constructor.
void add_report(const uint64_t line_number, std::string &&treebank_file_name, std::string &&treebank_id, treebank_file_report &&err) noexcept
Adds a report on a treebank file.
Definition treebank_collection_report.hpp:119
void set_treebank_error(treebank_file_error &&err) noexcept
Sets the error concerning the main file of the collection.
Definition treebank_collection_report.hpp:140
treebank_file_error m_treebank_error
A treebank error.
Definition treebank_collection_report.hpp:178
Treebank file error report class.
Definition treebank_file_error.hpp:64
treebank_file_error_type get_error_type() const noexcept
Returns the error type.
Definition treebank_file_error.hpp:127
Report on a treebank file.
Definition treebank_file_report.hpp:69
@ no_error
No error occurred.
Main namespace of the library.
Definition basic_types.hpp:48