AppStream.SystemInfo – appstream Reference Manual
Packages
appstream
AppStream
SystemInfo
SystemInfo
SystemInfo.template_for_chassis
get_device_name_for_modalias
get_display_length
get_gui_available
get_kernel_name
get_kernel_version
get_memory_total
get_modaliases
get_os_cid
get_os_homepage
get_os_id
get_os_name
get_os_version
has_device_matching_modalias
has_input_control
modalias_to_syspath
set_display_length
set_gui_available
set_input_control
SystemInfo
Object Hierarchy:
Description:
[
CCode
( type_id =
"as_system_info_get_type ()"
) ]
public
class
SystemInfo
:
Object
Namespace:
AppStream
Package:
appstream
Content:
Creation methods:
public
SystemInfo
()
Creates a new
SystemInfo
.
public
SystemInfo.template_for_chassis
(
ChassisKind
chassis)
throws
Error
Creates a new
SystemInfo
that can be used as a mock system for the given chassis type, reading (mostly) no information from the current system.
Methods:
public
string
get_device_name_for_modalias
(
string
modalias,
bool
allow_fallback)
throws
Error
Return a human readable device name for the given modalias.
public
ulong
get_display_length
(
DisplaySideKind
side)
Get the current display length for the given side kind.
public
bool
get_gui_available
()
Check whether graphical applications can be displayed via X11 or Wayland.
public
unowned
string
get_kernel_name
()
Get the name of the current kernel, e.
public
unowned
string
get_kernel_version
()
Get the version of the current kernel, e.
public
ulong
get_memory_total
()
Get the current total amount of physical memory in MiB.
public
unowned
GenericArray
<
string
>
get_modaliases
()
Get a list of modaliases for all the hardware on this system that has them.
public
unowned
string
get_os_cid
()
Get the AppStream component ID of the current operating system.
public
unowned
string
get_os_homepage
()
Get the homepage URL of the current operating system.
public
unowned
string
get_os_id
()
Get the ID of the current operating system.
public
unowned
string
get_os_name
()
Get the humen-readable name of the current operating system.
public
unowned
string
get_os_version
()
Get the version string of the current operating system.
public
bool
has_device_matching_modalias
(
string
modalias_glob)
Check if there is a device on this system that matches the given modalias glob.
public
CheckResult
has_input_control
(
ControlKind
kind)
throws
Error
Test if the current system has a specific user input control method.
public
unowned
string
modalias_to_syspath
(
string
modalias)
Receive a path in /sys for the devices with the given modalias.
public
void
set_display_length
(
DisplaySideKind
side,
ulong
value_dip)
Set the current display length for the given side kind.
public
void
set_gui_available
(
bool
available)
Set whether this system has a GUI / desktop environment available.
public
void
set_input_control
(
ControlKind
kind,
bool
found)
Explicitly mark a user input control as present or not present on this system.
Inherited Members:
All known members inherited from class GLib.Object
@get
@new
@ref
@set
add_toggle_ref
add_weak_pointer
bind_property
connect
constructed
disconnect
dispose
dup_data
dup_qdata
force_floating
freeze_notify
get_class
get_data
get_property
get_qdata
get_type
getv
interface_find_property
interface_install_property
interface_list_properties
is_floating
new_valist
new_with_properties
newv
notify
notify_property
ref_count
ref_sink
remove_toggle_ref
remove_weak_pointer
replace_data
replace_qdata
set_data
set_data_full
set_property
set_qdata
set_qdata_full
set_valist
setv
steal_data
steal_qdata
thaw_notify
unref
watch_closure
weak_ref
weak_unref