Share via


DbMappingViewCacheTypeAttribute Class

Definition

Defines a custom attribute that specifies the mapping view cache type (subclass of DbMappingViewCache) associated with a context type (subclass of ObjectContext or DbContext). The cache type is instantiated at runtime and used to retrieve pre-generated views in the corresponding context.

[System.AttributeUsage(System.AttributeTargets.Assembly, AllowMultiple=true)]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1019:DefineAccessorsForAttributeArguments")]
public sealed class DbMappingViewCacheTypeAttribute : Attribute
type DbMappingViewCacheTypeAttribute = class
    inherit Attribute
Public NotInheritable Class DbMappingViewCacheTypeAttribute
Inherits Attribute
Inheritance
DbMappingViewCacheTypeAttribute
Attributes

Constructors

DbMappingViewCacheTypeAttribute(Type, String)

Creates a DbMappingViewCacheTypeAttribute instance that associates a context type with a mapping view cache type.

DbMappingViewCacheTypeAttribute(Type, Type)

Creates a DbMappingViewCacheTypeAttribute instance that associates a context type with a mapping view cache type.

Applies to