|  | 
|      | 
|  | 
| The MPL Reference Manual: Metafunction ClassBoost , ,
  
   | ||||||||||||||||||||||||||||||||
| Front Page / Metafunctions / Concepts / Metafunction Class | 
А.класс метафункции— это определенная форма представления метафункции, которая обеспечивает метапрограммирование более высокого порядка. Точнее, это класс с общедоступным гнездом.Метафункцияназываетсяприменяется. Соответственно, вызов класса метафункции определяется как вызов его вложеннойприменимойметафункции.
В следующей таблице и последующих спецификацияхfпредставляет собойкласс метафункций.
| Expression | Type | Complexity | 
|---|---|---|
| f::применять::тип | Любой тип | Не уточняется. | 
| f::применять<>::type | Любой тип | Не уточняется. | 
| f::применять | Любой тип | Не уточняется. | 
typedef f::apply::type x;
| Precondition: | f is a nullary Metafunction Class; f::apply::type is a type-name. | 
|---|---|
| Semantics: | x is the result of the metafunction class invocation. | 
typedef f::apply<>::type x;
| Precondition: | f is a nullary Metafunction Class; f::apply<>::type is a type-name. | 
|---|---|
| Semantics: | x is the result of the metafunction class invocation. | 
typedef f::apply<a1,...an>::type x;
| Precondition: | f is an n-ary metafunction class; apply is a Metafunction. | 
|---|---|
| Semantics: | x is the result of the metafunction class invocation with the actual arguments a1,... an. | 
Статья The MPL Reference Manual: Metafunction Class раздела может быть полезна для разработчиков на c++ и boost.
:: Главная :: ::
| реклама |