The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

KinoSearch::Store::RAMFolder - In-memory Folder implementation.

SYNOPSIS

    my $folder = KinoSearch::Store::RAMFolder->new;
    
    # or sometimes...
    my $folder = KinoSearch::Store::RAMFolder->new(
        path   => '/path/to/folder',
    );

DESCRIPTION

RAMFolder is an entirely in-memory implementation of KinoSearch::Store::Folder. It serves two main purposes.

First, it's possible to load an existing FSFolder into memory, which can improve search-speed -- if you have that kind of RAM to spare. Needless to say, any FSFolder you try to load this way should be appropriately modest in size.

Second, RAMFolder is handy for testing and development.

CONSTRUCTORS

new( [labeled params] )

    my $folder = KinoSearch::Store::RAMFolder->new(
        path   => '/path/to/folder',   # optional
    );
  • path - If supplied, attempt to read an FSFolder at that location into memory; otherwise the Folder starts out empty.

INHERITANCE

KinoSearch::Store::RAMFolder isa KinoSearch::Store::Folder isa KinoSearch::Obj.

COPYRIGHT AND LICENSE

Copyright 2005-2009 Marvin Humphrey

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.