Wt: Wt::WAbstractProxyModel::BaseItem Struct Reference

Wt 3.3.0

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes

- Class List
- Class Hierarchy
- Class Members

Public Member Functions | Public Attributes
Wt::WAbstractProxyModel::BaseItem Struct Reference

A base class for an item modeling a source index parent. More...

Inherited by Wt::WBatchEditProxyModel::Item.

List of all members.

## Public Member Functions
| BaseItem (const WModelIndex &sourceIndex)
| Create a BaseItem.
## Public Attributes
WModelIndex | sourceIndex_
| The source model index.

## Detailed Description

A base class for an item modeling a source index parent.

Many mplementations of a proxy model will need to maintain a data structure per source model indexes, where they relate source rows or columns to proxy rows or columns, per hierarchical parent.

It may be convenient to start from this item class as a base class so that shiftModelIndexes() can be used to update this data structure when the source model adds or removes rows.

You will typically use your derived class of this item as the internal pointer for proxy model indexes: a proxy model index will have an item as internal pointer whose sourceIndex_ corresponds to the source equivalent of the proxy model index parent.

See also:
  createIndex()

## Member Data Documentation

WModelIndex Wt::WAbstractProxyModel::BaseItem::sourceIndex_

The source model index.

The source model index for this item.

All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator