mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-25 15:06:14 +01:00
[GIRepository] Rename g_irepository_enumerate
Rename it to g_irepository_enumerate_versions
This commit is contained in:
parent
da698167a0
commit
ab9085eda3
@ -1050,7 +1050,7 @@ free_candidate (struct NamespaceVersionCandidadate *candidate)
|
||||
}
|
||||
|
||||
static GSList *
|
||||
enumerate_namespace_versions (const gchar *namespace)
|
||||
enumerate_namespace_versions (const gchar *namespace)
|
||||
{
|
||||
GSList *candidates = NULL;
|
||||
GHashTable *found_versions = g_hash_table_new (g_str_hash, g_str_equal);
|
||||
@ -1123,7 +1123,7 @@ enumerate_namespace_versions (const gchar *namespace)
|
||||
g_dir_close (dir);
|
||||
index++;
|
||||
}
|
||||
|
||||
|
||||
g_slist_free (tmp_path);
|
||||
g_free (namespace_dash);
|
||||
g_free (namespace_typelib);
|
||||
@ -1165,20 +1165,21 @@ find_namespace_latest (const gchar *namespace,
|
||||
}
|
||||
|
||||
/**
|
||||
* g_irepository_enumerate:
|
||||
* @repository: (allow-none): Repository
|
||||
* g_irepository_enumerate_versions:
|
||||
* @repository: (allow-none): the repository
|
||||
* @namespace_: GI namespace, e.g. "Gtk"
|
||||
*
|
||||
* Returns: (element-type utf8) (transfer full): An array of versions available for
|
||||
* this namespace.
|
||||
* Obtain a list of versions for @namespace_ in this @repository.
|
||||
*
|
||||
* Returns: (element-type utf8) (transfer full): the array of versions.
|
||||
*/
|
||||
GList *
|
||||
g_irepository_enumerate (GIRepository *repository,
|
||||
g_irepository_enumerate_versions (GIRepository *repository,
|
||||
const gchar *namespace_)
|
||||
{
|
||||
GList *ret = NULL;
|
||||
GSList *candidates, *link;
|
||||
|
||||
|
||||
candidates = enumerate_namespace_versions (namespace_);
|
||||
for (link = candidates; link; link = link->next)
|
||||
{
|
||||
|
@ -101,8 +101,8 @@ gboolean g_irepository_is_registered (GIRepository *repository,
|
||||
GIBaseInfo * g_irepository_find_by_name (GIRepository *repository,
|
||||
const gchar *namespace_,
|
||||
const gchar *name);
|
||||
GList * g_irepository_enumerate (GIRepository *repository,
|
||||
const gchar *namespace_);
|
||||
GList * g_irepository_enumerate_versions (GIRepository *repository,
|
||||
const gchar *namespace_);
|
||||
GTypelib * g_irepository_require (GIRepository *repository,
|
||||
const gchar *namespace_,
|
||||
const gchar *version,
|
||||
|
Loading…
Reference in New Issue
Block a user