Class ProgressEventHandlerInfo

Class ProgressEventHandlerInfo

Namespace: Aspose.Imaging.ProgressManagement
Assembly: Aspose.Imaging.dll (25.2.0)

This class represents information about image load/save/export operations progress, that can be used in external application to show conversion progress to end user

public class ProgressEventHandlerInfo

Inheritance

objectProgressEventHandlerInfo

Inherited Members

object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Examples

The following example shows how to print information about progress events for load/export operations.```csharp [C#]

                                                                                                             public void Test3460()
                                                                                                             {
                                                                                                                 string dir = "c:\\aspose.imaging\\net\\issues\\3460";
                                                                                                                 string fileName = System.IO.Path.Combine(dir, "big.png");

                                                                                                                 // Example of use of separate operation progress event handlers for load/export operations
                                                                                                                 using (var image = Aspose.Imaging.Image.Load(fileName, new Aspose.Imaging.LoadOptions { ProgressEventHandler = ProgressCallback }))
                                                                                                                 {
                                                                                                                     image.Save(fileName + ".psd",
                                                                                                                                new Aspose.Imaging.ImageOptions.PsdOptions() { ProgressEventHandler = ExportProgressCallback });
                                                                                                                 }
                                                                                                             }

                                                                                                             private void ProgressCallback(Aspose.Imaging.ProgressManagement.ProgressEventHandlerInfo info)
                                                                                                             {
                                                                                                                 System.Console.WriteLine("{0} : {1}/{2}", info.EventType, info.Value, info.MaxValue);
                                                                                                             }

                                                                                                             private void ExportProgressCallback(Aspose.Imaging.ProgressManagement.ProgressEventHandlerInfo info)
                                                                                                             {
                                                                                                                 System.Console.WriteLine("Export event {0} : {1}/{2}", info.EventType, info.Value, info.MaxValue);
                                                                                                             }

                                                                                                             // The STDOUT log may look like this:
                                                                                                             //Initialization : 1/4
                                                                                                             //PreProcessing : 2/4
                                                                                                             //Processing : 3/4
                                                                                                             //Finalization : 4/4
                                                                                                             //Export event Initialization : 1/4
                                                                                                             //Export event PreProcessing : 2/4
                                                                                                             //Export event Processing : 3/4
                                                                                                             //Export event RelativeProgress : 1/1
                                                                                                             //RelativeProgress : 1/1
                                                                                                             //Export event Finalization : 4/4

## Properties

### <a id="Aspose_Imaging_ProgressManagement_ProgressEventHandlerInfo_Description"></a> Description

Gets the description of the event

```csharp
public string Description { get; }

Property Value

string

EventType

Gets the type of the event.

public EventType EventType { get; }

Property Value

EventType

MaxValue

Gets the upper progress value limit.

public int MaxValue { get; }

Property Value

int

Value

Gets current progress value.

public int Value { get; }

Property Value

int