| 1 | package Template::Flute::Filter; | ||
| 2 | |||
| 3 | use strict; | ||
| 4 | use warnings; | ||
| 5 | |||
| 6 | =head1 NAME | ||
| 7 | |||
| 8 | Template::Flute::Filter - Filter base class | ||
| 9 | |||
| 10 | =head1 METHODS | ||
| 11 | |||
| 12 | =head2 new | ||
| 13 | |||
| 14 | Creates Template::Flute::Filter object. | ||
| 15 | |||
| 16 | =cut | ||
| 17 | |||
| 18 | sub new { | ||
| 19 | my ($class, $self); | ||
| 20 | |||
| 21 | $class = shift; | ||
| 22 | $self = {}; | ||
| 23 | bless $self, $class; | ||
| 24 | $self->init(@_); | ||
| 25 | return $self; | ||
| 26 | }; | ||
| 27 | |||
| 28 | =head2 init | ||
| 29 | |||
| 30 | No-op initializer, may be overridden in subclass. | ||
| 31 | |||
| 32 | =cut | ||
| 33 | |||
| 34 | sub init { | ||
| 35 | }; | ||
| 36 | |||
| 37 | =head2 filter | ||
| 38 | |||
| 39 | No-op filter, supposed to be overridden in subclass. | ||
| 40 | |||
| 41 | =cut | ||
| 42 | |||
| 43 | sub filter { | ||
| 44 | my ($self, $value) = @_; | ||
| 45 | |||
| 46 | return $value; | ||
| 47 | } | ||
| 48 | |||
| 49 | =head1 AUTHOR | ||
| 50 | |||
| 51 | Stefan Hornburg (Racke), <racke@linuxia.de> | ||
| 52 | |||
| 53 | =head1 LICENSE AND COPYRIGHT | ||
| 54 | |||
| 55 | Copyright 2011-2019 Stefan Hornburg (Racke) <racke@linuxia.de>. | ||
| 56 | |||
| 57 | This program is free software; you can redistribute it and/or modify it | ||
| 58 | under the terms of either: the GNU General Public License as published | ||
| 59 | by the Free Software Foundation; or the Artistic License. | ||
| 60 | |||
| 61 | See http://dev.perl.org/licenses/ for more information. | ||
| 62 | |||
| 63 | =cut | ||
| 64 | |||
| 65 | 1; |