| Search-Tools documentation | Contained in the Search-Tools distribution. |
Search::Tools::RegExp::Keywords - (**DEPRECATED**) access regular expressions for keywords
# deprecated. See Search::Tools::Query
As of version 0.24 this class is deprecated in favor of Search::Tools::Query.
Return Keyword object for keyword.
Returns array of keywords.
Get/set the Search::Tools::Keywords (deprecated) object.
Peter Karman perl@peknet.com
Based on the HTML::HiLiter regular expression building code, originally by the same author, copyright 2004 by Cray Inc.
Thanks to Atomic Learning www.atomiclearning.com
for sponsoring the development of this module.
Copyright 2006 by Peter Karman. This package is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
HTML::HiLiter, Search::Tools::RegExp, Search::Tools::RegExp::Keyword
| Search-Tools documentation | Contained in the Search-Tools distribution. |
package Search::Tools::RegExp::Keywords; use strict; use warnings; use Carp; use base qw( Search::Tools::Object ); __PACKAGE__->mk_ro_accessors( qw( kw start_bound end_bound hash array ) ); our $VERSION = '0.45'; sub keywords { my $self = shift; return @{ $self->{array} }; } sub re { my $self = shift; my $q = shift or croak "need query to get regular expression"; unless ( exists $self->{hash}->{$q} ) { croak "no regexp for query '$q'"; } return $self->{hash}->{$q}; } 1; __END__