KDE 4.4 PyKDE API Reference
  • KDE's Python API
  • Overview
  • PyKDE Home
  • Sitemap
  • Contact Us
 

Result Class Reference

from PyKDE4.nepomuk import *

Namespace: Nepomuk.Query.Result

Detailed Description

\class Result result.h Nepomuk/Query/Result

A single search result.

A search via QueryServiceClient returns a set of Result object. A result consists of a Nepomuk.Resource and an optional score.

Author:
Sebastian Trueg <trueg@kde.org>

Since:
4.4


Methods

 __init__ (self)
 __init__ (self, Nepomuk.Resource resource, float score=0.0)
 __init__ (self, Nepomuk.Query.Result a0)
 addRequestProperty (self, Nepomuk.Types.Property property, Soprano.Node value)
bool operator == (self, Nepomuk.Query.Result a0)
Soprano.Node operator [] (self, Nepomuk.Types.Property property)
{Nepomuk.Types.Property:Soprano.Node} requestProperties (self)
Soprano.Node requestProperty (self, Nepomuk.Types.Property property)
Nepomuk.Resource resource (self)
float score (self)
 setScore (self, float score)

Method Documentation

__init__ (   self )

Copy constructor.

__init__ (  self,
Nepomuk.Resource  resource,
float  score=0.0
)

Create a new result.

Parameters:
resource  The result resource.

Parameters:
score  The optional result score.

__init__ (  self,
Nepomuk.Query.Result  a0
)

Copy constructor.

addRequestProperty (  self,
Nepomuk.Types.Property  property,
Soprano.Node  value
)

Add the value of a request property.

\sa Query.RequestProperty

bool operator == (  self,
Nepomuk.Query.Result  a0
)

Comparison operator

Soprano.Node operator [] (  self,
Nepomuk.Types.Property  property
)

Retrieve value of request property property.

\sa requestProperties, addRequestProperty

{Nepomuk.Types.Property:Soprano.Node} requestProperties (   self )

Retrieve the values of the request properties.

\sa Query.RequestProperty

Soprano.Node requestProperty (  self,
Nepomuk.Types.Property  property
)

Retrieve value of request property property.

\sa requestProperties, addRequestProperty

Nepomuk.Resource resource (   self )

The result resource.

float score (   self )

The score of the result. By default the value is 0.0 which means no score.

\sa setScore

setScore (  self,
float  score
)

Set the score of the result.

\sa score

  • Full Index

Modules

  • akonadi
  • dnssd
  • kdecore
  • kdeui
  • khtml
  • kio
  • knewstuff
  • kparts
  • kutils
  • nepomuk
  • phonon
  • plasma
  • polkitqt
  • solid
  • soprano
This documentation is maintained by Simon Edwards.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal