line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
###################################################################### |
2
|
|
|
|
|
|
|
# $Id: SizeAwareCache.pm,v 1.10 2002/04/07 17:04:46 dclinton Exp $ |
3
|
|
|
|
|
|
|
# Copyright (C) 2001-2003 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::SizeAwareCache; |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
|
15
|
1
|
|
|
1
|
|
6
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
41
|
|
16
|
1
|
|
|
1
|
|
5
|
use Cache::Cache; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
45
|
|
17
|
1
|
|
|
1
|
|
5
|
use vars qw( @ISA @EXPORT_OK $EXPIRES_NOW $EXPIRES_NEVER $NO_MAX_SIZE ); |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
78
|
|
18
|
1
|
|
|
1
|
|
4
|
use Exporter; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
134
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
@ISA = qw( Cache::Cache Exporter ); |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
@EXPORT_OK = qw( $EXPIRES_NOW $EXPIRES_NEVER $NO_MAX_SIZE ); |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
$EXPIRES_NOW = $Cache::Cache::EXPIRES_NOW; |
25
|
|
|
|
|
|
|
$EXPIRES_NEVER = $Cache::Cache::EXPIRES_NEVER; |
26
|
|
|
|
|
|
|
$NO_MAX_SIZE = -1; |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
sub limit_size; |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
sub get_max_size; |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
sub set_max_size; |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
1; |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
__END__ |