Class ProgressStatePS
- Namespace
- SunamoPS._public.SunamoInterfaces.Interfaces
- Assembly
- SunamoPS.dll
Tracks progress state for batch operations with event-based notifications.
public class ProgressStatePS
- Inheritance
-
ProgressStatePS
- Inherited Members
- Extension Methods
Properties
Count
Gets or sets the current item count.
public int Count { get; set; }
Property Value
IsRegistered
Gets or sets whether this progress state has registered event handlers.
public bool IsRegistered { get; set; }
Property Value
Methods
Init(Action<int>, Action<int>, Action)
Initializes the progress state with event handlers.
public void Init(Action<int> overallItems, Action<int> anotherItem, Action writeProgressBarEnd)
Parameters
overallItemsAction<int>Handler called with total item count.
anotherItemAction<int>Handler called when another item is processed.
writeProgressBarEndActionHandler called when progress bar should end.
OnAnotherItem()
Increments count and raises the AnotherItem event.
public void OnAnotherItem()
OnAnotherItem(int)
Raises the AnotherItem event with the specified count.
public void OnAnotherItem(int count)
Parameters
countintCurrent item count.
OnOverallItems(int)
Resets the count and raises the OverallItems event.
public void OnOverallItems(int totalCount)
Parameters
totalCountintTotal number of items to process.
OnWriteProgressBarEnd()
Raises the WriteProgressBarEnd event.
public void OnWriteProgressBarEnd()
Events
AnotherItem
Event raised when another item is processed.
public event Action<int>? AnotherItem
Event Type
OverallItems
Event raised to set the total number of items.
public event Action<int>? OverallItems
Event Type
WriteProgressBarEnd
Event raised when the progress bar should be closed.
public event Action? WriteProgressBarEnd