Issue Details (XML | Word | Printable)

Key: DIRMINA-140
Type: New Feature New Feature
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Trustin Lee
Reporter: Trustin Lee
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
MINA

ByteBuffer.prefixedDataAvailable()

Created: 07/Dec/05 01:26 PM   Updated: 07/Dec/05 01:29 PM
Return to search
Component/s: None
Affects Version/s: None
Fix Version/s: 0.9.0

Time Tracking:
Not Specified

Resolution Date: 07/Dec/05 01:29 PM


 Description  « Hide
Many protocols use a data type which has a data length field as a prefix. It will be very useful if users can check if the buffer contains the whole data by inspecting the data length field before start reading the data. ByteBuffer.prefixedDataAvailable() will let users do this trivial and repetitive task with just one method call.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Repository Revision Date User Message
ASF #354703 Wed Dec 07 04:29:25 UTC 2005 trustin Resolved issue: DIRMINA-140 (ByteBuffer.prefixedDataAvailable())
* Added ByteBuffer.prefixedDataAvailable()
* Simplified ObjectSerilizationDecoder to use ByteBuffer.prefixedDataAvailable()
* All prefixed data type getter/setter throw BufferUnderflowException before reading the partial content thanks to prefixedDataAvailable()
Files Changed
MODIFY /directory/network/trunk/src/java/org/apache/mina/common/ByteBuffer.java
MODIFY /directory/network/trunk/src/java/org/apache/mina/filter/codec/serialization/ObjectSerializationDecoder.java

Trustin Lee made changes - 07/Dec/05 01:29 PM
Field Original Value New Value
Status Open [ 1 ] Closed [ 6 ]
Assignee Trustin Lee [ trustin ]
Resolution Fixed [ 1 ]