Salome HOME
fe2ec51d8cc01419225622d2365c89f507a8e320
[modules/homard.git] / src / HOMARD / HOMARD_Hypothesis.hxx
1 //  HOMARD HOMARD : implementation of HOMARD idl descriptions
2 //
3 // Copyright (C) 2011-2014  CEA/DEN, EDF R&D
4 //
5 // This library is free software; you can redistribute it and/or
6 // modify it under the terms of the GNU Lesser General Public
7 // License as published by the Free Software Foundation; either
8 // version 2.1 of the License, or (at your option) any later version.
9 //
10 // This library is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13 // Lesser General Public License for more details.
14 //
15 // You should have received a copy of the GNU Lesser General Public
16 // License along with this library; if not, write to the Free Software
17 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
18 //
19 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 //
21 //  File   : HOMARD_Hypothesis.hxx
22 //  Author : Paul RASCLE, EDF
23 //  Module : HOMARD
24 //
25 // Remarques :
26 // L'ordre de description des fonctions est le meme dans tous les fichiers
27 // HOMARD_aaaa.idl, HOMARD_aaaa.hxx, HOMARD_aaaa.cxx, HOMARD_aaaa_i.hxx, HOMARD_aaaa_i.cxx :
28 // 1. Les generalites : Name, Delete, DumpPython, Dump, Restore
29 // 2. Les caracteristiques
30 // 3. Le lien avec les autres structures
31 //
32 // Quand les 2 fonctions Setxxx et Getxxx sont presentes, Setxxx est decrit en premier
33
34 #ifndef _HOMARD_HYPOTHESIS_HXX_
35 #define _HOMARD_HYPOTHESIS_HXX_
36
37 #include "HOMARD.hxx"
38
39 #include <string>
40 #include <list>
41
42 #if defined WIN32
43 #pragma warning ( disable: 4251 )
44 #endif
45
46 class HOMARDIMPL_EXPORT HOMARD_Hypothesis
47 {
48 public:
49   HOMARD_Hypothesis();
50   ~HOMARD_Hypothesis();
51
52 // Generalites
53   void                          SetName( const char* Name );
54   std::string                   GetName() const;
55
56   std::string                   GetDumpPython() const;
57
58 // Caracteristiques
59   void                          SetAdapType( int TypeAdap );
60   int                           GetAdapType() const;
61   void                          SetRefinTypeDera( int TypeRaff, int TypeDera );
62   int                           GetRefinType() const;
63   int                           GetUnRefType() const;
64
65   void                          SetField( const char* FieldName );
66   std::string                   GetFieldName() const;
67   void                          SetUseField( int UsField );
68   int                           GetUseField()    const;
69
70   void                          SetUseComp( int UsCmpI );
71   int                           GetUseComp()    const;
72   void                          AddComp( const char* NomComp );
73   void                          SupprComp( const char* NomComp );
74   void                          SupprComps();
75   const std::list<std::string>& GetComps() const;
76
77   void                          SetRefinThr( int TypeThR, double ThreshR );
78   int                           GetRefinThrType()   const;
79   double                        GetThreshR()   const;
80   void                          SetUnRefThr( int TypeThC, double ThreshC );
81   int                           GetUnRefThrType()   const;
82   double                        GetThreshC()   const;
83
84   void                          SetNivMax( int NivMax );
85   const int                     GetNivMax() const;
86
87   void                          SetDiamMin( double DiamMin );
88   const double                  GetDiamMin() const;
89
90   void                          SetAdapInit( int AdapInit );
91   const int                     GetAdapInit() const;
92
93   void                          SetLevelOutput( int LevelOutput );
94   const int                     GetLevelOutput() const;
95
96   void                          AddGroup( const char* LeGroupe);
97   void                          SetGroups(const std::list<std::string>& ListGroup );
98   const std::list<std::string>& GetGroups() const;
99
100   void                          SetTypeFieldInterp( int TypeFieldInterp );
101   int                           GetTypeFieldInterp() const;
102   void                          AddFieldInterpType( const char* FieldInterp, int TypeInterp );
103   void                          SupprFieldInterp( const char* FieldInterp );
104   void                          SupprFieldInterps();
105   const std::list<std::string>& GetFieldInterps() const;
106
107 // Liens avec les autres structures
108   void                          SetCaseCreation( const char* NomCasCreation );
109   std::string                   GetCaseCreation() const;
110
111   void                          LinkIteration( const char* NomIter );
112   void                          UnLinkIteration( const char* NomIter );
113   void                          UnLinkIterations();
114   const std::list<std::string>& GetIterations() const;
115
116   void                          AddZone( const char* NomZone, int TypeUse );
117   void                          SupprZone( const char* NomZone );
118   void                          SupprZones();
119   const std::list<std::string>& GetZones() const;
120
121 private:
122   std::string                   _Name;
123   std::string                   _NomCasCreation;
124
125   int                           _TypeAdap; // -1 pour une adapation Uniforme,
126                                            //  0 si l adaptation depend des zones,
127                                            //  1 pour des champs
128
129   int                           _TypeRaff;
130   int                           _TypeDera;
131
132   std::string                   _Field;
133   int                           _TypeThR;
134   int                           _TypeThC;
135   double                        _ThreshR;
136   double                        _ThreshC;
137   int                           _UsField;
138   int                           _UsCmpI;
139   int                           _TypeFieldInterp; // 0 pour aucune interpolation,
140                                                   // 1 pour interpolation de tous les champs,
141                                                   // 2 pour une liste
142   int                           _NivMax;
143   double                        _DiamMin;
144   int                           _AdapInit;
145   int                           _LevelOutput;
146
147   std::list<std::string>        _ListIter;
148   std::list<std::string>        _ListZone;
149   std::list<std::string>        _ListComp;
150   std::list<std::string>        _ListGroupSelected;
151   std::list<std::string>        _ListFieldInterp;
152
153 };
154
155 #endif