The Gaudi Framework  master (1304469f)
Loading...
Searching...
No Matches
extends< BASE, Interfaces > Class Template Reference

Base class used to extend a class implementing other interfaces. More...

#include </builds/gaudi/Gaudi/GaudiKernel/include/GaudiKernel/extends.h>

Inheritance diagram for extends< BASE, Interfaces >:
Collaboration diagram for extends< BASE, Interfaces >:

Public Types

using base_class = extends
 Typedef to this class.
 
using extend_interfaces_base = extend_interfaces<Interfaces...>
 Typedef to the base of this class.
 
- Public Types inherited from extend_interfaces< Interfaces... >
using ext_iids
 take union of the ext_iids of all Interfaces...
 

Public Member Functions

void const * i_cast (const InterfaceID &tid) const override
 Implementation of IInterface::i_cast.
 
StatusCode queryInterface (const InterfaceID &ti, void **pp) override
 Implementation of IInterface::queryInterface.
 
std::vector< std::string > getInterfaceNames () const override
 Implementation of IInterface::getInterfaceNames.
 

Detailed Description

template<typename BASE, typename... Interfaces>
class extends< BASE, Interfaces >

Base class used to extend a class implementing other interfaces.

Version for one interface.

Author
Marco Clemencic

Definition at line 19 of file extends.h.

Member Typedef Documentation

◆ base_class

template<typename BASE, typename... Interfaces>
using extends< BASE, Interfaces >::base_class = extends

Typedef to this class.

Definition at line 23 of file extends.h.

◆ extend_interfaces_base

template<typename BASE, typename... Interfaces>
using extends< BASE, Interfaces >::extend_interfaces_base = extend_interfaces<Interfaces...>

Typedef to the base of this class.

Definition at line 25 of file extends.h.

Member Function Documentation

◆ getInterfaceNames()

template<typename BASE, typename... Interfaces>
std::vector< std::string > extends< BASE, Interfaces >::getInterfaceNames ( ) const
inlineoverride

Implementation of IInterface::getInterfaceNames.

Definition at line 49 of file extends.h.

49 {
53 // start with base, and move the rest...
54 vb.insert( vb.end(), std::make_move_iterator( vi.begin() ), std::make_move_iterator( vi.end() ) );
55 return vb;
56 }
Base class used to extend a class implementing other interfaces.
Definition extends.h:19
std::vector< std::string > getInterfaceNames(Gaudi::interface_list< Is... >)
Definition IInterface.h:158
typename Gaudi::interface_list_cat< typename Interfaces::ext_iids... >::type ext_iids

◆ i_cast()

template<typename BASE, typename... Interfaces>
void const * extends< BASE, Interfaces >::i_cast ( const InterfaceID & tid) const
inlineoverride

Implementation of IInterface::i_cast.

Definition at line 32 of file extends.h.

32 {
34 void* ptr = Gaudi::iid_cast( tid, iids{}, this );
35 return ptr ? ptr : BASE::i_cast( tid );
36 }
void * iid_cast(const InterfaceID &tid, Gaudi::interface_list< Is... >, P *ptr)
Definition IInterface.h:163

◆ queryInterface()

template<typename BASE, typename... Interfaces>
StatusCode extends< BASE, Interfaces >::queryInterface ( const InterfaceID & ti,
void ** pp )
inlineoverride

Implementation of IInterface::queryInterface.

Definition at line 39 of file extends.h.

39 {
40 if ( !pp ) return StatusCode::FAILURE;
41 *pp = i_cast( ti );
42 // if cast failed, try the base class
43 if ( !*pp ) return BASE::queryInterface( ti, pp );
44 this->addRef();
46 }
void const * i_cast(const InterfaceID &tid) const override
Implementation of IInterface::i_cast.
Definition extends.h:32

The documentation for this class was generated from the following file: