Class ProgressMonitor
ProgressMonitor is an interface that an application can use to indicate the progress of a lengthy operation (such as PDFDoc.Save()).
ProgressMonitor has a range and a current position. The range represents the entire duration of the operation, and the current position represents the progress the application has made toward completing the operation.
Implements
Inherited Members
Namespace: pdftron.Common
Assembly: PDFTronDotNet.dll
Syntax
public abstract class ProgressMonitor : IDisposable
Constructors
ProgressMonitor()
Instantiates a default ProgressMonitor object
Declaration
public ProgressMonitor()
Methods
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
Declaration
public void Dispose()
Dispose(bool)
Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
bool | disposing |
~ProgressMonitor()
Declaration
protected ~ProgressMonitor()
GetPos()
Get the current position of the progress monitor.
Declaration
public abstract int GetPos()
Returns
Type | Description |
---|---|
int | position of the progress monitor |
GetRange(ref int, ref int)
get upper and lower limit of the progress monitor
Declaration
public abstract void GetRange(ref int start, ref int finish)
Parameters
Type | Name | Description |
---|---|---|
int | start | lower limit of the range |
int | finish | upper limit of the range |
OffsetPos(int)
Advances the current position of a progress monitor by a specified increment and redraws the bar to reflect the new position.
Declaration
public abstract int OffsetPos(int offset)
Parameters
Type | Name | Description |
---|---|---|
int | offset | advances the current position of a progress bar control by a specified increment and redraws the bar to reflect the new position. |
Returns
Type | Description |
---|---|
int | the previous position of the progress monitor |
SetPos(int)
Set the current position for a progress monitor and redraws the bar to reflect the new ranges.
Declaration
public abstract int SetPos(int pos)
Parameters
Type | Name | Description |
---|---|---|
int | pos | the new position of the progress monitor |
Returns
Type | Description |
---|---|
int | the previous position of the progress monitor |
SetRange(int, int)
set upper and lower limit of the progress monitor
Declaration
public abstract void SetRange(int start, int finish)
Parameters
Type | Name | Description |
---|---|---|
int | start | lower limit of the range |
int | finish | upper limit of the range |
SetStep(int)
Specifies the step increment for a progress bar monitor.
Declaration
public abstract int SetStep(int nstep)
Parameters
Type | Name | Description |
---|---|---|
int | nstep | new step increment. |
Returns
Type | Description |
---|---|
int | the previous step increment |
StepIt()
Advances the current position for a progress monitor by the step increment (see SetStep) and redraws the monitor to reflect the new position.
Declaration
public abstract int StepIt()
Returns
Type | Description |
---|---|
int | new postion after stepping |