Plucene::QueryParser - Turn query strings into Plucene::Search::Query objects
my $p = Plucene::QueryParser->new({ analyzer => Plucene::Analysis::Analyzer $a, default => "text" }); my Plucene::Search::Query $q = $p->parse("foo bar:baz");
This module is responsible for turning a query string into a Plucene::Query object. It needs to have an Analyzer object to help it tokenize incoming queries, and it also needs to know the default field to be used if no field is given in the query string.
my $p = Plucene::QueryParser->new({ analyzer => Plucene::Analysis::Analyzer $a, default => "text" });
Construct a new query parser
my Plucene::Search::Query $q = $p->parse("foo bar:baz");
Turns the string into a query object.
To install Plucene, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Plucene
CPAN shell
perl -MCPAN -e shell install Plucene
For more information on module installation, please visit the detailed CPAN module installation guide.