#include <engine.hpp>
Public Member Functions | |
engine (readonly_context &context, const config &cfg) | |
virtual | ~engine () |
virtual bool | is_ok () const |
virtual void | do_parse_aspect_from_config (const config &cfg, const std::string &id, std::back_insert_iterator< std::vector< aspect_ptr >> b) |
virtual void | do_parse_candidate_action_from_config (rca_context &context, const config &cfg, std::back_insert_iterator< std::vector< candidate_action_ptr >> b) |
virtual void | do_parse_goal_from_config (const config &cfg, std::back_insert_iterator< std::vector< goal_ptr >> b) |
virtual void | do_parse_engine_from_config (const config &cfg, std::back_insert_iterator< std::vector< engine_ptr >> b) |
virtual void | do_parse_stage_from_config (ai_context &context, const config &cfg, std::back_insert_iterator< std::vector< stage_ptr >> b) |
virtual std::string | evaluate (const std::string &str) |
readonly_context & | get_readonly_context () |
virtual void | set_ai_context (ai_context_ptr context) |
set ai context (which is not available during early initialization) More... | |
virtual ai_context_ptr | get_ai_context () |
virtual config | to_config () const |
serialize More... | |
virtual std::string | get_id () const |
virtual std::string | get_engine () const |
virtual std::string | get_name () const |
Public Member Functions inherited from ai::component | |
component () | |
virtual | ~component () |
virtual component * | get_child (const path_element &child) |
virtual std::vector< component * > | get_children (const std::string &type) |
virtual std::vector< std::string > | get_children_types () |
virtual bool | change_child (const path_element &child, const config &cfg) |
virtual bool | add_child (const path_element &child, const config &cfg) |
virtual bool | delete_child (const path_element &child) |
property_handler_map & | property_handlers () |
Static Public Member Functions | |
static void | parse_aspect_from_config (readonly_context &context, const config &cfg, const std::string &id, std::back_insert_iterator< std::vector< aspect_ptr >> b) |
static void | parse_goal_from_config (readonly_context &context, const config &cfg, std::back_insert_iterator< std::vector< goal_ptr >> b) |
static void | parse_candidate_action_from_config (rca_context &context, const config &cfg, std::back_insert_iterator< std::vector< candidate_action_ptr >> b) |
static void | parse_engine_from_config (readonly_context &context, const config &cfg, std::back_insert_iterator< std::vector< engine_ptr >> b) |
static void | parse_stage_from_config (ai_context &context, const config &cfg, std::back_insert_iterator< std::vector< stage_ptr >> b) |
Protected Attributes | |
readonly_context & | ai_ |
ai_context_ptr | ai_context_ |
std::string | engine_ |
name of the engine which has created this engine More... | |
std::string | id_ |
std::string | name_ |
Definition at line 34 of file engine.hpp.
ai::engine::engine | ( | readonly_context & | context, |
const config & | cfg | ||
) |
Definition at line 33 of file engine.cpp.
References ai_, ai::side_context::get_side(), LOG_AI_ENGINE, and name_.
|
virtual |
Definition at line 43 of file engine.cpp.
|
virtual |
Reimplemented in ai::engine_cpp.
Definition at line 97 of file engine.cpp.
|
virtual |
Reimplemented in ai::engine_fai, and ai::engine_cpp.
Definition at line 102 of file engine.cpp.
|
virtual |
Reimplemented in ai::engine_cpp.
Definition at line 106 of file engine.cpp.
|
virtual |
Reimplemented in ai::engine_cpp.
Definition at line 110 of file engine.cpp.
|
virtual |
Reimplemented in ai::engine_fai, and ai::engine_cpp.
Definition at line 114 of file engine.cpp.
|
virtual |
Reimplemented in ai::engine_lua, and ai::engine_fai.
Definition at line 119 of file engine.cpp.
|
virtual |
Definition at line 129 of file engine.cpp.
References ai_context_.
Referenced by ai::cfun_ai_get_targets().
|
inlinevirtual |
|
inlinevirtual |
Implements ai::component.
Definition at line 83 of file engine.hpp.
References id_.
Referenced by ai::engine_lua::to_config().
|
inlinevirtual |
Implements ai::component.
Definition at line 89 of file engine.hpp.
References name_.
Referenced by to_config().
readonly_context & ai::engine::get_readonly_context | ( | ) |
Definition at line 142 of file engine.cpp.
References ai_.
Referenced by ai::lua_ai_context::create(), ai::get_readonly_context(), ai::impl_ai_aspect_get(), ai::impl_ai_aspect_list(), and ai::impl_ai_get().
|
virtual |
Reimplemented in ai::engine_lua.
Definition at line 47 of file engine.cpp.
|
static |
Definition at line 52 of file engine.cpp.
References b, and ai::readonly_context::get_engine_by_cfg().
Referenced by ai::composite_aspect< T >::add_facet(), ai::composite_aspect< T >::composite_aspect(), ai::composite_aspect< T >::create_facet(), ai::readonly_context_impl::on_readonly_context_create(), and ai::ai_composite::replace_aspect().
|
static |
Definition at line 61 of file engine.cpp.
References b, and ai::readonly_context::get_engine_by_cfg().
Referenced by ai::ai_default_rca::candidate_action_evaluation_loop::on_create().
|
static |
Definition at line 70 of file engine.cpp.
References b, and ai::readonly_context::get_engine_by_cfg().
Referenced by ai::ai_composite::create_engine(), and ai::readonly_context_impl::on_readonly_context_create().
|
static |
Definition at line 79 of file engine.cpp.
References b, and ai::readonly_context::get_engine_by_cfg().
Referenced by ai::ai_composite::create_goal(), and ai::readonly_context_impl::on_readonly_context_create().
|
static |
Definition at line 88 of file engine.cpp.
References b, and ai::readonly_context::get_engine_by_cfg().
Referenced by ai::ai_composite::create_stage().
|
virtual |
set ai context (which is not available during early initialization)
Definition at line 124 of file engine.cpp.
References ai_context_.
|
virtual |
serialize
Reimplemented in ai::engine_lua, and ai::engine_fai.
Definition at line 134 of file engine.cpp.
References engine_, and get_name().
Referenced by ai::engine_fai::to_config(), and ai::engine_lua::to_config().
|
protected |
Definition at line 93 of file engine.hpp.
Referenced by ai::engine_lua::do_parse_aspect_from_config(), ai::engine_cpp::do_parse_aspect_from_config(), ai::engine_cpp::do_parse_candidate_action_from_config(), ai::engine_fai::do_parse_candidate_action_from_config(), ai::engine_cpp::do_parse_engine_from_config(), ai::engine_lua::do_parse_goal_from_config(), ai::engine_cpp::do_parse_goal_from_config(), ai::engine_cpp::do_parse_stage_from_config(), engine(), and get_readonly_context().
|
protected |
Definition at line 94 of file engine.hpp.
Referenced by get_ai_context(), and set_ai_context().
|
protected |
name of the engine which has created this engine
Definition at line 97 of file engine.hpp.
Referenced by get_engine(), and to_config().
|
protected |
Definition at line 98 of file engine.hpp.
Referenced by get_id().
|
protected |
Definition at line 99 of file engine.hpp.
Referenced by engine(), ai::engine_cpp::engine_cpp(), ai::engine_fai::engine_fai(), ai::engine_lua::engine_lua(), and get_name().