1Cache::FileBackend(3) User Contributed Perl DocumentationCache::FileBackend(3)
2
3
4

NAME

6       Cache::FileBackend -- a filesystem based persistance mechanism
7

DESCRIPTION

9       The FileBackend class is used to persist data to the filesystem
10

SYNOPSIS

12         my $backend = new Cache::FileBackend( '/tmp/FileCache', 3, 000 );
13
14         See Cache::Backend for the usage synopsis.
15
16         $backend->store( 'namespace', 'foo', 'bar' );
17
18         my $bar = $backend->restore( 'namespace', 'foo' );
19
20         my $size_of_bar = $backend->get_size( 'namespace', 'foo' );
21
22         foreach my $key ( $backend->get_keys( 'namespace' ) )
23         {
24           $backend->delete_key( 'namespace', $key );
25         }
26
27         foreach my $namespace ( $backend->get_namespaces( ) )
28         {
29           $backend->delete_namespace( $namespace );
30         }
31

METHODS

33       See Cache::Backend for the API documentation.
34
35       new( $root, $depth, $directory_umask )
36           Construct a new FileBackend that writes data to the $root direc‐
37           tory, automatically creates subdirectories $depth levels deep, and
38           uses the umask of $directory_umask when creating directories.
39

PROPERTIES

41       (get⎪set)_root
42           The location of the parent directory in which to store the files
43
44       (get⎪set)_depth
45           The branching factor of the subdirectories created to store the
46           files
47
48       (get⎪set)_directory_umask
49           The umask to be used when creating directories
50

SEE ALSO

52       Cache::Backend, Cache::MemoryBackend, Cache::SharedMemoryBackend
53

AUTHOR

55       Original author: DeWitt Clinton <dewitt@unto.net>
56
57       Last author:     $Author: dclinton $
58
59       Copyright (C) 2001-2003 DeWitt Clinton
60
61
62
63perl v5.8.8                       2003-04-15             Cache::FileBackend(3)
Impressum