Softpedia
 


LINUX CATEGORIES:



GLOBAL PAGES >>
NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Linux Kernel 3.9.3 / 3....
  • LibreOffice 3.6.6 / 4.0.3
  • MPlayer 1.1.1
  • systemd 204
  • Arch Linux 2013.05.01
  • Blender 2.67a
  • KDE Software Compilatio...
  • CrunchBang Linux Stable...
  • Elementary OS 0.1 / 0.2...
  • SystemRescueCd 3.6.0
  • Home > Linux > Programming > Libraries

    Cache::Mmap 0.11

    Download button

    No screenshots available
    Downloads: 580  View global page NEW!  Tell us about an update
    User Rating:
    Rated by:
    Good (3.0/5)
    9 user(s)
    Developer:

    License / Price:

    Last Updated:

    Category:
    Peter Haworth | More programs
    Perl Artistic License / FREE
    April 15th, 2008, 14:07 GMT
    ROOT / Programming / Libraries

     Read user reviews (0)  Refer to a friend  Subscribe

    Cache::Mmap description

    Cache::Mmap Perl module helps you to share data cache using memory mapped files.

    Cache::Mmap Perl module helps you to share data cache using memory mapped files.

    SYNOPSIS

    use Cache::Mmap;

    $cache=Cache::Mmap->new($filename,%options);

    $val1=$cache->read($key1);
    $cache->write($key2,$val2);
    $cache->delete($key3);

    This module implements a shared data cache, using memory mapped files. If routines are provided which interact with the underlying data, access to the cache is completely transparent, and the module handles all the details of refreshing cache contents, and updating underlying data, if necessary.
    Cache entries are assigned to "buckets" within the cache file, depending on the key. Within each bucket, entries are stored approximately in order of last access, so that frequently accessed entries will move to the head of the bucket, thus decreasing access time. Concurrent accesses to the same bucket are prevented by file locking of the relevant section of the cache file.

    CONFIGURATION METHODS

    These methods are used to examine/update the configuration of a cache. Most of these methods are read-only, and the value returned may be different to that passed to the constructor, since the cache may have been created by an earlier process which specified different parameters.

    buckets()

    Returns the number of buckets in the cache file.

    bucketsize()

    Returns the size of buckets (in bytes) in the cache file.

    cachenegative()

    Returns true if items not found in the underlying data are cached anyway.

    context()

    Returns the context data for reads and writes to the underlying data.

    context($context)

    Provides new context data for reads and writes to the underlying data.

    expiry()

    Returns the time in seconds cache entries are considered valid for, or zero for indefinite validity.

    pagesize()

    Returns the page size (in bytes) of the cache file.

    strings()

    Returns true if the cache stores strings rather than references.

    writethrough()

    Returns true if items written to the cache are immediately written to the underlying data.

    Product's homepage

    Requirements:

    · Perl

      


    TAGS:

    share data cache | memory mapped files | Perl module | Cache::Mmap | share | data

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM