void readBlockHeader(int leadByte) throws IOException { switch (leadByte) { case Protocol.ID_START_BLOCK_SMALL: remaining = riverUnmarshaller.readUnsignedByte(); return; case Protocol.ID_START_BLOCK_MEDIUM: remaining = riverUnmarshaller.readUnsignedShort(); return; case Protocol.ID_START_BLOCK_LARGE: final int len = riverUnmarshaller.readInt(); if (len < 0) { throw new StreamCorruptedException("Invalid block length"); } remaining = len; return; case Protocol.ID_END_BLOCK_DATA: remaining = -1; return; default: throw badLeadByte(leadByte); } }
void readBlockHeader(int leadByte) throws IOException { switch (leadByte) { case Protocol.ID_START_BLOCK_SMALL: remaining = riverUnmarshaller.readUnsignedByte(); return; case Protocol.ID_START_BLOCK_MEDIUM: remaining = riverUnmarshaller.readUnsignedShort(); return; case Protocol.ID_START_BLOCK_LARGE: final int len = riverUnmarshaller.readInt(); if (len < 0) { throw new StreamCorruptedException("Invalid block length"); } remaining = len; return; case Protocol.ID_END_BLOCK_DATA: remaining = -1; return; default: throw badLeadByte(leadByte); } }
void readBlockHeader(int leadByte) throws IOException { switch (leadByte) { case Protocol.ID_START_BLOCK_SMALL: remaining = riverUnmarshaller.readUnsignedByte(); return; case Protocol.ID_START_BLOCK_MEDIUM: remaining = riverUnmarshaller.readUnsignedShort(); return; case Protocol.ID_START_BLOCK_LARGE: final int len = riverUnmarshaller.readInt(); if (len < 0) { throw new StreamCorruptedException("Invalid block length"); } remaining = len; return; case Protocol.ID_END_BLOCK_DATA: remaining = -1; return; default: throw badLeadByte(leadByte); } }
void readBlockHeader(int leadByte) throws IOException { switch (leadByte) { case Protocol.ID_START_BLOCK_SMALL: remaining = riverUnmarshaller.readUnsignedByte(); return; case Protocol.ID_START_BLOCK_MEDIUM: remaining = riverUnmarshaller.readUnsignedShort(); return; case Protocol.ID_START_BLOCK_LARGE: final int len = riverUnmarshaller.readInt(); if (len < 0) { throw new StreamCorruptedException("Invalid block length"); } remaining = len; return; case Protocol.ID_END_BLOCK_DATA: remaining = -1; return; default: throw badLeadByte(leadByte); } }
void readBlockHeader(int leadByte) throws IOException { switch (leadByte) { case Protocol.ID_START_BLOCK_SMALL: remaining = riverUnmarshaller.readUnsignedByte(); return; case Protocol.ID_START_BLOCK_MEDIUM: remaining = riverUnmarshaller.readUnsignedShort(); return; case Protocol.ID_START_BLOCK_LARGE: final int len = riverUnmarshaller.readInt(); if (len < 0) { throw new StreamCorruptedException("Invalid block length"); } remaining = len; return; case Protocol.ID_END_BLOCK_DATA: remaining = -1; return; default: throw badLeadByte(leadByte); } }
void readBlockHeader(int leadByte) throws IOException { switch (leadByte) { case Protocol.ID_START_BLOCK_SMALL: remaining = riverUnmarshaller.readUnsignedByte(); return; case Protocol.ID_START_BLOCK_MEDIUM: remaining = riverUnmarshaller.readUnsignedShort(); return; case Protocol.ID_START_BLOCK_LARGE: final int len = riverUnmarshaller.readInt(); if (len < 0) { throw new StreamCorruptedException("Invalid block length"); } remaining = len; return; case Protocol.ID_END_BLOCK_DATA: remaining = -1; return; default: throw badLeadByte(leadByte); } }
void readBlockHeader(int leadByte) throws IOException { switch (leadByte) { case Protocol.ID_START_BLOCK_SMALL: remaining = riverUnmarshaller.readUnsignedByte(); return; case Protocol.ID_START_BLOCK_MEDIUM: remaining = riverUnmarshaller.readUnsignedShort(); return; case Protocol.ID_START_BLOCK_LARGE: final int len = riverUnmarshaller.readInt(); if (len < 0) { throw new StreamCorruptedException("Invalid block length"); } remaining = len; return; case Protocol.ID_END_BLOCK_DATA: remaining = -1; return; default: throw badLeadByte(leadByte); } }