Table model that exposes a list of VoIP call records for display in the VoIP Calls dialog, supporting both relative and time-of-day timestamp formatting.
More...
#include <voip_calls_info_model.h>
|
| enum | Column {
StartTime
, StopTime
, InitialSpeaker
, From
,
To
, Protocol
, Duration
, Packets
,
State
, Comments
, ColumnCount
} |
| | Column indices for the VoIP calls table. More...
|
| |
|
| | VoipCallsInfoModel (QObject *parent=0) |
| | Constructs the model with an empty call list.
|
| |
| QVariant | data (const QModelIndex &index, int role=Qt::DisplayRole) const |
| | Returns display or decoration data for the given cell.
|
| |
| QVariant | headerData (int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const |
| | Returns column header labels for the VoIP calls table.
|
| |
| int | rowCount (const QModelIndex &parent=QModelIndex()) const |
| | Returns the number of call records currently held by the model.
|
| |
| int | columnCount (const QModelIndex &parent=QModelIndex()) const |
| | Returns the number of columns in the model.
|
| |
| void | setTimeOfDay (bool timeOfDay) |
| | Controls whether timestamps are shown as time-of-day or relative times.
|
| |
| bool | timeOfDay () const |
| | Returns whether timestamps are currently shown as time-of-day values.
|
| |
| void | updateCalls (GQueue *callsinfos) |
| | Replaces the model's call list with the contents of callsinfos and notifies the view to refresh.
|
| |
|
void | removeAllCalls () |
| | Removes all call records from the model and notifies the view.
|
| |
Table model that exposes a list of VoIP call records for display in the VoIP Calls dialog, supporting both relative and time-of-day timestamp formatting.
◆ Column
Column indices for the VoIP calls table.
| Enumerator |
|---|
| StartTime | Timestamp of the first packet in the call.
|
| StopTime | Timestamp of the last packet in the call.
|
| InitialSpeaker | Address of the party that initiated the call.
|
| From | Calling party address or URI.
|
| To | Called party address or URI.
|
| Protocol | Signalling protocol (e.g. SIP, H.323).
|
| Duration | Total duration of the call.
|
| Packets | Number of packets belonging to the call.
|
| State | Current call state (e.g. CALL, COMPLETED).
|
| Comments | Free-text comments or extra protocol info.
|
| ColumnCount | Sentinel value; not an actual column.
|
◆ VoipCallsInfoModel()
| VoipCallsInfoModel::VoipCallsInfoModel |
( |
QObject * |
parent = 0 | ) |
|
Constructs the model with an empty call list.
- Parameters
-
| parent | Optional parent QObject. |
◆ columnCount()
| int VoipCallsInfoModel::columnCount |
( |
const QModelIndex & |
parent = QModelIndex() | ) |
const |
Returns the number of columns in the model.
- Parameters
-
- Returns
- Number of columns (Column::ColumnCount).
◆ data()
| QVariant VoipCallsInfoModel::data |
( |
const QModelIndex & |
index, |
|
|
int |
role = Qt::DisplayRole |
|
) |
| const |
Returns display or decoration data for the given cell.
- Parameters
-
| index | Model index of the cell to query. |
| role | Qt item data role. |
- Returns
- The requested data, or an invalid QVariant if not applicable.
◆ headerData()
| QVariant VoipCallsInfoModel::headerData |
( |
int |
section, |
|
|
Qt::Orientation |
orientation, |
|
|
int |
role = Qt::DisplayRole |
|
) |
| const |
Returns column header labels for the VoIP calls table.
- Parameters
-
| section | Column index. |
| orientation | Qt::Horizontal for column headers. |
| role | Qt item data role. |
- Returns
- Header label string, or an invalid QVariant if not applicable.
◆ indexToCallInfo()
Returns the voip_calls_info_t record associated with index.
- Parameters
-
| index | Model index whose row identifies the call record. |
- Returns
- Pointer to the voip_calls_info_t, or
nullptr if the index is invalid.
◆ rowCount()
| int VoipCallsInfoModel::rowCount |
( |
const QModelIndex & |
parent = QModelIndex() | ) |
const |
Returns the number of call records currently held by the model.
- Parameters
-
| parent | Unused; must be an invalid index for table models. |
- Returns
- Number of rows.
◆ setTimeOfDay()
| void VoipCallsInfoModel::setTimeOfDay |
( |
bool |
timeOfDay | ) |
|
Controls whether timestamps are shown as time-of-day or relative times.
- Parameters
-
| timeOfDay | true to display absolute time-of-day; false for relative. |
◆ timeOfDay()
| bool VoipCallsInfoModel::timeOfDay |
( |
| ) |
const |
Returns whether timestamps are currently shown as time-of-day values.
- Returns
true if time-of-day display is active.
◆ updateCalls()
| void VoipCallsInfoModel::updateCalls |
( |
GQueue * |
callsinfos | ) |
|
Replaces the model's call list with the contents of callsinfos and notifies the view to refresh.
- Parameters
-
| callsinfos | GQueue of voip_calls_info_t pointers to display. |
The documentation for this class was generated from the following files:
- /builds/wireshark/wireshark/ui/qt/models/voip_calls_info_model.h
- /builds/wireshark/wireshark/ui/qt/models/voip_calls_info_model.cpp