Commit | Line | Data |
9bb20750 |
1 | package Plack::Session::Store::Null; |
2 | use strict; |
3 | use warnings; |
4 | |
30cc0a71 |
5 | our $VERSION = '0.01'; |
6 | our $AUTHORITY = 'cpan:STEVAN'; |
7 | |
9bb20750 |
8 | sub new { bless {} => shift } |
9 | sub fetch {} |
10 | sub store {} |
11 | sub delete {} |
12 | sub cleanup {} |
13 | sub persist {} |
14 | |
74e0eff0 |
15 | sub dump_session { +{} } |
16 | |
9bb20750 |
17 | 1; |
18 | |
19 | __END__ |
20 | |
21 | =pod |
22 | |
23 | =head1 NAME |
24 | |
25 | Plack::Session::Store::Null - Null store |
26 | |
3d92cf47 |
27 | =head1 SYNOPSIS |
28 | |
29 | use Plack::Builder; |
30 | use Plack::Middleware::Session; |
31 | use Plack::Session::Store::Null; |
32 | |
33 | my $app = sub { |
34 | return [ 200, [ 'Content-Type' => 'text/plain' ], [ 'Hello Foo' ] ]; |
35 | }; |
36 | |
37 | builder { |
38 | enable 'Session', |
39 | store => Plack::Session::Store::Null->new; |
40 | $app; |
41 | }; |
42 | |
9bb20750 |
43 | =head1 DESCRIPTION |
44 | |
45 | Sometimes you don't want to store anything in your sessions, but |
46 | L<Plack::Session> requires a C<store> instance, so you can use this |
47 | one and all methods will return null. |
48 | |
3d92cf47 |
49 | This is a subclass of L<Plack::Session::Store> and implements |
50 | it's full interface. |
51 | |
9bb20750 |
52 | =head1 BUGS |
53 | |
54 | All complex software has bugs lurking in it, and this module is no |
55 | exception. If you find a bug please either email me, or add the bug |
56 | to cpan-RT. |
57 | |
58 | =head1 AUTHOR |
59 | |
60 | Stevan Little E<lt>stevan.little@iinteractive.comE<gt> |
61 | |
62 | =head1 COPYRIGHT AND LICENSE |
63 | |
64 | Copyright 2009 Infinity Interactive, Inc. |
65 | |
66 | L<http://www.iinteractive.com> |
67 | |
68 | This library is free software; you can redistribute it and/or modify |
69 | it under the same terms as Perl itself. |
70 | |
71 | =cut |
72 | |