The Battle for Wesnoth  1.13.4+dev
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
game_logic::move_map_callable Class Reference

#include <callable_objects.hpp>

Inheritance diagram for game_logic::move_map_callable:
Inheritance graph

Public Member Functions

 move_map_callable (const move_map &srcdst, const move_map &dstsrc, const unit_map &units)
 
const move_mapsrcdst () const
 
const move_mapdstsrc () const
 
- Public Member Functions inherited from game_logic::formula_callable
 formula_callable (bool has_self=true)
 
variant query_value (const std::string &key) const
 
void mutate_value (const std::string &key, const variant &value)
 
std::vector< formula_inputinputs () const
 
bool equals (const formula_callable *other) const
 
bool less (const formula_callable *other) const
 
void serialize (std::string &str) const
 
bool has_key (const std::string &key) const
 
- Public Member Functions inherited from reference_counted_object
 reference_counted_object ()
 
 reference_counted_object (const reference_counted_object &)
 
reference_counted_objectoperator= (const reference_counted_object &)
 
virtual ~reference_counted_object ()
 
void add_ref () const
 
void dec_ref () const
 
int refcount () const
 

Private Types

typedef std::multimap
< map_location, map_location
move_map
 

Private Member Functions

variant get_value (const std::string &key) const
 
void get_inputs (std::vector< game_logic::formula_input > *inputs) const
 

Private Attributes

const move_mapsrcdst_
 
const move_mapdstsrc_
 
const unit_mapunits_
 

Additional Inherited Members

- Protected Types inherited from game_logic::formula_callable
enum  TYPE {
  FORMULA_C, TERRAIN_C, LOCATION_C, UNIT_TYPE_C,
  UNIT_C, ATTACK_TYPE_C, MOVE_PARTIAL_C, MOVE_C,
  ATTACK_C, MOVE_MAP_C
}
 
- Protected Member Functions inherited from game_logic::formula_callable
virtual ~formula_callable ()
 
virtual void set_value (const std::string &key, const variant &value)
 
virtual int do_compare (const formula_callable *callable) const
 
virtual void serialize_to_string (std::string &) const
 
- Protected Member Functions inherited from reference_counted_object
void turn_reference_counting_off () const
 
- Protected Attributes inherited from game_logic::formula_callable
TYPE type_
 

Detailed Description

Definition at line 244 of file callable_objects.hpp.

Member Typedef Documentation

Definition at line 245 of file callable_objects.hpp.

Constructor & Destructor Documentation

game_logic::move_map_callable::move_map_callable ( const move_map srcdst,
const move_map dstsrc,
const unit_map units 
)
inline

Member Function Documentation

const move_map& game_logic::move_map_callable::dstsrc ( ) const
inline

Definition at line 260 of file callable_objects.hpp.

References dstsrc_.

void game_logic::move_map_callable::get_inputs ( std::vector< game_logic::formula_input > *  inputs) const
privatevirtual

Reimplemented from game_logic::formula_callable.

Definition at line 44 of file callable_objects.cpp.

References game_logic::FORMULA_READ_ONLY.

variant game_logic::move_map_callable::get_value ( const std::string key) const
privatevirtual

Implements game_logic::formula_callable.

Definition at line 24 of file callable_objects.cpp.

References unit_map::count(), i, srcdst_, and units_.

const move_map& game_logic::move_map_callable::srcdst ( ) const
inline

Definition at line 259 of file callable_objects.hpp.

References srcdst_.

Member Data Documentation

const move_map& game_logic::move_map_callable::dstsrc_
private

Definition at line 247 of file callable_objects.hpp.

Referenced by dstsrc().

const move_map& game_logic::move_map_callable::srcdst_
private

Definition at line 246 of file callable_objects.hpp.

Referenced by get_value(), and srcdst().

const unit_map& game_logic::move_map_callable::units_
private

Definition at line 248 of file callable_objects.hpp.

Referenced by get_value().


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