Gaudi Framework, version v20r4

Generated: 8 Jan 2009

PoolDbCnvFactory< ConcreteConverter, i > Class Template Reference

#include <PoolDb/PoolDbCnvFactory.h>

Inheritance diagram for PoolDbCnvFactory< ConcreteConverter, i >:

Inheritance graph
[legend]
Collaboration diagram for PoolDbCnvFactory< ConcreteConverter, i >:

Collaboration graph
[legend]

List of all members.


Detailed Description

template<class ConcreteConverter, int i>
class PoolDbCnvFactory< ConcreteConverter, i >

Description: Implementation definition for POOL converter factories.

Author:
M.Frank
Version:
1.0

Definition at line 52 of file PoolDbCnvFactory.h.


Public Types

typedef ConcreteConverter converter_t
 Converter type.

Public Member Functions

 PoolDbCnvFactory ()
 Standard constructor.
virtual ~PoolDbCnvFactory ()
 Standard destructor.
virtual const std::string & typeName () const
 Access to object type.
virtual const CLIDobjType () const
 Access to the class type of the converter.
virtual const long repSvcType () const
 Access to the service type of the converter.
virtual unsigned long addRef () const
virtual unsigned long release () const
virtual const std::string & ident () const
virtual unsigned long addRef ()
 Increment the reference count of Interface instance.
virtual unsigned long release ()
 Release Interface instance.
virtual StatusCode queryInterface (const InterfaceID &riid, void **ppISvc)
 Query factory interface.
virtual IConverterinstantiate (long typ, const CLID &, ISvcLocator *svcloc) const
 Instantiation method.
virtual IConverterinstantiate (ISvcLocator *) const
 virtual overload: Instantiate an instance of a converter
virtual IInterfaceinstantiate (IInterface *) const
 Create an instance of a generic Gaudi object: Method is disabled!

Private Attributes

std::string m_typeName
 Object type name.

Member Typedef Documentation

template<class ConcreteConverter, int i>
typedef ConcreteConverter PoolDbCnvFactory< ConcreteConverter, i >::converter_t

Converter type.

Definition at line 59 of file PoolDbCnvFactory.h.


Constructor & Destructor Documentation

template<class ConcreteConverter, int i>
PoolDbCnvFactory< ConcreteConverter, i >::PoolDbCnvFactory (  )  [inline]

Standard constructor.

Definition at line 62 of file PoolDbCnvFactory.h.

00062                       {
00063     m_typeName = "";
00064     FactoryTable::instance()->addFactory( this );
00065   }

template<class ConcreteConverter, int i>
virtual PoolDbCnvFactory< ConcreteConverter, i >::~PoolDbCnvFactory (  )  [inline, virtual]

Standard destructor.

Definition at line 67 of file PoolDbCnvFactory.h.

00067 {  }


Member Function Documentation

template<class ConcreteConverter, int i>
virtual const std::string& PoolDbCnvFactory< ConcreteConverter, i >::typeName (  )  const [inline, virtual]

Access to object type.

Definition at line 69 of file PoolDbCnvFactory.h.

00069                                                 {
00070     // The name MUST be set here, not in the constructor.
00071     // At construction time it is not yet clear if we run from
00072     // an executable or a DLL.
00073     if ( m_typeName == "" )  {
00074       if ( System::moduleType() == System::SHAREDLIB )  {
00075         m_typeName  = System::moduleName();
00076         m_typeName += ":";
00077       }
00078       // Get the class name using the RTTI. 
00079       m_typeName += System::typeinfoName( typeid(ConcreteConverter) );
00080     }
00081     return m_typeName;
00082   }

template<class ConcreteConverter, int i>
virtual const CLID& PoolDbCnvFactory< ConcreteConverter, i >::objType (  )  const [virtual]

Access to the class type of the converter.

template<class ConcreteConverter, int i>
virtual const long PoolDbCnvFactory< ConcreteConverter, i >::repSvcType (  )  const [inline, virtual]

Access to the service type of the converter.

Definition at line 86 of file PoolDbCnvFactory.h.

00087   {    return pool::POOL_StorageType.type();  }

