The Battle for Wesnoth  1.17.0-dev
Classes | Public Types | Public Member Functions | Private Attributes | List of all members
reports Class Reference

#include <reports.hpp>


class  context
struct  generator

Public Types

using generator_function = std::function< config(reports::context &)>
typedef std::map< std::string, std::shared_ptr< reports::generator > > dynamic_report_generators

Public Member Functions

void register_generator (const std::string &name, generator *)
config generate_report (const std::string &name, context &ct, bool only_static=false)
const std::set< std::string > & report_list ()

Private Attributes

std::set< std::string > all_reports_
dynamic_report_generators dynamic_generators_

Detailed Description

Definition at line 42 of file reports.hpp.

Member Typedef Documentation

◆ dynamic_report_generators

typedef std::map<std::string, std::shared_ptr<reports::generator> > reports::dynamic_report_generators

Definition at line 83 of file reports.hpp.

◆ generator_function

Definition at line 81 of file reports.hpp.

Member Function Documentation

◆ generate_report()

config reports::generate_report ( const std::string &  name,
reports::context rc,
bool  only_static = false 

Definition at line 1759 of file reports.cpp.

References i, and static_generators.

Referenced by display::refresh_report().

◆ register_generator()

void reports::register_generator ( const std::string &  name,
reports::generator g 

Definition at line 1754 of file reports.cpp.

◆ report_list()

const std::set< std::string > & reports::report_list ( )

Definition at line 1772 of file reports.cpp.

References static_generators.

Referenced by game_display::draw_sidebar().

Member Data Documentation

◆ all_reports_

std::set<std::string> reports::all_reports_

Definition at line 87 of file reports.hpp.

◆ dynamic_generators_

dynamic_report_generators reports::dynamic_generators_

Definition at line 89 of file reports.hpp.

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