1
2
3
4
5
6
7
8
9
10
11
12
13
| package chat.util;
|
| import io.netty.buffer.ByteBuf;
|
| public class BytesSelfUtil {
|
| public static byte[] getReadableBytes(ByteBuf ackPayload) {
| byte[] resBytes = new byte[ackPayload.readableBytes()];
| ackPayload.getBytes(0, resBytes);
| return resBytes;
| }
|
| }
|
|