Salome HOME
Add an Angle option in the cylinder primitive in order to build portion of cylinders...
[modules/geom.git] / src / GEOM_I_Superv / GEOM_Superv_i.cc
1 // Copyright (C) 2007-2014  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 #include "GEOM_Superv_i.hh"
24 #include "SALOME_LifeCycleCORBA.hxx"
25
26 #include CORBA_SERVER_HEADER(SALOME_Session)
27 #include "SALOMEDSClient_ClientFactory.hxx"
28
29 #define isNewStudy(a,b) (a > 0 && a != b)
30
31 //=============================================================================
32 //  constructor:
33 //=============================================================================
34 GEOM_Superv_i::GEOM_Superv_i(CORBA::ORB_ptr orb,
35                              PortableServer::POA_ptr poa,
36                              PortableServer::ObjectId * contId,
37                              const char *instanceName,
38                              const char *interfaceName) :
39   Engines_Component_i(orb, poa, contId, instanceName, interfaceName)
40 {
41   MESSAGE("GEOM_Superv_i::GEOM_Superv_i");
42
43   _thisObj = this ;
44   _id = _poa->activate_object(_thisObj);
45   name_service = new SALOME_NamingService(_orb);
46   //get RootPOA (the default)
47   //myPOA = PortableServer::RefCountServantBase::_default_POA();
48   CORBA::Object_var anObj = _orb->resolve_initial_references("RootPOA");
49   myPOA = PortableServer::POA::_narrow(anObj);
50
51   setGeomEngine();
52
53   myStudyID = -1;
54   myLastStudyID = -1;
55
56   myBasicOp = GEOM::GEOM_IBasicOperations::_nil();
57   my3DPrimOp = GEOM::GEOM_I3DPrimOperations::_nil();
58   myBoolOp = GEOM::GEOM_IBooleanOperations::_nil();
59   myInsOp = GEOM::GEOM_IInsertOperations::_nil();
60   myTransfOp = GEOM::GEOM_ITransformOperations::_nil();
61   myShapesOp = GEOM::GEOM_IShapesOperations::_nil();
62   myBlocksOp = GEOM::GEOM_IBlocksOperations::_nil();
63   myCurvesOp = GEOM::GEOM_ICurvesOperations::_nil();
64   myLocalOp = GEOM::GEOM_ILocalOperations::_nil();
65   myGroupOp = GEOM::GEOM_IGroupOperations::_nil();
66 }
67
68 //=============================================================================
69 //  destructor
70 //=============================================================================
71 GEOM_Superv_i::~GEOM_Superv_i()
72 {
73   MESSAGE("GEOM_Superv_i::~GEOM_Superv_i");
74   if (!CORBA::is_nil(myBasicOp))
75     myBasicOp->UnRegister();
76   if (!CORBA::is_nil(myBoolOp))
77     myBoolOp->UnRegister();
78   if (!CORBA::is_nil(my3DPrimOp))
79     my3DPrimOp->UnRegister();
80   delete name_service;
81 }
82
83 //============================================================================
84 // function : register()
85 // purpose  : register 'name' in 'name_service'
86 //============================================================================
87 void GEOM_Superv_i::register_name(char * name)
88 {
89   GEOM::GEOM_Superv_var g = _this();
90   name_service->Register(g, name);
91 }
92
93 //=============================================================================
94 //  setGEOMEngine:
95 //=============================================================================
96 void GEOM_Superv_i::setGeomEngine()
97 {
98   if ( !CORBA::is_nil(myGeomEngine) )
99     return;
100
101   // get GEOM_Gen engine
102   Engines::Container_var cont=GetContainerRef();
103   CORBA::String_var container_name=cont->name();
104   std::string shortName=container_name.in();
105   shortName=shortName.substr(12); // substract "/Containers/"
106   SALOME_LifeCycleCORBA* lcc = new SALOME_LifeCycleCORBA( name_service );
107   Engines::EngineComponent_var comp = lcc->FindOrLoad_Component( shortName.c_str(), "GEOM" );
108   delete lcc;
109
110   myGeomEngine = GEOM::GEOM_Gen::_narrow(comp);
111 }
112
113 //=============================================================================
114 //  SetStudyID:
115 //=============================================================================
116 void GEOM_Superv_i::SetStudyID( CORBA::Long theId )
117 {
118   // mkr : PAL10770 -->
119   myLastStudyID = myStudyID;
120
121   CORBA::Object_ptr anObject = name_service->Resolve("/Kernel/Session");
122   if ( !CORBA::is_nil(anObject) ) {
123     SALOME::Session_var aSession = SALOME::Session::_narrow(anObject);
124     if ( !CORBA::is_nil(aSession) ) {
125       int aStudyID = aSession->GetActiveStudyId();
126       if ( theId != aStudyID && aStudyID > 0) { // mkr : IPAL12128
127         MESSAGE("Warning : given study ID theId="<<theId<<" is wrong and will be replaced by the value "<<aStudyID);
128         myStudyID = aStudyID;
129       }
130       else
131         myStudyID = theId; // mkr : IPAL12128
132     }
133   }
134
135   if ( isNewStudy(myLastStudyID,myStudyID) ) {
136     if (CORBA::is_nil(myGeomEngine)) setGeomEngine();
137     std::string anEngine = _orb->object_to_string( myGeomEngine );
138
139     CORBA::Object_var anObj = name_service->Resolve("/myStudyManager");
140     if ( !CORBA::is_nil(anObj) ) {
141       SALOMEDS::StudyManager_var aStudyManager = SALOMEDS::StudyManager::_narrow(anObj);
142       if ( !CORBA::is_nil(aStudyManager) ) {
143         _PTR(Study) aDSStudy = ClientFactory::Study(aStudyManager->GetStudyByID(myStudyID));
144         if ( aDSStudy ) {
145           _PTR(SComponent) aSCO = aDSStudy->FindComponent(myGeomEngine->ComponentDataType());
146           if ( aSCO ) {
147             _PTR(StudyBuilder) aBuilder = aDSStudy->NewBuilder();
148             if ( aBuilder ) aBuilder->LoadWith( aSCO, anEngine );
149           }
150         }
151       }
152     }
153   }
154   // mkr : PAL10770 <--
155 }
156
157 //=============================================================================
158 //  CreateListOfGO:
159 //=============================================================================
160 GEOM::GEOM_List_ptr GEOM_Superv_i::CreateListOfGO()
161 {
162   MESSAGE("GEOM_Superv_i::CreateListOfGO()");
163   GEOM_List_i<GEOM::ListOfGO>* aListPtr = new GEOM_List_i<GEOM::ListOfGO>();
164   return aListPtr->_this();
165 }
166
167 //=============================================================================
168 //  AddItemToListOfGO:
169 //=============================================================================
170 void GEOM_Superv_i::AddItemToListOfGO(GEOM::GEOM_List_ptr& theList,
171                                       GEOM::GEOM_Object_ptr theObject)
172 {
173   MESSAGE("GEOM_Superv_i::AddItemToListOfGO(...)");
174   GEOM::GEOM_Object_var anObj =  GEOM::GEOM_Object::_duplicate(theObject);
175   if (GEOM_List_i<GEOM::ListOfGO>* aList =
176       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theList, myPOA).in())) {
177     aList->AddObject(anObj);
178     MESSAGE(" NewLength = "<<aList->GetList().length());
179   }
180 }
181
182 //=============================================================================
183 //  CreateListOfLong:
184 //=============================================================================
185 GEOM::GEOM_List_ptr GEOM_Superv_i::CreateListOfLong()
186 {
187   MESSAGE("GEOM_Superv_i::CreateListOfLong()");
188   GEOM_List_i<GEOM::ListOfLong>* aListPtr = new GEOM_List_i<GEOM::ListOfLong>();
189   return aListPtr->_this();
190 }
191
192 //=============================================================================
193 //  AddItemToListOfLong:
194 //=============================================================================
195 void GEOM_Superv_i::AddItemToListOfLong(GEOM::GEOM_List_ptr& theList,
196                                         CORBA::Long theObject)
197 {
198   MESSAGE("GEOM_Superv_i::AddItemToListOfLong(...)");
199   if (GEOM_List_i<GEOM::ListOfLong>* aList =
200       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theList, myPOA).in())) {
201     aList->AddObject(theObject);
202     MESSAGE(" NewLength = "<<aList->GetList().length());
203   }
204 }
205
206 //=============================================================================
207 //  CreateListOfDouble:
208 //=============================================================================
209 GEOM::GEOM_List_ptr GEOM_Superv_i::CreateListOfDouble()
210 {
211   MESSAGE("GEOM_Superv_i::CreateListOfDouble()");
212   GEOM_List_i<GEOM::ListOfDouble>* aListPtr = new GEOM_List_i<GEOM::ListOfDouble>();
213   return aListPtr->_this();
214 }
215
216 //=============================================================================
217 //  AddItemToListOfDouble:
218 //=============================================================================
219 void GEOM_Superv_i::AddItemToListOfDouble(GEOM::GEOM_List_ptr& theList,
220                                           CORBA::Double theObject)
221 {
222   MESSAGE("GEOM_Superv_i::AddItemToListOfDouble(...)");
223   if (GEOM_List_i<GEOM::ListOfDouble>* aList =
224       dynamic_cast<GEOM_List_i<GEOM::ListOfDouble>*>(GetServant(theList, myPOA).in())) {
225     aList->AddObject(theObject);
226     MESSAGE(" NewLength = "<<aList->GetList().length());
227   }
228 }
229
230 //=============================================================================
231 //  getBasicOp:
232 //=============================================================================
233 void GEOM_Superv_i::getBasicOp()
234 {
235   if (CORBA::is_nil(myGeomEngine))
236     setGeomEngine();
237   // get GEOM_IBasicOperations interface
238   if (CORBA::is_nil(myBasicOp) || isNewStudy(myLastStudyID,myStudyID)) {
239     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
240     //     Try to get id of the study from the SALOME Session
241     if(myStudyID < 0 ) SetStudyID(-1);
242     myBasicOp = myGeomEngine->GetIBasicOperations(myStudyID);
243   }
244 }
245
246 //=============================================================================
247 //  get3DPrimOp:
248 //=============================================================================
249 void GEOM_Superv_i::get3DPrimOp()
250 {
251   if (CORBA::is_nil(myGeomEngine))
252     setGeomEngine();
253   // get GEOM_I3DPrimOperations interface
254   if (CORBA::is_nil(my3DPrimOp) || isNewStudy(myLastStudyID,myStudyID)) {
255     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
256     //     Try to get id of the study from the SALOME Session
257     if(myStudyID < 0 ) SetStudyID(-1);
258     my3DPrimOp = myGeomEngine->GetI3DPrimOperations(myStudyID);
259   }
260 }
261
262 //=============================================================================
263 //  getBoolOp:
264 //=============================================================================
265 void GEOM_Superv_i::getBoolOp()
266 {
267   if (CORBA::is_nil(myGeomEngine))
268     setGeomEngine();
269   // get GEOM_IBooleanOperations interface
270   if (CORBA::is_nil(myBoolOp) || isNewStudy(myLastStudyID,myStudyID)) {
271     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
272     //     Try to get id of the study from the SALOME Session
273     if(myStudyID < 0 ) SetStudyID(-1);
274     myBoolOp = myGeomEngine->GetIBooleanOperations(myStudyID);
275   }
276 }
277
278 //=============================================================================
279 //  getInsOp:
280 //=============================================================================
281 void GEOM_Superv_i::getInsOp()
282 {
283   if (CORBA::is_nil(myGeomEngine))
284     setGeomEngine();
285   // get GEOM_IInsertOperations interface
286   if (CORBA::is_nil(myInsOp) || isNewStudy(myLastStudyID,myStudyID)) {
287     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
288     //     Try to get id of the study from the SALOME Session
289     if(myStudyID < 0 ) SetStudyID(-1);
290     myInsOp = myGeomEngine->GetIInsertOperations(myStudyID);
291   }
292 }
293
294 //=============================================================================
295 //  getTransfOp:
296 //=============================================================================
297 void GEOM_Superv_i::getTransfOp()
298 {
299   if (CORBA::is_nil(myGeomEngine))
300     setGeomEngine();
301   // get GEOM_ITransformOperations interface
302   if (CORBA::is_nil(myTransfOp) || isNewStudy(myLastStudyID,myStudyID)) {
303     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
304     //     Try to get id of the study from the SALOME Session
305     if(myStudyID < 0 ) SetStudyID(-1);
306     myTransfOp = myGeomEngine->GetITransformOperations(myStudyID);
307   }
308 }
309
310 //=============================================================================
311 //  getShapesOp:
312 //=============================================================================
313 void GEOM_Superv_i::getShapesOp()
314 {
315   if (CORBA::is_nil(myGeomEngine))
316     setGeomEngine();
317   // get GEOM_IShapesOperations interface
318   if (CORBA::is_nil(myShapesOp) || isNewStudy(myLastStudyID,myStudyID)) {
319     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
320     //     Try to get id of the study from the SALOME Session
321     if(myStudyID < 0 ) SetStudyID(-1);
322     myShapesOp = myGeomEngine->GetIShapesOperations(myStudyID);
323   }
324 }
325
326 //=============================================================================
327 //  getBlocksOp:
328 //=============================================================================
329 void GEOM_Superv_i::getBlocksOp()
330 {
331   if (CORBA::is_nil(myGeomEngine))
332     setGeomEngine();
333   // get GEOM_IBlocksOperations interface
334   if (CORBA::is_nil(myBlocksOp) || isNewStudy(myLastStudyID,myStudyID)) {
335     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
336     //     Try to get id of the study from the SALOME Session
337     if(myStudyID < 0 ) SetStudyID(-1);
338     myBlocksOp = myGeomEngine->GetIBlocksOperations(myStudyID);
339   }
340 }
341
342 //=============================================================================
343 //  getCurvesOp:
344 //=============================================================================
345 void GEOM_Superv_i::getCurvesOp()
346 {
347   if (CORBA::is_nil(myGeomEngine))
348     setGeomEngine();
349   // get GEOM_ICurvesOperations interface
350   if (CORBA::is_nil(myCurvesOp) || isNewStudy(myLastStudyID,myStudyID)) {
351     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
352     //     Try to get id of the study from the SALOME Session
353     if(myStudyID < 0 ) SetStudyID(-1);
354     myCurvesOp = myGeomEngine->GetICurvesOperations(myStudyID);
355   }
356 }
357
358 //=============================================================================
359 //  getLocalOp:
360 //=============================================================================
361 void GEOM_Superv_i::getLocalOp()
362 {
363   if (CORBA::is_nil(myGeomEngine))
364     setGeomEngine();
365   // get GEOM_ILocalOperations interface
366   if (CORBA::is_nil(myLocalOp) || isNewStudy(myLastStudyID,myStudyID)) {
367     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
368     //     Try to get id of the study from the SALOME Session
369     if(myStudyID < 0 ) SetStudyID(-1);
370     myLocalOp = myGeomEngine->GetILocalOperations(myStudyID);
371   }
372 }
373
374 //=============================================================================
375 //  getGroupOp:
376 //=============================================================================
377 void GEOM_Superv_i::getGroupOp()
378 {
379   if (CORBA::is_nil(myGeomEngine))
380     setGeomEngine();
381   // get GEOM_IGroupOperations interface
382   if (CORBA::is_nil(myGroupOp) || isNewStudy(myLastStudyID,myStudyID)) {
383     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
384     //     Try to get id of the study from the SALOME Session
385     if(myStudyID < 0 ) SetStudyID(-1);
386     myGroupOp = myGeomEngine->GetIGroupOperations(myStudyID);
387   }
388 }
389
390 //=============================================================================
391 //  getAdvancedOp:
392 //=============================================================================
393 void GEOM_Superv_i::getAdvancedOp()
394 {
395   if (CORBA::is_nil(myGeomEngine))
396     setGeomEngine();
397   // get GEOM_IAdvancedOperations interface
398   if (CORBA::is_nil(myAdvancedOp) || isNewStudy(myLastStudyID,myStudyID)) {
399     //rnv: to fix bug "IPAL22461 6.3.0: Incorrect study storage if study contains shape modified with YACS"
400     //     Try to get id of the study from the SALOME Session
401     if(myStudyID < 0 ) SetStudyID(-1);
402     //myAdvancedOp = myGeomEngine->GetIAdvancedOperations(myStudyID);
403     myAdvancedOp = GEOM::GEOM_IAdvancedOperations::_narrow(myGeomEngine->GetPluginOperations(myStudyID, "AdvancedEngine"));
404   }
405 }
406
407 //=============================================================================
408 //  GetServant:
409 //=============================================================================
410 PortableServer::ServantBase_var GEOM_Superv_i::GetServant(CORBA::Object_ptr       theObject,
411                                                           PortableServer::POA_ptr thePOA)
412 {
413   if(CORBA::is_nil(theObject))  return NULL;
414   PortableServer::Servant aServant = thePOA->reference_to_servant(theObject);
415   return aServant;
416 }
417
418 //============================================================================
419 // function : Save()
420 // purpose  : save OCAF/Geom document
421 //============================================================================
422 SALOMEDS::TMPFile* GEOM_Superv_i::Save(SALOMEDS::SComponent_ptr theComponent,
423                                        const char* theURL,
424                                        CORBA::Boolean isMultiFile)
425 {
426   SALOMEDS::TMPFile_var aStreamFile;
427   return aStreamFile._retn();
428 }
429
430 //============================================================================
431 // function : SaveASCII()
432 // purpose  :
433 //============================================================================
434 SALOMEDS::TMPFile* GEOM_Superv_i::SaveASCII(SALOMEDS::SComponent_ptr theComponent,
435                                             const char* theURL,
436                                             CORBA::Boolean isMultiFile)
437 {
438   SALOMEDS::TMPFile_var aStreamFile;
439   return aStreamFile._retn();
440 }
441
442 //============================================================================
443 // function : Load()
444 // purpose  :
445 //============================================================================
446 CORBA::Boolean GEOM_Superv_i::Load(SALOMEDS::SComponent_ptr theComponent,
447                                    const SALOMEDS::TMPFile& theStream,
448                                    const char* theURL,
449                                    CORBA::Boolean isMultiFile)
450 {
451   return false;
452 }
453
454 //============================================================================
455 // function : LoadASCII()
456 // purpose  :
457 //============================================================================
458 CORBA::Boolean GEOM_Superv_i::LoadASCII(SALOMEDS::SComponent_ptr theComponent,
459                                         const SALOMEDS::TMPFile& theStream,
460                                         const char* theURL,
461                                         CORBA::Boolean isMultiFile)
462 {
463   return false;
464 }
465
466 //============================================================================
467 // function : Close()
468 // purpose  :
469 //============================================================================
470 void GEOM_Superv_i::Close(SALOMEDS::SComponent_ptr theComponent)
471 {
472 }
473
474 //============================================================================
475 // function : ComponentDataType()
476 // purpose  :
477 //============================================================================
478 char* GEOM_Superv_i::ComponentDataType()
479 {
480   return 0;
481 }
482
483 //============================================================================
484 // function : IORToLocalPersistentID()
485 // purpose  :
486 //============================================================================
487 char* GEOM_Superv_i::IORToLocalPersistentID(SALOMEDS::SObject_ptr theSObject,
488                                             const char* IORString,
489                                             CORBA::Boolean isMultiFile,
490                                             CORBA::Boolean isASCII)
491 {
492   return 0;
493 }
494
495 //============================================================================
496 // function : LocalPersistentIDToIOR()
497 // purpose  : Create/Load CORBA object from a persistent ref (an entry)
498 //          : Used when a study is loaded
499 //          : The IOR (IORName) of object created is returned
500 //============================================================================
501 char* GEOM_Superv_i::LocalPersistentIDToIOR(SALOMEDS::SObject_ptr theSObject,
502                                             const char* aLocalPersistentID,
503                                             CORBA::Boolean isMultiFile,
504                                             CORBA::Boolean isASCII)
505 {
506   return 0;
507 }
508
509 //============================================================================
510 // function : CanPublishInStudy
511 // purpose  :
512 //============================================================================
513 CORBA::Boolean GEOM_Superv_i::CanPublishInStudy(CORBA::Object_ptr theIOR)
514 {
515   if (CORBA::is_nil(myGeomEngine))
516     setGeomEngine();
517   return myGeomEngine->CanPublishInStudy(theIOR);
518 }
519
520 //============================================================================
521 // function : PublishInStudy
522 // purpose  :
523 //============================================================================
524 SALOMEDS::SObject_ptr GEOM_Superv_i::PublishInStudy(SALOMEDS::Study_ptr theStudy,
525                                                     SALOMEDS::SObject_ptr theSObject,
526                                                     CORBA::Object_ptr theObject,
527                                                     const char* theName) throw (SALOME::SALOME_Exception)
528 {
529   if (CORBA::is_nil(myGeomEngine))
530     setGeomEngine();
531   return myGeomEngine->PublishInStudy(theStudy, theSObject, theObject, theName);
532 }
533
534 //============================================================================
535 // function : PublishNamedShapesInStudy
536 // purpose  :
537 //============================================================================
538 GEOM::ListOfGO*
539 GEOM_Superv_i::PublishNamedShapesInStudy(SALOMEDS::Study_ptr theStudy,
540                                          //SALOMEDS::SObject_ptr theSObject,
541                                          CORBA::Object_ptr theObject)
542 {
543   if (CORBA::is_nil(myGeomEngine))
544     setGeomEngine();
545   return myGeomEngine->PublishNamedShapesInStudy(theStudy, theObject);
546 }
547
548 //============================================================================
549 // function : CanCopy()
550 // purpose  :
551 //============================================================================
552 CORBA::Boolean GEOM_Superv_i::CanCopy(SALOMEDS::SObject_ptr theObject)
553 {
554   return false;
555 }
556
557 //============================================================================
558 // function : CopyFrom()
559 // purpose  :
560 //============================================================================
561 SALOMEDS::TMPFile* GEOM_Superv_i::CopyFrom(SALOMEDS::SObject_ptr theObject, CORBA::Long& theObjectID)
562 {
563   SALOMEDS::TMPFile_var aStreamFile;
564   return aStreamFile._retn();
565 }
566
567 //============================================================================
568 // function : CanPaste()
569 // purpose  :
570 //============================================================================
571 CORBA::Boolean GEOM_Superv_i::CanPaste(const char* theComponentName, CORBA::Long theObjectID)
572 {
573   return false;
574 }
575
576 //============================================================================
577 // function : PasteInto()
578 // purpose  :
579 //============================================================================
580 SALOMEDS::SObject_ptr GEOM_Superv_i::PasteInto(const SALOMEDS::TMPFile& theStream,
581                                                CORBA::Long theObjectID,
582                                                SALOMEDS::SObject_ptr theObject)
583 {
584   SALOMEDS::SObject_var aNewSO;
585   return aNewSO._retn();
586 }
587
588 //================= Primitives Construction : BasicOperations =================
589 //=============================================================================
590 //  MakePointXYZ:
591 //=============================================================================
592 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePointXYZ(CORBA::Double theX,
593                                                   CORBA::Double theY,
594                                                   CORBA::Double theZ)
595 {
596   beginService( " GEOM_Superv_i::MakePointXYZ" );
597   MESSAGE("GEOM_Superv_i::MakePointXYZ");
598   getBasicOp();
599   // make vertex and return
600   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePointXYZ(theX, theY, theZ);
601   endService( " GEOM_Superv_i::MakePointXYZ" );
602   return anObj;
603 }
604
605 //=============================================================================
606 //  MakePointWithReference:
607 //=============================================================================
608 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePointWithReference (GEOM::GEOM_Object_ptr theReference,
609                                                              CORBA::Double theX,
610                                                              CORBA::Double theY,
611                                                              CORBA::Double theZ)
612 {
613   beginService( " GEOM_Superv_i::MakePointWithReference" );
614   MESSAGE("GEOM_Superv_i::MakePointWithReference");
615   getBasicOp();
616   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePointWithReference(theReference, theX, theY, theZ);
617   endService( " GEOM_Superv_i::MakePointWithReference" );
618   return anObj;
619 }
620
621 //=============================================================================
622 //  MakePointOnCurve:
623 //=============================================================================
624 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePointOnCurve (GEOM::GEOM_Object_ptr theRefCurve,
625                                                        CORBA::Double theParameter)
626 {
627   beginService( " GEOM_Superv_i::MakePointOnCurve" );
628   MESSAGE("GEOM_Superv_i::MakePointOnCurve");
629   getBasicOp();
630   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePointOnCurve(theRefCurve, theParameter);
631   endService( " GEOM_Superv_i::MakePointOnCurve" );
632   return anObj;
633 }
634
635 //=============================================================================
636 //  MakePointOnCurveByLength:
637 //=============================================================================
638 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePointOnCurveByLength (GEOM::GEOM_Object_ptr theRefCurve,
639                                                                CORBA::Double theLength,
640                                                                GEOM::GEOM_Object_ptr theStartPoint)
641 {
642   beginService( " GEOM_Superv_i::MakePointOnCurveByLength" );
643   MESSAGE("GEOM_Superv_i::MakePointOnCurveByLength");
644   getBasicOp();
645   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePointOnCurveByLength(theRefCurve, theLength, theStartPoint);
646   endService( " GEOM_Superv_i::MakePointOnCurveByLength" );
647   return anObj;
648 }
649
650 //=============================================================================
651 //  MakePointOnCurveByCoord
652 //=============================================================================
653 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePointOnCurveByCoord (GEOM::GEOM_Object_ptr theRefCurve,
654                                                               CORBA::Double theXParameter,
655                                                               CORBA::Double theYParameter,
656                                                               CORBA::Double theZParameter)
657 {
658   beginService( " GEOM_Superv_i::MakePointOnCurveByCoord" );
659   MESSAGE("GEOM_Superv_i::MakePointOnCurveByCoord");
660   getBasicOp();
661   GEOM::GEOM_Object_ptr anObj =
662     myBasicOp->MakePointOnCurveByCoord(theRefCurve, theXParameter,
663                                 theYParameter, theZParameter);
664   endService( " GEOM_Superv_i::MakePointOnCurveByCoord" );
665   return anObj;
666 }
667
668 //=============================================================================
669 //  MakePointOnSurface:
670 //=============================================================================
671 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePointOnSurface (GEOM::GEOM_Object_ptr theRefSurface,
672                                                          CORBA::Double theUParameter,
673                                                          CORBA::Double theVParameter)
674 {
675   beginService( " GEOM_Superv_i::MakePointOnSurface" );
676   MESSAGE("GEOM_Superv_i::MakePointOnSurface");
677   getBasicOp();
678   GEOM::GEOM_Object_ptr anObj =
679     myBasicOp->MakePointOnSurface(theRefSurface, theUParameter, theVParameter);
680   endService( " GEOM_Superv_i::MakePointOnSurface" );
681   return anObj;
682 }
683
684 //=============================================================================
685 //  MakePointOnSurfaceByCoord
686 //=============================================================================
687 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePointOnSurfaceByCoord (GEOM::GEOM_Object_ptr theRefSurface,
688                                                                 CORBA::Double theXParameter,
689                                                                 CORBA::Double theYParameter,
690                                                                 CORBA::Double theZParameter)
691 {
692   beginService( " GEOM_Superv_i::MakePointOnSurfaceByCoord" );
693   MESSAGE("GEOM_Superv_i::MakePointOnSurfaceByCoord");
694   getBasicOp();
695   GEOM::GEOM_Object_ptr anObj =
696     myBasicOp->MakePointOnSurfaceByCoord(theRefSurface, theXParameter,
697                                 theYParameter, theZParameter);
698   endService( " GEOM_Superv_i::MakePointOnSurfaceByCoord" );
699   return anObj;
700 }
701
702 //=============================================================================
703 //  MakePointOnLinesIntersection:
704 //=============================================================================
705 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePointOnLinesIntersection (GEOM::GEOM_Object_ptr theRefLine1,
706                                                                    GEOM::GEOM_Object_ptr theRefLine2)
707 {
708   beginService( " GEOM_Superv_i::MakePointOnLinesIntersection" );
709   MESSAGE("GEOM_Superv_i::MakePointOnLinesIntersection");
710   getBasicOp();
711   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePointOnLinesIntersection(theRefLine1, theRefLine2);
712   endService( " GEOM_Superv_i::MakePointOnLinesIntersection" );
713   return anObj;
714 }
715
716 //=============================================================================
717 //  MakeTangentOnCurve:
718 //=============================================================================
719 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeTangentOnCurve (GEOM::GEOM_Object_ptr theRefCurve,
720                                                          CORBA::Double theParameter)
721 {
722   beginService( " GEOM_Superv_i::MakeTangentOnCurve" );
723   MESSAGE("GEOM_Superv_i::MakeTangentOnCurve");
724   getBasicOp();
725   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakeTangentOnCurve(theRefCurve, theParameter);
726   endService( " GEOM_Superv_i::MakeTangentOnCurve" );
727   return anObj;
728 }
729
730 //=============================================================================
731 //  MakeVectorDXDYDZ:
732 //=============================================================================
733 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeVectorDXDYDZ (CORBA::Double theDX,
734                                                        CORBA::Double theDY,
735                                                        CORBA::Double theDZ)
736 {
737   beginService( " GEOM_Superv_i::MakeVectorDXDYDZ" );
738   MESSAGE("GEOM_Superv_i::MakeVectorDXDYDZ");
739   getBasicOp();
740   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakeVectorDXDYDZ(theDX, theDY, theDZ);
741   endService( " GEOM_Superv_i::MakeVectorDXDYDZ" );
742   return anObj;
743 }
744
745 //=============================================================================
746 //  MakeVectorTwoPnt:
747 //=============================================================================
748 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeVectorTwoPnt (GEOM::GEOM_Object_ptr thePnt1,
749                                                        GEOM::GEOM_Object_ptr thePnt2)
750 {
751   beginService( " GEOM_Superv_i::MakeVectorTwoPnt" );
752   MESSAGE("GEOM_Superv_i::MakeVector");
753   getBasicOp();
754   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakeVectorTwoPnt(thePnt1, thePnt2);
755   endService( " GEOM_Superv_i::MakeVectorTwoPnt" );
756   return anObj;
757 }
758
759 //=============================================================================
760 //  MakeLineTwoPnt:
761 //=============================================================================
762 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeLineTwoPnt (GEOM::GEOM_Object_ptr thePnt1,
763                                                      GEOM::GEOM_Object_ptr thePnt2)
764 {
765   beginService( " GEOM_Superv_i::MakeLineTwoPnt");
766   MESSAGE("GEOM_Superv_i::MakeLineTwoPnt");
767   getBasicOp();
768   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakeLineTwoPnt(thePnt1, thePnt2);
769   endService( " GEOM_Superv_i::MakeLineTwoPnt");
770   return anObj;
771 }
772
773 //=============================================================================
774 //  MakeLineTwoFaces:
775 //=============================================================================
776 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeLineTwoFaces (GEOM::GEOM_Object_ptr theFace1,
777                                                        GEOM::GEOM_Object_ptr theFace2)
778 {
779   beginService( " GEOM_Superv_i::MakeLineTwoFaces");
780   MESSAGE("GEOM_Superv_i::MakeLineTwoFaces");
781   getBasicOp();
782   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakeLineTwoFaces(theFace1, theFace2);
783   endService( " GEOM_Superv_i::MakeLineTwoFaces");
784   return anObj;
785 }
786
787 //=============================================================================
788 //  MakePlaneThreePnt:
789 //=============================================================================
790 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePlaneThreePnt (GEOM::GEOM_Object_ptr thePnt1,
791                                                         GEOM::GEOM_Object_ptr thePnt2,
792                                                         GEOM::GEOM_Object_ptr thePnt3,
793                                                         CORBA::Double theTrimSize)
794 {
795   beginService( " GEOM_Superv_i::MakePlaneThreePnt");
796   MESSAGE("GEOM_Superv_i::MakePlaneThreePnt");
797   getBasicOp();
798   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePlaneThreePnt(thePnt1, thePnt2, thePnt3, theTrimSize);
799   endService( " GEOM_Superv_i::MakePlaneThreePnt");
800   return anObj;
801 }
802
803 //=============================================================================
804 //  MakePlanePntVec:
805 //=============================================================================
806 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePlanePntVec (GEOM::GEOM_Object_ptr thePnt,
807                                                       GEOM::GEOM_Object_ptr theVec,
808                                                       CORBA::Double theTrimSize)
809 {
810   beginService( " GEOM_Superv_i::MakePlanePntVec" );
811   MESSAGE("GEOM_Superv_i::MakePlanePntVec");
812   getBasicOp();
813   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePlanePntVec(thePnt, theVec, theTrimSize);
814   endService( " GEOM_Superv_i::MakePlanePntVec" );
815   return anObj;
816 }
817
818 //=============================================================================
819 //  MakePlaneFace:
820 //=============================================================================
821 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePlaneFace (GEOM::GEOM_Object_ptr theFace,
822                                                     CORBA::Double theTrimSize)
823 {
824   beginService( " GEOM_Superv_i::MakePlaneFace" );
825   MESSAGE("GEOM_Superv_i::MakePlaneFace");
826   getBasicOp();
827   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePlaneFace(theFace, theTrimSize);
828   endService( " GEOM_Superv_i::MakePlaneFace" );
829   return anObj;
830 }
831
832 //=============================================================================
833 //  MakePlane2Vec:
834 //=============================================================================
835 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePlane2Vec (GEOM::GEOM_Object_ptr theVec1,
836                                                     GEOM::GEOM_Object_ptr theVec2,
837                                                     CORBA::Double theTrimSize)
838 {
839   beginService( " GEOM_Superv_i::MakePlane2Vec" );
840   MESSAGE("GEOM_Superv_i::MakePlane2Vec");
841   getBasicOp();
842   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePlane2Vec(theVec1, theVec2, theTrimSize);
843   endService( " GEOM_Superv_i::MakePlane2Vec" );
844   return anObj;
845 }
846
847 //=============================================================================
848 //  MakePlaneLCS:
849 //=============================================================================
850 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePlaneLCS (GEOM::GEOM_Object_ptr theLCS,
851                                                    CORBA::Double theTrimSize,
852                                                    CORBA::Double theOrientation)
853 {
854   beginService( " GEOM_Superv_i::MakePlaneLCS" );
855   MESSAGE("GEOM_Superv_i::MakePlaneLCS");
856   getBasicOp();
857   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakePlaneLCS(theLCS, theTrimSize, theOrientation);
858   endService( " GEOM_Superv_i::MakePlaneLCS" );
859   return anObj;
860 }
861
862 //=============================================================================
863 //  MakeMarker:
864 //=============================================================================
865 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeMarker
866 (CORBA::Double theOX , CORBA::Double theOY , CORBA::Double theOZ,
867  CORBA::Double theXDX, CORBA::Double theXDY, CORBA::Double theXDZ,
868  CORBA::Double theYDX, CORBA::Double theYDY, CORBA::Double theYDZ)
869 {
870   beginService( " GEOM_Superv_i::MakeMarker" );
871   MESSAGE("GEOM_Superv_i::MakeMarker");
872   getBasicOp();
873   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakeMarker(theOX, theOY, theOZ, theXDX, theXDY, theXDZ, theYDX, theYDY, theYDZ);
874   endService( " GEOM_Superv_i::MakeMarker" );
875   return anObj;
876 }
877
878 //=============================================================================
879 //  MakeMarkerFromShape:
880 //=============================================================================
881 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeMarkerFromShape (GEOM::GEOM_Object_ptr theShape)
882 {
883   beginService( " GEOM_Superv_i::MakeMarkerFromShape" );
884   MESSAGE("GEOM_Superv_i::MakeMarkerFromShape");
885   getBasicOp();
886   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakeMarkerFromShape(theShape);
887   endService( " GEOM_Superv_i::MakeMarkerFromShape" );
888   return anObj;
889 }
890
891 //=============================================================================
892 //  MakeMarkerPntTwoVec:
893 //=============================================================================
894 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeMarkerPntTwoVec (GEOM::GEOM_Object_ptr theOrigin,
895                                                           GEOM::GEOM_Object_ptr theXVec,
896                                                           GEOM::GEOM_Object_ptr theYVec)
897 {
898   beginService( " GEOM_Superv_i::MakeMarkerPntTwoVec" );
899   MESSAGE("GEOM_Superv_i::MakeMarkerPntTwoVec");
900   getBasicOp();
901   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakeMarkerPntTwoVec(theOrigin, theXVec, theYVec);
902   endService( " GEOM_Superv_i::MakeMarkerPntTwoVec" );
903   return anObj;
904 }
905
906 //=============================================================================
907 //  MakeTangentPlaneOnFace:
908 //=============================================================================
909 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeTangentPlaneOnFace (GEOM::GEOM_Object_ptr theFace,
910                                                  CORBA::Double theParameterU,
911                                                  CORBA::Double theParameterV,
912                                                  CORBA::Double theTrimSize)
913 {
914   beginService( " GEOM_Superv_i::MakeTangentPlaneOnFace" );
915   MESSAGE("GEOM_Superv_i::MakeTangentPlaneOnFace");
916   getBasicOp();
917   GEOM::GEOM_Object_ptr anObj = myBasicOp->MakeTangentPlaneOnFace(theFace, theParameterU,theParameterV,theTrimSize);
918   endService( " GEOM_Superv_i::MakeTangentPlaneOnFace" );
919   return anObj;
920 }
921
922 //================= Primitives Construction : 3DPrimOperations ================
923 //=============================================================================
924 //  MakeBox:
925 //=============================================================================
926 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeBox (CORBA::Double theX1,
927                                               CORBA::Double theY1,
928                                               CORBA::Double theZ1,
929                                               CORBA::Double theX2,
930                                               CORBA::Double theY2,
931                                               CORBA::Double theZ2)
932 {
933   beginService( " GEOM_Superv_i::MakeBox" );
934   MESSAGE("GEOM_Superv_i::MakeBox");
935   getBasicOp();
936   get3DPrimOp();
937   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeBoxTwoPnt(myBasicOp->MakePointXYZ(theX1, theY1, theZ1),
938                                                           myBasicOp->MakePointXYZ(theX2, theY2, theZ2));
939   endService( " GEOM_Superv_i::MakeBox" );
940   return anObj;
941 }
942
943 //=============================================================================
944 //  MakeBoxDXDYDZ:
945 //=============================================================================
946 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeBoxDXDYDZ (CORBA::Double theDX,
947                                                     CORBA::Double theDY,
948                                                     CORBA::Double theDZ)
949 {
950   beginService( " GEOM_Superv_i::MakeBoxDXDYDZ" );
951   MESSAGE("GEOM_Superv_i::MakeBoxDXDYDZ");
952   get3DPrimOp();
953   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeBoxDXDYDZ(theDX, theDY, theDZ);
954   endService( " GEOM_Superv_i::MakeBoxDXDYDZ" );
955   return anObj;
956 }
957
958 //=============================================================================
959 //  MakeBoxTwoPnt:
960 //=============================================================================
961 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeBoxTwoPnt (GEOM::GEOM_Object_ptr thePnt1,
962                                                     GEOM::GEOM_Object_ptr thePnt2)
963 {
964   beginService( " GEOM_Superv_i::MakeBoxTwoPnt" );
965   MESSAGE("GEOM_Superv_i::MakeBoxTwoPnt");
966   get3DPrimOp();
967   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeBoxTwoPnt(thePnt1, thePnt2);
968   endService( " GEOM_Superv_i::MakeBoxTwoPnt" );
969   return anObj;
970 }
971
972 //=============================================================================
973 //  MakeFaceHW:
974 //=============================================================================
975 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFaceHW (CORBA::Double theH,
976                                                  CORBA::Double theW,
977                                                  CORBA::Short  theOrientation)
978 {
979   beginService( " GEOM_Superv_i::MakeFaceHW" );
980   MESSAGE("GEOM_Superv_i::MakeFaceHW");
981   get3DPrimOp();
982   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeFaceHW(theH, theW, theOrientation);
983   endService( " GEOM_Superv_i::MakeFaceHW" );
984   return anObj;
985 }
986
987 //=============================================================================
988 //  MakeFaceObjHW:
989 //=============================================================================
990 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFaceObjHW (GEOM::GEOM_Object_ptr theObj,
991                                                     CORBA::Double theH,
992                                                     CORBA::Double theW)
993 {
994   beginService( " GEOM_Superv_i::MakeFaceObjHW" );
995   MESSAGE("GEOM_Superv_i::MakeFaceObjHW");
996   get3DPrimOp();
997   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeFaceObjHW(theObj, theH, theW);
998   endService( " GEOM_Superv_i::MakeFaceObjHW" );
999   return anObj;
1000 }
1001
1002 //=============================================================================
1003 //  MakeDiskPntVecR:
1004 //=============================================================================
1005 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeDiskPntVecR (GEOM::GEOM_Object_ptr theCenter,
1006                                                       GEOM::GEOM_Object_ptr theVector,
1007                                                       CORBA::Double theR)
1008 {
1009   beginService( " GEOM_Superv_i::MakeDiskPntVecR" );
1010   MESSAGE("GEOM_Superv_i::MakeDiskPntVecR");
1011   get3DPrimOp();
1012   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeDiskPntVecR(theCenter, theVector, theR);
1013   endService( " GEOM_Superv_i::MakeDiskPntVecR" );
1014   return anObj;
1015 }
1016
1017 //=============================================================================
1018 //  MakeDiskThreePnt:
1019 //=============================================================================
1020 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeDiskThreePnt (GEOM::GEOM_Object_ptr thePnt1,
1021                                                        GEOM::GEOM_Object_ptr thePnt2,
1022                                                        GEOM::GEOM_Object_ptr thePnt3)
1023 {
1024   beginService( " GEOM_Superv_i::MakeDiskThreePnt" );
1025   MESSAGE("GEOM_Superv_i::MakeDiskThreePnt");
1026   get3DPrimOp();
1027   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeDiskThreePnt(thePnt1, thePnt2, thePnt3);
1028   endService( " GEOM_Superv_i::MakeDiskThreePnt" );
1029   return anObj;
1030 }
1031
1032 //=============================================================================
1033 //  MakeDiskR:
1034 //=============================================================================
1035 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeDiskR (CORBA::Double theR,
1036                                                 CORBA::Short  theOrientation)
1037 {
1038   beginService( " GEOM_Superv_i::MakeDiskR" );
1039   MESSAGE("GEOM_Superv_i::MakeDiskR");
1040   get3DPrimOp();
1041   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeDiskR(theR, theOrientation);
1042   endService( " GEOM_Superv_i::MakeDiskR" );
1043   return anObj;
1044 }
1045
1046 //=============================================================================
1047 //  MakeCylinderPntVecRH:
1048 //=============================================================================
1049 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeCylinderPntVecRH (GEOM::GEOM_Object_ptr thePnt,
1050                                                            GEOM::GEOM_Object_ptr theAxis,
1051                                                            CORBA::Double theRadius,
1052                                                            CORBA::Double theHeight,
1053                                                            CORBA::Double theAngle)
1054 {
1055   beginService( " GEOM_Superv_i::MakeCylinderPntVecRH" );
1056   MESSAGE("GEOM_Superv_i::MakeCylinderPntVecRH");
1057   get3DPrimOp();
1058   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeCylinderPntVecRH(thePnt, theAxis, theRadius, theHeight, theAngle);
1059   endService( " GEOM_Superv_i::MakeCylinderPntVecRH" );
1060   return anObj;
1061 }
1062
1063 //=============================================================================
1064 //  MakeCylinderRH:
1065 //=============================================================================
1066 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeCylinderRH (CORBA::Double theR,
1067                                                      CORBA::Double theH,
1068                                                      CORBA::Double theA)
1069 {
1070   beginService( " GEOM_Superv_i::MakeCylinderRH" );
1071   MESSAGE("GEOM_Superv_i::MakeCylinderRH");
1072   get3DPrimOp();
1073   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeCylinderRH(theR, theH, theA);
1074   endService( " GEOM_Superv_i::MakeCylinderRH" );
1075   return anObj;
1076 }
1077
1078 //=============================================================================
1079 //  MakeSphere:
1080 //=============================================================================
1081 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSphere  (CORBA::Double theX,
1082                                                   CORBA::Double theY,
1083                                                   CORBA::Double theZ,
1084                                                   CORBA::Double theRadius)
1085 {
1086   beginService( " GEOM_Superv_i::MakeSphepe" );
1087   MESSAGE("GEOM_Superv_i::MakeSphepe");
1088   getBasicOp();
1089   get3DPrimOp();
1090   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeSpherePntR(myBasicOp->MakePointXYZ(theX, theY, theZ), theRadius);
1091   endService( " GEOM_Superv_i::MakeSphepe" );
1092   return anObj;
1093 }
1094
1095 //=============================================================================
1096 //  MakeSphereR:
1097 //=============================================================================
1098 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSphereR (CORBA::Double theR)
1099 {
1100   beginService( " GEOM_Superv_i::MakeSphereR" );
1101   MESSAGE("GEOM_Superv_i::MakeSphereR");
1102   get3DPrimOp();
1103   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeSphereR(theR);
1104   endService( " GEOM_Superv_i::MakeSphereR" );
1105   return anObj;
1106 }
1107
1108 //=============================================================================
1109 //  MakeSpherePntR:
1110 //=============================================================================
1111 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSpherePntR (GEOM::GEOM_Object_ptr thePnt,
1112                                                      CORBA::Double theR)
1113 {
1114   beginService( " GEOM_Superv_i::MakeSpherePntR" );
1115   MESSAGE("GEOM_Superv_i::MakeSpherePntR");
1116   get3DPrimOp();
1117   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeSpherePntR(thePnt, theR);
1118   endService( " GEOM_Superv_i::MakeSpherePntR" );
1119   return anObj;
1120 }
1121
1122 //=============================================================================
1123 //  MakeTorusPntVecRR:
1124 //=============================================================================
1125 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeTorusPntVecRR (GEOM::GEOM_Object_ptr thePnt,
1126                                                         GEOM::GEOM_Object_ptr theVec,
1127                                                         CORBA::Double theRMajor,
1128                                                         CORBA::Double theRMinor)
1129 {
1130   beginService( " GEOM_Superv_i::MakeTorusPntVecRR" );
1131   MESSAGE("GEOM_Superv_i::MakeTorusPntVecRR");
1132   get3DPrimOp();
1133   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeTorusPntVecRR(thePnt, theVec, theRMajor, theRMinor);
1134   endService( " GEOM_Superv_i::MakeTorusPntVecRR" );
1135   return anObj;
1136 }
1137
1138 //=============================================================================
1139 //  MakeTorusRR:
1140 //=============================================================================
1141 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeTorusRR (CORBA::Double theRMajor,
1142                                                   CORBA::Double theRMinor)
1143 {
1144   beginService( " GEOM_Superv_i::MakeTorusRR" );
1145   MESSAGE("GEOM_Superv_i::MakeTorusRR");
1146   get3DPrimOp();
1147   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeTorusRR(theRMajor, theRMinor);
1148   endService( " GEOM_Superv_i::MakeTorusRR" );
1149   return anObj;
1150 }
1151
1152 //=============================================================================
1153 //  MakeConePntVecR1R2H:
1154 //=============================================================================
1155 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeConePntVecR1R2H (GEOM::GEOM_Object_ptr thePnt,
1156                                                           GEOM::GEOM_Object_ptr theAxis,
1157                                                           CORBA::Double theR1,
1158                                                           CORBA::Double theR2,
1159                                                           CORBA::Double theHeight)
1160 {
1161   beginService( " GEOM_Superv_i::MakeConePntVecR1R2H" );
1162   MESSAGE("GEOM_Superv_i::MakeConePntVecR1R2H");
1163   get3DPrimOp();
1164   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeConePntVecR1R2H(thePnt, theAxis, theR1, theR2, theHeight);
1165   endService( " GEOM_Superv_i::MakeConePntVecR1R2H" );
1166   return anObj;
1167 }
1168
1169 //=============================================================================
1170 //  MakeConeR1R2H:
1171 //=============================================================================
1172 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeConeR1R2H (CORBA::Double theR1,
1173                                                     CORBA::Double theR2,
1174                                                     CORBA::Double theHeight)
1175 {
1176   beginService( " GEOM_Superv_i::MakeConeR1R2H" );
1177   MESSAGE("GEOM_Superv_i::MakeConeR1R2H");
1178   get3DPrimOp();
1179   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeConeR1R2H(theR1, theR2, theHeight);
1180   endService( " GEOM_Superv_i::MakeConeR1R2H" );
1181   return anObj;
1182 }
1183
1184 //=============================================================================
1185 //  MakePrismVecH:
1186 //=============================================================================
1187 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePrismVecH (GEOM::GEOM_Object_ptr theBase,
1188                                                     GEOM::GEOM_Object_ptr theVec,
1189                                                     CORBA::Double         theH)
1190 {
1191   beginService( " GEOM_Superv_i::MakePrismVecH" );
1192   MESSAGE("GEOM_Superv_i::MakePrismVecH");
1193   get3DPrimOp();
1194   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakePrismVecH(theBase, theVec, theH);
1195   endService( " GEOM_Superv_i::MakePrismVecH" );
1196   return anObj;
1197 }
1198
1199 //=============================================================================
1200 //  MakePrismVecH2Ways:
1201 //=============================================================================
1202 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePrismVecH2Ways (GEOM::GEOM_Object_ptr theBase,
1203                                                          GEOM::GEOM_Object_ptr theVec,
1204                                                          CORBA::Double         theH)
1205 {
1206   beginService( " GEOM_Superv_i::MakePrismVecH2Ways" );
1207   MESSAGE("GEOM_Superv_i::MakePrismVecH2Ways");
1208   get3DPrimOp();
1209   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakePrismVecH2Ways(theBase, theVec, theH);
1210   endService( " GEOM_Superv_i::MakePrismVecH2Ways" );
1211   return anObj;
1212 }
1213
1214 //=============================================================================
1215 //  MakePrismTwoPnt:
1216 //=============================================================================
1217 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePrismTwoPnt (GEOM::GEOM_Object_ptr theBase,
1218                                                       GEOM::GEOM_Object_ptr thePoint1,
1219                                                       GEOM::GEOM_Object_ptr thePoint2)
1220 {
1221   beginService( " GEOM_Superv_i::MakePrismTwoPnt" );
1222   MESSAGE("GEOM_Superv_i::MakePrismTwoPnt");
1223   get3DPrimOp();
1224   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakePrismTwoPnt(theBase, thePoint1, thePoint2);
1225   endService( " GEOM_Superv_i::MakePrismTwoPnt" );
1226   return anObj;
1227 }
1228
1229 //=============================================================================
1230 //  MakePrismTwoPnt2Ways:
1231 //=============================================================================
1232 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePrismTwoPnt2Ways (GEOM::GEOM_Object_ptr theBase,
1233                                                            GEOM::GEOM_Object_ptr thePoint1,
1234                                                            GEOM::GEOM_Object_ptr thePoint2)
1235 {
1236   beginService( " GEOM_Superv_i::MakePrismTwoPnt2Ways" );
1237   MESSAGE("GEOM_Superv_i::MakePrismTwoPnt2Ways");
1238   get3DPrimOp();
1239   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakePrismTwoPnt2Ways(theBase, thePoint1, thePoint2);
1240   endService( " GEOM_Superv_i::MakePrismTwoPnt2Ways" );
1241   return anObj;
1242 }
1243
1244 //=============================================================================
1245 //  MakePrismDXDYDZ:
1246 //=============================================================================
1247 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePrismDXDYDZ (GEOM::GEOM_Object_ptr theBase,
1248                       CORBA::Double theDX, CORBA::Double theDY, CORBA::Double theDZ)
1249 {
1250   beginService( " GEOM_Superv_i::MakePrismDXDYDZ" );
1251   MESSAGE("GEOM_Superv_i::MakePrismDXDYDZ");
1252   get3DPrimOp();
1253   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakePrismDXDYDZ(theBase, theDX, theDY, theDZ);
1254   endService( " GEOM_Superv_i::MakePrismDXDYDZ" );
1255   return anObj;
1256 }
1257
1258 //=============================================================================
1259 //  MakePrismDXDYDZ:
1260 //=============================================================================
1261 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePrismDXDYDZ2Ways (GEOM::GEOM_Object_ptr theBase,
1262                       CORBA::Double theDX, CORBA::Double theDY, CORBA::Double theDZ)
1263 {
1264   beginService( " GEOM_Superv_i::MakePrismDXDYDZ2Ways" );
1265   MESSAGE("GEOM_Superv_i::MakePrismDXDYDZ2Ways");
1266   get3DPrimOp();
1267   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakePrismDXDYDZ2Ways(theBase, theDX, theDY, theDZ);
1268   endService( " GEOM_Superv_i::MakePrismDXDYDZ2Ways" );
1269   return anObj;
1270 }
1271
1272 //=============================================================================
1273 //  MakePipe:
1274 //=============================================================================
1275 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePipe (GEOM::GEOM_Object_ptr theBase,
1276                                                GEOM::GEOM_Object_ptr thePath)
1277 {
1278   beginService( " GEOM_Superv_i::MakePipe" );
1279   MESSAGE("GEOM_Superv_i::MakePipe");
1280   get3DPrimOp();
1281   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakePipe(theBase, thePath);
1282   endService( " GEOM_Superv_i::MakePipe" );
1283   return anObj;
1284 }
1285
1286 //=============================================================================
1287 //  MakeRevolutionAxisAngle:
1288 //=============================================================================
1289 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeRevolutionAxisAngle (GEOM::GEOM_Object_ptr theBase,
1290                                                               GEOM::GEOM_Object_ptr theAxis,
1291                                                               CORBA::Double theAngle)
1292 {
1293   beginService( " GEOM_Superv_i::MakeRevolutionAxisAngle" );
1294   MESSAGE("GEOM_Superv_i::MakeRevolutionAxisAngle");
1295   get3DPrimOp();
1296   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeRevolutionAxisAngle(theBase, theAxis, theAngle);
1297   endService( " GEOM_Superv_i::MakeRevolutionAxisAngle" );
1298   return anObj;
1299 }
1300
1301 //=============================================================================
1302 //  MakeRevolutionAxisAngle:
1303 //=============================================================================
1304 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeRevolutionAxisAngle2Ways (GEOM::GEOM_Object_ptr theBase,
1305                                                                    GEOM::GEOM_Object_ptr theAxis,
1306                                                                    CORBA::Double theAngle)
1307 {
1308   beginService( " GEOM_Superv_i::MakeRevolutionAxisAngle2Ways" );
1309   MESSAGE("GEOM_Superv_i::MakeRevolutionAxisAngle2Ways");
1310   get3DPrimOp();
1311   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeRevolutionAxisAngle2Ways(theBase, theAxis, theAngle);
1312   endService( " GEOM_Superv_i::MakeRevolutionAxisAngle2Ways" );
1313   return anObj;
1314 }
1315
1316 //=============================================================================
1317 //  MakeFilling:
1318 //=============================================================================
1319 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFilling (GEOM::GEOM_Object_ptr theShape,
1320                                                   CORBA::Long theMinDeg,
1321                                                   CORBA::Long theMaxDeg,
1322                                                   CORBA::Double theTol2D,
1323                                                   CORBA::Double theTol3D,
1324                                                   CORBA::Long theNbIter,
1325                                                   GEOM::filling_oper_method theMethod,
1326                                                   CORBA::Boolean theApprox)
1327 {
1328   beginService( " GEOM_Superv_i::MakeFilling" );
1329   MESSAGE("GEOM_Superv_i::MakeFilling");
1330   get3DPrimOp();
1331   GEOM::GEOM_Object_ptr anObj =
1332     my3DPrimOp->MakeFilling(theShape, theMinDeg, theMaxDeg, theTol2D, theTol3D,
1333                             theNbIter, theMethod, theApprox);
1334   endService( " GEOM_Superv_i::MakeFilling" );
1335   return anObj;
1336 }
1337
1338 //============================= BooleanOperations =============================
1339 //=============================================================================
1340 //  MakeBoolean:
1341 //=============================================================================
1342 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeBoolean
1343                                         (GEOM::GEOM_Object_ptr theShape1,
1344                                          GEOM::GEOM_Object_ptr theShape2,
1345                                          CORBA::Long           theOperation)
1346 {
1347   beginService( " GEOM_Superv_i::MakeBoolean" );
1348   // theOperation indicates the operation to be done:
1349   // 1 - Common, 2 - Cut, 3 - Fuse, 4 - Section
1350   MESSAGE("GEOM_Superv_i::MakeBoolean");
1351   getBoolOp();
1352   GEOM::GEOM_Object_ptr anObj =
1353     myBoolOp->MakeBoolean(theShape1, theShape2, theOperation, false);
1354   endService( " GEOM_Superv_i::MakeBoolean" );
1355   return anObj;
1356 }
1357
1358 //=============================================================================
1359 //  MakeThruSections:
1360 //=============================================================================
1361 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeThruSections(const GEOM::ListOfGO& theSeqSections,
1362                                          CORBA::Boolean theModeSolid,
1363                                          CORBA::Double thePreci,
1364                                          CORBA::Boolean theRuled)
1365 {
1366   beginService( " GEOM_Superv_i::MakeThruSections" );
1367   MESSAGE("GEOM_Superv_i::MakeThruSections");
1368   get3DPrimOp();
1369   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakeThruSections(theSeqSections, theModeSolid,thePreci,theRuled);
1370   endService( " GEOM_Superv_i::MakeThruSections" );
1371   return anObj;
1372 }
1373
1374 //=============================================================================
1375 //  MakePipe:
1376 //=============================================================================
1377 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePipeWithDifferentSections
1378                      (const GEOM::ListOfGO& theBases,
1379                       const GEOM::ListOfGO& theLocations,
1380                       GEOM::GEOM_Object_ptr thePath,
1381                       CORBA::Boolean theWithContact,
1382                       CORBA::Boolean theWithCorrections)
1383 {
1384   beginService( " GEOM_Superv_i::MakePipeWithDifferentSections" );
1385   MESSAGE("GEOM_Superv_i::MakePipeWithDifferentSections");
1386   get3DPrimOp();
1387   GEOM::GEOM_Object_ptr anObj = my3DPrimOp->MakePipeWithDifferentSections(theBases,theLocations, thePath,theWithContact,theWithCorrections);
1388   endService( " GEOM_Superv_i::MakePipeWithDifferentSections" );
1389   return anObj;
1390 }
1391
1392
1393 //=============================================================================
1394 //  MakePipe:
1395 //=============================================================================
1396 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePipeWithShellSections
1397                    (const GEOM::ListOfGO& theBases,
1398                     const GEOM::ListOfGO& theSubBases,
1399                     const GEOM::ListOfGO& theLocations,
1400                     GEOM::GEOM_Object_ptr thePath,
1401                     CORBA::Boolean theWithContact,
1402                     CORBA::Boolean theWithCorrections)
1403 {
1404   beginService( " GEOM_Superv_i::MakePipeWithShellSections" );
1405   MESSAGE("GEOM_Superv_i::MakePipeWithShellSections");
1406   get3DPrimOp();
1407   GEOM::GEOM_Object_ptr anObj =
1408     my3DPrimOp->MakePipeWithShellSections(theBases, theSubBases,
1409                                           theLocations, thePath,
1410                                           theWithContact, theWithCorrections);
1411   endService( " GEOM_Superv_i::MakePipeWithShellSections" );
1412   return anObj;
1413 }
1414
1415
1416 //=============================================================================
1417 //  MakePipe:
1418 //=============================================================================
1419 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePipeShellsWithoutPath
1420                    (const GEOM::ListOfGO& theBases,
1421                     const GEOM::ListOfGO& theLocations)
1422 {
1423   beginService( " GEOM_Superv_i::MakePipeShellsWithoutPath" );
1424   MESSAGE("GEOM_Superv_i::MakePipeShellsWithoutPath");
1425   get3DPrimOp();
1426   GEOM::GEOM_Object_ptr anObj =
1427     my3DPrimOp->MakePipeShellsWithoutPath(theBases,theLocations);
1428   endService( " GEOM_Superv_i::MakePipeShellsWithoutPath" );
1429   return anObj;
1430 }
1431
1432
1433 //=============================================================================
1434 //  MakePipe:
1435 //=============================================================================
1436 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePipeBiNormalAlongVector
1437                                                 (GEOM::GEOM_Object_ptr theBase,
1438                                                  GEOM::GEOM_Object_ptr thePath,
1439                                                  GEOM::GEOM_Object_ptr theVec)
1440 {
1441   beginService( " GEOM_Superv_i::MakePipeBiNormalAlongVector" );
1442   MESSAGE("GEOM_Superv_i::MakePipeBiNormalAlongVector");
1443   get3DPrimOp();
1444   GEOM::GEOM_Object_ptr anObj =
1445     my3DPrimOp->MakePipeBiNormalAlongVector(theBase, thePath, theVec);
1446   endService( " GEOM_Superv_i::MakePipeBiNormalAlongVector" );
1447   return anObj;
1448 }
1449
1450
1451 //=============================================================================
1452 //  MakeFuse:
1453 //=============================================================================
1454 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFuse
1455                                         (GEOM::GEOM_Object_ptr theShape1,
1456                                          GEOM::GEOM_Object_ptr theShape2)
1457 {
1458   beginService( " GEOM_Superv_i::MakeFuse" );
1459   MESSAGE("GEOM_Superv_i::MakeFuse");
1460   getBoolOp();
1461   GEOM::GEOM_Object_ptr anObj =
1462     myBoolOp->MakeBoolean(theShape1, theShape2, 3, false);
1463   endService( " GEOM_Superv_i::MakeFuse" );
1464   return anObj;
1465 }
1466
1467 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeCommon (GEOM::GEOM_Object_ptr theShape1,
1468                                                  GEOM::GEOM_Object_ptr theShape2)
1469 {
1470   beginService( " GEOM_Superv_i::MakeCommon" );
1471   MESSAGE("GEOM_Superv_i::MakeCommon");
1472   getBoolOp();
1473   GEOM::GEOM_Object_ptr anObj =
1474     myBoolOp->MakeBoolean(theShape1, theShape2, 1, false);
1475   endService( " GEOM_Superv_i::MakeCommon" );
1476   return anObj;
1477 }
1478
1479 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeCut (GEOM::GEOM_Object_ptr theShape1,
1480                                               GEOM::GEOM_Object_ptr theShape2)
1481 {
1482   beginService( " GEOM_Superv_i::MakeCut" );
1483   MESSAGE("GEOM_Superv_i::MakeCut");
1484   getBoolOp();
1485   GEOM::GEOM_Object_ptr anObj =
1486     myBoolOp->MakeBoolean(theShape1, theShape2, 2, false);
1487   endService( " GEOM_Superv_i::MakeCut" );
1488   return anObj;
1489 }
1490
1491 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSection (GEOM::GEOM_Object_ptr theShape1,
1492                                                   GEOM::GEOM_Object_ptr theShape2)
1493 {
1494   beginService( " GEOM_Superv_i::MakeCut" );
1495   MESSAGE("GEOM_Superv_i::MakeCut");
1496   getBoolOp();
1497   GEOM::GEOM_Object_ptr anObj =
1498     myBoolOp->MakeBoolean(theShape1, theShape2, 4, false);
1499   endService( " GEOM_Superv_i::MakeCut" );
1500   return anObj;
1501 }
1502
1503 //=============================================================================
1504 //  MakePartition:
1505 //=============================================================================
1506 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePartition (GEOM::GEOM_List_ptr   theShapes,
1507                                                     GEOM::GEOM_List_ptr   theTools,
1508                                                     GEOM::GEOM_List_ptr   theKeepInside,
1509                                                     GEOM::GEOM_List_ptr   theRemoveInside,
1510                                                     CORBA::Short      theLimit,
1511                                                     CORBA::Boolean    theRemoveWebs,
1512                                                     GEOM::GEOM_List_ptr theMaterials,
1513                                                     CORBA::Short theKeepNonlimitShapes)
1514 {
1515   beginService( " GEOM_Superv_i::MakePartition" );
1516   MESSAGE("GEOM_Superv_i::MakePartition");
1517   GEOM_List_i<GEOM::ListOfGO>* aListImplS =
1518     dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theShapes, myPOA).in());
1519   GEOM_List_i<GEOM::ListOfGO>* aListImplT =
1520     dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theTools, myPOA).in());
1521   GEOM_List_i<GEOM::ListOfGO>* aListImplKI =
1522     dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theKeepInside, myPOA).in());
1523   GEOM_List_i<GEOM::ListOfGO>* aListImplRI =
1524     dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theRemoveInside, myPOA).in());
1525   GEOM_List_i<GEOM::ListOfLong>* aListImplM =
1526     dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theMaterials, myPOA).in());
1527   if (aListImplS && aListImplT && aListImplKI && aListImplRI && aListImplM) {
1528     getBoolOp();
1529     GEOM::GEOM_Object_ptr anObj =
1530       myBoolOp->MakePartition(aListImplS->GetList(), aListImplT->GetList(),
1531                               aListImplKI->GetList(), aListImplRI->GetList(),
1532                               theLimit, theRemoveWebs, aListImplM->GetList(),
1533                               theKeepNonlimitShapes);
1534     endService( " GEOM_Superv_i::MakePartition" );
1535     return anObj;
1536   }
1537   endService( " GEOM_Superv_i::MakePartition" );
1538   return NULL;
1539 }
1540
1541 //=============================================================================
1542 //  MakeHalfPartition:
1543 //=============================================================================
1544 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeHalfPartition (GEOM::GEOM_Object_ptr theShape,
1545                                                         GEOM::GEOM_Object_ptr thePlane)
1546 {
1547   beginService( " GEOM_Superv_i::MakeHalfPartition" );
1548   MESSAGE("GEOM_Superv_i::MakeHalfPartition");
1549   getBoolOp();
1550   GEOM::GEOM_Object_ptr anObj =
1551     myBoolOp->MakeHalfPartition(theShape, thePlane);
1552   endService( " GEOM_Superv_i::MakeHalfPartition" );
1553   return anObj;
1554 }
1555
1556 //============================== InsertOperations =============================
1557 //=============================================================================
1558 //  MakeCopy:
1559 //=============================================================================
1560 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeCopy (GEOM::GEOM_Object_ptr theOriginal)
1561 {
1562   beginService( " GEOM_Superv_i::MakeCopy" );
1563   MESSAGE("GEOM_Superv_i::MakeCopy");
1564   getInsOp();
1565   GEOM::GEOM_Object_ptr anObj = myInsOp->MakeCopy(theOriginal);
1566   endService( " GEOM_Superv_i::MakeCopy" );
1567   return anObj;
1568 }
1569
1570 //=============================================================================
1571 //  Export:
1572 //=============================================================================
1573 void GEOM_Superv_i::Export (GEOM::GEOM_Object_ptr theObject,
1574                             const char*           theFileName,
1575                             const char*           theFormatName)
1576 {
1577   beginService( " GEOM_Superv_i::Export" );
1578   MESSAGE("GEOM_Superv_i::Export");
1579   getInsOp();
1580   myInsOp->Export(theObject, theFileName, theFormatName);
1581   endService( " GEOM_Superv_i::Export" );
1582 }
1583
1584 //=============================================================================
1585 //  Import:
1586 //=============================================================================
1587 GEOM::GEOM_Object_ptr GEOM_Superv_i::ImportFile (const char* theFileName,
1588                                                  const char* theFormatName)
1589 {
1590   beginService( " GEOM_Superv_i::ImportFile" );
1591   MESSAGE("GEOM_Superv_i::ImportFile");
1592   getInsOp();
1593   GEOM::ListOfGO* aSeq = myInsOp->ImportFile(theFileName, theFormatName);
1594   GEOM::GEOM_Object_ptr anObj;
1595   
1596   if (aSeq->length() > 0) {
1597     anObj = aSeq->operator[](0);
1598   }
1599
1600   endService( " GEOM_Superv_i::ImportFile" );
1601   return anObj;
1602 }
1603
1604 //=============================================================================
1605 //  ImportTranslators:
1606 //=============================================================================
1607 void GEOM_Superv_i::ImportTranslators (GEOM::string_array_out theFormats,
1608                                        GEOM::string_array_out thePatterns)
1609 {
1610   beginService( " GEOM_Superv_i::ImportTranslators" );
1611   MESSAGE("GEOM_Superv_i::ImportTranslators");
1612   getInsOp();
1613   myInsOp->ImportTranslators(theFormats, thePatterns);
1614   endService( " GEOM_Superv_i::ImportTranslators" );
1615 }
1616
1617 //=============================================================================
1618 //  ExportTranslators:
1619 //=============================================================================
1620 void GEOM_Superv_i::ExportTranslators (GEOM::string_array_out theFormats,
1621                                        GEOM::string_array_out thePatterns)
1622 {
1623   beginService( " GEOM_Superv_i::ExportTranslators" );
1624   MESSAGE("GEOM_Superv_i::ExportTranslators");
1625   getInsOp();
1626   myInsOp->ExportTranslators(theFormats, thePatterns);
1627   endService( " GEOM_Superv_i::ExportTranslators" );
1628 }
1629
1630 //============================= TransformOperations ===========================
1631 //=============================================================================
1632 //  TranslateTwoPoints:
1633 //=============================================================================
1634 GEOM::GEOM_Object_ptr GEOM_Superv_i::TranslateTwoPoints (GEOM::GEOM_Object_ptr theObject,
1635                                                          GEOM::GEOM_Object_ptr thePoint1,
1636                                                          GEOM::GEOM_Object_ptr thePoint2)
1637 {
1638   beginService( " GEOM_Superv_i::TranslateTwoPoints" );
1639   MESSAGE("GEOM_Superv_i::TranslateTwoPoints");
1640   getTransfOp();
1641   GEOM::GEOM_Object_ptr anObj = myTransfOp->TranslateTwoPoints(theObject, thePoint1, thePoint2);
1642   endService( " GEOM_Superv_i::TranslateTwoPoints" );
1643   return anObj;
1644 }
1645
1646 //=============================================================================
1647 //  TranslateTwoPointsCopy:
1648 //=============================================================================
1649 GEOM::GEOM_Object_ptr GEOM_Superv_i::TranslateTwoPointsCopy (GEOM::GEOM_Object_ptr theObject,
1650                                                              GEOM::GEOM_Object_ptr thePoint1,
1651                                                              GEOM::GEOM_Object_ptr thePoint2)
1652 {
1653   beginService( " GEOM_Superv_i::TranslateTwoPointsCopy" );
1654   MESSAGE("GEOM_Superv_i::TranslateTwoPointsCopy");
1655   getTransfOp();
1656   GEOM::GEOM_Object_ptr anObj = myTransfOp->TranslateTwoPointsCopy(theObject, thePoint1, thePoint2);
1657   endService( " GEOM_Superv_i::TranslateTwoPointsCopy" );
1658   return anObj;
1659 }
1660
1661 //=============================================================================
1662 //  TranslateDXDYDZ:
1663 //=============================================================================
1664 GEOM::GEOM_Object_ptr GEOM_Superv_i::TranslateDXDYDZ (GEOM::GEOM_Object_ptr theObject,
1665                                                       CORBA::Double theDX,
1666                                                       CORBA::Double theDY,
1667                                                       CORBA::Double theDZ)
1668 {
1669   beginService( " GEOM_Superv_i::TranslateDXDYDZ" );
1670   MESSAGE("GEOM_Superv_i::TranslateDXDYDZ");
1671   getTransfOp();
1672   GEOM::GEOM_Object_ptr anObj = myTransfOp->TranslateDXDYDZ(theObject, theDX, theDY, theDZ);
1673   endService( " GEOM_Superv_i::TranslateDXDYDZ" );
1674   return anObj;
1675 }
1676
1677 //=============================================================================
1678 //  TranslateDXDYDZCopy:
1679 //=============================================================================
1680 GEOM::GEOM_Object_ptr GEOM_Superv_i::TranslateDXDYDZCopy (GEOM::GEOM_Object_ptr theObject,
1681                                                           CORBA::Double theDX,
1682                                                           CORBA::Double theDY,
1683                                                           CORBA::Double theDZ)
1684 {
1685   beginService( " GEOM_Superv_i::TranslateDXDYDZCopy" );
1686   MESSAGE("GEOM_Superv_i::TranslateDXDYDZCopy");
1687   getTransfOp();
1688   GEOM::GEOM_Object_ptr anObj = myTransfOp->TranslateDXDYDZCopy(theObject, theDX, theDY, theDZ);
1689   endService( " GEOM_Superv_i::TranslateDXDYDZCopy" );
1690   return anObj;
1691 }
1692
1693 //=============================================================================
1694 //  TranslateVector:
1695 //=============================================================================
1696 GEOM::GEOM_Object_ptr GEOM_Superv_i::TranslateVector (GEOM::GEOM_Object_ptr theObject,
1697                                                       GEOM::GEOM_Object_ptr theVector)
1698 {
1699   beginService( " GEOM_Superv_i::TranslateVector" );
1700   MESSAGE("GEOM_Superv_i::TranslateVector");
1701   getTransfOp();
1702   GEOM::GEOM_Object_ptr anObj = myTransfOp->TranslateVector(theObject, theVector);
1703   endService( " GEOM_Superv_i::TranslateVector" );
1704   return anObj;
1705 }
1706
1707 //=============================================================================
1708 //  TranslateVectorCopy:
1709 //=============================================================================
1710 GEOM::GEOM_Object_ptr GEOM_Superv_i::TranslateVectorCopy (GEOM::GEOM_Object_ptr theObject,
1711                                                           GEOM::GEOM_Object_ptr theVector)
1712 {
1713   beginService( " GEOM_Superv_i::TranslateVectorCopy" );
1714   MESSAGE("GEOM_Superv_i::TranslateVectorCopy");
1715   getTransfOp();
1716   GEOM::GEOM_Object_ptr anObj = myTransfOp->TranslateVectorCopy(theObject, theVector);
1717   endService( " GEOM_Superv_i::TranslateVectorCopy" );
1718   return anObj;
1719 }
1720
1721 //=============================================================================
1722 //  TranslateVectorDistance:
1723 //=============================================================================
1724 GEOM::GEOM_Object_ptr GEOM_Superv_i::TranslateVectorDistance (GEOM::GEOM_Object_ptr theObject,
1725                                                               GEOM::GEOM_Object_ptr theVector,
1726                                                               CORBA::Double theDistance,
1727                                                               CORBA::Boolean theCopy)
1728 {
1729   beginService( " GEOM_Superv_i::TranslateVectorDistance" );
1730   MESSAGE("GEOM_Superv_i::TranslateVectorDistance");
1731   getTransfOp();
1732   GEOM::GEOM_Object_ptr anObj = myTransfOp->TranslateVectorDistance(theObject,
1733                                                                     theVector, theDistance, theCopy);
1734   endService( " GEOM_Superv_i::TranslateVectorDistance" );
1735   return anObj;
1736 }
1737
1738 //=============================================================================
1739 //  MultiTranslate1D:
1740 //=============================================================================
1741 GEOM::GEOM_Object_ptr GEOM_Superv_i::MultiTranslate1D (GEOM::GEOM_Object_ptr theObject,
1742                                                        GEOM::GEOM_Object_ptr theVector,
1743                                                        CORBA::Double theStep,
1744                                                        CORBA::Long theNbTimes)
1745 {
1746   beginService( " GEOM_Superv_i::MultiTranslate1D" );
1747   MESSAGE("GEOM_Superv_i::MultiTranslate1D");
1748   getTransfOp();
1749   GEOM::GEOM_Object_ptr anObj = myTransfOp->MultiTranslate1D(theObject, theVector, theStep, theNbTimes);
1750   endService( " GEOM_Superv_i::MultiTranslate1D" );
1751   return anObj;
1752 }
1753
1754 //=============================================================================
1755 //  MultiTranslate2D:
1756 //=============================================================================
1757 GEOM::GEOM_Object_ptr GEOM_Superv_i::MultiTranslate2D (GEOM::GEOM_Object_ptr theObject,
1758                                                        GEOM::GEOM_Object_ptr theVector1,
1759                                                        CORBA::Double theStep1,
1760                                                        CORBA::Long theNbTimes1,
1761                                                        GEOM::GEOM_Object_ptr theVector2,
1762                                                        CORBA::Double theStep2,
1763                                                        CORBA::Long theNbTimes2)
1764 {
1765   beginService( " GEOM_Superv_i::MultiTranslate2D" );
1766   MESSAGE("GEOM_Superv_i::MultiTranslate2D");
1767   getTransfOp();
1768   GEOM::GEOM_Object_ptr anObj = myTransfOp->MultiTranslate2D(theObject, theVector1, theStep1, theNbTimes1,
1769                                                              theVector2, theStep2, theNbTimes2);
1770   endService( " GEOM_Superv_i::MultiTranslate2D" );
1771   return anObj;
1772 }
1773
1774 //=============================================================================
1775 //  Rotate:
1776 //=============================================================================
1777 GEOM::GEOM_Object_ptr GEOM_Superv_i::Rotate (GEOM::GEOM_Object_ptr theObject,
1778                                              GEOM::GEOM_Object_ptr theAxis,
1779                                              CORBA::Double theAngle)
1780 {
1781   beginService( " GEOM_Superv_i::Rotate" );
1782   MESSAGE("GEOM_Superv_i::Rotate");
1783   getTransfOp();
1784   GEOM::GEOM_Object_ptr anObj = myTransfOp->Rotate(theObject, theAxis, theAngle);
1785   endService( " GEOM_Superv_i::Rotate" );
1786   return anObj;
1787 }
1788
1789 //=============================================================================
1790 //  RotateCopy:
1791 //=============================================================================
1792 GEOM::GEOM_Object_ptr GEOM_Superv_i::RotateCopy (GEOM::GEOM_Object_ptr theObject,
1793                                                  GEOM::GEOM_Object_ptr theAxis,
1794                                                  CORBA::Double theAngle)
1795 {
1796   beginService( " GEOM_Superv_i::RotateCopy" );
1797   MESSAGE("GEOM_Superv_i::RotateCopy");
1798   getTransfOp();
1799   GEOM::GEOM_Object_ptr anObj = myTransfOp->RotateCopy(theObject, theAxis, theAngle);
1800   endService( " GEOM_Superv_i::RotateCopy" );
1801   return anObj;
1802 }
1803 //=============================================================================
1804 //  RotateThreePoints:
1805 //=============================================================================
1806 GEOM::GEOM_Object_ptr GEOM_Superv_i::RotateThreePoints (GEOM::GEOM_Object_ptr theObject,
1807                                                         GEOM::GEOM_Object_ptr theCentPoint,
1808                                                         GEOM::GEOM_Object_ptr thePoint1,
1809                                                         GEOM::GEOM_Object_ptr thePoint2)
1810 {
1811   beginService( " GEOM_Superv_i::RotateThreePoints" );
1812   MESSAGE("GEOM_Superv_i::RotateThreePoints");
1813   getTransfOp();
1814   GEOM::GEOM_Object_ptr anObj = myTransfOp->RotateThreePoints(theObject, theCentPoint, thePoint1, thePoint2);
1815   endService( " GEOM_Superv_i::RotateThreePoints" );
1816   return anObj;
1817 }
1818
1819 //=============================================================================
1820 //  RotateThreePointsCopy:
1821 //=============================================================================
1822 GEOM::GEOM_Object_ptr GEOM_Superv_i::RotateThreePointsCopy (GEOM::GEOM_Object_ptr theObject,
1823                                                             GEOM::GEOM_Object_ptr theCentPoint,
1824                                                             GEOM::GEOM_Object_ptr thePoint1,
1825                                                             GEOM::GEOM_Object_ptr thePoint2)
1826 {
1827   beginService( " GEOM_Superv_i::RotateThreePointsCopy" );
1828   MESSAGE("GEOM_Superv_i::RotateThreePointsCopy");
1829   getTransfOp();
1830   GEOM::GEOM_Object_ptr anObj = myTransfOp->RotateThreePointsCopy(theObject, theCentPoint, thePoint1, thePoint2);
1831   endService( " GEOM_Superv_i::RotateThreePointsCopy" );
1832   return anObj;
1833 }
1834
1835 //=============================================================================
1836 //  MultiRotate1D:
1837 //=============================================================================
1838 GEOM::GEOM_Object_ptr GEOM_Superv_i::MultiRotate1D (GEOM::GEOM_Object_ptr theObject,
1839                                                     GEOM::GEOM_Object_ptr theAxis,
1840                                                     CORBA::Long theNbTimes)
1841 {
1842   beginService( " GEOM_Superv_i::MultiRotate1D" );
1843   MESSAGE("GEOM_Superv_i::MultiRotate1D");
1844   getTransfOp();
1845   GEOM::GEOM_Object_ptr anObj = myTransfOp->MultiRotate1D(theObject, theAxis, theNbTimes);
1846   endService( " GEOM_Superv_i::MultiRotate1D" );
1847   return anObj;
1848 }
1849
1850 //=============================================================================
1851 //  MultiRotate2D:
1852 //=============================================================================
1853 GEOM::GEOM_Object_ptr GEOM_Superv_i::MultiRotate2D (GEOM::GEOM_Object_ptr theObject,
1854                                                     GEOM::GEOM_Object_ptr theAxis,
1855                                                     CORBA::Double theAngle,
1856                                                     CORBA::Long theNbTimes1,
1857                                                     CORBA::Double theStep,
1858                                                     CORBA::Long theNbTimes2)
1859 {
1860   beginService( " GEOM_Superv_i::MultiRotate2D" );
1861   MESSAGE("GEOM_Superv_i::MultiRotate2D");
1862   getTransfOp();
1863   GEOM::GEOM_Object_ptr anObj = myTransfOp->MultiRotate2D(theObject, theAxis, theAngle, theNbTimes1, theStep, theNbTimes2);
1864   endService( " GEOM_Superv_i::MultiRotate2D" );
1865   return anObj;
1866 }
1867
1868 //=============================================================================
1869 //  MirrorPlane:
1870 //=============================================================================
1871 GEOM::GEOM_Object_ptr GEOM_Superv_i::MirrorPlane (GEOM::GEOM_Object_ptr theObject,
1872                                                   GEOM::GEOM_Object_ptr thePlane)
1873 {
1874   beginService( " GEOM_Superv_i::MirrorPlane" );
1875   MESSAGE("GEOM_Superv_i::MirrorPlane");
1876   getTransfOp();
1877   GEOM::GEOM_Object_ptr anObj = myTransfOp->MirrorPlane(theObject, thePlane);
1878   endService( " GEOM_Superv_i::MirrorPlane" );
1879   return anObj;
1880 }
1881
1882 //=============================================================================
1883 //  MirrorPlaneCopy:
1884 //=============================================================================
1885 GEOM::GEOM_Object_ptr GEOM_Superv_i::MirrorPlaneCopy (GEOM::GEOM_Object_ptr theObject,
1886                                                       GEOM::GEOM_Object_ptr thePlane)
1887 {
1888   beginService( " GEOM_Superv_i::MirrorPlaneCopy" );
1889   MESSAGE("GEOM_Superv_i::MirrorPlaneCopy");
1890   getTransfOp();
1891   GEOM::GEOM_Object_ptr anObj = myTransfOp->MirrorPlaneCopy(theObject, thePlane);
1892   endService( " GEOM_Superv_i::MirrorPlaneCopy" );
1893   return anObj;
1894 }
1895
1896 //=============================================================================
1897 //  MirrorAxis:
1898 //=============================================================================
1899 GEOM::GEOM_Object_ptr GEOM_Superv_i::MirrorAxis (GEOM::GEOM_Object_ptr theObject,
1900                                                  GEOM::GEOM_Object_ptr theAxis)
1901 {
1902   beginService( " GEOM_Superv_i::MirrorAxis" );
1903   MESSAGE("GEOM_Superv_i::MirrorAxis");
1904   getTransfOp();
1905   GEOM::GEOM_Object_ptr anObj = myTransfOp->MirrorAxis(theObject, theAxis);
1906   endService( " GEOM_Superv_i::MirrorAxis" );
1907   return anObj;
1908 }
1909
1910 //=============================================================================
1911 //  MirrorAxisCopy:
1912 //=============================================================================
1913 GEOM::GEOM_Object_ptr GEOM_Superv_i::MirrorAxisCopy (GEOM::GEOM_Object_ptr theObject,
1914                                                      GEOM::GEOM_Object_ptr theAxis)
1915 {
1916   beginService( " GEOM_Superv_i::MirrorAxisCopy" );
1917   MESSAGE("GEOM_Superv_i::MirrorAxisCopy");
1918   getTransfOp();
1919   GEOM::GEOM_Object_ptr anObj = myTransfOp->MirrorAxisCopy(theObject, theAxis);
1920   endService( " GEOM_Superv_i::MirrorAxisCopy" );
1921   return anObj;
1922 }
1923
1924 //=============================================================================
1925 //  MirrorPoint:
1926 //=============================================================================
1927 GEOM::GEOM_Object_ptr GEOM_Superv_i::MirrorPoint (GEOM::GEOM_Object_ptr theObject,
1928                                                   GEOM::GEOM_Object_ptr thePoint)
1929 {
1930   beginService( " GEOM_Superv_i::MirrorPoint" );
1931   MESSAGE("GEOM_Superv_i::MirrorPoint");
1932   getTransfOp();
1933   GEOM::GEOM_Object_ptr anObj = myTransfOp->MirrorPoint(theObject, thePoint);
1934   endService( " GEOM_Superv_i::MirrorPoint" );
1935   return anObj;
1936 }
1937
1938 //=============================================================================
1939 //  MirrorPointCopy:
1940 //=============================================================================
1941 GEOM::GEOM_Object_ptr GEOM_Superv_i::MirrorPointCopy (GEOM::GEOM_Object_ptr theObject,
1942                                                       GEOM::GEOM_Object_ptr thePoint)
1943 {
1944   beginService( " GEOM_Superv_i::MirrorPoint" );
1945   MESSAGE("GEOM_Superv_i::MirrorPointCopy");
1946   getTransfOp();
1947   GEOM::GEOM_Object_ptr anObj = myTransfOp->MirrorPointCopy(theObject, thePoint);
1948   endService( " GEOM_Superv_i::MirrorPoint" );
1949   return anObj;
1950 }
1951
1952 //=============================================================================
1953 //  OffsetShape:
1954 //=============================================================================
1955 GEOM::GEOM_Object_ptr GEOM_Superv_i::OffsetShape (GEOM::GEOM_Object_ptr theObject,
1956                                                   CORBA::Double theOffset)
1957 {
1958   beginService( " GEOM_Superv_i::OffsetShape" );
1959   MESSAGE("GEOM_Superv_i::OffsetShape");
1960   getTransfOp();
1961   GEOM::GEOM_Object_ptr anObj = myTransfOp->OffsetShape(theObject, theOffset);
1962   endService( " GEOM_Superv_i::OffsetShape" );
1963   return anObj;
1964 }
1965
1966 //=============================================================================
1967 //  OffsetShapeCopy:
1968 //=============================================================================
1969 GEOM::GEOM_Object_ptr GEOM_Superv_i::OffsetShapeCopy (GEOM::GEOM_Object_ptr theObject,
1970                                                       CORBA::Double theOffset)
1971 {
1972   beginService( " GEOM_Superv_i::OffsetShapeCopy" );
1973   MESSAGE("GEOM_Superv_i::OffsetShapeCopy");
1974   getTransfOp();
1975   GEOM::GEOM_Object_ptr anObj = myTransfOp->OffsetShapeCopy(theObject, theOffset);
1976   endService( " GEOM_Superv_i::OffsetShapeCopy" );
1977   return anObj;
1978 }
1979
1980 //=============================================================================
1981 //  ScaleShape:
1982 //=============================================================================
1983 GEOM::GEOM_Object_ptr GEOM_Superv_i::ScaleShape (GEOM::GEOM_Object_ptr theObject,
1984                                                  GEOM::GEOM_Object_ptr thePoint,
1985                                                  CORBA::Double theFactor)
1986 {
1987   beginService( " GEOM_Superv_i::ScaleShape" );
1988   MESSAGE("GEOM_Superv_i::ScaleShape");
1989   getTransfOp();
1990   GEOM::GEOM_Object_ptr anObj = myTransfOp->ScaleShape(theObject, thePoint, theFactor);
1991   endService( " GEOM_Superv_i::ScaleShape" );
1992   return anObj;
1993 }
1994
1995 //=============================================================================
1996 //  ScaleShapeCopy:
1997 //=============================================================================
1998 GEOM::GEOM_Object_ptr GEOM_Superv_i::ScaleShapeCopy (GEOM::GEOM_Object_ptr theObject,
1999                                                      GEOM::GEOM_Object_ptr thePoint,
2000                                                      CORBA::Double theFactor)
2001 {
2002   beginService( " GEOM_Superv_i::ScaleShapeCopy" );
2003   MESSAGE("GEOM_Superv_i::ScaleShapeCopy");
2004   getTransfOp();
2005   GEOM::GEOM_Object_ptr anObj = myTransfOp->ScaleShapeCopy(theObject, thePoint, theFactor);
2006   endService( " GEOM_Superv_i::ScaleShapeCopy" );
2007   return anObj;
2008 }
2009
2010 //=============================================================================
2011 //  ScaleShapeAlongAxes:
2012 //=============================================================================
2013 GEOM::GEOM_Object_ptr GEOM_Superv_i::ScaleShapeAlongAxes (GEOM::GEOM_Object_ptr theObject,
2014                                                           GEOM::GEOM_Object_ptr thePoint,
2015                                                           CORBA::Double theFactorX,
2016                                                           CORBA::Double theFactorY,
2017                                                           CORBA::Double theFactorZ)
2018 {
2019   beginService( " GEOM_Superv_i::ScaleShapeAlongAxes" );
2020   MESSAGE("GEOM_Superv_i::ScaleShapeAlongAxes");
2021   getTransfOp();
2022   GEOM::GEOM_Object_ptr anObj = myTransfOp->ScaleShapeAlongAxes
2023     (theObject, thePoint, theFactorX, theFactorY, theFactorZ);
2024   endService( " GEOM_Superv_i::ScaleShapeAlongAxes" );
2025   return anObj;
2026 }
2027
2028 //=============================================================================
2029 //  ScaleShapeAlongAxesCopy:
2030 //=============================================================================
2031 GEOM::GEOM_Object_ptr GEOM_Superv_i::ScaleShapeAlongAxesCopy (GEOM::GEOM_Object_ptr theObject,
2032                                                               GEOM::GEOM_Object_ptr thePoint,
2033                                                               CORBA::Double theFactorX,
2034                                                               CORBA::Double theFactorY,
2035                                                               CORBA::Double theFactorZ)
2036 {
2037   beginService( " GEOM_Superv_i::ScaleShapeAlongAxesCopy" );
2038   MESSAGE("GEOM_Superv_i::ScaleShapeAlongAxesCopy");
2039   getTransfOp();
2040   GEOM::GEOM_Object_ptr anObj = myTransfOp->ScaleShapeAlongAxesCopy
2041     (theObject, thePoint, theFactorX, theFactorY, theFactorZ);
2042   endService( " GEOM_Superv_i::ScaleShapeAlongAxesCopy" );
2043   return anObj;
2044 }
2045
2046 //=============================================================================
2047 //  PositionShape:
2048 //=============================================================================
2049 GEOM::GEOM_Object_ptr GEOM_Superv_i::PositionShape (GEOM::GEOM_Object_ptr theObject,
2050                                                     GEOM::GEOM_Object_ptr theStartLCS,
2051                                                     GEOM::GEOM_Object_ptr theEndLCS)
2052 {
2053   beginService( " GEOM_Superv_i::PositionShape" );
2054   MESSAGE("GEOM_Superv_i::PositionShape");
2055   getTransfOp();
2056   GEOM::GEOM_Object_ptr anObj = myTransfOp->PositionShape(theObject, theStartLCS, theEndLCS);
2057   endService( " GEOM_Superv_i::PositionShape" );
2058   return anObj;
2059 }
2060
2061 //=============================================================================
2062 //  PositionShapeCopy:
2063 //=============================================================================
2064 GEOM::GEOM_Object_ptr GEOM_Superv_i::PositionShapeCopy (GEOM::GEOM_Object_ptr theObject,
2065                                                         GEOM::GEOM_Object_ptr theStartLCS,
2066                                                         GEOM::GEOM_Object_ptr theEndLCS)
2067 {
2068   beginService( " GEOM_Superv_i::PositionShapeCopy" );
2069   MESSAGE("GEOM_Superv_i::PositionShapeCopy");
2070   getTransfOp();
2071   GEOM::GEOM_Object_ptr anObj = myTransfOp->PositionShapeCopy(theObject, theStartLCS, theEndLCS);
2072   endService( " GEOM_Superv_i::PositionShapeCopy" );
2073   return anObj;
2074 }
2075
2076 //=============================================================================
2077 //  PositionAlongPath:
2078 //=============================================================================
2079 GEOM::GEOM_Object_ptr GEOM_Superv_i::PositionAlongPath (GEOM::GEOM_Object_ptr theObject,
2080                                                         GEOM::GEOM_Object_ptr thePath,
2081                                                         CORBA::Double         theDistance,
2082                                                         CORBA::Boolean        theCopy,
2083                                                         CORBA::Boolean        theReverse)
2084 {
2085   beginService( " GEOM_Superv_i::PositionAlongPath" );
2086   MESSAGE("GEOM_Superv_i::PositionAlongPath");
2087   getTransfOp();
2088   GEOM::GEOM_Object_ptr anObj = myTransfOp->PositionAlongPath(theObject, thePath, theDistance, theCopy, theReverse);
2089   endService( " GEOM_Superv_i::PositionAlongPath" );
2090   return anObj;
2091 }
2092
2093 //=============================== ShapesOperations ============================
2094 //=============================================================================
2095 //  Make:
2096 //=============================================================================
2097 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeEdge (GEOM::GEOM_Object_ptr thePnt1,
2098                                                GEOM::GEOM_Object_ptr thePnt2)
2099 {
2100   beginService( " GEOM_Superv_i::MakeEdge" );
2101   MESSAGE("GEOM_Superv_i::MakeEdge");
2102   getShapesOp();
2103   GEOM::GEOM_Object_ptr anObj = myShapesOp->MakeEdge(thePnt1, thePnt2);
2104   endService( " GEOM_Superv_i::MakeEdge" );
2105   return anObj;
2106 }
2107
2108 //=============================================================================
2109 //  MakeEdgeOnCurveByLength:
2110 //=============================================================================
2111 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeEdgeOnCurveByLength (GEOM::GEOM_Object_ptr theRefCurve,
2112                                                               CORBA::Double theLength,
2113                                                               GEOM::GEOM_Object_ptr theStartPoint)
2114 {
2115   beginService( " GEOM_Superv_i::MakeEdgeOnCurveByLength" );
2116   MESSAGE("GEOM_Superv_i::MakeEdgeOnCurveByLength");
2117   getShapesOp();
2118   GEOM::GEOM_Object_ptr anObj = myShapesOp->MakeEdgeOnCurveByLength(theRefCurve, theLength, theStartPoint);
2119   endService( " GEOM_Superv_i::MakeEdgeOnCurveByLength" );
2120   return anObj;
2121 }
2122
2123 //=============================================================================
2124 //  MakeWire:
2125 //=============================================================================
2126 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeWire (GEOM::GEOM_List_ptr theEdgesAndWires,
2127                                                CORBA::Double       theTolerance)
2128 {
2129   beginService( " GEOM_Superv_i::MakeWire" );
2130   MESSAGE("GEOM_Superv_i::MakeWire");
2131   if (GEOM_List_i<GEOM::ListOfGO>* aListImplEW =
2132       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theEdgesAndWires, myPOA).in())) {
2133     getShapesOp();
2134     GEOM::GEOM_Object_ptr anObj = myShapesOp->MakeWire(aListImplEW->GetList(), theTolerance);
2135     endService( " GEOM_Superv_i::MakeWire" );
2136     return anObj;
2137   }
2138   endService( " GEOM_Superv_i::MakeWire" );
2139   return NULL;
2140 }
2141
2142 //=============================================================================
2143 //  MakeFace:
2144 //=============================================================================
2145 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFace (GEOM::GEOM_Object_ptr theWire,
2146                                                CORBA::Boolean isPlanarWanted)
2147 {
2148   beginService( " GEOM_Superv_i::MakeFace" );
2149   MESSAGE("GEOM_Superv_i::MakeFace");
2150   getShapesOp();
2151   GEOM::GEOM_Object_ptr anObj = myShapesOp->MakeFace(theWire, isPlanarWanted);
2152   endService( " GEOM_Superv_i::MakeFace" );
2153   return anObj;
2154 }
2155
2156 //=============================================================================
2157 //  MakeFaceWires:
2158 //=============================================================================
2159 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFaceWires (GEOM::GEOM_List_ptr theWires,
2160                                                     CORBA::Boolean isPlanarWanted)
2161 {
2162   beginService( " GEOM_Superv_i::MakeFaceWires" );
2163   MESSAGE("GEOM_Superv_i::MakeFaceWires");
2164   if (GEOM_List_i<GEOM::ListOfGO>* aListImplW =
2165       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theWires, myPOA).in())) {
2166     getShapesOp();
2167     GEOM::GEOM_Object_ptr anObj = myShapesOp->MakeFaceWires(aListImplW->GetList(), isPlanarWanted);
2168     endService( " GEOM_Superv_i::MakeFaceWires" );
2169     return anObj;
2170   }
2171   endService( " GEOM_Superv_i::MakeFaceWires" );
2172   return NULL;
2173 }
2174
2175 //=============================================================================
2176 //  MakeShell:
2177 //=============================================================================
2178 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeShell (GEOM::GEOM_List_ptr theFacesAndShells)
2179 {
2180   beginService( " GEOM_Superv_i::MakeShell" );
2181   MESSAGE("GEOM_Superv_i::MakeShell");
2182   if (GEOM_List_i<GEOM::ListOfGO>* aListImplFS =
2183       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theFacesAndShells, myPOA).in())) {
2184     getShapesOp();
2185     GEOM::GEOM_Object_ptr anObj = myShapesOp->MakeShell(aListImplFS->GetList());
2186     endService( " GEOM_Superv_i::MakeShell" );
2187     return anObj;
2188   }
2189   endService( " GEOM_Superv_i::MakeShell" );
2190   return NULL;
2191 }
2192
2193 //=============================================================================
2194 //  MakeSolidShell:
2195 //=============================================================================
2196 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSolidShell (GEOM::GEOM_Object_ptr theShell)
2197 {
2198   beginService( " GEOM_Superv_i::MakeSolidShell" );
2199   MESSAGE("GEOM_Superv_i::MakeSolidShell");
2200   getShapesOp();
2201   GEOM::GEOM_Object_ptr anObj = myShapesOp->MakeSolidShell(theShell);
2202   endService( " GEOM_Superv_i::MakeSolidShell" );
2203   return anObj;
2204 }
2205
2206 //=============================================================================
2207 //  MakeSolidShells:
2208 //=============================================================================
2209 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSolidShells (GEOM::GEOM_List_ptr theShells)
2210 {
2211   beginService( " GEOM_Superv_i::MakeSolidShells" );
2212   MESSAGE("GEOM_Superv_i::MakeSolidShells");
2213   if (GEOM_List_i<GEOM::ListOfGO>* aListImplS =
2214       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theShells, myPOA).in())) {
2215     getShapesOp();
2216     GEOM::GEOM_Object_ptr anObj = myShapesOp->MakeSolidShells(aListImplS->GetList());
2217     endService( " GEOM_Superv_i::MakeSolidShells" );
2218     return anObj;
2219   }
2220   endService( " GEOM_Superv_i::MakeSolidShells" );
2221   return NULL;
2222 }
2223
2224 //=============================================================================
2225 //  MakeCompound:
2226 //=============================================================================
2227 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeCompound (GEOM::GEOM_List_ptr theShapes)
2228 {
2229   beginService( " GEOM_Superv_i::MakeCompound" );
2230   MESSAGE("GEOM_Superv_i::MakeCompound");
2231   if (GEOM_List_i<GEOM::ListOfGO>* aListImpl =
2232       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theShapes, myPOA).in())) {
2233     getShapesOp();
2234     GEOM::GEOM_Object_ptr anObj = myShapesOp->MakeCompound(aListImpl->GetList());
2235     endService( " GEOM_Superv_i::MakeCompound" );
2236     return anObj;
2237   }
2238   endService( " GEOM_Superv_i::MakeCompound" );
2239   return NULL;
2240 }
2241
2242 //=============================================================================
2243 //  MakeGlueFaces:
2244 //=============================================================================
2245 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeGlueFaces (GEOM::GEOM_Object_ptr theShape,
2246                                                     CORBA::Double   theTolerance,
2247                                                     CORBA::Boolean doKeepNonSolids)
2248 {
2249   beginService( " GEOM_Superv_i::MakeGlueFaces" );
2250   MESSAGE("GEOM_Superv_i::MakeGlueFaces");
2251   getShapesOp();
2252   GEOM::GEOM_Object_ptr anObj =
2253     myShapesOp->MakeGlueFaces(theShape, theTolerance, doKeepNonSolids);
2254   endService( " GEOM_Superv_i::MakeGlueFaces" );
2255   return anObj;
2256 }
2257
2258 //=============================================================================
2259 //  GetGlueFaces:
2260 //=============================================================================
2261 GEOM::GEOM_List_ptr GEOM_Superv_i::GetGlueFaces (GEOM::GEOM_Object_ptr theShape,
2262                                                  CORBA::Double theTolerance)
2263 {
2264   beginService( " GEOM_Superv_i::GetGlueFaces" );
2265   MESSAGE("GEOM_Superv_i::GetGlueFaces");
2266   getShapesOp();
2267   GEOM::ListOfGO* aList = myShapesOp->GetGlueFaces(theShape, theTolerance);
2268   GEOM_List_i<GEOM::ListOfGO>* aListPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aList));
2269   MESSAGE(" List of "<<aListPtr->GetList().length()<<" element(s)");
2270   endService( " GEOM_Superv_i::GetGlueFaces" );
2271   return aListPtr->_this();
2272 }
2273
2274 //=============================================================================
2275 //  MakeGlueFacesByList:
2276 //=============================================================================
2277 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeGlueFacesByList (GEOM::GEOM_Object_ptr theShape,
2278                                                           CORBA::Double theTolerance,
2279                                                           const GEOM::ListOfGO& theFaces,
2280                                                           CORBA::Boolean doKeepNonSolids,
2281                                                           CORBA::Boolean doGlueAllEdges)
2282 {
2283   beginService( " GEOM_Superv_i::MakeGlueFacesByList" );
2284   MESSAGE("GEOM_Superv_i::MakeGlueFacesByList");
2285   getShapesOp();
2286   GEOM::GEOM_Object_ptr anObj =
2287     myShapesOp->MakeGlueFacesByList(theShape, theTolerance, theFaces,
2288                                     doKeepNonSolids, doGlueAllEdges);
2289   endService( " GEOM_Superv_i::MakeGlueFacesByList" );
2290   return anObj;
2291 }
2292
2293 //=============================================================================
2294 //  MakeExplode:
2295 //=============================================================================
2296 GEOM::GEOM_List_ptr GEOM_Superv_i::MakeExplode (GEOM::GEOM_Object_ptr theShape,
2297                                                     CORBA::Long theShapeType,
2298                                                     CORBA::Boolean isSorted)
2299 {
2300   beginService( " GEOM_Superv_i::MakeExplode" );
2301   MESSAGE("GEOM_Superv_i::MakeExplode");
2302   getShapesOp();
2303
2304   GEOM::ListOfGO* aList = myShapesOp->MakeExplode(theShape, theShapeType, isSorted);
2305   GEOM_List_i<GEOM::ListOfGO>* aListPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aList));
2306   MESSAGE(" List of "<<aListPtr->GetList().length()<<" element(s)");
2307   endService( " GEOM_Superv_i::MakeExplode" );
2308   return aListPtr->_this();
2309 }
2310
2311 //=============================================================================
2312 //  NumberOfFaces:
2313 //=============================================================================
2314 CORBA::Long GEOM_Superv_i::NumberOfFaces (GEOM::GEOM_Object_ptr theShape)
2315 {
2316   beginService( " GEOM_Superv_i::NumberOfFaces" );
2317   MESSAGE("GEOM_Superv_i::NumberOfFaces");
2318   getShapesOp();
2319   CORBA::Long aRes = myShapesOp->NumberOfFaces(theShape);
2320   endService( " GEOM_Superv_i::NumberOfFaces" );
2321   return aRes;
2322 }
2323
2324 //=============================================================================
2325 //  NumberOfEdges:
2326 //=============================================================================
2327 CORBA::Long GEOM_Superv_i::NumberOfEdges (GEOM::GEOM_Object_ptr theShape)
2328 {
2329   beginService( " GEOM_Superv_i::NumberOfEdges" );
2330   MESSAGE("GEOM_Superv_i::NumberOfEdges");
2331   getShapesOp();
2332   CORBA::Long aRes = myShapesOp->NumberOfEdges(theShape);
2333   endService( " GEOM_Superv_i::NumberOfEdges" );
2334   return aRes;
2335 }
2336
2337
2338 //=============================================================================
2339 //  ChangeOrientation:
2340 //=============================================================================
2341 GEOM::GEOM_Object_ptr GEOM_Superv_i::ChangeOrientation (GEOM::GEOM_Object_ptr theShape)
2342 {
2343   beginService( " GEOM_Superv_i::ChangeOrientation" );
2344   MESSAGE("GEOM_Superv_i::ChangeOrientation");
2345   getShapesOp();
2346   GEOM::GEOM_Object_ptr anObj = myShapesOp->ChangeOrientation(theShape);
2347   endService( " GEOM_Superv_i::ChangeOrientation" );
2348   return anObj;
2349 }
2350
2351
2352 //=============================================================================
2353 //  GetShapesOnShape:
2354 //=============================================================================
2355 GEOM::GEOM_List_ptr GEOM_Superv_i::GetShapesOnShape
2356                                           (GEOM::GEOM_Object_ptr theCheckShape,
2357                                            GEOM::GEOM_Object_ptr theShape,
2358                                            CORBA::Short theShapeType,
2359                                            GEOM::shape_state theState)
2360 {
2361   beginService( " GEOM_Superv_i::GetShapesOnShape" );
2362   MESSAGE("GEOM_Superv_i::GetShapesOnShape");
2363   getShapesOp();
2364   GEOM::ListOfGO* aList =
2365     myShapesOp->GetShapesOnShape(theCheckShape, theShape, theShapeType, theState);
2366   GEOM_List_i<GEOM::ListOfGO>* aListPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aList));
2367   MESSAGE(" List of "<<aListPtr->GetList().length()<<" element(s)");
2368   endService( " GEOM_Superv_i::GetShapesOnShape" );
2369   return aListPtr->_this();
2370 }
2371
2372
2373 //=============================================================================
2374 //  GetShapesOnShapeAsCompound:
2375 //=============================================================================
2376 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetShapesOnShapeAsCompound
2377                                           (GEOM::GEOM_Object_ptr theCheckShape,
2378                                            GEOM::GEOM_Object_ptr theShape,
2379                                            CORBA::Short theShapeType,
2380                                            GEOM::shape_state theState)
2381 {
2382   beginService( " GEOM_Superv_i::GetShapesOnShapeAsCompound" );
2383   MESSAGE("GEOM_Superv_i::GetShapesOnShapeAsCompound");
2384   getShapesOp();
2385   GEOM::GEOM_Object_ptr anObj =
2386     myShapesOp->GetShapesOnShapeAsCompound(theCheckShape, theShape, theShapeType, theState);
2387   endService( " GEOM_Superv_i::GetShapesOnShapeAsCompound" );
2388   return anObj;
2389 }
2390
2391
2392 //=============================== BlocksOperations ============================
2393 //=============================================================================
2394 //  MakeQuad4Vertices:
2395 //=============================================================================
2396 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeQuad4Vertices (GEOM::GEOM_Object_ptr thePnt1,
2397                                                         GEOM::GEOM_Object_ptr thePnt2,
2398                                                         GEOM::GEOM_Object_ptr thePnt3,
2399                                                         GEOM::GEOM_Object_ptr thePnt4)
2400 {
2401   beginService( " GEOM_Superv_i::MakeQuad4Vertices" );
2402   MESSAGE("GEOM_Superv_i::MakeQuad4Vertices");
2403   getBlocksOp();
2404   GEOM::GEOM_Object_ptr anObj = myBlocksOp->MakeQuad4Vertices(thePnt1, thePnt2, thePnt3, thePnt4);
2405   endService( " GEOM_Superv_i::MakeQuad4Vertices" );
2406   return anObj;
2407 }
2408
2409 //=============================================================================
2410 //  MakeQuad:
2411 //=============================================================================
2412 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeQuad (GEOM::GEOM_Object_ptr theEdge1,
2413                                                GEOM::GEOM_Object_ptr theEdge2,
2414                                                GEOM::GEOM_Object_ptr theEdge3,
2415                                                GEOM::GEOM_Object_ptr theEdge4)
2416 {
2417   beginService( " GEOM_Superv_i::MakeQuad" );
2418   MESSAGE("GEOM_Superv_i::MakeQuad");
2419   getBlocksOp();
2420   GEOM::GEOM_Object_ptr anObj = myBlocksOp->MakeQuad(theEdge1, theEdge2, theEdge3, theEdge4);
2421   endService( " GEOM_Superv_i::MakeQuad" );
2422   return anObj;
2423 }
2424
2425 //=============================================================================
2426 //  MakeQuad2Edges:
2427 //=============================================================================
2428 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeQuad2Edges (GEOM::GEOM_Object_ptr theEdge1,
2429                                                      GEOM::GEOM_Object_ptr theEdge2)
2430 {
2431   beginService( " GEOM_Superv_i::MakeQuad2Edges" );
2432   MESSAGE("GEOM_Superv_i::MakeQuad2Edges");
2433   getBlocksOp();
2434   GEOM::GEOM_Object_ptr anObj = myBlocksOp->MakeQuad2Edges(theEdge1, theEdge2);
2435   endService( " GEOM_Superv_i::MakeQuad2Edges" );
2436   return anObj;
2437 }
2438
2439 //=============================================================================
2440 //  MakeHexa:
2441 //=============================================================================
2442 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeHexa (GEOM::GEOM_Object_ptr theFace1,
2443                                                GEOM::GEOM_Object_ptr theFace2,
2444                                                GEOM::GEOM_Object_ptr theFace3,
2445                                                GEOM::GEOM_Object_ptr theFace4,
2446                                                GEOM::GEOM_Object_ptr theFace5,
2447                                                GEOM::GEOM_Object_ptr theFace6)
2448 {
2449   beginService( " GEOM_Superv_i::MakeHexa" );
2450   MESSAGE("GEOM_Superv_i::MakeHexa");
2451   getBlocksOp();
2452   GEOM::GEOM_Object_ptr anObj = myBlocksOp->MakeHexa(theFace1, theFace2, theFace3, theFace4, theFace5, theFace6);
2453   endService( " GEOM_Superv_i::MakeHexa" );
2454   return anObj;
2455 }
2456
2457 //=============================================================================
2458 //  MakeHexa2Faces:
2459 //=============================================================================
2460 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeHexa2Faces (GEOM::GEOM_Object_ptr theFace1,
2461                                                      GEOM::GEOM_Object_ptr theFace2)
2462 {
2463   beginService( " GEOM_Superv_i::MakeHexa2Faces" );
2464   MESSAGE("GEOM_Superv_i::MakeHexa2Faces");
2465   getBlocksOp();
2466   GEOM::GEOM_Object_ptr anObj = myBlocksOp->MakeHexa2Faces(theFace1, theFace2);
2467   endService( " GEOM_Superv_i::MakeHexa2Faces" );
2468   return anObj;
2469 }
2470
2471 //=============================================================================
2472 //  GetPoint:
2473 //=============================================================================
2474 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetPoint (GEOM::GEOM_Object_ptr theShape,
2475                                                CORBA::Double   theX,
2476                                                CORBA::Double   theY,
2477                                                CORBA::Double   theZ,
2478                                                CORBA::Double   theEpsilon)
2479 {
2480   beginService( " GEOM_Superv_i::GetPoint" );
2481   MESSAGE("GEOM_Superv_i::GetPoint");
2482   getBlocksOp();
2483   GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetPoint(theShape, theX, theY, theZ, theEpsilon);
2484   endService( " GEOM_Superv_i::GetPoint" );
2485   return anObj;
2486 }
2487
2488 //=============================================================================
2489 //  GetEdge:
2490 //=============================================================================
2491 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetEdge (GEOM::GEOM_Object_ptr theShape,
2492                                               GEOM::GEOM_Object_ptr thePoint1,
2493                                               GEOM::GEOM_Object_ptr thePoint2)
2494 {
2495   beginService( " GEOM_Superv_i::GetEdge" );
2496   MESSAGE("GEOM_Superv_i::GetEdge");
2497   getBlocksOp();
2498   GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetEdge(theShape, thePoint1, thePoint2);
2499   endService( " GEOM_Superv_i::GetEdge" );
2500   return anObj;
2501 }
2502
2503 //=============================================================================
2504 //  GetEdgeNearPoint:
2505 //=============================================================================
2506 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetEdgeNearPoint (GEOM::GEOM_Object_ptr theShape,
2507                                                        GEOM::GEOM_Object_ptr thePoint)
2508 {
2509   beginService( " GEOM_Superv_i::GetEdgeNearPoint" );
2510   MESSAGE("GEOM_Superv_i::GetEdgeNearPoint");
2511   getBlocksOp();
2512   GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetEdgeNearPoint(theShape, thePoint);
2513   endService( " GEOM_Superv_i::GetEdgeNearPoint" );
2514   return anObj;
2515 }
2516
2517 //=============================================================================
2518 //  GetFaceByPoints:
2519 //=============================================================================
2520 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetFaceByPoints (GEOM::GEOM_Object_ptr theShape,
2521                                                       GEOM::GEOM_Object_ptr thePoint1,
2522                                                       GEOM::GEOM_Object_ptr thePoint2,
2523                                                       GEOM::GEOM_Object_ptr thePoint3,
2524                                                       GEOM::GEOM_Object_ptr thePoint4)
2525 {
2526   beginService( " GEOM_Superv_i::GetFaceByPoints" );
2527   MESSAGE("GEOM_Superv_i::GetFaceByPoints");
2528   getBlocksOp();
2529   GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetFaceByPoints(theShape, thePoint1, thePoint2, thePoint3, thePoint4);
2530   endService( " GEOM_Superv_i::GetFaceByPoints" );
2531   return anObj;
2532 }
2533
2534 //=============================================================================
2535 //  GetFaceByEdges:
2536 //=============================================================================
2537 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetFaceByEdges (GEOM::GEOM_Object_ptr theShape,
2538                                                      GEOM::GEOM_Object_ptr theEdge1,
2539                                                      GEOM::GEOM_Object_ptr theEdge2)
2540 {
2541   beginService( " GEOM_Superv_i::GetFaceByEdges" );
2542   MESSAGE("GEOM_Superv_i::GetFaceByEdges");
2543   getBlocksOp();
2544   GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetFaceByEdges(theShape, theEdge1, theEdge2);
2545   endService( " GEOM_Superv_i::GetFaceByEdges" );
2546   return anObj;
2547 }
2548
2549 //=============================================================================
2550 //  GetOppositeFace:
2551 //=============================================================================
2552 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetOppositeFace (GEOM::GEOM_Object_ptr theBlock,
2553                                                       GEOM::GEOM_Object_ptr theFace)
2554 {
2555   beginService( " GEOM_Superv_i::GetOppositeFace" );
2556   MESSAGE("GEOM_Superv_i::GetOppositeFace");
2557   getBlocksOp();
2558   GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetOppositeFace(theBlock, theFace);
2559   endService( " GEOM_Superv_i::GetOppositeFace" );
2560   return anObj;
2561 }
2562
2563 //=============================================================================
2564 //  GetFaceNearPoint:
2565 //=============================================================================
2566 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetFaceNearPoint (GEOM::GEOM_Object_ptr theShape,
2567                                                        GEOM::GEOM_Object_ptr thePoint)
2568 {
2569   beginService( " GEOM_Superv_i::GetFaceNearPoint" );
2570   MESSAGE("GEOM_Superv_i::GetFaceNearPoint");
2571   getBlocksOp();
2572   GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetFaceNearPoint(theShape, thePoint);
2573   endService( " GEOM_Superv_i::GetFaceNearPoint" );
2574   return anObj;
2575 }
2576
2577 //=============================================================================
2578 //  GetFaceByNormale:
2579 //=============================================================================
2580 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetFaceByNormale (GEOM::GEOM_Object_ptr theBlock,
2581                                                        GEOM::GEOM_Object_ptr theVector)
2582 {
2583   beginService( " GEOM_Superv_i::GetFaceByNormale" );
2584   MESSAGE("GEOM_Superv_i::GetFaceByNormale");
2585   getBlocksOp();
2586   GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetFaceByNormale(theBlock, theVector);
2587   endService( " GEOM_Superv_i::GetFaceByNormale" );
2588   return anObj;
2589 }
2590
2591 //=============================================================================
2592 //  IsCompoundOfBlocks:
2593 //=============================================================================
2594 CORBA::Boolean GEOM_Superv_i::IsCompoundOfBlocks (GEOM::GEOM_Object_ptr theCompound,
2595                                                   CORBA::Long     theMinNbFaces,
2596                                                   CORBA::Long     theMaxNbFaces,
2597                                                   CORBA::Long&          theNbBlocks)
2598 {
2599   beginService( " GEOM_Superv_i::IsCompoundOfBlocks" );
2600   MESSAGE("GEOM_Superv_i::IsCompoundOfBlocks");
2601   getBlocksOp();
2602   CORBA::Boolean aRes = myBlocksOp->IsCompoundOfBlocks(theCompound, theMinNbFaces, theMaxNbFaces, theNbBlocks);
2603   endService( " GEOM_Superv_i::IsCompoundOfBlocks" );
2604   return aRes;
2605 }
2606
2607 //=============================================================================
2608 //  CheckCompoundOfBlocks:
2609 //=============================================================================
2610 CORBA::Boolean GEOM_Superv_i::CheckCompoundOfBlocks
2611 (GEOM::GEOM_Object_ptr theCompound,
2612  GEOM::GEOM_IBlocksOperations::BCErrors_out theErrors)
2613 {
2614   beginService( " GEOM_Superv_i::CheckCompoundOfBlocks" );
2615   MESSAGE("GEOM_Superv_i::CheckCompoundOfBlocks");
2616   getBlocksOp();
2617   CORBA::Boolean aRes = myBlocksOp->CheckCompoundOfBlocks(theCompound, theErrors);
2618   endService( " GEOM_Superv_i::CheckCompoundOfBlocks" );
2619   return aRes;
2620 }
2621
2622 //=============================================================================
2623 //  PrintBCErrors:
2624 //=============================================================================
2625 char* GEOM_Superv_i::PrintBCErrors (GEOM::GEOM_Object_ptr theCompound,
2626                                     const GEOM::GEOM_IBlocksOperations::BCErrors& theErrors)
2627 {
2628   beginService( " GEOM_Superv_i::PrintBCErrors" );
2629   MESSAGE("GEOM_Superv_i::PrintBCErrors");
2630   getBlocksOp();
2631   char* anErrors = myBlocksOp->PrintBCErrors(theCompound, theErrors);
2632   endService( " GEOM_Superv_i::PrintBCErrors" );
2633   return anErrors;
2634 }
2635
2636 //=============================================================================
2637 //  ExplodeCompoundOfBlocks:
2638 //=============================================================================
2639 GEOM::GEOM_List_ptr GEOM_Superv_i::ExplodeCompoundOfBlocks (GEOM::GEOM_Object_ptr theCompound,
2640                                                                 CORBA::Long     theMinNbFaces,
2641                                                                 CORBA::Long     theMaxNbFaces)
2642 {
2643   beginService( " GEOM_Superv_i::ExplodeCompoundOfBlocks" );
2644   MESSAGE("GEOM_Superv_i::ExplodeCompoundOfBlocks");
2645   getBlocksOp();
2646   GEOM::ListOfGO* aBlocks = myBlocksOp->ExplodeCompoundOfBlocks(theCompound, theMinNbFaces, theMaxNbFaces);
2647   GEOM_List_i<GEOM::ListOfGO>* aListPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aBlocks));
2648   endService( " GEOM_Superv_i::ExplodeCompoundOfBlocks" );
2649   return aListPtr->_this();
2650 }
2651
2652 //=============================================================================
2653 //  GetBlockNearPoint:
2654 //=============================================================================
2655 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetBlockNearPoint (GEOM::GEOM_Object_ptr theCompound,
2656                                                         GEOM::GEOM_Object_ptr thePoint)
2657 {
2658   beginService( " GEOM_Superv_i::GetBlockNearPoint" );
2659   MESSAGE("GEOM_Superv_i::GetBlockNearPoint");
2660   getBlocksOp();
2661   GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetBlockNearPoint(theCompound, thePoint);
2662   endService( " GEOM_Superv_i::GetBlockNearPoint" );
2663   return anObj;
2664 }
2665
2666 //=============================================================================
2667 //  GetBlockByParts:
2668 //=============================================================================
2669 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetBlockByParts (GEOM::GEOM_Object_ptr theCompound,
2670                                                       GEOM::GEOM_List_ptr theParts)
2671 {
2672   beginService( " GEOM_Superv_i::GetBlockByParts" );
2673   MESSAGE("GEOM_Superv_i::GetBlockByParts");
2674   if (GEOM_List_i<GEOM::ListOfGO>* aListImplP =
2675       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theParts, myPOA).in())) {
2676     getBlocksOp();
2677     GEOM::GEOM_Object_ptr anObj = myBlocksOp->GetBlockByParts(theCompound, aListImplP->GetList());
2678     endService( " GEOM_Superv_i::GetBlockByParts" );
2679     return anObj;
2680   }
2681   endService( " GEOM_Superv_i::GetBlockByParts" );
2682   return NULL;
2683 }
2684
2685 //=============================================================================
2686 //  GetBlocksByParts:
2687 //=============================================================================
2688 GEOM::GEOM_List_ptr GEOM_Superv_i::GetBlocksByParts (GEOM::GEOM_Object_ptr theCompound,
2689                                                          GEOM::GEOM_List_ptr theParts)
2690 {
2691   beginService( " GEOM_Superv_i::GetBlocksByParts" );
2692   MESSAGE("GEOM_Superv_i::GetBlocksByParts");
2693   if (GEOM_List_i<GEOM::ListOfGO>* aListImplP =
2694       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theParts, myPOA).in())) {
2695     getBlocksOp();
2696
2697     GEOM::ListOfGO* aBlocks = myBlocksOp->GetBlocksByParts(theCompound, aListImplP->GetList());
2698     GEOM_List_i<GEOM::ListOfGO>* aListPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aBlocks));
2699     endService( " GEOM_Superv_i::GetBlocksByParts" );
2700     return aListPtr->_this();
2701   }
2702   endService( " GEOM_Superv_i::GetBlocksByParts" );
2703   return NULL;
2704 }
2705
2706 //=============================================================================
2707 //  MakeMultiTransformation1D:
2708 //=============================================================================
2709 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeMultiTransformation1D (GEOM::GEOM_Object_ptr theBlock,
2710                                                                 CORBA::Long     theDirFace1,
2711                                                                 CORBA::Long     theDirFace2,
2712                                                                 CORBA::Long     theNbTimes)
2713 {
2714   beginService( " GEOM_Superv_i::MakeMultiTransformation1D" );
2715   MESSAGE("GEOM_Superv_i::MakeMultiTransformation1D");
2716   getBlocksOp();
2717   GEOM::GEOM_Object_ptr anObj = myBlocksOp->MakeMultiTransformation1D(theBlock, theDirFace1, theDirFace2, theNbTimes);
2718   endService( " GEOM_Superv_i::MakeMultiTransformation1D" );
2719   return anObj;
2720 }
2721
2722 //=============================================================================
2723 //  MakeMultiTransformation2D:
2724 //=============================================================================
2725 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeMultiTransformation2D
2726 (GEOM::GEOM_Object_ptr theBlock,
2727  CORBA::Long     theDirFace1U,
2728  CORBA::Long     theDirFace2U,
2729  CORBA::Long     theNbTimesU,
2730  CORBA::Long     theDirFace1V,
2731  CORBA::Long     theDirFace2V,
2732  CORBA::Long     theNbTimesV)
2733 {
2734   beginService( " GEOM_Superv_i::MakeMultiTransformation2D" );
2735   MESSAGE("GEOM_Superv_i::MakeMultiTransformation2D");
2736   getBlocksOp();
2737   GEOM::GEOM_Object_ptr anObj = myBlocksOp->MakeMultiTransformation2D(theBlock,
2738                                                                       theDirFace1U, theDirFace2U, theNbTimesU,
2739                                                                       theDirFace1V, theDirFace2V, theNbTimesV);
2740   endService( " GEOM_Superv_i::MakeMultiTransformation2D" );
2741   return anObj;
2742 }
2743
2744 //=============================== CurvesOperations ============================
2745 //=============================================================================
2746 //  MakeCirclePntVecR:
2747 //=============================================================================
2748 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeCirclePntVecR (GEOM::GEOM_Object_ptr theCenter,
2749                                                         GEOM::GEOM_Object_ptr theVector,
2750                                                         CORBA::Double theR)
2751 {
2752   beginService( " GEOM_Superv_i::MakeCirclePntVecR" );
2753   MESSAGE("GEOM_Superv_i::MakeCirclePntVecR");
2754   getCurvesOp();
2755   GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeCirclePntVecR(theCenter, theVector, theR);
2756   endService( " GEOM_Superv_i::MakeCirclePntVecR" );
2757   return anObj;
2758 }
2759
2760 //=============================================================================
2761 //  MakeCircleThreePnt:
2762 //=============================================================================
2763 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeCircleThreePnt (GEOM::GEOM_Object_ptr thePnt1,
2764                                                          GEOM::GEOM_Object_ptr thePnt2,
2765                                                          GEOM::GEOM_Object_ptr thePnt3)
2766 {
2767   beginService( " GEOM_Superv_i::MakeCircleThreePnt" );
2768   MESSAGE("GEOM_Superv_i::MakeCircleThreePnt");
2769   getCurvesOp();
2770   GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeCircleThreePnt(thePnt1, thePnt2, thePnt3);
2771   endService( " GEOM_Superv_i::MakeCircleThreePnt" );
2772   return anObj;
2773 }
2774 //=============================================================================
2775 //  MakeCircleCenter2Pnt:
2776 //=============================================================================
2777 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeCircleCenter2Pnt (GEOM::GEOM_Object_ptr thePnt1,
2778                                                              GEOM::GEOM_Object_ptr thePnt2,
2779                                                            GEOM::GEOM_Object_ptr thePnt3)
2780 {
2781   beginService( " GEOM_Superv_i::MakeCircleCenter2Pnt" );
2782   MESSAGE("GEOM_Superv_i::MakeCircleCenter2Pnt");
2783   getCurvesOp();
2784   GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeCircleCenter2Pnt(thePnt1, thePnt2, thePnt3);
2785   endService( " GEOM_Superv_i::MakeCircleCenter2Pnt" );
2786   return anObj;
2787 }
2788
2789 //=============================================================================
2790 //  MakeEllipse:
2791 //=============================================================================
2792 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeEllipse (GEOM::GEOM_Object_ptr theCenter,
2793                                                   GEOM::GEOM_Object_ptr theVector,
2794                                                   CORBA::Double theRMajor,
2795                                                   CORBA::Double theRMinor)
2796 {
2797   beginService( " GEOM_Superv_i::MakeEllipse" );
2798   MESSAGE("GEOM_Superv_i::MakeEllipse");
2799   getCurvesOp();
2800   GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeEllipse(theCenter, theVector, theRMajor, theRMinor);
2801   endService( " GEOM_Superv_i::MakeEllipse" );
2802   return anObj;
2803 }
2804
2805 //=============================================================================
2806 //  MakeEllipseVec:
2807 //=============================================================================
2808 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeEllipseVec (GEOM::GEOM_Object_ptr theCenter,
2809                                                      GEOM::GEOM_Object_ptr theVector,
2810                                                      CORBA::Double theRMajor,
2811                                                      CORBA::Double theRMinor,
2812                                                      GEOM::GEOM_Object_ptr theVectorMajor)
2813 {
2814   beginService( " GEOM_Superv_i::MakeEllipseVec" );
2815   MESSAGE("GEOM_Superv_i::MakeEllipseVec");
2816   getCurvesOp();
2817   GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeEllipseVec(theCenter, theVector, theRMajor, theRMinor, theVectorMajor);
2818   endService( " GEOM_Superv_i::MakeEllipseVec" );
2819   return anObj;
2820 }
2821
2822 //=============================================================================
2823 //  MakeArc:
2824 //=============================================================================
2825 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeArc (GEOM::GEOM_Object_ptr thePnt1,
2826                                               GEOM::GEOM_Object_ptr thePnt2,
2827                                               GEOM::GEOM_Object_ptr thePnt3)
2828 {
2829   beginService( " GEOM_Superv_i::MakeArc" );
2830   MESSAGE("GEOM_Superv_i::MakeArc");
2831   getCurvesOp();
2832   GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeArc(thePnt1, thePnt2, thePnt3);
2833   endService( " GEOM_Superv_i::MakeArc" );
2834   return anObj;
2835 }
2836
2837 //=============================================================================
2838 //  MakeArcCenter:
2839 //=============================================================================
2840 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeArcCenter (GEOM::GEOM_Object_ptr theCenter,
2841                                                     GEOM::GEOM_Object_ptr thePnt1,
2842                                                     GEOM::GEOM_Object_ptr thePnt2,
2843                                                     CORBA::Boolean theSense)
2844 {
2845   beginService( " GEOM_Superv_i::MakeArcCenter" );
2846   MESSAGE("GEOM_Superv_i::MakeArcCenter");
2847   getCurvesOp();
2848   GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeArcCenter(theCenter, thePnt1, thePnt2,theSense);
2849   endService( " GEOM_Superv_i::MakeArcCenter" );
2850   return anObj;
2851 }
2852
2853 //=============================================================================
2854 //  MakeArcOfEllipse:
2855 //=============================================================================
2856 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeArcOfEllipse (GEOM::GEOM_Object_ptr thePnt1,
2857                                                        GEOM::GEOM_Object_ptr thePnt2,
2858                                                        GEOM::GEOM_Object_ptr thePnt3)
2859 {
2860   beginService( " GEOM_Superv_i::MakeArcOfEllipse" );
2861   MESSAGE("GEOM_Superv_i::MakeArcOfEllipse");
2862   getCurvesOp();
2863   GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeArcOfEllipse(thePnt1, thePnt2, thePnt3);
2864   endService( " GEOM_Superv_i::MakeArcOfEllipse" );
2865   return anObj;
2866 }
2867
2868 //=============================================================================
2869 //  MakePolyline:
2870 //=============================================================================
2871 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakePolyline (GEOM::GEOM_List_ptr thePoints,
2872                                                    CORBA::Boolean      theIsClosed)
2873 {
2874   beginService( " GEOM_Superv_i::MakePolyline" );
2875   MESSAGE("GEOM_Superv_i::MakePolyline");
2876   if (GEOM_List_i<GEOM::ListOfGO>* aListImplP =
2877       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(thePoints, myPOA).in())) {
2878     getCurvesOp();
2879     GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakePolyline(aListImplP->GetList(), theIsClosed);
2880     endService( " GEOM_Superv_i::MakePolyline" );
2881     return anObj;
2882   }
2883   endService( " GEOM_Superv_i::MakePolyline" );
2884   return NULL;
2885 }
2886
2887 //=============================================================================
2888 //  MakeSplineBezier:
2889 //=============================================================================
2890 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSplineBezier (GEOM::GEOM_List_ptr thePoints,
2891                                                        CORBA::Boolean      theIsClosed)
2892 {
2893   beginService( " GEOM_Superv_i::MakeSplineBezier" );
2894   MESSAGE("GEOM_Superv_i::MakeSplineBezier");
2895   if (GEOM_List_i<GEOM::ListOfGO>* aListImplP =
2896       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(thePoints, myPOA).in())) {
2897     getCurvesOp();
2898     GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeSplineBezier(aListImplP->GetList(), theIsClosed);
2899     endService( " GEOM_Superv_i::MakeSplineBezier" );
2900     return anObj;
2901   }
2902   endService( " GEOM_Superv_i::MakeSplineBezier" );
2903   return NULL;
2904 }
2905
2906 //=============================================================================
2907 //  MakeSplineInterpolation:
2908 //=============================================================================
2909 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSplineInterpolation (GEOM::GEOM_List_ptr thePoints,
2910                                                               CORBA::Boolean      theIsClosed,
2911                                                               CORBA::Boolean      theDoReordering)
2912 {
2913   beginService( " GEOM_Superv_i::MakeSplineInterpolation" );
2914   MESSAGE("GEOM_Superv_i::MakeSplineInterpolation");
2915   if (GEOM_List_i<GEOM::ListOfGO>* aListImplP =
2916       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(thePoints, myPOA).in())) {
2917     getCurvesOp();
2918     GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeSplineInterpolation(aListImplP->GetList(), theIsClosed, theDoReordering);
2919     endService( " GEOM_Superv_i::MakeSplineInterpolation" );
2920     return anObj;
2921   }
2922   endService( " GEOM_Superv_i::MakeSplineInterpolation" );
2923   return NULL;
2924 }
2925
2926 //=============================================================================
2927 //  MakeSketcher:
2928 //=============================================================================
2929 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSketcher (const char* theCommand,
2930                                                    GEOM::GEOM_List_ptr theWorkingPlane)
2931 {
2932   beginService( " GEOM_Superv_i::MakeSketcher" );
2933   MESSAGE("GEOM_Superv_i::MakeSketcher");
2934   if (GEOM_List_i<GEOM::ListOfDouble>* aListImplWP =
2935       dynamic_cast<GEOM_List_i<GEOM::ListOfDouble>*>(GetServant(theWorkingPlane, myPOA).in())) {
2936     getCurvesOp();
2937     GEOM::GEOM_Object_ptr anObj = myCurvesOp->MakeSketcher(theCommand, aListImplWP->GetList());
2938     endService( " GEOM_Superv_i::MakeSketcher" );
2939     return anObj;
2940   }
2941   endService( " GEOM_Superv_i::MakeSketcher" );
2942   return NULL;
2943 }
2944
2945 //=============================================================================
2946 //  Make3DSketcher:
2947 //=============================================================================
2948 GEOM::GEOM_Object_ptr GEOM_Superv_i::Make3DSketcher ( GEOM::GEOM_List_ptr theCoordinates)
2949 {
2950   beginService( " GEOM_Superv_i::Make3DSketcher" );
2951   MESSAGE("GEOM_Superv_i::Make3DSketcher");
2952   if (GEOM_List_i<GEOM::ListOfDouble>* aListImpl =
2953       dynamic_cast<GEOM_List_i<GEOM::ListOfDouble>*>(GetServant(theCoordinates, myPOA).in())) {
2954     getCurvesOp();
2955     GEOM::GEOM_Object_ptr anObj = myCurvesOp->Make3DSketcher(aListImpl->GetList());
2956     endService( " GEOM_Superv_i::Make3DSketcher" );
2957     return anObj;
2958   }
2959   endService( " GEOM_Superv_i::Make3DSketcher" );
2960   return NULL;
2961 }
2962
2963 //=============================== LocalOperations =============================
2964 //=============================================================================
2965 //  MakeFilletAll:
2966 //=============================================================================
2967 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFilletAll (GEOM::GEOM_Object_ptr theShape,
2968                                                     CORBA::Double theR)
2969 {
2970   beginService( " GEOM_Superv_i::MakeFilletAll" );
2971   MESSAGE("GEOM_Superv_i::MakeFilletAllMakeSketcher");
2972   getLocalOp();
2973   GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeFilletAll(theShape, theR);
2974   endService( " GEOM_Superv_i::MakeFilletAll" );
2975   return anObj;
2976 }
2977
2978 //=============================================================================
2979 //  MakeFilletEdges:
2980 //=============================================================================
2981 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFilletEdges (GEOM::GEOM_Object_ptr theShape,
2982                                                       CORBA::Double theR,
2983                                                       GEOM::GEOM_List_ptr theEdges)
2984 {
2985   beginService( " GEOM_Superv_i::MakeFilletEdges" );
2986   MESSAGE("GEOM_Superv_i::MakeFilletEdges");
2987   if (GEOM_List_i<GEOM::ListOfLong>* aListImplE =
2988       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theEdges, myPOA).in())) {
2989     getLocalOp();
2990     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeFilletEdges(theShape, theR, aListImplE->GetList());
2991     endService( " GEOM_Superv_i::MakeFilletEdges" );
2992     return anObj;
2993   }
2994   endService( " GEOM_Superv_i::MakeFilletEdges" );
2995   return NULL;
2996 }
2997
2998 //=============================================================================
2999 //  MakeFilletEdges R1 R2:
3000 //=============================================================================
3001 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFilletEdgesR1R2 (GEOM::GEOM_Object_ptr theShape,
3002                                                           CORBA::Double theR1,
3003                                                           CORBA::Double theR2,
3004                                                           GEOM::GEOM_List_ptr theEdges)
3005 {
3006   beginService( " GEOM_Superv_i::MakeFilletEdgesR1R2" );
3007   MESSAGE("GEOM_Superv_i::MakeFilletEdgesR1R2");
3008   if (GEOM_List_i<GEOM::ListOfLong>* aListImplE =
3009       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theEdges, myPOA).in())) {
3010     getLocalOp();
3011     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeFilletEdgesR1R2(theShape, theR1,
3012                                                                  theR2, aListImplE->GetList());
3013     endService( " GEOM_Superv_i::MakeFilletEdgesR1R2" );
3014     return anObj;
3015   }
3016   endService( " GEOM_Superv_i::MakeFilletEdgesR1R2" );
3017   return NULL;
3018 }
3019
3020 //=============================================================================
3021 //  MakeFilletFaces:
3022 //=============================================================================
3023 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFilletFaces (GEOM::GEOM_Object_ptr theShape,
3024                                                       CORBA::Double theR,
3025                                                       GEOM::GEOM_List_ptr theFaces)
3026 {
3027   beginService( " GEOM_Superv_i::MakeFilletFaces" );
3028   MESSAGE("GEOM_Superv_i::MakeFilletFaces");
3029   if (GEOM_List_i<GEOM::ListOfLong>* aListImplF =
3030       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theFaces, myPOA).in())) {
3031     getLocalOp();
3032     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeFilletFaces(theShape, theR, aListImplF->GetList());
3033     endService( " GEOM_Superv_i::MakeFilletFaces" );
3034     return anObj;
3035   }
3036   endService( " GEOM_Superv_i::MakeFilletFaces" );
3037   return NULL;
3038 }
3039
3040 //=============================================================================
3041 //  MakeFilletFaces R1 R2:
3042 //=============================================================================
3043 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFilletFacesR1R2 (GEOM::GEOM_Object_ptr theShape,
3044                                                           CORBA::Double theR1,
3045                                                           CORBA::Double theR2,
3046                                                           GEOM::GEOM_List_ptr theFaces)
3047 {
3048   beginService( " GEOM_Superv_i::MakeFilletFacesR1R2" );
3049   MESSAGE("GEOM_Superv_i::MakeFilletFacesR1R2");
3050   if (GEOM_List_i<GEOM::ListOfLong>* aListImplF =
3051       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theFaces, myPOA).in())) {
3052     getLocalOp();
3053     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeFilletFacesR1R2(theShape, theR1, theR2,
3054                                                                  aListImplF->GetList());
3055     endService( " GEOM_Superv_i::MakeFilletFacesR1R2" );
3056     return anObj;
3057   }
3058   endService( " GEOM_Superv_i::MakeFilletFacesR1R2" );
3059   return NULL;
3060 }
3061
3062 //=============================================================================
3063 //  MakeFillet2D:
3064 //=============================================================================
3065 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFillet2D (GEOM::GEOM_Object_ptr theShape,
3066                                                    CORBA::Double theR,
3067                                                    GEOM::GEOM_List_ptr theVertexes)
3068 {
3069   beginService( " GEOM_Superv_i::MakeFillet2D" );
3070   MESSAGE("GEOM_Superv_i::MakeFillet2D");
3071   if (GEOM_List_i<GEOM::ListOfLong>* aListImplV =
3072       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theVertexes, myPOA).in())) {
3073     getLocalOp();
3074     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeFillet2D(theShape, theR, aListImplV->GetList());
3075     endService( " GEOM_Superv_i::MakeFillet2D" );
3076     return anObj;
3077   }
3078   endService( " GEOM_Superv_i::MakeFillet2D" );
3079   return NULL;
3080 }
3081
3082 //=============================================================================
3083 //  MakeFillet1D:
3084 //=============================================================================
3085 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeFillet1D (GEOM::GEOM_Object_ptr theShape,
3086                                                    CORBA::Double theR,
3087                                                    GEOM::GEOM_List_ptr theVertexes,
3088                                                    CORBA::Boolean doIgnoreSecantVertices)
3089 {
3090   beginService( " GEOM_Superv_i::MakeFillet1D" );
3091   MESSAGE("GEOM_Superv_i::MakeFillet1D");
3092   if (GEOM_List_i<GEOM::ListOfLong>* aListImplV =
3093       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theVertexes, myPOA).in())) {
3094     getLocalOp();
3095     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeFillet1D
3096       (theShape, theR, aListImplV->GetList(), doIgnoreSecantVertices);
3097     endService( " GEOM_Superv_i::MakeFillet1D" );
3098     return anObj;
3099   }
3100   endService( " GEOM_Superv_i::MakeFillet1D" );
3101   return NULL;
3102 }
3103
3104 //=============================================================================
3105 //  MakeChamferAll:
3106 //=============================================================================
3107 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeChamferAll (GEOM::GEOM_Object_ptr theShape, CORBA::Double theD)
3108 {
3109   beginService( " GEOM_Superv_i::MakeChamferAll" );
3110   MESSAGE("GEOM_Superv_i::MakeChamferAll");
3111   getLocalOp();
3112   GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeChamferAll(theShape, theD);
3113   endService( " GEOM_Superv_i::MakeChamferAll" );
3114   return anObj;
3115 }
3116
3117 //=============================================================================
3118 //  MakeChamferEdge:
3119 //=============================================================================
3120 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeChamferEdge (GEOM::GEOM_Object_ptr theShape,
3121                                                       CORBA::Double theD1, CORBA::Double theD2,
3122                                                       CORBA::Long theFace1, CORBA::Long theFace2)
3123 {
3124   beginService( " GEOM_Superv_i::MakeChamferEdge" );
3125   MESSAGE("GEOM_Superv_i::MakeChamferEdge");
3126   getLocalOp();
3127   GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeChamferEdge(theShape, theD1, theD2, theFace1, theFace2);
3128   endService( " GEOM_Superv_i::MakeChamferEdge" );
3129   return anObj;
3130 }
3131
3132 //=============================================================================
3133 //  MakeChamferEdgeAD:
3134 //=============================================================================
3135 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeChamferEdgeAD (GEOM::GEOM_Object_ptr theShape,
3136                                                         CORBA::Double theD, CORBA::Double theAngle,
3137                                                         CORBA::Long theFace1, CORBA::Long theFace2)
3138 {
3139   beginService( " GEOM_Superv_i::MakeChamferEdgeAD" );
3140   MESSAGE("GEOM_Superv_i::MakeChamferEdgeAD");
3141   getLocalOp();
3142   GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeChamferEdgeAD(theShape, theD, theAngle, theFace1, theFace2);
3143   endService( " GEOM_Superv_i::MakeChamferEdgeAD" );
3144   return anObj;
3145 }
3146
3147 //=============================================================================
3148 //  MakeChamferFaces:
3149 //=============================================================================
3150 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeChamferFaces (GEOM::GEOM_Object_ptr theShape,
3151                                                        CORBA::Double theD1, CORBA::Double theD2,
3152                                                        GEOM::GEOM_List_ptr theFaces)
3153 {
3154   beginService( " GEOM_Superv_i::MakeChamferFaces" );
3155   MESSAGE("GEOM_Superv_i::MakeChamferFaces");
3156   if (GEOM_List_i<GEOM::ListOfLong>* aListImplF =
3157       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theFaces, myPOA).in())) {
3158     getLocalOp();
3159     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeChamferFaces(theShape, theD1, theD2, aListImplF->GetList());
3160     endService( " GEOM_Superv_i::MakeChamferFaces" );
3161     return anObj;
3162   }
3163   endService( " GEOM_Superv_i::MakeChamferFaces" );
3164   return NULL;
3165 }
3166
3167 //=============================================================================
3168 //  MakeChamferFacesAD:
3169 //=============================================================================
3170 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeChamferFacesAD (GEOM::GEOM_Object_ptr theShape,
3171                                                          CORBA::Double theD, CORBA::Double theAngle,
3172                                                          GEOM::GEOM_List_ptr theFaces)
3173 {
3174   beginService( " GEOM_Superv_i::MakeChamferFacesAD" );
3175   MESSAGE("GEOM_Superv_i::MakeChamferFacesAD");
3176   if (GEOM_List_i<GEOM::ListOfLong>* aListImplF =
3177       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theFaces, myPOA).in())) {
3178     getLocalOp();
3179     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeChamferFacesAD(theShape, theD, theAngle, aListImplF->GetList());
3180     endService( " GEOM_Superv_i::MakeChamferFacesAD" );
3181     return anObj;
3182   }
3183   endService( " GEOM_Superv_i::MakeChamferFacesAD" );
3184   return NULL;
3185 }
3186
3187 //=============================================================================
3188 //  MakeChamferEdges:
3189 //=============================================================================
3190 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeChamferEdges (GEOM::GEOM_Object_ptr theShape,
3191                                                        CORBA::Double theD1, CORBA::Double theD2,
3192                                                        GEOM::GEOM_List_ptr theEdges)
3193 {
3194   beginService( " GEOM_Superv_i::MakeChamferEdges" );
3195   MESSAGE("GEOM_Superv_i::MakeChamferEdges");
3196   if (GEOM_List_i<GEOM::ListOfLong>* aListImplF =
3197       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theEdges, myPOA).in())) {
3198     getLocalOp();
3199     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeChamferEdges(theShape, theD1, theD2, aListImplF->GetList());
3200     endService( " GEOM_Superv_i::MakeChamferEdges" );
3201     return anObj;
3202   }
3203   endService( " GEOM_Superv_i::MakeChamferEdges" );
3204   return NULL;
3205 }
3206
3207 //=============================================================================
3208 //  MakeChamferEdgesAD:
3209 //=============================================================================
3210 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeChamferEdgesAD (GEOM::GEOM_Object_ptr theShape,
3211                                                          CORBA::Double theD, CORBA::Double theAngle,
3212                                                          GEOM::GEOM_List_ptr theEdges)
3213 {
3214   beginService( " GEOM_Superv_i::MakeChamferEdgesAD" );
3215   MESSAGE("GEOM_Superv_i::MakeChamferEdgesAD");
3216   if (GEOM_List_i<GEOM::ListOfLong>* aListImplF =
3217       dynamic_cast<GEOM_List_i<GEOM::ListOfLong>*>(GetServant(theEdges, myPOA).in())) {
3218     getLocalOp();
3219     GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeChamferEdgesAD(theShape, theD, theAngle, aListImplF->GetList());
3220     endService( " GEOM_Superv_i::MakeChamferEdgesAD" );
3221     return anObj;
3222   }
3223   endService( " GEOM_Superv_i::MakeChamferEdgesAD" );
3224   return NULL;
3225 }
3226
3227 //=============================================================================
3228 //  MakeArchimede:
3229 //=============================================================================
3230 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeArchimede (GEOM::GEOM_Object_ptr theShape,
3231                                                     CORBA::Double theWeight,
3232                                                     CORBA::Double theWaterDensity,
3233                                                     CORBA::Double theMeshingDeflection)
3234 {
3235   beginService( " GEOM_Superv_i::MakeArchimede" );
3236   MESSAGE("GEOM_Superv_i::MakeArchimede");
3237   getLocalOp();
3238   GEOM::GEOM_Object_ptr anObj = myLocalOp->MakeArchimede(theShape, theWeight, theWaterDensity, theMeshingDeflection);
3239   endService( " GEOM_Superv_i::MakeArchimede" );
3240   return anObj;
3241 }
3242
3243 //=============================================================================
3244 //  GetSubShapeIndexMakeFilletAll:
3245 //=============================================================================
3246 CORBA::Long GEOM_Superv_i::GetSubShapeIndex (GEOM::GEOM_Object_ptr theShape,
3247                                              GEOM::GEOM_Object_ptr theSubShape)
3248 {
3249   beginService( " GEOM_Superv_i::GetSubShapeIndex" );
3250   MESSAGE("GEOM_Superv_i::GetSubShapeIndexMakeArchimede");
3251   getLocalOp();
3252   CORBA::Long aRes = myLocalOp->GetSubShapeIndex(theShape, theSubShape);
3253   endService( " GEOM_Superv_i::GetSubShapeIndex" );
3254   return aRes;
3255 }
3256
3257 //=============================== GroupOperations =============================
3258 //=============================================================================
3259 //  CreateGroup:
3260 //=============================================================================
3261 GEOM::GEOM_Object_ptr GEOM_Superv_i::CreateGroup (GEOM::GEOM_Object_ptr theMainShape,
3262                                                   CORBA::Long theShapeType)
3263 {
3264   beginService( " GEOM_Superv_i::CreateGroup" );
3265   MESSAGE("GEOM_Superv_i::CreateGroup");
3266   getGroupOp();
3267   GEOM::GEOM_Object_ptr anObj = myGroupOp->CreateGroup(theMainShape, theShapeType);
3268   endService( " GEOM_Superv_i::CreateGroup" );
3269   return anObj;
3270 }
3271
3272 //=============================================================================
3273 //  AddObject:
3274 //=============================================================================
3275 void GEOM_Superv_i::AddObject (GEOM::GEOM_Object_ptr theGroup,
3276                                CORBA::Long theSubShapeId)
3277 {
3278   beginService( " GEOM_Superv_i::AddObject" );
3279   MESSAGE("GEOM_Superv_i::AddObject");
3280   getGroupOp();
3281   myGroupOp->AddObject(theGroup, theSubShapeId);
3282   endService( " GEOM_Superv_i::AddObject" );
3283 }
3284
3285 //=============================================================================
3286 //  RemoveObject:
3287 //=============================================================================
3288 void GEOM_Superv_i::RemoveObject (GEOM::GEOM_Object_ptr theGroup,
3289                                   CORBA::Long theSubShapeId)
3290 {
3291   beginService( " GEOM_Superv_i::RemoveObject" );
3292   MESSAGE("GEOM_Superv_i::RemoveObject");
3293   getGroupOp();
3294   myGroupOp->RemoveObject(theGroup, theSubShapeId);
3295   endService( " GEOM_Superv_i::RemoveObject" );
3296 }
3297
3298 //=============================================================================
3299 //  GetType:
3300 //=============================================================================
3301 CORBA::Long GEOM_Superv_i::GetType (GEOM::GEOM_Object_ptr theGroup)
3302 {
3303   beginService( " GEOM_Superv_i::GetType" );
3304   MESSAGE("GEOM_Superv_i::GetType");
3305   getGroupOp();
3306   CORBA::Long aResult = myGroupOp->GetType(theGroup);
3307   endService( " GEOM_Superv_i::GetType" );
3308   return aResult;
3309 }
3310
3311 //=============================================================================
3312 //  GetMainShape:
3313 //=============================================================================
3314 GEOM::GEOM_Object_ptr GEOM_Superv_i::GetMainShape (GEOM::GEOM_Object_ptr theGroup)
3315 {
3316   beginService( " GEOM_Superv_i::GetMainShape" );
3317   MESSAGE("GEOM_Superv_i::GetMainShape");
3318   getGroupOp();
3319   GEOM::GEOM_Object_ptr anObj = myGroupOp->GetMainShape(theGroup);
3320   endService( " GEOM_Superv_i::GetMainShape" );
3321   return anObj;
3322 }
3323
3324 //=============================================================================
3325 //  GetObjects:
3326 //=============================================================================
3327 GEOM::GEOM_List_ptr GEOM_Superv_i::GetObjects (GEOM::GEOM_Object_ptr theGroup)
3328 {
3329   beginService( " GEOM_Superv_i::GetObjects" );
3330   MESSAGE("GEOM_Superv_i::GetObjects");
3331   getGroupOp();
3332
3333   GEOM::ListOfLong* aList = myGroupOp->GetObjects(theGroup);
3334   GEOM_List_i<GEOM::ListOfLong>* aListPtr = new GEOM_List_i<GEOM::ListOfLong>(*(aList));
3335   MESSAGE(" List of "<<aListPtr->GetList().length()<<" element(s)");
3336   endService( " GEOM_Superv_i::GetObjects" );
3337   return aListPtr->_this();
3338 }
3339
3340 //=============================================================================
3341 //  ExportXAO
3342 //=============================================================================
3343 CORBA::Boolean GEOM_Superv_i::ExportXAO (GEOM::GEOM_Object_ptr shape,
3344                                          const GEOM::ListOfGO& groups, const GEOM::ListOfFields& fields,
3345                                          const char* author, const char* fileName)
3346 {
3347   beginService( " GEOM_Superv_i::ExportXAO" );
3348   MESSAGE("GEOM_Superv_i::ExportXAO");
3349   getInsOp();
3350   CORBA::Boolean isGood = myInsOp->ExportXAO(shape, groups, fields, author, fileName);
3351   endService( " GEOM_Superv_i::ExportXAO" );
3352   return isGood;
3353 }
3354
3355 //=============================================================================
3356 //  ImportXAO
3357 //=============================================================================
3358 CORBA::Boolean GEOM_Superv_i::ImportXAO (const char* fileName, GEOM::GEOM_Object_out shape, 
3359                                          GEOM::ListOfGO_out subShapes, GEOM::ListOfGO_out groups, GEOM::ListOfFields_out fields)
3360 {
3361   return false;
3362 }
3363
3364 //=============================== Advanced Operations =============================
3365 //=============================================================================
3366 //  MakePipeTShape
3367 //=============================================================================
3368 GEOM::GEOM_List_ptr GEOM_Superv_i::MakePipeTShape
3369                     (CORBA::Double theR1, CORBA::Double theW1, CORBA::Double theL1,
3370                      CORBA::Double theR2, CORBA::Double theW2, CORBA::Double theL2,
3371                      CORBA::Boolean theHexMesh)
3372 {
3373   beginService( " GEOM_Superv_i::MakePipeTShape" );
3374   MESSAGE("GEOM_Superv_i::MakePipeTShape");
3375   getAdvancedOp();
3376
3377   GEOM::ListOfGO* aSeq = myAdvancedOp->MakePipeTShape(theR1, theW1, theL1, theR2, theW2, theL2, theHexMesh);
3378   GEOM_List_i<GEOM::ListOfGO>* aSeqPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aSeq));
3379   MESSAGE(" List of "<<aSeqPtr->GetList().length()<<" element(s)");
3380   endService( " GEOM_Superv_i::MakePipeTShape" );
3381   return aSeqPtr->_this();
3382 }
3383
3384 //=============================================================================
3385 //  MakePipeTShapeWithPosition
3386 //=============================================================================
3387 GEOM::GEOM_List_ptr GEOM_Superv_i::MakePipeTShapeWithPosition
3388                     (CORBA::Double theR1, CORBA::Double theW1, CORBA::Double theL1,
3389                      CORBA::Double theR2, CORBA::Double theW2, CORBA::Double theL2, CORBA::Boolean theHexMesh,
3390                      GEOM::GEOM_Object_ptr theP1, GEOM::GEOM_Object_ptr theP2, GEOM::GEOM_Object_ptr theP3)
3391 {
3392   beginService( " GEOM_Superv_i::MakePipeTShapeWithPosition" );
3393   MESSAGE("GEOM_Superv_i::MakePipeTShapeWithPosition");
3394   getAdvancedOp();
3395
3396   GEOM::ListOfGO* aSeq = myAdvancedOp->MakePipeTShapeWithPosition(theR1, theW1, theL1, theR2, theW2, theL2, theHexMesh, theP1, theP2, theP3);
3397   GEOM_List_i<GEOM::ListOfGO>* aSeqPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aSeq));
3398   MESSAGE(" List of "<<aSeqPtr->GetList().length()<<" element(s)");
3399   endService( " GEOM_Superv_i::MakePipeTShapeWithPosition" );
3400   return aSeqPtr->_this();
3401 }
3402
3403 //=============================================================================
3404 //  MakePipeTShapeChamfer
3405 //=============================================================================
3406 GEOM::GEOM_List_ptr GEOM_Superv_i::MakePipeTShapeChamfer
3407                     (CORBA::Double theR1, CORBA::Double theW1, CORBA::Double theL1,
3408                      CORBA::Double theR2, CORBA::Double theW2, CORBA::Double theL2,
3409                      CORBA::Double theH, CORBA::Double theW, CORBA::Boolean theHexMesh)
3410 {
3411   beginService( " GEOM_Superv_i::MakePipeTShapeChamfer" );
3412   MESSAGE("GEOM_Superv_i::MakePipeTShapeChamfer");
3413   getAdvancedOp();
3414
3415   GEOM::ListOfGO* aSeq = myAdvancedOp->MakePipeTShapeChamfer(theR1, theW1, theL1, theR2, theW2, theL2, theH, theW, theHexMesh);
3416   GEOM_List_i<GEOM::ListOfGO>* aSeqPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aSeq));
3417   MESSAGE(" List of "<<aSeqPtr->GetList().length()<<" element(s)");
3418   endService( " GEOM_Superv_i::MakePipeTShapeChamfer" );
3419   return aSeqPtr->_this();
3420 }
3421
3422 //=============================================================================
3423 //  MakePipeTShapeChamferWithPosition
3424 //=============================================================================
3425 GEOM::GEOM_List_ptr GEOM_Superv_i::MakePipeTShapeChamferWithPosition
3426                     (CORBA::Double theR1, CORBA::Double theW1, CORBA::Double theL1,
3427                      CORBA::Double theR2, CORBA::Double theW2, CORBA::Double theL2,
3428                      CORBA::Double theH, CORBA::Double theW, CORBA::Boolean theHexMesh,
3429                      GEOM::GEOM_Object_ptr theP1, GEOM::GEOM_Object_ptr theP2, GEOM::GEOM_Object_ptr theP3)
3430 {
3431   beginService( " GEOM_Superv_i::MakePipeTShapeChamferWithPosition" );
3432   MESSAGE("GEOM_Superv_i::MakePipeTShapeChamferWithPosition");
3433   getAdvancedOp();
3434
3435   GEOM::ListOfGO* aSeq = myAdvancedOp->MakePipeTShapeChamferWithPosition(theR1, theW1, theL1, theR2, theW2, theL2, theH, theW, theHexMesh, theP1, theP2, theP3);
3436   GEOM_List_i<GEOM::ListOfGO>* aSeqPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aSeq));
3437   MESSAGE(" List of "<<aSeqPtr->GetList().length()<<" element(s)");
3438   endService( " GEOM_Superv_i::MakePipeTShapeChamferWithPosition" );
3439   return aSeqPtr->_this();
3440 }
3441
3442 //=============================================================================
3443 //  MakePipeTShapeFillet
3444 //=============================================================================
3445 GEOM::GEOM_List_ptr GEOM_Superv_i::MakePipeTShapeFillet
3446                     (CORBA::Double theR1, CORBA::Double theW1, CORBA::Double theL1,
3447                      CORBA::Double theR2, CORBA::Double theW2, CORBA::Double theL2,
3448                      CORBA::Double theRF, CORBA::Boolean theHexMesh)
3449 {
3450   beginService( " GEOM_Superv_i::MakePipeTShapeFillet" );
3451   MESSAGE("GEOM_Superv_i::MakePipeTShapeFillet");
3452   getAdvancedOp();
3453
3454   GEOM::ListOfGO* aSeq = myAdvancedOp->MakePipeTShapeFillet(theR1, theW1, theL1, theR2, theW2, theL2, theRF, theHexMesh);
3455   GEOM_List_i<GEOM::ListOfGO>* aSeqPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aSeq));
3456   MESSAGE(" List of "<<aSeqPtr->GetList().length()<<" element(s)");
3457   endService( " GEOM_Superv_i::MakePipeTShapeFillet" );
3458   return aSeqPtr->_this();
3459 }
3460
3461 //=============================================================================
3462 //  MakePipeTShapeFilletWithPosition
3463 //=============================================================================
3464 GEOM::GEOM_List_ptr GEOM_Superv_i::MakePipeTShapeFilletWithPosition
3465                     (CORBA::Double theR1, CORBA::Double theW1, CORBA::Double theL1,
3466                      CORBA::Double theR2, CORBA::Double theW2, CORBA::Double theL2,
3467                      CORBA::Double theRF, CORBA::Boolean theHexMesh,
3468                      GEOM::GEOM_Object_ptr theP1, GEOM::GEOM_Object_ptr theP2, GEOM::GEOM_Object_ptr theP3)
3469 {
3470   beginService( " GEOM_Superv_i::MakePipeTShapeFilletWithPosition" );
3471   MESSAGE("GEOM_Superv_i::MakePipeTShapeFilletWithPosition");
3472   getAdvancedOp();
3473
3474   GEOM::ListOfGO* aSeq = myAdvancedOp->MakePipeTShapeFilletWithPosition(theR1, theW1, theL1, theR2, theW2, theL2, theRF, theHexMesh, theP1, theP2, theP3);
3475   GEOM_List_i<GEOM::ListOfGO>* aSeqPtr = new GEOM_List_i<GEOM::ListOfGO>(*(aSeq));
3476   MESSAGE(" List of "<<aSeqPtr->GetList().length()<<" element(s)");
3477   endService( " GEOM_Superv_i::MakePipeTShapeFilletWithPosition" );
3478   return aSeqPtr->_this();
3479 }
3480
3481 //=============================================================================
3482 //  MakeDividedDisk
3483 //=============================================================================
3484 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeDividedDisk (CORBA::Double theR, CORBA::Double theRatio, 
3485                                                       CORBA::Short theOrientation, GEOM::pattern thePattern)
3486 {
3487   beginService( " GEOM_Superv_i::MakeDividedDisk" );
3488   MESSAGE("GEOM_Superv_i::MakeDividedDisk");
3489   getAdvancedOp();
3490   GEOM::GEOM_Object_ptr anObj = myAdvancedOp->MakeDividedDisk(theR, theRatio, theOrientation, thePattern);
3491   endService( " GEOM_Superv_i::MakeDividedDisk" );
3492   return anObj;
3493 }
3494
3495 //=============================================================================
3496 //  MakeDividedCylinder
3497 //=============================================================================
3498 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeDividedCylinder (CORBA::Double theR, 
3499                                                           CORBA::Double theH,
3500                                                           GEOM::pattern thePattern)
3501 {
3502   beginService( " GEOM_Superv_i::MakeDividedCylinder" );
3503   MESSAGE("GEOM_Superv_i::MakeDividedCylinder");
3504   getAdvancedOp();
3505   GEOM::GEOM_Object_ptr anObj = myAdvancedOp->MakeDividedCylinder(theR, theH, thePattern);
3506   endService( " GEOM_Superv_i::MakeDividedCylinder" );
3507   return anObj;
3508 }
3509
3510 //=============================================================================
3511 //  MakeSmoothingSurface
3512 //=============================================================================
3513 GEOM::GEOM_Object_ptr GEOM_Superv_i::MakeSmoothingSurface (GEOM::GEOM_List_ptr thelPoints)
3514 {
3515   beginService( " GEOM_Superv_i::MakeSmoothingSurface" );
3516   MESSAGE("GEOM_Superv_i::MakeSmoothingSurface");
3517   getAdvancedOp();
3518   if (GEOM_List_i<GEOM::ListOfGO>* aListImplP =
3519       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(thelPoints, myPOA).in())) {
3520     getCurvesOp();
3521     GEOM::GEOM_Object_ptr anObj = myAdvancedOp->MakeSmoothingSurface(aListImplP->GetList(), 2, 8, 0.);
3522     endService( " GEOM_Superv_i::MakeSmoothingSurface" );
3523     return anObj;
3524   }
3525   endService( " GEOM_Superv_i::MakeSmoothingSurface" );
3526   return NULL;
3527 }
3528
3529 /*@@ insert new functions before this line @@ do not remove this line @@*/
3530
3531 //=====================================================================================
3532 // EXPORTED METHODS
3533 //=====================================================================================
3534 extern "C"
3535 {
3536 #ifdef WIN32
3537   __declspec( dllexport )
3538 #endif
3539   PortableServer::ObjectId * GEOM_SupervEngine_factory(CORBA::ORB_ptr orb,
3540                                                        PortableServer::POA_ptr poa,
3541                                                        PortableServer::ObjectId * contId,
3542                                                        const char *instanceName,
3543                                                        const char * interfaceName)
3544   {
3545     GEOM_Superv_i * myGEOM_Superv_i = new GEOM_Superv_i(orb, poa, contId, instanceName, interfaceName);
3546     //Don't understand the reason why this component is registered ???
3547 //    myGEOM_Superv_i->register_name("/myGEOM_Superv");
3548     return myGEOM_Superv_i->getId() ;
3549   }
3550 }