NAME
Test::C2FIT::Parse - Parsing of html source, filtering out contents of arbitrary tags.
SYNOPSIS
Normally, you do not use Parse directly.
$parse = new Test::C2FIT::Parse($string,["table","tr","td"]);
$parse = new Test::C2FIT::Parse($string,["a"]);
DESCRIPTION
Parse creates a linked list of Parse-Objects, so upon parsing, the original content can be restored (or modified, what the fit framework is actually doing).
METHODS
- last()
-
Returns the last parse object in the same hierarchy level (table -> table, tr -> tr etc.) or self, if self is the last one.
- leaf()
-
Returns the first leaf node (=lower hierarchy) or self, if self has no parts.
- text()
-
Returns the text (html markup removed) of the parse object.
- leader()
-
Return the part of the input, which came before this parse object.
- tag()
-
Returns the tag, including any attributes.
- body()
-
Returns the tag body.
- parts()
-
Returns the first Parse object of the next lower hierarchy (e.g. table -> tr, tr -> td etc.)
- end()
-
Returns the closing tag.
- trailer()
-
Returns the portion of the input, which came after this parse object.
- more()
-
Returns the next Parse object on the same hierarchy level.
SEE ALSO
Extensive and up-to-date documentation on FIT can be found at: http://fit.c2.com/