summaryM:DotNetNuke.Data.PetaPoco.FluentMapperExtensions.Cache``1(DotNetNuke.Data.PetaPoco.FluentMapper{``0},System.String,System.Int32,System.Web.Caching.CacheItemPriority)

Namespace: DotNetNuke.Data.PetaPoco
Assembly: DotNetNuke (in DotNetNuke.dll)

Syntax

C#
public static FluentMapper<TModel> Cache<TModel>(
	this FluentMapper<TModel> mapper,
	string cacheKey,
	int timeOut = 20,
	CacheItemPriority priority = CacheItemPriority.Normal
)
Visual Basic
<ExtensionAttribute> 
Public Shared Function Cache(Of TModel) ( 
	mapper As FluentMapper(Of TModel),
	cacheKey As String,
	Optional timeOut As Integer = 20,
	Optional priority As CacheItemPriority = CacheItemPriority.Normal
) As FluentMapper(Of TModel)

Parameters

mapper
Type: DotNetNuke.Data.PetaPoco..::..FluentMapper<(Of <(<'TModel>)>)>
parammapperM:DotNetNuke.Data.PetaPoco.FluentMapperExtensions.Cache``1(DotNetNuke.Data.PetaPoco.FluentMapper{``0},System.String,System.Int32,System.Web.Caching.CacheItemPriority)
cacheKey
Type: System..::..String
paramcacheKeyM:DotNetNuke.Data.PetaPoco.FluentMapperExtensions.Cache``1(DotNetNuke.Data.PetaPoco.FluentMapper{``0},System.String,System.Int32,System.Web.Caching.CacheItemPriority)
timeOut
Type: System..::..Int32
paramtimeOutM:DotNetNuke.Data.PetaPoco.FluentMapperExtensions.Cache``1(DotNetNuke.Data.PetaPoco.FluentMapper{``0},System.String,System.Int32,System.Web.Caching.CacheItemPriority)
priority
Type: System.Web.Caching..::..CacheItemPriority
parampriorityM:DotNetNuke.Data.PetaPoco.FluentMapperExtensions.Cache``1(DotNetNuke.Data.PetaPoco.FluentMapper{``0},System.String,System.Int32,System.Web.Caching.CacheItemPriority)

Type Parameters

TModel
typeparamTModelM:DotNetNuke.Data.PetaPoco.FluentMapperExtensions.Cache``1(DotNetNuke.Data.PetaPoco.FluentMapper{``0},System.String,System.Int32,System.Web.Caching.CacheItemPriority)

Return Value

returnsM:DotNetNuke.Data.PetaPoco.FluentMapperExtensions.Cache``1(DotNetNuke.Data.PetaPoco.FluentMapper{``0},System.String,System.Int32,System.Web.Caching.CacheItemPriority)

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type FluentMapper<(Of <(<'TModel>)>)>. When you use instance method syntax to call this method, omit the first parameter. For more information, see [b8020aae-374d-46a9-bcb7-8cc2390b93b6] or [175ce3ff-9bbf-4e64-8421-faeb81a0bb51].

See Also