Salome HOME
Merge branch 'master' into Dev_1.1.0
[modules/shaper.git] / src / ModuleBase / ModuleBase_FilterCustom.h
1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
2
3 // File:        ModuleBase_FilterCustom.h
4 // Created:     10 Dec 2014
5 // Author:      Natalia ERMOLAEVA
6
7 #ifndef ModuleBase_FilterCustom_H
8 #define ModuleBase_FilterCustom_H
9
10 #include "ModuleBase.h"
11
12 #include "ModuleBase_Filter.h"
13
14 /**
15 * \ingroup GUI
16 * This is a child of ModuleBase_Filter to be used in the factory of filters. Despite of other
17 * child it does not create the internal filter itself, it get it from the constructor argument.
18 * This is useful for custom filters, which are not the standard OCC filters. It is not necessary
19 * to redefine the ModuleBase_Filter. The filter is realized and put here as the class parameter.
20 */
21
22 class ModuleBase_FilterCustom: public ModuleBase_Filter
23 {
24 public:
25   /**
26    * Constructor
27    * \param theFilter an OCC filter to be used in the parent base filter
28    */
29   MODULEBASE_EXPORT ModuleBase_FilterCustom(Handle(SelectMgr_Filter) theFilter); 
30
31   /**
32    * Sets the arguments to the filter. Currently it is not used in this filter.
33    * \param theArguments a list of arguments
34    */
35   MODULEBASE_EXPORT virtual void setArguments(const std::list<std::string>& theArguments);
36
37 protected:
38   /**
39    * It creates an OCC filter. The realization is empty because the filter is set through the constructor
40    */
41   virtual void createFilter();
42
43 };
44
45 #endif //ModuleBase_FilterCustom