You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
483 B
16 lines
483 B
using System;
|
|
using System.Collections.Generic;
|
|
|
|
namespace SqlSugar
|
|
{
|
|
public interface ICacheService
|
|
{
|
|
void Add<V>(string key, V value);
|
|
void Add<V>(string key, V value, int cacheDurationInSeconds);
|
|
bool ContainsKey<V>(string key);
|
|
V Get<V>(string key);
|
|
IEnumerable<string> GetAllKey<V>();
|
|
void Remove<V>(string key);
|
|
V GetOrCreate<V>(string cacheKey, Func<V> create,int cacheDurationInSeconds=int.MaxValue);
|
|
}
|
|
}
|