1 /**
2 * BSD-style license; for more info see http://pmd.sourceforge.net/license.html
3 */
4 package net.sourceforge.pmd.testframework;
5
6 import java.io.IOException;
7 import java.io.InputStream;
8
9 import org.apache.commons.io.IOUtils;
10
11 /**
12 * @deprecated Just use apache {@link IOUtils}
13 */
14 @Deprecated
15 public final class StreamUtil {
16
17 private StreamUtil() {
18 // utility class
19 }
20
21 /**
22 * @deprecated use {@link IOUtils#toString(InputStream)} instead
23 */
24 @Deprecated
25 public static String toString(InputStream stream) {
26 try {
27 return IOUtils.toString(stream);
28 } catch (IOException e) {
29 throw new RuntimeException(e);
30 }
31 }
32 }