16 lines
320 B
Go
16 lines
320 B
Go
package cache
|
|
|
|
import "io"
|
|
|
|
type Cache interface {
|
|
Get(key string, writer io.Writer) error
|
|
GetString(key string) (string, error)
|
|
GetJSON(key string, value any) error
|
|
|
|
Set(key string, value io.Reader) error
|
|
SetJSON(key string, value any) error
|
|
SetString(key string, value string) error
|
|
|
|
Delete(key string) error
|
|
}
|