Salome HOME
CCAR: problem with an endless loop in getAIS
[modules/geom.git] / idl / GEOM_Gen.idl
index 304b16a861880d0a674f075b0d20cb0c1464ade6..18efa2a0cda928bfd6b79356b9b826e09a79f58d 100644 (file)
 //
 //  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 //
-
 //  File   : GEOM_Gen.idl
 //  Author : Sergey RUIN
-//
+
 #ifndef __GEOM_GEN__
 #define __GEOM_GEN__
 
@@ -45,13 +44,13 @@ module GEOM
    * Marker type
    */
   enum marker_type { MT_NONE, MT_POINT, MT_PLUS, MT_STAR, MT_O, MT_X, MT_O_POINT, MT_O_PLUS,
-                    MT_O_STAR, MT_O_X, MT_BALL, MT_RING1, MT_RING2, MT_RING3, MT_USER };
+                     MT_O_STAR, MT_O_X, MT_BALL, MT_RING1, MT_RING2, MT_RING3, MT_USER };
 
   /*!
    * Marker size
    */
   enum marker_size { MS_NONE, MS_10, MS_15, MS_20, MS_25, MS_30, MS_35,
-                    MS_40, MS_45, MS_50, MS_55, MS_60, MS_65, MS_70 };
+                     MS_40, MS_45, MS_50, MS_55, MS_60, MS_65, MS_70 };
 
   /*!
    *  State of shape relatively geometrical surface like plane, sphere or cylinder.
@@ -112,7 +111,12 @@ module GEOM
     FSM_GetShapesOnShape,
 
     /*! Use GetInPlaceByHistory method (can work only after Partition) */
-    FSM_GetInPlaceByHistory
+    FSM_GetInPlaceByHistory,
+
+    /*! To be used only for multi-transformation result.
+     *  Only this method can be used after multi-transformation.
+     */
+    FSM_MultiTransformed
   };
 
   /*!
@@ -167,6 +171,33 @@ module GEOM
      */
     shape_type GetShapeType();
 
+    /*!
+     *  Get the topology type of the object value.
+     *  In contrast to the shape type, this function returns type of the most
+     *  top-level sub-shape of the COMPOUND or COMPSOLID, if there is only one
+     *  sub-shape there.
+     *  \sa GetShapeType()
+     */
+    shape_type GetTopologyType();
+
+    /*!
+     *  Get a minimal type of the top-level shapes contained in the object.
+     *  This function is useful for the compounds only; for simple shapes it
+     *  exactly the same value as GetShapeType().
+     *  Note, that compounds are procesed recursively.
+     *  \sa GetShapeType(), GetTopologyType(), GetMaxShapeType()
+     */
+    shape_type GetMinShapeType();
+
+    /*!
+     *  Get a maximal type of the top-level shapes contained in the object.
+     *  This function is useful for the compounds only; for simple shapes it
+     *  exactly the same value as GetShapeType().
+     *  Note, that compounds are procesed recursively.
+     *  \sa GetShapeType(), GetTopologyType(), GetMinShapeType()
+     */
+    shape_type GetMaxShapeType();
+    
     /*!
      *  Set name of the object.
      *  \param theName is a name which will be associated with this object.
@@ -376,7 +407,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created point.
      */
     GEOM_Object MakePointWithReference (in GEOM_Object theReference,
-                                       in double theX, in double theY, in double theZ);
+                                        in double theX, in double theY, in double theZ);
 
     /*!
      *  Create a point, corresponding to the given parameter on the given curve.
@@ -385,7 +416,17 @@ module GEOM
      *  \return New GEOM_Object, containing the created point.
      */
     GEOM_Object MakePointOnCurve (in GEOM_Object theRefCurve,
-                                 in double theParameter);
+                                  in double theParameter);
+
+    /*!
+     *  Create a point, corresponding to the given length on the given curve.
+     *  \param theRefCurve The referenced curve.
+     *  \param theLength Length on the referenced curve.
+     *  \return New GEOM_Object, containing the created point.
+     */
+    GEOM_Object MakePointOnCurveByLength (in GEOM_Object theRefCurve,
+                                          in double theLength);
+
 
     /*!
      *  Create a point on the given curve, projecting given point
@@ -409,8 +450,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created point.
      */
     GEOM_Object MakePointOnSurface (in GEOM_Object theRefSurf,
-                                   in double theUParameter,
-                                   in double theVParameter);
+                                    in double theUParameter,
+                                    in double theVParameter);
 
     /*!
      *  Create a point on the given surface, projecting given point
@@ -432,7 +473,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created point.
      */
     GEOM_Object MakePointOnLinesIntersection (in GEOM_Object theRefLine1,
-                                             in GEOM_Object theRefLine2);
+                                              in GEOM_Object theRefLine2);
 
      /*!
      *  Create a vector, corresponding to tangent to the given parameter on the given curve.
@@ -443,7 +484,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created point.
      */
      GEOM_Object MakeTangentOnCurve (in GEOM_Object theRefCurve,
-                                    in double theParameter);
+                                     in double theParameter);
 
     /*!
      *  Create a vector with the given components.
@@ -453,8 +494,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created vector.
      */
     GEOM_Object MakeVectorDXDYDZ (in double theDX,
-                                 in double theDY,
-                                 in double theDZ);
+                                  in double theDY,
+                                  in double theDZ);
 
     /*!
      *  Create a vector between two points.
@@ -498,9 +539,9 @@ module GEOM
      *  \return New GEOM_Object, containing the created plane.
      */
     GEOM_Object MakePlaneThreePnt (in GEOM_Object thePnt1,
-                                  in GEOM_Object thePnt2,
-                                  in GEOM_Object thePnt3,
-                                  in double theTrimSize);
+                                   in GEOM_Object thePnt2,
+                                   in GEOM_Object thePnt3,
+                                   in double theTrimSize);
 
     /*!
      *  Create a plane, passing through the given point
@@ -511,8 +552,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created plane.
      */
     GEOM_Object MakePlanePntVec (in GEOM_Object thePnt,
-                                in GEOM_Object theVec,
-                                in double theTrimSize);
+                                 in GEOM_Object theVec,
+                                 in double theTrimSize);
 
     /*!
      *  Create a plane, similar to the existing one, but with another size of representing face.
@@ -521,7 +562,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created plane.
      */
     GEOM_Object MakePlaneFace (in GEOM_Object theFace,
-                              in double theTrimSize);
+                               in double theTrimSize);
 
     /*!
      *  Create a plane, by two vectors.
@@ -531,8 +572,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created plane.
      */
     GEOM_Object MakePlane2Vec (in GEOM_Object theVec1,
-                              in GEOM_Object theVec2,
-                              in double theTrimSize);
+                               in GEOM_Object theVec2,
+                               in double theTrimSize);
 
     /*!
      *  Create a plane, defined by local coordinate system.
@@ -542,8 +583,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created plane.
      */
     GEOM_Object MakePlaneLCS (in GEOM_Object theLCS,
-                             in double theTrimSize,
-                             in double theOrientation);
+                              in double theTrimSize,
+                              in double theOrientation);
 
     /*!
      *  Create a local coordinate system.
@@ -553,8 +594,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created coordinate system.
      */
     GEOM_Object MakeMarker (in double theOX , in double theOY , in double theOZ,
-                           in double theXDX, in double theXDY, in double theXDZ,
-                           in double theYDX, in double theYDY, in double theYDZ);
+                            in double theXDX, in double theXDY, in double theXDZ,
+                            in double theYDX, in double theYDY, in double theYDZ);
 
     /*!
      *  Create a local coordinate system from shape.
@@ -562,7 +603,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created coordinate system.
      */
     GEOM_Object MakeMarkerFromShape (in GEOM_Object theShape);
-   
+
     /*!
      *  Create a local coordinate system from point and two vectors (DX, DY).
      *  \param theOrigin Point of coordinate system origin.
@@ -571,7 +612,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created coordinate system.
      */
     GEOM_Object MakeMarkerPntTwoVec (in GEOM_Object theOrigin, in GEOM_Object theXVec, in GEOM_Object theYVec);
-       
+
     /*!
      *  Create a tangent plane to specified face in the point with specified parameters.
      *  Values of parameters should be between 0. and 1.0
@@ -582,9 +623,9 @@ module GEOM
      *  \return New GEOM_Object, containing the face built on tangent plane.
      */
     GEOM_Object MakeTangentPlaneOnFace(in GEOM_Object theFace,
-                                      in double theParameterU,
-                                      in double theParameterV,
-                                      in double theTrimSize);
+                                       in double theParameterU,
+                                       in double theParameterV,
+                                       in double theTrimSize);
   };
 
   interface GEOM_ITransformOperations : GEOM_IOperations
