Skip to main content.
home | support | download

Back to List Archive

Re: Working examples of $swish -> PropertyList() ?

From: Bill Moseley <moseley(at)not-real.hank.org>
Date: Wed Oct 12 2005 - 12:47:56 GMT
On Wed, Oct 12, 2005 at 08:34:57AM -0400, Thomas R. Bruce wrote:
> Folks:
> 
> I'm having a nasty time getting the PropertyList method to work in the 
> Perl API; calls to it seem to just hang indefinitely, and strace is 
> little help.


$ perl -MSWISH::API -le 'print $_->Name for SWISH::API->new("index.swish-e index2")->PropertyList("index2")'
swishreccount
swishrank
swishfilenum
swishdbfile
swishdocpath
swishtitle
swishdocsize
swishlastmodified

$ perl -MSWISH::API -le 'print $_ for SWISH::API->new("index.swish-e index2")->IndexNames'
index.swish-e
index2


Is it possible you have two versions of swish installed?

> Hangs in the debugger at the first call to PropertyList().  I checked 
> the archive, but the only discussion of PropertyList is as a method for 
> SwishResult, not a swish handle.  The documentation curiously says that 
> PropertyList's one parameter is an "open" index file -- is this 
> significant in some way I'm just not getting?

Right, you can't do:

    $sw = SWISH::API->new('foo');
    $sw->PropertyList('bar');

because bar is not an index in $sw.

-- 
Bill Moseley
moseley@hank.org

Unsubscribe from or help with the swish-e list: 
   http://swish-e.org/Discussion/

Help with Swish-e:
   http://swish-e.org/current/docs
   swish-e@sunsite.berkeley.edu
Received on Wed Oct 12 05:47:57 2005