<refentry id="streamtuner-st-sgml-ref-api">
<refmeta>
<refentrytitle>st-sgml-ref</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>STREAMTUNER Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>st-sgml-ref</refname><refpurpose>functions for expanding SGML character references.</refpurpose>
</refnamediv>

<refsynopsisdiv><title>Synopsis</title>

<synopsis>



<link linkend="char">char</link>*       <link linkend="st-sgml-ref-expand">st_sgml_ref_expand</link>              (const <link linkend="char">char</link> *str);
<link linkend="char">char</link>*       <link linkend="st-sgml-ref-expand-len">st_sgml_ref_expand_len</link>          (const <link linkend="char">char</link> *str,
                                             <link linkend="int">int</link> len);
</synopsis>
</refsynopsisdiv>









<refsect1>
<title>Description</title>
<para>

</para>
</refsect1>

<refsect1>
<title>Details</title>
<refsect2>
<title><anchor id="st-sgml-ref-expand"/>st_sgml_ref_expand ()</title>
<indexterm><primary>st_sgml_ref_expand</primary></indexterm><programlisting><link linkend="char">char</link>*       st_sgml_ref_expand              (const <link linkend="char">char</link> *str);</programlisting>
<para>
Parses <parameter>str</parameter>, expanding its SGML character references and XHTML
character entities. See <link linkend="st-sgml-ref-expand-len"><function>st_sgml_ref_expand_len()</function></link>.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>str</parameter>&nbsp;:</term>
<listitem><simpara> the nul-terminated string to parse.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> the expansion of <parameter>str</parameter>. The string should be freed
when no longer needed.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="st-sgml-ref-expand-len"/>st_sgml_ref_expand_len ()</title>
<indexterm><primary>st_sgml_ref_expand_len</primary></indexterm><programlisting><link linkend="char">char</link>*       st_sgml_ref_expand_len          (const <link linkend="char">char</link> *str,
                                             <link linkend="int">int</link> len);</programlisting>
<para>
Parses <parameter>str</parameter>, expanding its SGML character references and XHTML
character entities.
</para>
<para>
Numerical SGML character references as well as XHTML entities are
supported. Unsupported entities will be inserted verbatim into the
result.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>str</parameter>&nbsp;:</term>
<listitem><simpara> the string to parse.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>len</parameter>&nbsp;:</term>
<listitem><simpara> the length of <parameter>str</parameter>, or -1 if <parameter>str</parameter> is nul-terminated.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> the expansion of <parameter>str</parameter>. The string should be freed
when no longer needed.
</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>




</refentry>
