#include <bdlb_variant.h>
List of all members.
Public Member Functions |
| Variant_RawVisitorHelper (VISITOR *visitor) |
template<class ARGUMENT_TYPE > |
RESULT_TYPE | operator() (ARGUMENT_TYPE &argument) |
template<class ARGUMENT_TYPE > |
RESULT_TYPE | operator() (const ARGUMENT_TYPE &argument) |
template<class ARGUMENT_TYPE > |
RESULT_TYPE | operator() (ARGUMENT_TYPE &argument) const |
template<class ARGUMENT_TYPE > |
RESULT_TYPE | operator() (const ARGUMENT_TYPE &argument) const |
RESULT_TYPE | operator() (bslmf::Nil) const |
Detailed Description
template<class RESULT_TYPE, class VISITOR>
class bdlb::Variant_RawVisitorHelper< RESULT_TYPE, VISITOR >
This struct
provides a helper for implementing Variant::applyRaw
that enables applyRaw
to support visitor functors that do not provide an overload for operator()(bslmf::Nil)
. Objects of this type are constructed using a functor of (template parameter) type VISITOR
, whose operator()
returns the (template parameter) type RESULT_TYPE
. A Variant_RawVisitorHelper
wraps a functor of type VISITOR
and provides an implementation of operator()(bslmf::Nil)
that performs a BSLS_ASSERT_OPT(false)
. Note that this overload is needed to enable compilation (specifically, to instantiate doApply
and doApplyR
), but is never invoked by any code path at runtime.
See Component bdlb_variant
Constructor & Destructor Documentation
template<class RESULT_TYPE , class VISITOR >
Create a RawVisitorHelper
functor that delegates to the specified visitor
.
Member Function Documentation
template<class RESULT_TYPE , class VISITOR >
template<class ARGUMENT_TYPE >
template<class RESULT_TYPE , class VISITOR >
template<class ARGUMENT_TYPE >
Invoke the functor supplied at construction with the specified argument
, and return the result.
template<class RESULT_TYPE , class VISITOR >
template<class ARGUMENT_TYPE >
template<class RESULT_TYPE , class VISITOR >
template<class ARGUMENT_TYPE >
Invoke the functor supplied at construction with the specified argument
, and return the result.
template<class RESULT_TYPE , class VISITOR >
Do not call. The behavior of this method is undefined.
The documentation for this class was generated from the following file: