Re: Python hookup to beagle for querying indexed data
- From: Jon Trowbridge <trow novell com>
- To: Michael Hay <michael hay gmail com>
- Cc: Dashboard <dashboard-hackers gnome org>
- Subject: Re: Python hookup to beagle for querying indexed data
- Date: Thu, 06 Jan 2005 13:06:15 -0600
On Wed, 2005-01-05 at 07:22 -0800, Michael Hay wrote:
> I'm trying to have a python client make queries into Beagle any
> helpful hints or thoughts on this?
Call the NewQueryPath method in the com.novell.Beagle.Factory interface
on the /com/novell/Beagle/Factory object. That will construct a
server-side query object and returns a path to it as a string.
The methods in the com.novell.Beagle.Query interface can then be used to
define the search string, etc. for the Query. (Look in
BeagleClient/QueryProxy.cs to see the definition of that interface.)
Hits come back asynchronously --- you need to listen for the
HitsAddedAsBinary event to get the results. Hits are encoded as binary
blobs. Look at WriteAsBinary and ReadAsBinary methods in
BeagleClient/Hit.cs to figure out how to decode them.
The source code for beagle-query is in tools/Query.cs. It might help to
look at that too.
Good luck,
-J
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]