-// Copyright (C) 2007-2012 CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2014 CEA/DEN, EDF R&D, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
+// version 2.1 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
class GEOMImpl_IShapesOperations : public GEOM_IOperations
{
public:
+
+ enum SubShapeType {
+ None = 0x00,
+ Groups = 0x01,
+ Fields = 0x02,
+ SubShapes = 0x04,
+ All = Groups | Fields | SubShapes,
+ };
+
Standard_EXPORT GEOMImpl_IShapesOperations(GEOM_Engine* theEngine, int theDocID);
Standard_EXPORT ~GEOMImpl_IShapesOperations();
const Standard_Real theTolerance,
std::list<Handle(GEOM_Object)> theEdges);
- Standard_EXPORT Handle(TColStd_HSequenceOfTransient) GetExistingSubObjects
- (Handle(GEOM_Object) theShape,
- const Standard_Boolean theGroupsOnly);
-
+ Standard_EXPORT Handle(TColStd_HSequenceOfTransient) GetExistingSubObjects(Handle(GEOM_Object) theShape,
+ const Standard_Boolean theGroupsOnly);
+ Standard_EXPORT Handle(TColStd_HSequenceOfTransient) GetExistingSubObjects(Handle(GEOM_Object) theShape,
+ const Standard_Integer theTypes = All);
+
enum ExplodeType {
EXPLODE_OLD_INCLUDE_MAIN,
EXPLODE_NEW_INCLUDE_MAIN,
const Standard_Integer theShapeType,
GEOMAlgo_State theState);
+ /*!
+ * \brief Explode a shape into edges sorted in a row from a starting point.
+ * \param theShape - the shape to be exploded on edges.
+ * \param theStartPoint - the starting point.
+ * \return Ordered list of edges sorted in a row from a starting point.
+ */
+ Standard_EXPORT Handle(TColStd_HSequenceOfTransient)
+ GetSubShapeEdgeSorted (const Handle(GEOM_Object) &theShape,
+ const Handle(GEOM_Object) &theStartPoint);
+
private:
Handle(GEOM_Object) MakeShape (std::list<Handle(GEOM_Object)> theShapes,
const Standard_Integer theObjectType,
const Handle(TColStd_HSequenceOfInteger)& theShapeIDs,
TCollection_AsciiString & theShapeEntries);
+ /*!
+ * \brief Explode a shape into edges sorted in a row from a starting point.
+ * \param theShape - the shape to be exploded on edges.
+ * \param theStartPoint - the starting point.
+ * \return Ordered list of edges sorted in a row from a starting point.
+ */
+ Handle(TColStd_HSequenceOfInteger) getSubShapeEdgeSortedIDs
+ (const Handle(GEOM_Object) &theShape,
+ const Handle(GEOM_Object) &theStartPoint);
+
/*!
* \brief Select the object created last
* \param theObj1 - Object 1