[−][src]Trait qmetaobject::itemmodel::QAbstractItemModel
This trait allow to override a Qt QAbstractItemModel
Required methods
fn index(&self, row: i32, column: i32, parent: QModelIndex) -> QModelIndex
Refer to the Qt documentation of QAbstractItemModel::index
fn parent(&self, index: QModelIndex) -> QModelIndex
Refer to the Qt documentation of QAbstractItemModel::parent
fn row_count(&self, parent: QModelIndex) -> i32
Refer to the Qt documentation of QAbstractItemModel::rowCount
fn column_count(&self, parent: QModelIndex) -> i32
Refer to the Qt documentation of QAbstractItemModel::columnCount
fn data(&self, index: QModelIndex, role: i32) -> QVariant
Refer to the Qt documentation of QAbstractItemModel::data
Provided methods
fn get_object_description() -> &'static QObjectDescription where
Self: Sized,
Self: Sized,
Required for the implementation detail of the QObject custom derive
fn set_data(
&mut self,
_index: QModelIndex,
_value: &QVariant,
_role: i32
) -> bool
&mut self,
_index: QModelIndex,
_value: &QVariant,
_role: i32
) -> bool
Refer to the Qt documentation of QAbstractItemModel::setData
fn role_names(&self) -> HashMap<i32, QByteArray>
Refer to the Qt documentation of QAbstractItemModel::roleNames
Methods
impl dyn QAbstractItemModel
[src]
pub fn begin_insert_rows(&self, parent: QModelIndex, first: i32, last: i32)
[src]
Refer to the Qt documentation of QAbstractListModel::beginInsertRows
pub fn end_insert_rows(&self)
[src]
Refer to the Qt documentation of QAbstractListModel::endInsertRows
pub fn begin_remove_rows(&self, parent: QModelIndex, first: i32, last: i32)
[src]
Refer to the Qt documentation of QAbstractListModel::beginRemoveRows
pub fn end_remove_rows(&self)
[src]
Refer to the Qt documentation of QAbstractListModel::endRemoveRows
pub fn begin_reset_model(&self)
[src]
Refer to the Qt documentation of QAbstractListModel::beginResetModel
pub fn end_reset_model(&self)
[src]
Refer to the Qt documentation of QAbstractListModel::endResetModel
pub fn layout_about_to_be_changed(&self)
[src]
Refer to the Qt documentation of QAbstractListModel::layoutAboutToBeChanged
update_model_indexes need to be called between layout_about_to_be_changed and layout_changed
pub fn update_model_indexes<F>(&self, f: F) where
F: FnMut(QModelIndex) -> QModelIndex,
[src]
F: FnMut(QModelIndex) -> QModelIndex,
Refer to the Qt documentation of QAbstractListModel::layoutAboutToBeChanged
update_model_indexes need to be called between layout_about_to_be_changed and layout_changed
pub fn layout_changed(&self)
[src]
Refer to the Qt documentation of QAbstractListModel::layoutChanged
update_model_indexes need to be called between layout_about_to_be_changed and layout_changed
pub fn data_changed(&self, top_left: QModelIndex, bottom_right: QModelIndex)
[src]
Refer to the Qt documentation of QAbstractListModel::dataChanged
pub fn create_index(&self, row: i32, column: i32, id: usize) -> QModelIndex
[src]
Refer to the Qt documentation of QAbstractItemModel::createIndex