Samchon Framework for CPP  1.0.0
samchon::library::ProgressEvent Class Reference

Event representing a progress. More...

#include <ProgressEvent.hpp>

Collaboration diagram for samchon::library::ProgressEvent:

Public Member Functions

 ProgressEvent (EventDispatcher *source, size_t numerator, size_t denominator)
 Construct from source and progress. More...
auto getNumerator () const -> size_t
 Get numerator, number of current progress. More...
auto getDenominator () const -> size_t
 Get denominator, number of total progress. More...
auto getPercent () const -> double
 Get percentage of the progress. More...
- Public Member Functions inherited from samchon::library::Event
 Event (EventDispatcher *source, int type)
 Construct from source and type. More...
auto getSource () const -> EventDispatcher *
 Get source of the Event. More...
auto getType () const -> int
 Get type of the Event. More...

Protected Attributes

size_t numerator
 The number of current progress. More...
size_t denominator
 The number of total progress. More...
- Protected Attributes inherited from samchon::library::Event
 Source of the event. More...
int type
 Type of the event. More...

Detailed Description

Event representing a progress.


Definition at line 15 of file ProgressEvent.hpp.

Constructor & Destructor Documentation

samchon::library::ProgressEvent::ProgressEvent ( EventDispatcher source,
size_t  numerator,
size_t  denominator 

Construct from source and progress.

sourceSource of the event; who made the event
numeratorThe number of current progress
denominatorThe number of total progress
exceptiondenominator is zero

Definition at line 55 of file ProgressEvent.hpp.

References denominator, and numerator.

Member Function Documentation

auto samchon::library::ProgressEvent::getNumerator ( ) const -> size_t

Get numerator, number of current progress.

Definition at line 66 of file ProgressEvent.hpp.

References numerator.

auto samchon::library::ProgressEvent::getDenominator ( ) const -> size_t

Get denominator, number of total progress.

Definition at line 74 of file ProgressEvent.hpp.

References denominator.

auto samchon::library::ProgressEvent::getPercent ( ) const -> double

Get percentage of the progress.

Definition at line 82 of file ProgressEvent.hpp.

Member Data Documentation

size_t samchon::library::ProgressEvent::numerator

The number of current progress.

Definition at line 32 of file ProgressEvent.hpp.

Referenced by getNumerator(), and ProgressEvent().

size_t samchon::library::ProgressEvent::denominator

The number of total progress.

denominator cannot be zero

Definition at line 38 of file ProgressEvent.hpp.

Referenced by getDenominator(), and ProgressEvent().

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