%i_isreal() %i_real() %i_imag() added
[scilab.git] / scilab / modules / data_structures / help / en_US / types / typename.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:lang="en" xml:id="typename">
3     <refnamediv>
4         <refname>typename</refname>
5         <refpurpose>associates a name to variable type</refpurpose>
6     </refnamediv>
7     <refsynopsisdiv>
8         <title>Syntax</title>
9         <synopsis>[types [ [,names]]=typename()
10         </synopsis>
11     </refsynopsisdiv>
12     <refsection>
13         <title>Arguments</title>
14         <variablelist>
15             <varlistentry>
16                 <term>types</term>
17                 <listitem>
18                     <para>an integer column vector: the types codes of each defined data types.</para>
19                 </listitem>
20             </varlistentry>
21             <varlistentry>
22                 <term>names</term>
23                 <listitem>
24                     <para>a column vector of strings: the names associated to type codes.</para>
25                 </listitem>
26             </varlistentry>
27         </variablelist>
28     </refsection>
29     <refsection>
30         <title>Description</title>
31         <para>
32             The function and operator overloading make use of a formal name
33             associated to data types to form the name of the overloading function
34             (see <link linkend="overloading">overloading</link>). The <function>typename</function> can be used to handle this
35             formal names for hard coded data types (the <literal>tlist</literal> or <literal>mlist</literal>
36             coded data types formal names are defined in another way, see <link linkend="overloading">overloading</link>).
37         </para>
38         <para>
39             <function>typename</function> returns information on defined data types.
40         </para>
41     </refsection>
42     <refsection>
43         <title>Examples</title>
44         <programlisting role="example"><![CDATA[
45 [typs,nams]=typename();
46 disp("First type (double) : " + string(typs(1)) + " / " + nams(1));
47 ]]></programlisting>
48     </refsection>
49
50     <refsection role="see also">
51         <title>See also</title>
52         <simplelist type="inline">
53             <member>
54                 <link linkend="type">type</link>
55             </member>
56             <member>
57                 <link linkend="typeof">typeof</link>
58             </member>
59             <member>
60                 <link linkend="overloading">overloading</link>
61             </member>
62             <member>
63                 <link linkend="tlist">tlist</link>
64             </member>
65             <member>
66                 <link linkend="mlist">mlist</link>
67             </member>
68         </simplelist>
69     </refsection>
70 </refentry>