--- /dev/null
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+# CONFIGURATION MANAGEMENT OF EDF VERSION
+# ======================================================================
+# COPYRIGHT (C) 1991 - 2002 EDF R&D WWW.CODE-ASTER.ORG
+# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY
+# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY
+# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR
+# (AT YOUR OPTION) ANY LATER VERSION.
+#
+# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT
+# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF
+# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU
+# GENERAL PUBLIC LICENSE FOR MORE DETAILS.
+#
+# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE
+# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER,
+# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE.
+#
+#
+# ======================================================================
+
+"""
+ Ce module sert à lancer EFICAS configuré pour Code_Aster
+"""
+# Modules Python
+
+# Modules Eficas
+import prefs
+name='prefs_'+prefs.code
+__import__(name)
+
+from InterfaceQT4 import eficas_go
+
+eficas_go.lance_eficas_ssIhm(code=prefs.code,fichier="/home/noyret/Eficas_Aster/zz.comm",version='v9.5')
#
# ======================================================================
-print "INTERFACEQT4"
import types,sys,os
import traceback
from PyQt4 import *
sys.exit(res)
-def lance_eficas_ssIhm(code=None,fichier=None):
+def lance_eficas_ssIhm(code=None,fichier=None,version='v9.5'):
"""
Lance l'appli EFICAS pour trouver les noms des groupes
"""
Eficas=Appli(code=code)
from ssIhm import QWParentSSIhm
- parent=QWParentSSIhm(code,Eficas,'v9.4')
+ parent=QWParentSSIhm(code,Eficas,version)
+
+ import readercata
+ if not hasattr( readercata, 'reader' ) :
+ readercata.reader = readercata.READERCATA( parent, Eficas )
- from readercata import READERCATA
- readercata = READERCATA( parent, Eficas )
-
from editor import JDCEditor
monEditeur=JDCEditor(Eficas,fichier)
print monEditeur.cherche_Groupes()
self.appliEficas.close()
sys.exit(1)
+
if self.version_code is not None:
# La version a ete fixee
for cata in liste_cata_possibles:
--- /dev/null
+# -*- coding: utf-8 -*-
+# CONFIGURATION MANAGEMENT OF EDF VERSION
+# ======================================================================
+# COPYRIGHT (C) 1991 - 2002 EDF R&D WWW.CODE-ASTER.ORG
+# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY
+# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY
+# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR
+# (AT YOUR OPTION) ANY LATER VERSION.
+#
+# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT
+# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF
+# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU
+# GENERAL PUBLIC LICENSE FOR MORE DETAILS.
+#
+# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE
+# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER,
+# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE.
+#
+#
+# ======================================================================
+# permet de lancer EFICAS en n affichant rien
+
+class QWParentSSIhm:
+ def __init__(self,code,appliEficas,version_code):
+ self.ihm="QT"
+ self.code=code
+ self.version_code=version_code
+ self.appliEficas=appliEficas
+
--- /dev/null
+# -*- coding: utf-8 -*-
+# CONFIGURATION MANAGEMENT OF EDF VERSION
+# ======================================================================
+# COPYRIGHT (C) 1991 - 2002 EDF R&D WWW.CODE-ASTER.ORG
+# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY
+# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY
+# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR
+# (AT YOUR OPTION) ANY LATER VERSION.
+#
+# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT
+# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF
+# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU
+# GENERAL PUBLIC LICENSE FOR MORE DETAILS.
+#
+# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE
+# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER,
+# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE.
+#
+#
+# ======================================================================
+"""
+ Ce module contient le plugin generateur d une liste des GroupNo et GroupMA
+"""
+import traceback
+import types,string,re
+
+from generator_python import PythonGenerator
+def entryPoint():
+ """
+ Retourne les informations nécessaires pour le chargeur de plugins
+
+ Ces informations sont retournées dans un dictionnaire
+ """
+ return {
+ # Le nom du plugin
+ 'name' : 'GroupMA',
+ # La factory pour créer une instance du plugin
+ 'factory' : GroupMAGenerator,
+ }
+
+
+class GroupMAGenerator(PythonGenerator):
+ """
+ Ce generateur parcourt un objet de type JDC et produit
+ un texte au format eficas et
+ un texte au format homard
+
+ """
+ # Les extensions de fichier préconisées
+ extensions=('.comm',)
+
+ def __init__(self):
+ PythonGenerator.__init__(self)
+ self.liste=[]
+
+ def gener(self,obj,format='brut'):
+ self.liste=[]
+ self.text=PythonGenerator.gener(self,obj,'brut')
+ return self.liste
+
+ def generMCSIMP(self,obj) :
+ if 'grma' in repr(obj.definition.type) or 'grno' in repr(obj.definition.type) :
+ self.liste.append(obj.valeur)
+ s=PythonGenerator.generMCSIMP(self,obj)
+ return s