| 1 | package Hash::Persistent::Memory; | ||
| 2 | |||
| 3 | # ABSTRACT: in-memory persistent object which doesn't really store anything | ||
| 4 | |||
| 5 | 1 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 6 | 1 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | sub new { | ||
| 9 | 2 | ▶ | return bless {} => shift; |
|
Subroutine
new: called CC=1 SCAR=0.0
Pod
undocumented
| |||
| 10 | } | ||
| 11 | |||
| 12 | ▶ | sub commit {} | |
|
Subroutine
commit: called CC=1 SCAR=0.0
Pod
undocumented
| |||
| 13 | |||
| 14 | # we probably should cleanup $self contents, but Hash::Persistent currently doesn't do it. | ||
| 15 | sub remove { | ||
| 16 | 1 | ▶ | my $self = shift; |
|
Subroutine
remove: called CC=2 SCAR=6.9
Pod
undocumented
| |||
| 17 | 1 | delete $self->{$_} for keys %$self; | |
| 18 | } | ||
| 19 | |||
| 20 | 1 | 1; | |
| 21 | |||
| 22 | __END__ | ||