=head1 NAME

Hash::Storage::Driver::DBI - DBI driver for Hash::Storage

MODULE IS IN A DEVELOPMENT STAGE. DO NOT USE IT YET.

=head1 SYNOPSIS

    my $st = Hash::Storage->new( driver => [ DBI => {
        dbh           => $dbh,
        serializer    => 'JSON',
        table         => 'users',
        key_column    => 'user_id',
        data_column   => 'serialized',
        index_columns => ['age', 'fname', 'lname', 'gender']
    }]);

    # Store hash by id
    $st->set( 'user1' => { fname => 'Viktor', gender => 'M', age => '28' } );

    # Get hash by id
    my $user_data = $st->get('user1');

    # Delete hash by id
    $st->del('user1');

=head1 DESCRIPTION

Hash::Storage::Driver::DBI is a DBI Driver for Hash::Storage (multipurpose storage for hash). You can consider Hash::Storage object as a collection of hashes.
You can use it for storing users, sessions and a lot more data.

=head1 OPTIONS

=head2 dbh

Database handler

=head2 serializer

Data::Serializer driver name

=head2 table

Table name to save data

=head2 key_column

column for saving object id

=head2 data_column

all data will be serialized in one field.

=head2 index_columns

List of colums to increase searches

=head1 AUTHOR

"koorchik", C<< <"koorchik at cpan.org"> >>

=head1 BUGS

Please report any bugs or feature requests to L<https://github.com/koorchik/Hash-Storage-Driver-DBI/issues>

=head1 ACKNOWLEDGEMENTS


=head1 LICENSE AND COPYRIGHT

Copyright 2012 "koorchik".

This program is free software; you can redistribute it and/or modify it
under the terms of either: the GNU General Public License as published
by the Free Software Foundation; or the Artistic License.

See http://dev.perl.org/licenses/ for more information.

=cut