@@ -597,8 +638,8 @@ module GEOM
      *  \return theObject.
      */
     GEOM_Object TranslateTwoPoints (in GEOM_Object theObject,
-                                   in GEOM_Object thePoint1,
-                                   in GEOM_Object thePoint2);
+                                    in GEOM_Object thePoint1,
+                                    in GEOM_Object thePoint2);
 
     /*!
      *  Translate the given object along the vector, specified
@@ -609,7 +650,7 @@ module GEOM
      *  \return New GEOM_Object, containing the translated object.
      */
     GEOM_Object TranslateTwoPointsCopy (in GEOM_Object theObject,
-                                       in GEOM_Object thePoint1,
+                                        in GEOM_Object thePoint1,
                                         in GEOM_Object thePoint2);
 
     /*!
@@ -619,7 +660,7 @@ module GEOM
      *  \return theObject.
      */
     GEOM_Object TranslateDXDYDZ (in GEOM_Object theObject,
-                                in double theDX, in double theDY, in double theDZ);
+                                 in double theDX, in double theDY, in double theDZ);
 
     /*!
      *  Translate the given object along the vector, specified
@@ -629,7 +670,7 @@ module GEOM
      *  \return New GEOM_Object, containing the translated object.
      */
     GEOM_Object TranslateDXDYDZCopy (in GEOM_Object theObject,
-                                    in double theDX, in double theDY, in double theDZ);
+                                     in double theDX, in double theDY, in double theDZ);
 
 
     /*!
@@ -639,7 +680,7 @@ module GEOM
      *  \return theObject.
      */
     GEOM_Object TranslateVector (in GEOM_Object theObject,
-                                in GEOM_Object theVector);
+                                 in GEOM_Object theVector);
 
     /*!
      *  Translate the given object along the given vector,
@@ -649,7 +690,7 @@ module GEOM
      *  \return New GEOM_Object, containing the translated object.
      */
     GEOM_Object TranslateVectorCopy (in GEOM_Object theObject,
-                                    in GEOM_Object theVector);
+                                     in GEOM_Object theVector);
 
     /*!
      *  Translate the given object along the given vector on given distance,
@@ -661,9 +702,9 @@ module GEOM
      *  \return New GEOM_Object, containing the translated object.
      */
     GEOM_Object TranslateVectorDistance (in GEOM_Object theObject,
-                                        in GEOM_Object theVector,
-                                        in double      theDistance,
-                                        in boolean     theCopy);
+                                         in GEOM_Object theVector,
+                                         in double      theDistance,
+                                         in boolean     theCopy);
 
     /*!
      *  Translate the given object along the given vector a given number times
@@ -675,9 +716,9 @@ module GEOM
      *          the shapes, obtained after each translation.
      */
     GEOM_Object MultiTranslate1D (in GEOM_Object theObject,
-                                 in GEOM_Object theVector,
-                                 in double theStep,
-                                 in long theNbTimes);
+                                  in GEOM_Object theVector,
+                                  in double theStep,
+                                  in long theNbTimes);
 
     /*!
      *  Conseqently apply two specified translations to theObject specified number of times.
@@ -692,12 +733,12 @@ module GEOM
      *          the shapes, obtained after each translation.
      */
     GEOM_Object MultiTranslate2D (in GEOM_Object theObject,
-                                 in GEOM_Object theVector1,
-                                 in double theStep1,
-                                 in long theNbTimes1,
-                                 in GEOM_Object theVector2,
-                                 in double theStep2,
-                                 in long theNbTimes2);
+                                  in GEOM_Object theVector1,
+                                  in double theStep1,
+                                  in long theNbTimes1,
+                                  in GEOM_Object theVector2,
+                                  in double theStep2,
+                                  in long theNbTimes2);
 
     /*!
      *  Rotate given object around vector perpendicular to plane containing three points.
@@ -708,9 +749,9 @@ module GEOM
      *  \return theObject.
      */
     GEOM_Object RotateThreePoints (in GEOM_Object theObject,
-                                  in GEOM_Object theCentPoint,
-                                  in GEOM_Object thePoint1,
-                                  in GEOM_Object thePoint2);
+                                   in GEOM_Object theCentPoint,
+                                   in GEOM_Object thePoint1,
+                                   in GEOM_Object thePoint2);
 
 
     /*!
@@ -723,9 +764,9 @@ module GEOM
      *  \return New GEOM_Object, containing the rotated object.
      */
     GEOM_Object RotateThreePointsCopy (in GEOM_Object theObject,
-                                      in GEOM_Object theCentPoint,
-                                      in GEOM_Object thePoint1,
-                                      in GEOM_Object thePoint2);
+                                       in GEOM_Object theCentPoint,
+                                       in GEOM_Object thePoint1,
+                                       in GEOM_Object thePoint2);
 
     /*!
      *  Rotate the given object around the given axis on the given angle.
@@ -735,8 +776,8 @@ module GEOM
      *  \return theObject.
      */
     GEOM_Object Rotate (in GEOM_Object theObject,
-                       in GEOM_Object theAxis,
-                       in double theAngle);
+                        in GEOM_Object theAxis,
+                        in double theAngle);
 
 
     /*!
@@ -748,8 +789,8 @@ module GEOM
      *  \return New GEOM_Object, containing the rotated object.
      */
     GEOM_Object RotateCopy (in GEOM_Object theObject,
-                           in GEOM_Object theAxis,
-                           in double theAngle);
+                            in GEOM_Object theAxis,
+                            in double theAngle);
 
 
     /*!
@@ -762,8 +803,8 @@ module GEOM
      *          shapes, obtained after each rotation.
      */
     GEOM_Object MultiRotate1D (in GEOM_Object theObject,
-                              in GEOM_Object theAxis,
-                              in long theNbTimes);
+                               in GEOM_Object theAxis,
+                               in long theNbTimes);
 
     /*!
      *  Rotate the given object around the
@@ -781,11 +822,11 @@ module GEOM
      *          shapes, obtained after each transformation.
      */
     GEOM_Object MultiRotate2D (in GEOM_Object theObject,
-                              in GEOM_Object theAxis,
-                              in double theAngle,
-                              in long theNbTimes1,
-                              in double theStep,
-                              in long theNbTimes2);
+                               in GEOM_Object theAxis,
+                               in double theAngle,
+                               in long theNbTimes1,
+                               in double theStep,
+                               in long theNbTimes2);
 
     /*!
      *  Replace the given object by an object,
@@ -862,7 +903,7 @@ module GEOM
      *  \return theObject.
      */
     GEOM_Object ScaleShape (in GEOM_Object theObject, in GEOM_Object thePoint,
-                           in double theFactor);
+                            in double theFactor);
 
     /*!
      *  Scale the given object by the factor, creating its copy before the scaling.
@@ -872,7 +913,7 @@ module GEOM
      *  \return New GEOM_Object, containing the scaled shape.
      */
     GEOM_Object ScaleShapeCopy (in GEOM_Object theObject, in GEOM_Object thePoint,
-                               in double theFactor);
+                                in double theFactor);
 
     /*!
      *  Scale the given object by different factors along coordinate axes.
@@ -913,8 +954,8 @@ module GEOM
      *  \return theObject.
      */
     GEOM_Object PositionShape (in GEOM_Object theObject,
-                              in GEOM_Object theStartLCS,
-                              in GEOM_Object theEndLCS);
+                               in GEOM_Object theStartLCS,
+                               in GEOM_Object theEndLCS);
 
     /*!
      *  Modify the Location of the given object by LCS,
@@ -929,24 +970,34 @@ module GEOM
      *  \return New GEOM_Object, containing the displaced shape.
      */
     GEOM_Object PositionShapeCopy (in GEOM_Object theObject,
-                                  in GEOM_Object theStartLCS,
-                                  in GEOM_Object theEndLCS);
+                                   in GEOM_Object theStartLCS,
+                                   in GEOM_Object theEndLCS);
 
     /*!
      *  Modify the Location of the given object by Path,
      *  \param  theObject The object to be displaced.
      *  \param  thePath Wire or Edge along that the object will be translated.
-     * \param  theDistance progress of Path (0 = actual location, 1 = end of path location).
-     * \param  theCopy is a true or false parameter. true is to create a copy, false to move the object.
-     * \param  theCopy is a true or false parameter. true is to reverse direction, false is to move normal direction.
+     *        \param  theDistance progress of Path (0 = actual location, 1 = end of path location).
+     *        \param  theCopy is a true or false parameter. true is to create a copy, false to move the object.
+     *        \param  theCopy is a true or false parameter. true is to reverse direction, false is to move normal direction.
      *  \return New GEOM_Object, containing the displaced shape.
      */
