43
43
<a name="UDisksLinuxDriveAta.synopsis"></a><h2>Synopsis</h2>
44
44
<pre class="synopsis"> <a class="link" href="UDisksLinuxDriveAta.html#UDisksLinuxDriveAta-struct" title="UDisksLinuxDriveAta">UDisksLinuxDriveAta</a>;
45
45
<a class="link" href="UDisksDriveAta.html" title="UDisksDriveAta"><span class="returnvalue">UDisksDriveAta</span></a> * <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-new" title="udisks_linux_drive_ata_new ()">udisks_linux_drive_ata_new</a> (<em class="parameter"><code><span class="type">void</span></code></em>);
46
<span class="returnvalue">gboolean</span> <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-update" title="udisks_linux_drive_ata_update ()">udisks_linux_drive_ata_update</a> (<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
46
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-update" title="udisks_linux_drive_ata_update ()">udisks_linux_drive_ata_update</a> (<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
47
47
<em class="parameter"><code><a class="link" href="UDisksLinuxDriveObject.html" title="UDisksLinuxDriveObject"><span class="type">UDisksLinuxDriveObject</span></a> *object</code></em>);
48
<span class="returnvalue">gboolean</span> <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-refresh-smart-sync" title="udisks_linux_drive_ata_refresh_smart_sync ()">udisks_linux_drive_ata_refresh_smart_sync</a>
49
(<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
50
<em class="parameter"><code><span class="type">gboolean</span> nowakeup</code></em>,
51
<em class="parameter"><code>const <span class="type">gchar</span> *simulate_path</code></em>,
52
<em class="parameter"><code><span class="type">GCancellable</span> *cancellable</code></em>,
53
<em class="parameter"><code><span class="type">GError</span> **error</code></em>);
54
<span class="returnvalue">gboolean</span> <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-smart-selftest-sync" title="udisks_linux_drive_ata_smart_selftest_sync ()">udisks_linux_drive_ata_smart_selftest_sync</a>
55
(<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
56
<em class="parameter"><code>const <span class="type">gchar</span> *type</code></em>,
57
<em class="parameter"><code><span class="type">GCancellable</span> *cancellable</code></em>,
58
<em class="parameter"><code><span class="type">GError</span> **error</code></em>);
48
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-refresh-smart-sync" title="udisks_linux_drive_ata_refresh_smart_sync ()">udisks_linux_drive_ata_refresh_smart_sync</a>
49
(<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
50
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> nowakeup</code></em>,
51
<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *simulate_path</code></em>,
52
<em class="parameter"><code><a href="http://library.gnome.org/devel/gio/unstable/GCancellable.html"><span class="type">GCancellable</span></a> *cancellable</code></em>,
53
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);
54
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-smart-selftest-sync" title="udisks_linux_drive_ata_smart_selftest_sync ()">udisks_linux_drive_ata_smart_selftest_sync</a>
55
(<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
56
<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *type</code></em>,
57
<em class="parameter"><code><a href="http://library.gnome.org/devel/gio/unstable/GCancellable.html"><span class="type">GCancellable</span></a> *cancellable</code></em>,
58
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);
59
59
<span class="returnvalue">void</span> <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-apply-configuration" title="udisks_linux_drive_ata_apply_configuration ()">udisks_linux_drive_ata_apply_configuration</a>
60
60
(<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
61
61
<em class="parameter"><code><a class="link" href="UDisksLinuxDevice.html" title="UDisksLinuxDevice"><span class="type">UDisksLinuxDevice</span></a> *device</code></em>,
62
<em class="parameter"><code><span class="type">GVariant</span> *configuration</code></em>);
63
<span class="returnvalue">gboolean</span> <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-secure-erase-sync" title="udisks_linux_drive_ata_secure_erase_sync ()">udisks_linux_drive_ata_secure_erase_sync</a>
62
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-GVariant.html#GVariant"><span class="type">GVariant</span></a> *configuration</code></em>);
63
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="UDisksLinuxDriveAta.html#udisks-linux-drive-ata-secure-erase-sync" title="udisks_linux_drive_ata_secure_erase_sync ()">udisks_linux_drive_ata_secure_erase_sync</a>
64
64
(<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
65
65
<em class="parameter"><code><span class="type">uid_t</span> caller_uid</code></em>,
66
<em class="parameter"><code><span class="type">gboolean</span> enhanced</code></em>,
67
<em class="parameter"><code><span class="type">GError</span> **error</code></em>);
66
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> enhanced</code></em>,
67
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);
70
70
<div class="refsect1">
71
71
<a name="UDisksLinuxDriveAta.object-hierarchy"></a><h2>Object Hierarchy</h2>
72
72
<pre class="synopsis">
74
+----GDBusInterfaceSkeleton
73
<a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
74
+----<a href="http://library.gnome.org/devel/gio/unstable/GDBusInterfaceSkeleton.html">GDBusInterfaceSkeleton</a>
75
75
+----<a class="link" href="UDisksDriveAta.html#UDisksDriveAtaSkeleton">UDisksDriveAtaSkeleton</a>
76
76
+----UDisksLinuxDriveAta
115
115
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
116
<td>A new <a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a>. Free with <code class="function">g_object_unref()</code>.</td>
116
<td>A new <a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a>. Free with <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a>.</td>
121
121
<div class="refsect2">
122
122
<a name="udisks-linux-drive-ata-update"></a><h3>udisks_linux_drive_ata_update ()</h3>
123
<pre class="programlisting"><span class="returnvalue">gboolean</span> udisks_linux_drive_ata_update (<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
123
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> udisks_linux_drive_ata_update (<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
124
124
<em class="parameter"><code><a class="link" href="UDisksLinuxDriveObject.html" title="UDisksLinuxDriveObject"><span class="type">UDisksLinuxDriveObject</span></a> *object</code></em>);</pre>
126
126
Updates the interface.
151
151
<div class="refsect2">
152
152
<a name="udisks-linux-drive-ata-refresh-smart-sync"></a><h3>udisks_linux_drive_ata_refresh_smart_sync ()</h3>
153
<pre class="programlisting"><span class="returnvalue">gboolean</span> udisks_linux_drive_ata_refresh_smart_sync
153
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> udisks_linux_drive_ata_refresh_smart_sync
154
154
(<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
155
<em class="parameter"><code><span class="type">gboolean</span> nowakeup</code></em>,
156
<em class="parameter"><code>const <span class="type">gchar</span> *simulate_path</code></em>,
157
<em class="parameter"><code><span class="type">GCancellable</span> *cancellable</code></em>,
158
<em class="parameter"><code><span class="type">GError</span> **error</code></em>);</pre>
155
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> nowakeup</code></em>,
156
<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *simulate_path</code></em>,
157
<em class="parameter"><code><a href="http://library.gnome.org/devel/gio/unstable/GCancellable.html"><span class="type">GCancellable</span></a> *cancellable</code></em>,
158
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
160
160
Synchronously refreshes ATA S.M.A.R.T. data on <em class="parameter"><code>drive</code></em> using one of
161
161
the physical drives associated with it. The calling thread is
162
162
blocked until the data has been obtained.
165
If <em class="parameter"><code>nowake</code></em> is <code class="literal">TRUE</code> and the disk is in a sleep state this fails
165
If <em class="parameter"><code>nowake</code></em> is <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> and the disk is in a sleep state this fails
166
166
with <a class="link" href="udisks2-UDisksError.html#UDISKS-ERROR-WOULD-WAKEUP:CAPS"><code class="literal">UDISKS_ERROR_WOULD_WAKEUP</code></a>.
186
186
<td><p><span class="term"><em class="parameter"><code>nowakeup</code></em> :</span></p></td>
187
<td>If <code class="literal">TRUE</code>, will not wake up the disk if asleep.</td>
187
<td>If <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>, will not wake up the disk if asleep.</td>
190
190
<td><p><span class="term"><em class="parameter"><code>simulate_path</code></em> :</span></p></td>
191
<td>If not <code class="literal">NULL</code>, the path of a file with a libatasmart blob to use.</td>
191
<td>If not <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>, the path of a file with a libatasmart blob to use.</td>
194
194
<td><p><span class="term"><em class="parameter"><code>cancellable</code></em> :</span></p></td>
195
<td>A <span class="type">GCancellable</span> or <code class="literal">NULL</code>.</td>
195
<td>A <a href="http://library.gnome.org/devel/gio/unstable/GCancellable.html"><span class="type">GCancellable</span></a> or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</td>
198
198
<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td>
210
210
<div class="refsect2">
211
211
<a name="udisks-linux-drive-ata-smart-selftest-sync"></a><h3>udisks_linux_drive_ata_smart_selftest_sync ()</h3>
212
<pre class="programlisting"><span class="returnvalue">gboolean</span> udisks_linux_drive_ata_smart_selftest_sync
212
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> udisks_linux_drive_ata_smart_selftest_sync
213
213
(<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
214
<em class="parameter"><code>const <span class="type">gchar</span> *type</code></em>,
215
<em class="parameter"><code><span class="type">GCancellable</span> *cancellable</code></em>,
216
<em class="parameter"><code><span class="type">GError</span> **error</code></em>);</pre>
214
<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *type</code></em>,
215
<em class="parameter"><code><a href="http://library.gnome.org/devel/gio/unstable/GCancellable.html"><span class="type">GCancellable</span></a> *cancellable</code></em>,
216
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
218
218
Starts (or aborts) a SMART self-test on <em class="parameter"><code>drive</code></em>. Valid values for
219
219
<em class="parameter"><code>type</code></em> includes 'short', 'extended', 'conveyance' and 'abort'.
241
241
<td><p><span class="term"><em class="parameter"><code>cancellable</code></em> :</span></p></td>
242
<td>A <span class="type">GCancellable</span> that can be used to cancel the operation or <code class="literal">NULL</code>. <span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span>
242
<td>A <a href="http://library.gnome.org/devel/gio/unstable/GCancellable.html"><span class="type">GCancellable</span></a> that can be used to cancel the operation or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span>
246
246
<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td>
247
<td>Return location for error or <code class="literal">NULL</code>.</td>
247
<td>Return location for error or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</td>
250
250
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
252
<code class="literal">TRUE</code> if the operation succeed, <code class="literal">FALSE</code> if <em class="parameter"><code>error</code></em> is set.</td>
252
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the operation succeed, <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if <em class="parameter"><code>error</code></em> is set.</td>
291
291
<div class="refsect2">
292
292
<a name="udisks-linux-drive-ata-secure-erase-sync"></a><h3>udisks_linux_drive_ata_secure_erase_sync ()</h3>
293
<pre class="programlisting"><span class="returnvalue">gboolean</span> udisks_linux_drive_ata_secure_erase_sync
293
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> udisks_linux_drive_ata_secure_erase_sync
294
294
(<em class="parameter"><code><a class="link" href="UDisksLinuxDriveAta.html" title="UDisksLinuxDriveAta"><span class="type">UDisksLinuxDriveAta</span></a> *drive</code></em>,
295
295
<em class="parameter"><code><span class="type">uid_t</span> caller_uid</code></em>,
296
<em class="parameter"><code><span class="type">gboolean</span> enhanced</code></em>,
297
<em class="parameter"><code><span class="type">GError</span> **error</code></em>);</pre>
296
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> enhanced</code></em>,
297
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
299
299
Performs an ATA Secure Erase opeartion. Blocks the calling thread until the operation completes.
319
319
<td><p><span class="term"><em class="parameter"><code>enhanced</code></em> :</span></p></td>
321
<code class="literal">TRUE</code> to use the enhanced version of the ATA secure erase command.</td>
321
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> to use the enhanced version of the ATA secure erase command.</td>
324
324
<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td>
325
<td>Return location for error or <code class="literal">NULL</code>.</td>
325
<td>Return location for error or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</td>
328
328
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
330
<code class="literal">TRUE</code> if the operation succeeded, <code class="literal">FALSE</code> if <em class="parameter"><code>error</code></em> is set.</td>
330
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the operation succeeded, <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if <em class="parameter"><code>error</code></em> is set.</td>