| 1 | |
| 2 | <refentry id="strindexk"> |
| 3 | <indexterm id="Indexstrindexk"><primary>strindexk</primary></indexterm> |
| 4 | <refentryinfo><title>Strings:Manipulation</title></refentryinfo> |
| 5 | <refmeta> |
| 6 | <refentrytitle>strindexk</refentrytitle> |
| 7 | </refmeta> |
| 8 | |
| 9 | |
| 10 | |
| 11 | <refnamediv> |
| 12 | <refname>strindexk</refname> |
| 13 | <refpurpose> |
| 14 | Return the position of the first occurence of a string in another string |
| 15 | </refpurpose> |
| 16 | </refnamediv> |
| 17 | |
| 18 | <refsect1> |
| 19 | <title>Description</title> |
| 20 | <para> |
| 21 | Return the position of the first occurence of S2 in S1, or -1 if not |
| 22 | found. If S2 is empty, 0 is returned. strindexk runs both at init and |
| 23 | performance time. |
| 24 | </para> |
| 25 | </refsect1> |
| 26 | |
| 27 | <refsect1> |
| 28 | <title>Syntax</title> |
| 29 | <synopsis>kpos <command>strindexk</command> S1, S2</synopsis> |
| 30 | </refsect1> |
| 31 | |
| 32 | <refsect1> |
| 33 | <title>Examples</title> |
| 34 | <para> |
| 35 | Here is an example of the strindexk opcode. It uses the file <ulink url="examples/strindexk.csd"><citetitle>strindexk.csd</citetitle></ulink>. |
| 36 | <example> |
| 37 | <title>Example of the strindexk opcode.</title> |
| 38 | <para>See the sections <link linkend="UsingRealTime"><citetitle>Real-time Audio</citetitle></link> and <link linkend="CommandFlags"><citetitle>Command Line Flags</citetitle></link> for more information on using command line flags.</para> |
| 39 | <xi:include href="examples-xml/strindexk.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> |
| 40 | </example> |
| 41 | </para> |
| 42 | </refsect1> |
| 43 | |
| 44 | <refsect1> |
| 45 | <title>See Also</title> |
| 46 | <para><link linkend="stringmanipulate"><citetitle></citetitle>String Manipulation Opcodes</link></para> |
| 47 | </refsect1> |
| 48 | |
| 49 | <refsect1> |
| 50 | <title>Credits</title> |
| 51 | <para> |
| 52 | <simplelist> |
| 53 | <member>Author: Istvan Varga</member> |
| 54 | <member>2006</member> |
| 55 | </simplelist> |
| 56 | </para> |
| 57 | <para>New in version 5.02</para> |
| 58 | </refsect1> |
| 59 | </refentry> |