-
     GEOM_Object PositionAlongPath (in GEOM_Object theObject,
-                                  in GEOM_Object thePath,
-                                  in double theDistance,
-                                  in boolean theCopy,
-                                  in boolean theReverse);
+                                   in GEOM_Object thePath,
+                                   in double theDistance,
+                                   in boolean theCopy,
+                                   in boolean theReverse);
+
+    /*!
+     *  Transform the shape in the same way what was used for the sample shape creation.
+     *  \param theObject The object to be transformed.
+     *  \param theSample The object containing information about required transformation.
+     *  \note Implementation of this method is limited by multi-transformations now.
+     *  \note Internal method.
+     *  \return New GEOM_Object, containing the transformed shape.
+     */
+    GEOM_Object TransformLikeOtherCopy (in GEOM_Object theObject,
+                                        in GEOM_Object theSample);
 
     /*!
      *  Recompute the shape from its arguments.
@@ -1010,16 +1061,16 @@ module GEOM
      *  \return New GEOM_Object, containing the created disk.
      */
     GEOM_Object MakeDiskPntVecR (in GEOM_Object thePnt,
-                                in GEOM_Object theVec,
-                                in double theR);
+                                 in GEOM_Object theVec,
+                                 in double theR);
     /*!
      *  Create a disk (circular face), passing through three given points
      *  \param thePnt1, thePnt2, thePnt3 Points, defining the disk.
      *  \return New GEOM_Object, containing the created disk.
      */
     GEOM_Object MakeDiskThreePnt (in GEOM_Object thePnt1,
-                                 in GEOM_Object thePnt2,
-                                 in GEOM_Object thePnt3);
+                                  in GEOM_Object thePnt2,
+                                  in GEOM_Object thePnt3);
 
     /*!
      *  Create a disk specified dimensions along OX-OY coordinate axes,
@@ -1049,9 +1100,9 @@ module GEOM
      *  \return New GEOM_Object, containing the created cylinder.
      */
     GEOM_Object MakeCylinderPntVecRH (in GEOM_Object thePnt,
-                                     in GEOM_Object theAxis,
-                                     in double      theR,
-                                     in double      theH);
+                                      in GEOM_Object theAxis,
+                                      in double      theR,
+                                      in double      theH);
 
     /*!
      *  Create a cone with given height and radiuses at
@@ -1078,10 +1129,10 @@ module GEOM
      *  \return New GEOM_Object, containing the created cone.
      */
     GEOM_Object MakeConePntVecR1R2H (in GEOM_Object thePnt,
-                                    in GEOM_Object theAxis,
-                                    in double      theR1,
-                                    in double      theR2,
-                                    in double      theH);
+                                     in GEOM_Object theAxis,
+                                     in double      theR1,
+                                     in double      theR2,
+                                     in double      theH);
 
     /*!
      *  Create a torus with given radiuses at the origin of coordinate system.
@@ -1090,7 +1141,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created torus.
      */
     GEOM_Object MakeTorusRR (in double theRMajor,
-                            in double theRMinor);
+                             in double theRMinor);
 
     /*!
      *  Create a torus with given center, normal vector and radiuses.
@@ -1101,9 +1152,9 @@ module GEOM
      *  \return New GEOM_Object, containing the created torus.
      */
     GEOM_Object MakeTorusPntVecRR (in GEOM_Object thePnt,
-                                  in GEOM_Object theVec,
-                                  in double theRMajor,
-                                  in double theRMinor);
+                                   in GEOM_Object theVec,
+                                   in double theRMajor,
+                                   in double theRMinor);
 
     /*!
      *  Create a sphere with given radius at the origin of coordinate system.
@@ -1130,12 +1181,12 @@ module GEOM
      *  \return New GEOM_Object, containing the created prism.
      */
     GEOM_Object MakePrismVecH (in GEOM_Object theBase,
-                              in GEOM_Object theVec,
-                              in double      theH);
+                               in GEOM_Object theVec,
+                               in double      theH);
     /*  The Same Prism but in 2 directions (forward&backward) */
     GEOM_Object MakePrismVecH2Ways (in GEOM_Object theBase,
-                                   in GEOM_Object theVec,
-                                   in double      theH);
+                                    in GEOM_Object theVec,
+                                    in double      theH);
 
     /*!
      *  Create a shape by extrusion of the base shape along a vector, defined by two points.
@@ -1145,12 +1196,12 @@ module GEOM
      *  \return New GEOM_Object, containing the created prism.
      */
     GEOM_Object MakePrismTwoPnt (in GEOM_Object theBase,
-                                in GEOM_Object thePoint1,
-                                in GEOM_Object thePoint2);
+                                 in GEOM_Object thePoint1,
+                                 in GEOM_Object thePoint2);
     /*  The same prism but in two directions forward&backward */
     GEOM_Object MakePrismTwoPnt2Ways (in GEOM_Object theBase,
-                                     in GEOM_Object thePoint1,
-                                     in GEOM_Object thePoint2);
+                                      in GEOM_Object thePoint1,
+                                      in GEOM_Object thePoint2);
 
     /*!
      *  Create a shape by extrusion of the base shape along a vector, defined by DX DY DZ.
@@ -1159,7 +1210,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created prism.
      */
     GEOM_Object MakePrismDXDYDZ (in GEOM_Object theBase,
-                                in double theDX, in double theDY, in double theDZ);
+                                   in double theDX, in double theDY, in double theDZ);
     /*  The same prism but in two directions forward&backward */
     GEOM_Object MakePrismDXDYDZ2Ways (in GEOM_Object theBase,
                                       in double theDX, in double theDY, in double theDZ);
@@ -1183,12 +1234,12 @@ module GEOM
      *  \return New GEOM_Object, containing the created revolution.
      */
     GEOM_Object MakeRevolutionAxisAngle (in GEOM_Object theBase,
-                                        in GEOM_Object theAxis,
-                                        in double theAngle);
+                                         in GEOM_Object theAxis,
+                                         in double theAngle);
     /*  The Same Revolution but in both ways forward&backward */
     GEOM_Object MakeRevolutionAxisAngle2Ways (in GEOM_Object theBase,
-                                             in GEOM_Object theAxis,
-                                             in double theAngle);
+                                              in GEOM_Object theAxis,
+                                              in double theAngle);
 
     /*!
      *  Create a filling from the given compound of contours.
@@ -1201,9 +1252,9 @@ module GEOM
      *  \return New GEOM_Object, containing the created filling surface.
      */
     GEOM_Object MakeFilling (in GEOM_Object theShape,
-                            in long theMinDeg, in long theMaxDeg,
-                            in double theTol2D, in double theTol3D,
-                            in long theNbIter,
+                             in long theMinDeg, in long theMaxDeg,
+                             in double theTol2D, in double theTol3D,
+                             in long theNbIter,
                              in filling_oper_method theMethod,
                              in boolean theApprox);
 
@@ -1216,8 +1267,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created shell or solid.
      */
     GEOM_Object MakeThruSections(in ListOfGO theSeqSections,
-                                in boolean theModeSolid,
-                                in double thePreci,
+                                 in boolean theModeSolid,
+                                 in double thePreci,
                                  in boolean theRuled);
 
       /*!
@@ -1232,14 +1283,14 @@ module GEOM
      *  \param theWithContact - the mode defining that the section is translated to be in
      *                          contact with the spine.
      *  \param - WithCorrection - defining that the section is rotated to be
-     *                          orthogonal to the spine tangent in the correspondent point
+     *                                 orthogonal to the spine tangent in the correspondent point
      *  \return New GEOM_Object, containing the created pipe.
      */
     GEOM_Object MakePipeWithDifferentSections (in ListOfGO theSeqBases,
-                                              in ListOfGO theLocations,
-                                              in GEOM_Object thePath,
-                                              in boolean theWithContact ,
-                                              in boolean theWithCorrection );
+                                               in ListOfGO theLocations,
+                                               in GEOM_Object thePath,
+                                               in boolean theWithContact ,
+                                               in boolean theWithCorrection );
 
     /*!
      *  Create a shape by extrusion of the profile shape along
@@ -1254,15 +1305,15 @@ module GEOM
      *  \param theWithContact - the mode defining that the section is translated to be in
      *                          contact with the spine.
      *  \param - WithCorrection - defining that the section is rotated to be
-     *                          orthogonal to the spine tangent in the correspondent point
+     *                                 orthogonal to the spine tangent in the correspondent point
      *  \return New GEOM_Object, containing the created pipe.
      */
     GEOM_Object MakePipeWithShellSections (in ListOfGO theSeqBases,
-                                          in ListOfGO theSeqSubBases,
-                                          in ListOfGO theLocations,
-                                          in GEOM_Object thePath,
-                                          in boolean theWithContact ,
-                                          in boolean theWithCorrection );
+                                           in ListOfGO theSeqSubBases,
+                                           in ListOfGO theLocations,
+                                           in GEOM_Object thePath,
+                                           in boolean theWithContact ,
+                                           in boolean theWithCorrection );
 
     /*!
      * Create solids between given sections
@@ -1271,7 +1322,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created solids.
      */
     GEOM_Object MakePipeShellsWithoutPath (in ListOfGO theSeqBases,
-                                          in ListOfGO theLocations);
+                                           in ListOfGO theLocations);
 
     /*!
      *  Create a shape by extrusion of the base shape along
@@ -1285,8 +1336,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created pipe.
      */
     GEOM_Object MakePipeBiNormalAlongVector (in GEOM_Object theBase,
-                                            in GEOM_Object thePath,
-                                            in GEOM_Object theVec);
+                                             in GEOM_Object thePath,
+                                             in GEOM_Object theVec);
 
   };
 
@@ -1305,6 +1356,17 @@ module GEOM
      */
     GEOM_Object MakeEdge (in GEOM_Object thePnt1, in GEOM_Object thePnt2);
 
