<?xml version="1.0" ?>
<node name="/Account_Manager_Interface_Query" xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0">
  <tp:copyright>Copyright (C) 2008 Nokia Corporation</tp:copyright>
  <tp:license xmlns="http://www.w3.org/1999/xhtml">
    <p>This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.</p>

<p>This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Lesser General Public License for more details.</p>

<p>You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.</p>
  </tp:license>
  <interface name="com.nokia.AccountManager.Interface.Query">
    <tp:requires interface="org.freedesktop.Telepathy.AccountManager"/>
    <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
      <p>The Query interface provides a convienient way for clients to retrieve
      a subset of the accounts satisfying certain conditions.</p>

      <tp:rationale>
        <p>This is basically the same API proposed by Zdra</p>
      </tp:rationale>
    </tp:docstring>

    <method name="FindAccounts"
      tp:name-for-bindings="Find_Accounts">
      <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
        <p>Find all accounts which match the search query.</p>
        <p>An empty parameter should return all accounts</p>
      </tp:docstring>

      <arg direction="in" name="params" type="a{sv}" tp:type="String_Variant_Map">
        <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
          <p>The search query data. The keys can be any Connection Manager
          parameter (in which case they must be prepended with the string
          "param-"), any readable Account property (in the form
          <code>Interface.PropertyName</code>) or any of these special
          keys:</p>
          <ul>
            <li>s: Manager</li>
            <li>s: Protocol</li>
            <li>u: RequestedPresence</li>
            <li>s: RequestedStatus</li>
            <li>u: CurrentPresence</li>
            <li>s: CurrentStatus</li>
          </ul>
        </tp:docstring>
      </arg>
      <arg direction="out" name="accounts" type="ao">
        <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
          The array of account objects.
        </tp:docstring>
      </arg>
    </method>

    <property name="Keywords" type="as" access="read">
      <tp:docstring>
        A list of the special keywords recognized by the FindAccounts method.
        <tp:rationale>
          <p>It's likely that some new keywords will be added later, or that
          different implementation of this interface will support a different
          set of keywords; in such a scenario it seems proper to inform the
          client about supported keywords.</p>
          <p>But I'm not sure this is really needed.</p>
        </tp:rationale>
      </tp:docstring>
    </property>
  </interface>
</node>
<!-- vim:set sw=2 sts=2 et ft=xml: -->