template<class ConcreteConverter, int i>
virtual unsigned long PoolDbCnvFactory< ConcreteConverter, i >::addRef (  )  const [inline, virtual]

Definition at line 88 of file PoolDbCnvFactory.h.

00088 {     return 1;           }

template<class ConcreteConverter, int i>
virtual unsigned long PoolDbCnvFactory< ConcreteConverter, i >::release (  )  const [inline, virtual]

Definition at line 89 of file PoolDbCnvFactory.h.

00089 {     return 1;           }

template<class ConcreteConverter, int i>
virtual const std::string& PoolDbCnvFactory< ConcreteConverter, i >::ident (  )  const [inline, virtual]

Definition at line 90 of file PoolDbCnvFactory.h.

00090 {     return typeName();  }

template<class ConcreteConverter, int i>
virtual unsigned long PoolDbCnvFactory< ConcreteConverter, i >::addRef (  )  [inline, virtual]

Increment the reference count of Interface instance.

Implements IInterface.

Definition at line 92 of file PoolDbCnvFactory.h.

00092 {     return 1;           }

template<class ConcreteConverter, int i>
virtual unsigned long PoolDbCnvFactory< ConcreteConverter, i >::release (  )  [inline, virtual]

Release Interface instance.

Implements IInterface.

Definition at line 93 of file PoolDbCnvFactory.h.

00093 {     return 1;           }

template<class ConcreteConverter, int i>
virtual StatusCode PoolDbCnvFactory< ConcreteConverter, i >::queryInterface ( const InterfaceID riid,
void **  ppISvc 
) [inline, virtual]

Query factory interface.

Implements IInterface.

Definition at line 96 of file PoolDbCnvFactory.h.

00096                                                                               {
00097           if ( IID_IPoolDbCnvFactory == riid )   {
00098       *ppISvc = (IPoolDbCnvFactory *) this;
00099     }
00100           else if( IID_ICnvFactory == riid )    {
00101         *ppISvc = (ICnvFactory*) this;
00102     }
00103           else if ( IID_IFactory == riid )     {
00104           *ppISvc = (IFactory *) this;
00105     }
00106     else if ( IID_IInterface == riid )    {
00107         *ppISvc = (IInterface *) this;
00108     }
00109           else    {
00110                   return StatusCode::FAILURE;
00111     }
00112     addRef();
00113           return StatusCode::SUCCESS;
00114   }

template<class ConcreteConverter, int i>
virtual IConverter* PoolDbCnvFactory< ConcreteConverter, i >::instantiate ( long  typ,
const CLID ,
ISvcLocator svcloc 
) const [inline, virtual]

Instantiation method.

Parameters:
typ [IN] Storage type of the converter to be created
clid [IN] Class identifier of the converter
svcloc [IN] Pointer to service locator object
Returns:
Pointer to created converter object.

Implements IPoolDbCnvFactory.

Definition at line 124 of file PoolDbCnvFactory.h.

00127   {    return new ConcreteConverter(typ, svcloc);  }

template<class ConcreteConverter, int i>
virtual IConverter* PoolDbCnvFactory< ConcreteConverter, i >::instantiate ( ISvcLocator  )  const [inline, virtual]

virtual overload: Instantiate an instance of a converter

Definition at line 130 of file PoolDbCnvFactory.h.

00131   {    return 0;  }

template<class ConcreteConverter, int i>
virtual IInterface* PoolDbCnvFactory< ConcreteConverter, i >::instantiate ( IInterface  )  const [inline, virtual]

Create an instance of a generic Gaudi object: Method is disabled!

Definition at line 134 of file PoolDbCnvFactory.h.

00135   {    return 0;  }


Member Data Documentation

template<class ConcreteConverter, int i>
std::string PoolDbCnvFactory< ConcreteConverter, i >::m_typeName [mutable, private]

Object type name.

Definition at line 56 of file PoolDbCnvFactory.h.


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

Generated at Thu Jan 8 17:52:08 2009 for Gaudi Framework, version v20r4 by Doxygen version 1.5.6 written by Dimitri van Heesch, © 1997-2004