Quasardb API for PHP
Introduction Installation Compilation Configuration API Reference

Classes

  • QdbBatch
  • QdbBatchResult
  • QdbBlob
  • QdbCluster
  • QdbDeque
  • QdbEntry
  • QdbEntryCollection
  • QdbExpirableEntry
  • QdbHashSet
  • QdbInteger
  • QdbTag
  • QdbTagCollection

Exceptions

  • QdbAliasAlreadyExistsException
  • QdbAliasNotFoundException
  • QdbConnectionException
  • QdbContainerEmptyException
  • QdbException
  • QdbIncompatibleTypeException
  • QdbInputException
  • QdbOperationDisabledException
  • QdbOperationException
  • QdbProtocolException
  • QdbSystemException
 1:  2:  3:  4:  5:  6:  7:  8:  9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 
<?php

/**
 * An entry which can expire.
 */
abstract class QdbExpirableEntry extends QdbEntry
{
    /**
     * Sets the absolute expiration time of the entry.
     * @param int $expiry_time The absolute expiration time, in seconds since epoch (`0` means "never expires").
     * @throws QdbAliasNotFoundException
     * @example
     * <code>
     * // Expire entry in two days
     * $cluster->blob('Milk bottle')->expiresAt(time()+172800);
     * </code>
     */
    function expiresAt($expiry_time);

    /**
     * Sets the relative expiration time of the entry.
     * @param int $time_delta The relative expiration time, in seconds.
     * @throws QdbAliasNotFoundException
     * @example
     * <code>
     * // Expire entry in two days
     * $cluster->blob('Milk bottle')->expiresFromNow(172800);
     * </code>
     */
    function expiresFromNow($time_delta);

    /**
     * Gets the expiration time of the entry.
     * @return int The absolute expiration time, in seconds since epoch (`0` means "never expires").
     * @throws QdbAliasNotFoundException
     * @example
     * <code>
     * $expiryTime = $cluster->blob('Milk bottle')->getExpiryTime();
     * </code>
     */
    function getExpiryTime();
}
?>
Copyright 2009-2017 quasardb SAS Documentation generated by ApiGen