jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dominique Pfister <dominique.pfis...@day.com>
Subject Re: Limit of 65535 bytes per String value?
Date Thu, 17 Feb 2005 11:18:20 GMT
David Nuescheler wrote:
>>DataOutputStream.writeUTF(String str, DataOutput out) :
>>       if (utflen > 65535)
>>           throw new UTFDataFormatException();
> 
> 
> LOL ;) that will make for a pretty site 
> in sun's bug parade.
> 
Well, the javadoc for the interface method DataOutput.writeUTF declares 
this limitation that is probably due to the internal limit for constant 
string values inside a Java Virtual Machine:

* [...] If this number is larger than
* <code>65535</code>, then a <code>UTFDataFormatException</code>
* is thrown.

Sadly enough, this warning didn't make it into the javadoc of 
DataOutputStream's implementation...

Dominique

Mime
View raw message