Archived
0

модернизания NetStream (extends Input/Output stream)

cherry-pick: d783317b5d
This commit is contained in:
2018-12-24 11:30:46 +03:00
parent fa5ef8c97c
commit 0feefc83e4
7 changed files with 72 additions and 38 deletions

View File

@@ -1,7 +1,3 @@
/*
* DmitriyMX <dimon550@gmail.com>
* 2018-07-25
*/
package mc.core.network.proto_1_12_2.netty.wrappers;
import io.netty.buffer.ByteBuf;
@@ -25,8 +21,9 @@ public class WrapperNetInputStream extends NetInputStream_p340 {
}
@Override
public void readBytes(byte[] buffer) {
byteBuf.readBytes(buffer);
public int readBytes(byte[] buffer, int offset, int length) {
byteBuf.readBytes(buffer, offset, length);
return length;
}
@Override

View File

@@ -1,7 +1,3 @@
/*
* DmitriyMX <dimon550@gmail.com>
* 2018-07-25
*/
package mc.core.network.proto_1_12_2.netty.wrappers;
import io.netty.buffer.ByteBuf;
@@ -30,8 +26,8 @@ public class WrapperNetOutputStream extends NetOutputStream_p340 {
}
@Override
public void writeBytes(byte[] buffer) {
byteBuf.writeBytes(buffer);
public void writeBytes(byte[] buffer, int offset, int lengtn) {
byteBuf.writeBytes(buffer, offset, lengtn);
}
@Override