| # Gaudi Framework, version v21r7p1 |

Home |  | Generated: 15 Feb 2010

# ComponentManager.cpp

Go to the documentation of this file.

    00001 /*
    00002  * ComponentManager.cpp
    00003  *
    00004  *  Created on: Feb 20, 2009
    00005  *      Author: Marco Clemencic
    00006  */
    00007
    00008 #include "GaudiKernel/ComponentManager.h"
    00009
    00010 //------------------------------------------------------------------------------
    00011 // Constructor
    00012 ComponentManager::ComponentManager(IInterface *application, const InterfaceID &baseIID):
    00013   m_application(application), m_stateful(application), m_basicInterfaceId(baseIID)
    00014 {
    00015 }
    00016
    00017 //------------------------------------------------------------------------------
    00018 // Basic interface id of the managed components.
    00019 const InterfaceID& ComponentManager::componentBaseInterface() const {
    00020   return m_basicInterfaceId;
    00021 }
    00022
    00023 //------------------------------------------------------------------------------
    00024 // Virtual destructor
    00025 ComponentManager::~ComponentManager() {
    00026 }
    00027
    00028 //------------------------------------------------------------------------------
    00029 // queryInterface implementation that falls back on the owner.
    00030 StatusCode ComponentManager::queryInterface(const InterfaceID& iid, void** pinterface)
    00031 {
    00032   // try local interfaces
    00033   StatusCode sc = base_class::queryInterface(iid,pinterface);
    00034   if (sc.isSuccess()) return sc;
    00035   // fall back on the owner
    00036   return m_application->queryInterface(iid, pinterface);
    00037 }