The Battle for Wesnoth  1.15.0+dev
Public Member Functions | Private Attributes | List of all members
lua_mapgen::filter Class Reference

#include <lua_terrainfilter.hpp>

Public Member Functions

 filter (lua_State *L, int data_index, int res_index=0)
 a lua table with the folllowing attributes [1]: the filter table, More...
 
 filter (const filter &)=delete
 
filteroperator= (const filter &)=delete
 
 filter (filter &&)=default
 
filteroperator= (filter &&)=default
 
 ~filter ()
 
bool matches (const mapgen_gamemap &m, map_location l)
 

Private Attributes

std::map< std::string, std::set< map_location > > known_sets_
 
std::unique_ptr< filter_implimpl_
 

Detailed Description

Definition at line 29 of file lua_terrainfilter.hpp.

Constructor & Destructor Documentation

◆ filter() [1/3]

lua_mapgen::filter::filter ( lua_State L,
int  data_index,
int  res_index = 0 
)
explicit

a lua table with the folllowing attributes [1]: the filter table,

data_index a index to the lua stack pointing to the lua table that describes the filter.

res_index a positive index to the lua stack pointing to the lua table that describes the filter resources.

Definition at line 704 of file lua_terrainfilter.cpp.

References impl_, LOG_LMG, lua_pop, and lua_pushvalue().

◆ filter() [2/3]

lua_mapgen::filter::filter ( const filter )
delete

◆ filter() [3/3]

lua_mapgen::filter::filter ( filter &&  )
default

◆ ~filter()

lua_mapgen::filter::~filter ( )

Definition at line 719 of file lua_terrainfilter.cpp.

Referenced by impl_terainfilter_collect().

Member Function Documentation

◆ matches()

bool lua_mapgen::filter::matches ( const mapgen_gamemap m,
map_location  l 
)

Definition at line 713 of file lua_terrainfilter.cpp.

References impl_, and log_scope.

Referenced by intf_mg_get_locations_part2(), and intf_mg_get_tiles_radius().

◆ operator=() [1/2]

filter& lua_mapgen::filter::operator= ( const filter )
delete

◆ operator=() [2/2]

filter& lua_mapgen::filter::operator= ( filter &&  )
default

Member Data Documentation

◆ impl_

std::unique_ptr<filter_impl> lua_mapgen::filter::impl_
private

Definition at line 50 of file lua_terrainfilter.hpp.

◆ known_sets_

std::map<std::string, std::set<map_location> > lua_mapgen::filter::known_sets_
private

Definition at line 49 of file lua_terrainfilter.hpp.


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