Filters and sorts data coming from a source QAbstractItemModel More...
Import Statement: | import . |
The SortFilterProxyModel type provides support for filtering and sorting data coming from a source model.
filters : list<Filter> |
This property holds the list of filters for this proxy model. To be included in the model, a row of the source model has to be accepted by all the top level filters of this list.
See also Filter.
proxyRoles : list<ProxyRole> |
This property holds the list of proxy roles for this proxy model. Each proxy role adds a new custom role to the model.
See also ProxyRole.
The role name of the source model's data used for the sorting.
See also sortRole and roleForName.
sorters : list<Sorter> |
This property holds the list of sorters for this proxy model. The rows of the source model are sorted by the sorters of this list, in their order of insertion.
See also Sorter.
Return the data for the given roleNamte of the item at row in the proxy model. This allows the role data to be read (not modified) from JavaScript. This equivalent to calling data(index(row, 0), roleForName(roleName))
.
Return the item at row in the proxy model as a map of all its roles. This allows the item data to be read (not modified) from JavaScript.
Returns the row in the SortFilterProxyModel given the sourceRow from the source model. Returns -1 if there is no corresponding row.
Returns the model index in the SortFilterProxyModel given the sourceIndex from the source model.
Returns the source model row corresponding to the given proxyRow from the SortFilterProxyModel. Returns -1 if there is no corresponding row.
Returns the source model index corresponding to the given proxyIndex from the SortFilterProxyModel.
Returns the role number for the given roleName. If no role is found for this roleName, -1
is returned.