C# Class Geta.EPi.Extensions.SingletonPage.DefaultContentReferenceCache

Default cache for singleton page content references. Uses ConcurrentDictionary.
Inheritance: IContentReferenceCache
Exibir arquivo Open project: Geta/EPi.Extensions

Public Methods

Method Description
DefaultContentReferenceCache ( ) : System

Instantiates new DefaultContentReferenceCache.

GetOrAdd ( CacheKey key, Func valueFactory ) : EPiServer.Core.ContentReference

Gets or adds a singleton page content reference to the cache when not empty.

Method Details

DefaultContentReferenceCache() public method

Instantiates new DefaultContentReferenceCache.
public DefaultContentReferenceCache ( ) : System
return System

GetOrAdd() public method

Gets or adds a singleton page content reference to the cache when not empty.
public GetOrAdd ( CacheKey key, Func valueFactory ) : EPiServer.Core.ContentReference
key CacheKey Cache key as a pair of the root page content reference and singleton page type.
valueFactory Func Factory function to get singleton page content reference.
return EPiServer.Core.ContentReference