comparison OrthancServer/ParsedDicomFile.cpp @ 1699:8ca0e89798b2

"/modify" can insert/modify sequences
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 09 Oct 2015 13:31:22 +0200
parents 18c02c6987d5
children 4aaaecae5803
comparison
equal deleted inserted replaced
1698:d78b87f93bcf 1699:8ca0e89798b2
589 } 589 }
590 } 590 }
591 591
592 592
593 void ParsedDicomFile::Insert(const DicomTag& tag, 593 void ParsedDicomFile::Insert(const DicomTag& tag,
594 const std::string& utf8Value)
595 {
596 std::auto_ptr<DcmElement> element(FromDcmtkBridge::CreateElementForTag(tag));
597 FromDcmtkBridge::FillElementWithString(*element, tag, utf8Value, false, GetEncoding());
598 InsertInternal(*pimpl_->file_->getDataset(), element.release());
599 }
600
601
602 void ParsedDicomFile::Insert(const DicomTag& tag,
603 const Json::Value& value, 594 const Json::Value& value,
604 bool decodeBinaryTags) 595 bool decodeBinaryTags)
605 { 596 {
606 std::auto_ptr<DcmElement> element(FromDcmtkBridge::FromJson(tag, value, decodeBinaryTags, GetEncoding())); 597 std::auto_ptr<DcmElement> element(FromDcmtkBridge::FromJson(tag, value, decodeBinaryTags, GetEncoding()));
607 InsertInternal(*pimpl_->file_->getDataset(), element.release()); 598 InsertInternal(*pimpl_->file_->getDataset(), element.release());