<?xml version="1.0" encoding="UTF-8"?><api:function-page xml:base="/apidoc/8.0/spell.doubleMetaphone.xml" generated="2015-10-07T16:36:00.016766-07:00" mode="javascript" xmlns:api="http://marklogic.com/rundmc/api"><api:function-name>spell.doubleMetaphone</api:function-name><api:suggest>spell.doublemetaphone</api:suggest><api:suggest>spell</api:suggest><api:suggest>doublemetaphone</api:suggest><api:function-link mode="xquery" fullname="spell:double-metaphone">/apidoc/8.0/spell:double-metaphone.xml</api:function-link><api:function mode="javascript" name="doubleMetaphone" type="builtin" lib="spell" category="SpellBuiltins" hidden="false" bucket="MarkLogic Built-In Functions" prefix="spell" namespace="http://marklogic.com/xdmp/spell" fullname="spell.doubleMetaphone"><api:summary>
  Given a word returns the two metaphone keys.
  The primary and secondary metaphone keys which represent
  the phonetic encoding of two words
  are returned as a sequence of two strings.  Double metaphone is an algorithm
  based on phonetic sounds useful in providing data to spelling correction
  suggestions.
</api:summary><api:params><api:param name="word" type="xs:string"><api:param-description>
    The word for phonetic matching.
  </api:param-description><api:param-name>word</api:param-name><api:param-type>String</api:param-type></api:param></api:params><api:return>ValueIterator</api:return><api:usage>
   The <code xmlns="http://www.w3.org/1999/xhtml">spell:double-metaphone</code> function is a built-in function and
   does not require the <code xmlns="http://www.w3.org/1999/xhtml">import module</code> statement in the XQuery
   prolog.
</api:usage><api:example class="javascript"><pre xml:space="preserve" xmlns="http://www.w3.org/1999/xhtml">
spell.doubleMetaphone("smith");
  
=&gt; smo xmt
</pre></api:example><api:example class="javascript"><pre xml:space="preserve" xmlns="http://www.w3.org/1999/xhtml">
spell.doubleMetaphone("jones");
  
=&gt; jns ans
</pre></api:example></api:function></api:function-page>