Version: 9.16.0
MED_Common.hxx
Go to the documentation of this file.
1// Copyright (C) 2007-2026 CEA, EDF, OPEN CASCADE
2//
3// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
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, or (at your option) any later version.
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
23#ifndef MED_Common_HeaderFile
24#define MED_Common_HeaderFile
25
26#include "MED_WrapperDef.hxx"
27#include "MED_Vector.hxx"
28#include "MED_SharedPtr.hxx"
29
30#include <string>
31#include <set>
32#include <map>
33
34#include <med.h>
35#include <smIdType.hxx>
36
37#ifdef WIN32
38#pragma warning(disable:4099)
39#endif
40
41namespace MED
42{
43 typedef enum {eFAUX, eVRAI} EBooleen;
44 typedef double TFloat;
45// #if defined(HAVE_F77INT64)
46// typedef long TInt;
47// #else
48// typedef int TInt;
49// #endif
50 typedef med_int TInt;
51 typedef hid_t TIdt;
52 typedef herr_t TErr;
53
55
56 typedef enum {eFLOAT64=6, eINT=24, eLONG=26} ETypeChamp;
57
59
60 typedef enum {eCART, eCYL, eSPHER} ERepere;
61
62 typedef enum {eNOD, eDESC} EConnectivite;
63
64 typedef enum {ePOINT1=1, eSEG2=102, eSEG3=103, eTRIA3=203,
65 eQUAD4=204, eTRIA6=206, eTRIA7=207, eQUAD8=208, eQUAD9=209, eTETRA4=304,
66 ePYRA5=305, ePENTA6=306, eHEXA8=308, eOCTA12=312, eTETRA10=310,
67 ePYRA13=313, ePENTA15=315, ePENTA18=318, eHEXA20=320, eHEXA27=327,
69 eBALL=1101, // no such a type in med.h, it's just a trick
71
73
75
77
79
84 typedef std::set<std::string> TStringSet;
85
86 typedef std::map<EGeometrieElement,TInt> TGeom2Size;
87 typedef std::map<EEntiteMaillage,TGeom2Size> TEntityInfo;
88
89 typedef std::set<EGeometrieElement> TGeomSet;
90 typedef std::map<EEntiteMaillage,TGeomSet> TEntity2GeomSet;
91
92 struct TNameInfo;
94
95 struct TMeshInfo;
97
98 struct TFamilyInfo;
100
101 struct TElemInfo;
103
104 struct TNodeInfo;
106
107 struct TPolygoneInfo;
109
110 struct TPolyedreInfo;
112
113 struct TCellInfo;
115
116 struct TBallInfo;
118
119 struct TFieldInfo;
121
122 struct TTimeStampInfo;
124
125 struct TProfileInfo;
127
128 struct TGaussInfo;
130
131 class TGrilleInfo;
133
134 struct TTimeStampValueBase;
136
137 struct TWrapper;
139
141 TInt
143
145 TInt
147
149 TInt
150 GetNOMLength();
151
153 TInt
155
157 TInt
159
161 void
163
165 TInt
167
169 TInt
171
173 const TEntity2GeomSet&
175}
176
177#endif // MED_Common_HeaderFile
#define MEDWRAPPER_EXPORT
Definition: MED_WrapperDef.hxx:33
Specialization of SharedPtr for TWrapper.
Definition: MED_Wrapper.hxx:967
To extend the boost::shared_ptr to support such features automatic dynamic cast.
Definition: MED_SharedPtr.hxx:37
Class that wraps the MED API.
Definition: MED_Wrapper.hxx:43
Definition: MED_Algorithm.cxx:28
SharedPtr< TMeshInfo > PMeshInfo
Definition: MED_Common.hxx:96
void GetVersionRelease(TInt &major, TInt &minor, TInt &release)
Definition: MED_Common.cxx:59
EEntiteMaillage
Definition: MED_Common.hxx:72
@ eSTRUCT_ELEMENT
Definition: MED_Common.hxx:72
@ eARETE
Definition: MED_Common.hxx:72
@ eNOEUD_ELEMENT
Definition: MED_Common.hxx:72
@ eNOEUD
Definition: MED_Common.hxx:72
@ eFACE
Definition: MED_Common.hxx:72
@ eMAILLE
Definition: MED_Common.hxx:72
TVector< std::string > TStringVector
Definition: MED_Common.hxx:83
TInt GetPNOMLength()
Definition: MED_Common.cxx:53
ERepere
Definition: MED_Common.hxx:60
@ eSPHER
Definition: MED_Common.hxx:60
@ eCART
Definition: MED_Common.hxx:60
@ eCYL
Definition: MED_Common.hxx:60
SharedPtr< TElemInfo > PElemInfo
Definition: MED_Common.hxx:102
TVector< TFloat > TFloatVector
Definition: MED_Common.hxx:82
SharedPtr< TFieldInfo > PFieldInfo
Definition: MED_Common.hxx:120
SharedPtr< TBallInfo > PBallInfo
Definition: MED_Common.hxx:117
SharedPtr< TTimeStampValueBase > PTimeStampValueBase
Definition: MED_Common.hxx:135
SharedPtr< TPolygoneInfo > PPolygoneInfo
Definition: MED_Common.hxx:108
SharedPtr< TProfileInfo > PProfileInfo
Definition: MED_Common.hxx:126
double TFloat
Definition: MED_Common.hxx:44
const MED::TEntity2GeomSet & GetEntity2GeomSet()
Definition: MED_Common.cxx:80
EModeProfil
Definition: MED_Common.hxx:74
@ eGLOBAL
Definition: MED_Common.hxx:74
@ eNO_PFLMOD
Definition: MED_Common.hxx:74
@ eCOMPACT
Definition: MED_Common.hxx:74
EGeometrieElement
Definition: MED_Common.hxx:64
@ eBALL
Definition: MED_Common.hxx:69
@ eTETRA10
Definition: MED_Common.hxx:66
@ eSEG2
Definition: MED_Common.hxx:64
@ eNONE
Definition: MED_Common.hxx:68
@ eHEXA8
Definition: MED_Common.hxx:66
@ eTRIA3
Definition: MED_Common.hxx:64
@ ePOLYGONE
Definition: MED_Common.hxx:68
@ eOCTA12
Definition: MED_Common.hxx:66
@ ePYRA5
Definition: MED_Common.hxx:66
@ eTRIA7
Definition: MED_Common.hxx:65
@ ePYRA13
Definition: MED_Common.hxx:67
@ ePENTA15
Definition: MED_Common.hxx:67
@ eTETRA4
Definition: MED_Common.hxx:65
@ eTRIA6
Definition: MED_Common.hxx:65
@ eHEXA20
Definition: MED_Common.hxx:67
@ eQUAD8
Definition: MED_Common.hxx:65
@ ePOLYGON2
Definition: MED_Common.hxx:68
@ ePENTA6
Definition: MED_Common.hxx:66
@ eAllGeoType
Definition: MED_Common.hxx:70
@ eHEXA27
Definition: MED_Common.hxx:67
@ eSEG3
Definition: MED_Common.hxx:64
@ eQUAD9
Definition: MED_Common.hxx:65
@ eQUAD4
Definition: MED_Common.hxx:65
@ ePOINT1
Definition: MED_Common.hxx:64
@ ePENTA18
Definition: MED_Common.hxx:67
@ ePOLYEDRE
Definition: MED_Common.hxx:68
std::set< EGeometrieElement > TGeomSet
Definition: MED_Common.hxx:89
std::map< EEntiteMaillage, TGeom2Size > TEntityInfo
Definition: MED_Common.hxx:87
SharedPtr< TFamilyInfo > PFamilyInfo
Definition: MED_Common.hxx:99
EConnectivite
Definition: MED_Common.hxx:62
@ eNOD
Definition: MED_Common.hxx:62
@ eDESC
Definition: MED_Common.hxx:62
SharedPtr< TWrapper > PWrapper
Definition: MED_Common.hxx:138
EMaillage
Definition: MED_Common.hxx:58
@ eNON_STRUCTURE
Definition: MED_Common.hxx:58
@ eSTRUCTURE
Definition: MED_Common.hxx:58
EBooleen
Definition: MED_Common.hxx:43
@ eFAUX
Definition: MED_Common.hxx:43
@ eVRAI
Definition: MED_Common.hxx:43
TVector< smIdType > TIDVector
Definition: MED_Common.hxx:81
TInt GetNbConn(EGeometrieElement typmai, EEntiteMaillage, TInt)
Definition: MED_Common.cxx:67
TVector< TInt > TIntVector
Definition: MED_Common.hxx:80
TInt GetLNOMLength()
Definition: MED_Common.cxx:47
TInt GetNbNodes(EGeometrieElement typmai)
Definition: MED_Common.cxx:75
SharedPtr< TGaussInfo > PGaussInfo
Definition: MED_Common.hxx:129
SharedPtr< TNameInfo > PNameInfo
Definition: MED_Common.hxx:93
herr_t TErr
Definition: MED_Common.hxx:52
med_int TInt
Definition: MED_Common.hxx:50
SharedPtr< TPolyedreInfo > PPolyedreInfo
Definition: MED_Common.hxx:111
TInt GetNOMLength()
Definition: MED_Common.cxx:41
TInt GetDESCLength()
Definition: MED_Common.cxx:29
EGrilleType
Definition: MED_Common.hxx:76
@ eGRILLE_POLAIRE
Definition: MED_Common.hxx:76
@ eGRILLE_CARTESIENNE
Definition: MED_Common.hxx:76
@ eGRILLE_STANDARD
Definition: MED_Common.hxx:76
ETypeChamp
Definition: MED_Common.hxx:56
@ eLONG
Definition: MED_Common.hxx:56
@ eINT
Definition: MED_Common.hxx:56
@ eFLOAT64
Definition: MED_Common.hxx:56
SharedPtr< TNodeInfo > PNodeInfo
Definition: MED_Common.hxx:105
SharedPtr< TCellInfo > PCellInfo
Definition: MED_Common.hxx:114
EModeSwitch
Definition: MED_Common.hxx:54
@ eFULL_INTERLACE
Definition: MED_Common.hxx:54
@ eNO_INTERLACE
Definition: MED_Common.hxx:54
SharedPtr< TGrilleInfo > PGrilleInfo
Definition: MED_Common.hxx:132
hid_t TIdt
Definition: MED_Common.hxx:51
std::map< EEntiteMaillage, TGeomSet > TEntity2GeomSet
Definition: MED_Common.hxx:90
std::set< std::string > TStringSet
Definition: MED_Common.hxx:84
std::map< EGeometrieElement, TInt > TGeom2Size
Definition: MED_Common.hxx:86
ETable
Definition: MED_Common.hxx:78
@ eNUM
Definition: MED_Common.hxx:78
@ eCONN
Definition: MED_Common.hxx:78
@ eCOOR_IND1
Definition: MED_Common.hxx:78
@ eCOOR_IND2
Definition: MED_Common.hxx:78
@ eCOOR_IND3
Definition: MED_Common.hxx:78
@ eNOM
Definition: MED_Common.hxx:78
@ eCOOR
Definition: MED_Common.hxx:78
@ eFAM
Definition: MED_Common.hxx:78
TInt GetIDENTLength()
Definition: MED_Common.cxx:35
SharedPtr< TTimeStampInfo > PTimeStampInfo
Definition: MED_Common.hxx:123
Define a class representing MED_BALL structure element.
Definition: MED_Structures.hxx:346
Define a base class which represents MED Cells entity.
Definition: MED_Structures.hxx:282
Define a parent class for all MED entities that describes mesh entities such as nodes and cells.
Definition: MED_Structures.hxx:188
Define a base class which represents MED Family entity.
Definition: MED_Structures.hxx:135
Define a base class which represents MED Field entity.
Definition: MED_Structures.hxx:393
The class represents MED Gauss entity.
Definition: MED_Structures.hxx:447
Define a base class which represents MED Grille (structured mesh)
Definition: MED_Structures.hxx:978
Define a base class which represents MED Mesh entity.
Definition: MED_Structures.hxx:112
Define a parent class for all named MED entities.
Definition: MED_Structures.hxx:80
Define a base class which represents MED Nodes entity.
Definition: MED_Structures.hxx:246
Define a base class which represents MED Polyedre entity.
Definition: MED_Structures.hxx:358
Define a base class which represents MED Polygon entity.
Definition: MED_Structures.hxx:309
The class represents MED Profile entity.
Definition: MED_Structures.hxx:544
Define a base class which represents MED TimeStamp.
Definition: MED_Structures.hxx:501
The class is a base class for MED TimeStamp values holder.
Definition: MED_Structures.hxx:775