This commit is contained in:
RedKale
2016-02-23 10:58:46 +08:00
parent 4b9cf768f4
commit 10f7f3e4fd

View File

@@ -11,7 +11,9 @@ import java.nio.charset.*;
/**
* 简单的byte[]操作类。
*
* <p> 详情见: http://www.redkale.org
* <p>
* 详情见: http://www.redkale.org
*
* @author zhangjx
*/
public final class ByteArray {
@@ -52,6 +54,10 @@ public final class ByteArray {
return count;
}
public byte get(int index) {
return content[index];
}
public void write(byte[] buf) {
System.arraycopy(this.content, 0, buf, 0, count);
}