ValidationContext.SetCacheValue<T> 方法

设置缓存对象与该名称

命名空间:  Microsoft.VisualStudio.Modeling.Validation
程序集:  Microsoft.VisualStudio.Modeling.Sdk.11.0(在 Microsoft.VisualStudio.Modeling.Sdk.11.0.dll 中)

语法

声明
Public Sub SetCacheValue(Of T As {Class, New}) ( _
    name As String, _
    cacheObject As T _
)
public void SetCacheValue<T>(
    string name,
    T cacheObject
)
where T : class, new()

类型参数

  • T
    使用无参数构造函数的类

参数

  • cacheObject
    类型:T
    将关联的缓存对象用给定的名称

.NET Framework 安全性

请参见

参考

ValidationContext 类

Microsoft.VisualStudio.Modeling.Validation 命名空间