Skip to content

Commit 0cc94ec

Browse files
author
Gary Gregory
committed
[IO-510] Add and adapt ReadAheadInputStream and
BufferedFileChannelInputStream from Apache Spark. Lowest level ctor does not need to be public for now.
1 parent 82b0291 commit 0cc94ec

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/main/java/org/apache/commons/io/input/ReadAheadInputStream.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,11 @@ private static ExecutorService newExecutorService() {
5454

5555
/**
5656
* Creates a new daemon thread.
57-
*
57+
*
5858
* @param r the thread's runnable.
5959
* @return a new daemon thread.
6060
*/
61-
private static Thread newThread(Runnable r) {
61+
private static Thread newThread(final Runnable r) {
6262
final Thread thread = new Thread(r, "commons-io-read-ahead");
6363
thread.setDaemon(true);
6464
return thread;
@@ -140,7 +140,7 @@ public ReadAheadInputStream(final InputStream inputStream, final int bufferSizeI
140140
* @param executorService An executor service for the read-ahead thread.
141141
* @param shutdownExecutorService Whether or not to shutdown the given ExecutorService on close.
142142
*/
143-
public ReadAheadInputStream(final InputStream inputStream, final int bufferSizeInBytes,
143+
private ReadAheadInputStream(final InputStream inputStream, final int bufferSizeInBytes,
144144
final ExecutorService executorService, final boolean shutdownExecutorService) {
145145
if (bufferSizeInBytes <= 0) {
146146
throw new IllegalArgumentException(

0 commit comments

Comments
 (0)