Salome HOME
Fix for the problem of selection of the circle center as a start point of line of...
[modules/shaper.git] / src / SketchPlugin / SketchPlugin_Plugin.h
index fad6fa739df89b3b55d9a66ede701a2dd67bc863..b4a17a408bdc41202233b4cbc01ee039d2350681 100644 (file)
@@ -1,8 +1,22 @@
-// Copyright (C) 2014-20xx CEA/DEN, EDF R&D -->
-
-// File:        SketchPlugin_Plugin.hxx
-// Created:     31 Mar 2014
-// Author:      Mikhail PONIKAROV
+// Copyright (C) 2014-2017  CEA/DEN, EDF R&D
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or
+// email : webmaster.salome@opencascade.com<mailto:webmaster.salome@opencascade.com>
+//
 
 #ifndef SKETCHPLUGIN_PLUGIN_H_
 #define SKETCHPLUGIN_PLUGIN_H_
 #include <ModelAPI_Feature.h>
 #include <ModelAPI_Events.h>
 
-class SKETCHPLUGIN_EXPORT SketchPlugin_Plugin : public ModelAPI_Plugin, public Events_Listener
+/**\class SketchPlugin_Plugin
+ * \ingroup Plugins
+ * \brief Interface common for any plugin: allows to use plugin by the plugins manager.
+ */
+class 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);
+  SKETCHPLUGIN_EXPORT virtual FeaturePtr createFeature(std::string theFeatureID);
+
+  /// Constructor that registers features and other plugin elements.
+  SKETCHPLUGIN_EXPORT SketchPlugin_Plugin();
 
- public:
-  /// Is needed for python wrapping by swig
-  SketchPlugin_Plugin();
   //! Redefinition of Events_Listener method
-  virtual void processEvent(const std::shared_ptr<Events_Message>& theMessage);
- protected:
+  SKETCHPLUGIN_EXPORT virtual void processEvent(const std::shared_ptr<Events_Message>& theMessage);
+
+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;
 };