Salome HOME
Updated documentation
authorsbh <sergey.belash@opencascade.com>
Thu, 29 Jan 2015 17:10:00 +0000 (20:10 +0300)
committersbh <sergey.belash@opencascade.com>
Thu, 29 Jan 2015 17:10:00 +0000 (20:10 +0300)
doc/doxyfile.in
src/Config/Config_Prop.h
src/Config/Config_PropManager.h
src/Config/Config_SelectionFilterMessage.h
src/Config/Config_ValidatorMessage.h
src/Config/Config_WidgetReader.h
src/Config/Config_XMLReader.h
src/ConnectorPlugin/ConnectorPlugin.py
src/ConnectorPlugin/ConnectorPlugin_ExportFeature.py

index 56cda9b0b44b1a3038c99e06653e250347b36105..5f96a4dc137b297e5da641079926573648c65cc8 100644 (file)
@@ -691,7 +691,8 @@ FILE_PATTERNS          = *.h \
                          *.cpp \
                          *.hxx \
                          *.cxx \
-                         *.doc
+                         *.doc \
+                         *.py
 
 # The RECURSIVE tag can be used to turn specify whether or not subdirectories
 # should be searched for input files as well. Possible values are YES and NO.
@@ -719,7 +720,8 @@ EXCLUDE_SYMLINKS       = NO
 # against the file with absolute path, so to exclude all test directories
 # for example use the pattern */test/*
 
-EXCLUDE_PATTERNS       =
+EXCLUDE_PATTERNS       = */Test/*.py
+# (Python unit tests excluded)
 
 # The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names
 # (namespaces, classes, functions, etc.) that should be excluded from the
index fe64ca05886118dee592df0db576d5a69615a4e5..5e6cc4bc8576045bef9023694e7966a1c3121254 100644 (file)
@@ -52,6 +52,7 @@ class Config_Prop
    * Creates a one property
    * \param theSection - name of section (domain of using) of the property.
    * \param theName - name (title) of the value.
+   * \param theTitle - title of the value
    * \param theType - type of the value.
    * \param theDefaultValue - default value of the property. This is an initial property value
    */
index 751e3f44618be83535da73368f5e6504f83768f8..c6bba0810a4311ff0bad110bbe7df34a72b18231 100644 (file)
@@ -27,6 +27,7 @@ class Config_PropManager
    * Registers property parameters
    * \param theSection - name of section (domain of using) of the property.
    * \param theName - name (title) of the value.
+   * \param theTitle - title of the value.
    * \param theType - type of the value.
    * \param theDefValue - default and initial value of the property
    * Returns True if the property succesfully registered
index 3f4039e73658d37b4072b49780dc5ad482a390e6..ed661b93c599173378c22601d7c67f9c1a125429 100644 (file)
@@ -32,6 +32,11 @@ class Config_SelectionFilterMessage : public Events_Message
   std::list<std::string> myFilterParameters;
 
  public:
+  /*!
+   * Constructor.
+   * \param theId - Events_ID of the message
+   * \param theParent - pointer to the sender
+   */
   CONFIG_EXPORT Config_SelectionFilterMessage(const Events_ID theId, const void* theParent = 0);
   CONFIG_EXPORT virtual ~Config_SelectionFilterMessage();
 
index e21b1f9fd3570496815caa3234abed6e415d163a..99650e22efeaaec2e5990f0a0a3bec0e647644e5 100644 (file)
@@ -32,6 +32,11 @@ class Config_ValidatorMessage : public Events_Message
   std::list<std::string> myVaidatorParameters;
 
  public:
+  /*!
+   * Constructor.
+   * \param theId - Events_ID of the message
+   * \param theParent - pointer to the sender
+   */
   CONFIG_EXPORT Config_ValidatorMessage(const Events_ID theId, const void* theParent = 0);
   CONFIG_EXPORT virtual ~Config_ValidatorMessage();
 
