|
ACAV f0ba4b7c9529
Abstract Syntax Tree (AST) visualization tool for C, C++, and Objective-C
|
Application configuration manager. More...
#include <AppConfig.h>
Public Member Functions | |
| QString | getConfigFilePath () const |
| Get the path to the currently loaded configuration file. | |
| bool | reload () |
| Reload settings from the config file on disk. | |
| QString | getCacheDirectory (const QString &compilationDatabasePath) const |
| Get the cache directory for a compilation database. | |
| QString | getDependenciesFilePath (const QString &compilationDatabasePath) const |
| Get the dependencies JSON file path for a compilation database. | |
| QString | getAstCacheDirectory (const QString &compilationDatabasePath) const |
| Get the AST cache directory for a compilation database. | |
| QString | getAstFilePath (const QString &compilationDatabasePath, const QString &sourceFilePath) const |
| Get the AST cache file path for a source file. | |
| QString | getMetadataFilePath (const QString &compilationDatabasePath) const |
| Get the metadata JSON file path for a compilation database. | |
| QString | getBuildDirectory (const QString &compilationDatabasePath) const |
| Get the build directory from cached metadata. | |
| bool | getCommentExtractionEnabled () const |
| Whether to extract and display comments in AST (default: false). | |
| bool | getMemoryProfilingEnabled () const |
| Whether memory profiling checkpoints are enabled (default: false). | |
| QString | getCacheRoot () const |
| Custom cache root directory (default: ~/.cache/acav/). | |
| int | getFontSize () const |
| Editor/UI font size (default: 11). | |
| QString | getFontFamily () const |
| Editor/UI font family (default: empty = system default). | |
| int | getParallelProcessorCount () const |
| Number of parallel processors for query-dependencies (default: 0 = auto) 0 means use all available CPU cores, otherwise use the specified count. | |
Static Public Member Functions | |
| static void | initialize (const QString &configFilePath=QString()) |
| Initialize the singleton with a custom config file path. | |
| static AppConfig & | instance () |
| Get the singleton instance. | |
Application configuration manager.
Manages application settings including cache directories for storing query-dependencies output and other cached data. Uses an INI configuration file that users can edit directly.
Default config file: ~/.acav Default cache directory: ~/.cache/acav/
Definition at line 42 of file AppConfig.h.
| QString acav::AppConfig::getAstCacheDirectory | ( | const QString & | compilationDatabasePath | ) | const |
Get the AST cache directory for a compilation database.
| compilationDatabasePath | Path to compile_commands.json |
Definition at line 328 of file AppConfig.cpp.
References getCacheDirectory().
Referenced by getAstFilePath().
| QString acav::AppConfig::getAstFilePath | ( | const QString & | compilationDatabasePath, |
| const QString & | sourceFilePath ) const |
Get the AST cache file path for a source file.
| compilationDatabasePath | Path to compile_commands.json |
| sourceFilePath | Path to source file |
Definition at line 341 of file AppConfig.cpp.
References getAstCacheDirectory().
| QString acav::AppConfig::getBuildDirectory | ( | const QString & | compilationDatabasePath | ) | const |
Get the build directory from cached metadata.
| compilationDatabasePath | Path to compile_commands.json |
Definition at line 273 of file AppConfig.cpp.
References getMetadataFilePath().
| QString acav::AppConfig::getCacheDirectory | ( | const QString & | compilationDatabasePath | ) | const |
Get the cache directory for a compilation database.
| compilationDatabasePath | Path to compile_commands.json |
Definition at line 249 of file AppConfig.cpp.
Referenced by getAstCacheDirectory(), getDependenciesFilePath(), getMetadataFilePath(), and acav::MainWindow::loadCompilationDatabase().
| QString acav::AppConfig::getCacheRoot | ( | ) | const |
Custom cache root directory (default: ~/.cache/acav/).
Definition at line 358 of file AppConfig.cpp.
| bool acav::AppConfig::getCommentExtractionEnabled | ( | ) | const |
Whether to extract and display comments in AST (default: false).
Definition at line 350 of file AppConfig.cpp.
| QString acav::AppConfig::getConfigFilePath | ( | ) | const |
Get the path to the currently loaded configuration file.
Definition at line 133 of file AppConfig.cpp.
| QString acav::AppConfig::getDependenciesFilePath | ( | const QString & | compilationDatabasePath | ) | const |
Get the dependencies JSON file path for a compilation database.
| compilationDatabasePath | Path to compile_commands.json |
Definition at line 261 of file AppConfig.cpp.
References getCacheDirectory().
Referenced by acav::MainWindow::loadCompilationDatabase().
| QString acav::AppConfig::getFontFamily | ( | ) | const |
Editor/UI font family (default: empty = system default).
Definition at line 229 of file AppConfig.cpp.
| int acav::AppConfig::getFontSize | ( | ) | const |
Editor/UI font size (default: 11).
Definition at line 227 of file AppConfig.cpp.
| bool acav::AppConfig::getMemoryProfilingEnabled | ( | ) | const |
Whether memory profiling checkpoints are enabled (default: false).
Definition at line 354 of file AppConfig.cpp.
| QString acav::AppConfig::getMetadataFilePath | ( | const QString & | compilationDatabasePath | ) | const |
Get the metadata JSON file path for a compilation database.
| compilationDatabasePath | Path to compile_commands.json |
Definition at line 267 of file AppConfig.cpp.
References getCacheDirectory().
Referenced by getBuildDirectory().
| int acav::AppConfig::getParallelProcessorCount | ( | ) | const |
Number of parallel processors for query-dependencies (default: 0 = auto) 0 means use all available CPU cores, otherwise use the specified count.
Definition at line 231 of file AppConfig.cpp.
|
static |
Initialize the singleton with a custom config file path.
| configFilePath | Path to INI config file (empty = use default) Must be called before instance() - typically in main() |
Definition at line 103 of file AppConfig.cpp.
|
static |
Get the singleton instance.
Definition at line 120 of file AppConfig.cpp.
Referenced by acav::MainWindow::loadCompilationDatabase().
| bool acav::AppConfig::reload | ( | ) |
Reload settings from the config file on disk.
Definition at line 137 of file AppConfig.cpp.