21 #ifndef ABSTRACT_SEARCH_MODEL_H_ 22 #define ABSTRACT_SEARCH_MODEL_H_ 24 #include <QAbstractTableModel> 25 #include <QAbstractListModel> 28 #include "Utils/Library/SearchMode.h" 39 virtual QModelIndex getFirstRowIndexOf(
const QString& substr);
40 virtual QModelIndex getNextRowIndexOf(
const QString& substr,
int cur_row,
const QModelIndex& parent=QModelIndex())=0;
41 virtual QModelIndex getPrevRowIndexOf(
const QString& substr,
int cur_row,
const QModelIndex& parent=QModelIndex())=0;
43 virtual int getNumberResults(
const QString& str);
44 virtual bool has_items()
const=0;
46 virtual ::Library::SearchModeMask search_mode()
const final;
54 template <
typename Model>
67 using Model::rowCount;
69 virtual bool has_items()
const override 71 return (rowCount() > 0);
Definition: SearchableModel.h:55
Definition: SearchableModel.h:34
Definition: org_mpris_media_player2_adaptor.h:21