![]() |
![]() |
![]() |
Libosinfo Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Properties |
#define OSINFO_OS_PROP_DISTRO #define OSINFO_OS_PROP_FAMILY struct OsinfoOs; struct OsinfoOsClass; OsinfoDeviceLink * osinfo_os_add_device (OsinfoOs *os
,OsinfoDevice *dev
); void osinfo_os_add_media (OsinfoOs *os
,OsinfoMedia *media
); void osinfo_os_add_minimum_resources (OsinfoOs *os
,OsinfoResources *resources
); void osinfo_os_add_recommended_resources (OsinfoOs *os
,OsinfoResources *resources
); void osinfo_os_add_tree (OsinfoOs *os
,OsinfoTree *tree
); OsinfoDeviceList * osinfo_os_get_all_devices (OsinfoOs *os
,OsinfoFilter *filter
); OsinfoDeviceLinkList * osinfo_os_get_device_links (OsinfoOs *os
,OsinfoFilter *filter
); OsinfoDeviceList * osinfo_os_get_devices (OsinfoOs *os
,OsinfoFilter *filter
); OsinfoDeviceList * osinfo_os_get_devices_by_property (OsinfoOs *os
,const char *property
,const char *value
,gboolean inherited
); const gchar * osinfo_os_get_distro (OsinfoOs *os
); const gchar * osinfo_os_get_family (OsinfoOs *os
); OsinfoMediaList * osinfo_os_get_media_list (OsinfoOs *os
); OsinfoResourcesList * osinfo_os_get_minimum_resources (OsinfoOs *os
); OsinfoResourcesList * osinfo_os_get_recommended_resources (OsinfoOs *os
); OsinfoTreeList * osinfo_os_get_tree_list (OsinfoOs *os
); OsinfoOs * osinfo_os_new (const gchar *id
);
OsinfoOs is an entity representing an operating system. Operating systems have a list of supported devices. There are relationships amongst operating systems to declare which are newest releases, which are clones and which are derived from a common ancestry.
OsinfoDeviceLink * osinfo_os_add_device (OsinfoOs *os
,OsinfoDevice *dev
);
Associated a device with an operating system. The returned OsinfoDeviceLink can be used to record extra metadata against the link
|
an operating system |
|
the device to associate with. [transfer none] |
Returns : |
the device association. [transfer none] |
void osinfo_os_add_media (OsinfoOs *os
,OsinfoMedia *media
);
Adds installation media media
to operating system os
.
|
an operating system |
|
the media to add. [transfer none] |
void osinfo_os_add_minimum_resources (OsinfoOs *os
,OsinfoResources *resources
);
Adds resources
to list of minimum resources of operating system os
.
|
an operating system |
|
the resources to add. [transfer none] |
void osinfo_os_add_recommended_resources (OsinfoOs *os
,OsinfoResources *resources
);
Adds resources
to list of recommended resources of operating system os
.
|
an operating system |
|
the resources to add. [transfer none] |
void osinfo_os_add_tree (OsinfoOs *os
,OsinfoTree *tree
);
Adds installation tree tree
to operating system os
.
|
an operating system |
|
the tree to add. [transfer none] |
OsinfoDeviceList * osinfo_os_get_all_devices (OsinfoOs *os
,OsinfoFilter *filter
);
Get all devices matching a given filter but unlike osinfo_os_get_devices this function also retreives devices from all derived and cloned operating systems.
|
an operating system |
|
an optional device property filter. [allow-none][transfer none] |
Returns : |
A list of devices. [transfer full] |
OsinfoDeviceLinkList * osinfo_os_get_device_links (OsinfoOs *os
,OsinfoFilter *filter
);
Get all devices matching a given filter. The filter matches against the links, not the devices.
|
an operating system |
|
an optional device property filter. [allow-none][transfer none] |
Returns : |
A list of device links. [transfer full] |
OsinfoDeviceList * osinfo_os_get_devices (OsinfoOs *os
,OsinfoFilter *filter
);
Get all devices matching a given filter
|
an operating system |
|
an optional device property filter. [allow-none][transfer none] |
Returns : |
A list of devices. [transfer full] |
OsinfoDeviceList * osinfo_os_get_devices_by_property (OsinfoOs *os
,const char *property
,const char *value
,gboolean inherited
);
A utility function that gets devices found from the list of devices
os
supports, for which the value of property
is value
.
|
an operating system |
|
the property of interest |
|
the required value of property property
|
|
Should devices from inherited and cloned OSs be included in the search. |
Returns : |
The found devices. [transfer full] |
const gchar * osinfo_os_get_distro (OsinfoOs *os
);
Retrieves the generic family the OS os
belongs to, for example fedora,
ubuntu, windows, solaris, freebsd etc.
|
a OsinfoOs |
Returns : |
the distro of this os. [transfer none] |
const gchar * osinfo_os_get_family (OsinfoOs *os
);
Retrieves the generic family the OS os
belongs to, based upon its kernel,
for example linux, winnt, solaris, freebsd etc.
|
a OsinfoOs |
Returns : |
the family of this os. [transfer none] |
OsinfoMediaList * osinfo_os_get_media_list (OsinfoOs *os
);
Get all installation medias associated with operating system os
.
|
an operating system |
Returns : |
A list of medias. [transfer full] |
OsinfoResourcesList * osinfo_os_get_minimum_resources (OsinfoOs *os
);
Get the list of minimum required resources for the operating system os
.
|
an operating system |
Returns : |
A list of resources. [transfer full] |
OsinfoResourcesList * osinfo_os_get_recommended_resources
(OsinfoOs *os
);
Get the list of recommended resources for the operating system os
.
|
an operating system |
Returns : |
A list of resources. [transfer full] |
OsinfoTreeList * osinfo_os_get_tree_list (OsinfoOs *os
);
Get all installation trees associated with operating system os
.
|
an operating system |
Returns : |
A list of trees. [transfer full] |
OsinfoOs * osinfo_os_new (const gchar *id
);
Create a new operating system entity
|
a unique identifier |
Returns : |
a new operating system entity. [transfer full] |