/*!
* \brief 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 };
+ enum marker_type { MT_NONE, MT_POINT, MT_PLUS, MT_STAR, MT_X, MT_O, MT_O_POINT, MT_O_PLUS,
+ MT_O_STAR, MT_O_X, MT_RING1, MT_RING2, MT_RING3, MT_BALL, MT_USER };
/*!
* /brief Marker size
*/
long GetType();
+ /*!
+ * \brief Get value of a modification counter of the object
+ */
+ long GetTick();
+
/*!
* \brief Set a Study entry where this object was published.
*/
in GEOM_Object theShape2,
in long theOperation,
in boolean IsCheckSelfInte);
+ /*!
+ * \brief Perform fusion boolean operation on two given shapes.
+ * \param theShape1 First argument for fuse operation.
+ * \param theShape2 Second argument for fuse operation.
+ * \param IsCheckSelfInte If TRUE, perform check self intersection
+ * of arguments before an operation.
+ * \param IsRmExtraEdges If TRUE, perform removal of extra edges
+ * during an operation.
+ * \return New GEOM_Object, containing the result shape.
+ */
+ GEOM_Object MakeFuse (in GEOM_Object theShape1,
+ in GEOM_Object theShape2,
+ in boolean IsCheckSelfInte,
+ in boolean IsRmExtraEdges);
/*!
* \brief Perform fusion boolean operation on list of objects.
* \param theShapes Shapes to be fused.
* \param IsCheckSelfInte If TRUE, perform check self intersection
* of arguments before an operation.
+ * \param IsRmExtraEdges If TRUE, perform removal of extra edges
+ * during an operation.
* \return New GEOM_Object, containing the result shape.
*/
GEOM_Object MakeFuseList (in ListOfGO theShapes,
- in boolean IsCheckSelfInte);
+ in boolean IsCheckSelfInte,
+ in boolean IsRmExtraEdges);
/*!
* \brief Perform common boolean operation on list of objects.
* Each shape from theRemoveInside must belong to theShapes also.
* \param theRemoveWebs If TRUE, perform Glue 3D algorithm.
* \param theMaterials Material indices for each shape. Make sence, only if theRemoveWebs is TRUE.
- * \param IsCheckSelfInte If TRUE, perform check self intersection
- * of arguments before an operation.
*
* \return New GEOM_Object, containing the result shapes.
*/
in short theLimit,
in boolean theRemoveWebs,
in ListOfLong theMaterials,
- in short theKeepNonlimitShapes,
- in boolean IsCheckSelfInte);
+ in short theKeepNonlimitShapes);
/*!
* \brief Perform partition operation.
* a compound containing nonintersected shapes. Performance will be better
* since intersection between shapes from compound is not performed.
*
- * Description of all parameters as in previous method MakePartition()
+ * Description of all parameters as in previous method MakePartition().
+ * One additional parameter is provided:
+ * \param IsCheckSelfInte If TRUE, perform check self intersection
+ * of arguments before an operation.
*
* \note Passed compounds (via ListShapes or via ListTools)
* have to consist of nonintersecting shapes.
* \brief Perform partition of the Shape with the Plane
* \param theShape Shape to be intersected.
* \param thePlane Tool shape, to intersect theShape.
- * \param IsCheckSelfInte If TRUE, perform check self intersection
- * of arguments before an operation.
* \return New GEOM_Object, containing the result shape.
*/
GEOM_Object MakeHalfPartition (in GEOM_Object theShape,
- in GEOM_Object thePlane,
- in boolean IsCheckSelfInte);
+ in GEOM_Object thePlane);
};
// # GEOM_ICurvesOperations:
out double EdgeMin, out double EdgeMax,
out double VertMin, out double VertMax);
+ /*!
+ * \brief Enumeration of Shape defects coming from CheckShape algorithms.
+ */
+ enum ShapeErrorType
+ {
+ /* for vertices */
+ InvalidPointOnCurve,
+ InvalidPointOnCurveOnSurface,
+ InvalidPointOnSurface,
+
+ /* for edges */
+ No3DCurve,
+ Multiple3DCurve,
+ Invalid3DCurve,
+ NoCurveOnSurface,
+ InvalidCurveOnSurface,
+ InvalidCurveOnClosedSurface,
+ InvalidSameRangeFlag,
+ InvalidSameParameterFlag,
+ InvalidDegeneratedFlag,
+
+ FreeEdge,
+ InvalidMultiConnexity,
+ InvalidRange,
+
+ /* for wires */
+ EmptyWire,
+ RedundantEdge,
+ SelfIntersectingWire, /* on a face */
+
+ /* for faces */
+ NoSurface,
+ InvalidWire,
+ RedundantWire,
+ IntersectingWires,
+ InvalidImbricationOfWires,
+
+ /* for shells */
+ EmptyShell,
+ RedundantFace,
+
+ /* for shapes */
+ UnorientableShape,
+ NotClosed,
+ NotConnected,
+
+ SubshapeNotInShape,
+
+ BadOrientation,
+ BadOrientationOfSubshape,
+
+ InvalidToleranceValue,
+
+ /* for exception */
+ CheckFail
+ };
+
+ /*!
+ * \brief Description of a shape defect: type and incriminated sub-shapes.
+ */
+ struct ShapeError
+ {
+ ShapeErrorType error;
+ ListOfLong incriminated;
+ };
+
+ /*!
+ * \brief Sequence of all shape defects.
+ */
+ typedef sequence<ShapeError> ShapeErrors;
+
/*!
* \brief Check a topology of the given shape.
* \param theShape Shape to check validity of.
- * \param theDescription Output. Description of problems in the shape, if they are.
+ * \param theErrors Structure, containing discovered errors and incriminated sub-shapes.
* \return TRUE, if the shape "seems to be valid" from the topological point of view.
*/
- boolean CheckShape (in GEOM_Object theShape,
- out string theDescription);
+ boolean CheckShape (in GEOM_Object theShape,
+ out ShapeErrors theErrors);
/*!
* \brief Check a topology and a geometry of the given shape.
* \param theShape Shape to check validity of.
- * \param theDescription Output. Description of problems in the shape, if they are.
+ * \param theErrors Structure, containing discovered errors and incriminated sub-shapes.
* \return TRUE, if the shape "seems to be valid".
*/
- boolean CheckShapeWithGeometry (in GEOM_Object theShape,
- out string theDescription);
+ boolean CheckShapeWithGeometry (in GEOM_Object theShape,
+ out ShapeErrors theErrors);
+
+ /*!
+ * \brief Convert sequence of shape errors, returned by
+ * <VAR>CheckShape()</VAR> or <VAR>CheckShapeWithGeometry()</VAR>, into string.
+ * \param theShape the invalid shape.
+ * \param theErrors The sequence of \a theShape errors.
+ * \return String, describing all the errors in form, suitable for printing.
+ */
+ string PrintShapeErrors (in GEOM_Object theShape,
+ in ShapeErrors theErrors);
/*!
* \brief Check a topology of the given shape on self-intersections presence.
/*!
*
* Create a smoothing surface from a set of points
- * \param thelPoints list of points
+ * \param thelPoints list of points. Compounds of points are accepted as well.
+ * \param theNbMax maximum number of Bezier pieces in the resulting surface.
+ * \param theDegMax maximum degree of the resulting BSpline surface
+ * \param theDMax specifies maximum value of the GeomPlate_PlateG0Criterion criterion.
* \return New GEOM_Object, containing the created shape.
*/
- GEOM_Object MakeSmoothingSurface (in ListOfGO thelPoints);
+ GEOM_Object MakeSmoothingSurface (in ListOfGO thelPoints,
+ in long theNbMax,
+ in long theDegMax,
+ in double theDMax);
/*@@ insert new functions before this line @@ do not remove this line @@*/
};
void Move( in object_list what,
in SALOMEDS::SObject where,
in long row );
+
+ /*!
+ * \brief Collects dependencies of the given objects from other ones
+ * \param theStudy The study in which the object is published
+ * \param theListOfEntries List of GEOM object entries in OCAF tree (not in study)
+ * \return Struct of dependent entries and its links as a byte array
+ * \note This method is supposed to be used by GUI only.
+ */
+ SALOMEDS::TMPFile GetDependencyTree(in SALOMEDS::Study theStudy,
+ in string_array theListOfEntries);
+
+ /*!
+ * \brief Fills 3 lists that is used to clean study of redundant objects:
+ * - dependencies of the given objects from other ones;
+ * - children of the given objects;
+ * - all other objects in study.
+ * \param theStudy The study in which the object was published
+ * \param theSelectedEntries List of GEOM object entries in OCAF tree
+ * \param theParentEntries List of GEOM object entries on which the given objects depend
+ * \param theSubEntries Children entries list of the given objects
+ * \param theOtherEntries List of GEOM object entries which are in the study, but not in parents and children lists
+ * \note This method is supposed to be used by GUI only.
+ */
+ void GetEntriesToCleanStudy(in SALOMEDS::Study theStudy,
+ inout string_array theSelectedEntries,
+ inout string_array theParentEntries,
+ inout string_array theSubEntries,
+ inout string_array theOtherEntries);
+
};
};