Salome HOME
Porting HOMARD SALOME module on WIN32 platform.
[modules/homard.git] / src / HOMARD_I / HOMARD_Iteration_i.hxx
1 // Copyright (C) 2011-2013  CEA/DEN, EDF R&D
2 //
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.
7 //
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.
12 //
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
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19 // Remarques :
20 // L'ordre de description des fonctions est le meme dans tous les fichiers
21 // HOMARD_aaaa.idl, HOMARD_aaaa.hxx, HOMARD_aaaa.cxx, HOMARD_aaaa_i.hxx, HOMARD_aaaa_i.cxx :
22 // 1. Les generalites : Name, Delete, DumpPython, Dump, Restore
23 // 2. Les caracteristiques
24 // 3. Le lien avec les autres structures
25 //
26 // Quand les 2 fonctions Setxxx et Getxxx sont presentes, Setxxx est decrit en premier
27 //
28
29 #ifndef _HOMARD_ITERATION_I_HXX_
30 #define _HOMARD_ITERATION_I_HXX_
31
32 #include <SALOMEconfig.h>
33 #include CORBA_SERVER_HEADER(HOMARD_Gen)
34 #include CORBA_SERVER_HEADER(HOMARD_Iteration)
35
36 #include "HOMARD_i.hxx"
37 #include "SALOME_Component_i.hxx"
38 #include "SALOME_NamingService.hxx"
39 #include "Utils_CorbaException.hxx"
40
41 #include <string>
42
43 class HOMARD_Iteration;
44
45 class HOMARDENGINE_EXPORT HOMARD_Iteration_i:
46   public virtual Engines_Component_i,
47   public virtual POA_HOMARD::HOMARD_Iteration,
48   public virtual PortableServer::ServantBase
49 {
50 public:
51   HOMARD_Iteration_i( CORBA::ORB_ptr orb,
52                       HOMARD::HOMARD_Gen_var gen_i );
53   HOMARD_Iteration_i();
54
55   virtual ~HOMARD_Iteration_i();
56
57 // Generalites
58   void                   SetName( const char* Name );
59   char*                  GetName();
60
61   CORBA::Long            Delete( CORBA::Long Option );
62
63   char*                  GetDumpPython();
64
65   std::string            Dump() const;
66   bool                   Restore( const std::string& stream );
67
68 // Caracteristiques
69   void                   SetDirNameLoc( const char* NomDir );
70   char*                  GetDirNameLoc();
71
72   char*                  GetDirName();
73
74   void                   SetNumber( CORBA::Long NumIter );
75   CORBA::Long            GetNumber();
76
77   void                   SetState( CORBA::Long etat );
78   CORBA::Long            GetState();
79
80   void                   SetMeshName( const char* NomMesh );
81   char*                  GetMeshName();
82
83   void                   SetMeshFile( const char* MeshFile );
84   char*                  GetMeshFile();
85
86   void                   SetFieldFile( const char* FieldFile );
87   char*                  GetFieldFile();
88 // Instants pour le champ de pilotage
89   void                   SetTimeStep( CORBA::Long TimeStep );
90   void                   SetTimeStepRank( CORBA::Long TimeStep, CORBA::Long Rank );
91   void                   SetTimeStepRankLast();
92   CORBA::Long            GetTimeStep();
93   CORBA::Long            GetRank();
94 // Instants pour un champ a interpoler
95   void                   SetFieldInterpTimeStep( const char* FieldInterp, CORBA::Long TimeStep );
96   void                   SetFieldInterpTimeStepRank( const char* FieldInterp, CORBA::Long TimeStep, CORBA::Long Rank );
97   HOMARD::listeFieldInterpTSRsIter* GetFieldInterpsTimeStepRank();
98   void                   SetFieldInterp( const char* FieldInterp );
99   HOMARD::listeFieldInterpsIter* GetFieldInterps();
100   void                   SupprFieldInterps();
101
102   void                   SetLogFile( const char* LogFile );
103   char*                  GetLogFile();
104
105   CORBA::Long            Compute(CORBA::Long etatMenage, CORBA::Long Option);
106
107   void                   MeshInfo(CORBA::Long Qual, CORBA::Long Diam, CORBA::Long Conn, CORBA::Long Tail, CORBA::Long Inte);
108
109   void                   MeshInfoOption(CORBA::Long Qual, CORBA::Long Diam, CORBA::Long Conn, CORBA::Long Tail, CORBA::Long Inte, CORBA::Long Option);
110
111   void                   SetFileInfo( const char* FileInfo );
112   char*                  GetFileInfo();
113
114   // Liens avec les autres iterations
115   HOMARD::HOMARD_Iteration_ptr NextIteration( const char* Name) ;
116
117   void                   LinkNextIteration( const char* NomIteration );
118   void                   UnLinkNextIteration( const char* NomIteration );
119   HOMARD::listeIterFilles* GetIterations();
120
121   void                   SetIterParentName( const char* NomIterParent );
122   char*                  GetIterParentName();
123   HOMARD::HOMARD_Iteration_ptr GetIterParent() ;
124
125 // Liens avec les autres structures
126   void                   SetCaseName( const char* NomCas );
127   char*                  GetCaseName();
128
129   void                   AssociateHypo( const char* NomHypo);
130   void                   SetHypoName( const char* NomHypo );
131   char*                  GetHypoName();
132
133 // Divers
134   void                   SetInfoCompute( CORBA::Long MessInfo );
135   CORBA::Long            GetInfoCompute();
136
137 private:
138   ::HOMARD_Iteration*    myHomardIteration;
139
140   CORBA::ORB_ptr         _orb;
141   HOMARD::HOMARD_Gen_var _gen_i;
142 };
143
144 #endif