1CHI::CacheObject(3)   User Contributed Perl Documentation  CHI::CacheObject(3)
2
3
4

NAME

6       CHI::CacheObject - Contains information about cache entries
7

VERSION

9       version 0.60
10

SYNOPSIS

12           my $object = $cache->get_object($key);
13
14           my $key        = $object->key();
15           my $value      = $object->value();
16           my $expires_at = $object->expires_at();
17           my $created_at = $object->created_at();
18
19           if ($object->is_expired()) { ... }
20

DESCRIPTION

22       The CHI method returns this object if the key exists.  The object will
23       be returned even if the entry has expired, as long as it has not been
24       removed.
25
26       There is currently no public API for creating one of these objects
27       directly.
28

METHODS

30       All methods are read-only. The get_* methods are provided for backward
31       compatibility with Cache::Cache's Cache::Object.
32
33       key The key.
34
35       value
36           The value.
37
38       expires_at
39       get_expires_at
40           Epoch time at which item expires.
41
42       created_at
43       get_created_at
44           Epoch time at which item was last written to.
45
46       is_expired
47           Returns boolean indicating whether item has expired. This may be
48           probabilistically determined if an "expires_variance" was used.
49

SEE ALSO

51       CHI
52

AUTHOR

54       Jonathan Swartz <swartz@pobox.com>
55
57       This software is copyright (c) 2012 by Jonathan Swartz.
58
59       This is free software; you can redistribute it and/or modify it under
60       the same terms as the Perl 5 programming language system itself.
61
62
63
64perl v5.30.0                      2019-07-26               CHI::CacheObject(3)
Impressum