Top | ![]() |
![]() |
![]() |
![]() |
gchar * | application-id | Read / Write |
gchar * | architecture | Read / Write |
gboolean | eject-after-install | Read / Write |
gchar * | initrd-path | Read / Write |
gboolean | installer | Read / Write |
gint | installer-reboots | Read / Write |
gboolean | installer-script | Read / Write |
gchar * | kernel-path | Read / Write |
gpointer | languages | Read |
gboolean | live | Read / Write |
OsinfoOs * | os | Read / Write |
gchar * | publisher-id | Read / Write |
gchar * | system-id | Read / Write |
gchar * | url | Read / Write |
gchar * | volume-id | Read / Write |
gint64 | volume-size | Read / Write |
#define | OSINFO_MEDIA_ERROR |
enum | OsinfoMediaError |
enum | OsinfoMediaDetectFlags |
#define | OSINFO_MEDIA_PROP_ARCHITECTURE |
#define | OSINFO_MEDIA_PROP_URL |
#define | OSINFO_MEDIA_PROP_VOLUME_ID |
#define | OSINFO_MEDIA_PROP_SYSTEM_ID |
#define | OSINFO_MEDIA_PROP_PUBLISHER_ID |
#define | OSINFO_MEDIA_PROP_APPLICATION_ID |
#define | OSINFO_MEDIA_PROP_KERNEL |
#define | OSINFO_MEDIA_PROP_INITRD |
#define | OSINFO_MEDIA_PROP_LIVE |
#define | OSINFO_MEDIA_PROP_INSTALLER |
#define | OSINFO_MEDIA_PROP_INSTALLER_REBOOTS |
#define | OSINFO_MEDIA_PROP_LANG |
#define | OSINFO_MEDIA_PROP_LANG_REGEX |
#define | OSINFO_MEDIA_PROP_LANG_MAP |
#define | OSINFO_MEDIA_PROP_VARIANT |
#define | OSINFO_MEDIA_PROP_VOLUME_SIZE |
#define | OSINFO_MEDIA_PROP_EJECT_AFTER_INSTALL |
#define | OSINFO_MEDIA_PROP_INSTALLER_SCRIPT |
#define | OSINFO_MEDIA_PROP_BOOTABLE |
GEnum ╰── OsinfoMediaError GFlags ╰── OsinfoMediaDetectFlags GObject ╰── OsinfoEntity ╰── OsinfoMedia
OsinfoMedia * osinfo_media_create_from_location (const gchar *location
,GCancellable *cancellable
,GError **error
);
Creates a new OsinfoMedia for installation media at location
. The location
could be a http:// or a https:// URI or a local path.
NOTE: Currently this only works for ISO images/devices.
void osinfo_media_create_from_location_async (const gchar *location
,gint priority
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
Asynchronous variant of osinfo_media_create_from_location.
OsinfoMedia * osinfo_media_create_from_location_finish (GAsyncResult *res
,GError **error
);
Finishes an asynchronous media object creation process started with osinfo_media_create_from_location_async.
Since: 1.6.0
OsinfoMedia * osinfo_media_create_from_location_with_flags (const gchar *location
,GCancellable *cancellable
,guint flags
,GError **error
);
Creates a new OsinfoMedia for installation media at location
. The location
could be a http:// or a https:// URI or a local path.
NOTE: Currently this only works for ISO images/devices.
location |
the location of an installation media |
|
cancellable |
a GCancellable, or |
[allow-none] |
error |
The location where to store any error, or |
|
flags |
An OsinfoMediaDetectFlag, or 0. |
Since: 1.6.0
void osinfo_media_create_from_location_with_flags_async (const gchar *location
,gint priority
,GCancellable *cancellable
,GAsyncReadyCallback callback
,guint flags
,gpointer user_data
);
Asynchronous variant of osinfo_media_create_from_location_with_flags.
location |
the location of an installation media |
|
priority |
the I/O priority of the request |
|
cancellable |
a GCancellable, or |
[allow-none] |
callback |
Function to call when result of this call is ready |
|
flags |
An OsinfoMediaDetectFlag, or 0. |
|
user_data |
The user data to pass to |
Since: 1.6.0
OsinfoMedia * osinfo_media_create_from_location_with_flags_finish (GAsyncResult *res
,GError **error
);
Finishes an asynchronous media object creation process started with osinfo_media_create_from_location_async.
const gchar *
osinfo_media_get_architecture (OsinfoMedia *media
);
Retrieves the target hardware architecture of the OS media
provides.
const gchar *
osinfo_media_get_url (OsinfoMedia *media
);
The URL to the media
const gchar *
osinfo_media_get_volume_id (OsinfoMedia *media
);
If media
is an ISO9660 image/device, this function retrieves the expected
volume ID.
Note: In practice, this will usually not be the exact copy of the volume ID string on the ISO image/device but rather a regular expression that matches it.
const gchar *
osinfo_media_get_system_id (OsinfoMedia *media
);
If media
is an ISO9660 image/device, this function retrieves the expected
system ID.
Note: In practice, this will usually not be the exact copy of the system ID string on the ISO image/device but rather a regular expression that matches it.
const gchar *
osinfo_media_get_publisher_id (OsinfoMedia *media
);
If media
is an ISO9660 image/device, this function retrieves the expected
publisher ID.
Note: In practice, this will usually not be the exact copy of the publisher ID string on the ISO image/device but rather a regular expression that matches it.
const gchar *
osinfo_media_get_application_id (OsinfoMedia *media
);
If media
is an ISO9660 image/device, this function retrieves the expected
application ID.
Note: In practice, this will usually not be the exact copy of the application ID string on the ISO image/device but rather a regular expression that matches it.
const gchar *
osinfo_media_get_kernel_path (OsinfoMedia *media
);
Retrieves the path to the kernel image in the install tree.
Note: This only applies to installer medias of 'linux' OS family.
const gchar *
osinfo_media_get_initrd_path (OsinfoMedia *media
);
Retrieves the path to the initrd image in the install tree.
Note: This only applies to installer medias of 'linux' OS family.
OsinfoOsVariantList *
osinfo_media_get_os_variants (OsinfoMedia *media
);
Gets the variants of the associated operating system.
Since: 0.2.9
GList *
osinfo_media_get_languages (OsinfoMedia *media
);
If media is an installer, this property indicates the languages that can be used during automatic installations.
On media that are not installers, this property will indicate the languages that the user interface can be displayed in. Use osinfo_media_get_installer(or OsinfoMedia::installer) to know if the media is an installer or not.
a GList
containing the list of the UI languages this media supports. The list
must be freed with g_list_free()
when no longer needed. If the
supported languages are unknown, NULL will be returned.
[transfer container][element-type utf8]
Since: 0.2.3
gboolean
osinfo_media_get_installer (OsinfoMedia *media
);
Whether media
provides an installer for an OS.
Since: 0.0.3
gboolean
osinfo_media_get_live (OsinfoMedia *media
);
Whether media
can boot directly an OS without any installations.
Since: 0.0.3
gint
osinfo_media_get_installer_reboots (OsinfoMedia *media
);
If media is an installer, this method retrieves the number of reboots the installer takes before installation is complete.
This function is not supposed to be called on media that has no installer. You can use osinfo_media_get_installer(or OsinfoMedia::installer) to check that.
Warning: Some media allow you to install from live sessions, in which case number of reboots *alone* is not a reliable method for tracking installation.
Since: 0.2.1
gboolean
osinfo_media_get_eject_after_install (OsinfoMedia *media
);
Whether media
should ejected after the installation procces.
Since: 0.2.13
gboolean
osinfo_media_supports_installer_script
(OsinfoMedia *media
);
Whether media
supports installation using install scripts.
Since: 1.3.0
void osinfo_media_add_install_script (OsinfoMedia *media
,OsinfoInstallScript *script
);
Adds an script
to the specified media
Since: 1.4.0
OsinfoInstallScriptList *
osinfo_media_get_install_script_list (OsinfoMedia *media
);
Since: 1.4.0
GError codes used for errors in the OSINFO_MEDIA_ERROR domain, during reading of data from install media location.
#define OSINFO_MEDIA_PROP_EJECT_AFTER_INSTALL "eject-after-install"
“application-id”
property “application-id” gchar *
Expected application ID (regular expression) for ISO9660 image/device.
Flags: Read / Write
Default value: NULL
“architecture”
property “architecture” gchar *
The target hardware architecture of this media.
Flags: Read / Write
Default value: NULL
“eject-after-install”
property “eject-after-install” gboolean
Whether the media should be ejected after the installation process.
Some distros need their media to not be ejected after the final reboot during its installation process as some packages are installed after the reboot (which may cause the media to be ejected, depending on the application).
Flags: Read / Write
Default value: TRUE
“initrd-path”
property “initrd-path” gchar *
The path to the initrd image in the install tree.
Flags: Read / Write
Default value: NULL
“installer”
property “installer” gboolean
Whether media provides an installer for an OS.
Flags: Read / Write
Default value: TRUE
“installer-reboots”
property “installer-reboots” gint
If media is an installer, this property indicates the number of reboots the installer takes before installation is complete.
This property is not applicable to media that has no installer. You can use osinfo_media_get_installer(or OsinfoMedia::installer) to check that.
Warning: Some media allow you to install from live sessions, in which case number of reboots *alone* is not a reliable method for tracking installation.
Flags: Read / Write
Default value: 1
“installer-script”
property “installer-script” gboolean
Whether the media supports installation via an install-script.
Some distros provide a few different medias and not all the medias support installation via an install script.
Flags: Read / Write
Default value: TRUE
“kernel-path”
property “kernel-path” gchar *
The path to the kernel image in the install tree.
Flags: Read / Write
Default value: NULL
“languages”
property “languages” gpointer
If media is an installer, this property indicates the languages that can be used during automatic installations.
On media that are not installers, this property will indicate the languages that the user interface can be displayed in. Use osinfo_media_get_installer(or OsinfoMedia::installer) to know if the media is an installer or not.
Type: GLib.List(utf8) Transfer: container
Flags: Read
“live”
property “live” gboolean
Whether media can boot directly an OS without any installations.
Flags: Read / Write
Default value: FALSE
“os”
property“os” OsinfoOs *
Os information for the current media. For media stored in an
OsinfoDB, it will be filled when the database is loaded, otherwise
the property will be filled after a successful call to
osinfo_db_identify_media()
.
Flags: Read / Write
“publisher-id”
property “publisher-id” gchar *
Expected publisher ID (regular expression) for ISO9660 image/device.
Flags: Read / Write
Default value: NULL
“system-id”
property “system-id” gchar *
Expected system ID (regular expression) for ISO9660 image/device.
Flags: Read / Write
Default value: NULL
“volume-id”
property “volume-id” gchar *
Expected volume ID (regular expression) for ISO9660 image/device.
Flags: Read / Write
Default value: NULL