+    /*!
+     *  Create an edge from specified wire.
+     *  \param theWire source Wire.
+     *  \param theLinearTolerance linear tolerance value
+     *  \param theAngularTolerance angular tolerance value
+     *  \return New GEOM_Object, containing the created edge.
+     */
+    GEOM_Object MakeEdgeWire (in GEOM_Object theWire,
+                             in double theLinearTolerance, 
+                             in double theAngularTolerance);
+
     /*!
      *  Create a wire from the set of edges and wires.
      *  \param theEdgesAndWires List of edge and/or wires.
@@ -1388,7 +1450,18 @@ module GEOM
      *  \return New GEOM_Object, containing a copy of theShape without some faces.
      */
     GEOM_Object MakeGlueFacesByList (in GEOM_Object theShape, in double theTolerance,
-                                    in ListOfGO theFaces, in boolean doKeepNonSolids);
+                                     in ListOfGO theFaces, in boolean doKeepNonSolids);
+
+    /*!
+     *  Get all sub-shapes and groups of \a theShape,
+     *  that were created already by any other methods.
+     *  \param theShape Any shape.
+     *  \param theGroupsOnly If this parameter is TRUE, only groups will be
+     *                       returned, else all found sub-shapes and groups.
+     *  \return List of existing sub-objects of \a theShape.
+     */
+    ListOfGO GetExistingSubObjects (in GEOM_Object theShape,
+                                    in boolean     theGroupsOnly);
 
     /*!
      *  Deprecated method. Use MakeAllSubShapes() instead.
@@ -1436,7 +1509,7 @@ module GEOM
      *        Don't try to apply modification operations on them.
      */
     GEOM_Object GetSubShape (in GEOM_Object theMainShape,
-                            in long        theID);
+                             in long        theID);
 
     /*!
      *  Get global index of \a theSubShape in \a theMainShape.
@@ -1513,8 +1586,8 @@ module GEOM
      *  \return List of sub-shapes of theShape1, shared with theShape2.
      */
     ListOfGO GetSharedShapes (in GEOM_Object theShape1,
-                             in GEOM_Object theShape2,
-                             in long        theShapeType);
+                              in GEOM_Object theShape2,
+                              in long        theShapeType);
 
     /*!
      *  Get all sub-shapes, shared by all shapes in the list \a theShapes.
@@ -1536,9 +1609,9 @@ module GEOM
      *  \return List of all found sub-shapes.
      */
     ListOfGO GetShapesOnPlane (in GEOM_Object theShape,
-                              in long        theShapeType,
-                              in GEOM_Object theAx1,
-                              in shape_state theState);
+                               in long        theShapeType,
+                               in GEOM_Object theAx1,
+                               in shape_state theState);
     /*!
      *  Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
      *  the specified plane by the certain way, defined through \a theState parameter.
@@ -1551,10 +1624,10 @@ module GEOM
      *  \return List of all found sub-shapes.
      */
     ListOfGO GetShapesOnPlaneWithLocation (in GEOM_Object theShape,
-                                          in long        theShapeType,
-                                          in GEOM_Object theAx1,
-                                          in GEOM_Object thePnt,
-                                          in shape_state theState);
+                                           in long        theShapeType,
+                                           in GEOM_Object theAx1,
+                                           in GEOM_Object thePnt,
+                                           in shape_state theState);
 
 
 
