Change ByteBufferEnumerator<T>.Create(...).ToArray() to IO.ByteConver… #11
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.
…ter.ToArray(...) throughout the codebase
I think we could still improve on the code in DicomElement.cs since, in several of the cases, .ToArray() is being called to then just throw away the array to fetch a single item. This change is certainly no worse than the old code (and is indeed better perf-wise) but I suspect we could sometimes keep the ByteBufferEnumerator and use Linq to apply .Skip(item-1).First() on the IEnumerable.
I figured I'd jump in and make this change after seeing a bit of a discussion in gitter.