lib/Dancer/Plugin/Params/Normalization/Abstract.pm

filter: Statementstmt 92.3% 12 / 13 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 75.0% 3 / 4 Podpod 100% 1 / 1 totaltotal 88.8% 16 / 18 CC 1 SCAR 2.2
CC
1
Cov
92%
normalize
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.2
« blib/lib/Dancer/Plugin/Params/Normalization/Trim.pm ↑ Summary
1 #
2 # This file is part of Dancer-Plugin-Params-Normalization
3 #
4 # This software is copyright (c) 2011 by Damien "dams" Krotkine.
5 #
6 # This is free software; you can redistribute it and/or modify it under
7 # the same terms as the Perl 5 programming language system itself.
8 #
9 package Dancer::Plugin::Params::Normalization::Abstract;
10 {
11 5 $Dancer::Plugin::Params::Normalization::Abstract::VERSION = '0.52';
12 }
13 5 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
14 5 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
15  
16 # ABSTRACT: class for custom parameters normalization
17  
18 5 ▶use base 'Dancer::Engine';
Subroutine BEGIN: called CC=1 SCAR=0.0
19  
20 # args: ($class)
21 # Overload this method in your normalization class if you have some init stuff to do,
22 # such as a database connection or making sure a directory exists...
23 # sub init { return 1; }
24  
25 # args: ($self, $hashref)
26 # receives a hashref of parameters names/values. It should return a hashrefs of
27 # the normalized (modified) parameters.
28 0 ▶sub normalize {
Subroutine normalize: not called CC=1 SCAR=6.9
Pod documented
29 0 die "retrieve not implemented";
30 }
31  
32 # Methods below this this line should not be overloaded.
33  
34 # The constructor is inherited from Dancer::Engine, itself inherited from Dancer::Object.
35  
36 5 1;
37  
38 __END__
« blib/lib/Dancer/Plugin/Params/Normalization/Trim.pm ↑ Summary