[ 
https://issues.apache.org/jira/browse/HBASE-6352?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13408664#comment-13408664
 ] 

Jean-Marc Spaggiari commented on HBASE-6352:
--------------------------------------------

[[email protected]]Here is a simple example:
byte[] endKey = Bytes.copy (startKey);
endKey[endKey.length - 1]++;
Scan scan = new Scan (startKey, endKey);

I know that if the last byte is 255 this will cause and issue but it's just for 
the example. Also, I will provide soon another suggestion to have a methode 
that increase the last byte of the array safely. It's usefull when workin with 
the scans (I think).
                
> Add copy method in Bytes
> ------------------------
>
>                 Key: HBASE-6352
>                 URL: https://issues.apache.org/jira/browse/HBASE-6352
>             Project: HBase
>          Issue Type: Improvement
>          Components: util
>    Affects Versions: 0.94.0
>            Reporter: Jean-Marc Spaggiari
>            Priority: Minor
>              Labels: Bytes, Util
>         Attachments: HBASE_JIRA_6352.patch, HBASE_JIRA_6352_v2.patch
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Having a "copy" method into Bytes might be nice to reduce client code size 
> and improve readability.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to