BytesWritable value = new BytesWritable();BytesWritable不能作为mapreduce中的key或者value,与ByteWritable不同。1,BytesWritable.tobyte()//将ByteWritable类型的数据转换为十六进制对,并以空格分开;2,BytesWritable.set(byte[] newData,in...
摘要由CSDN通过智能技术生成
BytesWritable value = new BytesWritable();
BytesWritable不能作为mapreduce中的key或者value,与ByteWritable不同。
1,BytesWritable.tobyte()//将ByteWritable类型的数据转换为十六进制对,并以空格分开;
2,BytesWritable.set(byte[] newData,int offset,int length);//将值设置为给定的字节范围的副本
3,BytesWritable.copyBytes()//获得对象的byte[]类型全部数据:Get a copy of the bytes that is exactly the length of the data. See getBytes() for faster access to the underlying array.
4,BytesWritable.getBytes()//**Get the data backing the BytesWritable. Please use copyBytes() if you need the returned array to be precisely the length of the data.**
Modifier and Type
Method and Description
byte[]
copyBytes():Get a copy of the bytes that is exactly the length of the data.
BytesWritable value = new BytesWritable();BytesWritable不能作为mapreduce中的key或者value,与ByteWritable不同。1,BytesWritable.tobyte()//将ByteWritable类型的数据转换为十六进制对,并以空格分开;2,BytesWritable.set(byte[] newData,in...