Top | ![]() |
![]() |
![]() |
![]() |
gchar *
fwupd_device_to_string (FwupdDevice *self
);
Builds a text representation of the object.
Since: 0.9.3
const gchar *
fwupd_device_get_id (FwupdDevice *self
);
Gets the ID.
Since: 0.9.3
void fwupd_device_set_id (FwupdDevice *self
,const gchar *id
);
Sets the ID.
Since: 0.9.3
const gchar *
fwupd_device_get_parent_id (FwupdDevice *self
);
Gets the parent ID.
Since: 1.0.8
void fwupd_device_set_parent_id (FwupdDevice *self
,const gchar *parent_id
);
Sets the parent ID.
Since: 1.0.8
const gchar *
fwupd_device_get_composite_id (FwupdDevice *self
);
Gets the composite ID, falling back to the device ID if unset.
The composite ID will be the same value for all parent, child and sibling devices.
Since: 1.6.0
void fwupd_device_set_composite_id (FwupdDevice *self
,const gchar *composite_id
);
Sets the composite ID, which is usually a SHA1 hash of a grandparent or parent device.
Since: 1.6.0
FwupdDevice *
fwupd_device_get_root (FwupdDevice *self
);
Gets the device root.
Since: 1.7.4
FwupdDevice *
fwupd_device_get_parent (FwupdDevice *self
);
Gets the parent.
Since: 1.0.8
void fwupd_device_set_parent (FwupdDevice *self
,FwupdDevice *parent
);
Sets the parent. Only used internally.
Since: 1.0.8
void fwupd_device_add_child (FwupdDevice *self
,FwupdDevice *child
);
Adds a child device. An child device is logically linked to the primary device in some way.
NOTE: You should never call this function from user code, it is for daemon
use only. Only use fwupd_device_set_parent()
to set up a logical tree.
Since: 1.5.1
void fwupd_device_remove_child (FwupdDevice *self
,FwupdDevice *child
);
Removes a child device.
NOTE: You should never call this function from user code, it is for daemon use only.
Since: 1.6.2
GPtrArray *
fwupd_device_get_children (FwupdDevice *self
);
Gets the device children. These can only be assigned using fwupd_device_set_parent()
.
Since: 1.3.7
const gchar *
fwupd_device_get_name (FwupdDevice *self
);
Gets the device name.
Since: 0.9.3
void fwupd_device_set_name (FwupdDevice *self
,const gchar *name
);
Sets the device name.
Since: 0.9.3
const gchar *
fwupd_device_get_serial (FwupdDevice *self
);
Gets the serial number for the device.
Since: 1.1.2
void fwupd_device_set_serial (FwupdDevice *self
,const gchar *serial
);
Sets the serial number for the device.
Since: 1.1.2
const gchar *
fwupd_device_get_summary (FwupdDevice *self
);
Gets the device summary.
Since: 0.9.3
void fwupd_device_set_summary (FwupdDevice *self
,const gchar *summary
);
Sets the device summary.
Since: 0.9.3
const gchar *
fwupd_device_get_branch (FwupdDevice *self
);
Gets the current device branch.
Since: 1.5.0
void fwupd_device_set_branch (FwupdDevice *self
,const gchar *branch
);
Sets the current device branch.
Since: 1.5.0
const gchar *
fwupd_device_get_description (FwupdDevice *self
);
Gets the device description in AppStream markup format.
Since: 0.9.3
void fwupd_device_set_description (FwupdDevice *self
,const gchar *description
);
Sets the device description.
Since: 0.9.3
const gchar *
fwupd_device_get_version (FwupdDevice *self
);
Gets the device version.
Since: 0.9.3
void fwupd_device_set_version (FwupdDevice *self
,const gchar *version
);
Sets the device version.
Since: 0.9.3
const gchar *
fwupd_device_get_version_lowest (FwupdDevice *self
);
Gets the lowest version of firmware the device will accept.
Since: 0.9.3
void fwupd_device_set_version_lowest (FwupdDevice *self
,const gchar *version_lowest
);
Sets the lowest version of firmware the device will accept.
Since: 0.9.3
guint64
fwupd_device_get_version_lowest_raw (FwupdDevice *self
);
Gets the lowest version of firmware the device will accept in raw format.
Since: 1.4.0
void fwupd_device_set_version_lowest_raw (FwupdDevice *self
,guint64 version_lowest_raw
);
Sets the raw lowest version number from the hardware before converted to a string.
Since: 1.4.0
const gchar *
fwupd_device_get_version_bootloader (FwupdDevice *self
);
Gets the version of the bootloader.
Since: 0.9.3
void fwupd_device_set_version_bootloader (FwupdDevice *self
,const gchar *version_bootloader
);
Sets the bootloader version.
Since: 0.9.3
guint64
fwupd_device_get_version_bootloader_raw
(FwupdDevice *self
);
Gets the bootloader version of firmware the device will accept in raw format.
Since: 1.4.0
void fwupd_device_set_version_bootloader_raw (FwupdDevice *self
,guint64 version_bootloader_raw
);
Sets the raw bootloader version number from the hardware before converted to a string.
Since: 1.4.0
guint64
fwupd_device_get_version_raw (FwupdDevice *self
);
Gets the raw version number from the hardware before converted to a string.
Since: 1.3.6
void fwupd_device_set_version_raw (FwupdDevice *self
,guint64 version_raw
);
Sets the raw version number from the hardware before converted to a string.
Since: 1.3.6
guint64
fwupd_device_get_version_build_date (FwupdDevice *self
);
Gets the date when the firmware was built.
Since: 1.6.2
void fwupd_device_set_version_build_date (FwupdDevice *self
,guint64 version_build_date
);
Sets the date when the firmware was built.
Since: 1.6.2
FwupdVersionFormat
fwupd_device_get_version_format (FwupdDevice *self
);
Gets the version format.
Since: 1.2.9
void fwupd_device_set_version_format (FwupdDevice *self
,FwupdVersionFormat version_format
);
Sets the version format.
Since: 1.2.9
guint32
fwupd_device_get_flashes_left (FwupdDevice *self
);
Gets the number of flash cycles left on the device
Since: 0.9.3
void fwupd_device_set_flashes_left (FwupdDevice *self
,guint32 flashes_left
);
Sets the number of flash cycles left on the device
Since: 0.9.3
guint32
fwupd_device_get_install_duration (FwupdDevice *self
);
Gets the time estimate for firmware installation (in seconds)
Since: 1.1.3
void fwupd_device_set_install_duration (FwupdDevice *self
,guint32 duration
);
Sets the time estimate for firmware installation (in seconds)
Since: 1.1.3
guint64
fwupd_device_get_flags (FwupdDevice *self
);
Gets device flags.
Since: 0.9.3
void fwupd_device_set_flags (FwupdDevice *self
,guint64 flags
);
Sets device flags.
Since: 0.9.3
void fwupd_device_add_flag (FwupdDevice *self
,FwupdDeviceFlags flag
);
Adds a specific device flag to the device.
Since: 0.9.3
void fwupd_device_remove_flag (FwupdDevice *self
,FwupdDeviceFlags flag
);
Removes a specific device flag from the device.
Since: 0.9.3
gboolean fwupd_device_has_flag (FwupdDevice *self
,FwupdDeviceFlags flag
);
Finds if the device has a specific device flag.
Since: 0.9.3
guint64
fwupd_device_get_created (FwupdDevice *self
);
Gets when the device was created.
Since: 0.9.3
void fwupd_device_set_created (FwupdDevice *self
,guint64 created
);
Sets when the device was created.
Since: 0.9.3
guint64
fwupd_device_get_modified (FwupdDevice *self
);
Gets when the device was modified.
Since: 0.9.3
void fwupd_device_set_modified (FwupdDevice *self
,guint64 modified
);
Sets when the device was modified.
Since: 0.9.3
GPtrArray *
fwupd_device_get_checksums (FwupdDevice *self
);
Gets the device checksums.
Since: 0.9.3
void fwupd_device_add_checksum (FwupdDevice *self
,const gchar *checksum
);
Adds a device checksum.
Since: 0.9.3
const gchar *
fwupd_device_get_plugin (FwupdDevice *self
);
Gets the plugin that created the device.
Since: 1.0.0
void fwupd_device_set_plugin (FwupdDevice *self
,const gchar *plugin
);
Sets the plugin that created the device.
Since: 1.0.0
const gchar *
fwupd_device_get_protocol (FwupdDevice *self
);
fwupd_device_get_protocol
has been deprecated since version 1.5.8 and should not be used in newly-written code.
Use fwupd_device_get_protocols()
instead.
Gets the protocol name that the device uses for updating.
Since: 1.3.6
void fwupd_device_set_protocol (FwupdDevice *self
,const gchar *protocol
);
fwupd_device_set_protocol
has been deprecated since version 1.5.8 and should not be used in newly-written code.
Use fwupd_device_add_protocol()
instead.
Sets the protocol name that is used to update the device.
Since: 1.3.6
void fwupd_device_add_protocol (FwupdDevice *self
,const gchar *protocol
);
Adds a device protocol name.
Since: 1.5.8
gboolean fwupd_device_has_protocol (FwupdDevice *self
,const gchar *protocol
);
Finds out if the device has this specific protocol name.
Since: 1.5.8
GPtrArray *
fwupd_device_get_protocols (FwupdDevice *self
);
Gets the device protocol names.
Since: 1.5.8
const gchar *
fwupd_device_get_vendor (FwupdDevice *self
);
Gets the device vendor.
Since: 0.9.3
void fwupd_device_set_vendor (FwupdDevice *self
,const gchar *vendor
);
Sets the device vendor.
Since: 0.9.3
const gchar *
fwupd_device_get_vendor_id (FwupdDevice *self
);
fwupd_device_get_vendor_id
has been deprecated since version 1.5.5 and should not be used in newly-written code.
Use fwupd_device_get_vendor_ids()
instead.
Gets the combined device vendor ID.
Since: 0.9.4
void fwupd_device_set_vendor_id (FwupdDevice *self
,const gchar *vendor_id
);
fwupd_device_set_vendor_id
has been deprecated since version 1.5.5 and should not be used in newly-written code.
Use fwupd_device_add_vendor_id()
instead.
Sets the device vendor ID.
self |
||
vendor_id |
the vendor ID, e.g. 'USB:0x1234' or 'USB:0x1234|PCI:0x5678'. |
[not nullable] |
Since: 0.9.4
void fwupd_device_add_vendor_id (FwupdDevice *self
,const gchar *vendor_id
);
Adds a device vendor ID.
Since: 1.5.5
gboolean fwupd_device_has_vendor_id (FwupdDevice *self
,const gchar *vendor_id
);
Finds out if the device has this specific vendor ID.
Since: 1.5.5
GPtrArray *
fwupd_device_get_vendor_ids (FwupdDevice *self
);
Gets the device vendor ID.
Since: 1.5.5
void fwupd_device_add_guid (FwupdDevice *self
,const gchar *guid
);
Adds the GUID if it does not already exist.
Since: 0.9.3
gboolean fwupd_device_has_guid (FwupdDevice *self
,const gchar *guid
);
Finds out if the device has this specific GUID.
Since: 0.9.3
GPtrArray *
fwupd_device_get_guids (FwupdDevice *self
);
Gets the GUIDs.
Since: 0.9.3
const gchar *
fwupd_device_get_guid_default (FwupdDevice *self
);
Gets the default GUID.
Since: 0.9.3
void fwupd_device_add_instance_id (FwupdDevice *self
,const gchar *instance_id
);
Adds the instance ID if it does not already exist.
Since: 1.2.5
gboolean fwupd_device_has_instance_id (FwupdDevice *self
,const gchar *instance_id
);
Finds out if the device has this specific instance ID.
Since: 1.2.5
GPtrArray *
fwupd_device_get_instance_ids (FwupdDevice *self
);
Gets the instance IDs.
Since: 1.2.5
void fwupd_device_add_icon (FwupdDevice *self
,const gchar *icon
);
Adds the icon name if it does not already exist.
Since: 0.9.8
gboolean fwupd_device_has_icon (FwupdDevice *self
,const gchar *icon
);
Finds out if the device has this specific icon.
Since: 1.6.2
GPtrArray *
fwupd_device_get_icons (FwupdDevice *self
);
Gets the icon names to use for the device.
NOTE: Icons specified without a full path are stock icons and should be loaded from the users icon theme.
Since: 0.9.8
GPtrArray *
fwupd_device_get_issues (FwupdDevice *self
);
Gets the list of issues currently affecting this device.
Since: 1.7.6
void fwupd_device_add_issue (FwupdDevice *self
,const gchar *issue
);
Adds an current issue to this device.
Since: 1.7.6
FwupdUpdateState
fwupd_device_get_update_state (FwupdDevice *self
);
Gets the update state.
Since: 0.9.8
void fwupd_device_set_update_state (FwupdDevice *self
,FwupdUpdateState update_state
);
Sets the update state.
Since: 0.9.8
const gchar *
fwupd_device_get_update_error (FwupdDevice *self
);
Gets the update error string.
Since: 0.9.8
void fwupd_device_set_update_error (FwupdDevice *self
,const gchar *update_error
);
Sets the update error string.
Since: 0.9.8
const gchar *
fwupd_device_get_update_message (FwupdDevice *self
);
Gets the update message string.
Since: 1.2.4
void fwupd_device_set_update_message (FwupdDevice *self
,const gchar *update_message
);
Sets the update message string.
Since: 1.2.4
const gchar *
fwupd_device_get_update_image (FwupdDevice *self
);
Gets the update image URL.
Since: 1.4.5
void fwupd_device_set_update_image (FwupdDevice *self
,const gchar *update_image
);
Sets the update image URL.
Since: 1.4.5
FwupdStatus
fwupd_device_get_status (FwupdDevice *self
);
Returns what the device is currently doing.
Since: 1.4.0
void fwupd_device_set_status (FwupdDevice *self
,FwupdStatus status
);
Sets what the device is currently doing.
Since: 1.4.0
void fwupd_device_add_release (FwupdDevice *self
,FwupdRelease *release
);
Adds a release for this device.
Since: 0.9.8
GPtrArray *
fwupd_device_get_releases (FwupdDevice *self
);
Gets all the releases for this device.
Since: 0.9.8
FwupdRelease *
fwupd_device_get_release_default (FwupdDevice *self
);
Gets the default release for this device.
Since: 0.9.8
gint fwupd_device_compare (FwupdDevice *self1
,FwupdDevice *self2
);
Comparison function for comparing two device objects.
Since: 1.1.1
FwupdDevice *
fwupd_device_from_variant (GVariant *value
);
Creates a new device using serialized data.
Since: 1.0.0
GPtrArray *
fwupd_device_array_from_variant (GVariant *value
);
Creates an array of new devices using serialized data.
Since: 1.2.10