- Object
-
- VarLengthMessageScanner
-
- All Implemented Interfaces:
MessageScanner
public class VarLengthMessageScanner extends Object implements MessageScanner
This scanner treats all data which was written into the buffer so far as one single message. As the result such messages may have variable length. Effectively message will consist from whatever ICE managed to receive from the client in one non blocking read operation.
-
-
Constructor Summary
Constructors Constructor Description VarLengthMessageScanner()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
scan(ByteBuffer buf)
-
-
-
Method Detail
-
scan
public int scan(ByteBuffer buf)
- Specified by:
scan
in interfaceMessageScanner
- Returns:
- message end position or -1 if message is not complete or not found in the buffer yet. If last byte of the message found on position n then the message end position will be considered as n + 1.
-
-