index 339b3ad21f4831a3458f829069a6936bf26e7a22..a95d8b805b154302decb362ca6c23d1111e5d2d5 100644 (file)
 class Config_WidgetReader : public Config_XMLReader
 {
  public:
+  /*!
+   * Constructor
+   * \param theXmlFile - full path to the xml file which will be processed by the reader
+   */
   CONFIG_EXPORT Config_WidgetReader(const std::string& theXmlFile);
   CONFIG_EXPORT virtual ~Config_WidgetReader();
 
index 1a75184b619496a5627c26ef968bf2947272454b..01e64c39494cecb606212073c5daec89c38fd8a9 100644 (file)
@@ -36,6 +36,10 @@ struct _xmlDoc;
 class Config_XMLReader
 {
  public:
+  /*!
+   * Constructor
+   * \param theXmlFile - full path to the xml file which will be processed by the reader
+   */
   CONFIG_EXPORT Config_XMLReader(const std::string& theXmlFile);
   CONFIG_EXPORT virtual ~Config_XMLReader();
   /*!
index b532bbd7c3179449fef0c4d576c8d002717411dd..345e4f8c0d03a3dc915ef605f8974692b9990f8a 100644 (file)
@@ -1,25 +1,29 @@
-"""
-Copyright (C) 2014-20xx CEA/DEN, EDF R&D
-"""
+## @package Plugins
+#  Python plugin for exporting entities into Salome's GEOM module
+#  Copyright (C) 2014-20xx CEA/DEN, EDF R&D
 
 import ModelAPI
 
 from ConnectorPlugin_ExportFeature import ExportFeature
 
-
+## @ingroup Plugins
+#  The main class for management the construction features as plugin.
 class ConnectorPlugin(ModelAPI.ModelAPI_Plugin):
 
+    ## The constructor.
     def __init__(self):
         ModelAPI.ModelAPI_Plugin.__init__(self)
         pass
 
+    ## Creates the feature objects of this plugin by the feature string ID.
     def createFeature(self, theFeatureID):
         if theFeatureID == ExportFeature.ID():
             return ExportFeature().__disown__()
         else:
             print "ConnectorPlugin: No such feature %s" % theFeatureID
 
+## The plugin created on module importing (from c++)
 plugin = ConnectorPlugin()
+## Main session of the application
 aSession = ModelAPI.ModelAPI_Session.get()
-print "Module loaded. Session", aSession
 aSession.registerPlugin(plugin)
index c6f9d8c0f48751e3dee7ebc7aeaa7ffee2535f20..e69b259fe73e248ffcc950f15fd775f2cc918af8 100644 (file)
@@ -1,6 +1,6 @@
-"""
-Copyright (C) 2014-20xx CEA/DEN, EDF R&D
-"""
+## @package Plugins
+#  ExportFeature class definition
+#  Copyright (C) 2014-20xx CEA/DEN, EDF R&D
 
 import EventsAPI
 import ModelAPI
@@ -9,34 +9,37 @@ import salome
 from salome.geom import geomBuilder
 
 
+## @ingroup Plugins
+#  Feature to export all shapes and groups into the GEOM module
 class ExportFeature(ModelAPI.ModelAPI_Feature):
 
-    "Feature to create a box by drawing a sketch and extruding it"
-
+    ## The constructor.
     def __init__(self):
         ModelAPI.ModelAPI_Feature.__init__(self)
 
     @staticmethod
+    ## Export kind. Static.
     def ID():
         return "ExportToGEOM"
 
+    ## Returns the kind of a feature.
     def getKind(self):
         return ExportFeature.ID()
 
-    # This feature is action: has no property pannel and executes immideately
+    ## This feature is action: has no property pannel and executes immideately.
     def isAction(self):
         return True
 
-    # The action is not placed into the histiry anyway
+    # The action is not placed into the history anyway
     #def isInHistory(self):
     #    return False
 
+    ## This feature has no attributes, as it is action.
     def initAttributes(self):
-      # This feature has no attributes, it is action
       pass
-        
+
+    ## Exports all bodies
     def exportBodies(self):
-        # Get all bodies
         kResultBodyType = "Bodies"
         aPartSize = self.Part.size(kResultBodyType)
         if aPartSize == 0:
@@ -56,6 +59,7 @@ class ExportFeature(ModelAPI.ModelAPI_Feature):
             self.geompy.addToStudy(aBrep, "NewGeomShape_{0}".format(idx + 1))
             self.geomObjects.append([aShape, aBrep])
 
+    ## Exports all groups
     def exportGroups(self):
         # iterate all features to find groups
         aFeaturesNum = self.Part.size("Features")
@@ -68,7 +72,10 @@ class ExportFeature(ModelAPI.ModelAPI_Feature):
                 groupIndex = groupIndex + 1
                 self.createGroupFromList(aSelectionList, "NewGeomGroup_{0}".format(groupIndex))
                      
-    def createGroupFromList(self, theSelectionList, theGroupName):     
+    ## Creates a group by given list of selected objects and the name
+    #  @param theSelectionList: list of selected objects
+    #  @param theGroupName: name of the group to create
+    def createGroupFromList(self, theSelectionList, theGroupName):
         # iterate on all selected entities of the group
         # and get the corresponding ID
         aSelectionNum = theSelectionList.size()
@@ -95,10 +102,14 @@ class ExportFeature(ModelAPI.ModelAPI_Feature):
                 self.geompy.UnionIDs(aGroup,Ids)
                 self.geompy.addToStudyInFather(obj[1], aGroup, theGroupName)
           
+    ## Exports all shapes and groups into the GEOM module.
     def execute(self):
         aSession = ModelAPI.ModelAPI_Session.get()
+        ## Get active document
         self.Part = aSession.activeDocument()
+        ## List of objects created in the old geom for later use
         self.geomObjects = []
+        ## geomBuilder tool
         self.geompy = geomBuilder.New(salome.myStudy)
        
         # Export bodies and groups