The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

ROADS::Rank - A class to rank WHOIS++ search results

SYNOPSIS

  use ROADS::Rank;
  # @results are the results of a WHOIS++ query done already
  @ranked_results = rank($query, @results);

DESCRIPTION

This class defines a mechanism for sorting the results of a WHOIS++ search according to the number of occurrences of the search terms in the resulting templates.

METHODS

rank( query, @results );

This method takes an array of WHOIS++ template handles results, and the original search terms query which gave rise to them. It sorts the handles according to the frequency of the search terms in the templates which they point to, and returns the sorted list.

BUGS

We probably don't cope very well with some of the possible permutations of search terms and punctuation. Perhaps we should strip them down to just alphanumerics before doing the comparison ?

SEE ALSO

"admin.pl" in admin-cgi, "search.pl" in cgi-bin

COPYRIGHT

Copyright (c) 1988, Martin Hamilton <martinh@gnu.org> and Jon Knight <jon@net.lut.ac.uk>. All rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

It was developed by the Department of Computer Studies at Loughborough University of Technology, as part of the ROADS project. ROADS is funded under the UK Electronic Libraries Programme (eLib), the European Commission Telematics for Research Programme, and the TERENA development programme.

AUTHOR

Martin Hamilton <martinh@gnu.org>