Enet4 / dicom-rs

Rust implementation of the DICOM standard
https://dicom-rs.github.io
Apache License 2.0
404 stars 76 forks source link

Change attribute actions (Set, SetIfMissing, Replace) #360

Closed Enet4 closed 1 year ago

Enet4 commented 1 year ago

This makes a few changes to the upcoming attribute operations API. Replace and ReplaceStr now have a different behavior, in that they do not set the value unless the attribute already exists (as in, is present in the receiving object, regardless of being empty or not). Set and SetStr should be used when the intent is to define the attribute regardless of whether it exists yet.