Lumiera  0.pre.03
»edit your freedom«
configflags.hpp File Reference

Go to the source code of this file.

Description

Under some circumstances it is necessary to assemble functionality out of elementary building blocks.

Especially, this assembly can be expressed as template specialisations directed by a configuration type. Thus, the purpose of this header is to encode flag-like configurations as distinct types, which can be used to select such specialisations. Each possible configuration can be encoded as a list of flags, which allows to generate, filter and process those configurations. The final goal is to automatically generate a factory which is able to deliver objects configured according to the situation encoded in the flags.

Note
currently there is an inherent limitation to configurations defined by a maximum of 5 independent flags. While it is easy to increase this limit, you should consider that the final goal is to generate template instantiations, which would lead to more and more code bloat with growing number of possible combinations.
See also
steam::engine::config::Strategy usage example
steam::engine::config::ConfigSelector
typelist.hpp

Definition in file configflags.hpp.

Classes

struct  BuildConfigFromFlags< FLAGS, CONF >
 build a configuration type from a list-of-flags More...
 
struct  BuildConfigFromFlags< Node< Flag< Fl >, FLAGS >, CONF >
 
struct  Config< f1, f2, f3, f4, f5 >
 < distinct type representing a configuration More...
 
struct  ConfigSetFlag< Fl, CONF >
 
struct  ConfigSetFlag< Fl, Config< f1, f2, f3, f4, IGN > >
 set (prepend) the Flag to the given config More...
 
struct  DefineConfigByFlags< FLAGS >
 create a configuration type for the given list-of-flags More...
 
struct  Flag< bit >
 
struct  Flag< 0 >
 
struct  FlagInfo< FLAGS >
 Helper for calculating values and for invoking runtime code based on a given FlagTuple. More...
 
struct  FlagInfo< Node< CONF, TAIL > >
 
struct  FlagInfo< Node< Flag< ff >, FLAGS > >
 
struct  FlagInfo< NullType >
 
struct  Flags< f1, f2, f3, f4, f5 >
 
struct  maxC< ii, jj >
 helper comparing enum values and flags More...
 

Variables

const size_t CONFIG_FLAGS_MAX = 5
 

Namespaces

 lib
 Implementation namespace for support and library code.