directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Trustin Lee <trus...@gmail.com>
Subject Re: [mina] ByteBuffer problem?
Date Wed, 20 Apr 2005 08:03:33 GMT
Hi Vinod,

2005/4/20, Vinod Panicker <vinod.p@gmail.com>:
> Hi Trustin,
> 
> Here's the code that I was having a problem with -
> 
> -- begin code --
> 
> public void decode(ProtocolSession session, ByteBuffer in,
> ProtocolDecoderOutput out)
> {
>        ByteBuffer temp = ByteBuffer.allocate(in.capacity());
>        temp.put(in);
>        temp.flip().limit(in.limit());
>        in.flip();
>        System.out.println("[D] Data decoded : " + in.getHexDump());
>        System.out.println("[D] Data decoded char : " + in.getString(in.limit(),
>                Charset.defaultCharset().newDecoder()));
>        out.write(temp);
> }

There was a bug in getString() methods.  SVN server is down for now. 
I'll check in the fix and test cases soon.  I'm sorry for
inconvenience!

Trustin
-- 
what we call human nature is actually human habit
--
http://gleamynode.net/

Mime
View raw message