diff options
| author | Carl Hetherington <cth@carlh.net> | 2026-04-01 00:27:34 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2026-04-01 23:43:00 +0200 |
| commit | a0814a2e44e56d0378c6a47ca9c741de5cfe6356 (patch) | |
| tree | 4deb871f14830d22d3ed5afe9ea69241a37db16b | |
| parent | a82a17578812a41232d69ea10d88b19004418583 (diff) | |
Remove VerificationNote::note.tidy-verify
| -rw-r--r-- | src/cpl.cc | 8 | ||||
| -rw-r--r-- | src/verify.cc | 8 | ||||
| -rw-r--r-- | src/verify.h | 26 | ||||
| -rw-r--r-- | test/verify_test.cc | 11 |
4 files changed, 3 insertions, 50 deletions
@@ -155,12 +155,8 @@ CPL::CPL(boost::filesystem::path file, vector<dcp::VerificationNote>* notes) /* ContentVersion is required in SMPTE */ if (notes) { notes->push_back( - dcp::VerificationNote( - dcp::VerificationNote::Code::MISSING_CPL_CONTENT_VERSION, - _id, - file - ) - ); + dcp::VerificationNote(dcp::VerificationNote::Code::MISSING_CPL_CONTENT_VERSION, file).set_cpl_id(_id) + ); } } auto rating_list = f.node_child("RatingList"); diff --git a/src/verify.cc b/src/verify.cc index 40087346..ac12800b 100644 --- a/src/verify.cc +++ b/src/verify.cc @@ -2361,7 +2361,6 @@ dcp::operator== (dcp::VerificationNote const& a, dcp::VerificationNote const& b) { return a.type() == b.type() && a.code() == b.code() && - a.note() == b.note() && a.file() == b.file() && a.line() == b.line() && a.frame() == b.frame() && @@ -2469,10 +2468,6 @@ dcp::operator< (dcp::VerificationNote const& a, dcp::VerificationNote const& b) return a.code() < b.code(); } - if (a.note() != b.note()) { - return less_than_optional(a.note(), b.note()); - } - if (a.file() != b.file()) { return less_than_optional(a.file(), b.file()); } @@ -2621,9 +2616,6 @@ std::ostream& dcp::operator<< (std::ostream& s, dcp::VerificationNote const& note) { s << note_to_string (note); - if (note.note()) { - s << " [" << note.note().get() << "]"; - } if (note.file()) { s << " [" << note.file().get() << "]"; } diff --git a/src/verify.h b/src/verify.h index 44bb94a6..cb9801ef 100644 --- a/src/verify.h +++ b/src/verify.h @@ -603,25 +603,12 @@ public: : _code(code) {} - VerificationNote(Code code, std::string note) - : _code(code) - { - _data[Data::NOTE] = note; - } - VerificationNote(Code code, boost::filesystem::path file) : _code(code) { _data[Data::FILE] = file; } - VerificationNote(Code code, std::string note, boost::filesystem::path file) - : _code(code) - { - _data[Data::NOTE] = note; - _data[Data::FILE] = file; - } - VerificationNote(Code code, boost::filesystem::path file, uint64_t line) : _code (code) { @@ -629,14 +616,6 @@ public: _data[Data::LINE] = line; } - VerificationNote(Code code, std::string note, boost::filesystem::path file, uint64_t line) - : _code (code) - { - _data[Data::NOTE] = note; - _data[Data::FILE] = file; - _data[Data::LINE] = line; - } - Type type() const; Code code () const { @@ -668,7 +647,6 @@ private: LINE, ///< error line number within the FILE LOAD_FONT_ID, MAIN_PICTURE_ACTIVE_AREA, - NOTE, ///< further information about the error OTHER_ASSET_ID, OTHER_DURATION, PKL_ID, @@ -695,10 +673,6 @@ private: } public: - boost::optional<std::string> note () const { - return data<std::string>(Data::NOTE); - } - boost::optional<boost::filesystem::path> file () const { return data<boost::filesystem::path>(Data::FILE); } diff --git a/test/verify_test.cc b/test/verify_test.cc index 7f32c438..e3cff85a 100644 --- a/test/verify_test.cc +++ b/test/verify_test.cc @@ -242,10 +242,9 @@ string to_string(dcp::VerificationNote const& note) { string s = note_to_string(note) + dcp::String::compose( - "\n [%1 %2 %3 %4 %5 %6 %7 ", + "\n [%1 %2 %3 %4 %5 %6 ", static_cast<int>(note.type()), static_cast<int>(note.code()), - note.note().get_value_or("<none>"), note.file().get_value_or("<none>"), note.line().get_value_or(0), note.frame().get_value_or(0), @@ -420,14 +419,6 @@ note(dcp::VerificationNote::Code code, shared_ptr<const dcp::CPL> cpl) static dcp::VerificationNote -note(dcp::VerificationNote::Code code, string note, shared_ptr<const dcp::CPL> cpl) -{ - return dcp::VerificationNote(code, note).set_cpl_id(cpl->id()); -} - - -static -dcp::VerificationNote note(dcp::VerificationNote::Code code, boost::filesystem::path path, shared_ptr<const dcp::CPL> cpl) { return dcp::VerificationNote(code, path).set_cpl_id(cpl->id()); |
