Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello!
Opening this as a draft in case you feel it does not belong in the lib.
When extracting information from Dicom Element values, I often find it necessary to make sure that a value is not "empty" or "zero"; that is that the value provided is an actual value.
A few examples would be a PatientName value of "", a Rows or Columns value of 0, or a OB element with no actual bytes present.
This PR adds an IsZero() method to value that checks if the inner value is actually a zero-value.
Example Usage:
This PR will likely have merge conflicts with #195 . If you end up liking both of them, feel free to merge either one, then I can update the other to resolve any merge conflicts that occur.
Thanks!
As a side note: a lot of these PRs are groundwork I am using for a value decoder helper-type I am using internally. If you would be interested in seeing what I am tinkering on there, I could open a draft PR with it, as I think it might make a nice addition to the lib. Let me know!