Closed sadikovi closed 6 years ago
@sunchao Could you review this PR too? It adds byte array encodings and fixes some issues to make them work. I only tested with unit tests, not with actual files though. Also apologies for changing get()
method in DeltaByteArrayDecoder
, it actually only needed couple of changes, but I thought that these changes made method simpler and easier to understand what is going on - happy to revert it to the original code!
Would love to know your ideas and suggestions for the change. Thanks for merging previous patch - it makes this patch work!
Thanks @sadikovi ! and sorry for the delay. I'll take a look at this PR soon :)
@sunchao all good, no worries:) whenever you have time to review it.
@sunchao Would you mind reviewing this PR again? I addressed some of the comments and replied to your inline comments. Would appreciate if you could have a look. Thanks!
@sunchao Thank you for the review. I updated the code according to your changes.
bytes_written
, it did not affect anything + there is no need to mix changes in one PRput
method in delta length byte array encoding and only copy data when flush_buffer
is called.Could you review again, when you have time? Thanks. Feel free to comment on any changes, because it helps me to avoid "Java-like" coding, and start thinking on how to avoid extensive data copy.
@sunchao Thanks for merging!
This PR adds
DELTA_LENGTH_BYTE_ARRAY
andDELTA_BYTE_ARRAY
encodings and fixes some small issues in decodings.Changes:
DELTA_LENGTH_BYTE_ARRAY
encodingDELTA_BYTE_ARRAY
encodingslice()
method forByteArray
get_encoder
andget_decoder
DELTA_BYTE_ARRAY
decodingget()
method, fixed current_idx update, and modified overall method to handle prefix length 0 (IMHO, it is a bit simpler now)Fixes #33 Fixes #34