From: Yohann Pipeau Date: Sat, 23 Apr 2022 06:05:29 +0000 (+0200) Subject: Utilisation de la classe Tuple interne à EFICAS X-Git-Tag: merge_uncertainty_odysee_1210~95 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=04e53312d842c201fc8e832b08034118071781fc;p=tools%2Feficas.git Utilisation de la classe Tuple interne à EFICAS --- diff --git a/ReacteurNumerique/cata_RN_EDG.py b/ReacteurNumerique/cata_RN_EDG.py index 08bc5243..8fc6e9da 100644 --- a/ReacteurNumerique/cata_RN_EDG.py +++ b/ReacteurNumerique/cata_RN_EDG.py @@ -14,6 +14,7 @@ function so, this module must not use relative import. # EFICAS from Accas import OPER, BLOC, FACT, SIMP, ASSD, JDC_CATA, VerifTypeTuple, Matrice +from Accas import Tuple as _Tuple from Extensions.i18n import tr # Warning: The names of these variables are defined by EFICAS @@ -25,7 +26,7 @@ VERSION_CATALOGUE = "V_0" NMIN_CORE_FUEL_ELTS = 1 NMAX_CORE_FUEL_ELTS = 18 -class Tuple: +class Tuple(_Tuple): """Organize the data into a fixed size tuple. Warnings @@ -33,17 +34,11 @@ class Tuple: This class respect the EFICAS conventions. """ - def __init__(self, ntuple): - self.ntuple = ntuple - def __convert__(self, valeur): if len(valeur) != self.ntuple: return None return valeur - def info(self): # pylint: disable=missing-function-docstring - return "Tuple de %s elements" % self.ntuple - class VerifPostTreatment(VerifTypeTuple): """Validate the data comming from ``Scenario_data.post_processing``.