1 #ifndef CSM_WOLRD_RESOURCETABLE_H
2 #define CSM_WOLRD_RESOURCETABLE_H
21 virtual int rowCount (
const QModelIndex &
parent = QModelIndex())
const;
25 virtual QVariant
data (
const QModelIndex &
index,
int role = Qt::DisplayRole)
const;
27 virtual QVariant
headerData (
int section, Qt::Orientation orientation,
int role = Qt::DisplayRole)
const;
29 virtual bool setData (
const QModelIndex &
index,
const QVariant &value,
int role = Qt::EditRole);
31 virtual Qt::ItemFlags
flags (
const QModelIndex &
index)
const;
33 virtual QModelIndex
index (
int row,
int column,
const QModelIndex&
parent = QModelIndex())
36 virtual QModelIndex
parent (
const QModelIndex&
index)
const;
38 virtual QModelIndex
getModelIndex (
const std::string&
id,
int column)
const;
50 virtual std::pair<UniversalId, std::string>
view (
int row)
const;
53 virtual bool isDeleted (
const std::string&
id)
const;
virtual QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const
Definition: resourcetable.cpp:31
virtual bool setData(const QModelIndex &index, const QVariant &value, int role=Qt::EditRole)
Definition: resourcetable.cpp:80
virtual QVariant headerData(int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const
Definition: resourcetable.cpp:45
virtual Qt::ItemFlags flags(const QModelIndex &index) const
Definition: resourcetable.cpp:86
const Resources * mResources
Definition: resourcetable.hpp:12
virtual int getColumnId(int column) const
Definition: resourcetable.cpp:147
virtual std::pair< UniversalId, std::string > view(int row) const
Definition: resourcetable.cpp:137
virtual ~ResourceTable()
Definition: resourcetable.cpp:13
Definition: resources.hpp:17
virtual int findColumnIndex(Columns::ColumnId id) const
Definition: resourcetable.cpp:127
ResourceTable(const Resources *resources, unsigned int features=0)
Definition: resourcetable.cpp:9
virtual QModelIndex getModelIndex(const std::string &id, int column) const
Definition: resourcetable.cpp:111
virtual int columnCount(const QModelIndex &parent=QModelIndex()) const
Definition: resourcetable.cpp:23
virtual bool isDeleted(const std::string &id) const
Is id flagged as deleted?
Definition: resourcetable.cpp:142
virtual QModelIndex index(int row, int column, const QModelIndex &parent=QModelIndex()) const
Definition: resourcetable.cpp:91
ColumnId
Definition: columns.hpp:13
Definition: idtablebase.hpp:12
Definition: resourcetable.hpp:10
virtual int searchColumnIndex(Columns::ColumnId id) const
Definition: resourcetable.cpp:116
virtual int rowCount(const QModelIndex &parent=QModelIndex()) const
Definition: resourcetable.cpp:15
virtual QModelIndex parent(const QModelIndex &index) const
Definition: resourcetable.cpp:106