Development/Tutorials/Metadata/Nepomuk/QueryService

From KDE TechBase
Nepomuk Query Service
Tutorial Series   Nepomuk
Previous   Strigi Service
What's Next  
Further Reading   Nepomuk Services, Nepomuk Server

Nepomuk Query Service

The Query service provides a D-Bus interfaces named org.kde.nepomuk.QueryService which is exported at nepomukqueryservice. This interface allows to issue queries using a simple user language (most importantly one can use AND and OR to combine terms and field:value terms to query certain fields. In the latter case value will be matched to a literal value or the label of a resource in case the property matching field has a non-literal range.)

Calling the query method will return the path to a new D-Bus object which provides the interface org.kde.nepomuk.Query. The latter interface allows to list the results and emits signals for new or removed results.

Normally one would use the libnepomukqueryclient library provided by kdebase/workspace to access this services.

Another possibility is the Nepomuk Query KIO slave named nepomuksearch. This will return results formatted as UDSEntries.