Skip to main content.
home | support | download

Back to List Archive

Re: Perl API : Getting the search time

From: Bill Moseley <moseley(at)>
Date: Wed Apr 20 2005 - 17:03:52 GMT
On Wed, Apr 20, 2005 at 09:29:20AM -0700, CheHax wrote:
> my $hits = $results->Hits;
> and I am looking for something like if ever it exists :
> my $time = $result->TimeTaken;

The swish library doesn't track that.  That's in the binary.

> Otherwise, what's my solution ? Run a timer in my PERL script starting
> before the search and ending right after it ?

perldoc Time::HiRes


   print "Search time: 0.0023 seconds\n";

will probably work fine.

Bill Moseley

Unsubscribe from or help with the swish-e list:

Help with Swish-e:
Received on Wed Apr 20 10:03:53 2005