The Battle for Wesnoth  1.15.0-dev
Public Types | Public Member Functions | Static Public Member Functions | Private Member Functions | List of all members
ai::candidate_action_factory Class Referenceabstract

#include <rca.hpp>

Inheritance diagram for ai::candidate_action_factory:
Inheritance graph

Public Types

typedef std::shared_ptr< candidate_action_factoryfactory_ptr
 
typedef std::map< std::string, factory_ptrfactory_map
 
typedef std::pair< const std::string, factory_ptrfactory_map_pair
 

Public Member Functions

virtual candidate_action_ptr get_new_instance (rca_context &context, const config &cfg)=0
 
 candidate_action_factory (const std::string &name)
 
virtual ~candidate_action_factory ()
 

Static Public Member Functions

static factory_mapget_list ()
 

Private Member Functions

bool is_duplicate (const std::string &name)
 

Detailed Description

Definition at line 145 of file rca.hpp.

Member Typedef Documentation

◆ factory_map

Definition at line 149 of file rca.hpp.

◆ factory_map_pair

typedef std::pair<const std::string, factory_ptr> ai::candidate_action_factory::factory_map_pair

Definition at line 150 of file rca.hpp.

◆ factory_ptr

Definition at line 148 of file rca.hpp.

Constructor & Destructor Documentation

◆ candidate_action_factory()

ai::candidate_action_factory::candidate_action_factory ( const std::string &  name)
inline

Definition at line 162 of file rca.hpp.

◆ ~candidate_action_factory()

virtual ai::candidate_action_factory::~candidate_action_factory ( )
inlinevirtual

Definition at line 171 of file rca.hpp.

Member Function Documentation

◆ get_list()

static factory_map& ai::candidate_action_factory::get_list ( )
inlinestatic

Definition at line 152 of file rca.hpp.

Referenced by ai::engine_cpp::do_parse_candidate_action_from_config().

◆ get_new_instance()

virtual candidate_action_ptr ai::candidate_action_factory::get_new_instance ( rca_context context,
const config cfg 
)
pure virtual

◆ is_duplicate()

bool ai::candidate_action_factory::is_duplicate ( const std::string &  name)
private

Definition at line 112 of file rca.cpp.

References ERR_AI_STAGE_RCA.


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