Class sh::scripting::api::ApiSearchCriterionFactory

class sh::scripting::api::ApiSearchCriterionFactory : public sh::search::SearchCriterionFactory

Public Functions

ApiSearchCriterionFactory(QString key, QString description)
QString key()

Returns the string key for the associated search criterion class. .

QString description()

Returns the description string for the associated search criterion class. .

void editor(std::shared_ptr<sh::search::SearchCriterion> c, sh::ui::SearchPanelConfiguration *panelcfg)
void editorupdateconfig(sh::ui::SearchPanelConfiguration *panelcfg, std::shared_ptr<sh::search::SearchCriterion> c)
std::shared_ptr<sh::search::SearchCriterion> construct()

Constructs an instance of the associated search criterion class. .

bool isVisibleFor(sh::filesystem::Operation *op, std::shared_ptr<sh::filesystem::FilesystemNode> node)

Checks if the associated search criterion class should be offered to the user for a given node. .

void editor(std::shared_ptr<sh::search::SearchCriterion> c, sh::ui::SearchPanelConfiguration *panelcfg) = 0

Builds the search config ui in a search panel.

Takes the data from c and populates panelcfg with it.

void editorupdateconfig(sh::ui::SearchPanelConfiguration *panelcfg, std::shared_ptr<sh::search::SearchCriterion> c) = 0

Updates own data with the content from the search config ui in a search panel.

Takes the data from panelcfg and updates c with it.

Public Members

std::function<QString(QList<QString>)> _getsearchspecdesc
std::function< std::shared_ptr< sh::search::SearchCriterion >)> _construct
std::function<bool(sh::filesystem::Operation*, std::shared_ptr<sh::filesystem::FilesystemNode>)> _isVisibleFor