38 std::map<std::string, std::string>
flags;
50 const std::filesystem::path& target_path,
51 const std::map<std::string, std::string>& current_flags,
52 std::function<
bool(std::string)> version_eval_fun,
53 std::function<
bool(std::string)> fomm_eval_fun = [](
auto s) {
return true; })
57 if(cur_type.dependencies.evaluate(
58 target_path, current_flags, version_eval_fun, fomm_eval_fun))
Header for the File struct.
The fomod namespace contains classes used for parsing a FOMOD xml file and for creating an installer.
Definition dependency.h:22
PluginType
Describes how a plugin is presented.
Definition plugintype.h:20
Header for the PluginDependency struct.
Header for the PluginType enum.
Represents one selectable option during installation.
Definition plugin.h:24
PluginType default_type
Fallback type if this has potential types but none are valid.
Definition plugin.h:34
PluginType type
Affects how this plugin is displayed.
Definition plugin.h:32
std::vector< PluginDependency > potential_types
Plugin takes the first type for which the condition is fulfilled.
Definition plugin.h:36
std::filesystem::path image_path
Path to an image representing this plugin.
Definition plugin.h:30
void updateType(const std::filesystem::path &target_path, const std::map< std::string, std::string > ¤t_flags, std::function< bool(std::string)> version_eval_fun, std::function< bool(std::string)> fomm_eval_fun=[](auto s) { return true;})
Updates type according to potential_types.
Definition plugin.h:49
std::string name
Plugin name.
Definition plugin.h:26
std::string description
Plugin description.
Definition plugin.h:28
std::vector< File > files
Files to be installed when this is selected.
Definition plugin.h:40
std::map< std::string, std::string > flags
Flags to be set when this is selected.
Definition plugin.h:38