File: multivisitor.xml

package info (click to toggle)
boost1.74 1.74.0%2Bds1-21
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 463,588 kB
  • sloc: cpp: 3,338,117; xml: 131,293; python: 33,088; ansic: 14,292; asm: 4,038; sh: 3,353; makefile: 1,193; perl: 1,036; yacc: 478; php: 212; ruby: 102; lisp: 24; sql: 13; csh: 6
file content (96 lines) | stat: -rw-r--r-- 3,696 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE header PUBLIC "-//Boost//DTD BoostBook XML V1.0//EN"
  "http://www.boost.org/tools/boostbook/dtd/boostbook.dtd">
<!--
    Copyright 2013-2020 Antony Polukhin.

    Distributed under the Boost Software License, Version 1.0. (See accompanying
    file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-->
<header name="boost/variant/multivisitors.hpp">
  <using-namespace name="boost"/>

  <para>Provides declarations of <functionname>apply_visitor</functionname> for three or more
    <code><classname>variant</classname></code> parameters.</para>

    <macro name="BOOST_VARAINT_MAX_MULTIVIZITOR_PARAMS">
      <purpose>
        <simpara>Controls maximum amount of <code><classname>variant</classname></code>
          parameters for multi visistors. Not used when <code>std::tuple</code> is available and
          <code><macroname>BOOST_VARIANT_DO_NOT_USE_VARIADIC_TEMPLATES</macroname></code>
          is not defined.</simpara>
      </purpose>

      <description>
        <para><emphasis role="bold">Note</emphasis>: Default amount is 4. Define it 
          to bigger value before including &lt;boost/variant/multivisitors.hpp&gt; to
          increase maximum amount of <code><classname>variant</classname></code>
          parameters for <functionname>apply_visitor</functionname>.</para>
      </description>
    </macro>

  <namespace name="boost">
    <overloaded-function name="apply_visitor /*three or more variant parameters*/">
      <description>
        <simpara>Allows compile-time checked type-safe application of the
        given visitor to the content of the given variant, ensuring that all
        types are handled by the visitor. See <functionname>apply_visitor</functionname>
        for more information.</simpara>
      </description>

      <signature>
        <template>
          <template-type-parameter name="MultiVisitor"/>
          <template-type-parameter name="Variant1"/>
          <template-type-parameter name="Variant2"/>
          <template-type-parameter name="Variant3"/>
        </template>

        <type>typename MultiVisitor::result_type OR decltype(auto)</type>

        <parameter name="visitor">
          <paramtype>MultiVisitor &amp;</paramtype>
        </parameter>
        <parameter name="operand1">
          <paramtype>Variant1&amp;&amp;</paramtype>
        </parameter>
        <parameter name="operand2">
          <paramtype>Variant2&amp;&amp;</paramtype>
        </parameter>
        <parameter name="operand3">
          <paramtype>Variant3&amp;&amp;</paramtype>
        </parameter>
        <parameter name="other_operands">
          <paramtype>...</paramtype>
        </parameter>
      </signature>

      <signature>
        <template>
          <template-type-parameter name="MultiVisitor"/>
          <template-type-parameter name="Variant1"/>
          <template-type-parameter name="Variant2"/>
          <template-type-parameter name="Variant3"/>
        </template>

        <type>typename MultiVisitor::result_type OR decltype(auto)</type>

        <parameter name="visitor">
          <paramtype>const MultiVisitor &amp;</paramtype>
        </parameter>
        <parameter name="operand1">
          <paramtype>Variant1&amp;&amp;</paramtype>
        </parameter>
        <parameter name="operand2">
          <paramtype>Variant2&amp;&amp;</paramtype>
        </parameter>
        <parameter name="operand3">
          <paramtype>Variant3&amp;&amp;</paramtype>
        </parameter>
        <parameter name="other_operands">
          <paramtype>...</paramtype>
        </parameter>
      </signature>
    </overloaded-function>
  </namespace>
</header>