diff options
| author | Michael Biebl <biebl@debian.org> | 2012-03-24 01:37:02 +0100 |
|---|---|---|
| committer | Michael Biebl <biebl@debian.org> | 2012-03-24 01:37:02 +0100 |
| commit | 6d09564a44846697e1b2a4d50fc5272834c33ed9 (patch) | |
| tree | 562300c45bf4c7d09a2903ccdf1c4d1647989725 /docs/libnm-util/html/libnm-util-nm-utils.html | |
| parent | 1ac8eb294d0f5e38bd08f709047a73e24a5a4dd3 (diff) | |
| parent | de06e5715e780baade318f3490ac7a4c9ce84e32 (diff) | |
Merge tag 'upstream/0.9.4.0'
Upstream version 0.9.4.0
Diffstat (limited to 'docs/libnm-util/html/libnm-util-nm-utils.html')
| -rw-r--r-- | docs/libnm-util/html/libnm-util-nm-utils.html | 178 |
1 files changed, 173 insertions, 5 deletions
diff --git a/docs/libnm-util/html/libnm-util-nm-utils.html b/docs/libnm-util/html/libnm-util-nm-utils.html index c9aa3d53..a17c1ece 100644 --- a/docs/libnm-util/html/libnm-util-nm-utils.html +++ b/docs/libnm-util/html/libnm-util-nm-utils.html @@ -24,6 +24,8 @@ <a href="#libnm-util-nm-utils.synopsis" class="shortcut">Top</a> | <a href="#libnm-util-nm-utils.description" class="shortcut">Description</a> + | + <a href="#libnm-util-nm-utils.object-hierarchy" class="shortcut">Object Hierarchy</a> </td></tr> </table> <div class="refentry"> @@ -37,14 +39,24 @@ </tr></table></div> <div class="refsynopsisdiv"> <a name="libnm-util-nm-utils.synopsis"></a><h2>Synopsis</h2> -<pre class="synopsis"> +<a name="NMUtilsSecurityType"></a><pre class="synopsis"> #include <nm-utils.h> -enum <a class="link" href="libnm-util-nm-utils.html#NMUtilsSecurityType" title="enum NMUtilsSecurityType">NMUtilsSecurityType</a>; +enum <a class="link" href="libnm-util-nm-utils.html#NMUtilsSecurityType-enum" title="enum NMUtilsSecurityType">NMUtilsSecurityType</a>; +#define <a class="link" href="libnm-util-nm-utils.html#NM-UTILS-HWADDR-LEN-MAX:CAPS" title="NM_UTILS_HWADDR_LEN_MAX">NM_UTILS_HWADDR_LEN_MAX</a> <span class="returnvalue">void</span> <a class="link" href="libnm-util-nm-utils.html#nm-utils-deinit" title="nm_utils_deinit ()">nm_utils_deinit</a> (<em class="parameter"><code><span class="type">void</span></code></em>); const <span class="returnvalue">char</span> * <a class="link" href="libnm-util-nm-utils.html#nm-utils-escape-ssid" title="nm_utils_escape_ssid ()">nm_utils_escape_ssid</a> (<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint8"><span class="type">guint8</span></a> *ssid</code></em>, <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint32"><span class="type">guint32</span></a> len</code></em>); <a href="http://library.gnome.org/devel/glib/unstable/glib-Hash-Tables.html#GHashTable"><span class="returnvalue">GHashTable</span></a> * <a class="link" href="libnm-util-nm-utils.html#nm-utils-gvalue-hash-dup" title="nm_utils_gvalue_hash_dup ()">nm_utils_gvalue_hash_dup</a> (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Hash-Tables.html#GHashTable"><span class="type">GHashTable</span></a> *hash</code></em>); +<a href="http://library.gnome.org/devel/glib/unstable/glib-Byte-Arrays.html#GByteArray"><span class="returnvalue">GByteArray</span></a> * <a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-atoba" title="nm_utils_hwaddr_atoba ()">nm_utils_hwaddr_atoba</a> (<em class="parameter"><code>const <span class="type">char</span> *asc</code></em>, + <em class="parameter"><code><span class="type">int</span> type</code></em>); +<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint8"><span class="returnvalue">guint8</span></a> * <a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-aton" title="nm_utils_hwaddr_aton ()">nm_utils_hwaddr_aton</a> (<em class="parameter"><code>const <span class="type">char</span> *asc</code></em>, + <em class="parameter"><code><span class="type">int</span> type</code></em>, + <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> buffer</code></em>); +<span class="returnvalue">int</span> <a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-len" title="nm_utils_hwaddr_len ()">nm_utils_hwaddr_len</a> (<em class="parameter"><code><span class="type">int</span> type</code></em>); +<span class="returnvalue">char</span> * <a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-ntoa" title="nm_utils_hwaddr_ntoa ()">nm_utils_hwaddr_ntoa</a> (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gconstpointer"><span class="type">gconstpointer</span></a> addr</code></em>, + <em class="parameter"><code><span class="type">int</span> type</code></em>); +<span class="returnvalue">int</span> <a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-type" title="nm_utils_hwaddr_type ()">nm_utils_hwaddr_type</a> (<em class="parameter"><code><span class="type">int</span> len</code></em>); <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="libnm-util-nm-utils.html#nm-utils-init" title="nm_utils_init ()">nm_utils_init</a> (<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>); <a href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"><span class="returnvalue">GSList</span></a> * <a class="link" href="libnm-util-nm-utils.html#nm-utils-ip4-addresses-from-gvalue" title="nm_utils_ip4_addresses_from_gvalue ()">nm_utils_ip4_addresses_from_gvalue</a> (<em class="parameter"><code>const <a href="http://library.gnome.org/devel/gobject/unstable/gobject-Generic-values.html#GValue"><span class="type">GValue</span></a> *value</code></em>); <span class="returnvalue">void</span> <a class="link" href="libnm-util-nm-utils.html#nm-utils-ip4-addresses-to-gvalue" title="nm_utils_ip4_addresses_to_gvalue ()">nm_utils_ip4_addresses_to_gvalue</a> (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"><span class="type">GSList</span></a> *list</code></em>, @@ -73,7 +85,7 @@ const <span class="returnvalue">char</span> * <a class="link" href="libnm <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="libnm-util-nm-utils.html#nm-utils-same-ssid" title="nm_utils_same_ssid ()">nm_utils_same_ssid</a> (<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Byte-Arrays.html#GByteArray"><span class="type">GByteArray</span></a> *ssid1</code></em>, <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Byte-Arrays.html#GByteArray"><span class="type">GByteArray</span></a> *ssid2</code></em>, <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> ignore_trailing_null</code></em>); -<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="libnm-util-nm-utils.html#nm-utils-security-valid" title="nm_utils_security_valid ()">nm_utils_security_valid</a> (<em class="parameter"><code><a class="link" href="libnm-util-nm-utils.html#NMUtilsSecurityType" title="enum NMUtilsSecurityType"><span class="type">NMUtilsSecurityType</span></a> type</code></em>, +<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="libnm-util-nm-utils.html#nm-utils-security-valid" title="nm_utils_security_valid ()">nm_utils_security_valid</a> (<em class="parameter"><code><a class="link" href="libnm-util-nm-utils.html#NMUtilsSecurityType"><span class="type">NMUtilsSecurityType</span></a> type</code></em>, <em class="parameter"><code><span class="type">NMDeviceWifiCapabilities</span> wifi_caps</code></em>, <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> have_ap</code></em>, <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> adhoc</code></em>, @@ -96,6 +108,13 @@ const <span class="returnvalue">char</span> * <a class="link" href="libnm </pre> </div> <div class="refsect1"> +<a name="libnm-util-nm-utils.object-hierarchy"></a><h2>Object Hierarchy</h2> +<pre class="synopsis"> + GEnum + +----NMUtilsSecurityType +</pre> +</div> +<div class="refsect1"> <a name="libnm-util-nm-utils.description"></a><h2>Description</h2> <p> A collection of utility functions for working SSIDs, IP addresses, WiFi @@ -105,7 +124,7 @@ access points and devices, among other things. <div class="refsect1"> <a name="libnm-util-nm-utils.details"></a><h2>Details</h2> <div class="refsect2"> -<a name="NMUtilsSecurityType"></a><h3>enum NMUtilsSecurityType</h3> +<a name="NMUtilsSecurityType-enum"></a><h3>enum NMUtilsSecurityType</h3> <pre class="programlisting">typedef enum { NMU_SEC_INVALID = 0, NMU_SEC_NONE, @@ -178,6 +197,17 @@ generating the dynamic WEP keys automatically </div> <hr> <div class="refsect2"> +<a name="NM-UTILS-HWADDR-LEN-MAX:CAPS"></a><h3>NM_UTILS_HWADDR_LEN_MAX</h3> +<pre class="programlisting">#define NM_UTILS_HWADDR_LEN_MAX 20 /* INFINIBAND_ALEN */ +</pre> +<p> +The maximum length of a hardware address of a type known by +<a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-len" title="nm_utils_hwaddr_len ()"><code class="function">nm_utils_hwaddr_len()</code></a> or <a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-aton" title="nm_utils_hwaddr_aton ()"><code class="function">nm_utils_hwaddr_aton()</code></a>. This can be used +as the size of the buffer passed to <a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-aton" title="nm_utils_hwaddr_aton ()"><code class="function">nm_utils_hwaddr_aton()</code></a>. +</p> +</div> +<hr> +<div class="refsect2"> <a name="nm-utils-deinit"></a><h3>nm_utils_deinit ()</h3> <pre class="programlisting"><span class="returnvalue">void</span> nm_utils_deinit (<em class="parameter"><code><span class="type">void</span></code></em>);</pre> <p> @@ -243,6 +273,144 @@ returned hash with <a href="http://library.gnome.org/devel/glib/unstable/glib-Ha </div> <hr> <div class="refsect2"> +<a name="nm-utils-hwaddr-atoba"></a><h3>nm_utils_hwaddr_atoba ()</h3> +<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Byte-Arrays.html#GByteArray"><span class="returnvalue">GByteArray</span></a> * nm_utils_hwaddr_atoba (<em class="parameter"><code>const <span class="type">char</span> *asc</code></em>, + <em class="parameter"><code><span class="type">int</span> type</code></em>);</pre> +<p> +Parses <em class="parameter"><code>asc</code></em> and converts it to binary form in a <a href="http://library.gnome.org/devel/glib/unstable/glib-Byte-Arrays.html#GByteArray"><span class="type">GByteArray</span></a>. See +<a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-aton" title="nm_utils_hwaddr_aton ()"><code class="function">nm_utils_hwaddr_aton()</code></a> if you don't want a <a href="http://library.gnome.org/devel/glib/unstable/glib-Byte-Arrays.html#GByteArray"><span class="type">GByteArray</span></a>. +</p> +<div class="variablelist"><table border="0"> +<col align="left" valign="top"> +<tbody> +<tr> +<td><p><span class="term"><em class="parameter"><code>asc</code></em> :</span></p></td> +<td>the ASCII representation of a hardware address</td> +</tr> +<tr> +<td><p><span class="term"><em class="parameter"><code>type</code></em> :</span></p></td> +<td>the type of address; either <code class="literal">ARPHRD_ETHER</code> or <code class="literal">ARPHRD_INFINIBAND</code> +</td> +</tr> +<tr> +<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> +<td>a new <a href="http://library.gnome.org/devel/glib/unstable/glib-Byte-Arrays.html#GByteArray"><span class="type">GByteArray</span></a>, or <a href="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a> if <em class="parameter"><code>asc</code></em> couldn't +be parsed. <span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span> +</td> +</tr> +</tbody> +</table></div> +</div> +<hr> +<div class="refsect2"> +<a name="nm-utils-hwaddr-aton"></a><h3>nm_utils_hwaddr_aton ()</h3> +<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint8"><span class="returnvalue">guint8</span></a> * nm_utils_hwaddr_aton (<em class="parameter"><code>const <span class="type">char</span> *asc</code></em>, + <em class="parameter"><code><span class="type">int</span> type</code></em>, + <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> buffer</code></em>);</pre> +<p> +Parses <em class="parameter"><code>asc</code></em> and converts it to binary form in <em class="parameter"><code>buffer</code></em>. See +<a class="link" href="libnm-util-nm-utils.html#nm-utils-hwaddr-atoba" title="nm_utils_hwaddr_atoba ()"><code class="function">nm_utils_hwaddr_atoba()</code></a> if you'd rather have the result in a +<a href="http://library.gnome.org/devel/glib/unstable/glib-Byte-Arrays.html#GByteArray"><span class="type">GByteArray</span></a>. +</p> +<div class="variablelist"><table border="0"> +<col align="left" valign="top"> +<tbody> +<tr> +<td><p><span class="term"><em class="parameter"><code>asc</code></em> :</span></p></td> +<td>the ASCII representation of a hardware address</td> +</tr> +<tr> +<td><p><span class="term"><em class="parameter"><code>type</code></em> :</span></p></td> +<td>the type of address; either <code class="literal">ARPHRD_ETHER</code> or <code class="literal">ARPHRD_INFINIBAND</code> +</td> +</tr> +<tr> +<td><p><span class="term"><em class="parameter"><code>buffer</code></em> :</span></p></td> +<td>buffer to store the result into</td> +</tr> +<tr> +<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> +<td> +<em class="parameter"><code>buffer</code></em>, or <a href="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a> if <em class="parameter"><code>asc</code></em> couldn't be parsed</td> +</tr> +</tbody> +</table></div> +</div> +<hr> +<div class="refsect2"> +<a name="nm-utils-hwaddr-len"></a><h3>nm_utils_hwaddr_len ()</h3> +<pre class="programlisting"><span class="returnvalue">int</span> nm_utils_hwaddr_len (<em class="parameter"><code><span class="type">int</span> type</code></em>);</pre> +<p> +Returns the length in octets of a hardware address of type <em class="parameter"><code>type</code></em>. +</p> +<div class="variablelist"><table border="0"> +<col align="left" valign="top"> +<tbody> +<tr> +<td><p><span class="term"><em class="parameter"><code>type</code></em> :</span></p></td> +<td>the type of address; either <code class="literal">ARPHRD_ETHER</code> or <code class="literal">ARPHRD_INFINIBAND</code> +</td> +</tr> +<tr> +<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> +<td>the length</td> +</tr> +</tbody> +</table></div> +</div> +<hr> +<div class="refsect2"> +<a name="nm-utils-hwaddr-ntoa"></a><h3>nm_utils_hwaddr_ntoa ()</h3> +<pre class="programlisting"><span class="returnvalue">char</span> * nm_utils_hwaddr_ntoa (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gconstpointer"><span class="type">gconstpointer</span></a> addr</code></em>, + <em class="parameter"><code><span class="type">int</span> type</code></em>);</pre> +<p> +Converts <em class="parameter"><code>addr</code></em> to textual form. +</p> +<div class="variablelist"><table border="0"> +<col align="left" valign="top"> +<tbody> +<tr> +<td><p><span class="term"><em class="parameter"><code>addr</code></em> :</span></p></td> +<td>a binary hardware address</td> +</tr> +<tr> +<td><p><span class="term"><em class="parameter"><code>type</code></em> :</span></p></td> +<td>the type of address; either <code class="literal">ARPHRD_ETHER</code> or <code class="literal">ARPHRD_INFINIBAND</code> +</td> +</tr> +<tr> +<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> +<td>the textual form of <em class="parameter"><code>addr</code></em>. <span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span> +</td> +</tr> +</tbody> +</table></div> +</div> +<hr> +<div class="refsect2"> +<a name="nm-utils-hwaddr-type"></a><h3>nm_utils_hwaddr_type ()</h3> +<pre class="programlisting"><span class="returnvalue">int</span> nm_utils_hwaddr_type (<em class="parameter"><code><span class="type">int</span> len</code></em>);</pre> +<p> +Returns the type (either <code class="literal">ARPHRD_ETHER</code> or <code class="literal">ARPHRD_INFINIBAND</code>) of the raw +address given its length. +</p> +<div class="variablelist"><table border="0"> +<col align="left" valign="top"> +<tbody> +<tr> +<td><p><span class="term"><em class="parameter"><code>len</code></em> :</span></p></td> +<td>the length of hardware address in bytes</td> +</tr> +<tr> +<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> +<td>the type, either <code class="literal">ARPHRD_ETHER</code> or <code class="literal">ARPHRD_INFINIBAND</code>, or -1 if +the address length was not recognized</td> +</tr> +</tbody> +</table></div> +</div> +<hr> +<div class="refsect2"> <a name="nm-utils-init"></a><h3>nm_utils_init ()</h3> <pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> nm_utils_init (<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> <p> @@ -673,7 +841,7 @@ NULLs, even though that is functionally pointless. <hr> <div class="refsect2"> <a name="nm-utils-security-valid"></a><h3>nm_utils_security_valid ()</h3> -<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> nm_utils_security_valid (<em class="parameter"><code><a class="link" href="libnm-util-nm-utils.html#NMUtilsSecurityType" title="enum NMUtilsSecurityType"><span class="type">NMUtilsSecurityType</span></a> type</code></em>, +<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> nm_utils_security_valid (<em class="parameter"><code><a class="link" href="libnm-util-nm-utils.html#NMUtilsSecurityType"><span class="type">NMUtilsSecurityType</span></a> type</code></em>, <em class="parameter"><code><span class="type">NMDeviceWifiCapabilities</span> wifi_caps</code></em>, <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> have_ap</code></em>, <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> adhoc</code></em>, |