File Coverage

blib/lib/AxKit/Provider/HTML.pm
Criterion Covered Total %
statement 4 6 66.6
branch n/a
condition n/a
subroutine 2 2 100.0
pod n/a
total 6 8 75.0


line stmt bran cond sub pod time code
1             # $Id: HTML.pm,v 1.1.1.1 2002/05/29 22:03:41 matt Exp $
2              
3             package AxKit::Provider::HTML;
4              
5             @ISA = qw(Apache::AxKit::Provider::File);
6             $VERSION = '1.0';
7              
8 2     2   11408 use strict;
  2         4  
  2         57  
9 2     2   2541 use XML::LibXML;
  0            
  0            
10             use Apache::AxKit::Provider::File;
11             use Apache::AxKit::Exception;
12              
13             sub get_fh {
14             throw Apache::AxKit::Exception ( -text => "get_fh not supported for HTML provider" );
15             }
16              
17             sub get_strref {
18             my $self = shift;
19            
20             my $file = $self->{file};
21             my $parser = XML::LibXML->new();
22             my $doc = $parser->parse_html_file($file);
23             my $str = $doc->toString;
24             return \$str;
25             }
26              
27             1;
28             __END__