Re: problem of using mina communicate with c++ socket

2007-09-03 Thread Lan Boon Ping
Hi, Be aware of little Endian(C++) and big Endian(Java), you should be able to use the ByteBuffer to decode the Struct Employee corrrectly. For instance, ByteBuffer message; message.order(ByteOrder.LITTLE_ENDIAN) ; byte[] name = new byte[10]; message.get( name); int id = message.getInt(); int

Re: problem of using mina communicate with c++ socket

2007-09-04 Thread Lan Boon Ping
it do not do ByteOrder > > > 2007/9/4, mat <[EMAIL PROTECTED]>: > > > > Does JVM do the byte reserve for us in the method message.order( > > ByteOrder.LITTLE_ENDIAN) ? > > > > On 9/4/07, Lan Boon Ping < [EMAIL PROTECTED]> wrote: > > > > > > Hi

Re: New name for ByteBuffer?

2007-09-18 Thread Lan Boon Ping
I would choose MINADataBuffer as there is a java.awt.image.DataBuffer. Regards Boon Ping. On 9/18/07, Julien Vermillard <[EMAIL PROTECTED]> wrote: > > > MINAByteBuffer, because it's MINA, not Mina and I like obvious names :) > Julien > > > On Tue, 18 Sep 2007 10:14:56 +0900 > "Trustin Lee" <[EMAI