<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE section PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" 
   "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">

<section id="msilo.functions" xmlns:xi="http://www.w3.org/2001/XInclude">
    <sectioninfo>
    </sectioninfo>

    <title>Functions</title>

    <section id="m_store">
	<title><function>m_store(mode, next_hop)</function></title>
	<para>
	    The method stores certain parts of the current SIP request (it
	    should be called when the request type is MESSAGE and the
	    destination user is offline or his UA does not support MESSAGE
	    requests). If the user is registered with a UA which does not
	    support MESSAGE requests you should not use mode="0"
	    if you have changed the request uri with the contact address of
	    user's UA.
	</para>
	<para>Meaning of the parameters is as follows:</para>
	<itemizedlist>
	    <listitem>
		<para>
		    <emphasis>mode</emphasis> - specifies what to save as R-URI.
		</para>
		<itemizedlist>
		    <listitem>
			<para>
			    "0" - first check if new_uri is an address of
			    record. If yes, then use it and store it as R-URI, otherwise look at
			    R-URI and, if necessary, at URI from "To" header.
			</para>
		    </listitem>
		    <listitem>
			<para>
			    "1" - look first at R-URI and then at URI from
			    "To" header.
			</para>
		    </listitem>
		    <listitem>
			<para>
			    "2" - look only at URI form "To" header.
			</para>
		    </listitem>
		</itemizedlist>
	    </listitem>
	    <listitem>
		<para>
		    <emphasis>next_hop (optional)</emphasis> - specifies next hop for sending
			outgoing messages (use as "outbound
			proxy"). Its value can be unset, empty or set to a sip URI like
			"sip:127.0.0.1:5060".
		</para>
	    </listitem>
	</itemizedlist>
    </section>
    
    <section id="m_dump">
	<title><function>m_dump(next_hop)</function></title>
	<para>
	    The method sends stored messages for the SIP user that is going to
	    register to his actual contact address. The method should be called
	    when a REGISTER request is received and the "Expire" header has a
	    value greater than zero. The parameter can contain machine used as
		"outbound proxy" or can be empty.
	</para>
	<para>Meaning of the parameters is as follows:</para>
	<itemizedlist>
	    <listitem>
		<para>
		    <emphasis>next_hop (optional)</emphasis> - specifies next hop for sending
			outgoing messages (use as "outbound
			proxy"). Its value can be unset, empty or set to a sip URI like
			"sip:127.0.0.1:5060".
		</para>
	    </listitem>
	</itemizedlist>
    </section>
    
</section>
