---
title: "SyncHandler Class"
canonical: https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_SyncHandler.htm
product: "Graphics Mill 5.5 for .NET"
---

This documentation is for the old version. [Go to the latest Graphics Mill docs](https://www.graphicsmill.com/docs/gm/)

# SyncHandler Class
 
This is a base class for all the codecs, transforms, as well as any other operations which can be run asynchronously. It contains partial implementation for [ISyncHandler](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_ISyncHandler.htm.md) interface.
 
**Namespace:** [Aurigma.GraphicsMill](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill.htm.md)
 **Assembly:** Aurigma.GraphicsMill (in Aurigma.GraphicsMill.dll)
 
## Syntax
  
```
Public Class SyncHandler _Implements ISyncHandler
```
 
```csharp
public class SyncHandler : ISyncHandler
```
 
## Remarks
  
Main aim of this class is to provide access to operation execution. Using [Abort()](https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_SyncHandler_Abort.htm.md) method you can cancel the operation execution. [Pause()](https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_SyncHandler_Pause.htm.md) and [Continue()](https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_SyncHandler_Continue.htm.md) methods are used to suspend/resume the operation.
 
This class provides asynchronous modes support. It is specified with [SynchronizationMode](https://www.graphicsmill.com/docs/gm5/P_Aurigma_GraphicsMill_SyncHandler_SynchronizationMode.htm.md). For synchronization of some thread with the operation completion, you can use [WaitForCompletion()](https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_SyncHandler_WaitForCompletion.htm.md) method.
 
A number of events can be used to provide control of the operation execution:
 
- **[Starting](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_SyncHandler_Starting.htm.md)/[Started](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_SyncHandler_Started.htm.md)**operation is starting/has been started;
- **[Progress](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_SyncHandler_Progress.htm.md)** operation is running;
- **[Paused](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_SyncHandler_Paused.htm.md)/[Continued](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_SyncHandler_Continued.htm.md)**operation was paused/resumed;
- **[Aborted](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_SyncHandler_Aborted.htm.md)** operation was cancelled;
- **[Stopping](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_SyncHandler_Stopping.htm.md)/[Stopped](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_SyncHandler_Stopped.htm.md)**operation is about to finish/fully completed.

This class also provides an implementation for [ILockable](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_ILockable.htm.md) interface, so you can use object locking functionality.
 
## Inheritance Hierarchy
  
- [System.Object](http://msdn2.microsoft.com/en-us/e5kfa45b)
    - Aurigma.GraphicsMill.SyncHandler
        - [Aurigma.GraphicsMill.UnitConverterHandler](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_UnitConverterHandler.htm.md)
        - [Aurigma.GraphicsMill.Codecs.AsfIndexer](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Codecs_AsfIndexer.htm.md)
        - [Aurigma.GraphicsMill.Codecs.FormatReader](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Codecs_FormatReader.htm.md)
        - [Aurigma.GraphicsMill.Codecs.FormatWriter](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Codecs_FormatWriter.htm.md)
        - [Aurigma.GraphicsMill.Codecs.LosslessJpegTransform](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Codecs_LosslessJpegTransform.htm.md)
 
## Thread Safety
 Static members of this type are safe for multi-threaded operations. Instance members of this type are safe for multi-threaded operations.
   
## See Also

### Reference

- [SyncHandler Members](https://www.graphicsmill.com/docs/gm5/AllMembers_T_Aurigma_GraphicsMill_SyncHandler.htm.md)
- [Aurigma.GraphicsMill Namespace](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill.htm.md)
