From 5b1266eb0d44f5ac1a25d1346a2cf66713e33041 Mon Sep 17 00:00:00 2001 From: Alexander Bigerl Date: Mon, 12 Apr 2021 15:52:24 +0200 Subject: [PATCH] set visibility of Streams' static members --- .../main/java/org/aksw/iguana/commons/streams/Streams.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/iguana.commons/src/main/java/org/aksw/iguana/commons/streams/Streams.java b/iguana.commons/src/main/java/org/aksw/iguana/commons/streams/Streams.java index 1553bc4b..55ef9edd 100644 --- a/iguana.commons/src/main/java/org/aksw/iguana/commons/streams/Streams.java +++ b/iguana.commons/src/main/java/org/aksw/iguana/commons/streams/Streams.java @@ -14,11 +14,11 @@ */ public class Streams { - final static int bufferSize = 16 * 1024 * 1024; // 16 MB buffer + public static final int bufferSize = 16 * 1024 * 1024; // 16 MB buffer - final static ThreadLocal threadBuffer = ThreadLocal.withInitial(() -> new byte[bufferSize]); + protected static final ThreadLocal threadBuffer = ThreadLocal.withInitial(() -> new byte[bufferSize]); - final static ThreadLocal threadByteArrayOutputStream = ThreadLocal.withInitial(() -> new ByteArrayOutputStream(bufferSize)); + protected static final ThreadLocal threadByteArrayOutputStream = ThreadLocal.withInitial(() -> new ByteArrayOutputStream(bufferSize)); /** * Fastest way to serialize a stream to UTF-8 according to https://stackoverflow.com/a/35446009/6800941