Salome HOME
bos #29468: Advanced geometry features: distance Edge-Edge & Face-Face
[modules/geom.git] / src / GEOM_I / GEOM_I3DPrimOperations_i.cc
index e302bdb1e00d83b73aa159b6266746356565d263..54ba75082dad30ca9609508b6f587ee444704036 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2007-2014  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2022  CEA/DEN, EDF R&D, OPEN CASCADE
 //
 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@ -70,7 +70,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeBoxDXDYDZ (CORBA::Double the
   GetOperations()->SetNotDone();
 
   //Create the Box
-  Handle(GEOM_Object) anObject = GetOperations()->MakeBoxDXDYDZ(theDX, theDY, theDZ);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeBoxDXDYDZ(theDX, theDY, theDZ);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -90,13 +90,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeBoxTwoPnt
   //Set a not done flag
   GetOperations()->SetNotDone();
 
-  Handle(GEOM_Object) aPnt1 = GetObjectImpl(thePnt1);
-  Handle(GEOM_Object) aPnt2 = GetObjectImpl(thePnt2);
+  Handle(::GEOM_Object) aPnt1 = GetObjectImpl(thePnt1);
+  Handle(::GEOM_Object) aPnt2 = GetObjectImpl(thePnt2);
 
   if (aPnt1.IsNull() || aPnt2.IsNull()) return aGEOMObject._retn();
 
   //Create the Box
-  Handle(GEOM_Object) anObject = GetOperations()->MakeBoxTwoPnt(aPnt1, aPnt2);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeBoxTwoPnt(aPnt1, aPnt2);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -121,7 +121,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeFaceHW (CORBA::Double theH,
     return aGEOMObject._retn();
 
   //Create the Face
-  Handle(GEOM_Object) anObject = GetOperations()->MakeFaceHW(theH, theW, theOrientation);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeFaceHW(theH, theW, theOrientation);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -144,13 +144,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeFaceObjHW
   GetOperations()->SetNotDone();
 
   //Get the reference object
-  Handle(GEOM_Object) anObj = GetObjectImpl(theObj);
+  Handle(::GEOM_Object) anObj = GetObjectImpl(theObj);
 
   if (anObj.IsNull())
     return aGEOMObject._retn();
 
   //Create the Face
-  Handle(GEOM_Object) anObject = GetOperations()->MakeFaceObjHW(anObj, theH, theW);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeFaceObjHW(anObj, theH, theW);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -172,13 +172,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeDiskPntVecR
   GetOperations()->SetNotDone();
 
   //Get the reference points
-  Handle(GEOM_Object) aPnt = GetObjectImpl(thePnt);
-  Handle(GEOM_Object) aVec = GetObjectImpl(theVec);
+  Handle(::GEOM_Object) aPnt = GetObjectImpl(thePnt);
+  Handle(::GEOM_Object) aVec = GetObjectImpl(theVec);
 
   if (aPnt.IsNull() || aVec.IsNull()) return aGEOMObject._retn();
 
   // Make Disk
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakeDiskPntVecR(aPnt, aVec, theR);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -201,14 +201,14 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeDiskThreePnt
   GetOperations()->SetNotDone();
 
   //Get the reference points
-  Handle(GEOM_Object) aPnt1 = GetObjectImpl(thePnt1);
-  Handle(GEOM_Object) aPnt2 = GetObjectImpl(thePnt2);
-  Handle(GEOM_Object) aPnt3 = GetObjectImpl(thePnt3);
+  Handle(::GEOM_Object) aPnt1 = GetObjectImpl(thePnt1);
+  Handle(::GEOM_Object) aPnt2 = GetObjectImpl(thePnt2);
+  Handle(::GEOM_Object) aPnt3 = GetObjectImpl(thePnt3);
 
   if (aPnt1.IsNull() || aPnt2.IsNull() || aPnt3.IsNull()) return aGEOMObject._retn();
 
   // Make Disk
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
       GetOperations()->MakeDiskThreePnt(aPnt1, aPnt2, aPnt3);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -233,7 +233,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeDiskR (CORBA::Double theR,
     return aGEOMObject._retn();
 
   //Create the Face
-  Handle(GEOM_Object) anObject = GetOperations()->MakeDiskR(theR, theOrientation);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeDiskR(theR, theOrientation);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -254,7 +254,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeCylinderRH (CORBA::Double th
   GetOperations()->SetNotDone();
 
   //Create the Cylinder
-  Handle(GEOM_Object) anObject = GetOperations()->MakeCylinderRH(theR, theH);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeCylinderRH(theR, theH);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -276,7 +276,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeCylinderRHA (CORBA::Double t
   GetOperations()->SetNotDone();
 
   //Create the Cylinder
-  Handle(GEOM_Object) anObject = GetOperations()->MakeCylinderRHA(theR, theH, theA);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeCylinderRHA(theR, theH, theA);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -298,13 +298,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeCylinderPntVecRH
   GetOperations()->SetNotDone();
 
   //Get the reference points
-  Handle(GEOM_Object) aPnt = GetObjectImpl(thePnt);
-  Handle(GEOM_Object) aVec = GetObjectImpl(theVec);
+  Handle(::GEOM_Object) aPnt = GetObjectImpl(thePnt);
+  Handle(::GEOM_Object) aVec = GetObjectImpl(theVec);
 
   if (aPnt.IsNull() || aVec.IsNull()) return aGEOMObject._retn();
 
   //Create the Cylinder
-  Handle(GEOM_Object) anObject = GetOperations()->MakeCylinderPntVecRH(aPnt, aVec, theR, theH);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeCylinderPntVecRH(aPnt, aVec, theR, theH);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -326,13 +326,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeCylinderPntVecRHA
   GetOperations()->SetNotDone();
 
   //Get the reference points
-  Handle(GEOM_Object) aPnt = GetObjectImpl(thePnt);
-  Handle(GEOM_Object) aVec = GetObjectImpl(theVec);
+  Handle(::GEOM_Object) aPnt = GetObjectImpl(thePnt);
+  Handle(::GEOM_Object) aVec = GetObjectImpl(theVec);
 
   if (aPnt.IsNull() || aVec.IsNull()) return aGEOMObject._retn();
 
   //Create the Cylinder
-  Handle(GEOM_Object) anObject = GetOperations()->MakeCylinderPntVecRHA(aPnt, aVec, theR, theH, theA);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeCylinderPntVecRHA(aPnt, aVec, theR, theH, theA);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -354,7 +354,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeConeR1R2H (CORBA::Double the
   GetOperations()->SetNotDone();
 
   //Create the Cone
-  Handle(GEOM_Object) anObject = GetOperations()->MakeConeR1R2H(theR1, theR2, theH);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeConeR1R2H(theR1, theR2, theH);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -376,13 +376,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeConePntVecR1R2H
   GetOperations()->SetNotDone();
 
   //Get the reference points
-  Handle(GEOM_Object) aPnt = GetObjectImpl(thePnt);
-  Handle(GEOM_Object) aVec = GetObjectImpl(theVec);
+  Handle(::GEOM_Object) aPnt = GetObjectImpl(thePnt);
+  Handle(::GEOM_Object) aVec = GetObjectImpl(theVec);
 
   if (aPnt.IsNull() || aVec.IsNull()) return aGEOMObject._retn();
 
   //Create the Cone
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
       GetOperations()->MakeConePntVecR1R2H(aPnt, aVec, theR1, theR2, theH);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -403,7 +403,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeSphereR (CORBA::Double theR)
   GetOperations()->SetNotDone();
 
   //Create the Cone
-  Handle(GEOM_Object) anObject = GetOperations()->MakeSphereR(theR);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeSphereR(theR);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -424,12 +424,12 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeSpherePntR
   GetOperations()->SetNotDone();
 
   //Get the reference point
-  Handle(GEOM_Object) aPnt = GetObjectImpl(thePnt);
+  Handle(::GEOM_Object) aPnt = GetObjectImpl(thePnt);
 
   if (aPnt.IsNull()) return aGEOMObject._retn();
 
   //Create the Sphere
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakeSpherePntR(aPnt, theR);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -451,7 +451,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeTorusRR
   GetOperations()->SetNotDone();
 
   // Make Torus
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakeTorusRR(theRMajor, theRMinor);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -474,13 +474,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeTorusPntVecRR
   GetOperations()->SetNotDone();
 
   //Get the reference points
-  Handle(GEOM_Object) aPnt = GetObjectImpl(thePnt);
-  Handle(GEOM_Object) aVec = GetObjectImpl(theVec);
+  Handle(::GEOM_Object) aPnt = GetObjectImpl(thePnt);
+  Handle(::GEOM_Object) aVec = GetObjectImpl(theVec);
 
   if (aPnt.IsNull() || aVec.IsNull()) return aGEOMObject._retn();
 
   // Make Torus
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakeTorusPntVecRR(aPnt, aVec, theRMajor, theRMinor);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -503,13 +503,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePrismVecH
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) aVec = GetObjectImpl(theVec);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aVec = GetObjectImpl(theVec);
 
   if (aBase.IsNull() || aVec.IsNull()) return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakePrismVecH(aBase, aVec, theH);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -532,13 +532,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePrismVecH2Ways
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) aVec = GetObjectImpl(theVec);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aVec = GetObjectImpl(theVec);
 
   if (aBase.IsNull() || aVec.IsNull()) return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
       GetOperations()->MakePrismVecH2Ways(aBase, aVec, theH);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -561,13 +561,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePrismVecHWithScaling
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) aVec = GetObjectImpl(theVec);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aVec = GetObjectImpl(theVec);
 
   if (aBase.IsNull() || aVec.IsNull()) return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakePrismVecH(aBase, aVec, theH, theScaleFactor);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -591,15 +591,15 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePrismTwoPnt
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) aPoint1 = GetObjectImpl(thePoint1);
-  Handle(GEOM_Object) aPoint2 = GetObjectImpl(thePoint2);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aPoint1 = GetObjectImpl(thePoint1);
+  Handle(::GEOM_Object) aPoint2 = GetObjectImpl(thePoint2);
 
   if (aBase.IsNull() || aPoint1.IsNull() || aPoint2.IsNull())
     return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakePrismTwoPnt(aBase, aPoint1, aPoint2);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -623,15 +623,15 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePrismTwoPnt2Ways
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) aPoint1 = GetObjectImpl(thePoint1);
-  Handle(GEOM_Object) aPoint2 = GetObjectImpl(thePoint2);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aPoint1 = GetObjectImpl(thePoint1);
+  Handle(::GEOM_Object) aPoint2 = GetObjectImpl(thePoint2);
 
   if (aBase.IsNull() || aPoint1.IsNull() || aPoint2.IsNull())
     return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakePrismTwoPnt2Ways(aBase, aPoint1, aPoint2);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -656,15 +656,15 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePrismTwoPntWithScaling
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) aPoint1 = GetObjectImpl(thePoint1);
-  Handle(GEOM_Object) aPoint2 = GetObjectImpl(thePoint2);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aPoint1 = GetObjectImpl(thePoint1);
+  Handle(::GEOM_Object) aPoint2 = GetObjectImpl(thePoint2);
 
   if (aBase.IsNull() || aPoint1.IsNull() || aPoint2.IsNull())
     return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakePrismTwoPnt(aBase, aPoint1, aPoint2, theScaleFactor);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -687,12 +687,12 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePrismDXDYDZ
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
 
   if (aBase.IsNull()) return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
       GetOperations()->MakePrismDXDYDZ(aBase, theDX, theDY, theDZ);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -715,12 +715,12 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePrismDXDYDZ2Ways
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
 
   if (aBase.IsNull()) return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
       GetOperations()->MakePrismDXDYDZ2Ways(aBase, theDX, theDY, theDZ);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -744,12 +744,12 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePrismDXDYDZWithScaling
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
 
   if (aBase.IsNull()) return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakePrismDXDYDZ(aBase, theDX, theDY, theDZ, theScaleFactor);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -766,7 +766,8 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeDraftPrism
                       (GEOM::GEOM_Object_ptr theInitShape, GEOM::GEOM_Object_ptr theBase, 
                        CORBA::Double  theHeight,
                        CORBA::Double  theAngle,
-                       CORBA::Boolean theFuse)
+                       CORBA::Boolean theFuse,
+                       CORBA::Boolean theInvert)
 {
   GEOM::GEOM_Object_var aGEOMObject;
   
@@ -774,13 +775,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeDraftPrism
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aInit   = GetObjectImpl(theInitShape);
-  Handle(GEOM_Object) aBase   = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aInit   = GetObjectImpl(theInitShape);
+  Handle(::GEOM_Object) aBase   = GetObjectImpl(theBase);
 
   if (aBase.IsNull() || aInit.IsNull()) return aGEOMObject._retn();
 
   //Create the Prism
-  Handle(GEOM_Object) anObject = GetOperations()->MakeDraftPrism(aInit, aBase, theHeight, theAngle, theFuse);
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeDraftPrism(aInit, aBase, theHeight, theAngle, theFuse, theInvert);
  
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -793,27 +794,34 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeDraftPrism
  *  MakePipe
  */
 //=============================================================================
-GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipe
-                 (GEOM::GEOM_Object_ptr theBase, GEOM::GEOM_Object_ptr thePath)
+GEOM::ListOfGO *GEOM_I3DPrimOperations_i::MakePipe
+                           (GEOM::GEOM_Object_ptr theBase,
+                            GEOM::GEOM_Object_ptr thePath,
+                            CORBA::Boolean        IsGenerateGroups)
 {
-  GEOM::GEOM_Object_var aGEOMObject;
+  GEOM::ListOfGO_var aSeq = new GEOM::ListOfGO;
 
   //Set a not done flag
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) aPath = GetObjectImpl(thePath);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aPath = GetObjectImpl(thePath);
 
-  if (aBase.IsNull() || aPath.IsNull()) return aGEOMObject._retn();
+  if (aBase.IsNull() || aPath.IsNull()) return aSeq._retn();
 
   //Create the Pipe
-  Handle(GEOM_Object) anObject =
-    GetOperations()->MakePipe(aBase, aPath);
-  if (!GetOperations()->IsDone() || anObject.IsNull())
-    return aGEOMObject._retn();
+  Handle(TColStd_HSequenceOfTransient) aHSeq =
+    GetOperations()->MakePipe(aBase, aPath, IsGenerateGroups);
+  if (!GetOperations()->IsDone() || aHSeq.IsNull())
+    return aSeq._retn();
 
-  return GetObject(anObject);
+  Standard_Integer aLength = aHSeq->Length();
+  aSeq->length(aLength);
+  for (Standard_Integer i = 1; i <= aLength; i++)
+    aSeq[i-1] = GetObject(Handle(::GEOM_Object)::DownCast(aHSeq->Value(i)));
+
+  return aSeq._retn();
 }
 
 //=============================================================================
