-=head1 METHODS
-
-=head2 open
-
- $store->open({
- path => 'var/',
- debug => 1,
- clean => 1,
- });
-
-=cut
-
-my $path;
-
-my $debug = 0;
-
-sub open {
- my $self = shift;
-
- my $args = shift;
-
- $debug = $args->{debug};
- $path = $args->{path} || confess "no path?";
-
- warn "open ",dump( $args ) if $debug;
-
- $path = "$path/yaml";
-
- if ( ! -e $path ) {
- mkdir $path || die "can't create $path: $!";
- warn "created $path directory\n" if $debug;
- } elsif ( $args->{clean} ) {
- warn "removed old $path\n" if $debug;
- foreach my $uid ( $self->all_uids ) {
- my $file = "$path/$uid.yml";
- unlink $file || die "can't remove $file: $!";
- }
- }
-
-
-}
-
-=head2 update_uid_state
-
- $store->update_uid_state( $uid, $state );
-