Top |
Modulemd.ModuleIndexModulemd.ModuleIndex — A simplistic wrapper around GHashTable to ensure type-safety for [Modulemd.Module](Modulemd.Module.md) objects. |
gboolean modulemd_module_index_update_from_file (ModulemdModuleIndex *self
,const gchar *yaml_file
,GPtrArray **failures
,GError **error
);
self |
This ModulemdModuleIndex object |
|
yaml_file |
A YAML file containing the module metadata and other related information such as default streams. |
[in] |
failures |
An array containing any subdocuments from the YAML file that failed to parse. See ModulemdSubdocumentInfo for more details. |
[out][element-type ModulemdSubdocumentInfo][transfer container] |
error |
A GError containing additional information if this function fails. |
[out] |
TRUE if the update was successful. Returns FALSE and sets failures and error approriately if any of the YAML subdocuments were invalid or if there was a parse error.
Since: 2.0
gboolean modulemd_module_index_update_from_string (ModulemdModuleIndex *self
,const gchar *yaml_string
,GPtrArray **failures
,GError **error
);
self |
This ModulemdModuleIndex object |
|
yaml_string |
A YAML string containing the module metadata and other related information such as default streams. |
[in] |
failures |
An array containing any subdocuments from the YAML file that failed to parse. See ModulemdSubdocumentInfo for more details. |
[out][element-type ModulemdSubdocumentInfo][transfer container] |
error |
A GError containing additional information if this function fails. |
[out] |
TRUE if the update was successful. Returns FALSE and sets failures and error approriately if any of the YAML subdocuments were invalid or if there was a parse error.
Since: 2.0
gboolean modulemd_module_index_update_from_stream (ModulemdModuleIndex *self
,FILE *yaml_stream
,GPtrArray **failures
,GError **error
);
[skip]
self |
This ModulemdModuleIndex object |
|
yaml_stream |
A YAML stream containing the module metadata and other related information such as default streams. |
[in] |
failures |
An array containing any subdocuments from the YAML file that failed to parse. See ModulemdSubdocumentInfo for more details. |
[out][element-type ModulemdSubdocumentInfo][transfer container] |
error |
A GError containing additional information if this function fails. |
[out] |
TRUE if the update was successful. Returns FALSE and sets failures and error approriately if any of the YAML subdocuments were invalid or if there was a parse error.
Since: 2.0
const gchar * modulemd_module_index_dump_to_string (ModulemdModuleIndex *self
,GError **error
);
self |
This ModulemdModuleIndex |
|
error |
A GError containing the reason the function failed, NULL if the function succeeded. |
[out] |
A YAML representation of the index as a string. In the event of an error, sets error appropriately and returns NULL.
Since: 2.0
gboolean modulemd_module_index_dump_to_stream (ModulemdModuleIndex *self
,FILE *yaml_stream
,GError **error
);
[skip]
self |
This ModulemdModuleIndex |
|
yaml_stream |
A stream to write the module metadata and other related information to. |
[in] |
error |
A GError containing the reason the function failed, NULL if the function succeeded. |
[out] |
Since: 2.0
GStrv
modulemd_module_index_get_module_names_as_strv
(ModulemdModuleIndex *self
);
[rename-to modulemd_module_index_get_module_names]
Since: 2.0
ModulemdModule * modulemd_module_index_get_module (ModulemdModuleIndex *self
,const gchar *module_name
);
The ModulemdModule object matching the provided module name or NULL if the key was not present in the index.
Since: 2.0
gboolean modulemd_module_index_add_module_stream (ModulemdModuleIndex *self
,ModulemdModuleStream *stream
,GError **error
);
self |
This ModulemdModuleIndex |
|
stream |
The ModulemdModuleStream to add to the index. |
|
error |
A GError containing the reason the ModulemdModuleStream object could not be added or NULL if the function succeeded. |
[out] |
TRUE if the ModulemdModule was added succesfully. If the stream already existed in the index, it will be replaced by the new one. On failure, returns FALSE and sets error appropriately.
Since: 2.0
gboolean modulemd_module_index_add_defaults (ModulemdModuleIndex *self
,ModulemdDefaults *defaults
,GError **error
);
self |
This ModulemdModuleIndex |
|
defaults |
The ModulemdDefaults object to add to the index. |
|
error |
A GError containing the reason the ModulemdDefaults object could not be added or NULL if the function succeeded. |
[out] |
TRUE if the ModulemdDefaults was added succesfully. If the defaults already existed in the index, it will be replaced by the new one. On failure, returns FALSE and sets error approriately.
Since: 2.0
gboolean modulemd_module_index_add_translation (ModulemdModuleIndex *self
,ModulemdTranslation *translation
,GError **error
);