private void RaiseProgressEvent() { // Raise the event by using the () operator. if (ProgressEvent != null) { PumpProgressEventArgs args = new PumpProgressEventArgs(); args.BytesRead = BytesRead; args.BytesWritten = BytesWritten; args.SourcePosition = InputStream.Position; args.DestinationPosition = OutputStream.Position; ProgressEvent(this, args); } }
private void RaiseProgressEvent() { // Raise the event by using the () operator. if (ProgressEvent == null) { return; } PumpProgressEventArgs args = new PumpProgressEventArgs { BytesRead = BytesRead, BytesWritten = BytesWritten, SourcePosition = InputStream.Position, DestinationPosition = OutputStream.Position }; ProgressEvent(this, args); }