类库说明文档
![]() | JHCacheGetTtype Method (String, Ttype) |
获取当前应用程序的 System.Web.Caching.Cache 中存放的指定键的值
Namespace: DCSoft.Utility.Web
Assembly: DCSoft.Utility (in DCSoft.Utility.dll) Version: 0.0.0.0 (1.0.0.0)

C#
public static Ttype Get<Ttype>( string key, Ttype defaultValue )
Parameters
- key
- Type: SystemString
缓存键 - defaultValue
- Type: Ttype
默认值,当异常或获取值为 null 时,将返回该默认值
Type Parameters
- Ttype
- 最终要得到的数据类型
Return Value
Type: Ttype返回指定类型的缓存值
