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

PrevUpHomeNext

Class impl

boost::log::attributes::current_thread_id::impl — Factory implementation.

Synopsis

// In header: <boost/log/attributes/current_thread_id.hpp>



// Factory implementation.

class impl : public attribute_value::impl {
public:

  // public member functions
  virtual bool dispatch(type_dispatcher &);
  virtual intrusive_ptr< attribute_value::impl > detach_from_thread();
  virtual typeindex::type_index get_type() const;
};

Description

impl public member functions

  1. virtual bool dispatch(type_dispatcher & dispatcher);

    The method dispatches the value to the given object.

    Parameters:

    dispatcher

    The object that attempts to dispatch the stored value.

    Returns:

    true if dispatcher was capable to consume the real attribute value type and false otherwise.

  2. virtual intrusive_ptr< attribute_value::impl > detach_from_thread();

    The method is called when the attribute value is passed to another thread (e.g. in case of asynchronous logging). The value should ensure it properly owns all thread-specific data.

    Returns:

    An actual pointer to the attribute value. It may either point to this object or another. In the latter case the returned pointer replaces the pointer used by caller to invoke this method and is considered to be a functional equivalent to the previous pointer.

  3. virtual typeindex::type_index get_type() const;

    Returns:

    The attribute value type


PrevUpHomeNext