LogViewer
A modern log viewer with AI-assisted analysis (Qt 6)
Loading...
Searching...
No Matches
ui::qt::DrillDownFilter Class Reference

#include <DrillDownFilter.hpp>

Collaboration diagram for ui::qt::DrillDownFilter:
Collaboration graph

Public Member Functions

void Apply (EventsTableView &view, const db::EventsContainer &events, const std::vector< unsigned long > &indices, const std::vector< unsigned long > &shown)
 Narrows view to indices. shown: the events the panel shows.
 
bool IsActive (const EventsTableView &view, const db::EventsContainer &events) const
 
const std::vector< unsigned long > & Shown () const
 The events the panel showed before the drill-down.
 
void Restore (EventsTableView &view, const db::EventsContainer &events)
 
void Reset ()
 Forgets the drill-down (the filter was replaced by someone else).
 

Private Attributes

bool m_active {false}
 
std::uint64_t m_generation {0}
 
std::vector< unsigned long > m_applied
 
std::optional< std::vector< unsigned long > > m_previous
 
std::vector< unsigned long > m_shown
 

Detailed Description

A panel's temporary "drill down" filter (timeline bucket, trace) set on top of whatever filter the rest of the application had set.

It remembers that previous filter, so Restore() brings it back instead of clearing every filter, and the events the panel showed before, so the panel can keep showing them while its own filter is active.

Member Function Documentation

◆ Apply()

void ui::qt::DrillDownFilter::Apply ( EventsTableView &  view,
const db::EventsContainer &  events,
const std::vector< unsigned long > &  indices,
const std::vector< unsigned long > &  shown 
)
inline

Narrows view to indices. shown: the events the panel shows.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ IsActive()

bool ui::qt::DrillDownFilter::IsActive ( const EventsTableView &  view,
const db::EventsContainer &  events 
) const
inline

True while the view still shows the last Apply(): nobody else changed the filter since and the data set is the same.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Reset()

void ui::qt::DrillDownFilter::Reset ( )
inline

Forgets the drill-down (the filter was replaced by someone else).

Here is the caller graph for this function:

◆ Restore()

void ui::qt::DrillDownFilter::Restore ( EventsTableView &  view,
const db::EventsContainer &  events 
)
inline

Puts back the filter that was set before Apply() (only while IsActive: a filter set by someone else since is left alone).

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Shown()

const std::vector< unsigned long > & ui::qt::DrillDownFilter::Shown ( ) const
inline

The events the panel showed before the drill-down.

Here is the caller graph for this function:

Member Data Documentation

◆ m_active

bool ui::qt::DrillDownFilter::m_active {false}
private

◆ m_applied

std::vector<unsigned long> ui::qt::DrillDownFilter::m_applied
private

◆ m_generation

std::uint64_t ui::qt::DrillDownFilter::m_generation {0}
private

◆ m_previous

std::optional<std::vector<unsigned long> > ui::qt::DrillDownFilter::m_previous
private

◆ m_shown

std::vector<unsigned long> ui::qt::DrillDownFilter::m_shown
private

The documentation for this class was generated from the following file: