diff options
author | Seonah Moon <seonah1.moon@samsung.com> | 2021-02-04 10:08:28 +0900 |
---|---|---|
committer | Seonah Moon <seonah1.moon@samsung.com> | 2021-02-04 10:08:57 +0900 |
commit | 99a33f08e5808e9b4ea40f9ba0d717196b2ef090 (patch) | |
tree | cc6d986a1f22e98bfcd987e83778d829f1dbecde /doc/reference/xml | |
parent | 40d523a658c1a2e2311f0d588a96cbfb7eded09f (diff) | |
download | libidn-99a33f08e5808e9b4ea40f9ba0d717196b2ef090.tar.gz libidn-99a33f08e5808e9b4ea40f9ba0d717196b2ef090.tar.bz2 libidn-99a33f08e5808e9b4ea40f9ba0d717196b2ef090.zip |
Imported Upstream version 1.23upstream/1.23upstream
Change-Id: Icfaf3a8b6a8c778e14a771acd595696cdbded864
Diffstat (limited to 'doc/reference/xml')
-rw-r--r-- | doc/reference/xml/api-index-deprecated.xml | 5 | ||||
-rw-r--r-- | doc/reference/xml/api-index-full.xml | 97 | ||||
-rw-r--r-- | doc/reference/xml/idn-free.xml | 51 | ||||
-rw-r--r-- | doc/reference/xml/idna.xml | 568 | ||||
-rw-r--r-- | doc/reference/xml/intprops.xml | 140 | ||||
-rw-r--r-- | doc/reference/xml/pr29.xml | 172 | ||||
-rw-r--r-- | doc/reference/xml/punycode.xml | 240 | ||||
-rw-r--r-- | doc/reference/xml/stringprep.xml | 866 | ||||
-rw-r--r-- | doc/reference/xml/tld.xml | 483 | ||||
-rw-r--r-- | doc/reference/xml/verify.xml | 66 |
10 files changed, 0 insertions, 2688 deletions
diff --git a/doc/reference/xml/api-index-deprecated.xml b/doc/reference/xml/api-index-deprecated.xml deleted file mode 100644 index 1132835..0000000 --- a/doc/reference/xml/api-index-deprecated.xml +++ /dev/null @@ -1,5 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE indexdiv PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<indexdiv> -</indexdiv> diff --git a/doc/reference/xml/api-index-full.xml b/doc/reference/xml/api-index-full.xml deleted file mode 100644 index 70cf02b..0000000 --- a/doc/reference/xml/api-index-full.xml +++ /dev/null @@ -1,97 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE indexdiv PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<indexdiv> -<indexdiv><title>I</title> -<indexentry><primaryie linkends="IDNAPI--CAPS"><link linkend="IDNAPI--CAPS">IDNAPI</link></primaryie></indexentry> -<indexentry><primaryie linkends="IDNA-ACE-PREFIX--CAPS"><link linkend="IDNA-ACE-PREFIX--CAPS">IDNA_ACE_PREFIX</link></primaryie></indexentry> -<indexentry><primaryie linkends="Idna-flags"><link linkend="Idna-flags">Idna_flags</link></primaryie></indexentry> -<indexentry><primaryie linkends="Idna-rc"><link linkend="Idna-rc">Idna_rc</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-strerror"><link linkend="idna-strerror">idna_strerror</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-ascii-4i"><link linkend="idna-to-ascii-4i">idna_to_ascii_4i</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-ascii-4z"><link linkend="idna-to-ascii-4z">idna_to_ascii_4z</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-ascii-8z"><link linkend="idna-to-ascii-8z">idna_to_ascii_8z</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-ascii-lz"><link linkend="idna-to-ascii-lz">idna_to_ascii_lz</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-unicode-44i"><link linkend="idna-to-unicode-44i">idna_to_unicode_44i</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-unicode-4z4z"><link linkend="idna-to-unicode-4z4z">idna_to_unicode_4z4z</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-unicode-8z4z"><link linkend="idna-to-unicode-8z4z">idna_to_unicode_8z4z</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-unicode-8z8z"><link linkend="idna-to-unicode-8z8z">idna_to_unicode_8z8z</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-unicode-8zlz"><link linkend="idna-to-unicode-8zlz">idna_to_unicode_8zlz</link></primaryie></indexentry> -<indexentry><primaryie linkends="idna-to-unicode-lzlz"><link linkend="idna-to-unicode-lzlz">idna_to_unicode_lzlz</link></primaryie></indexentry> -<indexentry><primaryie linkends="INT-BUFSIZE-BOUND--CAPS"><link linkend="INT-BUFSIZE-BOUND--CAPS">INT_BUFSIZE_BOUND</link></primaryie></indexentry> -<indexentry><primaryie linkends="INT-STRLEN-BOUND--CAPS"><link linkend="INT-STRLEN-BOUND--CAPS">INT_STRLEN_BOUND</link></primaryie></indexentry> -</indexdiv> -<indexdiv><title>P</title> -<indexentry><primaryie linkends="pr29-4"><link linkend="pr29-4">pr29_4</link></primaryie></indexentry> -<indexentry><primaryie linkends="pr29-4z"><link linkend="pr29-4z">pr29_4z</link></primaryie></indexentry> -<indexentry><primaryie linkends="pr29-8z"><link linkend="pr29-8z">pr29_8z</link></primaryie></indexentry> -<indexentry><primaryie linkends="Pr29-rc"><link linkend="Pr29-rc">Pr29_rc</link></primaryie></indexentry> -<indexentry><primaryie linkends="pr29-strerror"><link linkend="pr29-strerror">pr29_strerror</link></primaryie></indexentry> -<indexentry><primaryie linkends="punycode-decode"><link linkend="punycode-decode">punycode_decode</link></primaryie></indexentry> -<indexentry><primaryie linkends="punycode-encode"><link linkend="punycode-encode">punycode_encode</link></primaryie></indexentry> -<indexentry><primaryie linkends="Punycode-status"><link linkend="Punycode-status">Punycode_status</link></primaryie></indexentry> -<indexentry><primaryie linkends="punycode-strerror"><link linkend="punycode-strerror">punycode_strerror</link></primaryie></indexentry> -<indexentry><primaryie linkends="punycode-uint"><link linkend="punycode-uint">punycode_uint</link></primaryie></indexentry> -</indexdiv> -<indexdiv><title>S</title> -<indexentry><primaryie linkends="signed-type-or-expr--"><link linkend="signed-type-or-expr--">signed_type_or_expr__</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep"><link linkend="stringprep">stringprep</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-4i"><link linkend="stringprep-4i">stringprep_4i</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-4zi"><link linkend="stringprep-4zi">stringprep_4zi</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-check-version"><link linkend="stringprep-check-version">stringprep_check_version</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-convert"><link linkend="stringprep-convert">stringprep_convert</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-iscsi"><link linkend="stringprep-iscsi">stringprep_iscsi</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-kerberos5"><link linkend="stringprep-kerberos5">stringprep_kerberos5</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-locale-charset"><link linkend="stringprep-locale-charset">stringprep_locale_charset</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-locale-to-utf8"><link linkend="stringprep-locale-to-utf8">stringprep_locale_to_utf8</link></primaryie></indexentry> -<indexentry><primaryie linkends="STRINGPREP-MAX-MAP-CHARS--CAPS"><link linkend="STRINGPREP-MAX-MAP-CHARS--CAPS">STRINGPREP_MAX_MAP_CHARS</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-nameprep"><link linkend="stringprep-nameprep">stringprep_nameprep</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-nameprep-no-unassigned"><link linkend="stringprep-nameprep-no-unassigned">stringprep_nameprep_no_unassigned</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-plain"><link linkend="stringprep-plain">stringprep_plain</link></primaryie></indexentry> -<indexentry><primaryie linkends="Stringprep-profile"><link linkend="Stringprep-profile">Stringprep_profile</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-profile"><link linkend="stringprep-profile">stringprep_profile</link></primaryie></indexentry> -<indexentry><primaryie linkends="Stringprep-profiles"><link linkend="Stringprep-profiles">Stringprep_profiles</link></primaryie></indexentry> -<indexentry><primaryie linkends="Stringprep-profile-flags"><link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link></primaryie></indexentry> -<indexentry><primaryie linkends="Stringprep-profile-steps"><link linkend="Stringprep-profile-steps">Stringprep_profile_steps</link></primaryie></indexentry> -<indexentry><primaryie linkends="Stringprep-rc"><link linkend="Stringprep-rc">Stringprep_rc</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-strerror"><link linkend="stringprep-strerror">stringprep_strerror</link></primaryie></indexentry> -<indexentry><primaryie linkends="Stringprep-table-element"><link linkend="Stringprep-table-element">Stringprep_table_element</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-ucs4-nfkc-normalize"><link linkend="stringprep-ucs4-nfkc-normalize">stringprep_ucs4_nfkc_normalize</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-ucs4-to-utf8"><link linkend="stringprep-ucs4-to-utf8">stringprep_ucs4_to_utf8</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-unichar-to-utf8"><link linkend="stringprep-unichar-to-utf8">stringprep_unichar_to_utf8</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-utf8-nfkc-normalize"><link linkend="stringprep-utf8-nfkc-normalize">stringprep_utf8_nfkc_normalize</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-utf8-to-locale"><link linkend="stringprep-utf8-to-locale">stringprep_utf8_to_locale</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-utf8-to-ucs4"><link linkend="stringprep-utf8-to-ucs4">stringprep_utf8_to_ucs4</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-utf8-to-unichar"><link linkend="stringprep-utf8-to-unichar">stringprep_utf8_to_unichar</link></primaryie></indexentry> -<indexentry><primaryie linkends="STRINGPREP-VERSION--CAPS"><link linkend="STRINGPREP-VERSION--CAPS">STRINGPREP_VERSION</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-xmpp-nodeprep"><link linkend="stringprep-xmpp-nodeprep">stringprep_xmpp_nodeprep</link></primaryie></indexentry> -<indexentry><primaryie linkends="stringprep-xmpp-resourceprep"><link linkend="stringprep-xmpp-resourceprep">stringprep_xmpp_resourceprep</link></primaryie></indexentry> -</indexdiv> -<indexdiv><title>T</title> -<indexentry><primaryie linkends="tld-check-4"><link linkend="tld-check-4">tld_check_4</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-check-4t"><link linkend="tld-check-4t">tld_check_4t</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-check-4tz"><link linkend="tld-check-4tz">tld_check_4tz</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-check-4z"><link linkend="tld-check-4z">tld_check_4z</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-check-8z"><link linkend="tld-check-8z">tld_check_8z</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-check-lz"><link linkend="tld-check-lz">tld_check_lz</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-default-table"><link linkend="tld-default-table">tld_default_table</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-get-4"><link linkend="tld-get-4">tld_get_4</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-get-4z"><link linkend="tld-get-4z">tld_get_4z</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-get-table"><link linkend="tld-get-table">tld_get_table</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-get-z"><link linkend="tld-get-z">tld_get_z</link></primaryie></indexentry> -<indexentry><primaryie linkends="Tld-rc"><link linkend="Tld-rc">Tld_rc</link></primaryie></indexentry> -<indexentry><primaryie linkends="tld-strerror"><link linkend="tld-strerror">tld_strerror</link></primaryie></indexentry> -<indexentry><primaryie linkends="Tld-table"><link linkend="Tld-table">Tld_table</link></primaryie></indexentry> -<indexentry><primaryie linkends="Tld-table-element"><link linkend="Tld-table-element">Tld_table_element</link></primaryie></indexentry> -<indexentry><primaryie linkends="TYPE-MAXIMUM--CAPS"><link linkend="TYPE-MAXIMUM--CAPS">TYPE_MAXIMUM</link></primaryie></indexentry> -<indexentry><primaryie linkends="TYPE-MINIMUM--CAPS"><link linkend="TYPE-MINIMUM--CAPS">TYPE_MINIMUM</link></primaryie></indexentry> -<indexentry><primaryie linkends="TYPE-ONES-COMPLEMENT--CAPS"><link linkend="TYPE-ONES-COMPLEMENT--CAPS">TYPE_ONES_COMPLEMENT</link></primaryie></indexentry> -<indexentry><primaryie linkends="TYPE-SIGNED--CAPS"><link linkend="TYPE-SIGNED--CAPS">TYPE_SIGNED</link></primaryie></indexentry> -<indexentry><primaryie linkends="TYPE-SIGNED-MAGNITUDE--CAPS"><link linkend="TYPE-SIGNED-MAGNITUDE--CAPS">TYPE_SIGNED_MAGNITUDE</link></primaryie></indexentry> -<indexentry><primaryie linkends="TYPE-TWOS-COMPLEMENT--CAPS"><link linkend="TYPE-TWOS-COMPLEMENT--CAPS">TYPE_TWOS_COMPLEMENT</link></primaryie></indexentry> -</indexdiv> -<indexdiv><title>V</title> -<indexentry><primaryie linkends="verify"><link linkend="verify">verify</link></primaryie></indexentry> -<indexentry><primaryie linkends="verify-true"><link linkend="verify-true">verify_true</link></primaryie></indexentry> -</indexdiv> -</indexdiv> diff --git a/doc/reference/xml/idn-free.xml b/doc/reference/xml/idn-free.xml deleted file mode 100644 index 787c26f..0000000 --- a/doc/reference/xml/idn-free.xml +++ /dev/null @@ -1,51 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<refentry id="libidn-idn-free"> -<refmeta> -<refentrytitle role="top_of_page" id="libidn-idn-free.top_of_page">idn-free</refentrytitle> -<manvolnum>3</manvolnum> -<refmiscinfo>LIBIDN Library</refmiscinfo> -</refmeta> - -<refnamediv> -<refname>idn-free</refname> -<refpurpose></refpurpose> -</refnamediv> - -<refsynopsisdiv id="libidn-idn-free.synopsis" role="synopsis"> -<title role="synopsis.title">Synopsis</title> - -<synopsis> -#define <link linkend="IDNAPI--CAPS">IDNAPI</link> -</synopsis> -</refsynopsisdiv> - - - - - - - - - -<refsect1 id="libidn-idn-free.description" role="desc"> -<title role="desc.title">Description</title> -<para> -</para> -</refsect1> - -<refsect1 id="libidn-idn-free.details" role="details"> -<title role="details.title">Details</title> -<refsect2 id="IDNAPI--CAPS" role="macro"> -<title>IDNAPI</title> -<indexterm zone="IDNAPI--CAPS"><primary sortas="IDNAPI">IDNAPI</primary></indexterm><programlisting>#define IDNAPI</programlisting> -<para> -</para></refsect2> - -</refsect1> - - - - -</refentry> diff --git a/doc/reference/xml/idna.xml b/doc/reference/xml/idna.xml deleted file mode 100644 index 309aa91..0000000 --- a/doc/reference/xml/idna.xml +++ /dev/null @@ -1,568 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<refentry id="libidn-idna"> -<refmeta> -<refentrytitle role="top_of_page" id="libidn-idna.top_of_page">idna</refentrytitle> -<manvolnum>3</manvolnum> -<refmiscinfo>LIBIDN Library</refmiscinfo> -</refmeta> - -<refnamediv> -<refname>idna</refname> -<refpurpose></refpurpose> -</refnamediv> - -<refsynopsisdiv id="libidn-idna.synopsis" role="synopsis"> -<title role="synopsis.title">Synopsis</title> - -<synopsis> -#define <link linkend="IDNAPI--CAPS">IDNAPI</link> -enum <link linkend="Idna-rc">Idna_rc</link>; -enum <link linkend="Idna-flags">Idna_flags</link>; -#define <link linkend="IDNA-ACE-PREFIX--CAPS">IDNA_ACE_PREFIX</link> -const <link linkend="char">char</link> * <link linkend="idna-strerror">idna_strerror</link> (<link linkend="Idna-rc">Idna_rc</link> rc); -<link linkend="int">int</link> <link linkend="idna-to-ascii-4i">idna_to_ascii_4i</link> (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="char">char</link> *out, - <link linkend="int">int</link> flags); -<link linkend="int">int</link> <link linkend="idna-to-unicode-44i">idna_to_unicode_44i</link> (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="uint32-t">uint32_t</link> *out, - <link linkend="size-t">size_t</link> *outlen, - <link linkend="int">int</link> flags); -<link linkend="int">int</link> <link linkend="idna-to-ascii-4z">idna_to_ascii_4z</link> (const <link linkend="uint32-t">uint32_t</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags); -<link linkend="int">int</link> <link linkend="idna-to-ascii-8z">idna_to_ascii_8z</link> (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags); -<link linkend="int">int</link> <link linkend="idna-to-ascii-lz">idna_to_ascii_lz</link> (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags); -<link linkend="int">int</link> <link linkend="idna-to-unicode-4z4z">idna_to_unicode_4z4z</link> (const <link linkend="uint32-t">uint32_t</link> *input, - <link linkend="uint32-t">uint32_t</link> **output, - <link linkend="int">int</link> flags); -<link linkend="int">int</link> <link linkend="idna-to-unicode-8z4z">idna_to_unicode_8z4z</link> (const <link linkend="char">char</link> *input, - <link linkend="uint32-t">uint32_t</link> **output, - <link linkend="int">int</link> flags); -<link linkend="int">int</link> <link linkend="idna-to-unicode-8z8z">idna_to_unicode_8z8z</link> (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags); -<link linkend="int">int</link> <link linkend="idna-to-unicode-8zlz">idna_to_unicode_8zlz</link> (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags); -<link linkend="int">int</link> <link linkend="idna-to-unicode-lzlz">idna_to_unicode_lzlz</link> (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags); -</synopsis> -</refsynopsisdiv> - - - - - - - - - -<refsect1 id="libidn-idna.description" role="desc"> -<title role="desc.title">Description</title> -<para> -</para> -</refsect1> - -<refsect1 id="libidn-idna.details" role="details"> -<title role="details.title">Details</title> -<refsect2 id="IDNAPI--CAPS" role="macro"> -<title>IDNAPI</title> -<indexterm zone="IDNAPI--CAPS"><primary sortas="IDNAPI">IDNAPI</primary></indexterm><programlisting>#define IDNAPI</programlisting> -<para> -</para></refsect2> -<refsect2 id="Idna-rc" role="enum"> -<title>enum Idna_rc</title> -<indexterm zone="Idna-rc"><primary sortas="Idna_rc">Idna_rc</primary></indexterm><programlisting> typedef enum - { - IDNA_SUCCESS = 0, - IDNA_STRINGPREP_ERROR = 1, - IDNA_PUNYCODE_ERROR = 2, - IDNA_CONTAINS_NON_LDH = 3, - /* Workaround typo in earlier versions. */ - IDNA_CONTAINS_LDH = IDNA_CONTAINS_NON_LDH, - IDNA_CONTAINS_MINUS = 4, - IDNA_INVALID_LENGTH = 5, - IDNA_NO_ACE_PREFIX = 6, - IDNA_ROUNDTRIP_VERIFY_ERROR = 7, - IDNA_CONTAINS_ACE_PREFIX = 8, - IDNA_ICONV_ERROR = 9, - /* Internal errors. */ - IDNA_MALLOC_ERROR = 201, - IDNA_DLOPEN_ERROR = 202 - } Idna_rc; -</programlisting> -<para> -Enumerated return codes of <link linkend="idna-to-ascii-4i"><function>idna_to_ascii_4i()</function></link>, -<link linkend="idna-to-unicode-44i"><function>idna_to_unicode_44i()</function></link> functions (and functions derived from those -functions). The value 0 is guaranteed to always correspond to -success.</para> -<para> -</para><variablelist role="enum"> -<varlistentry id="IDNA-SUCCESS--CAPS" role="constant"> -<term><literal>IDNA_SUCCESS</literal></term> -<listitem><simpara> Successful operation. This value is guaranteed to - always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-STRINGPREP-ERROR--CAPS" role="constant"> -<term><literal>IDNA_STRINGPREP_ERROR</literal></term> -<listitem><simpara> Error during string preparation. -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-PUNYCODE-ERROR--CAPS" role="constant"> -<term><literal>IDNA_PUNYCODE_ERROR</literal></term> -<listitem><simpara> Error during punycode operation. -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-CONTAINS-NON-LDH--CAPS" role="constant"> -<term><literal>IDNA_CONTAINS_NON_LDH</literal></term> -<listitem><simpara> For IDNA_USE_STD3_ASCII_RULES, indicate that - the string contains non-LDH ASCII characters. -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-CONTAINS-LDH--CAPS" role="constant"> -<term><literal>IDNA_CONTAINS_LDH</literal></term> -<listitem><simpara> -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-CONTAINS-MINUS--CAPS" role="constant"> -<term><literal>IDNA_CONTAINS_MINUS</literal></term> -<listitem><simpara> For IDNA_USE_STD3_ASCII_RULES, indicate that - the string contains a leading or trailing hyphen-minus (U+002D). -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-INVALID-LENGTH--CAPS" role="constant"> -<term><literal>IDNA_INVALID_LENGTH</literal></term> -<listitem><simpara> The final output string is not within the - (inclusive) range 1 to 63 characters. -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-NO-ACE-PREFIX--CAPS" role="constant"> -<term><literal>IDNA_NO_ACE_PREFIX</literal></term> -<listitem><simpara> The string does not contain the ACE prefix - (for ToUnicode). -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-ROUNDTRIP-VERIFY-ERROR--CAPS" role="constant"> -<term><literal>IDNA_ROUNDTRIP_VERIFY_ERROR</literal></term> -<listitem><simpara> The ToASCII operation on output - string does not equal the input. -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-CONTAINS-ACE-PREFIX--CAPS" role="constant"> -<term><literal>IDNA_CONTAINS_ACE_PREFIX</literal></term> -<listitem><simpara> The input contains the ACE prefix (for - ToASCII). -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-ICONV-ERROR--CAPS" role="constant"> -<term><literal>IDNA_ICONV_ERROR</literal></term> -<listitem><simpara> Could not convert string in locale encoding. -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-MALLOC-ERROR--CAPS" role="constant"> -<term><literal>IDNA_MALLOC_ERROR</literal></term> -<listitem><simpara> Could not allocate buffer (this is typically a - fatal error). -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-DLOPEN-ERROR--CAPS" role="constant"> -<term><literal>IDNA_DLOPEN_ERROR</literal></term> -<listitem><simpara> Could not dlopen the libcidn DSO (only used - internally in libc). -</simpara></listitem> -</varlistentry> -</variablelist></refsect2> -<refsect2 id="Idna-flags" role="enum"> -<title>enum Idna_flags</title> -<indexterm zone="Idna-flags"><primary sortas="Idna_flags">Idna_flags</primary></indexterm><programlisting> typedef enum - { - IDNA_ALLOW_UNASSIGNED = 0x0001, - IDNA_USE_STD3_ASCII_RULES = 0x0002 - } Idna_flags; -</programlisting> -<para> -Flags to pass to <link linkend="idna-to-ascii-4i"><function>idna_to_ascii_4i()</function></link>, <link linkend="idna-to-unicode-44i"><function>idna_to_unicode_44i()</function></link> etc.</para> -<para> -</para><variablelist role="enum"> -<varlistentry id="IDNA-ALLOW-UNASSIGNED--CAPS" role="constant"> -<term><literal>IDNA_ALLOW_UNASSIGNED</literal></term> -<listitem><simpara> Don't reject strings containing unassigned - Unicode code points. -</simpara></listitem> -</varlistentry> -<varlistentry id="IDNA-USE-STD3-ASCII-RULES--CAPS" role="constant"> -<term><literal>IDNA_USE_STD3_ASCII_RULES</literal></term> -<listitem><simpara> Validate strings according to STD3 - rules (i.e., normal host name rules). -</simpara></listitem> -</varlistentry> -</variablelist></refsect2> -<refsect2 id="IDNA-ACE-PREFIX--CAPS" role="macro"> -<title>IDNA_ACE_PREFIX</title> -<indexterm zone="IDNA-ACE-PREFIX--CAPS"><primary sortas="IDNA_ACE_PREFIX">IDNA_ACE_PREFIX</primary></indexterm><programlisting># define IDNA_ACE_PREFIX "xn--" -</programlisting> -<para> -The IANA allocated prefix to use for IDNA. "xn--"</para> -<para> -</para></refsect2> -<refsect2 id="idna-strerror" role="function"> -<title>idna_strerror ()</title> -<indexterm zone="idna-strerror"><primary sortas="idna_strerror">idna_strerror</primary></indexterm><programlisting>const <link linkend="char">char</link> * idna_strerror (<link linkend="Idna-rc">Idna_rc</link> rc);</programlisting> -<para> -Convert a return code integer to a text string. This string can be -used to output a diagnostic message to the user. -</para> -<para> -IDNA_SUCCESS: Successful operation. This value is guaranteed to - always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -IDNA_STRINGPREP_ERROR: Error during string preparation. -IDNA_PUNYCODE_ERROR: Error during punycode operation. -IDNA_CONTAINS_NON_LDH: For IDNA_USE_STD3_ASCII_RULES, indicate that - the string contains non-LDH ASCII characters. -IDNA_CONTAINS_MINUS: For IDNA_USE_STD3_ASCII_RULES, indicate that - the string contains a leading or trailing hyphen-minus (U+002D). -IDNA_INVALID_LENGTH: The final output string is not within the - (inclusive) range 1 to 63 characters. -IDNA_NO_ACE_PREFIX: The string does not contain the ACE prefix - (for ToUnicode). -IDNA_ROUNDTRIP_VERIFY_ERROR: The ToASCII operation on output - string does not equal the input. -IDNA_CONTAINS_ACE_PREFIX: The input contains the ACE prefix (for - ToASCII). -IDNA_ICONV_ERROR: Could not convert string in locale encoding. -IDNA_MALLOC_ERROR: Could not allocate buffer (this is typically a - fatal error). -IDNA_DLOPEN_ERROR: Could not dlopen the libcidn DSO (only used - internally in libc).</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>rc</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-rc"><type>Idna_rc</type></link> return code. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns a pointer to a statically allocated string -containing a description of the error with the return code <parameter>rc</parameter>. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-ascii-4i" role="function"> -<title>idna_to_ascii_4i ()</title> -<indexterm zone="idna-to-ascii-4i"><primary sortas="idna_to_ascii_4i">idna_to_ascii_4i</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_ascii_4i (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="char">char</link> *out, - <link linkend="int">int</link> flags);</programlisting> -<para> -The ToASCII operation takes a sequence of Unicode code points that -make up one domain label and transforms it into a sequence of code -points in the ASCII range (0..7F). If ToASCII succeeds, the -original sequence and the resulting sequence are equivalent labels. -</para> -<para> -It is important to note that the ToASCII operation can fail. ToASCII -fails if any step of it fails. If any step of the ToASCII operation -fails on any label in a domain name, that domain name MUST NOT be used -as an internationalized domain name. The method for deadling with this -failure is application-specific. -</para> -<para> -The inputs to ToASCII are a sequence of code points, the AllowUnassigned -flag, and the UseSTD3ASCIIRules flag. The output of ToASCII is either a -sequence of ASCII code points or a failure condition. -</para> -<para> -ToASCII never alters a sequence of code points that are all in the ASCII -range to begin with (although it could fail). Applying the ToASCII -operation multiple times has exactly the same effect as applying it just -once.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input array with unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>inlen</parameter> :</term> -<listitem><simpara> length of input array with unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>out</parameter> :</term> -<listitem><simpara> output zero terminated string that must have room for at - least 63 characters plus the terminating zero. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns 0 on success, or an <link linkend="Idna-rc"><type>Idna_rc</type></link> error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-unicode-44i" role="function"> -<title>idna_to_unicode_44i ()</title> -<indexterm zone="idna-to-unicode-44i"><primary sortas="idna_to_unicode_44i">idna_to_unicode_44i</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_unicode_44i (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="uint32-t">uint32_t</link> *out, - <link linkend="size-t">size_t</link> *outlen, - <link linkend="int">int</link> flags);</programlisting> -<para> -The ToUnicode operation takes a sequence of Unicode code points -that make up one domain label and returns a sequence of Unicode -code points. If the input sequence is a label in ACE form, then the -result is an equivalent internationalized label that is not in ACE -form, otherwise the original sequence is returned unaltered. -</para> -<para> -ToUnicode never fails. If any step fails, then the original input -sequence is returned immediately in that step. -</para> -<para> -The Punycode decoder can never output more code points than it -inputs, but Nameprep can, and therefore ToUnicode can. Note that -the number of octets needed to represent a sequence of code points -depends on the particular character encoding used. -</para> -<para> -The inputs to ToUnicode are a sequence of code points, the -AllowUnassigned flag, and the UseSTD3ASCIIRules flag. The output of -ToUnicode is always a sequence of Unicode code points.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input array with unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>inlen</parameter> :</term> -<listitem><simpara> length of input array with unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>out</parameter> :</term> -<listitem><simpara> output array with unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>outlen</parameter> :</term> -<listitem><simpara> on input, maximum size of output array with unicode code points, - on exit, actual size of output array with unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="Idna-rc"><type>Idna_rc</type></link> error condition, but it must only be - used for debugging purposes. The output buffer is always - guaranteed to contain the correct data according to the - specification (sans malloc induced errors). NB! This means that - you normally ignore the return code from this function, as - checking it means breaking the standard. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-ascii-4z" role="function"> -<title>idna_to_ascii_4z ()</title> -<indexterm zone="idna-to-ascii-4z"><primary sortas="idna_to_ascii_4z">idna_to_ascii_4z</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_ascii_4z (const <link linkend="uint32-t">uint32_t</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags);</programlisting> -<para> -Convert UCS-4 domain name to ASCII string. The domain name may -contain several labels, separated by dots. The output buffer must -be deallocated by the caller.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> zero terminated input Unicode string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> pointer to newly allocated output string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="IDNA-SUCCESS--CAPS"><literal>IDNA_SUCCESS</literal></link> on success, or error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-ascii-8z" role="function"> -<title>idna_to_ascii_8z ()</title> -<indexterm zone="idna-to-ascii-8z"><primary sortas="idna_to_ascii_8z">idna_to_ascii_8z</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_ascii_8z (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags);</programlisting> -<para> -Convert UTF-8 domain name to ASCII string. The domain name may -contain several labels, separated by dots. The output buffer must -be deallocated by the caller.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> zero terminated input UTF-8 string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> pointer to newly allocated output string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="IDNA-SUCCESS--CAPS"><literal>IDNA_SUCCESS</literal></link> on success, or error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-ascii-lz" role="function"> -<title>idna_to_ascii_lz ()</title> -<indexterm zone="idna-to-ascii-lz"><primary sortas="idna_to_ascii_lz">idna_to_ascii_lz</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_ascii_lz (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags);</programlisting> -<para> -Convert domain name in the locale's encoding to ASCII string. The -domain name may contain several labels, separated by dots. The -output buffer must be deallocated by the caller.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> zero terminated input string encoded in the current locale's - character set. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> pointer to newly allocated output string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="IDNA-SUCCESS--CAPS"><literal>IDNA_SUCCESS</literal></link> on success, or error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-unicode-4z4z" role="function"> -<title>idna_to_unicode_4z4z ()</title> -<indexterm zone="idna-to-unicode-4z4z"><primary sortas="idna_to_unicode_4z4z">idna_to_unicode_4z4z</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_unicode_4z4z (const <link linkend="uint32-t">uint32_t</link> *input, - <link linkend="uint32-t">uint32_t</link> **output, - <link linkend="int">int</link> flags);</programlisting> -<para> -Convert possibly ACE encoded domain name in UCS-4 format into a -UCS-4 string. The domain name may contain several labels, -separated by dots. The output buffer must be deallocated by the -caller.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> zero-terminated Unicode string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> pointer to newly allocated output Unicode string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="IDNA-SUCCESS--CAPS"><literal>IDNA_SUCCESS</literal></link> on success, or error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-unicode-8z4z" role="function"> -<title>idna_to_unicode_8z4z ()</title> -<indexterm zone="idna-to-unicode-8z4z"><primary sortas="idna_to_unicode_8z4z">idna_to_unicode_8z4z</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_unicode_8z4z (const <link linkend="char">char</link> *input, - <link linkend="uint32-t">uint32_t</link> **output, - <link linkend="int">int</link> flags);</programlisting> -<para> -Convert possibly ACE encoded domain name in UTF-8 format into a -UCS-4 string. The domain name may contain several labels, -separated by dots. The output buffer must be deallocated by the -caller.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> zero-terminated UTF-8 string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> pointer to newly allocated output Unicode string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="IDNA-SUCCESS--CAPS"><literal>IDNA_SUCCESS</literal></link> on success, or error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-unicode-8z8z" role="function"> -<title>idna_to_unicode_8z8z ()</title> -<indexterm zone="idna-to-unicode-8z8z"><primary sortas="idna_to_unicode_8z8z">idna_to_unicode_8z8z</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_unicode_8z8z (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags);</programlisting> -<para> -Convert possibly ACE encoded domain name in UTF-8 format into a -UTF-8 string. The domain name may contain several labels, -separated by dots. The output buffer must be deallocated by the -caller.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> zero-terminated UTF-8 string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> pointer to newly allocated output UTF-8 string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="IDNA-SUCCESS--CAPS"><literal>IDNA_SUCCESS</literal></link> on success, or error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-unicode-8zlz" role="function"> -<title>idna_to_unicode_8zlz ()</title> -<indexterm zone="idna-to-unicode-8zlz"><primary sortas="idna_to_unicode_8zlz">idna_to_unicode_8zlz</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_unicode_8zlz (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags);</programlisting> -<para> -Convert possibly ACE encoded domain name in UTF-8 format into a -string encoded in the current locale's character set. The domain -name may contain several labels, separated by dots. The output -buffer must be deallocated by the caller.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> zero-terminated UTF-8 string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> pointer to newly allocated output string encoded in the - current locale's character set. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="IDNA-SUCCESS--CAPS"><literal>IDNA_SUCCESS</literal></link> on success, or error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="idna-to-unicode-lzlz" role="function"> -<title>idna_to_unicode_lzlz ()</title> -<indexterm zone="idna-to-unicode-lzlz"><primary sortas="idna_to_unicode_lzlz">idna_to_unicode_lzlz</primary></indexterm><programlisting><link linkend="int">int</link> idna_to_unicode_lzlz (const <link linkend="char">char</link> *input, - <link linkend="char">char</link> **output, - <link linkend="int">int</link> flags);</programlisting> -<para> -Convert possibly ACE encoded domain name in the locale's character -set into a string encoded in the current locale's character set. -The domain name may contain several labels, separated by dots. The -output buffer must be deallocated by the caller.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> zero-terminated string encoded in the current locale's - character set. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> pointer to newly allocated output string encoded in the - current locale's character set. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> an <link linkend="Idna-flags"><type>Idna_flags</type></link> value, e.g., <link linkend="IDNA-ALLOW-UNASSIGNED--CAPS"><literal>IDNA_ALLOW_UNASSIGNED</literal></link> or - <link linkend="IDNA-USE-STD3-ASCII-RULES--CAPS"><literal>IDNA_USE_STD3_ASCII_RULES</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="IDNA-SUCCESS--CAPS"><literal>IDNA_SUCCESS</literal></link> on success, or error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> - -</refsect1> - - - - -</refentry> diff --git a/doc/reference/xml/intprops.xml b/doc/reference/xml/intprops.xml deleted file mode 100644 index 0d70f2a..0000000 --- a/doc/reference/xml/intprops.xml +++ /dev/null @@ -1,140 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<refentry id="libidn-intprops"> -<refmeta> -<refentrytitle role="top_of_page" id="libidn-intprops.top_of_page">intprops</refentrytitle> -<manvolnum>3</manvolnum> -<refmiscinfo>LIBIDN Library</refmiscinfo> -</refmeta> - -<refnamediv> -<refname>intprops</refname> -<refpurpose></refpurpose> -</refnamediv> - -<refsynopsisdiv id="libidn-intprops.synopsis" role="synopsis"> -<title role="synopsis.title">Synopsis</title> - -<synopsis> -#define <link linkend="TYPE-TWOS-COMPLEMENT--CAPS">TYPE_TWOS_COMPLEMENT</link> (t) -#define <link linkend="TYPE-ONES-COMPLEMENT--CAPS">TYPE_ONES_COMPLEMENT</link> (t) -#define <link linkend="TYPE-SIGNED-MAGNITUDE--CAPS">TYPE_SIGNED_MAGNITUDE</link> (t) -#define <link linkend="TYPE-SIGNED--CAPS">TYPE_SIGNED</link> (t) -#define <link linkend="TYPE-MINIMUM--CAPS">TYPE_MINIMUM</link> (t) -#define <link linkend="TYPE-MAXIMUM--CAPS">TYPE_MAXIMUM</link> (t) -#define <link linkend="signed-type-or-expr--">signed_type_or_expr__</link> (t) -#define <link linkend="INT-STRLEN-BOUND--CAPS">INT_STRLEN_BOUND</link> (t) -#define <link linkend="INT-BUFSIZE-BOUND--CAPS">INT_BUFSIZE_BOUND</link> (t) -</synopsis> -</refsynopsisdiv> - - - - - - - - - -<refsect1 id="libidn-intprops.description" role="desc"> -<title role="desc.title">Description</title> -<para> -</para> -</refsect1> - -<refsect1 id="libidn-intprops.details" role="details"> -<title role="details.title">Details</title> -<refsect2 id="TYPE-TWOS-COMPLEMENT--CAPS" role="macro"> -<title>TYPE_TWOS_COMPLEMENT()</title> -<indexterm zone="TYPE-TWOS-COMPLEMENT--CAPS"><primary sortas="TYPE_TWOS_COMPLEMENT">TYPE_TWOS_COMPLEMENT</primary></indexterm><programlisting>#define TYPE_TWOS_COMPLEMENT(t) ((t) ~ (t) 0 == (t) -1) -</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>t</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="TYPE-ONES-COMPLEMENT--CAPS" role="macro"> -<title>TYPE_ONES_COMPLEMENT()</title> -<indexterm zone="TYPE-ONES-COMPLEMENT--CAPS"><primary sortas="TYPE_ONES_COMPLEMENT">TYPE_ONES_COMPLEMENT</primary></indexterm><programlisting>#define TYPE_ONES_COMPLEMENT(t) ((t) ~ (t) 0 == 0) -</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>t</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="TYPE-SIGNED-MAGNITUDE--CAPS" role="macro"> -<title>TYPE_SIGNED_MAGNITUDE()</title> -<indexterm zone="TYPE-SIGNED-MAGNITUDE--CAPS"><primary sortas="TYPE_SIGNED_MAGNITUDE">TYPE_SIGNED_MAGNITUDE</primary></indexterm><programlisting>#define TYPE_SIGNED_MAGNITUDE(t) ((t) ~ (t) 0 < (t) -1) -</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>t</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="TYPE-SIGNED--CAPS" role="macro"> -<title>TYPE_SIGNED()</title> -<indexterm zone="TYPE-SIGNED--CAPS"><primary sortas="TYPE_SIGNED">TYPE_SIGNED</primary></indexterm><programlisting>#define TYPE_SIGNED(t) (! ((t) 0 < (t) -1)) -</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>t</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="TYPE-MINIMUM--CAPS" role="macro"> -<title>TYPE_MINIMUM()</title> -<indexterm zone="TYPE-MINIMUM--CAPS"><primary sortas="TYPE_MINIMUM">TYPE_MINIMUM</primary></indexterm><programlisting>#define TYPE_MINIMUM(t)</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>t</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="TYPE-MAXIMUM--CAPS" role="macro"> -<title>TYPE_MAXIMUM()</title> -<indexterm zone="TYPE-MAXIMUM--CAPS"><primary sortas="TYPE_MAXIMUM">TYPE_MAXIMUM</primary></indexterm><programlisting>#define TYPE_MAXIMUM(t)</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>t</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="signed-type-or-expr--" role="macro"> -<title>signed_type_or_expr__()</title> -<indexterm zone="signed-type-or-expr--"><primary sortas="signed_type_or_expr__">signed_type_or_expr__</primary></indexterm><programlisting>#define signed_type_or_expr__(t)</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>t</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="INT-STRLEN-BOUND--CAPS" role="macro"> -<title>INT_STRLEN_BOUND()</title> -<indexterm zone="INT-STRLEN-BOUND--CAPS"><primary sortas="INT_STRLEN_BOUND">INT_STRLEN_BOUND</primary></indexterm><programlisting>#define INT_STRLEN_BOUND(t)</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>t</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="INT-BUFSIZE-BOUND--CAPS" role="macro"> -<title>INT_BUFSIZE_BOUND()</title> -<indexterm zone="INT-BUFSIZE-BOUND--CAPS"><primary sortas="INT_BUFSIZE_BOUND">INT_BUFSIZE_BOUND</primary></indexterm><programlisting>#define INT_BUFSIZE_BOUND(t) (INT_STRLEN_BOUND (t) + 1) -</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>t</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> - -</refsect1> - - - - -</refentry> diff --git a/doc/reference/xml/pr29.xml b/doc/reference/xml/pr29.xml deleted file mode 100644 index dc1d62b..0000000 --- a/doc/reference/xml/pr29.xml +++ /dev/null @@ -1,172 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<refentry id="libidn-pr29"> -<refmeta> -<refentrytitle role="top_of_page" id="libidn-pr29.top_of_page">pr29</refentrytitle> -<manvolnum>3</manvolnum> -<refmiscinfo>LIBIDN Library</refmiscinfo> -</refmeta> - -<refnamediv> -<refname>pr29</refname> -<refpurpose></refpurpose> -</refnamediv> - -<refsynopsisdiv id="libidn-pr29.synopsis" role="synopsis"> -<title role="synopsis.title">Synopsis</title> - -<synopsis> -#define <link linkend="IDNAPI--CAPS">IDNAPI</link> -enum <link linkend="Pr29-rc">Pr29_rc</link>; -const <link linkend="char">char</link> * <link linkend="pr29-strerror">pr29_strerror</link> (<link linkend="Pr29-rc">Pr29_rc</link> rc); -<link linkend="int">int</link> <link linkend="pr29-4">pr29_4</link> (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> len); -<link linkend="int">int</link> <link linkend="pr29-4z">pr29_4z</link> (const <link linkend="uint32-t">uint32_t</link> *in); -<link linkend="int">int</link> <link linkend="pr29-8z">pr29_8z</link> (const <link linkend="char">char</link> *in); -</synopsis> -</refsynopsisdiv> - - - - - - - - - -<refsect1 id="libidn-pr29.description" role="desc"> -<title role="desc.title">Description</title> -<para> -</para> -</refsect1> - -<refsect1 id="libidn-pr29.details" role="details"> -<title role="details.title">Details</title> -<refsect2 id="IDNAPI--CAPS" role="macro"> -<title>IDNAPI</title> -<indexterm zone="IDNAPI--CAPS"><primary sortas="IDNAPI">IDNAPI</primary></indexterm><programlisting>#define IDNAPI</programlisting> -<para> -</para></refsect2> -<refsect2 id="Pr29-rc" role="enum"> -<title>enum Pr29_rc</title> -<indexterm zone="Pr29-rc"><primary sortas="Pr29_rc">Pr29_rc</primary></indexterm><programlisting> typedef enum - { - PR29_SUCCESS = 0, - PR29_PROBLEM = 1, /* String is a problem sequence. */ - PR29_STRINGPREP_ERROR = 2 /* Charset conversion failed (p29_8*). */ - } Pr29_rc; -</programlisting> -<para> -Enumerated return codes for <link linkend="pr29-4"><function>pr29_4()</function></link>, <link linkend="pr29-4z"><function>pr29_4z()</function></link>, <link linkend="pr29-8z"><function>pr29_8z()</function></link>. The -value 0 is guaranteed to always correspond to success.</para> -<para> -</para><variablelist role="enum"> -<varlistentry id="PR29-SUCCESS--CAPS" role="constant"> -<term><literal>PR29_SUCCESS</literal></term> -<listitem><simpara> Successful operation. This value is guaranteed to - always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -</simpara></listitem> -</varlistentry> -<varlistentry id="PR29-PROBLEM--CAPS" role="constant"> -<term><literal>PR29_PROBLEM</literal></term> -<listitem><simpara> A problem sequence was encountered. -</simpara></listitem> -</varlistentry> -<varlistentry id="PR29-STRINGPREP-ERROR--CAPS" role="constant"> -<term><literal>PR29_STRINGPREP_ERROR</literal></term> -<listitem><simpara> The character set conversion failed (only - for <link linkend="pr29-8"><function>pr29_8()</function></link> and <link linkend="pr29-8z"><function>pr29_8z()</function></link>). -</simpara></listitem> -</varlistentry> -</variablelist></refsect2> -<refsect2 id="pr29-strerror" role="function"> -<title>pr29_strerror ()</title> -<indexterm zone="pr29-strerror"><primary sortas="pr29_strerror">pr29_strerror</primary></indexterm><programlisting>const <link linkend="char">char</link> * pr29_strerror (<link linkend="Pr29-rc">Pr29_rc</link> rc);</programlisting> -<para> -Convert a return code integer to a text string. This string can be -used to output a diagnostic message to the user. -</para> -<para> -PR29_SUCCESS: Successful operation. This value is guaranteed to - always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -PR29_PROBLEM: A problem sequence was encountered. -PR29_STRINGPREP_ERROR: The character set conversion failed (only - for <link linkend="pr29-8"><function>pr29_8()</function></link> and <link linkend="pr29-8z"><function>pr29_8z()</function></link>).</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>rc</parameter> :</term> -<listitem><simpara> an <link linkend="Pr29-rc"><type>Pr29_rc</type></link> return code. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns a pointer to a statically allocated string - containing a description of the error with the return code <parameter>rc</parameter>. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="pr29-4" role="function"> -<title>pr29_4 ()</title> -<indexterm zone="pr29-4"><primary sortas="pr29_4">pr29_4</primary></indexterm><programlisting><link linkend="int">int</link> pr29_4 (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> len);</programlisting> -<para> -Check the input to see if it may be normalized into different -strings by different NFKC implementations, due to an anomaly in the -NFKC specifications.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input array with unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>len</parameter> :</term> -<listitem><simpara> length of input array with unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns the <link linkend="Pr29-rc"><type>Pr29_rc</type></link> value <link linkend="PR29-SUCCESS--CAPS"><literal>PR29_SUCCESS</literal></link> on success, - and <link linkend="PR29-PROBLEM--CAPS"><literal>PR29_PROBLEM</literal></link> if the input sequence is a "problem sequence" - (i.e., may be normalized into different strings by different - implementations). -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="pr29-4z" role="function"> -<title>pr29_4z ()</title> -<indexterm zone="pr29-4z"><primary sortas="pr29_4z">pr29_4z</primary></indexterm><programlisting><link linkend="int">int</link> pr29_4z (const <link linkend="uint32-t">uint32_t</link> *in);</programlisting> -<para> -Check the input to see if it may be normalized into different -strings by different NFKC implementations, due to an anomaly in the -NFKC specifications.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> zero terminated array of Unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns the <link linkend="Pr29-rc"><type>Pr29_rc</type></link> value <link linkend="PR29-SUCCESS--CAPS"><literal>PR29_SUCCESS</literal></link> on success, - and <link linkend="PR29-PROBLEM--CAPS"><literal>PR29_PROBLEM</literal></link> if the input sequence is a "problem sequence" - (i.e., may be normalized into different strings by different - implementations). -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="pr29-8z" role="function"> -<title>pr29_8z ()</title> -<indexterm zone="pr29-8z"><primary sortas="pr29_8z">pr29_8z</primary></indexterm><programlisting><link linkend="int">int</link> pr29_8z (const <link linkend="char">char</link> *in);</programlisting> -<para> -Check the input to see if it may be normalized into different -strings by different NFKC implementations, due to an anomaly in the -NFKC specifications.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> zero terminated input UTF-8 string. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns the <link linkend="Pr29-rc"><type>Pr29_rc</type></link> value <link linkend="PR29-SUCCESS--CAPS"><literal>PR29_SUCCESS</literal></link> on success, - and <link linkend="PR29-PROBLEM--CAPS"><literal>PR29_PROBLEM</literal></link> if the input sequence is a "problem sequence" - (i.e., may be normalized into different strings by different - implementations), or <link linkend="PR29-STRINGPREP-ERROR--CAPS"><literal>PR29_STRINGPREP_ERROR</literal></link> if there was a - problem converting the string from UTF-8 to UCS-4. -</simpara></listitem></varlistentry> -</variablelist></refsect2> - -</refsect1> - - - - -</refentry> diff --git a/doc/reference/xml/punycode.xml b/doc/reference/xml/punycode.xml deleted file mode 100644 index 2176286..0000000 --- a/doc/reference/xml/punycode.xml +++ /dev/null @@ -1,240 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<refentry id="libidn-punycode"> -<refmeta> -<refentrytitle role="top_of_page" id="libidn-punycode.top_of_page">punycode</refentrytitle> -<manvolnum>3</manvolnum> -<refmiscinfo>LIBIDN Library</refmiscinfo> -</refmeta> - -<refnamediv> -<refname>punycode</refname> -<refpurpose></refpurpose> -</refnamediv> - -<refsynopsisdiv id="libidn-punycode.synopsis" role="synopsis"> -<title role="synopsis.title">Synopsis</title> - -<synopsis> -#define <link linkend="IDNAPI--CAPS">IDNAPI</link> -enum <link linkend="Punycode-status">Punycode_status</link>; -const <link linkend="char">char</link> * <link linkend="punycode-strerror">punycode_strerror</link> (<link linkend="Punycode-status">Punycode_status</link> rc); -typedef <link linkend="punycode-uint">punycode_uint</link>; -<link linkend="int">int</link> <link linkend="punycode-encode">punycode_encode</link> (<link linkend="size-t">size_t</link> input_length, - const <link linkend="punycode-uint">punycode_uint</link> input[], - unsigned <link linkend="char">char</link> case_flags[], - <link linkend="size-t">size_t</link> *output_length, - <link linkend="char">char</link> output[]); -<link linkend="int">int</link> <link linkend="punycode-decode">punycode_decode</link> (<link linkend="size-t">size_t</link> input_length, - const <link linkend="char">char</link> input[], - <link linkend="size-t">size_t</link> *output_length, - <link linkend="punycode-uint">punycode_uint</link> output[], - unsigned <link linkend="char">char</link> case_flags[]); -</synopsis> -</refsynopsisdiv> - - - - - - - - - -<refsect1 id="libidn-punycode.description" role="desc"> -<title role="desc.title">Description</title> -<para> -</para> -</refsect1> - -<refsect1 id="libidn-punycode.details" role="details"> -<title role="details.title">Details</title> -<refsect2 id="IDNAPI--CAPS" role="macro"> -<title>IDNAPI</title> -<indexterm zone="IDNAPI--CAPS"><primary sortas="IDNAPI">IDNAPI</primary></indexterm><programlisting>#define IDNAPI</programlisting> -<para> -</para></refsect2> -<refsect2 id="Punycode-status" role="enum"> -<title>enum Punycode_status</title> -<indexterm zone="Punycode-status"><primary sortas="Punycode_status">Punycode_status</primary></indexterm><programlisting> typedef enum - { - PUNYCODE_SUCCESS = punycode_success, - PUNYCODE_BAD_INPUT = punycode_bad_input, - PUNYCODE_BIG_OUTPUT = punycode_big_output, - PUNYCODE_OVERFLOW = punycode_overflow - } Punycode_status; -</programlisting> -<para> -Enumerated return codes of <link linkend="punycode-encode"><function>punycode_encode()</function></link> and <link linkend="punycode-decode"><function>punycode_decode()</function></link>. -The value 0 is guaranteed to always correspond to success.</para> -<para> -</para><variablelist role="enum"> -<varlistentry id="PUNYCODE-SUCCESS--CAPS" role="constant"> -<term><literal>PUNYCODE_SUCCESS</literal></term> -<listitem><simpara> Successful operation. This value is guaranteed - to always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -</simpara></listitem> -</varlistentry> -<varlistentry id="PUNYCODE-BAD-INPUT--CAPS" role="constant"> -<term><literal>PUNYCODE_BAD_INPUT</literal></term> -<listitem><simpara> Input is invalid. -</simpara></listitem> -</varlistentry> -<varlistentry id="PUNYCODE-BIG-OUTPUT--CAPS" role="constant"> -<term><literal>PUNYCODE_BIG_OUTPUT</literal></term> -<listitem><simpara> Output would exceed the space provided. -</simpara></listitem> -</varlistentry> -<varlistentry id="PUNYCODE-OVERFLOW--CAPS" role="constant"> -<term><literal>PUNYCODE_OVERFLOW</literal></term> -<listitem><simpara> Input needs wider integers to process. -</simpara></listitem> -</varlistentry> -</variablelist></refsect2> -<refsect2 id="punycode-strerror" role="function"> -<title>punycode_strerror ()</title> -<indexterm zone="punycode-strerror"><primary sortas="punycode_strerror">punycode_strerror</primary></indexterm><programlisting>const <link linkend="char">char</link> * punycode_strerror (<link linkend="Punycode-status">Punycode_status</link> rc);</programlisting> -<para> -Convert a return code integer to a text string. This string can be -used to output a diagnostic message to the user. -</para> -<para> -PUNYCODE_SUCCESS: Successful operation. This value is guaranteed - to always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -PUNYCODE_BAD_INPUT: Input is invalid. -PUNYCODE_BIG_OUTPUT: Output would exceed the space provided. -PUNYCODE_OVERFLOW: Input needs wider integers to process.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>rc</parameter> :</term> -<listitem><simpara> an <link linkend="Punycode-status"><type>Punycode_status</type></link> return code. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns a pointer to a statically allocated string -containing a description of the error with the return code <parameter>rc</parameter>. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="punycode-uint" role="typedef"> -<title>punycode_uint</title> -<indexterm zone="punycode-uint"><primary sortas="punycode_uint">punycode_uint</primary></indexterm><programlisting> typedef uint32_t punycode_uint; -</programlisting> -<para> -Unicode code point data type, this is always a 32 bit unsigned -integer.</para> -<para> -</para></refsect2> -<refsect2 id="punycode-encode" role="function"> -<title>punycode_encode ()</title> -<indexterm zone="punycode-encode"><primary sortas="punycode_encode">punycode_encode</primary></indexterm><programlisting><link linkend="int">int</link> punycode_encode (<link linkend="size-t">size_t</link> input_length, - const <link linkend="punycode-uint">punycode_uint</link> input[], - unsigned <link linkend="char">char</link> case_flags[], - <link linkend="size-t">size_t</link> *output_length, - <link linkend="char">char</link> output[]);</programlisting> -<para> -Converts a sequence of code points (presumed to be Unicode code -points) to Punycode.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input_length</parameter> :</term> -<listitem><simpara> The number of code points in the <parameter>input</parameter> array and - the number of flags in the <parameter>case_flags</parameter> array. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> An array of code points. They are presumed to be Unicode - code points, but that is not strictly REQUIRED. The array - contains code points, not code units. UTF-16 uses code units - D800 through DFFF to refer to code points 10000..10FFFF. The - code points D800..DFFF do not occur in any valid Unicode string. - The code points that can occur in Unicode strings (0..D7FF and - E000..10FFFF) are also called Unicode scalar values. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>case_flags</parameter> :</term> -<listitem><simpara> A <link linkend="NULL--CAPS"><literal>NULL</literal></link> pointer or an array of boolean values parallel - to the <parameter>input</parameter> array. Nonzero (true, flagged) suggests that the - corresponding Unicode character be forced to uppercase after - being decoded (if possible), and zero (false, unflagged) suggests - that it be forced to lowercase (if possible). ASCII code points - (0..7F) are encoded literally, except that ASCII letters are - forced to uppercase or lowercase according to the corresponding - case flags. If <parameter>case_flags</parameter> is a <link linkend="NULL--CAPS"><literal>NULL</literal></link> pointer then ASCII letters - are left as they are, and other code points are treated as - unflagged. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output_length</parameter> :</term> -<listitem><simpara> The caller passes in the maximum number of ASCII - code points that it can receive. On successful return it will - contain the number of ASCII code points actually output. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> An array of ASCII code points. It is *not* - null-terminated; it will contain zeros if and only if the <parameter>input</parameter> - contains zeros. (Of course the caller can leave room for a - terminator and add one if needed.) -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> The return value can be any of the <link linkend="Punycode-status"><type>Punycode_status</type></link> - values defined above except <link linkend="PUNYCODE-BAD-INPUT--CAPS"><literal>PUNYCODE_BAD_INPUT</literal></link>. If not - <link linkend="PUNYCODE-SUCCESS--CAPS"><literal>PUNYCODE_SUCCESS</literal></link>, then <parameter>output_size</parameter> and <parameter>output</parameter> might contain - garbage. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="punycode-decode" role="function"> -<title>punycode_decode ()</title> -<indexterm zone="punycode-decode"><primary sortas="punycode_decode">punycode_decode</primary></indexterm><programlisting><link linkend="int">int</link> punycode_decode (<link linkend="size-t">size_t</link> input_length, - const <link linkend="char">char</link> input[], - <link linkend="size-t">size_t</link> *output_length, - <link linkend="punycode-uint">punycode_uint</link> output[], - unsigned <link linkend="char">char</link> case_flags[]);</programlisting> -<para> -Converts Punycode to a sequence of code points (presumed to be -Unicode code points).</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>input_length</parameter> :</term> -<listitem><simpara> The number of ASCII code points in the <parameter>input</parameter> array. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>input</parameter> :</term> -<listitem><simpara> An array of ASCII code points (0..7F). -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output_length</parameter> :</term> -<listitem><simpara> The caller passes in the maximum number of code - points that it can receive into the <parameter>output</parameter> array (which is also - the maximum number of flags that it can receive into the - <parameter>case_flags</parameter> array, if <parameter>case_flags</parameter> is not a <link linkend="NULL--CAPS"><literal>NULL</literal></link> pointer). On - successful return it will contain the number of code points - actually output (which is also the number of flags actually - output, if case_flags is not a null pointer). The decoder will - never need to output more code points than the number of ASCII - code points in the input, because of the way the encoding is - defined. The number of code points output cannot exceed the - maximum possible value of a punycode_uint, even if the supplied - <parameter>output_length</parameter> is greater than that. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>output</parameter> :</term> -<listitem><simpara> An array of code points like the input argument of - <link linkend="punycode-encode"><function>punycode_encode()</function></link> (see above). -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>case_flags</parameter> :</term> -<listitem><simpara> A <link linkend="NULL--CAPS"><literal>NULL</literal></link> pointer (if the flags are not needed by the - caller) or an array of boolean values parallel to the <parameter>output</parameter> - array. Nonzero (true, flagged) suggests that the corresponding - Unicode character be forced to uppercase by the caller (if - possible), and zero (false, unflagged) suggests that it be forced - to lowercase (if possible). ASCII code points (0..7F) are output - already in the proper case, but their flags will be set - appropriately so that applying the flags would be harmless. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> The return value can be any of the <link linkend="Punycode-status"><type>Punycode_status</type></link> - values defined above. If not <link linkend="PUNYCODE-SUCCESS--CAPS"><literal>PUNYCODE_SUCCESS</literal></link>, then - <parameter>output_length</parameter>, <parameter>output</parameter>, and <parameter>case_flags</parameter> might contain garbage. - -</simpara></listitem></varlistentry> -</variablelist></refsect2> - -</refsect1> - - - - -</refentry> diff --git a/doc/reference/xml/stringprep.xml b/doc/reference/xml/stringprep.xml deleted file mode 100644 index 4af4a8b..0000000 --- a/doc/reference/xml/stringprep.xml +++ /dev/null @@ -1,866 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<refentry id="libidn-stringprep"> -<refmeta> -<refentrytitle role="top_of_page" id="libidn-stringprep.top_of_page">stringprep</refentrytitle> -<manvolnum>3</manvolnum> -<refmiscinfo>LIBIDN Library</refmiscinfo> -</refmeta> - -<refnamediv> -<refname>stringprep</refname> -<refpurpose></refpurpose> -</refnamediv> - -<refsynopsisdiv id="libidn-stringprep.synopsis" role="synopsis"> -<title role="synopsis.title">Synopsis</title> - -<synopsis> -#define <link linkend="IDNAPI--CAPS">IDNAPI</link> -#define <link linkend="STRINGPREP-VERSION--CAPS">STRINGPREP_VERSION</link> -enum <link linkend="Stringprep-rc">Stringprep_rc</link>; -enum <link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link>; -enum <link linkend="Stringprep-profile-steps">Stringprep_profile_steps</link>; -#define <link linkend="STRINGPREP-MAX-MAP-CHARS--CAPS">STRINGPREP_MAX_MAP_CHARS</link> -typedef <link linkend="Stringprep-table-element">Stringprep_table_element</link>; -typedef <link linkend="Stringprep-profile">Stringprep_profile</link>; -typedef <link linkend="Stringprep-profiles">Stringprep_profiles</link>; -#define <link linkend="stringprep-nameprep">stringprep_nameprep</link> (in, maxlen) -#define <link linkend="stringprep-nameprep-no-unassigned">stringprep_nameprep_no_unassigned</link> (in, maxlen) -#define <link linkend="stringprep-plain">stringprep_plain</link> (in, maxlen) -#define <link linkend="stringprep-kerberos5">stringprep_kerberos5</link> (in, maxlen) -#define <link linkend="stringprep-xmpp-nodeprep">stringprep_xmpp_nodeprep</link> (in, maxlen) -#define <link linkend="stringprep-xmpp-resourceprep">stringprep_xmpp_resourceprep</link> (in, maxlen) -#define <link linkend="stringprep-iscsi">stringprep_iscsi</link> (in, maxlen) -<link linkend="int">int</link> <link linkend="stringprep-4i">stringprep_4i</link> (<link linkend="uint32-t">uint32_t</link> *ucs4, - <link linkend="size-t">size_t</link> *len, - <link linkend="size-t">size_t</link> maxucs4len, - <link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link> flags, - const <link linkend="Stringprep-profile">Stringprep_profile</link> *profile); -<link linkend="int">int</link> <link linkend="stringprep-4zi">stringprep_4zi</link> (<link linkend="uint32-t">uint32_t</link> *ucs4, - <link linkend="size-t">size_t</link> maxucs4len, - <link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link> flags, - const <link linkend="Stringprep-profile">Stringprep_profile</link> *profile); -<link linkend="int">int</link> <link linkend="stringprep">stringprep</link> (<link linkend="char">char</link> *in, - <link linkend="size-t">size_t</link> maxlen, - <link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link> flags, - const <link linkend="Stringprep-profile">Stringprep_profile</link> *profile); -<link linkend="int">int</link> <link linkend="stringprep-profile">stringprep_profile</link> (const <link linkend="char">char</link> *in, - <link linkend="char">char</link> **out, - const <link linkend="char">char</link> *profile, - <link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link> flags); -const <link linkend="char">char</link> * <link linkend="stringprep-strerror">stringprep_strerror</link> (<link linkend="Stringprep-rc">Stringprep_rc</link> rc); -const <link linkend="char">char</link> * <link linkend="stringprep-check-version">stringprep_check_version</link> (const <link linkend="char">char</link> *req_version); -<link linkend="int">int</link> <link linkend="stringprep-unichar-to-utf8">stringprep_unichar_to_utf8</link> (<link linkend="uint32-t">uint32_t</link> c, - <link linkend="char">char</link> *outbuf); -<link linkend="uint32-t">uint32_t</link> <link linkend="stringprep-utf8-to-unichar">stringprep_utf8_to_unichar</link> (const <link linkend="char">char</link> *p); -<link linkend="uint32-t">uint32_t</link> * <link linkend="stringprep-utf8-to-ucs4">stringprep_utf8_to_ucs4</link> (const <link linkend="char">char</link> *str, - <link linkend="ssize-t">ssize_t</link> len, - <link linkend="size-t">size_t</link> *items_written); -<link linkend="char">char</link> * <link linkend="stringprep-ucs4-to-utf8">stringprep_ucs4_to_utf8</link> (const <link linkend="uint32-t">uint32_t</link> *str, - <link linkend="ssize-t">ssize_t</link> len, - <link linkend="size-t">size_t</link> *items_read, - <link linkend="size-t">size_t</link> *items_written); -<link linkend="char">char</link> * <link linkend="stringprep-utf8-nfkc-normalize">stringprep_utf8_nfkc_normalize</link> (const <link linkend="char">char</link> *str, - <link linkend="ssize-t">ssize_t</link> len); -<link linkend="uint32-t">uint32_t</link> * <link linkend="stringprep-ucs4-nfkc-normalize">stringprep_ucs4_nfkc_normalize</link> (<link linkend="uint32-t">uint32_t</link> *str, - <link linkend="ssize-t">ssize_t</link> len); -const <link linkend="char">char</link> * <link linkend="stringprep-locale-charset">stringprep_locale_charset</link> (void); -<link linkend="char">char</link> * <link linkend="stringprep-convert">stringprep_convert</link> (const <link linkend="char">char</link> *str, - const <link linkend="char">char</link> *to_codeset, - const <link linkend="char">char</link> *from_codeset); -<link linkend="char">char</link> * <link linkend="stringprep-locale-to-utf8">stringprep_locale_to_utf8</link> (const <link linkend="char">char</link> *str); -<link linkend="char">char</link> * <link linkend="stringprep-utf8-to-locale">stringprep_utf8_to_locale</link> (const <link linkend="char">char</link> *str); -</synopsis> -</refsynopsisdiv> - - - - - - - - - -<refsect1 id="libidn-stringprep.description" role="desc"> -<title role="desc.title">Description</title> -<para> -</para> -</refsect1> - -<refsect1 id="libidn-stringprep.details" role="details"> -<title role="details.title">Details</title> -<refsect2 id="IDNAPI--CAPS" role="macro"> -<title>IDNAPI</title> -<indexterm zone="IDNAPI--CAPS"><primary sortas="IDNAPI">IDNAPI</primary></indexterm><programlisting>#define IDNAPI</programlisting> -<para> -</para></refsect2> -<refsect2 id="STRINGPREP-VERSION--CAPS" role="macro"> -<title>STRINGPREP_VERSION</title> -<indexterm zone="STRINGPREP-VERSION--CAPS"><primary sortas="STRINGPREP_VERSION">STRINGPREP_VERSION</primary></indexterm><programlisting># define STRINGPREP_VERSION "1.15" -</programlisting> -<para> -String defined via CPP denoting the header file version number. -Used together with <link linkend="stringprep-check-version"><function>stringprep_check_version()</function></link> to verify header file -and run-time library consistency.</para> -<para> -</para></refsect2> -<refsect2 id="Stringprep-rc" role="enum"> -<title>enum Stringprep_rc</title> -<indexterm zone="Stringprep-rc"><primary sortas="Stringprep_rc">Stringprep_rc</primary></indexterm><programlisting> typedef enum - { - STRINGPREP_OK = 0, - /* Stringprep errors. */ - STRINGPREP_CONTAINS_UNASSIGNED = 1, - STRINGPREP_CONTAINS_PROHIBITED = 2, - STRINGPREP_BIDI_BOTH_L_AND_RAL = 3, - STRINGPREP_BIDI_LEADTRAIL_NOT_RAL = 4, - STRINGPREP_BIDI_CONTAINS_PROHIBITED = 5, - /* Error in calling application. */ - STRINGPREP_TOO_SMALL_BUFFER = 100, - STRINGPREP_PROFILE_ERROR = 101, - STRINGPREP_FLAG_ERROR = 102, - STRINGPREP_UNKNOWN_PROFILE = 103, - /* Internal errors. */ - STRINGPREP_NFKC_FAILED = 200, - STRINGPREP_MALLOC_ERROR = 201 - } Stringprep_rc; -</programlisting> -<para> -Enumerated return codes of <link linkend="stringprep"><function>stringprep()</function></link>, <link linkend="stringprep-profile"><function>stringprep_profile()</function></link> -functions (and macros using those functions). The value 0 is -guaranteed to always correspond to success.</para> -<para> -</para><variablelist role="enum"> -<varlistentry id="STRINGPREP-OK--CAPS" role="constant"> -<term><literal>STRINGPREP_OK</literal></term> -<listitem><simpara> Successful operation. This value is guaranteed to - always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-CONTAINS-UNASSIGNED--CAPS" role="constant"> -<term><literal>STRINGPREP_CONTAINS_UNASSIGNED</literal></term> -<listitem><simpara> String contain unassigned Unicode - code points, which is forbidden by the profile. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-CONTAINS-PROHIBITED--CAPS" role="constant"> -<term><literal>STRINGPREP_CONTAINS_PROHIBITED</literal></term> -<listitem><simpara> String contain code points - prohibited by the profile. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-BIDI-BOTH-L-AND-RAL--CAPS" role="constant"> -<term><literal>STRINGPREP_BIDI_BOTH_L_AND_RAL</literal></term> -<listitem><simpara> String contain code points with - conflicting bidirection category. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-BIDI-LEADTRAIL-NOT-RAL--CAPS" role="constant"> -<term><literal>STRINGPREP_BIDI_LEADTRAIL_NOT_RAL</literal></term> -<listitem><simpara> Leading and trailing character - in string not of proper bidirectional category. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-BIDI-CONTAINS-PROHIBITED--CAPS" role="constant"> -<term><literal>STRINGPREP_BIDI_CONTAINS_PROHIBITED</literal></term> -<listitem><simpara> Contains prohibited code - points detected by bidirectional code. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-TOO-SMALL-BUFFER--CAPS" role="constant"> -<term><literal>STRINGPREP_TOO_SMALL_BUFFER</literal></term> -<listitem><simpara> Buffer handed to function was too - small. This usually indicate a problem in the calling - application. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-PROFILE-ERROR--CAPS" role="constant"> -<term><literal>STRINGPREP_PROFILE_ERROR</literal></term> -<listitem><simpara> The stringprep profile was inconsistent. - This usually indicate an internal error in the library. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-FLAG-ERROR--CAPS" role="constant"> -<term><literal>STRINGPREP_FLAG_ERROR</literal></term> -<listitem><simpara> The supplied flag conflicted with profile. - This usually indicate a problem in the calling application. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-UNKNOWN-PROFILE--CAPS" role="constant"> -<term><literal>STRINGPREP_UNKNOWN_PROFILE</literal></term> -<listitem><simpara> The supplied profile name was not - known to the library. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-NFKC-FAILED--CAPS" role="constant"> -<term><literal>STRINGPREP_NFKC_FAILED</literal></term> -<listitem><simpara> The Unicode NFKC operation failed. This - usually indicate an internal error in the library. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-MALLOC-ERROR--CAPS" role="constant"> -<term><literal>STRINGPREP_MALLOC_ERROR</literal></term> -<listitem><simpara> The <link linkend="malloc"><function>malloc()</function></link> was out of memory. This is - usually a fatal error. -</simpara></listitem> -</varlistentry> -</variablelist></refsect2> -<refsect2 id="Stringprep-profile-flags" role="enum"> -<title>enum Stringprep_profile_flags</title> -<indexterm zone="Stringprep-profile-flags"><primary sortas="Stringprep_profile_flags">Stringprep_profile_flags</primary></indexterm><programlisting> typedef enum - { - STRINGPREP_NO_NFKC = 1, - STRINGPREP_NO_BIDI = 2, - STRINGPREP_NO_UNASSIGNED = 4 - } Stringprep_profile_flags; -</programlisting> -<para> -Stringprep profile flags.</para> -<para> -</para><variablelist role="enum"> -<varlistentry id="STRINGPREP-NO-NFKC--CAPS" role="constant"> -<term><literal>STRINGPREP_NO_NFKC</literal></term> -<listitem><simpara> Disable the NFKC normalization, as well as - selecting the non-NFKC case folding tables. Usually the profile - specifies BIDI and NFKC settings, and applications should not - override it unless in special situations. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-NO-BIDI--CAPS" role="constant"> -<term><literal>STRINGPREP_NO_BIDI</literal></term> -<listitem><simpara> Disable the BIDI step. Usually the profile - specifies BIDI and NFKC settings, and applications should not - override it unless in special situations. -</simpara></listitem> -</varlistentry> -<varlistentry id="STRINGPREP-NO-UNASSIGNED--CAPS" role="constant"> -<term><literal>STRINGPREP_NO_UNASSIGNED</literal></term> -<listitem><simpara> Make the library return with an error if - string contains unassigned characters according to profile. -</simpara></listitem> -</varlistentry> -</variablelist></refsect2> -<refsect2 id="Stringprep-profile-steps" role="enum"> -<title>enum Stringprep_profile_steps</title> -<indexterm zone="Stringprep-profile-steps"><primary sortas="Stringprep_profile_steps">Stringprep_profile_steps</primary></indexterm><programlisting> typedef enum - { - STRINGPREP_NFKC = 1, - STRINGPREP_BIDI = 2, - STRINGPREP_MAP_TABLE = 3, - STRINGPREP_UNASSIGNED_TABLE = 4, - STRINGPREP_PROHIBIT_TABLE = 5, - STRINGPREP_BIDI_PROHIBIT_TABLE = 6, - STRINGPREP_BIDI_RAL_TABLE = 7, - STRINGPREP_BIDI_L_TABLE = 8 - } Stringprep_profile_steps; -</programlisting> -<para> -Various steps in the stringprep algorithm. You really want to -study the source code to understand this one. Only useful if you -want to add another profile.</para> -<para> -</para></refsect2> -<refsect2 id="STRINGPREP-MAX-MAP-CHARS--CAPS" role="macro"> -<title>STRINGPREP_MAX_MAP_CHARS</title> -<indexterm zone="STRINGPREP-MAX-MAP-CHARS--CAPS"><primary sortas="STRINGPREP_MAX_MAP_CHARS">STRINGPREP_MAX_MAP_CHARS</primary></indexterm><programlisting># define STRINGPREP_MAX_MAP_CHARS 4 -</programlisting> -<para> -Maximum number of code points that can replace a single code point, -during stringprep mapping.</para> -<para> -</para></refsect2> -<refsect2 id="Stringprep-table-element" role="typedef"> -<title>Stringprep_table_element</title> -<indexterm zone="Stringprep-table-element"><primary sortas="Stringprep_table_element">Stringprep_table_element</primary></indexterm><programlisting> typedef struct Stringprep_table_element Stringprep_table_element; -</programlisting> -<para> -</para></refsect2> -<refsect2 id="Stringprep-profile" role="typedef"> -<title>Stringprep_profile</title> -<indexterm zone="Stringprep-profile"><primary sortas="Stringprep_profile">Stringprep_profile</primary></indexterm><programlisting> typedef struct Stringprep_table Stringprep_profile; -</programlisting> -<para> -</para></refsect2> -<refsect2 id="Stringprep-profiles" role="typedef"> -<title>Stringprep_profiles</title> -<indexterm zone="Stringprep-profiles"><primary sortas="Stringprep_profiles">Stringprep_profiles</primary></indexterm><programlisting> typedef struct Stringprep_profiles Stringprep_profiles; -</programlisting> -<para> -</para></refsect2> -<refsect2 id="stringprep-nameprep" role="macro"> -<title>stringprep_nameprep()</title> -<indexterm zone="stringprep-nameprep"><primary sortas="stringprep_nameprep">stringprep_nameprep</primary></indexterm><programlisting>#define stringprep_nameprep(in, maxlen)</programlisting> -<para> -Prepare the input UTF-8 string according to the nameprep profile. -The AllowUnassigned flag is true, use -<link linkend="stringprep-nameprep-no-unassigned"><function>stringprep_nameprep_no_unassigned()</function></link> if you want a false -AllowUnassigned. Returns 0 iff successful, or an error code.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input/ouput array with string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxlen</parameter> :</term> -<listitem><simpara> maximum length of input/output array. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-nameprep-no-unassigned" role="macro"> -<title>stringprep_nameprep_no_unassigned()</title> -<indexterm zone="stringprep-nameprep-no-unassigned"><primary sortas="stringprep_nameprep_no_unassigned">stringprep_nameprep_no_unassigned</primary></indexterm><programlisting>#define stringprep_nameprep_no_unassigned(in, maxlen)</programlisting> -<para> -Prepare the input UTF-8 string according to the nameprep profile. -The AllowUnassigned flag is false, use <link linkend="stringprep-nameprep"><function>stringprep_nameprep()</function></link> for -true AllowUnassigned. Returns 0 iff successful, or an error code.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input/ouput array with string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxlen</parameter> :</term> -<listitem><simpara> maximum length of input/output array. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-plain" role="macro"> -<title>stringprep_plain()</title> -<indexterm zone="stringprep-plain"><primary sortas="stringprep_plain">stringprep_plain</primary></indexterm><programlisting>#define stringprep_plain(in, maxlen)</programlisting> -<para> -Prepare the input UTF-8 string according to the draft SASL -ANONYMOUS profile. Returns 0 iff successful, or an error code.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input/ouput array with string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxlen</parameter> :</term> -<listitem><simpara> maximum length of input/output array. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-kerberos5" role="macro"> -<title>stringprep_kerberos5()</title> -<indexterm zone="stringprep-kerberos5"><primary sortas="stringprep_kerberos5">stringprep_kerberos5</primary></indexterm><programlisting>#define stringprep_kerberos5(in, maxlen)</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxlen</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-xmpp-nodeprep" role="macro"> -<title>stringprep_xmpp_nodeprep()</title> -<indexterm zone="stringprep-xmpp-nodeprep"><primary sortas="stringprep_xmpp_nodeprep">stringprep_xmpp_nodeprep</primary></indexterm><programlisting>#define stringprep_xmpp_nodeprep(in, maxlen)</programlisting> -<para> -Prepare the input UTF-8 string according to the draft XMPP node -identifier profile. Returns 0 iff successful, or an error code.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input/ouput array with string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxlen</parameter> :</term> -<listitem><simpara> maximum length of input/output array. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-xmpp-resourceprep" role="macro"> -<title>stringprep_xmpp_resourceprep()</title> -<indexterm zone="stringprep-xmpp-resourceprep"><primary sortas="stringprep_xmpp_resourceprep">stringprep_xmpp_resourceprep</primary></indexterm><programlisting>#define stringprep_xmpp_resourceprep(in, maxlen)</programlisting> -<para> -Prepare the input UTF-8 string according to the draft XMPP resource -identifier profile. Returns 0 iff successful, or an error code.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input/ouput array with string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxlen</parameter> :</term> -<listitem><simpara> maximum length of input/output array. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-iscsi" role="macro"> -<title>stringprep_iscsi()</title> -<indexterm zone="stringprep-iscsi"><primary sortas="stringprep_iscsi">stringprep_iscsi</primary></indexterm><programlisting>#define stringprep_iscsi(in, maxlen)</programlisting> -<para> -Prepare the input UTF-8 string according to the draft iSCSI -stringprep profile. Returns 0 iff successful, or an error code.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input/ouput array with string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxlen</parameter> :</term> -<listitem><simpara> maximum length of input/output array. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-4i" role="function"> -<title>stringprep_4i ()</title> -<indexterm zone="stringprep-4i"><primary sortas="stringprep_4i">stringprep_4i</primary></indexterm><programlisting><link linkend="int">int</link> stringprep_4i (<link linkend="uint32-t">uint32_t</link> *ucs4, - <link linkend="size-t">size_t</link> *len, - <link linkend="size-t">size_t</link> maxucs4len, - <link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link> flags, - const <link linkend="Stringprep-profile">Stringprep_profile</link> *profile);</programlisting> -<para> -Prepare the input UCS-4 string according to the stringprep profile, -and write back the result to the input string. -</para> -<para> -The input is not required to be zero terminated (<parameter>ucs4</parameter>[<parameter>len</parameter>] = 0). -The output will not be zero terminated unless <parameter>ucs4</parameter>[<parameter>len</parameter>] = 0. -Instead, see <link linkend="stringprep-4zi"><function>stringprep_4zi()</function></link> if your input is zero terminated or -if you want the output to be. -</para> -<para> -Since the stringprep operation can expand the string, <parameter>maxucs4len</parameter> -indicate how large the buffer holding the string is. This function -will not read or write to code points outside that size. -</para> -<para> -The <parameter>flags</parameter> are one of <link linkend="Stringprep-profile-flags"><type>Stringprep_profile_flags</type></link> values, or 0. -</para> -<para> -The <parameter>profile</parameter> contain the <link linkend="Stringprep-profile"><type>Stringprep_profile</type></link> instructions to -perform. Your application can define new profiles, possibly -re-using the generic stringprep tables that always will be part of -the library, or use one of the currently supported profiles.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>ucs4</parameter> :</term> -<listitem><simpara> input/output array with string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>len</parameter> :</term> -<listitem><simpara> on input, length of input array with Unicode code points, - on exit, length of output array with Unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxucs4len</parameter> :</term> -<listitem><simpara> maximum length of input/output array. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> a <link linkend="Stringprep-profile-flags"><type>Stringprep_profile_flags</type></link> value, or 0. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>profile</parameter> :</term> -<listitem><simpara> pointer to <link linkend="Stringprep-profile"><type>Stringprep_profile</type></link> to use. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="STRINGPREP-OK--CAPS"><literal>STRINGPREP_OK</literal></link> iff successful, or an - <link linkend="Stringprep-rc"><type>Stringprep_rc</type></link> error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-4zi" role="function"> -<title>stringprep_4zi ()</title> -<indexterm zone="stringprep-4zi"><primary sortas="stringprep_4zi">stringprep_4zi</primary></indexterm><programlisting><link linkend="int">int</link> stringprep_4zi (<link linkend="uint32-t">uint32_t</link> *ucs4, - <link linkend="size-t">size_t</link> maxucs4len, - <link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link> flags, - const <link linkend="Stringprep-profile">Stringprep_profile</link> *profile);</programlisting> -<para> -Prepare the input zero terminated UCS-4 string according to the -stringprep profile, and write back the result to the input string. -</para> -<para> -Since the stringprep operation can expand the string, <parameter>maxucs4len</parameter> -indicate how large the buffer holding the string is. This function -will not read or write to code points outside that size. -</para> -<para> -The <parameter>flags</parameter> are one of <link linkend="Stringprep-profile-flags"><type>Stringprep_profile_flags</type></link> values, or 0. -</para> -<para> -The <parameter>profile</parameter> contain the <link linkend="Stringprep-profile"><type>Stringprep_profile</type></link> instructions to -perform. Your application can define new profiles, possibly -re-using the generic stringprep tables that always will be part of -the library, or use one of the currently supported profiles.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>ucs4</parameter> :</term> -<listitem><simpara> input/output array with zero terminated string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxucs4len</parameter> :</term> -<listitem><simpara> maximum length of input/output array. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> a <link linkend="Stringprep-profile-flags"><type>Stringprep_profile_flags</type></link> value, or 0. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>profile</parameter> :</term> -<listitem><simpara> pointer to <link linkend="Stringprep-profile"><type>Stringprep_profile</type></link> to use. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="STRINGPREP-OK--CAPS"><literal>STRINGPREP_OK</literal></link> iff successful, or an - <link linkend="Stringprep-rc"><type>Stringprep_rc</type></link> error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep" role="function"> -<title>stringprep ()</title> -<indexterm zone="stringprep"><primary sortas="stringprep">stringprep</primary></indexterm><programlisting><link linkend="int">int</link> stringprep (<link linkend="char">char</link> *in, - <link linkend="size-t">size_t</link> maxlen, - <link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link> flags, - const <link linkend="Stringprep-profile">Stringprep_profile</link> *profile);</programlisting> -<para> -Prepare the input zero terminated UTF-8 string according to the -stringprep profile, and write back the result to the input string. -</para> -<para> -Note that you must convert strings entered in the systems locale -into UTF-8 before using this function, see -<link linkend="stringprep-locale-to-utf8"><function>stringprep_locale_to_utf8()</function></link>. -</para> -<para> -Since the stringprep operation can expand the string, <parameter>maxlen</parameter> -indicate how large the buffer holding the string is. This function -will not read or write to characters outside that size. -</para> -<para> -The <parameter>flags</parameter> are one of <link linkend="Stringprep-profile-flags"><type>Stringprep_profile_flags</type></link> values, or 0. -</para> -<para> -The <parameter>profile</parameter> contain the <link linkend="Stringprep-profile"><type>Stringprep_profile</type></link> instructions to -perform. Your application can define new profiles, possibly -re-using the generic stringprep tables that always will be part of -the library, or use one of the currently supported profiles.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input/ouput array with string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>maxlen</parameter> :</term> -<listitem><simpara> maximum length of input/output array. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> a <link linkend="Stringprep-profile-flags"><type>Stringprep_profile_flags</type></link> value, or 0. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>profile</parameter> :</term> -<listitem><simpara> pointer to <link linkend="Stringprep-profile"><type>Stringprep_profile</type></link> to use. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="STRINGPREP-OK--CAPS"><literal>STRINGPREP_OK</literal></link> iff successful, or an error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-profile" role="function"> -<title>stringprep_profile ()</title> -<indexterm zone="stringprep-profile"><primary sortas="stringprep_profile">stringprep_profile</primary></indexterm><programlisting><link linkend="int">int</link> stringprep_profile (const <link linkend="char">char</link> *in, - <link linkend="char">char</link> **out, - const <link linkend="char">char</link> *profile, - <link linkend="Stringprep-profile-flags">Stringprep_profile_flags</link> flags);</programlisting> -<para> -Prepare the input zero terminated UTF-8 string according to the -stringprep profile, and return the result in a newly allocated -variable. -</para> -<para> -Note that you must convert strings entered in the systems locale -into UTF-8 before using this function, see -<link linkend="stringprep-locale-to-utf8"><function>stringprep_locale_to_utf8()</function></link>. -</para> -<para> -The output <parameter>out</parameter> variable must be deallocated by the caller. -</para> -<para> -The <parameter>flags</parameter> are one of <link linkend="Stringprep-profile-flags"><type>Stringprep_profile_flags</type></link> values, or 0. -</para> -<para> -The <parameter>profile</parameter> specifies the name of the stringprep profile to use. -It must be one of the internally supported stringprep profiles.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> input array with UTF-8 string to prepare. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>out</parameter> :</term> -<listitem><simpara> output variable with pointer to newly allocate string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>profile</parameter> :</term> -<listitem><simpara> name of stringprep profile to use. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>flags</parameter> :</term> -<listitem><simpara> a <link linkend="Stringprep-profile-flags"><type>Stringprep_profile_flags</type></link> value, or 0. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns <link linkend="STRINGPREP-OK--CAPS"><literal>STRINGPREP_OK</literal></link> iff successful, or an error code. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-strerror" role="function"> -<title>stringprep_strerror ()</title> -<indexterm zone="stringprep-strerror"><primary sortas="stringprep_strerror">stringprep_strerror</primary></indexterm><programlisting>const <link linkend="char">char</link> * stringprep_strerror (<link linkend="Stringprep-rc">Stringprep_rc</link> rc);</programlisting> -<para> -Convert a return code integer to a text string. This string can be -used to output a diagnostic message to the user. -</para> -<para> -STRINGPREP_OK: Successful operation. This value is guaranteed to - always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -STRINGPREP_CONTAINS_UNASSIGNED: String contain unassigned Unicode - code points, which is forbidden by the profile. -STRINGPREP_CONTAINS_PROHIBITED: String contain code points - prohibited by the profile. -STRINGPREP_BIDI_BOTH_L_AND_RAL: String contain code points with - conflicting bidirection category. -STRINGPREP_BIDI_LEADTRAIL_NOT_RAL: Leading and trailing character - in string not of proper bidirectional category. -STRINGPREP_BIDI_CONTAINS_PROHIBITED: Contains prohibited code - points detected by bidirectional code. -STRINGPREP_TOO_SMALL_BUFFER: Buffer handed to function was too - small. This usually indicate a problem in the calling - application. -STRINGPREP_PROFILE_ERROR: The stringprep profile was inconsistent. - This usually indicate an internal error in the library. -STRINGPREP_FLAG_ERROR: The supplied flag conflicted with profile. - This usually indicate a problem in the calling application. -STRINGPREP_UNKNOWN_PROFILE: The supplied profile name was not - known to the library. -STRINGPREP_NFKC_FAILED: The Unicode NFKC operation failed. This - usually indicate an internal error in the library. -STRINGPREP_MALLOC_ERROR: The <link linkend="malloc"><function>malloc()</function></link> was out of memory. This is - usually a fatal error.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>rc</parameter> :</term> -<listitem><simpara> a <link linkend="Stringprep-rc"><type>Stringprep_rc</type></link> return code. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns a pointer to a statically allocated string - containing a description of the error with the return code <parameter>rc</parameter>. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-check-version" role="function"> -<title>stringprep_check_version ()</title> -<indexterm zone="stringprep-check-version"><primary sortas="stringprep_check_version">stringprep_check_version</primary></indexterm><programlisting>const <link linkend="char">char</link> * stringprep_check_version (const <link linkend="char">char</link> *req_version);</programlisting> -<para> -Check that the version of the library is at minimum the requested one -and return the version string; return NULL if the condition is not -satisfied. If a NULL is passed to this function, no check is done, -but the version string is simply returned. -</para> -<para> -See <link linkend="STRINGPREP-VERSION--CAPS"><literal>STRINGPREP_VERSION</literal></link> for a suitable <parameter>req_version</parameter> string.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>req_version</parameter> :</term> -<listitem><simpara> Required version number, or NULL. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Version string of run-time library, or NULL if the -run-time library does not meet the required version number. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-unichar-to-utf8" role="function"> -<title>stringprep_unichar_to_utf8 ()</title> -<indexterm zone="stringprep-unichar-to-utf8"><primary sortas="stringprep_unichar_to_utf8">stringprep_unichar_to_utf8</primary></indexterm><programlisting><link linkend="int">int</link> stringprep_unichar_to_utf8 (<link linkend="uint32-t">uint32_t</link> c, - <link linkend="char">char</link> *outbuf);</programlisting> -<para> -Converts a single character to UTF-8.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>c</parameter> :</term> -<listitem><simpara> a ISO10646 character code -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>outbuf</parameter> :</term> -<listitem><simpara> output buffer, must have at least 6 bytes of space. - If <link linkend="NULL--CAPS"><literal>NULL</literal></link>, the length will be computed and returned - and nothing will be written to <parameter>outbuf</parameter>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> number of bytes written. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-utf8-to-unichar" role="function"> -<title>stringprep_utf8_to_unichar ()</title> -<indexterm zone="stringprep-utf8-to-unichar"><primary sortas="stringprep_utf8_to_unichar">stringprep_utf8_to_unichar</primary></indexterm><programlisting><link linkend="uint32-t">uint32_t</link> stringprep_utf8_to_unichar (const <link linkend="char">char</link> *p);</programlisting> -<para> -Converts a sequence of bytes encoded as UTF-8 to a Unicode character. -If <parameter>p</parameter> does not point to a valid UTF-8 encoded character, results are -undefined.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>p</parameter> :</term> -<listitem><simpara> a pointer to Unicode character encoded as UTF-8 -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> the resulting character. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-utf8-to-ucs4" role="function"> -<title>stringprep_utf8_to_ucs4 ()</title> -<indexterm zone="stringprep-utf8-to-ucs4"><primary sortas="stringprep_utf8_to_ucs4">stringprep_utf8_to_ucs4</primary></indexterm><programlisting><link linkend="uint32-t">uint32_t</link> * stringprep_utf8_to_ucs4 (const <link linkend="char">char</link> *str, - <link linkend="ssize-t">ssize_t</link> len, - <link linkend="size-t">size_t</link> *items_written);</programlisting> -<para> -Convert a string from UTF-8 to a 32-bit fixed width -representation as UCS-4, assuming valid UTF-8 input. -This function does no error checking on the input.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>str</parameter> :</term> -<listitem><simpara> a UTF-8 encoded string -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>len</parameter> :</term> -<listitem><simpara> the maximum length of <parameter>str</parameter> to use. If <parameter>len</parameter> < 0, then - the string is nul-terminated. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>items_written</parameter> :</term> -<listitem><simpara> location to store the number of characters in the - result, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> a pointer to a newly allocated UCS-4 string. - This value must be deallocated by the caller. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-ucs4-to-utf8" role="function"> -<title>stringprep_ucs4_to_utf8 ()</title> -<indexterm zone="stringprep-ucs4-to-utf8"><primary sortas="stringprep_ucs4_to_utf8">stringprep_ucs4_to_utf8</primary></indexterm><programlisting><link linkend="char">char</link> * stringprep_ucs4_to_utf8 (const <link linkend="uint32-t">uint32_t</link> *str, - <link linkend="ssize-t">ssize_t</link> len, - <link linkend="size-t">size_t</link> *items_read, - <link linkend="size-t">size_t</link> *items_written);</programlisting> -<para> -Convert a string from a 32-bit fixed width representation as UCS-4. -to UTF-8. The result will be terminated with a 0 byte.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>str</parameter> :</term> -<listitem><simpara> a UCS-4 encoded string -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>len</parameter> :</term> -<listitem><simpara> the maximum length of <parameter>str</parameter> to use. If <parameter>len</parameter> < 0, then - the string is terminated with a 0 character. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>items_read</parameter> :</term> -<listitem><simpara> location to store number of characters read read, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>items_written</parameter> :</term> -<listitem><simpara> location to store number of bytes written or <link linkend="NULL--CAPS"><literal>NULL</literal></link>. - The value here stored does not include the trailing 0 - byte. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> a pointer to a newly allocated UTF-8 string. - This value must be deallocated by the caller. - If an error occurs, <link linkend="NULL--CAPS"><literal>NULL</literal></link> will be returned and <parameter>error</parameter> - set. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-utf8-nfkc-normalize" role="function"> -<title>stringprep_utf8_nfkc_normalize ()</title> -<indexterm zone="stringprep-utf8-nfkc-normalize"><primary sortas="stringprep_utf8_nfkc_normalize">stringprep_utf8_nfkc_normalize</primary></indexterm><programlisting><link linkend="char">char</link> * stringprep_utf8_nfkc_normalize (const <link linkend="char">char</link> *str, - <link linkend="ssize-t">ssize_t</link> len);</programlisting> -<para> -Converts a string into canonical form, standardizing -such issues as whether a character with an accent -is represented as a base character and combining -accent or as a single precomposed character. -</para> -<para> -The normalization mode is NFKC (ALL COMPOSE). It standardizes -differences that do not affect the text content, such as the -above-mentioned accent representation. It standardizes the -"compatibility" characters in Unicode, such as SUPERSCRIPT THREE to -the standard forms (in this case DIGIT THREE). Formatting -information may be lost but for most text operations such -characters should be considered the same. It returns a result with -composed forms rather than a maximally decomposed form.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>str</parameter> :</term> -<listitem><simpara> a UTF-8 encoded string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>len</parameter> :</term> -<listitem><simpara> length of <parameter>str</parameter>, in bytes, or -1 if <parameter>str</parameter> is nul-terminated. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> a newly allocated string, that is the - NFKC normalized form of <parameter>str</parameter>. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-ucs4-nfkc-normalize" role="function"> -<title>stringprep_ucs4_nfkc_normalize ()</title> -<indexterm zone="stringprep-ucs4-nfkc-normalize"><primary sortas="stringprep_ucs4_nfkc_normalize">stringprep_ucs4_nfkc_normalize</primary></indexterm><programlisting><link linkend="uint32-t">uint32_t</link> * stringprep_ucs4_nfkc_normalize (<link linkend="uint32-t">uint32_t</link> *str, - <link linkend="ssize-t">ssize_t</link> len);</programlisting> -<para> -Converts UCS4 string into UTF-8 and runs -<link linkend="stringprep-utf8-nfkc-normalize"><function>stringprep_utf8_nfkc_normalize()</function></link>.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>str</parameter> :</term> -<listitem><simpara> a Unicode string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>len</parameter> :</term> -<listitem><simpara> length of <parameter>str</parameter> array, or -1 if <parameter>str</parameter> is nul-terminated. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> a newly allocated Unicode string, that is the NFKC - normalized form of <parameter>str</parameter>. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-locale-charset" role="function"> -<title>stringprep_locale_charset ()</title> -<indexterm zone="stringprep-locale-charset"><primary sortas="stringprep_locale_charset">stringprep_locale_charset</primary></indexterm><programlisting>const <link linkend="char">char</link> * stringprep_locale_charset (void);</programlisting> -<para> -Find out current locale charset. The function respect the CHARSET -environment variable, but typically uses nl_langinfo(CODESET) when -it is supported. It fall back on "ASCII" if CHARSET isn't set and -nl_langinfo isn't supported or return anything. -</para> -<para> -Note that this function return the application's locale's preferred -charset (or thread's locale's preffered charset, if your system -support thread-specific locales). It does not return what the -system may be using. Thus, if you receive data from external -sources you cannot in general use this function to guess what -charset it is encoded in. Use stringprep_convert from the external -representation into the charset returned by this function, to have -data in the locale encoding.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Return the character set used by the current locale. - It will never return NULL, but use "ASCII" as a fallback. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-convert" role="function"> -<title>stringprep_convert ()</title> -<indexterm zone="stringprep-convert"><primary sortas="stringprep_convert">stringprep_convert</primary></indexterm><programlisting><link linkend="char">char</link> * stringprep_convert (const <link linkend="char">char</link> *str, - const <link linkend="char">char</link> *to_codeset, - const <link linkend="char">char</link> *from_codeset);</programlisting> -<para> -Convert the string from one character set to another using the -system's <link linkend="iconv"><function>iconv()</function></link> function.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>str</parameter> :</term> -<listitem><simpara> input zero-terminated string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>to_codeset</parameter> :</term> -<listitem><simpara> name of destination character set. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>from_codeset</parameter> :</term> -<listitem><simpara> name of origin character set, as used by <parameter>str</parameter>. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns newly allocated zero-terminated string which - is <parameter>str</parameter> transcoded into to_codeset. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-locale-to-utf8" role="function"> -<title>stringprep_locale_to_utf8 ()</title> -<indexterm zone="stringprep-locale-to-utf8"><primary sortas="stringprep_locale_to_utf8">stringprep_locale_to_utf8</primary></indexterm><programlisting><link linkend="char">char</link> * stringprep_locale_to_utf8 (const <link linkend="char">char</link> *str);</programlisting> -<para> -Convert string encoded in the locale's character set into UTF-8 by -using <link linkend="stringprep-convert"><function>stringprep_convert()</function></link>.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>str</parameter> :</term> -<listitem><simpara> input zero terminated string. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns newly allocated zero-terminated string which - is <parameter>str</parameter> transcoded into UTF-8. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="stringprep-utf8-to-locale" role="function"> -<title>stringprep_utf8_to_locale ()</title> -<indexterm zone="stringprep-utf8-to-locale"><primary sortas="stringprep_utf8_to_locale">stringprep_utf8_to_locale</primary></indexterm><programlisting><link linkend="char">char</link> * stringprep_utf8_to_locale (const <link linkend="char">char</link> *str);</programlisting> -<para> -Convert string encoded in UTF-8 into the locale's character set by -using <link linkend="stringprep-convert"><function>stringprep_convert()</function></link>.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>str</parameter> :</term> -<listitem><simpara> input zero terminated string. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns newly allocated zero-terminated string which - is <parameter>str</parameter> transcoded into the locale's character set. -</simpara></listitem></varlistentry> -</variablelist></refsect2> - -</refsect1> - - - - -</refentry> diff --git a/doc/reference/xml/tld.xml b/doc/reference/xml/tld.xml deleted file mode 100644 index 3fc8000..0000000 --- a/doc/reference/xml/tld.xml +++ /dev/null @@ -1,483 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<refentry id="libidn-tld"> -<refmeta> -<refentrytitle role="top_of_page" id="libidn-tld.top_of_page">tld</refentrytitle> -<manvolnum>3</manvolnum> -<refmiscinfo>LIBIDN Library</refmiscinfo> -</refmeta> - -<refnamediv> -<refname>tld</refname> -<refpurpose></refpurpose> -</refnamediv> - -<refsynopsisdiv id="libidn-tld.synopsis" role="synopsis"> -<title role="synopsis.title">Synopsis</title> - -<synopsis> -#define <link linkend="IDNAPI--CAPS">IDNAPI</link> -typedef <link linkend="Tld-table-element">Tld_table_element</link>; -typedef <link linkend="Tld-table">Tld_table</link>; -enum <link linkend="Tld-rc">Tld_rc</link>; -const <link linkend="char">char</link> * <link linkend="tld-strerror">tld_strerror</link> (<link linkend="Tld-rc">Tld_rc</link> rc); -<link linkend="int">int</link> <link linkend="tld-get-4">tld_get_4</link> (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="char">char</link> **out); -<link linkend="int">int</link> <link linkend="tld-get-4z">tld_get_4z</link> (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="char">char</link> **out); -<link linkend="int">int</link> <link linkend="tld-get-z">tld_get_z</link> (const <link linkend="char">char</link> *in, - <link linkend="char">char</link> **out); -const <link linkend="Tld-table">Tld_table</link> * <link linkend="tld-get-table">tld_get_table</link> (const <link linkend="char">char</link> *tld, - const <link linkend="Tld-table">Tld_table</link> **tables); -const <link linkend="Tld-table">Tld_table</link> * <link linkend="tld-default-table">tld_default_table</link> (const <link linkend="char">char</link> *tld, - const <link linkend="Tld-table">Tld_table</link> **overrides); -<link linkend="int">int</link> <link linkend="tld-check-4t">tld_check_4t</link> (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> *tld); -<link linkend="int">int</link> <link linkend="tld-check-4tz">tld_check_4tz</link> (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> *tld); -<link linkend="int">int</link> <link linkend="tld-check-4">tld_check_4</link> (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> **overrides); -<link linkend="int">int</link> <link linkend="tld-check-4z">tld_check_4z</link> (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> **overrides); -<link linkend="int">int</link> <link linkend="tld-check-8z">tld_check_8z</link> (const <link linkend="char">char</link> *in, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> **overrides); -<link linkend="int">int</link> <link linkend="tld-check-lz">tld_check_lz</link> (const <link linkend="char">char</link> *in, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> **overrides); -</synopsis> -</refsynopsisdiv> - - - - - - - - - -<refsect1 id="libidn-tld.description" role="desc"> -<title role="desc.title">Description</title> -<para> -</para> -</refsect1> - -<refsect1 id="libidn-tld.details" role="details"> -<title role="details.title">Details</title> -<refsect2 id="IDNAPI--CAPS" role="macro"> -<title>IDNAPI</title> -<indexterm zone="IDNAPI--CAPS"><primary sortas="IDNAPI">IDNAPI</primary></indexterm><programlisting>#define IDNAPI</programlisting> -<para> -</para></refsect2> -<refsect2 id="Tld-table-element" role="typedef"> -<title>Tld_table_element</title> -<indexterm zone="Tld-table-element"><primary sortas="Tld_table_element">Tld_table_element</primary></indexterm><programlisting> typedef struct Tld_table_element Tld_table_element; -</programlisting> -<para> -</para></refsect2> -<refsect2 id="Tld-table" role="typedef"> -<title>Tld_table</title> -<indexterm zone="Tld-table"><primary sortas="Tld_table">Tld_table</primary></indexterm><programlisting> typedef struct Tld_table Tld_table; -</programlisting> -<para> -</para></refsect2> -<refsect2 id="Tld-rc" role="enum"> -<title>enum Tld_rc</title> -<indexterm zone="Tld-rc"><primary sortas="Tld_rc">Tld_rc</primary></indexterm><programlisting> typedef enum - { - TLD_SUCCESS = 0, - TLD_INVALID = 1, /* Invalid character found. */ - TLD_NODATA = 2, /* Char, domain or inlen = 0. */ - TLD_MALLOC_ERROR = 3, - TLD_ICONV_ERROR = 4, - TLD_NO_TLD = 5, - /* Workaround typo in earlier versions. */ - TLD_NOTLD = TLD_NO_TLD - } Tld_rc; -</programlisting> -<para> -Enumerated return codes of the TLD checking functions. -The value 0 is guaranteed to always correspond to success.</para> -<para> -</para><variablelist role="enum"> -<varlistentry id="TLD-SUCCESS--CAPS" role="constant"> -<term><literal>TLD_SUCCESS</literal></term> -<listitem><simpara> Successful operation. This value is guaranteed to - always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -</simpara></listitem> -</varlistentry> -<varlistentry id="TLD-INVALID--CAPS" role="constant"> -<term><literal>TLD_INVALID</literal></term> -<listitem><simpara> Invalid character found. -</simpara></listitem> -</varlistentry> -<varlistentry id="TLD-NODATA--CAPS" role="constant"> -<term><literal>TLD_NODATA</literal></term> -<listitem><simpara> No input data was provided. -</simpara></listitem> -</varlistentry> -<varlistentry id="TLD-MALLOC-ERROR--CAPS" role="constant"> -<term><literal>TLD_MALLOC_ERROR</literal></term> -<listitem><simpara> Error during memory allocation. -</simpara></listitem> -</varlistentry> -<varlistentry id="TLD-ICONV-ERROR--CAPS" role="constant"> -<term><literal>TLD_ICONV_ERROR</literal></term> -<listitem><simpara> Error during iconv string conversion. -</simpara></listitem> -</varlistentry> -<varlistentry id="TLD-NO-TLD--CAPS" role="constant"> -<term><literal>TLD_NO_TLD</literal></term> -<listitem><simpara> No top-level domain found in domain string. -</simpara></listitem> -</varlistentry> -<varlistentry id="TLD-NOTLD--CAPS" role="constant"> -<term><literal>TLD_NOTLD</literal></term> -<listitem><simpara> -</simpara></listitem> -</varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-strerror" role="function"> -<title>tld_strerror ()</title> -<indexterm zone="tld-strerror"><primary sortas="tld_strerror">tld_strerror</primary></indexterm><programlisting>const <link linkend="char">char</link> * tld_strerror (<link linkend="Tld-rc">Tld_rc</link> rc);</programlisting> -<para> -Convert a return code integer to a text string. This string can be -used to output a diagnostic message to the user. -</para> -<para> -TLD_SUCCESS: Successful operation. This value is guaranteed to - always be zero, the remaining ones are only guaranteed to hold - non-zero values, for logical comparison purposes. -TLD_INVALID: Invalid character found. -TLD_NODATA: No input data was provided. -TLD_MALLOC_ERROR: Error during memory allocation. -TLD_ICONV_ERROR: Error during iconv string conversion. -TLD_NO_TLD: No top-level domain found in domain string.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>rc</parameter> :</term> -<listitem><simpara> tld return code -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns a pointer to a statically allocated string -containing a description of the error with the return code <parameter>rc</parameter>. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-get-4" role="function"> -<title>tld_get_4 ()</title> -<indexterm zone="tld-get-4"><primary sortas="tld_get_4">tld_get_4</primary></indexterm><programlisting><link linkend="int">int</link> tld_get_4 (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="char">char</link> **out);</programlisting> -<para> -Isolate the top-level domain of <parameter>in</parameter> and return it as an ASCII -string in <parameter>out</parameter>.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> Array of unicode code points to process. Does not need to be - zero terminated. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>inlen</parameter> :</term> -<listitem><simpara> Number of unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>out</parameter> :</term> -<listitem><simpara> Zero terminated ascii result string pointer. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Return <link linkend="TLD-SUCCESS--CAPS"><literal>TLD_SUCCESS</literal></link> on success, or the corresponding - <link linkend="Tld-rc"><type>Tld_rc</type></link> error code otherwise. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-get-4z" role="function"> -<title>tld_get_4z ()</title> -<indexterm zone="tld-get-4z"><primary sortas="tld_get_4z">tld_get_4z</primary></indexterm><programlisting><link linkend="int">int</link> tld_get_4z (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="char">char</link> **out);</programlisting> -<para> -Isolate the top-level domain of <parameter>in</parameter> and return it as an ASCII -string in <parameter>out</parameter>.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> Zero terminated array of unicode code points to process. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>out</parameter> :</term> -<listitem><simpara> Zero terminated ascii result string pointer. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Return <link linkend="TLD-SUCCESS--CAPS"><literal>TLD_SUCCESS</literal></link> on success, or the corresponding - <link linkend="Tld-rc"><type>Tld_rc</type></link> error code otherwise. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-get-z" role="function"> -<title>tld_get_z ()</title> -<indexterm zone="tld-get-z"><primary sortas="tld_get_z">tld_get_z</primary></indexterm><programlisting><link linkend="int">int</link> tld_get_z (const <link linkend="char">char</link> *in, - <link linkend="char">char</link> **out);</programlisting> -<para> -Isolate the top-level domain of <parameter>in</parameter> and return it as an ASCII -string in <parameter>out</parameter>. The input string <parameter>in</parameter> may be UTF-8, ISO-8859-1 or -any ASCII compatible character encoding.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> Zero terminated character array to process. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>out</parameter> :</term> -<listitem><simpara> Zero terminated ascii result string pointer. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Return <link linkend="TLD-SUCCESS--CAPS"><literal>TLD_SUCCESS</literal></link> on success, or the corresponding - <link linkend="Tld-rc"><type>Tld_rc</type></link> error code otherwise. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-get-table" role="function"> -<title>tld_get_table ()</title> -<indexterm zone="tld-get-table"><primary sortas="tld_get_table">tld_get_table</primary></indexterm><programlisting>const <link linkend="Tld-table">Tld_table</link> * tld_get_table (const <link linkend="char">char</link> *tld, - const <link linkend="Tld-table">Tld_table</link> **tables);</programlisting> -<para> -Get the TLD table for a named TLD by searching through the given -TLD table array.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>tld</parameter> :</term> -<listitem><simpara> TLD name (e.g. "com") as zero terminated ASCII byte string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>tables</parameter> :</term> -<listitem><simpara> Zero terminated array of <link linkend="Tld-table"><type>Tld_table</type></link> info-structures for - TLDs. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Return structure corresponding to TLD <parameter>tld</parameter> by going - thru <parameter>tables</parameter>, or return <link linkend="NULL--CAPS"><literal>NULL</literal></link> if no such structure is found. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-default-table" role="function"> -<title>tld_default_table ()</title> -<indexterm zone="tld-default-table"><primary sortas="tld_default_table">tld_default_table</primary></indexterm><programlisting>const <link linkend="Tld-table">Tld_table</link> * tld_default_table (const <link linkend="char">char</link> *tld, - const <link linkend="Tld-table">Tld_table</link> **overrides);</programlisting> -<para> -Get the TLD table for a named TLD, using the internal defaults, -possibly overrided by the (optional) supplied tables.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>tld</parameter> :</term> -<listitem><simpara> TLD name (e.g. "com") as zero terminated ASCII byte string. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>overrides</parameter> :</term> -<listitem><simpara> Additional zero terminated array of <link linkend="Tld-table"><type>Tld_table</type></link> - info-structures for TLDs, or <link linkend="NULL--CAPS"><literal>NULL</literal></link> to only use library deault - tables. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Return structure corresponding to TLD <parameter>tld_str</parameter>, first - looking through <parameter>overrides</parameter> then thru built-in list, or <link linkend="NULL--CAPS"><literal>NULL</literal></link> if - no such structure found. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-check-4t" role="function"> -<title>tld_check_4t ()</title> -<indexterm zone="tld-check-4t"><primary sortas="tld_check_4t">tld_check_4t</primary></indexterm><programlisting><link linkend="int">int</link> tld_check_4t (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> *tld);</programlisting> -<para> -Test each of the code points in <parameter>in</parameter> for whether or not -they are allowed by the data structure in <parameter>tld</parameter>, return -the position of the first character for which this is not -the case in <parameter>errpos</parameter>.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> Array of unicode code points to process. Does not need to be - zero terminated. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>inlen</parameter> :</term> -<listitem><simpara> Number of unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>errpos</parameter> :</term> -<listitem><simpara> Position of offending character is returned here. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>tld</parameter> :</term> -<listitem><simpara> A <link linkend="Tld-table"><type>Tld_table</type></link> data structure representing the restrictions for - which the input should be tested. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns the <link linkend="Tld-rc"><type>Tld_rc</type></link> value <link linkend="TLD-SUCCESS--CAPS"><literal>TLD_SUCCESS</literal></link> if all code - points are valid or when <parameter>tld</parameter> is null, <link linkend="TLD-INVALID--CAPS"><literal>TLD_INVALID</literal></link> if a - character is not allowed, or additional error codes on general - failure conditions. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-check-4tz" role="function"> -<title>tld_check_4tz ()</title> -<indexterm zone="tld-check-4tz"><primary sortas="tld_check_4tz">tld_check_4tz</primary></indexterm><programlisting><link linkend="int">int</link> tld_check_4tz (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> *tld);</programlisting> -<para> -Test each of the code points in <parameter>in</parameter> for whether or not -they are allowed by the data structure in <parameter>tld</parameter>, return -the position of the first character for which this is not -the case in <parameter>errpos</parameter>.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> Zero terminated array of unicode code points to process. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>errpos</parameter> :</term> -<listitem><simpara> Position of offending character is returned here. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>tld</parameter> :</term> -<listitem><simpara> A <link linkend="Tld-table"><type>Tld_table</type></link> data structure representing the restrictions for - which the input should be tested. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns the <link linkend="Tld-rc"><type>Tld_rc</type></link> value <link linkend="TLD-SUCCESS--CAPS"><literal>TLD_SUCCESS</literal></link> if all code - points are valid or when <parameter>tld</parameter> is null, <link linkend="TLD-INVALID--CAPS"><literal>TLD_INVALID</literal></link> if a - character is not allowed, or additional error codes on general - failure conditions. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-check-4" role="function"> -<title>tld_check_4 ()</title> -<indexterm zone="tld-check-4"><primary sortas="tld_check_4">tld_check_4</primary></indexterm><programlisting><link linkend="int">int</link> tld_check_4 (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> inlen, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> **overrides);</programlisting> -<para> -Test each of the code points in <parameter>in</parameter> for whether or not they are -allowed by the information in <parameter>overrides</parameter> or by the built-in TLD -restriction data. When data for the same TLD is available both -internally and in <parameter>overrides</parameter>, the information in <parameter>overrides</parameter> takes -precedence. If several entries for a specific TLD are found, the -first one is used. If <parameter>overrides</parameter> is <link linkend="NULL--CAPS"><literal>NULL</literal></link>, only the built-in -information is used. The position of the first offending character -is returned in <parameter>errpos</parameter>.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> Array of unicode code points to process. Does not need to be - zero terminated. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>inlen</parameter> :</term> -<listitem><simpara> Number of unicode code points. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>errpos</parameter> :</term> -<listitem><simpara> Position of offending character is returned here. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>overrides</parameter> :</term> -<listitem><simpara> A <link linkend="Tld-table"><type>Tld_table</type></link> array of additional domain restriction - structures that complement and supersede the built-in information. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns the <link linkend="Tld-rc"><type>Tld_rc</type></link> value <link linkend="TLD-SUCCESS--CAPS"><literal>TLD_SUCCESS</literal></link> if all code - points are valid or when <parameter>tld</parameter> is null, <link linkend="TLD-INVALID--CAPS"><literal>TLD_INVALID</literal></link> if a - character is not allowed, or additional error codes on general - failure conditions. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-check-4z" role="function"> -<title>tld_check_4z ()</title> -<indexterm zone="tld-check-4z"><primary sortas="tld_check_4z">tld_check_4z</primary></indexterm><programlisting><link linkend="int">int</link> tld_check_4z (const <link linkend="uint32-t">uint32_t</link> *in, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> **overrides);</programlisting> -<para> -Test each of the code points in <parameter>in</parameter> for whether or not they are -allowed by the information in <parameter>overrides</parameter> or by the built-in TLD -restriction data. When data for the same TLD is available both -internally and in <parameter>overrides</parameter>, the information in <parameter>overrides</parameter> takes -precedence. If several entries for a specific TLD are found, the -first one is used. If <parameter>overrides</parameter> is <link linkend="NULL--CAPS"><literal>NULL</literal></link>, only the built-in -information is used. The position of the first offending character -is returned in <parameter>errpos</parameter>.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> Zero-terminated array of unicode code points to process. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>errpos</parameter> :</term> -<listitem><simpara> Position of offending character is returned here. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>overrides</parameter> :</term> -<listitem><simpara> A <link linkend="Tld-table"><type>Tld_table</type></link> array of additional domain restriction - structures that complement and supersede the built-in information. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns the <link linkend="Tld-rc"><type>Tld_rc</type></link> value <link linkend="TLD-SUCCESS--CAPS"><literal>TLD_SUCCESS</literal></link> if all code - points are valid or when <parameter>tld</parameter> is null, <link linkend="TLD-INVALID--CAPS"><literal>TLD_INVALID</literal></link> if a - character is not allowed, or additional error codes on general - failure conditions. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-check-8z" role="function"> -<title>tld_check_8z ()</title> -<indexterm zone="tld-check-8z"><primary sortas="tld_check_8z">tld_check_8z</primary></indexterm><programlisting><link linkend="int">int</link> tld_check_8z (const <link linkend="char">char</link> *in, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> **overrides);</programlisting> -<para> -Test each of the characters in <parameter>in</parameter> for whether or not they are -allowed by the information in <parameter>overrides</parameter> or by the built-in TLD -restriction data. When data for the same TLD is available both -internally and in <parameter>overrides</parameter>, the information in <parameter>overrides</parameter> takes -precedence. If several entries for a specific TLD are found, the -first one is used. If <parameter>overrides</parameter> is <link linkend="NULL--CAPS"><literal>NULL</literal></link>, only the built-in -information is used. The position of the first offending character -is returned in <parameter>errpos</parameter>. Note that the error position refers to the -decoded character offset rather than the byte position in the -string.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> Zero-terminated UTF8 string to process. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>errpos</parameter> :</term> -<listitem><simpara> Position of offending character is returned here. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>overrides</parameter> :</term> -<listitem><simpara> A <link linkend="Tld-table"><type>Tld_table</type></link> array of additional domain restriction - structures that complement and supersede the built-in information. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns the <link linkend="Tld-rc"><type>Tld_rc</type></link> value <link linkend="TLD-SUCCESS--CAPS"><literal>TLD_SUCCESS</literal></link> if all - characters are valid or when <parameter>tld</parameter> is null, <link linkend="TLD-INVALID--CAPS"><literal>TLD_INVALID</literal></link> if a - character is not allowed, or additional error codes on general - failure conditions. -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="tld-check-lz" role="function"> -<title>tld_check_lz ()</title> -<indexterm zone="tld-check-lz"><primary sortas="tld_check_lz">tld_check_lz</primary></indexterm><programlisting><link linkend="int">int</link> tld_check_lz (const <link linkend="char">char</link> *in, - <link linkend="size-t">size_t</link> *errpos, - const <link linkend="Tld-table">Tld_table</link> **overrides);</programlisting> -<para> -Test each of the characters in <parameter>in</parameter> for whether or not they are -allowed by the information in <parameter>overrides</parameter> or by the built-in TLD -restriction data. When data for the same TLD is available both -internally and in <parameter>overrides</parameter>, the information in <parameter>overrides</parameter> takes -precedence. If several entries for a specific TLD are found, the -first one is used. If <parameter>overrides</parameter> is <link linkend="NULL--CAPS"><literal>NULL</literal></link>, only the built-in -information is used. The position of the first offending character -is returned in <parameter>errpos</parameter>. Note that the error position refers to the -decoded character offset rather than the byte position in the -string.</para> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>in</parameter> :</term> -<listitem><simpara> Zero-terminated string in the current locales encoding to process. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>errpos</parameter> :</term> -<listitem><simpara> Position of offending character is returned here. -</simpara></listitem></varlistentry> -<varlistentry><term><parameter>overrides</parameter> :</term> -<listitem><simpara> A <link linkend="Tld-table"><type>Tld_table</type></link> array of additional domain restriction - structures that complement and supersede the built-in information. -</simpara></listitem></varlistentry> -<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> Returns the <link linkend="Tld-rc"><type>Tld_rc</type></link> value <link linkend="TLD-SUCCESS--CAPS"><literal>TLD_SUCCESS</literal></link> if all - characters are valid or when <parameter>tld</parameter> is null, <link linkend="TLD-INVALID--CAPS"><literal>TLD_INVALID</literal></link> if a - character is not allowed, or additional error codes on general - failure conditions. -</simpara></listitem></varlistentry> -</variablelist></refsect2> - -</refsect1> - - - - -</refentry> diff --git a/doc/reference/xml/verify.xml b/doc/reference/xml/verify.xml deleted file mode 100644 index 55b9819..0000000 --- a/doc/reference/xml/verify.xml +++ /dev/null @@ -1,66 +0,0 @@ -<?xml version="1.0"?> -<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" - "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> -<refentry id="libidn-verify"> -<refmeta> -<refentrytitle role="top_of_page" id="libidn-verify.top_of_page">verify</refentrytitle> -<manvolnum>3</manvolnum> -<refmiscinfo>LIBIDN Library</refmiscinfo> -</refmeta> - -<refnamediv> -<refname>verify</refname> -<refpurpose></refpurpose> -</refnamediv> - -<refsynopsisdiv id="libidn-verify.synopsis" role="synopsis"> -<title role="synopsis.title">Synopsis</title> - -<synopsis> -#define <link linkend="verify-true">verify_true</link> (R) -#define <link linkend="verify">verify</link> (R) -</synopsis> -</refsynopsisdiv> - - - - - - - - - -<refsect1 id="libidn-verify.description" role="desc"> -<title role="desc.title">Description</title> -<para> -</para> -</refsect1> - -<refsect1 id="libidn-verify.details" role="details"> -<title role="details.title">Details</title> -<refsect2 id="verify-true" role="macro"> -<title>verify_true()</title> -<indexterm zone="verify-true"><primary sortas="verify_true">verify_true</primary></indexterm><programlisting>#define verify_true(R)</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>R</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> -<refsect2 id="verify" role="macro"> -<title>verify()</title> -<indexterm zone="verify"><primary sortas="verify">verify</primary></indexterm><programlisting># define verify(R) extern int (* verify_function__ (void)) [verify_true (R)] -</programlisting> -<para> -</para><variablelist role="params"> -<varlistentry><term><parameter>R</parameter> :</term> -<listitem><simpara> -</simpara></listitem></varlistentry> -</variablelist></refsect2> - -</refsect1> - - - - -</refentry> |