]> SALOME platform Git repositories - modules/adao.git/blob - src/daSalome/daGUI/ADAO.py
Salome HOME
Updating copyright date information
[modules/adao.git] / src / daSalome / daGUI / ADAO.py
1 # -*- coding: utf-8 -*-
2 # Copyright (C) 2008-2016 EDF R&D
3 #
4 # This file is part of SALOME ADAO module
5 #
6 # This library is free software; you can redistribute it and/or
7 # modify it under the terms of the GNU Lesser General Public
8 # License as published by the Free Software Foundation; either
9 # version 2.1 of the License.
10 #
11 # This library is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 # Lesser General Public License for more details.
15 #
16 # You should have received a copy of the GNU Lesser General Public
17 # License along with this library; if not, write to the Free Software
18 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
19 #
20 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 #
22 # Author: André Ribes, andre.ribes@edf.fr, EDF R&D
23
24 import ADAO_COMPONENT__POA
25 import SALOME_ComponentPy
26 import SALOME_DriverPy
27
28 from daUtils.adaoLogger import *
29
30 class ADAO(ADAO_COMPONENT__POA.ADAO_ENGINE,
31            SALOME_ComponentPy.SALOME_ComponentPy_i,
32            SALOME_DriverPy.SALOME_DriverPy_i):
33   """
34       Pour etre un composant SALOME cette classe Python
35       doit avoir le nom du composant et heriter de la
36       classe ADAO_COMPONENT issue de la compilation de l'idl
37       par omniidl et de la classe SALOME_ComponentPy_i
38       qui porte les services generaux d'un composant SALOME
39   """
40   def __init__ ( self, orb, poa, contID, containerName, instanceName,
41       interfaceName ):
42     debug("Creating ADAO component instance", "ENGINE")
43     SALOME_ComponentPy.SALOME_ComponentPy_i.__init__(self, orb, poa,
44         contID, containerName, instanceName, interfaceName, 0)
45     SALOME_DriverPy.SALOME_DriverPy_i.__init__(self, interfaceName)
46
47     # On stocke dans l'attribut _naming_service, une ref sur le Naming Service
48     self._naming_service = SALOME_ComponentPy.SALOME_NamingServicePy_i( self._orb )
49
50   def print_ping():
51     info("ADAO ENGINE Ping", "ENGINE")