GetInt returns the value for an integer within the cache or a not found error.
(key int64)
| 310 | |
| 311 | // GetInt returns the value for an integer within the cache or a not found error. |
| 312 | func (cache *Cache) GetInt(key int64) (value []byte, err error) { |
| 313 | var bKey [8]byte |
| 314 | binary.LittleEndian.PutUint64(bKey[:], uint64(key)) |
| 315 | return cache.Get(bKey[:]) |
| 316 | } |
| 317 | |
| 318 | // GetIntWithExpiration returns the value and expiration or a not found error. |
| 319 | func (cache *Cache) GetIntWithExpiration(key int64) (value []byte, expireAt uint32, err error) { |