org.apache.commons.compress.utils
Class IOUtils

java.lang.Object
  extended by org.apache.commons.compress.utils.IOUtils

public final class IOUtils
extends Object

Utility functions

This class is immutable

Method Summary
static long copy(InputStream input, OutputStream output)
          Copies the content of a InputStream into an OutputStream.
static long copy(InputStream input, OutputStream output, int buffersize)
          Copies the content of a InputStream into an OutputStream
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

copy

public static long copy(InputStream input,
                        OutputStream output)
                 throws IOException
Copies the content of a InputStream into an OutputStream. Uses a default buffer size of 8024 bytes.

Parameters:
input - the InputStream to copy
output - the target Stream
Throws:
IOException - if an error occurs

copy

public static long copy(InputStream input,
                        OutputStream output,
                        int buffersize)
                 throws IOException
Copies the content of a InputStream into an OutputStream

Parameters:
input - the InputStream to copy
output - the target Stream
buffersize - the buffer size to use
Throws:
IOException - if an error occurs


Copyright © 2010 The Apache Software Foundation. All Rights Reserved.