RazorEngine


DefaultCachingProvider

Defined in RazorEngine.dll.

The default caching provider (See ICachingProvider). This implementation does a very simple in-memory caching. It can handle when the same template is used with multiple model-types.

Constructors

ConstructorDescription
new()
Signature: unit -> unit

Initializes a new instance of the DefaultCachingProvider class.

new(registerForCleanup)
Signature: registerForCleanup:Action<string> -> unit

Initializes a new instance of the DefaultCachingProvider class.

Instance members

Instance memberDescription
CacheTemplate(template, templateKey)
Signature: (template:ICompiledTemplate * templateKey:ITemplateKey) -> unit
Modifiers: abstract

Caches a template. See ICachingProvider.CacheTemplate.

Dispose()
Signature: unit -> unit
Modifiers: abstract

Dispose the instance.

TryRetrieveTemplate(...)
Signature: (templateKey:ITemplateKey * modelType:Type * compiledTemplate:byref<ICompiledTemplate>) -> bool
Modifiers: abstract

Try to retrieve a template from the cache. See ICachingProvider.TryRetrieveTemplate.

Returns:

TypeLoader
Signature: TypeLoader
Modifiers: abstract

The manages DefaultCachingProvider.TypeLoader. See ICachingProvider.TypeLoader

Static members

Static memberDescription
GetModelTypeKey(modelType)
Signature: modelType:Type -> Type

Get the key used within a dictionary for a modelType.

Fork me on GitHub