LiRepoEntry

LiRepoEntry — An entry in a Limba repository sources.list

Functions

Types and Values

Object Hierarchy

    GObject
    ╰── LiRepoEntry

Description

Functions

LI_TYPE_REPO_ENTRY

#define LI_TYPE_REPO_ENTRY (li_repo_entry_get_type ())


li_repo_index_kind_to_string ()

const gchar *
li_repo_index_kind_to_string (LiRepoIndexKinds kind);

Converts the flag value to an text representation.

Parameters

kind

the LiRepoIndexKinds.

 

Returns

string version of kind


li_repo_index_kind_from_string ()

LiRepoIndexKinds
li_repo_index_kind_from_string (const gchar *kind_str);

Converts the text representation to an flag value.

Parameters

kind_str

the string.

 

Returns

a LiRepoIndexKinds or LI_REPO_INDEX_KIND_NONE for unknown


li_repo_entry_new ()

LiRepoEntry *
li_repo_entry_new (void);

Creates a new LiRepoEntry.

Returns

a LiRepoEntry.

[transfer full]


li_repo_entry_parse ()

gboolean
li_repo_entry_parse (LiRepoEntry *re,
                     const gchar *repo_line);

Read a repository source entry in the form of "common,devel,source http://example.com/repo"

Returns

TRUE on success, FALSE on error


li_repo_entry_get_kinds ()

LiRepoIndexKinds
li_repo_entry_get_kinds (LiRepoEntry *re);

li_repo_entry_set_kinds ()

void
li_repo_entry_set_kinds (LiRepoEntry *re,
                         LiRepoIndexKinds kinds);

li_repo_entry_add_kind ()

void
li_repo_entry_add_kind (LiRepoEntry *re,
                        LiRepoIndexKinds kind);

li_repo_entry_has_kind ()

gboolean
li_repo_entry_has_kind (LiRepoEntry *re,
                        LiRepoIndexKinds kind);

li_repo_entry_get_url ()

const gchar *
li_repo_entry_get_url (LiRepoEntry *re);

li_repo_entry_set_url ()

void
li_repo_entry_set_url (LiRepoEntry *re,
                       const gchar *url);

li_repo_entry_get_id ()

const gchar *
li_repo_entry_get_id (LiRepoEntry *re);

Returns

An unique identifier for this repository, to be used in filepaths. Currently, that is the MD5 checksum of its URL.


li_repo_entry_get_cache_dir ()

const gchar *
li_repo_entry_get_cache_dir (LiRepoEntry *re);

Returns

The private cache directory of this repository entry.


li_repo_entry_get_appstream_fname ()

const gchar *
li_repo_entry_get_appstream_fname (LiRepoEntry *re);

Returns

The AppStream distro XML filename for this repository.


li_repo_entry_get_index_urls_for_arch ()

gchar **
li_repo_entry_get_index_urls_for_arch (LiRepoEntry *re,
                                       const gchar *arch);

Get array of indices to download for the given architecture.


li_repo_entry_get_metadata_url_for_arch ()

gchar *
li_repo_entry_get_metadata_url_for_arch
                               (LiRepoEntry *re,
                                const gchar *arch);

Get AppStream metadata URL to download for the given architecture.

Types and Values

struct LiRepoEntryClass

struct LiRepoEntryClass {
	GObjectClass		parent_class;
};


LIMBA_CACHE_DIR

#define LIMBA_CACHE_DIR "/var/cache/limba/"


APPSTREAM_CACHE_DIR

#define APPSTREAM_CACHE_DIR "/var/cache/app-info/"


enum LiRepoIndexKinds

Flags defining which index kinds this repository entry defines.

Members

LI_REPO_INDEX_KIND_NONE

Source entry has no kind (= it is disabled)

 

LI_REPO_INDEX_KIND_COMMON

Download the "common" index

 

LI_REPO_INDEX_KIND_DEVEL

Download the "devel" (SDK) index

 

LI_REPO_INDEX_KIND_SOURCE

Download the "source" index

 

LiRepoEntry

typedef struct _LiRepoEntry LiRepoEntry;