Proxy model handling sorting, filtering, and column visibility for traffic data.
More...
#include <traffic_tree.h>
|
| void | filterForColumn (int column, int filterOn, QString filterText) |
| | Applies filtering criteria for a specific column.
|
| |
|
| virtual bool | filterAcceptsRow (int source_row, const QModelIndex &source_parent) const |
| | Determines if a row from the source model should be included.
|
| |
| virtual bool | filterAcceptsColumn (int source_column, const QModelIndex &source_parent) const |
| | Determines if a column from the source model should be included.
|
| |
| virtual bool | lessThan (const QModelIndex &source_left, const QModelIndex &source_right) const |
| | Compares two items for sorting.
|
| |
Proxy model handling sorting, filtering, and column visibility for traffic data.
◆ anonymous enum
Types of filtering operations available for traffic data.
| Enumerator |
|---|
| TRAFFIC_DATA_LESS | Filter for values strictly less than the target.
|
| TRAFFIC_DATA_GREATER | Filter for values strictly greater than the target.
|
| TRAFFIC_DATA_EQUAL | Filter for values equal to the target.
|
◆ TrafficDataFilterProxy()
| TrafficDataFilterProxy::TrafficDataFilterProxy |
( |
QObject * |
parent = nullptr | ) |
|
◆ columnVisible()
| bool TrafficDataFilterProxy::columnVisible |
( |
int |
column | ) |
const |
Checks if a column is currently visible.
- Parameters
-
- Returns
- True if visible, false otherwise.
◆ filterAcceptsColumn()
| bool TrafficDataFilterProxy::filterAcceptsColumn |
( |
int |
source_column, |
|
|
const QModelIndex & |
source_parent |
|
) |
| const |
|
protectedvirtual |
Determines if a column from the source model should be included.
- Parameters
-
| source_column | The source column index. |
| source_parent | The source parent index. |
- Returns
- True if the column is accepted, false otherwise.
◆ filterAcceptsRow()
| bool TrafficDataFilterProxy::filterAcceptsRow |
( |
int |
source_row, |
|
|
const QModelIndex & |
source_parent |
|
) |
| const |
|
protectedvirtual |
Determines if a row from the source model should be included.
- Parameters
-
| source_row | The source row index. |
| source_parent | The source parent index. |
- Returns
- True if the row is accepted, false otherwise.
◆ filterForColumn
| void TrafficDataFilterProxy::filterForColumn |
( |
int |
column, |
|
|
int |
filterOn, |
|
|
QString |
filterText |
|
) |
| |
|
slot |
Applies filtering criteria for a specific column.
- Parameters
-
| column | The column index to filter. |
| filterOn | The filter operation type (e.g., less, greater, equal). |
| filterText | The text value to filter against. |
◆ lessThan()
| bool TrafficDataFilterProxy::lessThan |
( |
const QModelIndex & |
source_left, |
|
|
const QModelIndex & |
source_right |
|
) |
| const |
|
protectedvirtual |
Compares two items for sorting.
- Parameters
-
| source_left | The left model index. |
| source_right | The right model index. |
- Returns
- True if the left item is less than the right item, false otherwise.
◆ setColumnVisibility()
| void TrafficDataFilterProxy::setColumnVisibility |
( |
int |
column, |
|
|
bool |
visible |
|
) |
| |
Sets the visibility for a specific column.
- Parameters
-
| column | The column index. |
| visible | True to show the column, false to hide it. |
The documentation for this class was generated from the following files: