| ## Public API Reference

- Main Page
- Modules
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# csProgressPulse Class Reference

The csProgressPulse class provides a simple twirling textual cursor built out of the characters '-', '\', '|', and '/'. More...

`#include <csutil/csppulse.h>`

List of all members.

## Public Member Functions
| csProgressPulse (iConsoleOutput *)
| Constructs a new progress pulse.
void | Erase ()
| Erase the pulse indicator.
void | Reset ()
| Reset the state and erase the indicator.
void | Step ()
| Increment the progress by one pulse.
| ~csProgressPulse ()
| Destroys the progress pulse.

## Detailed Description

The csProgressPulse class provides a simple twirling textual cursor built out of the characters '-', '\', '|', and '/'.

This type of functionality is generally used as a sort of pulse beat during indeterminately lengthy computational operations in order to let the user know that progress is being made and that the program is not hanging. By default, the pulse beat is presented to the user by passing CS_MSG_INITIALIZATION to the system print function. This setting may be changed with the SetMessageType() method. To animate the pulse object, call the Step() method each time a unit of work has been completed. At each step a backspace (\b) followed by one of the pulse characters (-, \, |, or /) is printed, except for the very first step, in which case the backspace is omitted. Erase() clears the pulse, if necessary, by printing a backspace, followed by a space (' '), followed by one more backspace. Reset() erases the pulse and then resets the state. Erase() is called automatically by the destructor.

Definition at line 47 of file csppulse.h.

## Constructor & Destructor Documentation

csProgressPulse::csProgressPulse | ( | iConsoleOutput * |  | ) |

Constructs a new progress pulse.

csProgressPulse::~csProgressPulse | ( |  | ) |

Destroys the progress pulse.

## Member Function Documentation

void csProgressPulse::Erase | ( |  | ) |

Erase the pulse indicator.

void csProgressPulse::Reset | ( |  | ) |

Reset the state and erase the indicator.

void csProgressPulse::Step | ( |  | ) |

Increment the progress by one pulse.

The documentation for this class was generated from the following file:

- csutil/csppulse.h