Elements  6.2
A C++ base framework for the Euclid Software.
Public Types | Public Member Functions | Private Attributes | List of all members
Elements::Examples::PiCalculator Class Reference

#include <PiCalculator.h>

Public Types

typedef void(* show_result_callback_type) (double pi)
 

Public Member Functions

 PiCalculator ()=default
 
void calculate (unsigned int terms)
 
void setShowResultCallback (show_result_callback_type f)
 

Private Attributes

show_result_callback_type m_show_result_callback {}
 

Detailed Description

Definition at line 32 of file PiCalculator.h.

Member Typedef Documentation

◆ show_result_callback_type

typedef void(* Elements::Examples::PiCalculator::show_result_callback_type) (double pi)

Definition at line 37 of file PiCalculator.h.

Constructor & Destructor Documentation

◆ PiCalculator()

Elements::Examples::PiCalculator::PiCalculator ( )
default

Member Function Documentation

◆ calculate()

void Elements::Examples::PiCalculator::calculate ( unsigned int  terms)

Definition at line 23 of file PiCalculator.cpp.

References m_show_result_callback, and Elements::Kernel::Units::pi.

◆ setShowResultCallback()

void Elements::Examples::PiCalculator::setShowResultCallback ( show_result_callback_type  f)

Definition at line 41 of file PiCalculator.cpp.

References m_show_result_callback.

Member Data Documentation

◆ m_show_result_callback

show_result_callback_type Elements::Examples::PiCalculator::m_show_result_callback {}
private

Definition at line 41 of file PiCalculator.h.

Referenced by calculate(), and setShowResultCallback().


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