1
0
mirror of https://github.com/astaxie/beego.git synced 2025-07-10 03:30:20 +00:00

Add GetMulti method for Cache interface

This commit is contained in:
weizili.build17
2015-06-07 21:33:01 +08:00
parent b9852df51c
commit 970f0b460c
8 changed files with 258 additions and 1 deletions

2
cache/cache.go vendored
View File

@ -47,6 +47,8 @@ import (
type Cache interface {
// get cached value by key.
Get(key string) interface{}
// GetMulti is a batch version of Get.
GetMulti(keys []string) []interface{}
// set cached value with key and expire time.
Put(key string, val interface{}, timeout int64) error
// delete cached value by key.