@@ -831,13 +839,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeRevolutionAxisAngle
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) anAxis = GetObjectImpl(theAxis);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) anAxis = GetObjectImpl(theAxis);
 
   if (aBase.IsNull() || anAxis.IsNull()) return aGEOMObject._retn();
 
   //Create the Revolution
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
       GetOperations()->MakeRevolutionAxisAngle(aBase, anAxis, theAngle);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -860,13 +868,13 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeRevolutionAxisAngle2Ways
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) anAxis = GetObjectImpl(theAxis);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) anAxis = GetObjectImpl(theAxis);
 
   if (aBase.IsNull() || anAxis.IsNull()) return aGEOMObject._retn();
 
   //Create the Revolution
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
       GetOperations()->MakeRevolutionAxisAngle2Ways(aBase, anAxis, theAngle);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -895,7 +903,7 @@ GEOM_I3DPrimOperations_i::MakeFilling(const GEOM::ListOfGO&     theContours,
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  std::list< Handle(GEOM_Object) > aShapes;
+  std::list< Handle(::GEOM_Object) > aShapes;
   if (! GetListOfObjectsImpl( theContours, aShapes ))
     return aGEOMObject._retn();
 
@@ -924,7 +932,7 @@ GEOM_I3DPrimOperations_i::MakeFilling(const GEOM::ListOfGO&     theContours,
   }
 
   //Create the Solid
-  Handle(GEOM_Object) anObject = GetOperations()->MakeFilling
+  Handle(::GEOM_Object) anObject = GetOperations()->MakeFilling
     (aShapes, theMinDeg, theMaxDeg, theTol2D, theTol3D, theNbIter, aMethod, theApprox);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -952,7 +960,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeThruSections(const GEOM::Lis
   //Get the shapes
   aLen = theSeqSections.length();
   for (ind = 0; ind < aLen; ind++) {
-    Handle(GEOM_Object) aSh = GetObjectImpl(theSeqSections[ind]);
+    Handle(::GEOM_Object) aSh = GetObjectImpl(theSeqSections[ind]);
     if (!aSh.IsNull())
       aSeqSections->Append(aSh);
   }
@@ -960,7 +968,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeThruSections(const GEOM::Lis
     return aGEOMObject._retn();
 
   // Make shell or solid
-  Handle(GEOM_Object) anObject =
+  Handle(::GEOM_Object) anObject =
     GetOperations()->MakeThruSections(aSeqSections,theModeSolid,thePreci,theRuled);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
@@ -973,14 +981,16 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeThruSections(const GEOM::Lis
  *  MakePipeWithDifferentSections
  */
 //=============================================================================
-GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeWithDifferentSections
-                      (const GEOM::ListOfGO& theBases,
-                       const GEOM::ListOfGO& theLocations,
-                       GEOM::GEOM_Object_ptr thePath,
-                       CORBA::Boolean theWithContact,
-                       CORBA::Boolean theWithCorrections)
+GEOM::ListOfGO *GEOM_I3DPrimOperations_i::MakePipeWithDifferentSections
+                           (const GEOM::ListOfGO        &theBases,
+                            const GEOM::ListOfGO        &theLocations,
+                                  GEOM::GEOM_Object_ptr  thePath,
+                                  CORBA::Boolean         theWithContact,
+                                  CORBA::Boolean         theWithCorrections,
+                                  CORBA::Boolean         IsBySteps,
+                                  CORBA::Boolean         IsGenerateGroups)
 {
-  GEOM::GEOM_Object_var aGEOMObject;
+  GEOM::ListOfGO_var aSeq = new GEOM::ListOfGO;
 
   //Set a not done flag
   GetOperations()->SetNotDone();
@@ -993,19 +1003,19 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeWithDifferentSections
   aNbLocs = theLocations.length();
 
   if (aNbLocs && aNbBases != aNbLocs)
-    return aGEOMObject._retn();
+    return aSeq._retn();
 
-  Handle(GEOM_Object) aPath = GetObjectImpl(thePath);
+  Handle(::GEOM_Object) aPath = GetObjectImpl(thePath);
   if (aPath.IsNull())
-    return aGEOMObject._retn();
+    return aSeq._retn();
 
   for (ind = 0; ind < aNbBases; ind++) {
-    Handle(GEOM_Object) aBase = GetObjectImpl(theBases[ind]);
+    Handle(::GEOM_Object) aBase = GetObjectImpl(theBases[ind]);
     if (aBase.IsNull())
       continue;
     if (aNbLocs)
     {
-      Handle(GEOM_Object) aLoc = GetObjectImpl(theLocations[ind]);
+      Handle(::GEOM_Object) aLoc = GetObjectImpl(theLocations[ind]);
       if (aLoc.IsNull())
         continue;
       aSeqLocations->Append(aLoc);
@@ -1013,16 +1023,23 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeWithDifferentSections
     aSeqBases->Append(aBase);
   }
   if (!aSeqBases->Length())
-    return aGEOMObject._retn();
+    return aSeq._retn();
 
   // Make pipe
-  Handle(GEOM_Object) anObject =
-    GetOperations()->MakePipeWithDifferentSections(aSeqBases,aSeqLocations ,aPath,
-                                                   theWithContact,theWithCorrections);
-  if (!GetOperations()->IsDone() || anObject.IsNull())
-    return aGEOMObject._retn();
-
-  return GetObject(anObject);
+  Handle(TColStd_HSequenceOfTransient) aHSeq =
+    GetOperations()->MakePipeWithDifferentSections
+              (aSeqBases, aSeqLocations,
+               aPath, theWithContact,
+               theWithCorrections, IsBySteps, IsGenerateGroups);
+  if (!GetOperations()->IsDone() || aHSeq.IsNull())
+    return aSeq._retn();
+
+  Standard_Integer aLength = aHSeq->Length();
+  aSeq->length(aLength);
+  for (Standard_Integer i = 1; i <= aLength; i++)
+    aSeq[i-1] = GetObject(Handle(::GEOM_Object)::DownCast(aHSeq->Value(i)));
+
+  return aSeq._retn();
 }
 
 
@@ -1031,15 +1048,16 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeWithDifferentSections
  *  MakePipeWithShellSections
  */
 //=============================================================================
-GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeWithShellSections
-                 (const GEOM::ListOfGO& theBases,
-                  const GEOM::ListOfGO& theSubBases,
-                  const GEOM::ListOfGO& theLocations,
-                  GEOM::GEOM_Object_ptr thePath,
-                  CORBA::Boolean theWithContact,
-                  CORBA::Boolean theWithCorrections)
+GEOM::ListOfGO *GEOM_I3DPrimOperations_i::MakePipeWithShellSections
+                           (const GEOM::ListOfGO        &theBases,
+                            const GEOM::ListOfGO        &theSubBases,
+                            const GEOM::ListOfGO        &theLocations,
+                                  GEOM::GEOM_Object_ptr  thePath,
+                                  CORBA::Boolean         theWithContact,
+                                  CORBA::Boolean         theWithCorrections,
+                                  CORBA::Boolean         IsGenerateGroups)
 {
-  GEOM::GEOM_Object_var aGEOMObject;
+  GEOM::ListOfGO_var aSeq = new GEOM::ListOfGO;
 
   //Set a not done flag
   GetOperations()->SetNotDone();
@@ -1054,18 +1072,18 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeWithShellSections
   aNbLocs = theLocations.length();
 
   if (aNbLocs && aNbBases != aNbLocs)
-    return aGEOMObject._retn();
+    return aSeq._retn();
 
-  Handle(GEOM_Object) aPath = GetObjectImpl(thePath);
+  Handle(::GEOM_Object) aPath = GetObjectImpl(thePath);
   if (aPath.IsNull())
-    return aGEOMObject._retn();
+    return aSeq._retn();
 
   for (ind = 0; ind < aNbBases; ind++) {
-    Handle(GEOM_Object) aBase = GetObjectImpl(theBases[ind]);
+    Handle(::GEOM_Object) aBase = GetObjectImpl(theBases[ind]);
     if (aBase.IsNull())
       continue;
     if (aNbLocs) {
-      Handle(GEOM_Object) aLoc = GetObjectImpl(theLocations[ind]);
+      Handle(::GEOM_Object) aLoc = GetObjectImpl(theLocations[ind]);
       if (aLoc.IsNull())
         continue;
       aSeqLocations->Append(aLoc);
@@ -1073,7 +1091,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeWithShellSections
     aSeqBases->Append(aBase);
 
     if (aNbSubBases >= aNbBases) {
-      Handle(GEOM_Object) aSubBase = GetObjectImpl(theSubBases[ind]);
+      Handle(::GEOM_Object) aSubBase = GetObjectImpl(theSubBases[ind]);
       if (aSubBase.IsNull()) {
         aSeqSubBases->Clear();
         aNbSubBases = 0;
@@ -1083,17 +1101,23 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeWithShellSections
     }
   }
   if (!aSeqBases->Length())
-    return aGEOMObject._retn();
+    return aSeq._retn();
 
   // Make pipe
-  Handle(GEOM_Object) anObject =
-    GetOperations()->MakePipeWithShellSections(aSeqBases, aSeqSubBases,
-                                               aSeqLocations, aPath,
-                                               theWithContact, theWithCorrections);
-  if (!GetOperations()->IsDone() || anObject.IsNull())
-    return aGEOMObject._retn();
-
-  return GetObject(anObject);
+  Handle(TColStd_HSequenceOfTransient) aHSeq =
+    GetOperations()->MakePipeWithShellSections
+                  (aSeqBases, aSeqSubBases,
+                   aSeqLocations, aPath,
+                   theWithContact, theWithCorrections, IsGenerateGroups);
+  if (!GetOperations()->IsDone() || aHSeq.IsNull())
+    return aSeq._retn();
+
+  Standard_Integer aLength = aHSeq->Length();
+  aSeq->length(aLength);
+  for (Standard_Integer i = 1; i <= aLength; i++)
+    aSeq[i-1] = GetObject(Handle(::GEOM_Object)::DownCast(aHSeq->Value(i)));
+
+  return aSeq._retn();
 }
 
 
@@ -1102,11 +1126,12 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeWithShellSections
  *  MakePipeShellsWithoutPath
  */
 //=============================================================================
-GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeShellsWithoutPath
-                 (const GEOM::ListOfGO& theBases,
-                  const GEOM::ListOfGO& theLocations)
+GEOM::ListOfGO *GEOM_I3DPrimOperations_i::MakePipeShellsWithoutPath
+                           (const GEOM::ListOfGO &theBases,
+                            const GEOM::ListOfGO &theLocations,
+                                  CORBA::Boolean  IsGenerateGroups)
 {
-  GEOM::GEOM_Object_var aGEOMObject;
+  GEOM::ListOfGO_var aSeq = new GEOM::ListOfGO;
 
   //Set a not done flag
   GetOperations()->SetNotDone();
@@ -1119,14 +1144,14 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeShellsWithoutPath
   aNbLocs = theLocations.length();
 
   if (aNbLocs && aNbBases != aNbLocs)
-    return aGEOMObject._retn();
+    return aSeq._retn();
 
   for (ind = 0; ind < aNbBases; ind++) {
-    Handle(GEOM_Object) aBase = GetObjectImpl(theBases[ind]);
+    Handle(::GEOM_Object) aBase = GetObjectImpl(theBases[ind]);
     if (aBase.IsNull())
       continue;
     if (aNbLocs) {
-      Handle(GEOM_Object) aLoc = GetObjectImpl(theLocations[ind]);
+      Handle(::GEOM_Object) aLoc = GetObjectImpl(theLocations[ind]);
       if (aLoc.IsNull())
         continue;
       aSeqLocations->Append(aLoc);
@@ -1135,16 +1160,22 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeShellsWithoutPath
   }
 
   if (!aSeqBases->Length())
-    return aGEOMObject._retn();
+    return aSeq._retn();
 
   // Make pipe
-  Handle(GEOM_Object) anObject =
-    GetOperations()->MakePipeShellsWithoutPath(aSeqBases,aSeqLocations);
+  Handle(TColStd_HSequenceOfTransient) aHSeq =
+    GetOperations()->MakePipeShellsWithoutPath
+          (aSeqBases, aSeqLocations, IsGenerateGroups);
 
-  if (!GetOperations()->IsDone() || anObject.IsNull())
-    return aGEOMObject._retn();
+  if (!GetOperations()->IsDone() || aHSeq.IsNull())
+    return aSeq._retn();
 
-  return GetObject(anObject);
+  Standard_Integer aLength = aHSeq->Length();
+  aSeq->length(aLength);
+  for (Standard_Integer i = 1; i <= aLength; i++)
+    aSeq[i-1] = GetObject(Handle(::GEOM_Object)::DownCast(aHSeq->Value(i)));
+
+  return aSeq._retn();
 }
 
 //=============================================================================
@@ -1152,30 +1183,37 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeShellsWithoutPath
  *  MakePipeBiNormalAlongVector
  */
 //=============================================================================
-GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeBiNormalAlongVector
-                 (GEOM::GEOM_Object_ptr theBase,
-                  GEOM::GEOM_Object_ptr thePath,
-                  GEOM::GEOM_Object_ptr theVec)
+GEOM::ListOfGO *GEOM_I3DPrimOperations_i::MakePipeBiNormalAlongVector
+                           (GEOM::GEOM_Object_ptr theBase,
+                            GEOM::GEOM_Object_ptr thePath,
+                            GEOM::GEOM_Object_ptr theVec,
+                            CORBA::Boolean        IsGenerateGroups)
 {
-  GEOM::GEOM_Object_var aGEOMObject;
+  GEOM::ListOfGO_var aSeq = new GEOM::ListOfGO;
 
   //Set a not done flag
   GetOperations()->SetNotDone();
 
   //Get the reference objects
-  Handle(GEOM_Object) aBase = GetObjectImpl(theBase);
-  Handle(GEOM_Object) aPath = GetObjectImpl(thePath);
-  Handle(GEOM_Object) aVec = GetObjectImpl(theVec);
+  Handle(::GEOM_Object) aBase = GetObjectImpl(theBase);
+  Handle(::GEOM_Object) aPath = GetObjectImpl(thePath);
+  Handle(::GEOM_Object) aVec = GetObjectImpl(theVec);
 
-  if (aBase.IsNull() || aPath.IsNull() || aVec.IsNull()) return aGEOMObject._retn();
+  if (aBase.IsNull() || aPath.IsNull() || aVec.IsNull()) return aSeq._retn();
 
   //Create the Pipe
-  Handle(GEOM_Object) anObject =
-    GetOperations()->MakePipeBiNormalAlongVector(aBase, aPath, aVec);
-  if (!GetOperations()->IsDone() || anObject.IsNull())
-    return aGEOMObject._retn();
-
-  return GetObject(anObject);
+  Handle(TColStd_HSequenceOfTransient) aHSeq =
+    GetOperations()->MakePipeBiNormalAlongVector
+          (aBase, aPath, aVec, IsGenerateGroups);
+  if (!GetOperations()->IsDone() || aHSeq.IsNull())
+    return aSeq._retn();
+
+  Standard_Integer aLength = aHSeq->Length();
+  aSeq->length(aLength);
+  for (Standard_Integer i = 1; i <= aLength; i++)
+    aSeq[i-1] = GetObject(Handle(::GEOM_Object)::DownCast(aHSeq->Value(i)));
+
+  return aSeq._retn();
 }
 
 //=============================================================================
@@ -1184,9 +1222,11 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakePipeBiNormalAlongVector
  */
 //=============================================================================
 GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeThickening
-                 (GEOM::GEOM_Object_ptr theObject,
-                  CORBA::Double theOffset,
-                  CORBA::Boolean doCopy)
+                 (GEOM::GEOM_Object_ptr   theObject,
+                  const GEOM::ListOfLong &theFacesIDs,
+                  CORBA::Double           theOffset,
+                  CORBA::Boolean          doCopy,
+                  CORBA::Boolean          theInside)
 {
   GEOM::GEOM_Object_var aGEOMObject;
   //Set a not done flag
@@ -1204,14 +1244,27 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeThickening
     aGEOMObject = GEOM::GEOM_Object::_duplicate(theObject);
 
   //Get the basic object
-  Handle(GEOM_Object) aBasicObject = GetObjectImpl(theObject);
+  Handle(::GEOM_Object) aBasicObject = GetObjectImpl(theObject);
   if (aBasicObject.IsNull()) return aGEOMObject._retn();
-  
+
+  // Get faces IDs.
+  Handle(TColStd_HArray1OfInteger) aFaceIDs;
+  Standard_Integer                 aNbIDs = theFacesIDs.length();
+  Standard_Integer                 i;
+
+  if (aNbIDs > 0) {
+    aFaceIDs = new TColStd_HArray1OfInteger (1, aNbIDs);
+
+    for (i = 0; i < aNbIDs; i++) {
+      aFaceIDs->SetValue(i + 1, theFacesIDs[i]);
+    }
+  }
+
   //Create the thickened shape
   if (doCopy)
   {
-    Handle(GEOM_Object) anObject = GetOperations()->MakeThickening(
-      aBasicObject, theOffset, doCopy);
+    Handle(::GEOM_Object) anObject = GetOperations()->MakeThickening(
+      aBasicObject, aFaceIDs, theOffset, doCopy, theInside);
     if (!GetOperations()->IsDone() || anObject.IsNull())
       return aGEOMObject._retn();
     
@@ -1219,7 +1272,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::MakeThickening
   }
   else
   {
-    GetOperations()->MakeThickening(aBasicObject, theOffset, doCopy);
+    GetOperations()->MakeThickening(aBasicObject, aFaceIDs, theOffset, doCopy, theInside);
     
     // Update GUI.
     UpdateGUIForObject(theObject);
@@ -1244,14 +1297,14 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::RestorePath
   GetOperations()->SetNotDone();
 
   // Get the reference objects
-  Handle(GEOM_Object) aShape = GetObjectImpl(theShape);
-  Handle(GEOM_Object) aBase1 = GetObjectImpl(theBase1);
-  Handle(GEOM_Object) aBase2 = GetObjectImpl(theBase2);
+  Handle(::GEOM_Object) aShape = GetObjectImpl(theShape);
+  Handle(::GEOM_Object) aBase1 = GetObjectImpl(theBase1);
+  Handle(::GEOM_Object) aBase2 = GetObjectImpl(theBase2);
 
   if (aShape.IsNull() || aBase1.IsNull() || aBase2.IsNull()) return aGEOMObject._retn();
 
   // Create the Path
-  Handle(GEOM_Object) anObject = GetOperations()->RestorePath(aShape, aBase1, aBase2);
+  Handle(::GEOM_Object) anObject = GetOperations()->RestorePath(aShape, aBase1, aBase2);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();
 
@@ -1274,7 +1327,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::RestorePathEdges
   GetOperations()->SetNotDone();
 
   // Get the reference objects
-  Handle(GEOM_Object) aShape = GetObjectImpl(theShape);
+  Handle(::GEOM_Object) aShape = GetObjectImpl(theShape);
   if (aShape.IsNull()) return aGEOMObject._retn();
 
   Handle(TColStd_HSequenceOfTransient) aSeqBases1 = new TColStd_HSequenceOfTransient;
@@ -1285,12 +1338,12 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::RestorePathEdges
   int aNbBases2 = theBase2.length();
 
   for (ind = 0; ind < aNbBases1; ind++) {
-    Handle(GEOM_Object) aBase = GetObjectImpl(theBase1[ind]);
+    Handle(::GEOM_Object) aBase = GetObjectImpl(theBase1[ind]);
     if (!aBase.IsNull())
       aSeqBases1->Append(aBase);
   }
   for (ind = 0; ind < aNbBases2; ind++) {
-    Handle(GEOM_Object) aBase = GetObjectImpl(theBase2[ind]);
+    Handle(::GEOM_Object) aBase = GetObjectImpl(theBase2[ind]);
     if (!aBase.IsNull())
       aSeqBases2->Append(aBase);
   }
@@ -1299,7 +1352,7 @@ GEOM::GEOM_Object_ptr GEOM_I3DPrimOperations_i::RestorePathEdges
     return aGEOMObject._retn();
 
   // Create the Path
-  Handle(GEOM_Object) anObject = GetOperations()->RestorePath(aShape, aSeqBases1, aSeqBases2);
+  Handle(::GEOM_Object) anObject = GetOperations()->RestorePath(aShape, aSeqBases1, aSeqBases2);
   if (!GetOperations()->IsDone() || anObject.IsNull())
     return aGEOMObject._retn();