This is an automatically generated e-mail. To reply, visit: https://git.reviewboard.kde.org/r/117085/

This change has been marked as submitted.


Review request for Baloo.
By Denis Steckelmacher.

Updated March 26, 2014, 2:28 p.m.

Repository: baloo

Description

This patch adds two methods in Baloo::Term: setUserData and userData. They can be used to associate arbitrary QVariants to terms. The data is not serialized to JSON nor read back when the term is deserialized.

The primary use of these two methods is to allow the user query parser to store the position and length of terms. This information is then read back by the query builder widget that uses it to syntax-highlight the queries. Other applications may want to associate data with terms, for instance to pass hints to the search stores.

Testing

The code compiles and all the unit tests of Baloo pass ("make test" in the build directory lists 12 passing tests)

Diffs

  • src/core/term.cpp (ec98c4a)
  • src/core/term.h (23df3f1)

View Diff