protected void write (char[] chars, int startIndex, int length) throws IOException

All write methods call into this one. If getCanWrapLines() returns false, this will call output with each sequence of chars that doesn't contain a NEWLINE, followed by a call to writeLineSeparator. On the other hand, if getCanWrapLines() returns true, this will split the string, as necessary, so getLineLength is honored. The only exception is if the current string contains no whitespace, and won't fit in which case the line length will exceed getLineLength.

Parameters:
chars    characters to output
startIndex    starting index
length    length of output

Exceptions:
IOException    on any I/O error

Since:  1.3