Mercurial > hg > orthanc
diff OrthancFramework/Sources/DicomParsing/DicomWebJsonVisitor.cpp @ 4734:b51c08bd5c38
added ITagVisitor::Action_Remove
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 05 Jul 2021 16:12:10 +0200 |
parents | 4e81412ead0a |
children | 979ae3ea3381 |
line wrap: on
line diff
--- a/OrthancFramework/Sources/DicomParsing/DicomWebJsonVisitor.cpp Mon Jun 28 14:25:37 2021 +0200 +++ b/OrthancFramework/Sources/DicomParsing/DicomWebJsonVisitor.cpp Mon Jul 05 16:12:10 2021 +0200 @@ -371,32 +371,38 @@ #endif - void DicomWebJsonVisitor::VisitNotSupported(const std::vector<DicomTag> &parentTags, - const std::vector<size_t> &parentIndexes, - const DicomTag &tag, - ValueRepresentation vr) + ITagVisitor::Action + DicomWebJsonVisitor::VisitNotSupported(const std::vector<DicomTag> &parentTags, + const std::vector<size_t> &parentIndexes, + const DicomTag &tag, + ValueRepresentation vr) { + return Action_None; } - void DicomWebJsonVisitor::VisitEmptySequence(const std::vector<DicomTag>& parentTags, - const std::vector<size_t>& parentIndexes, - const DicomTag& tag) + ITagVisitor::Action + DicomWebJsonVisitor::VisitEmptySequence(const std::vector<DicomTag>& parentTags, + const std::vector<size_t>& parentIndexes, + const DicomTag& tag) { if (tag.GetElement() != 0x0000) { Json::Value& node = CreateNode(parentTags, parentIndexes, tag); node[KEY_VR] = EnumerationToString(ValueRepresentation_Sequence); } + + return Action_None; } - void DicomWebJsonVisitor::VisitBinary(const std::vector<DicomTag>& parentTags, - const std::vector<size_t>& parentIndexes, - const DicomTag& tag, - ValueRepresentation vr, - const void* data, - size_t size) + ITagVisitor::Action + DicomWebJsonVisitor::VisitBinary(const std::vector<DicomTag>& parentTags, + const std::vector<size_t>& parentIndexes, + const DicomTag& tag, + ValueRepresentation vr, + const void* data, + size_t size) { assert(vr == ValueRepresentation_OtherByte || vr == ValueRepresentation_OtherDouble || @@ -456,14 +462,17 @@ } } } + + return Action_None; } - void DicomWebJsonVisitor::VisitIntegers(const std::vector<DicomTag>& parentTags, - const std::vector<size_t>& parentIndexes, - const DicomTag& tag, - ValueRepresentation vr, - const std::vector<int64_t>& values) + ITagVisitor::Action + DicomWebJsonVisitor::VisitIntegers(const std::vector<DicomTag>& parentTags, + const std::vector<size_t>& parentIndexes, + const DicomTag& tag, + ValueRepresentation vr, + const std::vector<int64_t>& values) { if (tag.GetElement() != 0x0000 && vr != ValueRepresentation_NotSupported) @@ -482,13 +491,16 @@ node[KEY_VALUE] = content; } } + + return Action_None; } - void DicomWebJsonVisitor::VisitDoubles(const std::vector<DicomTag>& parentTags, - const std::vector<size_t>& parentIndexes, - const DicomTag& tag, - ValueRepresentation vr, - const std::vector<double>& values) + ITagVisitor::Action + DicomWebJsonVisitor::VisitDoubles(const std::vector<DicomTag>& parentTags, + const std::vector<size_t>& parentIndexes, + const DicomTag& tag, + ValueRepresentation vr, + const std::vector<double>& values) { if (tag.GetElement() != 0x0000 && vr != ValueRepresentation_NotSupported) @@ -507,13 +519,16 @@ node[KEY_VALUE] = content; } } + + return Action_None; } - void DicomWebJsonVisitor::VisitAttributes(const std::vector<DicomTag>& parentTags, - const std::vector<size_t>& parentIndexes, - const DicomTag& tag, - const std::vector<DicomTag>& values) + ITagVisitor::Action + DicomWebJsonVisitor::VisitAttributes(const std::vector<DicomTag>& parentTags, + const std::vector<size_t>& parentIndexes, + const DicomTag& tag, + const std::vector<DicomTag>& values) { if (tag.GetElement() != 0x0000) { @@ -531,6 +546,8 @@ node[KEY_VALUE] = content; } } + + return Action_None; }