Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F90319321
keyword_list.cc
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Thu, Oct 31, 11:34
Size
2 KB
Mime Type
text/x-c
Expires
Sat, Nov 2, 11:34 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
22050820
Attached To
rLIBMULTISCALE LibMultiScale
keyword_list.cc
View Options
#include "atom_model_list.hh"
#include "compute_list.hh"
#include "continuum_model_list.hh"
#include "coupler_list.hh"
#include "dd_model_list.hh"
#include "dumper_list.hh"
#include "filter_list.hh"
#include "geometry_list.hh"
#include "stimulation_list.hh"
/* -------------------------------------------------------------------------- */
#include <boost/preprocessor.hpp>
#include <map>
#include <vector>
/* -------------------------------------------------------------------------- */
#include <boost/preprocessor.hpp>
#define stringify_macro(s) stringify_macro_1(s)
#define stringify_macro_1(s) #s
/* -------------------------------------------------------------------------- */
#define APPEND_MODEL_KEY_TO_LIST(r, data, x) \
data[stringify_macro(BOOST_PP_TUPLE_ELEM(3, 2, x))].resize(1); \
data[stringify_macro(BOOST_PP_TUPLE_ELEM(3, 2, x))][0] = \
stringify_macro(BOOST_PP_TUPLE_ELEM(3, 0, x));
#define APPEND_COUPLER_KEY_TO_LIST(r, data, x) \
data[stringify_macro(BOOST_PP_TUPLE_ELEM(4, 1, x))].push_back( \
stringify_macro(BOOST_PP_TUPLE_ELEM(4, 0, x)));
#define APPEND_NORMAL_KEY_TO_LIST(r, data, x) \
data[stringify_macro(BOOST_PP_TUPLE_ELEM(2, 1, x))].push_back( \
stringify_macro(BOOST_PP_TUPLE_ELEM(2, 0, x)));
/* -------------------------------------------------------------------------- */
auto getKeyWordList() {
std::map<std::string, std::vector<std::string>> key_list;
BOOST_PP_SEQ_FOR_EACH(APPEND_MODEL_KEY_TO_LIST, key_list, LIST_ATOM_MODEL);
BOOST_PP_SEQ_FOR_EACH(APPEND_MODEL_KEY_TO_LIST, key_list, LIST_DD_MODEL);
BOOST_PP_SEQ_FOR_EACH(APPEND_MODEL_KEY_TO_LIST, key_list,
LIST_CONTINUUM_MODEL);
BOOST_PP_SEQ_FOR_EACH(APPEND_COUPLER_KEY_TO_LIST, key_list, LIST_COUPLER);
BOOST_PP_SEQ_FOR_EACH(APPEND_NORMAL_KEY_TO_LIST, key_list, LIST_GEOMETRY);
BOOST_PP_SEQ_FOR_EACH(APPEND_NORMAL_KEY_TO_LIST, key_list, LIST_STIMULATION);
BOOST_PP_SEQ_FOR_EACH(APPEND_NORMAL_KEY_TO_LIST, key_list, LIST_DUMPER);
BOOST_PP_SEQ_FOR_EACH(APPEND_NORMAL_KEY_TO_LIST, key_list, LIST_COMPUTE);
BOOST_PP_SEQ_FOR_EACH(APPEND_NORMAL_KEY_TO_LIST, key_list, LIST_FILTER);
return key_list;
}
/* -------------------------------------------------------------------------- */
Event Timeline
Log In to Comment