#include <set>
/**
+ * \ingroup GUI
* Allows to get a selection filter by the feature identifier and
* the attribute identifier (if attribute is validated).
* All accessible filters must be registered by the ID string first.
class ModuleBase_FilterFactory : public QObject
{
private:
- std::map<std::string, Handle_ModuleBase_Filter> myIDs; ///< map from ID to registered filter
+ std::map<std::string, ModuleBase_Filter*> myIDs; ///< map from ID to registered filter
/// filters IDs to list of arguments
typedef std::map<std::string, std::list<std::string> > AttrFilters;
/// filters IDs by feature ID
public:
/// Registers the instance of the filter by the ID
MODULEBASE_EXPORT virtual void registerFilter(const std::string& theID,
- Handle_ModuleBase_Filter theFilter);
+ ModuleBase_Filter* theFilter);
/// Assigns filter to the attribute of the feature
MODULEBASE_EXPORT virtual void assignFilter(const std::string& theID,
const std::string& theFeatureID,
- const std::string& theAttrID);
+ const std::string& theAttrID,
+ const std::list<std::string>& theArguments);
/// Provides a filter for the attribute, returns NULL if no filter
MODULEBASE_EXPORT void filters(const std::string& theFeatureID,
SelectMgr_ListOfFilter& theFilters) const;
/// Returns registered filter by its Id
- MODULEBASE_EXPORT virtual const Handle_ModuleBase_Filter filter(const std::string& theID) const;
+ MODULEBASE_EXPORT virtual const ModuleBase_Filter* filter(const std::string& theID) const;
protected:
ModuleBase_FilterFactory();