boost::openmethod::virtual_traits<Class*, Registry>::cast

Cast to another type.

Synopsis

template<typename Derived>
static
Derived
cast(Class* ptr);

Description

Cast an object to another type. If possible, use static_cast. Otherwise, use Registry::rtti::dynamic_cast_ref.

Return Value

A pointer to the same object, cast to Derived.

Template Parameters

Name Description

Derived

A pointer type.

Parameters

Name Description

obj

A pointer to a Class object.

Created with MrDocs