@@ -1570,10 +1643,10 @@ module GEOM
      *  \return List of all found sub-shapes.
      */
     ListOfGO GetShapesOnCylinder (in GEOM_Object theShape,
-                                 in long        theShapeType,
-                                 in GEOM_Object theAxis,
-                                 in double      theRadius,
-                                 in shape_state theState);
+                                  in long        theShapeType,
+                                  in GEOM_Object theAxis,
+                                  in double      theRadius,
+                                  in shape_state theState);
 
     /*!
      *  Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
@@ -1605,10 +1678,10 @@ module GEOM
      *  \return List of all found sub-shapes.
      */
     ListOfGO GetShapesOnSphere (in GEOM_Object theShape,
-                               in long        theShapeType,
-                               in GEOM_Object theCenter,
-                               in double      theRadius,
-                               in shape_state theState);
+                                in long        theShapeType,
+                                in GEOM_Object theCenter,
+                                in double      theRadius,
+                                in shape_state theState);
 
     /*!
      *  Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
@@ -1641,9 +1714,9 @@ module GEOM
      *  \return List of IDs of all found sub-shapes.
      */
     ListOfLong GetShapesOnPlaneIDs (in GEOM_Object theShape,
-                                   in long        theShapeType,
-                                   in GEOM_Object theAx1,
-                                   in shape_state theState);
+                                    in long        theShapeType,
+                                    in GEOM_Object theAx1,
+                                    in shape_state theState);
 
     /*!
      *  Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
@@ -1657,10 +1730,10 @@ module GEOM
      *  \return List of IDs of all found sub-shapes.
      */
     ListOfLong GetShapesOnPlaneWithLocationIDs (in GEOM_Object theShape,
-                                               in long        theShapeType,
-                                               in GEOM_Object theAx1,
-                                               in GEOM_Object thePnt,
-                                               in shape_state theState);
+                                                in long        theShapeType,
+                                                in GEOM_Object theAx1,
+                                                in GEOM_Object thePnt,
+                                                in shape_state theState);
 
     /*!
      *  Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
@@ -1674,10 +1747,10 @@ module GEOM
      *  \return List of IDs of all found sub-shapes.
      */
     ListOfLong GetShapesOnCylinderIDs (in GEOM_Object theShape,
-                                      in long        theShapeType,
-                                      in GEOM_Object theAxis,
-                                      in double      theRadius,
-                                      in shape_state theState);
+                                       in long        theShapeType,
+                                       in GEOM_Object theAxis,
+                                       in double      theRadius,
+                                       in shape_state theState);
 
     /*!
      *  Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
@@ -1709,10 +1782,10 @@ module GEOM
      *  \return List of IDs of all found sub-shapes.
      */
     ListOfLong GetShapesOnSphereIDs (in GEOM_Object theShape,
-                                    in long        theShapeType,
-                                    in GEOM_Object theCenter,
-                                    in double      theRadius,
-                                    in shape_state theState);
+                                     in long        theShapeType,
+                                     in GEOM_Object theCenter,
+                                     in double      theRadius,
+                                     in shape_state theState);
 
     /*!
      *  Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
@@ -1743,9 +1816,9 @@ module GEOM
      * \return List of IDs of all found sub-shapes.
      */
     ListOfLong GetShapesOnBoxIDs (in GEOM_Object theBox,
-                                 in GEOM_Object theShape,
-                                 in long        theShapeType,
-                                 in shape_state theState);
+                                  in GEOM_Object theShape,
+                                  in long        theShapeType,
+                                  in shape_state theState);
 
     /*!
      * \brief Find subshapes complying with given status
@@ -1756,9 +1829,9 @@ module GEOM
      * \return List of all found sub-shapes.
      */
     ListOfGO GetShapesOnBox (in GEOM_Object theBox,
-                            in GEOM_Object theShape,
-                            in long        theShapeType,
-                            in shape_state theState);
+                             in GEOM_Object theShape,
+                             in long        theShapeType,
+                             in shape_state theState);
 
     /*!
      * \brief Find subshapes complying with given status
@@ -1769,9 +1842,9 @@ module GEOM
      * \return List of IDs of all found sub-shapes.
      */
     ListOfLong GetShapesOnShapeIDs (in GEOM_Object theCheckShape,
-                                   in GEOM_Object theShape,
-                                   in short       theShapeType,
-                                   in shape_state theState);
+                                    in GEOM_Object theShape,
+                                    in short       theShapeType,
+                                    in shape_state theState);
 
     /*!
      * \brief Find subshapes complying with given status
@@ -1782,9 +1855,9 @@ module GEOM
      * \return List of all found sub-shapes.
      */
     ListOfGO GetShapesOnShape (in GEOM_Object theCheckShape,
-                              in GEOM_Object theShape,
-                              in short       theShapeType,
-                              in shape_state theState);
+                               in GEOM_Object theShape,
+                               in short       theShapeType,
+                               in shape_state theState);
 
     /*!
      * \brief Find subshapes complying with given status
@@ -1795,9 +1868,9 @@ module GEOM
      * \return compound includes all found sub-shapes.
      */
     GEOM_Object GetShapesOnShapeAsCompound (in GEOM_Object theCheckShape,
-                                           in GEOM_Object theShape,
-                                           in short       theShapeType,
-                                           in shape_state theState);
+                                            in GEOM_Object theShape,
+                                            in short       theShapeType,
+                                            in shape_state theState);
 
     /*!
      *  Get sub-shape(s) of \a theShapeWhere, which are
@@ -1807,7 +1880,7 @@ module GEOM
      *  \return Group of all found sub-shapes or a single found sub-shape.
      */
     GEOM_Object GetInPlace (in GEOM_Object theShapeWhere,
-                           in GEOM_Object theShapeWhat);
+                            in GEOM_Object theShapeWhat);
 
     /*!
      *  Get sub-shape(s) of \a theShapeWhere, which are
@@ -1824,7 +1897,7 @@ module GEOM
      *  \return Group of all found sub-shapes or a single found sub-shape.
      */
     GEOM_Object GetInPlaceByHistory (in GEOM_Object theShapeWhere,
-                                    in GEOM_Object theShapeWhat);
+                                     in GEOM_Object theShapeWhat);
 
     /*!
      *  Get sub-shape of theShapeWhere, which are
@@ -1834,7 +1907,7 @@ module GEOM
      *  \return found sub-shape.
      */
     GEOM_Object GetSame (in GEOM_Object theShapeWhere,
-                        in GEOM_Object theShapeWhat);
+                                in GEOM_Object theShapeWhat);
   };
 
   /*!
@@ -1855,9 +1928,9 @@ module GEOM
      *  \return New GEOM_Object, containing the created face.
      */
     GEOM_Object MakeQuad (in GEOM_Object theEdge1,
-                         in GEOM_Object theEdge2,
-                         in GEOM_Object theEdge3,
-                         in GEOM_Object theEdge4);
+                          in GEOM_Object theEdge2,
+                          in GEOM_Object theEdge3,
+                          in GEOM_Object theEdge4);
 
     /*!
      *  Create a quadrangle face on two edges.
@@ -1866,7 +1939,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created face.
      */
     GEOM_Object MakeQuad2Edges (in GEOM_Object theEdge1,
-                               in GEOM_Object theEdge2);
+                                in GEOM_Object theEdge2);
 
     /*!
      *  Create a quadrangle face with specified corners.
@@ -1875,9 +1948,9 @@ module GEOM
      *  \return New GEOM_Object, containing the created face.
      */
     GEOM_Object MakeQuad4Vertices (in GEOM_Object thePnt1,
-                                  in GEOM_Object thePnt2,
-                                  in GEOM_Object thePnt3,
-                                  in GEOM_Object thePnt4);
+                                   in GEOM_Object thePnt2,
+                                   in GEOM_Object thePnt3,
+                                   in GEOM_Object thePnt4);
 
     /*!
      *  Create a hexahedral solid, bounded by the six given faces. Order of
@@ -1886,11 +1959,11 @@ module GEOM
      *  \return New GEOM_Object, containing the created solid.
      */
     GEOM_Object MakeHexa (in GEOM_Object theFace1,
-                         in GEOM_Object theFace2,
-                         in GEOM_Object theFace3,
-                         in GEOM_Object theFace4,
-                         in GEOM_Object theFace5,
-                         in GEOM_Object theFace6);
+                          in GEOM_Object theFace2,
+                          in GEOM_Object theFace3,
+                          in GEOM_Object theFace4,
+                          in GEOM_Object theFace5,
+                          in GEOM_Object theFace6);
 
     /*!
      *  Create a hexahedral solid between two given faces.
@@ -1899,7 +1972,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created solid.
      */
     GEOM_Object MakeHexa2Faces (in GEOM_Object theFace1,
-                               in GEOM_Object theFace2);
+                                in GEOM_Object theFace2);
 
     /*!
      *  Extract elements of blocks and blocks compounds
@@ -1914,10 +1987,19 @@ module GEOM
      *  \return New GEOM_Object, containing the found vertex.
      */
     GEOM_Object GetPoint (in GEOM_Object theShape,
-                         in double      theX,
-                         in double      theY,
-                         in double      theZ,
-                         in double      theEpsilon);
+                          in double      theX,
+                          in double      theY,
+                          in double      theZ,
+                          in double      theEpsilon);
+
+    /*!
+     *  Find a vertex of the given shape, which has minimal distance to the given point.
+     *  \param theShape Any shape.
+     *  \param thePoint Point, close to the desired vertex.
+     *  \return New GEOM_Object, containing the found vertex.
+     */
+    GEOM_Object GetVertexNearPoint (in GEOM_Object theShape,
+                                    in GEOM_Object thePoint);
 
     /*!
      *  Get an edge, found in the given shape by two given vertices.
@@ -1926,8 +2008,8 @@ module GEOM
      *  \return New GEOM_Object, containing the found edge.
      */
     GEOM_Object GetEdge (in GEOM_Object theShape,
-                        in GEOM_Object thePoint1,
-                        in GEOM_Object thePoint2);
+                         in GEOM_Object thePoint1,
+                         in GEOM_Object thePoint2);
 
     /*!
      *  Find an edge of the given shape, which has minimal distance to the given point.
@@ -1936,7 +2018,7 @@ module GEOM
      *  \return New GEOM_Object, containing the found edge.
      */
     GEOM_Object GetEdgeNearPoint (in GEOM_Object theShape,
-                                 in GEOM_Object thePoint);
+                                  in GEOM_Object thePoint);
 
     /*!
      *  Returns a face, found in the given shape by four given corner vertices.
@@ -1945,10 +2027,10 @@ module GEOM
      *  \return New GEOM_Object, containing the found face.
      */
     GEOM_Object GetFaceByPoints (in GEOM_Object theShape,
-                                in GEOM_Object thePoint1,
-                                in GEOM_Object thePoint2,
-                                in GEOM_Object thePoint3,
-                                in GEOM_Object thePoint4);
+                                 in GEOM_Object thePoint1,
+                                 in GEOM_Object thePoint2,
+                                 in GEOM_Object thePoint3,
+                                 in GEOM_Object thePoint4);
 
     /*!
      *  Get a face of block, found in the given shape by two given edges.
@@ -1957,8 +2039,8 @@ module GEOM
      *  \return New GEOM_Object, containing the found face.
      */
     GEOM_Object GetFaceByEdges (in GEOM_Object theShape,
-                               in GEOM_Object theEdge1,
-                               in GEOM_Object theEdge2);
+                                in GEOM_Object theEdge1,
+                                in GEOM_Object theEdge2);
 
     /*!
      *  Find a face, opposite to the given one in the given block.
@@ -1967,7 +2049,7 @@ module GEOM
      *  \return New GEOM_Object, containing the found face.
      */
     GEOM_Object GetOppositeFace (in GEOM_Object theBlock,
-                                in GEOM_Object theFace);
+                                 in GEOM_Object theFace);
 
     /*!
      *  Find a face of the given shape, which has minimal distance to the given point.
@@ -1976,7 +2058,7 @@ module GEOM
      *  \return New GEOM_Object, containing the found face.
      */
     GEOM_Object GetFaceNearPoint (in GEOM_Object theShape,
-                                 in GEOM_Object thePoint);
+                                  in GEOM_Object thePoint);
 
     /*!
      *  Find a face of block, whose outside normale has minimal angle with the given vector.
@@ -1985,7 +2067,23 @@ module GEOM
      *  \return New GEOM_Object, containing the found face.
      */
     GEOM_Object GetFaceByNormale (in GEOM_Object theBlock,
-                                 in GEOM_Object theVector);
+                                  in GEOM_Object theVector);
+
+    /*!
+     *  Find all subshapes of type \a theShapeType of the given shape,
+     *  which have minimal distance to the given point.
+     *  \param theShape Any shape.
+     *  \param thePoint Point, close to the desired shape.
+     *  \param theShapeType Defines what kind of subshapes is searched.
+     *  \param theTolerance The tolerance for distances comparison. All shapes
+     *                      with distances to the given point in interval
+     *                      [minimal_distance, minimal_distance + theTolerance] will be gathered.
+     *  \return New GEOM_Object, containing a group of all found shapes.
+     */
+    GEOM_Object GetShapesNearPoint (in GEOM_Object theShape,
+                                    in GEOM_Object thePoint,
+                                    in long        theShapeType,
+                                    in double      theTolerance);
 
     /*!
      *  Extract blocks from blocks compounds
@@ -2001,9 +2099,9 @@ module GEOM
      *  \return theNbBlocks Number of specified blocks in theCompound.
      */
     boolean IsCompoundOfBlocks (in GEOM_Object theCompound,
-                               in long        theMinNbFaces,
-                               in long        theMaxNbFaces,
-                               out long       theNbBlocks);
+                                in long        theMinNbFaces,
+                                in long        theMaxNbFaces,
+                                out long       theNbBlocks);
 
     /*!
      *  Enumeration of Blocks Compound defects.
@@ -2054,7 +2152,7 @@ module GEOM
      *  \return theErrors Structure, containing discovered errors and incriminated sub-shapes.
      */
     boolean CheckCompoundOfBlocks (in GEOM_Object theCompound,
-                                  out BCErrors   theErrors);
+                                   out BCErrors   theErrors);
 
     /*!
      *  Convert sequence of Blocks Compound errors, returned by
@@ -2064,7 +2162,7 @@ module GEOM
      *  \return String, describing all the errors in form, suitable for printing.
      */
     string PrintBCErrors (in GEOM_Object theCompound,
-                         in BCErrors    theErrors);
+                          in BCErrors    theErrors);
 
     /*!
      *  Remove all seam and degenerated edges from \a theShape.
@@ -2097,8 +2195,8 @@ module GEOM
      *  \return List of GEOM_Objects, containing the retrieved blocks.
      */
     ListOfGO ExplodeCompoundOfBlocks (in GEOM_Object theCompound,
-                                     in long        theMinNbFaces,
-                                     in long        theMaxNbFaces);
+                                      in long        theMinNbFaces,
+                                      in long        theMaxNbFaces);
 
     /*!
      *  Find block, containing the given point inside its volume or on boundary.
@@ -2108,7 +2206,7 @@ module GEOM
      *  \return New GEOM_Object, containing the found block.
      */
     GEOM_Object GetBlockNearPoint (in GEOM_Object theCompound,
-                                  in GEOM_Object thePoint);
+                                   in GEOM_Object thePoint);
 
     /*!
      *  Find block, containing all the elements, passed as the parts, or maximum quantity of them.
@@ -2117,7 +2215,7 @@ module GEOM
      *  \return New GEOM_Object, containing the found block.
      */
     GEOM_Object GetBlockByParts (in GEOM_Object theCompound,
-                                in ListOfGO    theParts);
+                                 in ListOfGO    theParts);
 
     /*!
      *  Return all blocks, containing all the elements, passed as the parts.
@@ -2126,7 +2224,7 @@ module GEOM
      *  \return List of GEOM_Objects, containing the found blocks.
      */
     ListOfGO GetBlocksByParts (in GEOM_Object theCompound,
-                              in ListOfGO    theParts);
+                               in ListOfGO    theParts);
 
     /*!
      *  Operations on blocks with gluing of result
@@ -2144,9 +2242,9 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeMultiTransformation1D (in GEOM_Object theBlock,
-                                          in long        theDirFace1,
-                                          in long        theDirFace2,
-                                          in long        theNbTimes);
+                                           in long        theDirFace1,
+                                           in long        theDirFace2,
+                                           in long        theNbTimes);
 
     /*!
      *  Multi-transformate block and glue the result.
@@ -2157,12 +2255,12 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeMultiTransformation2D (in GEOM_Object theBlock,
-                                          in long        theDirFace1U,
-                                          in long        theDirFace2U,
-                                          in long        theNbTimesU,
-                                          in long        theDirFace1V,
-                                          in long        theDirFace2V,
-                                          in long        theNbTimesV);
+                                           in long        theDirFace1U,
+                                           in long        theDirFace2U,
+                                           in long        theNbTimesU,
+                                           in long        theDirFace1V,
+                                           in long        theDirFace2V,
+                                           in long        theNbTimesV);
 
     /*!
      *  Special operation - propagation
@@ -2193,8 +2291,8 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeBoolean (in GEOM_Object theShape1,
-                            in GEOM_Object theShape2,
-                            in long theOperation);
+                             in GEOM_Object theShape2,
+                             in long theOperation);
 
     /*!
      *  Perform partition operation.
@@ -2222,13 +2320,13 @@ module GEOM
      *  \return New GEOM_Object, containing the result shapes.
      */
     GEOM_Object MakePartition (in ListOfGO   theShapes,
-                              in ListOfGO   theTools,
-                              in ListOfGO   theKeepInside,
-                              in ListOfGO   theRemoveInside,
-                              in short      theLimit,
-                              in boolean    theRemoveWebs,
-                              in ListOfLong theMaterials,
-                              in short      theKeepNonlimitShapes);
+                               in ListOfGO   theTools,
+                               in ListOfGO   theKeepInside,
+                               in ListOfGO   theRemoveInside,
+                               in short      theLimit,
+                               in boolean    theRemoveWebs,
+                               in ListOfLong theMaterials,
+                               in short      theKeepNonlimitShapes);
 
     /*!
      *  Perform partition operation.
@@ -2244,13 +2342,13 @@ module GEOM
      *  \return New GEOM_Object, containing the result shapes.
      */
     GEOM_Object MakePartitionNonSelfIntersectedShape (in ListOfGO   theShapes,
-                                                     in ListOfGO   theTools,
-                                                     in ListOfGO   theKeepInside,
-                                                     in ListOfGO   theRemoveInside,
-                                                     in short      theLimit,
-                                                     in boolean    theRemoveWebs,
-                                                     in ListOfLong theMaterials,
-                                                     in short      theKeepNonlimitShapes);
+                                                      in ListOfGO   theTools,
+                                                      in ListOfGO   theKeepInside,
+                                                      in ListOfGO   theRemoveInside,
+                                                      in short      theLimit,
+                                                      in boolean    theRemoveWebs,
+                                                      in ListOfLong theMaterials,
+                                                      in short      theKeepNonlimitShapes);
 
     /*!
      *  Perform partition of the Shape with the Plane
@@ -2259,7 +2357,7 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeHalfPartition (in GEOM_Object theShape,
-                                  in GEOM_Object thePlane);
+                                   in GEOM_Object thePlane);
   };
 
   /*!
@@ -2276,16 +2374,16 @@ module GEOM
      *  \return New GEOM_Object, containing the created circle.
      */
     GEOM_Object MakeCirclePntVecR (in GEOM_Object thePnt,
-                                  in GEOM_Object theVec,
-                                  in double theR);
+                                   in GEOM_Object theVec,
+                                   in double theR);
     /*!
      *  Create a circle, passing through three given points
      *  \param thePnt1,thePnt2,thePnt3 Points, defining the circle.
      *  \return New GEOM_Object, containing the created circle.
      */
     GEOM_Object MakeCircleThreePnt (in GEOM_Object thePnt1,
-                                   in GEOM_Object thePnt2,
-                                   in GEOM_Object thePnt3);
+                                    in GEOM_Object thePnt2,
+                                    in GEOM_Object thePnt3);
     /*!
      *  Create a circle with given center, with a radius equals the distance from center to Point1
      *  and on a plane defined by all of three points.
@@ -2293,8 +2391,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created circle.
      */
     GEOM_Object MakeCircleCenter2Pnt (in GEOM_Object thePnt1,
-                                     in GEOM_Object thePnt2,
-                                     in GEOM_Object thePnt3);
+                                      in GEOM_Object thePnt2,
+                                      in GEOM_Object thePnt3);
     /*!
      *  Create an ellipse with given center, normal vector and radiuses.
      *  \param thePnt Ellipse center.
@@ -2304,9 +2402,9 @@ module GEOM
      *  \return New GEOM_Object, containing the created ellipse.
      */
     GEOM_Object MakeEllipse (in GEOM_Object thePnt,
-                            in GEOM_Object theVec,
-                            in double theRMajor,
-                            in double theRMinor);
+                             in GEOM_Object theVec,
+                             in double theRMajor,
+                             in double theRMinor);
 
     /*!
      *  Create an ellipse with given center, normal vector, main axis vector and radiuses.
@@ -2318,10 +2416,10 @@ module GEOM
      *  \return New GEOM_Object, containing the created ellipse.
      */
     GEOM_Object MakeEllipseVec (in GEOM_Object thePnt,
-                               in GEOM_Object theVec,
-                               in double theRMajor,
-                               in double theRMinor,
-                               in GEOM_Object theVecMaj);
+                                in GEOM_Object theVec,
+                                in double theRMajor,
+                                in double theRMinor,
+                                in GEOM_Object theVecMaj);
 
     /*!
      *  Create an arc of circle, passing through three given points.
@@ -2331,8 +2429,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created arc.
      */
     GEOM_Object MakeArc (in GEOM_Object thePnt1,
-                        in GEOM_Object thePnt2,
-                        in GEOM_Object thePnt3);
+                         in GEOM_Object thePnt2,
+                         in GEOM_Object thePnt3);
 
     /*!
      *  Create an arc of circle of center C from one point to another
@@ -2355,8 +2453,8 @@ module GEOM
      *  \return New GEOM_Object, containing the created arc.
      */
     GEOM_Object MakeArcOfEllipse (in GEOM_Object theCenter,
-                                 in GEOM_Object thePnt1,
-                                 in GEOM_Object thePnt2);
+                                  in GEOM_Object thePnt1,
+                                  in GEOM_Object thePnt2);
 
 
     /*!
@@ -2452,7 +2550,7 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeFilletAll (in GEOM_Object theShape,
-                              in double      theR);
+                               in double      theR);
 
     /*!
      *  Perform a fillet on the specified edges of the given shape
@@ -2464,12 +2562,12 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeFilletEdges (in GEOM_Object theShape,
-                                in double      theR,
-                                in ListOfLong  theEdges);
+                                 in double      theR,
+                                 in ListOfLong  theEdges);
     GEOM_Object MakeFilletEdgesR1R2 (in GEOM_Object theShape,
-                                    in double      theR1,
-                                    in double      theR2,
-                                    in ListOfLong  theEdges);
+                                     in double      theR1,
+                                     in double      theR2,
+                                     in ListOfLong  theEdges);
 
     /*!
      *  Perform a fillet on all edges of the specified faces of the given shape.
@@ -2481,13 +2579,13 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeFilletFaces (in GEOM_Object theShape,
-                                in double      theR,
-                                in ListOfLong  theFaces);
+                                 in double      theR,
+                                 in ListOfLong  theFaces);
 
     GEOM_Object MakeFilletFacesR1R2 (in GEOM_Object theShape,
-                                    in double      theR1,
-                                    in double      theR2,
-                                    in ListOfLong  theFaces);
+                                     in double      theR1,
+                                     in double      theR2,
+                                     in ListOfLong  theFaces);
 
     /*!
      *  Perform a fillet on face of the specified vertexes of the given shape.
@@ -2499,8 +2597,8 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeFillet2D (in GEOM_Object theShape,
-                             in double      theR,
-                             in ListOfLong  theVertexes);
+                              in double      theR,
+                              in ListOfLong  theVertexes);
 
     /*!
      *  Perform a fillet on edges of the specified vertexes of the given wire.
@@ -2514,8 +2612,8 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeFillet1D (in GEOM_Object theShape,
-                             in double      theR,
-                             in ListOfLong  theVertexes);
+                              in double      theR,
+                              in ListOfLong  theVertexes);
 
     /*!
      *  Perform a symmetric chamfer on all edges of the given shape.
@@ -2524,7 +2622,7 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeChamferAll (in GEOM_Object theShape,
-                               in double      theD);
+                                in double      theD);
 
     /*!
      *  Perform a chamfer on edges, common to the specified faces.
@@ -2538,15 +2636,15 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeChamferEdge (in GEOM_Object theShape,
-                                in double theD1, in double theD2,
-                                in long theFace1, in long theFace2);
+                                 in double theD1, in double theD2,
+                                 in long theFace1, in long theFace2);
     /*!
      *  The Same but with params theD = Chamfer Lenght
      *  and theAngle = Chamfer Angle (Angle in radians)
      */
     GEOM_Object MakeChamferEdgeAD (in GEOM_Object theShape,
-                                  in double theD, in double theAngle,
-                                  in long theFace1, in long theFace2);
+                                   in double theD, in double theAngle,
+                                   in long theFace1, in long theFace2);
 
     /*!
      *  Perform a chamfer on all edges of the specified faces.
@@ -2562,15 +2660,15 @@ module GEOM
      *  \return New GEOM_Object, containing the result shape.
      */
     GEOM_Object MakeChamferFaces (in GEOM_Object theShape,
-                                 in double theD1, in double theD2,
-                                 in ListOfLong theFaces);
+                                  in double theD1, in double theD2,
+                                  in ListOfLong theFaces);
     /*!
      *  The Same but with params theD = Chamfer Lenght
      *  and theAngle = Chamfer Angle (Angle in radians)
      */
     GEOM_Object MakeChamferFacesAD (in GEOM_Object theShape,
-                                   in double theD, in double theAngle,
-                                   in ListOfLong theFaces);
+                                    in double theD, in double theAngle,
+                                    in ListOfLong theFaces);
 
    /*!
     *  Perform a chamfer on edges,
@@ -2581,15 +2679,15 @@ module GEOM
     *  \return New GEOM_Object, containing the result shape.
     */
     GEOM_Object MakeChamferEdges (in GEOM_Object theShape,
-                                 in double theD1, in double theD2,
-                                 in ListOfLong theEdges);
+                                  in double theD1, in double theD2,
+                                  in ListOfLong theEdges);
     /*!
      *  The Same but with params theD = Chamfer Lenght
      *  and theAngle = Chamfer Angle (Angle in radians)
      */
     GEOM_Object MakeChamferEdgesAD (in GEOM_Object theShape,
-                                   in double theD, in double theAngle,
-                                   in ListOfLong theEdges);
+                                    in double theD, in double theAngle,
+                                    in ListOfLong theEdges);
 
     /*!
      *  Perform an Archimde operation on the given shape with given parameters.
@@ -2602,9 +2700,9 @@ module GEOM
      *          by a plane, corresponding to water level.
      */
     GEOM_Object MakeArchimede (in GEOM_Object theShape,
-                              in double theWeight,
-                              in double theWaterDensity,
-                              in double theMeshDeflection);
+                               in double theWeight,
+                               in double theWaterDensity,
+                               in double theMeshDeflection);
 
     /*!
      *  Duplicates <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR>.
@@ -2630,9 +2728,9 @@ module GEOM
      *  \return New GEOM_Object, containing processed shape.
      */
     GEOM_Object ProcessShape (in GEOM_Object theShapes,
-                             in string_array theOperators,
-                             in string_array theParameters,
-                             in string_array theValues);
+                              in string_array theOperators,
+                              in string_array theParameters,
+                              in string_array theValues);
 
     /*!
      *  Get default sequence of operators, their parameters and parameters' values
@@ -2644,8 +2742,8 @@ module GEOM
      *                           as parameters are listed in \a theParameters list.
      */
     void GetShapeProcessParameters (out string_array theOperators,
-                                   out string_array theParameters,
-                                   out string_array theValues);
+                                    out string_array theParameters,
+                                    out string_array theValues);
     /*!
      *  Get parameters and parameters' values for the given Shape Process operation.
      *  In the current implementation the defaults are
@@ -2656,8 +2754,8 @@ module GEOM
      *                           as parameters are listed in \a theParameters list.
      */
     void GetOperatorParameters (in string theOperator,
-                               out string_array theParameters,
-                               out string_array theValues);
+                                out string_array theParameters,
+                                out string_array theValues);
 
     /*!
      *  Remove faces from the given object (shape).
@@ -2678,7 +2776,7 @@ module GEOM
      *  \return New GEOM_Object, containing processed shape.
      */
     GEOM_Object CloseContour (in GEOM_Object theObject, in short_array theWires,
-                             in boolean isCommonVertex);
+                              in boolean isCommonVertex);
 
     /*!
      *  Remove internal wires and edges from the given object (face).
@@ -2718,7 +2816,7 @@ module GEOM
      *  \return New GEOM_Object, containing processed shape.
      */
     GEOM_Object DivideEdge (in GEOM_Object theObject, in short theEdgeIndex,
-                           in double theValue, in boolean isByParameter);
+                            in double theValue, in boolean isByParameter);
 
     /*!
      *  Get a list of wires (wrapped in GEOM_Object-s),
@@ -2729,8 +2827,8 @@ module GEOM
      *  \return FALSE, if an error(s) occured during the method execution.
      */
     boolean GetFreeBoundary (in GEOM_Object theObject,
-                            out ListOfGO theClosedWires,
-                            out ListOfGO theOpenWires);
+                             out ListOfGO theClosedWires,
+                             out ListOfGO theOpenWires);
 
     /*!
      *  Change orientation of the given object.
@@ -2740,6 +2838,14 @@ module GEOM
     GEOM_Object ChangeOrientation (in GEOM_Object theObject);
     GEOM_Object ChangeOrientationCopy (in GEOM_Object theObject);
 
+    /*!
+     *  Try to limit tolerance of the given object by value \a theTolerance.
+     *  \param theObject Shape to be processed.
+     *  \param theTolerance Required tolerance value.
+     *  \return New GEOM_Object, containing processed shape.
+     */
+    GEOM_Object LimitTolerance (in GEOM_Object theObject, in double theTolerance);
+
   };
 
   /*!
@@ -2781,7 +2887,7 @@ module GEOM
      *  \return Returns available formats and patterns through the arguments.
      */
     void ImportTranslators (out string_array theFormats,
-                           out string_array thePatterns);
+                            out string_array thePatterns);
 
     /*!
      *  Get the supported export formats and corresponding patterns for File dialog.
@@ -2790,7 +2896,7 @@ module GEOM
      *  \return Returns available formats and patterns through the arguments.
      */
     void ExportTranslators (out string_array theFormats,
-                           out string_array thePatterns);
+                            out string_array thePatterns);
 
     /*!
      * Load texture from file
@@ -2891,8 +2997,8 @@ module GEOM
      */
     //short KindOfShape (in GEOM_Object   theShape,
     GEOM_IKindOfShape::shape_kind KindOfShape (in  GEOM_Object  theShape,
-                                              out ListOfLong   theIntegers,
-                                              out ListOfDouble theDoubles);
+                                               out ListOfLong   theIntegers,
+                                               out ListOfDouble theDoubles);
 
     /*!
      *  Get position (LCS) of theShape.
@@ -2906,9 +3012,9 @@ module GEOM
      *  \return Returns position of the shape through the last nine arguments.
      */
     void GetPosition (in GEOM_Object theShape,
-                     out double Ox, out double Oy, out double Oz,
-                     out double Zx, out double Zy, out double Zz,
-                     out double Xx, out double Xy, out double Xz);
+                      out double Ox, out double Oy, out double Oz,
+                      out double Zx, out double Zy, out double Zz,
+                      out double Xx, out double Xy, out double Xz);
 
     /*!
      *  Get summarized length of all wires,
@@ -2920,9 +3026,9 @@ module GEOM
      *  \return Returns shape properties through the last three arguments.
      */
     void GetBasicProperties (in GEOM_Object theShape,
-                            out double theLength,
-                            out double theSurfArea,
-                            out double theVolume);
+                             out double theLength,
+                             out double theSurfArea,
+                             out double theVolume);
 
     /*!
      *  Get a point, situated at the centre of mass of theShape.
@@ -2930,8 +3036,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created point.
      */
     GEOM_Object GetCentreOfMass (in GEOM_Object theShape);
