Represents a download operation maintained by the WebCore.
Assembly: Awesomium.Core (in Awesomium.Core.dll) Version: 184.108.40.206
public class DownloadItem : ViewModel
Public Class DownloadItem Inherits ViewModel
public ref class DownloadItem : public ViewModel
Thetype exposes the following members.
Determines if the download operation can be canceled.
Cancels this download operation.
Determines if the downloaded file can be opened.
Determines if the folder containing the downloaded file can be opened.
Determines if the download operation can be removed from Downloads.
Serves as a hash function for a particular type.(Overrides ObjectGetHashCode.)
Triggers the Canceled event.
Triggers the Canceling event.
Triggers the Completed event.
Triggers the ProgressChanged event.
Triggers the PropertyChanged event.(Inherited from ViewModel.)
Attempts to open the downloaded file, launching the application that is associated with the file's type.
Attempts to open the folder containing the downloaded file.
Helper method to raise the PropertyChanged event.(Inherited from ViewModel.)
Removes a complete or canceled operation from Downloads.
Tests whether two specifiedinstances are equivalent.
Tests whether two specifiedinstances are not equal.
Gets the current downloading speed, or 0 if the operation is canceled or complete.
Gets the name of the downloaded file.
Gets if the download operation represented by this class, is currently active.
Gets if the download operation represented by this class, has been canceled.
Gets if the download operation represented by this class, has completed.
Gets the mime type of the file downloaded.
Gets the unique identifier of the view that initiated the download operation. This corresponds to Identifier.
Gets the operation's progress percentage.
Gets the number of bytes received so far.
Gets the full path to the downloaded file.
Gets the total number of bytes (may be 0 if unknown).
Gets the URL that initiated the download.
Gets the WebSession instance that controls this download operation.
Occurs when this download operation is canceled.
Occurs when this download operation is about to be canceled, as a result of calling Cancel.
Occurs when this download operation is complete.
Occurs when the status of this download operation has changed.
Occurs when the value of a property of this class, has changed.(Inherited from ViewModel.)
Repeating a Download OperationTwo instances are considered equal when the originating Url, MimeType and destination path (see SavePath), are equal. This means that if you attempt to download the same file, from the same URL and save it to the same destination, Awesomium.NET will restart the old download operation instead of creating a new one. In this scenario there will be no change to the Downloads collection after the DownloadBegin event if fired. What's more, Info will return the existing representing the previous download operation, with the values of all its members intact: For example, IsComplete may be true and ReceivedBytes will reflect the number of bytes received during the previous operation. These values will only be reset after the DownloadBegin event. This behavior is useful for the following reasons:
- If you are using the Downloads collection as a data source in an MVVM application, you wouldn't want a new item be created for a download operation that is actually being repeated.
- The new (repeated) download operation, can still be canceled at DownloadBegin by setting Cancel to true. Letting the members of the reused instance intact during DownloadBegin, allows users to cancel the operation without affecting the appearance and behavior of the visual element bound to the reused instance. When the download operation starts (immediately after DownloadBegin), the members of the reused instance will be reset allowing any bound visual element reflect that a previous download operation, is being repeated.