Class IOUtils

java.lang.Object
org.apache.commons.io.IOUtils
VASSAL.tools.io.IOUtils

@Deprecated(since="2020-11-14", forRemoval=true) public class IOUtils extends org.apache.commons.io.IOUtils
Deprecated, for removal: This API element is subject to removal in a future version.
Use IOUtils instead.
General I/O stream manipulation utilities. This class provides static utility methods to reduce boilerplate I/O code.
Since:
3.1.0
Author:
Joel Uckelman
  • Field Summary

    Fields inherited from class org.apache.commons.io.IOUtils

    CR, DEFAULT_BUFFER_SIZE, DIR_SEPARATOR, DIR_SEPARATOR_UNIX, DIR_SEPARATOR_WINDOWS, EMPTY_BYTE_ARRAY, EOF, LF, LINE_SEPARATOR, LINE_SEPARATOR_UNIX, LINE_SEPARATOR_WINDOWS
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    Deprecated, for removal: This API element is subject to removal in a future version.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static void
    Deprecated, for removal: This API element is subject to removal in a future version.
    use try with resources or close and catch manually
    static int
    Deprecated, for removal: This API element is subject to removal in a future version.
    static int
    copy​(InputStream in, OutputStream out, byte[] buffer)
    Deprecated, for removal: This API element is subject to removal in a future version.
    static long
    Deprecated, for removal: This API element is subject to removal in a future version.

    Methods inherited from class org.apache.commons.io.IOUtils

    buffer, buffer, buffer, buffer, buffer, buffer, buffer, buffer, byteArray, byteArray, close, close, close, close, closeQuietly, closeQuietly, closeQuietly, closeQuietly, closeQuietly, closeQuietly, closeQuietly, closeQuietly, closeQuietly, closeQuietly, consume, contentEquals, contentEquals, contentEqualsIgnoreEOL, copy, copy, copy, copy, copy, copy, copy, copy, copy, copy, copy, copy, copy, copyLarge, copyLarge, copyLarge, copyLarge, copyLarge, copyLarge, copyLarge, copyLarge, length, length, length, length, lineIterator, lineIterator, lineIterator, read, read, read, read, read, readFully, readFully, readFully, readFully, readFully, readFully, readLines, readLines, readLines, readLines, resourceToByteArray, resourceToByteArray, resourceToString, resourceToString, resourceToURL, resourceToURL, skip, skip, skip, skipFully, skipFully, skipFully, toBufferedInputStream, toBufferedInputStream, toBufferedReader, toBufferedReader, toByteArray, toByteArray, toByteArray, toByteArray, toByteArray, toByteArray, toByteArray, toByteArray, toByteArray, toByteArray, toCharArray, toCharArray, toCharArray, toCharArray, toInputStream, toInputStream, toInputStream, toInputStream, toInputStream, toInputStream, toString, toString, toString, toString, toString, toString, toString, toString, toString, toString, toString, toString, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, writeChunked, writeChunked, writeLines, writeLines, writeLines, writeLines, writer

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • IOUtils

      protected IOUtils()
      Deprecated, for removal: This API element is subject to removal in a future version.
  • Method Details

    • copy

      @Deprecated(since="2020-11-14", forRemoval=true) public static int copy(FileInputStream in, FileOutputStream out) throws IOException
      Deprecated, for removal: This API element is subject to removal in a future version.
      Copies bytes from a FileInputStream to a FileOutputStream. This method uses channels. The input file should not be written to during the copy.
      Parameters:
      in - the source
      out - the destination
      Throws:
      IOException - if one occurs while reading or writing
    • copyLarge

      @Deprecated(since="2020-11-14", forRemoval=true) public static long copyLarge(FileInputStream in, FileOutputStream out) throws IOException
      Deprecated, for removal: This API element is subject to removal in a future version.
      Copies bytes from a large (over 2GB) FileInputStream to a FileOutputStream. This method uses channels. The input file should not be written to during the copy.
      Parameters:
      in - the source
      out - the destination
      Throws:
      IOException - if one occurs while reading or writing
    • copy

      @Deprecated(since="2020-11-14", forRemoval=true) public static int copy(InputStream in, OutputStream out, byte[] buffer) throws IOException
      Deprecated, for removal: This API element is subject to removal in a future version.
      Copies bytes from an InputStream to an OutputStream via a byte buffer. This method buffers input internally, so the input stream should not be a BufferedInputStream.
      Parameters:
      in - the source
      out - the destination
      buffer - the buffer
      Returns:
      the number of bytes copied
      Throws:
      IOException - if one occurs while reading or writing
    • closeQuietly

      @Deprecated(since="2020-11-14", forRemoval=true) public static void closeQuietly(AutoCloseable c)
      Deprecated, for removal: This API element is subject to removal in a future version.
      use try with resources or close and catch manually
      Close an AutoCloseable unconditionally. Equivalent to calling c.close() when c is nonnull.
      Parameters:
      c - a (possibly null) AutoCloseable