2024.8.23
|
Public Member Functions | |
__construct () | |
getBrowser () | |
getDefaultLang () | |
getDownloadId () | |
getHostname () | |
getLang () | |
getLogsVerbose () | |
getMaxLogsArchives () | |
getNotepad () | |
getRaw ($key) | |
getScriptsTimeout () | |
getTimezone () | |
isLaunchStartup () | |
isOnline () | |
replace ($key, $value) | |
replaceAll ($params) | |
Data Fields | |
const | CFG_BROWSER = 'browser' |
const | CFG_DEFAULT_LANG = 'defaultLang' |
const | CFG_HOSTNAME = 'hostname' |
const | CFG_LANG = 'lang' |
const | CFG_LAUNCH_STARTUP = 'launchStartup' |
const | CFG_LOGS_VERBOSE = 'logsVerbose' |
const | CFG_MAX_LOGS_ARCHIVES = 'maxLogsArchives' |
const | CFG_NOTEPAD = 'notepad' |
const | CFG_ONLINE = 'online' |
const | CFG_SCRIPTS_TIMEOUT = 'scriptsTimeout' |
const | CFG_TIMEZONE = 'timezone' |
const | DISABLED = 0 |
const | DOWNLOAD_ID = 'DownloadId' |
const | ENABLED = 1 |
const | VERBOSE_DEBUG = 2 |
const | VERBOSE_REPORT = 1 |
const | VERBOSE_SIMPLE = 0 |
const | VERBOSE_TRACE = 3 |
Private Attributes | |
$raw | |
Class Config
This class handles the configuration settings for the Bearsampp application. It reads the configuration from an INI file and provides methods to access and modify these settings.
Definition at line 16 of file class.config.php.
Config::__construct | ( | ) |
Constructs a Config object and initializes the configuration settings. Reads the configuration from the INI file and sets the default timezone.
Definition at line 46 of file class.config.php.
References $bearsamppRoot, and getTimezone().
Config::getBrowser | ( | ) |
Retrieves the browser setting from the configuration.
Definition at line 162 of file class.config.php.
References CFG_BROWSER.
Config::getDefaultLang | ( | ) |
Retrieves the default language setting from the configuration.
Definition at line 112 of file class.config.php.
References CFG_DEFAULT_LANG.
Config::getDownloadId | ( | ) |
Retrieves the license key from the configuration.
Definition at line 132 of file class.config.php.
References DOWNLOAD_ID.
Config::getHostname | ( | ) |
Retrieves the hostname setting from the configuration.
Definition at line 172 of file class.config.php.
References CFG_HOSTNAME.
Config::getLang | ( | ) |
Retrieves the language setting from the configuration.
Definition at line 102 of file class.config.php.
References CFG_LANG.
Config::getLogsVerbose | ( | ) |
Retrieves the logs verbosity setting from the configuration.
Definition at line 202 of file class.config.php.
Config::getMaxLogsArchives | ( | ) |
Retrieves the maximum logs archives setting from the configuration.
Definition at line 212 of file class.config.php.
Config::getNotepad | ( | ) |
Retrieves the notepad setting from the configuration.
Definition at line 192 of file class.config.php.
References CFG_NOTEPAD.
Config::getRaw | ( | $key | ) |
Retrieves the raw configuration value for the specified key.
string | $key | The configuration key. |
Definition at line 61 of file class.config.php.
Config::getScriptsTimeout | ( | ) |
Retrieves the scripts timeout setting from the configuration.
Definition at line 182 of file class.config.php.
Config::getTimezone | ( | ) |
Retrieves the timezone setting from the configuration.
Definition at line 122 of file class.config.php.
References CFG_TIMEZONE.
Referenced by __construct().
Config::isLaunchStartup | ( | ) |
Checks if the application is set to launch at startup.
Definition at line 152 of file class.config.php.
References CFG_LAUNCH_STARTUP, and ENABLED.
Config::isOnline | ( | ) |
Checks if the application is set to be online.
Definition at line 142 of file class.config.php.
References CFG_ONLINE, and ENABLED.
Config::replace | ( | $key, | |
$value ) |
Replaces a single configuration value with the specified key and value.
string | $key | The configuration key. |
mixed | $value | The new configuration value. |
Definition at line 72 of file class.config.php.
References replaceAll().
Config::replaceAll | ( | $params | ) |
Replaces multiple configuration values with the specified key-value pairs.
array | $params | An associative array of key-value pairs to replace. |
Definition at line 82 of file class.config.php.
References $bearsamppRoot, and Util\logTrace().
Referenced by replace().
|
private |
Definition at line 40 of file class.config.php.
const Config::CFG_BROWSER = 'browser' |
Definition at line 28 of file class.config.php.
Referenced by ActionReload\__construct(), ActionStartup\checkBrowser(), getBrowser(), and ActionChangeBrowser\processWindow().
const Config::CFG_DEFAULT_LANG = 'defaultLang' |
Definition at line 26 of file class.config.php.
Referenced by getDefaultLang().
const Config::CFG_HOSTNAME = 'hostname' |
Definition at line 27 of file class.config.php.
Referenced by ActionReload\__construct(), getHostname(), and ActionStartup\refreshHostname().
const Config::CFG_LANG = 'lang' |
Definition at line 20 of file class.config.php.
Referenced by ActionSwitchLang\__construct(), and getLang().
const Config::CFG_LAUNCH_STARTUP = 'launchStartup' |
Definition at line 30 of file class.config.php.
Referenced by ActionLaunchStartup\__construct(), ActionReload\__construct(), and isLaunchStartup().
const Config::CFG_LOGS_VERBOSE = 'logsVerbose' |
Definition at line 19 of file class.config.php.
Referenced by ActionSwitchLogsVerbose\__construct().
const Config::CFG_MAX_LOGS_ARCHIVES = 'maxLogsArchives' |
Definition at line 18 of file class.config.php.
const Config::CFG_NOTEPAD = 'notepad' |
Definition at line 22 of file class.config.php.
Referenced by getNotepad().
const Config::CFG_ONLINE = 'online' |
Definition at line 29 of file class.config.php.
Referenced by ActionSwitchOnline\__construct(), and isOnline().
const Config::CFG_SCRIPTS_TIMEOUT = 'scriptsTimeout' |
Definition at line 23 of file class.config.php.
const Config::CFG_TIMEZONE = 'timezone' |
Definition at line 21 of file class.config.php.
Referenced by getTimezone().
const Config::DISABLED = 0 |
Definition at line 33 of file class.config.php.
Referenced by ActionReload\__construct(), ActionSwitchOnline\__construct(), TplAppApache\getMenuApache(), TplAppFilezilla\getMenuFilezilla(), TplAppGit\getMenuGit(), TplAppMailhog\getMenuMailhog(), TplAppMailpit\getMenuMailpit(), TplAppMariadb\getMenuMariadb(), TplAppMemcached\getMenuMemcached(), TplAppMysql\getMenuMysql(), TplAppNodejs\getMenuNodejs(), TplAppPhp\getMenuPhp(), TplAppPostgresql\getMenuPostgresql(), TplAppXlight\getMenuXlight(), TplAppLaunchStartup\process(), TplAppOnline\process(), BinApache\setEnable(), BinFilezilla\setEnable(), BinMailhog\setEnable(), BinMailpit\setEnable(), BinMariadb\setEnable(), BinMemcached\setEnable(), BinMysql\setEnable(), BinNodejs\setEnable(), BinPhp\setEnable(), BinPostgresql\setEnable(), and BinXlight\setEnable().
const Config::DOWNLOAD_ID = 'DownloadId' |
Definition at line 24 of file class.config.php.
Referenced by getDownloadId().
const Config::ENABLED = 1 |
Definition at line 32 of file class.config.php.
Referenced by ActionLaunchStartup\__construct(), ActionReload\__construct(), ActionSwitchOnline\__construct(), TplAppApache\getMenuApache(), TplAppFilezilla\getMenuFilezilla(), TplAppGit\getMenuGit(), TplAppMailhog\getMenuMailhog(), TplAppMailpit\getMenuMailpit(), TplAppMariadb\getMenuMariadb(), TplAppMemcached\getMenuMemcached(), TplAppMysql\getMenuMysql(), TplAppNodejs\getMenuNodejs(), TplAppPhp\getMenuPhp(), TplAppPostgresql\getMenuPostgresql(), TplAppXlight\getMenuXlight(), isLaunchStartup(), isOnline(), ToolGit\isScanStartup(), TplAppLaunchStartup\process(), TplAppOnline\process(), BinApache\setEnable(), BinFilezilla\setEnable(), BinMailhog\setEnable(), BinMailpit\setEnable(), BinMariadb\setEnable(), BinMemcached\setEnable(), BinMysql\setEnable(), BinNodejs\setEnable(), BinPhp\setEnable(), BinPostgresql\setEnable(), and BinXlight\setEnable().
const Config::VERBOSE_DEBUG = 2 |
Definition at line 37 of file class.config.php.
Referenced by TplAppLogsVerbose\getMenuLogsVerbose(), and Util\log().
const Config::VERBOSE_REPORT = 1 |
Definition at line 36 of file class.config.php.
Referenced by TplAppLogsVerbose\getMenuLogsVerbose(), and Util\log().
const Config::VERBOSE_SIMPLE = 0 |
Definition at line 35 of file class.config.php.
Referenced by TplAppLogsVerbose\getMenuLogsVerbose(), and Util\log().
const Config::VERBOSE_TRACE = 3 |
Definition at line 38 of file class.config.php.
Referenced by TplAppLogsVerbose\getMenuLogsVerbose(), and Util\log().