2929 * This implementation provides a light weight
3030 * object for testing with an {@link Reader}
3131 * where the contents don't matter.
32+ * </p>
3233 * <p>
3334 * One use case would be for testing the handling of
3435 * large {@link Reader} as it can emulate that
3536 * scenario without the overhead of actually processing
3637 * large numbers of characters - significantly speeding up
3738 * test execution times.
39+ * </p>
3840 * <p>
3941 * This implementation returns a space from the method that
4042 * reads a character and leaves the array unchanged in the read
4143 * methods that are passed a character array.
4244 * If alternative data is required the <code>processChar()</code> and
4345 * <code>processChars()</code> methods can be implemented to generate
4446 * data, for example:
45- *
47+ * </p>
48+ *
4649 * <pre>
4750 * public class TestReader extends NullReader {
4851 * public TestReader(int size) {
@@ -73,7 +76,7 @@ public class NullReader extends Reader {
7376 private final boolean markSupported ;
7477
7578 /**
76- * Create a {@link Reader} that emulates a specified size
79+ * Creates a {@link Reader} that emulates a specified size
7780 * which supports marking and does not throw EOFException.
7881 *
7982 * @param size The size of the reader to emulate.
@@ -83,7 +86,7 @@ public NullReader(final long size) {
8386 }
8487
8588 /**
86- * Create a {@link Reader} that emulates a specified
89+ * Creates a {@link Reader} that emulates a specified
8790 * size with option settings.
8891 *
8992 * @param size The size of the reader to emulate.
@@ -100,7 +103,7 @@ public NullReader(final long size, final boolean markSupported, final boolean th
100103 }
101104
102105 /**
103- * Return the current position.
106+ * Returns the current position.
104107 *
105108 * @return the current position.
106109 */
@@ -109,7 +112,7 @@ public long getPosition() {
109112 }
110113
111114 /**
112- * Return the size this {@link Reader} emulates.
115+ * Returns the size this {@link Reader} emulates.
113116 *
114117 * @return The size of the reader to emulate.
115118 */
@@ -118,7 +121,7 @@ public long getSize() {
118121 }
119122
120123 /**
121- * Close this Reader - resets the internal state to
124+ * Closes this Reader - resets the internal state to
122125 * the initial values.
123126 *
124127 * @throws IOException If an error occurs.
@@ -131,7 +134,7 @@ public void close() throws IOException {
131134 }
132135
133136 /**
134- * Mark the current position.
137+ * Marks the current position.
135138 *
136139 * @param readlimit The number of characters before this marked position
137140 * is invalid.
@@ -157,7 +160,7 @@ public boolean markSupported() {
157160 }
158161
159162 /**
160- * Read a character.
163+ * Reads a character.
161164 *
162165 * @return Either The character value returned by <code>processChar()</code>
163166 * or <code>-1</code> if the end of file has been reached and
@@ -179,7 +182,7 @@ public int read() throws IOException {
179182 }
180183
181184 /**
182- * Read some characters into the specified array.
185+ * Reads some characters into the specified array.
183186 *
184187 * @param chars The character array to read into
185188 * @return The number of characters read or <code>-1</code>
@@ -195,7 +198,7 @@ public int read(final char[] chars) throws IOException {
195198 }
196199
197200 /**
198- * Read the specified number characters into an array.
201+ * Reads the specified number characters into an array.
199202 *
200203 * @param chars The character array to read into.
201204 * @param offset The offset to start reading characters into.
@@ -226,7 +229,7 @@ public int read(final char[] chars, final int offset, final int length) throws I
226229 }
227230
228231 /**
229- * Reset the stream to the point when mark was last called.
232+ * Resets the stream to the point when mark was last called.
230233 *
231234 * @throws UnsupportedOperationException if mark is not supported.
232235 * @throws IOException If no position has been marked
@@ -251,7 +254,7 @@ public synchronized void reset() throws IOException {
251254 }
252255
253256 /**
254- * Skip a specified number of characters.
257+ * Skips a specified number of characters.
255258 *
256259 * @param numberOfChars The number of characters to skip.
257260 * @return The number of characters skipped or <code>-1</code>
@@ -279,9 +282,10 @@ public long skip(final long numberOfChars) throws IOException {
279282 }
280283
281284 /**
282- * Return a character value for the <code>read()</code> method.
285+ * Returns a character value for the <code>read()</code> method.
283286 * <p>
284287 * This implementation returns zero.
288+ * </p>
285289 *
286290 * @return This implementation always returns zero.
287291 */
@@ -295,6 +299,7 @@ protected int processChar() {
295299 * method.
296300 * <p>
297301 * This implementation leaves the character array unchanged.
302+ * </p>
298303 *
299304 * @param chars The character array
300305 * @param offset The offset to start at.
@@ -305,7 +310,7 @@ protected void processChars(final char[] chars, final int offset, final int leng
305310 }
306311
307312 /**
308- * Handle End of File.
313+ * Handles End of File.
309314 *
310315 * @return <code>-1</code> if <code>throwEofException</code> is
311316 * set to {@code false}
0 commit comments