bundles/org.apache.jasper.glassfish/src/org/apache/jasper/xmlparser/ASCIIReader.java
public int read(char ch[], int offset, int length) throws IOException {
        if (length > fBuffer.length) {
            length = fBuffer.length;
        }
        int count = fInputStream.read(fBuffer, 0, length);
        for (int i = 0; i < count; i++) {
            int b0 = fBuffer[i];
            if (b0 < 0) {
                throw new IOException(Localizer.getMessage("jsp.error.xml.invalidASCII",
							   Integer.toString(b0)));
            }
            ch[offset + i] = (char)b0;
        }
        return count;
    }
public int read(char ch[], int offset, int length) throws IOException {
        if (length > fBuffer.length) {
            length = fBuffer.length;
        }
        int count = fInputStream.read(fBuffer, 0, length);
        for (int i = 0; i < count; i++) {
            int b0 = fBuffer[i];
            if (b0 < 0) {
                throw new IOException(Localizer.getMessage("jsp.error.xml.invalidASCII",
							   Integer.toString(b0)));
            }
            ch[offset + i] = (char)b0;
        }
        return count;
    }
public int read ( char ch [ ] , int offset , int length ) throws IOException { if ( length > fBuffer . length ) { length = fBuffer . length ; } int count = fInputStream . read ( fBuffer , 0 , length ) ; for ( int i = 0 ; i < count ; i ++ ) { int b0 = fBuffer [ i ] ; if ( b0 < 0 ) { throw new IOException ( Localizer . getMessage ( "jsp.error.xml.invalidASCII" , Integer . toString ( b0 ) ) ) ; } ch [ offset + i ] = ( char ) b0 ; } return count ; }
Read characters into a portion of an array.  This method will block
until some input is available, an I/O error occurs, or the end of the
stream is reached.

@param      ch     Destination buffer
@param      offset Offset at which to start storing characters
@param      length Maximum number of characters to read

@return     The number of characters read, or -1 if the end of the
stream has been reached

@exception  IOException  If an I/O error occurs
Read characters into a portion of an array . This method will block until some input is available an I / O error occurs or the end of the stream is reached .