- Name: perl-Lexical-Persistence
- Version: 1.020
- Release: 1
- Epoch: 0
- Group: Development/Languages/Perl
- License: GPL v1+ or Artistic
- Url: http://search.cpan.org/dist/Lexical-Persistence/
- Summary: Lexical::Persistence - Persistent lexical variable values for arbitrary calls.
- Architecture: noarch
- Size: 14853
- Distribution: PLD 3.0 (Th)
- Vendor: PLD
- Packager: PLD bug tracking system ( http://bugs.pld-linux.org/ )
Description:
Lexical::Persistence does a few things, all related. Note that all
the behaviors listed here are the defaults. Subclasses can override
nearly every aspect of Lexical::Persistence's behavior.
Lexical::Persistence lets your code access persistent data through
lexical variables. This example prints "some value" because the value
of $x perists in the $lp object between setter() and getter().
use Lexical::Persistence;
my $lp = Lexical::Persistence->new();
$lp->call(\&setter);
$lp->call(\&getter);
sub setter { my $x = "some value" }
sub getter { print my $x, "\n" }
Lexicals with leading underscores are not persistent.
By default, Lexical::Persistence supports accessing data from multiple
sources through the use of variable prefixes. The set_context()
member sets each data source. It takes a prefix name and a hash of
key/value pairs. By default, the keys must have sigils representing
their variable types.
- BuildArch:
- ExcludeArch:
- ExclusiveArch:
- Cookie: src.th.pld-linux.org 1327781669
- Buildhost: src.th.pld-linux.org