/man/redisExpire.Rd

http://github.com/bwlewis/rredis · Unknown · 41 lines · 41 code · 0 blank · 0 comment · 0 complexity · 75fc9926f976185a17158833f63cc892 MD5 · raw file

  1. \name{redisExpire}
  2. \alias{redisExpire}
  3. \alias{redisPexpire}
  4. \title{Set a timeout on the specified key.}
  5. \description{
  6. Set a timeout on the specified key, after which the key and
  7. corresponding value will be deleted.
  8. }
  9. \usage{
  10. redisExpire(key, seconds)
  11. redisPexpire(key, milliseconds)
  12. }
  13. \arguments{
  14. \item{key}{The character key on which to set the timeout.}
  15. \item{seconds}{The integer timeout in seconds.}
  16. \item{milliseconds}{The integer timeout in milliseconds.}
  17. }
  18. \details{Operations that modify value(s) corresponding to a key subsequent
  19. to the \code{redisExpire} function clear the timeout, removing the expiration.
  20. The \code{redisExpire} function can't set a new timeout value once a timeout
  21. has been set on a key.
  22. }
  23. \value{
  24. Boolean TRUE if the timeout command was successful, FALSE otherwise.
  25. }
  26. \references{
  27. http://redis.io/commands
  28. }
  29. \author{
  30. B. W. Lewis
  31. }
  32. \seealso{
  33. \code{\link{redisExpireAt}}
  34. }
  35. \examples{
  36. \dontrun{
  37. redisConnect()
  38. redisLPush('x',runif(5))
  39. redisExpire('x', 3)
  40. }
  41. }