...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
boost::log::expressions::attribute_actor
// In header: <boost/log/expressions/attr_fwd.hpp> template<typename T, typename FallbackPolicyT, typename TagT, template< typename > class ActorT> class attribute_actor : public ActorT< attribute_terminal< T, FallbackPolicyT, TagT > > { public: // construct/copy/destruct explicit attribute_actor(base_type const &); // public member functions attribute_name get_name() const; fallback_policy const & get_fallback_policy() const; or_none_result_type or_none() const; or_throw_result_type or_throw() const; template<typename DefaultT> attribute_actor< value_type, fallback_to_default< DefaultT >, tag_type, ActorT > or_default(DefaultT const &) const; };
An attribute value extraction terminal actor
attribute_actor
public member functionsattribute_name get_name() const;
Returns: |
The attribute name |
fallback_policy const & get_fallback_policy() const;
Returns: |
Fallback policy |
or_none_result_type or_none() const;Generates an expression that extracts the attribute value or a default value.
or_throw_result_type or_throw() const;Generates an expression that extracts the attribute value or throws an exception.
template<typename DefaultT> attribute_actor< value_type, fallback_to_default< DefaultT >, tag_type, ActorT > or_default(DefaultT const & def_val) const;Generates an expression that extracts the attribute value or a default value.