-    
-    
+
     /*
      *  Get the vertex by index for 1D objects depends the edge/wire orientation
      *  \param theShape Shape (wire or edge) to find the vertex on it
@@ -2949,7 +3054,7 @@ module GEOM
      *  \return New GEOM_Object, containing the created normal vector.
      */
     GEOM_Object GetNormal (in GEOM_Object theFace,
-                          in GEOM_Object theOptionalPoint);
+                           in GEOM_Object theOptionalPoint);
 
     /*!
      *  Get inertia matrix and moments of inertia of theShape.
@@ -2959,10 +3064,10 @@ module GEOM
      *  \return Returns inertia through the last twelve arguments.
      */
     void GetInertia (in GEOM_Object theShape,
-                    out double I11, out double I12, out double I13,
-                    out double I21, out double I22, out double I23,
-                    out double I31, out double I32, out double I33,
-                    out double Ix , out double Iy , out double Iz);
+                     out double I11, out double I12, out double I13,
+                     out double I21, out double I22, out double I23,
+                     out double I31, out double I32, out double I33,
+                     out double Ix , out double Iy , out double Iz);
 
     /*!
      *  Get parameters of bounding box of the given shape
@@ -2973,9 +3078,9 @@ module GEOM
      *  \return Returns parameters of bounding box through the last six arguments.
      */
     void GetBoundingBox (in GEOM_Object theShape,
-                        out double Xmin, out double Xmax,
-                        out double Ymin, out double Ymax,
-                        out double Zmin, out double Zmax);
+                         out double Xmin, out double Xmax,
+                         out double Ymin, out double Ymax,
+                         out double Zmin, out double Zmax);
 
     /*!
      *  Get min and max tolerances of sub-shapes of theShape
@@ -2986,9 +3091,9 @@ module GEOM
      *  \return Returns shape tolerances through the last six arguments.
      */
     void GetTolerance (in GEOM_Object theShape,
-                      out double FaceMin, out double FaceMax,
-                      out double EdgeMin, out double EdgeMax,
-                      out double VertMin, out double VertMax);
+                       out double FaceMin, out double FaceMax,
+                       out double EdgeMin, out double EdgeMax,
+                       out double VertMin, out double VertMax);
 
     /*!
      *  Check a topology of the given shape.
@@ -2997,7 +3102,7 @@ module GEOM
      *  \return TRUE, if the shape "seems to be valid" from the topological point of view.
      */
     boolean CheckShape (in GEOM_Object theShape,
-                       out string     theDescription);
+                        out string     theDescription);
 
     /*!
      *  Check a topology and a geometry of the given shape.
@@ -3006,7 +3111,7 @@ module GEOM
      *  \return TRUE, if the shape "seems to be valid".
      */
     boolean CheckShapeWithGeometry (in GEOM_Object theShape,
-                                   out string     theDescription);
+                                    out string     theDescription);
 
     /*!
      *  Obtain description of the given shape
@@ -3023,8 +3128,8 @@ module GEOM
      *  \return Value of the minimal distance between the given shapes.
      */
     double GetMinDistance (in GEOM_Object theShape1, in GEOM_Object theShape2,
-                          out double X1, out double Y1, out double Z1,
-                          out double X2, out double Y2, out double Z2);
+                           out double X1, out double Y1, out double Z1,
+                           out double X2, out double Y2, out double Z2);
 
     /*!
      *  Get angle between the given lines or linear edges.
@@ -3062,7 +3167,7 @@ module GEOM
      *  \return Value of curvature.
      */
     double MaxSurfaceCurvatureByParam (in GEOM_Object theShape, in double theUParam,
-                                      in double theVParam);
+                                       in double theVParam);
 
     /*!
      *  Get max radius of curvature of surface in the given point
@@ -3080,7 +3185,7 @@ module GEOM
      *  \return Value of curvature.
      */
     double MinSurfaceCurvatureByParam (in GEOM_Object theShape, in double theUParam,
-                                      in double theVParam);
+                                       in double theVParam);
 
     /*!
      *  Get min radius of curvature of surface in the given point
@@ -3189,9 +3294,9 @@ module GEOM
      *  \param theHexMesh Boolean indicating if shape is prepared for hex mesh (default=true)
      *  \return List of GEOM_Objects, containing the created shape and propagation groups.
      */
