(Conversion Library).
#include <comstl/comstl.h>
#include <comstl/util/refcount_functions.h>
#include <comstl/util/interface_traits.hpp>
#include <comstl/error/bad_interface_cast.hpp>
#include <stlsoft/smartptr/ref_ptr.hpp>
#include <stlsoft/util/operator_bool.hpp>
Go to the source code of this file.
Namespaces | |
namespace | comstl |
Classes | |
struct | ignore_interface_cast_exception |
A function class that does not throw any exceptions. More... | |
struct | ignore_interface_cast_exception::thrown_type |
The exception type. More... | |
struct | throw_bad_interface_cast_exception |
A function class that throws the bad_interface_cast exception class. More... | |
struct | noaddref_release |
A function class that calls Release() on the interface. More... | |
struct | addref_release |
A function class that does not call Release() on the interface. More... | |
class | interface_cast_base |
Base class for the interface cast classes comstl::interface_cast_noaddref and comstl::interface_cast_addref. More... | |
class | interface_cast_noaddref |
Interface cast for raw pointers that does not add a net reference count. More... | |
class | interface_cast_addref |
Interface cast for raw pointers that does add a net reference count. More... | |
Functions | |
template<typename I> | |
I * | simple_interface_cast (I *pi) |
template<typename I> | |
interface | AddRef () |
STDMETHOD_ (ULONG, Release)() | |
template<typename IDest, typename ISrc> | |
bool | interface_cast_test (ISrc *src) |
Determines whether an interface is available on an object. | |
template<typename IDest, typename ISrc> | |
bool | interface_cast_test (stlsoft::ref_ptr< ISrc > &src) |
Determines whether an interface is available on an object. | |
template<typename IDest, typename ISrc> | |
stlsoft::ref_ptr< IDest > | interface_cast (ISrc *src) |
Casts a raw interface pointer to a wrapped instance. | |
template<typename IDest, typename ISrc> | |
stlsoft::ref_ptr< IDest > | interface_cast (stlsoft::ref_ptr< ISrc > src) |
Casts between instances of wrapped instances. | |
template<typename IDest, typename ISrc> | |
stlsoft::ref_ptr< IDest > | try_interface_cast (ISrc *src) |
Attempts to cast a raw interface pointer to a wrapped instance. | |
template<typename IDest, typename ISrc> | |
stlsoft::ref_ptr< IDest > | try_interface_cast (stlsoft::ref_ptr< ISrc > src) |
Attempts to cast between instances of wrapped instances. | |
template<typename I, typename X> | |
I | get_ptr (comstl_ns_qual(interface_cast_noaddref)< I, X > &p) |
Attribute shim to retrieve the interface pointer of the given cast instance. | |
template<typename I, typename X> | |
I | get_ptr (comstl_ns_qual(interface_cast_noaddref)< I, X > const &p) |
Attribute shim to retrieve the interface pointer of the given cast instance. | |
template<typename I, typename X> | |
I | get_ptr (comstl_ns_qual(interface_cast_addref)< I, X > &p) |
Attribute shim to retrieve the interface pointer of the given cast instance. | |
template<typename I, typename X> | |
I const | get_ptr (comstl_ns_qual(interface_cast_addref)< I, X > const &p) |
Attribute shim to retrieve the interface pointer of the given cast instance. |