Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for an old version of Boost. Click here to view this page for the latest version.
PrevUpHomeNext

Class template callback

boost::log::type_dispatcher::callback

Synopsis

// In header: <boost/log/utility/type_dispatch/type_dispatcher.hpp>


template<typename T> 
class callback {
public:

  // public member functions
  void operator()(T const &) const;
  explicit operator bool() const noexcept;
  bool operator!() const noexcept;
};

Description

This interface is used by type dispatchers to consume the dispatched value.

callback public member functions

  1. void operator()(T const & value) const;

    The operator invokes the visitor-specific logic with the given value

    Parameters:

    value

    The dispatched value

  2. explicit operator bool() const noexcept;

    The operator checks if the visitor is attached to a receiver

  3. bool operator!() const noexcept;

    The operator checks if the visitor is not attached to a receiver


PrevUpHomeNext