Scott,
Have to revisit this thread because there is a bug in the Java
implementation.
Scott Ferguson skrev:
> The 'l' encoding is for Hessian 1.0 compatibility.
Ok, short comment about this .. why not remove it completely from 2.0?
Is it required for the spec to be comp. with 1.0? Is it required that a
2.0 server can handle other versions than 2.0? Anyway, that's beside the
point..
> x6e is followed by the int production. So a length of 0 would be
>
> x6e x90
>
> Or
>
> x6e I(cap-i) b3 b2 b1 b0
>
> The int production encodes the number of bytes.
The java implementation uses this in Hessian2Output.
if (length < 0) {
} else if (length < 0x100) {
_buffer[_offset++] = (byte) (LENGTH_BYTE);
_buffer[_offset++] = (byte) (length);
} else {
_buffer[_offset++] = (byte) ('l');
_buffer[_offset++] = (byte) (length >> 24);
_buffer[_offset++] = (byte) (length >> 16);
_buffer[_offset++] = (byte) (length >> 8);
_buffer[_offset++] = (byte) (length);
}
That has to be a bug, right? Also, all examples about this is wrong in
the spec .. but the grammar spec in the beginning of the spec is
correct. However, using that encoding will not work with the server.
Cheers,
/Niclas
_______________________________________________
hessian-interest mailing list
[email protected]
http://maillist.caucho.com/mailman/listinfo/hessian-interest