Workspace 7.0.2
|
Application-level functionality for all workspace applications.
Namespaces | |
namespace | __ClassConstraintsPrivate |
namespace | IndexBasedIteratorPrivate |
namespace | Josuttis |
namespace | PluginManagerImplPrivate |
namespace | PrivateInheritanceTests |
namespace | PrivateStreamableTests |
namespace | Tag |
namespace | Ui |
namespace | Web |
namespace | WorkflowTreeStr |
Classes | |
class | AgentSettings |
class | ArgumentsParser |
Abstract base class for dealing with command line arguments. More... | |
class | BasicTextLogger |
Convenience class for writing to the log using an object, rather than inheritance. More... | |
class | BuiltinPlugin |
This is the built-in plugin class. More... | |
class | ConditionalAlphaNumericCompare |
Functor for comparing two strings differently if they are alphabetic vs numeric. If both strings are numbers, they will be compared numerically. If one or the other is a string, they will be compared as strings. More... | |
class | ConfigurePluginsDialog |
Dialog for configuring the workspace plugins. More... | |
class | ConfigurePluginsWidget |
Widget for configuring the workspace plugins. More... | |
class | ConfigureRemoteWidget |
Widget for configuring remote authentication details. More... | |
class | ConvertToLegacy |
class | DirectoryFilter |
Provides a platform-independent way to get a filtered directory listing. More... | |
class | DistributedLogManager |
Singleton for managing the logging streams associated with execution threads. More... | |
class | DownloaderWidget |
class | EmptyPluginConfig |
Provides a configuration widget for plugins with no configurable parameters. More... | |
class | EmptyPluginMenu |
A default implementation of PluginMenu for plugins that do not supply a custom menu for the Workspace editor. More... | |
class | EnforceCondition |
Generic class which is only defined when the template parameter is true . More... | |
class | EnforceCondition< true > |
class | ExecutedWorkspaceHistory |
class | ExecutionInspectorWidget |
class | FileNameNaturalLessThan |
Compares two QFileInfo's "naturally". Numbers will be compared as numbers, strings compared as strings etc. More... | |
class | Filter |
Filter elements with given expressions. More... | |
class | ForcedShutdownEvent |
This event is raised by something that wants to force the application to quit. More... | |
class | GlobalNotifications |
Singleton on which application-wide notifications can be observed. More... | |
struct | HasOperatorEqual |
Constraints class for whether or not a type can be compared to another with operator==. More... | |
struct | HasOperatorLessThan |
Constraints class for whether or not a type can be compared to another with operator<. More... | |
class | HelpImplementation |
Base class for a help implementation. More... | |
class | HelpNetworkAccessManager |
class | HelpPlugin |
Plugin providing a help implementation. More... | |
class | HelpViewer |
class | HelpWindow |
class | IndexBasedIterator |
Generic base class for adding support for iteration to index-based container classes. More... | |
class | IntegerRangeString |
Allow a user to use a range string in the form "-6, -3--1, 1-2, 3, 6" etc. Empty range string will match all. More... | |
class | IpcClient |
Local inter-process communication client. This client is part of a local inter-process communication (IPC) client-server architecture providing two-way communications between the workspace-server process and the child process spawned by workspace-server in remote execution. The IpcClient use QLocalSocket to communicate with IpcServer. Currently there is only one IpcClient per child process. But the code supports multiple IpcClients per IpcServer. The IpcClient connects to IpcServer on a port keyed by the workspace label that is executed in the child process. The connection IpcClient-IpcServer remains open as long as the child process is running. The IpcClient receives OperationUpdateEvent notifications from WorkspaceBatch (which runs the child process) and sends messages to IpcServer. More... | |
class | IpcServer |
Local inter-process communication server. This server is part of a local inter-process communication (IPC) client-server architecture providing two-way communications between the workspace-server process and the child process spawned by workspace-server in remote execution. The IpcServer use IpcServerSocket which wraps QLocalSocket to communicate with its possibly many connected IpcClients. There will be one IpcServer per WorkspaceObserver (hence per child process). The IpcServer listens on a port keyed by the workspace label that is executed in the child process. The connections IpcClients-IpcServer remains open as long as the child process is running. The IpcServer receives messages from IpcClients and notifies WorkspaceObserver about OperationUpdateEvent. More... | |
class | IpcServerSocket |
IpcServerSocket wraps QLocalSocket and represents a connection from IpcServer to one single IpcClient. More... | |
struct | IsContainer |
Constraints class for whether or not a type is a container. The determination is based on whether the type has a const_iterator type and begin() and end() functions that return that type. More... | |
class | IsDerivedFrom |
Define a constraints base class with a testable value. More... | |
struct | IsSortable |
Constraints class for whether or not a type is sortable; i.e. whether or not it can be compared against another using operator<(). More... | |
struct | IsSortableContainer |
Constraints class for whether or not a type is a sortable container; i.e. a container that can be compared using operator<(). This requires that its elements are also able to be sorted using operator<. More... | |
class | LicenseManager |
class | LoggingThread |
Thread for modifying the log - writing to it, adding streams etc. More... | |
class | LogManager |
Singleton for managing the logging streams associated with execution threads. More... | |
class | LogManagerImplThreaded |
Implementation of the LogManager that supports logging from mulitiple threads simultaneously. More... | |
class | LogManagerImplUnthreaded |
Implementation of the LogManager that supports logging from a single thread only. More... | |
class | LogWorkflow |
LogStream subclass for directing a log stream to file. More... | |
class | Memento |
Utility class implementing a Memento design pattern. More... | |
class | OOPScheduleeArgumentsParser |
Helper class for dealing with command line arguments supplied to an OOP schedulee application. More... | |
class | OperationHelpGenerator |
Generates doxygen files for each operation registered with Workspace. More... | |
class | PerThreadNetworkAccessManager |
class | PluginConfig |
Provider of a QWidget for configuring a plugin. You can use the Developer wizard to generate a stub implementation of this class. See Integrating a custom plugin settings widget into the Workspace Editor. More... | |
class | PluginManager |
Singleton responsible for tracking all operation factories in the application. More... | |
class | PluginMenu |
An interface for integrating a custom plugin menu into the Workspace editor. More... | |
class | ProcessWorkflows |
class | QMyApplication |
class | QProcessRobust |
Safer implementation of a subset of what QProcess tries to achieve. More... | |
class | QtDebugCapture |
Captures Qt debug messages. More... | |
class | RefCountedObject |
Base class for reference-counted objects. More... | |
class | RefCountedObjectPtr |
Template class for smart pointers-to-T objects (requires modification to T). More... | |
class | RefCountedPtr |
Template class for reference-counted pointers-to-T (T requires no special modification). More... | |
class | RemoteManager |
Singleton for handling network requests. More... | |
class | RemoteSchedulerDialog |
Widget for modifying the remote scheduler settings. More... | |
class | RemoteSchedulerService |
class | RemoteSchedulerServiceBase |
class | RemoteSchedulerWidget |
Widget for controlling the remote scheduler. More... | |
class | ScopedElapsedTimeLogger |
Measure and trace elapsed time during lifetime of object. More... | |
class | ScopeGuard |
Generic scopeguard to simplify RAII where cleanup is needed. More... | |
class | SessionHandler |
class | SessionManager |
class | Settings |
Singleton class holding the settings for the Workspace. More... | |
class | SettingsMap |
This abstract class stores settings information and current value. It wraps around QMap that maps some type of settings Enum to a QVariant. More... | |
class | SettingsVariables |
Singleton class for storing settings variables. More... | |
class | ShutdownEvent |
Event raised when the main application event loop stops. More... | |
class | Smtp |
class | SoundEffectRegistry |
Sound effect registry. More... | |
class | StandAloneWindow |
struct | Streamable |
Traits class to determine if a type T supports output and input streaming. More... | |
struct | StreamableIn |
Traits class to determine if a type T supports input streaming. More... | |
struct | StreamableOut |
Traits class to determine if a type T supports output streaming. More... | |
class | TestIfDerivedFrom |
Define a constraints base class with a testable value. More... | |
class | TestIfDerivedFuncs |
class | TextLogger |
Convenience base class for anything associated with an operation that needs to write text to the log manager. More... | |
class | TextTemplate |
Represents a template (or set of templates) that can be rendered using a supplied context. More... | |
class | TypeT |
Type classification template. More... | |
class | UdpBroadcast |
Local broadcast helper This class implements a broadcast helper on the local interface using UDP diagrams. Listener apps can also use this class to receive the broadcast messages on shared socket SO_REUSEADDR. More... | |
class | UserInterfaceMap |
class | VariableLengthArray |
An array class similar to std::vector or QVector. More... | |
class | WorkflowAnalyseBatchArgumentsParser |
Command line argument parser for workspace-analyse-batch. More... | |
class | WorkspaceAgent |
class | WorkspaceAgentWorkflows |
class | WorkspaceAgentWorkflowWidget |
class | WorkspaceArgumentsParser |
Helper class for dealing with command line arguments supplied to a workspace application. More... | |
class | WorkspaceContainer |
class | WorkspaceObserver |
class | WorkspacePlugin |
Base class for all workspace plugin classes. More... | |
class | WorkspaceQueue |
class | XmlEntitiesHandler |
This class makes it easy to convert HTML strings back to plain texts. More... | |
Typedefs | |
using | MessageCategory = Application::LogManager::MessageCategory |
typedef CSIRO::Application::ReportExceptionsApp | ParentApp |
using | WebPage = QWebEnginePage |
typedef QWebEngineView | WebView |
Enumerations | |
enum class | SoundEffect { ExecutionComplete = 0 , ExecutionFailed , ConnectionMade , Size } |
enum class | UiSetting { SetLabelOnNestedWorkflowAction = 0 , Unknown } |
Functions | |
template<class Real > | |
bool | approxEqual (Real a, Real b, Real eps=epsilon< Real >()) |
template<typename Real > | |
Real | clamp (Real x, Real lowerlimit, Real upperlimit) |
template<typename Real > | |
Real | clampMinPrec (Real value, Real minPrec=std::numeric_limits< Real >::min()) |
template<typename T , typename F > | |
int | compareContainers (const T &left, const T &right, const F &compareFunc) |
template<typename Callable > | |
ScopeGuard< Callable > | createScopeGuard (Callable rollback) |
template<class Real > | |
bool | definitelyGreaterThan (Real a, Real b, Real eps=epsilon< Real >()) |
template<class Real > | |
bool | definitelyGreaterThanOrEqualTo (Real a, Real b, Real eps=epsilon< Real >()) |
template<class Real > | |
bool | definitelyLessThan (Real a, Real b, Real eps=epsilon< Real >()) |
template<class Real > | |
bool | definitelyLessThanOrEqualTo (Real a, Real b, Real eps=epsilon< Real >()) |
template<class Real > | |
bool | definitelyWithinRangeInclusive (Real val, Real min, Real max, Real eps=epsilon< Real >()) |
template<typename T > | |
T | divideAndCeil (T numerator, T denominator) |
template<typename T > | |
T | divideAndRound (T numerator, T denominator) |
template<class Real > | |
constexpr Real | epsilon () |
QString | findExecutable (const QString &exeName) |
void | findLocalFiles (const QString &dirName, const QStringList &nameFilters, bool findRecursively, const QRegularExpression &excludeRegex, QStack< QString > &filesStack) |
DataExecution::SerializedItem | findWorkflowItem (const QString &workflowPath, const DataExecution::SerializedItem &top) |
QString | getDemangledName (const char *name) |
template<typename T , size_t S> | |
constexpr size_t | getFileNameOffset (const T(&str)[S], size_t i=S - 1) |
template<typename T > | |
constexpr size_t | getFileNameOffset (T(&str)[1]) |
QString | getFirstWorkspaceInstallArea (const QString &suffix, bool traceInfo) |
CSIRO_WORKSPACE_API QStringList | getReferencedPlugins (const QString &workflowFileName) |
QStringList | getWorkspaceInstallAreas (const QString &pathSuffix, bool traceInfo) |
CSIRO_WORKSPACE_API QString | getWorkspaceRootDirectory () |
bool | haveDisplayAvailable () |
bool | haveExecutable (const QString &exeName) |
bool | haveGuiAvailable () |
template<class charT , class traits > | |
std::basic_istream< charT, traits > & | ignoreLine (std::basic_istream< charT, traits > &strm) |
bool | initThreads () |
template<typename T1 , typename T2 > | |
bool | isSameObject (T1 &obj1, T2 &obj2) |
bool | jsonFromString (const QString &jsonStr, QJsonDocument &result, bool logParseError=false) |
bool | keysMatch (const std::string &s1, const std::string &s2) |
bool | KeysMatch (const std::string &s1, const std::string &s2) |
QString | launchExecutable (const QString &exeName, const QStringList &arguments, const QString &launcher, const QStringList &launcherArgs) |
QString | launchExecutable (const QStringList &environment, const QStringList &exeNames, const QStringList &arguments) |
QString | launchExecutable (const QStringList &exeNames, const QStringList &arguments, const QString &launcher, const QStringList &launcherArgs) |
bool | loadTranslation (const QString &baseName, const QStringList &searchPaths) |
CSIRO_WORKSPACE_API void | matchGuiMinRequirementsOrPromptAndExit () |
template<class T > | |
T | max3 (const T &a, const T &b, const T &c) |
template<class T > | |
T | min3 (const T &a, const T &b, const T &c) |
QString | normalizeFileName (const QString &filename) |
const LogManager::MessageCategory & | operator<< (const LogManager::MessageCategory &category, const QString &message) |
CSIRO_WORKSPACE_API bool | operator== (const LogManager::MessageCategory &lhs, const LogManager::MessageCategory &rhs) |
CSIRO_WORKSPACE_API void | patchCommandLineArguments (int &argc, char **&argv, bool addToBegin) |
int | processServerCommandLine (int argc, char *argv[]) |
uint | qHash (const CSIRO::Application::LogManager::MessageCategory &key, uint seed=0) |
double | randomInRange (double low, double high) |
double | RandomInRange (double low, double high) |
double | randomProb () |
double | RandomProb () |
QStringList | regexpSplit (const QRegularExpression ®exp, const QString &str) |
bool | runExecutable (const QString &exeName, const QStringList &arguments, const QString &launcher, const QStringList &launcherArgs) |
bool | runExecutable (const QStringList &exeNames, const QStringList &arguments, const QString &launcher, const QStringList &launcherArgs) |
template<class Real > | |
Real | safeACos (Real val) |
void | seedRandomGenerator (unsigned seed) |
void | SeedRandomGenerator (unsigned seed) |
void | serverCommandLineHelp (const char *command) |
void | SetConsoleColour (int type) |
void | setupTranslators () |
template<typename T > | |
int | sign (T val) |
QString | sizeString (size_t bytes) |
template<typename Real > | |
Real | smoothstep (Real edge0, Real edge1, Real x) |
CSIRO_WORKSPACE_API bool | testGuiMinRequirements () |
template<typename T > | |
std::string | ToString (const T &obj) |
std::string & | trimBlanks (std::string &s) |
std::string & | TrimBlanks (std::string &s) |
typedef CSIRO::Application::ReportExceptionsApp ParentApp |
using WebPage = QWebEnginePage |
typedef QWebEngineView WebView |
|
strong |
|
strong |
|
inline |
Floating point comparison function (absolute / relative, depending upon the size of the values)s
Real clamp | ( | Real | x, |
Real | lowerlimit, | ||
Real | upperlimit | ||
) |
Clamp a value to a lower/upper limit if needed.
x | The value to clamp |
lowerlimit | The lower limit of the clamp |
upperlimit | The upper limit of the clamp |
|
inline |
Clamps value to a specific minimum precision (minPrec). If fabs(value) is less than minPrec, minPrec will be returned, otherwise value is returned.
value | The value to clamp |
minPrec | The minimum precision allowed for value. If the fabs(value) is less than this value, minPrec will be returned. |
int compareContainers | ( | const T & | left, |
const T & | right, | ||
const F & | compareFunc | ||
) |
Compare containers based on some value. If the two containers are equal but one is shorter, the shorter one is considered less.
-1 means left < right 0 means left == right 1 means left > right
ScopeGuard< Callable > createScopeGuard | ( | Callable | rollback | ) |
rollback | Rollback function to invoke when the guard is destroyed unless dismissed. The rollback function must not throw an exception, or it will result in the application terminating due to problems with destructor unwinding. Handle all exceptions within the rollback function. |
Creates a guard, allowing us to use super-handy type inferencing and lambdas.
|
inline |
Floating point comparison using relative tolerance (a > b).
|
inline |
Floating point comparison using relative tolerance (a >= b).
|
inline |
Floating point comparison using relative tolerance (a < b).
|
inline |
Floating point comparison using relative tolerance (a <= b).
|
inline |
Convenience floating point comparison using relative / absolute tolerance.
|
inline |
Integer division that rounds the result to the nearest integer higher than the result rather than just truncate
|
inline |
Integer division that rounds the result to the nearest integer rather than just truncate
|
inlineconstexpr |
Custom epsilon that is several times the machines min precision.
CSIRO_WORKSPACE_API QString findExecutable | ( | const QString & | exeName | ) |
exeName | The name of the executable to find. On Windows, this should not include the filename extension. |
If exeName is not an absolute path, this function will attempt to find an executable on the current PATH which can be launched using the specified exeName. If exeName is already an absolute path, it is assumed that the path is correct.
The usefulness of the function is mostly due to its support for honouring the PATHEXT environment variable. Regardless of whether exeName has an absolute path or not, the function will search for exeName as is, and if that is not found it will also try appending each suffix specified in PATHEXT. This is generally only useful on Windows, but it allows the caller to specify an exeName in a more or less platform independent way and let the function handle filename extensions automatically.
void findLocalFiles | ( | const QString & | dirName, |
const QStringList & | nameFilters, | ||
bool | findRecursively, | ||
const QRegularExpression & | excludeRegex, | ||
QStack< QString > & | filesStack | ||
) |
DataExecution::SerializedItem findWorkflowItem | ( | const QString & | workflowPath, |
const DataExecution::SerializedItem & | top | ||
) |
CSIRO_WORKSPACE_API QString getDemangledName | ( | const char * | name | ) |
|
inlineconstexpr |
|
inlineconstexpr |
CSIRO_WORKSPACE_API QString getFirstWorkspaceInstallArea | ( | const QString & | suffix, |
bool | traceInfo | ||
) |
Returns the first workspace install area with the provided suffix that exists.
CSIRO_WORKSPACE_API QStringList getReferencedPlugins | ( | const QString & | workflowFileName | ) |
workflowFileName | name of the workflow file to parse. |
CSIRO_WORKSPACE_API QStringList getWorkspaceInstallAreas | ( | const QString & | pathSuffix, |
bool | traceInfo | ||
) |
pathSuffix | The desired path below each candidate install area. |
traceInfo | Write log messages |
Install areas are generally found from two sources:
CSIRO_WORKSPACE_API QString getWorkspaceRootDirectory | ( | ) |
*As long as this process was run using a Workspace launcher (which will have set the WORKSPACE_INSTALL_AREAS to include all install areas including the one containing the main workspace library.
CSIRO_WORKSPACE_API bool haveDisplayAvailable | ( | ) |
This function has nothing to do with detecting a physical monitor attached to the host machine. Rather, it determines whether or not a display is available from a software perspective. A display could be a virtual off-screen buffer or it could be attached to a physical device, but this function does not distinguish between the two.
One of the main uses of this function is to pass the result as the GUIenabled parameter of a QApplication constructor. That parameter modifies how the application is initialized during startup.
A display is always available under Windows, but for most other platforms, a display is only present if the DISPLAY environment variable is set.
CSIRO_WORKSPACE_API bool haveExecutable | ( | const QString & | exeName | ) |
This function is a convenience. It merely returns whether the result of findExecutable() is an non-empty string.
CSIRO_WORKSPACE_API bool haveGuiAvailable | ( | ) |
The haveGuiAvailable() function is intended to be called after the main application object has been created. It is useful when the client code won't know in advance what type of application object will be used (ie QCoreApplication, QApplication or a subclass of either of these).
|
inline |
Ignore everything up to the end of this line. This code was taken from "The C++ Standard Library", by Nicolai M. Josuttis, p614 (with slight changes).
|
inline |
Initialises threaded rendering support, which is required on X-based platforms in order to use multi-threaded OpenGL data processing and rendering. We can't make this part of the rendering plugin, as we need it for any application that potentially uses 3D visualisation, which includes Workspace-GUI itself.
For platforms other than X11, this function will simply return true. For X11, it will invoke the XInitThreads() function.
bool isSameObject | ( | T1 & | obj1, |
T2 & | obj2 | ||
) |
Function to return if two pointers refer to the same object. The pointers can be to different types, even totally unrelated types. Template specializations will transparently handle this and return true/false as necessary, even as compile-time constants if that can be ascertained (eg unrelated classes). If the classes are related by inheritance, then the test is done at run-time as a simple pointer equivalence test with the compiler providing appropriate conversion to a pointer to the common base class.
|
inline |
jsonStr | String to convert to a JSON document |
result | The resulting JSON document |
logParseError | Logs any parse error details if true, silently returns false otherwise |
|
inline |
|
inline |
CSIRO_WORKSPACE_API QString launchExecutable | ( | const QString & | exeName, |
const QStringList & | arguments, | ||
const QString & | launcher, | ||
const QStringList & | launcherArgs | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This overload exists to make it easy to pass a single exeName rather than a list of names. Without it, a single literal would need to be surrounded with QString().
CSIRO_WORKSPACE_API QString launchExecutable | ( | const QStringList & | environment, |
const QStringList & | exeNames, | ||
const QStringList & | arguments | ||
) |
environment | Specify environments that should be passed to the executable |
exeNames | A list of candidate executable names to find and launch. The first one found to match the criteria will be used. On Windows, these names should not include the filename extension. |
arguments | The arguments that should be passed to the executable. This function is conceptually similar to launching the result of findExecutable() with a few important differences. It will continue searching until it finds and successfully launches an executable. This can be useful if there are executables that fail to load for some reason (eg missing dependencies). If you don't want this behaviour, call findExecutable() and launch it using QProcess yourself. |
A list of exeNames is typically used rather than a single name when a command has different names on different platforms or distributions (as is often the case under linux). The names will be tried in the specified order, checking the full set of paths before moving on to the next candidate name.
CSIRO_WORKSPACE_API QString launchExecutable | ( | const QStringList & | exeNames, |
const QStringList & | arguments, | ||
const QString & | launcher, | ||
const QStringList & | launcherArgs | ||
) |
exeNames | A list of candidate executable names to find and launch. The first one found to match the criteria will be used. On Windows, these names should not include the filename extension. |
arguments | The arguments that should be passed to the executable. |
launcher | If non-empty, this specifies an executable to use to launch the exeName. (see below for details). |
launcherArgs | If launcher is non-empty, this specifies an argument to pass to the launcher (see below for details). |
This function is conceptually similar to launching the result of findExecutable() with a few important differences. It will continue searching until it finds and successfully launches an executable. This can be useful if there are executables that fail to load for some reason (eg missing dependencies). If you don't want this behaviour, call findExecutable() and launch it using QProcess yourself.
A list of exeNames is typically used rather than a single name when a command has different names on different platforms or distributions (as is often the case under linux). The names will be tried in the specified order, checking the full set of paths before moving on to the next candidate name.
The executable can be launched indirectly by another launcher. This is sometimes useful if you want to do things like modify environment variables, chain executables, etc. If launcher is a non-empty string, it is assumed to be a command that can be run (ie it must already be on the PATH or it must be an absolute path). The full command line in this case will be launcher followed by the launcherArgs (if any), the exeName that was found and after that the arguments.
The Workspace framework uses a special kind of launcher for all of its own executables. These launchers all support the use of –launch
as the first parameter, which has the effect of treating the second parameter as another executable to launch and any subsequent arguments will be passed along unchanged to this executable. Before launching the executable, it will augment various environment variables such as PATH, LD_LIBRARY_PATH, DYLD_FRAMEWORK_PATH, QT_PLUGIN_PATH and WORKSPACE_INSTALL_AREAS. Any executable that was built using the launcher_for_executable
CMake macro (provided by the Workspace framework) will also support this –launch
option to launch another executable.
CSIRO_WORKSPACE_API bool loadTranslation | ( | const QString & | baseName, |
const QStringList & | searchPaths | ||
) |
baseName | The base name of the translation file to search for. As an example, the baseName for the Qt translation files is simply "qt", while for the workspace itself, it is "workspace". The actual translation files will typically be named something like "qt_de.qm", etc. See the documentation for QTranslator::load() for full details. |
searchPaths | A list of directories in which to look for translation files. This list will often be provided by a call to getWorkspaceInstallAreas(). |
This function would not typically be called directly by client code. It is generally only used by WorkspacePlugin::addTranslation() as an implementation detail.
CSIRO_WORKSPACE_API void matchGuiMinRequirementsOrPromptAndExit | ( | ) |
Check the hardware and software environment to see if that matches the minimum requirement for running Workspace. If does not match, it prompt a message box and exit the process.
|
inline |
|
inline |
|
inline |
Produce a consistently formatted (wrt separators, number of separators, etc.) filename. You can use this to normalize filenames for comparison.
filename | The filename to normalize |
|
inline |
category | The category of message to write to the log |
message | Message to write to the log |
Stream-like convenience method for writing messages to a particular log category, e.g:
LOG_DEBUG << tr("An error occurred in a debug build.") + "\n";
CSIRO_WORKSPACE_API bool operator== | ( | const LogManager::MessageCategory & | lhs, |
const LogManager::MessageCategory & | rhs | ||
) |
Required for comparison in hashable containers such as QSet
CSIRO_WORKSPACE_API void patchCommandLineArguments | ( | int & | argc, |
char **& | argv, | ||
bool | addToBegin | ||
) |
If we don't have a display available, we need to prepend two command line arguments to our application: -platform offscreen. This replaces the previous functionality in Qt4 where the third parameter of QApplication was the 'hasGuiAvailable' bool. To simplify the code, we always allocate a new argv regardless, and we always clean it up. The patched arguments argv use a newly allocated buffer and will be leaked till the end of the the process, hence this method should only be used to patch the main function's arguments once.
int processServerCommandLine | ( | int | argc, |
char * | argv[] | ||
) |
argc | One more than the number of arguments passed to the application. This must be the value of argc passed to main(). |
argv | This must be the value of argv passed to main(). |
Clients call this function if they want to process server command line options. Currently, only one option may be specified at a time. Supported options are:
–version –vendor –writesettings
It is assumed that clients will exit the application when this function returns. Therefore, clients should only call it if they have already determined that there are options to process and/or that they don't want to launch the application proper.
|
inline |
Enables MessageCategory objects to be stored in hashable containers such as QSet.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
regexp | The regular expression to delimit the split. |
str | The string to split. |
Splits a string, where the matched regular expression is the delimeter. Any captures in the regexp will be included in the resulting stringlist as separate strings, inserted appropriately.
CSIRO_WORKSPACE_API bool runExecutable | ( | const QString & | exeName, |
const QStringList & | arguments, | ||
const QString & | launcher, | ||
const QStringList & | launcherArgs | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This overload exists to make it easy to pass a single exeName rather than a list of names. Without it, a single literal would need to be surrounded with QString().
CSIRO_WORKSPACE_API bool runExecutable | ( | const QStringList & | exeNames, |
const QStringList & | arguments, | ||
const QString & | launcher, | ||
const QStringList & | launcherArgs | ||
) |
This function is entirely analogous to launchExecutable() except it waits for the process to finish before returning.
|
inline |
Function for safely computing acos of +1.0 or -1.0 where rounding errors may occur.
|
inline |
|
inline |
void serverCommandLineHelp | ( | const char * | command | ) |
command | The name of the command for which help should be shown. |
Callers can append their own options to the output.
void SetConsoleColour | ( | int | type | ) |
CSIRO_WORKSPACE_API void setupTranslators | ( | ) |
Installs the Qt and workspace translation files for the current default locale. For information on what the default locale is, see documentation for Qt's QLocale class.
This function would typically be called just after the main QApplication object has been created. It does not use PluginManager in any way and Workspace plugins should call WorkspacePlugin::addTranslation() in their own setup() function in order to make their translations available to the application.
|
inline |
Obtains the sign of a number.
T | The numeric data type in question (or a type implicitly convertible to a numeric type) |
val | The value of which we're obtaining the sign. |
|
inline |
Real smoothstep | ( | Real | edge0, |
Real | edge1, | ||
Real | x | ||
) |
Function to smoothly step between two floating point edges for interpolation purposes.
edge0 | The lower edge limit |
edge1 | The upper edge limit |
x | Value between limits |
CSIRO_WORKSPACE_API bool testGuiMinRequirements | ( | ) |
Check the hardware and software environment to see if that matches the minimum requirement for running Workspace.
|
inline |
|
inline |
|
inline |