Salome HOME
Merge branch 'Dev_0.7.1' of newgeom:newgeom.git into Dev_0.7.1
authorsbh <sergey.belash@opencascade.com>
Tue, 27 Jan 2015 09:02:34 +0000 (12:02 +0300)
committersbh <sergey.belash@opencascade.com>
Tue, 27 Jan 2015 09:02:34 +0000 (12:02 +0300)
83 files changed:
doc/doxyfile.in
msvc10_env.bat
src/Config/Config_AttributeMessage.h
src/Config/Config_FeatureMessage.h
src/ConstructionPlugin/ConstructionPlugin_Plane.h
src/ConstructionPlugin/ConstructionPlugin_Plugin.h
src/Events/Events_Error.h
src/Events/Events_LongOp.h
src/Events/Events_Loop.h
src/Events/Events_MessageGroup.h
src/ExchangePlugin/ExchangePlugin_ImportFeature.h
src/ExchangePlugin/ExchangePlugin_Plugin.h
src/ExchangePlugin/ExchangePlugin_Validators.cpp
src/ExchangePlugin/ExchangePlugin_Validators.h
src/FeaturesPlugin/FeaturesPlugin_Boolean.h
src/FeaturesPlugin/FeaturesPlugin_Extrusion.h
src/FeaturesPlugin/FeaturesPlugin_Group.h
src/FeaturesPlugin/FeaturesPlugin_Placement.h
src/FeaturesPlugin/FeaturesPlugin_Plugin.h
src/GeomAPI/GeomAPI_DataMapOfShapeShape.cpp
src/GeomAPI/GeomAPI_DataMapOfShapeShape.h
src/GeomAPI/GeomAPI_ICustomPrs.h
src/GeomAPI/GeomAPI_PlanarEdges.h
src/GeomAPI/GeomAPI_Shape.h
src/GeomAlgoAPI/GeomAlgoAPI_Boolean.h
src/GeomAlgoAPI/GeomAlgoAPI_MakeShape.cpp
src/GeomAlgoAPI/GeomAlgoAPI_MakeShape.h
src/Model/CMakeLists.txt
src/Model/Model_Application.h
src/Model/Model_AttributeSelection.cpp
src/Model/Model_AttributeSelectionList.h
src/Model/Model_Data.h
src/Model/Model_Document.cpp
src/Model/Model_Document.h
src/Model/Model_Events.h
src/Model/Model_FeatureValidator.h
src/Model/Model_ResultBody.h
src/Model/Model_ResultConstruction.h
src/Model/Model_ResultGroup.h
src/Model/Model_ResultPart.h
src/Model/Model_Session.h
src/Model/Model_Validator.h
src/ModelAPI/ModelAPI_AttributeSelectionList.h
src/ModelAPI/ModelAPI_Data.h
src/ModelAPI/ModelAPI_Document.h
src/ModelAPI/ModelAPI_Events.h
src/ModelAPI/ModelAPI_Feature.h
src/ModelAPI/ModelAPI_FeatureValidator.h
src/ModelAPI/ModelAPI_Plugin.h
src/ModelAPI/ModelAPI_RefAttrValidator.h
src/ModelAPI/ModelAPI_ResultValidator.h
src/ModelAPI/ModelAPI_Session.h
src/ModuleBase/ModuleBase_DoubleSpinBox.cpp
src/ModuleBase/ModuleBase_DoubleSpinBox.h
src/ModuleBase/ModuleBase_Filter.h
src/ModuleBase/ModuleBase_FilterFace.h
src/ModuleBase/ModuleBase_FilterLinearEdge.h
src/ModuleBase/ModuleBase_FilterMulti.h
src/ModuleBase/ModuleBase_FilterNoConsructionSubShapes.h
src/ModuleBase/ModuleBase_FilterShapeType.h
src/ModuleBase/ModuleBase_IModule.h
src/ModuleBase/ModuleBase_IViewer.h
src/ModuleBase/ModuleBase_IWorkshop.h
src/ModuleBase/ModuleBase_OperationDescription.h
src/ModuleBase/ModuleBase_Preferences.h
src/ModuleBase/ModuleBase_SelectionValidator.h
src/ModuleBase/ModuleBase_ViewerFilters.h
src/ModuleBase/ModuleBase_WidgetDoubleValue.h
src/ModuleBase/ModuleBase_WidgetMultiSelector.h
src/ModuleBase/ModuleBase_WidgetShapeSelector.h
src/PartSetPlugin/PartSetPlugin_Plugin.h
src/SketchPlugin/SketchPlugin_Feature.h
src/SketchPlugin/SketchPlugin_Plugin.h
src/SketchPlugin/SketchPlugin_ResultValidators.h
src/SketchPlugin/SketchPlugin_Sketch.h
src/SketchPlugin/SketchPlugin_Validators.h
src/SketchSolver/SketchSolver_Constraint.cpp
src/SketchSolver/SketchSolver_Constraint.h
src/SketchSolver/SketchSolver_ConstraintGroup.cpp
src/SketchSolver/SketchSolver_ConstraintGroup.h
src/SketchSolver/SketchSolver_Solver.h
src/XGUI/XGUI_Displayer.h
src/XGUI/XGUI_Selection.h

index 5ca8b8a0da0f20053acf404b0197392b5437b56f..c44dbe6f01411a6fd6d061215e4326bb7af707fc 100644 (file)
@@ -861,7 +861,7 @@ VERBATIM_HEADERS       = YES
 # of all compounds will be generated. Enable this if the project
 # contains a lot of classes, structs, unions or interfaces.
 
-ALPHABETICAL_INDEX     = NO
+ALPHABETICAL_INDEX     = YES
 
 # If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then
 # the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns
index f5707a410c41f4d60803f03574684e7a87e8799d..cff0812ac22211ee37f597d4e42271e77a56a08d 100644 (file)
@@ -135,6 +135,13 @@ set PATH=%CMAKEDIR%\bin;%PATH%
 @SET PATH=%DOXYGEN_ROOT_DIR%\bin;%PATH%
 @REM -------------------------
 
+@REM -------------------------
+@REM GRAPHVIZ 
+@SET GRAPHVIZ_ROOT_DIR=%PDIR%\graphviz-2.38.0
+@SET GRAPHVIZHOME=%GRAPHVIZ_ROOT_DIR%
+@SET PATH=%GRAPHVIZ_ROOT_DIR%\bin;%PATH%
+@REM -------------------------
+
 @REM -------------------------
 @REM SUIT
 @SET SUIT_DIR=%PDIR%\suit
