Modulemd.Intent

Modulemd.Intent — Overrides ModulemdDefaults when a specific system "purpose" has been set.

Functions

Types and Values

Description

Functions

modulemd_intent_new ()

ModulemdIntent *
modulemd_intent_new (const gchar *name);

Returns

A newly-allocated ModulemdIntent object. This must be freed with g_object_unref().

[transfer full]

Since: 1.5


modulemd_intent_set_intent_name ()

void
modulemd_intent_set_intent_name (ModulemdIntent *self,
                                 const gchar *name);

Sets the "module-name" property.

Parameters

name

The module name to which these defaults apply.

[not nullable]

Since: 1.5


modulemd_intent_peek_intent_name ()

const gchar *
modulemd_intent_peek_intent_name (ModulemdIntent *self);

Retrieves the module name to which these defaults apply.

Returns

a string containing the "module-name" property. This string must not be modified or freed. If you need to do so, use modulemd_intent_dup_intent_name() instead.

Since: 1.5


modulemd_intent_dup_intent_name ()

gchar *
modulemd_intent_dup_intent_name (ModulemdIntent *self);

Retrieves the module name to which these defaults apply.

Returns

a string containing the "module-name" property. This string must be freed with g_free() when the caller is done with it.

Since: 1.5


modulemd_intent_set_default_stream ()

void
modulemd_intent_set_default_stream (ModulemdIntent *self,
                                    const gchar *stream);

Sets the "default-stream" property.

Parameters

stream

The default stream for this module

 

Since: 1.5


modulemd_intent_peek_default_stream ()

const gchar *
modulemd_intent_peek_default_stream (ModulemdIntent *self);

Retrieves the default stream.

Returns

a string containing the "default-stream" property. This string must not be modified or freed. If you need to do so, use modulemd_intent_dup_default_stream() instead.

Since: 1.5


modulemd_intent_dup_default_stream ()

gchar *
modulemd_intent_dup_default_stream (ModulemdIntent *self);

Retrieves the default stream.

Returns

a string containing the "default-stream" property. This string must be freed with g_free() when the caller is done with it.

Since: 1.5


modulemd_intent_set_profiles_for_stream ()

void
modulemd_intent_set_profiles_for_stream
                               (ModulemdIntent *self,
                                const gchar *stream,
                                gchar **profiles);

Parameters

stream

The name of the stream getting default profiles

 

profiles

The set of profile names to install by default when installing this stream of the module.

[array zero-terminated=1][transfer none]

Since: 1.5


modulemd_intent_assign_profiles_for_stream ()

void
modulemd_intent_assign_profiles_for_stream
                               (ModulemdIntent *self,
                                const gchar *stream,
                                ModulemdSimpleSet *profiles);

Parameters

stream

The name of the stream getting default profiles

 

profiles

A ModulemdSimpleSet of profile names to install by default when installing this stream of the module.

 

Since: 1.5


modulemd_intent_set_profile_defaults ()

void
modulemd_intent_set_profile_defaults (ModulemdIntent *self,
                                      GHashTable *profile_defaults);

Assigns the hash table of streams and their default profiles

Parameters

profile_defaults

.

[nullable][element-type utf8 ModulemdSimpleSet][transfer none]

Since: 1.5


modulemd_intent_dup_profiles_for_stream ()

gchar **
modulemd_intent_dup_profiles_for_stream
                               (ModulemdIntent *self,
                                const gchar *stream);

Parameters

stream

The name of the stream from which to retrieve defaults

 

Returns

A zero-terminated array of strings that provides the list of profiles that should be installed by default when this stream is specified.

[array zero-terminated=1][transfer full]

Since: 1.5


modulemd_intent_peek_profile_defaults ()

GHashTable *
modulemd_intent_peek_profile_defaults (ModulemdIntent *self);

Retrieves a hash table of the profile defaults.

Returns

A GHashTable containing the set of profile defaults for streams of this module. This hash table is maintained by the ModulemdIntent object and must not be freed or modified. If modification is necessary, use modulemd_intent_dup_profile_defaults() instead.

[element-type utf8 ModulemdSimpleSet][transfer none]

Since: 1.5


modulemd_intent_dup_profile_defaults ()

GHashTable *
modulemd_intent_dup_profile_defaults (ModulemdIntent *self);

Retrieves a copy of the hash table of profile defaults.

Returns

A GHashTable containing the set of profile defaults for streams of this module. This hash table is a copy and must be freed with g_hash_table_unref() when the caller is finished with it. The elements it contains are maintained by the hash table and will be automatically freed when their key is removed or the hash table is freed.

[element-type utf8 ModulemdSimpleSet][transfer container]

Since: 1.5


modulemd_intent_copy ()

ModulemdIntent *
modulemd_intent_copy (ModulemdIntent *self);

Makes a deep copy of a ModulemdIntent

Returns

A deep copy of the ModulemdIntent.

[transfer full]

Since: 1.5

Types and Values

MODULEMD_TYPE_INTENT

#define MODULEMD_TYPE_INTENT (modulemd_intent_get_type ())

ModulemdIntent

typedef struct _ModulemdIntent ModulemdIntent;