![]() |
Home | Libraries | People | FAQ | More |
boost::apply_visitor_delayed_t — Adapts a visitor for use as a function object.
// In header: <boost/variant/apply_visitor.hpp> template<typename Visitor> class apply_visitor_delayed_t { public: // types typedef ; // construct/copy/destruct (); // function object interface template<typename ... Variant> (); template<typename Variant> (); template<typename Variant1, typename Variant2> (, ); };
Adapts the function given at construction for use as a
function object. This is useful, for example, when one needs to
operate on each element of a sequence of variant objects using a
standard library algorithm such as
std::for_each
.
See the "visitor-only" form of
apply_visitor
for a simple
way to create apply_visitor_delayed_t
objects.
See apply_visitor_delayed_cpp14_t
which is used on C++14 compatible compilers when Visitor
has no
result_type
typedef.
apply_visitor_delayed_t
function object interfacetemplate<typename ... Variant> ( operand); template<typename Variant> ( operand); template<typename Variant1, typename Variant2> ( operand1, operand2);Function call operator.
Invokes
apply_visitor
on the
stored visitor using the given operands.
Notes: |
Version with variadic templates is used by default if BOOST_VARIANT_DO_NOT_USE_VARIADIC_TEMPLATES is not defined. |