Boost.OpenMethod

    • Motivation
    • Basic Features
      • Methods and Overriders
      • Performance
      • Smart Pointers
      • Header and Implementation Files
      • Namespaces
      • Friends
      • Multiple Dispatch
    • Advanced Features
      • Core API
      • Registries and Policies
      • Custom RTTI
      • Error Handling
      • Virtual Pointer Alternatives
      • Shared Libraries
    • Reference
      • Headers
      • Macros
      • Namespace boost::openmethod
  • boost::openmethod::policies::RttiFn::dynamic_cast_ref
arrow_upward

boost::openmethod::policies::RttiFn::dynamic_cast_ref

Casts an object to a type.

Synopsis

Declared in <boost/openmethod/preamble.hpp>

template<
    typename D,
    typename B>
static
D
dynamic_cast_ref(B&& obj);

Template Parameters

Name Description

D

A reference to a subclass of B.

B

A registered class.

Parameters

Name Description

obj

A reference to an instance of B.

Created with MrDocs