RazorEngine


CSharpDirectCompilerService

Defined in RazorEngine.dll.

Defines a direct compiler service for the C# syntax.

Constructors

ConstructorDescription
new(strictMode, markupParserFactory)
Signature: (strictMode:bool * markupParserFactory:Func<ParserBase>) -> unit

Initialises a new instance of CSharpDirectCompilerService.

Instance members

Instance memberDescription
BuildTypeName(templateType, modelType)
Signature: (templateType:Type * modelType:Type) -> string
Modifiers: abstract

Builds a type name for the specified template type.

Returns: The string type name (including namespace).

IncludeReferences()
Signature: unit -> IEnumerable<CompilerReference>
Modifiers: abstract

Returns a set of assemblies that must be referenced by the compiled template.

Returns: The set of assemblies.

SourceFileExtension
Signature: string
Modifiers: abstract

Extension of a source file without dot ("cs" for C# files or "vb" for VB.NET files).

Fork me on GitHub