Exemple #1
0
        /// <summary>
        /// Efficiently pumps data from a sparse stream to another stream.
        /// </summary>
        /// <param name="inStream">The stream to pump from.</param>
        /// <param name="outStream">The stream to pump to.</param>
        /// <param name="chunkSize">The smallest sequence of zero bytes that will be skipped when writing to <paramref name="outStream"/></param>
        /// <remarks><paramref name="outStream"/> must support seeking.</remarks>
        public static void Pump(Stream inStream, Stream outStream, int chunkSize)
        {
            StreamPump pump = new StreamPump(inStream, outStream, chunkSize);

            pump.Run();
        }
 /// <summary>
 /// Efficiently pumps data from a sparse stream to another stream.
 /// </summary>
 /// <param name="inStream">The stream to pump from.</param>
 /// <param name="outStream">The stream to pump to.</param>
 /// <param name="chunkSize">The smallest sequence of zero bytes that will be skipped when writing to <paramref name="outStream"/></param>
 /// <remarks><paramref name="outStream"/> must support seeking.</remarks>
 public static void Pump(Stream inStream, Stream outStream, int chunkSize)
 {
     StreamPump pump = new StreamPump(inStream, outStream, chunkSize);
     pump.Run();
 }