index 160efa7e85f84f88e27d28b2637e0762327a2c0d..9272a7b6ed3fd9f82d535d5a9fc2770f3f79e02f 100644 (file)
@@ -12,7 +12,9 @@
 /*!
  * \class Config_AttributeMessage
  * \brief Class to pass an attribute's (widget's) entry info extracted from xml file.
+ * \code
  * <widget id="tool_object" concealment="true" obligatory="0"/>
+ * \endcode
  */
 class Config_AttributeMessage : public Events_Message
 {
index f890f44c3f8f42f743e6774a0e996b126eb2d8ab..28ae49c3891681333db52dd166b13c5b0dc0b1f7 100644 (file)
@@ -12,7 +12,9 @@
  * \class Config_FeatureMessage\r
  * \brief Class to pass a feature entry extracted from xml file.\r
  * Example of the feature entry:\r
+ * \code\r
  * <feature id="Part" text="New part" tooltip="Creates a new part" icon=":pictures/part_ico.png"/>\r
+ * \endcode\r
  */\r
 class Config_FeatureMessage : public Events_Message\r
 {\r
index e58dd2ec4a4e76b7b297b5adc1bfc213d08b94b5..369f20586bf2d0aadd87700b2972d8bf20ba56b0 100644 (file)
@@ -20,9 +20,9 @@ const std::string FACE_ATTR = "planeFace";
 /// attribute name for distance
 const std::string DISTANCE_ATTR = "distance";
 
-/**\class ConstructionPlugin_Axis
+/**\class ConstructionPlugin_Plane
  * \ingroup DataModel
- * \brief Feature for creation of the new axis in PartSet.
+ * \brief Feature for creation of the new planar surface in PartSet.
  */
 class ConstructionPlugin_Plane : public ModelAPI_Feature, public GeomAPI_ICustomPrs
 {
index 39f2449fc5fad4e942953f8015801b66bc39d42c..a7ec72fc43e56b3ff5c4935d27ded5f7e2ad6403 100644 (file)
 #include "ModelAPI_Plugin.h"
 #include "ModelAPI_Feature.h"
 
+/**\class ConstructionPlugin_Plugin
+ * \ingroup Plugins
+ * \brief The main class for management the construction features as plugin.
+ */
 class CONSTRUCTIONPLUGIN_EXPORT ConstructionPlugin_Plugin : public ModelAPI_Plugin
 {
- public:
+public:
   /// Creates the feature object of this plugin by the feature string ID
   virtual FeaturePtr createFeature(std::string theFeatureID);
 
- public:
+  /// Default constructor
   ConstructionPlugin_Plugin();
 };
 
index d3222a28e1ffb5566d4d1a72761c86b283ba3108..561c987ce141be705eb03dc88f7b049babde742b 100644 (file)
 
 #include <string>
 
+/**\class Events_Error
+ * \ingroup EventsLoop
+ * \brief An error message event.
+ *
+ * Is generated by any algorithm or GUI of the application to inform the user about
+ * the problem. In GUI mode all such errors are collected in the message log window.
+ */
 class EVENTS_EXPORT Events_Error : public Events_Message
 {
   char* myDescription;  ///< pointer to the description of the error
 
- public:
+public:
+  /// default destructor   
   virtual ~Events_Error();
 
+  /// Identifier of this event (one for all errors)
   static Events_ID errorID();
+  /// Specific error string
   char* description() const;
+  /// Allows to send an error quickly: it creates and sends the error object automatically
   static void send(char* theDescription, const void* theSender = 0);
+  /// Allows to send an error quickly: it creates and sends the error object automatically
   static void send(std::string theDescription, const void* theSender = 0);
 
- protected:
+protected:
+  /// Default constructor. Use "send" message for generation an error.
   Events_Error(char* theDescription, const void* theSender = 0);
 };
 
index f8e5dd8f2b2ee22794a2a618a7ad61ad0dc815ff..c2e6c2e2eb02e24e2a91b46dc5b529df479712cb 100644 (file)
@@ -16,7 +16,8 @@
  */
 class EVENTS_EXPORT Events_LongOp : public Events_Message
 {
- public:
+public:
+  /// Default destructor
   virtual ~Events_LongOp();
   /// Returns the identifier of this event
   static Events_ID eventID();
@@ -27,7 +28,8 @@ class EVENTS_EXPORT Events_LongOp : public Events_Message
   /// Returns true if the long operation is performed
   static bool isPerformed();
 
- protected:
+protected:
+  /// Default constructor. Use "start" and "end" for generation.
   Events_LongOp(void* theSender = 0);
 };
 
index 669c56febbc72e3acf676608a38acb6643112ad5..a11426f1b99263f8581a0d4b5640c14db9167bd3 100644 (file)
@@ -16,7 +16,7 @@
 
 class Events_MessageGroup;
 
-/**\class Events_Lopp
+/**\class Events_Loop
  * \ingroup EventsLoop
  * \brief Base class that manages the receiving and sending of all
  * not Qt-events in the application.
@@ -54,6 +54,7 @@ class Events_Loop
   EVENTS_EXPORT static Events_ID eventByName(const char* theName);
 
   //! Allows to send an event
+  //! \param theMessage the enevt message to send
   //! \param isGroup is true for grouping messages if possible
   EVENTS_EXPORT void send(const std::shared_ptr<Events_Message>& theMessage, bool isGroup = true);
 
index 146f5d3bca199d0353af601d964f68ef7b0d27c3..a2aa26084a5797bb0fe0c0298b6d2bc515b34b4e 100644 (file)
@@ -10,7 +10,7 @@
 #include <Events_Message.h>
 #include <memory>
 
-/**\class Events_Message
+/**\class Events_MessageGroup
  * \ingroup EventsLoop
  * \brief Message that allows to group messages and send them later as a group of messages.
  *
index f62fee937663c61eb31e5f33a126e04d93f2b726..24bd6964f503b3fdb5d0b6a5db912082f10f52b3 100644 (file)
@@ -8,6 +8,12 @@
 
 #include <map>
 
+/**\class ExchangePlugin_ImportFeature
+ * \ingroup Plugins
+ * \brief Feature for import shapes from the external files in CAD formats.
+ *
+ * The set of supported formats is defined in the configuration file.
+ */
 class ExchangePlugin_ImportFeature : public ModelAPI_Feature
 {
  public:
@@ -23,8 +29,9 @@ class ExchangePlugin_ImportFeature : public ModelAPI_Feature
     static const std::string MY_FILE_PATH_ID("import_file_selector");
     return MY_FILE_PATH_ID;
   }
-
+  /// default constructor
   EXCHANGEPLUGIN_EXPORT ExchangePlugin_ImportFeature();
+  /// default destructor
   EXCHANGEPLUGIN_EXPORT virtual ~ExchangePlugin_ImportFeature();
 
   /// Returns the unique kind of a feature
@@ -42,6 +49,7 @@ class ExchangePlugin_ImportFeature : public ModelAPI_Feature
   }
 
  protected:
+  /// POerforms the import of the file
   EXCHANGEPLUGIN_EXPORT bool importFile(const std::string& theFileName);
 
 private:
index 89531bd8a225a3dccf26d764875132f95f592a3d..97e1534c713424ed665b76eca29e403bf84b885d 100644 (file)
 #include <ModelAPI_Plugin.h>
 #include <ModelAPI_Feature.h>
 
+/**\class ExchangePlugin_Plugin
+ * \ingroup Plugins
+ * \brief The main class for management the import and export operations as plugin.
+ */
 class EXCHANGEPLUGIN_EXPORT ExchangePlugin_Plugin : public ModelAPI_Plugin
 {
  public:
index e708041a8f7e034bc342fa8ddb0706b56ec85e91..c001a0c3f41585bd42416e2b7ca68ec4822807d3 100644 (file)
@@ -33,23 +33,6 @@ bool ExchangePlugin_ImportFormatValidator::parseFormats(const std::list<std::str
   return result;
 }
 
-bool ExchangePlugin_ImportFormatValidator::parsePlugins(const std::list<std::string>& theArguments,
-                                                        std::list<std::string>& outPlugins)
-{
-  std::list<std::string>::const_iterator it = theArguments.begin();
-  bool result = true;
-  for (; it != theArguments.end(); ++it) {
-    std::string anArg = *it;
-    int aSepPos = anArg.find(":");
-    if (aSepPos == std::string::npos) {
-      result = false;
-      continue;
-    }
-    outPlugins.push_back(anArg.substr(aSepPos + 1));
-  }
-  return result;
-}
-
 bool ExchangePlugin_ImportFormatValidator::isValid(const AttributePtr& theAttribute,
                                                    const std::list<std::string>& theArguments) const
 {
index 1e93f95accb8c8d164b6882b3bedbcbeb4e42961..f8db19fc21857ae0e17ecea369e868b4340d7b93 100644 (file)
 #include "ExchangePlugin.h"
 #include <ModelAPI_AttributeValidator.h>
 
+/**\class ExchangePlugin_ImportFormatValidator
+ * \ingroup Validators
+ * \brief Validator for the imported formats checking
+ *
+ * The configuration file of import/export features contains the information
+ * about which formats are supported and the extension of the associated files.
+ * This validator filters out files that are out of this description.
+ */
 class ExchangePlugin_ImportFormatValidator : public ModelAPI_AttributeValidator
 {
-  /*
+  /**
    * Parses input arguments "BREP:BREPImport", "STEP:STEPImport"
    * into list of file formats "BREP","STEP"
    * and list of corresponding plugins: "BREPImport", "STEPImport"
    */
   static bool parseFormats(const std::list<std::string>& theArguments,
                              std::list<std::string>& outFormats);
-  static bool parsePlugins(const std::list<std::string>& theArguments,
-                           std::list<std::string>& outPlugins);
- public:
+public:
+  /**
+   * Returns true is the file-name attribute correctly corresponds to the set of
+   * allowed formats.
+   */
   virtual bool isValid(const AttributePtr& theAttribute,
                        const std::list<std::string>& theArguments) const;
 
index 824dcd0dbb5dd787032974c50c93f6c0b95dde69..65ad15d2e99f2ba424a3ebb50e75681d613d8713 100644 (file)
 #include <GeomAPI_Shape.h>
 #include <GeomAlgoAPI_Boolean.h>
 
+/**\class FeaturesPlugin_Boolean
+ * \ingroup Plugins
+ * \brief Feature for applying of Boolean operations on Solids.
+ *
+ * Supports three kinds of Boolean operations: Cut, Fuse and Common.
+ * For all of them requires two Solids: object and tool.
+ */
 class FeaturesPlugin_Boolean : public ModelAPI_Feature
 {
- public:
+public:
   /// Extrusion kind
   inline static const std::string& ID()
   {
@@ -46,7 +53,6 @@ class FeaturesPlugin_Boolean : public ModelAPI_Feature
     BOOL_COMMON
   };
 
-
   /// Returns the kind of a feature
   FEATURESPLUGIN_EXPORT virtual const std::string& getKind()
   {
index 8199fcb2e131bdb039f368f6eba5d55bab2a14a6..bbc636c9251fdda8b8d7a64f0f654dfe6dfbd92a 100644 (file)
 #include <ModelAPI_ResultBody.h>
 #include <GeomAlgoAPI_Extrusion.h>
 #include <GeomAPI_Shape.h>
+
+/**\class FeaturesPlugin_Extrusion
+ * \ingroup Plugins
+ * \brief Feature for creation of extrusion from the planar face.
+ *
+ * Extrusion creates the lateral faces based on edges of the base face and
+ * the top face equal to the base face. Direction of extrusion is taken from the face
+ * plane, but can be corrected by the "reverse" flag.
+ */
 class FeaturesPlugin_Extrusion : public ModelAPI_Feature
 {
  public:
index e859d5e89b562a99f87cce07d3dbe053a22143ef..50f82339a359872d68b1867a1c59ed9a22c7ea83 100644 (file)
 #include <ModelAPI_Feature.h>
 #include <GeomAPI_Shape.h>
 
+/**\class FeaturesPlugin_Group
+ * \ingroup Plugins
+ * \brief Feature for selection of sub-shapes of some shapes.
+ *
+ * All selected sub-shapes must be of equal type (vertex, edge, face, etc) but may
+ * be selected on different objects.
+ */
 class FeaturesPlugin_Group : public ModelAPI_Feature
 {
  public:
@@ -20,12 +27,6 @@ class FeaturesPlugin_Group : public ModelAPI_Feature
     static const std::string MY_GROUP_ID("Group");
     return MY_GROUP_ID;
   }
-  /// attribute name of group name
-  //inline static const std::string& NAME_ID()
-  //{
-  //  static const std::string MY_GROUP_NAME_ID("group_name");
-  //  return MY_GROUP_NAME_ID;
-  //}
   /// attribute name of selected entities list
   inline static const std::string& LIST_ID()
   {
index 3cfd358874a21a7d361df35dbe086aae70c3206b..e96541de32bf43b44a7b147077f6d97ac611a45a 100644 (file)
 class ModelAPI_ResultBody;
 class GeomAPI_Shape;
 
+/**\class FeaturesPlugin_Placement
+ * \ingroup Plugins
+ * \brief Feature for applying of placement operation: relative movement of Solid.
+ *
+ * Locates the selected attractable_face of the solid in the middle of the selected
+ * placement_base face. Faces must be planar. Orientation of the placed solid is
+ * depended on the underlied planes of both faces.
+ */
 class FeaturesPlugin_Placement : public ModelAPI_Feature
 {
  public:
index 651de9badeffa4e5ee1b4fc61f873d9b7fa248f1..64750feedaf1df11a72a73afae4a0baa0dd459dc 100644 (file)
 #include <ModelAPI_Plugin.h>
 #include <ModelAPI_Feature.h>
 
+/**\class FeaturesPlugin_Plugin
+ * \ingroup Plugins
+ * \brief The main class for management the 3D features as plugin.
+ */
 class FEATURESPLUGIN_EXPORT FeaturesPlugin_Plugin : public ModelAPI_Plugin
 {
  public:
@@ -18,6 +22,7 @@ class FEATURESPLUGIN_EXPORT FeaturesPlugin_Plugin : public ModelAPI_Plugin
   virtual FeaturePtr createFeature(std::string theFeatureID);
 
  public:
+  /// Default constructor
   FeaturesPlugin_Plugin();
 };
 
index c42ef1562edac8a5ea29487a597c983ba77c68ba..97e3f10683127f11da42d3fe25b3b18ba3540267 100644 (file)
@@ -14,19 +14,16 @@ using namespace std;
 GeomAPI_DataMapOfShapeShape::GeomAPI_DataMapOfShapeShape()
        :GeomAPI_Interface((void *)new TopTools_DataMapOfShapeShape){}
 
-/// Clear 
 void GeomAPI_DataMapOfShapeShape::clear()
 {
   implPtr<TopTools_DataMapOfShapeShape>()->Clear();
 }
 
-/// Size 
 int GeomAPI_DataMapOfShapeShape::size()
 {
   return implPtr<TopTools_DataMapOfShapeShape>()->Extent();
 }
 
-/// Adds the Key <K> to  the Map <me>  with  the  Item. Returns True  if the Key  was not already in the map
 bool GeomAPI_DataMapOfShapeShape::bind (std::shared_ptr<GeomAPI_Shape> theKey, std::shared_ptr<GeomAPI_Shape> theItem)
 {
   bool flag(false);
@@ -35,7 +32,6 @@ bool GeomAPI_DataMapOfShapeShape::bind (std::shared_ptr<GeomAPI_Shape> theKey, s
   return flag;
 }
 
-/// Returns true if theKey is stored  in the map.
 bool GeomAPI_DataMapOfShapeShape::isBound (std::shared_ptr<GeomAPI_Shape> theKey)
 {
   bool flag(false);
@@ -44,7 +40,6 @@ bool GeomAPI_DataMapOfShapeShape::isBound (std::shared_ptr<GeomAPI_Shape> theKey
   return flag;
 }
 
-/// Returns  the Item stored  with the Key in the Map. To be checked before with isBound()
 const std::shared_ptr<GeomAPI_Shape> GeomAPI_DataMapOfShapeShape::find(std::shared_ptr<GeomAPI_Shape> theKey)
 {
   std::shared_ptr<GeomAPI_Shape> aShape(new GeomAPI_Shape());  
@@ -52,7 +47,6 @@ const std::shared_ptr<GeomAPI_Shape> GeomAPI_DataMapOfShapeShape::find(std::shar
   return aShape;
 }  
   
-/// Removes the Key from the  map. Returns true if the Key was in the Map
 bool GeomAPI_DataMapOfShapeShape::unBind(std::shared_ptr<GeomAPI_Shape> theKey)
 {
   bool flag(false);
index 40c447baed4d31ff5d5c083391ca584a90b4d50e..24d3db14ed4562770f69ef54a0cd510683c1826a 100644 (file)
@@ -17,7 +17,6 @@ class GeomAPI_Dir;
  * \ingroup DataModel
  * \brief DataMap of Shape - Shape defined by TopoDS_Shapes
  */
-
 class GEOMAPI_EXPORT GeomAPI_DataMapOfShapeShape : public GeomAPI_Interface
 {
  public:
@@ -30,7 +29,7 @@ class GEOMAPI_EXPORT GeomAPI_DataMapOfShapeShape : public GeomAPI_Interface
   /// Size of the map
   int size();
 
-  /// Adds the Key <K> to  the Map <me>  with  the  Item. Returns True  if the Key  was not already in the map
+  /// Adds \a theKey to me with \a theItem. Returns True if the Key  was not already in the map
   bool bind (std::shared_ptr<GeomAPI_Shape> theKey, std::shared_ptr<GeomAPI_Shape> theItem);
 
   /// Returns true if theKey is stored  in the map.
index c398a33bce83e204803d9bfc3fa7dd6bfbba7e80..cbed444b76919614476c2d0ea53f5a0068926f26 100644 (file)
@@ -16,6 +16,7 @@
 class GeomAPI_ICustomPrs
 {
 public:
+  /// Modifies the given presentation in the custom way.
   virtual void customisePresentation(AISObjectPtr thePrs) = 0;
 };
 
index a9cd54a31679cd0453b185caa936f52235f6b06d..627bc5d719cfded780ee8c181ba13a29d18103c2 100644 (file)
 
 /**\class GeomAPI_PlanarEdges
  * \ingroup DataModel
- * \brief Interface to the edge object
+ * \brief Interface to the set of edges located in one plane
+ *
+ * Normally this interface corresponds to theedges of the sketch
  */
-
 class GeomAPI_PlanarEdges : public GeomAPI_Shape
 {
  public:
   /// Creation of empty (null) shape
   GEOMAPI_EXPORT GeomAPI_PlanarEdges();
 
+  /// Returns whether the shape is alone vertex
   GEOMAPI_EXPORT virtual bool isVertex() const;
 
-  /// Returns whether the shape is an edge
+  /// Returns whether the shape is alone edge
   GEOMAPI_EXPORT virtual bool isEdge() const;
-
+  /// Appends the edge to the set
   GEOMAPI_EXPORT void addEdge(std::shared_ptr<GeomAPI_Shape> theEdge);
+  /// Returns the list of edges in this interface
   GEOMAPI_EXPORT std::list<std::shared_ptr<GeomAPI_Shape> > getEdges();
 
   /// Returns True if the wire is defined in a plane
   GEOMAPI_EXPORT bool hasPlane() const;
 
-  /// Set/Get origin point
+  /// Sets origin point
   GEOMAPI_EXPORT void setOrigin(const std::shared_ptr<GeomAPI_Pnt>& theOrigin);
 
+  /// Returns the plane origin point
   GEOMAPI_EXPORT std::shared_ptr<GeomAPI_Pnt> origin() const;
 
-  /// Set/Get X direction vector
+  /// Sets X direction vector
   GEOMAPI_EXPORT void setDirX(const std::shared_ptr<GeomAPI_Dir>& theDirX);
+  /// Returns X direction vector
   GEOMAPI_EXPORT std::shared_ptr<GeomAPI_Dir> dirX() const;
 
-  /// Set/Get Y direction vector
+  /// Sets Y direction vector
   GEOMAPI_EXPORT void setDirY(const std::shared_ptr<GeomAPI_Dir>& theDirY);
+  /// Returns Y direction vector
   GEOMAPI_EXPORT std::shared_ptr<GeomAPI_Dir> dirY() const;
 
-  /// Set/Get Normal direction vector
+  /// Sets Z direction vector
   GEOMAPI_EXPORT void setNorm(const std::shared_ptr<GeomAPI_Dir>& theNorm);
+  /// Returns Z direction vector
   GEOMAPI_EXPORT std::shared_ptr<GeomAPI_Dir> norm() const;
 
 private:
+  /// Origin point of the plane
   std::shared_ptr<GeomAPI_Pnt> myOrigin;
+  /// The X direction inside of the plane
   std::shared_ptr<GeomAPI_Dir> myDirX;
+  /// The Y direction inside of the plane
   std::shared_ptr<GeomAPI_Dir> myDirY;
+  /// The normal direction to the plane
   std::shared_ptr<GeomAPI_Dir> myNorm;
 };
 
index 8ff96d9815ca5e00c3e93ed1d2dc5e2b201a6100..8e2c22f9a41afe72addb07b7cb9c353fb3cf69b7 100644 (file)
@@ -21,6 +21,7 @@ class GEOMAPI_EXPORT GeomAPI_Shape : public GeomAPI_Interface
   /// Creation of empty (null) shape
   GeomAPI_Shape();
 
+  /// Returns true if the underlied shape is null
   bool isNull() const;
 
   /// Returns whether the shapes are equal
@@ -40,6 +41,7 @@ class GEOMAPI_EXPORT GeomAPI_Shape : public GeomAPI_Interface
   bool computeSize(double& theXmin, double& theYmin, double& theZmin,
                    double& theXmax, double& theYmax, double& theZmax) const;
 
+  /// Returns the shape as BRep stream
   std::string getShapeStream() const;
 };
 
index ac7b267d0eb4f4c0aba8c772c45b7b5c63d32799..a8a5659de8ea2470759c9cd481f87936663de983 100644 (file)
 class GeomAlgoAPI_Boolean : public GeomAPI_Interface
 {
  public:
-  /* \brief Creates cut boolean operation
+  /**\brief Creates cut boolean operation
    * \param[in] theShape the main shape
    * \param[in] theTool  toole shape for boolean
    * \return a solid as result of operation
    */
   GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> makeCut(
                                                  std::shared_ptr<GeomAPI_Shape> theShape,
-                                              std::shared_ptr<GeomAPI_Shape> theTool);
+                                            std::shared_ptr<GeomAPI_Shape> theTool);
 
-  /* \brief Creates fuse boolean operation
+  /**\brief Creates fuse boolean operation
    * \param[in] theShape the main shape
    * \param[in] theTool  second shape
    * \return a solid as result of operation
@@ -38,10 +38,9 @@ class GeomAlgoAPI_Boolean : public GeomAPI_Interface
                                                  std::shared_ptr<GeomAPI_Shape> theShape,
                                               std::shared_ptr<GeomAPI_Shape> theTool);
 
-  /* \brief Creates common boolean operation
+  /**\brief Creates common boolean operation
    * \param[in] theObject the main shape
    * \param[in] theTool  second shape
-   * \param[in] theType  type of the operation: Fuse, Cut, Common
    * \return a solid as result of operation
    */
   GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> makeCommon(
index f28779de5f60f244d5c41124d2541b00fdeefcbf..4682f1fb0c760213ab57f52b24533b17ac25abe7 100644 (file)
@@ -27,7 +27,6 @@ const std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_MakeShape::shape() const
   return myShape;
 }
 
-/// Returns the  list   of shapes generated   from the shape <theShape>
 void GeomAlgoAPI_MakeShape::generated(
   const std::shared_ptr<GeomAPI_Shape> theShape, ListOfShape& theHistory)
 {
@@ -43,7 +42,6 @@ void GeomAlgoAPI_MakeShape::generated(
   }
 }
 
-/// Returns the  list   of shapes modified   from the shape <theShape>
 void GeomAlgoAPI_MakeShape::modified(
   const std::shared_ptr<GeomAPI_Shape> theShape, ListOfShape& theHistory)
 {
@@ -59,7 +57,6 @@ void GeomAlgoAPI_MakeShape::modified(
   }
 }
 
-/// Returns whether the shape is an edge
 bool GeomAlgoAPI_MakeShape::isDeleted(const std::shared_ptr<GeomAPI_Shape> theShape)
 {
   bool isDeleted(false);
index 25812634c1324b30302cc280d47df2eb1ae937ec..4082464af400eb496fead480e3019ab41d59aa2e 100644 (file)
@@ -9,36 +9,37 @@
 #include <GeomAPI_Shape.h>
 #include <memory>
 #include <GeomAlgoAPI.h>
-//#include <BRepBuilderAPI_MakeShape.hxx>
+
 /**\class GeomAlgoAPI_MakeShape
  * \ingroup DataModel
  * \brief Interface to the root class of all topological shapes constructions
  */
 class GeomAlgoAPI_MakeShape : public GeomAPI_Interface
 {
- public:
-   /// Constructor
+public:
+  /// Constructor
   GEOMALGOAPI_EXPORT GeomAlgoAPI_MakeShape();
-
+  /// Constructor by the already stored builder in the interface
   GEOMALGOAPI_EXPORT GeomAlgoAPI_MakeShape(void* theBuilder);
 
   /// Returns a shape built by the shape construction algorithm
   GEOMALGOAPI_EXPORT const std::shared_ptr<GeomAPI_Shape>  shape() const;
 
-  /// Returns the  list   of shapes generated   from the shape <theShape>
+  /// Returns the list of shapes generated from the shape \a theShape
   GEOMALGOAPI_EXPORT virtual void generated(
     const std::shared_ptr<GeomAPI_Shape> theShape, ListOfShape& theHistory);
 
-  /// Returns the  list   of shapes modified   from the shape <theShape>
+  /// Returns the  list of shapes modified from the shape \a theShape
   GEOMALGOAPI_EXPORT virtual void modified(
     const std::shared_ptr<GeomAPI_Shape> theShape, ListOfShape& theHistory);
 
   /// Returns whether the shape is an edge
   GEOMALGOAPI_EXPORT virtual bool isDeleted(const std::shared_ptr<GeomAPI_Shape> theShape);
-
+  /// Initializes the algorithm by the builder stored in the interface
   GEOMALGOAPI_EXPORT void init(void* theMkShape);
 
   protected:
+  /// The resulting shape
        std::shared_ptr<GeomAPI_Shape> myShape;
 };
 
index 379fc69afe1c6f9f664f729f6b77b5fb352b33e3..4865602acdf89002d21df797244afb7402ac605c 100644 (file)
@@ -69,7 +69,7 @@ SET(PROJECT_LIBRARIES
 
 
 ADD_DEFINITIONS(-DMODEL_EXPORTS ${CAS_DEFINITIONS})
-ADD_LIBRARY(Model MODULE ${PROJECT_SOURCES} ${PROJECT_HEADERS})
+ADD_LIBRARY(Model SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS})
 TARGET_LINK_LIBRARIES(Model ${PROJECT_LIBRARIES})
 
 INCLUDE_DIRECTORIES(
index d1156b2844e80a7daacbfd107b9299bfe8d1da73..b5a2af8e026ccc1adab9b76a03289f23f49e0cbf 100644 (file)
@@ -18,17 +18,19 @@ DEFINE_STANDARD_HANDLE(Model_Application, TDocStd_Application)
 /**\class Model_Application
  * \ingroup DataModel
  * \brief Realization of Open CASCADE application abstraction. Class for internal use only.
+ *
  * Application supports the formats and document management. It is uses OCAF-lke
  * architecture and just implements specific features of the module.
  */
 class Model_Application : public TDocStd_Application
 {
- public:
+public:
   // useful methods inside of the module
 
   // CASCADE RTTI
-  DEFINE_STANDARD_RTTI(Model_Application)
-  ;
+  /// Definition of "Handles" usage
+  /// \param Model_Application is the class name that is covered by the OCCT Handle
+  DEFINE_STANDARD_RTTI(Model_Application);
 
   //! Retuns the application: one per process    
   MODEL_EXPORT static Handle_Model_Application getApplication();
index 33d1b25f5302f26d72bf60d2da27c8e19fbb2710..418cce2f2c9c616d0484a0c77e6ad3fe97bbe8cc 100644 (file)
@@ -192,7 +192,7 @@ bool Model_AttributeSelection::update()
   if (aContext->groupName() == ModelAPI_ResultBody::group()) {
     // body: just a named shape, use selection mechanism from OCCT
     TNaming_Selector aSelector(aSelLab);
-    bool aResult = aSelector.Solve(scope()) == Standard_True;
+    bool aResult = true;//aSelector.Solve(scope()) == Standard_True;
     owner()->data()->sendAttributeUpdated(this);
     return aResult;
   } else if (aContext->groupName() == ModelAPI_ResultConstruction::group()) {
index fdae79ee6a9c7b73b3d1ebf4bb978d15b246b794..eacc518c6bc8ecbcc0f8bf11b5bd1902ffeb4614 100644 (file)
@@ -36,9 +36,13 @@ public:
   /// Returns the number ofselection attributes in the list
   MODEL_EXPORT virtual int size();
 
+  /// The type of all elements selection
+  /// \returns the index of the OCCT enumeration of the type of shape
   MODEL_EXPORT virtual int selectionType();
 
-  MODEL_EXPORT virtual void setSelectionType(int);
+  /// Sets the type of all elements selection
+  /// \param theType the index of the OCCT enumeration of the type of shape
+  MODEL_EXPORT virtual void setSelectionType(int theType);
 
   /// Returns the attribute selection by the index (zero based)
   MODEL_EXPORT virtual std::shared_ptr<ModelAPI_AttributeSelection> value(const int theIndex);
index e8ddf546dae72bc56a31d781eb5532a361c57b37..6604e86e8a246dfce43bccf065e6944fb5637dfc 100644 (file)
@@ -161,16 +161,16 @@ class Model_Data : public ModelAPI_Data
   /// Returns the identifier of feature-owner, unique in this document
   MODEL_EXPORT virtual int featureId() const;
 
-  // returns all objects referenced to this
+  /// returns all objects referenced to this
   MODEL_EXPORT virtual const std::set<AttributePtr>& refsToMe() {return myRefsToMe;}
 
-  // returns all references by attributes of this data
-  // \param theRefs returned list of pairs: id of referenced attribute and list of referenced objects
+  /// returns all references by attributes of this data
+  /// \param theRefs returned list of pairs: id of referenced attribute and list of referenced objects
   MODEL_EXPORT virtual void referencesToObjects(
     std::list<std::pair<std::string, std::list<ObjectPtr> > >& theRefs);
 
 private:
-  // removes all information about back references
+  /// removes all information about back references
   void eraseBackReferences();
   // adds a back reference (with identifier which attribute references to this object
   void addBackReference(FeaturePtr theFeature, std::string theAttrID);
index 3efd64be7ee7be75491a628bf3790a68150f4d59..680b7fd3ed6354db2a17bb0ae5a97d30213f1648 100644 (file)
@@ -250,8 +250,7 @@ void Model_Document::close(const bool theForever)
     subDoc(*aSubIter)->close(theForever);
 
   // close for thid document needs no transaction in this document
-  if (this == aPM->moduleDocument().get())
-    std::static_pointer_cast<Model_Session>(Model_Session::get())->setCheckTransactions(false);
+  std::static_pointer_cast<Model_Session>(Model_Session::get())->setCheckTransactions(false);
 
   // delete all features of this document
   std::shared_ptr<ModelAPI_Document> aThis = 
@@ -282,8 +281,7 @@ void Model_Document::close(const bool theForever)
       myDoc->Close();
   }
 
-  if (this == aPM->moduleDocument().get())
-    std::static_pointer_cast<Model_Session>(Model_Session::get())->setCheckTransactions(true);
+  std::static_pointer_cast<Model_Session>(Model_Session::get())->setCheckTransactions(true);
 }
 
 void Model_Document::startOperation()
index 56490a15c337b60a825b729215da58567411df97..f57349d7e19a77802835904792fa6fc4ce60cd60 100644 (file)
@@ -40,7 +40,6 @@ class Model_Document : public ModelAPI_Document
 
   //! Loads the OCAF document from the file.
   //! \param theFileName full name of the file to load
-  //! \param theStudyID identifier of the SALOME study to associate with loaded file
   //! \returns true if file was loaded successfully
   MODEL_EXPORT virtual bool load(const char* theFileName);
 
@@ -76,10 +75,11 @@ class Model_Document : public ModelAPI_Document
   MODEL_EXPORT virtual void redo();
 
   //! Adds to the document the new feature of the given feature id
-  //! \param creates feature and puts it in the document
+  //! \param theID creates feature and puts it in the document
   MODEL_EXPORT virtual FeaturePtr addFeature(std::string theID);
 
   //! Removes the feature from the document (with result)
+  //! \param theFeature the feature to be removed
   //! \param theCheck if it is false, do not check the references
   MODEL_EXPORT virtual void removeFeature(FeaturePtr theFeature, const bool theCheck = true);
 
@@ -106,7 +106,6 @@ class Model_Document : public ModelAPI_Document
   //! Returns the feature in the group by the index (started from zero)
   //! \param theGroupID group that contains a feature
   //! \param theIndex zero-based index of feature in the group
-  //! \param isOperation if it is true, returns feature (not Object)
   //! \param theHidden if it is true, it counts also the features that are not in tree
   MODEL_EXPORT virtual ObjectPtr object(const std::string& theGroupID, const int theIndex,
                                         const bool theHidden = false);
@@ -163,6 +162,7 @@ class Model_Document : public ModelAPI_Document
   //! Creates new document with binary file format
   Model_Document(const std::string theID, const std::string theKind);
 
+  //! Returns the internal OCCT document of this interface
   Handle_TDocStd_Document document()
   {
     return myDoc;
index 6c492c1ca3a3f1eff6ac8d4fe5e3862e7bfcea38..d52e7f8caea85a062109f2f4defdc5798b3e1d46 100644 (file)
@@ -73,10 +73,13 @@ class Model_ObjectDeletedMessage : public ModelAPI_ObjectDeletedMessage
     return myGroups;
   }
 
+  /// Returns the new empty message of this type
   virtual std::shared_ptr<Events_MessageGroup> newEmpty();
 
+  /// Returns the identifier of this message
   virtual const Events_ID messageId();
 
+  /// Appends to this message the given one
   virtual void Join(const std::shared_ptr<Events_MessageGroup>& theJoined);
 };
 
index 86f287c99460cf08dfe963efb05b60f8fad6cd69..e412301fec5dfbad8cda15b775f6c0f397eb7632 100644 (file)
 #include <set>
 #include <map>
 
+/**\class Model_FeatureValidator
+ * \ingroup DataModel
+ * \brief The geneneric validator for the whole feature.
+ *
+ * Can be redefined for some specific feature, but by default for each feature this validator is
+ * used: it checks each argument of the feature and if one of it is not valid (and obligatory),
+ * the hole feature is invalid.
+ */
 class Model_FeatureValidator : public ModelAPI_FeatureValidator
 {
   // not obligatory attributes, not checked for initialization
   std::map<std::string, std::set<std::string> > myNotObligatory;
- public:
+public:
   /// Returns true if feature and/or attributes are valid
   /// \param theFeature the validated feature
+  /// \param theArguments the arguments in the configuration file for this validator
+  /// \returns true if feature is valid
   MODEL_EXPORT virtual bool isValid(const std::shared_ptr<ModelAPI_Feature>& theFeature,
     const std::list<std::string>& theArguments) const;
 
-  // sets not obligatory attributes, not checked for initialization
+  /// sets not obligatory attributes, not checked for initialization
   virtual void registerNotObligatory(std::string theFeature, std::string theAttribute);
 
   /// Returns true if the attribute in feature is not obligatory for the feature execution
index 8da264eec6f52ea54597172c561a3715ec7ad9c3..f4fbb7b1f36feaccf10aa9ad5ef8dae5d996efa4 100644 (file)
@@ -15,7 +15,7 @@
 
 class TNaming_Builder;
 
-/**\class ModelAPI_ResultBody
+/**\class Model_ResultBody
  * \ingroup DataModel
  * \brief The body (shape) result of a feature.
  *
index fa7e3f1aad99e3faa3e173584e6a1851ef5c57b5..a66aeeb5a73eccebf1883dca7f04715774d5174b 100644 (file)
@@ -10,7 +10,7 @@
 #include "Model.h"
 #include <ModelAPI_ResultConstruction.h>
 
-/**\class ModelAPI_ResultConstruction
+/**\class Model_ResultConstruction
  * \ingroup DataModel
  * \brief The construction element result of a feature.
  *
index 46a453de348b2f92fe2d495eabc5eb4dec269235..33b4351c9ac3e59bd7527528d6b8d5a0d6490272 100644 (file)
@@ -10,7 +10,7 @@
 #include "Model.h"
 #include <ModelAPI_ResultGroup.h>
 
-/**\class ModelAPI_ResultGroup
+/**\class Model_ResultGroup
  * \ingroup DataModel
  * \brief The groups result.
  *
index 8397a9766969df1b7f1561410ff00dd7ee34717b..cda7bf6cd5f25a290116d6a99ce03f042d353243 100644 (file)
@@ -10,7 +10,7 @@
 #include "Model.h"
 #include <ModelAPI_ResultPart.h>
 
-/**\class ModelAPI_ResultPart
+/**\class Model_ResultPart
  * \ingroup DataModel
  * \brief The Part document, result of a creation of new part feature.
  *
index 19172f3877389cb708f750595acd544f1d353b6e..fa94b8aae8588b8153a7086aff2d0a4c3c5879e3 100644 (file)
@@ -35,7 +35,6 @@ class Model_Session : public ModelAPI_Session, public Events_Listener
 
   //! Loads the OCAF document from the file.
   //! \param theFileName full name of the file to load
-  //! \param theStudyID identifier of the SALOME study to associate with loaded file
   //! \returns true if file was loaded successfully
   MODEL_EXPORT virtual bool load(const char* theFileName);
 
@@ -102,6 +101,7 @@ class Model_Session : public ModelAPI_Session, public Events_Listener
   /// Returns the validators factory: the only one instance per application
   MODEL_EXPORT virtual ModelAPI_ValidatorsFactory* validators();
 
+  /// Sets the flag to check modifications outside the transaction or not
   void setCheckTransactions(const bool theCheck)
   {
     myCheckTransactions = theCheck;
index cab877163a4fa18bb647537eff8be239f34614d9..4747c534ba87a7711b7ae1125058ff2ab35e1131 100644 (file)
@@ -89,6 +89,7 @@ class Model_ValidatorsFactory : public ModelAPI_ValidatorsFactory
   virtual bool isConcealed(std::string theFeature, std::string theAttribute);
 
 protected:
+  /// Adds the defualt validators that are usefull for all features.
   void addDefaultValidators(std::list<ModelAPI_Validator*>& theValidators,
                             std::list<std::list<std::string> >& theArguments) const;
   /// Get instance from Session
index 7bb04753a250ec21c3b2a6339738f74761b11bba..cc8077e325bfa221c9c0d58aefa784fd53a8c236 100644 (file)
@@ -30,9 +30,13 @@ class ModelAPI_AttributeSelectionList : public ModelAPI_Attribute
   /// Returns the number ofselection attributes in the list
   virtual int size() = 0;
 
+  /// The type of all elements selection
+  /// \returns the index of the enumeration of the type of shape
   virtual int selectionType() = 0;
 
-  virtual void setSelectionType(int) = 0;
+  /// Sets the type of all elements selection
+  /// \param theType the index of the enumeration of the type of shape
+  virtual void setSelectionType(int theType) = 0;
 
   /// Returns the attribute selection by the index (zero based)
   virtual std::shared_ptr<ModelAPI_AttributeSelection> value(const int theIndex) = 0;
index f982581de10bcff128dbcbfa270310320ed6a9d9..bb532ce08bc51bb56e97357cceae56636489f3af 100644 (file)
@@ -124,11 +124,11 @@ class MODELAPI_EXPORT ModelAPI_Data
   /// Returns the identifier of feature-owner, unique in this document
   virtual int featureId() const = 0;
 
- // returns all objects referenced to this
 /// returns all objects referenced to this
   virtual const std::set<std::shared_ptr<ModelAPI_Attribute> >& refsToMe() = 0;
 
-  // returns all references by attributes of this data
-  // \param theRefs returned list of pairs: id of referenced attribute and list of referenced objects
+  /// returns all references by attributes of this data
+  /// \param theRefs returned list of pairs: id of referenced attribute and list of referenced objects
   virtual void referencesToObjects(
     std::list<std::pair<std::string, std::list<std::shared_ptr<ModelAPI_Object> > > >& theRefs) = 0;
  protected:
index b0aabbec3569713383e07dbe439f5aecde2b6013..d6a7ce0bf07baa7561d851a3f0370338b51d76af 100644 (file)
@@ -22,7 +22,7 @@ class ModelAPI_ResultPart;
 class ModelAPI_ResultGroup;
 class ModelAPI_Data;
 
-/**\class Model_Document
+/**\class ModelAPI_Document
  * \ingroup DataModel
  * \brief Document for internal data structure of any object storage.
  * Document contains all data that must be stored/retrived in the file.
@@ -41,7 +41,7 @@ public:
   virtual void close(const bool theForever = false) = 0;
 
   //! Adds to the document the new feature of the given feature id
-  //! \param creates feature and puts it in the document (if it is not action)
+  //! \param theID creates feature and puts it in the document (if it is not action)
   virtual std::shared_ptr<ModelAPI_Feature> addFeature(std::string theID) = 0;
 
   //! Removes the feature from the document
index 9876e616a863ee3819af26cab49aa866bfc28e7b..fb332baff0c5ce0a2b8a9d66e0a2b65f5d7d729c 100644 (file)
@@ -48,7 +48,9 @@ static const char * EVENT_FEATURE_STATE_RESPONSE = "FeatureStateResponse";
 class MODELAPI_EXPORT ModelAPI_ObjectUpdatedMessage : public Events_MessageGroup
 {
  protected:
+  /// Creates an empty message
   ModelAPI_ObjectUpdatedMessage(const Events_ID theID, const void* theSender = 0);
+  /// The virtual destructor
   virtual ~ModelAPI_ObjectUpdatedMessage();
 
  public:
@@ -65,28 +67,33 @@ class MODELAPI_EXPORT ModelAPI_ObjectUpdatedMessage : public Events_MessageGroup
 /// Message that feature was deleted (used for Object Browser update)
 class MODELAPI_EXPORT ModelAPI_ObjectDeletedMessage : public Events_MessageGroup
 {
- protected:
+protected:
+  /// Creates an empty message
   ModelAPI_ObjectDeletedMessage(const Events_ID theID, const void* theSender = 0);
+  /// The virtual destructor
   virtual ~ModelAPI_ObjectDeletedMessage();
 
- public:
+public:
   /// Returns the feature that has been updated
   virtual std::shared_ptr<ModelAPI_Document> document() const = 0;
 
   /// Returns the group where the feature was deleted
   virtual const std::set<std::string>& groups() const = 0;
 
+  /// Creates the new empty message of this kind
   virtual std::shared_ptr<Events_MessageGroup> newEmpty() = 0;
 
+  /// Returns the identifier of the kind of a message
   virtual const Events_ID messageId() = 0;
 
+  /// Appenad to this message the given one.
   virtual void Join(const std::shared_ptr<Events_MessageGroup>& theJoined) = 0;
 };
 
 /// Allows to create ModelAPI messages
 class MODELAPI_EXPORT ModelAPI_EventCreator
 {
- public:
+public:
   /// creates created, updated or moved messages and sends to the loop
   virtual void sendUpdated(const ObjectPtr& theObject, const Events_ID& theEvent,
                            const bool isGroupped = true) const = 0;
@@ -102,25 +109,33 @@ class MODELAPI_EXPORT ModelAPI_EventCreator
 };
 
 // TODO(sbh): Move this message into a separate package, like "GuiAPI"
+/// Contains the state information about the feature: is it enabled or disabled.
 class ModelAPI_FeatureStateMessage : public Events_Message
 {
- public:
+public:
+  /// Creates an empty message
   MODELAPI_EXPORT ModelAPI_FeatureStateMessage(const Events_ID theID, const void* theSender = 0);
+  /// The virtual destructor
   MODELAPI_EXPORT virtual ~ModelAPI_FeatureStateMessage();
 
-  // For request
+  /// Returns the feature this message is related to
   MODELAPI_EXPORT std::shared_ptr<ModelAPI_Feature> feature() const;
+  /// Stores the feature this message is related to
   MODELAPI_EXPORT void setFeature(std::shared_ptr<ModelAPI_Feature>& theFeature);
   // For response
+  /// Returns true if feature has specific state
   MODELAPI_EXPORT bool hasState(const std::string& theFeatureId) const;
+  /// Returns true if feature is enabled
   MODELAPI_EXPORT bool state(const  std::string& theFeatureId, bool theDefault = false) const;
+  /// Stores the feature state
   MODELAPI_EXPORT void setState(const std::string& theFeatureId, bool theValue);
+  /// Returns all feature IDs with states
   MODELAPI_EXPORT std::list<std::string> features() const;
 
  private:
-  // For Request
+  /// For Request
   std::shared_ptr<ModelAPI_Feature> myCurrentFeature;
-  // For response
+  /// For response
   std::map<std::string, bool> myFeatureState;
 };
 
index a8ce3e94cda1384a69e36b844a3eacfcf6d0d80f..183077f4fff6e55b47067a7430f0f83b4226ab38 100644 (file)
@@ -96,66 +96,68 @@ class ModelAPI_Feature : public ModelAPI_Object
   /// To virtually destroy the fields of successors
   MODELAPI_EXPORT virtual ~ModelAPI_Feature();
 
+  /// Returns the feature by the object (result).
   MODELAPI_EXPORT static std::shared_ptr<ModelAPI_Feature> feature(ObjectPtr theObject);
 
  //
  // Helper methods, aliases for data()->method()
  // -----------------------------------------------------------------------------------------------
+  /// Returns the name stored in the attribute
   inline std::string name()
   {
     return data()->name();
   }
-
+  /// Returns the Boolean attribute by the identifier
   inline std::shared_ptr<ModelAPI_AttributeBoolean> boolean(const std::string& theID)
   {
     return data()->boolean(theID);
   }
-
+  /// Returns the document reference attribute
   inline std::shared_ptr<ModelAPI_AttributeDocRef> document(const std::string& theID)
   {
     return data()->document(theID);
   }
-
+  /// Returns the real attribute by the identifier
   inline std::shared_ptr<ModelAPI_AttributeDouble> real(const std::string& theID)
   {
     return data()->real(theID);
   }
-
+  /// Returns the integer attribute by the identifier
   inline std::shared_ptr<ModelAPI_AttributeInteger> integer(const std::string& theID)
   {
     return data()->integer(theID);
   }
-
+  /// Returns the reference attribute by the identifier
   inline std::shared_ptr<ModelAPI_AttributeRefAttr> refattr(const std::string& theID)
   {
     return data()->refattr(theID);
   }
-
+  /// Returns the reference attribute by the identifier
   inline std::shared_ptr<ModelAPI_AttributeReference> reference(const std::string& theID)
   {
     return data()->reference(theID);
   }
-
+  /// Returns the list of references attribute by the identifier
   inline std::shared_ptr<ModelAPI_AttributeRefList> reflist(const std::string& theID)
   {
     return data()->reflist(theID);
   }
-
+  /// Returns the shape selection attribute by the identifier
   inline std::shared_ptr<ModelAPI_AttributeSelection> selection(const std::string& theID)
   {
     return data()->selection(theID);
   }
-
+  /// Returns the list of shape selections attribute by the identifier
   inline std::shared_ptr<ModelAPI_AttributeSelectionList> selectionList(const std::string& theID)
   {
     return data()->selectionList(theID);
   }
-
+  /// Returns the string attribute by the identifier
   inline std::shared_ptr<ModelAPI_AttributeString> string(const std::string& theID)
   {
     return data()->string(theID);
   }
-
+  /// Returns the attribute by the identifier
   inline std::shared_ptr<ModelAPI_Attribute> attribute(const std::string& theID)
   {
     return data()->attribute(theID);
index 85e06609c6f3facdd654fee13edd8cf82b406cbd..59161acbef6b9fdd8b7a208a6f831b25f875979f 100644 (file)
 #include "ModelAPI.h"
 #include "ModelAPI_Validator.h"
 
+/**\class ModelAPI_FeatureValidator
+ * \ingroup DataModel
+ * \brief The geneneric validator for the whole feature.
+ *
+ * Can be redefined for some specific feature, but by default for each feature this validator is
+ * used: it checks each argument of the feature and if one of it is not valid (and obligatory),
+ * the hole feature is invalid.
+ */
 class ModelAPI_FeatureValidator : public ModelAPI_Validator
 {
  public:
   /// Returns true if feature and/or attributes are valid
   /// \param theFeature the validated feature
-  /// \param theAttr the validated attribute ID, empty string of feature is validated
   /// \param theArguments list of string, feature attribute names: dependent attributes
   virtual bool isValid(const std::shared_ptr<ModelAPI_Feature>& theFeature,
     const std::list<std::string>& theArguments) const = 0;
index 6493a27e5548851ce11cbd490aaffbdd8a6ccfab..de421e726c29c176b12a5adf2ababa5aee625712 100644 (file)
@@ -17,7 +17,6 @@ class ModelAPI_Feature;
  * \ingroup DataModel
  * \brief Interface common for any plugin: allows to use plugin by the plugins manager.
  */
-
 class MODELAPI_EXPORT ModelAPI_Plugin
 {
  public:
index 1e4d7bdddad8a029542f0a4fb04b14b9003ef880..ab8ffc6cd5709f22a6819110506f65be5a870b4e 100644 (file)
@@ -12,7 +12,8 @@
 #include <ModelAPI_Attribute.h>
 #include <ModelAPI_AttributeValidator.h>
 
-/*
+/**\class ModelAPI_RefAttrValidator
+ * \ingroup DataModel
  * Used for filtering out the object that can be used for reference attribute value
  */
 class ModelAPI_RefAttrValidator : public ModelAPI_AttributeValidator
index f106d96dd0909fef860e8971fd8eac042df04fde..01d73eaed9e9cd77735cee7d080b6f3c7b299d43 100644 (file)
 #include "ModelAPI_Validator.h"
 #include "ModelAPI_Object.h"
 
+/**\class ModelAPI_ResultValidator
+ * \ingroup DataModel
+ * \brief The base class for selection filter for results of features.
+ *
+ * The referenced arguments of feature is normally results displayed in the viewer or by the 
+ * selection attribute. This filter allows to filter out the results not usable as this argument.
+ */
 class ModelAPI_ResultValidator : public ModelAPI_Validator
 {
- public:
+public:
+  /// The abstract method for implementation in the specific validator.
+  /// \param theObject the checked object as an argument
+  /// \returns true if object is OK for this filter
   virtual bool isValid(const ObjectPtr theObject) const = 0;
 };
 
index f3ebb3d00aa4c5bdd4bf419c1b411f64e8b5c2fb..619509dd2cfdeb97f5d75ec53db32c7556aed5c5 100644 (file)
@@ -32,7 +32,6 @@ class MODELAPI_EXPORT ModelAPI_Session
 
   //! Loads the OCAF document from the file.
   //! \param theFileName full name of the file to load
-  //! \param theStudyID identifier of the SALOME study to associate with loaded file
   //! \returns true if file was loaded successfully
   virtual bool load(const char* theFileName) = 0;
 
@@ -104,7 +103,7 @@ class MODELAPI_EXPORT ModelAPI_Session
  protected:
   /// Creates the feature object using plugins functionality
   virtual std::shared_ptr<ModelAPI_Feature> createFeature(std::string theFeatureID) = 0;
-
+  /// Sets the session interface implementation (once per application launch)
   static void setSession(std::shared_ptr<ModelAPI_Session> theManager);
 
   friend class Model_Document;
index 683d215784bcc3c130cad428f52b80677fed506b..a8489408dc6bec240b76ccaf602e7552d6523ac5 100644 (file)
@@ -52,10 +52,11 @@ const double PSEUDO_ZERO = 1.e-20;
  a step value of 1.0 and a precision of 2 decimal places.
  The value is initially set to 0.00.
 
- \param parent parent object
+ \param theParent parent object
+ \param thePrecision precision of values input
  */
-ModuleBase_DoubleSpinBox::ModuleBase_DoubleSpinBox(QWidget* parent, int thePrecision)
-    : QDoubleSpinBox(parent),
+ModuleBase_DoubleSpinBox::ModuleBase_DoubleSpinBox(QWidget* theParent, int thePrecision)
+    : QDoubleSpinBox(theParent),
       myCleared(false)
 {
   // VSR 01/07/2010: Disable thousands separator for spin box
@@ -165,7 +166,7 @@ QString ModuleBase_DoubleSpinBox::textFromValue(double val) const
 
 /*!
  \brief Return source string with removed leading and trailing zeros.
- \param str source string
+ \param src source string
  \return resulting string
  */
 QString ModuleBase_DoubleSpinBox::removeTrailingZeroes(const QString& src) const
@@ -300,9 +301,8 @@ QValidator::State ModuleBase_DoubleSpinBox::validate(QString& str, int& pos) con
 
 /*!
  \brief Called when user enters the text in the spin box.
- \param txt current spin box text (not used)
  */
-void ModuleBase_DoubleSpinBox::onTextChanged(const QString& /*txt*/)
+void ModuleBase_DoubleSpinBox::onTextChanged(const QString& )
 {
   myCleared = false;
 }
index b8d8c2bea304f7122e3f6ed2b2f3fca9a4d69ec1..5eb2d976e427169185f1dbf1cfbdc0f7048b4e0a 100644 (file)
 #include <QDoubleSpinBox>
 #include <QValidator>
 
+
+/**
+* An extension and customozation of QDoubleSpinBox class
+*/
 class MODULEBASE_EXPORT ModuleBase_DoubleSpinBox : public QDoubleSpinBox
 {
 Q_OBJECT
 
  public:
-  ModuleBase_DoubleSpinBox(QWidget* = 0, int thePrecision = 6);
+  ModuleBase_DoubleSpinBox(QWidget* theParent = 0, int thePrecision = 6);
   virtual ~ModuleBase_DoubleSpinBox();
 
+  /// Returns true if the control is clear
   bool isCleared() const;
+
+  /// Set control clear
   virtual void setCleared(const bool);
 
+  /// Returns current precision
   int getPrecision() const;
+
+  /// Set precision
   void setPrecision(const int);
 
+  /// Set step
   virtual void stepBy(int);
 
+  /// Converts value from string to double
   virtual double valueFromText(const QString&) const;
+
+  /// Convert value from double to string
   virtual QString textFromValue(double) const;
 
+  /// Validate current value
   virtual QValidator::State validate(QString&, int&) const;
 
  protected slots:
+   /// Called on text changed
   virtual void onTextChanged(const QString&);
 
  protected:
+   /// Removes extra trailing zero symbols
   QString removeTrailingZeroes(const QString&) const;
 
  private:
+   /// Is clear flag
   bool myCleared;
+
+  /// Precision value
   int myPrecision;
 };
 
index 7b1f63d1e91c66ad02fb295675011988ed6f5994..4b684e272c76776d8c4e7e18a4e23028dc7e9179 100644 (file)
@@ -24,6 +24,7 @@
 class ModuleBase_Filter
 {
 public:
+  /// Constructor
   MODULEBASE_EXPORT ModuleBase_Filter() {}
 
   /**
@@ -45,7 +46,8 @@ protected:
   virtual void createFilter() = 0;
 
 protected:
-  Handle(SelectMgr_Filter) myFilter; // current instance of the OCC selection filter
+  /// current instance of the OCC selection filter
+  Handle(SelectMgr_Filter) myFilter; 
 };
 
 #endif //ModuleBase_Filter
index 4e6919a37e38f3a5c9e18b198906531a58b34448..c73f602f1d9429d1d09dd47cfd4e9fe0d613ce20 100644 (file)
 
 #include <StdSelect_TypeOfFace.hxx>
 
+/**
+* A class of a viewer filter by faces
+*/
 class ModuleBase_FilterFace: public ModuleBase_Filter
 {
 public:
+  /// Convert string to StdSelect_TypeOfFace value
+  /// \param theType a string value
   static MODULEBASE_EXPORT StdSelect_TypeOfFace faceType(const std::string& theType);
 
+  /// Constructor
   MODULEBASE_EXPORT ModuleBase_FilterFace(): 
       ModuleBase_Filter() {}
 
index cdfa8e4351ad0f9976bf74e1dd9feb8e5ffd63eb..10bc1d32e2565e9b72d02e1cd68160ef1d395e7f 100644 (file)
 
 #include <StdSelect_TypeOfEdge.hxx>
 
+/**
+* A class of a viewer filter by linear edges
+*/
 class ModuleBase_FilterLinearEdge: public ModuleBase_Filter
 {
 public:
+  /// Convert string to StdSelect_TypeOfFace value
+  /// \param theType a string value
   static MODULEBASE_EXPORT StdSelect_TypeOfEdge edgeType(const std::string& theType);
 
+  /// Constructor
   MODULEBASE_EXPORT ModuleBase_FilterLinearEdge(): 
       ModuleBase_Filter() {}
 
index e7ba0f175d37c99e1de47b3cb12879abad756467..9a69d59bab7ac45b33a036737c0949e6b8b94d3c 100644 (file)
@@ -13,6 +13,9 @@
 
 #include <StdSelect_TypeOfFace.hxx>
 
+/**
+* An implementation of filter which support using of several filters according to OR statement
+*/
 class ModuleBase_FilterMulti: public ModuleBase_Filter
 {
   /**
@@ -40,7 +43,8 @@ protected:
   virtual void createFilter();
 
 protected:
-  std::list<std::string> myArguments; /// the filter arguments
+  /// the filter arguments
+  std::list<std::string> myArguments; 
 };
 
 #endif //ModuleBase_FilterMulti
index 49b11279971e03af32ae48295d3114c875485a38..d70bfa6ce4fa96efb3ccf53d189eb705cb6ab0e5 100644 (file)
@@ -24,6 +24,8 @@ DEFINE_STANDARD_HANDLE(ModuleBase_FilterNoConsructionSubShapes, SelectMgr_Filter
 class ModuleBase_FilterNoConsructionSubShapes: public SelectMgr_Filter
 {
 public:
+  /// Constructor
+  /// \param theWorkshop instance of workshop interface
   Standard_EXPORT ModuleBase_FilterNoConsructionSubShapes(ModuleBase_IWorkshop* theWorkshop):
       SelectMgr_Filter(), myWorkshop(theWorkshop) {}
 
@@ -38,6 +40,7 @@ public:
   DEFINE_STANDARD_RTTI(ModuleBase_FilterNoConsructionSubShapes)
 
 protected:
+  /// Instance of workshop interface
   ModuleBase_IWorkshop* myWorkshop;
 };
 
index 2b20a2965755739efd5a0678e6f0d9e642651e49..9cf3208ebaf1c281255e56ee0321cb02421d6fd6 100644 (file)
 
 #include <StdSelect_TypeOfFace.hxx>
 
+/**
+* A class of a viewer filter by shape type
+*/
 class ModuleBase_FilterShapeType: public ModuleBase_Filter
 {
 public:
+  /// Constructor 
+  /// \param theType type of shape
   static MODULEBASE_EXPORT TopAbs_ShapeEnum shapeType(const std::string& theType);
 
   MODULEBASE_EXPORT ModuleBase_FilterShapeType();
@@ -33,7 +38,8 @@ protected:
   virtual void createFilter();
 
 private:
-  TopAbs_ShapeEnum myShapeType; /// the shape type of the filter
+  /// the shape type of the filter
+  TopAbs_ShapeEnum myShapeType; 
 };
 
 #endif //ModuleBase_FilterShapeType
index 5703bb3c068b09a228f3475cf0ca058a1e6fc380..29cdc430d099e3f81ecf3258f6c6b681ae90d610 100644 (file)
@@ -30,6 +30,8 @@ class MODULEBASE_EXPORT ModuleBase_IModule : public QObject
   Q_OBJECT\r
  public:\r
 \r
+   /// Constructor\r
+   /// \param theParent instance of workshop intrface\r
    ModuleBase_IModule(ModuleBase_IWorkshop* theParent);\r
 \r
   virtual ~ModuleBase_IModule() {}\r
@@ -40,7 +42,8 @@ class MODULEBASE_EXPORT ModuleBase_IModule : public QObject
   /// Called on creation of menu item in desktop\r
   virtual void actionCreated(QAction*);\r
 \r
-  /// Called when user selects feature for editing\r
+  /// Launching of a edit operation on the feature \r
+  /// \param theFeature feature for editing\r
   virtual void editFeature(FeaturePtr theFeature);\r
 \r
   /// Creates an operation and send it to loop\r
@@ -64,10 +67,12 @@ class MODULEBASE_EXPORT ModuleBase_IModule : public QObject
   /// Realizes some functionality by an operation abort\r
   virtual void operationAborted(ModuleBase_Operation* theOperation) {}\r
 \r
-  /// Called when it is necessary to update a command state (enable or disable it)\r
-  //virtual bool isFeatureEnabled(const QString& theCmdId) const = 0;\r
-\r
   /// Creates custom widgets for property panel\r
+  /// \param theType a type of widget\r
+  /// \param theParent the parent object\r
+  /// \param theWidgetApi the widget configuation. The attribute of the model widget is obtained from\r
+  /// \param theParentId is Id of a parent of the current attribute\r
+  /// \param theModelWidgets list of widget objects\r
   virtual QWidget* createWidgetByType(const std::string& theType, QWidget* theParent,\r
                                       Config_WidgetAPI* theWidgetApi, std::string theParentId,\r
                                       QList<ModuleBase_ModelWidget*>& theModelWidgets)\r
@@ -75,6 +80,7 @@ class MODULEBASE_EXPORT ModuleBase_IModule : public QObject
     return 0;\r
   }\r
 \r
+  /// Returns current workshop\r
   ModuleBase_IWorkshop* workshop() const { return myWorkshop; }\r
 \r
   /// Call back forlast tuning of property panel before operation performance\r
@@ -82,35 +88,13 @@ class MODULEBASE_EXPORT ModuleBase_IModule : public QObject
   virtual void propertyPanelDefined(ModuleBase_Operation* theOperation) {}\r
 \r
 public slots:\r
+  /// Called on call of command corresponded to a feature\r
   void onFeatureTriggered();\r
 \r
 protected slots:\r
   /// Called on selection changed event\r
   virtual void onSelectionChanged() {}\r
 \r
-  /// SLOT, that is called by mouse press in the viewer.\r
-  /// The mouse released point is sent to the current operation to be processed.\r
-  /// \param theEvent the mouse event\r
-  //virtual void onMousePressed(QMouseEvent* theEvent) {}\r
-\r
-  /// SLOT, that is called by mouse release in the viewer.\r
-  /// The mouse released point is sent to the current operation to be processed.\r
-  /// \param theEvent the mouse event\r
-  //virtual void onMouseReleased(QMouseEvent* theEvent) {}\r
-  \r
-  /// SLOT, that is called by mouse move in the viewer.\r
-  /// The mouse moved point is sent to the current operation to be processed.\r
-  /// \param theEvent the mouse event\r
-  //virtual void onMouseMoved(QMouseEvent* theEvent) {}\r
-\r
-  /// SLOT, that is called by the mouse double click in the viewer.\r
-  /// \param theEvent the mouse event\r
-  //virtual void onMouseDoubleClick(QMouseEvent* theEvent) {}\r
-\r
-  /// SLOT, that is called by the key in the viewer is clicked.\r
-  /// \param theEvent the mouse event\r
-  //virtual void onKeyRelease(QKeyEvent* theEvent) {}\r
-\r
  protected:\r
   /// Sends the operation for launching\r
   /// \param theOperation the operation\r
@@ -118,8 +102,7 @@ protected slots:
 \r
   /// Creates a new operation\r
   /// \param theCmdId the operation name\r
-  /// \param theFeatureKind a kind of feature to get the feature xml description\r
-  virtual ModuleBase_Operation* createOperation(const std::string& theFeatureId);\r
+  virtual ModuleBase_Operation* createOperation(const std::string& theCmdId);\r
 \r
   /// Register validators for this module\r
   virtual void registerValidators() {}\r
@@ -132,7 +115,10 @@ protected slots:
 \r
 protected:\r
 \r
+  /// Reference to workshop\r
   ModuleBase_IWorkshop* myWorkshop;\r
+\r
+  /// Map of features in XML\r
   std::map<std::string, std::string> myFeaturesInFiles;\r
 };\r
 \r
index 33205b817d06bb8b814e88b4c0256b0d0ff8a2bb..c84a7d0582a8d58cae71e96ba12aaa443493fec4 100644 (file)
@@ -21,6 +21,8 @@ class MODULEBASE_EXPORT ModuleBase_IViewer : public QObject
 {
 Q_OBJECT
  public:
+   /// Constructor
+   /// \param theParent a parent object
   ModuleBase_IViewer(QObject* theParent)
       : QObject(theParent)
   {
@@ -36,12 +38,14 @@ Q_OBJECT
   virtual Handle(V3d_View) activeView() const = 0;
 
   //! Enable or disable selection in the viewer
+  //! \param isEnabled is enable or disable flag
   virtual void enableSelection(bool isEnabled) = 0;
 
   //! Returns true if selection is enabled
   virtual bool isSelectionEnabled() const = 0;
 
   //! Enable or disable multiselection in the viewer
+  //! \param isEnable is enable or disable flag
   virtual void enableMultiselection(bool isEnable) = 0;
 
   //! Returns true if multiselection is enabled
@@ -57,9 +61,11 @@ Q_OBJECT
   virtual void setViewProjection(double theX, double theY, double theZ) = 0;
 
   /// Add selection filter to the viewer
+  /// \param theFilter a selection filter
   virtual void addSelectionFilter(const Handle(SelectMgr_Filter)& theFilter) = 0;
 
   /// Remove selection filter from the viewer
+  /// \param theFilter a selection filter
   virtual void removeSelectionFilter(const Handle(SelectMgr_Filter)& theFilter) = 0;
 
   /// Remove all selection filters from the viewer
@@ -69,21 +75,43 @@ Q_OBJECT
   virtual void update() = 0;
 
 signals:
+  /// Signal emited when last view window is closed
   void lastViewClosed();
+
+  /// Signal emited before view window is closed
   void tryCloseView(ModuleBase_IViewWindow* theWnd);
+
+  /// Signal emited on delete view window
   void deleteView(ModuleBase_IViewWindow* theWnd);
+
+  /// Signal emited on creation of view window
   void viewCreated(ModuleBase_IViewWindow* theWnd);
+
+  /// Signal emited on key release
   void activated(ModuleBase_IViewWindow* theWnd);
 
+  /// Signal emited on mouse press
   void mousePress(ModuleBase_IViewWindow* theWnd, QMouseEvent* theEvent);
+
+  /// Signal emited on mouse release
   void mouseRelease(ModuleBase_IViewWindow* theWnd, QMouseEvent* theEvent);
+
+  /// Signal emited on mouse double click
   void mouseDoubleClick(ModuleBase_IViewWindow* theWnd, QMouseEvent* theEvent);
+
+  /// Signal emited on mouse move
   void mouseMove(ModuleBase_IViewWindow* theWnd, QMouseEvent* theEvent);
 
+  /// Signal emited on key press
   void keyPress(ModuleBase_IViewWindow* theWnd, QKeyEvent* theEvent);
+
+  /// Signal emited on key release
   void keyRelease(ModuleBase_IViewWindow* theWnd, QKeyEvent* theEvent);
 
+  /// Signal emited on selection changed
   void selectionChanged();
+
+  /// Signal emited on selection changed
   void contextMenuRequested(QContextMenuEvent*);
 };
 
index 3679e30d2df1fbc5833f33b258db503739905dcc..e755062f6b4cc51e6a2d0690b919a35531824c99 100644 (file)
@@ -28,6 +28,8 @@ class MODULEBASE_EXPORT ModuleBase_IWorkshop : public QObject
 {
 Q_OBJECT
  public:
+   /// Constructor
+   /// \param theParent parent object
   ModuleBase_IWorkshop(QObject* theParent)
       : QObject(theParent)
   {}
@@ -35,6 +37,7 @@ Q_OBJECT
   virtual ~ModuleBase_IWorkshop()
   {}
 
+  /// Return current selection instance
   virtual ModuleBase_ISelection* selection() const = 0;
 
   /// Activate sub-shapes selection (opens local context)
@@ -70,6 +73,7 @@ Q_OBJECT
   virtual void setSelected(const QObjectPtrList& theFeatures) = 0;
 
 signals:
+  /// Signal selection chaged.
   void selectionChanged();
 
   /// Signal which is emited after activation of property panel
index bd9f525517ca61e06d5e8bf73076fc33058f7018..65c87285dfec8b0cb09659134fec6c3118953327 100644 (file)
@@ -23,7 +23,7 @@
 \r
 /*!\r
  * \class ModuleBase_OperationDescription\r
- *\r
+ * Description of operation from XML\r
  */\r
 class MODULEBASE_EXPORT ModuleBase_OperationDescription\r
 {\r
@@ -38,10 +38,6 @@ class MODULEBASE_EXPORT ModuleBase_OperationDescription
   /// \return string name of the operation.\r
   const QString& operationId() const;\r
 \r
-  /// Returns XML representation of the operation's widget.\r
-  /// \return XML QString\r
-  //const QString& xmlRepresentation() const;\r
-\r
   /// Returns a short description of operation (will be\r
   /// inserted in title of property panel)\r
   const QString& description() const;\r
@@ -50,15 +46,6 @@ class MODULEBASE_EXPORT ModuleBase_OperationDescription
   /// inserted in title of property panel)\r
   void setDescription(const QString& theDescription);\r
 \r
-  /// Sets a list of model widgets, according to the operation feature xml definition\r
-  /// \param theWidgets a list of widgets\r
-  //void setModelWidgets(const std::string& theXmlRepresentation,\r
-  //                     const QList<ModuleBase_ModelWidget*>& theWidgets);\r
-\r
-  /// Sets a list of model widgets, according to the operation feature xml definition\r
-  /// \param theWidgets a list of widgets\r
-  //const QList<ModuleBase_ModelWidget*>& modelWidgets() const;\r
-\r
   /// Returns XML representation of the operation's widget.\r
   /// \return XML QString\r
   const QString& xmlRepresentation() const;\r
@@ -73,10 +60,14 @@ class MODULEBASE_EXPORT ModuleBase_OperationDescription
 \r
  private:\r
   //!< Next fields could be extracted into a subclass;\r
-  QString myOperationId;  /// the operation identifier\r
-  QString myDescription;  /// the short description of the opertaion\r
-  QString myXmlRepresentation;  /// the xml definition\r
-  //QList<ModuleBase_ModelWidget*> myWidgets; /// the list of operation widgets\r
+   /// the operation identifier\r
+  QString myOperationId;  \r
+\r
+  /// the short description of the opertaion\r
+  QString myDescription;  \r
+\r
+  /// the xml definition\r
+  QString myXmlRepresentation;  \r
 };\r
 \r
-#endif //ModuleBase_OperationDescription_H\r
\ No newline at end of file
+#endif //ModuleBase_OperationDescription_H\r
index e04c63bbca35c7880bbbddd33ca13bbe7fde8a53..b7783c09dff2df92e865497ed561e3b83461f506 100644 (file)
 class SUIT_ResourceMgr;
 class QWidget;
 
-// Pair of values: section name, value name
+/// \typedef ModuleBase_Pref Pair of values: section name, value name
 typedef QPair<QString, QString> ModuleBase_Pref;
+
+/// \typedef ModuleBase_Prefs list of preferences
 typedef QList<ModuleBase_Pref> ModuleBase_Prefs;
 
 //***********************************************************************
@@ -35,6 +37,7 @@ class MODULEBASE_EXPORT ModuleBase_Preferences
 
   /// Sets a resource manager
   /// It is used in case of necessity to define external resource manager (not NewGeom)
+  /// \param theMgr resource manager
   static void setResourceMgr(SUIT_ResourceMgr* theMgr) { myResourceMgr = theMgr; }
 
   /// Updates Config_PropManager properties by module from SUIT_ResourceMgr
@@ -50,7 +53,9 @@ class MODULEBASE_EXPORT ModuleBase_Preferences
   /// Loads properties defined by module to Config_PropManager
   static void loadCustomProps();
 
-  /// 
+  /// Create editable content
+  /// \param thePref interface to preference manager
+  /// \param thePage an id of a page
   static void createEditContent(ModuleBase_IPrefMgr* thePref, int thePage);
 
 private:
@@ -66,6 +71,9 @@ class MODULEBASE_EXPORT ModuleBase_PreferencesMgr : public SUIT_PreferenceMgr
 {
 Q_OBJECT
  public:
+   /// Constructor
+   /// \param theResource resource manager
+   /// \param theParent a paren widget
   ModuleBase_PreferencesMgr(QtxResourceMgr* theResource, QWidget* theParent)
       : SUIT_PreferenceMgr(theResource, theParent)
   {
index 180d59936a37308129a606c3f15429a1d883ec5e..045e730e20fe28e182bfd2facaa0974effc995a3 100644 (file)
 #include <list>
 #include <string>
 
+/**
+* A validator of selection
+*/
 class ModuleBase_SelectionValidator : public ModelAPI_Validator
 {
  public:
+   /// Returns True if selection is valid
+   /// \param theSelection selection instance
   virtual bool isValid(const ModuleBase_ISelection* theSelection) const = 0;
+
+   /// Returns True if selection is valid
+   /// \param theSelection selection instance
+   /// \param theArguments list of arguments
   virtual bool isValid(const ModuleBase_ISelection* theSelection,
                        const std::list<std::string>& theArguments) const
   {
index 708eb9e03b15b55a0cca152c893da0ecdf2e70a1..0b34930942fe239327a6951b98e335ca2facd7b4 100644 (file)
@@ -27,14 +27,19 @@ DEFINE_STANDARD_HANDLE(ModuleBase_ShapeDocumentFilter, SelectMgr_Filter);
 class ModuleBase_ShapeDocumentFilter: public SelectMgr_Filter
 {
 public:
+  /// Constructor
+  /// \param theWorkshop instance of workshop interface
   Standard_EXPORT ModuleBase_ShapeDocumentFilter(ModuleBase_IWorkshop* theWorkshop): SelectMgr_Filter(),
     myWorkshop(theWorkshop) {}
 
+  /// Returns True if the given owner is acceptable for selection
+  /// \param theOwner the selected owner
   Standard_EXPORT virtual Standard_Boolean IsOk(const Handle(SelectMgr_EntityOwner)& theOwner) const;
 
   DEFINE_STANDARD_RTTI(ModuleBase_ShapeDocumentFilter)
 
 protected:
+  /// Reference to workshop
   ModuleBase_IWorkshop* myWorkshop;
 };
 
@@ -46,15 +51,23 @@ DEFINE_STANDARD_HANDLE(ModuleBase_ShapeInPlaneFilter, SelectMgr_Filter);
 class ModuleBase_ShapeInPlaneFilter: public SelectMgr_Filter
 {
 public:
+  /// Constructor
   Standard_EXPORT ModuleBase_ShapeInPlaneFilter(): SelectMgr_Filter() {}
 
+  /// Set working plane
+  /// \param thePane plane object
   void setPlane(const gp_Pln& thePane) { myPlane = thePane; }
+
+  /// Returns current working plane
   gp_Pln plane() const { return myPlane; }
 
+  /// Returns True if the given owner is acceptable for selection
+  /// \param theOwner the selected owner
   Standard_EXPORT virtual Standard_Boolean IsOk(const Handle(SelectMgr_EntityOwner)& theOwner) const;
 
   DEFINE_STANDARD_RTTI(ModuleBase_ShapeInPlaneFilter)
 private:
+  /// Working plane
   gp_Pln myPlane;
 };
 
@@ -62,18 +75,26 @@ private:
 /**
 * A filter which provides filtering of selection in 3d viewer.
 * Installing of this filter lets to select only object of requested type
+* Accepts following objects types:
+* - "construction" - to select ModelAPI_ResultConstruction objects
 */
 DEFINE_STANDARD_HANDLE(ModuleBase_ObjectTypesFilter, SelectMgr_Filter);
 class ModuleBase_ObjectTypesFilter: public ModuleBase_ShapeDocumentFilter
 {
 public:
+  /// Constructor
+  /// \param theWorkshop instance of workshop interface
+  /// \param theTypes list of object types
   Standard_EXPORT ModuleBase_ObjectTypesFilter(ModuleBase_IWorkshop* theWorkshop, const QStringList& theTypes): 
       ModuleBase_ShapeDocumentFilter(theWorkshop), myTypes(theTypes) {}
 
+  /// Returns True if the given owner is acceptable for selection
+  /// \param theOwner the selected owner
   Standard_EXPORT virtual Standard_Boolean IsOk(const Handle(SelectMgr_EntityOwner)& theOwner) const;
 
   DEFINE_STANDARD_RTTI(ModuleBase_ObjectTypesFilter)
 private:
+  /// List of object types
   QStringList myTypes;
 };
 
index 5c1ef4bb9f84e3923a386d52fbe78e3b9f0d0e4a..d956662a5d9e77c2609307081d2f294153b1c038 100644 (file)
@@ -19,7 +19,9 @@ class QTimer;
 /**
 * A class of property panel widget for double value input
 * It can be defined with "doublevalue" keyword. For example:
-* "<doublevalue id="x" label="X:" icon=":pictures/x_point.png" tooltip="X coordinate"/>"
+* \code
+* <doublevalue id="x" label="X:" icon=":pictures/x_point.png" tooltip="X coordinate"/>
+* \endcode
 */
 class MODULEBASE_EXPORT ModuleBase_WidgetDoubleValue : public ModuleBase_ModelWidget
 {
index bf8f8841a021a813aaf3ed2af162f98639370ded..66ef0bc87f2ff6dcc960e30bd3d16a15af1f19b5 100644 (file)
@@ -31,10 +31,29 @@ class QComboBox;
 class ModuleBase_IWorkshop;
 class QAction;
 
+
+/**
+* Implementation of widget for shapes selection. This widget provides selection of several shapes.
+* It can be defined in XML file as following:
+* \code
+* <multi_selector id="group_list" 
+*    tooltip="Select a set of objects" 
+*    type_choice="Vertices Edges Faces Solids" /> 
+* \endcode
+* It uses folloing parameters:
+* - id - is a name of corresponded attribute
+* - tooltip - a tooltip for the widget
+* - type_choice - list of expected shape types.
+*/
 class MODULEBASE_EXPORT ModuleBase_WidgetMultiSelector : public ModuleBase_ModelWidget
 {
   Q_OBJECT
  public:
+  /// Constructor
+  /// \param theParent the parent object
+  /// \param theWorkshop instance of workshop interface
+  /// \param theData the widget configuation. The attribute of the model widget is obtained from
+  /// \param theParentId is Id of a parent of the current attribute
   ModuleBase_WidgetMultiSelector(QWidget* theParent,
                                  ModuleBase_IWorkshop* theWorkshop,
                                  const Config_WidgetAPI* theData,
@@ -42,7 +61,6 @@ class MODULEBASE_EXPORT ModuleBase_WidgetMultiSelector : public ModuleBase_Model
   virtual ~ModuleBase_WidgetMultiSelector();
 
   /// Saves the internal parameters to the given feature
-  /// \param theObject a model feature to be changed
   virtual bool storeValue() const;
 
   virtual bool restoreValue();
@@ -55,28 +73,49 @@ class MODULEBASE_EXPORT ModuleBase_WidgetMultiSelector : public ModuleBase_Model
   /// \return a control list
   virtual QList<QWidget*> getControls() const;
 
-  virtual bool eventFilter(QObject* theObj, QEvent* theEvent);
+  virtual bool eventFilter(QObject* , QEvent* );
 
  public slots:
+  /// Activate or deactivate selection
   void activateSelection(bool toActivate);
+
+  /// Slot is called on selection type changed
   void onSelectionTypeChanged();
+
+  /// Slot is called on selection changed
   void onSelectionChanged();
 
 protected slots:
+  /// Slot for copy command in a list pop-up menu
   void onCopyItem();
+
+  /// Slot is called on selection of list of selected items
   void onListSelection();
 
  protected:
+   /// Provide filtering of selected shapes
+   /// \param theShapesToFilter source list of shapes
+   /// \param theResult result list of shapes
   void filterShapes(const NCollection_List<TopoDS_Shape>& theShapesToFilter,
                     NCollection_List<TopoDS_Shape>& theResult);
+
+  /// Set current shape type for selection
   void setCurrentShapeType(const TopAbs_ShapeEnum theShapeType);
+
+  /// Start shape selection
   void activateShapeSelection();
 
  private:
+   /// Update selection list
    void updateSelectionList(AttributeSelectionListPtr);
 
+   /// List control
   QListWidget* myListControl;
+
+  /// Combobox of types
   QComboBox* myTypeCombo;
+
+  /// Container
   QWidget* myMainWidget;
 
   //TODO: Move into the base of selectors
@@ -85,9 +124,13 @@ protected slots:
   /// If true then local selector has to be activated in context
   bool myIsActive;
 
+  /// \typedef GeomSelection provides correspondance between Result object and its shape
   typedef QPair<ResultPtr, GeomShapePtr> GeomSelection;
+
+  /// Variable of GeomSelection type
   QList<GeomSelection> mySelection;
 
+  /// An action for pop-up menu in a list control
   QAction* myCopyAction;
 };
 
index 7757d3141070cc520073ac17c7d3a7e7f4d971cd..755714ffdfdd04fcc509a5bc8914eba30a00d8e6 100644 (file)
@@ -25,12 +25,46 @@ class QLineEdit;
 class QToolButton;
 class ModuleBase_IWorkshop;
 
+/**
+* Implementation of widget for shapes selection.
+* This type of widget can be defined in XML file with 'shape_selector' keyword.
+* For example:
+* \code
+*   <shape_selector id="main_object" 
+*    label="Main object" 
+*    icon=":icons/cut_shape.png" 
+*    tooltip="Select an object solid"
+*    shape_types="solid shell"
+*    concealment="true"
+*  />
+* \endcode
+* It can use following parameters:
+* - id - name of object attribute
+* - label - content of widget's label
+* - icon - icon which can be used instead label
+* - tooltip - the witget's tooltip text
+* - shape_types - list of shape types for selection. 
+*       Possible values: face, vertex, wire, edge, shell, solid
+* - object_types - types of selectable objects. 
+*       For today it supports only one type "construction" 
+*        which corresponds to ModelAPI_ResultConstruction object type
+* - concealment - hide or not hide selected object after operation
+*/
 class MODULEBASE_EXPORT ModuleBase_WidgetShapeSelector : public ModuleBase_ModelWidget
 {
 Q_OBJECT
  public:
+
+   /// Converts string value (name of shape type) to shape enum value
+   /// \param theType - string with shape type name
+   /// \return TopAbs_ShapeEnum value
   static TopAbs_ShapeEnum shapeType(const QString& theType);
 
+  /// Constructor
+  /// \param theParent the parent object
+  /// \param theWorkshop instance of workshop interface
+  /// \param theData the widget configuation. The attribute of the model widget is obtained from
+  /// \param theParentId is Id of a parent of the current attribute
   ModuleBase_WidgetShapeSelector(QWidget* theParent, ModuleBase_IWorkshop* theWorkshop,
                             const Config_WidgetAPI* theData, const std::string& theParentId);
 
@@ -52,6 +86,7 @@ Q_OBJECT
   /// \return a control list
   virtual QList<QWidget*> getControls() const;
 
+  /// Returns currently selected data object
   ObjectPtr selectedFeature() const
   {
     return mySelectedObject;
@@ -76,29 +111,34 @@ Q_OBJECT
   void activateSelection(bool toActivate);
 
  private slots:
+   /// Slot which is called on selection event
   void onSelectionChanged();
 
  protected:
+   /// Computes and updates name of selected object in the widget
   void updateSelectionName();
-  void raisePanel() const;
 
-  /// Returns true if shape of given object corresponds to requested shape type
-  /// This method is called only in non sub-shapes selection mode
-  //virtual bool acceptObjectShape(const ObjectPtr theObject) const;
+  /// Raise panel which contains this widget
+  void raisePanel() const;
 
   /// Returns true if selected shape corresponds to requested shape types
-  /// This method is called only in sub-shapes selection mode
+  /// \param theShape a shape
   virtual bool acceptSubShape(std::shared_ptr<GeomAPI_Shape> theShape) const;
 
   /// Returns true if selected object corresponds to requested Object type
   /// Thid method is used in any selection mode
+  /// \param theObject an object 
   virtual bool acceptObjectType(const ObjectPtr theObject) const;
 
 
   // Set the given object as a value of the widget
+  /// \param theObj an object 
+  /// \param theShape a shape
   void setObject(ObjectPtr theObj, std::shared_ptr<GeomAPI_Shape> theShape = std::shared_ptr<GeomAPI_Shape>());
 
   /// Check the selected with validators if installed
+  /// \param theObj the object for checking
+  /// \param theShape the shape for checking
   virtual bool isValid(ObjectPtr theObj, std::shared_ptr<GeomAPI_Shape> theShape);
 
   /// Clear attribute
@@ -106,20 +146,35 @@ Q_OBJECT
 
   //----------- Class members -------------
  protected:
+
+   /// Container of the widget's control
   QWidget* myContainer;
+
+  /// Label of the widget
   QLabel* myLabel;
+
+  /// Input control of the widget
   QLineEdit* myTextLine;
 
+  /// Reference to workshop
   ModuleBase_IWorkshop* myWorkshop;
 
+  /// Pointer to selected object
   ObjectPtr mySelectedObject;
-  std::shared_ptr<GeomAPI_Shape> myShape;
 
+  /// Pointer to selected shape
+  GeomShapePtr myShape;
+
+  /// List of accepting shapes types
   QStringList myShapeTypes;
+
+  /// List of accepting object types
   QStringList myObjectTypes;
 
+  /// Active/inactive flag
   bool myIsActive;
 
+  /// Filter by objects types
   Handle(ModuleBase_ObjectTypesFilter) myObjTypeFilter;
 };
 
index 364ebb48dfbf4f12e2fbd571930136890e3c3b0b..59ace5aa844925d932003f95b08eb89d41727d25 100644 (file)
 
 #include <memory>
 
+/**\class FeaturesPlugin_Plugin
+ * \ingroup Plugins
+ * \brief The main class for management the part set operations as plugin.
+ */
 class PARTSETPLUGIN_EXPORT PartSetPlugin_Plugin : public ModelAPI_Plugin,
                                                   public Events_Listener
 {
index b69de135ba91d246cd0ef9e24ded6df0bf745563..bf7cb93fabc27bd87eb40d1cd7237ebe4eb508c7 100644 (file)
@@ -55,6 +55,7 @@ class SketchPlugin_Feature : public ModelAPI_Feature, public GeomAPI_ICustomPrs
   /// Returns true is sketch element is under the rigid constraint
   SKETCHPLUGIN_EXPORT virtual bool isFixed() {return false;}
 
+  /// Returns true of the feature is created basing on the external shape of not-this-sketch object
   inline bool isExternal() const
   {
     AttributeSelectionPtr aAttr = data()->selection(EXTERNAL_ID());
index a02ef822c85e1bbdc88de7c458dc031c84aa2ca6..9354ef398a42c2f87bc12152e99b6c5b1eba5bce 100644 (file)
 #include <ModelAPI_Feature.h>
 #include <ModelAPI_Events.h>
 
+/**\class SketchPlugin_Plugin
+ * \ingroup DataModel
+ * \brief Interface common for any plugin: allows to use plugin by the plugins manager.
+ */
 class SKETCHPLUGIN_EXPORT SketchPlugin_Plugin : public ModelAPI_Plugin, public Events_Listener
 {
- public:
+public:
   /// Creates the feature object of this plugin by the feature string ID
   virtual FeaturePtr createFeature(std::string theFeatureID);
 
@@ -23,7 +27,8 @@ class SKETCHPLUGIN_EXPORT SketchPlugin_Plugin : public ModelAPI_Plugin, public E
   SketchPlugin_Plugin();
   //! Redefinition of Events_Listener method
   virtual void processEvent(const std::shared_ptr<Events_Message>& theMessage);
- protected:
+protected:
+  //! Returns the state of the feature in the WorkBench: enabled or disabled for the moment.
   std::shared_ptr<ModelAPI_FeatureStateMessage> getFeaturesState(
       const std::shared_ptr<ModelAPI_Feature>& theFeature) const;
 };
index d5100d8fcbd040ab1033a8ae2f60d2df3cc298a2..6e328b1757d3d6f244293f78c881e08f268a0f56 100644 (file)
 #include <ModelAPI_ResultValidator.h>
 #include <ModelAPI_Object.h>
 
+/**\class SketchPlugin_ResultPointValidator
+ * \ingroup Validators
+ * \brief Validator for the points selection
+ *
+ * Allows to select points only.
+ */
 class SketchPlugin_ResultPointValidator : public ModelAPI_ResultValidator
 {
- public:
+public:
+  /// Returns true if theObject is a point
   SKETCHPLUGIN_EXPORT virtual bool isValid(const ObjectPtr theObject) const;
 };
 
+/**\class SketchPlugin_ResultLineValidator
+ * \ingroup Validators
+ * \brief Validator for the linear segments selection
+ *
+ * Allows to select linear segments only.
+ */
 class SketchPlugin_ResultLineValidator : public ModelAPI_ResultValidator
 {
- public:
+public:
+  /// Returns true if theObject is a line
   SKETCHPLUGIN_EXPORT virtual bool isValid(const ObjectPtr theObject) const;
 };
 
+/**\class SketchPlugin_ResultArcValidator
+ * \ingroup Validators
+ * \brief Validator for the circular segments selection
+ *
+ * Allows to select circular segments only.
+ */
 class SketchPlugin_ResultArcValidator : public ModelAPI_ResultValidator
 {
  public:
+  /// Returns true if theObject is an arc
   SKETCHPLUGIN_EXPORT virtual bool isValid(const ObjectPtr theObject) const;
 };
 
index a65fbb197acfc781006b9a927c2d1db539104c8f..14e3082f0e6250231532dbc1232256231e87ecca 100644 (file)
@@ -139,14 +139,6 @@ class SketchPlugin_Sketch : public ModelAPI_CompositeFeature//, public GeomAPI_I
 
   SKETCHPLUGIN_EXPORT virtual void attributeChanged(const std::string& theID);
 protected:
-  /// Creates a plane and append it to the list
-  /// \param theX the X normal value
-  /// \param theY the Y normal value
-  /// \param theZ the Z normal value
-  /// \param theShapes the list of result shapes
-  //void addPlane(double theX, double theY, double theZ,
-  //              std::list<std::shared_ptr<GeomAPI_Shape> >& theShapes) const;
-
   /// Checks whether the plane is set in the sketch.
   /// \returns the boolean state
   bool isPlaneSet();
index 2f675c4f4fcc46150eb1cfc8b70463fb49a1ff20..0e94d7a70152f50fe66a01f4c65eea2a91b5e74d 100644 (file)
 #include "SketchPlugin.h"
 #include <ModelAPI_RefAttrValidator.h>
 
+/**\class SketchPlugin_DistanceAttrValidator
+ * \ingroup Validators
+ * \brief Validator for the distance input.
+ *
+ * It just checks that distance is greater than zero.
+ */
 class SketchPlugin_DistanceAttrValidator : public ModelAPI_RefAttrValidator
 {
  public:
@@ -27,7 +33,9 @@ class SketchPlugin_DistanceAttrValidator : public ModelAPI_RefAttrValidator
                        const AttributePtr& theAttribute) const { return true; };
 };
 
-/**
+/**\class SketchPlugin_DifferentObjectsValidator
+ * \ingroup Validators
+ *
  * Check that there is no same object was already selected in the feature.
  * For an example: to avoid perpendicularity on line and the same line.
  */
index 88f4572a17c05d7e8b20e352b0524cf32045a075..61a42b64cf43195b46d9b6bb549cffc78040aa83 100644 (file)
@@ -229,11 +229,13 @@ AttrType typeOfAttribute(std::shared_ptr<ModelAPI_Attribute> theAttribute)
         return ARC;
     }
   } else {
-    const std::string aType = anAttrRef->attr()->attributeType();
-    if (aType == GeomDataAPI_Point2D::type())
-      return POINT2D;
-    if (aType == GeomDataAPI_Point2D::type())
-      return POINT2D;
+    if (anAttrRef->attr().get() != NULL) {
+      const std::string aType = anAttrRef->attr()->attributeType();
+      if (aType == GeomDataAPI_Point2D::type())
+        return POINT2D;
+      if (aType == GeomDataAPI_Point2D::type())
+        return POINT2D;
+    }
   }
 
   return UNKNOWN;
index 4520bf3a585e0c31a6cb0fad0e618715f519b76d..e194c2571cf48619bd2530d00415884b3a50d5d3 100644 (file)
  */
 class SketchSolver_Constraint
 {
- public:
+public:
+  /// Default constructor
   SketchSolver_Constraint();
+  /// Creates constraint to manage the given constraint from plugin
   SketchSolver_Constraint(std::shared_ptr<SketchPlugin_Constraint> theConstraint);
 
   /** \brief Compute constraint type according to SolveSpace identifiers
index 6a6fe158e47ef4e8f06eb711ae9d1876c381eaa5..1b1a621c251d6a46d114c6a4baf646aa5b77ade7 100644 (file)
 /// Tolerance for value of parameters
 const double tolerance = 1.e-10;
 
-/*
+/**
  * Collects all sketch solver error' codes
  * as inline static functions
- * TODO: Move this class into a separate file
  */
+ // TODO: Move this class into a separate file
 class SketchSolver_Error
 {
  public:
index 00e8d4e7b54a8533c068476a92a6a356d53785c9..94734f20c0f0edec67accf815efd79046fe9f99d 100644 (file)
@@ -62,6 +62,10 @@ class SketchSolver_ConstraintGroup
    *  \return \c true if the constraint added or updated successfully
    */
   bool changeConstraint(std::shared_ptr<SketchPlugin_Constraint> theConstraint);
+  /** \brief Adds or updates a rigid constraint in the group
+   *  \param[in] theConstraint constraint to be changed
+   *  \return \c true if the constraint added or updated successfully
+   */
   bool changeRigidConstraint(std::shared_ptr<SketchPlugin_Constraint> theConstraint);
 
   /** \brief Verifies the feature attributes are used in this group
@@ -76,6 +80,7 @@ class SketchSolver_ConstraintGroup
    */
   bool isBaseWorkplane(std::shared_ptr<ModelAPI_CompositeFeature> theWorkplane) const;
 
+  /// Returns the current workplane
   std::shared_ptr<ModelAPI_CompositeFeature> getWorkplane() const
   {
     return mySketch;
@@ -115,6 +120,9 @@ class SketchSolver_ConstraintGroup
    *  \param[in] theEntity attribute of the constraint
    */
   void updateRelatedConstraints(std::shared_ptr<ModelAPI_Attribute> theEntity) const;
+  /** \brief Searches the constraints built on the entity and emit the signal to update them
+   *  \param[in] theFeature feature of the constraint
+   */
   void updateRelatedConstraintsFeature(std::shared_ptr<ModelAPI_Feature> theFeature) const;
 
   /** \brief Adds or updates an entity in the group
index fd2e5213256f245e86d72ee6d8e6c9aa798eefd8..7079f1598549d2660c1c15102dce44a84a18bba4 100644 (file)
@@ -27,6 +27,9 @@ typedef unsigned int UINT32;
 // Unknown entity
 #define SLVS_E_UNKNOWN 0
 
+/**
+ * The main class that performs the high-level operations for connection to the SolveSpace.
+ */
 class SketchSolver_Solver
 {
  public:
index 75f424311721f4573a9f8535fe50b70e80a5a66d..b917e55eb6e70e314d2a54b0700f6ad3738885f1 100644 (file)
@@ -35,11 +35,14 @@ class XGUI_Workshop;
 class XGUI_EXPORT XGUI_Displayer
 {
  public:
-   /// Enumeration of possible display mode
+   /// \enum DisplayMode display mode
    enum DisplayMode { 
-     NoMode = -1, /// Mode is not defined
-     Wireframe,   /// Wireframe display mode
-     Shading      /// Shading display mode
+     /// Mode is not defined
+     NoMode = -1, 
+     /// Wireframe display mode
+     Wireframe, 
+     /// Shading display mode
+     Shading      
    };
 
   /// Constructor
index 5dcd44ee157adbb11a40f159d0425ab29682efd0..5c3eb4a41309299f28ba1b538dc54e750b50385f 100644 (file)
 
 class XGUI_Workshop;
 
+/**
+* Implementation of \ref ModuleBase_ISelection interface.
+*/
 class XGUI_EXPORT XGUI_Selection : public ModuleBase_ISelection
 {
  public:
+   /// Constructor
+   /// \param theWorkshop reference to workshop instance
   XGUI_Selection(XGUI_Workshop* theWorkshop);
 
   /// Returns a list of viewer selected presentations