public void onBinaryFrame(WebSocketSession s, WebSocketFrameHeader header, ByteBuffer... payload) {
HandlerWrapper handler = getHandler(FrameType.BYTE);
if (handler == null) {
return;
}
MessageHandler mHandler = handler.getHandler();
if (mHandler instanceof MessageHandler.Partial) {
super.onBinaryFrame(s, header, payload);
} else {
if (binaryFrame.isEmpty() && header.isLastFragement()) {
((MessageHandler.Whole) mHandler).onMessage(toBuffer(payload));