NullCache.pm untested

filter: Statementstmt 0.0% 0 / 27 Branchbran n/a Conditioncond 0.0% 0 / 3 MC/DCmcdc n/a Subroutinesub 0.0% 0 / 25 Podpod 0.0% 0 / 21 totaltotal 0.0% 0 / 76 SCAR 6.9
CC
1
Cov
0%
Clear
2.0
Purge
2.0
Size
2.0
CRAP 2.0
1 ######################################################################
2 # $Id: NullCache.pm,v 1.7 2002/07/18 06:15:18 dclinton Exp $
3 # Copyright (C) 2001 Jay Sachs, 2002 DeWitt Clinton All Rights Reserved
4 #
5 # Software distributed under the License is distributed on an "AS
6 # IS" basis, WITHOUT WARRANTY OF ANY KIND, either expressed or
7 # implied. See the License for the specific language governing
8 # rights and limitations under the License.
9 ######################################################################
10  
11  
12 package Cache::NullCache;
13  
14 use strict;
15 use vars qw( @ISA );
16 use Cache::BaseCache;
17 use Cache::Cache qw( $EXPIRES_NOW );
18  
19 @ISA = qw ( Cache::BaseCache );
20  
21  
22 sub Clear
23 {
24 }
25  
26  
27 sub Purge
28 {
29 }
30  
31  
32 sub Size
33 {
34 return 0;
35 }
36  
37  
38 sub new
39 {
40 my ( $proto ) = @_;
41  
42 return bless( {}, ref( $proto ) || $proto );
43 }
44  
45  
46 sub clear
47 {
48 }
49  
50  
51 sub get
52 {
53 return undef;
54 }
55  
56  
57 sub get_object
58 {
59 return undef;
60 }
61  
62  
63 sub purge
64 {
65 }
66  
67  
68 sub remove
69 {
70 }
71  
72  
73 sub set
74 {
75 }
76  
77  
78 sub set_object
79 {
80 }
81  
82  
83 sub size
84 {
85 return 0;
86 }
87  
88  
89 sub get_default_expires_in
90 {
91 return $EXPIRES_NOW;
92 }
93  
94  
95 sub get_keys
96 {
97 return ( );
98 }
99  
100  
101 sub get_identifiers
102 {
103 warn( "get_identifiers has been marked deprepricated. use get_keys" );
104  
105 return ( );
106 }
107  
108  
109 sub get_auto_purge_interval
110 {
111 return 0;
112 }
113  
114  
115 sub set_auto_purge_interval
116 {
117 }
118  
119  
120 sub get_auto_purge_on_set
121 {
122 return 0;
123 }
124  
125  
126 sub set_auto_purge_on_set
127 {
128 }
129  
130  
131 sub get_auto_purge_on_get
132 {
133 return 0;
134 }
135  
136  
137 sub set_auto_purge_on_get
138 {
139 }
140  
141  
142 __END__