左晓为主开发手持机充值管理机
easysocket/src/main/java/com/easysocket/connection/iowork/EasyWriter.java
@@ -4,6 +4,7 @@
import com.easysocket.interfaces.conn.IConnectionManager;
import com.easysocket.interfaces.conn.ISocketActionDispatch;
import com.easysocket.interfaces.io.IWriter;
import com.easysocket.utils.HexUtil;
import com.easysocket.utils.LogUtil;
import java.io.IOException;
@@ -92,8 +93,8 @@
    @Override
    public void write(byte[] sendBytes) throws IOException {
        if (sendBytes != null) {
            LogUtil.d("Socket发送数据String-->" + new String(sendBytes, Charset.forName("utf-8")));
            LogUtil.d("Socket发送数据byte[]-->" + Arrays.toString(sendBytes));
            LogUtil.d("EasyWriter--Socket发送数据String-->" + HexUtil.bytesToHex(sendBytes));
            LogUtil.d("EasyWriter--Socket发送数据byte[]-->" + Arrays.toString(sendBytes));
            int packageSize = socketOptions.getMaxWriteBytes(); // 每次可以发送的最大数据
            int remainingCount = sendBytes.length;
            ByteBuffer writeBuf = ByteBuffer.allocate(packageSize);