Reuse constant, normalize spelling.
MODIFY
src/main/java/org/apache/commons/io/output/ByteArrayOutputStream.java
src/main/java/org/apache/commons/io/output/ByteArrayOutputStream.java
import java.io.OutputStream;
/**
- * Implements a ThreadSafe version of
- * {@link AbstractByteArrayOutputStream} using instance
- * synchronisation.
+ * Implements a ThreadSafe version of {@link AbstractByteArrayOutputStream} using instance synchronization.
*/
//@ThreadSafe
public class ByteArrayOutputStream extends AbstractByteArrayOutputStream {
@@ -121,7 +119,7 @@ public synchronized void writeTo(final OutputStream out) throws IOException {
*/
public static InputStream toBufferedInputStream(final InputStream input)
throws IOException {
- return toBufferedInputStream(input, 1024);
+ return toBufferedInputStream(input, DEFAULT_SIZE);
}
/**

MODIFY
src/main/java/org/apache/commons/io/output/UnsynchronizedByteArrayOutputStream.java
src/main/java/org/apache/commons/io/output/UnsynchronizedByteArrayOutputStream.java
@@ -119,7 +119,7 @@ public void writeTo(final OutputStream out) throws IOException {
*/
public static InputStream toBufferedInputStream(final InputStream input)
throws IOException {
- return toBufferedInputStream(input, 1024);
+ return toBufferedInputStream(input, DEFAULT_SIZE);
}
/**

Reuse constant, normalize spelling.