Click or drag to resize

RazorHelper Class

Helper to compile and execute Razor scripts (RazorEngineCore based)
Inheritance Hierarchy
SystemObject
  Seal.HelpersRazorHelper

Namespace: Seal.Helpers
Assembly: SealLibrary (in SealLibrary.dll) Version: 10.0.1.0+a44cd3a7f03c2bf3cdbd971a878c679e40bed08a
Syntax
C#
public class RazorHelper

The RazorHelper type exposes the following members.

Constructors
 NameDescription
Public methodRazorHelperInitializes a new instance of the RazorHelper class
Top
Methods
 NameDescription
Public methodStatic memberCompile Compile a Razor script under the given cache key if not already cached
Public methodStatic memberCompileExecute Compile a Razor script (if not already cached) and execute it with the given model. Returns the result of the script execution.
Public methodStatic memberCompilePartial Compile a Razor script as a partial template and return its cache key (used later by @Include)
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodStatic memberGetFullScript Returns the script with the default Seal using directives added (@using Seal.Model, @using Seal.Helpers)
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Public methodStatic memberLoadRazorAssemblies Force the load of the assemblies
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
Fields
 NameDescription
Public fieldStatic member_01 Field used to force the load of the System.Diagnostics.EventLog assembly (necessary to compile Security Scripts)
Public fieldStatic memberRazorCacheDirectory Directory where the compiled script assemblies are cached
Public fieldStatic memberValidator Optional script validator called before compilation and execution
Top
See Also