C# Class Castle.Components.Common.TemplateEngine.NVelocityTemplateEngine.NVelocityTemplateEngine

Implementation of ITemplateEngine that uses NVelocity
Inheritance: ITemplateEngine, ISupportInitialize
Afficher le fichier Open project: nats/castle-1.0.3-mono Class Usage Examples

Méthodes publiques

Méthode Description
AddResourceAssembly ( string assembly ) : void

Add an assembly to the resource collection.

BeginInit ( ) : void

Starts/configure NVelocity based on the properties.

EndInit ( ) : void
HasTemplate ( String templateName ) : bool

Returns true only if the specified template exists and can be used

NVelocityTemplateEngine ( ) : System

Constructs a NVelocityTemplateEngine instance assuming the default values

NVelocityTemplateEngine ( String templateDir ) : System

Constructs a NVelocityTemplateEngine instance specifing the template directory

Process ( IDictionary context, String templateName, TextWriter output ) : bool

Process the template with data from the context.

Process ( IDictionary context, string templateName, TextWriter output, TextReader inputTemplate ) : bool

Process the input template with data from the context.

Process ( IDictionary context, string templateName, TextWriter output, string inputTemplate ) : bool

Process the input template with data from the context.

Private Methods

Méthode Description
CreateContext ( IDictionary context ) : IContext
ExpandTemplateDir ( String templateDir ) : String

Method Details

AddResourceAssembly() public méthode

Add an assembly to the resource collection.
public AddResourceAssembly ( string assembly ) : void
assembly string
Résultat void

BeginInit() public méthode

Starts/configure NVelocity based on the properties.
public BeginInit ( ) : void
Résultat void

EndInit() public méthode

public EndInit ( ) : void
Résultat void

HasTemplate() public méthode

Returns true only if the specified template exists and can be used
public HasTemplate ( String templateName ) : bool
templateName String
Résultat bool

NVelocityTemplateEngine() public méthode

Constructs a NVelocityTemplateEngine instance assuming the default values
public NVelocityTemplateEngine ( ) : System
Résultat System

NVelocityTemplateEngine() public méthode

Constructs a NVelocityTemplateEngine instance specifing the template directory
public NVelocityTemplateEngine ( String templateDir ) : System
templateDir String
Résultat System

Process() public méthode

Process the template with data from the context.
public Process ( IDictionary context, String templateName, TextWriter output ) : bool
context IDictionary
templateName String
output System.IO.TextWriter
Résultat bool

Process() public méthode

Process the input template with data from the context.
public Process ( IDictionary context, string templateName, TextWriter output, TextReader inputTemplate ) : bool
context IDictionary The context.
templateName string Name of the template. Used only for information during logging
output System.IO.TextWriter The output.
inputTemplate System.IO.TextReader The input template.
Résultat bool

Process() public méthode

Process the input template with data from the context.
public Process ( IDictionary context, string templateName, TextWriter output, string inputTemplate ) : bool
context IDictionary The context.
templateName string Name of the template. Used only for information during logging
output System.IO.TextWriter The output.
inputTemplate string The input template.
Résultat bool