1. Overview
Compact GTK statistics page that displays allowed, denied, and total connection counters for the current application session.
File role: Implementation. The file contains 61 lines and belongs to the pages/StatsPage.cpp path.
The companion file is pages/StatsPage.hpp.
2. Component Responsibilities
- Implement the behavior declared by the corresponding header or entry-point contract.
- Build the three-value statistics grid
- Receive updated counters from the main window
- Format and display the allowed, denied, and total values
3. Dependencies and Integration
Project-level dependencies:
StatsPage.hppglibmm/i18n.h
4. Functions and Methods
The file exposes or implements 3 detected function or method signatures.
1. StatsPage
StatsPage::StatsPage() : Gtk::Box(Gtk::Orientation::VERTICAL, 16)
Implements the stats page operation declared by this component.
2. buildGrid
void StatsPage::buildGrid()
Builds and configures the grid user-interface or internal structure.
3. updateStats
void StatsPage::updateStats(uint64_t allowed, uint64_t denied, uint64_t total)
Updates stats using the latest runtime data.
5. Runtime Flow
- Build the three-value statistics grid
- Receive updated counters from the main window
- Format and display the allowed, denied, and total values
6. Runtime and Security Considerations
- Displays aggregate counters only and does not store sensitive connection details.
7. Error Handling and Operational Notes
- Errors are propagated through the return type, callbacks, or the owning controller.
8. Source Integrity
Relative source path: pages/StatsPage.cpp
SHA-256:
bfac6865cbb66a05527bf0a1eace415440d2c17f04543d39ce172052ebc94618
9. Licensing
No standalone license block is present in this file. Licensing follows the surrounding BastionGuard Secure Connection project and its accompanying source notices.
