public static void CopyToAsync(this Stream source, Stream dest, Action<CompletedArgs> completionCallback)
 {
     AsynchronousStreamCopy copy = null;
     copy = new AsynchronousStreamCopy(source, dest, args =>
     {
         copy.Dispose();
         completionCallback(args);
     });
     copy.Start();
 }
Beispiel #2
0
        public static void CopyToAsync(this Stream source, Stream dest, Action <CompletedArgs> completionCallback)
        {
            AsynchronousStreamCopy copy = null;

            copy = new AsynchronousStreamCopy(source, dest, args =>
            {
                copy.Dispose();
                completionCallback(args);
            });
            copy.Start();
        }