Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

text::context(3pm) [debian man page]

Text::Context(3pm)					User Contributed Perl Documentation					Text::Context(3pm)

NAME
Text::Context - Handle highlighting search result context snippets SYNOPSIS
use Text::Context; my $snippet = Text::Context->new($text, @keywords); $snippet->keywords("foo", "bar"); # In case you change your mind print $snippet->as_html; print $snippet->as_text; DESCRIPTION
Given a piece of text and some search terms, produces an object which locates the search terms in the message, extracts a reasonable-length string containing all the search terms, and optionally dumps the string out as HTML text with the search terms highlighted in bold. new Creates a new snippet object for holding and formatting context for search terms. keywords Accessor method to get/set keywords. As the context search is done case-insensitively, the keywords will be lower-cased. paras @paras = $self->paras($maxlen) Return shortened paragraphs to fit together into a snippet of at most $maxlen characters. as_text Calculates a "representative" string which contains the given search terms. If there's lots and lots of context between the terms, it's replaced with an ellipsis. as_html([ start => "<some tag>", end => "<some end tag>" ]) Markup the snippet as a HTML string using the specified delimiters or with a default set of delimiters ("<span class="quoted">"). AUTHOR
Original author: Simon Cozens Current maintainer: Tony Bowden BUGS and QUERIES Please direct all correspondence regarding this module to: bug-Text-Context@rt.cpan.org COPYRIGHT AND LICENSE
Copyright (C) 2002-2005 Kasei This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. perl v5.10.1 2009-07-23 Text::Context(3pm)

Check Out this Related Man Page

MooseX::Declare::Context::Parameterized(3pm)		User Contributed Perl Documentation	      MooseX::Declare::Context::Parameterized(3pm)

NAME
MooseX::Declare::Context::Parameterized - context for parsing optionally parameterized statements DESCRIPTION
This context trait will add optional parameterization functionality to the context. ATTRIBUTES
parameter_signature This will be set when the "strip_parameter_signature" method is called and it was able to extract a list of parameterisations. METHODS
has_parameter_signature Predicate method for the "parameter_signature" attribute. add_parameter Allows storing parameters extracted from "parameter_signature" to be used later on. get_parameters Returns all previously added parameters. strip_parameter_signature Maybe[Str] Object->strip_parameter_signature() This method is intended to parse the main namespace of a namespaced keyword. It will use Devel::Declare::Context::Simples "strip_word" method and store the result in the "namespace" attribute if true. SEE ALSO
o MooseX::Declare o MooseX::Declare::Context AUTHOR
Florian Ragwitz <rafl@debian.org> COPYRIGHT AND LICENSE
This software is copyright (c) 2008 by Florian Ragwitz. This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. perl v5.18.2 2013-12-14 MooseX::Declare::Context::Parameterized(3pm)
Man Page