<?xml version="1.0" encoding="UTF-8"?>

<node name="/org/freedesktop/Tracker">
  <interface name="org.freedesktop.Tracker.Metadata">

    <!-- Retrieves an array of metadata values for the specified array
	 of metadata keys for a service and id pair.
      --> 
    <method name="Get">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/> 
      <arg type="s" name="service_type" direction="in" />
      <arg type="s" name="uri" direction="in" />
      <arg type="as" name="keys" direction="in" />
      <arg type="as" name="metadata" direction="out" />
    </method>
    
    <!-- Retrieves all known metadata of the service/uri in an array of
	 key,value
    -->
    <method name="GetAll">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/> 
      <arg type="s" name="service_type" direction="in" />
      <arg type="s" name="uri" direction="in" />
      <arg type="aas" name="metadata" direction="out" />
    </method>

    <!-- Retrieves an array of metadata values for the specified array
	 of metadata keys for services and id pair.
      --> 
    <method name="GetMultiple">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/> 
      <arg type="s" name="service_type" direction="in" />
      <arg type="as" name="uris" direction="in" />
      <arg type="as" name="keys" direction="in" />
      <arg type="aas" name="metadata" direction="out" />
    </method>
    
    <!-- Sets specified metadata keys to the specified metadata values
	 for a service and id pair.
      -->
    <method name="Set">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/> 
      <arg type="s" name="service_type" direction="in" />
      <arg type="s" name="uri" direction="in" />
      <arg type="as" name="keys" direction="in" />
      <arg type="as" name="metadata" direction="in" />
    </method>
       
    <!-- Gets all details of a named metadata type (e.g. "Video:FrameRate" or "Audio:Title"). 
	 data_type: keyword, index, fulltext, string, integer, dobule, date, blob, struct, link
    -->		
    <method name="GetTypeDetails">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/> 
      <arg type="s" name="metadata" direction="in" />
      <arg type="s" name="data_type" direction="out" />
      <arg type="b" name="is_embedded" direction="out" />
      <arg type="b" name="is_writable" direction="out" />
    </method>
    
    <!-- Returns an array of all metadata types that are registered
	 for a certain service type. You can enter "*" as the service type to get all
	 registered metadata types .
      --> 
    <method name="GetRegisteredTypes">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/> 
      <arg type="s" name="service_type" direction="in" />
      <arg type="as" name="result" direction="out" />
    </method>
       
    <!-- Returns an array of all service types that are registered.
      -->
    <method name="GetRegisteredClasses">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
      <arg type="as" name="result" direction="out" />
    </method>

    <!-- returns an array of all unique values of given metadata types. Optionally a rdf query can be
	 used to filter the results. The results are sorted based on the metadata fields either in
	 ascending or descending order. 
      -->
    <method name="GetUniqueValues">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
      <arg type="s" name="service" direction="in" />
      <arg type="as" name="meta_types" direction="in" />
      <arg type="s" name="query" direction="in" />
      <arg type="b" name="descending" direction="in" />
      <arg type="i" name="offset" direction="in" />
      <arg type="i" name="max_hits" direction="in" />
      <arg type="aas" name="result" direction="out" />
    </method>

    <method name="GetSum">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
      <arg type="s" name="service" direction="in" />
      <arg type="s" name="field" direction="in" />
      <arg type="s" name="query" direction="in" />
      <arg type="i" name="result" direction="out" />
    </method>

    <method name="GetCount">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
      <arg type="s" name="service" direction="in" />
      <arg type="s" name="field" direction="in" />
      <arg type="s" name="query" direction="in" />
      <arg type="i" name="result" direction="out" />
    </method>

    <method name="GetUniqueValuesWithCount">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
      <arg type="s" name="service" direction="in" />
      <arg type="as" name="meta_types" direction="in" />
      <arg type="s" name="query" direction="in" />
      <arg type="s" name="count_field" direction="in" />
      <arg type="b" name="descending" direction="in" />
      <arg type="i" name="offset" direction="in" />
      <arg type="i" name="max_hits" direction="in" />
      <arg type="aas" name="result" direction="out" />
    </method>

    <method name="GetUniqueValuesWithCountAndSum">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
      <arg type="s" name="service" direction="in" />
      <arg type="as" name="meta_types" direction="in" />
      <arg type="s" name="query" direction="in" />
      <arg type="s" name="count_field" direction="in" />
      <arg type="s" name="sum_field" direction="in" />
      <arg type="b" name="descending" direction="in" />
      <arg type="i" name="offset" direction="in" />
      <arg type="i" name="max_hits" direction="in" />
      <arg type="aas" name="result" direction="out" />
    </method>

    <method name="GetUniqueValuesWithConcatCountAndSum">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
      <arg type="s" name="service" direction="in" />
      <arg type="as" name="meta_types" direction="in" />
      <arg type="s" name="query" direction="in" />
      <arg type="s" name="concat_field" direction="in" />
      <arg type="s" name="count_field" direction="in" />
      <arg type="s" name="sum_field" direction="in" />
      <arg type="b" name="descending" direction="in" />
      <arg type="i" name="offset" direction="in" />
      <arg type="i" name="max_hits" direction="in" />
      <arg type="aas" name="result" direction="out" />
    </method>

    <method name="GetUniqueValuesWithAggregates">
      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
      <arg type="s" name="service" direction="in" />
      <arg type="as" name="meta_types" direction="in" />
      <arg type="s" name="query" direction="in" />
      <arg type="as" name="aggregates" direction="in" />
      <arg type="as" name="aggregate_fields" direction="in" />
      <arg type="b" name="descending" direction="in" />
      <arg type="i" name="offset" direction="in" />
      <arg type="i" name="max_hits" direction="in" />
      <arg type="aas" name="result" direction="out" />
    </method>

  </interface>
</node>
