mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-19 20:25:29 +08:00
refs #478, updated project
* use env. variables to set status of project (dev.environment, local setup dir) * convert project to string
This commit is contained in:
committed by
Mathew Sutcliffe
parent
2d46a93676
commit
4fce848c59
@@ -18,7 +18,6 @@
|
||||
|
||||
namespace BlackMisc
|
||||
{
|
||||
|
||||
/*!
|
||||
* Metadata about the project
|
||||
*/
|
||||
@@ -55,9 +54,6 @@ namespace BlackMisc
|
||||
//! with GUI?
|
||||
static bool isCompiledWithGui();
|
||||
|
||||
//! Info string about compilation
|
||||
static const QString &compiledInfo();
|
||||
|
||||
//! Simulator String info
|
||||
static const BlackMisc::Simulation::CSimulatorInfo &simulators();
|
||||
|
||||
@@ -97,6 +93,9 @@ namespace BlackMisc
|
||||
//! Running in dev.environment, so on a programmers machine
|
||||
static bool isRunningInDeveloperEnvironment();
|
||||
|
||||
//! Use development setup?
|
||||
static bool useDevelopmentSetup();
|
||||
|
||||
//! Beta / dev.environment?
|
||||
static bool isRunningInBetaOrDeveloperEnvironment();
|
||||
|
||||
@@ -106,16 +105,57 @@ namespace BlackMisc
|
||||
//! Where resource files (static DB files, ...) etc are located
|
||||
static QString getSwiftResourceDir();
|
||||
|
||||
//! Private resource dir for developer's own resource files
|
||||
static QString getSwiftPrivateResourceDir();
|
||||
|
||||
//! Where resource files (static DB files, ...) etc are located
|
||||
static QString getSwiftStaticDbFilesDir();
|
||||
|
||||
//! Dump all env.variables
|
||||
static QString getEnvironmentVariables(const QString &separator = QString("\n"));
|
||||
|
||||
//! Info string about compilation
|
||||
static const QString &compiledWithInfo(bool shortVersion = true);
|
||||
|
||||
//! Env.information
|
||||
static QString environmentInfo(const QString &separator = QString("\n"));
|
||||
|
||||
//! Whole info
|
||||
static QString convertToQString(const QString &separator = QString("\n"));
|
||||
|
||||
private:
|
||||
//! Constructor
|
||||
CProject() {}
|
||||
|
||||
//! Split version
|
||||
static int getMajorMinor(int index);
|
||||
|
||||
// --------------- env.vars. -------------
|
||||
// centralized in one place here so we have an overview
|
||||
|
||||
//! Environment variable indicating "dev.environment"
|
||||
static const QString &envVarDevelopment();
|
||||
|
||||
//! Value
|
||||
//! //! \value true|false
|
||||
static QString envVarDevelopmentValue();
|
||||
|
||||
//! Read data from productive or development setupnding on dev. environment yes/no
|
||||
static const QString &envDevelopmentSetup();
|
||||
|
||||
//! Value
|
||||
//! \value true|false
|
||||
//! \remarks If this is set, the explicit value will be used.
|
||||
//! If not set, default will be used depe
|
||||
static QString envDevelopmentSetupValue();
|
||||
|
||||
//! Environment variable private resources
|
||||
static const QString &envVarPrivateSetupDir();
|
||||
|
||||
//! Value
|
||||
//! \value directory path
|
||||
static QString envVarPrivateSetupDirValue();
|
||||
};
|
||||
}
|
||||
} // ns
|
||||
|
||||
#endif // guard
|
||||
|
||||
Reference in New Issue
Block a user