FrameDecoder will keep calling the decoder method until it returns null?

"Trustin Lee (이희승)" trustin at gmail.com
Wed Jan 6 20:40:37 EST 2010


hezjing wrote:
> Hi
> 
> I'm reading the Netty 3.2 Getting
> Started<http://www.jboss.org/file-access/default/members/netty/freezone/guide/3.2/html/start.html#d0e56>
> .
> 
> Section 1.7.3 (The Second Solution) explained that the FrameDecoder will
> keep calling the decoder method until it returns null.
> 
> Shouldn't be the FrameDecoder will keep calling the decoder method until it
> returns ChannelBuffer object (or not null)?

To express in pseudo code:

  do {
      frame = decode(...);
  } while (frame != null);

So, FrameDecoder keeps calling decode() until it returns null (i.e.
while it returns non-null)

Or.. am I missing something?

-- 
what we call human nature in actuality is human habit
http://gleamynode.net/


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 260 bytes
Desc: OpenPGP digital signature
Url : http://lists.jboss.org/pipermail/netty-users/attachments/20100107/cefd3656/attachment.bin 


More information about the netty-users mailing list