1 // Copyright (C) 2007-2021 CEA/DEN, EDF R&D
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 // Authors : Guillaume Boulant (EDF) - 01/06/2011
22 #include "MEDFactory_i.hxx"
23 #include "utilities.h"
25 #include "MEDDataManager_i.hxx"
26 #include "MEDCalculator_i.hxx"
27 #include "MEDPresentationManager_i.hxx"
28 #include "MEDCommandsHistoryManager_i.hxx"
30 //=============================================================================
32 * standard constructor
34 //=============================================================================
36 MEDFactory_i::MEDFactory_i(CORBA::ORB_ptr orb,
37 PortableServer::POA_ptr poa,
38 PortableServer::ObjectId* contId,
39 const char* instanceName,
40 const char* interfaceName,
42 : Engines_Component_i(orb, poa, contId, instanceName, interfaceName, false, checkNS)
44 MESSAGE("activate object");
46 _id = _poa->activate_object(_thisObj);
49 MEDFactory_i::~MEDFactory_i()
54 MEDCALC::MEDDataManager_ptr
55 MEDFactory_i::getDataManager()
57 MEDDataManager_i* medDataManager = MEDDataManager_i::getInstance();
58 MEDCALC::MEDDataManager_ptr medDataManagerPtr = medDataManager->_this();
59 return medDataManagerPtr;
62 MEDCALC::MEDCalculator_ptr
63 MEDFactory_i::getCalculator()
65 MEDCalculator_i* medCalculator = MEDCalculator_i::getInstance();
66 MEDCALC::MEDCalculator_ptr medCalculatorPtr = medCalculator->_this();
67 return medCalculatorPtr;
70 MEDCALC::MEDPresentationManager_ptr
71 MEDFactory_i::getPresentationManager()
73 MEDPresentationManager_i* manager = MEDPresentationManager_i::getInstance();
74 MEDCALC::MEDPresentationManager_ptr managerPtr = manager->_this();
78 MEDCALC::MEDCommandsHistoryManager_ptr
79 MEDFactory_i::getCommandsHistoryManager()
81 MEDCommandsHistoryManager_i* manager = MEDCommandsHistoryManager_i::getInstance();
82 MEDCALC::MEDCommandsHistoryManager_ptr managerPtr = manager->_this();