[Templates-cvs] cvs commit: TT3/lib/Template Component.pm

cvs@template-toolkit.org cvs@template-toolkit.org
Mon, 13 Dec 2004 17:45:57 +0000


cvs         04/12/13 17:45:56

  Modified:    lib/Template Component.pm
  Log:
  * added component reference to context child created in process(), this
    gives access to metadata, etc.
  
  Revision  Changes    Path
  1.11      +4 -3      TT3/lib/Template/Component.pm
  
  Index: Component.pm
  ===================================================================
  RCS file: /template-toolkit/TT3/lib/Template/Component.pm,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- Component.pm	2004/12/13 13:32:55	1.10
  +++ Component.pm	2004/12/13 17:45:56	1.11
  @@ -15,7 +15,7 @@
   #   modify it under the same terms as Perl itself.
   #
   # REVISION
  -#   $Id: Component.pm,v 1.10 2004/12/13 13:32:55 abw Exp $
  +#   $Id: Component.pm,v 1.11 2004/12/13 17:45:56 abw Exp $
   #
   #========================================================================
   
  @@ -27,7 +27,7 @@
   use Template::Base;
   use base qw( Template::Base );
   
  -our $VERSION   = sprintf("%d.%02d", q$Revision: 1.10 $ =~ /(\d+)\.(\d+)/);
  +our $VERSION   = sprintf("%d.%02d", q$Revision: 1.11 $ =~ /(\d+)\.(\d+)/);
   our $DEBUG     = 0 unless defined $DEBUG;
   our $ERROR     = '';
   our $THROW     = 'component';
  @@ -243,6 +243,7 @@
       $context = $context->child({
           templates => $self->{ templates },
           variables => $variables,
  +        component => $self,
       });
   
       $self->{ _HOT } = 1;
  @@ -345,7 +346,7 @@
   
   =head1 VERSION
   
  -$Revision: 1.10 $
  +$Revision: 1.11 $
   
   =head1 COPYRIGHT