Bot::IRC::Store::SQLite - Bot::IRC persistent data storage with SQLite
version 1.29
use Bot::IRC; Bot::IRC->new( connect => { server => 'irc.perl.org' }, plugins => ['Store::SQLite'], vars => { store => 'bot.sqlite' }, )->run;
This Bot::IRC plugin provides a persistent storage mechanism with a SQLite database file. By default, it's the "store.sqlite" file, but this can be changed with the vars, store value.
vars
store
This plugin adds a single sub to the bot object called store(). Calling it will return a storage object which itself provides get() and set() methods. These operate just like you would expect.
store()
get()
set()
$bot->store->set( user => { nick => 'gryphon', score => 42 } );
my $score = $bot->store->set('user')->{score};
Bot::IRC
Gryphon Shafer <gryphon@cpan.org>
This software is Copyright (c) 2016-2021 by Gryphon Shafer.
This is free software, licensed under:
The Artistic License 2.0 (GPL Compatible)
To install Bot::IRC, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Bot::IRC
CPAN shell
perl -MCPAN -e shell install Bot::IRC
For more information on module installation, please visit the detailed CPAN module installation guide.