X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FExcel%2FTemplate%2FContainer.pm;h=2b65d716746857f8a2f159d5e3f3084085ff71af;hb=e976988f30574c0c21cfa29fc5d080827e003fb6;hp=df966d94408c8f225127102664a4ee7eac3269e7;hpb=a084e413f6358c99b0a5334ce1438ebdb3c8c46c;p=p5sagit%2FExcel-Template.git diff --git a/lib/Excel/Template/Container.pm b/lib/Excel/Template/Container.pm index df966d9..2b65d71 100644 --- a/lib/Excel/Template/Container.pm +++ b/lib/Excel/Template/Container.pm @@ -71,51 +71,51 @@ sub render { $_[0]->iterate_over_children($_[1]) } # return $self->iterate_over_children($context); #} -sub max_of -{ - my $self = shift; - my ($context, $attr) = @_; - - my $max = $context->get($self, $attr); - - ELEMENT: - foreach my $e (@{$self->{ELEMENTS}}) - { - $e->enter_scope($context); - - my $v = $e->isa('CONTAINER') - ? $e->max_of($context, $attr) - : $e->calculate($context, $attr); - - $max = $v if $max < $v; - - $e->exit_scope($context, 1); - } - - return $max; -} - -sub total_of -{ - my $self = shift; - my ($context, $attr) = @_; - - my $total = 0; - - ELEMENT: - foreach my $e (@{$self->{ELEMENTS}}) - { - $e->enter_scope($context); - - $total += $e->isa('CONTAINER') - ? $e->total_of($context, $attr) - : $e->calculate($context, $attr); - - $e->exit_scope($context, 1); - } - - return $total; -} +#sub max_of +#{ +# my $self = shift; +# my ($context, $attr) = @_; +# +# my $max = $context->get($self, $attr); +# +# ELEMENT: +# foreach my $e (@{$self->{ELEMENTS}}) +# { +# $e->enter_scope($context); +# +# my $v = $e->isa('CONTAINER') +# ? $e->max_of($context, $attr) +# : $e->calculate($context, $attr); +# +# $max = $v if $max < $v; +# +# $e->exit_scope($context, 1); +# } +# +# return $max; +#} +# +#sub total_of +#{ +# my $self = shift; +# my ($context, $attr) = @_; +# +# my $total = 0; +# +# ELEMENT: +# foreach my $e (@{$self->{ELEMENTS}}) +# { +# $e->enter_scope($context); +# +# $total += $e->isa('CONTAINER') +# ? $e->total_of($context, $attr) +# : $e->calculate($context, $attr); +# +# $e->exit_scope($context, 1); +# } +# +# return $total; +#} 1; __END__