Album
view release on metacpan or search on metacpan
script/album view on Meta::CPAN
}
}
::cache_entry($file, $self);
}
}
# Actualize.
$self->{file_size} = $st[7];
$self->{timestamp} = $st[9];
}
bless($self, $pkg);
}
INIT {
no strict 'refs';
for my $sub ( @std_fields, @exif_fields ) {
$sub = "_".$sub if $sub eq "rotation";
*{"ImageInfo::$sub"} = sub {
my ($self, $value) = @_;
$self->{$sub} = $value if defined($value);
$self->{$sub};
script/album view on Meta::CPAN
#### Cache maintenance.
package ImageInfoCache;
use constant CACHE_VERSION => 3;
sub new {
my ($pkg, $file) = @_;
$pkg = ref($pkg) || $pkg;
my $self = bless({}, $pkg);
if ( defined($file) ) {
$self->load($file);
if ( ($self->{_version} || 1) != CACHE_VERSION ) {
warn("Incompatible cache version " . $self->version .
" -- invalidated\n") if $verbose;
$self = bless({}, $pkg);
}
}
$self->{_version} = CACHE_VERSION;
$self;
}
sub load {
my ($self, $file) = @_;
our $info;
$info = undef;
( run in 0.959 second using v1.01-cache-2.11-cpan-de7293f3b23 )