Salome HOME
6683207cc2fcff56103105f91d37a80aa6ebc895
[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 * This is a child of ModuleBase_Filter to be used in the factory of filters. Despite of other
16 * child it does not create the internal filter itself, it get it from the constructor argument.
17 * This is useful for custom filters, which are not the standard OCC filters. It is not necessary
18 * to redefine the ModuleBase_Filter. The filter is realized and put here as the class parameter.
19 */
20
21 class ModuleBase_FilterCustom: public ModuleBase_Filter
22 {
23 public:
24   /**
25    * Constructor
26    * \param theFilter an OCC filter to be used in the parent base filter
27    */
28   MODULEBASE_EXPORT ModuleBase_FilterCustom(Handle(SelectMgr_Filter) theFilter); 
29
30   /**
31    * Sets the arguments to the filter. Currently it is not used in this filter.
32    * \param theArguments a list of arguments
33    */
34   MODULEBASE_EXPORT virtual void setArguments(const std::list<std::string>& theArguments);
35
36 protected:
37   /**
38    * It creates an OCC filter. The realization is empty because the filter is set through the constructor
39    */
40   virtual void createFilter();
41
42 };
43
44 #endif //ModuleBase_FilterCustom