File: //snap/gnome-3-38-2004/143/usr/share/gtk-doc/html/gudev/GUdevDevice.html
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GUdevDevice: GUdev Reference Manual</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="index.html" title="GUdev Reference Manual">
<link rel="up" href="ref-API.html" title="API Reference">
<link rel="prev" href="GUdevClient.html" title="GUdevClient">
<link rel="next" href="GUdevEnumerator.html" title="GUdevEnumerator">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="5"><tr valign="middle">
<td width="100%" align="left" class="shortcuts">
<a href="#" class="shortcut">Top</a><span id="nav_description"> <span class="dim">|</span>
<a href="#GUdevDevice.description" class="shortcut">Description</a></span><span id="nav_hierarchy"> <span class="dim">|</span>
<a href="#GUdevDevice.object-hierarchy" class="shortcut">Object Hierarchy</a></span>
</td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
<td><a accesskey="u" href="ref-API.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
<td><a accesskey="p" href="GUdevClient.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
<td><a accesskey="n" href="GUdevEnumerator.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
</tr></table>
<div class="refentry">
<a name="GUdevDevice"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="GUdevDevice.top_of_page"></a>GUdevDevice</span></h2>
<p>GUdevDevice — Get information about a device</p>
</td>
<td class="gallery_image" valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1">
<a name="GUdevDevice.functions"></a><h2>Functions</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="functions_return">
<col class="functions_name">
</colgroup>
<tbody>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-subsystem" title="g_udev_device_get_subsystem ()">g_udev_device_get_subsystem</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-devtype" title="g_udev_device_get_devtype ()">g_udev_device_get_devtype</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-name" title="g_udev_device_get_name ()">g_udev_device_get_name</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-number" title="g_udev_device_get_number ()">g_udev_device_get_number</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-path" title="g_udev_device_get_sysfs_path ()">g_udev_device_get_sysfs_path</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-driver" title="g_udev_device_get_driver ()">g_udev_device_get_driver</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-action" title="g_udev_device_get_action ()">g_udev_device_get_action</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#guint64"><span class="returnvalue">guint64</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-seqnum" title="g_udev_device_get_seqnum ()">g_udev_device_get_seqnum</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GUdevClient.html#GUdevDeviceType" title="enum GUdevDeviceType"><span class="returnvalue">GUdevDeviceType</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-device-type" title="g_udev_device_get_device_type ()">g_udev_device_get_device_type</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GUdevClient.html#GUdevDeviceNumber" title="GUdevDeviceNumber"><span class="returnvalue">GUdevDeviceNumber</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-device-number" title="g_udev_device_get_device_number ()">g_udev_device_get_device_number</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-device-file" title="g_udev_device_get_device_file ()">g_udev_device_get_device_file</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-device-file-symlinks" title="g_udev_device_get_device_file_symlinks ()">g_udev_device_get_device_file_symlinks</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="returnvalue">GUdevDevice</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-parent" title="g_udev_device_get_parent ()">g_udev_device_get_parent</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="returnvalue">GUdevDevice</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-parent-with-subsystem" title="g_udev_device_get_parent_with_subsystem ()">g_udev_device_get_parent_with_subsystem</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-tags" title="g_udev_device_get_tags ()">g_udev_device_get_tags</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-is-initialized" title="g_udev_device_get_is_initialized ()">g_udev_device_get_is_initialized</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#guint64"><span class="returnvalue">guint64</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-usec-since-initialized" title="g_udev_device_get_usec_since_initialized ()">g_udev_device_get_usec_since_initialized</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-keys" title="g_udev_device_get_property_keys ()">g_udev_device_get_property_keys</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-has-property" title="g_udev_device_has_property ()">g_udev_device_has_property</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-property" title="g_udev_device_get_property ()">g_udev_device_get_property</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-int" title="g_udev_device_get_property_as_int ()">g_udev_device_get_property_as_int</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#guint64"><span class="returnvalue">guint64</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-uint64" title="g_udev_device_get_property_as_uint64 ()">g_udev_device_get_property_as_uint64</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#gdouble"><span class="returnvalue">gdouble</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-double" title="g_udev_device_get_property_as_double ()">g_udev_device_get_property_as_double</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-boolean" title="g_udev_device_get_property_as_boolean ()">g_udev_device_get_property_as_boolean</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-strv" title="g_udev_device_get_property_as_strv ()">g_udev_device_get_property_as_strv</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-keys" title="g_udev_device_get_sysfs_attr_keys ()">g_udev_device_get_sysfs_attr_keys</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-has-sysfs-attr" title="g_udev_device_has_sysfs_attr ()">g_udev_device_has_sysfs_attr</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr" title="g_udev_device_get_sysfs_attr ()">g_udev_device_get_sysfs_attr</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-int" title="g_udev_device_get_sysfs_attr_as_int ()">g_udev_device_get_sysfs_attr_as_int</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#guint64"><span class="returnvalue">guint64</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-uint64" title="g_udev_device_get_sysfs_attr_as_uint64 ()">g_udev_device_get_sysfs_attr_as_uint64</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#gdouble"><span class="returnvalue">gdouble</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-double" title="g_udev_device_get_sysfs_attr_as_double ()">g_udev_device_get_sysfs_attr_as_double</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-boolean" title="g_udev_device_get_sysfs_attr_as_boolean ()">g_udev_device_get_sysfs_attr_as_boolean</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
</td>
<td class="function_name">
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-strv" title="g_udev_device_get_sysfs_attr_as_strv ()">g_udev_device_get_sysfs_attr_as_strv</a> <span class="c_punctuation">()</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GUdevDevice.other"></a><h2>Types and Values</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="name">
<col class="description">
</colgroup>
<tbody>
<tr>
<td class="datatype_keyword"> </td>
<td class="function_name"><a class="link" href="GUdevDevice.html#GUdevDevice-struct" title="GUdevDevice">GUdevDevice</a></td>
</tr>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="GUdevDevice.html#GUdevDeviceClass" title="struct GUdevDeviceClass">GUdevDeviceClass</a></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GUdevDevice.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="screen"> <a href="../gobject/gobject-The-Base-Object-Type.html#GObject-struct">GObject</a>
<span class="lineart">╰──</span> GUdevDevice
</pre>
</div>
<div class="refsect1">
<a name="GUdevDevice.description"></a><h2>Description</h2>
<p>The <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> class is used to get information about a specific
device. Note that you cannot instantiate a <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> object
yourself. Instead you must use <a class="link" href="GUdevClient.html" title="GUdevClient"><span class="type">GUdevClient</span></a> to obtain <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>
objects.</p>
<p>To get basic information about a device, use
<a class="link" href="GUdevDevice.html#g-udev-device-get-subsystem" title="g_udev_device_get_subsystem ()"><code class="function">g_udev_device_get_subsystem()</code></a>, <a class="link" href="GUdevDevice.html#g-udev-device-get-devtype" title="g_udev_device_get_devtype ()"><code class="function">g_udev_device_get_devtype()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-name" title="g_udev_device_get_name ()"><code class="function">g_udev_device_get_name()</code></a>, <a class="link" href="GUdevDevice.html#g-udev-device-get-number" title="g_udev_device_get_number ()"><code class="function">g_udev_device_get_number()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-path" title="g_udev_device_get_sysfs_path ()"><code class="function">g_udev_device_get_sysfs_path()</code></a>, <a class="link" href="GUdevDevice.html#g-udev-device-get-driver" title="g_udev_device_get_driver ()"><code class="function">g_udev_device_get_driver()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-action" title="g_udev_device_get_action ()"><code class="function">g_udev_device_get_action()</code></a>, <a class="link" href="GUdevDevice.html#g-udev-device-get-seqnum" title="g_udev_device_get_seqnum ()"><code class="function">g_udev_device_get_seqnum()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-device-type" title="g_udev_device_get_device_type ()"><code class="function">g_udev_device_get_device_type()</code></a>, <a class="link" href="GUdevDevice.html#g-udev-device-get-device-number" title="g_udev_device_get_device_number ()"><code class="function">g_udev_device_get_device_number()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-device-file" title="g_udev_device_get_device_file ()"><code class="function">g_udev_device_get_device_file()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-device-file-symlinks" title="g_udev_device_get_device_file_symlinks ()"><code class="function">g_udev_device_get_device_file_symlinks()</code></a>.</p>
<p>To navigate the device tree, use <a class="link" href="GUdevDevice.html#g-udev-device-get-parent" title="g_udev_device_get_parent ()"><code class="function">g_udev_device_get_parent()</code></a> and
<a class="link" href="GUdevDevice.html#g-udev-device-get-parent-with-subsystem" title="g_udev_device_get_parent_with_subsystem ()"><code class="function">g_udev_device_get_parent_with_subsystem()</code></a>.</p>
<p>To access udev properties for the device, use
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-keys" title="g_udev_device_get_property_keys ()"><code class="function">g_udev_device_get_property_keys()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-has-property" title="g_udev_device_has_property ()"><code class="function">g_udev_device_has_property()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-property" title="g_udev_device_get_property ()"><code class="function">g_udev_device_get_property()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-int" title="g_udev_device_get_property_as_int ()"><code class="function">g_udev_device_get_property_as_int()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-uint64" title="g_udev_device_get_property_as_uint64 ()"><code class="function">g_udev_device_get_property_as_uint64()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-double" title="g_udev_device_get_property_as_double ()"><code class="function">g_udev_device_get_property_as_double()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-boolean" title="g_udev_device_get_property_as_boolean ()"><code class="function">g_udev_device_get_property_as_boolean()</code></a> and
<a class="link" href="GUdevDevice.html#g-udev-device-get-property-as-strv" title="g_udev_device_get_property_as_strv ()"><code class="function">g_udev_device_get_property_as_strv()</code></a>.</p>
<p>To access sysfs attributes for the device, use
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-keys" title="g_udev_device_get_sysfs_attr_keys ()"><code class="function">g_udev_device_get_sysfs_attr_keys()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-has-sysfs-attr" title="g_udev_device_has_sysfs_attr ()"><code class="function">g_udev_device_has_sysfs_attr()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr" title="g_udev_device_get_sysfs_attr ()"><code class="function">g_udev_device_get_sysfs_attr()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-int" title="g_udev_device_get_sysfs_attr_as_int ()"><code class="function">g_udev_device_get_sysfs_attr_as_int()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-uint64" title="g_udev_device_get_sysfs_attr_as_uint64 ()"><code class="function">g_udev_device_get_sysfs_attr_as_uint64()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-double" title="g_udev_device_get_sysfs_attr_as_double ()"><code class="function">g_udev_device_get_sysfs_attr_as_double()</code></a>,
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-boolean" title="g_udev_device_get_sysfs_attr_as_boolean ()"><code class="function">g_udev_device_get_sysfs_attr_as_boolean()</code></a> and
<a class="link" href="GUdevDevice.html#g-udev-device-get-sysfs-attr-as-strv" title="g_udev_device_get_sysfs_attr_as_strv ()"><code class="function">g_udev_device_get_sysfs_attr_as_strv()</code></a>.</p>
<p>Note that all getters on <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> are non-reffing – returned
values are owned by the object, should not be freed and are only
valid as long as the object is alive.</p>
<p>By design, <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> will not react to changes for a device – it
only contains a snapshot of information when the <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>
object was created. To work with changes, you typically connect to
the <a class="link" href="GUdevClient.html#GUdevClient-uevent" title="The “uevent” signal"><span class="type">“uevent”</span></a> signal on a <a class="link" href="GUdevClient.html" title="GUdevClient"><span class="type">GUdevClient</span></a> and get a new
<a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> whenever an event happens.</p>
</div>
<div class="refsect1">
<a name="GUdevDevice.functions_details"></a><h2>Functions</h2>
<div class="refsect2">
<a name="g-udev-device-get-subsystem"></a><h3>g_udev_device_get_subsystem ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_subsystem (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the subsystem for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-subsystem.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-subsystem.returns"></a><h4>Returns</h4>
<p> The subsystem for <em class="parameter"><code>device</code></em>
.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-devtype"></a><h3>g_udev_device_get_devtype ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_devtype (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the device type for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-devtype.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-devtype.returns"></a><h4>Returns</h4>
<p> The devtype for <em class="parameter"><code>device</code></em>
.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-name"></a><h3>g_udev_device_get_name ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_name (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the name of <em class="parameter"><code>device</code></em>
, e.g. "sda3".</p>
<div class="refsect3">
<a name="g-udev-device-get-name.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-name.returns"></a><h4>Returns</h4>
<p> The name of <em class="parameter"><code>device</code></em>
.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-number"></a><h3>g_udev_device_get_number ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_number (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the number of <em class="parameter"><code>device</code></em>
, e.g. "3" if <a class="link" href="GUdevDevice.html#g-udev-device-get-name" title="g_udev_device_get_name ()"><code class="function">g_udev_device_get_name()</code></a> returns "sda3".</p>
<div class="refsect3">
<a name="g-udev-device-get-number.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-number.returns"></a><h4>Returns</h4>
<p> The number of <em class="parameter"><code>device</code></em>
.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-sysfs-path"></a><h3>g_udev_device_get_sysfs_path ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_sysfs_path (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the sysfs path for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-path.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-path.returns"></a><h4>Returns</h4>
<p> The sysfs path for <em class="parameter"><code>device</code></em>
.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-driver"></a><h3>g_udev_device_get_driver ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_driver (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the name of the driver used for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-driver.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-driver.returns"></a><h4>Returns</h4>
<p>The name of the driver for <em class="parameter"><code>device</code></em>
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if
unknown. </p>
<p><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-action"></a><h3>g_udev_device_get_action ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_action (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the most recent action (e.g. "add", "remove", "change", etc.) for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-action.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-action.returns"></a><h4>Returns</h4>
<p> An action string.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-seqnum"></a><h3>g_udev_device_get_seqnum ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#guint64"><span class="returnvalue">guint64</span></a>
g_udev_device_get_seqnum (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the most recent sequence number for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-seqnum.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-seqnum.returns"></a><h4>Returns</h4>
<p> A sequence number.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-device-type"></a><h3>g_udev_device_get_device_type ()</h3>
<pre class="programlisting"><a class="link" href="GUdevClient.html#GUdevDeviceType" title="enum GUdevDeviceType"><span class="returnvalue">GUdevDeviceType</span></a>
g_udev_device_get_device_type (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the type of the device file, if any, for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-device-type.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-device-type.returns"></a><h4>Returns</h4>
<p> The device number for <em class="parameter"><code>device</code></em>
or <a class="link" href="GUdevClient.html#G-UDEV-DEVICE-TYPE-NONE:CAPS"><span class="type">G_UDEV_DEVICE_TYPE_NONE</span></a> if the device does not have a device file.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-device-number"></a><h3>g_udev_device_get_device_number ()</h3>
<pre class="programlisting"><a class="link" href="GUdevClient.html#GUdevDeviceNumber" title="GUdevDeviceNumber"><span class="returnvalue">GUdevDeviceNumber</span></a>
g_udev_device_get_device_number (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the device number, if any, for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-device-number.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-device-number.returns"></a><h4>Returns</h4>
<p> The device number for <em class="parameter"><code>device</code></em>
or 0 if unknown.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-device-file"></a><h3>g_udev_device_get_device_file ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_device_file (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the device file for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-device-file.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-device-file.returns"></a><h4>Returns</h4>
<p>The device file for <em class="parameter"><code>device</code></em>
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if no
device file exists. </p>
<p><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-device-file-symlinks"></a><h3>g_udev_device_get_device_file_symlinks ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
g_udev_device_get_device_file_symlinks
(<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets a list of symlinks (in <code class="literal">/dev</code>) that points to
the device file for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-device-file-symlinks.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-device-file-symlinks.returns"></a><h4>Returns</h4>
<p>A <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> terminated string array of symlinks. This array is owned by <em class="parameter"><code>device</code></em>
and should not be freed by the caller. </p>
<p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> zero-terminated=1][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> utf8]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-parent"></a><h3>g_udev_device_get_parent ()</h3>
<pre class="programlisting"><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="returnvalue">GUdevDevice</span></a> *
g_udev_device_get_parent (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets the immediate parent of <em class="parameter"><code>device</code></em>
, if any.</p>
<div class="refsect3">
<a name="g-udev-device-get-parent.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-parent.returns"></a><h4>Returns</h4>
<p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if
<em class="parameter"><code>device</code></em>
has no parent. Free with <a href="../gobject/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a>. </p>
<p><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>][<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-parent-with-subsystem"></a><h3>g_udev_device_get_parent_with_subsystem ()</h3>
<pre class="programlisting"><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="returnvalue">GUdevDevice</span></a> *
g_udev_device_get_parent_with_subsystem
(<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *subsystem</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *devtype</code></em>);</pre>
<p>Walks up the chain of parents of <em class="parameter"><code>device</code></em>
and returns the first
device encountered where <em class="parameter"><code>subsystem</code></em>
and <em class="parameter"><code>devtype</code></em>
matches, if any.</p>
<div class="refsect3">
<a name="g-udev-device-get-parent-with-subsystem.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>subsystem</p></td>
<td class="parameter_description"><p>The subsystem of the parent to get.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>devtype</p></td>
<td class="parameter_description"><p>The devtype of the parent to get or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is OK, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-parent-with-subsystem.returns"></a><h4>Returns</h4>
<p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if
<em class="parameter"><code>device</code></em>
has no parent with <em class="parameter"><code>subsystem</code></em>
and <em class="parameter"><code>devtype</code></em>
. Free with
<a href="../gobject/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a>. </p>
<p><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>][<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-tags"></a><h3>g_udev_device_get_tags ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
g_udev_device_get_tags (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets all tags for <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-tags.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-tags.returns"></a><h4>Returns</h4>
<p>A <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> terminated string array of tags. This array is owned by <em class="parameter"><code>device</code></em>
and should not be freed by the caller. </p>
<p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> zero-terminated=1][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> utf8]</span></p>
</div>
<p class="since">Since: <a class="link" href="ix02.html#api-index-165">165</a></p>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-is-initialized"></a><h3>g_udev_device_get_is_initialized ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
g_udev_device_get_is_initialized (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets whether <em class="parameter"><code>device</code></em>
has been initialized.</p>
<div class="refsect3">
<a name="g-udev-device-get-is-initialized.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-is-initialized.returns"></a><h4>Returns</h4>
<p> Whether <em class="parameter"><code>device</code></em>
has been initialized.</p>
</div>
<p class="since">Since: <a class="link" href="ix02.html#api-index-165">165</a></p>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-usec-since-initialized"></a><h3>g_udev_device_get_usec_since_initialized ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#guint64"><span class="returnvalue">guint64</span></a>
g_udev_device_get_usec_since_initialized
(<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets number of micro-seconds since <em class="parameter"><code>device</code></em>
was initialized.</p>
<p>This only works for devices with properties in the udev
database. All other devices return 0.</p>
<div class="refsect3">
<a name="g-udev-device-get-usec-since-initialized.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-usec-since-initialized.returns"></a><h4>Returns</h4>
<p> Number of micro-seconds since <em class="parameter"><code>device</code></em>
was initialized or 0 if unknown.</p>
</div>
<p class="since">Since: <a class="link" href="ix02.html#api-index-165">165</a></p>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-property-keys"></a><h3>g_udev_device_get_property_keys ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
g_udev_device_get_property_keys (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets all keys for properties on <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-property-keys.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-property-keys.returns"></a><h4>Returns</h4>
<p>A <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> terminated string array of property keys. This array is owned by <em class="parameter"><code>device</code></em>
and should not be freed by the caller. </p>
<p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> zero-terminated=1][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> utf8]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-has-property"></a><h3>g_udev_device_has_property ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
g_udev_device_has_property (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
<p>Check if a the property with the given key exists.</p>
<div class="refsect3">
<a name="g-udev-device-has-property.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>key</p></td>
<td class="parameter_description"><p>Name of property.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-has-property.returns"></a><h4>Returns</h4>
<p> <a href="../glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> only if the value for <em class="parameter"><code>key</code></em>
exist.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-property"></a><h3>g_udev_device_get_property ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_property (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
<p>Look up the value for <em class="parameter"><code>key</code></em>
on <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-property.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>key</p></td>
<td class="parameter_description"><p>Name of property.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-property.returns"></a><h4>Returns</h4>
<p>The value for <em class="parameter"><code>key</code></em>
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if <em class="parameter"><code>key</code></em>
doesn't
exist on <em class="parameter"><code>device</code></em>
. Do not free this string, it is owned by <em class="parameter"><code>device</code></em>
. </p>
<p><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-property-as-int"></a><h3>g_udev_device_get_property_as_int ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a>
g_udev_device_get_property_as_int (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
<p>Look up the value for <em class="parameter"><code>key</code></em>
on <em class="parameter"><code>device</code></em>
and convert it to an integer
using <code class="function">strtol()</code>.</p>
<div class="refsect3">
<a name="g-udev-device-get-property-as-int.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>key</p></td>
<td class="parameter_description"><p>Name of property.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-property-as-int.returns"></a><h4>Returns</h4>
<p> The value for <em class="parameter"><code>key</code></em>
or 0 if <em class="parameter"><code>key</code></em>
doesn't exist or
isn't an integer.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-property-as-uint64"></a><h3>g_udev_device_get_property_as_uint64 ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#guint64"><span class="returnvalue">guint64</span></a>
g_udev_device_get_property_as_uint64 (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
<p>Look up the value for <em class="parameter"><code>key</code></em>
on <em class="parameter"><code>device</code></em>
and convert it to an unsigned
64-bit integer using <a href="../glib/glib-String-Utility-Functions.html#g-ascii-strtoull"><code class="function">g_ascii_strtoull()</code></a>.</p>
<div class="refsect3">
<a name="g-udev-device-get-property-as-uint64.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>key</p></td>
<td class="parameter_description"><p>Name of property.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-property-as-uint64.returns"></a><h4>Returns</h4>
<p> The value for <em class="parameter"><code>key</code></em>
or 0 if <em class="parameter"><code>key</code></em>
doesn't exist or isn't a
<a href="../glib/glib-Basic-Types.html#guint64"><span class="type">guint64</span></a>.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-property-as-double"></a><h3>g_udev_device_get_property_as_double ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#gdouble"><span class="returnvalue">gdouble</span></a>
g_udev_device_get_property_as_double (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
<p>Look up the value for <em class="parameter"><code>key</code></em>
on <em class="parameter"><code>device</code></em>
and convert it to a double
precision floating point number using <code class="function">strtod()</code>.</p>
<div class="refsect3">
<a name="g-udev-device-get-property-as-double.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>key</p></td>
<td class="parameter_description"><p>Name of property.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-property-as-double.returns"></a><h4>Returns</h4>
<p> The value for <em class="parameter"><code>key</code></em>
or 0.0 if <em class="parameter"><code>key</code></em>
doesn't exist or isn't a
<a href="../glib/glib-Basic-Types.html#gdouble"><span class="type">gdouble</span></a>.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-property-as-boolean"></a><h3>g_udev_device_get_property_as_boolean ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
g_udev_device_get_property_as_boolean (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
<p>Look up the value for <em class="parameter"><code>key</code></em>
on <em class="parameter"><code>device</code></em>
and convert it to an
boolean. This is done by doing a case-insensitive string comparison
on the string value against "1" and "true".</p>
<div class="refsect3">
<a name="g-udev-device-get-property-as-boolean.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>key</p></td>
<td class="parameter_description"><p>Name of property.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-property-as-boolean.returns"></a><h4>Returns</h4>
<p> The value for <em class="parameter"><code>key</code></em>
or <a href="../glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if <em class="parameter"><code>key</code></em>
doesn't exist or
isn't a <a href="../glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-property-as-strv"></a><h3>g_udev_device_get_property_as_strv ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
g_udev_device_get_property_as_strv (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
<p>Look up the value for <em class="parameter"><code>key</code></em>
on <em class="parameter"><code>device</code></em>
and return the result of
splitting it into non-empty tokens split at white space (only space
(' '), form-feed ('\f'), newline ('\n'), carriage return ('\r'),
horizontal tab ('\t'), and vertical tab ('\v') are considered; the
locale is not taken into account).</p>
<div class="refsect3">
<a name="g-udev-device-get-property-as-strv.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>key</p></td>
<td class="parameter_description"><p>Name of property.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-property-as-strv.returns"></a><h4>Returns</h4>
<p>The value of <em class="parameter"><code>key</code></em>
on <em class="parameter"><code>device</code></em>
split into tokens or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if <em class="parameter"><code>key</code></em>
doesn't exist. This array is owned by <em class="parameter"><code>device</code></em>
and should not be
freed by the caller. </p>
<p><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>][<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> zero-terminated=1][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> utf8]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-sysfs-attr-keys"></a><h3>g_udev_device_get_sysfs_attr_keys ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
g_udev_device_get_sysfs_attr_keys (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>);</pre>
<p>Gets all keys for sysfs attributes on <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-keys.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-keys.returns"></a><h4>Returns</h4>
<p>A <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> terminated string array of sysfs attribute keys. This array is owned by <em class="parameter"><code>device</code></em>
and should not be freed by the caller. </p>
<p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> zero-terminated=1][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> utf8]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-has-sysfs-attr"></a><h3>g_udev_device_has_sysfs_attr ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
g_udev_device_has_sysfs_attr (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
<p>Check if a the sysfs attribute with the given key exists.</p>
<div class="refsect3">
<a name="g-udev-device-has-sysfs-attr.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>key</p></td>
<td class="parameter_description"><p>Name of sysfs attribute.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-has-sysfs-attr.returns"></a><h4>Returns</h4>
<p> <a href="../glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> only if the value for <em class="parameter"><code>key</code></em>
exist.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-sysfs-attr"></a><h3>g_udev_device_get_sysfs_attr ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
g_udev_device_get_sysfs_attr (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *name</code></em>);</pre>
<p>Look up the sysfs attribute with <em class="parameter"><code>name</code></em>
on <em class="parameter"><code>device</code></em>
.</p>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>name</p></td>
<td class="parameter_description"><p>Name of the sysfs attribute.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr.returns"></a><h4>Returns</h4>
<p>The value of the sysfs attribute or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if
there is no such attribute. Do not free this string, it is owned by
<em class="parameter"><code>device</code></em>
. </p>
<p><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-sysfs-attr-as-int"></a><h3>g_udev_device_get_sysfs_attr_as_int ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a>
g_udev_device_get_sysfs_attr_as_int (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *name</code></em>);</pre>
<p>Look up the sysfs attribute with <em class="parameter"><code>name</code></em>
on <em class="parameter"><code>device</code></em>
and convert it to an integer
using <code class="function">strtol()</code>.</p>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-int.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>name</p></td>
<td class="parameter_description"><p>Name of the sysfs attribute.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-int.returns"></a><h4>Returns</h4>
<p> The value of the sysfs attribute or 0 if there is no such
attribute.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-sysfs-attr-as-uint64"></a><h3>g_udev_device_get_sysfs_attr_as_uint64 ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#guint64"><span class="returnvalue">guint64</span></a>
g_udev_device_get_sysfs_attr_as_uint64
(<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *name</code></em>);</pre>
<p>Look up the sysfs attribute with <em class="parameter"><code>name</code></em>
on <em class="parameter"><code>device</code></em>
and convert it to an unsigned
64-bit integer using <a href="../glib/glib-String-Utility-Functions.html#g-ascii-strtoull"><code class="function">g_ascii_strtoull()</code></a>.</p>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-uint64.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>name</p></td>
<td class="parameter_description"><p>Name of the sysfs attribute.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-uint64.returns"></a><h4>Returns</h4>
<p> The value of the sysfs attribute or 0 if there is no such
attribute.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-sysfs-attr-as-double"></a><h3>g_udev_device_get_sysfs_attr_as_double ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#gdouble"><span class="returnvalue">gdouble</span></a>
g_udev_device_get_sysfs_attr_as_double
(<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *name</code></em>);</pre>
<p>Look up the sysfs attribute with <em class="parameter"><code>name</code></em>
on <em class="parameter"><code>device</code></em>
and convert it to a double
precision floating point number using <code class="function">strtod()</code>.</p>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-double.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>name</p></td>
<td class="parameter_description"><p>Name of the sysfs attribute.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-double.returns"></a><h4>Returns</h4>
<p> The value of the sysfs attribute or 0.0 if there is no such
attribute.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-sysfs-attr-as-boolean"></a><h3>g_udev_device_get_sysfs_attr_as_boolean ()</h3>
<pre class="programlisting"><a href="../glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
g_udev_device_get_sysfs_attr_as_boolean
(<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *name</code></em>);</pre>
<p>Look up the sysfs attribute with <em class="parameter"><code>name</code></em>
on <em class="parameter"><code>device</code></em>
and convert it to an
boolean. This is done by doing a case-insensitive string comparison
on the string value against "1" and "true".</p>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-boolean.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>name</p></td>
<td class="parameter_description"><p>Name of the sysfs attribute.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-boolean.returns"></a><h4>Returns</h4>
<p> The value of the sysfs attribute or <a href="../glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if there is no such
attribute.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-udev-device-get-sysfs-attr-as-strv"></a><h3>g_udev_device_get_sysfs_attr_as_strv ()</h3>
<pre class="programlisting">const <a href="../glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * const *
g_udev_device_get_sysfs_attr_as_strv (<em class="parameter"><code><a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> *device</code></em>,
<em class="parameter"><code>const <a href="../glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *name</code></em>);</pre>
<p>Look up the sysfs attribute with <em class="parameter"><code>name</code></em>
on <em class="parameter"><code>device</code></em>
and return the result of
splitting it into non-empty tokens split at white space (only space (' '),
form-feed ('\f'), newline ('\n'), carriage return ('\r'), horizontal
tab ('\t'), and vertical tab ('\v') are considered; the locale is
not taken into account).</p>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-strv.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>device</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>name</p></td>
<td class="parameter_description"><p>Name of the sysfs attribute.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-udev-device-get-sysfs-attr-as-strv.returns"></a><h4>Returns</h4>
<p>The value of the sysfs attribute split into tokens or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if
there is no such attribute. This array is owned by <em class="parameter"><code>device</code></em>
and
should not be freed by the caller. </p>
<p><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>][<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>][<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym> zero-terminated=1][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> utf8]</span></p>
</div>
</div>
</div>
<div class="refsect1">
<a name="GUdevDevice.other_details"></a><h2>Types and Values</h2>
<div class="refsect2">
<a name="GUdevDevice-struct"></a><h3>GUdevDevice</h3>
<pre class="programlisting">typedef struct _GUdevDevice GUdevDevice;</pre>
<p>The <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a> struct is opaque and should not be accessed directly.</p>
</div>
<hr>
<div class="refsect2">
<a name="GUdevDeviceClass"></a><h3>struct GUdevDeviceClass</h3>
<pre class="programlisting">struct GUdevDeviceClass {
GObjectClass parent_class;
};
</pre>
<p>Class structure for <a class="link" href="GUdevDevice.html" title="GUdevDevice"><span class="type">GUdevDevice</span></a>.</p>
<div class="refsect3">
<a name="GUdevDeviceClass.members"></a><h4>Members</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="300px" class="struct_members_name">
<col class="struct_members_description">
<col width="200px" class="struct_members_annotations">
</colgroup>
<tbody></tbody>
</table></div>
</div>
</div>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
</body>
</html>