comparison Lib/IMPL/Web/TT/Collection.pm @ 107:0e72ad99eef7

Updated Web::TT
author wizard
date Thu, 13 May 2010 03:46:29 +0400
parents
children ddf0f037d460
comparison
equal deleted inserted replaced
106:83e356614c1e 107:0e72ad99eef7
1 package IMPL::Web::TT::Collection;
2 use strict;
3
4 use base qw(IMPL::DOM::Node);
5
6 __PACKAGE__->PassThroughArgs;
7
8 our $AUTOLOAD;
9 sub AUTOLOAD {
10 my $this = shift;
11 my ($method) = ($AUTOLOAD =~ /(\w+)$/);
12
13 my @result = $this->selectNodes($method);
14
15 return $result[0] if @result;
16 return;
17 }
18
19 sub as_list {
20 $_[0]->childNodes;
21 }
22
23 1;