-    ListOfGO MakePipeTShape (in double theR1, in double theW1, in double theL1, 
-                               in double theR2, in double theW2, in double theL2,
-                               in boolean theHexMesh);
+    ListOfGO MakePipeTShape (in double theR1, in double theW1, in double theL1,
+                                in double theR2, in double theW2, in double theL2,
+                                in boolean theHexMesh);
     /*!
      *  Create a T-shape object with specified caracteristics for the main and
      *  the incident pipes (radius, width, half-length).
@@ -3209,10 +3314,10 @@ module GEOM
      *  \param theP3 Junction point of incident pipe
      *  \return List of GEOM_Objects, containing the created shape and propagation groups.
      */
-    ListOfGO MakePipeTShapeWithPosition (in double theR1, in double theW1, in double theL1, 
-                                           in double theR2, in double theW2, in double theL2,
-                                           in boolean theHexMesh,
-                                           in GEOM_Object theP1, in GEOM_Object theP2, in GEOM_Object theP3);
+    ListOfGO MakePipeTShapeWithPosition (in double theR1, in double theW1, in double theL1,
+                                            in double theR2, in double theW2, in double theL2,
+                                            in boolean theHexMesh,
+                                            in GEOM_Object theP1, in GEOM_Object theP2, in GEOM_Object theP3);
     /*!
      *  Create a T-shape object with specified caracteristics for the main and
      *  the incident pipes (radius, width, half-length). A chamfer is created
@@ -3230,8 +3335,8 @@ module GEOM
      *  \return List of GEOM_Objects, containing the created shape and propagation groups.
      */
     ListOfGO MakePipeTShapeChamfer (in double theR1, in double theW1, in double theL1,
-                                   in double theR2, in double theW2, in double theL2,
-                                   in double theH, in double theW, in boolean theHexMesh);
+                                    in double theR2, in double theW2, in double theL2,
+                                    in double theH, in double theW, in boolean theHexMesh);
     /*!
      *  Create a T-shape object with specified caracteristics for the main and
      *  the incident pipes (radius, width, half-length). A chamfer is created
@@ -3252,10 +3357,10 @@ module GEOM
      *  \param theP3 Junction point of incident pipe
      *  \return List of GEOM_Objects, containing the created shape and propagation groups.
      */
