1 <?xml version="1.0" encoding="utf-8"?><doc>
3 <name>System.ComponentModel.EventBasedAsync</name>
6 <member name="T:System.ComponentModel.BackgroundWorker">
7 <summary>Executes an operation on a separate thread.</summary>
9 <member name="M:System.ComponentModel.BackgroundWorker.#ctor">
10 <summary>Initializes a new instance of the <see cref="T:System.ComponentModel.BackgroundWorker"></see> class.</summary>
12 <member name="M:System.ComponentModel.BackgroundWorker.CancelAsync">
13 <summary>Requests cancellation of a pending background operation.</summary>
14 <exception cref="T:System.InvalidOperationException"><see cref="System.ComponentModel.BackgroundWorker.WorkerSupportsCancellation"></see> is <see langword="false"></see>.</exception>
16 <member name="P:System.ComponentModel.BackgroundWorker.CancellationPending">
17 <summary>Gets a value indicating whether the application has requested cancellation of a background operation.</summary>
18 <returns><see langword="true"></see> if the application has requested cancellation of a background operation; otherwise, <see langword="false"></see>. The default is <see langword="false"></see>.</returns>
20 <member name="M:System.ComponentModel.BackgroundWorker.Dispose">
23 <member name="M:System.ComponentModel.BackgroundWorker.Dispose(System.Boolean)">
24 <param name="disposing"></param>
26 <member name="E:System.ComponentModel.BackgroundWorker.DoWork">
27 <summary>Occurs when <see cref="M:System.ComponentModel.BackgroundWorker.RunWorkerAsync"></see> is called.</summary>
29 <member name="P:System.ComponentModel.BackgroundWorker.IsBusy">
30 <summary>Gets a value indicating whether the <see cref="T:System.ComponentModel.BackgroundWorker"></see> is running an asynchronous operation.</summary>
31 <returns><see langword="true"></see>, if the <see cref="T:System.ComponentModel.BackgroundWorker"></see> is running an asynchronous operation; otherwise, <see langword="false"></see>.</returns>
33 <member name="M:System.ComponentModel.BackgroundWorker.OnDoWork(System.ComponentModel.DoWorkEventArgs)">
34 <summary>Raises the <see cref="E:System.ComponentModel.BackgroundWorker.DoWork"></see> event.</summary>
35 <param name="e">An <see cref="T:System.EventArgs"></see> that contains the event data.</param>
37 <member name="M:System.ComponentModel.BackgroundWorker.OnProgressChanged(System.ComponentModel.ProgressChangedEventArgs)">
38 <summary>Raises the <see cref="E:System.ComponentModel.BackgroundWorker.ProgressChanged"></see> event.</summary>
39 <param name="e">An <see cref="T:System.EventArgs"></see> that contains the event data.</param>
41 <member name="M:System.ComponentModel.BackgroundWorker.OnRunWorkerCompleted(System.ComponentModel.RunWorkerCompletedEventArgs)">
42 <summary>Raises the <see cref="E:System.ComponentModel.BackgroundWorker.RunWorkerCompleted"></see> event.</summary>
43 <param name="e">An <see cref="T:System.EventArgs"></see> that contains the event data.</param>
45 <member name="E:System.ComponentModel.BackgroundWorker.ProgressChanged">
46 <summary>Occurs when <see cref="M:System.ComponentModel.BackgroundWorker.ReportProgress(System.Int32)"></see> is called.</summary>
48 <member name="M:System.ComponentModel.BackgroundWorker.ReportProgress(System.Int32)">
49 <summary>Raises the <see cref="E:System.ComponentModel.BackgroundWorker.ProgressChanged"></see> event.</summary>
50 <param name="percentProgress">The percentage, from 0 to 100, of the background operation that is complete.</param>
51 <exception cref="T:System.InvalidOperationException">The <see cref="System.ComponentModel.BackgroundWorker.WorkerReportsProgress"></see> property is set to <see langword="false"></see>.</exception>
53 <member name="M:System.ComponentModel.BackgroundWorker.ReportProgress(System.Int32,System.Object)">
54 <summary>Raises the <see cref="E:System.ComponentModel.BackgroundWorker.ProgressChanged"></see> event.</summary>
55 <param name="percentProgress">The percentage, from 0 to 100, of the background operation that is complete.</param>
56 <param name="userState">The state object passed to <see cref="M:System.ComponentModel.BackgroundWorker.RunWorkerAsync(System.Object)"></see>.</param>
57 <exception cref="T:System.InvalidOperationException">The <see cref="System.ComponentModel.BackgroundWorker.WorkerReportsProgress"></see> property is set to <see langword="false"></see>.</exception>
59 <member name="M:System.ComponentModel.BackgroundWorker.RunWorkerAsync">
60 <summary>Starts execution of a background operation.</summary>
61 <exception cref="T:System.InvalidOperationException"><see cref="System.ComponentModel.BackgroundWorker.IsBusy"></see> is <see langword="true"></see>.</exception>
63 <member name="M:System.ComponentModel.BackgroundWorker.RunWorkerAsync(System.Object)">
64 <summary>Starts execution of a background operation.</summary>
65 <param name="argument">A parameter for use by the background operation to be executed in the <see cref="E:System.ComponentModel.BackgroundWorker.DoWork"></see> event handler.</param>
66 <exception cref="T:System.InvalidOperationException"><see cref="System.ComponentModel.BackgroundWorker.IsBusy"></see> is <see langword="true"></see>.</exception>
68 <member name="E:System.ComponentModel.BackgroundWorker.RunWorkerCompleted">
69 <summary>Occurs when the background operation has completed, has been canceled, or has raised an exception.</summary>
71 <member name="P:System.ComponentModel.BackgroundWorker.WorkerReportsProgress">
72 <summary>Gets or sets a value indicating whether the <see cref="T:System.ComponentModel.BackgroundWorker"></see> can report progress updates.</summary>
73 <returns><see langword="true"></see> if the <see cref="T:System.ComponentModel.BackgroundWorker"></see> supports progress updates; otherwise <see langword="false"></see>. The default is <see langword="false"></see>.</returns>
75 <member name="P:System.ComponentModel.BackgroundWorker.WorkerSupportsCancellation">
76 <summary>Gets or sets a value indicating whether the <see cref="T:System.ComponentModel.BackgroundWorker"></see> supports asynchronous cancellation.</summary>
77 <returns><see langword="true"></see> if the <see cref="T:System.ComponentModel.BackgroundWorker"></see> supports cancellation; otherwise <see langword="false"></see>. The default is <see langword="false"></see>.</returns>
79 <member name="T:System.ComponentModel.AsyncOperationManager">
80 <summary>Provides concurrency management for classes that support asynchronous method calls. This class cannot be inherited.</summary>
82 <member name="M:System.ComponentModel.AsyncOperationManager.CreateOperation(System.Object)">
83 <summary>Returns an <see cref="T:System.ComponentModel.AsyncOperation"></see> for tracking the duration of a particular asynchronous operation.</summary>
84 <param name="userSuppliedState">An object used to associate a piece of client state, such as a task ID, with a particular asynchronous operation.</param>
85 <returns>An <see cref="T:System.ComponentModel.AsyncOperation"></see> that you can use to track the duration of an asynchronous method invocation.</returns>
87 <member name="P:System.ComponentModel.AsyncOperationManager.SynchronizationContext">
88 <summary>Gets or sets the synchronization context for the asynchronous operation.</summary>
89 <returns>The synchronization context for the asynchronous operation.</returns>
91 <member name="T:System.ComponentModel.AsyncOperation">
92 <summary>Tracks the lifetime of an asynchronous operation.</summary>
94 <member name="M:System.ComponentModel.AsyncOperation.Finalize">
95 <summary>Finalizes the asynchronous operation.</summary>
97 <member name="M:System.ComponentModel.AsyncOperation.OperationCompleted">
98 <summary>Ends the lifetime of an asynchronous operation.</summary>
99 <exception cref="T:System.InvalidOperationException"><see cref="System.ComponentModel.AsyncOperation.OperationCompleted"></see> has been called previously for this task.</exception>
101 <member name="M:System.ComponentModel.AsyncOperation.Post(System.Threading.SendOrPostCallback,System.Object)">
102 <summary>Invokes a delegate on the thread or context appropriate for the application model.</summary>
103 <param name="d">A <see cref="T:System.Threading.SendOrPostCallback"></see> object that wraps the delegate to be called when the operation ends.</param>
104 <param name="arg">An argument for the delegate contained in the d parameter.</param>
105 <exception cref="T:System.InvalidOperationException">The <see cref="System.ComponentModel.AsyncOperation.PostOperationCompleted(System.Threading.SendOrPostCallback,System.Object)"></see> method has been called previously for this task.</exception>
106 <exception cref="T:System.ArgumentNullException"><paramref name="d">d</paramref> is <see langword="null"></see>.</exception>
108 <member name="M:System.ComponentModel.AsyncOperation.PostOperationCompleted(System.Threading.SendOrPostCallback,System.Object)">
109 <summary>Ends the lifetime of an asynchronous operation.</summary>
110 <param name="d">A <see cref="T:System.Threading.SendOrPostCallback"></see> object that wraps the delegate to be called when the operation ends.</param>
111 <param name="arg">An argument for the delegate contained in the d parameter.</param>
112 <exception cref="T:System.InvalidOperationException"><see cref="System.ComponentModel.AsyncOperation.OperationCompleted"></see> has been called previously for this task.</exception>
113 <exception cref="T:System.ArgumentNullException"><paramref name="d">d</paramref> is <see langword="null"></see>.</exception>
115 <member name="P:System.ComponentModel.AsyncOperation.SynchronizationContext">
116 <summary>Gets the <see cref="T:System.Threading.SynchronizationContext"></see> object that was passed to the constructor.</summary>
117 <returns>The <see cref="T:System.Threading.SynchronizationContext"></see> object that was passed to the constructor.</returns>
119 <member name="P:System.ComponentModel.AsyncOperation.UserSuppliedState">
120 <summary>Gets or sets an object used to uniquely identify an asynchronous operation.</summary>
121 <returns>The state object passed to the asynchronous method invocation.</returns>
123 <member name="T:System.ComponentModel.AsyncCompletedEventHandler">
124 <summary>Represents the method that will handle the MethodName<see langword="Completed"></see> event of an asynchronous operation.</summary>
125 <param name="sender">The source of the event.</param>
126 <param name="e">An <see cref="T:System.ComponentModel.AsyncCompletedEventArgs"></see> that contains the event data.</param>
128 <member name="T:System.ComponentModel.AsyncCompletedEventArgs">
129 <summary>Provides data for the MethodName<see langword="Completed"></see> event.</summary>
131 <member name="M:System.ComponentModel.AsyncCompletedEventArgs.#ctor(System.Exception,System.Boolean,System.Object)">
132 <summary>Initializes a new instance of the <see cref="T:System.ComponentModel.AsyncCompletedEventArgs"></see> class.</summary>
133 <param name="error">Any error that occurred during the asynchronous operation.</param>
134 <param name="cancelled">A value indicating whether the asynchronous operation was canceled.</param>
135 <param name="userState">The optional user-supplied state object passed to the <see cref="M:System.ComponentModel.BackgroundWorker.RunWorkerAsync(System.Object)"></see> method.</param>
137 <member name="P:System.ComponentModel.AsyncCompletedEventArgs.Cancelled">
138 <summary>Gets a value indicating whether an asynchronous operation has been canceled.</summary>
139 <returns><see langword="true"></see> if the background operation has been canceled; otherwise <see langword="false"></see>. The default is <see langword="false"></see>.</returns>
141 <member name="P:System.ComponentModel.AsyncCompletedEventArgs.Error">
142 <summary>Gets a value indicating which error occurred during an asynchronous operation.</summary>
143 <returns>An <see cref="T:System.Exception"></see> instance, if an error occurred during an asynchronous operation; otherwise <see langword="null"></see>.</returns>
145 <member name="M:System.ComponentModel.AsyncCompletedEventArgs.RaiseExceptionIfNecessary">
146 <summary>Raises a user-supplied exception if an asynchronous operation failed.</summary>
147 <exception cref="T:System.InvalidOperationException">The <see cref="System.ComponentModel.AsyncCompletedEventArgs.Cancelled"></see> property is <see langword="true"></see>.</exception>
148 <exception cref="T:System.Reflection.TargetInvocationException">The <see cref="System.ComponentModel.AsyncCompletedEventArgs.Error"></see> property has been set by the asynchronous operation. The <see cref="System.Exception.InnerException"></see> property holds a reference to <see cref="System.ComponentModel.AsyncCompletedEventArgs.Error"></see>.</exception>
150 <member name="P:System.ComponentModel.AsyncCompletedEventArgs.UserState">
151 <summary>Gets the unique identifier for the asynchronous task.</summary>
152 <returns>An object reference that uniquely identifies the asynchronous task; otherwise, <see langword="null"></see> if no value has been set.</returns>
154 <member name="T:System.ComponentModel.ProgressChangedEventHandler">
155 <summary>Represents the method that will handle the <see cref="E:System.ComponentModel.BackgroundWorker.ProgressChanged"></see> event of the <see cref="T:System.ComponentModel.BackgroundWorker"></see> class. This class cannot be inherited.</summary>
156 <param name="sender">The source of the event.</param>
157 <param name="e">A <see cref="T:System.ComponentModel.ProgressChangedEventArgs"></see> that contains the event data.</param>
159 <member name="T:System.ComponentModel.ProgressChangedEventArgs">
160 <summary>Provides data for the <see cref="E:System.ComponentModel.BackgroundWorker.ProgressChanged"></see> event.</summary>
162 <member name="M:System.ComponentModel.ProgressChangedEventArgs.#ctor(System.Int32,System.Object)">
163 <summary>Initializes a new instance of the <see cref="T:System.ComponentModel.ProgressChangedEventArgs"></see> class.</summary>
164 <param name="progressPercentage">The percentage of an asynchronous task that has been completed.</param>
165 <param name="userState">A unique user state.</param>
167 <member name="P:System.ComponentModel.ProgressChangedEventArgs.ProgressPercentage">
168 <summary>Gets the asynchronous task progress percentage.</summary>
169 <returns>A percentage value indicating the asynchronous task progress.</returns>
171 <member name="P:System.ComponentModel.ProgressChangedEventArgs.UserState">
172 <summary>Gets a unique user state.</summary>
173 <returns>A unique <see cref="T:System.Object"></see> indicating the user state.</returns>
175 <member name="T:System.ComponentModel.RunWorkerCompletedEventHandler">
176 <summary>Represents the method that will handle the <see cref="E:System.ComponentModel.BackgroundWorker.RunWorkerCompleted"></see> event of a <see cref="T:System.ComponentModel.BackgroundWorker"></see> class.</summary>
177 <param name="sender">The source of the event.</param>
178 <param name="e">A <see cref="T:System.ComponentModel.RunWorkerCompletedEventArgs"></see> that contains the event data.</param>
180 <member name="T:System.ComponentModel.RunWorkerCompletedEventArgs">
181 <summary>Provides data for the MethodName<see langword="Completed"></see> event.</summary>
183 <member name="M:System.ComponentModel.RunWorkerCompletedEventArgs.#ctor(System.Object,System.Exception,System.Boolean)">
184 <summary>Initializes a new instance of the <see cref="T:System.ComponentModel.RunWorkerCompletedEventArgs"></see> class.</summary>
185 <param name="result">The result of an asynchronous operation.</param>
186 <param name="error">Any error that occurred during the asynchronous operation.</param>
187 <param name="cancelled">A value indicating whether the asynchronous operation was canceled.</param>
189 <member name="P:System.ComponentModel.RunWorkerCompletedEventArgs.Result">
190 <summary>Gets a value that represents the result of an asynchronous operation.</summary>
191 <returns>An <see cref="T:System.Object"></see> representing the result of an asynchronous operation.</returns>
192 <exception cref="T:System.Reflection.TargetInvocationException"><see cref="System.ComponentModel.AsyncCompletedEventArgs.Error"></see> is not <see langword="null"></see>. The <see cref="System.Exception.InnerException"></see> property holds a reference to <see cref="System.ComponentModel.AsyncCompletedEventArgs.Error"></see>.</exception>
193 <exception cref="T:System.InvalidOperationException"><see cref="System.ComponentModel.AsyncCompletedEventArgs.Cancelled"></see> is <see langword="true"></see>.</exception>
195 <member name="P:System.ComponentModel.RunWorkerCompletedEventArgs.UserState">
196 <summary>Gets a value that represents the user state.</summary>
197 <returns>An <see cref="T:System.Object"></see> representing the user state.</returns>
199 <member name="T:System.ComponentModel.DoWorkEventHandler">
200 <summary>Represents the method that will handle the <see cref="E:System.ComponentModel.BackgroundWorker.DoWork"></see> event. This class cannot be inherited.</summary>
201 <param name="sender">The source of the event.</param>
202 <param name="e">A <see cref="T:System.ComponentModel.DoWorkEventArgs"></see> that contains the event data.</param>
204 <member name="T:System.ComponentModel.DoWorkEventArgs">
205 <summary>Provides data for the <see cref="E:System.ComponentModel.BackgroundWorker.DoWork"></see> event handler.</summary>
207 <member name="M:System.ComponentModel.DoWorkEventArgs.#ctor(System.Object)">
208 <summary>Initializes a new instance of the <see cref="T:System.ComponentModel.DoWorkEventArgs"></see> class.</summary>
209 <param name="argument">Specifies an argument for an asynchronous operation.</param>
211 <member name="P:System.ComponentModel.DoWorkEventArgs.Argument">
212 <summary>Gets a value that represents the argument of an asynchronous operation.</summary>
213 <returns>An <see cref="T:System.Object"></see> representing the argument of an asynchronous operation.</returns>
215 <member name="P:System.ComponentModel.DoWorkEventArgs.Cancel">
218 <member name="P:System.ComponentModel.DoWorkEventArgs.Result">
219 <summary>Gets or sets a value that represents the result of an asynchronous operation.</summary>
220 <returns>An <see cref="T:System.Object"></see> representing the result of an asynchronous operation.</returns>