2 Questions on StringBuffer
Ulf Zibis
Ulf.Zibis at gmx.de
Wed Mar 17 21:24:57 UTC 2010
Am 17.03.2010 20:12, schrieb Martin Buchholz:
> On Wed, Mar 17, 2010 at 10:02, Ulf Zibis<Ulf.Zibis at gmx.de> wrote:
>
>>
>> Additionally I think, there's a bug in javadoc of those methods.
>> Actually they throw StringIndexOutOfBoundsException.
>>
> Why would that be a bug?
>
I think, javadoc should indicate StringIndexOutOfBoundsException here:
/**
* @throws IndexOutOfBoundsException {@inheritDoc}
* @see #length()
*/
public synchronized char charAt(int index) {
if ((index < 0) || (index >= count))
throw new StringIndexOutOfBoundsException(index);
return value[index];
}
Or am I not enough informed about {@inheritDoc} ?
-Ulf
More information about the core-libs-dev
mailing list