mirror of
https://github.com/loot/libloot.git
synced 2026-07-27 14:16:01 -07:00
Add include_user_metadata parameter to Database::general_messages()
The C++ wrapper defaults it to true, so the behaviour hasn't changed for existing callers that don't pass a value for the evaluateConditions parameter, i.e. that call GetGeneralMessages(). Since the new parameter comes before evaluateConditions, existing GetGeneralMessages(true) and GetGeneralMessages(false) calls need to be replaced with GetGeneralMessages(true, true) and GetGeneralMessages(true, false) to retain their existing behaviour. The parameter order was chosen to match that of GetPluginMetadata(), at the cost of this backwards incompatibility.
This commit is contained in:
@@ -167,6 +167,10 @@ public:
|
||||
|
||||
/**
|
||||
* @brief Get all general messages listed in the loaded metadata lists.
|
||||
* @param includeUserMetadata
|
||||
* If true, any general messages present in the userlist are included
|
||||
* in the returned metadata, otherwise the metadata returned only
|
||||
* includes metadata from the masterlist.
|
||||
* @param evaluateConditions
|
||||
* If true, any metadata conditions are evaluated before the metadata
|
||||
* is returned, otherwise unevaluated metadata is returned. Evaluating
|
||||
@@ -176,6 +180,7 @@ public:
|
||||
* to any particular plugin.
|
||||
*/
|
||||
virtual std::vector<Message> GetGeneralMessages(
|
||||
bool includeUserMetadata = true,
|
||||
bool evaluateConditions = false) const = 0;
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user