Package edu.umd.cs.findbugs.io
Class IO
java.lang.Object
edu.umd.cs.findbugs.io.IO
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidClose given InputStream, ignoring any resulting exception.static voidclose(InputStream inputStream) Close given InputStream, ignoring any resulting exception.static voidclose(OutputStream outputStream) Close given OutputStream, ignoring any resulting exception.static longcopy(InputStream in, OutputStream out) static longcopy(InputStream in, OutputStream out, long maxBytes) static longstatic longstatic byte[]readAll(InputStream in) static byte[]readAll(InputStream in, int size) static Stringstatic voidskipFully(InputStream in, long bytes) Provide a skip fully method.static boolean
-
Constructor Details
-
IO
public IO()
-
-
Method Details
-
readAll
- Throws:
IOException
-
readAll
- Throws:
IOException
-
readAll
- Throws:
IOException
-
copy
public static long copy(@WillNotClose InputStream in, @WillNotClose OutputStream out) throws IOException - Throws:
IOException
-
copy
- Throws:
IOException
-
copy
public static long copy(@WillNotClose InputStream in, @WillNotClose OutputStream out, long maxBytes) throws IOException - Throws:
IOException
-
copy
- Throws:
IOException
-
close
Close given InputStream, ignoring any resulting exception. -
close
Close given InputStream, ignoring any resulting exception.- Parameters:
inputStream- the InputStream to close; may be null (in which case nothing happens)
-
close
Close given OutputStream, ignoring any resulting exception.- Parameters:
outputStream- the OutputStream to close; may be null (in which case nothing happens)
-
skipFully
Provide a skip fully method. Either skips the requested number of bytes or throws an IOException;- Parameters:
in- The input stream on which to perform the skipbytes- Number of bytes to skip- Throws:
EOFException- if we reach EOF and still need to skip more bytesIOException- if in.skip throws an IOException
-
verifyURL
-