#include <contexts.hpp>


Public Member Functions | |
| keeps_cache () | |
| ~keeps_cache () | |
| void | handle_generic_event (const std::string &event_name) |
| void | clear () |
| const std::set< map_location > & | get () |
| void | init (gamemap &map) |
Private Attributes | |
| gamemap * | map_ |
| std::set< map_location > | keeps_ |
Definition at line 110 of file contexts.hpp.
| ai::keeps_cache::keeps_cache | ( | ) |
Definition at line 880 of file contexts.cpp.
References ai::manager::add_map_changed_observer(), and ai::manager::add_turn_started_observer().

| ai::keeps_cache::~keeps_cache | ( | ) |
Definition at line 889 of file contexts.cpp.
References ai::manager::remove_map_changed_observer(), and ai::manager::remove_turn_started_observer().

| void ai::keeps_cache::clear | ( | ) |
Definition at line 895 of file contexts.cpp.
References keeps_.
Referenced by handle_generic_event(), and ai::readonly_context_impl::invalidate_keeps_cache().

| const std::set< map_location > & ai::keeps_cache::get | ( | ) |
Definition at line 906 of file contexts.cpp.
References get_adjacent_tiles(), gamemap::h(), gamemap::is_castle(), gamemap::is_keep(), keeps_, map_, and gamemap::w().
Referenced by ai::readonly_context_impl::keeps().


| void ai::keeps_cache::handle_generic_event | ( | const std::string & | event_name | ) | [virtual] |
Implements events::observer.
Definition at line 855 of file contexts.cpp.
References clear().

| void ai::keeps_cache::init | ( | gamemap & | map | ) |
Definition at line 901 of file contexts.cpp.
References map_.
Referenced by ai::readonly_context_impl::readonly_context_impl().

std::set<map_location> ai::keeps_cache::keeps_ [private] |
Definition at line 121 of file contexts.hpp.
gamemap* ai::keeps_cache::map_ [private] |
Definition at line 120 of file contexts.hpp.
| Generated by doxygen 1.7.1 on Thu May 24 2012 01:18:35 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |