|
using System;
using System.Collections.Generic;
using System.Text;
using System.ComponentModel;
namespace AsyncGen
{
/// <summary>
/// Holds the progress percentage and the incremental results of an operation.
/// </summary>
/// <typeparam name="TResults">The type of the incremental results.</typeparam>
public class ProgressChangedEventArgs<TResults> : ProgressChangedEventArgs
{
/// <summary>
/// Constructor.
/// </summary>
/// <param name="progressPercentage">An <see cref="Int32"/> between 0 and 100 that indicates the progress of the operation.</param>
/// <param name="results">Incremental results of the operation.</param>
/// <param name="userState">An object that uniquely identifies a specific invocation of the operation.</param>
public ProgressChangedEventArgs(int progressPercentage, TResults results, object userState)
: base(progressPercentage, userState)
{
this.results = results;
}
/// <summary>
/// Incremental results of the operation.
/// </summary>
public TResults Results
{
get { return results; }
}
private readonly TResults results;
}
/// <summary>
/// Defines the signature for a method that handles the <c><operation>ProgressChanged</c> event.
/// </summary>
/// <typeparam name="TResults">The type of the incremental results.</typeparam>
public delegate void ProgressChangedEventHandler<TResults>(object sender, ProgressChangedEventArgs<TResults> args);
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
I got my B.Sc. in Mathematics and Computer Science from Tel Aviv University in 1997. Since then I have developed software in UNIX, Win32 and .NET. I currently live in Haifa.