-    ListOfGO MakePipeTShapeChamferWithPosition (in double theR1, in double theW1, in double theL1, 
-                                                  in double theR2, in double theW2, in double theL2, 
-                                                  in double theH, in double theW, in boolean theHexMesh,
-                                                  in GEOM_Object theP1, in GEOM_Object theP2, in GEOM_Object theP3);
+    ListOfGO MakePipeTShapeChamferWithPosition (in double theR1, in double theW1, in double theL1,
+                                                   in double theR2, in double theW2, in double theL2,
+                                                   in double theH, in double theW, in boolean theHexMesh,
+                                                   in GEOM_Object theP1, in GEOM_Object theP2, in GEOM_Object theP3);
     /*!
      *  Create a T-shape object with specified caracteristics for the main and
      *  the incident pipes (radius, width, half-length). A fillet is created
@@ -3271,9 +3376,9 @@ module GEOM
      *  \param theHexMesh Boolean indicating if shape is prepared for hex mesh (default=true)
      *  \return List of GEOM_Objects, containing the created shape and propagation groups.
      */
-    ListOfGO MakePipeTShapeFillet (in double theR1, in double theW1, in double theL1, 
-                                     in double theR2, in double theW2, in double theL2, 
-                                     in double theRF, in boolean theHexMesh);
+    ListOfGO MakePipeTShapeFillet (in double theR1, in double theW1, in double theL1,
+                                      in double theR2, in double theW2, in double theL2,
+                                      in double theRF, in boolean theHexMesh);
     /*!
      *  Create a T-shape object with specified caracteristics for the main and
      *  the incident pipes (radius, width, half-length). A fillet is created
@@ -3293,13 +3398,13 @@ module GEOM
      *  \param theP3 Junction point of incident pipe
      *  \return List of GEOM_Objects, containing the created shape and propagation groups.
      */
-    ListOfGO MakePipeTShapeFilletWithPosition (in double theR1, in double theW1, in double theL1, 
-                                                 in double theR2, in double theW2, in double theL2, 
-                                                 in double theRF, in boolean theHexMesh,
-                                                 in GEOM_Object theP1, in GEOM_Object theP2, in GEOM_Object theP3);
+    ListOfGO MakePipeTShapeFilletWithPosition (in double theR1, in double theW1, in double theL1,
+                                                  in double theR2, in double theW2, in double theL2,
+                                                  in double theRF, in boolean theHexMesh,
+                                                  in GEOM_Object theP1, in GEOM_Object theP2, in GEOM_Object theP3);
     /*@@ insert new functions before this line @@ do not remove this line @@*/
   };
-    
+
   /*!
    *  GEOM_Gen: Interface to access other GEOM interfaces.
    *  Also contains some methods to access and manage GEOM objects.
@@ -3321,9 +3426,9 @@ module GEOM
      * Returns a SObject where theObject is placed
      */
     SALOMEDS::SObject AddInStudy (in SALOMEDS::Study theStudy,
-                                 in GEOM_Object theObject,
-                                 in string theName,
-                                 in GEOM_Object theFather);
+                                  in GEOM_Object theObject,
+                                  in string theName,
+                                  in GEOM_Object theFather);
 
     /*!
      *  Publish sub-shapes, standing for arguments and sub-shapes of arguments
@@ -3349,12 +3454,42 @@ module GEOM
      *  \return list of published sub-shapes
      */
     ListOfGO RestoreSubShapesO (in SALOMEDS::Study   theStudy,
-                               in GEOM_Object       theObject,
-                               in ListOfGO          theArgs,
-                               in find_shape_method theFindMethod,
-                               in boolean           theInheritFirstArg,
+                                 in GEOM_Object       theObject,
+                                in ListOfGO          theArgs,
+                                in find_shape_method theFindMethod,
+                                in boolean           theInheritFirstArg,
                                 in boolean           theAddPrefix);
 
+    /*!
+     *  Publish sub-shapes, standing for arguments and sub-shapes of arguments
+     *  To be used from python scripts out of geompy.addToStudy (non-default usage)
+     *  \param theStudy  the study, in which theObject is published already,
+     *                   and in which the arguments will be published
+     *  \param theObject published GEOM object, arguments of which will be published
+     *  \param theArgs   list of GEOM_Object, operation arguments to be published.
+     *                   If this list is empty, all operation arguments will be published
+     *  \param theFindMethod method to search subshapes, corresponding to arguments and
+     *                       their subshapes. Value from enumeration GEOM::find_shape_method.
+     *  \param theInheritFirstArg set properties of the first argument for \a theObject.
+     *                            Do not publish subshapes in place of arguments, but only
+     *                            in place of subshapes of the first argument,
+     *                            because the whole shape corresponds to the first argument.
+     *                            Mainly to be used after transformations, but it also can be
+     *                            usefull after partition with one object shape, and some other
+     *                            operations, where only the first argument has to be considered.
+     *                            If theObject has only one argument shape, this flag is automatically
+     *                            considered as True, not regarding really passed value.
+     *  \param theAddPrefix add prefix "from_" to names of restored sub-shapes,
+     *                      and prefix "from_subshapes_of_" to names of partially restored subshapes.
+     *  \return list of published sub-shapes
+     */
+    ListOfGO RestoreGivenSubShapesO (in SALOMEDS::Study   theStudy,
+                                     in GEOM_Object       theObject,
+                                     in ListOfGO          theArgs,
+                                     in find_shape_method theFindMethod,
+                                     in boolean           theInheritFirstArg,
+                                     in boolean           theAddPrefix);
+
     /*!
      *  Publish sub-shapes, standing for arguments and sub-shapes of arguments
      *  To be used from GUI and from geompy.addToStudy.
@@ -3362,10 +3497,10 @@ module GEOM
      *  \param theSObject study object, referencing GEOM object, arguments of which will be published
      */
     ListOfGO RestoreSubShapesSO (in SALOMEDS::Study   theStudy,
-                                in SALOMEDS::SObject theSObject,
-                                in ListOfGO          theArgs,
-                                in find_shape_method theFindMethod,
-                                in boolean           theInheritFirstArg,
+                                 in SALOMEDS::SObject theSObject,
+                                 in ListOfGO          theArgs,
+                                 in find_shape_method theFindMethod,
+                                 in boolean           theInheritFirstArg,
                                  in boolean           theAddPrefix);
 
     /*!
@@ -3446,8 +3581,8 @@ module GEOM
      *  \param theObject   The object which named subshapes are published
      */
     ListOfGO PublishNamedShapesInStudy(in SALOMEDS::Study theStudy,
-                                            //in SObject theSObject,
-                                            in Object theObject);
+                                       //in SObject theSObject,
+                                       in Object theObject);
   };
 };