logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

CHI::CacheObject - Contains information about cache entries

Author

       Jonathan Swartz <swartz@pobox.com>

Description

       The CHI method returns this object if the key exists.  The object will be returned even if the entry has
       expired, as long as it has not been removed.

       There is currently no public API for creating one of these objects directly.

Methods

       All methods are read-only. The get_* methods are provided for backward compatibility with Cache::Cache's
       Cache::Object.

       key The key.

       value
           The value.

       expires_at
       get_expires_at
           Epoch time at which item expires.

       created_at
       get_created_at
           Epoch time at which item was last written to.

       is_expired
           Returns  boolean  indicating whether item has expired. This may be probabilistically determined if an
           "expires_variance" was used.

Name

       CHI::CacheObject - Contains information about cache entries

See Also

       CHI

Synopsis

           my $object = $cache->get_object($key);

           my $key        = $object->key();
           my $value      = $object->value();
           my $expires_at = $object->expires_at();
           my $created_at = $object->created_at();

           if ($object->is_expired()) { ... }

Version

       version 0.61

See Also