Salome HOME
deecf6a8314ee7ce2fca8b5749a7d4248ece34c4
[modules/geom.git] / src / GEOM_I / GEOM_Field_i.hh
1 // Copyright (C) 2007-2021  CEA/DEN, EDF R&D, 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 _GEOM_Field_i_HeaderFile
24 #define _GEOM_Field_i_HeaderFile
25
26 #include "GEOMImpl_Gen.hxx"
27 #include "GEOM_BaseObject_i.hh"
28 #include "GEOM_Field.hxx"
29
30 #include <SALOMEconfig.h>
31 #include CORBA_SERVER_HEADER(GEOM_Gen)
32
33 #include <TopoDS_Shape.hxx>
34
35 //================================================================================
36 /*!
37  * \brief Class implementing GEOM::GEOM_Field interface
38  */
39 class GEOM_I_EXPORT GEOM_Field_i : public virtual POA_GEOM::GEOM_Field, public virtual GEOM_BaseObject_i
40 {
41  public:
42   GEOM_Field_i(PortableServer::POA_ptr thePOA, GEOM::GEOM_Gen_ptr theEngine, Handle(::GEOM_Field) theImpl);
43   ~GEOM_Field_i();
44
45   virtual GEOM::GEOM_Object_ptr GetShape();
46   virtual GEOM::field_data_type GetDataType();
47   virtual CORBA::Short GetDimension();
48   virtual GEOM::string_array* GetComponents();
49   virtual GEOM::GEOM_FieldStep_ptr AddStep(::CORBA::Long stepID, ::CORBA::Long stamp);
50   virtual void RemoveStep(::CORBA::Long stepID);
51   virtual CORBA::Long CountSteps();
52   virtual GEOM::ListOfLong* GetSteps();
53   virtual GEOM::GEOM_FieldStep_ptr GetStep(CORBA::Long stepID);
54   virtual ::CORBA::Boolean IsShape() { return false; }
55   virtual CORBA::Long GetArraySize();
56
57  private:
58
59   Handle(::GEOM_Field) _impl;
60 };
61
62 //================================================================================
63 /*!
64  * \brief Class implementing GEOM::GEOM_FieldStep interface
65  */
66 class GEOM_I_EXPORT GEOM_FieldStep_i : public virtual POA_GEOM::GEOM_FieldStep, public virtual GEOM_BaseObject_i
67 {
68  public:
69   GEOM_FieldStep_i(PortableServer::POA_ptr thePOA, GEOM::GEOM_Gen_ptr theEngine, Handle(::GEOM_FieldStep) theImpl);
70   ~GEOM_FieldStep_i();
71
72   virtual void SetStamp(::CORBA::Long stamp);
73   virtual ::CORBA::Long GetStamp();
74   virtual ::CORBA::Long GetID();
75   virtual GEOM::GEOM_Field_ptr GetField();
76   virtual ::CORBA::Boolean IsShape() { return false; }
77
78  protected:
79
80   Handle(::GEOM_FieldStep) _impl;
81 };
82
83 //================================================================================
84 /*!
85  * \brief Class implementing GEOM::GEOM_BoolFieldStep interface
86  */
87 class GEOM_I_EXPORT GEOM_BoolFieldStep_i : public virtual POA_GEOM::GEOM_BoolFieldStep, public virtual GEOM_FieldStep_i
88 {
89  public:
90   GEOM_BoolFieldStep_i(PortableServer::POA_ptr thePOA, GEOM::GEOM_Gen_ptr theEngine, Handle(::GEOM_FieldStep) theImpl);
91
92   virtual ::CORBA::Boolean SetValues(const ::GEOM::short_array& boolValues);
93   virtual GEOM::short_array* GetValues();
94 };
95
96 //================================================================================
97 /*!
98  * \brief Class implementing GEOM::GEOM_IntFieldStep interface
99  */
100 class GEOM_I_EXPORT GEOM_IntFieldStep_i : public virtual POA_GEOM::GEOM_IntFieldStep, public virtual GEOM_FieldStep_i
101 {
102  public:
103   GEOM_IntFieldStep_i(PortableServer::POA_ptr thePOA, GEOM::GEOM_Gen_ptr theEngine, Handle(::GEOM_FieldStep) theImpl);
104
105   virtual ::CORBA::Boolean SetValues(const ::GEOM::ListOfLong& intValues);
106   virtual GEOM::ListOfLong* GetValues();
107 };
108
109 //================================================================================
110 /*!
111  * \brief Class implementing GEOM::GEOM_DoubleFieldStep interface
112  */
113 class GEOM_I_EXPORT GEOM_DoubleFieldStep_i : public virtual POA_GEOM::GEOM_DoubleFieldStep, public virtual GEOM_FieldStep_i
114 {
115  public:
116   GEOM_DoubleFieldStep_i(PortableServer::POA_ptr thePOA, GEOM::GEOM_Gen_ptr theEngine, Handle(::GEOM_FieldStep) theImpl);
117
118   virtual ::CORBA::Boolean SetValues(const ::GEOM::ListOfDouble& doubleValues);
119   virtual GEOM::ListOfDouble* GetValues();
120 };
121
122 //================================================================================
123 /*!
124  * \brief Class implementing GEOM::GEOM_StringFieldStep interface
125  */
126 class GEOM_I_EXPORT GEOM_StringFieldStep_i : public virtual POA_GEOM::GEOM_StringFieldStep, public virtual GEOM_FieldStep_i
127 {
128  public:
129   GEOM_StringFieldStep_i(PortableServer::POA_ptr thePOA, GEOM::GEOM_Gen_ptr theEngine, Handle(::GEOM_FieldStep) theImpl);
130
131   virtual ::CORBA::Boolean SetValues(const ::GEOM::string_array& strValues);
132   virtual GEOM::string_array* GetValues();
133 };
134
135 #endif