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

Function template any_cast

boost::anys::any_cast

Synopsis

// In header: <boost/any/basic_any.hpp>


template<typename ValueType, std::size_t OptimizeForSize, 
         std::size_t OptimizeForAlignment> 
  const ValueType * 
  any_cast(const basic_any< OptimizeForSize, OptimizeForAlignment > * operand);

Description

Returns:

Const pointer to a ValueType stored in operand, nullptr if operand does not contain specified ValueType.


PrevUpHomeNext